@supersoniks/concorde 1.1.28 → 1.1.30

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 (57) hide show
  1. package/README.md +0 -0
  2. package/cli.js +0 -0
  3. package/concorde-core.bundle.js +21 -22
  4. package/concorde-core.es.js +22 -23
  5. package/core/components/functional/subscriber/subscriber.d.ts +2 -1
  6. package/core/components/functional/subscriber/subscriber.js +8 -0
  7. package/core/components/ui/_css/size.d.ts +1 -0
  8. package/core/components/ui/_css/size.js +26 -0
  9. package/core/components/ui/_css/type.d.ts +2 -0
  10. package/core/components/ui/_css/{types.js → type.js} +1 -1
  11. package/core/components/ui/alert/alert.d.ts +1 -1
  12. package/core/components/ui/alert/alert.js +6 -15
  13. package/core/components/ui/badge/badge.d.ts +1 -1
  14. package/core/components/ui/badge/badge.js +7 -6
  15. package/core/components/ui/button/button.d.ts +11 -6
  16. package/core/components/ui/button/button.js +32 -35
  17. package/core/components/ui/card/card-header.js +1 -1
  18. package/core/components/ui/divider/divider.d.ts +1 -1
  19. package/core/components/ui/divider/divider.js +7 -3
  20. package/core/components/ui/form/checkbox/checkbox.d.ts +11 -9
  21. package/core/components/ui/form/checkbox/checkbox.js +10 -6
  22. package/core/components/ui/form/css/form-control.js +56 -31
  23. package/core/components/ui/form/input/input.d.ts +23 -19
  24. package/core/components/ui/form/input/input.js +35 -33
  25. package/core/components/ui/form/radio/radio.js +1 -2
  26. package/core/components/ui/form/select/select.d.ts +9 -9
  27. package/core/components/ui/form/select/select.js +8 -14
  28. package/core/components/ui/form/textarea/textarea.d.ts +18 -17
  29. package/core/components/ui/form/textarea/textarea.js +12 -23
  30. package/core/components/ui/icon/icon.js +4 -0
  31. package/core/components/ui/image/image.d.ts +0 -1
  32. package/core/components/ui/image/image.js +0 -23
  33. package/core/components/ui/pop/pop.d.ts +1 -0
  34. package/core/components/ui/pop/pop.js +8 -0
  35. package/core/components/ui/progress/progress.d.ts +1 -0
  36. package/core/components/ui/progress/progress.js +13 -20
  37. package/core/components/ui/table/table-td.d.ts +1 -0
  38. package/core/components/ui/table/table-td.js +6 -2
  39. package/core/components/ui/table/table-th.js +2 -2
  40. package/core/components/ui/table/table-tr.js +3 -2
  41. package/core/components/ui/table/table.d.ts +1 -1
  42. package/core/components/ui/table/table.js +3 -20
  43. package/core/components/ui/theme/css/tailwind.css +0 -0
  44. package/core/components/ui/theme/css/tailwind.d.ts +0 -0
  45. package/core/components/ui/theme/theme-collection/core-variables.js +19 -8
  46. package/core/components/ui/theme/theme.d.ts +8 -1
  47. package/core/components/ui/theme/theme.js +42 -1
  48. package/core/components/ui/toast/toast-item.js +1 -1
  49. package/core/mixins/FormCheckable.d.ts +3 -2
  50. package/core/mixins/FormCheckable.js +5 -2
  51. package/core/mixins/FormElement.d.ts +3 -2
  52. package/core/mixins/FormElement.js +8 -4
  53. package/core/mixins/FormInput.d.ts +6 -5
  54. package/core/mixins/FormInput.js +1 -3
  55. package/mixins.d.ts +8 -6
  56. package/package.json +5 -3
  57. package/core/components/ui/_css/types.d.ts +0 -2
@@ -1,19 +1,21 @@
1
1
  import { css } from "lit";
