@birdapi/velinstyle 1.2.1 → 1.3.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.
Files changed (156) hide show
  1. package/README.de.md +148 -11
  2. package/README.md +174 -16
  3. package/cli/__fixtures__/atelier-library/showcases/01-login/app.css +1 -0
  4. package/cli/__fixtures__/atelier-library/showcases/01-login/app.js +2 -0
  5. package/cli/__fixtures__/atelier-library/showcases/01-login/index.html +5 -0
  6. package/cli/__fixtures__/atelier-library/showcases/04-pricing/app.css +1 -0
  7. package/cli/__fixtures__/atelier-library/showcases/04-pricing/app.js +2 -0
  8. package/cli/__fixtures__/atelier-library/showcases/04-pricing/index.html +5 -0
  9. package/cli/__fixtures__/atelier-library/showcases/36-calendar/app.css +1 -0
  10. package/cli/__fixtures__/atelier-library/showcases/36-calendar/app.js +2 -0
  11. package/cli/__fixtures__/atelier-library/showcases/36-calendar/index.html +5 -0
  12. package/cli/atelier-catalog.json +1267 -0
  13. package/cli/atelier-formats.js +159 -0
  14. package/cli/atelier.js +382 -0
  15. package/cli/blueprints/empty-state.html +3 -5
  16. package/cli/cli-manifest.json +441 -161
  17. package/cli/docgen/extract-cli.js +2 -1
  18. package/cli/docs-generate.js +9 -0
  19. package/cli/experience.js +173 -0
  20. package/cli/index.js +1384 -361
  21. package/cli/motion.js +738 -0
  22. package/cli/production/component-graph.json +166 -0
  23. package/cli/production/explain.js +52 -0
  24. package/cli/production/extract.js +278 -0
  25. package/cli/production/graph.js +102 -0
  26. package/cli/production/report.js +168 -0
  27. package/cli/production/run.js +355 -0
  28. package/cli/production/trim-css.js +177 -0
  29. package/cli/production/trim-fonts.js +23 -0
  30. package/cli/production/trim-icons.js +38 -0
  31. package/cli/production/trim-js.js +48 -0
  32. package/cli/production/trim-motion.js +22 -0
  33. package/cli/production/trim-themes.js +50 -0
  34. package/cli/production/watch.js +38 -0
  35. package/cli/review.js +48 -1
  36. package/cli/scripts/write-atelier-fixtures.mjs +33 -0
  37. package/cli/security.js +190 -0
  38. package/cli/skills.js +53 -10
  39. package/cli/transparency.js +140 -41
  40. package/cli/workflow.js +32 -17
  41. package/components/index.js +3 -0
  42. package/components/runtime/component-loaders.js +3 -0
  43. package/components/velin-drawer.js +43 -4
  44. package/components/velin-empty-state.js +83 -0
  45. package/components/velin-modal.js +76 -15
  46. package/components/velin-otp-input.js +220 -0
  47. package/components/velin-password-strength.js +147 -0
  48. package/components/velin-sheet.js +49 -4
  49. package/components/velin-theme-toggle.js +15 -1
  50. package/core/a11y/component-contracts.json +391 -255
  51. package/core/attributes/registry.js +1 -1
  52. package/core/meta/knowledge/components.json +75 -3
  53. package/core/motion/analyze.js +38 -0
  54. package/core/motion/blueprint.js +51 -0
  55. package/core/motion/composer.js +114 -0
  56. package/core/motion/data/registry.json +352 -0
  57. package/core/motion/effects.js +17 -1
  58. package/core/motion/index.js +112 -9
  59. package/core/motion/optimize.js +44 -0
  60. package/core/motion/policy.js +77 -0
  61. package/core/motion/registry.js +131 -0
  62. package/core/motion/review.js +59 -0
  63. package/core/motion/scan.js +150 -0
  64. package/core/motion/timeline.js +68 -0
  65. package/core/motion/transitions.js +49 -0
  66. package/core/motion/triggers.js +168 -0
  67. package/core/security/checks/fs.js +92 -0
  68. package/core/security/detect.js +35 -0
  69. package/core/security/engine.js +116 -0
  70. package/core/security/index.js +18 -0
  71. package/core/security/registry.js +85 -0
  72. package/core/security/report/report.js +113 -0
  73. package/core/security/rules/ci/index.js +146 -0
  74. package/core/security/rules/consumer/index.js +174 -0
  75. package/core/security/rules/deps/index.js +182 -0
  76. package/core/security/rules/index.js +24 -0
  77. package/core/security/rules/publish/index.js +230 -0
  78. package/core/security/rules/repo/index.js +143 -0
  79. package/core/security/rules/secrets/index.js +133 -0
  80. package/core/security/score/dependency-health.js +53 -0
  81. package/core/security/score/release-health.js +66 -0
  82. package/core/security/score/score.js +102 -0
  83. package/core/security/timeline/timeline.js +76 -0
  84. package/dist/chunks/attributes-2ORR27KA.js +404 -0
  85. package/dist/chunks/attributes-HK7VIOLA.js +1080 -0
  86. package/dist/chunks/attributes-VRHHVNDO.js +1080 -0
  87. package/dist/chunks/chunk-MYKUI364.js +116 -0
  88. package/dist/chunks/chunk-NEVBPD5T.js +116 -0
  89. package/dist/chunks/chunk-Y6HN7HWX.js +116 -0
  90. package/dist/chunks/runtime-entry.js +1 -1
  91. package/dist/chunks/velin-drawer-A7Q7EBOS.js +162 -0
  92. package/dist/chunks/velin-empty-state-3NTUH2RF.js +81 -0
  93. package/dist/chunks/velin-modal-3MV4FYBK.js +231 -0
  94. package/dist/chunks/velin-otp-input-PSK42MM6.js +207 -0
  95. package/dist/chunks/velin-password-strength-TAXMLSED.js +136 -0
  96. package/dist/chunks/velin-sheet-N2VVYXFP.js +157 -0
  97. package/dist/chunks/velin-theme-toggle-J2NHC7IM.js +304 -0
  98. package/dist/llms.txt +4 -4
  99. package/dist/search-index.json +232 -5
  100. package/dist/velin-agent.json +433 -46
  101. package/dist/velinstyle-components.iife.js +3695 -2272
  102. package/dist/velinstyle-components.js +3698 -2271
  103. package/dist/velinstyle-components.min.js +262 -120
  104. package/dist/velinstyle.css +96 -13
  105. package/dist/velinstyle.d.ts +3 -0
  106. package/dist/velinstyle.min.css +1 -1
  107. package/package.json +19 -4
  108. package/packages/velinstyle-cli-core/package.json +11 -0
  109. package/packages/velinstyle-cli-core/src/config.js +84 -0
  110. package/packages/velinstyle-cli-core/src/contract.js +56 -0
  111. package/packages/velinstyle-cli-core/src/event-bus.js +50 -0
  112. package/packages/velinstyle-cli-core/src/index.js +18 -0
  113. package/packages/velinstyle-cli-core/src/lifecycle.js +33 -0
  114. package/packages/velinstyle-cli-core/src/runner.js +129 -0
  115. package/packages/velinstyle-cli-registry/data/commands.json +1216 -0
  116. package/packages/velinstyle-cli-registry/data/layouts.json +33 -0
  117. package/packages/velinstyle-cli-registry/data/widgets.json +35 -0
  118. package/packages/velinstyle-cli-registry/package.json +13 -0
  119. package/packages/velinstyle-cli-registry/src/index.js +88 -0
  120. package/packages/velinstyle-cli-renderer/package.json +8 -0
  121. package/packages/velinstyle-cli-renderer/src/index.js +286 -0
  122. package/packages/velinstyle-cli-theme/package.json +8 -0
  123. package/packages/velinstyle-cli-theme/src/index.js +84 -0
  124. package/packages/velinstyle-cli-ui/package.json +8 -0
  125. package/packages/velinstyle-cli-ui/src/index.js +34 -0
  126. package/packages/velinstyle-motion/README.md +81 -0
  127. package/packages/velinstyle-motion/package.json +37 -0
  128. package/packages/velinstyle-motion/src/ai/mini-prompt.js +119 -0
  129. package/packages/velinstyle-motion/src/ai/provider.js +59 -0
  130. package/packages/velinstyle-motion/src/ai/providers/pixverse-setup.js +402 -0
  131. package/packages/velinstyle-motion/src/ai/providers/pixverse.js +245 -0
  132. package/packages/velinstyle-motion/src/config.js +257 -0
  133. package/packages/velinstyle-motion/src/export/html-clip.js +141 -0
  134. package/packages/velinstyle-motion/src/index.js +304 -0
  135. package/packages/velinstyle-motion/src/jobs/cache.js +30 -0
  136. package/packages/velinstyle-motion/src/jobs/queue.js +69 -0
  137. package/packages/velinstyle-motion/src/jobs/usage.js +53 -0
  138. package/packages/velinstyle-motion/src/local/effects.js +139 -0
  139. package/packages/velinstyle-motion/src/local/engine.js +96 -0
  140. package/packages/velinstyle-motion/src/providers-catalog.js +44 -0
  141. package/packages/velinstyle-motion/src/registry/presets.js +25 -0
  142. package/packages/velinstyle-motion/src/registry/presets.json +85 -0
  143. package/packages/velinstyle-motion/src/ux/cost-gate.js +37 -0
  144. package/packages/velinstyle-motion/src/ux/pixverse-gate.js +153 -0
  145. package/packages/velinstyle-motion/src/ux/wizard.js +171 -0
  146. package/packages/velinstyle-motion/src/validate-image.js +91 -0
  147. package/packages/velinstyle-skills/catalog.json +1 -1
  148. package/packages/velinstyle-skills/registry.json +1 -142
  149. package/packages/velinstyle-skills/skills/velin-motion-reduced-safe/SKILL.md +1 -1
  150. package/packages/velinstyle-skills/skills/velin-motion-reveal-feedback/SKILL.md +1 -1
  151. package/src/components/data-table.css +19 -0
  152. package/src/components/empty-auth.css +33 -0
  153. package/src/components/table.css +16 -6
  154. package/src/tokens/motion.css +7 -0
  155. package/src/utilities/scroll-animation.css +66 -0
  156. package/src/velinstyle.css +1 -0
