import { gql } from "@apollo/client"; import { PRODUCT_VARIANT_FRAGMENT } from "./Variant"; export const PRODUCT_FRAGMENT = gql` fragment ProductFragment on Product { id name slug description seoTitle seoDescription translation(languageCode: $locale) { id name slug description seoTitle seoDescription } variants { ...ProductVariantFragment } media { id url alt type } category { id name slug } metadata { key value } } ${PRODUCT_VARIANT_FRAGMENT} `; export const PRODUCT_LIST_ITEM_FRAGMENT = gql` fragment ProductListItemFragment on Product { id name slug description translation(languageCode: $locale) { id name slug description } variants { id name sku quantityAvailable pricing { price { gross { amount currency } } onSale discount { gross { amount currency } } } } media { id url alt } } `;