ghostcn 1.6.0 → 1.7.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/dist/registry/components/account-card.json +57 -0
- package/dist/registry/components/author-card.json +1 -1
- package/dist/registry/components/author-stack.json +63 -0
- package/dist/registry/components/back-to-top.json +72 -0
- package/dist/registry/components/callout.json +56 -0
- package/dist/registry/components/checkbox.json +82 -0
- package/dist/registry/components/code-copy.json +52 -0
- package/dist/registry/components/comments-section.json +56 -0
- package/dist/registry/components/dialog.json +83 -0
- package/dist/registry/components/dropdown.json +85 -0
- package/dist/registry/components/empty-state.json +65 -0
- package/dist/registry/components/error-card.json +74 -0
- package/dist/registry/components/faq-section.json +83 -0
- package/dist/registry/components/hero.json +89 -0
- package/dist/registry/components/image-lightbox.json +44 -0
- package/dist/registry/components/magazine-grid.json +62 -0
- package/dist/registry/components/mobile-dock.json +69 -0
- package/dist/registry/components/newsletter-form.json +1 -1
- package/dist/registry/components/pagination.json +1 -1
- package/dist/registry/components/post-card.json +1 -1
- package/dist/registry/components/post-grid.json +1 -1
- package/dist/registry/components/post-header.json +1 -1
- package/dist/registry/components/post-list.json +62 -0
- package/dist/registry/components/pull-quote.json +70 -0
- package/dist/registry/components/radio-group.json +94 -0
- package/dist/registry/components/reader-controls.json +60 -0
- package/dist/registry/components/reading-meta.json +49 -0
- package/dist/registry/components/related-posts.json +1 -1
- package/dist/registry/components/search-trigger.json +68 -0
- package/dist/registry/components/select.json +94 -0
- package/dist/registry/components/separator.json +46 -0
- package/dist/registry/components/series-nav.json +62 -0
- package/dist/registry/components/skeleton.json +48 -0
- package/dist/registry/components/skip-link.json +53 -0
- package/dist/registry/components/social-links.json +74 -0
- package/dist/registry/components/stat-strip.json +85 -0
- package/dist/registry/components/sticky-subscribe.json +82 -0
- package/dist/registry/components/subscribe-bar.json +61 -0
- package/dist/registry/components/switch.json +76 -0
- package/dist/registry/components/tabs.json +81 -0
- package/dist/registry/components/tag-bar.json +63 -0
- package/dist/registry/components/textarea.json +95 -0
- package/dist/registry/components/tier-comparison.json +55 -0
- package/dist/registry/components/timeline.json +85 -0
- package/dist/registry/components/tooltip.json +65 -0
- package/dist/registry/index.json +389 -0
- package/dist/templates/playground/playground.js +1 -1
- package/dist/utils/playground-server.js +8 -2
- package/dist/utils/preview-renderer.d.ts +72 -0
- package/dist/utils/preview-renderer.js +51 -5
- package/package.json +1 -1
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "sticky-subscribe",
|
|
3
|
+
"type": "components:members",
|
|
4
|
+
"description": "Scroll-triggered, session-dismissible native Ghost subscribe prompt that hides automatically for signed-in members.",
|
|
5
|
+
"dependencies": [],
|
|
6
|
+
"ghost_version": ">=5.0.0",
|
|
7
|
+
"parameters": {
|
|
8
|
+
"variant": {
|
|
9
|
+
"description": "Prompt style: default (floating card), bar (bottom banner), or minimal (pill).",
|
|
10
|
+
"options": [
|
|
11
|
+
"default",
|
|
12
|
+
"bar",
|
|
13
|
+
"minimal"
|
|
14
|
+
],
|
|
15
|
+
"default": "default"
|
|
16
|
+
},
|
|
17
|
+
"heading": {
|
|
18
|
+
"description": "Short prompt headline.",
|
|
19
|
+
"default": "Enjoying this story?"
|
|
20
|
+
},
|
|
21
|
+
"description": {
|
|
22
|
+
"description": "Optional subtext line."
|
|
23
|
+
},
|
|
24
|
+
"placeholder": {
|
|
25
|
+
"description": "Email placeholder text.",
|
|
26
|
+
"default": "you@example.com"
|
|
27
|
+
},
|
|
28
|
+
"buttonText": {
|
|
29
|
+
"description": "Submit button label.",
|
|
30
|
+
"default": "Subscribe"
|
|
31
|
+
},
|
|
32
|
+
"threshold": {
|
|
33
|
+
"description": "Scroll depth percentage (5-95) before showing.",
|
|
34
|
+
"default": "35"
|
|
35
|
+
},
|
|
36
|
+
"dismissKey": {
|
|
37
|
+
"description": "Session storage key suffix for dismissal.",
|
|
38
|
+
"default": "default"
|
|
39
|
+
},
|
|
40
|
+
"alwaysVisible": {
|
|
41
|
+
"description": "Keep rendered inline without scroll gating when true."
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"files": [
|
|
45
|
+
{
|
|
46
|
+
"name": "sticky-subscribe.hbs",
|
|
47
|
+
"type": "partial",
|
|
48
|
+
"target": "partials/components/sticky-subscribe.hbs",
|
|
49
|
+
"content": "{{!-- Styling parameters: class, titleClass, buttonClass --}}\n{{#with this as |ghostcnStyles|}}\n{{#if @site.members_enabled}}\n{{#unless @site.members_invite_only}}\n{{#if @site.allow_self_signup}}\n{{#unless @member}}\n<aside\n class=\"ghcn-sticky-sub{{#if ghostcnStyles.class}} {{ghostcnStyles.class}}{{/if}}\"\n data-ghcn-sticky-sub\n data-variant=\"{{#match variant \"bar\"}}bar{{else}}{{#match variant \"minimal\"}}minimal{{else}}default{{/match}}{{/match}}\"\n data-threshold=\"{{#if threshold}}{{threshold}}{{else}}35{{/if}}\"\n data-always-visible=\"{{#if alwaysVisible}}true{{else}}false{{/if}}\"\n data-dismiss-key=\"{{#if dismissKey}}{{dismissKey}}{{else}}default{{/if}}\"\n data-visible=\"{{#if alwaysVisible}}true{{else}}false{{/if}}\"\n aria-label=\"{{#if heading}}{{heading}}{{else}}Subscribe to newsletter{{/if}}\"\n>\n <div class=\"ghcn-sticky-sub__copy\">\n <p class=\"ghcn-sticky-sub__title{{#if ghostcnStyles.titleClass}} {{ghostcnStyles.titleClass}}{{/if}}\">{{#if heading}}{{heading}}{{else}}Enjoying this story?{{/if}}</p>\n {{#if description}}<p class=\"ghcn-sticky-sub__desc\">{{description}}</p>{{/if}}\n </div>\n {{#if @site.portal_signup_checkbox_required}}\n <a class=\"ghcn-sticky-sub__btn{{#if ghostcnStyles.buttonClass}} {{ghostcnStyles.buttonClass}}{{/if}}\" href=\"#/portal/signup\" data-portal=\"signup\">{{#if buttonText}}{{buttonText}}{{else}}Subscribe{{/if}}</a>\n {{else}}\n <form class=\"ghcn-sticky-sub__form\" data-members-form=\"subscribe\">\n <input class=\"ghcn-sticky-sub__input\" data-members-email type=\"email\" autocomplete=\"email\" required aria-label=\"Email address\" placeholder=\"{{#if placeholder}}{{placeholder}}{{else}}you@example.com{{/if}}\" />\n <button class=\"ghcn-sticky-sub__btn{{#if ghostcnStyles.buttonClass}} {{ghostcnStyles.buttonClass}}{{/if}}\" type=\"submit\">{{#if buttonText}}{{buttonText}}{{else}}Subscribe{{/if}}</button>\n <span class=\"ghcn-sticky-sub__msg ghcn-sticky-sub__msg--ok\" role=\"status\" data-members-success>Check your inbox to confirm.</span>\n <span class=\"ghcn-sticky-sub__msg ghcn-sticky-sub__msg--err\" role=\"alert\" data-members-error>Enter a valid email.</span>\n </form>\n {{/if}}\n <button type=\"button\" class=\"ghcn-sticky-sub__close\" data-sticky-sub-close aria-label=\"Dismiss subscribe prompt\">\n <svg aria-hidden=\"true\" viewBox=\"0 0 16 16\" width=\"14\" height=\"14\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\"><path d=\"M4 4l8 8M12 4l-8 8\"/></svg>\n </button>\n</aside>\n{{/unless}}\n{{/if}}\n{{/unless}}\n{{/if}}\n{{/with}}"
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
"name": "sticky-subscribe.css",
|
|
53
|
+
"type": "style",
|
|
54
|
+
"target": "assets/css/components/sticky-subscribe.css",
|
|
55
|
+
"content": ".ghcn-sticky-sub { box-sizing: border-box; min-width: 0; overflow-wrap: anywhere; border: 1px solid var(--border, #e4e4e7); border-radius: var(--ghcn-panel-radius, min(var(--radius, 8px), 24px)); background: var(--card, #fff); color: var(--card-foreground, #09090b); position: fixed; right: 20px; bottom: 20px; z-index: 45; width: min(calc(100vw - 32px), 380px); padding: 18px 42px 18px 18px; display: grid; gap: 12px; font-family: inherit; box-shadow: 0 14px 36px rgba(0, 0, 0, .14), 0 2px 6px rgba(0, 0, 0, .06); opacity: 0; pointer-events: none; transform: translateY(14px); transition: opacity 200ms ease, transform 200ms ease; }\n.ghcn-sticky-sub *, .ghcn-sticky-sub *::before, .ghcn-sticky-sub *::after { box-sizing: border-box; }\n.ghcn-sticky-sub[hidden] { display: none; }\n.ghcn-sticky-sub[data-visible=\"true\"] { opacity: 1; pointer-events: auto; transform: translateY(0); }\n.ghcn-sticky-sub[data-always-visible=\"true\"] { position: relative; right: auto; bottom: auto; z-index: auto; width: 100%; max-width: 440px; }\n.ghcn-sticky-sub:where([data-variant=\"bar\"]) { left: 16px; right: 16px; bottom: 16px; width: auto; max-width: 960px; margin-inline: auto; padding: 14px 48px 14px 20px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; }\n.ghcn-sticky-sub:where([data-variant=\"bar\"][data-always-visible=\"true\"]) { left: auto; right: auto; bottom: auto; width: 100%; }\n.ghcn-sticky-sub:where([data-variant=\"minimal\"]) { border-radius: 9999px; padding: 10px 44px 10px 18px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; max-width: 560px; }\n.ghcn-sticky-sub__copy { display: grid; gap: 3px; min-width: 0; }\n.ghcn-sticky-sub__title { margin: 0; font-size: 14.5px; font-weight: 700; letter-spacing: -.015em; color: var(--foreground); }\n.ghcn-sticky-sub__desc { margin: 0; font-size: 12.5px; line-height: 1.45; color: var(--muted-foreground); }\n.ghcn-sticky-sub__form { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0; flex: 1 1 240px; }\n.ghcn-sticky-sub__input { flex: 1 1 150px; min-width: 0; height: 36px; padding: 0 11px; border: 1px solid var(--input, var(--border)); border-radius: var(--ghcn-control-radius, var(--radius, 8px)); background: var(--background); color: var(--foreground); font: inherit; font-size: 13.5px; }\n.ghcn-sticky-sub:where([data-variant=\"minimal\"]) .ghcn-sticky-sub__input { border-radius: 9999px; }\n.ghcn-sticky-sub__btn { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; height: 36px; padding: 0 14px; border: 1px solid transparent; border-radius: var(--ghcn-control-radius, var(--radius, 8px)); background: var(--primary); color: var(--primary-foreground); font: inherit; font-size: 13px; font-weight: 600; text-decoration: none; white-space: nowrap; cursor: pointer; transition: opacity 150ms ease; }\n.ghcn-sticky-sub:where([data-variant=\"minimal\"]) .ghcn-sticky-sub__btn { border-radius: 9999px; }\n.ghcn-sticky-sub__btn:hover { opacity: .9; }\n.ghcn-sticky-sub__msg { display: none; flex-basis: 100%; font-size: 12px; font-weight: 500; }\n.ghcn-sticky-sub__form.success .ghcn-sticky-sub__msg--ok { display: block; color: var(--success, #15803d); }\n.ghcn-sticky-sub__form.error .ghcn-sticky-sub__msg--err { display: block; color: var(--destructive, #dc2626); }\n.ghcn-sticky-sub__close { position: absolute; top: 10px; right: 10px; display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border: 0; border-radius: 9999px; background: transparent; color: var(--muted-foreground); cursor: pointer; transition: background-color 150ms ease, color 150ms ease; }\n.ghcn-sticky-sub__close:hover { background: var(--secondary); color: var(--foreground); }\n@media (prefers-reduced-motion: reduce) { .ghcn-sticky-sub { transition: none; transform: none; } }\n.ghcn-sticky-sub:focus-visible, :where(.ghcn-sticky-sub) :focus-visible { outline: 2px solid var(--ring, currentColor); outline-offset: 2px; }"
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"name": "sticky-subscribe.js",
|
|
59
|
+
"type": "js",
|
|
60
|
+
"target": "assets/js/components/sticky-subscribe.js",
|
|
61
|
+
"content": "/* ghostcn sticky-subscribe: scroll-triggered dismissible subscribe prompt, CSP-safe, repeat-safe. */\n(() => {\n const KEY = 'ghcn-sticky-sub-dismissed';\n\n function isDismissed(id) {\n try { return sessionStorage.getItem(KEY + ':' + id) === '1'; } catch { return false; }\n }\n\n function dismiss(el, id) {\n el.hidden = true;\n el.dataset.visible = 'false';\n try { sessionStorage.setItem(KEY + ':' + id, '1'); } catch {}\n }\n\n function init() {\n document.querySelectorAll('[data-ghcn-sticky-sub]').forEach(el => {\n if (el.dataset.ghcnStickySubReady) return;\n el.dataset.ghcnStickySubReady = 'true';\n const id = el.dataset.dismissKey || 'default';\n const always = el.dataset.alwaysVisible === 'true';\n if (!always && isDismissed(id)) {\n el.hidden = true;\n return;\n }\n const closeBtn = el.querySelector('[data-sticky-sub-close]');\n if (closeBtn) closeBtn.addEventListener('click', () => dismiss(el, id));\n if (always) {\n el.hidden = false;\n el.dataset.visible = 'true';\n return;\n }\n const pct = Math.min(95, Math.max(5, Number(el.dataset.threshold) || 35));\n let footerInView = false;\n const update = () => {\n if (el.hidden) return;\n const doc = document.documentElement;\n const max = doc.scrollHeight - window.innerHeight;\n const ratio = max > 40 ? (window.scrollY / max) * 100 : 0;\n el.dataset.visible = (!footerInView && ratio >= pct) ? 'true' : 'false';\n };\n const footers = document.querySelectorAll('body > footer, .folio-footer, .ghcn-footer');\n const footer = footers[footers.length - 1] || document.querySelector('footer');\n if (footer && typeof IntersectionObserver !== 'undefined') {\n const io = new IntersectionObserver(entries => {\n footerInView = entries.some(entry => entry.isIntersecting);\n update();\n }, { threshold: 0.05 });\n io.observe(footer);\n }\n update();\n window.addEventListener('scroll', update, { passive: true });\n window.addEventListener('resize', update, { passive: true });\n });\n }\n\n if (document.readyState === 'loading') document.addEventListener('DOMContentLoaded', init, { once: true });\n else init();\n})();"
|
|
62
|
+
}
|
|
63
|
+
],
|
|
64
|
+
"gscan": {
|
|
65
|
+
"rules_satisfied": [
|
|
66
|
+
"GS010-PJ-VALID",
|
|
67
|
+
"GS050-MEMBERS-FORM"
|
|
68
|
+
],
|
|
69
|
+
"notes": "Uses Ghost native data-members-form, Portal checkbox fallback, and CSP-safe sessionStorage dismissal."
|
|
70
|
+
},
|
|
71
|
+
"styleSlots": {
|
|
72
|
+
"class": [
|
|
73
|
+
".ghcn-sticky-sub"
|
|
74
|
+
],
|
|
75
|
+
"titleClass": [
|
|
76
|
+
".ghcn-sticky-sub__title"
|
|
77
|
+
],
|
|
78
|
+
"buttonClass": [
|
|
79
|
+
".ghcn-sticky-sub__btn"
|
|
80
|
+
]
|
|
81
|
+
}
|
|
82
|
+
}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "subscribe-bar",
|
|
3
|
+
"type": "components:members",
|
|
4
|
+
"description": "Compact single-row native Ghost members subscribe bar for headers, footers, and hero sections.",
|
|
5
|
+
"dependencies": [],
|
|
6
|
+
"ghost_version": ">=5.0.0",
|
|
7
|
+
"parameters": {
|
|
8
|
+
"variant": {
|
|
9
|
+
"description": "Surface style: default, outline, or filled.",
|
|
10
|
+
"default": "default"
|
|
11
|
+
},
|
|
12
|
+
"size": {
|
|
13
|
+
"description": "Control height: sm, default, or lg.",
|
|
14
|
+
"default": "default"
|
|
15
|
+
},
|
|
16
|
+
"placeholder": {
|
|
17
|
+
"description": "Email input placeholder text.",
|
|
18
|
+
"default": "you@example.com"
|
|
19
|
+
},
|
|
20
|
+
"buttonText": {
|
|
21
|
+
"description": "Submit button text.",
|
|
22
|
+
"default": "Subscribe"
|
|
23
|
+
},
|
|
24
|
+
"ariaLabel": {
|
|
25
|
+
"description": "Accessible label for the email input.",
|
|
26
|
+
"default": "Email address"
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
"files": [
|
|
30
|
+
{
|
|
31
|
+
"name": "subscribe-bar.hbs",
|
|
32
|
+
"type": "partial",
|
|
33
|
+
"target": "partials/components/subscribe-bar.hbs",
|
|
34
|
+
"content": "{{!-- Styling parameters: class, inputClass, buttonClass --}}\n{{#with this as |ghostcnStyles|}}\n{{#if @site.members_enabled}}\n{{#unless @site.members_invite_only}}\n{{#if @site.allow_self_signup}}\n{{#unless @member}}\n<div class=\"ghcn-subscribe-bar{{#if ghostcnStyles.class}} {{ghostcnStyles.class}}{{/if}}\" data-variant=\"{{#match variant \"outline\"}}outline{{else}}{{#match variant \"filled\"}}filled{{else}}default{{/match}}{{/match}}\" data-size=\"{{#match size \"sm\"}}sm{{else}}{{#match size \"lg\"}}lg{{else}}default{{/match}}{{/match}}\">\n {{#if @site.portal_signup_checkbox_required}}\n <a class=\"ghcn-subscribe-bar__button{{#if ghostcnStyles.buttonClass}} {{ghostcnStyles.buttonClass}}{{/if}}\" href=\"#/portal/signup\" data-portal=\"signup\">{{#if buttonText}}{{buttonText}}{{else}}Subscribe{{/if}}</a>\n {{else}}\n <form class=\"ghcn-subscribe-bar__form\" data-members-form=\"subscribe\">\n <div class=\"ghcn-subscribe-bar__row\">\n <input\n class=\"ghcn-subscribe-bar__input{{#if ghostcnStyles.inputClass}} {{ghostcnStyles.inputClass}}{{/if}}\"\n data-members-email\n type=\"email\"\n autocomplete=\"email\"\n required\n aria-label=\"{{#if ariaLabel}}{{ariaLabel}}{{else}}Email address{{/if}}\"\n placeholder=\"{{#if placeholder}}{{placeholder}}{{else}}you@example.com{{/if}}\"\n />\n <button class=\"ghcn-subscribe-bar__button{{#if ghostcnStyles.buttonClass}} {{ghostcnStyles.buttonClass}}{{/if}}\" type=\"submit\">{{#if buttonText}}{{buttonText}}{{else}}Subscribe{{/if}}</button>\n </div>\n <p class=\"ghcn-subscribe-bar__status ghcn-subscribe-bar__status--success\" role=\"status\" data-members-success>\n <svg aria-hidden=\"true\" viewBox=\"0 0 16 16\" width=\"14\" height=\"14\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M3 8.5 6.5 12 13 4\"/></svg>\n <span>Check your inbox to confirm your subscription.</span>\n </p>\n <p class=\"ghcn-subscribe-bar__status ghcn-subscribe-bar__status--error\" role=\"alert\" data-members-error>\n <svg aria-hidden=\"true\" viewBox=\"0 0 16 16\" width=\"14\" height=\"14\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M4 4l8 8M12 4l-8 8\"/></svg>\n <span>Please enter a valid email address.</span>\n </p>\n </form>\n {{/if}}\n</div>\n{{/unless}}\n{{/if}}\n{{/unless}}\n{{/if}}\n{{/with}}"
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"name": "subscribe-bar.css",
|
|
38
|
+
"type": "style",
|
|
39
|
+
"target": "assets/css/components/subscribe-bar.css",
|
|
40
|
+
"content": ".ghcn-subscribe-bar { box-sizing: border-box; width: 100%; max-width: 460px; font-family: inherit; font-size: var(--ghcn-text-small, 14px); color: var(--foreground); }\n.ghcn-subscribe-bar *, .ghcn-subscribe-bar *::before, .ghcn-subscribe-bar *::after { box-sizing: border-box; }\n.ghcn-subscribe-bar__form { display: grid; gap: 6px; margin: 0; }\n.ghcn-subscribe-bar__row { display: flex; align-items: stretch; gap: 6px; padding: 4px; border: 1px solid var(--input, var(--border)); border-radius: calc(var(--ghcn-control-radius, var(--radius, 8px)) + 3px); background: var(--card, var(--background)); box-shadow: 0 1px 2px rgba(0, 0, 0, .04); transition: border-color 150ms ease, box-shadow 150ms ease; }\n.ghcn-subscribe-bar__row:focus-within { border-color: var(--ring, var(--primary)); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ring, var(--primary)) 16%, transparent); }\n.ghcn-subscribe-bar:where([data-variant=\"outline\"]) .ghcn-subscribe-bar__row { background: transparent; box-shadow: none; }\n.ghcn-subscribe-bar:where([data-variant=\"filled\"]) .ghcn-subscribe-bar__row { background: var(--secondary); border-color: transparent; box-shadow: none; }\n.ghcn-subscribe-bar:where([data-variant=\"filled\"]) .ghcn-subscribe-bar__row:focus-within { background: var(--background); border-color: var(--ring, var(--primary)); }\n.ghcn-subscribe-bar__input { flex: 1 1 auto; min-width: 0; min-height: 36px; padding: 0 12px; border: 0; border-radius: var(--ghcn-control-radius, var(--radius, 8px)); background: transparent; color: var(--foreground); font: inherit; font-size: 14px; line-height: 1.25; outline: none; }\n.ghcn-subscribe-bar__input::placeholder { color: var(--muted-foreground); }\n.ghcn-subscribe-bar__button { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; min-height: 36px; padding: 0 16px; border: 1px solid transparent; border-radius: var(--ghcn-control-radius, var(--radius, 8px)); background: var(--primary); color: var(--primary-foreground); font: inherit; font-size: 13px; font-weight: 600; line-height: 1; text-decoration: none; white-space: nowrap; cursor: pointer; transition: opacity 150ms ease; }\n.ghcn-subscribe-bar__button:hover { opacity: .9; }\n.ghcn-subscribe-bar:where([data-size=\"sm\"]) .ghcn-subscribe-bar__row { padding: 3px; }\n.ghcn-subscribe-bar:where([data-size=\"sm\"]) .ghcn-subscribe-bar__input { min-height: 30px; padding: 0 10px; font-size: 13px; }\n.ghcn-subscribe-bar:where([data-size=\"sm\"]) .ghcn-subscribe-bar__button { min-height: 30px; padding: 0 12px; font-size: 12px; }\n.ghcn-subscribe-bar:where([data-size=\"lg\"]) .ghcn-subscribe-bar__row { padding: 5px; }\n.ghcn-subscribe-bar:where([data-size=\"lg\"]) .ghcn-subscribe-bar__input { min-height: 44px; padding: 0 14px; font-size: 15px; }\n.ghcn-subscribe-bar:where([data-size=\"lg\"]) .ghcn-subscribe-bar__button { min-height: 44px; padding: 0 20px; font-size: 14px; }\n.ghcn-subscribe-bar__form.loading .ghcn-subscribe-bar__button { opacity: .65; pointer-events: none; }\n.ghcn-subscribe-bar__status { display: none; align-items: center; gap: 6px; margin: 2px 0 0 4px; font-size: 12px; font-weight: 500; line-height: 1.4; }\n.ghcn-subscribe-bar__form.success .ghcn-subscribe-bar__status--success,\n.ghcn-subscribe-bar__form.error .ghcn-subscribe-bar__status--error { display: inline-flex; }\n.ghcn-subscribe-bar__status--success { color: var(--success, #15803d); }\n.ghcn-subscribe-bar__status--error { color: var(--destructive, #dc2626); }\n@media (max-width: 420px) { .ghcn-subscribe-bar__row { flex-direction: column; padding: 6px; } .ghcn-subscribe-bar__button { width: 100%; } }\n.ghcn-subscribe-bar__button:focus-visible, :where(.ghcn-subscribe-bar__button) :focus-visible { outline: 2px solid var(--ring, currentColor); outline-offset: 2px; }"
|
|
41
|
+
}
|
|
42
|
+
],
|
|
43
|
+
"gscan": {
|
|
44
|
+
"rules_satisfied": [
|
|
45
|
+
"GS010-PJ-VALID",
|
|
46
|
+
"GS050-MEMBERS-FORM"
|
|
47
|
+
],
|
|
48
|
+
"notes": "Uses Ghost native data-members-form and respects portal_signup_checkbox_required."
|
|
49
|
+
},
|
|
50
|
+
"styleSlots": {
|
|
51
|
+
"class": [
|
|
52
|
+
".ghcn-subscribe-bar"
|
|
53
|
+
],
|
|
54
|
+
"inputClass": [
|
|
55
|
+
".ghcn-subscribe-bar__input"
|
|
56
|
+
],
|
|
57
|
+
"buttonClass": [
|
|
58
|
+
".ghcn-subscribe-bar__button"
|
|
59
|
+
]
|
|
60
|
+
}
|
|
61
|
+
}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "switch",
|
|
3
|
+
"type": "components:ui",
|
|
4
|
+
"description": "Accessible zero-JS native toggle switch (role=\"switch\") with default and selectable card styles.",
|
|
5
|
+
"dependencies": [],
|
|
6
|
+
"ghost_version": ">=5.0.0",
|
|
7
|
+
"parameters": {
|
|
8
|
+
"variant": {
|
|
9
|
+
"description": "Presentation: default or card.",
|
|
10
|
+
"options": [
|
|
11
|
+
"default",
|
|
12
|
+
"card"
|
|
13
|
+
],
|
|
14
|
+
"default": "default"
|
|
15
|
+
},
|
|
16
|
+
"size": {
|
|
17
|
+
"description": "Switch scale: sm, default, or lg.",
|
|
18
|
+
"options": [
|
|
19
|
+
"sm",
|
|
20
|
+
"default",
|
|
21
|
+
"lg"
|
|
22
|
+
],
|
|
23
|
+
"default": "default"
|
|
24
|
+
},
|
|
25
|
+
"label": {
|
|
26
|
+
"description": "Primary switch label.",
|
|
27
|
+
"default": "Weekly digest email"
|
|
28
|
+
},
|
|
29
|
+
"description": {
|
|
30
|
+
"description": "Optional muted helper text below the label."
|
|
31
|
+
},
|
|
32
|
+
"name": {
|
|
33
|
+
"description": "Optional native form input name."
|
|
34
|
+
},
|
|
35
|
+
"value": {
|
|
36
|
+
"description": "Optional form value."
|
|
37
|
+
},
|
|
38
|
+
"checked": {
|
|
39
|
+
"description": "Boolean. Checked state."
|
|
40
|
+
},
|
|
41
|
+
"disabled": {
|
|
42
|
+
"description": "Boolean. Disabled state."
|
|
43
|
+
}
|
|
44
|
+
},
|
|
45
|
+
"files": [
|
|
46
|
+
{
|
|
47
|
+
"name": "switch.hbs",
|
|
48
|
+
"type": "partial",
|
|
49
|
+
"target": "partials/components/switch.hbs",
|
|
50
|
+
"content": "{{!-- Styling parameters: class, inputClass, labelClass --}}\n{{#with this as |ghostcnStyles|}}\n<label class=\"ghcn-ui-switch{{#if ghostcnStyles.class}} {{ghostcnStyles.class}}{{/if}}\" data-variant=\"{{#match variant \"card\"}}card{{else}}default{{/match}}\" data-size=\"{{#match size \"sm\"}}sm{{else}}{{#match size \"lg\"}}lg{{else}}default{{/match}}{{/match}}\">\n <span class=\"ghcn-ui-switch__copy\">\n <span class=\"ghcn-ui-switch__label{{#if ghostcnStyles.labelClass}} {{ghostcnStyles.labelClass}}{{/if}}\">{{#if label}}{{label}}{{else}}Weekly digest email{{/if}}</span>\n {{#if description}}<span class=\"ghcn-ui-switch__desc\">{{description}}</span>{{/if}}\n </span>\n <span class=\"ghcn-ui-switch__control\">\n <input\n class=\"ghcn-ui-switch__input{{#if ghostcnStyles.inputClass}} {{ghostcnStyles.inputClass}}{{/if}}\"\n type=\"checkbox\"\n role=\"switch\"\n {{#if name}}name=\"{{name}}\"{{/if}}\n {{#if value}}value=\"{{value}}\"{{/if}}\n {{#if checked}}checked{{/if}}\n {{#if disabled}}disabled{{/if}}\n />\n <span class=\"ghcn-ui-switch__track\" aria-hidden=\"true\"><span class=\"ghcn-ui-switch__thumb\"></span></span>\n </span>\n</label>\n{{/with}}"
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"name": "switch.css",
|
|
54
|
+
"type": "style",
|
|
55
|
+
"target": "assets/css/components/switch.css",
|
|
56
|
+
"content": ".ghcn-ui-switch { box-sizing: border-box; display: flex; align-items: center; justify-content: space-between; gap: 16px; width: 100%; font-family: inherit; font-size: var(--ghcn-text-small, 14px); color: var(--foreground); cursor: pointer; }\n.ghcn-ui-switch *, .ghcn-ui-switch *::before, .ghcn-ui-switch *::after { box-sizing: border-box; }\n.ghcn-ui-switch:where([data-variant=\"card\"]) { box-sizing: border-box; min-width: 0; overflow-wrap: anywhere; border: 1px solid var(--border, #e4e4e7); border-radius: var(--ghcn-panel-radius, min(var(--radius, 8px), 24px)); background: var(--card, #fff); color: var(--card-foreground, #09090b); padding: 14px 16px; transition: border-color 150ms ease, background-color 150ms ease; }\n.ghcn-ui-switch:where([data-variant=\"card\"]):hover { border-color: color-mix(in srgb, var(--foreground) 22%, var(--border)); }\n.ghcn-ui-switch:where([data-variant=\"card\"]):has(input:checked) { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 5%, var(--card)); }\n.ghcn-ui-switch:has(input:disabled) { opacity: .55; cursor: not-allowed; }\n.ghcn-ui-switch__copy { display: grid; gap: 3px; min-width: 0; }\n.ghcn-ui-switch__label { font-weight: 600; line-height: 1.35; color: var(--foreground); }\n.ghcn-ui-switch__desc { font-size: 13px; line-height: 1.45; color: var(--muted-foreground); }\n.ghcn-ui-switch__control { position: relative; flex: 0 0 auto; display: inline-flex; }\n.ghcn-ui-switch__input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: inherit; }\n.ghcn-ui-switch__track { position: relative; display: inline-flex; align-items: center; width: 42px; height: 24px; padding: 2px; border-radius: 9999px; background: var(--input, var(--border)); transition: background-color 160ms ease; }\n.ghcn-ui-switch__thumb { width: 20px; height: 20px; border-radius: 9999px; background: #ffffff; box-shadow: 0 1px 3px rgba(0, 0, 0, .22); transform: translateX(0); transition: transform 160ms ease; }\n.ghcn-ui-switch__input:checked + .ghcn-ui-switch__track { background: var(--primary); }\n.ghcn-ui-switch__input:checked + .ghcn-ui-switch__track .ghcn-ui-switch__thumb { transform: translateX(18px); }\n.ghcn-ui-switch__input:focus-visible + .ghcn-ui-switch__track { outline: 2px solid var(--ring, var(--primary)); outline-offset: 2px; }\n.ghcn-ui-switch:where([data-size=\"sm\"]) .ghcn-ui-switch__track { width: 34px; height: 20px; }\n.ghcn-ui-switch:where([data-size=\"sm\"]) .ghcn-ui-switch__thumb { width: 16px; height: 16px; }\n.ghcn-ui-switch:where([data-size=\"sm\"]) .ghcn-ui-switch__input:checked + .ghcn-ui-switch__track .ghcn-ui-switch__thumb { transform: translateX(14px); }\n.ghcn-ui-switch:where([data-size=\"lg\"]) .ghcn-ui-switch__track { width: 50px; height: 28px; }\n.ghcn-ui-switch:where([data-size=\"lg\"]) .ghcn-ui-switch__thumb { width: 24px; height: 24px; }\n.ghcn-ui-switch:where([data-size=\"lg\"]) .ghcn-ui-switch__input:checked + .ghcn-ui-switch__track .ghcn-ui-switch__thumb { transform: translateX(22px); }\n@media (prefers-reduced-motion: reduce) { .ghcn-ui-switch__track, .ghcn-ui-switch__thumb { transition: none; } }"
|
|
57
|
+
}
|
|
58
|
+
],
|
|
59
|
+
"gscan": {
|
|
60
|
+
"rules_satisfied": [
|
|
61
|
+
"GS010-PJ-VALID"
|
|
62
|
+
],
|
|
63
|
+
"notes": "Zero-JS native checkbox input with role=\"switch\"."
|
|
64
|
+
},
|
|
65
|
+
"styleSlots": {
|
|
66
|
+
"class": [
|
|
67
|
+
".ghcn-ui-switch"
|
|
68
|
+
],
|
|
69
|
+
"inputClass": [
|
|
70
|
+
".ghcn-ui-switch__input"
|
|
71
|
+
],
|
|
72
|
+
"labelClass": [
|
|
73
|
+
".ghcn-ui-switch__label"
|
|
74
|
+
]
|
|
75
|
+
}
|
|
76
|
+
}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "tabs",
|
|
3
|
+
"type": "components:ui",
|
|
4
|
+
"description": "Accessible tabbed panel switcher with underline, pills, and boxed variants plus arrow-key navigation.",
|
|
5
|
+
"dependencies": [],
|
|
6
|
+
"ghost_version": ">=5.0.0",
|
|
7
|
+
"parameters": {
|
|
8
|
+
"variant": {
|
|
9
|
+
"description": "Tab bar treatment (underline default, pills, or boxed).",
|
|
10
|
+
"options": [
|
|
11
|
+
"default",
|
|
12
|
+
"pills",
|
|
13
|
+
"boxed"
|
|
14
|
+
],
|
|
15
|
+
"default": "default"
|
|
16
|
+
},
|
|
17
|
+
"ariaLabel": {
|
|
18
|
+
"description": "Accessible label for the tablist.",
|
|
19
|
+
"default": "Content tabs"
|
|
20
|
+
},
|
|
21
|
+
"tab1Label": {
|
|
22
|
+
"description": "First tab label.",
|
|
23
|
+
"default": "Overview"
|
|
24
|
+
},
|
|
25
|
+
"tab1Body": {
|
|
26
|
+
"description": "First tab escaped text body."
|
|
27
|
+
},
|
|
28
|
+
"tab2Label": {
|
|
29
|
+
"description": "Optional second tab label."
|
|
30
|
+
},
|
|
31
|
+
"tab2Body": {
|
|
32
|
+
"description": "Second tab escaped text body."
|
|
33
|
+
},
|
|
34
|
+
"tab3Label": {
|
|
35
|
+
"description": "Optional third tab label."
|
|
36
|
+
},
|
|
37
|
+
"tab3Body": {
|
|
38
|
+
"description": "Third tab escaped text body."
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
"files": [
|
|
42
|
+
{
|
|
43
|
+
"name": "tabs.hbs",
|
|
44
|
+
"type": "partial",
|
|
45
|
+
"target": "partials/components/tabs.hbs",
|
|
46
|
+
"content": "{{!-- Styling parameters: class, listClass, triggerClass, panelClass --}}\n{{#with this as |ghostcnStyles|}}\n<div class=\"ghcn-tabs{{#if ghostcnStyles.class}} {{ghostcnStyles.class}}{{/if}}\" data-ghcn-tabs data-variant=\"{{#match variant \"pills\"}}pills{{else}}{{#match variant \"boxed\"}}boxed{{else}}default{{/match}}{{/match}}\">\n <div class=\"ghcn-tabs__list{{#if ghostcnStyles.listClass}} {{ghostcnStyles.listClass}}{{/if}}\" role=\"tablist\" aria-label=\"{{#if ariaLabel}}{{ariaLabel}}{{else}}Content tabs{{/if}}\">\n <button type=\"button\" class=\"ghcn-tabs__trigger{{#if ghostcnStyles.triggerClass}} {{ghostcnStyles.triggerClass}}{{/if}}\" role=\"tab\" data-tab-trigger aria-selected=\"true\" tabindex=\"0\">{{#if tab1Label}}{{tab1Label}}{{else}}Overview{{/if}}</button>\n {{#if tab2Label}}<button type=\"button\" class=\"ghcn-tabs__trigger{{#if ghostcnStyles.triggerClass}} {{ghostcnStyles.triggerClass}}{{/if}}\" role=\"tab\" data-tab-trigger aria-selected=\"false\" tabindex=\"-1\">{{tab2Label}}</button>{{/if}}\n {{#if tab3Label}}<button type=\"button\" class=\"ghcn-tabs__trigger{{#if ghostcnStyles.triggerClass}} {{ghostcnStyles.triggerClass}}{{/if}}\" role=\"tab\" data-tab-trigger aria-selected=\"false\" tabindex=\"-1\">{{tab3Label}}</button>{{/if}}\n </div>\n <div class=\"ghcn-tabs__panel{{#if ghostcnStyles.panelClass}} {{ghostcnStyles.panelClass}}{{/if}}\" role=\"tabpanel\" data-tab-panel>\n {{#> @partial-block}}{{#if tab1Body}}<p>{{tab1Body}}</p>{{else}}<p>Use tabs to organize related content without cluttering the page.</p>{{/if}}{{/@partial-block}}\n </div>\n {{#if tab2Label}}\n <div class=\"ghcn-tabs__panel{{#if ghostcnStyles.panelClass}} {{ghostcnStyles.panelClass}}{{/if}}\" role=\"tabpanel\" data-tab-panel hidden>\n {{#if tab2Body}}<p>{{tab2Body}}</p>{{/if}}\n </div>\n {{/if}}\n {{#if tab3Label}}\n <div class=\"ghcn-tabs__panel{{#if ghostcnStyles.panelClass}} {{ghostcnStyles.panelClass}}{{/if}}\" role=\"tabpanel\" data-tab-panel hidden>\n {{#if tab3Body}}<p>{{tab3Body}}</p>{{/if}}\n </div>\n {{/if}}\n</div>\n{{/with}}"
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
"name": "tabs.css",
|
|
50
|
+
"type": "style",
|
|
51
|
+
"target": "assets/css/components/tabs.css",
|
|
52
|
+
"content": ".ghcn-tabs { box-sizing: border-box; font-family: inherit; font-size: var(--ghcn-text-body, 16px); line-height: 1.5; color: var(--foreground); }\n.ghcn-tabs *, .ghcn-tabs *::before, .ghcn-tabs *::after { box-sizing: border-box; }\n.ghcn-tabs:focus-visible, :where(.ghcn-tabs) :focus-visible { outline: 2px solid var(--ring, currentColor); outline-offset: 2px; }\n.ghcn-tabs { width: 100%; }\n.ghcn-tabs__list { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; border-bottom: 1px solid var(--border); }\n.ghcn-tabs:where([data-variant=\"pills\"]) .ghcn-tabs__list { border-bottom: 0; gap: 6px; }\n.ghcn-tabs:where([data-variant=\"boxed\"]) .ghcn-tabs__list { display: inline-flex; border-bottom: 0; padding: 4px; border: 1px solid var(--border); border-radius: var(--ghcn-control-radius, var(--radius, 8px)); background: var(--secondary); }\n.ghcn-tabs__trigger { position: relative; padding: 9px 14px; border: 1px solid transparent; border-bottom: 2px solid transparent; margin-bottom: -1px; background: transparent; color: var(--muted-foreground); font: inherit; font-size: var(--ghcn-text-small, 14px); font-weight: 600; cursor: pointer; transition: color 150ms ease, background-color 150ms ease, border-color 150ms ease; }\n.ghcn-tabs__trigger:hover { color: var(--foreground); }\n.ghcn-tabs__trigger[aria-selected=\"true\"] { color: var(--foreground); border-bottom-color: var(--primary); }\n.ghcn-tabs:where([data-variant=\"pills\"]) .ghcn-tabs__trigger { margin-bottom: 0; padding: 6px 13px; border-radius: 9999px; border: 1px solid transparent; }\n.ghcn-tabs:where([data-variant=\"pills\"]) .ghcn-tabs__trigger[aria-selected=\"true\"] { background: var(--primary); color: var(--primary-foreground); border-color: transparent; }\n.ghcn-tabs:where([data-variant=\"boxed\"]) .ghcn-tabs__trigger { margin-bottom: 0; padding: 6px 13px; border-radius: calc(var(--ghcn-control-radius, var(--radius, 8px)) - 2px); border: 1px solid transparent; }\n.ghcn-tabs:where([data-variant=\"boxed\"]) .ghcn-tabs__trigger[aria-selected=\"true\"] { background: var(--background); color: var(--foreground); border-color: var(--border); box-shadow: 0 1px 2px #0001; }\n.ghcn-tabs__panel { padding-top: 16px; color: var(--muted-foreground); font-size: var(--ghcn-text-small, 14px); }\n.ghcn-tabs__panel[hidden] { display: none; }\n.ghcn-tabs__panel > :first-child { margin-top: 0; }\n.ghcn-tabs__panel > :last-child { margin-bottom: 0; }\n@media (prefers-reduced-motion: reduce) { .ghcn-tabs__trigger { transition: none; } }\n"
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
"name": "tabs.js",
|
|
56
|
+
"type": "js",
|
|
57
|
+
"target": "assets/js/components/tabs.js",
|
|
58
|
+
"content": "/* ghostcn tabs: accessible WAI-ARIA tablist with arrow-key navigation and zero-JS fallback. */\n(() => {\n function init() {\n document.querySelectorAll('[data-ghcn-tabs]').forEach(root => {\n if (root.dataset.ghcnTabsReady) return;\n const buttons = [...root.querySelectorAll('[data-tab-trigger]')];\n const panels = [...root.querySelectorAll('[data-tab-panel]')];\n if (!buttons.length || !panels.length) return;\n root.dataset.ghcnTabsReady = 'true';\n const activate = (index, focus) => {\n const idx = ((index % buttons.length) + buttons.length) % buttons.length;\n buttons.forEach((btn, i) => {\n const active = i === idx;\n btn.setAttribute('aria-selected', String(active));\n btn.tabIndex = active ? 0 : -1;\n if (active && focus) btn.focus();\n });\n panels.forEach((panel, i) => { panel.hidden = i !== idx; });\n };\n buttons.forEach((btn, index) => {\n btn.addEventListener('click', () => activate(index, false));\n btn.addEventListener('keydown', event => {\n if (event.key === 'ArrowRight') { event.preventDefault(); activate(index + 1, true); }\n else if (event.key === 'ArrowLeft') { event.preventDefault(); activate(index - 1, true); }\n else if (event.key === 'Home') { event.preventDefault(); activate(0, true); }\n else if (event.key === 'End') { event.preventDefault(); activate(buttons.length - 1, true); }\n });\n });\n activate(0, false);\n });\n }\n if (document.readyState === 'loading') document.addEventListener('DOMContentLoaded', init, { once: true });\n else init();\n})();"
|
|
59
|
+
}
|
|
60
|
+
],
|
|
61
|
+
"gscan": {
|
|
62
|
+
"rules_satisfied": [
|
|
63
|
+
"GS010-PJ-VALID"
|
|
64
|
+
],
|
|
65
|
+
"notes": "Self-contained Ghostcn UI primitive."
|
|
66
|
+
},
|
|
67
|
+
"styleSlots": {
|
|
68
|
+
"class": [
|
|
69
|
+
".ghcn-tabs"
|
|
70
|
+
],
|
|
71
|
+
"listClass": [
|
|
72
|
+
".ghcn-tabs__list"
|
|
73
|
+
],
|
|
74
|
+
"triggerClass": [
|
|
75
|
+
".ghcn-tabs__trigger"
|
|
76
|
+
],
|
|
77
|
+
"panelClass": [
|
|
78
|
+
".ghcn-tabs__panel"
|
|
79
|
+
]
|
|
80
|
+
}
|
|
81
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "tag-bar",
|
|
3
|
+
"type": "components:content",
|
|
4
|
+
"description": "Horizontal snap-scrolling topic bar populated from public Ghost tags for quick category browsing.",
|
|
5
|
+
"dependencies": [],
|
|
6
|
+
"ghost_version": ">=5.0.0",
|
|
7
|
+
"parameters": {
|
|
8
|
+
"variant": {
|
|
9
|
+
"description": "Bar style: default, outline, or underline.",
|
|
10
|
+
"options": [
|
|
11
|
+
"default",
|
|
12
|
+
"outline",
|
|
13
|
+
"underline"
|
|
14
|
+
],
|
|
15
|
+
"default": "default"
|
|
16
|
+
},
|
|
17
|
+
"allLabel": {
|
|
18
|
+
"description": "Label for the leading \"All stories\" link.",
|
|
19
|
+
"default": "All stories"
|
|
20
|
+
},
|
|
21
|
+
"hideAll": {
|
|
22
|
+
"description": "Hide the leading \"All stories\" link when true."
|
|
23
|
+
},
|
|
24
|
+
"showCounts": {
|
|
25
|
+
"description": "Display post counts next to each tag when true."
|
|
26
|
+
},
|
|
27
|
+
"ariaLabel": {
|
|
28
|
+
"description": "Accessible navigation label.",
|
|
29
|
+
"default": "Browse topics"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
"files": [
|
|
33
|
+
{
|
|
34
|
+
"name": "tag-bar.hbs",
|
|
35
|
+
"type": "partial",
|
|
36
|
+
"target": "partials/components/tag-bar.hbs",
|
|
37
|
+
"content": "{{!-- Styling parameters: class, listClass, linkClass --}}\n{{#with this as |ghostcnStyles|}}\n{{#get \"tags\" filter=\"visibility:public\" limit=\"20\" include=\"count.posts\"}}\n{{#if tags}}\n<nav class=\"ghcn-tag-bar{{#if ghostcnStyles.class}} {{ghostcnStyles.class}}{{/if}}\" data-variant=\"{{#match ghostcnStyles.variant \"outline\"}}outline{{else}}{{#match ghostcnStyles.variant \"underline\"}}underline{{else}}default{{/match}}{{/match}}\" aria-label=\"{{#if ghostcnStyles.ariaLabel}}{{ghostcnStyles.ariaLabel}}{{else}}Browse topics{{/if}}\">\n <ul class=\"ghcn-tag-bar__list{{#if ghostcnStyles.listClass}} {{ghostcnStyles.listClass}}{{/if}}\" role=\"list\">\n {{#unless ghostcnStyles.hideAll}}\n <li class=\"ghcn-tag-bar__item\">\n <a class=\"ghcn-tag-bar__link{{#if ghostcnStyles.linkClass}} {{ghostcnStyles.linkClass}}{{/if}} ghcn-tag-bar__link--all\" href=\"{{@site.url}}\">{{#if ghostcnStyles.allLabel}}{{ghostcnStyles.allLabel}}{{else}}All stories{{/if}}</a>\n </li>\n {{/unless}}\n {{#foreach tags visibility=\"public\"}}\n <li class=\"ghcn-tag-bar__item\">\n <a class=\"ghcn-tag-bar__link{{#if ghostcnStyles.linkClass}} {{ghostcnStyles.linkClass}}{{/if}}\" href=\"{{url}}\">\n <span>{{name}}</span>\n {{#if ghostcnStyles.showCounts}}{{#if count.posts}}<span class=\"ghcn-tag-bar__count\">{{count.posts}}</span>{{/if}}{{/if}}\n </a>\n </li>\n {{/foreach}}\n </ul>\n</nav>\n{{/if}}\n{{/get}}\n{{/with}}"
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"name": "tag-bar.css",
|
|
41
|
+
"type": "style",
|
|
42
|
+
"target": "assets/css/components/tag-bar.css",
|
|
43
|
+
"content": ".ghcn-tag-bar { box-sizing: border-box; min-width: 0; margin-block: var(--ghcn-section-space, clamp(24px, 4vw, 48px)); font-family: inherit; font-size: var(--ghcn-text-body, 16px); line-height: 1.5; color: var(--foreground); width: min(100% - 32px, 1152px); margin-inline: auto; margin-block: 16px; }\n.ghcn-tag-bar *, .ghcn-tag-bar *::before, .ghcn-tag-bar *::after { box-sizing: border-box; }\n.ghcn-tag-bar__list { display: flex; align-items: center; gap: 8px; margin: 0; padding: 4px 2px; list-style: none; overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none; -webkit-overflow-scrolling: touch; }\n.ghcn-tag-bar__list::-webkit-scrollbar { display: none; }\n.ghcn-tag-bar__item { flex: 0 0 auto; scroll-snap-align: start; }\n.ghcn-tag-bar__link { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 14px; border: 1px solid transparent; border-radius: 9999px; background: var(--secondary); color: var(--secondary-foreground); font-size: 13.5px; font-weight: 500; line-height: 1; text-decoration: none; white-space: nowrap; transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease; }\n.ghcn-tag-bar__link:hover { background: var(--primary); color: var(--primary-foreground); }\n.ghcn-tag-bar__link--all { background: var(--primary); color: var(--primary-foreground); font-weight: 600; }\n.ghcn-tag-bar__link--all:hover { opacity: .9; }\n.ghcn-tag-bar__count { font-size: 11.5px; opacity: .72; font-variant-numeric: tabular-nums; }\n.ghcn-tag-bar:where([data-variant=\"outline\"]) .ghcn-tag-bar__link { background: var(--card, var(--background)); border-color: var(--border); color: var(--muted-foreground); }\n.ghcn-tag-bar:where([data-variant=\"outline\"]) .ghcn-tag-bar__link:hover { border-color: var(--foreground); color: var(--foreground); background: var(--secondary); }\n.ghcn-tag-bar:where([data-variant=\"outline\"]) .ghcn-tag-bar__link--all { border-color: var(--foreground); background: var(--foreground); color: var(--background); }\n.ghcn-tag-bar:where([data-variant=\"underline\"]) .ghcn-tag-bar__list { gap: 4px; padding: 0; border-bottom: 1px solid var(--border); }\n.ghcn-tag-bar:where([data-variant=\"underline\"]) .ghcn-tag-bar__link { min-height: 40px; padding: 0 12px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: transparent; color: var(--muted-foreground); margin-bottom: -1px; }\n.ghcn-tag-bar:where([data-variant=\"underline\"]) .ghcn-tag-bar__link:hover { color: var(--foreground); border-bottom-color: var(--border); background: transparent; }\n.ghcn-tag-bar:where([data-variant=\"underline\"]) .ghcn-tag-bar__link--all { color: var(--foreground); border-bottom-color: var(--primary); background: transparent; }\n.ghcn-tag-bar:focus-visible, :where(.ghcn-tag-bar) :focus-visible { outline: 2px solid var(--ring, currentColor); outline-offset: 2px; }"
|
|
44
|
+
}
|
|
45
|
+
],
|
|
46
|
+
"gscan": {
|
|
47
|
+
"rules_satisfied": [
|
|
48
|
+
"GS010-PJ-VALID"
|
|
49
|
+
],
|
|
50
|
+
"notes": "Uses Ghost native #get tags helper with public visibility filtering."
|
|
51
|
+
},
|
|
52
|
+
"styleSlots": {
|
|
53
|
+
"class": [
|
|
54
|
+
".ghcn-tag-bar"
|
|
55
|
+
],
|
|
56
|
+
"listClass": [
|
|
57
|
+
".ghcn-tag-bar__list"
|
|
58
|
+
],
|
|
59
|
+
"linkClass": [
|
|
60
|
+
".ghcn-tag-bar__link"
|
|
61
|
+
]
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "textarea",
|
|
3
|
+
"type": "components:ui",
|
|
4
|
+
"description": "Accessible labeled multiline textarea with optional hint, invalid, and disabled states.",
|
|
5
|
+
"dependencies": [],
|
|
6
|
+
"ghost_version": ">=5.0.0",
|
|
7
|
+
"parameters": {
|
|
8
|
+
"variant": {
|
|
9
|
+
"description": "Field surface style.",
|
|
10
|
+
"options": [
|
|
11
|
+
"default",
|
|
12
|
+
"filled"
|
|
13
|
+
],
|
|
14
|
+
"default": "default"
|
|
15
|
+
},
|
|
16
|
+
"size": {
|
|
17
|
+
"description": "Field scale.",
|
|
18
|
+
"options": [
|
|
19
|
+
"sm",
|
|
20
|
+
"default",
|
|
21
|
+
"lg"
|
|
22
|
+
],
|
|
23
|
+
"default": "default"
|
|
24
|
+
},
|
|
25
|
+
"label": {
|
|
26
|
+
"description": "Visible accessible label.",
|
|
27
|
+
"default": "Message"
|
|
28
|
+
},
|
|
29
|
+
"name": {
|
|
30
|
+
"description": "Form field name."
|
|
31
|
+
},
|
|
32
|
+
"id": {
|
|
33
|
+
"description": "Optional unique ID."
|
|
34
|
+
},
|
|
35
|
+
"rows": {
|
|
36
|
+
"description": "Initial visible text rows.",
|
|
37
|
+
"default": "4"
|
|
38
|
+
},
|
|
39
|
+
"value": {
|
|
40
|
+
"description": "Initial value."
|
|
41
|
+
},
|
|
42
|
+
"placeholder": {
|
|
43
|
+
"description": "Optional placeholder."
|
|
44
|
+
},
|
|
45
|
+
"hint": {
|
|
46
|
+
"description": "Optional help text."
|
|
47
|
+
},
|
|
48
|
+
"hintId": {
|
|
49
|
+
"description": "Unique ID for help text."
|
|
50
|
+
},
|
|
51
|
+
"invalid": {
|
|
52
|
+
"description": "Boolean invalid state."
|
|
53
|
+
},
|
|
54
|
+
"required": {
|
|
55
|
+
"description": "Boolean required state."
|
|
56
|
+
},
|
|
57
|
+
"disabled": {
|
|
58
|
+
"description": "Boolean disabled state."
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
"files": [
|
|
62
|
+
{
|
|
63
|
+
"name": "textarea.hbs",
|
|
64
|
+
"type": "partial",
|
|
65
|
+
"target": "partials/components/textarea.hbs",
|
|
66
|
+
"content": "{{!-- Styling parameters: class, labelClass, inputClass, descriptionClass --}}\n{{#with this as |ghostcnStyles|}}\n<div class=\"ghcn-ui-textarea{{#if ghostcnStyles.class}} {{ghostcnStyles.class}}{{/if}}\" data-variant=\"{{#match variant \"filled\"}}filled{{else}}default{{/match}}\" data-size=\"{{#match size \"sm\"}}sm{{else}}{{#match size \"lg\"}}lg{{else}}default{{/match}}{{/match}}\">\n <label class=\"ghcn-ui-textarea__label\">\n <span class=\"ghcn-ui-textarea__label-text{{#if ghostcnStyles.labelClass}} {{ghostcnStyles.labelClass}}{{/if}}\">{{#if label}}{{label}}{{else}}Message{{/if}}{{#if required}} (required){{/if}}</span>\n <textarea class=\"ghcn-ui-textarea__control{{#if ghostcnStyles.inputClass}} {{ghostcnStyles.inputClass}}{{/if}}\" rows=\"{{#if rows}}{{rows}}{{else}}4{{/if}}\"{{#if id}} id=\"{{id}}\"{{/if}}{{#if name}} name=\"{{name}}\"{{/if}}{{#if placeholder}} placeholder=\"{{placeholder}}\"{{/if}}{{#if required}} required{{/if}}{{#if disabled}} disabled{{/if}}{{#if invalid}} aria-invalid=\"true\"{{/if}}{{#if hint}}{{#if hintId}} aria-describedby=\"{{hintId}}\"{{/if}}{{/if}}>{{value}}</textarea>\n </label>\n {{#if hint}}<p class=\"ghcn-ui-textarea__hint{{#if ghostcnStyles.descriptionClass}} {{ghostcnStyles.descriptionClass}}{{/if}}\"{{#if hintId}} id=\"{{hintId}}\"{{/if}}>{{hint}}</p>{{/if}}\n</div>\n{{/with}}"
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
"name": "textarea.css",
|
|
70
|
+
"type": "style",
|
|
71
|
+
"target": "assets/css/components/textarea.css",
|
|
72
|
+
"content": ".ghcn-ui-textarea { box-sizing: border-box; font-family: inherit; font-size: var(--ghcn-text-body, 16px); line-height: 1.5; color: var(--foreground); }\n.ghcn-ui-textarea *, .ghcn-ui-textarea *::before, .ghcn-ui-textarea *::after { box-sizing: border-box; }\n.ghcn-ui-textarea:focus-visible, :where(.ghcn-ui-textarea) :focus-visible { outline: 2px solid var(--ring, currentColor); outline-offset: 2px; }\n.ghcn-ui-textarea { width: 100%; }\n.ghcn-ui-textarea__label { display: grid; gap: 6px; font-weight: 500; font-size: var(--ghcn-text-small, 14px); }\n.ghcn-ui-textarea__control { min-height: var(--ghcn-control-height, 40px); padding: var(--ghcn-control-padding, 8px 14px); border-radius: var(--ghcn-control-radius, var(--radius, 8px)); font-size: var(--ghcn-text-small, 14px); line-height: 1.4; width: 100%; min-width: 0; border: 1px solid var(--input); background: var(--background); color: var(--foreground); font-family: inherit; resize: vertical; transition: border-color 150ms ease, background-color 150ms ease; }\n.ghcn-ui-textarea:where([data-size=\"sm\"]) .ghcn-ui-textarea__control { padding: 7px 11px; font-size: 13px; }\n.ghcn-ui-textarea:where([data-size=\"lg\"]) .ghcn-ui-textarea__control { padding: 12px 16px; font-size: 16px; }\n.ghcn-ui-textarea:where([data-variant=\"filled\"]) .ghcn-ui-textarea__control { background: var(--muted); }\n.ghcn-ui-textarea__control::placeholder { color: var(--muted-foreground); }\n.ghcn-ui-textarea__control[aria-invalid=\"true\"] { border-color: var(--destructive); }\n.ghcn-ui-textarea__control:disabled { opacity: .5; cursor: not-allowed; }\n.ghcn-ui-textarea__hint { color: var(--muted-foreground); font-size: 13px; margin: 6px 0 0; }\n@media (prefers-reduced-motion: reduce) { .ghcn-ui-textarea__control { transition: none; } }\n"
|
|
73
|
+
}
|
|
74
|
+
],
|
|
75
|
+
"gscan": {
|
|
76
|
+
"rules_satisfied": [
|
|
77
|
+
"GS010-PJ-VALID"
|
|
78
|
+
],
|
|
79
|
+
"notes": "Self-contained Ghostcn UI primitive."
|
|
80
|
+
},
|
|
81
|
+
"styleSlots": {
|
|
82
|
+
"class": [
|
|
83
|
+
".ghcn-ui-textarea"
|
|
84
|
+
],
|
|
85
|
+
"labelClass": [
|
|
86
|
+
".ghcn-ui-textarea__label-text"
|
|
87
|
+
],
|
|
88
|
+
"inputClass": [
|
|
89
|
+
".ghcn-ui-textarea__control"
|
|
90
|
+
],
|
|
91
|
+
"descriptionClass": [
|
|
92
|
+
".ghcn-ui-textarea__hint"
|
|
93
|
+
]
|
|
94
|
+
}
|
|
95
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "tier-comparison",
|
|
3
|
+
"type": "components:members",
|
|
4
|
+
"description": "Responsive Ghost membership tier comparison matrix displaying live monthly/yearly prices, benefits, and Portal CTAs.",
|
|
5
|
+
"dependencies": [],
|
|
6
|
+
"ghost_version": ">=5.0.0",
|
|
7
|
+
"parameters": {
|
|
8
|
+
"variant": {
|
|
9
|
+
"description": "Table style: default, striped, or bordered.",
|
|
10
|
+
"default": "default"
|
|
11
|
+
},
|
|
12
|
+
"heading": {
|
|
13
|
+
"description": "Section heading text.",
|
|
14
|
+
"default": "Compare membership plans"
|
|
15
|
+
},
|
|
16
|
+
"description": {
|
|
17
|
+
"description": "Optional subheading description."
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"files": [
|
|
21
|
+
{
|
|
22
|
+
"name": "tier-comparison.hbs",
|
|
23
|
+
"type": "partial",
|
|
24
|
+
"target": "partials/components/tier-comparison.hbs",
|
|
25
|
+
"content": "{{!-- Styling parameters: class, titleClass, tableClass, buttonClass --}}\n{{#with this as |ghostcnStyles|}}\n{{#if @site.members_enabled}}\n{{#unless @site.members_invite_only}}\n{{#if @site.allow_self_signup}}\n{{#get \"tiers\" filter=\"visibility:public+active:true\" include=\"monthly_price,yearly_price,benefits\"}}\n{{#if tiers}}\n<section class=\"ghcn-tier-compare{{#if ghostcnStyles.class}} {{ghostcnStyles.class}}{{/if}}\" data-variant=\"{{#match ghostcnStyles.variant \"striped\"}}striped{{else}}{{#match ghostcnStyles.variant \"bordered\"}}bordered{{else}}default{{/match}}{{/match}}\">\n <header class=\"ghcn-tier-compare__header\">\n <h2 class=\"ghcn-tier-compare__title{{#if ghostcnStyles.titleClass}} {{ghostcnStyles.titleClass}}{{/if}}\">{{#if ghostcnStyles.heading}}{{ghostcnStyles.heading}}{{else}}Compare membership plans{{/if}}</h2>\n {{#if ghostcnStyles.description}}<p class=\"ghcn-tier-compare__desc\">{{ghostcnStyles.description}}</p>{{/if}}\n </header>\n <div class=\"ghcn-tier-compare__scroll\" role=\"region\" aria-label=\"{{#if ghostcnStyles.heading}}{{ghostcnStyles.heading}}{{else}}Compare membership plans{{/if}}\" tabindex=\"0\">\n <table class=\"ghcn-tier-compare__table{{#if ghostcnStyles.tableClass}} {{ghostcnStyles.tableClass}}{{/if}}\">\n <thead>\n <tr>\n <th scope=\"col\">Plan</th>\n <th scope=\"col\">Monthly</th>\n <th scope=\"col\">Yearly</th>\n <th scope=\"col\">Included</th>\n <th scope=\"col\"><span class=\"ghcn-sr-only\">Action</span></th>\n </tr>\n </thead>\n <tbody>\n {{#foreach tiers}}\n <tr class=\"ghcn-tier-compare__row{{#match type \"paid\"}} is-paid{{/match}}\">\n <th scope=\"row\" class=\"ghcn-tier-compare__plan\">\n <div class=\"ghcn-tier-compare__plan-head\">\n <span class=\"ghcn-tier-compare__name\">{{name}}</span>\n <span class=\"ghcn-tier-compare__badge\">{{#match type \"free\"}}Free{{else}}Paid{{/match}}</span>\n </div>\n {{#if description}}<p class=\"ghcn-tier-compare__plan-desc\">{{description}}</p>{{/if}}\n </th>\n <td class=\"ghcn-tier-compare__price\" data-label=\"Monthly\">\n {{#match type \"free\"}}\n <span class=\"ghcn-tier-compare__amount\">$0</span><span class=\"ghcn-tier-compare__period\">/mo</span>\n {{else}}\n {{#if monthly_price}}\n <span class=\"ghcn-tier-compare__amount\">{{price monthly_price currency=currency}}</span><span class=\"ghcn-tier-compare__period\">/mo</span>\n {{else}}—{{/if}}\n {{/match}}\n </td>\n <td class=\"ghcn-tier-compare__price\" data-label=\"Yearly\">\n {{#match type \"free\"}}\n <span class=\"ghcn-tier-compare__amount\">$0</span><span class=\"ghcn-tier-compare__period\">/yr</span>\n {{else}}\n {{#if yearly_price}}\n <span class=\"ghcn-tier-compare__amount\">{{price yearly_price currency=currency}}</span><span class=\"ghcn-tier-compare__period\">/yr</span>\n {{else}}—{{/if}}\n {{/match}}\n </td>\n <td class=\"ghcn-tier-compare__benefits\" data-label=\"Included\">\n {{#if benefits}}\n <ul class=\"ghcn-tier-compare__list\">\n {{#foreach benefits}}\n <li><svg class=\"ghcn-tier-compare__check\" aria-hidden=\"true\" viewBox=\"0 0 16 16\" width=\"14\" height=\"14\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M3 8.5 6.5 12 13 4\"/></svg><span>{{this}}</span></li>\n {{/foreach}}\n </ul>\n {{else}}—{{/if}}\n </td>\n <td class=\"ghcn-tier-compare__action\">\n {{#match type \"free\"}}\n {{#if @member}}\n <a class=\"ghcn-tier-compare__cta{{#if ghostcnStyles.buttonClass}} {{ghostcnStyles.buttonClass}}{{/if}} ghcn-tier-compare__cta--secondary\" href=\"#/portal/account\" data-portal=\"account\">Manage</a>\n {{else}}\n <a class=\"ghcn-tier-compare__cta{{#if ghostcnStyles.buttonClass}} {{ghostcnStyles.buttonClass}}{{/if}} ghcn-tier-compare__cta--secondary\" href=\"#/portal/signup\" data-portal=\"signup\">Join free</a>\n {{/if}}\n {{else}}\n {{#if @member.paid}}\n <a class=\"ghcn-tier-compare__cta{{#if ghostcnStyles.buttonClass}} {{ghostcnStyles.buttonClass}}{{/if}}\" href=\"#/portal/account/plans\" data-portal=\"account/plans\">Manage plan</a>\n {{else}}\n <a class=\"ghcn-tier-compare__cta{{#if ghostcnStyles.buttonClass}} {{ghostcnStyles.buttonClass}}{{/if}}\" href=\"#/portal/signup/{{id}}/monthly\" data-portal=\"signup/{{id}}/monthly\">Choose {{name}}</a>\n {{/if}}\n {{/match}}\n </td>\n </tr>\n {{/foreach}}\n </tbody>\n </table>\n </div>\n</section>\n{{/if}}\n{{/get}}\n{{/if}}\n{{/unless}}\n{{/if}}\n{{/with}}"
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
"name": "tier-comparison.css",
|
|
29
|
+
"type": "style",
|
|
30
|
+
"target": "assets/css/components/tier-comparison.css",
|
|
31
|
+
"content": ".ghcn-tier-compare { box-sizing: border-box; min-width: 0; margin-block: var(--ghcn-section-space, clamp(24px, 4vw, 48px)); font-family: inherit; font-size: var(--ghcn-text-body, 16px); line-height: 1.5; color: var(--foreground); width: min(100% - 32px, 1152px); margin-inline: auto; }\n.ghcn-tier-compare *, .ghcn-tier-compare *::before, .ghcn-tier-compare *::after { box-sizing: border-box; }\n.ghcn-tier-compare .ghcn-sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }\n.ghcn-tier-compare__header { display: grid; gap: 6px; margin-bottom: 18px; }\n.ghcn-tier-compare__title { font-size: var(--ghcn-title-section, clamp(24px, 3vw, 32px)); font-weight: 700; line-height: 1.18; letter-spacing: -.035em; text-wrap: balance; margin: 0; }\n.ghcn-tier-compare__desc { margin: 0; max-width: 60ch; color: var(--muted-foreground); font-size: var(--ghcn-text-small, 14px); line-height: 1.55; }\n.ghcn-tier-compare__scroll { box-sizing: border-box; min-width: 0; overflow-wrap: anywhere; border: 1px solid var(--border, #e4e4e7); border-radius: var(--ghcn-panel-radius, min(var(--radius, 8px), 24px)); background: var(--card, #fff); color: var(--card-foreground, #09090b); overflow-x: auto; box-shadow: 0 1px 2px rgba(0, 0, 0, .04); }\n.ghcn-tier-compare__table { width: 100%; border-collapse: collapse; text-align: left; font-size: 14px; }\n.ghcn-tier-compare__table thead th { padding: 13px 18px; border-bottom: 1px solid var(--border); background: var(--secondary); color: var(--muted-foreground); font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; white-space: nowrap; }\n.ghcn-tier-compare__table tbody th,\n.ghcn-tier-compare__table tbody td { padding: 18px; vertical-align: top; border-bottom: 1px solid var(--border); }\n.ghcn-tier-compare__table tbody tr:last-child th,\n.ghcn-tier-compare__table tbody tr:last-child td { border-bottom: 0; }\n.ghcn-tier-compare:where([data-variant=\"striped\"]) .ghcn-tier-compare__table tbody tr:nth-child(even) { background: color-mix(in srgb, var(--secondary) 55%, transparent); }\n.ghcn-tier-compare:where([data-variant=\"bordered\"]) .ghcn-tier-compare__table th,\n.ghcn-tier-compare:where([data-variant=\"bordered\"]) .ghcn-tier-compare__table td { border-right: 1px solid var(--border); }\n.ghcn-tier-compare:where([data-variant=\"bordered\"]) .ghcn-tier-compare__table th:last-child,\n.ghcn-tier-compare:where([data-variant=\"bordered\"]) .ghcn-tier-compare__table td:last-child { border-right: 0; }\n.ghcn-tier-compare__plan { min-width: 190px; font-weight: 400; }\n.ghcn-tier-compare__plan-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }\n.ghcn-tier-compare__name { font-size: 16px; font-weight: 700; letter-spacing: -.02em; color: var(--foreground); }\n.ghcn-tier-compare__badge { display: inline-flex; align-items: center; padding: 2px 8px; border-radius: 9999px; background: var(--secondary); color: var(--muted-foreground); font-size: 11px; font-weight: 600; }\n.ghcn-tier-compare__row.is-paid .ghcn-tier-compare__badge { background: color-mix(in srgb, var(--primary) 12%, var(--background)); color: var(--primary); }\n.ghcn-tier-compare__plan-desc { margin: 5px 0 0; color: var(--muted-foreground); font-size: 13px; line-height: 1.5; }\n.ghcn-tier-compare__price { white-space: nowrap; }\n.ghcn-tier-compare__amount { font-size: 18px; font-weight: 700; letter-spacing: -.025em; color: var(--foreground); }\n.ghcn-tier-compare__period { margin-left: 2px; font-size: 12px; color: var(--muted-foreground); }\n.ghcn-tier-compare__benefits { min-width: 220px; }\n.ghcn-tier-compare__list { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; font-size: 13.5px; color: var(--foreground); }\n.ghcn-tier-compare__list li { display: flex; align-items: flex-start; gap: 7px; line-height: 1.4; }\n.ghcn-tier-compare__check { flex: 0 0 auto; margin-top: 2px; color: var(--primary); }\n.ghcn-tier-compare__action { white-space: nowrap; text-align: right; }\n.ghcn-tier-compare__cta { display: inline-flex; align-items: center; justify-content: center; min-height: 36px; padding: 0 15px; border: 1px solid transparent; border-radius: var(--ghcn-control-radius, var(--radius, 8px)); background: var(--primary); color: var(--primary-foreground); font: inherit; font-size: 13px; font-weight: 600; text-decoration: none; transition: opacity 150ms ease, background-color 150ms ease; }\n.ghcn-tier-compare__cta:hover { opacity: .9; }\n.ghcn-tier-compare__cta--secondary { background: var(--secondary); color: var(--secondary-foreground); border-color: var(--border); }\n.ghcn-tier-compare__cta--secondary:hover { opacity: 1; background: color-mix(in srgb, var(--foreground) 6%, var(--secondary)); }\n.ghcn-tier-compare:focus-visible, :where(.ghcn-tier-compare) :focus-visible { outline: 2px solid var(--ring, currentColor); outline-offset: 2px; }"
|
|
32
|
+
}
|
|
33
|
+
],
|
|
34
|
+
"gscan": {
|
|
35
|
+
"rules_satisfied": [
|
|
36
|
+
"GS010-PJ-VALID",
|
|
37
|
+
"GS050-MEMBERS-TIERS"
|
|
38
|
+
],
|
|
39
|
+
"notes": "Uses Ghost native #get tiers helper, {{price}}, and data-portal signup actions."
|
|
40
|
+
},
|
|
41
|
+
"styleSlots": {
|
|
42
|
+
"class": [
|
|
43
|
+
".ghcn-tier-compare"
|
|
44
|
+
],
|
|
45
|
+
"titleClass": [
|
|
46
|
+
".ghcn-tier-compare__title"
|
|
47
|
+
],
|
|
48
|
+
"tableClass": [
|
|
49
|
+
".ghcn-tier-compare__table"
|
|
50
|
+
],
|
|
51
|
+
"buttonClass": [
|
|
52
|
+
".ghcn-tier-compare__cta"
|
|
53
|
+
]
|
|
54
|
+
}
|
|
55
|
+
}
|