STENCIL-3527: Adding toggle for weight and dimensions on product pages.#1092
Conversation
9ba7e01 to
59e0146
Compare
| "show_accept_visa": false, | ||
| "show_product_details_tabs": true, | ||
| "show_product_weight": true, | ||
| "show_product_dimensions": true, |
There was a problem hiding this comment.
Not needed. This only needs to be added once to the global settings on line 72 and 73
I noticed that there are several cases like this :(. It only needs to be added to the variations if the values are different.
There was a problem hiding this comment.
Removed and GTK!
| "show_accept_visa": false, | ||
| "show_product_details_tabs": true, | ||
| "show_product_weight": true, | ||
| "show_product_dimensions": true, |
| "depth": "Depth:", | ||
| "measurement": { | ||
| "metric": "cm", | ||
| "imperial": "in" |
There was a problem hiding this comment.
Indented now.
| <dd class="productView-info-value">{{product.availability}}</dd> | ||
| {{/if}} | ||
| {{#if product.weight}} | ||
| {{#if theme_settings.show_product_weight}} |
There was a problem hiding this comment.
you still need to check for product.weight. You can use all helper
{{#all product.weight theme_settings.show_product_weight}}
There was a problem hiding this comment.
Added this to weight as well as dimensions since dimensions are optional. Thanks for catching these!
59e0146 to
09ae9f5
Compare
| <dd class="productView-info-value" data-product-weight>{{product.weight}}</dd> | ||
| {{/if}} | ||
| {{/all}} | ||
| {{#all product.width product.height. product.depth theme_settings.show_product_dimensions}} |
There was a problem hiding this comment.
there is an extra dot in product.height. 😛
| "show_accept_visa": false, | ||
| "show_product_details_tabs": true, | ||
| "show_product_weight": true, | ||
| "show_product_dimensions": true, |
There was a problem hiding this comment.
If we never displayed this info before we should default it to false. We don't want people calling support that new data started showing up on their product details page.
There was a problem hiding this comment.
Good point. I had thought about that but forgot to implement. Good news is I am better at squashing ;)
|
What is the performance impact here? We have heard from merchants it is very slow using theme editor with a bunch of theme options to change. This seems it would slow down theme editor even more. Do we know either way? |
09ae9f5 to
4a9c905
Compare
|
This is just adding two more fields, so the impact should be marginal. |
4a9c905 to
a2e9b12
Compare
What?
Adds toggle settings to the theme editor for displaying (or not displaying) weight and dimensions on product pages.
Tickets / Documentation
This is a feature request from customers as documented here:
Screenshots (if appropriate)
Video of working changes: https://www.screencast.com/t/juQ8DUTeG3F8