forked from M3-Academy/challenge-vtex-io
Entrega do Desafio #1
@ -11,393 +11,7 @@
|
||||
"html#slider-block-container",
|
||||
"product-questions-and-answers"
|
||||
]
|
||||
},
|
||||
|
||||
//Breadcrumb
|
||||
|
||||
"html#breadcrumb": {
|
||||
"props": {
|
||||
"tag": "section",
|
||||
"testId": "breadcrumbs",
|
||||
"blockClass": "pdp-breadcrumb"
|
||||
},
|
||||
"children": ["breadcrumb"]
|
||||
},
|
||||
|
||||
//Availability
|
||||
|
||||
"condition-layout.product#availability": {
|
||||
"props": {
|
||||
"conditions": [
|
||||
{
|
||||
"subject": "isProductAvailable"
|
||||
}
|
||||
],
|
||||
"Then": "html#product-main",
|
||||
"Else": "html#product-availability"
|
||||
}
|
||||
},
|
||||
"html#product-main": {
|
||||
"props": {
|
||||
"blockClass": "product-main-content"
|
||||
},
|
||||
"children": ["html#flex-layout.col#stack", "html#right-col"]
|
||||
},
|
||||
|
||||
"html#flex-layout.col#stack": {
|
||||
"children": ["stack-layout"],
|
||||
"props": {
|
||||
"blockClass": "stack-layout-content",
|
||||
"rowGap": 0
|
||||
}
|
||||
},
|
||||
|
||||
"stack-layout": {
|
||||
"props": {
|
||||
"blockClass": "product"
|
||||
},
|
||||
"children": [
|
||||
"html#flex-layout.row#product-image",
|
||||
"product-bookmark",
|
||||
"product-specification-badges"
|
||||
]
|
||||
},
|
||||
|
||||
"product-specification-badges": {
|
||||
"props": {
|
||||
"specificationGroupName": "Group",
|
||||
"specificationName": "On Sale",
|
||||
"visibleWhen": "True",
|
||||
"displayValue": "SPECIFICATION_NAME"
|
||||
}
|
||||
},
|
||||
|
||||
"html#product-availability": {
|
||||
"props": {
|
||||
"blockClass": "product-availability-block"
|
||||
},
|
||||
"children": ["html#flex-layout.col#stack", "html#right-col-availability"]
|
||||
},
|
||||
|
||||
"html#right-col-availability": {
|
||||
"props": {
|
||||
"preventVerticalStretch": true,
|
||||
"rowGap": 0,
|
||||
"blockClass": "info-availability"
|
||||
},
|
||||
"children": [
|
||||
"html#identification-product-availability",
|
||||
"flex-layout.row#availability",
|
||||
"html#sku-selector"
|
||||
]
|
||||
},
|
||||
|
||||
"html#identification-product-availability": {
|
||||
"props": {
|
||||
"blockClass": "identification-product-availability"
|
||||
},
|
||||
"children": ["html#product-name", "product-identifier.product"]
|
||||
},
|
||||
|
||||
"flex-layout.row#availability": {
|
||||
"props": {
|
||||
"blockClass": "message-availability"
|
||||
},
|
||||
"children": ["availability-subscriber"]
|
||||
},
|
||||
|
||||
"html#right-col": {
|
||||
"props": {
|
||||
"preventVerticalStretch": true,
|
||||
"rowGap": 0
|
||||
},
|
||||
"children": [
|
||||
"html#identification-product",
|
||||
// "product-rating-summary",
|
||||
"flex-layout.row#selling-price",
|
||||
"installment-product-component",
|
||||
"html#pix-component",
|
||||
// "product-separator",
|
||||
"html#sku-selector",
|
||||
// "product-quantity",
|
||||
"html#cart-content",
|
||||
// "product-assembly-options",
|
||||
"product-gifts",
|
||||
// "flex-layout.row#add-to-cart-button",
|
||||
"availability-subscriber",
|
||||
"shipping-simulator",
|
||||
"placeholder-component"
|
||||
// "share#default"
|
||||
]
|
||||
},
|
||||
|
||||
"html#identification-product": {
|
||||
"props": {
|
||||
"blockClass": "identification-product-content"
|
||||
},
|
||||
"children": ["html#product-name", "product-identifier.product"]
|
||||
},
|
||||
|
||||
"html#product-name": {
|
||||
"props": {
|
||||
"marginBottom": 3
|
||||
},
|
||||
"children": ["vtex.store-components:product-name"]
|
||||
},
|
||||
|
||||
"html#pix-component": {
|
||||
"props": {
|
||||
"testId": "pix-price"
|
||||
},
|
||||
"children": ["pix-component"]
|
||||
},
|
||||
|
||||
"html#sku-selector": {
|
||||
"props": {
|
||||
"testId": "sku-selector"
|
||||
},
|
||||
"children": ["sku-selector"]
|
||||
},
|
||||
|
||||
"sku-selector": {
|
||||
"props": {
|
||||
"variationsSpacing": 3,
|
||||
"showValueNameForImageVariation": true,
|
||||
"blockClass": "sku-selector"
|
||||
}
|
||||
},
|
||||
|
||||
"html#cart-content": {
|
||||
"props": {
|
||||
"blockClass": "cart-content"
|
||||
},
|
||||
"children": ["html#product-quantity", "html#add-to-cart-button"]
|
||||
},
|
||||
|
||||
"html#product-quantity": {
|
||||
"props": {
|
||||
"testId": "product-quantity"
|
||||
},
|
||||
"children": ["product-quantity"]
|
||||
},
|
||||
"html#add-to-cart-button": {
|
||||
"props": {
|
||||
"testId": "add-to-cart-button"
|
||||
},
|
||||
"children": ["flex-layout.row#add-to-cart-button"]
|
||||
},
|
||||
|
||||
"flex-layout.row#add-to-cart-button": {
|
||||
"props": {
|
||||
"marginTop": 4,
|
||||
"marginBottom": 7
|
||||
},
|
||||
"children": ["add-to-cart-button"]
|
||||
},
|
||||
|
||||
//Slider
|
||||
|
||||
"html#slider-block-container": {
|
||||
"children": [
|
||||
"rich-text#slider-block-title",
|
||||
"html#list-context.product-list#slider-block"
|
||||
]
|
||||
},
|
||||
|
||||
"rich-text#slider-block-title": {
|
||||
"props": {
|
||||
"text": "### Você também pode gostar:",
|
||||
"blockClass": "slider-title"
|
||||
}
|
||||
},
|
||||
|
||||
"product-summary.shelf#slider-block": {
|
||||
"children": ["html#product-summary.shelf#product-content"]
|
||||
},
|
||||
|
||||
"html#product-summary.shelf#product-content": {
|
||||
"props": {
|
||||
"testId": "vtex-product-summary"
|
||||
},
|
||||
"children": [
|
||||
"product-summary-image#slider-images",
|
||||
"product-summary-name",
|
||||
// "product-summary-space",
|
||||
"product-summary-price"
|
||||
]
|
||||
},
|
||||
|
||||
"product-summary-image#slider-images": {
|
||||
"props": {
|
||||
"blockClass": "product-summary-image",
|
||||
"showBadge": false,
|
||||
"aspectRatio": "1:1"
|
||||
// "maxHeight": 300
|
||||
}
|
||||
},
|
||||
|
||||
"list-context.product-list#slider-block": {
|
||||
"blocks": ["product-summary.shelf#slider-block"],
|
||||
"children": ["html#slider-layout#products-carousel"]
|
||||
},
|
||||
|
||||
"html#list-context.product-list#slider-block": {
|
||||
"props": {
|
||||
"testId": "product-summary-list"
|
||||
},
|
||||
"children": ["list-context.product-list#slider-block"]
|
||||
},
|
||||
|
||||
"html#slider-layout#products-carousel": {
|
||||
"props": {
|
||||
"testId": "product-summary-list"
|
||||
},
|
||||
"children": ["slider-layout#products-carousel"]
|
||||
},
|
||||
|
||||
"slider-layout#products-carousel": {
|
||||
"props": {
|
||||
"itemsPerPage": {
|
||||
"desktop": 4,
|
||||
"tablet": 3,
|
||||
"phone": 2
|
||||
},
|
||||
"infinite": true,
|
||||
"showNavigationArrows": "always",
|
||||
"blockClass": "carousel"
|
||||
}
|
||||
},
|
||||
|
||||
//Product Images
|
||||
|
||||
"html#flex-layout.row#product-image": {
|
||||
"props": {
|
||||
"testId": "product-images"
|
||||
},
|
||||
"children": ["product-images"]
|
||||
},
|
||||
|
||||
"product-images": {
|
||||
"props": {
|
||||
"aspectRatio": {
|
||||
"desktop": "auto",
|
||||
"phone": "16:9"
|
||||
},
|
||||
"displayThumbnailsArrows": false,
|
||||
"showPaginationDots": false,
|
||||
"thumbnailsOrientation": "horizontal"
|
||||
}
|
||||
},
|
||||
|
||||
// Tab-Layout
|
||||
|
||||
"product-images#description-content": {
|
||||
"props": {
|
||||
"displayMode": "first-image",
|
||||
"zoomMode": "disabled",
|
||||
"blockClass": "image-description"
|
||||
}
|
||||
},
|
||||
|
||||
"tab-layout#description": {
|
||||
"children": ["tab-list#description", "tab-content#description"],
|
||||
"props": {
|
||||
"blockClass": "description-block",
|
||||
"defaultActiveTabId": "firstTab"
|
||||
}
|
||||
},
|
||||
|
||||
"tab-list#description": {
|
||||
"children": [
|
||||
"tab-list.item#firstTab",
|
||||
"tab-list.item#secondTab",
|
||||
"tab-list.item#thirdTab",
|
||||
"tab-list.item#fourthTab",
|
||||
"tab-list.item#fifthTab"
|
||||
]
|
||||
},
|
||||
|
||||
"tab-list.item#firstTab": {
|
||||
"props": {
|
||||
"tabId": "firstTab",
|
||||
"label": "Descrição",
|
||||
"defaultActiveTab": true
|
||||
}
|
||||
},
|
||||
|
||||
"tab-list.item#secondTab": {
|
||||
"props": {
|
||||
"tabId": "secondTab",
|
||||
"label": "Descrição"
|
||||
}
|
||||
},
|
||||
|
||||
"tab-list.item#thirdTab": {
|
||||
"props": {
|
||||
"tabId": "thirdTab",
|
||||
"label": "Descrição"
|
||||
}
|
||||
},
|
||||
|
||||
"tab-list.item#fourthTab": {
|
||||
"props": {
|
||||
"tabId": "fourthTab",
|
||||
"label": "Descrição"
|
||||
}
|
||||
},
|
||||
|
||||
"tab-list.item#fifthTab": {
|
||||
"props": {
|
||||
"tabId": "fifthTab",
|
||||
"label": "Descrição"
|
||||
}
|
||||
},
|
||||
|
||||
"tab-content#description": {
|
||||
"children": [
|
||||
"tab-content.item#firstTab",
|
||||
"tab-content.item#secondTab",
|
||||
"tab-content.item#thirdTab",
|
||||
"tab-content.item#fourthTab",
|
||||
"tab-content.item#fifthTab"
|
||||
]
|
||||
},
|
||||
|
||||
"tab-content.item#firstTab": {
|
||||
"children": ["product-images#description-content", "product-description"],
|
||||
"props": {
|
||||
"tabId": "firstTab"
|
||||
}
|
||||
},
|
||||
|
||||
"tab-content.item#secondTab": {
|
||||
"children": ["product-images#description-content", "product-description"],
|
||||
"props": {
|
||||
"tabId": "secondTab"
|
||||
}
|
||||
},
|
||||
|
||||
"tab-content.item#thirdTab": {
|
||||
"children": ["product-images#description-content", "product-description"],
|
||||
"props": {
|
||||
"tabId": "thirdTab"
|
||||
}
|
||||
},
|
||||
|
||||
"tab-content.item#fourthTab": {
|
||||
"children": ["product-images#description-content", "product-description"],
|
||||
"props": {
|
||||
"tabId": "fourthTab"
|
||||
}
|
||||
},
|
||||
|
||||
"tab-content.item#fifthTab": {
|
||||
"children": ["product-images#description-content", "product-description"],
|
||||
"props": {
|
||||
"tabId": "fifthTab"
|
||||
}
|
||||
}
|
||||
|
||||
// "share#default": {
|
||||
// "props": {
|
||||
// "social": {
|
||||
|
Loading…
Reference in New Issue
Block a user