@supersoniks/concorde 1.1.42 → 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.
- package/components.js +2 -3
- package/concorde-core.bundle.js +37 -35
- package/concorde-core.es.js +5081 -4317
- package/core/_types/types.d.ts +26 -0
- package/core/_types/types.js +1 -0
- package/core/components/functional/date/date.d.ts +13 -5
- package/core/components/functional/date/date.js +48 -29
- package/core/components/functional/example/example.d.ts +1 -1
- package/core/components/functional/example/example.js +1 -1
- package/core/components/functional/fetch/fetch.d.ts +40 -3
- package/core/components/functional/fetch/fetch.js +2 -6
- package/core/components/functional/functional.d.ts +2 -0
- package/core/components/functional/functional.js +2 -0
- package/core/components/functional/if/if.d.ts +3 -0
- package/core/components/functional/if/if.js +6 -12
- package/core/components/functional/if/if.test.d.ts +1 -0
- package/core/components/functional/if/if.test.js +44 -0
- package/core/components/functional/list/list.d.ts +32 -8
- package/core/components/functional/list/list.js +33 -40
- package/core/components/functional/mix/mix.d.ts +22 -0
- package/core/components/functional/mix/mix.js +99 -0
- package/core/components/functional/queue/queue.d.ts +16 -3
- package/core/components/functional/queue/queue.js +71 -15
- package/core/components/functional/router/redirect.d.ts +10 -1
- package/core/components/functional/router/redirect.js +5 -6
- package/core/components/functional/router/router.d.ts +15 -1
- package/core/components/functional/router/router.js +1 -6
- package/core/components/functional/sdui/SDUIDescriptorTransformer.d.ts +1 -1
- package/core/components/functional/sdui/SDUIDescriptorTransformer.js +24 -12
- package/core/components/functional/sdui/default-library.json +108 -0
- package/core/components/functional/sdui/sdui-utils.d.ts +5 -0
- package/core/components/functional/sdui/sdui-utils.js +63 -0
- package/core/components/functional/sdui/sdui.d.ts +16 -9
- package/core/components/functional/sdui/sdui.js +52 -25
- package/core/components/functional/sdui/types.d.ts +4 -2
- package/core/components/functional/states/states.d.ts +19 -3
- package/core/components/functional/states/states.js +7 -12
- package/core/components/functional/submit/submit.d.ts +16 -1
- package/core/components/functional/submit/submit.js +87 -17
- package/core/components/functional/subscriber/subscriber.d.ts +4 -1
- package/core/components/functional/subscriber/subscriber.js +1 -6
- package/core/components/functional/value/value.d.ts +7 -0
- package/core/components/functional/value/value.js +26 -0
- package/core/components/ui/_css/scroll.js +6 -7
- package/core/components/ui/_css/size.d.ts +1 -0
- package/core/components/ui/_css/size.js +3 -1
- package/core/components/ui/alert/alert.d.ts +2 -2
- package/core/components/ui/alert/alert.js +11 -16
- package/core/components/ui/badge/badge.d.ts +3 -1
- package/core/components/ui/badge/badge.js +36 -22
- package/core/components/ui/button/button.d.ts +23 -20
- package/core/components/ui/button/button.js +59 -42
- package/core/components/ui/captcha/captcha.d.ts +14 -2
- package/core/components/ui/captcha/captcha.js +17 -12
- package/core/components/ui/card/card-footer.js +1 -8
- package/core/components/ui/card/card-header-descripton.js +3 -9
- package/core/components/ui/card/card-header.js +1 -6
- package/core/components/ui/card/card-main.js +0 -5
- package/core/components/ui/card/card.d.ts +1 -1
- package/core/components/ui/card/card.js +28 -12
- package/core/components/ui/divider/divider.d.ts +2 -0
- package/core/components/ui/divider/divider.js +43 -16
- package/core/components/ui/form/checkbox/checkbox.d.ts +53 -16
- package/core/components/ui/form/checkbox/checkbox.js +53 -28
- package/core/components/ui/form/css/form-control.d.ts +2 -0
- package/core/components/ui/form/css/form-control.js +145 -67
- package/core/components/ui/form/fieldset/fieldset.d.ts +8 -1
- package/core/components/ui/form/fieldset/fieldset.js +45 -8
- package/core/components/ui/form/fieldset/legend-description.js +0 -5
- package/core/components/ui/form/fieldset/legend.js +3 -6
- package/core/components/ui/form/form-actions/form-actions.d.ts +2 -0
- package/core/components/ui/form/form-actions/form-actions.js +26 -11
- package/core/components/ui/form/form-layout/form-layout.d.ts +5 -2
- package/core/components/ui/form/form-layout/form-layout.js +31 -9
- package/core/components/ui/form/input/input.d.ts +15 -18
- package/core/components/ui/form/input/input.js +87 -52
- package/core/components/ui/form/input/password-helper.d.ts +1 -1
- package/core/components/ui/form/input/password-helper.js +3 -2
- package/core/components/ui/form/input/same-value-helper.d.ts +1 -1
- package/core/components/ui/form/input/same-value-helper.js +1 -0
- package/core/components/ui/form/input-autocomplete/input-autocomplete.d.ts +2 -3
- package/core/components/ui/form/input-autocomplete/input-autocomplete.js +2 -6
- package/core/components/ui/form/radio/radio.d.ts +6 -0
- package/core/components/ui/form/radio/radio.js +7 -12
- package/core/components/ui/form/select/select.d.ts +23 -7
- package/core/components/ui/form/select/select.js +69 -38
- package/core/components/ui/form/textarea/textarea.d.ts +13 -13
- package/core/components/ui/form/textarea/textarea.js +29 -36
- package/core/components/ui/group/group.d.ts +11 -1
- package/core/components/ui/group/group.js +79 -17
- package/core/components/ui/icon/icon.d.ts +10 -3
- package/core/components/ui/icon/icon.js +16 -15
- package/core/components/ui/icon/icons.js +11 -8
- package/core/components/ui/icon/icons.json +1 -1
- package/core/components/ui/image/image.js +0 -5
- package/core/components/ui/link/link.d.ts +1 -1
- package/core/components/ui/link/link.js +2 -6
- package/core/components/ui/loader/loader.js +2 -8
- package/core/components/ui/menu/menu-item.js +4 -9
- package/core/components/ui/menu/menu.d.ts +9 -1
- package/core/components/ui/menu/menu.js +183 -27
- package/core/components/ui/modal/modal-actions.js +1 -6
- package/core/components/ui/modal/modal-close.d.ts +1 -0
- package/core/components/ui/modal/modal-close.js +14 -10
- package/core/components/ui/modal/modal-content.js +0 -5
- package/core/components/ui/modal/modal-subtitle.js +2 -6
- package/core/components/ui/modal/modal-title.js +0 -5
- package/core/components/ui/modal/modal.d.ts +7 -7
- package/core/components/ui/modal/modal.js +36 -36
- package/core/components/ui/pop/pop.d.ts +6 -5
- package/core/components/ui/pop/pop.js +44 -44
- package/core/components/ui/progress/progress.js +34 -32
- package/core/components/ui/table/table-caption.js +5 -10
- package/core/components/ui/table/table-tbody.js +10 -14
- package/core/components/ui/table/table-td.d.ts +2 -0
- package/core/components/ui/table/table-td.js +8 -5
- package/core/components/ui/table/table-tfoot.js +5 -7
- package/core/components/ui/table/table-th.d.ts +2 -0
- package/core/components/ui/table/table-th.js +12 -9
- package/core/components/ui/table/table-thead.js +1 -6
- package/core/components/ui/table/table-tr.js +4 -6
- package/core/components/ui/table/table.d.ts +0 -3
- package/core/components/ui/table/table.js +14 -31
- package/core/components/ui/taxonomy/taxonomy.d.ts +6 -3
- package/core/components/ui/taxonomy/taxonomy.js +9 -9
- package/core/components/ui/theme/theme-collection/core-variables.js +13 -11
- package/core/components/ui/theme/theme-collection/dark.js +1 -1
- package/core/components/ui/theme/theme.d.ts +1 -6
- package/core/components/ui/theme/theme.js +7 -36
- package/core/components/ui/toast/message-subscriber.d.ts +13 -7
- package/core/components/ui/toast/toast-item.js +1 -1
- package/core/components/ui/toast/toast.d.ts +2 -1
- package/core/components/ui/toast/toast.js +29 -14
- package/core/components/ui/tooltip/tooltip.d.ts +1 -0
- package/core/components/ui/tooltip/tooltip.js +35 -14
- package/core/components/ui/ui.js +0 -3
- package/core/core.js +5 -6
- package/core/mixins/Fetcher.d.ts +19 -10
- package/core/mixins/Fetcher.js +26 -10
- package/core/mixins/FormCheckable.d.ts +17 -8
- package/core/mixins/FormCheckable.js +177 -22
- package/core/mixins/FormElement.d.ts +12 -7
- package/core/mixins/FormElement.js +42 -26
- package/core/mixins/FormInput.d.ts +8 -4
- package/core/mixins/FormInput.js +4 -3
- package/core/mixins/Subscriber.d.ts +7 -5
- package/core/mixins/Subscriber.js +34 -32
- package/core/utils/Arrays.d.ts +15 -15
- package/core/utils/DataBindObserver.d.ts +16 -9
- package/core/utils/DataBindObserver.js +23 -28
- package/core/utils/Electron.d.ts +5 -1
- package/core/utils/Electron.js +4 -2
- package/core/utils/HTML.d.ts +9 -2
- package/core/utils/HTML.js +22 -3
- package/core/utils/LocationHandler.d.ts +6 -5
- package/core/utils/LocationHandler.js +19 -8
- package/core/utils/Objects.d.ts +7 -4
- package/core/utils/Objects.js +28 -6
- package/core/utils/{PublisherProxy.d.mts → PublisherProxy.d.ts} +40 -31
- package/core/utils/{PublisherProxy.mjs → PublisherProxy.js} +54 -28
- package/core/utils/Utils.d.ts +3 -0
- package/core/utils/Utils.js +18 -0
- package/core/utils/api.d.ts +39 -7
- package/core/utils/api.js +45 -32
- package/img/concorde-logo.svg +1 -0
- package/img/concorde.png +0 -0
- package/img/concorde_def.png +0 -0
- package/mixins.d.ts +36 -18
- package/mixins.js +3 -4
- package/package.json +45 -10
- package/svg/regular/plane.svg +1 -0
- package/svg/solid/plane.svg +1 -0
- package/test-utils/TestUtils.d.ts +4 -0
- package/test-utils/TestUtils.js +12 -0
- package/utils.d.ts +3 -1
- package/utils.js +7 -5
- package/core/components/functional/configuration/configuration.d.ts +0 -5
- package/core/components/functional/configuration/configuration.js +0 -22
- package/core/components/ui/tabs/tab.d.ts +0 -6
- package/core/components/ui/tabs/tab.js +0 -46
- package/core/components/ui/tabs/tabs.d.ts +0 -15
- package/core/components/ui/tabs/tabs.js +0 -129
|
@@ -5,21 +5,22 @@ 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
|
var Pop_1;
|
|
8
|
-
import { html, LitElement, css } from
|
|
9
|
-
import { customElement, query, state, property } from
|
|
10
|
-
import HTML from
|
|
11
|
-
const tagName =
|
|
8
|
+
import { html, LitElement, css } from "lit";
|
|
9
|
+
import { customElement, query, state, property } from "lit/decorators.js";
|
|
10
|
+
import HTML from "@supersoniks/concorde/core/utils/HTML";
|
|
11
|
+
const tagName = "sonic-pop";
|
|
12
12
|
let Pop = Pop_1 = class Pop extends LitElement {
|
|
13
13
|
constructor() {
|
|
14
14
|
super(...arguments);
|
|
15
15
|
this.open = false;
|
|
16
|
-
this.toggle =
|
|
16
|
+
this.toggle = "true";
|
|
17
|
+
this.noToggle = false;
|
|
17
18
|
this.inline = false;
|
|
18
19
|
/**
|
|
19
20
|
* Ombre
|
|
20
21
|
*/
|
|
21
|
-
this.shadow =
|
|
22
|
-
this.placement =
|
|
22
|
+
this.shadow = "lg";
|
|
23
|
+
this.placement = "bottom";
|
|
23
24
|
this.positioningRuns = false;
|
|
24
25
|
this.lastContentX = Number.NaN;
|
|
25
26
|
this.lastContentY = Number.NaN;
|
|
@@ -32,16 +33,17 @@ 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.
|
|
36
|
+
if (this.open && this.noToggle)
|
|
36
37
|
return;
|
|
37
|
-
|
|
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();
|
|
41
43
|
}
|
|
42
44
|
_show() {
|
|
43
45
|
this.open = true;
|
|
44
|
-
this.popContent.setAttribute(
|
|
46
|
+
this.popContent.setAttribute("tabindex", "0");
|
|
45
47
|
if (this.popBtn && this.popContent && !this.positioningRuns) {
|
|
46
48
|
this.positioningRuns = true;
|
|
47
49
|
this.lastContentX = Number.NaN;
|
|
@@ -51,7 +53,7 @@ let Pop = Pop_1 = class Pop extends LitElement {
|
|
|
51
53
|
}
|
|
52
54
|
_hide() {
|
|
53
55
|
this.open = false;
|
|
54
|
-
this.popContent.setAttribute(
|
|
56
|
+
this.popContent.setAttribute("tabindex", "-1");
|
|
55
57
|
this.positioningRuns = false;
|
|
56
58
|
}
|
|
57
59
|
_handleClosePop(e) {
|
|
@@ -60,10 +62,10 @@ let Pop = Pop_1 = class Pop extends LitElement {
|
|
|
60
62
|
Pop_1.pops.forEach((pop) => {
|
|
61
63
|
const popContainsTarget = path.includes(pop);
|
|
62
64
|
const popContentContainsTarget = path.includes(pop.querySelector('[slot="content"]'));
|
|
63
|
-
const isCloseManual = HTML.getAncestorAttributeValue(target,
|
|
64
|
-
if (e.type ==
|
|
65
|
+
const isCloseManual = HTML.getAncestorAttributeValue(target, "data-on-select") === "keep";
|
|
66
|
+
if (e.type == "pointerdown" && popContainsTarget)
|
|
65
67
|
return;
|
|
66
|
-
if (e.type ==
|
|
68
|
+
if (e.type == "click" && ((popContainsTarget && isCloseManual) || !popContentContainsTarget))
|
|
67
69
|
return;
|
|
68
70
|
pop._hide();
|
|
69
71
|
});
|
|
@@ -71,8 +73,8 @@ let Pop = Pop_1 = class Pop extends LitElement {
|
|
|
71
73
|
connectedCallback() {
|
|
72
74
|
super.connectedCallback();
|
|
73
75
|
if (Pop_1.pops.size == 0) {
|
|
74
|
-
document.addEventListener(
|
|
75
|
-
document.addEventListener(
|
|
76
|
+
document.addEventListener("pointerdown", this._handleClosePop);
|
|
77
|
+
document.addEventListener("click", this._handleClosePop);
|
|
76
78
|
}
|
|
77
79
|
Pop_1.pops.add(this);
|
|
78
80
|
}
|
|
@@ -80,8 +82,8 @@ let Pop = Pop_1 = class Pop extends LitElement {
|
|
|
80
82
|
super.disconnectedCallback();
|
|
81
83
|
Pop_1.pops.delete(this);
|
|
82
84
|
if (Pop_1.pops.size == 0) {
|
|
83
|
-
document.removeEventListener(
|
|
84
|
-
document.removeEventListener(
|
|
85
|
+
document.removeEventListener("pointerdown", this._handleClosePop);
|
|
86
|
+
document.removeEventListener("click", this._handleClosePop);
|
|
85
87
|
}
|
|
86
88
|
}
|
|
87
89
|
_setUpMenu(placement) {
|
|
@@ -101,34 +103,34 @@ let Pop = Pop_1 = class Pop extends LitElement {
|
|
|
101
103
|
let xRight = x0 + thisRect.width + 2 * padding;
|
|
102
104
|
let yBottom = y0 + thisRect.height + padding;
|
|
103
105
|
switch (placement) {
|
|
104
|
-
case
|
|
106
|
+
case "bottom":
|
|
105
107
|
y = yBottom;
|
|
106
108
|
break;
|
|
107
|
-
case
|
|
109
|
+
case "top":
|
|
108
110
|
y = yTop;
|
|
109
111
|
break;
|
|
110
|
-
case
|
|
112
|
+
case "left":
|
|
111
113
|
x = xLeft;
|
|
112
114
|
break;
|
|
113
|
-
case
|
|
115
|
+
case "right":
|
|
114
116
|
x = xRight;
|
|
115
117
|
break;
|
|
116
118
|
}
|
|
117
119
|
let dxRight = window.innerWidth - xRight - bodyRect.left - contentRect.width - shiftPadding;
|
|
118
|
-
if (dxRight < 0 && placement ===
|
|
120
|
+
if (dxRight < 0 && placement === "right")
|
|
119
121
|
x = xLeft;
|
|
120
|
-
if (dxRight < 0 && [
|
|
122
|
+
if (dxRight < 0 && ["top", "bottom"].includes(placement))
|
|
121
123
|
x = Math.max(x + dxRight, xLeft + thisRect.width);
|
|
122
124
|
let dxLeft = -bodyRect.left - xLeft;
|
|
123
|
-
if (dxLeft > shiftPadding && placement ===
|
|
125
|
+
if (dxLeft > shiftPadding && placement === "left")
|
|
124
126
|
x = xRight;
|
|
125
127
|
let dyBottom = window.innerHeight - yBottom - bodyRect.top - contentRect.height - shiftPadding;
|
|
126
|
-
if (dyBottom < 0 && placement ===
|
|
128
|
+
if (dyBottom < 0 && placement === "bottom")
|
|
127
129
|
y = yTop;
|
|
128
|
-
if (dyBottom < 0 && [
|
|
130
|
+
if (dyBottom < 0 && ["left", "right"].includes(placement))
|
|
129
131
|
y = Math.max(y + dyBottom, yTop + thisRect.height);
|
|
130
132
|
let dyTop = -bodyRect.top - yTop;
|
|
131
|
-
if (dyTop > -shiftPadding && placement ===
|
|
133
|
+
if (dyTop > -shiftPadding && placement === "top")
|
|
132
134
|
y = yBottom;
|
|
133
135
|
this.lastContentX = x;
|
|
134
136
|
this.lastContentY = y;
|
|
@@ -145,7 +147,7 @@ let Pop = Pop_1 = class Pop extends LitElement {
|
|
|
145
147
|
tabindex="-1"
|
|
146
148
|
part="content"
|
|
147
149
|
class="
|
|
148
|
-
${this.open ?
|
|
150
|
+
${this.open ? "is-open" : ""}"
|
|
149
151
|
></slot>
|
|
150
152
|
`;
|
|
151
153
|
}
|
|
@@ -157,7 +159,7 @@ Pop.styles = [
|
|
|
157
159
|
display: inline-block;
|
|
158
160
|
vertical-align: middle;
|
|
159
161
|
}
|
|
160
|
-
slot[name=
|
|
162
|
+
slot[name="content"] {
|
|
161
163
|
max-width: 80vw;
|
|
162
164
|
background-color: var(--sc-base);
|
|
163
165
|
position: absolute;
|
|
@@ -172,7 +174,7 @@ Pop.styles = [
|
|
|
172
174
|
border-radius: min(calc(var(--sc-btn-rounded) * 2), 0.4em);
|
|
173
175
|
}
|
|
174
176
|
|
|
175
|
-
slot[name=
|
|
177
|
+
slot[name="content"].is-open {
|
|
176
178
|
transform: translateY(0) scale(1);
|
|
177
179
|
opacity: 1;
|
|
178
180
|
pointer-events: auto;
|
|
@@ -181,21 +183,21 @@ Pop.styles = [
|
|
|
181
183
|
}
|
|
182
184
|
|
|
183
185
|
/*OMBRE*/
|
|
184
|
-
:host([shadow]) slot[name=
|
|
185
|
-
:host([shadow=
|
|
186
|
-
:host([shadow=
|
|
186
|
+
:host([shadow]) slot[name="content"],
|
|
187
|
+
:host([shadow="md"]) slot[name="content"],
|
|
188
|
+
:host([shadow="true"]) slot[name="content"] {
|
|
187
189
|
box-shadow: var(--sc-shadow);
|
|
188
190
|
}
|
|
189
191
|
|
|
190
|
-
:host([shadow=
|
|
192
|
+
:host([shadow="sm"]) slot[name="content"] {
|
|
191
193
|
box-shadow: var(--sc-shadow-sm);
|
|
192
194
|
}
|
|
193
195
|
|
|
194
|
-
:host([shadow=
|
|
196
|
+
:host([shadow="none"]) slot[name="content"] {
|
|
195
197
|
box-shadow: none;
|
|
196
198
|
}
|
|
197
199
|
|
|
198
|
-
:host([shadow=
|
|
200
|
+
:host([shadow="lg"]) slot[name="content"] {
|
|
199
201
|
box-shadow: var(--sc-shadow-lg);
|
|
200
202
|
}
|
|
201
203
|
|
|
@@ -208,14 +210,17 @@ __decorate([
|
|
|
208
210
|
state()
|
|
209
211
|
], Pop.prototype, "open", void 0);
|
|
210
212
|
__decorate([
|
|
211
|
-
query(
|
|
213
|
+
query("slot:not([name=content])")
|
|
212
214
|
], Pop.prototype, "popBtn", void 0);
|
|
213
215
|
__decorate([
|
|
214
|
-
query(
|
|
216
|
+
query("slot[name=content]")
|
|
215
217
|
], Pop.prototype, "popContent", void 0);
|
|
216
218
|
__decorate([
|
|
217
219
|
property({ type: String })
|
|
218
220
|
], Pop.prototype, "toggle", void 0);
|
|
221
|
+
__decorate([
|
|
222
|
+
property({ type: Boolean })
|
|
223
|
+
], Pop.prototype, "noToggle", void 0);
|
|
219
224
|
__decorate([
|
|
220
225
|
property({ type: Boolean, reflect: true })
|
|
221
226
|
], Pop.prototype, "inline", void 0);
|
|
@@ -229,8 +234,3 @@ Pop = Pop_1 = __decorate([
|
|
|
229
234
|
customElement(tagName)
|
|
230
235
|
], Pop);
|
|
231
236
|
export { Pop };
|
|
232
|
-
//Ajout pour la creation du cem notamment pour Storybook
|
|
233
|
-
try {
|
|
234
|
-
customElements.define(tagName, Pop);
|
|
235
|
-
}
|
|
236
|
-
catch (e) { }
|
|
@@ -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
|
-
|
|
25
|
-
|
|
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
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
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:
|
|
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
|
-
|
|
119
|
-
|
|
120
|
-
|
|
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
|
|
127
|
-
margin-top
|
|
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) { }
|
|
@@ -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
|
|
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) { }
|
|
@@ -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
|
|
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-
|
|
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-
|
|
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) { }
|
|
@@ -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) { }
|
|
@@ -9,21 +9,19 @@ import { customElement } from "lit/decorators.js";
|
|
|
9
9
|
const tagName = "sonic-tfoot";
|
|
10
10
|
let TableTfoot = class TableTfoot extends LitElement {
|
|
11
11
|
render() {
|
|
12
|
-
return html `<tfoot
|
|
12
|
+
return html `<tfoot>
|
|
13
|
+
<slot></slot>
|
|
14
|
+
</tfoot>`;
|
|
13
15
|
}
|
|
14
16
|
};
|
|
15
17
|
TableTfoot.styles = [
|
|
16
18
|
css `
|
|
17
19
|
:host {
|
|
18
20
|
display: contents;
|
|
19
|
-
}
|
|
21
|
+
}
|
|
22
|
+
`,
|
|
20
23
|
];
|
|
21
24
|
TableTfoot = __decorate([
|
|
22
25
|
customElement(tagName)
|
|
23
26
|
], TableTfoot);
|
|
24
27
|
export { TableTfoot };
|
|
25
|
-
//Ajout pour la creation du cem notamment pour Storybook
|
|
26
|
-
try {
|
|
27
|
-
customElements.define(tagName, TableTfoot);
|
|
28
|
-
}
|
|
29
|
-
catch (e) { }
|
|
@@ -15,6 +15,8 @@ let TableTh = class TableTh extends LitElement {
|
|
|
15
15
|
const styles = {
|
|
16
16
|
textAlign: this.align,
|
|
17
17
|
minWidth: this.minWidth,
|
|
18
|
+
maxWidth: this.maxWidth,
|
|
19
|
+
width: this.width,
|
|
18
20
|
};
|
|
19
21
|
return html `<th
|
|
20
22
|
part="th"
|
|
@@ -31,10 +33,10 @@ TableTh.styles = [
|
|
|
31
33
|
css `
|
|
32
34
|
:host {
|
|
33
35
|
display: contents;
|
|
34
|
-
background:var(--sc-table-bg);
|
|
35
|
-
position:sticky;
|
|
36
|
-
top:0;
|
|
37
|
-
z-index:20;
|
|
36
|
+
background: var(--sc-table-bg);
|
|
37
|
+
position: sticky;
|
|
38
|
+
top: 0;
|
|
39
|
+
z-index: 20;
|
|
38
40
|
}
|
|
39
41
|
|
|
40
42
|
th {
|
|
@@ -60,12 +62,13 @@ __decorate([
|
|
|
60
62
|
__decorate([
|
|
61
63
|
property({ type: String })
|
|
62
64
|
], TableTh.prototype, "minWidth", void 0);
|
|
65
|
+
__decorate([
|
|
66
|
+
property({ type: String })
|
|
67
|
+
], TableTh.prototype, "maxWidth", void 0);
|
|
68
|
+
__decorate([
|
|
69
|
+
property({ type: String })
|
|
70
|
+
], TableTh.prototype, "width", void 0);
|
|
63
71
|
TableTh = __decorate([
|
|
64
72
|
customElement(tagName)
|
|
65
73
|
], TableTh);
|
|
66
74
|
export { TableTh };
|
|
67
|
-
//Ajout pour la creation du cem notamment pour Storybook
|
|
68
|
-
try {
|
|
69
|
-
customElements.define(tagName, TableTh);
|
|
70
|
-
}
|
|
71
|
-
catch (e) { }
|
|
@@ -17,14 +17,9 @@ TableThead.styles = [
|
|
|
17
17
|
:host {
|
|
18
18
|
display: table-header-group;
|
|
19
19
|
}
|
|
20
|
-
|
|
20
|
+
`,
|
|
21
21
|
];
|
|
22
22
|
TableThead = __decorate([
|
|
23
23
|
customElement(tagName)
|
|
24
24
|
], TableThead);
|
|
25
25
|
export { TableThead };
|
|
26
|
-
//Ajout pour la creation du cem notamment pour Storybook
|
|
27
|
-
try {
|
|
28
|
-
customElements.define(tagName, TableThead);
|
|
29
|
-
}
|
|
30
|
-
catch (e) { }
|
|
@@ -20,14 +20,12 @@ TableTr.styles = [
|
|
|
20
20
|
display: table-row;
|
|
21
21
|
}
|
|
22
22
|
|
|
23
|
-
|
|
23
|
+
:host([odd]) {
|
|
24
|
+
background: var(--sc-table-accent-bg);
|
|
25
|
+
}
|
|
26
|
+
`,
|
|
24
27
|
];
|
|
25
28
|
TableTr = __decorate([
|
|
26
29
|
customElement(tagName)
|
|
27
30
|
], TableTr);
|
|
28
31
|
export { TableTr };
|
|
29
|
-
//Ajout pour la creation du cem notamment pour Storybook
|
|
30
|
-
try {
|
|
31
|
-
customElements.define(tagName, TableTr);
|
|
32
|
-
}
|
|
33
|
-
catch (e) { }
|
|
@@ -9,10 +9,7 @@ import "@supersoniks/concorde/core/components/ui/table/table-caption";
|
|
|
9
9
|
export declare class Table extends LitElement {
|
|
10
10
|
static styles: import("lit").CSSResult[];
|
|
11
11
|
size?: "2xs" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl";
|
|
12
|
-
striped: boolean;
|
|
13
|
-
sticky: boolean;
|
|
14
12
|
bordered: boolean;
|
|
15
|
-
hover: boolean;
|
|
16
13
|
maxHeight?: string;
|
|
17
14
|
render(): import("lit-html").TemplateResult<1>;
|
|
18
15
|
}
|