Skip to content

Commit 95f7514

Browse files
Add auto-generated file header and new header section (Shopify#3745)
- Added auto-generated file header to multiple JSON and Liquid files to indicate that changes may be overwritten. - Introduced a new 'Header GFA' section in header-gfa.liquid with customizable logo, menu, and sticky header options. - Updated various templates to include empty settings objects for consistency and future customization.
1 parent 3056689 commit 95f7514

15 files changed

+247
-42
lines changed

config/settings_data.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"current": "Default",
312
"presets": {

sections/header-gfa.liquid

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
{%- if section.settings.enable_sticky_header -%}
2+
<div class="header-wrapper sticky">
3+
{%- else -%}
4+
<div class="header-wrapper">
5+
{%- endif -%}
6+
<header class="header header--gfa page-width">
7+
<div class="header__logo-wrapper">
8+
{%- if section.settings.logo != blank -%}
9+
<a href="{{ routes.root_url }}" class="header__logo-link">
10+
{{ section.settings.logo | image_url: width: section.settings.logo_width | image_tag: class: 'header__logo', widths: '50, 100, 150, 200, 250, 300, 400, 500' }}
11+
</a>
12+
{%- else -%}
13+
<a href="{{ routes.root_url }}" class="h4">{{ shop.name }}</a>
14+
{%- endif -%}
15+
</div>
16+
17+
<nav class="header__nav">
18+
{%- if section.settings.menu != blank -%}
19+
<ul class="header__menu list-unstyled">
20+
{%- for link in section.settings.menu.links -%}
21+
<li>
22+
<a href="{{ link.url }}" class="header__menu-item{% if link.current %} header__menu-item--active{% endif %}">
23+
{{ link.title }}
24+
</a>
25+
</li>
26+
{%- endfor -%}
27+
</ul>
28+
{%- endif -%}
29+
</nav>
30+
</header>
31+
</div>
32+
33+
{% schema %}
34+
{
35+
"name": "Header GFA",
36+
"settings": [
37+
{
38+
"type": "image_picker",
39+
"id": "logo",
40+
"label": "Logo"
41+
},
42+
{
43+
"type": "range",
44+
"id": "logo_width",
45+
"min": 50,
46+
"max": 300,
47+
"step": 10,
48+
"default": 100,
49+
"unit": "px",
50+
"label": "Logo width"
51+
},
52+
{
53+
"type": "link_list",
54+
"id": "menu",
55+
"label": "GFA Menu",
56+
"default": "main-menu"
57+
},
58+
{
59+
"type": "checkbox",
60+
"id": "enable_sticky_header",
61+
"default": true,
62+
"label": "Enable sticky header"
63+
}
64+
]
65+
}
66+
{% endschema %}

sections/header-group.json

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"name": "t:sections.header.name",
312
"type": "header",
@@ -9,28 +18,27 @@
918
"type": "announcement",
1019
"settings": {
1120
"text": "Welcome to our store",
12-
"text_alignment": "center",
13-
"color_scheme": "scheme-1",
1421
"link": ""
1522
}
1623
}
1724
},
1825
"block_order": [
1926
"announcement-bar-0"
20-
]
27+
],
28+
"settings": {}
2129
},
2230
"header": {
2331
"type": "header",
2432
"settings": {
25-
"color_scheme": "scheme-1",
2633
"logo_position": "middle-left",
34+
"mobile_logo_position": "center",
2735
"menu": "main-menu",
2836
"menu_type_desktop": "dropdown",
2937
"sticky_header_type": "on-scroll-up",
3038
"show_line_separator": true,
39+
"color_scheme": "scheme-1",
3140
"enable_country_selector": true,
3241
"enable_language_selector": true,
33-
"mobile_logo_position": "center",
3442
"margin_bottom": 0,
3543
"padding_top": 20,
3644
"padding_bottom": 20

templates/404.json

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"sections": {
312
"main": {
4-
"type": "main-404"
13+
"type": "main-404",
14+
"settings": {}
515
}
616
},
717
"order": [

templates/article.json

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"sections": {
312
"main": {
@@ -23,15 +32,17 @@
2332
}
2433
},
2534
"content": {
26-
"type": "content"
35+
"type": "content",
36+
"settings": {}
2737
}
2838
},
2939
"block_order": [
3040
"featured_image",
3141
"title",
3242
"share",
3343
"content"
34-
]
44+
],
45+
"settings": {}
3546
}
3647
},
3748
"order": [

templates/cart.json

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"sections": {
312
"cart-items": {
@@ -12,36 +21,35 @@
1221
"blocks": {
1322
"subtotal": {
1423
"type": "subtotal",
15-
"settings": {
16-
}
24+
"settings": {}
1725
},
1826
"buttons": {
1927
"type": "buttons",
20-
"settings": {
21-
}
28+
"settings": {}
2229
}
2330
},
2431
"block_order": [
2532
"subtotal",
2633
"buttons"
27-
]
34+
],
35+
"settings": {}
2836
},
2937
"featured-collection": {
3038
"type": "featured-collection",
3139
"settings": {
32-
"title": "Featured collection",
33-
"heading_size": "h2",
3440
"collection": "all",
3541
"products_to_show": 4,
42+
"title": "Featured collection",
43+
"heading_size": "h2",
3644
"columns_desktop": 4,
37-
"color_scheme": "scheme-1",
3845
"show_view_all": true,
39-
"swipe_on_mobile": false,
46+
"color_scheme": "scheme-1",
4047
"image_ratio": "square",
4148
"show_secondary_image": false,
4249
"show_vendor": false,
4350
"show_rating": false,
4451
"columns_mobile": "2",
52+
"swipe_on_mobile": false,
4553
"padding_top": 36,
4654
"padding_bottom": 36
4755
}

templates/customers/account.json

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"sections": {
312
"main": {
4-
"type": "main-account"
13+
"type": "main-account",
14+
"settings": {}
515
}
616
},
717
"order": [

templates/customers/activate_account.json

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"sections": {
312
"main": {
4-
"type": "main-activate-account"
13+
"type": "main-activate-account",
14+
"settings": {}
515
}
616
},
717
"order": [

templates/customers/addresses.json

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"sections": {
312
"main": {
4-
"type": "main-addresses"
13+
"type": "main-addresses",
14+
"settings": {}
515
}
616
},
717
"order": [

templates/customers/login.json

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"sections": {
312
"main": {
4-
"type": "main-login"
13+
"type": "main-login",
14+
"settings": {}
515
}
616
},
717
"order": [

templates/customers/order.json

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"sections": {
312
"main": {
4-
"type": "main-order"
13+
"type": "main-order",
14+
"settings": {}
515
}
616
},
717
"order": [

templates/customers/register.json

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"sections": {
312
"main": {
4-
"type": "main-register"
13+
"type": "main-register",
14+
"settings": {}
515
}
616
},
717
"order": [

templates/customers/reset_password.json

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
1+
/*
2+
* ------------------------------------------------------------
3+
* IMPORTANT: The contents of this file are auto-generated.
4+
*
5+
* This file may be updated by the Shopify admin theme editor
6+
* or related systems. Please exercise caution as any changes
7+
* made to this file may be overwritten.
8+
* ------------------------------------------------------------
9+
*/
110
{
211
"sections": {
312
"main": {
4-
"type": "main-reset-password"
13+
"type": "main-reset-password",
14+
"settings": {}
515
}
616
},
717
"order": [

0 commit comments

Comments
 (0)