@supersoniks/concorde 1.1.41 → 1.1.43

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 (234) hide show
  1. package/README.md +0 -0
  2. package/cli.js +0 -0
  3. package/components.d.ts +0 -0
  4. package/components.js +2 -3
  5. package/concorde-core.bundle.js +37 -42
  6. package/concorde-core.es.js +5702 -4823
  7. package/core/_types/types.d.ts +26 -0
  8. package/core/_types/types.js +1 -0
  9. package/core/components/functional/date/date.d.ts +13 -5
  10. package/core/components/functional/date/date.js +48 -29
  11. package/core/components/functional/example/example.d.ts +1 -1
  12. package/core/components/functional/example/example.js +1 -1
  13. package/core/components/functional/fetch/fetch.d.ts +40 -3
  14. package/core/components/functional/fetch/fetch.js +2 -6
  15. package/core/components/functional/functional.d.ts +2 -0
  16. package/core/components/functional/functional.js +2 -0
  17. package/core/components/functional/if/if.d.ts +3 -0
  18. package/core/components/functional/if/if.js +6 -12
  19. package/core/components/functional/if/if.test.d.ts +1 -0
  20. package/core/components/functional/if/if.test.js +44 -0
  21. package/core/components/functional/list/list.d.ts +32 -8
  22. package/core/components/functional/list/list.js +33 -40
  23. package/core/components/functional/mix/mix.d.ts +22 -0
  24. package/core/components/functional/mix/mix.js +99 -0
  25. package/core/components/functional/queue/queue.d.ts +16 -3
  26. package/core/components/functional/queue/queue.js +71 -15
  27. package/core/components/functional/router/redirect.d.ts +10 -1
  28. package/core/components/functional/router/redirect.js +5 -6
  29. package/core/components/functional/router/router.d.ts +15 -1
  30. package/core/components/functional/router/router.js +1 -6
  31. package/core/components/functional/sdui/SDUIDescriptorTransformer.d.ts +1 -1
  32. package/core/components/functional/sdui/SDUIDescriptorTransformer.js +24 -12
  33. package/core/components/functional/sdui/default-library.json +108 -0
  34. package/core/components/functional/sdui/sdui-utils.d.ts +5 -0
  35. package/core/components/functional/sdui/sdui-utils.js +63 -0
  36. package/core/components/functional/sdui/sdui.d.ts +20 -9
  37. package/core/components/functional/sdui/sdui.js +64 -24
  38. package/core/components/functional/sdui/types.d.ts +4 -2
  39. package/core/components/functional/sdui/types.js +0 -0
  40. package/core/components/functional/sonic-scope/sonic-scope.d.ts +0 -0
  41. package/core/components/functional/sonic-scope/sonic-scope.js +0 -0
  42. package/core/components/functional/states/states.d.ts +19 -3
  43. package/core/components/functional/states/states.js +7 -12
  44. package/core/components/functional/submit/submit.d.ts +16 -1
  45. package/core/components/functional/submit/submit.js +87 -17
  46. package/core/components/functional/subscriber/subscriber.d.ts +4 -1
  47. package/core/components/functional/subscriber/subscriber.js +1 -6
  48. package/core/components/functional/value/value.d.ts +7 -0
  49. package/core/components/functional/value/value.js +26 -0
  50. package/core/components/ui/_css/scroll.d.ts +0 -0
  51. package/core/components/ui/_css/scroll.js +6 -7
  52. package/core/components/ui/_css/size.d.ts +1 -0
  53. package/core/components/ui/_css/size.js +3 -1
  54. package/core/components/ui/_css/type.d.ts +0 -0
  55. package/core/components/ui/_css/type.js +0 -0
  56. package/core/components/ui/alert/alert.d.ts +2 -2
  57. package/core/components/ui/alert/alert.js +11 -16
  58. package/core/components/ui/badge/badge.d.ts +3 -1
  59. package/core/components/ui/badge/badge.js +36 -22
  60. package/core/components/ui/button/button.d.ts +23 -20
  61. package/core/components/ui/button/button.js +59 -42
  62. package/core/components/ui/captcha/captcha.d.ts +14 -2
  63. package/core/components/ui/captcha/captcha.js +17 -12
  64. package/core/components/ui/card/card-footer.d.ts +0 -0
  65. package/core/components/ui/card/card-footer.js +1 -8
  66. package/core/components/ui/card/card-header-descripton.d.ts +0 -0
  67. package/core/components/ui/card/card-header-descripton.js +3 -9
  68. package/core/components/ui/card/card-header.d.ts +0 -0
  69. package/core/components/ui/card/card-header.js +1 -6
  70. package/core/components/ui/card/card-main.d.ts +0 -0
  71. package/core/components/ui/card/card-main.js +0 -5
  72. package/core/components/ui/card/card.d.ts +1 -1
  73. package/core/components/ui/card/card.js +28 -12
  74. package/core/components/ui/divider/divider.d.ts +2 -0
  75. package/core/components/ui/divider/divider.js +44 -17
  76. package/core/components/ui/form/checkbox/checkbox.d.ts +53 -16
  77. package/core/components/ui/form/checkbox/checkbox.js +54 -29
  78. package/core/components/ui/form/css/form-control.d.ts +2 -0
  79. package/core/components/ui/form/css/form-control.js +145 -67
  80. package/core/components/ui/form/fieldset/fieldset.d.ts +8 -1
  81. package/core/components/ui/form/fieldset/fieldset.js +45 -8
  82. package/core/components/ui/form/fieldset/legend-description.d.ts +0 -0
  83. package/core/components/ui/form/fieldset/legend-description.js +0 -5
  84. package/core/components/ui/form/fieldset/legend.d.ts +0 -0
  85. package/core/components/ui/form/fieldset/legend.js +4 -7
  86. package/core/components/ui/form/form-actions/form-actions.d.ts +2 -0
  87. package/core/components/ui/form/form-actions/form-actions.js +26 -11
  88. package/core/components/ui/form/form-layout/form-layout.d.ts +5 -2
  89. package/core/components/ui/form/form-layout/form-layout.js +31 -9
  90. package/core/components/ui/form/input/input.d.ts +15 -18
  91. package/core/components/ui/form/input/input.js +89 -54
  92. package/core/components/ui/form/input/password-helper.d.ts +7 -1
  93. package/core/components/ui/form/input/password-helper.js +33 -10
  94. package/core/components/ui/form/input/same-value-helper.d.ts +1 -1
  95. package/core/components/ui/form/input/same-value-helper.js +1 -0
  96. package/core/components/ui/form/input-autocomplete/input-autocomplete.d.ts +34 -0
  97. package/core/components/ui/form/input-autocomplete/input-autocomplete.js +133 -0
  98. package/core/components/ui/form/radio/radio.d.ts +6 -0
  99. package/core/components/ui/form/radio/radio.js +7 -12
  100. package/core/components/ui/form/select/select.d.ts +23 -7
  101. package/core/components/ui/form/select/select.js +71 -40
  102. package/core/components/ui/form/textarea/textarea.d.ts +13 -13
  103. package/core/components/ui/form/textarea/textarea.js +31 -38
  104. package/core/components/ui/group/group.d.ts +11 -1
  105. package/core/components/ui/group/group.js +79 -17
  106. package/core/components/ui/icon/icon.d.ts +10 -3
  107. package/core/components/ui/icon/icon.js +16 -15
  108. package/core/components/ui/icon/icons.d.ts +0 -0
  109. package/core/components/ui/icon/icons.js +11 -8
  110. package/core/components/ui/icon/icons.json +1 -1
  111. package/core/components/ui/image/image.d.ts +0 -0
  112. package/core/components/ui/image/image.js +0 -5
  113. package/core/components/ui/link/link.d.ts +1 -1
  114. package/core/components/ui/link/link.js +2 -6
  115. package/core/components/ui/loader/loader.d.ts +0 -0
  116. package/core/components/ui/loader/loader.js +2 -8
  117. package/core/components/ui/loader/styles/fixed.d.ts +0 -0
  118. package/core/components/ui/loader/styles/fixed.js +0 -0
  119. package/core/components/ui/loader/styles/inline.d.ts +0 -0
  120. package/core/components/ui/loader/styles/inline.js +0 -0
  121. package/core/components/ui/menu/menu-item.d.ts +0 -0
  122. package/core/components/ui/menu/menu-item.js +4 -9
  123. package/core/components/ui/menu/menu.d.ts +9 -1
  124. package/core/components/ui/menu/menu.js +183 -27
  125. package/core/components/ui/modal/modal-actions.d.ts +0 -0
  126. package/core/components/ui/modal/modal-actions.js +1 -6
  127. package/core/components/ui/modal/modal-close.d.ts +1 -0
  128. package/core/components/ui/modal/modal-close.js +14 -10
  129. package/core/components/ui/modal/modal-content.d.ts +0 -0
  130. package/core/components/ui/modal/modal-content.js +0 -5
  131. package/core/components/ui/modal/modal-subtitle.d.ts +0 -0
  132. package/core/components/ui/modal/modal-subtitle.js +2 -6
  133. package/core/components/ui/modal/modal-title.d.ts +0 -0
  134. package/core/components/ui/modal/modal-title.js +0 -5
  135. package/core/components/ui/modal/modal.d.ts +7 -7
  136. package/core/components/ui/modal/modal.js +36 -36
  137. package/core/components/ui/pop/pop.d.ts +2 -1
  138. package/core/components/ui/pop/pop.js +11 -10
  139. package/core/components/ui/progress/progress.d.ts +0 -0
  140. package/core/components/ui/progress/progress.js +34 -32
  141. package/core/components/ui/table/table-caption.d.ts +0 -0
  142. package/core/components/ui/table/table-caption.js +5 -10
  143. package/core/components/ui/table/table-tbody.d.ts +0 -0
  144. package/core/components/ui/table/table-tbody.js +10 -14
  145. package/core/components/ui/table/table-td.d.ts +2 -0
  146. package/core/components/ui/table/table-td.js +8 -5
  147. package/core/components/ui/table/table-tfoot.d.ts +0 -0
  148. package/core/components/ui/table/table-tfoot.js +5 -7
  149. package/core/components/ui/table/table-th.d.ts +2 -0
  150. package/core/components/ui/table/table-th.js +12 -9
  151. package/core/components/ui/table/table-thead.d.ts +0 -0
  152. package/core/components/ui/table/table-thead.js +1 -6
  153. package/core/components/ui/table/table-tr.d.ts +0 -0
  154. package/core/components/ui/table/table-tr.js +4 -6
  155. package/core/components/ui/table/table.d.ts +0 -3
  156. package/core/components/ui/table/table.js +14 -31
  157. package/core/components/ui/taxonomy/taxonomy.d.ts +6 -3
  158. package/core/components/ui/taxonomy/taxonomy.js +9 -9
  159. package/core/components/ui/theme/css/tailwind.css +0 -0
  160. package/core/components/ui/theme/css/tailwind.d.ts +0 -0
  161. package/core/components/ui/theme/theme-collection/core-variables.d.ts +0 -0
  162. package/core/components/ui/theme/theme-collection/core-variables.js +13 -11
  163. package/core/components/ui/theme/theme-collection/dark.d.ts +0 -0
  164. package/core/components/ui/theme/theme-collection/dark.js +1 -1
  165. package/core/components/ui/theme/theme-collection/light.d.ts +0 -0
  166. package/core/components/ui/theme/theme-collection/light.js +0 -0
  167. package/core/components/ui/theme/theme.d.ts +1 -6
  168. package/core/components/ui/theme/theme.js +7 -36
  169. package/core/components/ui/toast/message-subscriber.d.ts +13 -7
  170. package/core/components/ui/toast/message-subscriber.js +0 -0
  171. package/core/components/ui/toast/toast-item.d.ts +0 -0
  172. package/core/components/ui/toast/toast-item.js +1 -1
  173. package/core/components/ui/toast/toast.d.ts +2 -1
  174. package/core/components/ui/toast/toast.js +29 -14
  175. package/core/components/ui/toast/types.d.ts +0 -0
  176. package/core/components/ui/toast/types.js +0 -0
  177. package/core/components/ui/tooltip/tooltip.d.ts +1 -0
  178. package/core/components/ui/tooltip/tooltip.js +35 -14
  179. package/core/components/ui/ui.d.ts +1 -0
  180. package/core/components/ui/ui.js +1 -3
  181. package/core/core.d.ts +0 -0
  182. package/core/core.js +5 -6
  183. package/core/mixins/Fetcher.d.ts +19 -10
  184. package/core/mixins/Fetcher.js +26 -10
  185. package/core/mixins/FormCheckable.d.ts +17 -8
  186. package/core/mixins/FormCheckable.js +177 -22
  187. package/core/mixins/FormElement.d.ts +12 -7
  188. package/core/mixins/FormElement.js +42 -26
  189. package/core/mixins/FormInput.d.ts +8 -4
  190. package/core/mixins/FormInput.js +4 -3
  191. package/core/mixins/Subscriber.d.ts +7 -5
  192. package/core/mixins/Subscriber.js +34 -32
  193. package/core/mixins/TemplatesContainer.d.ts +0 -0
  194. package/core/mixins/TemplatesContainer.js +0 -0
  195. package/core/mixins/mixins.d.ts +0 -0
  196. package/core/mixins/mixins.js +0 -0
  197. package/core/utils/Arrays.d.ts +15 -15
  198. package/core/utils/Arrays.js +0 -0
  199. package/core/utils/DataBindObserver.d.ts +16 -9
  200. package/core/utils/DataBindObserver.js +23 -28
  201. package/core/utils/Electron.d.ts +5 -1
  202. package/core/utils/Electron.js +4 -2
  203. package/core/utils/Format.d.ts +0 -0
  204. package/core/utils/Format.js +0 -0
  205. package/core/utils/HTML.d.ts +9 -2
  206. package/core/utils/HTML.js +22 -3
  207. package/core/utils/LocationHandler.d.ts +6 -5
  208. package/core/utils/LocationHandler.js +19 -8
  209. package/core/utils/Objects.d.ts +7 -4
  210. package/core/utils/Objects.js +28 -6
  211. package/core/utils/{PublisherProxy.d.mts → PublisherProxy.d.ts} +40 -31
  212. package/core/utils/{PublisherProxy.mjs → PublisherProxy.js} +54 -28
  213. package/core/utils/Utils.d.ts +3 -0
  214. package/core/utils/Utils.js +18 -0
  215. package/core/utils/api.d.ts +39 -7
  216. package/core/utils/api.js +45 -32
  217. package/img/concorde-logo.svg +1 -0
  218. package/img/concorde.png +0 -0
  219. package/img/concorde_def.png +0 -0
  220. package/mixins.d.ts +36 -18
  221. package/mixins.js +3 -4
  222. package/package.json +47 -10
  223. package/svg/regular/plane.svg +1 -0
  224. package/svg/solid/plane.svg +1 -0
  225. package/test-utils/TestUtils.d.ts +4 -0
  226. package/test-utils/TestUtils.js +12 -0
  227. package/utils.d.ts +3 -1
  228. package/utils.js +7 -5
  229. package/core/components/functional/configuration/configuration.d.ts +0 -5
  230. package/core/components/functional/configuration/configuration.js +0 -22
  231. package/core/components/ui/tabs/tab.d.ts +0 -6
  232. package/core/components/ui/tabs/tab.js +0 -46
  233. package/core/components/ui/tabs/tabs.d.ts +0 -15
  234. package/core/components/ui/tabs/tabs.js +0 -129
