@usecapsule/core-components 1.0.11 → 1.0.13-dev.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (161) hide show
  1. package/css/capsule-core.css +74 -41
  2. package/css/capsule-core.css.map +1 -1
  3. package/dist/capsule/capsule.esm.js +1 -1
  4. package/dist/capsule/capsule.esm.js.map +1 -1
  5. package/dist/capsule/index.esm.js +1 -1
  6. package/dist/capsule/index.esm.js.map +1 -1
  7. package/dist/capsule/p-0462f723.js +2 -0
  8. package/dist/capsule/p-0462f723.js.map +1 -0
  9. package/dist/capsule/p-202a85c9.entry.js +29 -0
  10. package/dist/capsule/p-202a85c9.entry.js.map +1 -0
  11. package/dist/capsule/p-68c73705.entry.js +2 -0
  12. package/dist/capsule/{p-1dc07cd7.entry.js.map → p-68c73705.entry.js.map} +1 -1
  13. package/dist/capsule/p-6fb7c4d1.js +3 -0
  14. package/dist/capsule/p-6fb7c4d1.js.map +1 -0
  15. package/dist/capsule/{p-11048392.entry.js → p-91412151.entry.js} +2 -2
  16. package/dist/capsule/{p-62e7869a.entry.js → p-a95ec4df.entry.js} +2 -2
  17. package/dist/capsule/p-c2bf050b.js +2 -0
  18. package/dist/capsule/p-c2bf050b.js.map +1 -0
  19. package/dist/capsule/p-d7be092d.entry.js +10 -0
  20. package/dist/capsule/p-d7be092d.entry.js.map +1 -0
  21. package/dist/capsule/p-f604b591.entry.js +2 -0
  22. package/dist/cjs/_commonjsHelpers-b3309d7b.js +12 -0
  23. package/dist/cjs/_commonjsHelpers-b3309d7b.js.map +1 -0
  24. package/dist/cjs/capsule.cjs.js +2 -2
  25. package/dist/cjs/constants-4bb85cc5.js +12 -0
  26. package/dist/cjs/constants-4bb85cc5.js.map +1 -0
  27. package/dist/cjs/cpsl-alert_17.cjs.entry.js +3783 -559
  28. package/dist/cjs/cpsl-alert_17.cjs.entry.js.map +1 -1
  29. package/dist/cjs/cpsl-animation.cjs.entry.js +20129 -0
  30. package/dist/cjs/cpsl-animation.cjs.entry.js.map +1 -0
  31. package/dist/cjs/cpsl-col.cjs.entry.js +2 -2
  32. package/dist/cjs/cpsl-grid.cjs.entry.js +3 -3
  33. package/dist/cjs/cpsl-info-box.cjs.entry.js +3 -3
  34. package/dist/cjs/cpsl-info-box.cjs.entry.js.map +1 -1
  35. package/dist/cjs/cpsl-row.cjs.entry.js +2 -2
  36. package/dist/cjs/{index-2a026742.js → index-3fccb5b4.js} +22 -1
  37. package/dist/cjs/index-3fccb5b4.js.map +1 -0
  38. package/dist/cjs/index.cjs.js +338 -0
  39. package/dist/cjs/index.cjs.js.map +1 -1
  40. package/dist/cjs/loader.cjs.js +2 -2
  41. package/dist/collection/assets/icons/capsule-rings-dark.svg +34 -0
  42. package/dist/collection/assets/icons/capsule.svg +4 -4
  43. package/dist/collection/assets/icons/hero-email.svg +8 -30
  44. package/dist/collection/assets/icons/hero-lock.svg +4 -34
  45. package/dist/collection/assets/icons/hero-passkey.svg +9 -17
  46. package/dist/collection/assets/icons/hero-phone.svg +4 -15
  47. package/dist/collection/assets/icons/hero-wallet.svg +5 -44
  48. package/dist/collection/assets/icons/index.js +4 -2
  49. package/dist/collection/assets/icons/index.js.map +1 -1
  50. package/dist/collection/assets/icons/more-login-options.svg +10 -10
  51. package/dist/collection/assets/icons/plus-circle.svg +5 -0
  52. package/dist/collection/assets/icons/wallet.svg +5 -0
  53. package/dist/collection/collection-manifest.json +1 -0
  54. package/dist/collection/components/cpsl-alert/cpsl-alert.js +1 -1
  55. package/dist/collection/components/cpsl-animation/cpsl-animation.css +17 -0
  56. package/dist/collection/components/cpsl-animation/cpsl-animation.js +102 -0
  57. package/dist/collection/components/cpsl-animation/cpsl-animation.js.map +1 -0
  58. package/dist/collection/components/cpsl-animation/test/cpsl-animation.e2e.js +29 -0
  59. package/dist/collection/components/cpsl-animation/test/cpsl-animation.e2e.js.map +1 -0
  60. package/dist/collection/components/cpsl-animation/test/cpsl-animation.spec.js +37 -0
  61. package/dist/collection/components/cpsl-animation/test/cpsl-animation.spec.js.map +1 -0
  62. package/dist/collection/components/cpsl-button/cpsl-button.css +3 -0
  63. package/dist/collection/components/cpsl-button/cpsl-button.js +2 -2
  64. package/dist/collection/components/cpsl-button/cpsl-button.js.map +1 -1
  65. package/dist/collection/components/cpsl-code-input/cpsl-code-input.js +2 -2
  66. package/dist/collection/components/cpsl-code-input/cpsl-code-input.js.map +1 -1
  67. package/dist/collection/components/cpsl-col/cpsl-col.js +1 -1
  68. package/dist/collection/components/cpsl-divider/cpsl-divider.js +1 -1
  69. package/dist/collection/components/cpsl-grid/cpsl-grid.js +2 -2
  70. package/dist/collection/components/cpsl-icon/cpsl-icon.css +14 -0
  71. package/dist/collection/components/cpsl-icon/cpsl-icon.js +2 -3
  72. package/dist/collection/components/cpsl-icon/cpsl-icon.js.map +1 -1
  73. package/dist/collection/components/cpsl-info-box/cpsl-info-box.css +1 -1
  74. package/dist/collection/components/cpsl-info-box/cpsl-info-box.js +1 -1
  75. package/dist/collection/components/cpsl-input/cpsl-input.css +9 -4
  76. package/dist/collection/components/cpsl-input/cpsl-input.js +8 -6
  77. package/dist/collection/components/cpsl-input/cpsl-input.js.map +1 -1
  78. package/dist/collection/components/cpsl-modal/cpsl-modal.css +56 -4
  79. package/dist/collection/components/cpsl-modal/cpsl-modal.js +341 -24
  80. package/dist/collection/components/cpsl-modal/cpsl-modal.js.map +1 -1
  81. package/dist/collection/components/cpsl-overlay/cpsl-overlay.js +30 -13
  82. package/dist/collection/components/cpsl-overlay/cpsl-overlay.js.map +1 -1
  83. package/dist/collection/components/cpsl-pill/cpsl-pill.css +3 -3
  84. package/dist/collection/components/cpsl-pill/cpsl-pill.js +1 -1
  85. package/dist/collection/components/cpsl-progress-indicator/cpsl-progress-indicator.css +3 -3
  86. package/dist/collection/components/cpsl-qr-code/cpsl-qr-code.css +3 -3
  87. package/dist/collection/components/cpsl-qr-code/cpsl-qr-code.js +1 -1
  88. package/dist/collection/components/cpsl-row/cpsl-row.js +1 -1
  89. package/dist/collection/components/cpsl-slide-button/cpsl-slide-button.css +19 -10
  90. package/dist/collection/components/cpsl-slide-button/cpsl-slide-button.js +54 -7
  91. package/dist/collection/components/cpsl-slide-button/cpsl-slide-button.js.map +1 -1
  92. package/dist/collection/components/cpsl-spinner/cpsl-spinner.css +2 -2
  93. package/dist/collection/components/cpsl-spinner/cpsl-spinner.js +2 -2
  94. package/dist/collection/components/cpsl-tab/cpsl-tab.js +1 -1
  95. package/dist/collection/components/cpsl-tabs/cpsl-tabs.css +17 -16
  96. package/dist/collection/components/cpsl-tabs/cpsl-tabs.js +2 -2
  97. package/dist/collection/components/cpsl-tabs/cpsl-tabs.js.map +1 -1
  98. package/dist/collection/components/cpsl-text/cpsl-text.js +1 -1
  99. package/dist/collection/components/cpsl-tile-button/cpsl-tile-button.css +3 -0
  100. package/dist/collection/components/cpsl-tile-button/cpsl-tile-button.js +2 -2
  101. package/dist/collection/constants.js +6 -0
  102. package/dist/collection/constants.js.map +1 -0
  103. package/dist/collection/index.js +1 -0
  104. package/dist/collection/index.js.map +1 -1
  105. package/dist/collection/interface.js.map +1 -1
  106. package/dist/collection/utils/theme/generateBorderRadii.js +56 -0
  107. package/dist/collection/utils/theme/generateBorderRadii.js.map +1 -0
  108. package/dist/collection/utils/theme/generateFont.js +7 -0
  109. package/dist/collection/utils/theme/generateFont.js.map +1 -0
  110. package/dist/collection/utils/theme/generatePalette.js +46 -0
  111. package/dist/collection/utils/theme/generatePalette.js.map +1 -0
  112. package/dist/collection/utils/theme/generateTheme.js +12 -0
  113. package/dist/collection/utils/theme/generateTheme.js.map +1 -0
  114. package/dist/collection/utils/theme/utils.js +21 -0
  115. package/dist/collection/utils/theme/utils.js.map +1 -0
  116. package/dist/esm/_commonjsHelpers-1789f0cf.js +9 -0
  117. package/dist/esm/_commonjsHelpers-1789f0cf.js.map +1 -0
  118. package/dist/esm/capsule.js +3 -3
  119. package/dist/esm/constants-7b49abd5.js +9 -0
  120. package/dist/esm/constants-7b49abd5.js.map +1 -0
  121. package/dist/esm/cpsl-alert_17.entry.js +3782 -558
  122. package/dist/esm/cpsl-alert_17.entry.js.map +1 -1
  123. package/dist/esm/cpsl-animation.entry.js +20125 -0
  124. package/dist/esm/cpsl-animation.entry.js.map +1 -0
  125. package/dist/esm/cpsl-col.entry.js +2 -2
  126. package/dist/esm/cpsl-grid.entry.js +3 -3
  127. package/dist/esm/cpsl-info-box.entry.js +3 -3
  128. package/dist/esm/cpsl-info-box.entry.js.map +1 -1
  129. package/dist/esm/cpsl-row.entry.js +2 -2
  130. package/dist/esm/{index-7c2f5cb9.js → index-f00e090c.js} +22 -1
  131. package/dist/esm/index-f00e090c.js.map +1 -0
  132. package/dist/esm/index.js +335 -0
  133. package/dist/esm/index.js.map +1 -1
  134. package/dist/esm/loader.js +3 -3
  135. package/dist/types/assets/icons/index.d.ts +3 -1
  136. package/dist/types/components/cpsl-animation/cpsl-animation.d.ts +9 -0
  137. package/dist/types/components/cpsl-modal/cpsl-modal.d.ts +26 -5
  138. package/dist/types/components/cpsl-overlay/cpsl-overlay.d.ts +2 -2
  139. package/dist/types/components/cpsl-slide-button/cpsl-slide-button.d.ts +1 -0
  140. package/dist/types/components.d.ts +125 -13
  141. package/dist/types/constants.d.ts +3 -0
  142. package/dist/types/index.d.ts +2 -0
  143. package/dist/types/interface.d.ts +122 -0
  144. package/dist/types/utils/theme/generateBorderRadii.d.ts +2 -0
  145. package/dist/types/utils/theme/generateFont.d.ts +2 -0
  146. package/dist/types/utils/theme/generatePalette.d.ts +7 -0
  147. package/dist/types/utils/theme/generateTheme.d.ts +3 -0
  148. package/dist/types/utils/theme/utils.d.ts +5 -0
  149. package/package.json +5 -3
  150. package/dist/capsule/p-1dc07cd7.entry.js +0 -2
  151. package/dist/capsule/p-5c020abe.entry.js +0 -2
  152. package/dist/capsule/p-9647dd63.js +0 -3
  153. package/dist/capsule/p-9647dd63.js.map +0 -1
  154. package/dist/capsule/p-bbbfec72.entry.js +0 -20
  155. package/dist/capsule/p-bbbfec72.entry.js.map +0 -1
  156. package/dist/cjs/index-2a026742.js.map +0 -1
  157. package/dist/collection/assets/icons/more-login-options-dark.svg +0 -13
  158. package/dist/esm/index-7c2f5cb9.js.map +0 -1
  159. /package/dist/capsule/{p-11048392.entry.js.map → p-91412151.entry.js.map} +0 -0
  160. /package/dist/capsule/{p-62e7869a.entry.js.map → p-a95ec4df.entry.js.map} +0 -0
  161. /package/dist/capsule/{p-5c020abe.entry.js.map → p-f604b591.entry.js.map} +0 -0