@@ -0,0 +1,116 @@
1
+ // components/runtime/component-loaders.js
2
+ var COMPONENT_LOADERS = {
3
+ "velin-accordion": () => import("./velin-accordion-WSY6BMLA.js"),
4
+ "velin-announcer": () => import("./velin-announcer-PVTXXCWR.js"),
5
+ "velin-bottom-nav": () => import("./velin-bottom-nav-N5F4UO2I.js"),
6
+ "velin-calendar": () => import("./velin-calendar-XC7JRDSH.js"),
7
+ "velin-carousel": () => import("./velin-carousel-ZTBANFQQ.js"),
8
+ "velin-code-block": () => import("./velin-code-block-ZGWG7JI5.js"),
9
+ "velin-collapse": () => import("./velin-collapse-5XYBUIID.js"),
10
+ "velin-combobox": () => import("./velin-combobox-56V2ZWT5.js"),
11
+ "velin-command": () => import("./velin-command-ZJSLPK7B.js"),
12
+ "velin-copy": () => import("./velin-copy-XDQSV2XU.js"),
13
+ "velin-countdown": () => import("./velin-countdown-V4Z5MA63.js"),
14
+ "velin-counter": () => import("./velin-counter-L5FYJF7A.js"),
15
+ "velin-data-table": () => import("./velin-data-table-UVR42UUM.js"),
16
+ "velin-dialog": () => import("./velin-dialog-3YK2RPRV.js"),
17
+ "velin-drawer": () => import("./velin-drawer-A7Q7EBOS.js"),
18
+ "velin-dropdown": () => import("./velin-dropdown-PLUIFA5M.js"),
19
+ "velin-email": () => import("./velin-email-TNFONXPW.js"),
20
+ "velin-empty-state": () => import("./velin-empty-state-3NTUH2RF.js"),
21
+ "velin-file-dropzone": () => import("./velin-file-dropzone-QRGF2JNA.js"),
22
+ "velin-form-summary": () => import("./velin-form-summary-XRQ7COQH.js"),
23
+ "velin-icon": () => import("./velin-icon-A6NCXGUK.js"),
24
+ "velin-lightbox": () => import("./velin-lightbox-P725FLTY.js"),
25
+ "velin-live-dot": () => import("./velin-live-dot-RJHX2DGY.js"),
26
+ "velin-menubar": () => import("./velin-menubar-6I2LM5HL.js"),
27
+ "velin-modal": () => import("./velin-modal-3MV4FYBK.js"),
28
+ "velin-otp-input": () => import("./velin-otp-input-PSK42MM6.js"),
29
+ "velin-password-strength": () => import("./velin-password-strength-TAXMLSED.js"),
30
+ "velin-persist": () => import("./velin-persist-DFPL3QP4.js"),
31
+ "velin-popover": () => import("./velin-popover-WZG2GHBL.js"),
32
+ "velin-progress-ring": () => import("./velin-progress-ring-E4YRLZHH.js"),
33
+ "velin-rating": () => import("./velin-rating-QBBYRRBU.js"),
34
+ "velin-scroll-top": () => import("./velin-scroll-top-OHYVVHHY.js"),
35
+ "velin-scrollspy": () => import("./velin-scrollspy-OKCT4FDV.js"),
36
+ "velin-search": () => import("./velin-search-L3UG6NDQ.js"),
37
+ "velin-secure-field": () => import("./velin-secure-field-DGYMP7OK.js"),
38
+ "velin-segmented-control": () => import("./velin-segmented-control-P74GJPAR.js"),
39
+ "velin-sheet": () => import("./velin-sheet-N2VVYXFP.js"),
40
+ "velin-sparkline": () => import("./velin-sparkline-XVTFC6GE.js"),
41
+ "velin-stepper": () => import("./velin-stepper-4YQJUHPC.js"),
42
+ "velin-stepper-wc": () => import("./velin-stepper-4YQJUHPC.js"),
43
+ "velin-tabs": () => import("./velin-tabs-5UQ5ZVMV.js"),
44
+ "velin-theme-toggle": () => import("./velin-theme-toggle-J2NHC7IM.js"),
45
+ "velin-toast": () => import("./velin-toast-UG5LWTG2.js"),
46
+ "velin-tooltip": () => import("./velin-tooltip-ZDH5SDLU.js"),
47
+ "velin-tooltip-wc": () => import("./velin-tooltip-ZDH5SDLU.js")
48
+ };
49
+
50
+ // components/runtime/index.js
51
+ var registry = /* @__PURE__ */ new Map();
52
+ var VELIN_TAG_RE = /^velin-[a-z0-9-]+$/;
53
+ function whenDefined(tagName) {
54
+ if (typeof customElements === "undefined") {
55
+ return Promise.reject(new Error("customElements not available"));
56
+ }
57
+ return customElements.whenDefined(tagName);
58
+ }
59
+ async function lazyDefine(tagName) {
60
+ const loader = COMPONENT_LOADERS[tagName];
61
+ if (!loader) {
62
+ throw new Error(`Unknown Velin component: ${tagName}`);
63
+ }
64
+ if (registry.has(tagName)) return registry.get(tagName);
65
+ const p = loader().then((mod) => {
66
+ const Cls = mod.default;
67
+ if (Cls && !customElements.get(tagName)) {
68
+ customElements.define(tagName, Cls);
69
+ }
70
+ return Cls;
71
+ });
72
+ registry.set(tagName, p);
73
+ return p;
74
+ }
75
+ async function register(tagNames) {
76
+ return Promise.all(tagNames.map((t) => lazyDefine(t)));
77
+ }
78
+ function collectTagsFromDOM(root) {
79
+ const tags = /* @__PURE__ */ new Set();
80
+ root.querySelectorAll("[data-velin-component]").forEach((el) => {
81
+ const name = el.getAttribute("data-velin-component");
82
+ if (name) tags.add(name.startsWith("velin-") ? name : `velin-${name}`);
83
+ });
84
+ for (const el of root.querySelectorAll("*")) {
85
+ const tag = el.tagName?.toLowerCase();
86
+ if (tag && VELIN_TAG_RE.test(tag) && COMPONENT_LOADERS[tag]) {
87
+ tags.add(tag);
88
+ }
89
+ }
90
+ return tags;
91
+ }
92
+ async function bootFromDOM(root = document, options = {}) {
93
+ const tags = options.tags?.length ? new Set(options.tags) : collectTagsFromDOM(root);
94
+ const wcPromise = register([...tags]);
95
+ if (options.attributes) {
96
+ const { bootAttributes } = await import("./attributes-HK7VIOLA.js");
97
+ await bootAttributes(root);
98
+ }
99
+ if (options.highlight) {
100
+ const { initHighlight } = await import("./highlight-M2ELQNYK.js");
101
+ initHighlight(root);
102
+ }
103
+ if (options.haptic) {
104
+ const { VelinHapticObserver } = await import("./velin-haptic-4QQTM3RK.js");
105
+ new VelinHapticObserver().start(root instanceof Document ? root.body : root);
106
+ }
107
+ return wcPromise;
108
+ }
109
+
110
+ export {
111
+ COMPONENT_LOADERS,
112
+ whenDefined,
113
+ lazyDefine,
114
+ register,
115
+ bootFromDOM
116
+ };
@@ -0,0 +1,116 @@
1
+ // components/runtime/component-loaders.js
2
+ var COMPONENT_LOADERS = {
3
+ "velin-accordion": () => import("./velin-accordion-WSY6BMLA.js"),
4
+ "velin-announcer": () => import("./velin-announcer-PVTXXCWR.js"),
5
+ "velin-bottom-nav": () => import("./velin-bottom-nav-N5F4UO2I.js"),
6
+ "velin-calendar": () => import("./velin-calendar-XC7JRDSH.js"),
7
+ "velin-carousel": () => import("./velin-carousel-ZTBANFQQ.js"),
8
+ "velin-code-block": () => import("./velin-code-block-ZGWG7JI5.js"),
9
+ "velin-collapse": () => import("./velin-collapse-5XYBUIID.js"),
10
+ "velin-combobox": () => import("./velin-combobox-56V2ZWT5.js"),
11
+ "velin-command": () => import("./velin-command-ZJSLPK7B.js"),
12
+ "velin-copy": () => import("./velin-copy-XDQSV2XU.js"),
13
+ "velin-countdown": () => import("./velin-countdown-V4Z5MA63.js"),
14
+ "velin-counter": () => import("./velin-counter-L5FYJF7A.js"),
15
+ "velin-data-table": () => import("./velin-data-table-UVR42UUM.js"),
16
+ "velin-dialog": () => import("./velin-dialog-3YK2RPRV.js"),
17
+ "velin-drawer": () => import("./velin-drawer-A7Q7EBOS.js"),
18
+ "velin-dropdown": () => import("./velin-dropdown-PLUIFA5M.js"),
19
+ "velin-email": () => import("./velin-email-TNFONXPW.js"),
20
+ "velin-empty-state": () => import("./velin-empty-state-3NTUH2RF.js"),
21
+ "velin-file-dropzone": () => import("./velin-file-dropzone-QRGF2JNA.js"),
22
+ "velin-form-summary": () => import("./velin-form-summary-XRQ7COQH.js"),
23
+ "velin-icon": () => import("./velin-icon-A6NCXGUK.js"),
24
+ "velin-lightbox": () => import("./velin-lightbox-P725FLTY.js"),
25
+ "velin-live-dot": () => import("./velin-live-dot-RJHX2DGY.js"),
26
+ "velin-menubar": () => import("./velin-menubar-6I2LM5HL.js"),
27
+ "velin-modal": () => import("./velin-modal-3MV4FYBK.js"),
28
+ "velin-otp-input": () => import("./velin-otp-input-PSK42MM6.js"),
29
+ "velin-password-strength": () => import("./velin-password-strength-TAXMLSED.js"),
30
+ "velin-persist": () => import("./velin-persist-DFPL3QP4.js"),
31
+ "velin-popover": () => import("./velin-popover-WZG2GHBL.js"),
32
+ "velin-progress-ring": () => import("./velin-progress-ring-E4YRLZHH.js"),
33
+ "velin-rating": () => import("./velin-rating-QBBYRRBU.js"),
34
+ "velin-scroll-top": () => import("./velin-scroll-top-OHYVVHHY.js"),
35
+ "velin-scrollspy": () => import("./velin-scrollspy-OKCT4FDV.js"),
36
+ "velin-search": () => import("./velin-search-L3UG6NDQ.js"),
37
+ "velin-secure-field": () => import("./velin-secure-field-DGYMP7OK.js"),
38
+ "velin-segmented-control": () => import("./velin-segmented-control-P74GJPAR.js"),
39
+ "velin-sheet": () => import("./velin-sheet-N2VVYXFP.js"),
40
+ "velin-sparkline": () => import("./velin-sparkline-XVTFC6GE.js"),
41
+ "velin-stepper": () => import("./velin-stepper-4YQJUHPC.js"),
42
+ "velin-stepper-wc": () => import("./velin-stepper-4YQJUHPC.js"),
43
+ "velin-tabs": () => import("./velin-tabs-5UQ5ZVMV.js"),
44
+ "velin-theme-toggle": () => import("./velin-theme-toggle-32J2CBNC.js"),
45
+ "velin-toast": () => import("./velin-toast-UG5LWTG2.js"),
46
+ "velin-tooltip": () => import("./velin-tooltip-ZDH5SDLU.js"),
47
+ "velin-tooltip-wc": () => import("./velin-tooltip-ZDH5SDLU.js")
48
+ };
49
+
50
+ // components/runtime/index.js
51
+ var registry = /* @__PURE__ */ new Map();
52
+ var VELIN_TAG_RE = /^velin-[a-z0-9-]+$/;
53
+ function whenDefined(tagName) {
54
+ if (typeof customElements === "undefined") {
55
+ return Promise.reject(new Error("customElements not available"));
56
+ }
57
+ return customElements.whenDefined(tagName);
58
+ }
59
+ async function lazyDefine(tagName) {
60
+ const loader = COMPONENT_LOADERS[tagName];
61
+ if (!loader) {
62
+ throw new Error(`Unknown Velin component: ${tagName}`);
63
+ }
64
+ if (registry.has(tagName)) return registry.get(tagName);
65
+ const p = loader().then((mod) => {
66
+ const Cls = mod.default;
67
+ if (Cls && !customElements.get(tagName)) {
68
+ customElements.define(tagName, Cls);
69
+ }
70
+ return Cls;
71
+ });
72
+ registry.set(tagName, p);
73
+ return p;
74
+ }
75
+ async function register(tagNames) {
76
+ return Promise.all(tagNames.map((t) => lazyDefine(t)));
77
+ }
78
+ function collectTagsFromDOM(root) {
79
+ const tags = /* @__PURE__ */ new Set();
80
+ root.querySelectorAll("[data-velin-component]").forEach((el) => {
81
+ const name = el.getAttribute("data-velin-component");
82
+ if (name) tags.add(name.startsWith("velin-") ? name : `velin-${name}`);
83
+ });
84
+ for (const el of root.querySelectorAll("*")) {
85
+ const tag = el.tagName?.toLowerCase();
86
+ if (tag && VELIN_TAG_RE.test(tag) && COMPONENT_LOADERS[tag]) {
87
+ tags.add(tag);
88
+ }
89
+ }
90
+ return tags;
91
+ }
92
+ async function bootFromDOM(root = document, options = {}) {
93
+ const tags = options.tags?.length ? new Set(options.tags) : collectTagsFromDOM(root);
94
+ const wcPromise = register([...tags]);
95
+ if (options.attributes) {
96
+ const { bootAttributes } = await import("./attributes-VRHHVNDO.js");
97
+ await bootAttributes(root);
98
+ }
99
+ if (options.highlight) {
100
+ const { initHighlight } = await import("./highlight-M2ELQNYK.js");
101
+ initHighlight(root);
102
+ }
103
+ if (options.haptic) {
104
+ const { VelinHapticObserver } = await import("./velin-haptic-4QQTM3RK.js");
105
+ new VelinHapticObserver().start(root instanceof Document ? root.body : root);
106
+ }
107
+ return wcPromise;
108
+ }
109
+
110
+ export {
111
+ COMPONENT_LOADERS,
112
+ whenDefined,
113
+ lazyDefine,
114
+ register,
115
+ bootFromDOM
116
+ };
@@ -0,0 +1,116 @@
1
+ // components/runtime/component-loaders.js
2
+ var COMPONENT_LOADERS = {
3
+ "velin-accordion": () => import("./velin-accordion-WSY6BMLA.js"),
4
+ "velin-announcer": () => import("./velin-announcer-PVTXXCWR.js"),
5
+ "velin-bottom-nav": () => import("./velin-bottom-nav-N5F4UO2I.js"),
6
+ "velin-calendar": () => import("./velin-calendar-XC7JRDSH.js"),
7
+ "velin-carousel": () => import("./velin-carousel-ZTBANFQQ.js"),
8
+ "velin-code-block": () => import("./velin-code-block-ZGWG7JI5.js"),
9
+ "velin-collapse": () => import("./velin-collapse-5XYBUIID.js"),
10
+ "velin-combobox": () => import("./velin-combobox-56V2ZWT5.js"),
11
+ "velin-command": () => import("./velin-command-ZJSLPK7B.js"),
12
+ "velin-copy": () => import("./velin-copy-XDQSV2XU.js"),
13
+ "velin-countdown": () => import("./velin-countdown-V4Z5MA63.js"),
14
+ "velin-counter": () => import("./velin-counter-L5FYJF7A.js"),
15
+ "velin-data-table": () => import("./velin-data-table-UVR42UUM.js"),
16
+ "velin-dialog": () => import("./velin-dialog-3YK2RPRV.js"),
17
+ "velin-drawer": () => import("./velin-drawer-A7Q7EBOS.js"),
18
+ "velin-dropdown": () => import("./velin-dropdown-PLUIFA5M.js"),
19
+ "velin-email": () => import("./velin-email-TNFONXPW.js"),
20
+ "velin-empty-state": () => import("./velin-empty-state-3NTUH2RF.js"),
21
+ "velin-file-dropzone": () => import("./velin-file-dropzone-QRGF2JNA.js"),
22
+ "velin-form-summary": () => import("./velin-form-summary-XRQ7COQH.js"),
23
+ "velin-icon": () => import("./velin-icon-A6NCXGUK.js"),
24
+ "velin-lightbox": () => import("./velin-lightbox-P725FLTY.js"),
25
+ "velin-live-dot": () => import("./velin-live-dot-RJHX2DGY.js"),
26
+ "velin-menubar": () => import("./velin-menubar-6I2LM5HL.js"),
27
+ "velin-modal": () => import("./velin-modal-3MV4FYBK.js"),
28
+ "velin-otp-input": () => import("./velin-otp-input-PSK42MM6.js"),
29
+ "velin-password-strength": () => import("./velin-password-strength-TAXMLSED.js"),
30
+ "velin-persist": () => import("./velin-persist-DFPL3QP4.js"),
31
+ "velin-popover": () => import("./velin-popover-WZG2GHBL.js"),
32
+ "velin-progress-ring": () => import("./velin-progress-ring-E4YRLZHH.js"),
33
+ "velin-rating": () => import("./velin-rating-QBBYRRBU.js"),
34
+ "velin-scroll-top": () => import("./velin-scroll-top-OHYVVHHY.js"),
35
+ "velin-scrollspy": () => import("./velin-scrollspy-OKCT4FDV.js"),
36
+ "velin-search": () => import("./velin-search-L3UG6NDQ.js"),
37
+ "velin-secure-field": () => import("./velin-secure-field-DGYMP7OK.js"),
38
+ "velin-segmented-control": () => import("./velin-segmented-control-P74GJPAR.js"),
39
+ "velin-sheet": () => import("./velin-sheet-N2VVYXFP.js"),
40
+ "velin-sparkline": () => import("./velin-sparkline-XVTFC6GE.js"),
41
+ "velin-stepper": () => import("./velin-stepper-4YQJUHPC.js"),
42
+ "velin-stepper-wc": () => import("./velin-stepper-4YQJUHPC.js"),
43
+ "velin-tabs": () => import("./velin-tabs-5UQ5ZVMV.js"),
44
+ "velin-theme-toggle": () => import("./velin-theme-toggle-32J2CBNC.js"),
45
+ "velin-toast": () => import("./velin-toast-UG5LWTG2.js"),
46
+ "velin-tooltip": () => import("./velin-tooltip-ZDH5SDLU.js"),
47
+ "velin-tooltip-wc": () => import("./velin-tooltip-ZDH5SDLU.js")
48
+ };
49
+
50
+ // components/runtime/index.js
51
+ var registry = /* @__PURE__ */ new Map();
52
+ var VELIN_TAG_RE = /^velin-[a-z0-9-]+$/;
53
+ function whenDefined(tagName) {
54
+ if (typeof customElements === "undefined") {
55
+ return Promise.reject(new Error("customElements not available"));
56
+ }
57
+ return customElements.whenDefined(tagName);
58
+ }
59
+ async function lazyDefine(tagName) {
60
+ const loader = COMPONENT_LOADERS[tagName];
61
+ if (!loader) {
62
+ throw new Error(`Unknown Velin component: ${tagName}`);
63
+ }
64
+ if (registry.has(tagName)) return registry.get(tagName);
65
+ const p = loader().then((mod) => {
66
+ const Cls = mod.default;
67
+ if (Cls && !customElements.get(tagName)) {
68
+ customElements.define(tagName, Cls);
69
+ }
70
+ return Cls;
71
+ });
72
+ registry.set(tagName, p);
73
+ return p;
74
+ }
75
+ async function register(tagNames) {
76
+ return Promise.all(tagNames.map((t) => lazyDefine(t)));
77
+ }
78
+ function collectTagsFromDOM(root) {
79
+ const tags = /* @__PURE__ */ new Set();
80
+ root.querySelectorAll("[data-velin-component]").forEach((el) => {
81
+ const name = el.getAttribute("data-velin-component");
82
+ if (name) tags.add(name.startsWith("velin-") ? name : `velin-${name}`);
83
+ });
84
+ for (const el of root.querySelectorAll("*")) {
85
+ const tag = el.tagName?.toLowerCase();
86
+ if (tag && VELIN_TAG_RE.test(tag) && COMPONENT_LOADERS[tag]) {
87
+ tags.add(tag);
88
+ }
89
+ }
90
+ return tags;
91
+ }
92
+ async function bootFromDOM(root = document, options = {}) {
93
+ const tags = options.tags?.length ? new Set(options.tags) : collectTagsFromDOM(root);
94
+ const wcPromise = register([...tags]);
95
+ if (options.attributes) {
96
+ const { bootAttributes } = await import("./attributes-2ORR27KA.js");
97
+ await bootAttributes(root);
98
+ }
99
+ if (options.highlight) {
100
+ const { initHighlight } = await import("./highlight-M2ELQNYK.js");
101
+ initHighlight(root);
102
+ }
103
+ if (options.haptic) {
104
+ const { VelinHapticObserver } = await import("./velin-haptic-4QQTM3RK.js");
105
+ new VelinHapticObserver().start(root instanceof Document ? root.body : root);
106
+ }
107
+ return wcPromise;
108
+ }
109
+
110
+ export {
111
+ COMPONENT_LOADERS,
112
+ whenDefined,
113
+ lazyDefine,
114
+ register,
115
+ bootFromDOM
116
+ };
@@ -4,7 +4,7 @@ import {
4
4
  lazyDefine,
5
5
  register,
6
6
  whenDefined
7
- } from "./chunk-CQMTCEI6.js";
7
+ } from "./chunk-MYKUI364.js";
8
8
  export {
9
9
  COMPONENT_LOADERS,
10
10
  bootFromDOM,
@@ -0,0 +1,162 @@
1
+ import {
2
+ clearBackgroundInert,
3
+ getFocusableElements,
4
+ restoreFocus,
5
+ saveFocus,
6
+ setBackgroundInert,
7
+ trapFocus
8
+ } from "./chunk-42VVPW6N.js";
9
+ import "./chunk-L7ZGUU4D.js";
10
+
11
+ // components/velin-drawer.js
12
+ var styles = `
13
+ :host { display: contents; }
14
+ .overlay {
15
+ position: fixed;
16
+ inset: 0;
17
+ z-index: var(--velin-z-overlay, 400);
18
+ background: var(--velin-color-overlay, rgba(0,0,0,0.4));
19
+ opacity: 0;
20
+ visibility: hidden;
21
+ transition: opacity 200ms ease, visibility 200ms ease;
22
+ }
23
+ :host([open]) .overlay { opacity: 1; visibility: visible; }
24
+ .drawer {
25
+ position: fixed;
26
+ z-index: var(--velin-z-modal, 500);
27
+ background: var(--velin-color-surface-bright, #fff);
28
+ box-shadow: var(--velin-shadow-xl, 0 20px 25px rgba(0,0,0,0.1));
29
+ display: flex;
30
+ flex-direction: column;
31
+ transition: transform 250ms ease;
32
+ overflow: hidden;
33
+ }
34
+ /* Side positioning -- default = start */
35
+ .drawer { inset-block: 0; inset-inline-start: 0; inset-inline-end: auto; inline-size: min(20rem, 85vw); transform: translateX(-100%); }
36
+ :host([open]) .drawer, :host([open][side="start"]) .drawer { transform: translateX(0); }
37
+ :host([side="end"]) .drawer { inset-inline-start: auto; inset-inline-end: 0; transform: translateX(100%); }
38
+ :host([open][side="end"]) .drawer { transform: translateX(0); }
39
+ :host([side="top"]) .drawer { inset-inline: 0; inset-inline-start: 0; inset-block-start: 0; inset-block-end: auto; block-size: min(50vh, 24rem); inline-size: 100%; transform: translateY(-100%); }
40
+ :host([open][side="top"]) .drawer { transform: translateY(0); }
41
+ :host([side="bottom"]) .drawer { inset-inline: 0; inset-inline-start: 0; inset-block-start: auto; inset-block-end: 0; block-size: min(50vh, 24rem); inline-size: 100%; transform: translateY(100%); }
42
+ :host([open][side="bottom"]) .drawer { transform: translateY(0); }
43
+ .header {
44
+ display: flex; align-items: center; justify-content: space-between;
45
+ padding: var(--velin-space-4, 1rem) var(--velin-space-5, 1.25rem);
46
+ border-bottom: 1px solid var(--velin-color-border, #ddd);
47
+ }
48
+ .title { font-size: var(--velin-text-lg, 1.25rem); font-weight: var(--velin-weight-semibold, 600); margin: 0; }
49
+ .close-btn {
50
+ min-width: 2.75rem; min-height: 2.75rem; display: inline-flex; align-items: center; justify-content: center;
51
+ background: none; border: none; border-radius: var(--velin-radius-md, 0.5rem); cursor: pointer;
52
+ color: var(--velin-color-text-muted, #666); font-size: 1.5rem; line-height: 1;
53
+ }
54
+ .close-btn:hover { background: var(--velin-color-surface-dim, #eee); color: var(--velin-color-text, #111); }
55
+ .body { flex: 1; padding: var(--velin-space-5, 1.25rem); overflow-y: auto; }
56
+ @media (prefers-reduced-motion: reduce) { .overlay, .drawer { transition: none; } }
57
+ `;
58
+ var VelinDrawer = class extends HTMLElement {
59
+ static get observedAttributes() {
60
+ return ["open", "title"];
61
+ }
62
+ constructor() {
63
+ super();
64
+ this.attachShadow({ mode: "open", delegatesFocus: true });
65
+ this._prev = null;
66
+ this._onKey = this._onKey.bind(this);
67
+ this._onTitleSlot = this._onTitleSlot.bind(this);
68
+ }
69
+ connectedCallback() {
70
+ if (this.shadowRoot.querySelector(".drawer")) return;
71
+ const titleId = "velin-drawer-title";
72
+ this.shadowRoot.innerHTML = `
73
+ <style>${styles}</style>
74
+ <div class="overlay" part="overlay"></div>
75
+ <div class="drawer" role="dialog" aria-modal="true" aria-labelledby="${titleId}" part="drawer">
76
+ <div class="header" part="header">
77
+ <h2 class="title" id="${titleId}" part="title">
78
+ <slot name="title"></slot>
79
+ <span class="title-fallback"></span>
80
+ </h2>
81
+ <button class="close-btn" aria-label="Close" part="close">&#215;</button>
82
+ </div>
83
+ <div class="body" part="body"><slot></slot></div>
84
+ </div>
85
+ `;
86
+ this.shadowRoot.querySelector(".close-btn").addEventListener("click", () => this.close());
87
+ this.shadowRoot.querySelector(".overlay").addEventListener("click", () => this.close());
88
+ this.shadowRoot.querySelector('slot[name="title"]').addEventListener("slotchange", this._onTitleSlot);
89
+ this._syncTitle();
90
+ }
91
+ attributeChangedCallback(name) {
92
+ if (name === "open") this.hasAttribute("open") ? this._open() : this._close();
93
+ if (name === "title") this._syncTitle();
94
+ }
95
+ open() {
96
+ this.setAttribute("open", "");
97
+ }
98
+ close() {
99
+ this.removeAttribute("open");
100
+ this.dispatchEvent(new CustomEvent("velin-close", { bubbles: true }));
101
+ }
102
+ _syncTitle() {
103
+ const fallback = this.shadowRoot?.querySelector(".title-fallback");
104
+ if (!fallback) return;
105
+ fallback.textContent = this.getAttribute("title") || "";
106
+ }
107
+ _hasTitleSlot() {
108
+ const slot = this.shadowRoot?.querySelector('slot[name="title"]');
109
+ if (!slot) return false;
110
+ return slot.assignedNodes({ flatten: true }).some((n) => {
111
+ if (n.nodeType === Node.TEXT_NODE) return Boolean(n.textContent.trim());
112
+ return n.nodeType === Node.ELEMENT_NODE;
113
+ });
114
+ }
115
+ _onTitleSlot() {
116
+ const dialog = this.shadowRoot?.querySelector('[role="dialog"]');
117
+ const fallback = this.shadowRoot?.querySelector(".title-fallback");
118
+ if (!dialog || !fallback) return;
119
+ if (this._hasTitleSlot()) {
120
+ fallback.hidden = true;
121
+ dialog.removeAttribute("aria-labelledby");
122
+ const slot = this.shadowRoot.querySelector('slot[name="title"]');
123
+ const label = slot.assignedNodes({ flatten: true }).map((n) => n.textContent || "").join(" ").trim();
124
+ if (label) dialog.setAttribute("aria-label", label);
125
+ } else {
126
+ fallback.hidden = false;
127
+ dialog.removeAttribute("aria-label");
128
+ dialog.setAttribute("aria-labelledby", "velin-drawer-title");
129
+ this._syncTitle();
130
+ }
131
+ }
132
+ _open() {
133
+ this._prev = saveFocus();
134
+ setBackgroundInert(this);
135
+ document.addEventListener("keydown", this._onKey);
136
+ requestAnimationFrame(() => {
137
+ const f = getFocusableElements(this.shadowRoot);
138
+ if (f.length) f[0].focus();
139
+ });
140
+ }
141
+ _close() {
142
+ document.removeEventListener("keydown", this._onKey);
143
+ clearBackgroundInert(this);
144
+ restoreFocus(this._prev);
145
+ }
146
+ _onKey(e) {
147
+ if (e.key === "Escape") {
148
+ this.close();
149
+ return;
150
+ }
151
+ trapFocus(this.shadowRoot, e);
152
+ }
153
+ disconnectedCallback() {
154
+ document.removeEventListener("keydown", this._onKey);
155
+ clearBackgroundInert(this);
156
+ }
157
+ };
158
+ customElements.define("velin-drawer", VelinDrawer);
159
+ var velin_drawer_default = VelinDrawer;
160
+ export {
161
+ velin_drawer_default as default
162
+ };
@@ -0,0 +1,81 @@
1
+ // components/velin-empty-state.js
2
+ var styles = `
3
+ :host {
4
+ display: block;
5
+ text-align: center;
6
+ padding: var(--velin-space-8, 2rem) var(--velin-space-4, 1rem);
7
+ }
8
+ .illustration {
9
+ display: flex;
10
+ justify-content: center;
11
+ margin-block-end: var(--velin-space-4, 1rem);
12
+ color: var(--velin-color-text-muted, #666);
13
+ }
14
+ .title {
15
+ margin: 0 0 var(--velin-space-2, 0.5rem);
16
+ font-size: var(--velin-text-xl, 1.25rem);
17
+ font-weight: var(--velin-weight-bold, 700);
18
+ color: var(--velin-color-text, #111);
19
+ }
20
+ .description {
21
+ margin: 0 0 var(--velin-space-4, 1rem);
22
+ color: var(--velin-color-text-muted, #666);
23
+ max-inline-size: 36rem;
24
+ margin-inline: auto;
25
+ }
26
+ .actions {
27
+ display: flex;
28
+ flex-wrap: wrap;
29
+ gap: var(--velin-space-3, 0.75rem);
30
+ justify-content: center;
31
+ }
32
+ `;
33
+ var VelinEmptyState = class extends HTMLElement {
34
+ static get observedAttributes() {
35
+ return ["heading", "description"];
36
+ }
37
+ constructor() {
38
+ super();
39
+ this.attachShadow({ mode: "open" });
40
+ }
41
+ connectedCallback() {
42
+ if (this.shadowRoot.querySelector(".root")) {
43
+ this._syncText();
44
+ return;
45
+ }
46
+ const titleId = "velin-empty-title";
47
+ this.shadowRoot.innerHTML = `
48
+ <style>${styles}</style>
49
+ <section class="root" part="root" role="status" aria-labelledby="${titleId}">
50
+ <div class="illustration" part="illustration"><slot name="illustration"></slot></div>
51
+ <h2 class="title" id="${titleId}" part="title">
52
+ <slot name="title"><span class="heading-fallback"></span></slot>
53
+ </h2>
54
+ <div class="description" part="description">
55
+ <slot name="description"><span class="description-fallback"></span></slot>
56
+ </div>
57
+ <div class="actions" part="actions"><slot name="actions"></slot></div>
58
+ <slot></slot>
59
+ </section>
60
+ `;
61
+ this._syncText();
62
+ }
63
+ attributeChangedCallback() {
64
+ this._syncText();
65
+ }
66
+ _syncText() {
67
+ const heading = this.shadowRoot?.querySelector(".heading-fallback");
68
+ const description = this.shadowRoot?.querySelector(".description-fallback");
69
+ if (heading) heading.textContent = this.getAttribute("heading") || "Nothing here yet";
70
+ if (description) {
71
+ const text = this.getAttribute("description") || "";
72
+ description.textContent = text;
73
+ description.hidden = !text;
74
+ }
75
+ }
76
+ };
77
+ customElements.define("velin-empty-state", VelinEmptyState);
78
+ var velin_empty_state_default = VelinEmptyState;
79
+ export {
80
+ velin_empty_state_default as default
81
+ };