Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

STENCIL-2599: Adds on/off toggle for Shop by Price. #1036

Merged
merged 1 commit into from
Jul 6, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
## Draft
- Product Images were obscuring product details on smaller viewports [#1019](https://github.com/bigcommerce/cornerstone/pull/1019)
- Add region tags to two template files to support payments team banner integration with content service [#1023](https://github.com/bigcommerce/cornerstone/pull/1023)
- Add on/off toggle to the theme editor for the "Shop by Price" panel located on category pages [#1036](https://github.com/bigcommerce/cornerstone/pull/1036)
- Fix H1-H6 font-sizing [#1034](https://github.com/bigcommerce/cornerstone/pull/1034)
- Reduce theme bundle size by using specific minified libraries [#1037](https://github.com/bigcommerce/cornerstone/pull/1037)

Expand Down
1 change: 1 addition & 0 deletions config.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
"productpage_related_products_count": 10,
"productpage_similar_by_views_count": 10,
"categorypage_products_per_page": 12,
"shop_by_price_visible": true,
"brandpage_products_per_page": 12,
"searchpage_products_per_page": 12,
"show_product_quick_view": true,
Expand Down
6 changes: 6 additions & 0 deletions schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1497,6 +1497,12 @@
}
]
},
{
"type": "checkbox",
"label": "Show "Shop by Price"",
"force_reload": true,
"id": "shop_by_price_visible"
},
{
"type": "heading",
"content": "Brand pages"
Expand Down
9 changes: 7 additions & 2 deletions templates/pages/category.html
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,17 @@ <h1 class="page-heading">{{category.name}}</h1>
{{{category.description}}}
{{{snippet 'categories'}}}
<div class="page">
{{#or category.subcategories category.faceted_search_enabled category.shop_by_price}}
{{#or category.subcategories category.faceted_search_enabled}}
<aside class="page-sidebar" id="faceted-search-container">
{{> components/category/sidebar}}
</aside>
{{else}}
{{#if theme_settings.shop_by_price_visible}}
<aside class="page-sidebar" id="faceted-search-container">
{{> components/category/sidebar}}
</aside>
{{/if}}
{{/or}}

<main class="page-content" id="product-listing-container">
{{#if category.products}}
{{> components/category/product-listing}}
Expand Down