You do not need to know React. The design system’s reference implementation is in React; on Shopify you use CSS + Liquid that your team ships to match those specs.
You will be able to:
packages/ui) and the component documentation on this site.component-api.json). If a table row and a code snippet disagree, trust the table / component page and ask your team to refresh the snippet text.ds-components.css package together.| Term | In plain language |
|---|---|
| Design tokens | Named CSS variables (colors, spacing, radius). Your theme references them as var(--ds-…) after you add ds-tokens.css. |
| Snippet | A small reusable Liquid file under Snippets (e.g. ds-button.liquid). You call it with {% render 'ds-button', … %}. |
| Section | A block merchants add in the theme editor; it has its own Liquid file under sections/ and often a {% schema %} JSON block for settings. |
| settings_schema.json | Theme-wide settings in Config. It must stay valid JSON: one array of setting groups (see Step 6). |
This guide walks you through integrating the ELFBAR Design System into a Shopify Liquid theme. After completing these steps, you will have:
Check that you have:
ds-tokens.css — from your design system team (or built from the monorepo packages/tokens if you are a developer)ds-components.css — component CSS that uses those tokens (not generated in this repo for Shopify; supplied by your team)ds-components.min.js (optional) — for accordions, tabs, etc., if your team provides itDevelopers: Token CSS is produced by the Style Dictionary pipeline under packages/tokens. Shopify-specific bundles (ds-components.css / .js) are a separate deliverable—coordinate with your team for file names and versions.
Purpose: Make design system CSS variables available everywhere in the theme.
Design tokens define colors, spacing, fonts, and radii. They ship as CSS variables (e.g. var(--ds-color-…)).
ds-tokens, extension .cssds-tokens.css from your design system teamOpen layout/theme.liquid. Before </head>, add:
{{ 'ds-tokens.css' | asset_url | stylesheet_tag }}Place it after your theme’s main stylesheet so tokens are available to later rules.
Purpose: Apply the design system’s look (buttons, cards, etc.) using classes such as .ds-button.
ds-componentsds-components.cssRight after the token line in layout/theme.liquid:
{{ 'ds-components.css' | asset_url | stylesheet_tag }}Example </head> tail:
{{ 'ds-tokens.css' | asset_url | stylesheet_tag }}
{{ 'ds-components.css' | asset_url | stylesheet_tag }}
</head>Purpose: Enable expand/collapse, tabs, and other patterns that need JavaScript.
If you only need static pieces (e.g. buttons and cards), you can skip this.
ds-components.min.js</body>In layout/theme.liquid:
{{ 'ds-components.min.js' | asset_url | script_tag }}Purpose: Add reusable snippets under Snippets and call them with {% render 'ds-…' %} from sections or templates.
ds-button → ds-button.liquid)If Shopify (Liquid) shows two fenced blocks, use the Two Liquid examples note on that page: the first block is the snippet file; the second is usage in a section or template — do not save the second block as a snippet.
Copy-paste parameters and {% render %} examples live on each component page next to Props API and Specs. This step is the checklist; use the table to open the right page.
| Component | Dev tab → Shopify (Liquid) |
|---|---|
| Accordion | Accordion |
| Badge | Badge |
| Breadcrumb | Breadcrumb |
| Button | Button |
| Gradient Button | Gradient Button |
| FAB | FAB |
| Icon Button | Icon Button |
| Card | Card |
| Checkbox | Checkbox |
| Chips | Chips |
| Date Picker | Date Picker |
| Dialogs | Dialogs |
| Divider | Divider |
| Loading | Loading |
| Menu | Menu |
| Options | Options |
| Pagination | Pagination |
| Radio | Radio |
| Scrollbar | Scrollbar |
| Search | Search |
| Selector | Selector |
| Skeleton | Skeleton |
| Switch | Switch |
| Tabs | Tabs |
| Text Field | Text Field |
| TextArea | TextArea |
| Toast | Toast |
| Tooltip | Tooltip |
If a page states the pattern is not a 1:1 Liquid port, follow its link to Storefront gaps and workarounds in this guide.
Purpose: Show real products and FAQ content using the snippets above.
Once snippets exist, call them from sections/*.liquid, templates/*.liquid, or other snippets.
Create sections/ds-product-grid.liquid:
<div class="ds-product-grid">
<div class="ds-product-grid__header">
{% if section.settings.title != blank %}
<h2>{{ section.settings.title }}</h2>
{% endif %}
</div>
<div class="ds-product-grid__items">
{% for product in collections[section.settings.collection].products limit: section.settings.limit %}
{% render 'ds-card',
image_url: product.featured_image | image_url: width: 600,
image_alt: product.featured_image.alt,
title: product.title,
price: product.price | money,
href: product.url
%}
{% endfor %}
</div>
</div>
{% schema %}
{
"name": "Product Grid",
"settings": [
{
"type": "text",
"id": "title",
"label": "Section Title",
"default": "Featured Products"
},
{
"type": "collection",
"id": "collection",
"label": "Collection"
},
{
"type": "range",
"id": "limit",
"label": "Number of products",
"min": 2,
"max": 12,
"step": 1,
"default": 4
}
],
"presets": [
{
"name": "Product Grid"
}
]
}
{% endschema %}Create sections/ds-faq.liquid:
<div class="ds-faq-section">
{% if section.settings.title != blank %}
<h2>{{ section.settings.title }}</h2>
{% endif %}
{% render 'ds-accordion', type: 'single' %}
</div>
{% schema %}
{
"name": "FAQ",
"settings": [
{
"type": "text",
"id": "title",
"label": "Section Title",
"default": "Frequently Asked Questions"
}
],
"blocks": [
{
"type": "accordion_item",
"name": "Question",
"settings": [
{
"type": "text",
"id": "title",
"label": "Question",
"default": "What is your return policy?"
},
{
"type": "richtext",
"id": "content",
"label": "Answer",
"default": "<p>We offer a 30-day return policy for all unused products.</p>"
}
]
}
],
"presets": [
{
"name": "FAQ",
"blocks": [
{ "type": "accordion_item" },
{ "type": "accordion_item" },
{ "type": "accordion_item" }
]
}
]
}
{% endschema %}Purpose: Switch ELFBAR / Lost Mary and optional dark mode using data-brand and data-theme on <html>, matching how tokens are scoped in the design system.
Open config/settings_schema.json. It is a JSON array [ … ] of blocks. Do not delete existing entries.
} of the last setting group in the array.}.Example fragment (your file will have more objects before and/or after):
[
{
"name": "Design System",
"settings": [
{
"type": "select",
"id": "ds_brand",
"label": "Brand",
"options": [
{ "value": "elfbar", "label": "ELFBAR" },
{ "value": "lostmary", "label": "Lost Mary" }
],
"default": "elfbar"
},
{
"type": "checkbox",
"id": "ds_dark_mode",
"label": "Enable dark mode",
"default": false
}
]
}
]If your file already contains other groups, the result should look like: [ { …existing… }, { "name": "Design System", … } ].
<html>In layout/theme.liquid:
<html
lang="{{ request.locale.iso_code }}"
{% if settings.ds_brand != 'elfbar' %}data-brand="{{ settings.ds_brand }}"{% endif %}
{% if settings.ds_dark_mode %}data-theme="dark"{% endif %}
>Components that read CSS variables from your token bundle will follow the selected brand and theme.
The interactive docs on this site describe spacing, variants, states, accessibility, and tokens for each component. Use them as the spec while you write Liquid and classes in Shopify.
/en/components/.../zh/components/...(If your deployment hides the default locale in the path, use your site’s actual prefix.)
| Topic | Path |
|---|---|
| Button | /components/buttons/button |
| Card | /components/card |
| Badge | /components/badge |
| Breadcrumb | /components/breadcrumb |
| Accordion | /components/accordion |
| Dialogs (reference for layout / tokens, not 1:1 Liquid) | /components/dialogs |
| Menu | /components/menu |
| Tabs | /components/tabs |
| Text field | /components/text-field |
ds-components.css expects.{% schema %} so content stays out of code.Some React components rely on portals, app-level state, or patterns that do not map 1:1 to a Liquid storefront. Use the ideas below when you still need a similar experience.
Menu.Toast stack.For Dialog, Toast, Menu, Datepicker, Fab, Options, see also the “Not available for storefront” table below for the short rationale.
The tables are generated from this repository when the docs site is built. They show planned CSS / snippet naming and variants from source.
Please note:
ds-*.liquid and CSS when they are ready.ds-components.min.js (or equivalent) and must align with your team’s script.