@caartzee/theme-sdk 0.0.0-stage → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +222 -2
- package/dist/bin/caartzee-theme.js +9223 -0
- package/dist/lib/index.js +11614 -0
- package/dist/types/src/auth/credentials-store.d.ts +18 -0
- package/dist/types/src/auth/index.d.ts +2 -0
- package/dist/types/src/auth/oauth-client.d.ts +39 -0
- package/dist/types/src/blocks/block-contract.d.ts +242 -0
- package/dist/types/src/candy/compatibility-matrix.d.ts +10 -0
- package/dist/types/src/candy/context-builder.d.ts +31 -0
- package/dist/types/src/candy/engine.d.ts +69 -0
- package/dist/types/src/candy/filters.d.ts +32 -0
- package/dist/types/src/candy/ide-support.d.ts +20 -0
- package/dist/types/src/candy/index.d.ts +9 -0
- package/dist/types/src/candy/schema-parser.d.ts +13 -0
- package/dist/types/src/candy/security.d.ts +54 -0
- package/dist/types/src/candy/tags.d.ts +11 -0
- package/dist/types/src/candy/types.d.ts +185 -0
- package/dist/types/src/cli/caartzee-cli.d.ts +9 -0
- package/dist/types/src/cli/candy-mcp.d.ts +2 -0
- package/dist/types/src/cli/candy-tool-server.d.ts +39 -0
- package/dist/types/src/cli/index.d.ts +1 -0
- package/dist/types/src/cli/mcp/component-tools.d.ts +2 -0
- package/dist/types/src/cli/mcp/docs-tools.d.ts +89 -0
- package/dist/types/src/cli/mcp/editor-tools.d.ts +22 -0
- package/dist/types/src/cli/mcp/resources-and-prompts.d.ts +2 -0
- package/dist/types/src/cli/mcp/testing-tools.d.ts +54 -0
- package/dist/types/src/cli/sdk-client.d.ts +12 -0
- package/dist/types/src/contracts/category-selection.d.ts +15 -0
- package/dist/types/src/contracts/commerce.d.ts +282 -0
- package/dist/types/src/contracts/footer-builder.d.ts +125 -0
- package/dist/types/src/contracts/hooks.d.ts +37 -0
- package/dist/types/src/contracts/manifest.d.ts +3127 -0
- package/dist/types/src/contracts/navigation.d.ts +39 -0
- package/dist/types/src/contracts/order-tracking.d.ts +40 -0
- package/dist/types/src/contracts/page.d.ts +262 -0
- package/dist/types/src/contracts/storefront-content.d.ts +60 -0
- package/dist/types/src/contracts/style-document.d.ts +2 -0
- package/dist/types/src/contracts/styles.d.ts +2002 -0
- package/dist/types/src/contracts/theme.d.ts +35 -0
- package/dist/types/src/dev-server/catalog-preview.d.ts +25 -0
- package/dist/types/src/dev-server/dev-server.d.ts +25 -0
- package/dist/types/src/dev-server/index.d.ts +1 -0
- package/dist/types/src/dev-server/local-commerce-runtime.d.ts +76 -0
- package/dist/types/src/dev-server/local-editor-server.d.ts +22 -0
- package/dist/types/src/dev-server/theme-preview.d.ts +8 -0
- package/dist/types/src/index.d.ts +27 -0
- package/dist/types/src/mock/index.d.ts +10 -0
- package/dist/types/src/mock/mock-categories.d.ts +2 -0
- package/dist/types/src/mock/mock-commerce.d.ts +55 -0
- package/dist/types/src/mock/mock-customer.d.ts +47 -0
- package/dist/types/src/mock/mock-hooks.d.ts +2 -0
- package/dist/types/src/mock/mock-products.d.ts +3 -0
- package/dist/types/src/rendering/commerce-pages.d.ts +16 -0
- package/dist/types/src/rendering/raw-html.d.ts +12 -0
- package/dist/types/src/rendering/section-wrapper.d.ts +30 -0
- package/dist/types/src/scaffold/candy-starter-assets.d.ts +2 -0
- package/dist/types/src/scaffold/commerce-generator.d.ts +3 -0
- package/dist/types/src/scaffold/index.d.ts +2 -0
- package/dist/types/src/scaffold/template-generator.d.ts +21 -0
- package/dist/types/src/sections/section-contract.d.ts +350 -0
- package/dist/types/src/settings/global-settings.d.ts +25 -0
- package/dist/types/src/templates/json-template.d.ts +991 -0
- package/dist/types/src/validation/package-validator.d.ts +53 -0
- package/dist/types/src/validation/rich-text.d.ts +24 -0
- package/package.json +29 -3
- package/templates/commerce/README.md +165 -0
- package/templates/commerce/assets/theme.css +1 -0
- package/templates/commerce/manifest.json +1 -0
- package/templates/commerce/src/blocks/index.ts +184 -0
- package/templates/commerce/src/config/settings-defaults.ts +25 -0
- package/templates/commerce/src/config/settings-schema.ts +102 -0
- package/templates/commerce/src/index.ts +90 -0
- package/templates/commerce/src/layouts/default.ts +275 -0
- package/templates/commerce/src/manifest.ts +976 -0
- package/templates/commerce/src/pages/account/components.ts +369 -0
- package/templates/commerce/src/pages/account/tabs.ts +792 -0
- package/templates/commerce/src/pages/account.ts +55 -0
- package/templates/commerce/src/pages/campaign.ts +423 -0
- package/templates/commerce/src/pages/cart.ts +261 -0
- package/templates/commerce/src/pages/category-detail.ts +124 -0
- package/templates/commerce/src/pages/category-list.ts +87 -0
- package/templates/commerce/src/pages/checkout.ts +712 -0
- package/templates/commerce/src/pages/commerce.ts +45 -0
- package/templates/commerce/src/pages/home.ts +160 -0
- package/templates/commerce/src/pages/index.ts +99 -0
- package/templates/commerce/src/pages/login.ts +204 -0
- package/templates/commerce/src/pages/order-success.ts +80 -0
- package/templates/commerce/src/pages/product-detail.ts +489 -0
- package/templates/commerce/src/pages/product-list.ts +125 -0
- package/templates/commerce/src/pages/search.ts +88 -0
- package/templates/commerce/src/pages/signup.ts +253 -0
- package/templates/commerce/src/pages/status.ts +7 -0
- package/templates/commerce/src/pages/theme-layout.ts +491 -0
- package/templates/commerce/src/pages/track-order.ts +196 -0
- package/templates/commerce/src/pages/wishlist.ts +83 -0
- package/templates/commerce/src/sections/about-story.ts +117 -0
- package/templates/commerce/src/sections/announcement-bar.ts +101 -0
- package/templates/commerce/src/sections/banner-grid.ts +319 -0
- package/templates/commerce/src/sections/campaign-banners.ts +158 -0
- package/templates/commerce/src/sections/category-slider.ts +144 -0
- package/templates/commerce/src/sections/content-builder.ts +123 -0
- package/templates/commerce/src/sections/content-controls.ts +45 -0
- package/templates/commerce/src/sections/custom-form.ts +59 -0
- package/templates/commerce/src/sections/faq-accordion.ts +123 -0
- package/templates/commerce/src/sections/footer.ts +728 -0
- package/templates/commerce/src/sections/header.ts +439 -0
- package/templates/commerce/src/sections/hero-slider.ts +492 -0
- package/templates/commerce/src/sections/hero.ts +137 -0
- package/templates/commerce/src/sections/index.ts +102 -0
- package/templates/commerce/src/sections/mobile-slider.ts +102 -0
- package/templates/commerce/src/sections/newsletter.ts +43 -0
- package/templates/commerce/src/sections/product-grid.ts +191 -0
- package/templates/commerce/src/sections/raw-html.ts +1 -0
- package/templates/commerce/src/sections/rich-text.ts +26 -0
- package/templates/commerce/src/sections/services-features.ts +211 -0
- package/templates/commerce/src/sections/testimonials.ts +194 -0
- package/templates/commerce/src/snippets/product-card.ts +178 -0
- package/templates/commerce/src/snippets/product-price.ts +46 -0
- package/templates/commerce/src/snippets/responsive-image.ts +29 -0
- package/templates/commerce/src/styles.ts +477 -0
- package/templates/commerce/src/templates/404.json +26 -0
- package/templates/commerce/src/templates/account.json +17 -0
- package/templates/commerce/src/templates/cart.json +17 -0
- package/templates/commerce/src/templates/category.json +16 -0
- package/templates/commerce/src/templates/checkout.json +15 -0
- package/templates/commerce/src/templates/collection.json +16 -0
- package/templates/commerce/src/templates/index.json +180 -0
- package/templates/commerce/src/templates/login.json +17 -0
- package/templates/commerce/src/templates/order-success.json +17 -0
- package/templates/commerce/src/templates/page.json +17 -0
- package/templates/commerce/src/templates/product.json +17 -0
- package/templates/commerce/src/templates/search.json +18 -0
- package/templates/commerce/src/templates/signup.json +17 -0
- package/templates/commerce/src/templates/track-order.json +17 -0
- package/templates/commerce/src/templates/wishlist.json +17 -0
- package/templates/commerce/src/templates.ts +510 -0
- package/templates/commerce/src/tokens.ts +22 -0
- package/templates/theme-candy-boilerplate/.editorconfig +14 -0
- package/templates/theme-candy-boilerplate/.gitattributes +1 -0
- package/templates/theme-candy-boilerplate/.vscode/extensions.json +7 -0
- package/templates/theme-candy-boilerplate/.vscode/settings.json +17 -0
- package/templates/theme-candy-boilerplate/assets/theme.css +78 -0
- package/templates/theme-candy-boilerplate/assets/theme.js +7 -0
- package/templates/theme-candy-boilerplate/candy.config.json +40 -0
- package/templates/theme-candy-boilerplate/index.ts +39 -0
- package/templates/theme-candy-boilerplate/layout/theme.candy +25 -0
- package/templates/theme-candy-boilerplate/locales/en.default.json +37 -0
- package/templates/theme-candy-boilerplate/manifest.json +123 -0
- package/templates/theme-candy-boilerplate/package.json +16 -0
- package/templates/theme-candy-boilerplate/schemas/settings_schema.json +36 -0
- package/templates/theme-candy-boilerplate/sections/featured-products.candy +89 -0
- package/templates/theme-candy-boilerplate/sections/footer.candy +50 -0
- package/templates/theme-candy-boilerplate/sections/header.candy +116 -0
- package/templates/theme-candy-boilerplate/sections/hero-banner.candy +135 -0
- package/templates/theme-candy-boilerplate/sections/image-with-text.candy +85 -0
- package/templates/theme-candy-boilerplate/snippets/price.candy +19 -0
- package/templates/theme-candy-boilerplate/snippets/product-card.candy +43 -0
- package/templates/theme-candy-boilerplate/templates/404.candy +12 -0
- package/templates/theme-candy-boilerplate/templates/cart.candy +51 -0
- package/templates/theme-candy-boilerplate/templates/collection.candy +51 -0
- package/templates/theme-candy-boilerplate/templates/index.candy +7 -0
- package/templates/theme-candy-boilerplate/templates/page.candy +10 -0
- package/templates/theme-candy-boilerplate/templates/product.candy +59 -0
- package/templates/theme-candy-boilerplate/templates/search.candy +40 -0
- package/templates/vscode-candy/LICENSE +21 -0
- package/templates/vscode-candy/README.md +22 -0
- package/templates/vscode-candy/extension.js +689 -0
- package/templates/vscode-candy/icons/candy-dark.svg +23 -0
- package/templates/vscode-candy/icons/candy-light.svg +23 -0
- package/templates/vscode-candy/icons/candy-logo.png +0 -0
- package/templates/vscode-candy/icons/candy-sweet-dark.svg +23 -0
- package/templates/vscode-candy/icons/candy-sweet-light.svg +23 -0
- package/templates/vscode-candy/language-configuration.json +47 -0
- package/templates/vscode-candy/package.json +118 -0
- package/templates/vscode-candy/schemas/candy-config.schema.json +56 -0
- package/templates/vscode-candy/schemas/candy-settings.schema.json +70 -0
- package/templates/vscode-candy/snippets/candy.code-snippets +270 -0
- package/templates/vscode-candy/syntaxes/candy.tmLanguage.json +296 -0
- package/templates/vscode-candy/vim/ftdetect/candy.vim +5 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none">
|
|
2
|
+
<!-- Top-Left Fluted Candy Wrapper Tail -->
|
|
3
|
+
<path d="M8.5 8.5 L2.2 1.8 L5.2 5.8 L1.8 5.2 L5.8 8.2 L1.8 9.2 L8.5 10.5 Z" fill="#F472B6"/>
|
|
4
|
+
<path d="M9.2 9.2 L2.8 2.2 L6.8 3.2 L8.2 1.5 L10.5 8.5 Z" fill="#FB7185"/>
|
|
5
|
+
|
|
6
|
+
<!-- Bottom-Right Fluted Candy Wrapper Tail -->
|
|
7
|
+
<path d="M15.5 15.5 L21.8 22.2 L18.8 18.2 L22.2 18.8 L18.2 15.8 L22.2 14.8 L15.5 13.5 Z" fill="#C084FC"/>
|
|
8
|
+
<path d="M14.8 14.8 L21.2 21.8 L17.2 20.8 L15.8 22.5 L13.5 15.5 Z" fill="#F472B6"/>
|
|
9
|
+
|
|
10
|
+
<!-- Wrapper Twist Knots -->
|
|
11
|
+
<ellipse cx="7.4" cy="7.4" rx="2.3" ry="1.3" transform="rotate(-45 7.4 7.4)" fill="#FBCFE8"/>
|
|
12
|
+
<ellipse cx="16.6" cy="16.6" rx="2.3" ry="1.3" transform="rotate(-45 16.6 16.6)" fill="#E9D5FF"/>
|
|
13
|
+
|
|
14
|
+
<!-- Main Round Candy Body -->
|
|
15
|
+
<circle cx="12" cy="12" r="6.6" fill="#EC4899" stroke="#FDF2F8" stroke-width="1.1"/>
|
|
16
|
+
|
|
17
|
+
<!-- Bold White Peppermint Candy Stripes -->
|
|
18
|
+
<path d="M7.6 10.2 C9.5 8.2, 12.8 8.2, 14.8 10.2" stroke="#FFFFFF" stroke-width="1.9" stroke-linecap="round" fill="none"/>
|
|
19
|
+
<path d="M9.2 13.8 C11.2 15.8, 14.5 15.8, 16.4 13.8" stroke="#FCE7F3" stroke-width="1.9" stroke-linecap="round" fill="none"/>
|
|
20
|
+
|
|
21
|
+
<!-- Candy Center Swirl / Shine -->
|
|
22
|
+
<circle cx="10.2" cy="9.8" r="1.1" fill="#FFFFFF"/>
|
|
23
|
+
</svg>
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none">
|
|
2
|
+
<!-- Top-Left Fluted Candy Wrapper Tail -->
|
|
3
|
+
<path d="M8.5 8.5 L2.2 1.8 L5.2 5.8 L1.8 5.2 L5.8 8.2 L1.8 9.2 L8.5 10.5 Z" fill="#DB2777"/>
|
|
4
|
+
<path d="M9.2 9.2 L2.8 2.2 L6.8 3.2 L8.2 1.5 L10.5 8.5 Z" fill="#E11D48"/>
|
|
5
|
+
|
|
6
|
+
<!-- Bottom-Right Fluted Candy Wrapper Tail -->
|
|
7
|
+
<path d="M15.5 15.5 L21.8 22.2 L18.8 18.2 L22.2 18.8 L18.2 15.8 L22.2 14.8 L15.5 13.5 Z" fill="#9333EA"/>
|
|
8
|
+
<path d="M14.8 14.8 L21.2 21.8 L17.2 20.8 L15.8 22.5 L13.5 15.5 Z" fill="#DB2777"/>
|
|
9
|
+
|
|
10
|
+
<!-- Wrapper Twist Knots -->
|
|
11
|
+
<ellipse cx="7.4" cy="7.4" rx="2.3" ry="1.3" transform="rotate(-45 7.4 7.4)" fill="#F472B6"/>
|
|
12
|
+
<ellipse cx="16.6" cy="16.6" rx="2.3" ry="1.3" transform="rotate(-45 16.6 16.6)" fill="#C084FC"/>
|
|
13
|
+
|
|
14
|
+
<!-- Main Round Candy Body -->
|
|
15
|
+
<circle cx="12" cy="12" r="6.6" fill="#DB2777" stroke="#FFFFFF" stroke-width="1.1"/>
|
|
16
|
+
|
|
17
|
+
<!-- Bold White Peppermint Candy Stripes -->
|
|
18
|
+
<path d="M7.6 10.2 C9.5 8.2, 12.8 8.2, 14.8 10.2" stroke="#FFFFFF" stroke-width="1.9" stroke-linecap="round" fill="none"/>
|
|
19
|
+
<path d="M9.2 13.8 C11.2 15.8, 14.5 15.8, 16.4 13.8" stroke="#FCE7F3" stroke-width="1.9" stroke-linecap="round" fill="none"/>
|
|
20
|
+
|
|
21
|
+
<!-- Candy Center Swirl / Shine -->
|
|
22
|
+
<circle cx="10.2" cy="9.8" r="1.1" fill="#FFFFFF"/>
|
|
23
|
+
</svg>
|
|
Binary file
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none">
|
|
2
|
+
<!-- Top-Left Fluted Candy Wrapper Tail -->
|
|
3
|
+
<path d="M8.5 8.5 L2.2 1.8 L5.2 5.8 L1.8 5.2 L5.8 8.2 L1.8 9.2 L8.5 10.5 Z" fill="#F472B6"/>
|
|
4
|
+
<path d="M9.2 9.2 L2.8 2.2 L6.8 3.2 L8.2 1.5 L10.5 8.5 Z" fill="#FB7185"/>
|
|
5
|
+
|
|
6
|
+
<!-- Bottom-Right Fluted Candy Wrapper Tail -->
|
|
7
|
+
<path d="M15.5 15.5 L21.8 22.2 L18.8 18.2 L22.2 18.8 L18.2 15.8 L22.2 14.8 L15.5 13.5 Z" fill="#C084FC"/>
|
|
8
|
+
<path d="M14.8 14.8 L21.2 21.8 L17.2 20.8 L15.8 22.5 L13.5 15.5 Z" fill="#F472B6"/>
|
|
9
|
+
|
|
10
|
+
<!-- Wrapper Twist Knots -->
|
|
11
|
+
<ellipse cx="7.4" cy="7.4" rx="2.3" ry="1.3" transform="rotate(-45 7.4 7.4)" fill="#FBCFE8"/>
|
|
12
|
+
<ellipse cx="16.6" cy="16.6" rx="2.3" ry="1.3" transform="rotate(-45 16.6 16.6)" fill="#E9D5FF"/>
|
|
13
|
+
|
|
14
|
+
<!-- Main Round Candy Body -->
|
|
15
|
+
<circle cx="12" cy="12" r="6.6" fill="#EC4899" stroke="#FDF2F8" stroke-width="1.1"/>
|
|
16
|
+
|
|
17
|
+
<!-- Bold White Peppermint Candy Stripes -->
|
|
18
|
+
<path d="M7.6 10.2 C9.5 8.2, 12.8 8.2, 14.8 10.2" stroke="#FFFFFF" stroke-width="1.9" stroke-linecap="round" fill="none"/>
|
|
19
|
+
<path d="M9.2 13.8 C11.2 15.8, 14.5 15.8, 16.4 13.8" stroke="#FCE7F3" stroke-width="1.9" stroke-linecap="round" fill="none"/>
|
|
20
|
+
|
|
21
|
+
<!-- Candy Center Swirl / Shine -->
|
|
22
|
+
<circle cx="10.2" cy="9.8" r="1.1" fill="#FFFFFF"/>
|
|
23
|
+
</svg>
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none">
|
|
2
|
+
<!-- Top-Left Fluted Candy Wrapper Tail -->
|
|
3
|
+
<path d="M8.5 8.5 L2.2 1.8 L5.2 5.8 L1.8 5.2 L5.8 8.2 L1.8 9.2 L8.5 10.5 Z" fill="#DB2777"/>
|
|
4
|
+
<path d="M9.2 9.2 L2.8 2.2 L6.8 3.2 L8.2 1.5 L10.5 8.5 Z" fill="#E11D48"/>
|
|
5
|
+
|
|
6
|
+
<!-- Bottom-Right Fluted Candy Wrapper Tail -->
|
|
7
|
+
<path d="M15.5 15.5 L21.8 22.2 L18.8 18.2 L22.2 18.8 L18.2 15.8 L22.2 14.8 L15.5 13.5 Z" fill="#9333EA"/>
|
|
8
|
+
<path d="M14.8 14.8 L21.2 21.8 L17.2 20.8 L15.8 22.5 L13.5 15.5 Z" fill="#DB2777"/>
|
|
9
|
+
|
|
10
|
+
<!-- Wrapper Twist Knots -->
|
|
11
|
+
<ellipse cx="7.4" cy="7.4" rx="2.3" ry="1.3" transform="rotate(-45 7.4 7.4)" fill="#F472B6"/>
|
|
12
|
+
<ellipse cx="16.6" cy="16.6" rx="2.3" ry="1.3" transform="rotate(-45 16.6 16.6)" fill="#C084FC"/>
|
|
13
|
+
|
|
14
|
+
<!-- Main Round Candy Body -->
|
|
15
|
+
<circle cx="12" cy="12" r="6.6" fill="#DB2777" stroke="#FFFFFF" stroke-width="1.1"/>
|
|
16
|
+
|
|
17
|
+
<!-- Bold White Peppermint Candy Stripes -->
|
|
18
|
+
<path d="M7.6 10.2 C9.5 8.2, 12.8 8.2, 14.8 10.2" stroke="#FFFFFF" stroke-width="1.9" stroke-linecap="round" fill="none"/>
|
|
19
|
+
<path d="M9.2 13.8 C11.2 15.8, 14.5 15.8, 16.4 13.8" stroke="#FCE7F3" stroke-width="1.9" stroke-linecap="round" fill="none"/>
|
|
20
|
+
|
|
21
|
+
<!-- Candy Center Swirl / Shine -->
|
|
22
|
+
<circle cx="10.2" cy="9.8" r="1.1" fill="#FFFFFF"/>
|
|
23
|
+
</svg>
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
{
|
|
2
|
+
"comments": {
|
|
3
|
+
"blockComment": ["{% comment %}", "{% endcomment %}"]
|
|
4
|
+
},
|
|
5
|
+
"brackets": [
|
|
6
|
+
["{%", "%}"],
|
|
7
|
+
["{%-", "-%}"],
|
|
8
|
+
["{{", "}}"],
|
|
9
|
+
["{{-", "-}}"],
|
|
10
|
+
["<!--", "-->"],
|
|
11
|
+
["<", ">"],
|
|
12
|
+
["{", "}"],
|
|
13
|
+
["[", "]"],
|
|
14
|
+
["(", ")"]
|
|
15
|
+
],
|
|
16
|
+
"autoClosingPairs": [
|
|
17
|
+
{ "open": "{{ ", "close": " }}" },
|
|
18
|
+
{ "open": "{{", "close": "}}" },
|
|
19
|
+
{ "open": "{% ", "close": " %}" },
|
|
20
|
+
{ "open": "{%", "close": "%}" },
|
|
21
|
+
{ "open": "{", "close": "}" },
|
|
22
|
+
{ "open": "[", "close": "]" },
|
|
23
|
+
{ "open": "(", "close": ")" },
|
|
24
|
+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
|
|
25
|
+
{ "open": "'", "close": "'", "notIn": ["string", "comment"] },
|
|
26
|
+
{ "open": "<!--", "close": "-->", "notIn": ["comment", "string"] }
|
|
27
|
+
],
|
|
28
|
+
"surroundingPairs": [
|
|
29
|
+
["{", "}"],
|
|
30
|
+
["[", "]"],
|
|
31
|
+
["(", ")"],
|
|
32
|
+
["\"", "\""],
|
|
33
|
+
["'", "'"],
|
|
34
|
+
["<", ">"]
|
|
35
|
+
],
|
|
36
|
+
"folding": {
|
|
37
|
+
"markers": {
|
|
38
|
+
"start": "^\\s*\\{%-?\\s*(if|unless|case|for|tablerow|capture|paginate|form|schema|style|stylesheet|javascript|comment|doc|raw)\\b.*-?%\\}",
|
|
39
|
+
"end": "^\\s*\\{%-?\\s*end(if|unless|case|for|tablerow|capture|paginate|form|schema|style|stylesheet|javascript|comment|doc|raw)\\b.*-?%\\}"
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
"indentationRules": {
|
|
43
|
+
"increaseIndentPattern": "^\\s*\\{%-?\\s*(if|elsif|else|unless|case|when|for|tablerow|capture|paginate|form|schema|style|stylesheet|javascript)\\b(?!.*\\{%-?\\s*end\\1\\b).*-?%\\}\\s*$",
|
|
44
|
+
"decreaseIndentPattern": "^\\s*\\{%-?\\s*(elsif|else|when|end(?:if|unless|case|for|tablerow|capture|paginate|form|schema|style|stylesheet|javascript))\\b.*-?%\\}"
|
|
45
|
+
},
|
|
46
|
+
"wordPattern": "(-?\\d*\\.\\d\\w*)|([^\\`\\~\\!\\@\\$\\^\\&\\*\\(\\)\\=\\+\\[\\{\\]\\}\\\\\\|\\;\\:\\'\\\"\\,\\.\\<\\>\\/\\s]+)"
|
|
47
|
+
}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "candy-language-support",
|
|
3
|
+
"displayName": "Candy Language Support (Caartzee Themes)",
|
|
4
|
+
"description": "Official syntax highlighting, embedded schema JSON/CSS/JS grammar, snippets, live diagnostics, and IntelliSense for Caartzee .candy storefront templates.",
|
|
5
|
+
"version": "1.4.0",
|
|
6
|
+
"publisher": "AkhilJinu",
|
|
7
|
+
"license": "MIT",
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "https://github.com/NatalNineITSolutions/caartzee_tenantAdmin_service"
|
|
11
|
+
},
|
|
12
|
+
"icon": "icons/candy-logo.png",
|
|
13
|
+
"galleryBanner": {
|
|
14
|
+
"color": "#1c102e",
|
|
15
|
+
"theme": "dark"
|
|
16
|
+
},
|
|
17
|
+
"engines": {
|
|
18
|
+
"vscode": "^1.75.0"
|
|
19
|
+
},
|
|
20
|
+
"categories": [
|
|
21
|
+
"Programming Languages",
|
|
22
|
+
"Snippets",
|
|
23
|
+
"Linters",
|
|
24
|
+
"Formatters"
|
|
25
|
+
],
|
|
26
|
+
"keywords": [
|
|
27
|
+
"candy",
|
|
28
|
+
"caartzee",
|
|
29
|
+
"liquid",
|
|
30
|
+
"theme",
|
|
31
|
+
"template",
|
|
32
|
+
"storefront"
|
|
33
|
+
],
|
|
34
|
+
"activationEvents": [
|
|
35
|
+
"onLanguage:candy",
|
|
36
|
+
"workspaceContains:**/*.candy",
|
|
37
|
+
"workspaceContains:**/candy.config.json"
|
|
38
|
+
],
|
|
39
|
+
"main": "./extension.js",
|
|
40
|
+
"contributes": {
|
|
41
|
+
"commands": [
|
|
42
|
+
{ "command": "candy.dev", "title": "Candy: Start Local Preview (dev)" },
|
|
43
|
+
{ "command": "candy.doctor", "title": "Candy: Run Theme Doctor" },
|
|
44
|
+
{ "command": "candy.syncManifest", "title": "Candy: Sync Manifest" },
|
|
45
|
+
{ "command": "candy.validate", "title": "Candy: Validate Theme" },
|
|
46
|
+
{ "command": "candy.build", "title": "Candy: Build Bundle" },
|
|
47
|
+
{ "command": "candy.push", "title": "Candy: Push to Partner Portal" }
|
|
48
|
+
],
|
|
49
|
+
"languages": [
|
|
50
|
+
{
|
|
51
|
+
"id": "candy",
|
|
52
|
+
"aliases": [
|
|
53
|
+
"Candy",
|
|
54
|
+
"Candy Template",
|
|
55
|
+
"Caartzee Candy",
|
|
56
|
+
"candy"
|
|
57
|
+
],
|
|
58
|
+
"extensions": [
|
|
59
|
+
".candy"
|
|
60
|
+
],
|
|
61
|
+
"configuration": "./language-configuration.json",
|
|
62
|
+
"icon": {
|
|
63
|
+
"light": "./icons/candy-sweet-light.svg",
|
|
64
|
+
"dark": "./icons/candy-sweet-dark.svg"
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
],
|
|
68
|
+
"grammars": [
|
|
69
|
+
{
|
|
70
|
+
"language": "candy",
|
|
71
|
+
"scopeName": "text.html.candy",
|
|
72
|
+
"path": "./syntaxes/candy.tmLanguage.json",
|
|
73
|
+
"embeddedLanguages": {
|
|
74
|
+
"meta.embedded.block.json.candy": "json",
|
|
75
|
+
"meta.embedded.block.css.candy": "css",
|
|
76
|
+
"meta.embedded.block.javascript.candy": "javascript"
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
],
|
|
80
|
+
"snippets": [
|
|
81
|
+
{
|
|
82
|
+
"language": "candy",
|
|
83
|
+
"path": "./snippets/candy.code-snippets"
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
"language": "liquid",
|
|
87
|
+
"path": "./snippets/candy.code-snippets"
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
"language": "html",
|
|
91
|
+
"path": "./snippets/candy.code-snippets"
|
|
92
|
+
}
|
|
93
|
+
],
|
|
94
|
+
"jsonValidation": [
|
|
95
|
+
{
|
|
96
|
+
"fileMatch": "candy.config.json",
|
|
97
|
+
"url": "./schemas/candy-config.schema.json"
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
"fileMatch": "**/schemas/settings_schema.json",
|
|
101
|
+
"url": "./schemas/candy-settings.schema.json"
|
|
102
|
+
}
|
|
103
|
+
],
|
|
104
|
+
"configurationDefaults": {
|
|
105
|
+
"[candy]": {
|
|
106
|
+
"editor.defaultFormatter": "AkhilJinu.candy-language-support",
|
|
107
|
+
"editor.tabSize": 2,
|
|
108
|
+
"editor.insertSpaces": true,
|
|
109
|
+
"editor.bracketPairColorization.enabled": true,
|
|
110
|
+
"editor.quickSuggestions": {
|
|
111
|
+
"other": true,
|
|
112
|
+
"comments": false,
|
|
113
|
+
"strings": true
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "Caartzee Candy Theme Configuration (candy.config.json)",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"required": ["engine", "slug", "name", "version"],
|
|
6
|
+
"properties": {
|
|
7
|
+
"engine": {
|
|
8
|
+
"type": "string",
|
|
9
|
+
"enum": ["candy"],
|
|
10
|
+
"description": "Theme template engine identifier (must be 'candy')."
|
|
11
|
+
},
|
|
12
|
+
"candyVersion": {
|
|
13
|
+
"type": "string",
|
|
14
|
+
"default": "1.0.0",
|
|
15
|
+
"description": "Candy language specification version."
|
|
16
|
+
},
|
|
17
|
+
"slug": {
|
|
18
|
+
"type": "string",
|
|
19
|
+
"pattern": "^[a-z0-9-]+$",
|
|
20
|
+
"description": "Unique kebab-case identifier for the theme."
|
|
21
|
+
},
|
|
22
|
+
"name": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"description": "Human-readable display name of the theme."
|
|
25
|
+
},
|
|
26
|
+
"version": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"description": "Semantic version of the theme (e.g. 1.0.0)."
|
|
29
|
+
},
|
|
30
|
+
"description": {
|
|
31
|
+
"type": "string",
|
|
32
|
+
"description": "Short summary of the theme."
|
|
33
|
+
},
|
|
34
|
+
"author": {
|
|
35
|
+
"type": "string",
|
|
36
|
+
"description": "Theme author or studio name."
|
|
37
|
+
},
|
|
38
|
+
"defaultLayout": {
|
|
39
|
+
"type": "string",
|
|
40
|
+
"default": "theme",
|
|
41
|
+
"description": "Default layout template name inside layout/<name>.candy."
|
|
42
|
+
},
|
|
43
|
+
"directories": {
|
|
44
|
+
"type": "object",
|
|
45
|
+
"properties": {
|
|
46
|
+
"layout": { "type": "string", "default": "layout" },
|
|
47
|
+
"templates": { "type": "string", "default": "templates" },
|
|
48
|
+
"sections": { "type": "string", "default": "sections" },
|
|
49
|
+
"snippets": { "type": "string", "default": "snippets" },
|
|
50
|
+
"schemas": { "type": "string", "default": "schemas" },
|
|
51
|
+
"assets": { "type": "string", "default": "assets" },
|
|
52
|
+
"locales": { "type": "string", "default": "locales" }
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "Caartzee Candy Settings Schema (settings_schema.json)",
|
|
4
|
+
"type": "array",
|
|
5
|
+
"items": {
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": ["name", "settings"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"name": {
|
|
10
|
+
"type": "string",
|
|
11
|
+
"description": "Settings group title in Theme Builder."
|
|
12
|
+
},
|
|
13
|
+
"settings": {
|
|
14
|
+
"type": "array",
|
|
15
|
+
"items": {
|
|
16
|
+
"type": "object",
|
|
17
|
+
"required": ["type"],
|
|
18
|
+
"properties": {
|
|
19
|
+
"id": { "type": "string" },
|
|
20
|
+
"type": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"enum": [
|
|
23
|
+
"text",
|
|
24
|
+
"textarea",
|
|
25
|
+
"richtext",
|
|
26
|
+
"inline_richtext",
|
|
27
|
+
"html",
|
|
28
|
+
"number",
|
|
29
|
+
"range",
|
|
30
|
+
"select",
|
|
31
|
+
"radio",
|
|
32
|
+
"checkbox",
|
|
33
|
+
"color",
|
|
34
|
+
"color_background",
|
|
35
|
+
"image",
|
|
36
|
+
"image_picker",
|
|
37
|
+
"url",
|
|
38
|
+
"link",
|
|
39
|
+
"font_picker",
|
|
40
|
+
"font",
|
|
41
|
+
"collection",
|
|
42
|
+
"product",
|
|
43
|
+
"header",
|
|
44
|
+
"paragraph"
|
|
45
|
+
]
|
|
46
|
+
},
|
|
47
|
+
"label": { "type": "string" },
|
|
48
|
+
"default": {},
|
|
49
|
+
"info": { "type": "string" },
|
|
50
|
+
"min": { "type": "number" },
|
|
51
|
+
"max": { "type": "number" },
|
|
52
|
+
"step": { "type": "number" },
|
|
53
|
+
"unit": { "type": "string" },
|
|
54
|
+
"options": {
|
|
55
|
+
"type": "array",
|
|
56
|
+
"items": {
|
|
57
|
+
"type": "object",
|
|
58
|
+
"required": ["label", "value"],
|
|
59
|
+
"properties": {
|
|
60
|
+
"label": { "type": "string" },
|
|
61
|
+
"value": { "type": ["string", "number", "boolean"] }
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
@@ -0,0 +1,270 @@
|
|
|
1
|
+
{
|
|
2
|
+
"Candy Output Expression": {
|
|
3
|
+
"prefix": ["{{", "out"],
|
|
4
|
+
"body": ["{{ ${1:expression} | ${2:escape} }}"],
|
|
5
|
+
"description": "Candy output expression with filter"
|
|
6
|
+
},
|
|
7
|
+
"Candy If Block": {
|
|
8
|
+
"prefix": ["if", "{% if"],
|
|
9
|
+
"body": [
|
|
10
|
+
"{% if ${1:condition} %}",
|
|
11
|
+
" $0",
|
|
12
|
+
"{% endif %}"
|
|
13
|
+
],
|
|
14
|
+
"description": "Candy conditional {% if %} block"
|
|
15
|
+
},
|
|
16
|
+
"Candy If / Else Block": {
|
|
17
|
+
"prefix": ["ifelse", "ife"],
|
|
18
|
+
"body": [
|
|
19
|
+
"{% if ${1:condition} %}",
|
|
20
|
+
" $2",
|
|
21
|
+
"{% else %}",
|
|
22
|
+
" $0",
|
|
23
|
+
"{% endif %}"
|
|
24
|
+
],
|
|
25
|
+
"description": "Candy {% if %} ... {% else %} ... {% endif %} block"
|
|
26
|
+
},
|
|
27
|
+
"Candy Unless Block": {
|
|
28
|
+
"prefix": ["unless"],
|
|
29
|
+
"body": [
|
|
30
|
+
"{% unless ${1:condition} %}",
|
|
31
|
+
" $0",
|
|
32
|
+
"{% endunless %}"
|
|
33
|
+
],
|
|
34
|
+
"description": "Candy {% unless %} block"
|
|
35
|
+
},
|
|
36
|
+
"Candy For Loop": {
|
|
37
|
+
"prefix": ["for", "{% for"],
|
|
38
|
+
"body": [
|
|
39
|
+
"{% for ${1:item} in ${2:collection} %}",
|
|
40
|
+
" $0",
|
|
41
|
+
"{% endfor %}"
|
|
42
|
+
],
|
|
43
|
+
"description": "Candy {% for %} loop"
|
|
44
|
+
},
|
|
45
|
+
"Candy For Loop with Else": {
|
|
46
|
+
"prefix": ["forelse"],
|
|
47
|
+
"body": [
|
|
48
|
+
"{% for ${1:product} in ${2:products} %}",
|
|
49
|
+
" $3",
|
|
50
|
+
"{% else %}",
|
|
51
|
+
" <p>${4:No items found.}</p>",
|
|
52
|
+
"{% endfor %}"
|
|
53
|
+
],
|
|
54
|
+
"description": "Candy {% for %} loop with empty fallback {% else %}"
|
|
55
|
+
},
|
|
56
|
+
"Candy Section Blocks Loop": {
|
|
57
|
+
"prefix": ["forblocks", "blocks"],
|
|
58
|
+
"body": [
|
|
59
|
+
"{% for block in section.blocks %}",
|
|
60
|
+
" <div {{ block.candy_attributes }}>",
|
|
61
|
+
" $0",
|
|
62
|
+
" </div>",
|
|
63
|
+
"{% endfor %}"
|
|
64
|
+
],
|
|
65
|
+
"description": "Iterate over section.blocks with Theme Builder inspector attributes"
|
|
66
|
+
},
|
|
67
|
+
"Candy Assign Variable": {
|
|
68
|
+
"prefix": ["assign"],
|
|
69
|
+
"body": ["{% assign ${1:variable_name} = ${2:value} %}"],
|
|
70
|
+
"description": "Assign a Candy variable"
|
|
71
|
+
},
|
|
72
|
+
"Candy Capture Variable": {
|
|
73
|
+
"prefix": ["capture"],
|
|
74
|
+
"body": [
|
|
75
|
+
"{% capture ${1:variable_name} %}",
|
|
76
|
+
" $0",
|
|
77
|
+
"{% endcapture %}"
|
|
78
|
+
],
|
|
79
|
+
"description": "Capture rendered HTML into a Candy variable"
|
|
80
|
+
},
|
|
81
|
+
"Candy Render Snippet": {
|
|
82
|
+
"prefix": ["render"],
|
|
83
|
+
"body": ["{% render '${1:snippet-name}', ${2:key}: ${3:value} %}"],
|
|
84
|
+
"description": "Render an isolated snippet from snippets/<name>.candy"
|
|
85
|
+
},
|
|
86
|
+
"Candy Section Include": {
|
|
87
|
+
"prefix": ["section"],
|
|
88
|
+
"body": ["{% section '${1:hero-banner}' %}"],
|
|
89
|
+
"description": "Render a section from sections/<name>.candy"
|
|
90
|
+
},
|
|
91
|
+
"Candy Layout Declaration": {
|
|
92
|
+
"prefix": ["layout"],
|
|
93
|
+
"body": ["{% layout '${1:theme}' %}"],
|
|
94
|
+
"description": "Declare the layout template (layout/<name>.candy)"
|
|
95
|
+
},
|
|
96
|
+
"Candy Paginate Block": {
|
|
97
|
+
"prefix": ["paginate"],
|
|
98
|
+
"body": [
|
|
99
|
+
"{% paginate ${1:collection.products} by ${2:12} %}",
|
|
100
|
+
" {% for ${3:product} in ${1:collection.products} %}",
|
|
101
|
+
" $0",
|
|
102
|
+
" {% endfor %}",
|
|
103
|
+
" {{ paginate | default_pagination }}",
|
|
104
|
+
"{% endpaginate %}"
|
|
105
|
+
],
|
|
106
|
+
"description": "Paginate a collection in Candy"
|
|
107
|
+
},
|
|
108
|
+
"Candy Form Block": {
|
|
109
|
+
"prefix": ["form"],
|
|
110
|
+
"body": [
|
|
111
|
+
"{% form '${1|product,cart,search,contact,customer_login|}' %}",
|
|
112
|
+
" $0",
|
|
113
|
+
"{% endform %}"
|
|
114
|
+
],
|
|
115
|
+
"description": "Render a Caartzee storefront form"
|
|
116
|
+
},
|
|
117
|
+
"Candy Style Block": {
|
|
118
|
+
"prefix": ["style"],
|
|
119
|
+
"body": [
|
|
120
|
+
"{% style %}",
|
|
121
|
+
" $0",
|
|
122
|
+
"{% endstyle %}"
|
|
123
|
+
],
|
|
124
|
+
"description": "Scoped Candy <style> block"
|
|
125
|
+
},
|
|
126
|
+
"Candy JavaScript Block": {
|
|
127
|
+
"prefix": ["javascript"],
|
|
128
|
+
"body": [
|
|
129
|
+
"{% javascript %}",
|
|
130
|
+
" $0",
|
|
131
|
+
"{% endjavascript %}"
|
|
132
|
+
],
|
|
133
|
+
"description": "Candy <script> block"
|
|
134
|
+
},
|
|
135
|
+
"Candy Section Schema": {
|
|
136
|
+
"prefix": ["schema", "{% schema"],
|
|
137
|
+
"body": [
|
|
138
|
+
"{% schema %}",
|
|
139
|
+
"{",
|
|
140
|
+
" \"name\": \"${1:Section Name}\",",
|
|
141
|
+
" \"type\": \"${2:section-slug}\",",
|
|
142
|
+
" \"category\": \"${3|Hero,Products,Content,Header,Footer,Marketing|}\",",
|
|
143
|
+
" \"allowedRegions\": [\"${4|body,header,footer|}\"],",
|
|
144
|
+
" \"settings\": [",
|
|
145
|
+
" {",
|
|
146
|
+
" \"id\": \"${5:heading}\",",
|
|
147
|
+
" \"type\": \"${6|text,textarea,richtext,number,range,select,checkbox,color,image,url|}\",",
|
|
148
|
+
" \"label\": \"${7:Heading}\",",
|
|
149
|
+
" \"default\": \"${8:Default value}\"",
|
|
150
|
+
" }",
|
|
151
|
+
" ],",
|
|
152
|
+
" \"blocks\": [],",
|
|
153
|
+
" \"presets\": [",
|
|
154
|
+
" {",
|
|
155
|
+
" \"name\": \"${1:Section Name}\",",
|
|
156
|
+
" \"isDefault\": true,",
|
|
157
|
+
" \"settings\": {",
|
|
158
|
+
" \"${5:heading}\": \"${8:Default value}\"",
|
|
159
|
+
" }",
|
|
160
|
+
" }",
|
|
161
|
+
" ]",
|
|
162
|
+
"}",
|
|
163
|
+
"{% endschema %}"
|
|
164
|
+
],
|
|
165
|
+
"description": "Complete Candy section {% schema %} JSON definition for Theme Builder"
|
|
166
|
+
},
|
|
167
|
+
"Candy Schema Setting Field": {
|
|
168
|
+
"prefix": ["setting"],
|
|
169
|
+
"body": [
|
|
170
|
+
"{",
|
|
171
|
+
" \"id\": \"${1:setting_id}\",",
|
|
172
|
+
" \"type\": \"${2|text,textarea,richtext,number,range,select,checkbox,color,image,url|}\",",
|
|
173
|
+
" \"label\": \"${3:Setting Label}\",",
|
|
174
|
+
" \"default\": \"${4:}\"",
|
|
175
|
+
"}"
|
|
176
|
+
],
|
|
177
|
+
"description": "Candy section schema setting field"
|
|
178
|
+
},
|
|
179
|
+
"Candy Dynamic Plugin Hook": {
|
|
180
|
+
"prefix": ["candy-hook", "hook"],
|
|
181
|
+
"body": ["{{ hooks.${1|product_reviews,product_price_after,product_add_to_cart_before,product_add_to_cart_after,product_description_after,login_form_top,login_form_bottom,signup_form_top,signup_form_bottom,cart_items_after,cart_summary_after,header_actions,header_announcement_before,header_announcement_after,footer_widgets_before,footer_widgets_after,footer_bottom|} }}"],
|
|
182
|
+
"description": "Render a Caartzee dynamic plugin hook slot"
|
|
183
|
+
},
|
|
184
|
+
"Candy Variant-Safe Add to Cart Button": {
|
|
185
|
+
"prefix": ["candy-add-to-cart", "atc"],
|
|
186
|
+
"body": [
|
|
187
|
+
"<button",
|
|
188
|
+
" type=\"button\"",
|
|
189
|
+
" class=\"js-add-to-cart\"",
|
|
190
|
+
" data-product-id=\"{{ product.id | escape }}\"",
|
|
191
|
+
" data-variant-id=\"{% if product.has_inventory_variants and product.selected_or_first_available_variant %}{{ product.selected_or_first_available_variant.id | escape }}{% endif %}\"",
|
|
192
|
+
" data-quantity=\"1\"",
|
|
193
|
+
" data-product-name=\"{{ product.title | escape }}\"",
|
|
194
|
+
" data-product-price=\"{{ product.price }}\"",
|
|
195
|
+
" data-product-image=\"{{ product.featured_image | image_url | escape }}\"",
|
|
196
|
+
">",
|
|
197
|
+
" ${1:Add to Bag}",
|
|
198
|
+
"</button>"
|
|
199
|
+
],
|
|
200
|
+
"description": "Caartzee variant-safe Add to Cart button (prevents /_api/cart 422 errors)"
|
|
201
|
+
},
|
|
202
|
+
"Candy Login Form with Firebase Google Sign-In": {
|
|
203
|
+
"prefix": ["candy-login-form"],
|
|
204
|
+
"body": [
|
|
205
|
+
"<form action=\"/_api/auth/login\" method=\"POST\" class=\"js-auth-form\" data-redirect=\"{{ redirect_url | default: '/account' | escape }}\">",
|
|
206
|
+
" {{ hooks.login_form_top }}",
|
|
207
|
+
" <input type=\"hidden\" name=\"redirect\" value=\"{{ redirect_url | default: '/account' | escape }}\" />",
|
|
208
|
+
" <input id=\"login-email\" type=\"email\" name=\"email\" required autocomplete=\"email\" placeholder=\"you@example.com\" />",
|
|
209
|
+
" <input id=\"login-password\" type=\"password\" name=\"password\" required autocomplete=\"current-password\" placeholder=\"••••••••\" />",
|
|
210
|
+
" <button type=\"submit\" class=\"js-submit-btn\">Sign In</button>",
|
|
211
|
+
"</form>",
|
|
212
|
+
"{% if google_auth_enabled or firebase_auth_enabled %}",
|
|
213
|
+
" <button type=\"button\" class=\"js-firebase-google-btn\" data-redirect=\"{{ redirect_url | default: '/account' | escape }}\">",
|
|
214
|
+
" <span class=\"js-google-btn-text\">Continue with Google</span>",
|
|
215
|
+
" </button>",
|
|
216
|
+
"{% endif %}",
|
|
217
|
+
"{{ hooks.login_form_bottom }}"
|
|
218
|
+
],
|
|
219
|
+
"description": "Caartzee customer login form with dynamic hooks and Firebase Google Sign-In"
|
|
220
|
+
},
|
|
221
|
+
"Candy Signup Form with Firebase Google Sign-In": {
|
|
222
|
+
"prefix": ["candy-signup-form"],
|
|
223
|
+
"body": [
|
|
224
|
+
"<form action=\"/_api/auth/register\" method=\"POST\" class=\"js-auth-form\" data-redirect=\"{{ redirect_url | default: '/account' | escape }}\">",
|
|
225
|
+
" {{ hooks.signup_form_top }}",
|
|
226
|
+
" <input type=\"hidden\" name=\"redirect\" value=\"{{ redirect_url | default: '/account' | escape }}\" />",
|
|
227
|
+
" <input id=\"reg-first-name\" type=\"text\" name=\"firstName\" required placeholder=\"First Name\" />",
|
|
228
|
+
" <input id=\"reg-last-name\" type=\"text\" name=\"lastName\" required placeholder=\"Last Name\" />",
|
|
229
|
+
" <input id=\"reg-email\" type=\"email\" name=\"email\" required autocomplete=\"email\" placeholder=\"you@example.com\" />",
|
|
230
|
+
" <input id=\"reg-phone\" type=\"tel\" name=\"mobile\" required pattern=\"[0-9]{10}\" maxlength=\"10\" inputmode=\"numeric\" placeholder=\"9876543210\" />",
|
|
231
|
+
" <input id=\"reg-password\" type=\"password\" name=\"password\" required minlength=\"8\" autocomplete=\"new-password\" placeholder=\"Password\" />",
|
|
232
|
+
" <button type=\"submit\" class=\"js-submit-btn\">Create Account</button>",
|
|
233
|
+
"</form>",
|
|
234
|
+
"{% if google_auth_enabled or firebase_auth_enabled %}",
|
|
235
|
+
" <button type=\"button\" class=\"js-firebase-google-btn\" data-redirect=\"{{ redirect_url | default: '/account' | escape }}\">",
|
|
236
|
+
" <span class=\"js-google-btn-text\">Continue with Google</span>",
|
|
237
|
+
" </button>",
|
|
238
|
+
"{% endif %}",
|
|
239
|
+
"{{ hooks.signup_form_bottom }}"
|
|
240
|
+
],
|
|
241
|
+
"description": "Caartzee customer signup form with dynamic hooks and Firebase Google Sign-In"
|
|
242
|
+
},
|
|
243
|
+
"Candy Header Menu Loop": {
|
|
244
|
+
"prefix": ["candy-header-menu"],
|
|
245
|
+
"body": [
|
|
246
|
+
"{% if linklists['main-menu'].links.size > 0 %}",
|
|
247
|
+
" {% for link in linklists['main-menu'].links %}",
|
|
248
|
+
" <a href=\"{{ link.url | safe_url }}\">{{ link.title | default: link.label | escape }}</a>",
|
|
249
|
+
" {% endfor %}",
|
|
250
|
+
"{% endif %}"
|
|
251
|
+
],
|
|
252
|
+
"description": "Render merchant Menu Manage navigation links"
|
|
253
|
+
},
|
|
254
|
+
"Candy Hero Mobile Sliders Loop": {
|
|
255
|
+
"prefix": ["candy-hero-slider"],
|
|
256
|
+
"body": [
|
|
257
|
+
"{% if mobile_sliders and mobile_sliders.size > 0 %}",
|
|
258
|
+
" {% for slide in mobile_sliders %}",
|
|
259
|
+
" <div class=\"slide{% if forloop.first %} is-active{% endif %}\" data-hero-slide=\"{{ forloop.index0 }}\">",
|
|
260
|
+
" <h1>{{ slide.title | escape }}</h1>",
|
|
261
|
+
" <p>{{ slide.description | escape }}</p>",
|
|
262
|
+
" <img src=\"{{ slide.image | image_url | escape }}\" alt=\"{{ slide.title | escape }}\" />",
|
|
263
|
+
" <a href=\"{{ slide.button_url | default: '/products' | safe_url }}\">{{ slide.button_text | default: 'Shop Now' | escape }}</a>",
|
|
264
|
+
" </div>",
|
|
265
|
+
" {% endfor %}",
|
|
266
|
+
"{% endif %}"
|
|
267
|
+
],
|
|
268
|
+
"description": "Render merchant Mobile Slider slides in hero-banner.candy"
|
|
269
|
+
}
|
|
270
|
+
}
|