@supersoniks/concorde 5.0.5 → 5.1.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/.github/workflows/ci.yml +21 -0
- package/.github-export-ignore +30 -0
- package/.tmp-cem/custom-elements.json +13705 -0
- package/CONTRIBUTING.md +59 -0
- package/DEV.md +54 -0
- package/LICENSE +21 -0
- package/OPEN_SOURCE_CHECKPOINT.md +133 -0
- package/build-infos.json +1 -1
- package/concorde-3d.bundle.js +3960 -0
- package/concorde-3d.es.js +33433 -0
- package/concorde-core.bundle.js +196 -196
- package/concorde-core.es.js +3685 -3405
- package/concorde-hugging-face-infer.bundle.js +32 -0
- package/concorde-hugging-face-infer.es.js +2952 -0
- package/concorde-interactive.bundle.js +1157 -0
- package/concorde-interactive.es.js +10734 -0
- package/concorde-shader.bundle.js +116 -0
- package/concorde-shader.es.js +8353 -0
- package/concorde-webgpu.bundle.js +307 -0
- package/concorde-webgpu.es.js +8627 -0
- package/custom-elements-manifest.config.mjs +14 -0
- package/dist/concorde-core.bundle.js +196 -196
- package/dist/concorde-core.es.js +3685 -3405
- package/docs/assets/{index-wVZpLVYW.js → index-D8MVWqY6.js} +1351 -1222
- package/docs/assets/index-DiD0qYvE.css +1 -0
- package/docs/crawl/core/components/ui/alert/alert.html +71 -172
- package/docs/crawl/core/components/ui/alert-messages/alert-messages.html +5 -113
- package/docs/crawl/core/components/ui/badge/badge.html +79 -157
- package/docs/crawl/core/components/ui/button/button.html +0 -1
- package/docs/crawl/core/components/ui/captcha/captcha.html +8 -90
- package/docs/crawl/core/components/ui/card/card.html +68 -222
- package/docs/crawl/core/components/ui/divider/divider.html +31 -117
- package/docs/crawl/core/components/ui/form/fieldset/fieldset.html +101 -232
- package/docs/crawl/core/components/ui/form/form-actions/form-actions.html +52 -95
- package/docs/crawl/core/components/ui/form/form-layout/form-layout.html +38 -97
- package/docs/crawl/core/components/ui/form/input/input.html +3 -3
- package/docs/crawl/core/components/ui/form/textarea/textarea.html +3 -3
- package/docs/crawl/core/components/ui/group/group.html +38 -60
- package/docs/crawl/core/components/ui/icon/icon.html +47 -136
- package/docs/crawl/core/components/ui/image/image.html +56 -244
- package/docs/crawl/core/components/ui/link/link.html +9 -67
- package/docs/crawl/core/components/ui/loader/loader.html +23 -97
- package/docs/crawl/core/components/ui/menu/menu.html +90 -162
- package/docs/crawl/core/components/ui/modal/modal.html +50 -275
- package/docs/crawl/core/components/ui/pop/pop.html +66 -260
- package/docs/crawl/core/components/ui/progress/progress.html +30 -103
- package/docs/crawl/core/components/ui/table/table.html +171 -303
- package/docs/crawl/core/components/ui/toast/toast.html +59 -170
- package/docs/crawl/core/components/ui/tooltip/tooltip.html +29 -90
- package/docs/crawl/docs/_decorators/ancestor-attribute.html +2 -3
- package/docs/crawl/docs/_getting-started/concorde-outside.html +3 -3
- package/docs/crawl/docs/_getting-started/start.html +1 -1
- package/docs/crawl/docs/_getting-started/theming.html +63 -311
- package/docs/crawl/hubs/form-components.html +53 -75
- package/docs/crawl/index.html +6 -7
- package/docs/docs-mock-api-sw.js +0 -2
- package/docs/docs-mock-api-sw.js.map +2 -2
- package/docs/index.html +7 -9
- package/docs/llms-full.txt +456 -1703
- package/docs/llms.txt +32 -25
- package/docs/sitemap.xml +0 -3
- package/docs/src/core/components/functional/fetch/fetch.md +0 -0
- package/docs/src/core/components/functional/if/if.md +0 -0
- package/docs/src/core/components/functional/list/list.md +0 -0
- package/docs/src/core/components/functional/router/router.md +0 -0
- package/docs/src/core/components/functional/sdui/sdui.md +0 -0
- package/docs/src/core/components/functional/states/states.md +0 -0
- package/docs/src/core/components/functional/submit/submit.md +0 -0
- package/docs/src/core/components/ui/alert/alert.md +72 -147
- package/docs/src/core/components/ui/alert-messages/alert-messages.md +0 -85
- package/docs/src/core/components/ui/badge/badge.md +80 -141
- package/docs/src/core/components/ui/button/button.md +0 -1
- package/docs/src/core/components/ui/captcha/captcha.md +6 -65
- package/docs/src/core/components/ui/card/card.md +65 -183
- package/docs/src/core/components/ui/divider/divider.md +13 -107
- package/docs/src/core/components/ui/form/fieldset/fieldset.md +99 -175
- package/docs/src/core/components/ui/form/form-actions/form-actions.md +52 -75
- package/docs/src/core/components/ui/form/form-layout/form-layout.md +34 -109
- package/docs/src/core/components/ui/form/input/input.md +1 -1
- package/docs/src/core/components/ui/form/radio/radio.md +0 -0
- package/docs/src/core/components/ui/form/select/select.md +0 -0
- package/docs/src/core/components/ui/form/switch/switch.md +0 -0
- package/docs/src/core/components/ui/form/textarea/textarea.md +1 -1
- package/docs/src/core/components/ui/group/group.md +36 -36
- package/docs/src/core/components/ui/icon/icon.md +43 -132
- package/docs/src/core/components/ui/image/image.md +53 -179
- package/docs/src/core/components/ui/link/link.md +7 -45
- package/docs/src/core/components/ui/loader/loader.md +22 -79
- package/docs/src/core/components/ui/menu/menu.md +92 -133
- package/docs/src/core/components/ui/modal/modal.md +47 -163
- package/docs/src/core/components/ui/pop/pop.md +64 -262
- package/docs/src/core/components/ui/progress/progress.md +30 -76
- package/docs/src/core/components/ui/table/table.md +171 -147
- package/docs/src/core/components/ui/toast/toast.md +58 -108
- package/docs/src/core/components/ui/tooltip/tooltip.md +26 -68
- package/docs/src/docs/_core-concept/subscriber.md +0 -0
- package/docs/src/docs/_decorators/ancestor-attribute.md +2 -3
- package/docs/src/docs/_getting-started/concorde-outside.md +3 -3
- package/docs/src/docs/_getting-started/my-first-subscriber.md +0 -0
- package/docs/src/docs/_getting-started/pubsub.md +0 -0
- package/docs/src/docs/_getting-started/start.md +1 -1
- package/docs/src/docs/_getting-started/theming.md +61 -223
- package/docs/src/docs/search/docs-search.json +348 -3083
- package/docs/src/tsconfig.declarations.json +22 -0
- package/docs/src/tsconfig.emit.json +23 -0
- package/docs/src/tsconfig.json +3 -63
- package/gitlab/job_github_mirror.sh +39 -0
- package/package.json +36 -2
- package/scripts/generate-sdui-catalog.mjs +250 -0
- package/scripts/generate-sdui-catalog.spec.ts +91 -0
- package/scripts/github-export.mjs +150 -0
- package/scripts/post-build-docs.js +0 -0
- package/scripts/post-build.mjs +0 -0
- package/scripts/pre-build.mjs +15 -0
- package/src/core/components/functional/fetch/fetch.md +0 -0
- 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 +5 -5
- package/src/core/components/functional/sdui/__fixtures__/descriptors.ts +251 -0
- package/src/core/components/functional/sdui/__snapshots__/sdui-action.spec.ts.snap +73 -0
- package/src/core/components/functional/sdui/__snapshots__/sdui-incremental.spec.ts.snap +50 -0
- package/src/core/components/functional/sdui/__snapshots__/sdui-partial.spec.ts.snap +50 -0
- package/src/core/components/functional/sdui/__snapshots__/sdui.regression.spec.ts.snap +461 -0
- package/src/core/components/functional/sdui/component-catalog.gaps.json +511 -0
- package/src/core/components/functional/sdui/component-catalog.json +3103 -0
- package/src/core/components/functional/sdui/component-catalog.spec.ts +23 -0
- package/src/core/components/functional/sdui/sdui-action.spec.ts +99 -0
- package/src/core/components/functional/sdui/sdui-dom-snapshot.ts +61 -0
- package/src/core/components/functional/sdui/sdui-extension-points.md +94 -0
- package/src/core/components/functional/sdui/sdui-incremental.spec.ts +137 -0
- package/src/core/components/functional/sdui/sdui-partial.spec.ts +83 -0
- package/src/core/components/functional/sdui/sdui-partial.ts +19 -0
- package/src/core/components/functional/sdui/sdui-safe.spec.ts +188 -0
- package/src/core/components/functional/sdui/sdui-safe.ts +100 -0
- package/src/core/components/functional/sdui/sdui.md +122 -0
- package/src/core/components/functional/sdui/sdui.regression.spec.ts +64 -0
- package/src/core/components/functional/sdui/sdui.ts +442 -34
- package/src/core/components/functional/sdui/types.ts +49 -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/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/css.d.ts +19 -0
- package/src/docs/_core-concept/subscriber.md +0 -0
- package/src/docs/_getting-started/my-first-subscriber.md +0 -0
- package/src/docs/_getting-started/pubsub.md +0 -0
- package/src/docs/example/users.ts +0 -0
- package/src/docs/search/page.ts +0 -0
- package/src/tsconfig.declarations.json +22 -0
- package/src/tsconfig.emit.json +23 -0
- package/src/tsconfig.json +90 -0
- package/src/tsconfig.tsbuildinfo +1 -1
- package/docs/assets/index-CD4WyL6o.css +0 -1
- package/docs/crawl/core/components/ui/theme/theme.html +0 -131
- package/docs/src/core/components/ui/theme/theme.md +0 -122
package/docs/llms.txt
CHANGED
|
@@ -29,36 +29,43 @@ Full text: https://concorde.supersoniks.org/llms-full.txt
|
|
|
29
29
|
- [Submit](https://concorde.supersoniks.org/crawl/core/components/functional/submit/submit.html) (core/components/functional/submit/submit): > Live demos: <docs-lit-demo> + src/docs/example/docs-submit-demos.ts. Use Local API demos (serviceURL="/docs-mock-api").
|
|
30
30
|
- [Subscriber](https://concorde.supersoniks.org/crawl/core/components/functional/subscriber/subscriber.html) (core/components/functional/subscriber/subscriber): La mixin Subscriber permet lier un composant à un publisher.
|
|
31
31
|
- [Value](https://concorde.supersoniks.org/crawl/core/components/functional/value/value.html) (core/components/functional/value/value): Simply shows a value from a data provider.
|
|
32
|
-
- [
|
|
33
|
-
- [Alert](https://concorde.supersoniks.org/crawl/core/components/ui/alert/alert.html) (core/components/ui/alert/alert):
|
|
34
|
-
- [Badge](https://concorde.supersoniks.org/crawl/core/components/ui/badge/badge.html) (core/components/ui/badge/badge):
|
|
32
|
+
- [Concorde](https://concorde.supersoniks.org/crawl/core/components/ui/alert-messages/alert-messages.html) (core/components/ui/alert-messages/alert-messages): Concorde documentation: Concorde
|
|
33
|
+
- [Alert](https://concorde.supersoniks.org/crawl/core/components/ui/alert/alert.html) (core/components/ui/alert/alert): This address is already in use. Lorem ipsum dolor sit amet.
|
|
34
|
+
- [Badge](https://concorde.supersoniks.org/crawl/core/components/ui/badge/badge.html) (core/components/ui/badge/badge): Messages <sonic-badge slot="suffix" type="danger" size="xs">5</sonic-badge>
|
|
35
35
|
- [Button](https://concorde.supersoniks.org/crawl/core/components/ui/button/button.html) (core/components/ui/button/button): The length of the button depends on the size of its content
|
|
36
|
-
- [Captcha](https://concorde.supersoniks.org/crawl/core/components/ui/captcha/captcha.html) (core/components/ui/captcha/captcha):
|
|
37
|
-
- [Card](https://concorde.supersoniks.org/crawl/core/components/ui/card/card.html) (core/components/ui/card/card):
|
|
38
|
-
- [Divider](https://concorde.supersoniks.org/crawl/core/components/ui/divider/divider.html) (core/components/ui/divider/divider):
|
|
36
|
+
- [Captcha](https://concorde.supersoniks.org/crawl/core/components/ui/captcha/captcha.html) (core/components/ui/captcha/captcha): Captcha: Submit with captcha
|
|
37
|
+
- [Card](https://concorde.supersoniks.org/crawl/core/components/ui/card/card.html) (core/components/ui/card/card): Suffix
|
|
38
|
+
- [Divider](https://concorde.supersoniks.org/crawl/core/components/ui/divider/divider.html) (core/components/ui/divider/divider): Default
|
|
39
|
+
|
|
40
|
+
Align
|
|
41
|
+
|
|
42
|
+
Size
|
|
43
|
+
|
|
44
|
+
Custom
|
|
45
|
+
|
|
46
|
+
Lorem ipsum dolor sit amet +25
|
|
39
47
|
- [Checkbox](https://concorde.supersoniks.org/crawl/core/components/ui/form/checkbox/checkbox.html) (core/components/ui/form/checkbox/checkbox): >Already checked checkbox
|
|
40
|
-
- [Fieldset](https://concorde.supersoniks.org/crawl/core/components/ui/form/fieldset/fieldset.html) (core/components/ui/form/fieldset/fieldset):
|
|
41
|
-
- [Form
|
|
42
|
-
- [Form
|
|
48
|
+
- [Fieldset](https://concorde.supersoniks.org/crawl/core/components/ui/form/fieldset/fieldset.html) (core/components/ui/form/fieldset/fieldset): Default
|
|
49
|
+
- [Form-actions](https://concorde.supersoniks.org/crawl/core/components/ui/form/form-actions/form-actions.html) (core/components/ui/form/form-actions/form-actions): Left seats
|
|
50
|
+
- [Form-layout](https://concorde.supersoniks.org/crawl/core/components/ui/form/form-layout/form-layout.html) (core/components/ui/form/form-layout/form-layout): autocomplete="email"
|
|
43
51
|
- [Input-autocomplete](https://concorde.supersoniks.org/crawl/core/components/ui/form/input-autocomplete/input-autocomplete.html) (core/components/ui/form/input-autocomplete/input-autocomplete): Champ formulaire + suggestions via queue. Valeur via formDataProvider + name ; la recherche filtre la queue (store interne).
|
|
44
|
-
- [Input](https://concorde.supersoniks.org/crawl/core/components/ui/form/input/input.html) (core/components/ui/form/input/input): Native
|
|
52
|
+
- [Input](https://concorde.supersoniks.org/crawl/core/components/ui/form/input/input.html) (core/components/ui/form/input/input): Native attibutes list
|
|
45
53
|
- [Radio](https://concorde.supersoniks.org/crawl/core/components/ui/form/radio/radio.html) (core/components/ui/form/radio/radio): >Already checked radio
|
|
46
54
|
- [Select](https://concorde.supersoniks.org/crawl/core/components/ui/form/select/select.html) (core/components/ui/form/select/select): {"value":"dark", "wording":"dark (set by \"attribute\")", "selected" : "true"}, {"value":"auto", "wording":"auto"}
|
|
47
55
|
- [Switch](https://concorde.supersoniks.org/crawl/core/components/ui/form/switch/switch.html) (core/components/ui/form/switch/switch): >Already checked switch
|
|
48
|
-
- [Textarea](https://concorde.supersoniks.org/crawl/core/components/ui/form/textarea/textarea.html) (core/components/ui/form/textarea/textarea): Native
|
|
49
|
-
- [Group](https://concorde.supersoniks.org/crawl/core/components/ui/group/group.html) (core/components/ui/group/group):
|
|
50
|
-
- [Icon](https://concorde.supersoniks.org/crawl/core/components/ui/icon/icon.html) (core/components/ui/icon/icon):
|
|
51
|
-
- [Image](https://concorde.supersoniks.org/crawl/core/components/ui/image/image.html) (core/components/ui/image/image):
|
|
52
|
-
- [Link](https://concorde.supersoniks.org/crawl/core/components/ui/link/link.html) (core/components/ui/link/link):
|
|
53
|
-
- [Loader](https://concorde.supersoniks.org/crawl/core/components/ui/loader/loader.html) (core/components/ui/loader/loader):
|
|
54
|
-
- [Menu](https://concorde.supersoniks.org/crawl/core/components/ui/menu/menu.html) (core/components/ui/menu/menu):
|
|
55
|
-
- [
|
|
56
|
-
- [Pop](https://concorde.supersoniks.org/crawl/core/components/ui/pop/pop.html) (core/components/ui/pop/pop):
|
|
57
|
-
- [Progress](https://concorde.supersoniks.org/crawl/core/components/ui/progress/progress.html) (core/components/ui/progress/progress):
|
|
58
|
-
- [Table](https://concorde.supersoniks.org/crawl/core/components/ui/table/table.html) (core/components/ui/table/table):
|
|
59
|
-
- [
|
|
60
|
-
- [
|
|
61
|
-
- [Tooltip](https://concorde.supersoniks.org/crawl/core/components/ui/tooltip/tooltip.html) (core/components/ui/tooltip/tooltip): Tooltip shows a short label on hover (and on focus when the trigger can receive focus). Wrap the trigger in the default slot—buttons, icons, or plain text. Default placement is top (center-aligned). A
|
|
56
|
+
- [Textarea](https://concorde.supersoniks.org/crawl/core/components/ui/form/textarea/textarea.html) (core/components/ui/form/textarea/textarea): Native attibutes list
|
|
57
|
+
- [Group](https://concorde.supersoniks.org/crawl/core/components/ui/group/group.html) (core/components/ui/group/group): Group: 😎 Standard ⭐ Premium 💎 Diamond
|
|
58
|
+
- [Icon](https://concorde.supersoniks.org/crawl/core/components/ui/icon/icon.html) (core/components/ui/icon/icon): customIconDefaultPrefix="regular">
|
|
59
|
+
- [Image](https://concorde.supersoniks.org/crawl/core/components/ui/image/image.html) (core/components/ui/image/image): src="https://thegoodlife.fr/wp-content/uploads/sites/2/2022/03/compagnies-aeriennes-nostalgie-coeur-insert-03-dr.jpg"
|
|
60
|
+
- [Link](https://concorde.supersoniks.org/crawl/core/components/ui/link/link.html) (core/components/ui/link/link): Link: Basic link with href attibute
|
|
61
|
+
- [Loader](https://concorde.supersoniks.org/crawl/core/components/ui/loader/loader.html) (core/components/ui/loader/loader): import {Loader} from "@supersoniks/concorde/core/components/ui/loader/loader";
|
|
62
|
+
- [Menu](https://concorde.supersoniks.org/crawl/core/components/ui/menu/menu.html) (core/components/ui/menu/menu): Row
|
|
63
|
+
- [Concorde](https://concorde.supersoniks.org/crawl/core/components/ui/modal/modal.html) (core/components/ui/modal/modal): Concorde: Simple modal Lorem ipsum dolor sit amet +33 Donec sed vestibulum augue. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed eget quam eu mi luctus faucibus. Click don't close Confir
|
|
64
|
+
- [Pop](https://concorde.supersoniks.org/crawl/core/components/ui/pop/pop.html) (core/components/ui/pop/pop): Click to open pop
|
|
65
|
+
- [Progress bar](https://concorde.supersoniks.org/crawl/core/components/ui/progress/progress.html) (core/components/ui/progress/progress): Displays an indicator showing the completion progress of a task.
|
|
66
|
+
- [Table](https://concorde.supersoniks.org/crawl/core/components/ui/table/table.html) (core/components/ui/table/table): Values available : primary, info, success, warning, danger
|
|
67
|
+
- [Toast](https://concorde.supersoniks.org/crawl/core/components/ui/toast/toast.html) (core/components/ui/toast/toast): Afficher un toast
|
|
68
|
+
- [Tooltip](https://concorde.supersoniks.org/crawl/core/components/ui/tooltip/tooltip.html) (core/components/ui/tooltip/tooltip): By default, tooltip is centered next to its content
|
|
62
69
|
- [Data flow](https://concorde.supersoniks.org/crawl/docs/_core-concept/dataFlow.html) (docs/_core-concept/dataFlow): Recommended patterns for new Concorde apps (Lit + TypeScript). Under the hood, data lives in a DataProvider store (legacy Publisher API: Legacy: Sharing data).
|
|
63
70
|
- [lit + tailwind + vite](https://concorde.supersoniks.org/crawl/docs/_core-concept/overview.html) (docs/_core-concept/overview): Some notes for an overview of Concorde's functioning
|
|
64
71
|
- [Legacy: Subscriber mixin](https://concorde.supersoniks.org/crawl/docs/_core-concept/subscriber.html) (docs/_core-concept/subscriber): > New app components: My first component and Data flow — extend LitElement with decorators (@subscribe, @ancestorAttribute, …). This mixin remains in core components (sonic-list, sonic-fetch, …) and l
|
|
@@ -83,7 +90,7 @@ Full text: https://concorde.supersoniks.org/llms-full.txt
|
|
|
83
90
|
- [Legacy: My first subscriber component](https://concorde.supersoniks.org/crawl/docs/_getting-started/my-first-subscriber.html) (docs/_getting-started/my-first-subscriber): > New projects: use My first component (@ancestorAttribute, @subscribe + DataProviderKey, .items on lists) and Data flow. This page documents the Subscriber mixin used by older apps and core component
|
|
84
91
|
- [Legacy: Sharing data](https://concorde.supersoniks.org/crawl/docs/_getting-started/pubsub.html) (docs/_getting-started/pubsub): > New apps: Data flow (get / set / DataProviderKey, decorators). This page documents the historical Publisher proxy API (PublisherManager, publisher.set, onAssign, …).
|
|
85
92
|
- [Introduction](https://concorde.supersoniks.org/crawl/docs/_getting-started/start.html) (docs/_getting-started/start): Based on lit.dev, Concorde is a collection of web components for shared apps and websites.
|
|
86
|
-
- [
|
|
93
|
+
- [Adding styles](https://concorde.supersoniks.org/crawl/docs/_getting-started/theming.html) (docs/_getting-started/theming): No style crosses the shadow root of a component, except for inheritable properties (which have the "inherit" property possible) and CSS variables.
|
|
87
94
|
- [API configuration](https://concorde.supersoniks.org/crawl/docs/_misc/api-configuration.html) (docs/_misc/api-configuration): APIConfiguration is the object built by HTML.getApiConfiguration from ancestor attributes on the DOM (or from a typed publisher — see @get / @post configuration key). It is passed to API by fetchers,
|
|
88
95
|
- [DataProviderKey](https://concorde.supersoniks.org/crawl/docs/_misc/dataProviderKey.html) (docs/_misc/dataProviderKey): The DataProviderKey<T> utility provides type-safe navigation through composite data structures. Each property or index access extends the path, and the final key can be retrieved via toString() or the
|
|
89
96
|
- [Local API demos (offline)](https://concorde.supersoniks.org/crawl/docs/_misc/docs-mock-api.html) (docs/_misc/docs-mock-api): The Concorde doc site does not call fragile third-party APIs during yarn dev. A Service Worker and the Vite dev middleware serve /docs-mock-api/* on the same origin.
|
package/docs/sitemap.xml
CHANGED
|
@@ -132,9 +132,6 @@
|
|
|
132
132
|
<url>
|
|
133
133
|
<loc>https://concorde.supersoniks.org/crawl/core/components/ui/table/table.html</loc>
|
|
134
134
|
</url>
|
|
135
|
-
<url>
|
|
136
|
-
<loc>https://concorde.supersoniks.org/crawl/core/components/ui/theme/theme.html</loc>
|
|
137
|
-
</url>
|
|
138
135
|
<url>
|
|
139
136
|
<loc>https://concorde.supersoniks.org/crawl/core/components/ui/toast/toast.html</loc>
|
|
140
137
|
</url>
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
# Alert
|
|
2
2
|
|
|
3
|
-
Alerts **surface important feedback** inline—errors, confirmations, or contextual help. Use **`label`** / **`text`** for simple copy, or the **default slot** for rich content (links, buttons). Set **`announce`** when the message appears after an action so screen readers pick it up.
|
|
4
|
-
|
|
5
|
-
## Basic example
|
|
6
|
-
|
|
7
3
|
<sonic-code>
|
|
8
4
|
<template>
|
|
9
5
|
<sonic-alert status="error" label="Email error" text="This address is already in use" background></sonic-alert>
|
|
@@ -12,52 +8,15 @@ Alerts **surface important feedback** inline—errors, confirmations, or context
|
|
|
12
8
|
|
|
13
9
|
## Status
|
|
14
10
|
|
|
15
|
-
Color and icon follow `status`. With no `status`, behavior is `default`.
|
|
16
|
-
|
|
17
|
-
<sonic-code>
|
|
18
|
-
<template>
|
|
19
|
-
<div class="grid gap-4">
|
|
20
|
-
<sonic-alert label="Default">This address is already in use.</sonic-alert>
|
|
21
|
-
<sonic-alert status="success" label="Success">This address is already in use.</sonic-alert>
|
|
22
|
-
<sonic-alert status="error" label="Error">This address is already in use.</sonic-alert>
|
|
23
|
-
<sonic-alert status="warning" label="Warning">This address is already in use.</sonic-alert>
|
|
24
|
-
<sonic-alert status="info" label="Info">This address is already in use.</sonic-alert>
|
|
25
|
-
</div>
|
|
26
|
-
</template>
|
|
27
|
-
</sonic-code>
|
|
28
|
-
|
|
29
|
-
## Accessibility (`announce`)
|
|
30
|
-
|
|
31
|
-
By default, an alert already in the DOM is **not** announced (no `role` / `aria-live`). Set **`announce`** when the message appears **after** user action (API response, validation, etc.): screen readers get `role="alert"` for `error`, otherwise `role="status"` and `aria-live="polite"`.
|
|
32
|
-
|
|
33
|
-
`sonic-alert-messages` sets `announce` on every rendered alert.
|
|
34
|
-
|
|
35
|
-
<sonic-code>
|
|
36
|
-
<template>
|
|
37
|
-
<sonic-alert announce status="success" label="Saved" text="Your changes were saved."></sonic-alert>
|
|
38
|
-
</template>
|
|
39
|
-
</sonic-code>
|
|
40
|
-
|
|
41
|
-
## Content and icon
|
|
42
|
-
|
|
43
|
-
`label` and `text` accept plain text only. The default slot is rendered after `text`. Use the **`icon`** slot to replace the default `sonic-icon`. **`noIcon`** hides the icon.
|
|
44
|
-
|
|
45
11
|
<sonic-code>
|
|
46
12
|
<template>
|
|
47
|
-
|
|
48
|
-
</
|
|
49
|
-
</sonic-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
<sonic-code>
|
|
56
|
-
<template>
|
|
57
|
-
<sonic-alert status="success" label="Achievement unlocked" background>
|
|
58
|
-
<span slot="icon" aria-hidden="true" class="text-lg leading-none">🎉</span>
|
|
59
|
-
You unlocked a new badge.
|
|
60
|
-
</sonic-alert>
|
|
13
|
+
<div class="grid gap-4">
|
|
14
|
+
<sonic-alert label="Default"> This address is already in use. </sonic-alert>
|
|
15
|
+
<sonic-alert status="success" label="Success"> This address is already in use. </sonic-alert>
|
|
16
|
+
<sonic-alert status="error" label="Error"> This address is already in use. </sonic-alert>
|
|
17
|
+
<sonic-alert status="warning" label="Warning"> This address is already in use. </sonic-alert>
|
|
18
|
+
<sonic-alert status="info" label="Info"> This address is already in use. </sonic-alert>
|
|
19
|
+
</div>
|
|
61
20
|
</template>
|
|
62
21
|
</sonic-code>
|
|
63
22
|
|
|
@@ -65,132 +24,98 @@ Project any markup into **`slot="icon"`** (emoji, image, custom component). Keep
|
|
|
65
24
|
|
|
66
25
|
<sonic-code>
|
|
67
26
|
<template>
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
27
|
+
<div class="grid gap-4">
|
|
28
|
+
<sonic-alert status="error" label="Email error" size="2xs">
|
|
29
|
+
This address is already in use. Lorem ipsum dolor sit amet.
|
|
30
|
+
</sonic-alert>
|
|
31
|
+
<sonic-alert status="error" label="Email error" size="xs">
|
|
32
|
+
This address is already in use. Lorem ipsum dolor sit amet.
|
|
33
|
+
</sonic-alert>
|
|
34
|
+
<sonic-alert status="error" label="Email error" size="sm">
|
|
35
|
+
This address is already in use. Lorem ipsum dolor sit amet.
|
|
36
|
+
</sonic-alert>
|
|
37
|
+
<sonic-alert status="error" label="Email error">
|
|
38
|
+
This address is already in use. Lorem ipsum dolor sit amet.
|
|
39
|
+
</sonic-alert>
|
|
40
|
+
<sonic-alert status="error" label="Email error" size="lg">
|
|
41
|
+
This address is already in use. Lorem ipsum dolor sit amet.
|
|
42
|
+
</sonic-alert>
|
|
43
|
+
<sonic-alert status="error" label="Email error" size="xl">
|
|
44
|
+
This address is already in use. Lorem ipsum dolor sit amet.
|
|
45
|
+
</sonic-alert>
|
|
46
|
+
<sonic-alert status="error" label="Email error" size="2xl">
|
|
47
|
+
This address is already in use. Lorem ipsum dolor sit amet.
|
|
48
|
+
</sonic-alert>
|
|
49
|
+
</div>
|
|
91
50
|
</template>
|
|
92
51
|
</sonic-code>
|
|
93
52
|
|
|
94
53
|
## Alert with link
|
|
95
54
|
|
|
96
|
-
Rich content in the slot (buttons, links).
|
|
97
|
-
|
|
98
55
|
<sonic-code>
|
|
99
56
|
<template>
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
57
|
+
<sonic-alert status="info" label="New messages !">
|
|
58
|
+
You have 2 unread messages<br />
|
|
59
|
+
<div class="flex gap-2 mt-1">
|
|
60
|
+
<sonic-button variant="outline" type="info" size="xs">See messages</sonic-button>
|
|
61
|
+
<sonic-button variant="ghost" type="info" size="xs">dismiss</sonic-button>
|
|
62
|
+
</div>
|
|
63
|
+
</sonic-alert>
|
|
107
64
|
</template>
|
|
108
65
|
</sonic-code>
|
|
109
66
|
|
|
110
67
|
## Background
|
|
111
68
|
|
|
112
|
-
Tinted background from the `status` color (`color-mix` on `currentColor`).
|
|
113
|
-
|
|
114
69
|
<sonic-code>
|
|
115
70
|
<template>
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
71
|
+
<div class="grid gap-4">
|
|
72
|
+
<sonic-alert background label="Lorem ipsum dolor">
|
|
73
|
+
This address is already in use.
|
|
74
|
+
</sonic-alert>
|
|
75
|
+
<sonic-alert status="success" background label="Lorem ipsum dolor">
|
|
76
|
+
This address is already in use.
|
|
77
|
+
</sonic-alert>
|
|
78
|
+
<sonic-alert status="error" background label="Lorem ipsum dolor">
|
|
79
|
+
This address is already in use.
|
|
80
|
+
</sonic-alert>
|
|
81
|
+
<sonic-alert status="warning" background label="Lorem ipsum dolor">
|
|
82
|
+
This address is already in use.
|
|
83
|
+
</sonic-alert>
|
|
84
|
+
<sonic-alert status="info" background label="Lorem ipsum dolor">
|
|
85
|
+
This address is already in use.
|
|
86
|
+
</sonic-alert>
|
|
87
|
+
</div>
|
|
131
88
|
</template>
|
|
132
89
|
</sonic-code>
|
|
133
90
|
|
|
134
91
|
## Dismissible
|
|
135
92
|
|
|
136
|
-
`dismissible` removes the alert from the DOM when the close control is clicked (i18n aria label). **`dismissible`** and **`background`** are independent: without `background`, close sits at the end of the row; with `background`, top-right.
|
|
137
|
-
|
|
138
93
|
<sonic-code>
|
|
139
94
|
<template>
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
This address is already in use.
|
|
156
|
-
</sonic-alert>
|
|
95
|
+
<sonic-alert class="mb-3" dismissible label="Lorem ipsum dolor">
|
|
96
|
+
This address is already in use.
|
|
97
|
+
</sonic-alert>
|
|
98
|
+
<sonic-alert status="success" class="mb-3" dismissible label="Lorem ipsum dolor">
|
|
99
|
+
This address is already in use.
|
|
100
|
+
</sonic-alert>
|
|
101
|
+
<sonic-alert status="error" class="mb-3" dismissible label="Lorem ipsum dolor">
|
|
102
|
+
This address is already in use.
|
|
103
|
+
</sonic-alert>
|
|
104
|
+
<sonic-alert status="warning" class="mb-3" dismissible label="Lorem ipsum dolor">
|
|
105
|
+
This address is already in use.
|
|
106
|
+
</sonic-alert>
|
|
107
|
+
<sonic-alert status="info" class="mb-3" dismissible label="Lorem ipsum dolor">
|
|
108
|
+
This address is already in use.
|
|
109
|
+
</sonic-alert>
|
|
157
110
|
</template>
|
|
158
111
|
</sonic-code>
|
|
159
112
|
|
|
160
113
|
## Dismiss forever
|
|
161
114
|
|
|
162
|
-
With **`dismissForever`**, dismissal is stored in `localStorage` (key `sonic-alert-dismissed`). A stable **`id`** on the element is **required**; without `id`, a warning is logged and nothing is persisted.
|
|
163
|
-
|
|
164
115
|
<sonic-code>
|
|
165
116
|
<template>
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
background
|
|
170
|
-
dismissForever
|
|
171
|
-
label="Lorem ipsum dolor"
|
|
172
|
-
id="addressUniqueId"
|
|
173
|
-
>
|
|
174
|
-
This address is already in use.
|
|
175
|
-
</sonic-alert>
|
|
117
|
+
<sonic-alert class="mb-3" dismissible dismissForever label="Lorem ipsum dolor" id="addressUniqueId">
|
|
118
|
+
This address is already in use.
|
|
119
|
+
</sonic-alert>
|
|
176
120
|
</template>
|
|
177
121
|
</sonic-code>
|
|
178
|
-
|
|
179
|
-
## API reference
|
|
180
|
-
|
|
181
|
-
| Attribute | Values | Description |
|
|
182
|
-
|----------|---------|-------------|
|
|
183
|
-
| `status` | `default` · `info` · `success` · `warning` · `error` | Color and default icon |
|
|
184
|
-
| `label` | string | Title (plain text) |
|
|
185
|
-
| `text` | string | Short body (plain text), rendered before the slot |
|
|
186
|
-
| `size` | `2xs` … `2xl` | Corner radius and typography |
|
|
187
|
-
| `background` | boolean | Tinted background (`color-mix` on status color) |
|
|
188
|
-
| `dismissible` | boolean | Close control; removes the element from the DOM |
|
|
189
|
-
| `dismissForever` | boolean | Persists dismissal in `localStorage`; requires **`id`** |
|
|
190
|
-
| `noIcon` | boolean | Hides the icon (including custom `icon` slot content) |
|
|
191
|
-
| `announce` | boolean | `role="alert"` / `aria-live` for dynamically injected content |
|
|
192
|
-
|
|
193
|
-
| Slot | Description |
|
|
194
|
-
|------|-------------|
|
|
195
|
-
| *(default)* | Message body (HTML, actions); rendered after `text` |
|
|
196
|
-
| `icon` | Replaces the default `sonic-icon` |
|
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
# Alert messages
|
|
2
|
-
|
|
3
|
-
**`sonic-alert-messages`** renders a vertical stack of **`sonic-alert`** items from a **`messages`** array on a linked **data provider** (typical pattern: **`submitResultDataProvider`** after a form submit). Only entries with **`type="public"`** are shown. Each alert gets **`announce`** so screen readers pick up feedback after the request.
|
|
4
|
-
|
|
5
|
-
## With submit result
|
|
6
|
-
|
|
7
|
-
Bind **`dataProvider`** to the same publisher as **`submitResultDataProvider`**. API **`messages`** entries need **`type`**: **`public`**, plus **`content`** and optional **`status`** (`warning` · `success` · `error` · `info`).
|
|
8
|
-
|
|
9
|
-
<sonic-code>
|
|
10
|
-
<template>
|
|
11
|
-
<sonic-scope
|
|
12
|
-
serviceURL="/docs-mock-api"
|
|
13
|
-
formDataProvider="submit-example"
|
|
14
|
-
submitResultDataProvider="submit-example-result"
|
|
15
|
-
>
|
|
16
|
-
<sonic-alert-messages dataProvider="submit-example-result" background class="mb-4"></sonic-alert-messages>
|
|
17
|
-
<div class="grid gap-4 max-w-md">
|
|
18
|
-
<sonic-input name="email" type="email" label="Email" value=""></sonic-input>
|
|
19
|
-
<sonic-input name="password" type="password" label="Password" value=""></sonic-input>
|
|
20
|
-
<sonic-submit endPoint="api/register" onClick>
|
|
21
|
-
<sonic-button type="primary">Submit (empty fields → error messages)</sonic-button>
|
|
22
|
-
</sonic-submit>
|
|
23
|
-
</div>
|
|
24
|
-
</sonic-scope>
|
|
25
|
-
</template>
|
|
26
|
-
</sonic-code>
|
|
27
|
-
|
|
28
|
-
## Shared alert props
|
|
29
|
-
|
|
30
|
-
**`size`** · **`background`** and **`noIcon`** apply to every rendered **`sonic-alert`** in the list.
|
|
31
|
-
|
|
32
|
-
<sonic-code>
|
|
33
|
-
<template>
|
|
34
|
-
<sonic-button
|
|
35
|
-
size="sm"
|
|
36
|
-
variant="outline"
|
|
37
|
-
class="mb-3"
|
|
38
|
-
onclick="SonicPublisherManager.get('submit-example-result').set({ messages: [{ type: 'public', content: 'Compact inline feedback without icons.', status: 'info' }] })"
|
|
39
|
-
>
|
|
40
|
-
Load sample messages
|
|
41
|
-
</sonic-button>
|
|
42
|
-
<sonic-alert-messages
|
|
43
|
-
dataProvider="submit-example-result"
|
|
44
|
-
size="sm"
|
|
45
|
-
background
|
|
46
|
-
noIcon
|
|
47
|
-
></sonic-alert-messages>
|
|
48
|
-
</template>
|
|
49
|
-
</sonic-code>
|
|
50
|
-
|
|
51
|
-
## Message shape
|
|
52
|
-
|
|
53
|
-
Example JSON on the result publisher (or API response merged into it):
|
|
54
|
-
|
|
55
|
-
<sonic-code language="typescript">
|
|
56
|
-
<template>
|
|
57
|
-
{
|
|
58
|
-
"messages": [
|
|
59
|
-
{
|
|
60
|
-
"type": "public",
|
|
61
|
-
"content": "The product has been added to your cart",
|
|
62
|
-
"status": "success"
|
|
63
|
-
}
|
|
64
|
-
]
|
|
65
|
-
}
|
|
66
|
-
</template>
|
|
67
|
-
</sonic-code>
|
|
68
|
-
|
|
69
|
-
## API reference
|
|
70
|
-
|
|
71
|
-
| Attribute | Values | Description |
|
|
72
|
-
|----------|---------|-------------|
|
|
73
|
-
| `dataProvider` | publisher id | Source object; **`messages`** array is auto-filled via **Subscriber** |
|
|
74
|
-
| `size` | `2xs` … `2xl` (default `md`) | Passed to each **`sonic-alert`** |
|
|
75
|
-
| `background` | boolean | Tinted background on each alert |
|
|
76
|
-
| `noIcon` | boolean | Hides icons on each alert |
|
|
77
|
-
| `messages` | `Message[]` | Usually set by the publisher; each item uses **`content`** as alert **`text`** |
|
|
78
|
-
|
|
79
|
-
| Message field | Values | Description |
|
|
80
|
-
|---------------|---------|-------------|
|
|
81
|
-
| `type` | `public` | Required for the message to render |
|
|
82
|
-
| `content` | string | Alert body (**`text`** on **`sonic-alert`**) |
|
|
83
|
-
| `status` | `warning` · `success` · `error` · `info` | Alert **`status`**; defaults to **`default`** when omitted |
|
|
84
|
-
|
|
85
|
-
No slots — alerts are generated from **`messages`**.
|