@@ -26,6 +26,16 @@ export namespace Components {
26
26
  */
27
27
  "type"?: 'error';
28
28
  }
29
+ interface CpslAnimation {
30
+ /**
31
+ * Will replay the animation
32
+ */
33
+ "replayAnimation": () => Promise<void>;
34
+ /**
35
+ * Source of the Lottie animation file.
36
+ */
37
+ "src": string;
38
+ }
29
39
  interface CpslButton {
30
40
  /**
31
41
  * If the button is disabled. Default is: false.
@@ -287,24 +297,44 @@ export namespace Components {
287
297
  "value"?: string;
288
298
  }
289
299
  interface CpslModal {
300
+ /**
301
+ * Duration in seconds of the modal entering. Default is .15.
302
+ */
303
+ "enterTransitionDuration"?: number;
304
+ /**
305
+ * Duration in seconds of the modal exiting. Default is .15.
306
+ */
307
+ "exitTransitionDuration"?: number;
290
308
  /**
291
309
  * Whether or not to show `footerExpandedFooter` and `footerExpandedHeader` slots.
292
310
  */
293
- "footerExpanded": boolean;
311
+ "footerExpanded"?: boolean;
312
+ /**
313
+ * Duration in seconds of the footer expansion animation. Default is 0.15.
314
+ */
315
+ "footerTransitionDuration"?: number;
316
+ /**
317
+ * Whether or not to show the overlay. This will always show the modal, regardless of the value of `open`.
318
+ */
319
+ "noOverlay"?: boolean;
294
320
  /**
295
- * Duration in seconds of the footer expansion animation. Default is .5.
321
+ * Whether or not to show the modal.
296
322
  */
297
- "transitionDuration": number;
323
+ "open": boolean;
298
324
  }