2
2
  export const formControl = css `
3
+
3
4
  * {
4
5
  box-sizing: border-box;
5
6
  }
6
7
 
7
8
  :host {
8
- --sc-input-height: var(--sc-form-height, 2.5em);
9
- --sc-input-border-width: var(--sc-form-border-width, 0.1rem);
10
- --sc-input-color: var(--sc-base-content, #1f2937);
9
+ --sc-input-height: var(--sc-form-height);
10
+ --sc-input-border-width: var(--sc-form-border-width);
11
+ --sc-input-color: var(--sc-base-content);
11
12
 
12
- --sc-item-rounded-tr: var(--sc-input-rounded, var(--sc-rounded));
13
- --sc-item-rounded-tl: var(--sc-input-rounded, var(--sc-rounded));
14
- --sc-item-rounded-bl: var(--sc-input-rounded, var(--sc-rounded));
15
- --sc-item-rounded-br: var(--sc-input-rounded, var(--sc-rounded));
13
+ --sc-item-rounded-tr: var(--sc-input-rounded);
14
+ --sc-item-rounded-tl: var(--sc-input-rounded);
15
+ --sc-item-rounded-bl: var(--sc-input-rounded);
16
+ --sc-item-rounded-br: var(--sc-input-rounded);
16
17
 
18
+ --sc-input-fs: var(--sc-fs, 1rem) ;
17
19
  --sc-input-ff: inherit;
18
20
  --sc-input-py: 0.6em;
19
21
  --sc-input-px: 1.15em;
@@ -25,8 +27,9 @@ export const formControl = css `
25
27
  --sc-input-suffix-color: var(--sc-input-color);
26
28
  --sc-input-suffix-bg: var(--sc-input-bg);
27
29
  --sc-input-suffix-border-color: var(--sc-input-border-color);
28
- --sc-label-fs: var(--sc-input-fs);
29
- --sc-label-fw: normal;
30
+
31
+ --sc-label-fs: var(--sc-fs, 1rem);
32
+ --sc-label-fw: var(--sc-label-font-weight);
30
33
  }
31
34
 
32
35
  .form-element {
@@ -112,7 +115,8 @@ export const formControl = css `
112
115
  display: flex;
113
116
  flex-wrap: wrap;
114
117
  align-items: center;
115
- gap: 0.2em;
118
+ gap: 0.35em;
119
+ min-height: var(--sc-form-height);
116
120
  }
117
121
 
118
122
  /*Disabled */
@@ -120,27 +124,10 @@ export const formControl = css `
120
124
  cursor: not-allowed;
121
125
  }
122
126
 
123
- /*SIZE*/
124
- :host {
125
- --sc-input-fs: 1rem;
126
- }
127
-
128
- :host([size="xs"]) {
129
- --sc-input-fs: 0.75rem;
130
- }
131
- :host([size="sm"]) {
132
- --sc-input-fs: 0.85rem;
133
- }
134
- :host([size="lg"]) {
135
- --sc-input-fs: 1.2rem;
136
- }
137
-
138
127
  :host([variant="ghost"]) .form-element {
139
128
  --sc-input-bg: transparent;
140
129
  }
141
130
 
142
-
143
-
144
131
  /*Disbaled*/
