diff --git a/CHANGELOG.md b/CHANGELOG.md index 044f54a81f..ae64f66f6f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Incorrect translation displaying in Home Page Carousel for da, sv and no. [#2224]https://github.com/bigcommerce/cornerstone/pull/2224 - Blog Pages Do Not Include Link Rel Next/Prev Tags. [#2214](https://github.com/bigcommerce/cornerstone/issues/2214). - Add lang attribute to html tag to improve checkout accesibility [#2210]https://github.com/bigcommerce/cornerstone/pull/2210 +- Moved custom_fields loop to a dedicated component [#2222](https://github.com/bigcommerce/cornerstone/pull/2222) - "None" modifier option is displayed as selected even if there is default modifier option [#2227]https://github.com/bigcommerce/cornerstone/pull/2227 - Add pickups to storefront invoice [#2216](https://github.com/bigcommerce/cornerstone/pull/2216) diff --git a/templates/components/amp/products/product-view-details.html b/templates/components/amp/products/product-view-details.html index 8675379ede..7fe15d454f 100644 --- a/templates/components/amp/products/product-view-details.html +++ b/templates/components/amp/products/product-view-details.html @@ -104,10 +104,7 @@ {{/if}} - {{#each product.custom_fields}} -
{{name}}:
-
{{{value}}}
- {{/each}} + {{> components/products/custom-fields }} diff --git a/templates/components/products/custom-fields.html b/templates/components/products/custom-fields.html new file mode 100644 index 0000000000..881b059270 --- /dev/null +++ b/templates/components/products/custom-fields.html @@ -0,0 +1,4 @@ +{{#each product.custom_fields}} +
{{name}}:
+
{{{value}}}
+{{/each}} diff --git a/templates/components/products/description-tabs.html b/templates/components/products/description-tabs.html index 82ffb9c2dc..56314bd1ea 100644 --- a/templates/components/products/description-tabs.html +++ b/templates/components/products/description-tabs.html @@ -38,10 +38,7 @@ {{#all product.custom_fields theme_settings.show_custom_fields_tabs}}
- {{#each product.custom_fields}} -
{{name}}:
-
{{{value}}}
- {{/each}} + {{> components/products/custom-fields }}
{{/all}} diff --git a/templates/components/products/product-view.html b/templates/components/products/product-view.html index 851e3f317f..a7da236736 100644 --- a/templates/components/products/product-view.html +++ b/templates/components/products/product-view.html @@ -218,10 +218,7 @@

{{/if}} {{#if theme_settings.show_custom_fields_tabs '!==' true}} - {{#each product.custom_fields}} -
{{name}}:
-
{{{ sanitize value}}}
- {{/each}} + {{> components/products/custom-fields }} {{/if}}