feat: made-testid

This commit is contained in:
Gabriel Ferreira Lehmann 2023-02-10 23:33:16 -03:00
parent a3944ae6d4
commit 89025c1a1e
2 changed files with 98 additions and 11 deletions

View File

@ -4,7 +4,7 @@
"html#breadcrumb",
"condition-layout.product#availability",
// "flex-layout.row#description",
"tab-layout#description",
"html#product-description",
// "flex-layout.row#specifications-title",
// "product-specification-group#table",
// "shelf.relatedProducts",
@ -37,7 +37,17 @@
"blocks": ["product-summary.shelf#carousel-shelf"]
},
"product-summary.shelf#carousel-shelf": {
"html#slider": {
"props": {
"testId": "product-summary-list"
},
"children": ["slider-layout#carousel-slider"]
},
"html#prateleira": {
"props": {
"testId": "vtex-product-summary"
},
"children": [
"product-summary-image",
"product-summary-name",
@ -45,6 +55,10 @@
]
},
"product-summary.shelf#carousel-shelf": {
"children": ["html#prateleira"]
},
"tab-layout#description": {
"children": ["tab-list#description", "tab-content#description"]
},
@ -166,6 +180,14 @@
},
"children": ["product-images#description", "flex-layout.col#description"]
},
"html#product-description": {
"props": {
"testId": "product-description"
},
"children": ["tab-layout#description"]
},
"product-description#notitle": {
"props": {
"showTitle": false
@ -237,9 +259,17 @@
"rowGap": 0
}
},
"flex-layout.row#product-image": {
"html#imagens": {
"props": {
"testId": "product-images"
},
"children": ["product-images"]
},
"flex-layout.row#product-image": {
"children": ["html#imagens"]
},
"product-images": {
"props": {
"aspectRatio": {
@ -262,12 +292,12 @@
},
"children": [
"flex-layout.row#product-name",
"product-identifier.product",
"html#codigo",
"product-rating-summary",
// "flex-layout.row#list-price-savings",
"flex-layout.row#selling-price",
"product-installments",
"pix-components",
"html#product-installments",
"html#pixzap",
// "product-separator",
"sku-selector",
"flex-layout.row#quantity-and-add-button",
@ -276,10 +306,39 @@
// "product-gifts",
// "flex-layout.row#buy-button",
"availability-subscriber",
"shipping-simulator"
"html#shipping-simulator"
// "share#default"
]
},
"html#pixzap": {
"props": {
"testId": "pix-price",
"blockClass": "pix"
},
"children": ["pix-components"]
},
"html#product-name": {
"props": {
"testId": "product-name"
},
"children": ["vtex.store-components:product-name"]
},
"html#shipping-simulator": {
"props": {
"testId": "shipping-simulator"
},
"children": ["shipping-simulator"]
},
"html#codigo": {
"props": {
"blockClass": "codigo",
"testId": "product-code"
},
"children": ["product-identifier.product"]
},
"flex-layout.row#quantity-and-add-button": {
"props": {
@ -288,7 +347,14 @@
"fullWidth": true,
"colGap": 0
},
"children": ["product-quantity", "flex-layout.row#buy-button"]
"children": ["html#product-quantity", "flex-layout.row#buy-button"]
},
"html#product-quantity": {
"props": {
"testId": "product-quantity"
},
"children": ["product-quantity"]
},
"product-identifier.product": {
@ -297,6 +363,13 @@
}
},
"html#product-installments": {
"props": {
"testId": "product-installments"
},
"children": ["product-installments"]
},
"product-installments": {
"props": {
"message": "{installmentsNumber} {hasInterest, select, true {x} false {}} de {installmentValue} sem juros",
@ -308,7 +381,7 @@
"props": {
"marginBottom": 3
},
"children": ["vtex.store-components:product-name"]
"children": ["html#product-name"]
},
"sku-selector": {
@ -330,6 +403,13 @@
"marginBottom": 7,
"blockClass": "add-to-cart-button-background"
},
"children": ["html#add-to-card-button"]
},
"html#add-to-card-button": {
"props": {
"testId": "add-to-cart-button"
},
"children": ["add-to-cart-button"]
},
@ -353,7 +433,7 @@
},
"children": [
"flex-layout.row#product-name",
"product-identifier.product",
"html#codigo",
"sku-selector",
"flex-layout.row#availability"
]

View File

@ -5,7 +5,7 @@
"preserveLayoutOnMobile": true,
"preventHorizontalStretch": true
},
"children": ["product-selling-price"]
"children": ["html#selling-price"]
},
"flex-layout.row#list-price-savings": {
@ -17,5 +17,12 @@
"marginTop": 5
},
"children": ["product-list-price", "product-price-savings"]
},
"html#selling-price": {
"props": {
"testId": "product-price"
},
"children": ["product-selling-price"]
}
}