145
132
  :host([disabled]) .form-element {
146
133
  pointer-events: none;
@@ -202,23 +189,61 @@ export const formControl = css `
202
189
  display:none;
203
190
  }
204
191
 
205
- :host([touched]) :not(:focus):invalid {
192
+ :host([touched][required]) :not(:focus):invalid {
206
193
  --sc-input-border-color: var(--sc-danger);
207
194
  --sc-input-color: var(--sc-danger);
208
195
  }
209
196
 
210
- :host([touched]) :not(:focus):invalid + .select-chevron{
197
+ :host([touched][required]) :not(:focus):invalid + .select-chevron{
211
198
  --sc-input-color: var(--sc-danger);
212
199
  }
213
200
 
214
201
  /*VALID*/
215
- :host([touched]) :not([value=""]):not(:focus):valid {
202
+ :host([touched][required]) :not([value=""]):not(:focus):valid {
216
203
  --sc-input-border-color: var(--sc-success);
217
204
  --sc-input-color: var(--sc-success);
218
205
  }
219
206
 
220
- :host([touched]) :not(:focus):valid + .select-chevron{
207
+ :host([touched][required]) :not(:focus):valid + .select-chevron{
221
208
  --sc-input-color: var(--sc-success);
222
209
  }
223
210
 
211
+ /*Input COLOR*/
212
+ :host([type="color"]) .form-element {
213
+ padding: 0;
214
+ border: 0;
215
+ min-width: var(--sc-input-height);
216
+ }
217
+ input[type="color"]::-webkit-color-swatch-wrapper {
218
+ padding: 0;
219
+ }
220
+ input[type="color"]::-webkit-color-swatch {
221
+ border: none;
222
+ border-radius: var(--sc-item-rounded-tl) var(--sc-item-rounded-tr) var(--sc-item-rounded-br)
223
+ var(--sc-item-rounded-bl);
224
+ }
225
+
226
+ /*Input Image*/
227
+ :host([type="image"]) .form-element {
228
+ padding: 0;
229
+ border:none;
230
+ }
231
+
232
+ /*Input reset & image*/
233
+ input[type="reset"],
234
+ input[type="submit"] {
235
+ cursor: pointer;
236
+ }
237
+
238
+ /*Input search*/
239
+ input[type="search"]::-webkit-search-cancel-button {
240
+ appearance:none;
241
+ cursor:pointer;
242
+ height: .65em;
243
+ width: .65em;
244
+ background-image: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iaXNvLTg4NTktMSI/Pg0KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE2LjAuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPg0KPCFET0NUWVBFIHN2ZyBQVUJMSUMgIi0vL1czQy8vRFREIFNWRyAxLjEvL0VOIiAiaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkIj4NCjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iQ2FwYV8xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4PSIwcHgiIHk9IjBweCINCgkgd2lkdGg9IjEyMy4wNXB4IiBoZWlnaHQ9IjEyMy4wNXB4IiB2aWV3Qm94PSIwIDAgMTIzLjA1IDEyMy4wNSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgMTIzLjA1IDEyMy4wNTsiDQoJIHhtbDpzcGFjZT0icHJlc2VydmUiPg0KPGc+DQoJPHBhdGggZD0iTTEyMS4zMjUsMTAuOTI1bC04LjUtOC4zOTljLTIuMy0yLjMtNi4xLTIuMy04LjUsMGwtNDIuNCw0Mi4zOTlMMTguNzI2LDEuNzI2Yy0yLjMwMS0yLjMwMS02LjEwMS0yLjMwMS04LjUsMGwtOC41LDguNQ0KCQljLTIuMzAxLDIuMy0yLjMwMSw2LjEsMCw4LjVsNDMuMSw0My4xbC00Mi4zLDQyLjVjLTIuMywyLjMtMi4zLDYuMSwwLDguNWw4LjUsOC41YzIuMywyLjMsNi4xLDIuMyw4LjUsMGw0Mi4zOTktNDIuNGw0Mi40LDQyLjQNCgkJYzIuMywyLjMsNi4xLDIuMyw4LjUsMGw4LjUtOC41YzIuMy0yLjMsMi4zLTYuMSwwLTguNWwtNDIuNS00Mi40bDQyLjQtNDIuMzk5QzEyMy42MjUsMTcuMTI1LDEyMy42MjUsMTMuMzI1LDEyMS4zMjUsMTAuOTI1eiIvPg0KPC9nPg0KPGc+DQo8L2c+DQo8Zz4NCjwvZz4NCjxnPg0KPC9nPg0KPGc+DQo8L2c+DQo8Zz4NCjwvZz4NCjxnPg0KPC9nPg0KPGc+DQo8L2c+DQo8Zz4NCjwvZz4NCjxnPg0KPC9nPg0KPGc+DQo8L2c+DQo8Zz4NCjwvZz4NCjxnPg0KPC9nPg0KPGc+DQo8L2c+DQo8Zz4NCjwvZz4NCjxnPg0KPC9nPg0KPC9zdmc+DQo=);
245
+ background-size: contain;
246
+ background-repeat: no-repeat;
247
+ }
248
+
224
249
  `;
@@ -3,16 +3,17 @@ declare const Input_base: {
3
3
  new (...args: any[]): {
4
4
  validateFormElement(): void;
5
5
  type: "number" | "search" | "file" | "button" | "password" | "url" | "color" | "hidden" | "time" | "image" | "text" | "reset" | "submit" | "month" | "week" | "checkbox" | "radio" | "range" | "tel" | "email" | "date" | "datetime-local";
6
- tabindex: string | null;
7
- 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" | null;
6
+ tabindex?: number | undefined;
7
+ 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
8
  getFormPublisher(): any;
9
9
  updateDataValue(): void;
10
10
  handleChange(e?: any): void;
11
+ handleBlur(e?: any): void;
11
12
  getValueForFormPublisher(): any;
12
- error: true | null;
13
+ error: boolean;
13
14
  autofocus: boolean;
15
+ required: boolean;
14
16
  disabled: true | null;
15
- required: true | null;
16
17
  formDataProvider: string;
17
18
  _value: any;
18
19
  value: any;
@@ -47,29 +48,32 @@ export declare class Input extends Input_base {
47
48
  /**
48
49
  * Taille du composant, implique notamment des modifications de typo et de marge interne
49
50
  */
50
- size: "" | "xs" | "sm" | "lg";
51
- list: "" | null;
52
- placeholder: string;
51
+ size?: "2xs" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl";
52
+ list?: string;
53
+ placeholder?: string;
54
+ pattern?: string;
55
+ min?: string;
56
+ max?: string;
53
57
  readonly: boolean;
54
- pattern: string | null;
55
- min: string | null;
56
- max: string | null;
57
- step: string | null;
58
- minlength: string | null;
59
- maxlength: string | null;
60
- label: string;
61
- description: string;
58
+ step?: number;
59
+ minlength?: number;
60
+ maxlength?: number;
61
+ src?: string;
62
+ label?: string;
63
+ description?: string;
62
64
  inlineContent: boolean;
63
65
  slotLabelNodes: Array<Node>;
64
66
  slotDescriptionNodes: Array<Node>;
65
67
  slotSuffixNodes: Array<Node>;
66
68
  slotPrefixNodes: Array<Node>;
67
- hasDescription: true | false;
68
- hasLabel: true | false;
69
- hasSuffix: true | false;
70
- hasPrefix: true | false;
69
+ input: HTMLInputElement;
70
+ hasDescription: boolean;
71
+ hasLabel: boolean;
72
+ hasSuffix: boolean;
73
+ hasPrefix: boolean;
71
74
  updated(): void;
72
75
  onSlotChange(): void;
76
+ inlineContentFocus(): void;
73
77
  render(): import("lit-html").TemplateResult<1>;
74
78
  }
75
79
  export {};
@@ -6,12 +6,14 @@ 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
10
  import { ifDefined } from "lit/directives/if-defined.js";
10
11
  import { formControl } from "@supersoniks/concorde/core/components/ui/form/css/form-control";
11
12
  import Subscriber from "@supersoniks/concorde/core/mixins/Subscriber";
12
13
  import FormElement from "@supersoniks/concorde/core/mixins/FormElement";
13
14
  import FormInput from "@supersoniks/concorde/core/mixins/FormInput";
14
15
  import { classMap } from "lit/directives/class-map.js";
16
+ import { fontSize } from "@supersoniks/concorde/core/components/ui/_css/size";
15
17
  /**
16
18
  * ### Le composent sonic-input étend les mixins FormInput, FormElement et Subscriber
17
19
  * **FormElement :**
@@ -26,25 +28,7 @@ const tagName = "sonic-input";
26
28
  let Input = class Input extends FormInput(FormElement(Subscriber(LitElement))) {
27
29
  constructor() {
28
30
  super(...arguments);
29
- /**
30
- * Taille du composant, implique notamment des modifications de typo et de marge interne
31
- */
32
- this.size = "";
33
- this.list = null;
34
- this.placeholder = "";
35
31
  this.readonly = false;
36
- this.pattern = null;
37
- this.min = null;
38
- this.max = null;
39
- this.step = null;
40
- this.minlength = null;
41
- this.maxlength = null;
42
- /*
43
- * TODO
44
- * Mutualiser avec le composant select
45
- */
46
- this.label = "";
47
- this.description = "";
48
32
  this.inlineContent = false;
49
33
  this.hasDescription = false;
50
34
  this.hasLabel = false;
@@ -61,6 +45,13 @@ let Input = class Input extends FormInput(FormElement(Subscriber(LitElement))) {
61
45
  onSlotChange() {
62
46
  this.requestUpdate();
63
47
  }
48
+ inlineContentFocus() {
49
+ var _a;
50
+ if (!this.inlineContent)
51
+ return;
52
+ console.log('oypouaze');
53
+ (_a = this.input) === null || _a === void 0 ? void 0 : _a.focus();
54
+ }
64
55
  render() {
65
56
  const slotClasses = {
66
57
  "has-prefix": this.hasPrefix,
@@ -71,31 +62,33 @@ let Input = class Input extends FormInput(FormElement(Subscriber(LitElement))) {
71
62
  >${this.label ? this.label : ""}<slot name="label" @slotchange=${this.onSlotChange}></slot
72
63
  ></label>
73
64
 
74
- <div class="form-control ${classMap(slotClasses)}">
65
+ <div @click=${this.inlineContentFocus} class="form-control ${classMap(slotClasses)}">
75
66
  <div class=" ${this.inlineContent ? "form-element form-element-wrapper" : "contents"}">
76
67
  <slot name="prefix" @slotchange=${this.onSlotChange}></slot>
77
68
  <input
78
69
  id="form-element"
79
70
  part="input"
80
71
  class="form-element input"
81
- type=${this.type}
82
72
  @input=${this.handleChange}
83
- ?disabled=${this.disabled}
73
+ @blur=${this.handleBlur}
74
+ type=${this.type}
75
+ disabled=${ifDefined(this.disabled)}
84
76
  ?readonly=${this.readonly}
77
+ ?autofocus=${this.autofocus}
85
78
  list=${ifDefined(this.list)}
86
- autofocus=${ifDefined(this.autofocus)}
87
- required=${ifDefined(this.required)}
88
79
  tabindex=${ifDefined(this.tabindex)}
89
80
  pattern=${ifDefined(this.pattern)}
90
81
  min=${ifDefined(this.min)}
91
82
  max=${ifDefined(this.max)}
92
83
  step=${ifDefined(this.step)}
84
+ src=${ifDefined(this.src)}
93
85
  minlength=${ifDefined(this.minlength)}
94
86
  maxlength=${ifDefined(this.maxlength)}
95
- placeholder="${this.placeholder}"
87
+ placeholder=${ifDefined(this.placeholder)}
88
+ required=${ifDefined(this.required)}
89
+ autocomplete=${ifDefined(this.autocomplete)}
96
90
  .name=${this.name}
97
91
  .value=${this.value}
98
- autocomplete=${ifDefined(this.autocomplete)}
99
92
  />
100
93
  <slot name="suffix" @slotchange=${this.onSlotChange}></slot>
101
94
  </div>
@@ -106,9 +99,12 @@ let Input = class Input extends FormInput(FormElement(Subscriber(LitElement))) {
106
99
  `;
107
100
  }
108
101
  };
109
- Input.styles = [formControl];
102
+ Input.styles = [
103
+ fontSize,
104
+ formControl
105
+ ];
110
106
  __decorate([
111
- property({ type: String })
107
+ property({ type: String, reflect: true })
112
108
  ], Input.prototype, "size", void 0);
113
109
  __decorate([
114
110
  property({ type: String })
@@ -116,9 +112,6 @@ __decorate([
116
112
  __decorate([
117
113
  property({ type: String })
118
114
  ], Input.prototype, "placeholder", void 0);
119
- __decorate([
120
- property({ type: Boolean })
121
- ], Input.prototype, "readonly", void 0);
122
115
  __decorate([
123
116
  property({ type: String })
124
117
  ], Input.prototype, "pattern", void 0);
@@ -129,14 +122,20 @@ __decorate([
129
122
  property({ type: String })
130
123
  ], Input.prototype, "max", void 0);
131
124
  __decorate([
132
- property({ type: String })
125
+ property({ type: Boolean })
126
+ ], Input.prototype, "readonly", void 0);
127
+ __decorate([
128
+ property({ type: Number })
133
129
  ], Input.prototype, "step", void 0);
134
130
  __decorate([
135
- property({ type: String })
131
+ property({ type: Number })
136
132
  ], Input.prototype, "minlength", void 0);
137
133
  __decorate([
138
- property({ type: String })
134
+ property({ type: Number })
139
135
  ], Input.prototype, "maxlength", void 0);
136
+ __decorate([
137
+ property({ type: String })
138
+ ], Input.prototype, "src", void 0);
140
139
  __decorate([
141
140
  property({ type: String })
142
141
  ], Input.prototype, "label", void 0);
@@ -158,6 +157,9 @@ __decorate([
158
157
  __decorate([
159
158
  queryAssignedNodes({ slot: "prefix" })
160
159
  ], Input.prototype, "slotPrefixNodes", void 0);
160
+ __decorate([
161
+ query('input')
162
+ ], Input.prototype, "input", void 0);
161
163
  __decorate([
162
164
  state()
163
165
  ], Input.prototype, "hasDescription", void 0);
@@ -17,9 +17,9 @@ const tagName = "sonic-radio";
17
17
  let Radio = class Radio extends Checkbox {
18
18
  constructor() {
19
19
  super();
20
+ this.radio = true;
20
21
  }
21
22
  connectedCallback() {
22
- this.radio = true;
23
23
  // this.iconName = "circle-small";
24
24
  // this.iconPrefix = "solid";
25
25
  super.connectedCallback();
@@ -32,7 +32,6 @@ Radio.styles = [
32
32
  :host input {
33
33
  border-radius: 50%;
34
34
  }
35
-
36
35
  :host sonic-icon {
37
36
  border-radius: 50%;
38
37
  overflow: hidden;
@@ -5,9 +5,9 @@ export declare class Select extends Select_base {
5
5
  static styles: import("lit").CSSResult[];
6
6
  valueKey: string;
7
7
  wordingKey: string;
8
- multiple: null;
9
- size: "" | "xs" | "sm" | "lg";
10
- selectSize: string | null;
8
+ multiple: boolean;
9
+ size?: "2xs" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl";
10
+ selectSize?: number;
11
11
  private _options;
12
12
  set options(value: Array<any>);
13
13
  get options(): Array<any>;
@@ -15,16 +15,16 @@ 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
+ label?: string;
19
+ description?: string;
20
20
  slotLabelNodes: Array<Node>;
21
21
  slotDescriptionNodes: Array<Node>;
22
22
  slotSuffixNodes: Array<Node>;
23
23
  slotPrefixNodes: Array<Node>;
24
- hasDescription: true | false;
25
- hasLabel: true | false;
26
- hasSuffix: true | false;
27
- hasPrefix: true | false;
24
+ hasDescription: boolean;
25
+ hasLabel: boolean;
26
+ hasSuffix: boolean;
27
+ hasPrefix: boolean;
28
28
  updated(): void;
29
29
  onSlotChange(): void;
30
30
  validateFormElement(): void;
@@ -27,17 +27,9 @@ let Select = class Select extends FormElement(Subscriber(LitElement)) {
27
27
  super(...arguments);
28
28
  this.valueKey = "value";
29
29
  this.wordingKey = "wording";
30
- this.multiple = null;
31
- this.size = "";
32
- this.selectSize = null;
30
+ this.multiple = false;
33
31
  this._options = [];
34
32
  this._value = "";
35
- /*
36
- * TODO
37
- * Mutualiser avec le composant select
38
- */
39
- this.label = "";
40
- this.description = "";
41
33
  this.hasDescription = false;
42
34
  this.hasLabel = false;
43
35
  this.hasSuffix = false;
@@ -117,10 +109,12 @@ let Select = class Select extends FormElement(Subscriber(LitElement)) {
117
109
  <div class="form-select-wrapper">
118
110
  <select
119
111
  @change=${this.handleChange}
120
- disabled=${ifDefined(this.multiple)}
112
+ @blur=${this.handleBlur}
113
+ disabled=${ifDefined(this.disabled)}
114
+ ?required=${this.required}
115
+ ?multiple=${this.multiple}
121
116
  size=${ifDefined(this.selectSize)}
122
- autofocus=${ifDefined(this.autofocus)}
123
- required=${ifDefined(this.required)}
117
+ ?autofocus=${this.autofocus}
124
118
  .value="${this.value}"
125
119
  class="form-element"
126
120
  >
@@ -182,10 +176,10 @@ __decorate([
182
176
  property({ type: Boolean })
183
177
  ], Select.prototype, "multiple", void 0);
184
178
  __decorate([
185
- property({ type: String })
179
+ property({ type: String, reflect: true })
186
180
  ], Select.prototype, "size", void 0);
187
181
  __decorate([
188
- property({ type: String })
182
+ property({ type: Number })
189
183
  ], Select.prototype, "selectSize", void 0);
190
184
  __decorate([
191
185
  property({ type: Array })
@@ -3,16 +3,17 @@ declare const Textarea_base: {
3
3
  new (...args: any[]): {
4
4
  validateFormElement(): void;
5
5
  type: "number" | "search" | "file" | "button" | "password" | "url" | "color" | "hidden" | "time" | "image" | "text" | "reset" | "submit" | "month" | "week" | "checkbox" | "radio" | "range" | "tel" | "email" | "date" | "datetime-local";
6
- tabindex: string | null;
7
- 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" | null;
6
+ tabindex?: number | undefined;
7
+ 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
8
  getFormPublisher(): any;
9
9
  updateDataValue(): void;
10
10
  handleChange(e?: any): void;
11
+ handleBlur(e?: any): void;
11
12
  getValueForFormPublisher(): any;
12
- error: true | null;
13
+ error: boolean;
13
14
  autofocus: boolean;
15
+ required: boolean;
14
16
  disabled: true | null;
15
- required: true | null;
16
17
  formDataProvider: string;
17
18
  _value: any;
18
19
  value: any;
@@ -45,23 +46,23 @@ declare const Textarea_base: {
45
46
  export declare class Textarea extends Textarea_base {
46
47
  static styles: import("lit").CSSResult[];
47
48
  size: "" | "xs" | "sm" | "lg";
48
- rows: string;
49
- cols: string;
50
- maxlength: string;
51
- minlength: string;
52
- wrap: "hard" | "soft" | null;
53
- readonly: boolean | null;
54
- placeholder: string;
55
- label: string;
56
- description: string;
49
+ rows?: number;
50
+ cols?: number;
51
+ maxlength?: number;
52
+ minlength?: number;
53
+ wrap?: "hard" | "soft";
54
+ readonly: boolean;
55
+ placeholder?: string;
56
+ label?: string;
57
+ description?: string;
57
58
  slotLabelNodes: Array<Node>;
58
59
  slotDescriptionNodes: Array<Node>;
59
60
  slotSuffixNodes: Array<Node>;
60
61
  slotPrefixNodes: Array<Node>;
61
- hasDescription: true | false;
62
- hasLabel: true | false;
63
- hasSuffix: true | false;
64
- hasPrefix: true | false;
62
+ hasDescription: boolean;
63
+ hasLabel: boolean;
64
+ hasSuffix: boolean;
65
+ hasPrefix: boolean;
65
66
  slotClasses: {};
66
67
  updated(): void;
67
68
  onSlotChange(): void;
@@ -20,19 +20,7 @@ let Textarea = class Textarea extends FormInput(FormElement(Subscriber(LitElemen
20
20
  // type: "" | "primary" | "warning" | "danger" | "success" | "info" = "";
21
21
  // @property({ type: String }) variant: "" | "ghost" | "outline" = "";
22
22
  this.size = "";
23
- this.rows = "";
24
- this.cols = "";
25
- this.maxlength = "";
26
- this.minlength = "";
27
- this.wrap = null;
28
- this.readonly = null;
29
- this.placeholder = "";
30
- /*
31
- * TODO
32
- * Mutualiser avec le composant select
33
- */
34
- this.label = "";
35
- this.description = "";
23
+ this.readonly = false;
36
24
  this.hasDescription = false;
37
25
  this.hasLabel = false;
38
26
  this.hasSuffix = false;
@@ -67,21 +55,22 @@ let Textarea = class Textarea extends FormInput(FormElement(Subscriber(LitElemen
67
55
  <div class="form-control">
68
56
  <textarea
69
57
  @input=${this.handleChange}
70
- ?disabled=${this.disabled}
58
+ @blur=${this.handleBlur}
59
+ disabled=${ifDefined(this.disabled)}
71
60
  ?required=${this.required}
72
- autocomplete=${ifDefined(this.autocomplete)}
73
- autofocus=${ifDefined(this.autofocus)}
61
+ ?autofocus=${this.autofocus}
74
62
  rows=${ifDefined(this.rows)}
75
63
  cols=${ifDefined(this.cols)}
76
64
  maxlength=${ifDefined(this.maxlength)}
77
65
  minlength=${ifDefined(this.minlength)}
78
66
  ?readonly=${this.readonly}
79
67
  spellcheck=${ifDefined(this.spellcheck)}
68
+ autocomplete=${ifDefined(this.autocomplete)}
69
+ tabindex=${ifDefined(this.tabindex)}
80
70
  wrap=${ifDefined(this.wrap)}
81
- class="form-element textarea custom-scroll"
82
71
  placeholder="${this.placeholder}"
83
- >
84
- ${this.value}</textarea
72
+ class="form-element textarea custom-scroll"
73
+ >${this.value}</textarea
85
74
  >
86
75
  </div>
87
76
 
@@ -104,16 +93,16 @@ __decorate([
104
93
  property({ type: String })
105
94
  ], Textarea.prototype, "size", void 0);
106
95
  __decorate([
107
- property({ type: String })
96
+ property({ type: Number })
108
97
  ], Textarea.prototype, "rows", void 0);
109
98
  __decorate([
110
- property({ type: String })
99
+ property({ type: Number })
111
100
  ], Textarea.prototype, "cols", void 0);
112
101
  __decorate([
113
- property({ type: String })
102
+ property({ type: Number })
114
103
  ], Textarea.prototype, "maxlength", void 0);
115
104
  __decorate([
116
- property({ type: String })
105
+ property({ type: Number })
117
106
  ], Textarea.prototype, "minlength", void 0);
118
107
  __decorate([
119
108
  property({ type: String })
@@ -119,6 +119,10 @@ Icon.styles = css `
119
119
  :host([size="2xl"]) svg {
120
120
  --sc-icon-size: 2em;
121
121
  }
122
+
123
+ :host([size="3xl"]) svg {
124
+ --sc-icon-size: 2.8em;
125
+
122
126
  `;
123
127
  __decorate([
124
128
  property({ type: String })
@@ -8,7 +8,6 @@ export declare class Image extends LitElement {
8
8
  ratio: string;
9
9
  objectPosition: string;
10
10
  imageRendering: string;
11
- shadow: "" | "none" | "sm" | "md";
12
11
  cover: boolean;
13
12
  render(): import("lit-html").TemplateResult<1>;
14
13
  }
@@ -18,7 +18,6 @@ let Image = class Image extends LitElement {
18
18
  this.ratio = "auto";
19
19
  this.objectPosition = "center center";
20
20
  this.imageRendering = "auto";
21
- this.shadow = "none";
22
21
  this.cover = false;
23
22
  }
24
23
  render() {
@@ -83,25 +82,6 @@ Image.styles = [
83
82
  --sc-img-radius: 0 !important;
84
83
  }
85
84
 
86
- /*OMBRE*/
87
- :host([shadow]) > div,
88
- :host([shadow="md"]) > div,
89
- :host([shadow="true"]) > div {
90
- box-shadow: var(--sc-shadow);
91
- }
92
-
93
- :host([shadow="sm"]) > div {
94
- box-shadow: var(--sc-shadow-sm);
95
- }
96
-
97
- :host([shadow="none"]) > div {
98
- box-shadow: none;
99
- }
100
-
101
- :host([shadow="lg"]) > div {
102
- box-shadow: var(--sc-shadow-lg);
103
- }
104
-
105
85
  :host([cover]),
106
86
  :host([cover]) > div,
107
87
  :host([cover]) img {
@@ -136,9 +116,6 @@ __decorate([
136
116
  __decorate([
137
117
  property({ type: String })
138
118
  ], Image.prototype, "imageRendering", void 0);
139
- __decorate([
140
- property({ type: String, reflect: true })
141
- ], Image.prototype, "shadow", void 0);
142
119
  __decorate([
143
120
  property({ type: Boolean, reflect: true })
144
121
  ], Image.prototype, "cover", void 0);