@@ -29,7 +29,7 @@ ModalActions.styles = [
29
29
  display: flex;
30
30
  gap: 0.5rem;
31
31
  margin-top: auto;
32
- padding-top: 1rem;
32
+ padding-top: 1.5rem;
33
33
  }
34
34
  `,
35
35
  ];
@@ -40,8 +40,3 @@ ModalActions = __decorate([
40
40
  customElement(tagName)
41
41
  ], ModalActions);
42
42
  export { ModalActions };
43
- //Ajout pour Storybook
44
- try {
45
- customElements.define(tagName, ModalActions);
46
- }
47
- catch (e) { }
@@ -1,6 +1,7 @@
1
1
  import { LitElement } from "lit";
2
2
  export declare class ModalClose extends LitElement {
3
3
  static styles: import("lit").CSSResult[];
4
+ reset?: string;
4
5
  render(): import("lit-html").TemplateResult<1>;
5
6
  handleClick(): void;
6
7
  }
@@ -5,11 +5,12 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
5
5
  return c > 3 && r && Object.defineProperty(target, key, r), r;
6
6
  };
7
7
  import { html, LitElement, css } from "lit";
8
- import { customElement } from "lit/decorators.js";
8
+ import { customElement, property } from "lit/decorators.js";
9
+ import { ifDefined } from "lit/directives/if-defined.js";
9
10
  const tagName = "sonic-modal-close";
10
11
  let ModalClose = class ModalClose extends LitElement {
11
12
  render() {
12
- return html `<sonic-button shape="circle" variant="ghost" @click=${this.handleClick}
13
+ return html `<sonic-button reset=${ifDefined(this.reset)} shape="circle" @click=${this.handleClick}
13
14
  ><sonic-icon name="cancel" size="lg"></sonic-icon
14
15
  ></sonic-button>`;