299
325
  interface CpslOverlay {
300
326
  /**
301
- * Whether or not to show the overlay.
327
+ * Duration in seconds of the fade out animation. Default is .5.
302
328
  */
303
- "open": boolean;
329
+ "enterTransitionDuration"?: number;
304
330
  /**
305
- * Duration in seconds of the fade in/out animation. Default is .5.
331
+ * Duration in seconds of the fade out animation. Default is .5.
306
332
  */
307
- "transitionDuration": number;
333
+ "exitTransitionDuration"?: number;
334
+ /**
335
+ * Whether or not to show the overlay.
336
+ */
337
+ "open": boolean;
308
338
  }
309
339
  interface CpslPill {
310
340
  /**
@@ -339,6 +369,10 @@ export namespace Components {
339
369
  interface CpslRow {
340
370
  }
341
371
  interface CpslSlideButton {
372
+ /**
373
+ * Whether or not the component is disabled. If true, the component will display the `startText`.
374
+ */
375
+ "disabled": boolean;
342
376
  /**
343
377
  * The name of the ending icon to show.
344
378
  */
@@ -407,6 +441,10 @@ export interface CpslInputCustomEvent<T> extends CustomEvent<T> {
407
441
  detail: T;
408
442
  target: HTMLCpslInputElement;
409
443
  }
444
+ export interface CpslModalCustomEvent<T> extends CustomEvent<T> {
445
+ detail: T;
446
+ target: HTMLCpslModalElement;
447
+ }
410
448
  export interface CpslSlideButtonCustomEvent<T> extends CustomEvent<T> {
411
449
  detail: T;
412
450
  target: HTMLCpslSlideButtonElement;
@@ -426,6 +464,12 @@ declare global {
426
464
  prototype: HTMLCpslAlertElement;
427
465
  new (): HTMLCpslAlertElement;
428
466
  };
467
+ interface HTMLCpslAnimationElement extends Components.CpslAnimation, HTMLStencilElement {
468
+ }
469
+ var HTMLCpslAnimationElement: {
470
+ prototype: HTMLCpslAnimationElement;
471
+ new (): HTMLCpslAnimationElement;
472
+ };
429
473
  interface HTMLCpslButtonElement extends Components.CpslButton, HTMLStencilElement {
430
474
  }
431
475
  var HTMLCpslButtonElement: {
@@ -499,7 +543,22 @@ declare global {
499
543
  prototype: HTMLCpslInputElement;
500
544
  new (): HTMLCpslInputElement;
501
545
  };
546
+ interface HTMLCpslModalElementEventMap {
547
+ "cpslModalEntering": null;
548
+ "cpslModalEntered": null;
549
+ "cpslModalExiting": null;
550
+ "cpslModalExited": null;
551
+ "cpslModalRequestClose": null;
552
+ }
502
553
  interface HTMLCpslModalElement extends Components.CpslModal, HTMLStencilElement {
554
+ addEventListener<K extends keyof HTMLCpslModalElementEventMap>(type: K, listener: (this: HTMLCpslModalElement, ev: CpslModalCustomEvent<HTMLCpslModalElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
555
+ addEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
556
+ addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
557
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
558
+ removeEventListener<K extends keyof HTMLCpslModalElementEventMap>(type: K, listener: (this: HTMLCpslModalElement, ev: CpslModalCustomEvent<HTMLCpslModalElementEventMap[K]>) => any, options?: boolean | EventListenerOptions): void;
559
+ removeEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
560
+ removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
561
+ removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
503
562
  }
504
563
  var HTMLCpslModalElement: {
505
564
  prototype: HTMLCpslModalElement;
@@ -607,6 +666,7 @@ declare global {
607
666
  };
608
667
  interface HTMLElementTagNameMap {
609
668
  "cpsl-alert": HTMLCpslAlertElement;
669
+ "cpsl-animation": HTMLCpslAnimationElement;
610
670
  "cpsl-button": HTMLCpslButtonElement;
611
671
  "cpsl-code-input": HTMLCpslCodeInputElement;
612
672
  "cpsl-col": HTMLCpslColElement;
@@ -640,6 +700,12 @@ declare namespace LocalJSX {
640
700
  */
641
701
  "type"?: 'error';
642
702
  }
703
+ interface CpslAnimation {
704
+ /**
705
+ * Source of the Lottie animation file.
706
+ */
707
+ "src"?: string;
708
+ }
643
709
  interface CpslButton {
644
710
  /**
645
711
  * If the button is disabled. Default is: false.
@@ -921,24 +987,64 @@ declare namespace LocalJSX {
921
987
  "value"?: string;
922
988
  }
923
989
  interface CpslModal {
990
+ /**
991
+ * Duration in seconds of the modal entering. Default is .15.
992
+ */
993
+ "enterTransitionDuration"?: number;
994
+ /**
995
+ * Duration in seconds of the modal exiting. Default is .15.
996
+ */
997
+ "exitTransitionDuration"?: number;
924
998
  /**
925
999
  * Whether or not to show `footerExpandedFooter` and `footerExpandedHeader` slots.
926
1000
  */
927
1001
  "footerExpanded"?: boolean;
928
1002
  /**
929
- * Duration in seconds of the footer expansion animation. Default is .5.
1003
+ * Duration in seconds of the footer expansion animation. Default is 0.15.
1004
+ */
1005
+ "footerTransitionDuration"?: number;
1006
+ /**
1007
+ * Whether or not to show the overlay. This will always show the modal, regardless of the value of `open`.
1008
+ */
1009
+ "noOverlay"?: boolean;
1010
+ /**
1011
+ * Emitted when enter animation finishes.
1012
+ */
1013
+ "onCpslModalEntered"?: (event: CpslModalCustomEvent<null>) => void;
1014
+ /**
1015
+ * Emitted when enter animation starts.
1016
+ */
1017
+ "onCpslModalEntering"?: (event: CpslModalCustomEvent<null>) => void;
1018
+ /**
1019
+ * Emitted when exit animation finishes.
930
1020
  */
931
- "transitionDuration"?: number;
1021
+ "onCpslModalExited"?: (event: CpslModalCustomEvent<null>) => void;
1022
+ /**
1023
+ * Emitted when exit animation starts.
1024
+ */
1025
+ "onCpslModalExiting"?: (event: CpslModalCustomEvent<null>) => void;
1026
+ /**
1027
+ * Emitted when exit animation finishes.
1028
+ */
1029
+ "onCpslModalRequestClose"?: (event: CpslModalCustomEvent<null>) => void;
1030
+ /**
1031
+ * Whether or not to show the modal.
1032
+ */
1033
+ "open"?: boolean;
932
1034
  }
933
1035
  interface CpslOverlay {
934
1036
  /**
935
- * Whether or not to show the overlay.
1037
+ * Duration in seconds of the fade out animation. Default is .5.
936
1038
  */
937
- "open"?: boolean;
1039
+ "enterTransitionDuration"?: number;
1040
+ /**
1041
+ * Duration in seconds of the fade out animation. Default is .5.
1042
+ */
1043
+ "exitTransitionDuration"?: number;
938
1044
  /**
939
- * Duration in seconds of the fade in/out animation. Default is .5.
1045
+ * Whether or not to show the overlay.
940
1046
  */
941
- "transitionDuration"?: number;
1047
+ "open"?: boolean;
942
1048
  }
943
1049
  interface CpslPill {
944
1050
  /**
@@ -973,6 +1079,10 @@ declare namespace LocalJSX {
973
1079
  interface CpslRow {
974
1080
  }
975
1081
  interface CpslSlideButton {
1082
+ /**
1083
+ * Whether or not the component is disabled. If true, the component will display the `startText`.
1084
+ */
1085
+ "disabled"?: boolean;
976
1086
  /**
977
1087
  * The name of the ending icon to show.
978
1088
  */
@@ -1042,6 +1152,7 @@ declare namespace LocalJSX {
1042
1152
  }
1043
1153
  interface IntrinsicElements {
1044
1154
  "cpsl-alert": CpslAlert;
1155
+ "cpsl-animation": CpslAnimation;
1045
1156
  "cpsl-button": CpslButton;
1046
1157
  "cpsl-code-input": CpslCodeInput;
1047
1158
  "cpsl-col": CpslCol;
@@ -1069,6 +1180,7 @@ declare module "@stencil/core" {
1069
1180
  export namespace JSX {
1070
1181
  interface IntrinsicElements {
1071
1182
  "cpsl-alert": LocalJSX.CpslAlert & JSXBase.HTMLAttributes<HTMLCpslAlertElement>;
1183
+ "cpsl-animation": LocalJSX.CpslAnimation & JSXBase.HTMLAttributes<HTMLCpslAnimationElement>;
1072
1184
  "cpsl-button": LocalJSX.CpslButton & JSXBase.HTMLAttributes<HTMLCpslButtonElement>;
1073
1185
  "cpsl-code-input": LocalJSX.CpslCodeInput & JSXBase.HTMLAttributes<HTMLCpslCodeInputElement>;
1074
1186
  "cpsl-col": LocalJSX.CpslCol & JSXBase.HTMLAttributes<HTMLCpslColElement>;
@@ -0,0 +1,3 @@
1
+ import { Theme } from './interface';
2
+ export declare const MOBILE_SIZE = 480;
3
+ export declare const DEFAULT_THEME: Theme;
@@ -1 +1,3 @@
1
1
  export * from './components';
2
+ export { default as generateTheme } from './utils/theme/generateTheme';
3
+ export type { Theme, BorderRadius } from './interface';
@@ -8,3 +8,125 @@ export type CssClassMap = {
8
8
  [className: string]: boolean;
9
9
  };
10
10
  export type IconType = keyof typeof Icons;
11
+ export type Theme = {
12
+ foregroundColor?: string;
13
+ backgroundColor?: string;
14
+ borderRadius?: BorderRadius;
15
+ font?: string;
16
+ customPalette?: CustomPalette;
17
+ };
18
+ export type BorderRadius = 'none' | 'xs' | 'sm' | 'md' | 'lg' | 'full';
19
+ export interface CustomPalette {
20
+ text?: {
21
+ primary?: string;
22
+ secondary?: string;
23
+ subtle?: string;
24
+ inverted?: string;
25
+ error?: string;
26
+ };
27
+ modal?: {
28
+ surface?: {
29
+ main?: string;
30
+ footer?: string;
31
+ };
32
+ border?: string;
33
+ };
34
+ input?: {
35
+ surface?: {
36
+ disabled?: string;
37
+ default?: string;
38
+ };
39
+ border?: {
40
+ placeholder?: string;
41
+ active?: string;
42
+ error?: string;
43
+ };
44
+ };
45
+ tileButton?: {
46
+ surface?: {
47
+ default?: string;
48
+ hover?: string;
49
+ pressed?: string;
50
+ };
51
+ border?: string;
52
+ };
53
+ primaryButton?: {
54
+ surface?: {
55
+ default?: string;
56
+ hover?: string;
57
+ pressed?: string;
58
+ disabled?: string;
59
+ };
60
+ border?: {
61
+ default?: string;
62
+ disabled?: string;
63
+ };
64
+ outline?: string;
65
+ };
66
+ secondaryButton?: {
67
+ surface?: {
68
+ default?: string;
69
+ hover?: string;
70
+ pressed?: string;
71
+ disabled?: string;
72
+ };
73
+ border?: {
74
+ default?: string;
75
+ disabled?: string;
76
+ };
77
+ outline?: string;
78
+ };
79
+ divider?: string;
80
+ spinner?: {
81
+ path?: string;
82
+ circle?: string;
83
+ };
84
+ pill?: {
85
+ text?: string;
86
+ container?: {
87
+ background?: string;
88
+ border?: string;
89
+ };
90
+ };
91
+ progressIndicator?: {
92
+ active?: string;
93
+ next?: string;
94
+ previous?: string;
95
+ };
96
+ qr?: {
97
+ fill?: string;
98
+ background?: string;
99
+ border?: string;
100
+ };
101
+ slideButton?: {
102
+ slider?: {
103
+ background?: string;
104
+ border?: string;
105
+ text?: string;
106
+ container?: {
107
+ start?: {
108
+ background?: string;
109
+ border?: string;
110
+ };
111
+ end?: {
112
+ background?: string;
113
+ border?: string;
114
+ };
115
+ };
116
+ };
117
+ start?: {
118
+ text?: string;
119
+ };
120
+ end?: {
121
+ text?: string;
122
+ };
123
+ };
124
+ alert?: {
125
+ surface?: {
126
+ error?: string;
127
+ };
128
+ border?: {
129
+ error?: string;
130
+ };
131
+ };
132
+ }
@@ -0,0 +1,2 @@
1
+ import { Theme } from '../../interface';
2
+ export declare const generateBorderRadii: ({ borderRadius }: Pick<Theme, 'borderRadius'>) => void;
@@ -0,0 +1,2 @@
1
+ import { Theme } from '../../interface';
2
+ export declare const generateFont: ({ font }: Pick<Theme, 'font'>) => void;
@@ -0,0 +1,7 @@
1
+ import { Theme } from '../../interface';
2
+ export type Palette = {
3
+ foregroundColors: string[];
4
+ backgroundColors: string[];
5
+ isDarkBackground: boolean;
6
+ };
7
+ export declare const generatePalette: ({ foregroundColor, backgroundColor, customPalette }: Pick<Theme, 'foregroundColor' | 'backgroundColor' | 'customPalette'>) => Palette;
@@ -0,0 +1,3 @@
1
+ import { Theme } from '../../interface';
2
+ declare const generateTheme: ({ foregroundColor, backgroundColor, font, customPalette, borderRadius }: Theme) => boolean;
3
+ export default generateTheme;
@@ -0,0 +1,5 @@
1
+ import { CustomPalette } from '../../interface';
2
+ export declare const isColor: (strColor: any) => boolean;
3
+ export declare const getCssColors: (customPalette: CustomPalette) => {
4
+ [k: string]: string;
5
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@usecapsule/core-components",
3
- "version": "1.0.11",
3
+ "version": "1.0.13-dev.0",
4
4
  "description": "Capsule Core Components",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.js",
@@ -27,7 +27,9 @@
27
27
  },
28
28
  "dependencies": {
29
29
  "@stencil/core": "^4.7.0",
30
+ "color2k": "^2.0.3",
30
31
  "gsap": "^3.12.5",
32
+ "lottie-web": "^5.12.2",
31
33
  "qr-code-styling": "^1.6.0-rc.1"
32
34
  },
33
35
  "devDependencies": {
@@ -43,9 +45,9 @@
43
45
  "jest": "^29.7.0",
44
46
  "jest-cli": "^29.7.0",
45
47
  "puppeteer": "^21.9.0",
48
+ "rollup-plugin-dotenv": "^0.5.0",
46
49
  "sass": "^1.71.1",
47
50
  "stencil-inline-svg": "^1.1.0",
48
51
  "ts-node": "^10.9.2"
49
- },
50
- "gitHead": "836431e75a5e255bfa6b04bdaeeabdf3fb70091e"
52
+ }
51
53
  }
@@ -1,2 +0,0 @@
1
- import{r as d,h as o,H as r}from"./p-9647dd63.js";const a=":host{--box-border-radius:var(--cpsl-border-radius-info-box);--box-padding-top:16px;--box-padding-bottom:16px;--box-padding-start:16px;--box-padding-end:16px;--box-border-width:1px}.info-box-container{border-radius:var(--input-border-radius);-webkit-padding-start:var(--box-padding-start);padding-inline-start:var(--box-padding-start);-webkit-padding-end:var(--box-padding-end);padding-inline-end:var(--box-padding-end);padding-top:var(--box-padding-top);padding-bottom:var(--box-padding-bottom);display:flex;background-color:var(--cpsl-color-background-subtle);border:var(--box-border-width) solid var(--cpsl-color-input-border-placeholder);border-radius:var(--box-border-radius)}";const b=a;const i=class{constructor(o){d(this,o)}render(){return o(r,{key:"17a3490640f95a341c0942188979b2cb82f37da1"},o("div",{key:"51c7731b3e11119e3fcb96f5ef2f47ffd71ba097",class:"info-box-container"},o("slot",{key:"82bfc871c4fb3856e553637514806435473f4728"})))}};i.style=b;export{i as cpsl_info_box};
2
- //# sourceMappingURL=p-1dc07cd7.entry.js.map
@@ -1,2 +0,0 @@
1
- import{r as a,h as e,H as s}from"./p-9647dd63.js";const c=":host{display:flex;flex-wrap:wrap}";const r=c;const o=class{constructor(e){a(this,e)}render(){return e(s,{key:"6b0ced877619502c78baeccaceaf68f1feed6ea7"},e("slot",{key:"d132ce91967ad16904886baa14149ac8990d314f"}))}};o.style=r;export{o as cpsl_row};
2
- //# sourceMappingURL=p-5c020abe.entry.js.map
@@ -1,3 +0,0 @@
1
- const t="capsule";let e;let n;let s=false;let o=false;let l=false;const c=(t,e="")=>{{return()=>{}}};const i=(t,e)=>{{return()=>{}}};const f="{visibility:hidden}.hydrated{visibility:inherit}";const r="slot-fb{display:contents}slot-fb[hidden]{display:none}";const u={};const a="http://www.w3.org/2000/svg";const d="http://www.w3.org/1999/xhtml";const p=t=>t!=null;const y=t=>{t=typeof t;return t==="object"||t==="function"};function h(t){var e,n,s;return(s=(n=(e=t.head)===null||e===void 0?void 0:e.querySelector('meta[name="csp-nonce"]'))===null||n===void 0?void 0:n.getAttribute("content"))!==null&&s!==void 0?s:undefined}const v=(t,e,...n)=>{let s=null;let o=null;let l=false;let c=false;const i=[];const f=e=>{for(let n=0;n<e.length;n++){s=e[n];if(Array.isArray(s)){f(s)}else if(s!=null&&typeof s!=="boolean"){if(l=typeof t!=="function"&&!y(s)){s=String(s)}if(l&&c){i[i.length-1].t+=s}else{i.push(l?m(null,s):s)}c=l}}};f(n);if(e){if(e.key){o=e.key}{const t=e.className||e.class;if(t){e.class=typeof t!=="object"?t:Object.keys(t).filter((e=>t[e])).join(" ")}}}const r=m(t,null);r.o=e;if(i.length>0){r.l=i}{r.i=o}return r};const m=(t,e)=>{const n={u:0,p:t,t:e,h:null,l:null};{n.o=null}{n.i=null}return n};const b={};const $=t=>t&&t.p===b;const w=(t,e)=>{if(t!=null&&!y(t)){if(e&4){return t==="false"?false:t===""||!!t}if(e&2){return parseFloat(t)}if(e&1){return String(t)}return t}return t};const g=t=>ht(t).$hostElement$;const S=(t,e,n)=>{const s=g(t);return{emit:t=>j(s,e,{bubbles:!!(n&4),composed:!!(n&2),cancelable:!!(n&1),detail:t})}};const j=(t,e,n)=>{const s=kt.ce(e,n);t.dispatchEvent(s);return s};const O=new WeakMap;const k=(t,e,n)=>{let s=St.get(t);if(xt&&n){s=s||new CSSStyleSheet;if(typeof s==="string"){s=e}else{s.replaceSync(e)}}else{s=e}St.set(t,s)};const C=(t,e,n)=>{var s;const o=x(e);const l=St.get(o);t=t.nodeType===11?t:Ot;if(l){if(typeof l==="string"){t=t.head||t;let n=O.get(t);let c;if(!n){O.set(t,n=new Set)}if(!n.has(o)){{c=Ot.createElement("style");c.innerHTML=l;const e=(s=kt.v)!==null&&s!==void 0?s:h(Ot);if(e!=null){c.setAttribute("nonce",e)}t.insertBefore(c,t.querySelector("link"))}if(e.u&4){c.innerHTML+=r}if(n){n.add(o)}}}else if(!t.adoptedStyleSheets.includes(l)){t.adoptedStyleSheets=[...t.adoptedStyleSheets,l]}}return o};const M=t=>{const e=t.m;const n=t.$hostElement$;const s=e.u;const o=c("attachStyles",e.$);const l=C(n.shadowRoot?n.shadowRoot:n.getRootNode(),e);if(s&10){n["s-sc"]=l;n.classList.add(l+"-h")}o()};const x=(t,e)=>"sc-"+t.$;const E=(t,e,n,s,o,l)=>{if(n!==s){let c=bt(t,e);let i=e.toLowerCase();if(e==="class"){const e=t.classList;const o=L(n);const l=L(s);e.remove(...o.filter((t=>t&&!l.includes(t))));e.add(...l.filter((t=>t&&!o.includes(t))))}else if(e==="style"){{for(const e in n){if(!s||s[e]==null){if(e.includes("-")){t.style.removeProperty(e)}else{t.style[e]=""}}}}for(const e in s){if(!n||s[e]!==n[e]){if(e.includes("-")){t.style.setProperty(e,s[e])}else{t.style[e]=s[e]}}}}else if(e==="key");else if(!c&&e[0]==="o"&&e[1]==="n"){if(e[2]==="-"){e=e.slice(3)}else if(bt(jt,i)){e=i.slice(2)}else{e=i[2]+e.slice(3)}if(n||s){const o=e.endsWith(U);e=e.replace(A,"");if(n){kt.rel(t,e,n,o)}if(s){kt.ael(t,e,s,o)}}}else{const i=y(s);if((c||i&&s!==null)&&!o){try{if(!t.tagName.includes("-")){const o=s==null?"":s;if(e==="list"){c=false}else if(n==null||t[e]!=o){t[e]=o}}else{t[e]=s}}catch(t){}}if(s==null||s===false){if(s!==false||t.getAttribute(e)===""){{t.removeAttribute(e)}}}else if((!c||l&4||o)&&!i){s=s===true?"":s;{t.setAttribute(e,s)}}}}};const P=/\s/;const L=t=>!t?[]:t.split(P);const U="Capture";const A=new RegExp(U+"$");const N=(t,e,n,s)=>{const o=e.h.nodeType===11&&e.h.host?e.h.host:e.h;const l=t&&t.o||u;const c=e.o||u;{for(s in l){if(!(s in c)){E(o,s,l[s],undefined,n,e.u)}}}for(s in c){E(o,s,l[s],c[s],n,e.u)}};const R=(t,s,l,c)=>{const i=s.l[l];let f=0;let r;let u;if(i.t!==null){r=i.h=Ot.createTextNode(i.t)}else{if(!o){o=i.p==="svg"}r=i.h=Ot.createElementNS(o?a:d,i.p);if(o&&i.p==="foreignObject"){o=false}{N(null,i,o)}if(p(e)&&r["s-si"]!==e){r.classList.add(r["s-si"]=e)}if(i.l){for(f=0;f<i.l.length;++f){u=R(t,i,f);if(u){r.appendChild(u)}}}{if(i.p==="svg"){o=false}else if(r.tagName==="foreignObject"){o=true}}}r["s-hn"]=n;return r};const T=(t,e,s,o,l,c)=>{let i=t;let f;if(i.shadowRoot&&i.tagName===n){i=i.shadowRoot}for(;l<=c;++l){if(o[l]){f=R(null,s,l);if(f){o[l].h=f;i.insertBefore(f,e)}}}};const W=(t,e,n)=>{for(let s=e;s<=n;++s){const e=t[s];if(e){const t=e.h;if(t){t.remove()}}}};const F=(t,e,n,s,o=false)=>{let l=0;let c=0;let i=0;let f=0;let r=e.length-1;let u=e[0];let a=e[r];let d=s.length-1;let p=s[0];let y=s[d];let h;let v;while(l<=r&&c<=d){if(u==null){u=e[++l]}else if(a==null){a=e[--r]}else if(p==null){p=s[++c]}else if(y==null){y=s[--d]}else if(H(u,p,o)){q(u,p,o);u=e[++l];p=s[++c]}else if(H(a,y,o)){q(a,y,o);a=e[--r];y=s[--d]}else if(H(u,y,o)){q(u,y,o);t.insertBefore(u.h,a.h.nextSibling);u=e[++l];y=s[--d]}else if(H(a,p,o)){q(a,p,o);t.insertBefore(a.h,u.h);a=e[--r];p=s[++c]}else{i=-1;{for(f=l;f<=r;++f){if(e[f]&&e[f].i!==null&&e[f].i===p.i){i=f;break}}}if(i>=0){v=e[i];if(v.p!==p.p){h=R(e&&e[c],n,i)}else{q(v,p,o);e[i]=undefined;h=v.h}p=s[++c]}else{h=R(e&&e[c],n,c);p=s[++c]}if(h){{u.h.parentNode.insertBefore(h,u.h)}}}}if(l>r){T(t,s[d+1]==null?null:s[d+1].h,n,s,c,d)}else if(c>d){W(e,l,r)}};const H=(t,e,n=false)=>{if(t.p===e.p){if(!n){return t.i===e.i}return true}return false};const q=(t,e,n=false)=>{const l=e.h=t.h;const c=t.l;const i=e.l;const f=e.p;const r=e.t;if(r===null){{o=f==="svg"?true:f==="foreignObject"?false:o}{if(f==="slot"&&!s);else{N(t,e,o)}}if(c!==null&&i!==null){F(l,c,e,i,n)}else if(i!==null){if(t.t!==null){l.textContent=""}T(l,null,e,i,0,i.length-1)}else if(c!==null){W(c,0,c.length-1)}if(o&&f==="svg"){o=false}}else if(t.t!==r){l.data=r}};const D=(t,o,l=false)=>{const c=t.$hostElement$;const i=t.m;const f=t.S||m(null,null);const r=$(o)?o:v(null,null,o);n=c.tagName;if(i.j){r.o=r.o||{};i.j.map((([t,e])=>r.o[e]=c[t]))}if(l&&r.o){for(const t of Object.keys(r.o)){if(c.hasAttribute(t)&&!["key","ref","style","class"].includes(t)){r.o[t]=c[t]}}}r.p=null;r.u|=4;t.S=r;r.h=f.h=c.shadowRoot||c;{e=c["s-sc"]}s=(i.u&1)!==0;q(f,r,l)};const I=(t,e)=>{if(e&&!t.O&&e["s-p"]){e["s-p"].push(new Promise((e=>t.O=e)))}};const V=(t,e)=>{{t.u|=16}if(t.u&4){t.u|=512;return}I(t,t.k);const n=()=>_(t,e);return Rt(n)};const _=(t,e)=>{const n=c("scheduleUpdate",t.m.$);const s=t.C;let o;if(e){{t.u|=256;if(t.M){t.M.map((([t,e])=>Y(s,t,e)));t.M=undefined}}{o=Y(s,"componentWillLoad")}}n();return z(o,(()=>G(t,s,e)))};const z=(t,e)=>B(t)?t.then(e):e();const B=t=>t instanceof Promise||t&&t.then&&typeof t.then==="function";const G=async(t,e,n)=>{var s;const o=t.$hostElement$;const l=c("update",t.m.$);const i=o["s-rc"];if(n){M(t)}const f=c("render",t.m.$);{J(t,e,o,n)}if(i){i.map((t=>t()));o["s-rc"]=undefined}f();l();{const e=(s=o["s-p"])!==null&&s!==void 0?s:[];const n=()=>K(t);if(e.length===0){n()}else{Promise.all(e).then(n);t.u|=4;e.length=0}}};const J=(t,e,n,s)=>{try{e=e.render();{t.u&=~16}{t.u|=2}{{{D(t,e,s)}}}}catch(e){$t(e,t.$hostElement$)}return null};const K=t=>{const e=t.m.$;const n=t.$hostElement$;const s=c("postUpdate",e);const o=t.C;const l=t.k;if(!(t.u&64)){t.u|=64;{Z(n)}{Y(o,"componentDidLoad")}s();{t.P(n);if(!l){X()}}}else{s()}{if(t.O){t.O();t.O=undefined}if(t.u&512){Nt((()=>V(t,false)))}t.u&=~(4|512)}};const Q=t=>{{const e=ht(t);const n=e.$hostElement$.isConnected;if(n&&(e.u&(2|16))===2){V(e,false)}return n}};const X=e=>{{Z(Ot.documentElement)}Nt((()=>j(jt,"appload",{detail:{namespace:t}})))};const Y=(t,e,n)=>{if(t&&t[e]){try{return t[e](n)}catch(t){$t(t)}}return undefined};const Z=t=>t.classList.add("hydrated");const tt=(t,e)=>ht(t).L.get(e);const et=(t,e,n,s)=>{const o=ht(t);const l=o.$hostElement$;const c=o.L.get(e);const i=o.u;const f=o.C;n=w(n,s.U[e][0]);const r=Number.isNaN(c)&&Number.isNaN(n);const u=n!==c&&!r;if((!(i&8)||c===undefined)&&u){o.L.set(e,n);if(f){if(s.A&&i&128){const t=s.A[e];if(t){t.map((t=>{try{f[t](n,c,e)}catch(t){$t(t,l)}}))}}if((i&(2|16))===2){V(o,false)}}}};const nt=(t,e,n)=>{var s;const o=t.prototype;if(e.U){if(t.watchers){e.A=t.watchers}const l=Object.entries(e.U);l.map((([t,[s]])=>{if(s&31||n&2&&s&32){Object.defineProperty(o,t,{get(){return tt(this,t)},set(n){et(this,t,n,e)},configurable:true,enumerable:true})}}));if(n&1){const n=new Map;o.attributeChangedCallback=function(t,s,l){kt.jmp((()=>{var c;const i=n.get(t);if(this.hasOwnProperty(i)){l=this[i];delete this[i]}else if(o.hasOwnProperty(i)&&typeof this[i]==="number"&&this[i]==l){return}else if(i==null){const n=ht(this);const o=n===null||n===void 0?void 0:n.u;if(o&&!(o&8)&&o&128&&l!==s){const o=n.C;const i=(c=e.A)===null||c===void 0?void 0:c[t];i===null||i===void 0?void 0:i.forEach((e=>{if(o[e]!=null){o[e].call(o,l,s,t)}}))}return}this[i]=l===null&&typeof this[i]==="boolean"?false:l}))};t.observedAttributes=Array.from(new Set([...Object.keys((s=e.A)!==null&&s!==void 0?s:{}),...l.filter((([t,e])=>e[0]&15)).map((([t,s])=>{var o;const l=s[1]||t;n.set(l,t);if(s[0]&512){(o=e.j)===null||o===void 0?void 0:o.push([t,l])}return l}))]))}}return t};const st=async(t,e,n,s)=>{let o;if((e.u&32)===0){e.u|=32;const s=n.N;if(s){o=gt(n);if(o.then){const t=i();o=await o;t()}if(!o.isProxied){{n.A=o.watchers}nt(o,n,2);o.isProxied=true}const t=c("createInstance",n.$);{e.u|=8}try{new o(e)}catch(t){$t(t)}{e.u&=~8}{e.u|=128}t()}else{o=t.constructor;customElements.whenDefined(n.$).then((()=>e.u|=128))}if(o.style){let t=o.style;const e=x(n);if(!St.has(e)){const s=c("registerStyles",n.$);k(e,t,!!(n.u&1));s()}}}const l=e.k;const f=()=>V(e,true);if(l&&l["s-rc"]){l["s-rc"].push(f)}else{f()}};const ot=t=>{};const lt=t=>{if((kt.u&1)===0){const e=ht(t);const n=e.m;const s=c("connectedCallback",n.$);if(!(e.u&1)){e.u|=1;{let n=t;while(n=n.parentNode||n.host){if(n["s-p"]){I(e,e.k=n);break}}}if(n.U){Object.entries(n.U).map((([e,[n]])=>{if(n&31&&t.hasOwnProperty(e)){const n=t[e];delete t[e];t[e]=n}}))}{st(t,e,n)}}else{rt(t,e,n.R);if(e===null||e===void 0?void 0:e.C);else if(e===null||e===void 0?void 0:e.T){e.T.then((()=>ot()))}}s()}};const ct=t=>{};const it=async t=>{if((kt.u&1)===0){const e=ht(t);{if(e.W){e.W.map((t=>t()));e.W=undefined}}if(e===null||e===void 0?void 0:e.C);else if(e===null||e===void 0?void 0:e.T){e.T.then((()=>ct()))}}};const ft=(t,e={})=>{var n;const s=c();const o=[];const l=e.exclude||[];const i=jt.customElements;const u=Ot.head;const a=u.querySelector("meta[charset]");const d=Ot.createElement("style");const p=[];let y;let v=true;Object.assign(kt,e);kt.F=new URL(e.resourcesUrl||"./",Ot.baseURI).href;let m=false;t.map((t=>{t[1].map((e=>{var n;const s={u:e[0],$:e[1],U:e[2],R:e[3]};if(s.u&4){m=true}{s.U=e[2]}{s.R=e[3]}{s.j=[]}{s.A=(n=e[4])!==null&&n!==void 0?n:{}}const c=s.$;const f=class extends HTMLElement{constructor(t){super(t);t=this;mt(t,s);if(s.u&1){{{t.attachShadow({mode:"open"})}}}}connectedCallback(){if(y){clearTimeout(y);y=null}if(v){p.push(this)}else{kt.jmp((()=>lt(this)))}}disconnectedCallback(){kt.jmp((()=>it(this)))}componentOnReady(){return ht(this).T}};s.N=t[0];if(!l.includes(c)&&!i.get(c)){o.push(c);i.define(c,nt(f,s,1))}}))}));if(o.length>0){if(m){d.textContent+=r}{d.textContent+=o+f}if(d.innerHTML.length){d.setAttribute("data-styles","");const t=(n=kt.v)!==null&&n!==void 0?n:h(Ot);if(t!=null){d.setAttribute("nonce",t)}u.insertBefore(d,a?a.nextSibling:u.firstChild)}}v=false;if(p.length){p.map((t=>t.connectedCallback()))}else{{kt.jmp((()=>y=setTimeout(X,30)))}}s()};const rt=(t,e,n,s)=>{if(n){n.map((([n,s,o])=>{const l=at(t,n);const c=ut(e,o);const i=dt(n);kt.ael(l,s,c,i);(e.W=e.W||[]).push((()=>kt.rel(l,s,c,i)))}))}};const ut=(t,e)=>n=>{try{{if(t.u&256){t.C[e](n)}else{(t.M=t.M||[]).push([e,n])}}}catch(t){$t(t)}};const at=(t,e)=>{if(e&8)return jt;return t};const dt=t=>Ct?{passive:(t&1)!==0,capture:(t&2)!==0}:(t&2)!==0;const pt=t=>kt.v=t;const yt=new WeakMap;const ht=t=>yt.get(t);const vt=(t,e)=>yt.set(e.C=t,e);const mt=(t,e)=>{const n={u:0,$hostElement$:t,m:e,L:new Map};{n.T=new Promise((t=>n.P=t));t["s-p"]=[];t["s-rc"]=[]}rt(t,n,e.R);return yt.set(t,n)};const bt=(t,e)=>e in t;const $t=(t,e)=>(0,console.error)(t,e);const wt=new Map;const gt=(t,e,n)=>{const s=t.$.replace(/-/g,"_");const o=t.N;const l=wt.get(o);if(l){return l[s]}
2
- /*!__STENCIL_STATIC_IMPORT_SWITCH__*/return import(`./${o}.entry.js${""}`).then((t=>{{wt.set(o,t)}return t[s]}),$t)};const St=new Map;const jt=typeof window!=="undefined"?window:{};const Ot=jt.document||{head:{}};const kt={u:0,F:"",jmp:t=>t(),raf:t=>requestAnimationFrame(t),ael:(t,e,n,s)=>t.addEventListener(e,n,s),rel:(t,e,n,s)=>t.removeEventListener(e,n,s),ce:(t,e)=>new CustomEvent(t,e)};const Ct=(()=>{let t=false;try{Ot.addEventListener("e",null,Object.defineProperty({},"passive",{get(){t=true}}))}catch(t){}return t})();const Mt=t=>Promise.resolve(t);const xt=(()=>{try{new CSSStyleSheet;return typeof(new CSSStyleSheet).replaceSync==="function"}catch(t){}return false})();const Et=[];const Pt=[];const Lt=(t,e)=>n=>{t.push(n);if(!l){l=true;if(e&&kt.u&4){Nt(At)}else{kt.raf(At)}}};const Ut=t=>{for(let e=0;e<t.length;e++){try{t[e](performance.now())}catch(t){$t(t)}}t.length=0};const At=()=>{Ut(Et);{Ut(Pt);if(l=Et.length>0){kt.raf(At)}}};const Nt=t=>Mt().then(t);const Rt=Lt(Pt,true);export{b as H,ft as b,S as c,Q as f,g,v as h,Mt as p,vt as r,pt as s};
3
- //# sourceMappingURL=p-9647dd63.js.map