@supersoniks/concorde 1.1.31 → 1.1.35

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 (202) 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 +0 -0
  5. package/concorde-core.bundle.js +102 -115
  6. package/concorde-core.es.js +7589 -55
  7. package/core/components/functional/configuration/configuration.d.ts +0 -0
  8. package/core/components/functional/configuration/configuration.js +0 -0
  9. package/core/components/functional/date/date.d.ts +0 -0
  10. package/core/components/functional/date/date.js +0 -0
  11. package/core/components/functional/example/example.d.ts +0 -0
  12. package/core/components/functional/example/example.js +0 -0
  13. package/core/components/functional/fetch/fetch.d.ts +0 -0
  14. package/core/components/functional/fetch/fetch.js +0 -0
  15. package/core/components/functional/functional.d.ts +0 -0
  16. package/core/components/functional/functional.js +0 -0
  17. package/core/components/functional/if/if.d.ts +0 -0
  18. package/core/components/functional/if/if.js +0 -0
  19. package/core/components/functional/list/list.d.ts +0 -0
  20. package/core/components/functional/list/list.js +0 -0
  21. package/core/components/functional/queue/queue.d.ts +4 -1
  22. package/core/components/functional/queue/queue.js +16 -3
  23. package/core/components/functional/router/redirect.d.ts +0 -0
  24. package/core/components/functional/router/redirect.js +0 -0
  25. package/core/components/functional/router/router.d.ts +0 -0
  26. package/core/components/functional/router/router.js +0 -0
  27. package/core/components/functional/sonic-scope/sonic-scope.d.ts +0 -0
  28. package/core/components/functional/sonic-scope/sonic-scope.js +0 -0
  29. package/core/components/functional/states/states.d.ts +0 -0
  30. package/core/components/functional/states/states.js +0 -0
  31. package/core/components/functional/submit/submit.d.ts +0 -0
  32. package/core/components/functional/submit/submit.js +35 -21
  33. package/core/components/functional/subscriber/subscriber.d.ts +0 -0
  34. package/core/components/functional/subscriber/subscriber.js +0 -0
  35. package/core/components/ui/_css/scroll.d.ts +0 -0
  36. package/core/components/ui/_css/scroll.js +0 -0
  37. package/core/components/ui/_css/size.d.ts +0 -0
  38. package/core/components/ui/_css/size.js +0 -0
  39. package/core/components/ui/_css/type.d.ts +0 -0
  40. package/core/components/ui/_css/type.js +0 -0
  41. package/core/components/ui/alert/alert.d.ts +0 -0
  42. package/core/components/ui/alert/alert.js +0 -0
  43. package/core/components/ui/badge/badge.d.ts +0 -0
  44. package/core/components/ui/badge/badge.js +0 -0
  45. package/core/components/ui/button/button.d.ts +3 -2
  46. package/core/components/ui/button/button.js +0 -0
  47. package/core/components/ui/captcha/captcha.d.ts +1 -0
  48. package/core/components/ui/captcha/captcha.js +14 -2
  49. package/core/components/ui/card/card-footer.d.ts +0 -0
  50. package/core/components/ui/card/card-footer.js +0 -0
  51. package/core/components/ui/card/card-header-descripton.d.ts +0 -0
  52. package/core/components/ui/card/card-header-descripton.js +0 -0
  53. package/core/components/ui/card/card-header.d.ts +0 -0
  54. package/core/components/ui/card/card-header.js +0 -0
  55. package/core/components/ui/card/card-main.d.ts +0 -0
  56. package/core/components/ui/card/card-main.js +0 -0
  57. package/core/components/ui/card/card.d.ts +0 -0
  58. package/core/components/ui/card/card.js +0 -0
  59. package/core/components/ui/divider/divider.d.ts +0 -0
  60. package/core/components/ui/divider/divider.js +0 -0
  61. package/core/components/ui/form/checkbox/checkbox.d.ts +11 -44
  62. package/core/components/ui/form/checkbox/checkbox.js +28 -35
  63. package/core/components/ui/form/css/form-control.d.ts +0 -0
  64. package/core/components/ui/form/css/form-control.js +0 -0
  65. package/core/components/ui/form/fieldset/fieldset.d.ts +0 -0
  66. package/core/components/ui/form/fieldset/fieldset.js +0 -0
  67. package/core/components/ui/form/fieldset/legend-description.d.ts +0 -0
  68. package/core/components/ui/form/fieldset/legend-description.js +0 -0
  69. package/core/components/ui/form/fieldset/legend.d.ts +7 -2
  70. package/core/components/ui/form/fieldset/legend.js +34 -8
  71. package/core/components/ui/form/form-actions/form-actions.d.ts +0 -0
  72. package/core/components/ui/form/form-actions/form-actions.js +0 -0
  73. package/core/components/ui/form/form-layout/form-layout.d.ts +0 -0
  74. package/core/components/ui/form/form-layout/form-layout.js +0 -0
  75. package/core/components/ui/form/input/input.d.ts +6 -2
  76. package/core/components/ui/form/input/input.js +4 -13
  77. package/core/components/ui/form/radio/radio.d.ts +0 -0
  78. package/core/components/ui/form/radio/radio.js +0 -0
  79. package/core/components/ui/form/select/select.d.ts +7 -2
  80. package/core/components/ui/form/select/select.js +32 -7
  81. package/core/components/ui/form/textarea/textarea.d.ts +6 -2
  82. package/core/components/ui/form/textarea/textarea.js +2 -7
  83. package/core/components/ui/group/group.d.ts +0 -0
  84. package/core/components/ui/group/group.js +0 -0
  85. package/core/components/ui/icon/icon.d.ts +0 -0
  86. package/core/components/ui/icon/icon.js +0 -0
  87. package/core/components/ui/icon/icons.d.ts +0 -0
  88. package/core/components/ui/icon/icons.js +0 -0
  89. package/core/components/ui/icon/icons.json +0 -0
  90. package/core/components/ui/image/image.d.ts +0 -0
  91. package/core/components/ui/image/image.js +0 -0
  92. package/core/components/ui/link/link.d.ts +0 -0
  93. package/core/components/ui/link/link.js +0 -0
  94. package/core/components/ui/loader/loader.d.ts +0 -0
  95. package/core/components/ui/loader/loader.js +0 -0
  96. package/core/components/ui/loader/styles/fixed.d.ts +0 -0
  97. package/core/components/ui/loader/styles/fixed.js +0 -0
  98. package/core/components/ui/loader/styles/inline.d.ts +0 -0
  99. package/core/components/ui/loader/styles/inline.js +0 -0
  100. package/core/components/ui/menu/menu-item.d.ts +0 -0
  101. package/core/components/ui/menu/menu-item.js +0 -0
  102. package/core/components/ui/menu/menu.d.ts +0 -0
  103. package/core/components/ui/menu/menu.js +0 -0
  104. package/core/components/ui/modal/modal-actions.d.ts +0 -0
  105. package/core/components/ui/modal/modal-actions.js +0 -0
  106. package/core/components/ui/modal/modal-close.d.ts +0 -0
  107. package/core/components/ui/modal/modal-close.js +0 -0
  108. package/core/components/ui/modal/modal-content.d.ts +0 -0
  109. package/core/components/ui/modal/modal-content.js +0 -0
  110. package/core/components/ui/modal/modal-subtitle.d.ts +0 -0
  111. package/core/components/ui/modal/modal-subtitle.js +0 -0
  112. package/core/components/ui/modal/modal-title.d.ts +0 -0
  113. package/core/components/ui/modal/modal-title.js +0 -0
  114. package/core/components/ui/modal/modal.d.ts +0 -0
  115. package/core/components/ui/modal/modal.js +0 -0
  116. package/core/components/ui/pop/pop.d.ts +0 -0
  117. package/core/components/ui/pop/pop.js +0 -0
  118. package/core/components/ui/progress/progress.d.ts +0 -0
  119. package/core/components/ui/progress/progress.js +0 -0
  120. package/core/components/ui/table/table-caption.d.ts +0 -0
  121. package/core/components/ui/table/table-caption.js +0 -0
  122. package/core/components/ui/table/table-tbody.d.ts +0 -0
  123. package/core/components/ui/table/table-tbody.js +0 -0
  124. package/core/components/ui/table/table-td.d.ts +0 -0
  125. package/core/components/ui/table/table-td.js +0 -0
  126. package/core/components/ui/table/table-tfoot.d.ts +0 -0
  127. package/core/components/ui/table/table-tfoot.js +0 -0
  128. package/core/components/ui/table/table-th.d.ts +0 -0
  129. package/core/components/ui/table/table-th.js +0 -0
  130. package/core/components/ui/table/table-thead.d.ts +0 -0
  131. package/core/components/ui/table/table-thead.js +0 -0
  132. package/core/components/ui/table/table-tr.d.ts +0 -0
  133. package/core/components/ui/table/table-tr.js +0 -0
  134. package/core/components/ui/table/table.d.ts +0 -0
  135. package/core/components/ui/table/table.js +0 -0
  136. package/core/components/ui/tabs/tab.d.ts +0 -0
  137. package/core/components/ui/tabs/tab.js +0 -0
  138. package/core/components/ui/tabs/tabs.d.ts +0 -0
  139. package/core/components/ui/tabs/tabs.js +0 -0
  140. package/core/components/ui/taxonomy/taxonomy.d.ts +0 -0
  141. package/core/components/ui/taxonomy/taxonomy.js +0 -0
  142. package/core/components/ui/theme/css/tailwind.css +0 -0
  143. package/core/components/ui/theme/css/tailwind.d.ts +0 -0
  144. package/core/components/ui/theme/theme-collection/core-variables.d.ts +0 -0
  145. package/core/components/ui/theme/theme-collection/core-variables.js +0 -0
  146. package/core/components/ui/theme/theme-collection/dark.d.ts +0 -0
  147. package/core/components/ui/theme/theme-collection/dark.js +0 -0
  148. package/core/components/ui/theme/theme-collection/light.d.ts +0 -0
  149. package/core/components/ui/theme/theme-collection/light.js +0 -0
  150. package/core/components/ui/theme/theme.d.ts +0 -0
  151. package/core/components/ui/theme/theme.js +0 -0
  152. package/core/components/ui/toast/message-subscriber.d.ts +0 -0
  153. package/core/components/ui/toast/message-subscriber.js +0 -0
  154. package/core/components/ui/toast/toast-item.d.ts +0 -0
  155. package/core/components/ui/toast/toast-item.js +0 -0
  156. package/core/components/ui/toast/toast.d.ts +0 -0
  157. package/core/components/ui/toast/toast.js +0 -0
  158. package/core/components/ui/toast/types.d.ts +0 -0
  159. package/core/components/ui/toast/types.js +0 -0
  160. package/core/components/ui/tooltip/tooltip.d.ts +0 -0
  161. package/core/components/ui/tooltip/tooltip.js +0 -0
  162. package/core/components/ui/ui.d.ts +0 -0
  163. package/core/components/ui/ui.js +0 -0
  164. package/core/core.d.ts +0 -0
  165. package/core/core.js +0 -0
  166. package/core/mixins/Fetcher.d.ts +0 -0
  167. package/core/mixins/Fetcher.js +0 -0
  168. package/core/mixins/FormCheckable.d.ts +3 -5
  169. package/core/mixins/FormCheckable.js +4 -15
  170. package/core/mixins/FormElement.d.ts +0 -0
  171. package/core/mixins/FormElement.js +7 -0
  172. package/core/mixins/FormInput.d.ts +8 -5
  173. package/core/mixins/FormInput.js +39 -2
  174. package/core/mixins/Subscriber.d.ts +0 -0
  175. package/core/mixins/Subscriber.js +4 -0
  176. package/core/mixins/TemplatesContainer.d.ts +0 -0
  177. package/core/mixins/TemplatesContainer.js +0 -0
  178. package/core/mixins/mixins.d.ts +0 -0
  179. package/core/mixins/mixins.js +0 -0
  180. package/core/utils/Arrays.d.ts +0 -0
  181. package/core/utils/Arrays.js +0 -0
  182. package/core/utils/DataBindObserver.d.ts +0 -0
  183. package/core/utils/DataBindObserver.js +0 -0
  184. package/core/utils/Electron.d.ts +0 -0
  185. package/core/utils/Electron.js +0 -0
  186. package/core/utils/Format.d.ts +0 -0
  187. package/core/utils/Format.js +0 -0
  188. package/core/utils/HTML.d.ts +0 -0
  189. package/core/utils/HTML.js +0 -0
  190. package/core/utils/LocationHandler.d.ts +0 -0
  191. package/core/utils/LocationHandler.js +0 -0
  192. package/core/utils/Objects.d.ts +0 -0
  193. package/core/utils/Objects.js +0 -0
  194. package/core/utils/PublisherProxy.d.mts +0 -0
  195. package/core/utils/PublisherProxy.mjs +0 -0
  196. package/core/utils/api.d.ts +4 -0
  197. package/core/utils/api.js +25 -1
  198. package/mixins.d.ts +9 -2
  199. package/mixins.js +0 -0
  200. package/package.json +1 -1
  201. package/utils.d.ts +0 -0
  202. package/utils.js +0 -0