15
16
  }
@@ -21,19 +22,22 @@ let ModalClose = class ModalClose extends LitElement {
21
22
  ModalClose.styles = [
22
23
  css `
23
24
  :host {
24
- position: absolute;
25
- right: 0.6rem;
26
- top: 0.6rem;
25
+ position: sticky;
26
+ display: block;
27
+ align-self: flex-end;
28
+ height: 0;
29
+ top: 0;
30
+ padding-top: 0.5rem;
31
+ padding-right: 0.5rem;
32
+ transform: translate3d(calc(var(--sc-modal-px)), calc(-1 * var(--sc-modal-py)), 0);
27
33
  z-index: 20;
28
34
  }
29
35
  `,
30
36
  ];
37
+ __decorate([
38
+ property()
39
+ ], ModalClose.prototype, "reset", void 0);
31
40
  ModalClose = __decorate([
32
41
  customElement(tagName)
33
42
  ], ModalClose);
34
43
  export { ModalClose };
35
- //Ajout pour Storybook
36
- try {
37
- customElements.define(tagName, ModalClose);
38
- }
39
- catch (e) { }
File without changes
@@ -23,8 +23,3 @@ ModalContent = __decorate([
23
23
  customElement(tagName)
24
24
  ], ModalContent);
25
25
  export { ModalContent };
26
- //Ajout pour Storybook
27
- try {
28
- customElements.define(tagName, ModalContent);
29
- }
30
- catch (e) { }
File without changes
@@ -17,9 +17,10 @@ ModalSubTitle.styles = [
17
17
  :host {
18
18
  font-size: 1.1rem;
19
19
  display: block;
20
- text-transform: uppercase;
20
+ line-height: 1.1rem;
21
21
  line-height: var(--sc-headings-line-height);
22
22
  font-family: var(--sc-headings-font-family);
23
+ font-weight: var(--sc-headings-font-weight);
23
24
  }
24
25
  `,
25
26
  ];
@@ -27,8 +28,3 @@ ModalSubTitle = __decorate([
27
28
  customElement(tagName)
28
29
  ], ModalSubTitle);
29
30
  export { ModalSubTitle };
30
- //Ajout pour Storybook
31
- try {
32
- customElements.define(tagName, ModalSubTitle);
33
- }
34
- catch (e) { }
File without changes
@@ -27,8 +27,3 @@ ModalTitle = __decorate([
27
27
  customElement(tagName)
28
28
  ], ModalTitle);
29
29
  export { ModalTitle };
30
- //Ajout pour Storybook
31
- try {
32
- customElements.define(tagName, ModalTitle);
33
- }
34
- catch (e) { }
@@ -1,17 +1,16 @@
1
- import { LitElement, nothing } from "lit";
1
+ import { LitElement, nothing, PropertyValues } from "lit";
2
2
  import "@supersoniks/concorde/core/components/ui/modal/modal-actions";
3
- import "@supersoniks/concorde/core/components/ui/modal/modal-title";
4
- import "@supersoniks/concorde/core/components/ui/modal/modal-subtitle";
5
- import "@supersoniks/concorde/core/components/ui/modal/modal-content";
6
3
  import "@supersoniks/concorde/core/components/ui/modal/modal-close";
4
+ import "@supersoniks/concorde/core/components/ui/modal/modal-content";
5
+ import "@supersoniks/concorde/core/components/ui/modal/modal-subtitle";
6
+ import "@supersoniks/concorde/core/components/ui/modal/modal-title";
7
7
  declare type ModalCreateOptions = {
8
8
  content?: string;
9
9
  };
10
- declare const Modal_base: (new (...args: any[]) => import("@supersoniks/concorde/core/mixins/Subscriber").SubscriberInterface) & typeof LitElement;
10
+ declare const Modal_base: (new (...args: any[]) => import("@supersoniks/concorde/core/mixins/Subscriber").SubscriberInterface<any>) & typeof LitElement;
11
11
  export declare class Modal extends Modal_base {
12
12
  static styles: import("lit").CSSResult[];
13
- hideOnOverlayClick: boolean;
14
- hideOnEscape: boolean;
13
+ forceAction: boolean;
15
14
  align: "center" | "right" | "left";
16
15
  padding: string;
17
16
  maxWidth: string;
@@ -26,6 +25,7 @@ export declare class Modal extends Modal_base {
26
25
  static create(options: ModalCreateOptions): Modal;
27
26
  connectedCallback(): void;
28
27
  updated(): void;
28
+ willUpdate(_changedProperties: PropertyValues): void;
29
29
  render(): import("lit-html").TemplateResult<1> | typeof nothing;
30
30
  show(): void;
31
31
  hide(): void;
@@ -4,24 +4,24 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
4
4
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
5
  return c > 3 && r && Object.defineProperty(target, key, r), r;
6
6
  };
7
- import { html, LitElement, css, nothing } from "lit";
8
- import { customElement, property, queryAssignedElements, query } from "lit/decorators.js";
9
- import Subscriber from "@supersoniks/concorde/core/mixins/Subscriber";
10
7
  import { animate, fadeIn, fadeOut } from "@lit-labs/motion";
11
- import { styleMap } from "lit/directives/style-map.js";
12
8
  import { customScroll } from "@supersoniks/concorde/core/components/ui/_css/scroll";
9
+ import Subscriber from "@supersoniks/concorde/core/mixins/Subscriber";
10
+ import { css, html, LitElement, nothing } from "lit";
11
+ import { customElement, property, query, queryAssignedElements } from "lit/decorators.js";
12
+ import { styleMap } from "lit/directives/style-map.js";
13
13
  import "@supersoniks/concorde/core/components/ui/modal/modal-actions";
14
- import "@supersoniks/concorde/core/components/ui/modal/modal-title";
15
- import "@supersoniks/concorde/core/components/ui/modal/modal-subtitle";
16
- import "@supersoniks/concorde/core/components/ui/modal/modal-content";
17
14
  import "@supersoniks/concorde/core/components/ui/modal/modal-close";
15
+ import "@supersoniks/concorde/core/components/ui/modal/modal-content";
16
+ import "@supersoniks/concorde/core/components/ui/modal/modal-subtitle";
17
+ import "@supersoniks/concorde/core/components/ui/modal/modal-title";
18
+ import { PublisherManager } from "@supersoniks/concorde/utils";
18
19
  const tagName = "sonic-modal";
19
20
  let Modal = class Modal extends Subscriber(LitElement) {
20
21
  constructor() {
21
22
  super(...arguments);
22
- this.hideOnOverlayClick = true;
23
- this.hideOnEscape = true;
24
- this.align = "center";
23
+ this.forceAction = false;
24
+ this.align = "left";
25
25
  this.padding = "var(--sc-modal-py) var(--sc-modal-px)";
26
26
  this.maxWidth = "var(--sc-modal-max-w) ";
27
27
  this.maxHeight = "var(--sc-modal-max-h) ";
@@ -41,6 +41,7 @@ let Modal = class Modal extends Subscriber(LitElement) {
41
41
  }
42
42
  connectedCallback() {
43
43
  super.connectedCallback();
44
+ this.handleFullsceen();
44
45
  }
45
46
  updated() {
46
47
  const currentModal = this;
@@ -51,10 +52,15 @@ let Modal = class Modal extends Subscriber(LitElement) {
51
52
  }, { once: true });
52
53
  });
53
54
  }
55
+ willUpdate(_changedProperties) {
56
+ if (_changedProperties.has("fullScreen")) {
57
+ this.handleFullsceen();
58
+ }
59
+ super.willUpdate(_changedProperties);
60
+ }
54
61
  render() {
55
62
  if (this.visible == false)
56
63
  return nothing;
57
- this.handleFullsceen();
58
64
  const modalStyles = {
59
65
  padding: this.padding,
60
66
  maxWidth: this.maxWidth,
@@ -99,7 +105,7 @@ let Modal = class Modal extends Subscriber(LitElement) {
99
105
 
100
106
  <div
101
107
  class="overlay"
102
- @click="${this.hideOnOverlayClick ? this.hide : ""}"
108
+ @click="${!this.forceAction ? this.hide : ""}"
103
109
  ${animate({
104
110
  keyframeOptions: {
105
111
  duration: 500,
@@ -121,6 +127,9 @@ let Modal = class Modal extends Subscriber(LitElement) {
121
127
  this.visible = false;
122
128
  (_a = this.modalElement) === null || _a === void 0 ? void 0 : _a.setAttribute("tabindex", "-1");
123
129
  this.dispatchEvent(new CustomEvent("hide"));
130
+ if (this.hasAttribute("resetDataProviderOnHide")) {
131
+ PublisherManager.get(this.getAttribute("resetDataProviderOnHide")).set({});
132
+ }
124
133
  }
125
134
  dispose() {
126
135
  this.hide();
@@ -130,7 +139,7 @@ let Modal = class Modal extends Subscriber(LitElement) {
130
139
  if (e.key === "Escape") {
131
140
  const modals = [...document.querySelectorAll(tagName)];
132
141
  modals.forEach((item) => {
133
- if (this.hideOnEscape == true) {
142
+ if (!this.forceAction) {
134
143
  item.hide();
135
144
  }
136
145
  });
@@ -152,11 +161,8 @@ Modal.styles = [
152
161
  :host {
153
162
  --sc-modal-py: 2.5rem;
154
163
  --sc-modal-px: 1.5rem;
155
- --sc-modal-content: var(--sc-base-content);
156
- --sc-modal-bg: var(--sc-base);
157
164
  --sc-modal-max-w: min(100vw, 64ch);
158
165
  --sc-modal-max-h: 80vh;
159
- --sc-modal-scrollbar-bg: var(--sc-base-300);
160
166
  --sc-modal-rounded: var(--sc-rounded-lg);
161
167
  }
162
168
 
@@ -170,7 +176,6 @@ Modal.styles = [
170
176
  left: 0;
171
177
  width: 100%;
172
178
  z-index: 990;
173
- text-align: center;
174
179
  align-items: center;
175
180
  justify-content: center;
176
181
  flex-direction: column;
@@ -178,18 +183,16 @@ Modal.styles = [
178
183
  pointer-events: none;
179
184
  }
180
185
 
181
-
182
186
  .modal-content {
183
- overflow-y: auto;
184
187
  display: flex;
185
188
  flex-direction: column;
186
- text-align: center;
187
- align-items: center;
188
189
  min-height: 10rem;
190
+ line-height: 1.25;
189
191
  }
190
192
 
191
193
  .modal {
192
194
  background: var(--sc-base);
195
+ color: var(--sc-base-content);
193
196
  width: 100%;
194
197
  box-shadow: var(--sc-shadow-lg);
195
198
  border-radius: var(--sc-modal-rounded) var(--sc-modal-rounded) 0 0;
@@ -199,7 +202,7 @@ Modal.styles = [
199
202
  }
200
203
 
201
204
  .overlay {
202
- background: var(--sc-base-200);
205
+ background: var(--sc-modal-overlay-bg, var(--sc-base-200));
203
206
  left: 0;
204
207
  top: 0;
205
208
  right: 0;
@@ -210,12 +213,12 @@ Modal.styles = [
210
213
  }
211
214
 
212
215
  ::slotted(sonic-modal-title) {
213
- margin-bottom: 1rem;
216
+ margin-bottom: 1.25rem;
214
217
  }
215
218
 
216
219
  ::slotted(sonic-modal-subtitle) {
217
- margin-top: -0.45rem;
218
- margin-bottom: 1rem;
220
+ margin-top: -0.9rem;
221
+ margin-bottom: 1.25rem;
219
222
  }
220
223
 
221
224
  @media (max-width: 767.5px) {
@@ -248,6 +251,11 @@ Modal.styles = [
248
251
  align-items: flex-start;
249
252
  }
250
253
 
254
+ :host([align="center"]) .modal-content {
255
+ text-align: center;
256
+ align-items: center;
257
+ }
258
+
251
259
  :host([align="right"]) .modal-content {
252
260
  text-align: right;
253
261
  align-items: flex-end;
@@ -260,11 +268,8 @@ Modal.styles = [
260
268
  `,
261
269
  ];
262
270
  __decorate([
263
- property({ type: Boolean, reflect: true })
264
- ], Modal.prototype, "hideOnOverlayClick", void 0);
265
- __decorate([
266
- property({ type: Boolean, reflect: true })
267
- ], Modal.prototype, "hideOnEscape", void 0);
271
+ property({ type: Boolean })
272
+ ], Modal.prototype, "forceAction", void 0);
268
273
  __decorate([
269
274
  property({ type: String, reflect: true })
270
275
  ], Modal.prototype, "align", void 0);
