Skip to content

Commit a87c5d8

Browse files
committed
fix: remove blank default values from press section schemas
Shopify rejects sections with empty string defaults on textarea/text settings. Remove default="" from intro_text (hero) and source (quotes) so the sections save without schema errors. https://claude.ai/code/session_01YYptL6XzKziDt7xGKhz4Tn
1 parent 5d31acb commit a87c5d8

2 files changed

Lines changed: 345 additions & 4 deletions

File tree

sections/gk-press-hero.liquid

Lines changed: 345 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,345 @@
1+
{%- style -%}
2+
.gk-press-hero {
3+
background-color: #0D0D0D;
4+
padding: {{ section.settings.padding_top }}px 0 {{ section.settings.padding_bottom }}px;
5+
position: relative;
6+
overflow: hidden;
7+
}
8+
9+
.gk-press-hero::before {
10+
content: '';
11+
position: absolute;
12+
top: -10%;
13+
left: 50%;
14+
transform: translateX(-50%);
15+
width: 900px;
16+
height: 560px;
17+
background: radial-gradient(ellipse at center, rgba(232, 105, 10, 0.07) 0%, transparent 68%);
18+
pointer-events: none;
19+
z-index: 0;
20+
}
21+
22+
.gk-press-hero::after {
23+
content: '';
24+
position: absolute;
25+
bottom: 0;
26+
left: 0;
27+
right: 0;
28+
height: 1px;
29+
background: linear-gradient(to right, transparent, rgba(232, 105, 10, 0.25), transparent);
30+
z-index: 1;
31+
}
32+
33+
.gk-press-hero__inner {
34+
max-width: var(--page-width);
35+
margin: 0 auto;
36+
padding: 0 24px;
37+
position: relative;
38+
z-index: 2;
39+
}
40+
41+
.gk-press-hero__content {
42+
text-align: center;
43+
max-width: 800px;
44+
margin: 0 auto;
45+
}
46+
47+
.gk-press-hero__eyebrow {
48+
font-family: 'DM Mono', monospace;
49+
text-transform: uppercase;
50+
letter-spacing: 4px;
51+
font-size: 0.72rem;
52+
color: #E8690A;
53+
margin-bottom: 20px;
54+
display: block;
55+
}
56+
57+
.gk-press-hero__heading {
58+
font-family: 'Bebas Neue', sans-serif;
59+
font-size: clamp(3.2rem, 9vw, 6rem);
60+
color: #E8E8E8;
61+
text-transform: uppercase;
62+
letter-spacing: 4px;
63+
margin: 0 0 4px 0;
64+
line-height: 0.95;
65+
}
66+
67+
.gk-press-hero__divider {
68+
display: flex;
69+
align-items: center;
70+
justify-content: center;
71+
gap: 14px;
72+
margin: 28px auto 28px;
73+
width: 260px;
74+
}
75+
76+
.gk-press-hero__divider-line {
77+
flex: 1;
78+
height: 1px;
79+
background: linear-gradient(to right, transparent, rgba(232, 105, 10, 0.7), transparent);
80+
}
81+
82+
.gk-press-hero__divider-dot {
83+
width: 5px;
84+
height: 5px;
85+
background-color: #E8690A;
86+
transform: rotate(45deg);
87+
flex-shrink: 0;
88+
box-shadow: 0 0 10px rgba(232, 105, 10, 0.7);
89+
}
90+
91+
.gk-press-hero__subheading {
92+
font-family: 'DM Sans', sans-serif;
93+
font-size: 1.1rem;
94+
color: #B0B0B0;
95+
line-height: 1.75;
96+
margin: 0 auto 16px;
97+
max-width: 660px;
98+
}
99+
100+
.gk-press-hero__intro {
101+
font-family: 'DM Sans', sans-serif;
102+
font-size: 0.95rem;
103+
color: #666666;
104+
line-height: 1.75;
105+
max-width: 560px;
106+
margin: 0 auto 40px;
107+
}
108+
109+
/* ── Featured In ── */
110+
.gk-press-hero__featured-in {
111+
margin-top: 52px;
112+
padding-top: 36px;
113+
border-top: 1px solid #222222;
114+
}
115+
116+
.gk-press-hero__featured-in-label {
117+
font-family: 'DM Mono', monospace;
118+
text-transform: uppercase;
119+
letter-spacing: 4px;
120+
font-size: 0.62rem;
121+
color: #444444;
122+
display: block;
123+
margin-bottom: 22px;
124+
}
125+
126+
.gk-press-hero__featured-in-row {
127+
display: flex;
128+
flex-wrap: wrap;
129+
justify-content: center;
130+
align-items: center;
131+
gap: 10px 20px;
132+
}
133+
134+
.gk-press-hero__pub-badge {
135+
font-family: 'DM Mono', monospace;
136+
text-transform: uppercase;
137+
letter-spacing: 2px;
138+
font-size: 0.62rem;
139+
color: #4A4A4A;
140+
padding: 7px 14px;
141+
border: 1px solid #232323;
142+
transition: color 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
143+
display: inline-block;
144+
}
145+
146+
.gk-press-hero__pub-badge:hover {
147+
color: #E8690A;
148+
border-color: rgba(232, 105, 10, 0.4);
149+
box-shadow: 0 0 12px rgba(232, 105, 10, 0.08);
150+
}
151+
152+
@media screen and (max-width: 989px) {
153+
.gk-press-hero::before {
154+
width: 600px;
155+
height: 400px;
156+
}
157+
}
158+
159+
@media screen and (max-width: 749px) {
160+
.gk-press-hero__heading {
161+
font-size: clamp(2.6rem, 13vw, 3.8rem);
162+
letter-spacing: 2px;
163+
}
164+
165+
.gk-press-hero__subheading {
166+
font-size: 1rem;
167+
}
168+
169+
.gk-press-hero__divider {
170+
width: 200px;
171+
}
172+
}
173+
{%- endstyle -%}
174+
175+
<section class="gk-press-hero" id="section-{{ section.id }}">
176+
<div class="gk-press-hero__inner">
177+
<div class="gk-press-hero__content">
178+
179+
{%- if section.settings.eyebrow != blank -%}
180+
<span class="gk-press-hero__eyebrow">{{ section.settings.eyebrow }}</span>
181+
{%- endif -%}
182+
183+
{%- if section.settings.heading != blank -%}
184+
<h1 class="gk-press-hero__heading">{{ section.settings.heading }}</h1>
185+
{%- endif -%}
186+
187+
<div class="gk-press-hero__divider">
188+
<span class="gk-press-hero__divider-line"></span>
189+
<span class="gk-press-hero__divider-dot"></span>
190+
<span class="gk-press-hero__divider-line"></span>
191+
</div>
192+
193+
{%- if section.settings.subheading != blank -%}
194+
<p class="gk-press-hero__subheading">{{ section.settings.subheading }}</p>
195+
{%- endif -%}
196+
197+
{%- if section.settings.intro_text != blank -%}
198+
<p class="gk-press-hero__intro">{{ section.settings.intro_text }}</p>
199+
{%- endif -%}
200+
201+
{%- if section.settings.show_featured_in -%}
202+
{%- assign has_pubs = false -%}
203+
{%- if section.settings.pub_1 != blank or section.settings.pub_2 != blank or section.settings.pub_3 != blank or section.settings.pub_4 != blank or section.settings.pub_5 != blank or section.settings.pub_6 != blank -%}
204+
{%- assign has_pubs = true -%}
205+
{%- endif -%}
206+
207+
{%- if has_pubs -%}
208+
<div class="gk-press-hero__featured-in">
209+
<span class="gk-press-hero__featured-in-label">Featured In</span>
210+
<div class="gk-press-hero__featured-in-row">
211+
{%- if section.settings.pub_1 != blank -%}
212+
<span class="gk-press-hero__pub-badge">{{ section.settings.pub_1 }}</span>
213+
{%- endif -%}
214+
{%- if section.settings.pub_2 != blank -%}
215+
<span class="gk-press-hero__pub-badge">{{ section.settings.pub_2 }}</span>
216+
{%- endif -%}
217+
{%- if section.settings.pub_3 != blank -%}
218+
<span class="gk-press-hero__pub-badge">{{ section.settings.pub_3 }}</span>
219+
{%- endif -%}
220+
{%- if section.settings.pub_4 != blank -%}
221+
<span class="gk-press-hero__pub-badge">{{ section.settings.pub_4 }}</span>
222+
{%- endif -%}
223+
{%- if section.settings.pub_5 != blank -%}
224+
<span class="gk-press-hero__pub-badge">{{ section.settings.pub_5 }}</span>
225+
{%- endif -%}
226+
{%- if section.settings.pub_6 != blank -%}
227+
<span class="gk-press-hero__pub-badge">{{ section.settings.pub_6 }}</span>
228+
{%- endif -%}
229+
</div>
230+
</div>
231+
{%- endif -%}
232+
{%- endif -%}
233+
234+
</div>
235+
</div>
236+
</section>
237+
238+
{% schema %}
239+
{
240+
"name": "GK Press Hero",
241+
"tag": "section",
242+
"class": "gk-press-hero-section",
243+
"settings": [
244+
{
245+
"type": "text",
246+
"id": "eyebrow",
247+
"label": "Eyebrow Text",
248+
"default": "In the Press"
249+
},
250+
{
251+
"type": "text",
252+
"id": "heading",
253+
"label": "Headline",
254+
"default": "Press & Media"
255+
},
256+
{
257+
"type": "textarea",
258+
"id": "subheading",
259+
"label": "Subheading",
260+
"default": "Greg Koch has been featured in leading guitar publications, interviews, and music media outlets around the world."
261+
},
262+
{
263+
"type": "textarea",
264+
"id": "intro_text",
265+
"label": "Intro Paragraph (optional)",
266+
"info": "Optional second line of supporting copy beneath the subheading."
267+
},
268+
{
269+
"type": "header",
270+
"content": "Featured In Row"
271+
},
272+
{
273+
"type": "checkbox",
274+
"id": "show_featured_in",
275+
"label": "Show Featured In Row",
276+
"default": true
277+
},
278+
{
279+
"type": "text",
280+
"id": "pub_1",
281+
"label": "Publication 1",
282+
"default": "Relix Magazine"
283+
},
284+
{
285+
"type": "text",
286+
"id": "pub_2",
287+
"label": "Publication 2",
288+
"default": "Vintage Guitar Magazine"
289+
},
290+
{
291+
"type": "text",
292+
"id": "pub_3",
293+
"label": "Publication 3",
294+
"default": "Guitar Player"
295+
},
296+
{
297+
"type": "text",
298+
"id": "pub_4",
299+
"label": "Publication 4",
300+
"default": "Premier Guitar"
301+
},
302+
{
303+
"type": "text",
304+
"id": "pub_5",
305+
"label": "Publication 5",
306+
"default": "Guitar World"
307+
},
308+
{
309+
"type": "text",
310+
"id": "pub_6",
311+
"label": "Publication 6 (optional)",
312+
"default": "Palm Beach Arts Paper"
313+
},
314+
{
315+
"type": "header",
316+
"content": "Spacing"
317+
},
318+
{
319+
"type": "range",
320+
"id": "padding_top",
321+
"label": "Padding Top",
322+
"min": 40,
323+
"max": 160,
324+
"step": 8,
325+
"default": 96,
326+
"unit": "px"
327+
},
328+
{
329+
"type": "range",
330+
"id": "padding_bottom",
331+
"label": "Padding Bottom",
332+
"min": 40,
333+
"max": 160,
334+
"step": 8,
335+
"default": 96,
336+
"unit": "px"
337+
}
338+
],
339+
"presets": [
340+
{
341+
"name": "GK Press Hero"
342+
}
343+
]
344+
}
345+
{% endschema %}

sections/gk-press-quotes.liquid

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,6 @@
281281
"type": "text",
282282
"id": "source",
283283
"label": "Source Label (optional)",
284-
"default": "",
285284
"info": "Optional secondary line below attribution — e.g. an article title or date."
286285
},
287286
{
@@ -303,7 +302,6 @@
303302
"settings": {
304303
"quote": "The best guitarist working today.",
305304
"attribution": "Palm Beach Arts Paper",
306-
"source": "",
307305
"emphasis": true
308306
}
309307
},
@@ -312,7 +310,6 @@
312310
"settings": {
313311
"quote": "A master of tone, groove, and musical personality.",
314312
"attribution": "Vintage Guitar Magazine",
315-
"source": "",
316313
"emphasis": false
317314
}
318315
},
@@ -321,7 +318,6 @@
321318
"settings": {
322319
"quote": "Add Joe Bonamassa quote here — enter the approved wording in the theme editor.",
323320
"attribution": "Joe Bonamassa",
324-
"source": "",
325321
"emphasis": false
326322
}
327323
}

0 commit comments

Comments
 (0)