Skip to content
Closed
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 .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ node_modules/
## Release files
release
*.zip
assets/style.css
117 changes: 0 additions & 117 deletions assets/critical.css
Original file line number Diff line number Diff line change
@@ -1,117 +0,0 @@
/** Critical CSS for the theme. This file is included on every page. */

/* Reset styles inspired by https://www.joshwcomeau.com/css/custom-css-reset/ */
* {
box-sizing: border-box;
margin: 0;
}

body {
display: flex;
flex-direction: column;
margin: 0;
min-height: 100svh;
}

html:has(dialog[scroll-lock][open], details[scroll-lock][open]) {
overflow: hidden;
}

img,
picture,
video,
canvas,
svg {
display: block;
max-width: 100%;
height: auto;
}

input,
textarea,
select {
font: inherit;
border-radius: var(--style-border-radius-inputs);
}

select {
background-color: var(--color-background);
color: currentcolor;
}

dialog {
background-color: var(--color-background);
color: var(--color-foreground);
}

p {
text-wrap: pretty;
}
p,
h1,
h2,
h3,
h4,
h5,
h6 {
overflow-wrap: break-word;
}

p:empty {
display: none;
}

:is(p, h1, h2, h3, h4, h5, h6):first-child,
:empty:first-child + :where(p, h1, h2, h3, h4, h5, h6) {
margin-block-start: 0;
}

:is(p, h1, h2, h3, h4, h5, h6):last-child,
:where(p, h1, h2, h3, h4, h5, h6) + :has(+ :empty:last-child) {
margin-block-end: 0;
}

/** Theme styles below */
body {
font-family: var(--font-primary--family);
background-color: var(--color-background);
color: var(--color-foreground);
}

/** Section layout utilities */

/**
* Setup a grid that enables both full-width and constrained layouts
* depending on the class of the child elements.
*
* By default, a minimum content margin is set on the left and right
* sides of the section and the content is centered in the viewport to
* not exceed the maximum page width.
*
* When a child element is given the `full-width` class, it will span
* the entire viewport.
*/
.shopify-section {
--content-width: min(
calc(var(--page-width) - var(--page-margin) * 2),
calc(100% - var(--page-margin) * 2)
);
--content-margin: minmax(var(--page-margin), 1fr);
--content-grid: var(--content-margin) var(--content-width) var(--content-margin);

/* This is required to make <img> elements work as background images */
position: relative;
grid-template-columns: var(--content-grid);
display: grid;
width: 100%;
}

/* Child elements, by default, are constrained to the central column of the grid. */
.shopify-section > * {
grid-column: 2;
}

/* Child elements that use the full-width utility class span the entire viewport. */
.shopify-section > .full-width {
grid-column: 1 / -1;
}
29 changes: 3 additions & 26 deletions blocks/group.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -12,37 +12,14 @@
{% enddoc %}

<div
class="group {{ block.settings.layout_direction }}"
style="
--padding: {{ block.settings.padding }}px;
--alignment: {{ block.settings.alignment }};
"
class="{% if block.settings.layout_direction == 'group--horizontal' %}flex flex-row justify-between items-center{% else %}flex flex-col{% endif %} {% if block.settings.layout_direction == 'group--vertical' %}items-{{ block.settings.alignment }}{% endif %} w-full overflow-hidden"
style="padding: {% if block.settings.layout_direction == 'group--horizontal' %}0 {{ block.settings.padding }}px{% else %}{{ block.settings.padding }}px 0{% endif %};"
{{ block.shopify_attributes }}
>
{% content_for 'blocks' %}
</div>

{% stylesheet %}
.group {
display: flex;
flex-wrap: nowrap;
overflow: hidden;
width: 100%;
}

.group--horizontal {
flex-direction: row;
justify-content: space-between;
align-items: center;
padding: 0 var(--padding);
}

.group--vertical {
flex-direction: column;
align-items: var(--alignment);
padding: var(--padding) 0;
}
{% endstylesheet %}
{% comment %} Replaced inline CSS with Tailwind classes {% endcomment %}

{% schema %}
{
Expand Down
20 changes: 6 additions & 14 deletions blocks/text.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -6,25 +6,17 @@
{% enddoc %}

<div
class="text {{ block.settings.text_style }}"
style="--text-align: {{ block.settings.alignment }}"
class="{% case block.settings.text_style %}
{% when 'text--title' %}text-3xl font-bold
{% when 'text--subtitle' %}text-2xl
{% else %}text-base
{% endcase %} text-{{ block.settings.alignment }}"
{{ block.shopify_attributes }}
>
{{ block.settings.text }}
</div>

{% stylesheet %}
.text {
text-align: var(--text-align);
}
.text--title {
font-size: 2rem;
font-weight: 700;
}
.text--subtitle {
font-size: 1.5rem;
}
{% endstylesheet %}
{% comment %} Replaced inline CSS with Tailwind classes {% endcomment %}

{% schema %}
{
Expand Down
4 changes: 4 additions & 0 deletions layout/password.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@
{% # Load and preload the critical CSS %}
{{ 'critical.css' | asset_url | stylesheet_tag: preload: true }}


{% comment %} Load Tailwind CSS {% endcomment %}
{{ 'style.css' | asset_url | stylesheet_tag: preload: true }}

{% # Social, title, etc. %}
{% render 'meta-tags' %}

Expand Down
3 changes: 3 additions & 0 deletions layout/theme.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@
{% # Load and preload the critical CSS %}
{{ 'critical.css' | asset_url | stylesheet_tag: preload: true }}

{% # Load and preload the style CSS %}
{{ 'style.css' | asset_url | stylesheet_tag: preload: true }}

{% # Social, title, etc. %}
{% render 'meta-tags' %}

Expand Down
Loading