Skip to content
Open
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 assets/icon-heart.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 4 additions & 4 deletions sections/header-group.json
Original file line number Diff line number Diff line change
Expand Up @@ -80,15 +80,15 @@
}
},
"settings": {
"logo_position": "left",
"logo_position": "center",
"menu_position": "left",
"menu_row": "top",
"show_search": true,
"search_position": "right",
"search_row": "top",
"show_country": true,
"show_country": false,
"country_selector_style": false,
"show_language": true,
"show_language": false,
"localization_font": "heading",
"localization_font_size": "0.875rem",
"localization_position": "right",
Expand All @@ -98,7 +98,7 @@
"enable_sticky_header": "always",
"divider_width": 0,
"divider_size": "page-width",
"border_width": 0,
"border_width": 1,
"color_scheme_top": "scheme-1",
"color_scheme_bottom": "",
"color_scheme_transparent": "scheme-6",
Expand Down
110 changes: 110 additions & 0 deletions sections/header.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -989,6 +989,116 @@
.header__column .localization-form__select {
background-color: var(--header-bg-color);
}

/* ===== Kanva-inspired clean header design ===== */

/* Increase header height for a more spacious feel */
body {
--header-height: 70px;
}

.header {
--header-padding: var(--padding-md);
}

.header.header--compact {
--header-padding: var(--padding-sm);
}

/* Clean white background with subtle bottom border */
.header__row {
background-color: var(--header-bg-color, #fff);
border-bottom-color: rgba(0, 0, 0, 0.08);
}

/* More generous column spacing */
.header__columns {
gap: var(--gap-2xl, 2rem);
align-items: center;
min-height: 70px;
}

/* Ensure left column (nav) has enough room */
.header__column--left {
gap: var(--gap-lg, 1.5rem);
}

/* Center column: logo area */
.header__column--center {
justify-content: center;
}

/* Right column: icons with tighter but even spacing */
.header__column--right {
gap: var(--gap-sm, 0.5rem);
}

/* Navigation tab styling - clean, minimal with refined typography */
@media screen and (min-width: 750px) {
.header-menu .menu-list__link {
font-size: 0.875rem;
font-weight: 400;
letter-spacing: 0.01em;
text-transform: none;
color: var(--color-foreground);
text-decoration: none;
padding: 0.5rem 0;
transition: opacity 0.2s ease;
}

.header-menu .menu-list__link:hover {
opacity: 0.65;
}

/* Dropdown caret for menu items with children */
.header-menu .menu-list__link[aria-haspopup]::after {
content: '';
display: inline-block;
width: 0;
height: 0;
margin-left: 5px;
border-left: 3.5px solid transparent;
border-right: 3.5px solid transparent;
border-top: 3.5px solid currentColor;
vertical-align: middle;
opacity: 0.6;
}

/* If the menu item already has a caret icon, ensure proper styling */
.header-menu .menu-list__link .icon-caret {
width: 10px;
height: 10px;
opacity: 0.6;
margin-left: 2px;
}
}

/* Header action buttons - consistent sizing for Kanva icon row */
.header-actions__action {
--button-color: var(--color-foreground);
width: var(--button-size, 44px);
height: var(--button-size, 44px);
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
transition: opacity 0.2s ease;
}

.header-actions__action:hover {
opacity: 0.65;
}

.header-actions__action svg {
width: 20px;
height: 20px;
}

/* Ensure header-actions items are evenly spaced */
header-actions {
gap: 0;
align-items: center;
}
{% endstylesheet %}

{% unless request.design_mode %}
Expand Down
131 changes: 81 additions & 50 deletions snippets/header-actions.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -26,56 +26,15 @@
<header-actions
{{- block.shopify_attributes -}}
>
{% if shop.customer_accounts_enabled %}
<script
src="{{ 'dialog.js' | asset_url }}"
type="module"
></script>

<anchored-popover-component
data-close-on-resize="true"
class="account-popover mobile:hidden"
>
{% render 'account-button' with 'account-popover' as popover_id %}
<div
class="account-popover__panel details-content color-{{ settings.popover_color_scheme }}"
id="account-popover"
popover="auto"
ref="popover"
>
{% render 'account-actions' %}
</div>
</anchored-popover-component>

<dialog-component
class="account-drawer"
{{ block.shopify_attributes }}
>
{% render 'account-button', attributes: 'on:click="/showDialog"' %}
<dialog
ref="dialog"
class="color-{{ settings.popover_color_scheme }} dialog-modal dialog-drawer account-drawer__dialog"
scroll-lock
aria-labelledby="account-drawer-heading"
>
<button
ref="closeButton"
on:click="/closeDialog"
class="button button-unstyled close-button account-drawer__close-button"
aria-label="{{ 'actions.close_dialog' | t }}"
autofocus
>
<span
class="svg-wrapper"
aria-hidden="true"
>
{{- 'icon-close.svg' | inline_asset_content -}}
</span>
</button>
{% render 'account-actions' %}
</dialog>
</dialog-component>
{% endif %}
<a
href="/pages/wishlist"
class="header-actions__action header-actions__wishlist"
aria-label="{{ 'accessibility.wishlist' | t | default: 'Wishlist' }}"
>
<span class="svg-wrapper" aria-hidden="true">
{{ 'icon-heart.svg' | inline_asset_content }}
</span>
</a>

{% if settings.cart_type == 'drawer' and template.name != 'cart' %}
<script
Expand Down Expand Up @@ -211,9 +170,81 @@
{{ cart_icon }}
</a>
{% endif %}

{% if shop.customer_accounts_enabled %}
<script
src="{{ 'dialog.js' | asset_url }}"
type="module"
></script>

<anchored-popover-component
data-close-on-resize="true"
class="account-popover mobile:hidden"
>
{% render 'account-button' with 'account-popover' as popover_id %}
<div
class="account-popover__panel details-content color-{{ settings.popover_color_scheme }}"
id="account-popover"
popover="auto"
ref="popover"
>
{% render 'account-actions' %}
</div>
</anchored-popover-component>

<dialog-component
class="account-drawer"
{{ block.shopify_attributes }}
>
{% render 'account-button', attributes: 'on:click="/showDialog"' %}
<dialog
ref="dialog"
class="color-{{ settings.popover_color_scheme }} dialog-modal dialog-drawer account-drawer__dialog"
scroll-lock
aria-labelledby="account-drawer-heading"
>
<button
ref="closeButton"
on:click="/closeDialog"
class="button button-unstyled close-button account-drawer__close-button"
aria-label="{{ 'actions.close_dialog' | t }}"
autofocus
>
<span
class="svg-wrapper"
aria-hidden="true"
>
{{- 'icon-close.svg' | inline_asset_content -}}
</span>
</button>
{% render 'account-actions' %}
</dialog>
</dialog-component>
{% endif %}
</header-actions>

{% stylesheet %}
.header-actions__wishlist {
display: flex;
align-items: center;
justify-content: center;
color: var(--color-foreground);
text-decoration: none;
}

.header-actions__wishlist .svg-wrapper {
height: var(--button-size);
width: var(--button-size);
display: flex;
align-items: center;
justify-content: center;
}

.header-actions__wishlist svg {
width: var(--icon-size-md);
height: var(--icon-size-md);
}

.account-popover {
--account-popover-min-width: 22rem;
--account-actions-max-width: 22rem;
Expand Down