11---
22_metadata :
3- hint : Real Shopify Dream theme benchmark — requires shopify_filters feature
4- doc : implementers/shopify-theme-filters.md
5- features :
6- - shopify_filters
3+ hint : |
4+ Shopify-shaped Dream product benchmark expressed with portable Liquid.
5+ CDN paths, cents conversion, and tag slugs use standard filters only.
76 data_files :
87 - _data/theme_database.yml
98specs :
@@ -26,12 +25,12 @@ specs:
2625 <div class="product__media">
2726 <div class="product__gallery">
2827 <div class="product__main-image">
29- <img src="{{ product.featured_image | product_img_url : 'large ' }}" alt="{{ product.title | escape }}">
28+ <img src="{{ product.featured_image | prepend : '/cdn/ ' }}" alt="{{ product.title | escape }}">
3029 </div>
3130 <div class="product__thumbnails">
3231 {% for image in product.images %}
3332 <button class="product__thumbnail-item" data-image-index="{{ forloop.index }}">
34- <img src="{{ image | product_img_url : 'small ' }}" alt="{{ product.title | escape }} - {{ forloop.index }}">
33+ <img src="{{ image | prepend : '/cdn/ ' }}" alt="{{ product.title | escape }} - {{ forloop.index }}">
3534 </button>
3635 {% endfor %}
3736 </div>
@@ -43,11 +42,11 @@ specs:
4342
4443 <div class="product__pricing">
4544 {% if product.compare_at_price > product.price %}
46- <span class="product__price product__price--sale">{{ product.price | money }}</span>
47- <span class="product__price product__price--compare">{{ product.compare_at_price | money }}</span>
45+ <span class="product__price product__price--sale">$ {{ product.price | divided_by: 100.0 }}</span>
46+ <span class="product__price product__price--compare">$ {{ product.compare_at_price | divided_by: 100.0 }}</span>
4847 <span class="product__badge">Sale</span>
4948 {% else %}
50- <span class="product__price">{{ product.price | money }}</span>
49+ <span class="product__price">$ {{ product.price | divided_by: 100.0 }}</span>
5150 {% endif %}
5251 </div>
5352
6362 <select name="id" id="ProductSelect" class="product-form__select">
6463 {% for variant in product.variants %}
6564 <option value="{{ variant.id }}" {% if variant.available == false %}disabled{% endif %}>
66- {{ variant.title }} - {{ variant.price | money }}{% if variant.available == false %} - Sold out{% endif %}
65+ {{ variant.title }} - $ {{ variant.price | divided_by: 100.0 }}{% if variant.available == false %} - Sold out{% endif %}
6766 </option>
6867 {% endfor %}
6968 </select>
@@ -100,7 +99,7 @@ specs:
10099 <ul class="tag-list">
101100 {% for tag in product.tags %}
102101 <li class="tag-list__item">
103- <a href="/collections/all/{{ tag | handle }}" class="tag">{{ tag }}</a>
102+ <a href="/collections/all/{{ tag | downcase | replace: ' ', '-' | url_encode }}" class="tag">{{ tag }}</a>
104103 </li>
105104 {% endfor %}
106105 </ul>
@@ -177,16 +176,16 @@ specs:
177176 <div class="product-card">
178177 <a href="{{ product.url }}" class="product-card__link">
179178 <div class="product-card__image">
180- <img src="{{ product.featured_image | product_img_url : 'medium ' }}" alt="{{ product.title | escape }}">
179+ <img src="{{ product.featured_image | prepend : '/cdn/ ' }}" alt="{{ product.title | escape }}">
181180 </div>
182181 <div class="product-card__info">
183182 <h3 class="product-card__title">{{ product.title }}</h3>
184183 <div class="product-card__price">
185184 {% if product.compare_at_price > product.price %}
186- <span class="product-card__price--sale">{{ product.price | money }}</span>
187- <span class="product-card__price--compare">{{ product.compare_at_price | money }}</span>
185+ <span class="product-card__price--sale">$ {{ product.price | divided_by: 100.0 }}</span>
186+ <span class="product-card__price--compare">$ {{ product.compare_at_price | divided_by: 100.0 }}</span>
188187 {% else %}
189- <span class="product-card__price--regular">{{ product.price | money }}</span>
188+ <span class="product-card__price--regular">$ {{ product.price | divided_by: 100.0 }}</span>
190189 {% endif %}
191190 </div>
192191 </div>
0 commit comments