@runwell/shopify-toolkit 0.4.0 → 0.4.1
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/lib/template.js
CHANGED
|
@@ -21,7 +21,8 @@ export function interpolate(source, vars) {
|
|
|
21
21
|
let working = source;
|
|
22
22
|
|
|
23
23
|
// Second pass: substitute {{config.X}} and {{brand.Y}} and {{client.Z}}
|
|
24
|
-
|
|
24
|
+
// Keys can include hyphens (e.g. brand.rain-forrest) and dots for nesting.
|
|
25
|
+
working = working.replace(/\{\{\s*([a-zA-Z][a-zA-Z0-9_.\-]*)\s*\}\}/g, (match, key) => {
|
|
25
26
|
// If the key starts with a Liquid keyword, leave it alone (it is Shopify Liquid)
|
|
26
27
|
const liquidKeywords = new Set([
|
|
27
28
|
'product', 'collection', 'cart', 'customer', 'shop', 'request',
|
package/modules/INDEX.md
CHANGED
|
@@ -44,7 +44,7 @@ Total modules: 31.
|
|
|
44
44
|
| `reviews` | social-proof | (native build) | sections:1 | heading | (none) | (none) |
|
|
45
45
|
| `risk-reversal` | conversion | (native build) | sections:1 | icon, heading, body, link_label, link_url, background_color, text_color | (none) | (none) |
|
|
46
46
|
| `shipping-bar` | conversion | (native build) | sections:1 | threshold_cents, message_below, message_qualified, message_default, background_color, text_color | (none) | (none) |
|
|
47
|
-
| `sticky-atc` | conversion |
|
|
47
|
+
| `sticky-atc` | conversion | Sticky Add To Cart Booster Pro and similar | sections:1 assets:1 | (none) | (none) | (none) |
|
|
48
48
|
| `subscriptions` | catalog | Recharge / Bold Subscriptions / Appstle for the storefront display layer; subscription management still uses Shopify's native customer account | snippets:1 | one_time_label, subscribe_label, fineprint | (none) | install-shopify-subscriptions + create-selling-plan-group + enable-customer-account-tab |
|
|
49
49
|
| `testimonials` | social-proof | (native build) | sections:1 | eyebrow, heading, background_color, text_color | (none) | (none) |
|
|
50
50
|
| `trust-badges` | social-proof | (native build) | sections:1 | background_color, text_color | (none) | (none) |
|
|
@@ -243,8 +243,9 @@ Total modules: 31.
|
|
|
243
243
|
### sticky-atc
|
|
244
244
|
|
|
245
245
|
- Category: conversion
|
|
246
|
-
-
|
|
247
|
-
-
|
|
246
|
+
- Replaces: Sticky Add To Cart Booster Pro and similar
|
|
247
|
+
- What: Sticky add-to-cart bar that slides up from the bottom on PDP after the buy area scrolls out of view.
|
|
248
|
+
- Files: sections:1 assets:1
|
|
248
249
|
|
|
249
250
|
### subscriptions
|
|
250
251
|
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
/* Runwell sticky add-to-cart bar.
|
|
2
|
+
Slides up from bottom on scroll past the buy area; hides when the
|
|
3
|
+
main buy button returns to view (driven by IntersectionObserver in
|
|
4
|
+
the section template).
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
.runwell-sticky-atc {
|
|
8
|
+
position: fixed;
|
|
9
|
+
inset: auto 0 0 0;
|
|
10
|
+
z-index: 60;
|
|
11
|
+
background: #FFFFFF;
|
|
12
|
+
border-top: 1px solid rgba(0, 0, 0, 0.08);
|
|
13
|
+
box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.06);
|
|
14
|
+
transform: translateY(100%);
|
|
15
|
+
transition: transform 0.25s ease, opacity 0.25s ease;
|
|
16
|
+
opacity: 0;
|
|
17
|
+
visibility: hidden;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.runwell-sticky-atc[aria-hidden='false'] {
|
|
21
|
+
transform: translateY(0);
|
|
22
|
+
opacity: 1;
|
|
23
|
+
visibility: visible;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.runwell-sticky-atc__inner {
|
|
27
|
+
display: flex;
|
|
28
|
+
align-items: center;
|
|
29
|
+
justify-content: space-between;
|
|
30
|
+
gap: 1rem;
|
|
31
|
+
max-width: 1200px;
|
|
32
|
+
margin: 0 auto;
|
|
33
|
+
padding: 0.75rem 1.25rem;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.runwell-sticky-atc__product {
|
|
37
|
+
display: flex;
|
|
38
|
+
align-items: center;
|
|
39
|
+
gap: 0.75rem;
|
|
40
|
+
min-width: 0;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.runwell-sticky-atc__thumb {
|
|
44
|
+
width: 40px;
|
|
45
|
+
height: 40px;
|
|
46
|
+
border-radius: 4px;
|
|
47
|
+
object-fit: cover;
|
|
48
|
+
flex-shrink: 0;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.runwell-sticky-atc__meta {
|
|
52
|
+
display: flex;
|
|
53
|
+
flex-direction: column;
|
|
54
|
+
min-width: 0;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.runwell-sticky-atc__title {
|
|
58
|
+
font-family: var(--font-heading-family, serif);
|
|
59
|
+
font-style: italic;
|
|
60
|
+
font-size: 0.95rem;
|
|
61
|
+
font-weight: 400;
|
|
62
|
+
line-height: 1.2;
|
|
63
|
+
color: var(--runwell-primary, #1A1A1A);
|
|
64
|
+
white-space: nowrap;
|
|
65
|
+
overflow: hidden;
|
|
66
|
+
text-overflow: ellipsis;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.runwell-sticky-atc__price {
|
|
70
|
+
font-family: var(--font-body-family, sans-serif);
|
|
71
|
+
font-size: 0.85rem;
|
|
72
|
+
font-weight: 500;
|
|
73
|
+
color: var(--runwell-primary, #1A1A1A);
|
|
74
|
+
opacity: 0.8;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.runwell-sticky-atc__form {
|
|
78
|
+
flex-shrink: 0;
|
|
79
|
+
margin: 0;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.runwell-sticky-atc__cta {
|
|
83
|
+
background: var(--runwell-primary, #1A1A1A);
|
|
84
|
+
color: #FFFFFF;
|
|
85
|
+
border: none;
|
|
86
|
+
border-radius: 0;
|
|
87
|
+
padding: 0.75rem 1.5rem;
|
|
88
|
+
font-family: var(--font-body-family, sans-serif);
|
|
89
|
+
font-size: 0.9rem;
|
|
90
|
+
font-weight: 600;
|
|
91
|
+
letter-spacing: 0.04em;
|
|
92
|
+
text-transform: uppercase;
|
|
93
|
+
cursor: pointer;
|
|
94
|
+
transition: opacity 0.15s ease;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
.runwell-sticky-atc__cta:hover {
|
|
98
|
+
opacity: 0.85;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.runwell-sticky-atc__cta:disabled {
|
|
102
|
+
opacity: 0.5;
|
|
103
|
+
cursor: not-allowed;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
@media (max-width: 749px) {
|
|
107
|
+
.runwell-sticky-atc__inner {
|
|
108
|
+
padding: 0.6rem 0.9rem;
|
|
109
|
+
}
|
|
110
|
+
.runwell-sticky-atc__title {
|
|
111
|
+
font-size: 0.85rem;
|
|
112
|
+
}
|
|
113
|
+
.runwell-sticky-atc__cta {
|
|
114
|
+
padding: 0.6rem 1.1rem;
|
|
115
|
+
font-size: 0.8rem;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
@@ -1,14 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sticky-atc",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"category": "conversion",
|
|
5
|
-
"description": "
|
|
5
|
+
"description": "Sticky add-to-cart bar that slides up from the bottom on PDP after the buy area scrolls out of view. Native, no app. Replaces Sticky Add To Cart Booster Pro and similar.",
|
|
6
6
|
"files": {
|
|
7
7
|
"sections": [
|
|
8
8
|
"sections/runwell-pdp-sticky.liquid"
|
|
9
|
+
],
|
|
10
|
+
"assets": [
|
|
11
|
+
"assets/runwell-sticky-atc.css"
|
|
9
12
|
]
|
|
10
13
|
},
|
|
11
14
|
"config": {
|
|
12
15
|
"schema": {}
|
|
13
16
|
}
|
|
14
|
-
}
|
|
17
|
+
}
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
{%- endcomment -%}
|
|
6
6
|
|
|
7
7
|
{%- if template == 'product' and product != blank -%}
|
|
8
|
+
{{ 'runwell-sticky-atc.css' | asset_url | stylesheet_tag }}
|
|
8
9
|
<div class="runwell-sticky-atc" data-runwell-sticky aria-hidden="true">
|
|
9
10
|
<div class="runwell-sticky-atc__inner">
|
|
10
11
|
<div class="runwell-sticky-atc__product">
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@runwell/shopify-toolkit",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.1",
|
|
4
4
|
"description": "Reusable Shopify theme modules from Runwell. Replaces typically app-driven features (reviews, wishlist, urgency, FAQ, post-purchase upsell, exit popups, free-ship progress, sticky ATC, testimonials, badges, bundles) with native Liquid + JS + CSS that ship across multiple client themes via a config-driven sync CLI.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.js",
|