@@ -10,14 +10,37 @@ import "@supersoniks/concorde/core/components/ui/form/fieldset/legend-descriptio
10
10
  import { ifDefined } from "lit/directives/if-defined.js";
11
11
  const tagName = "sonic-legend";
12
12
  let Legend = class Legend extends LitElement {
13
+ constructor() {
14
+ super(...arguments);
15
+ this.forceAutoFill = false;
16
+ }
17
+ get description() {
18
+ return this._description;
19
+ }
20
+ set description(value) {
21
+ if (this.hasAttribute("description") && !this.forceAutoFill)
22
+ value = this.getAttribute("description");
23
+ this._description = value;
24
+ this.requestUpdate();
25
+ }
26
+ get label() {
27
+ return this._label;
28
+ }
29
+ set label(value) {
30
+ if (this.hasAttribute("label") && !this.forceAutoFill)
31
+ value = this.getAttribute("label");
32
+ this._label = value;
33
+ this.requestUpdate();
34
+ }
13
35
  render() {
14
36
  return html `<legend part="legend">
15
37
  ${this.iconName
16
38
  ? html `<div class="icon">
17
- <sonic-icon
18
- name=${this.iconName}
19
- prefix=${ifDefined(this.iconPrefix)}
20
- library=${ifDefined(this.iconLibrary)}></sonic-icon>
39
+ <sonic-icon
40
+ name=${this.iconName}
41
+ prefix=${ifDefined(this.iconPrefix)}
42
+ library=${ifDefined(this.iconLibrary)}
43
+ ></sonic-icon>
21
44
  </div>`
22
45
  : ""}
23
46
 
@@ -67,11 +90,14 @@ Legend.styles = [
67
90
  `,
68
91
  ];
69
92
  __decorate([
70
- property({ type: String })
71
- ], Legend.prototype, "description", void 0);
93
+ property({ type: Boolean })
94
+ ], Legend.prototype, "forceAutoFill", void 0);
72
95
  __decorate([
73
- property({ type: String })
74
- ], Legend.prototype, "label", void 0);
96
+ property()
97
+ ], Legend.prototype, "description", null);
98
+ __decorate([
99
+ property()
100
+ ], Legend.prototype, "label", null);
75
101
  __decorate([
76
102
  property({ type: String })
77
103
  ], Legend.prototype, "iconName", void 0);
