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

Standardize heading font size options, add larger size #3498

Merged
merged 20 commits into from
Jun 7, 2024
Merged
Show file tree
Hide file tree
Changes from 16 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
6 changes: 6 additions & 0 deletions assets/base.css
Original file line number Diff line number Diff line change
Expand Up @@ -264,8 +264,14 @@ h5,
word-break: break-word;
}

.hxxl {
font-size: clamp(calc(var(--font-heading-scale) * 5.6rem), 14vw, calc(var(--font-heading-scale) * 7.2rem));
line-height: 1.1;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah I think the difference too with the hxl is that the division was happening on 1.1 while on there it happens on the 0.3 value because it's defined like this: 1 + 0.3 / ....

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, that's why we formatted the calc() that way. 😂

}

.hxl {
font-size: calc(var(--font-heading-scale) * 5rem);
line-height: calc(1 + 0.3 / max(1, var(--font-heading-scale)));
}

@media only screen and (min-width: 750px) {
Expand Down
12 changes: 0 additions & 12 deletions locales/cs.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3289,18 +3289,6 @@
"label": "Šířka obrázku v počítači",
"info": "Obrázek se automaticky optimalizuje pro mobilní prostředí."
},
"heading_size": {
"options__1": {
"label": "Malý"
},
"options__2": {
"label": "Střední"
},
"options__3": {
"label": "Velký"
},
"label": "Velikost nadpisu"
},
"text_style": {
"options__1": {
"label": "Hlavní část"
Expand Down
12 changes: 0 additions & 12 deletions locales/da.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3289,18 +3289,6 @@
"label": "Billedbredde på computer",
"info": "Billedet er automatisk optimeret til mobiltelefoner."
},
"heading_size": {
"options__1": {
"label": "Lille"
},
"options__2": {
"label": "Mellem"
},
"options__3": {
"label": "Stor"
},
"label": "Størrelse for overskrift"
},
"text_style": {
"options__1": {
"label": "Brødtekst"
Expand Down
12 changes: 0 additions & 12 deletions locales/de.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3289,18 +3289,6 @@
"label": "Desktop-Bildbreite",
"info": "Bild wird automatisch für die mobile Nutzung optimiert."
},
"heading_size": {
"options__1": {
"label": "Klein"
},
"options__2": {
"label": "Mittel"
},
"options__3": {
"label": "Groß"
},
"label": "Größe der Überschrift"
},
"text_style": {
"options__1": {
"label": "Nachricht"
Expand Down
15 changes: 3 additions & 12 deletions locales/en.default.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -413,6 +413,9 @@
},
"options__4": {
"label": "Extra large"
},
"options__5": {
"label": "Extra extra large"
}
},
"image_shape": {
Expand Down Expand Up @@ -1544,18 +1547,6 @@
"label": "Desktop image width",
"info": "Image is automatically optimized for mobile."
},
"heading_size": {
"options__1": {
"label": "Small"
},
"options__2": {
"label": "Medium"
},
"options__3": {
"label": "Large"
},
"label": "Heading size"
},
"text_style": {
"options__1": {
"label": "Body"
Expand Down
12 changes: 0 additions & 12 deletions locales/fi.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3289,18 +3289,6 @@
"label": "Työpöytäkuvan leveys",
"info": "Kuva optimoidaan automaattisesti mobiililaitteille."
},
"heading_size": {
"options__1": {
"label": "Pieni"
},
"options__2": {
"label": "Keskisuuri"
},
"options__3": {
"label": "Suuri"
},
"label": "Otsikon koko"
},
"text_style": {
"options__1": {
"label": "Leipäteksti"
Expand Down
12 changes: 0 additions & 12 deletions locales/it.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3289,18 +3289,6 @@
"label": "Larghezza immagine su desktop",
"info": "L'immagine viene automaticamente ottimizzata per il mobile."
},
"heading_size": {
"options__1": {
"label": "Piccola"
},
"options__2": {
"label": "Media"
},
"options__3": {
"label": "Grande"
},
"label": "Dimensione titolo"
},
"text_style": {
"options__1": {
"label": "Corpo"
Expand Down
12 changes: 0 additions & 12 deletions locales/ja.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3289,18 +3289,6 @@
"label": "デスクトップ画像の幅",
"info": "画像はモバイル用に自動で最適化されます。"
},
"heading_size": {
"options__1": {
"label": "小"
},
"options__2": {
"label": "中"
},
"options__3": {
"label": "大"
},
"label": "見出しのサイズ"
},
"text_style": {
"options__1": {
"label": "本文"
Expand Down
12 changes: 0 additions & 12 deletions locales/ko.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3289,18 +3289,6 @@
"label": "데스크톱 이미지 너비",
"info": "이미지는 자동으로 모바일에 최적화됩니다."
},
"heading_size": {
"options__1": {
"label": "작게"
},
"options__2": {
"label": "보통"
},
"options__3": {
"label": "크게"
},
"label": "제목 크기"
},
"text_style": {
"options__1": {
"label": "본문"
Expand Down
12 changes: 0 additions & 12 deletions locales/pt-PT.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3289,18 +3289,6 @@
"label": "Largura da imagem em computador",
"info": "A imagem é otimizada automaticamente em dispositivos móveis."
},
"heading_size": {
"options__1": {
"label": "Pequeno"
},
"options__2": {
"label": "Médio"
},
"options__3": {
"label": "Grande"
},
"label": "Tamanho do título"
},
"text_style": {
"options__1": {
"label": "Corpo"
Expand Down
12 changes: 0 additions & 12 deletions locales/vi.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3289,18 +3289,6 @@
"label": "Chiều rộng hình ảnh trên màn hình nền",
"info": "Hình ảnh được tự động tối ưu hóa cho thiết bị di động."
},
"heading_size": {
"options__1": {
"label": "Nhỏ"
},
"options__2": {
"label": "Trung bình"
},
"options__3": {
"label": "Lớn"
},
"label": "Cỡ tiêu đề"
},
"text_style": {
"options__1": {
"label": "Nội dung"
Expand Down
12 changes: 0 additions & 12 deletions locales/zh-CN.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3289,18 +3289,6 @@
"label": "台式设备图片宽度",
"info": "图片会针对移动设备进行自动优化。"
},
"heading_size": {
"options__1": {
"label": "小"
},
"options__2": {
"label": "中"
},
"options__3": {
"label": "大"
},
"label": "标题大小"
},
"text_style": {
"options__1": {
"label": "正文"
Expand Down
8 changes: 8 additions & 0 deletions sections/collage.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@
</div>
</div>

{% schema %}

Check notice on line 211 in sections/collage.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/collage.liquid#L211

[SchemaJsonFormat] JSON formatting could be improved
{
"name": "t:sections.collage.name",
"tag": "section",
Expand Down Expand Up @@ -238,6 +238,14 @@
{
"value": "h0",
"label": "t:sections.all.heading_size.options__3.label"
},
{
"value": "hxl",
"label": "t:sections.all.heading_size.options__4.label"
},
{
"value": "hxxl",
"label": "t:sections.all.heading_size.options__5.label"
}
],
"default": "h1",
Expand Down
8 changes: 8 additions & 0 deletions sections/collapsible-content.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@
</div>
</div>

{% schema %}

Check notice on line 109 in sections/collapsible-content.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/collapsible-content.liquid#L109

[SchemaJsonFormat] JSON formatting could be improved
{
"name": "t:sections.collapsible_content.name",
"tag": "section",
Expand Down Expand Up @@ -141,6 +141,14 @@
{
"value": "h0",
"label": "t:sections.all.heading_size.options__3.label"
},
{
"value": "hxl",
"label": "t:sections.all.heading_size.options__4.label"
},
{
"value": "hxxl",
"label": "t:sections.all.heading_size.options__5.label"
}
],
"default": "h1",
Expand Down
8 changes: 8 additions & 0 deletions sections/collection-list.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@
</div>
</div>

{% schema %}

Check notice on line 132 in sections/collection-list.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/collection-list.liquid#L132

[SchemaJsonFormat] JSON formatting could be improved
{
"name": "t:sections.collection-list.name",
"tag": "section",
Expand Down Expand Up @@ -160,6 +160,14 @@
{
"value": "h0",
"label": "t:sections.all.heading_size.options__3.label"
},
{
"value": "hxl",
"label": "t:sections.all.heading_size.options__4.label"
},
{
"value": "hxxl",
"label": "t:sections.all.heading_size.options__5.label"
}
],
"default": "h1",
Expand Down
8 changes: 8 additions & 0 deletions sections/contact-form.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@
</div>
</div>

{% schema %}

Check notice on line 136 in sections/contact-form.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/contact-form.liquid#L136

[SchemaJsonFormat] JSON formatting could be improved
{
"name": "t:sections.contact-form.name",
"tag": "section",
Expand Down Expand Up @@ -163,6 +163,14 @@
{
"value": "h0",
"label": "t:sections.all.heading_size.options__3.label"
},
{
"value": "hxl",
"label": "t:sections.all.heading_size.options__4.label"
},
{
"value": "hxxl",
"label": "t:sections.all.heading_size.options__5.label"
}
],
"default": "h1",
Expand Down
8 changes: 8 additions & 0 deletions sections/email-signup-banner.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@
</div>
</div>

{% schema %}

Check notice on line 139 in sections/email-signup-banner.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/email-signup-banner.liquid#L139

[SchemaJsonFormat] JSON formatting could be improved
{
"name": "t:sections.email-signup-banner.name",
"tag": "section",
Expand Down Expand Up @@ -327,6 +327,14 @@
{
"value": "h0",
"label": "t:sections.all.heading_size.options__3.label"
},
{
"value": "hxl",
"label": "t:sections.all.heading_size.options__4.label"
},
{
"value": "hxxl",
"label": "t:sections.all.heading_size.options__5.label"
}
],
"default": "h1",
Expand Down
8 changes: 8 additions & 0 deletions sections/featured-blog.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@
</div>
</div>

{% schema %}

Check notice on line 189 in sections/featured-blog.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/featured-blog.liquid#L189

[SchemaJsonFormat] JSON formatting could be improved
{
"name": "t:sections.featured-blog.name",
"tag": "section",
Expand Down Expand Up @@ -215,6 +215,14 @@
{
"value": "h0",
"label": "t:sections.all.heading_size.options__3.label"
},
{
"value": "hxl",
"label": "t:sections.all.heading_size.options__4.label"
},
{
"value": "hxxl",
"label": "t:sections.all.heading_size.options__5.label"
}
],
"default": "h1",
Expand Down
8 changes: 8 additions & 0 deletions sections/featured-collection.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@
</div>
</div>

{% schema %}

Check notice on line 193 in sections/featured-collection.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/featured-collection.liquid#L193

[SchemaJsonFormat] JSON formatting could be improved
{
"name": "t:sections.featured-collection.name",
"tag": "section",
Expand Down Expand Up @@ -220,6 +220,14 @@
{
"value": "h0",
"label": "t:sections.all.heading_size.options__3.label"
},
{
"value": "hxl",
"label": "t:sections.all.heading_size.options__4.label"
},
{
"value": "hxxl",
"label": "t:sections.all.heading_size.options__5.label"
}
],
"default": "h1",
Expand Down
8 changes: 8 additions & 0 deletions sections/featured-product.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -365,11 +365,11 @@
render 'share-button', block: block, share_link: share_url
%}
{%- when 'variant_picker' -%}
{% render 'product-variant-picker',
product: product,
block: block,
product_form_id: product_form_id
%}

Check warning on line 372 in sections/featured-product.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/featured-product.liquid#L368-L372

[NestedSnippet] Too many nested snippets

Check warning on line 372 in sections/featured-product.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/featured-product.liquid#L368-L372

[NestedSnippet] Too many nested snippets

Check warning on line 372 in sections/featured-product.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/featured-product.liquid#L368-L372

[NestedSnippet] Too many nested snippets
{%- when 'buy_buttons' -%}
{%- render 'buy-buttons',
block: block,
Expand Down Expand Up @@ -513,7 +513,7 @@
{% endif %}
</product-info>

{% schema %}

Check notice on line 516 in sections/featured-product.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/featured-product.liquid#L516

[SchemaJsonFormat] JSON formatting could be improved
{
"name": "t:sections.featured-product.name",
"tag": "section",
Expand Down Expand Up @@ -577,6 +577,14 @@
{
"value": "h0",
"label": "t:sections.all.heading_size.options__3.label"
},
{
"value": "hxl",
"label": "t:sections.all.heading_size.options__4.label"
},
{
"value": "hxxl",
"label": "t:sections.all.heading_size.options__5.label"
}
],
"default": "h1",
Expand Down
8 changes: 8 additions & 0 deletions sections/image-banner.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@
</div>
</div>

{% schema %}

Check notice on line 169 in sections/image-banner.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/image-banner.liquid#L169

[SchemaJsonFormat] JSON formatting could be improved
{
"name": "t:sections.image-banner.name",
"tag": "section",
Expand Down Expand Up @@ -388,6 +388,14 @@
{
"value": "h0",
"label": "t:sections.all.heading_size.options__3.label"
},
{
"value": "hxl",
"label": "t:sections.all.heading_size.options__4.label"
},
{
"value": "hxxl",
"label": "t:sections.all.heading_size.options__5.label"
}
],
"default": "h1",
Expand Down
8 changes: 8 additions & 0 deletions sections/image-with-text.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@
</div>
</div>

{% schema %}

Check notice on line 110 in sections/image-with-text.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/image-with-text.liquid#L110

[SchemaJsonFormat] JSON formatting could be improved
{
"name": "t:sections.image-with-text.name",
"class": "section",
Expand Down Expand Up @@ -350,6 +350,14 @@
{
"value": "h0",
"label": "t:sections.all.heading_size.options__3.label"
},
{
"value": "hxl",
"label": "t:sections.all.heading_size.options__4.label"
},
{
"value": "hxxl",
"label": "t:sections.all.heading_size.options__5.label"
}
],
"default": "h1",
Expand Down
8 changes: 8 additions & 0 deletions sections/multicolumn.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@
</div>
</div>

{% schema %}

Check notice on line 191 in sections/multicolumn.liquid

View workflow job for this annotation

GitHub Actions / Theme Check Report

sections/multicolumn.liquid#L191

[SchemaJsonFormat] JSON formatting could be improved
{
"name": "t:sections.multicolumn.name",
"class": "section",
Expand Down Expand Up @@ -218,6 +218,14 @@
{
"value": "h0",
"label": "t:sections.all.heading_size.options__3.label"
},
{
"value": "hxl",
"label": "t:sections.all.heading_size.options__4.label"
},
{
"value": "hxxl",
"label": "t:sections.all.heading_size.options__5.label"
}
],
"default": "h1",
Expand Down
Loading
Loading