mirror of
https://github.com/vercel/commerce.git
synced 2025-05-19 07:56:59 +00:00
wip: Saving work
This commit is contained in:
parent
7bf920ccc0
commit
bd4cabd16c
@ -15,13 +15,13 @@ export function ProductTastingNotes({ product }: { product: Product }) {
|
|||||||
return (
|
return (
|
||||||
<div className="flex flex-col justify-between space-y-6 px-6 md:flex-row md:items-end md:space-x-12 md:space-y-0">
|
<div className="flex flex-col justify-between space-y-6 px-6 md:flex-row md:items-end md:space-x-12 md:space-y-0">
|
||||||
{!!notes ? (
|
{!!notes ? (
|
||||||
<div className="flex w-1/2 flex-col space-y-4">
|
<div className="font-multilingual flex flex-col space-y-4 md:min-w-[120px] md:max-w-sm">
|
||||||
<h2 className="font-multilingual text-[38px] leading-tight">tasting notes</h2>
|
<h2 className="text-[38px] leading-tight">tasting notes</h2>
|
||||||
<div className="flex w-full flex-row justify-end whitespace-pre-line">{notes}</div>
|
<div className="flex w-full flex-row justify-end whitespace-pre-line">{notes}</div>
|
||||||
</div>
|
</div>
|
||||||
) : null}
|
) : null}
|
||||||
{imageUrl && imageHeight && imageWidth && (
|
{imageUrl && imageHeight && imageWidth && (
|
||||||
<div>
|
<div className="md:w-2/3">
|
||||||
<Image
|
<Image
|
||||||
src={imageUrl}
|
src={imageUrl}
|
||||||
width={imageWidth}
|
width={imageWidth}
|
||||||
|
@ -1,12 +1,7 @@
|
|||||||
import cartFragment from '../fragments/cart';
|
import cartFragment from '../fragments/cart';
|
||||||
|
|
||||||
export const addToCartMutation = /* GraphQL */ `
|
export const addToCartMutation = /* GraphQL */ `
|
||||||
mutation addToCart(
|
mutation addToCart($cartId: ID!, $lines: [CartLineInput!]!) {
|
||||||
$cartId: ID!
|
|
||||||
$lines: [CartLineInput!]!
|
|
||||||
$country: CountryCode
|
|
||||||
$language: LanguageCode
|
|
||||||
) @inContext($country: String, $language: String) {
|
|
||||||
cartLinesAdd(cartId: $cartId, lines: $lines) {
|
cartLinesAdd(cartId: $cartId, lines: $lines) {
|
||||||
cart {
|
cart {
|
||||||
...cart
|
...cart
|
||||||
@ -17,11 +12,7 @@ export const addToCartMutation = /* GraphQL */ `
|
|||||||
`;
|
`;
|
||||||
|
|
||||||
export const createCartMutation = /* GraphQL */ `
|
export const createCartMutation = /* GraphQL */ `
|
||||||
mutation createCart(
|
mutation createCart($lineItems: [CartLineInput!]) {
|
||||||
$lineItems: [CartLineInput!],
|
|
||||||
$country: CountryCode,
|
|
||||||
$language: LanguageCode
|
|
||||||
) @inContext($country: String, $language: String) {
|
|
||||||
cartCreate(input: { lines: $lineItems }) {
|
cartCreate(input: { lines: $lineItems }) {
|
||||||
cart {
|
cart {
|
||||||
...cart
|
...cart
|
||||||
@ -32,8 +23,7 @@ export const createCartMutation = /* GraphQL */ `
|
|||||||
`;
|
`;
|
||||||
|
|
||||||
export const editCartItemsMutation = /* GraphQL */ `
|
export const editCartItemsMutation = /* GraphQL */ `
|
||||||
mutation editCartItems($cartId: ID!, $lines: [CartLineUpdateInput!]!, $country: CountryCode, $language: LanguageCode)
|
mutation editCartItems($cartId: ID!, $lines: [CartLineUpdateInput!]!) {
|
||||||
@inContext($country: String, $language: String) {
|
|
||||||
cartLinesUpdate(cartId: $cartId, lines: $lines) {
|
cartLinesUpdate(cartId: $cartId, lines: $lines) {
|
||||||
cart {
|
cart {
|
||||||
...cart
|
...cart
|
||||||
@ -44,8 +34,7 @@ export const editCartItemsMutation = /* GraphQL */ `
|
|||||||
`;
|
`;
|
||||||
|
|
||||||
export const removeFromCartMutation = /* GraphQL */ `
|
export const removeFromCartMutation = /* GraphQL */ `
|
||||||
mutation removeFromCart($cartId: ID!, $lineIds: [ID!]!, $country: CountryCode, $language: LanguageCode)
|
mutation removeFromCart($cartId: ID!, $lineIds: [ID!]!) {
|
||||||
@inContext($country: String, $language: String) {
|
|
||||||
cartLinesRemove(cartId: $cartId, lineIds: $lineIds) {
|
cartLinesRemove(cartId: $cartId, lineIds: $lineIds) {
|
||||||
cart {
|
cart {
|
||||||
...cart
|
...cart
|
||||||
|
Loading…
x
Reference in New Issue
Block a user