@@ -2,7 +2,13 @@ import { LitElement } from "lit";
2
2
  declare const Input_base: {
3
3
  new (...args: any[]): {
4
4
  validateFormElement(): void;
5
+ forceAutoFill: boolean;
6
+ _type: "number" | "search" | "file" | "button" | "password" | "url" | "color" | "hidden" | "time" | "image" | "text" | "reset" | "submit" | "month" | "week" | "checkbox" | "radio" | "range" | "tel" | "email" | "date" | "datetime-local";
5
7
  type: "number" | "search" | "file" | "button" | "password" | "url" | "color" | "hidden" | "time" | "image" | "text" | "reset" | "submit" | "month" | "week" | "checkbox" | "radio" | "range" | "tel" | "email" | "date" | "datetime-local";
8
+ _description?: string | undefined;
9
+ description: string | undefined;
10
+ _label?: string | undefined;
11
+ label: string | undefined;
6
12
  tabindex?: number | undefined;
7
13
  autocomplete?: "url" | "name" | "language" | "on" | "tel" | "email" | "honorific-prefix" | "given-name" | "additional-name" | "family-name" | "honorific-suffix" | "nickname" | "username" | "new-password" | "current-password" | "one-time-code" | "organization-title" | "organization" | "street-address" | "address-line1" | "address-line2" | "address-line3" | "address-level4" | "address-level3" | "address-level2" | "address-level1" | "country" | "country-name" | "postal-code" | "cc-name" | "cc-given-name" | "cc-additional-name" | "cc-family-name" | "cc-number" | "cc-exp" | "cc-exp-month" | "cc-exp-year" | "cc-csc" | "cc-type" | "transaction-currency" | "transaction-amount" | "bday" | "bday-day" | "bday-month" | "bday-year" | "sex" | "tel-country-code" | "tel-national" | "tel-area-code" | "tel-local" | "tel-extension" | "impp" | "photo" | undefined;
8
14
  getFormPublisher(): any;
@@ -59,8 +65,6 @@ export declare class Input extends Input_base {
59
65
  minlength?: number;
60
66
  maxlength?: number;
61
67
  src?: string;
62
- label?: string;
63
- description?: string;
64
68
  inlineContent: boolean;
65
69
  slotLabelNodes: Array<Node>;
66
70
  slotDescriptionNodes: Array<Node>;
@@ -6,7 +6,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
6
6
  };
7
7
  import { html, LitElement } from "lit";
8
8
  import { customElement, property, queryAssignedNodes, state } from "lit/decorators.js";
9
- import { query } from 'lit/decorators/query.js';
9
+ import { query } from "lit/decorators/query.js";
10
10
  import { ifDefined } from "lit/directives/if-defined.js";
11
11
  import { formControl } from "@supersoniks/concorde/core/components/ui/form/css/form-control";
12
12
  import Subscriber from "@supersoniks/concorde/core/mixins/Subscriber";
@@ -49,7 +49,7 @@ let Input = class Input extends FormInput(FormElement(Subscriber(LitElement))) {
49
49
  var _a;
50
50
  if (!this.inlineContent)
51
51
  return;
52
- console.log('oypouaze');
52
+ console.log("oypouaze");
53
53
  (_a = this.input) === null || _a === void 0 ? void 0 : _a.focus();
54
54
  }
55
55
  render() {
@@ -99,10 +99,7 @@ let Input = class Input extends FormInput(FormElement(Subscriber(LitElement))) {
99
99
  `;
100
100
  }
101
101
  };
102
- Input.styles = [
103
- fontSize,
104
- formControl
105
- ];
102
+ Input.styles = [fontSize, formControl];
106
103
  __decorate([
107
104
  property({ type: String, reflect: true })
108
105
  ], Input.prototype, "size", void 0);
@@ -136,12 +133,6 @@ __decorate([
136
133
  __decorate([
137
134
  property({ type: String })
138
135
  ], Input.prototype, "src", void 0);
139
- __decorate([
140
- property({ type: String })
141
- ], Input.prototype, "label", void 0);
142
- __decorate([
143
- property({ type: String })
144
- ], Input.prototype, "description", void 0);
145
136
  __decorate([
146
137
  property({ type: Boolean, reflect: true })
147
138
  ], Input.prototype, "inlineContent", void 0);
@@ -158,7 +149,7 @@ __decorate([
158
149
  queryAssignedNodes({ slot: "prefix" })
159
150
  ], Input.prototype, "slotPrefixNodes", void 0);
160
151
  __decorate([
161
- query('input')
152
+ query("input")
162
153
  ], Input.prototype, "input", void 0);
163
154
  __decorate([
164
155
  state()
File without changes
File without changes
@@ -15,8 +15,13 @@ export declare class Select extends Select_base {
15
15
  get value(): string;
16
16
  set value(value: string);
17
17
  connectedCallback(): void;
18
- label?: string;
19
- description?: string;
18
+ forceAutoFill: boolean;
19
+ _description?: string;
20
+ get description(): string | undefined;
21
+ set description(value: string | undefined);
22
+ _label?: string;
23
+ get label(): string | undefined;
24
+ set label(value: string | undefined);
20
25
  slotLabelNodes: Array<Node>;
21
26
  slotDescriptionNodes: Array<Node>;
22
27
  slotSuffixNodes: Array<Node>;
@@ -30,6 +30,11 @@ let Select = class Select extends FormElement(Subscriber(LitElement)) {
30
30
  this.multiple = false;
31
31
  this._options = [];
32
32
  this._value = "";
33
+ /*
34
+ * TODO
35
+ * Mutualiser avec le composant textarea / input
36
+ */
37
+ this.forceAutoFill = false;
33
38
  this.hasDescription = false;
34
39
  this.hasLabel = false;
35
40
  this.hasSuffix = false;
@@ -75,6 +80,24 @@ let Select = class Select extends FormElement(Subscriber(LitElement)) {
75
80
  });
76
81
  }
77
82
  }
83
+ get description() {
84
+ return this._description;
85
+ }
86
+ set description(value) {
87
+ if (this.hasAttribute("description") && !this.forceAutoFill)
88
+ value = this.getAttribute("description");
89
+ this._description = value;
90
+ this.requestUpdate();
91
+ }
92
+ get label() {
93
+ return this._label;
94
+ }
95
+ set label(value) {
96
+ if (this.hasAttribute("label") && !this.forceAutoFill)
97
+ value = this.getAttribute("label");
98
+ this._label = value;
99
+ this.requestUpdate();
100
+ }
78
101
  updated() {
79
102
  var _a, _b, _c, _d;
80
103
  this.hasLabel = this.label || ((_a = this.slotLabelNodes) === null || _a === void 0 ? void 0 : _a.length) ? true : false;
@@ -126,7 +149,7 @@ let Select = class Select extends FormElement(Subscriber(LitElement)) {
126
149
  })}
127
150
  <slot></slot>
128
151
  </select>
129
- <sonic-icon class="select-chevron" name="nav-arrow-down" size="${this.size}"></sonic-icon>
152
+ <sonic-icon class="select-chevron" name="nav-arrow-down" size="${this.size}"></sonic-icon>
130
153
  </div>
131
154
  <slot name="suffix" @slotchange=${this.onSlotChange}></slot>
132
155
  </div>
@@ -155,7 +178,7 @@ Select.styles = [
155
178
  top: 50%;
156
179
  pointer-events: none;
157
180
  transform: translateY(-50%);
158
- color:var(--sc-input-color);
181
+ color: var(--sc-input-color);
159
182
  }
160
183
 
161
184
  option {
@@ -163,7 +186,6 @@ Select.styles = [
163
186
  color: var(--sc-base-content);
164
187
  background: var(--sc-base);
165
188
  }
166
-
167
189
  `,
168
190
  ];
169
191
  __decorate([
@@ -188,11 +210,14 @@ __decorate([
188
210
  property()
189
211
  ], Select.prototype, "value", null);
190
212
  __decorate([
191
- property({ type: String })
192
- ], Select.prototype, "label", void 0);
213
+ property({ type: Boolean })
214
+ ], Select.prototype, "forceAutoFill", void 0);
193
215
  __decorate([
194
- property({ type: String })
195
- ], Select.prototype, "description", void 0);
216
+ property()
217
+ ], Select.prototype, "description", null);
218
+ __decorate([
219
+ property()
220
+ ], Select.prototype, "label", null);
196
221
  __decorate([
197
222
  queryAssignedNodes({ slot: "label" })
198
223
  ], Select.prototype, "slotLabelNodes", void 0);
@@ -2,7 +2,13 @@ import { LitElement } from "lit";
2
2
  declare const Textarea_base: {
3
3
  new (...args: any[]): {
4
4
  validateFormElement(): void;
5
+ forceAutoFill: boolean;
6
+ _type: "number" | "search" | "file" | "button" | "password" | "url" | "color" | "hidden" | "time" | "image" | "text" | "reset" | "submit" | "month" | "week" | "checkbox" | "radio" | "range" | "tel" | "email" | "date" | "datetime-local";
5
7
  type: "number" | "search" | "file" | "button" | "password" | "url" | "color" | "hidden" | "time" | "image" | "text" | "reset" | "submit" | "month" | "week" | "checkbox" | "radio" | "range" | "tel" | "email" | "date" | "datetime-local";
8
+ _description?: string | undefined;
9
+ description: string | undefined;
10
+ _label?: string | undefined;
11
+ label: string | undefined;
6
12
  tabindex?: number | undefined;
7
13
  autocomplete?: "url" | "name" | "language" | "on" | "tel" | "email" | "honorific-prefix" | "given-name" | "additional-name" | "family-name" | "honorific-suffix" | "nickname" | "username" | "new-password" | "current-password" | "one-time-code" | "organization-title" | "organization" | "street-address" | "address-line1" | "address-line2" | "address-line3" | "address-level4" | "address-level3" | "address-level2" | "address-level1" | "country" | "country-name" | "postal-code" | "cc-name" | "cc-given-name" | "cc-additional-name" | "cc-family-name" | "cc-number" | "cc-exp" | "cc-exp-month" | "cc-exp-year" | "cc-csc" | "cc-type" | "transaction-currency" | "transaction-amount" | "bday" | "bday-day" | "bday-month" | "bday-year" | "sex" | "tel-country-code" | "tel-national" | "tel-area-code" | "tel-local" | "tel-extension" | "impp" | "photo" | undefined;
8
14
  getFormPublisher(): any;
@@ -53,8 +59,6 @@ export declare class Textarea extends Textarea_base {
53
59
  wrap?: "hard" | "soft";
54
60
  readonly: boolean;
55
61
  placeholder?: string;
56
- label?: string;
57
- description?: string;
58
62
  slotLabelNodes: Array<Node>;
59
63
  slotDescriptionNodes: Array<Node>;
60
64
  slotSuffixNodes: Array<Node>;
@@ -70,7 +70,8 @@ let Textarea = class Textarea extends FormInput(FormElement(Subscriber(LitElemen
70
70
  wrap=${ifDefined(this.wrap)}
71
71
  placeholder="${this.placeholder}"
72
72
  class="form-element textarea custom-scroll"
73
- >${this.value}</textarea
73
+ >
74
+ ${this.value}</textarea
74
75
  >
75
76
  </div>
76
77
 
@@ -113,12 +114,6 @@ __decorate([
113
114
  __decorate([
114
115
  property({ type: String })
115
116
  ], Textarea.prototype, "placeholder", void 0);
116
- __decorate([
117
- property({ type: String })
118
- ], Textarea.prototype, "label", void 0);
119
- __decorate([
120
- property({ type: String })
121
- ], Textarea.prototype, "description", void 0);
122
117
  __decorate([
123
118
  queryAssignedNodes({ slot: "label" })
124
119
  ], Textarea.prototype, "slotLabelNodes", void 0);
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
package/core/core.d.ts CHANGED
File without changes
package/core/core.js CHANGED
File without changes
File without changes
File without changes
@@ -7,11 +7,7 @@ declare const Form: <T extends Constructor<FormElementInterface>>(superClass: T)
7
7
  */
8
8
  _value: string | null;
9
9
  value: string | null;
10
- /**
11
- * Voir la mixin FormElement
12
- */
13
- _name: string;
14
- name: string;
10
+ forceAutoFill: boolean;
15
11
  /**
16
12
  * comme radio,mais peut être désélectionné après sélection
17
13
  */
@@ -48,6 +44,8 @@ declare const Form: <T extends Constructor<FormElementInterface>>(superClass: T)
48
44
  required: boolean;
49
45
  disabled: true | null;
50
46
  formDataProvider: string;
47
+ _name: string;
48
+ name: string;
51
49
  props: any;
52
50
  isConnected: boolean;
53
51
  getAncestorAttributeValue(attributeName: string): string;
@@ -21,10 +21,7 @@ const Form = (superClass) => {
21
21
  * Voir la mixin FormElement.
22
22
  */
23
23
  this._value = "";
24
- /**
25
- * Voir la mixin FormElement
26
- */
27
- this._name = "";
24
+ this.forceAutoFill = false;
28
25
  /**
29
26
  * comme radio,mais peut être désélectionné après sélection
30
27
  */
@@ -42,7 +39,7 @@ const Form = (superClass) => {
42
39
  return this._value;
43
40
  }
44
41
  set value(value) {
45
- if (this.hasAttribute("value"))
42
+ if (this.hasAttribute("value") && !this.forceAutoFill)
46
43
  value = this.getAttribute("value");
47
44
  if (this._value == value)
48
45
  return;
@@ -50,14 +47,6 @@ const Form = (superClass) => {
50
47
  this.updateDataValue();
51
48
  this.requestUpdate();
52
49
  }
53
- get name() {
54
- return this._name;
55
- }
56
- set name(value) {
57
- if (this.hasAttribute("name"))
58
- value = this.getAttribute("name");
59
- this._name = value;
60
- }
61
50
  get checked() {
62
51
  return this._checked;
63
52
  }
@@ -71,7 +60,7 @@ const Form = (superClass) => {
71
60
  if (!input || input.checkValidity())
72
61
  return;
73
62
  let value = this.getFormPublisher()[this.name].get();
74
- if ((this.unique || this.radio) && (value !== null && value.toString().length > 0))
63
+ if ((this.unique || this.radio) && value !== null && value.toString().length > 0)
75
64
  return;
76
65
  this.getFormPublisher().isFormValid = false;
77
66
  input.reportValidity();
@@ -144,7 +133,7 @@ const Form = (superClass) => {
144
133
  ], FormCheckable.prototype, "value", null);
145
134
  __decorate([
146
135
  property()
147
- ], FormCheckable.prototype, "name", null);
136
+ ], FormCheckable.prototype, "forceAutoFill", void 0);
148
137
  __decorate([
149
138
  property({ type: Boolean })
150
139
  ], FormCheckable.prototype, "unique", void 0);
File without changes
@@ -24,6 +24,7 @@ const Form = (superClass) => {
24
24
  this.error = false;
25
25
  this.autofocus = false;
26
26
  this.required = false;
27
+ this.forceAutoFill = false;
27
28
  this.disabled = null;
28
29
  this.onValueAssign = null;
29
30
  this.onFormValueAssign = null;
@@ -55,7 +56,10 @@ const Form = (superClass) => {
55
56
  return this._name;
56
57
  }
57
58
  set name(value) {
59
+ if (this.hasAttribute("name") && !this.forceAutoFill)
60
+ value = this.getAttribute("name");
58
61
  this._name = value;
62
+ this.requestUpdate();
59
63
  }
60
64
  validateFormElement() { }
61
65
  updateDataValue() {
@@ -235,6 +239,9 @@ const Form = (superClass) => {
235
239
  __decorate([
236
240
  property({ type: Boolean })
237
241
  ], FormElement.prototype, "required", void 0);
242
+ __decorate([
243
+ property()
244
+ ], FormElement.prototype, "forceAutoFill", void 0);
238
245
  __decorate([
239
246
  property({ type: Boolean })
240
247
  ], FormElement.prototype, "disabled", void 0);