challenge-vtex-io-andrea-ma.../store/blocks/pdp/product.jsonc

497 lines
11 KiB
Plaintext

{
"store.product": {
"children": [
"html#breadcrumb",
"condition-layout.product#availability",
"html#product-description",
"html#shelf-container",
"flex-layout.row#newsletter-wrapper"
// "newsletter-form"
]
},
"html#breadcrumb": {
"props": {
"tag": "section",
"testId": "breadcrumbs",
"blockClass": "pdp-breadcrumb"
},
"children": ["breadcrumb"]
},
"html#product-description": {
"props": {
"tag": "section",
"testId": "product-description"
},
"children": ["tab-layout#description"]
},
"tab-layout#description": {
"props": {
"blockClass": "description",
"defaultActiveTabId": "description1"
},
"children": ["tab-list#description", "tab-content#description"]
},
"tab-list#description": {
"children": [
"tab-list.item#description1",
"tab-list.item#description2",
"tab-list.item#description3",
"tab-list.item#description4",
"tab-list.item#description5"
]
},
"tab-list.item#description1": {
"props": {
"tabId": "description1",
"label": "Descrição",
"defaultActiveTab": true
}
},
"tab-list.item#description2": {
"props": {
"tabId": "description2",
"label": "Descrição",
"defaultActiveTab": false
}
},
"tab-list.item#description3": {
"props": {
"tabId": "description3",
"label": "Descrição",
"defaultActiveTab": false
}
},
"tab-list.item#description4": {
"props": {
"tabId": "description4",
"label": "Descrição",
"defaultActiveTab": false
}
},
"tab-list.item#description5": {
"props": {
"tabId": "description5",
"label": "Descrição",
"defaultActiveTab": false
}
},
"tab-content#description": {
"children": [
"tab-content.item#description1",
"tab-content.item#description2",
"tab-content.item#description3",
"tab-content.item#description4",
"tab-content.item#description5"
]
},
"tab-content.item#description1": {
"props": {
"tabId": "description1"
},
"children": ["product-images", "product-description"]
},
"tab-content.item#description2": {
"props": {
"tabId": "description2"
},
"children": ["product-images", "product-description"]
},
"tab-content.item#description3": {
"props": {
"tabId": "description3"
},
"children": ["product-images", "product-description"]
},
"tab-content.item#description4": {
"props": {
"tabId": "description4"
},
"children": ["product-images", "product-description"]
},
"tab-content.item#description5": {
"props": {
"tabId": "description5"
},
"children": ["product-images", "product-description"]
},
"condition-layout.product#availability": {
"props": {
"conditions": [
{
"subject": "isProductAvailable"
}
],
"Then": "flex-layout.row#product-main",
"Else": "flex-layout.row#product-availability"
}
},
"flex-layout.row#product-main": {
"props": {
"marginBottom": 5,
"blockClass": "productMain",
"fullWidth": true
},
"children": ["html#product-images", "flex-layout.col#right-col"]
},
"html#product-images": {
"props": {
"tag": "section",
"testId": "product-images",
"blockClass": "product-images"
},
"children": ["product-images"]
},
"product-images": {
"props": {
"aspectRatio": {
"desktop": "auto",
"phone": "16:9"
},
"thumbnailsOrientation": "horizontal",
"showNavigationArrows": false,
"showPaginationDots": false,
"maxHeight": 2560
}
},
"flex-layout.col#right-col": {
"props": {
"width": "50%",
"preventVerticalStretch": true,
"blockClass": "right-col"
},
"children": [
// "html#product-name",
"flex-layout.row#product-name",
"html#codigo",
// "product-rating-summary",
// "flex-layout.row#selling-price",
"html#selling-price",
"html#product-installments",
// "flex-layout.row#list-price-savings",
"html#pix-price",
"html#sku-selector",
// "product-assembly-options",
// "product-gifts",
"flex-layout.row#quantity-buy",
// "availability-subscriber",
"html#shipping-simulator"
]
},
"html#product-name": {
"props": {
"testId": "product-name",
"blockClass": "product-name"
},
"children": ["vtex.store-components:product-name"]
},
"flex-layout.row#product-name": {
"props": {
"marginBottom": 3,
"blockClass": "product-name"
},
"children": ["html#product-name"]
},
"html#codigo": {
"props": {
// "blockClass": "codigo",
"testId": "product-code"
},
"children": ["product-identifier.product"]
},
"html#product-installments": {
"props": {
"testId": "product-installments"
},
"children": ["product-installments"]
},
"html#pix-price": {
"props": {
"tag": "div",
"testId": "pix-price",
"blockClass": "pix-price"
},
"children": ["image#pix-logo", "flex-layout.col#pix-discount"]
},
// "flex-layout.col#pix-image": {
// "children": ["image#pix-logo"]
// },
"image#pix-logo": {
"props": {
"src": "https://agenciamagma.vteximg.com.br/arquivos/pix-andreamm.svg",
"blockClass": "pix-logo"
}
},
"flex-layout.col#pix-discount": {
"children": ["pix-discount", "product-price-savings"],
"props": {
"blockClass": "pix-discount"
}
},
"html#sku-selector": {
"props": {
"testId": "sku-selector"
},
"children": ["sku-selector"]
},
// "sku-selector": {
// "props": {
// // "showValueNameForImageVariation": true
// }
// },
"flex-layout.row#quantity-buy": {
"props": {
"blockClass": "quantity-buy",
"preventHorizontalStretch": true,
"preventVerticalStretch": true
},
"children": ["html#product-quantity", "flex-layout.col#buy-button"]
},
"html#product-quantity": {
"props": {
"testId": "product-quantity"
},
"children": ["product-quantity#quantity"]
},
"product-quantity#quantity": {
"props": {
// "blockClass": "quantity"
"showLabel": false
}
},
"flex-layout.col#buy-button": {
"props": {
"blockClass": "buy-button",
"width": "grow"
},
"children": ["html#add-to-cart-button"]
},
"html#add-to-cart-button": {
"props": {
"testId": "add-to-cart-button"
},
"children": ["add-to-cart-button#product"]
},
"flex-layout.row#buy-button": {
"props": {
"marginTop": 4,
"marginBottom": 7
},
"children": ["add-to-cart-button#product"]
},
"add-to-cart-button#product": {
"props": {
"text": "ADICIONAR À SACOLA"
}
},
"html#shipping-simulator": {
"props": {
"testId": "shipping-simulator",
"blockClass": "shipping-simulator"
},
"children": ["shipping-simulator"]
},
"flex-layout.row#product-availability": {
"props": {
"marginBottom": 5,
"blockClass": "productMain",
"fullWidth": true
},
"children": [
"html#product-images",
"flex-layout.col#right-col-availability"
]
},
"flex-layout.col#right-col-availability": {
"props": {
"width": "50%",
"preventVerticalStretch": true,
// "rowGap": 0,
"blockClass": "info-availability"
},
"children": [
"flex-layout.row#product-name",
"product-identifier.product",
"flex-layout.row#availability",
"html#sku-selector"
]
},
"flex-layout.row#availability": {
"props": {
"blockClass": "message-availability"
},
"children": ["availability-subscriber"]
},
"html#shelf-container": {
"props": {
"blockClass": "shelf-container"
},
"children": ["rich-text#see-also", "list-context.product-list"]
},
"rich-text#see-also": {
"props": {
"text": "#### Você também pode gostar:",
"blockClass": "see-also"
}
},
"list-context.product-list": {
"blocks": ["product-summary.shelf"],
"children": ["html#slider"]
},
"html#slider": {
"props": {
"testId": "product-summary-list"
},
"children": ["slider-layout#related-products"]
},
"slider-layout#related-products": {
"props": {
"itemsPerPage": {
"desktop": 4,
"tablet": 3,
"phone": 2
},
"infinite": true,
"showNavigationArrows": "always",
"blockClass": "carousel"
// "fullWidth": false
}
// ,
// "children": ["rich-text#1", "rich-text#2", "rich-text#3"]
},
"flex-layout.row#newsletter-wrapper": {
"props": {
"blockClass": "newsletter-wrapper"
},
"children": [
"rich-text#newsletter-title",
"rich-text#newsletter-subtitle",
"newsletter-form"
]
},
// "flex-layout.row#input-submit": {
// "children": ["newsletter-form"]
// },
"rich-text#newsletter-title": {
"props": {
"text": "Assine nossa newsletter",
"blockClass": "newsletter-title"
}
},
"rich-text#newsletter-subtitle": {
"props": {
"text": "Receba ofertas e novidades por e-mail",
"blockClass": "newsletter-subtitle"
}
},
"newsletter-form": {
"children": ["newsletter-input-email", "newsletter-submit"]
},
"newsletter-input-email": {
"props": {
"placeholderText": "Digite seu e-mail"
// "width": "90%"
}
}
// "newsletter": {
// "children": ["rich-text#newsletter-title", "newsletter-form"]
// },
// "rich-text#newsletter-title": {
// "props": {
// "text": "Assine nossa newsletter"
// }
// },
// "flex-layout.row#newsletter-wrapper": {
// "props": {
// "blockClass": "newsletter-wrapper"
// },
// "children": [
// "rich-text#newsletter-title",
// "rich-text#newsletter-subtitle",
// "newsletter-form"
// ]
// },
// "newsletter-form": {
// "children": [
// "rich-text#newsletter-title",
// "rich-text#newsletter-subtitle",
// "newsletter-input-email",
// "newsletter-submit"
// ]
// }
// "newsletter-form": {
// "children": [
// "rich-text#newsletter-title",
// "rich-text#newsletter-subtitle",
// // "newsletter-input-email",
// // "newsletter-submit"
// "flex-layout.row#newsletter-form"
// ]
// },
// "flex-layout.row#newsletter-form": {
// "props": {
// "blockClass": "newsletter-form",
// "preventHorizontalStretch": true,
// "preventVerticalStretch": true,
// "horizontalAlign": "center"
// },
// "children": [
// "rich-text#newsletter-title",
// "rich-text#newsletter-subtitle",
// "newsletter-form"
// ]
// }
// "newsletter-form": {
// "children": ["newsletter-input-email", "newsletter-submit"]
// }
// "newsletter-input-email": {
// "props": {
// "placeholderText": "Digite seu e-mail"
// // "width": "90%"
// }
}