@supersoniks/concorde 5.1.0 → 5.1.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/.claude/launch.json +15 -0
- package/.claude/vite.http.config.mjs +7 -0
- package/.taste-skill/after/desktop-fold.jpg +0 -0
- package/.taste-skill/after/desktop-page-01.jpg +0 -0
- package/.taste-skill/after/desktop-page-02.jpg +0 -0
- package/.taste-skill/after/desktop-page-03.jpg +0 -0
- package/.taste-skill/after/mobile-fold.jpg +0 -0
- package/.taste-skill/after/mobile-page-01.jpg +0 -0
- package/.taste-skill/after/report.json +4103 -0
- package/.taste-skill/after/tablet-fold.jpg +0 -0
- package/.taste-skill/after/tablet-page-01.jpg +0 -0
- package/.taste-skill/after/tablet-page-02.jpg +0 -0
- package/.taste-skill/before/desktop-fold.jpg +0 -0
- package/.taste-skill/before/desktop-page-01.jpg +0 -0
- package/.taste-skill/before/desktop-page-02.jpg +0 -0
- package/.taste-skill/before/mobile-fold.jpg +0 -0
- package/.taste-skill/before/mobile-page-01.jpg +0 -0
- package/.taste-skill/before/report.json +2556 -0
- package/.taste-skill/before/tablet-fold.jpg +0 -0
- package/.taste-skill/before/tablet-page-01.jpg +0 -0
- package/.taste-skill/direction.json +510 -0
- package/.taste-skill/notes.md +84 -0
- package/.taste-skill/prod/desktop-fold.jpg +0 -0
- package/.taste-skill/prod/desktop-page-01.jpg +0 -0
- package/.taste-skill/prod/desktop-page-02.jpg +0 -0
- package/.taste-skill/prod/desktop-page-03.jpg +0 -0
- package/.taste-skill/prod/mobile-fold.jpg +0 -0
- package/.taste-skill/prod/mobile-page-01.jpg +0 -0
- package/.taste-skill/prod/mobile-page-02.jpg +0 -0
- package/.taste-skill/prod/report.json +1973 -0
- package/.taste-skill/prod/tablet-fold.jpg +0 -0
- package/.taste-skill/prod/tablet-page-01.jpg +0 -0
- package/.taste-skill/prod/tablet-page-02.jpg +0 -0
- package/.tmp-cem/custom-elements.json +1939 -1939
- package/AUDIT.md +228 -0
- package/PLAN-AMELIORATION.md +220 -0
- package/build-infos.json +1 -1
- package/concorde-core.bundle.js +16 -16
- package/concorde-core.es.js +235 -233
- package/dist/concorde-core.bundle.js +16 -16
- package/dist/concorde-core.es.js +235 -233
- package/dist/img/archive/concorde-001-2cv.webp +0 -0
- package/dist/img/archive/concorde-red-arrows-2002-poster.jpg +0 -0
- package/dist/img/archive/concorde-red-arrows-2002.webm +0 -0
- package/dist/img/archive/credits.json +28 -0
- package/docs/assets/index-Bb-_LRyY.js +12280 -0
- package/docs/assets/index-CD4WyL6o.css +1 -0
- package/docs/docs-mock-api-sw.js +2 -0
- package/docs/docs-mock-api-sw.js.map +2 -2
- package/docs/index.html +9 -7
- package/index.html +27 -63
- package/package.json +11 -4
- package/public/img/archive/concorde-001-2cv.webp +0 -0
- package/public/img/archive/concorde-red-arrows-2002-poster.jpg +0 -0
- package/public/img/archive/concorde-red-arrows-2002.webm +0 -0
- package/public/img/archive/credits.json +28 -0
- package/scripts/post-build-docs.js +0 -0
- package/scripts/post-build.mjs +0 -0
- package/src/core/components/functional/fetch/fetch.md +2 -2
- package/src/core/components/functional/if/if.md +0 -0
- package/src/core/components/functional/if/if.ts +0 -0
- package/src/core/components/functional/list/list.demo.ts +0 -0
- package/src/core/components/functional/list/list.md +0 -0
- package/src/core/components/functional/router/router.md +0 -0
- package/src/core/components/functional/router/router.ts +0 -0
- package/src/core/components/functional/sdui/SDUIDescriptorTransformer.ts +0 -0
- package/src/core/components/functional/sdui/component-catalog.gaps.json +1 -1
- package/src/core/components/functional/sdui/component-catalog.json +1 -1
- package/src/core/components/functional/sdui/types.ts +0 -0
- package/src/core/components/functional/states/states.md +0 -0
- package/src/core/components/functional/submit/submit.md +0 -0
- package/src/core/components/functional/subscriber/subscriber.ts +0 -0
- package/src/core/components/functional/value/value.ts +0 -0
- package/src/core/components/ui/_css/size.ts +0 -0
- package/src/core/components/ui/captcha/altchaStyles.ts +0 -0
- package/src/core/components/ui/form/radio/radio.md +0 -0
- package/src/core/components/ui/form/select/select.md +0 -0
- package/src/core/components/ui/form/switch/switch.md +0 -0
- package/src/core/components/ui/modal/modal.ts +14 -11
- package/src/core/mixins/Subscriber.ts +0 -0
- package/src/core/utils/DataBindObserver.ts +0 -0
- package/src/core/utils/Objects.ts +0 -0
- package/src/core/utils/route.ts +0 -0
- package/src/docs/_core-concept/subscriber.md +0 -0
- package/src/docs/_getting-started/components.md +5 -0
- package/src/docs/_getting-started/my-first-subscriber.md +0 -0
- package/src/docs/_getting-started/pubsub.md +0 -0
- package/src/docs/_getting-started/theming.md +2 -2
- package/src/docs/code.ts +88 -75
- package/src/docs/components/docs-demo-sources.ts +16 -8
- package/src/docs/components/docs-lit-demo.ts +19 -37
- package/src/docs/docs.ts +5 -0
- package/src/docs/example/docs-boarding-pass-demo.ts +134 -0
- package/src/docs/example/docs-provider-keys.ts +12 -0
- package/src/docs/example/users.ts +0 -0
- package/src/docs/header/header.ts +233 -69
- package/src/docs/home/catalog.ts +44 -0
- package/src/docs/home/home.ts +513 -0
- package/src/docs/home/mach-stage.ts +389 -0
- package/src/docs/layout.ts +3 -1
- package/src/docs/navigation/components-index.ts +56 -0
- package/src/docs/navigation/navigation.ts +240 -232
- package/src/docs/navigation/pager.ts +67 -0
- package/src/docs/navigation/toc.ts +98 -0
- package/src/docs/search/docs-search.json +330 -20
- package/src/docs/search/markdown-renderer.ts +11 -3
- package/src/docs/search/page.ts +0 -0
- package/src/docs/shiki/index.ts +109 -0
- package/src/docs/tailwind/css/base/scrollbar.css +22 -0
- package/src/docs/tailwind/css/base/theme.css +96 -0
- package/src/docs/tailwind/css/base/typography.css +4 -0
- package/src/docs/tailwind/css/docs/boarding-pass.css +65 -0
- package/src/docs/tailwind/css/docs/content.css +32 -0
- package/src/docs/tailwind/css/docs/page.css +10 -0
- package/src/docs/tailwind/css/docs.css +9 -0
- package/src/docs/tailwind/css/home/hero.css +210 -0
- package/src/docs/tailwind/css/home/motion.css +84 -0
- package/src/docs/tailwind/css/home/sections.css +416 -0
- package/src/docs/tailwind/css/tailwind.css +7 -185
- package/src/tsconfig.json +23 -2
- package/src/tsconfig.tsbuildinfo +1 -1
- package/tailwind.config.js +8 -4
- package/.github/workflows/ci.yml +0 -21
- package/.github-export-ignore +0 -30
- package/CONTRIBUTING.md +0 -59
- package/DEV.md +0 -54
- package/LICENSE +0 -21
- package/OPEN_SOURCE_CHECKPOINT.md +0 -133
- package/concorde-3d.bundle.js +0 -3960
- package/concorde-3d.es.js +0 -33433
- package/concorde-hugging-face-infer.bundle.js +0 -32
- package/concorde-hugging-face-infer.es.js +0 -2952
- package/concorde-interactive.bundle.js +0 -1157
- package/concorde-interactive.es.js +0 -10734
- package/concorde-shader.bundle.js +0 -116
- package/concorde-shader.es.js +0 -8353
- package/concorde-webgpu.bundle.js +0 -307
- package/concorde-webgpu.es.js +0 -8627
- package/docs/assets/index-D8MVWqY6.js +0 -12251
- package/docs/assets/index-DiD0qYvE.css +0 -1
- package/docs/crawl/core/components/functional/date/date.html +0 -190
- package/docs/crawl/core/components/functional/fetch/fetch.html +0 -109
- package/docs/crawl/core/components/functional/if/if.html +0 -27
- package/docs/crawl/core/components/functional/jsonata/jsonata.html +0 -79
- package/docs/crawl/core/components/functional/list/list.html +0 -70
- package/docs/crawl/core/components/functional/mix/mix.html +0 -45
- package/docs/crawl/core/components/functional/queue/queue.html +0 -96
- package/docs/crawl/core/components/functional/router/router.html +0 -106
- package/docs/crawl/core/components/functional/sdui/sdui.html +0 -269
- package/docs/crawl/core/components/functional/states/states.html +0 -66
- package/docs/crawl/core/components/functional/submit/submit.html +0 -160
- package/docs/crawl/core/components/functional/subscriber/subscriber.html +0 -67
- package/docs/crawl/core/components/functional/value/value.html +0 -51
- package/docs/crawl/core/components/ui/alert/alert.html +0 -110
- package/docs/crawl/core/components/ui/alert-messages/alert-messages.html +0 -23
- package/docs/crawl/core/components/ui/badge/badge.html +0 -119
- package/docs/crawl/core/components/ui/button/button.html +0 -149
- package/docs/crawl/core/components/ui/captcha/captcha.html +0 -30
- package/docs/crawl/core/components/ui/card/card.html +0 -99
- package/docs/crawl/core/components/ui/divider/divider.html +0 -58
- package/docs/crawl/core/components/ui/form/checkbox/checkbox.html +0 -73
- package/docs/crawl/core/components/ui/form/fieldset/fieldset.html +0 -135
- package/docs/crawl/core/components/ui/form/form-actions/form-actions.html +0 -79
- package/docs/crawl/core/components/ui/form/form-layout/form-layout.html +0 -62
- package/docs/crawl/core/components/ui/form/input/input.html +0 -109
- package/docs/crawl/core/components/ui/form/input-autocomplete/input-autocomplete.html +0 -38
- package/docs/crawl/core/components/ui/form/radio/radio.html +0 -56
- package/docs/crawl/core/components/ui/form/select/select.html +0 -73
- package/docs/crawl/core/components/ui/form/switch/switch.html +0 -56
- package/docs/crawl/core/components/ui/form/textarea/textarea.html +0 -59
- package/docs/crawl/core/components/ui/group/group.html +0 -82
- package/docs/crawl/core/components/ui/icon/icon.html +0 -133
- package/docs/crawl/core/components/ui/image/image.html +0 -110
- package/docs/crawl/core/components/ui/link/link.html +0 -42
- package/docs/crawl/core/components/ui/loader/loader.html +0 -50
- package/docs/crawl/core/components/ui/menu/menu.html +0 -322
- package/docs/crawl/core/components/ui/modal/modal.html +0 -117
- package/docs/crawl/core/components/ui/pop/pop.html +0 -102
- package/docs/crawl/core/components/ui/progress/progress.html +0 -58
- package/docs/crawl/core/components/ui/table/table.html +0 -413
- package/docs/crawl/core/components/ui/toast/toast.html +0 -122
- package/docs/crawl/core/components/ui/tooltip/tooltip.html +0 -79
- package/docs/crawl/docs/_core-concept/dataFlow.html +0 -177
- package/docs/crawl/docs/_core-concept/overview.html +0 -66
- package/docs/crawl/docs/_core-concept/subscriber.html +0 -75
- package/docs/crawl/docs/_decorators/ancestor-attribute.html +0 -116
- package/docs/crawl/docs/_decorators/auto-subscribe.html +0 -202
- package/docs/crawl/docs/_decorators/bind.html +0 -141
- package/docs/crawl/docs/_decorators/get.html +0 -149
- package/docs/crawl/docs/_decorators/handle.html +0 -165
- package/docs/crawl/docs/_decorators/on-assign.html +0 -355
- package/docs/crawl/docs/_decorators/patch.html +0 -78
- package/docs/crawl/docs/_decorators/post.html +0 -139
- package/docs/crawl/docs/_decorators/publish.html +0 -61
- package/docs/crawl/docs/_decorators/put.html +0 -78
- package/docs/crawl/docs/_decorators/subscribe.html +0 -109
- package/docs/crawl/docs/_decorators/wait-for-ancestors.html +0 -137
- package/docs/crawl/docs/_directives/sub.html +0 -93
- package/docs/crawl/docs/_getting-started/ai-agents.html +0 -173
- package/docs/crawl/docs/_getting-started/concorde-manual-install.html +0 -100
- package/docs/crawl/docs/_getting-started/concorde-outside.html +0 -58
- package/docs/crawl/docs/_getting-started/create-a-component.html +0 -111
- package/docs/crawl/docs/_getting-started/my-first-component.html +0 -189
- package/docs/crawl/docs/_getting-started/my-first-subscriber.html +0 -110
- package/docs/crawl/docs/_getting-started/pubsub.html +0 -62
- package/docs/crawl/docs/_getting-started/start.html +0 -76
- package/docs/crawl/docs/_getting-started/theming.html +0 -85
- package/docs/crawl/docs/_misc/api-configuration.html +0 -149
- package/docs/crawl/docs/_misc/dataProviderKey.html +0 -135
- package/docs/crawl/docs/_misc/docs-mock-api.html +0 -158
- package/docs/crawl/docs/_misc/dynamic-path.html +0 -180
- package/docs/crawl/docs/_misc/endpoint.html +0 -50
- package/docs/crawl/docs/_misc/formelement-subscriber-removal.html +0 -138
- package/docs/crawl/docs/_misc/html-integration.html +0 -48
- package/docs/crawl/hubs/decorators.html +0 -547
- package/docs/crawl/hubs/form-components.html +0 -359
- package/docs/crawl/hubs/remote-data.html +0 -452
- package/docs/crawl/index.html +0 -101
- package/docs/llms-full.txt +0 -5761
- package/docs/llms.txt +0 -104
- package/docs/sitemap.xml +0 -237
- package/docs/src/core/components/functional/date/date.md +0 -290
- package/docs/src/core/components/functional/fetch/fetch.md +0 -125
- package/docs/src/core/components/functional/if/if.md +0 -9
- package/docs/src/core/components/functional/jsonata/jsonata.md +0 -56
- package/docs/src/core/components/functional/list/list.md +0 -65
- package/docs/src/core/components/functional/mix/mix.md +0 -41
- package/docs/src/core/components/functional/queue/queue.md +0 -72
- package/docs/src/core/components/functional/router/router.md +0 -94
- package/docs/src/core/components/functional/sdui/default-library.json +0 -108
- package/docs/src/core/components/functional/sdui/example.json +0 -99
- package/docs/src/core/components/functional/sdui/sdui.md +0 -356
- package/docs/src/core/components/functional/states/states.md +0 -87
- package/docs/src/core/components/functional/submit/submit.md +0 -114
- package/docs/src/core/components/functional/subscriber/subscriber.md +0 -91
- package/docs/src/core/components/functional/value/value.md +0 -35
- package/docs/src/core/components/ui/alert/alert.md +0 -121
- package/docs/src/core/components/ui/alert-messages/alert-messages.md +0 -0
- package/docs/src/core/components/ui/badge/badge.md +0 -127
- package/docs/src/core/components/ui/button/button.md +0 -182
- package/docs/src/core/components/ui/captcha/captcha.md +0 -12
- package/docs/src/core/components/ui/card/card.md +0 -97
- package/docs/src/core/components/ui/divider/divider.md +0 -35
- package/docs/src/core/components/ui/form/checkbox/checkbox.md +0 -77
- package/docs/src/core/components/ui/form/fieldset/fieldset.md +0 -129
- package/docs/src/core/components/ui/form/form-actions/form-actions.md +0 -77
- package/docs/src/core/components/ui/form/form-layout/form-layout.md +0 -44
- package/docs/src/core/components/ui/form/input/input.md +0 -142
- package/docs/src/core/components/ui/form/input-autocomplete/input-autocomplete.md +0 -29
- package/docs/src/core/components/ui/form/radio/radio.md +0 -57
- package/docs/src/core/components/ui/form/select/select.md +0 -71
- package/docs/src/core/components/ui/form/switch/switch.md +0 -57
- package/docs/src/core/components/ui/form/textarea/textarea.md +0 -65
- package/docs/src/core/components/ui/group/group.md +0 -75
- package/docs/src/core/components/ui/icon/icon.md +0 -125
- package/docs/src/core/components/ui/icon/icons.json +0 -1
- package/docs/src/core/components/ui/image/image.md +0 -107
- package/docs/src/core/components/ui/link/link.md +0 -43
- package/docs/src/core/components/ui/loader/loader.md +0 -55
- package/docs/src/core/components/ui/menu/menu.md +0 -329
- package/docs/src/core/components/ui/modal/modal.md +0 -119
- package/docs/src/core/components/ui/pop/pop.md +0 -96
- package/docs/src/core/components/ui/progress/progress.md +0 -63
- package/docs/src/core/components/ui/table/table.md +0 -455
- package/docs/src/core/components/ui/toast/toast.md +0 -166
- package/docs/src/core/components/ui/tooltip/tooltip.md +0 -82
- package/docs/src/docs/_core-concept/dataFlow.md +0 -88
- package/docs/src/docs/_core-concept/overview.md +0 -57
- package/docs/src/docs/_core-concept/subscriber.md +0 -75
- package/docs/src/docs/_decorators/ancestor-attribute.md +0 -127
- package/docs/src/docs/_decorators/auto-subscribe.md +0 -202
- package/docs/src/docs/_decorators/bind.md +0 -167
- package/docs/src/docs/_decorators/get.md +0 -162
- package/docs/src/docs/_decorators/handle.md +0 -175
- package/docs/src/docs/_decorators/on-assign.md +0 -390
- package/docs/src/docs/_decorators/patch.md +0 -70
- package/docs/src/docs/_decorators/post.md +0 -146
- package/docs/src/docs/_decorators/publish.md +0 -55
- package/docs/src/docs/_decorators/put.md +0 -70
- package/docs/src/docs/_decorators/subscribe.md +0 -100
- package/docs/src/docs/_decorators/wait-for-ancestors.md +0 -163
- package/docs/src/docs/_directives/sub.md +0 -91
- package/docs/src/docs/_getting-started/ai-agents.md +0 -76
- package/docs/src/docs/_getting-started/concorde-manual-install.md +0 -133
- package/docs/src/docs/_getting-started/concorde-outside.md +0 -33
- package/docs/src/docs/_getting-started/create-a-component.md +0 -139
- package/docs/src/docs/_getting-started/my-first-component.md +0 -236
- package/docs/src/docs/_getting-started/my-first-subscriber.md +0 -120
- package/docs/src/docs/_getting-started/pubsub.md +0 -37
- package/docs/src/docs/_getting-started/start.md +0 -47
- package/docs/src/docs/_getting-started/theming.md +0 -91
- package/docs/src/docs/_misc/api-configuration.md +0 -81
- package/docs/src/docs/_misc/dataProviderKey.md +0 -168
- package/docs/src/docs/_misc/docs-mock-api.md +0 -63
- package/docs/src/docs/_misc/dynamic-path.md +0 -71
- package/docs/src/docs/_misc/endpoint.md +0 -45
- package/docs/src/docs/_misc/formelement-subscriber-removal.md +0 -115
- package/docs/src/docs/_misc/html-integration.md +0 -15
- package/docs/src/docs/search/docs-search.json +0 -9507
- package/docs/src/tag-list.json +0 -1
- package/docs/src/tsconfig-model.json +0 -23
- package/docs/src/tsconfig.declarations.json +0 -22
- package/docs/src/tsconfig.emit.json +0 -23
- package/docs/src/tsconfig.json +0 -1182
- package/gitlab/job_github_mirror.sh +0 -39
- package/scripts/github-export.mjs +0 -150
- package/src/css.d.ts +0 -19
- package/src/docs/prism/index.ts +0 -6
- package/src/docs/prism/prism.css +0 -158
- package/src/docs/prism/prism.js +0 -1022
- package/src/tsconfig.declarations.json +0 -22
- package/src/tsconfig.emit.json +0 -23
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
import { html, LitElement } from "lit";
|
|
2
|
+
import { customElement, state } from "lit/decorators.js";
|
|
3
|
+
import { keyed } from "lit/directives/keyed.js";
|
|
4
|
+
import { subscribe } from "@supersoniks/concorde/core/decorators/Subscriber";
|
|
5
|
+
import { docsBoardingPassKey } from "./docs-provider-keys";
|
|
6
|
+
|
|
7
|
+
const destinations: Record<string, string> = {
|
|
8
|
+
JFK: "New York",
|
|
9
|
+
GIG: "Rio de Janeiro",
|
|
10
|
+
HND: "Tokyo",
|
|
11
|
+
DXB: "Dubai",
|
|
12
|
+
SYD: "Sydney",
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
const isChecked = (v: unknown) =>
|
|
16
|
+
v === true || v === "true" || v === 1 || v === "1";
|
|
17
|
+
|
|
18
|
+
@customElement("docs-boarding-pass-demo")
|
|
19
|
+
export class DocsBoardingPassDemo extends LitElement {
|
|
20
|
+
/** Light DOM: the pass is part of the page (styles in tailwind/css/docs/boarding-pass.css). */
|
|
21
|
+
createRenderRoot() {
|
|
22
|
+
return this;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
@subscribe(docsBoardingPassKey.firstName)
|
|
27
|
+
@state()
|
|
28
|
+
firstName = "";
|
|
29
|
+
|
|
30
|
+
@subscribe(docsBoardingPassKey.lastName)
|
|
31
|
+
@state()
|
|
32
|
+
lastName = "";
|
|
33
|
+
|
|
34
|
+
@subscribe(docsBoardingPassKey.destination)
|
|
35
|
+
@state()
|
|
36
|
+
destination = "JFK";
|
|
37
|
+
|
|
38
|
+
@subscribe(docsBoardingPassKey.firstClass)
|
|
39
|
+
@state()
|
|
40
|
+
firstClass = "";
|
|
41
|
+
|
|
42
|
+
render() {
|
|
43
|
+
const first = isChecked(this.firstClass);
|
|
44
|
+
const code = this.destination || "JFK";
|
|
45
|
+
const passenger =
|
|
46
|
+
`${this.lastName || "—"} / ${this.firstName || "—"}`.toUpperCase();
|
|
47
|
+
|
|
48
|
+
return html`
|
|
49
|
+
<div class="grid gap-6 max-w-[34rem] mx-auto">
|
|
50
|
+
<div formDataProvider=${docsBoardingPassKey.path} class="grid gap-3">
|
|
51
|
+
<div class="grid gap-3 sm:grid-cols-2">
|
|
52
|
+
<sonic-input name="firstName" label="First name"></sonic-input>
|
|
53
|
+
<sonic-input name="lastName" label="Last name"></sonic-input>
|
|
54
|
+
</div>
|
|
55
|
+
<sonic-select name="destination" label="Destination">
|
|
56
|
+
${Object.entries(destinations).map(
|
|
57
|
+
([value, city]) =>
|
|
58
|
+
html`<option value=${value}>${city} (${value})</option>`,
|
|
59
|
+
)}
|
|
60
|
+
</sonic-select>
|
|
61
|
+
<sonic-switch name="firstClass" value="true" unique
|
|
62
|
+
>First class</sonic-switch
|
|
63
|
+
>
|
|
64
|
+
</div>
|
|
65
|
+
|
|
66
|
+
<sonic-card
|
|
67
|
+
type=${first ? "invert" : "light"}
|
|
68
|
+
shadow="none"
|
|
69
|
+
class="block relative"
|
|
70
|
+
>
|
|
71
|
+
<div class="flex items-center justify-between gap-3 mb-5">
|
|
72
|
+
<span class="font-headings italic font-semibold text-xl"
|
|
73
|
+
>concorde airways</span
|
|
74
|
+
>
|
|
75
|
+
${keyed(
|
|
76
|
+
first,
|
|
77
|
+
html`<sonic-badge
|
|
78
|
+
class="bp-pop"
|
|
79
|
+
variant="outline"
|
|
80
|
+
type=${first ? "warning" : "default"}
|
|
81
|
+
>${first ? "First class" : "Economy"}</sonic-badge
|
|
82
|
+
>`,
|
|
83
|
+
)}
|
|
84
|
+
</div>
|
|
85
|
+
|
|
86
|
+
<div class="grid grid-cols-[auto_1fr_auto] items-center gap-3">
|
|
87
|
+
<div>
|
|
88
|
+
<div class="font-headings text-4xl sm:text-5xl leading-none">CDG</div>
|
|
89
|
+
<div class="text-xs opacity-70">Paris</div>
|
|
90
|
+
</div>
|
|
91
|
+
<div class="bp-route">
|
|
92
|
+
${keyed(
|
|
93
|
+
code,
|
|
94
|
+
html`<sonic-icon
|
|
95
|
+
class="bp-fly"
|
|
96
|
+
name="plane"
|
|
97
|
+
library="fontAwesome"
|
|
98
|
+
prefix="solid"
|
|
99
|
+
size="lg"
|
|
100
|
+
></sonic-icon>`,
|
|
101
|
+
)}
|
|
102
|
+
</div>
|
|
103
|
+
<div class="text-right">
|
|
104
|
+
${keyed(
|
|
105
|
+
code,
|
|
106
|
+
html`<div class="bp-pop font-headings text-4xl sm:text-5xl leading-none">
|
|
107
|
+
${code}
|
|
108
|
+
</div>`,
|
|
109
|
+
)}
|
|
110
|
+
<div class="text-xs opacity-70">${destinations[code]}</div>
|
|
111
|
+
</div>
|
|
112
|
+
</div>
|
|
113
|
+
|
|
114
|
+
<div class="grid grid-cols-3 gap-3 mt-6 text-sm">
|
|
115
|
+
<div class="col-span-3 sm:col-span-1 min-w-0">
|
|
116
|
+
<div class="text-xs opacity-60">Passenger</div>
|
|
117
|
+
<div class="font-bold truncate">${passenger}</div>
|
|
118
|
+
</div>
|
|
119
|
+
<div>
|
|
120
|
+
<div class="text-xs opacity-60">Seat</div>
|
|
121
|
+
<div class="font-bold">${first ? "1A" : "24C"}</div>
|
|
122
|
+
</div>
|
|
123
|
+
<div>
|
|
124
|
+
<div class="text-xs opacity-60">Boarding</div>
|
|
125
|
+
<div class="font-bold">${first ? "10:05" : "10:25"}</div>
|
|
126
|
+
</div>
|
|
127
|
+
</div>
|
|
128
|
+
|
|
129
|
+
<div class="bp-barcode h-10 mt-6 opacity-80"></div>
|
|
130
|
+
</sonic-card>
|
|
131
|
+
</div>
|
|
132
|
+
`;
|
|
133
|
+
}
|
|
134
|
+
}
|
|
@@ -111,6 +111,12 @@ export const docsToggleVisibilityKey = new DataProviderKey<{ togglePlan?: string
|
|
|
111
111
|
export const docsToggleLoaderFormKey = new DataProviderKey<{ toggleLoader?: string }>(
|
|
112
112
|
"toggleLoaderForm",
|
|
113
113
|
);
|
|
114
|
+
export const docsBoardingPassKey = new DataProviderKey<{
|
|
115
|
+
firstName?: string;
|
|
116
|
+
lastName?: string;
|
|
117
|
+
destination?: string;
|
|
118
|
+
firstClass?: string;
|
|
119
|
+
}>("boardingPass");
|
|
114
120
|
|
|
115
121
|
/** User / preview scopes */
|
|
116
122
|
export const docsUserScopeAKey = new DataProviderKey<DocsUserData>(
|
|
@@ -222,6 +228,12 @@ export function initDocsProviderDefaults(): void {
|
|
|
222
228
|
|
|
223
229
|
set(docsToggleVisibilityKey, { togglePlan: "true" });
|
|
224
230
|
set(docsToggleLoaderFormKey, { toggleLoader: "" });
|
|
231
|
+
set(docsBoardingPassKey, {
|
|
232
|
+
firstName: "André",
|
|
233
|
+
lastName: "Turcat",
|
|
234
|
+
destination: "JFK",
|
|
235
|
+
firstClass: "true",
|
|
236
|
+
});
|
|
225
237
|
|
|
226
238
|
set(docsUserScopeAKey, {
|
|
227
239
|
first_name: "Paul",
|
|
File without changes
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { html, LitElement, nothing } from "lit";
|
|
1
|
+
import { css, html, LitElement, nothing } from "lit";
|
|
2
2
|
import { customElement, state } from "lit/decorators.js";
|
|
3
3
|
import Subscriber from "@supersoniks/concorde/core/mixins/Subscriber";
|
|
4
4
|
import { tailwind } from "../tailwind";
|
|
@@ -7,11 +7,95 @@ import { Theme } from "@supersoniks/concorde/core/components/ui/theme/theme";
|
|
|
7
7
|
const tagName = "sonic-docs-header"; // For Astro.build
|
|
8
8
|
@customElement(tagName)
|
|
9
9
|
export class SonicComponent extends Subscriber(LitElement) {
|
|
10
|
-
static styles = [
|
|
10
|
+
static styles = [
|
|
11
|
+
tailwind,
|
|
12
|
+
css`
|
|
13
|
+
/* paint the page gutters too, so content never shows beside the sticky bar */
|
|
14
|
+
.header-bar {
|
|
15
|
+
box-shadow:
|
|
16
|
+
-5rem 0 0 var(--sc-base),
|
|
17
|
+
5rem 0 0 var(--sc-base);
|
|
18
|
+
}
|
|
19
|
+
/* the rule under the bar runs on through the gutters, edge to edge */
|
|
20
|
+
.header-bar::after {
|
|
21
|
+
content: "";
|
|
22
|
+
position: absolute;
|
|
23
|
+
left: 0;
|
|
24
|
+
right: 0;
|
|
25
|
+
bottom: -0.18rem;
|
|
26
|
+
height: 0.18rem;
|
|
27
|
+
background: currentColor;
|
|
28
|
+
box-shadow:
|
|
29
|
+
-5rem 0 0 currentColor,
|
|
30
|
+
5rem 0 0 currentColor;
|
|
31
|
+
}
|
|
32
|
+
.logo-plane path {
|
|
33
|
+
transform-box: view-box;
|
|
34
|
+
transform-origin: 33px 33px;
|
|
35
|
+
/* takes off every 6s (flight in the first ~1.1s, then parked) */
|
|
36
|
+
animation: takeoff 6s cubic-bezier(0.5, 0, 0.3, 1) 0.5s infinite;
|
|
37
|
+
}
|
|
38
|
+
.logo:hover .logo-plane path,
|
|
39
|
+
.logo:focus-visible .logo-plane path {
|
|
40
|
+
animation: takeoff-again 1.1s cubic-bezier(0.5, 0, 0.3, 1);
|
|
41
|
+
}
|
|
42
|
+
@keyframes takeoff-again {
|
|
43
|
+
12% {
|
|
44
|
+
transform: translateY(3px);
|
|
45
|
+
}
|
|
46
|
+
50% {
|
|
47
|
+
transform: translateY(-64px) scale(0.85);
|
|
48
|
+
}
|
|
49
|
+
50.01% {
|
|
50
|
+
transform: translateY(64px) scale(0.85);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
@keyframes takeoff {
|
|
54
|
+
0% {
|
|
55
|
+
transform: translateY(0);
|
|
56
|
+
}
|
|
57
|
+
2% {
|
|
58
|
+
transform: translateY(3px);
|
|
59
|
+
}
|
|
60
|
+
9% {
|
|
61
|
+
transform: translateY(-64px) scale(0.85);
|
|
62
|
+
}
|
|
63
|
+
9.01% {
|
|
64
|
+
transform: translateY(64px) scale(0.85);
|
|
65
|
+
}
|
|
66
|
+
18%,
|
|
67
|
+
100% {
|
|
68
|
+
transform: translateY(0);
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
@media (prefers-reduced-motion: reduce) {
|
|
72
|
+
.logo-plane path,
|
|
73
|
+
.logo:hover .logo-plane path {
|
|
74
|
+
animation: none;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
`,
|
|
78
|
+
];
|
|
11
79
|
|
|
12
80
|
@state() theme: "dark" | "light" = "light";
|
|
13
81
|
@state() searchVisible = false;
|
|
14
82
|
|
|
83
|
+
/** Publishes the bar's height as --docs-header-h so sticky panels sit right under it. */
|
|
84
|
+
private headerResize = new ResizeObserver(([entry]) => {
|
|
85
|
+
const h = Math.round(entry.target.getBoundingClientRect().height);
|
|
86
|
+
document.documentElement.style.setProperty("--docs-header-h", `${h}px`);
|
|
87
|
+
});
|
|
88
|
+
|
|
89
|
+
firstUpdated() {
|
|
90
|
+
const bar = this.shadowRoot?.querySelector(".header-bar");
|
|
91
|
+
if (bar) this.headerResize.observe(bar);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
disconnectedCallback() {
|
|
95
|
+
this.headerResize.disconnect();
|
|
96
|
+
super.disconnectedCallback();
|
|
97
|
+
}
|
|
98
|
+
|
|
15
99
|
connectedCallback() {
|
|
16
100
|
this.handleColorScheme();
|
|
17
101
|
super.connectedCallback();
|
|
@@ -36,9 +120,10 @@ export class SonicComponent extends Subscriber(LitElement) {
|
|
|
36
120
|
}
|
|
37
121
|
});
|
|
38
122
|
|
|
39
|
-
// on hash change, hide search
|
|
123
|
+
// on hash change, hide search and mobile navigation
|
|
40
124
|
window.addEventListener("hashchange", () => {
|
|
41
125
|
this.hideSearch();
|
|
126
|
+
this.closeNavigation();
|
|
42
127
|
});
|
|
43
128
|
}
|
|
44
129
|
|
|
@@ -63,6 +148,17 @@ export class SonicComponent extends Subscriber(LitElement) {
|
|
|
63
148
|
this.handleColorScheme();
|
|
64
149
|
}
|
|
65
150
|
|
|
151
|
+
openNavigation() {
|
|
152
|
+
this.shadowRoot
|
|
153
|
+
?.querySelector<HTMLElement & { show(): void }>("#mobile-nav")
|
|
154
|
+
?.show();
|
|
155
|
+
}
|
|
156
|
+
closeNavigation() {
|
|
157
|
+
this.shadowRoot
|
|
158
|
+
?.querySelector<HTMLElement & { hide(): void }>("#mobile-nav")
|
|
159
|
+
?.hide();
|
|
160
|
+
}
|
|
161
|
+
|
|
66
162
|
hideSearch() {
|
|
67
163
|
this.searchVisible = false;
|
|
68
164
|
}
|
|
@@ -72,12 +168,22 @@ export class SonicComponent extends Subscriber(LitElement) {
|
|
|
72
168
|
|
|
73
169
|
render() {
|
|
74
170
|
return html`<div
|
|
75
|
-
class="flex items-center gap-4 border-b-[.18rem]
|
|
171
|
+
class="flex items-center gap-2 sm:gap-4 border-b-[.18rem] text-content border-current py-3 sticky top-0 z-40 bg-neutral-0 header-bar"
|
|
76
172
|
>
|
|
77
|
-
<
|
|
78
|
-
|
|
173
|
+
<sonic-button
|
|
174
|
+
class="lg:hidden"
|
|
175
|
+
shape="circle"
|
|
176
|
+
variant="ghost"
|
|
177
|
+
icon
|
|
178
|
+
data-aria-label="Open navigation"
|
|
179
|
+
@click=${() => this.openNavigation()}
|
|
180
|
+
>
|
|
181
|
+
<sonic-icon name="menu" library="iconoir"></sonic-icon>
|
|
182
|
+
</sonic-button>
|
|
183
|
+
<div class="min-w-0">
|
|
184
|
+
<sonic-link href="/" class="logo flex items-end gap-x-1">
|
|
79
185
|
<svg
|
|
80
|
-
class="size-[2.4rem] inline-block
|
|
186
|
+
class="size-8 sm:size-[2.4rem] inline-block rotate-[55deg]"
|
|
81
187
|
viewBox="0 0 66 66"
|
|
82
188
|
fill="none"
|
|
83
189
|
xmlns="http://www.w3.org/2000/svg"
|
|
@@ -88,47 +194,60 @@ export class SonicComponent extends Subscriber(LitElement) {
|
|
|
88
194
|
r="30"
|
|
89
195
|
fill="var(--sc-base-content, #000)"
|
|
90
196
|
/>
|
|
91
|
-
<
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
197
|
+
<clipPath id="logo-circle">
|
|
198
|
+
<circle cx="33" cy="33" r="30" />
|
|
199
|
+
</clipPath>
|
|
200
|
+
<g class="logo-plane" clip-path="url(#logo-circle)">
|
|
201
|
+
<path
|
|
202
|
+
d="M33.2499 62.03C33.8799 59.24 34.26 56.17 34.39 53.08C34.57 52.78 34.9099 52.6 35.2599 52.64H35.39C35.48 52.64 35.5799 52.64 35.6899 52.64H35.7599C35.7599 52.64 35.7999 52.64 35.8299 52.64C36.2499 52.62 36.6799 52.58 36.9099 52.56C36.9399 52.56 36.9599 52.56 36.9799 52.56C37.0099 52.56 37.0299 52.56 37.0499 52.56H37.0899L37.2099 51.93H37.4799L37.5799 52.4L37.6899 52.49H39.2699L39.39 52.38L39.5099 51.93H39.7899L39.8399 52.21L39.9999 52.29L45.2099 51.86L46.2799 51.29C46.2799 51.29 46.2799 50.85 46.2399 50.25V50.18C46.2399 50.18 46.2399 50.13 46.2399 50.11C46.2099 49.62 46.1399 49.13 46.0399 48.65C45.7899 47.45 45.29 46 42.2 41.58C39.11 37.16 38.04 35.52 35.89 27.63C35.85 27.48 35.8199 27.35 35.7899 27.2C35.1399 24.53 34.6899 22.95 34.5199 22.38V10.89C34.4999 9.60996 34.3999 8.33996 34.2099 7.07996C34.0499 5.97996 33.6099 4.89996 33.3499 3.95996H32.6299C32.3599 4.89996 31.9299 5.97996 31.7699 7.06996C31.5799 8.33996 31.4799 9.60996 31.4599 10.89V22.38C31.2899 22.95 30.8299 24.52 30.1899 27.2C30.1599 27.35 30.1199 27.49 30.0899 27.63C27.9499 35.52 26.8699 37.16 23.7799 41.58C20.6899 46 20.1899 47.45 19.9399 48.65C19.8399 49.13 19.7799 49.62 19.7399 50.11C19.7399 50.13 19.7399 50.16 19.7399 50.18V50.25C19.6999 50.85 19.7 51.29 19.7 51.29L20.7699 51.86L25.9799 52.29L26.14 52.21L26.1899 51.93H26.4799L26.5999 52.38L26.7299 52.49H28.2999L28.4099 52.4L28.5099 51.93H28.7699L28.89 52.56H28.9399C28.9399 52.56 28.9799 52.56 29.0099 52.56C29.0299 52.56 29.0499 52.56 29.0799 52.56C29.3099 52.58 29.7499 52.63 30.1599 52.64C30.1799 52.64 30.2099 52.64 30.2299 52.64H30.2999C30.4099 52.64 30.5099 52.64 30.5999 52.64H30.7299C31.0799 52.6 31.4299 52.77 31.6099 53.08C31.7299 56.17 32.1099 59.24 32.7399 62.03H33.2499Z"
|
|
203
|
+
fill="var(--sc-base, #fff)"
|
|
204
|
+
/>
|
|
205
|
+
</g>
|
|
95
206
|
</svg>
|
|
96
207
|
|
|
97
208
|
<span
|
|
98
|
-
class="font-headings text-4xl leading-none inline-block italic font-semibold"
|
|
209
|
+
class="font-headings text-3xl sm:text-4xl leading-none inline-block italic font-semibold"
|
|
99
210
|
>concorde</span
|
|
100
211
|
>
|
|
101
212
|
</sonic-link>
|
|
102
213
|
</div>
|
|
103
214
|
|
|
104
|
-
<div class="ml-auto flex gap-x-3
|
|
215
|
+
<div class="ml-auto flex items-center gap-x-1 sm:gap-x-3">
|
|
105
216
|
<sonic-button
|
|
106
|
-
class="
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
217
|
+
class="hidden md:block"
|
|
218
|
+
variant="ghost"
|
|
219
|
+
size="sm"
|
|
220
|
+
href="#docs/_getting-started/start.md/start"
|
|
221
|
+
>Docs</sonic-button
|
|
110
222
|
>
|
|
111
|
-
<sonic-icon name="magnifying-glass" library="custom"></sonic-icon>
|
|
112
|
-
</sonic-button>
|
|
113
223
|
<sonic-button
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
224
|
+
class="hidden md:block"
|
|
225
|
+
variant="ghost"
|
|
226
|
+
size="sm"
|
|
227
|
+
href="#docs/_getting-started/components.md/components"
|
|
228
|
+
>Components</sonic-button
|
|
229
|
+
>
|
|
230
|
+
<sonic-button
|
|
231
|
+
variant="ghost"
|
|
232
|
+
shape="circle"
|
|
233
|
+
icon
|
|
234
|
+
target="_blank"
|
|
235
|
+
data-aria-label="npm package"
|
|
236
|
+
href="https://www.npmjs.com/package/@supersoniks/concorde"
|
|
118
237
|
>
|
|
119
|
-
Search...
|
|
120
238
|
<sonic-icon
|
|
121
|
-
name="
|
|
122
|
-
library="
|
|
123
|
-
|
|
239
|
+
name="npm"
|
|
240
|
+
library="fontAwesome"
|
|
241
|
+
prefix="brands"
|
|
124
242
|
></sonic-icon>
|
|
125
243
|
</sonic-button>
|
|
126
|
-
|
|
127
244
|
<sonic-pop>
|
|
128
245
|
<sonic-button shape="circle" variant="ghost" icon>
|
|
129
|
-
${
|
|
130
|
-
|
|
131
|
-
|
|
246
|
+
${
|
|
247
|
+
this.theme == "light"
|
|
248
|
+
? html`<sonic-icon name="sun" library="custom"></sonic-icon>`
|
|
249
|
+
: html`<sonic-icon name="moon" library="custom"></sonic-icon>`
|
|
250
|
+
}
|
|
132
251
|
</sonic-button>
|
|
133
252
|
|
|
134
253
|
<sonic-menu slot="content">
|
|
@@ -156,67 +275,112 @@ export class SonicComponent extends Subscriber(LitElement) {
|
|
|
156
275
|
</sonic-menu-item>
|
|
157
276
|
</sonic-menu>
|
|
158
277
|
</sonic-pop>
|
|
278
|
+
<sonic-button
|
|
279
|
+
class="lg:hidden"
|
|
280
|
+
shape="circle"
|
|
281
|
+
variant="ghost"
|
|
282
|
+
icon
|
|
283
|
+
@click=${() => (this.searchVisible = !this.searchVisible)}
|
|
284
|
+
>
|
|
285
|
+
<sonic-icon name="magnifying-glass" library="custom"></sonic-icon>
|
|
286
|
+
</sonic-button>
|
|
287
|
+
<sonic-button
|
|
288
|
+
@click=${() => (this.searchVisible = !this.searchVisible)}
|
|
289
|
+
class="hidden lg:block lg:w-[19rem]"
|
|
290
|
+
shape="block"
|
|
291
|
+
align="left"
|
|
292
|
+
>
|
|
293
|
+
Search...
|
|
294
|
+
<sonic-icon
|
|
295
|
+
name="magnifying-glass"
|
|
296
|
+
library="custom"
|
|
297
|
+
slot="prefix"
|
|
298
|
+
></sonic-icon>
|
|
299
|
+
</sonic-button>
|
|
159
300
|
</div>
|
|
160
301
|
</div>
|
|
161
302
|
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
>
|
|
183
|
-
<div
|
|
184
|
-
@click=${() => this.hideSearch()}
|
|
185
|
-
class="bg-neutral-0 dark:bg-neutral-300 opacity-90 fixed top-0 left-0 w-full h-full "
|
|
186
|
-
></div>
|
|
303
|
+
<sonic-modal
|
|
304
|
+
id="mobile-nav"
|
|
305
|
+
effect="fade"
|
|
306
|
+
maxWidth="min(92vw, 22rem)"
|
|
307
|
+
maxHeight="88vh"
|
|
308
|
+
closeOnLocationChange
|
|
309
|
+
>
|
|
310
|
+
<sonic-modal-title>Documentation</sonic-modal-title>
|
|
311
|
+
<sonic-modal-content>
|
|
312
|
+
<docs-navigation
|
|
313
|
+
class="block"
|
|
314
|
+
@click=${(e: Event) => {
|
|
315
|
+
const onItem = e
|
|
316
|
+
.composedPath()
|
|
317
|
+
.some((n) => (n as HTMLElement).tagName === "SONIC-MENU-ITEM");
|
|
318
|
+
if (onItem) this.closeNavigation();
|
|
319
|
+
}}
|
|
320
|
+
></docs-navigation>
|
|
321
|
+
</sonic-modal-content>
|
|
322
|
+
</sonic-modal>
|
|
187
323
|
|
|
324
|
+
${
|
|
325
|
+
this.searchVisible
|
|
326
|
+
? html`
|
|
188
327
|
<div
|
|
189
328
|
${animate({
|
|
190
329
|
keyframeOptions: {
|
|
191
330
|
duration: 250,
|
|
192
|
-
easing: `cubic-bezier(0.250, 0.250, 0.420, 1.225)`,
|
|
193
331
|
},
|
|
194
332
|
in: [
|
|
195
333
|
{
|
|
196
|
-
transform: "translateY(1rem) scale(1.05)",
|
|
197
334
|
opacity: 0,
|
|
198
335
|
},
|
|
199
336
|
],
|
|
200
337
|
out: [
|
|
201
338
|
{
|
|
202
|
-
transform: "scale(.90) ",
|
|
203
339
|
opacity: 0,
|
|
204
|
-
duration: 3000,
|
|
205
|
-
easing: `ease-in-out`,
|
|
206
340
|
},
|
|
207
341
|
],
|
|
208
342
|
stabilizeOut: true,
|
|
209
343
|
})}
|
|
210
|
-
class="
|
|
344
|
+
class="fixed top-0 w-full left-0 z-[3000] pt-[20vh] flex items-center justify-center "
|
|
211
345
|
>
|
|
212
|
-
<
|
|
213
|
-
|
|
214
|
-
class="
|
|
346
|
+
<div
|
|
347
|
+
@click=${() => this.hideSearch()}
|
|
348
|
+
class="bg-neutral-0 dark:bg-neutral-300 opacity-90 fixed top-0 left-0 w-full h-full "
|
|
349
|
+
></div>
|
|
350
|
+
|
|
351
|
+
<div
|
|
352
|
+
${animate({
|
|
353
|
+
keyframeOptions: {
|
|
354
|
+
duration: 250,
|
|
355
|
+
easing: `cubic-bezier(0.250, 0.250, 0.420, 1.225)`,
|
|
356
|
+
},
|
|
357
|
+
in: [
|
|
358
|
+
{
|
|
359
|
+
transform: "translateY(1rem) scale(1.05)",
|
|
360
|
+
opacity: 0,
|
|
361
|
+
},
|
|
362
|
+
],
|
|
363
|
+
out: [
|
|
364
|
+
{
|
|
365
|
+
transform: "scale(.90) ",
|
|
366
|
+
opacity: 0,
|
|
367
|
+
duration: 3000,
|
|
368
|
+
easing: `ease-in-out`,
|
|
369
|
+
},
|
|
370
|
+
],
|
|
371
|
+
stabilizeOut: true,
|
|
372
|
+
})}
|
|
373
|
+
class="relative z-20 max-w-[30rem] lg:max-w-[35rem] w-full block "
|
|
215
374
|
>
|
|
216
|
-
|
|
375
|
+
<docs-search
|
|
376
|
+
setFocus
|
|
377
|
+
class="max-w-[30rem] lg:max-w-[35rem] w-full block"
|
|
378
|
+
>
|
|
379
|
+
</docs-search>
|
|
380
|
+
</div>
|
|
217
381
|
</div>
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
382
|
+
`
|
|
383
|
+
: nothing
|
|
384
|
+
}`;
|
|
221
385
|
}
|
|
222
386
|
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/** One-line notes for the home index, keyed by sidebar label (taken from each component page). */
|
|
2
|
+
export const COMPONENT_NOTES: Record<string, { tag: string; note: string }> = {
|
|
3
|
+
Alert: { tag: "sonic-alert", note: "Inline feedback: errors, confirmations, contextual help." },
|
|
4
|
+
Badge: { tag: "sonic-badge", note: "Compact label for a status, a count or a category." },
|
|
5
|
+
Button: { tag: "sonic-button", note: "Action or link, with types, variants, sizes and loading." },
|
|
6
|
+
Captcha: { tag: "sonic-captcha", note: "ALTCHA widget wired to the surrounding form data." },
|
|
7
|
+
Card: { tag: "sonic-card", note: "Groups related content on a padded, themed surface." },
|
|
8
|
+
Checkbox: { tag: "sonic-checkbox", note: "Boolean or multi-value field that publishes to a form." },
|
|
9
|
+
Divider: { tag: "sonic-divider", note: "Horizontal or vertical separator, with an optional label." },
|
|
10
|
+
Fieldset: { tag: "sonic-fieldset", note: "Groups related controls under a legend." },
|
|
11
|
+
"Form actions": { tag: "sonic-form-actions", note: "Lays out submit, cancel and other form footer controls." },
|
|
12
|
+
"Form layout": { tag: "sonic-form-layout", note: "Responsive grid for form fields with steady spacing." },
|
|
13
|
+
Group: { tag: "sonic-group", note: "Joins buttons, inputs and selects into one row." },
|
|
14
|
+
Icon: { tag: "sonic-icon", note: "Inline SVG icons from the core set or a CDN library." },
|
|
15
|
+
Image: { tag: "sonic-image", note: "Responsive image with ratio, cover fit and load transition." },
|
|
16
|
+
Input: { tag: "sonic-input", note: "Text field that publishes its value to a form provider." },
|
|
17
|
+
"Input autocomplete": { tag: "sonic-input-autocomplete", note: "Field with suggestions fed by a queue." },
|
|
18
|
+
Link: { tag: "sonic-link", note: "Navigation for routes, anchors and external URLs." },
|
|
19
|
+
Loader: { tag: "sonic-loader", note: "Loading animation, inline or as an overlay." },
|
|
20
|
+
Menu: { tag: "sonic-menu", note: "Row or column of menu items for navigation or actions." },
|
|
21
|
+
Modal: { tag: "sonic-modal", note: "Dialog overlay with title, content and actions." },
|
|
22
|
+
Pop: { tag: "sonic-pop", note: "Floating panel anchored to a trigger." },
|
|
23
|
+
Progress: { tag: "sonic-progress", note: "Completion bar on a value and max scale, or indeterminate." },
|
|
24
|
+
Radio: { tag: "sonic-radio", note: "One choice among several, published to a form." },
|
|
25
|
+
Select: { tag: "sonic-select", note: "Drop-down choice that publishes to a form." },
|
|
26
|
+
Switch: { tag: "sonic-switch", note: "On and off toggle that publishes to a form." },
|
|
27
|
+
Table: { tag: "sonic-table", note: "Tabular data from composable rows and cells." },
|
|
28
|
+
Textarea: { tag: "sonic-textarea", note: "Multi-line text field for forms." },
|
|
29
|
+
Theme: { tag: "sonic-theme", note: "Registers the design tokens and wraps the app." },
|
|
30
|
+
Toast: { tag: "sonic-toast", note: "Short-lived feedback in a fixed stack." },
|
|
31
|
+
Tooltip: { tag: "sonic-tooltip", note: "Short label on hover and focus." },
|
|
32
|
+
Date: { tag: "sonic-date", note: "Formats dates and durations, localised." },
|
|
33
|
+
Fetch: { tag: "sonic-fetch", note: "Loads an endpoint into a data provider." },
|
|
34
|
+
If: { tag: "sonic-if", note: "Shows its content while a condition holds." },
|
|
35
|
+
List: { tag: "sonic-list", note: "Renders a fetched collection with a template." },
|
|
36
|
+
Mix: { tag: "sonic-mix", note: "Merges several data providers into one." },
|
|
37
|
+
Jsonata: { tag: "sonic-jsonata", note: "Transforms data with a JSONata expression." },
|
|
38
|
+
Queue: { tag: "sonic-queue", note: "Paginated, lazy-loaded lists, page after page." },
|
|
39
|
+
Router: { tag: "sonic-router", note: "Renders the view that matches the location." },
|
|
40
|
+
SDUI: { tag: "sonic-sdui", note: "Builds an interface from a JSON descriptor." },
|
|
41
|
+
States: { tag: "sonic-states", note: "Switches content on a data value or a pattern." },
|
|
42
|
+
Submit: { tag: "sonic-submit", note: "Sends a form provider to an API endpoint." },
|
|
43
|
+
Value: { tag: "sonic-value", note: "Prints a live value from a data provider." },
|
|
44
|
+
};
|