@@ -303,10 +308,5 @@ Modal = __decorate([
303
308
  ], Modal);
304
309
  export { Modal };
305
310
  if (typeof window !== "undefined") {
306
- let win = window;
307
- win.SonicModal = Modal;
308
- }
309
- try {
310
- customElements.define(tagName, Modal);
311
+ window.SonicModal = Modal;
311
312
  }
312
- catch (e) { }
@@ -7,6 +7,7 @@ export declare class Pop extends LitElement {
7
7
  popBtn: HTMLElement;
8
8
  popContent: HTMLElement;
9
9
  toggle: "true" | "false";
10
+ noToggle: boolean;
10
11
  inline: boolean;
11
12
  /**
12
13
  * Ombre
@@ -17,7 +18,7 @@ export declare class Pop extends LitElement {
17
18
  lastContentX: number;
18
19
  lastContentY: number;
19
20
  runPositioning(): void;
20
- _toggle(e: any): void;
21
+ _toggle(e: Event): void;
21
22
  _show(): void;
22
23
  _hide(): void;
23
24
  _handleClosePop(e: Event): void;
@@ -14,6 +14,7 @@ let Pop = Pop_1 = class Pop extends LitElement {
14
14
  super(...arguments);
15
15
  this.open = false;
16
16
  this.toggle = "true";
17
+ this.noToggle = false;
17
18
  this.inline = false;
18
19
  /**
19
20
  * Ombre
@@ -32,9 +33,10 @@ let Pop = Pop_1 = class Pop extends LitElement {
32
33
  window.requestAnimationFrame(() => this.runPositioning());
33
34
  }
34
35
  _toggle(e) {
35
- if (this.open && this.toggle == "false")
36
+ if (this.open && this.noToggle)
36
37
  return;
37
- if (e.type == "keydown" && (e.key != "ArrowDown" || this.open))
38
+ const keyboardEvent = e;
39
+ if (e.type == "keydown" && (keyboardEvent.key != "ArrowDown" || this.open))
38
40
  return;
39
41
  this.open = !this.open;
40
42
  this.open ? this._show() : this._hide();
@@ -158,6 +160,7 @@ Pop.styles = [
158
160
  vertical-align: middle;
159
161
  }
160
162
  slot[name="content"] {
163
+ max-width: 80vw;
161
164
  background-color: var(--sc-base);
162
165
  position: absolute;
163
166
  z-index: 50;
@@ -165,9 +168,9 @@ Pop.styles = [
165
168
  transform: translateY(1rem) scale(0.95);
166
169
  opacity: 0;
167
170
  pointer-events: none;
168
- transition-duration: 0.15s ;
171
+ transition-duration: 0.15s;
169
172
  transition-timing-function: ease;
170
- transition-property:all;
173
+ transition-property: all;
171
174
  border-radius: min(calc(var(--sc-btn-rounded) * 2), 0.4em);
172
175
  }
173
176
 
@@ -175,7 +178,7 @@ Pop.styles = [
175
178
  transform: translateY(0) scale(1);
176
179
  opacity: 1;
177
180
  pointer-events: auto;
178
- transition-property:scale, opacity;
181
+ transition-property: scale, opacity;
179
182
  transition-timing-function: cubic-bezier(0.25, 0.25, 0.42, 1.225);
180
183
  }
181
184
 
@@ -215,6 +218,9 @@ __decorate([
215
218
  __decorate([
216
219
  property({ type: String })
217
220
  ], Pop.prototype, "toggle", void 0);
221
+ __decorate([
222
+ property({ type: Boolean })
223
+ ], Pop.prototype, "noToggle", void 0);
218
224
  __decorate([
219
225
  property({ type: Boolean, reflect: true })
220
226
  ], Pop.prototype, "inline", void 0);
@@ -228,8 +234,3 @@ Pop = Pop_1 = __decorate([
228
234
  customElement(tagName)
229
235
  ], Pop);
230
236
  export { Pop };
231
- //Ajout pour la creation du cem notamment pour Storybook
232
- try {
233
- customElements.define(tagName, Pop);
234
- }
235
- catch (e) { }
File without changes
@@ -21,8 +21,8 @@ let Progress = class Progress extends LitElement {
21
21
  return html `
22
22
  <progress value=${ifDefined(this.value)} max=${this.max}></progress>
23
23
  <div class="slot-container">
24
- <slot></slot>
25
- <slot name="remaining"></slot>
24
+ <slot></slot>
25
+ <slot name="remaining"></slot>
26
26
  </div>
27
27
  `;
28
28
  }
@@ -33,15 +33,14 @@ Progress.styles = [
33
33
  :host {
34
34
  --sc-progress-bg: var(--sc-input-bg, var(--sc-base-100, #f5f5f5));
35
35
  --sc-progress-color: var(--sc-base-content, #1f2937);
36
- --sc-progress-height: .6em;
36
+ --sc-progress-height: 0.6em;
37
37
  --sc-progress-fs: var(--sc-fs, 1rem);
38
38
  --sc-progress-fw: 500;
39
39
  --sc-progress-rounded: var(--sc-rounded-lg);
40
40
  display: block;
41
41
  line-height: 1.2;
42
- font-weight:var(--sc-progress-fw);
43
- font-size:var(--sc-progress-fs);
44
- color:var(--sc-progress-color);
42
+ font-weight: var(--sc-progress-fw);
43
+ font-size: var(--sc-progress-fs);
45
44
  }
46
45
 
47
46
  progress {
@@ -50,7 +49,7 @@ Progress.styles = [
50
49
  -webkit-appearance: none;
51
50
  appearance: none;
52
51
  overflow: hidden;
53
- border:none;
52
+ border: none;
54
53
  height: var(--sc-progress-height);
55
54
  border-radius: var(--sc-progress-rounded);
56
55
  background-color: var(--sc-progress-bg);
@@ -61,7 +60,7 @@ Progress.styles = [
61
60
  border-radius: var(--sc-progress-rounded);
62
61
  }
63
62
 
64
- progress:not([value])::-moz-progress-bar {
63
+ progress:not([value])::-moz-progress-bar {
65
64
  background-color: var(--sc-progress-bg);
66
65
  }
67
66
 
@@ -75,15 +74,15 @@ Progress.styles = [
75
74
 
76
75
  /* Indeterminate */
77
76
  progress:indeterminate:after {
78
- background-color: var(--sc-progress-color);
79
- content: "";
80
- position: absolute;
81
- top: 0;
82
- bottom: 0;
83
- left: -40%;
84
- width: 33.333333%;
85
- border-radius: var(--sc-progress-rounded);
86
- animation: progress-loading 3s infinite ease-in-out;
77
+ background-color: var(--sc-progress-color);
78
+ content: "";
79
+ position: absolute;
80
+ top: 0;
81
+ bottom: 0;
82
+ left: -40%;
83
+ width: 33.333333%;
84
+ border-radius: var(--sc-progress-rounded);
85
+ animation: progress-loading 3s infinite ease-in-out;
87
86
  }
88
87
 
89
88
  @keyframes progress-loading {
@@ -91,7 +90,7 @@ Progress.styles = [
91
90
  left: 107%;
92
91
  }
93
92
  }
94
-
93
+
95
94
  /* COLOR TYPES */
96
95
  :host([type="warning"]) {
97
96
  --sc-progress-color: var(--sc-warning);
@@ -107,26 +106,33 @@ Progress.styles = [
107
106
  }
108
107
 
109
108
  :host([invert]) {
110
- --sc-progress-bg: var(--sc-base-700);
109
+ --sc-progress-bg: rgba(200, 200, 200, 0.1);
111
110
  }
111
+
112
112
  :host([type="default"][invert]) {
113
113
  --sc-progress-color: var(--sc-base);
114
114
  }
115
115
 
116
116
  slot[name="remaining"] {
117
- font-weight:var(--sc-font-weight-base);
118
- color:var(--sc-base-400);
119
- font-size:.85em;
120
- margin-top:.5em;
117
+ font-weight: var(--sc-font-weight-base);
118
+ font-size: 0.85em;
119
+ margin-top: 0.5em;
120
+ }
121
+ slot[name="remaining"]::slotted(*) {
122
+ margin-left: auto;
121
123
  }
122
-
124
+
125
+ slot:not([name]) {
126
+ color: var(--sc-progress-color);
127
+ }
128
+
123
129
  .slot-container {
124
- display:flex;
130
+ display: flex;
125
131
  justify-content: space-between;
126
- gap:.5em;
127
- margin-top:.15em;
132
+ gap: 0.5em;
133
+ margin-top: 0.15em;
128
134
  }
129
- `
135
+ `,
130
136
  ];
131
137
  __decorate([
132
138
  property({ type: Number })
@@ -147,7 +153,3 @@ Progress = __decorate([
147
153
  customElement(tagName)
148
154
  ], Progress);
149
155
  export { Progress };
150
- try {
151
- customElements.define(tagName, Progress);
152
- }
153
- catch (e) { }
File without changes
@@ -15,19 +15,14 @@ let TableCaption = class TableCaption extends LitElement {
15
15
  TableCaption.styles = [
16
16
  css `
17
17
  :host {
18
- display:table-caption;
19
- font-size:.75rem;
20
- color:var(--sc-table-caption-color);
21
- padding: var(--sc-table-td-py) var(--sc-table-td-px) calc(2 * var(--sc-table-td-py) );
18
+ display: table-caption;
19
+ font-size: 0.75rem;
20
+ color: var(--sc-table-caption-color);
21
+ padding: var(--sc-table-td-py) var(--sc-table-td-px) calc(2 * var(--sc-table-td-py));
22
22
  }
23
- `
23
+ `,
24
24
  ];
25
25
  TableCaption = __decorate([
26
26
  customElement(tagName)
27
27
  ], TableCaption);
28
28
  export { TableCaption };
29
- //Ajout pour la creation du cem notamment pour Storybook
30
- try {
31
- customElements.define(tagName, TableCaption);
32
- }
33
- catch (e) { }
File without changes
@@ -9,7 +9,9 @@ import { customElement } from "lit/decorators.js";
9
9
  const tagName = "sonic-tbody";
10
10
  let TableTbody = class TableTbody extends LitElement {
11
11
  render() {
12
- return html `<tbody><slot></slot></tbody>`;
12
+ return html `<tbody>
13
+ <slot></slot>
14
+ </tbody>`;
13
15
  }
14
16
  };
15
17
  TableTbody.styles = [
@@ -18,26 +20,20 @@ TableTbody.styles = [
18
20
  display: table-row-group;
19
21
  }
20
22
 
21
- ::slotted(sonic-tr:nth-child(odd)){
22
- background:var(--sc-base-50);
23
+ ::slotted(sonic-tr:nth-child(odd)) {
24
+ background: var(--sc-table-accent-bg);
23
25
  }
24
-
26
+
25
27
  ::slotted(sonic-tr:hover) {
26
- background:var(--sc-base-100);
28
+ background: var(--sc-table-hover-bg);
27
29
  }
28
30
 
29
- ::slotted(sonic-tr:not(:last-child)){
30
- border-bottom:var(--sc-form-border-width) solid var(--sc-base-200) !important;
31
+ ::slotted(sonic-tr:not(:last-child)) {
32
+ border-bottom: var(--sc-form-border-width) solid var(--sc-base-200) !important;
31
33
  }
32
-
33
- `
34
+ `,
34
35
  ];
35
36
  TableTbody = __decorate([
36
37
  customElement(tagName)
37
38
  ], TableTbody);
38
39
  export { TableTbody };
39
- //Ajout pour la creation du cem notamment pour Storybook
40
- try {
41
- customElements.define(tagName, TableTbody);
42
- }
43
- catch (e) { }
@@ -6,5 +6,7 @@ export declare class TableTd extends LitElement {
6
6
  align?: string;
7
7
  vAlign?: string;
8
8
  minWidth?: string;
9
+ maxWidth?: string;
10
+ width?: string;
9
11
  render(): import("lit-html").TemplateResult<1>;
10
12
  }
@@ -16,6 +16,8 @@ let TableTd = class TableTd extends LitElement {
16
16
  textAlign: this.align,
17
17
  verticalAlign: this.vAlign,
18
18
  minWidth: this.minWidth,
19
+ maxWidth: this.maxWidth,
20
+ width: this.width,
19
21
  };
20
22
  return html `<td
21
23
  part="td"
@@ -55,12 +57,13 @@ __decorate([
55
57
  __decorate([
56
58
  property({ type: String })
57
59
  ], TableTd.prototype, "minWidth", void 0);
60
+ __decorate([
61
+ property({ type: String })
62
+ ], TableTd.prototype, "maxWidth", void 0);
63
+ __decorate([
64
+ property({ type: String })
65
+ ], TableTd.prototype, "width", void 0);
58
66
  TableTd = __decorate([
59
67
  customElement(tagName)
60
68
  ], TableTd);
61
69
  export { TableTd };
62
- //Ajout pour la creation du cem notamment pour Storybook
63
- try {
64
- customElements.define(tagName, TableTd);
65
- }
66
- catch (e) { }
File without changes