@golemui/gui-lit 1.6.0-rc.1 → 2.0.0-rc.0
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/CHANGELOG.md +84 -0
- package/accordion.element-CE1gDRCy.js +84 -0
- package/alert.element-Bqcad7bR.js +43 -0
- package/{button.element-CKYv0Glr.js → button.element-CjeUWaly.js} +23 -24
- package/{calendar.element-DkHZFBNr.js → calendar.element-DXI9bfFN.js} +17 -22
- package/{checkbox.element-MukoziRw.js → checkbox.element-D8hXKLjW.js} +18 -22
- package/{currency.element-DNumeSKA.js → currency.element-D8t_MtIs.js} +22 -26
- package/{date-picker.element-DpQmremq.js → date-picker.element-X__hfSnj.js} +16 -21
- package/{date-time-calendar.element-GAr8VMGa.js → date-time-calendar.element-Dmyd7LQ0.js} +17 -21
- package/{date-time-picker.element-Bt0GYSpS.js → date-time-picker.element-QGn5dEbf.js} +23 -27
- package/{date-time.element-WfLnY_Cb.js → date-time.element-B0OuRjlf.js} +20 -25
- package/{date.element-ChpTi2AQ.js → date.element-Ba8wmaNU.js} +13 -18
- package/{dropdown.element-Ckh9JvEK.js → dropdown.element-Djee1u1L.js} +15 -29
- package/{file-upload.element-l_l_ubxJ.js → file-upload.element-B3oBEQ_s.js} +18 -23
- package/grid.element-CwDdlQ4b.js +54 -0
- package/index.js +42 -42
- package/index.umd.cjs +289 -352
- package/lib/components/accordion.element.d.ts +2 -2
- package/lib/components/alert.element.d.ts +0 -1
- package/lib/components/calendar.element.d.ts +0 -1
- package/lib/components/checkbox.element.d.ts +0 -1
- package/lib/components/currency.element.d.ts +0 -1
- package/lib/components/date-picker.element.d.ts +0 -1
- package/lib/components/date-time-calendar.element.d.ts +0 -1
- package/lib/components/date-time-picker.element.d.ts +0 -1
- package/lib/components/date-time.element.d.ts +0 -1
- package/lib/components/date.element.d.ts +0 -1
- package/lib/components/dropdown.element.d.ts +0 -1
- package/lib/components/file-upload.element.d.ts +0 -1
- package/lib/components/grid.element.d.ts +3 -3
- package/lib/components/list.element.d.ts +0 -1
- package/lib/components/markdown-text.element.d.ts +0 -1
- package/lib/components/markdown.element.d.ts +0 -1
- package/lib/components/multi-dropdown.element.d.ts +0 -1
- package/lib/components/multi-file-upload.element.d.ts +0 -1
- package/lib/components/multi-list.element.d.ts +0 -1
- package/lib/components/number.element.d.ts +0 -1
- package/lib/components/password.element.d.ts +0 -1
- package/lib/components/radiogroup.element.d.ts +0 -1
- package/lib/components/range-calendar.element.d.ts +0 -1
- package/lib/components/range-date-input.element.d.ts +0 -1
- package/lib/components/range-date-picker.element.d.ts +0 -1
- package/lib/components/range-date-time-calendar.element.d.ts +0 -1
- package/lib/components/range-date-time-input.element.d.ts +0 -1
- package/lib/components/range-date-time-picker.element.d.ts +0 -1
- package/lib/components/range-time-input.element.d.ts +0 -1
- package/lib/components/range-time-picker.element.d.ts +0 -1
- package/lib/components/renderer.element.d.ts +0 -1
- package/lib/components/repeater.element.d.ts +0 -1
- package/lib/components/select.element.d.ts +0 -1
- package/lib/components/tabs.element.d.ts +4 -15
- package/lib/components/tags.element.d.ts +0 -1
- package/lib/components/textarea.element.d.ts +0 -1
- package/lib/components/textinput.element.d.ts +0 -1
- package/lib/components/time-picker.element.d.ts +0 -1
- package/lib/components/time.element.d.ts +0 -1
- package/lib/components/toggle.element.d.ts +0 -1
- package/{list.element-UIKmXzeH.js → list.element-DfLD2X8s.js} +37 -38
- package/{markdown-text.element-DflCQwAo.js → markdown-text.element-Jos6zKYy.js} +17 -22
- package/{markdown.element-DUHHoi2Y.js → markdown.element-7tvZ028P.js} +11 -15
- package/{multi-dropdown.element-mX06nBBb.js → multi-dropdown.element-B1vV4rF-.js} +51 -65
- package/{multi-file-upload.element-DzAZAfc1.js → multi-file-upload.element-4h6JQgRF.js} +16 -21
- package/{multi-list.element-Bs-UN2Cy.js → multi-list.element-CNVHVkj0.js} +44 -45
- package/{number.element-mQSFQsYC.js → number.element-WRHwQGZz.js} +19 -23
- package/package.json +6 -6
- package/{password.element-xw5gugEg.js → password.element-DnV_PqKI.js} +17 -21
- package/{radiogroup.element-TqfrxVyI.js → radiogroup.element-Cqn_48Ao.js} +20 -24
- package/{range-calendar.element-BJr97SVA.js → range-calendar.element-V_56ZeT9.js} +13 -18
- package/{range-date-input.element-DDRYvP9h.js → range-date-input.element-D3ZG8OW-.js} +15 -20
- package/{range-date-picker.element-rdEr0_wu.js → range-date-picker.element-CaNHjueS.js} +21 -26
- package/{range-date-time-calendar.element-UlL1BBRJ.js → range-date-time-calendar.element-DyiiUB5Q.js} +19 -24
- package/{range-date-time-input.element-Cq4IdW7N.js → range-date-time-input.element-CVCPS7FC.js} +20 -25
- package/{range-date-time-picker.element-CnJcIN9C.js → range-date-time-picker.element-6nBQ_NZs.js} +16 -21
- package/{range-time-input.element-Cq0TrGe9.js → range-time-input.element-GXw45kMr.js} +12 -17
- package/{range-time-picker.element-BzlIuZ6m.js → range-time-picker.element-CG4PJg3u.js} +24 -29
- package/{renderer.element-BVwerbtL.js → renderer.element-FWOUTePl.js} +16 -21
- package/{repeater.element-DQNI4b7I.js → repeater.element-V508AKTJ.js} +8 -13
- package/{select.element-RBtbAvLx.js → select.element-BPrqKmDM.js} +17 -20
- package/tabs.element-CeZOk5Bj.js +88 -0
- package/{tags.element-CGvxhMmX.js → tags.element-CVCUsKZ0.js} +12 -17
- package/{textarea.element-E2ntRBtE.js → textarea.element-DrWG3xvs.js} +23 -27
- package/{textinput.element-0q5F5ol3.js → textinput.element-CCgsbYTB.js} +25 -29
- package/{time-picker.element-BiLaLr_c.js → time-picker.element-Q_OWcBVy.js} +21 -26
- package/{time.element-92goKRwJ.js → time.element-B0L2sriD.js} +20 -25
- package/{toggle.element-zDUc9Vja.js → toggle.element-BTjo7IVK.js} +18 -22
- package/accordion.element-BEenQrCh.js +0 -102
- package/alert.element-Dzv49O-1.js +0 -55
- package/flex.element-BW0_kx8z.js +0 -79
- package/grid.element-C019lV76.js +0 -78
- package/lib/components/flex.element.d.ts +0 -16
- package/tabs.element-BiVaQlvt.js +0 -171
|
@@ -1,27 +1,23 @@
|
|
|
1
|
-
import { InputWidgetAdapter as
|
|
1
|
+
import { InputWidgetAdapter as o, formContext as l, inputContext as u } from "@golemui/lit";
|
|
2
2
|
import "@golemui/gui-components/number";
|
|
3
3
|
import { consume as n, provide as m } from "@lit/context";
|
|
4
4
|
import { LitElement as h, html as c } from "lit";
|
|
5
5
|
import { property as b } from "lit/decorators.js";
|
|
6
6
|
import { unsubscribeAll as f, safeDefine as $ } from "@golemui/lit/internals";
|
|
7
7
|
import "rxjs";
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
import { live as D } from "lit/directives/live.js";
|
|
9
|
+
var g = Object.defineProperty, d = (r, e, a, v) => {
|
|
10
|
+
for (var t = void 0, i = r.length - 1, s; i >= 0; i--)
|
|
11
|
+
(s = r[i]) && (t = s(e, a, t) || t);
|
|
12
|
+
return t && g(e, a, t), t;
|
|
12
13
|
};
|
|
13
|
-
class
|
|
14
|
+
class p extends h {
|
|
14
15
|
constructor() {
|
|
15
|
-
super(...arguments), this.adapter = new
|
|
16
|
+
super(...arguments), this.adapter = new o(), this.subscriptions = [];
|
|
16
17
|
}
|
|
17
18
|
createRenderRoot() {
|
|
18
19
|
return this;
|
|
19
20
|
}
|
|
20
|
-
updated(e) {
|
|
21
|
-
super.updated(e);
|
|
22
|
-
const t = this.adapter.templateData.size;
|
|
23
|
-
t ? this.style.flex = String(t) : this.style.removeProperty("flex");
|
|
24
|
-
}
|
|
25
21
|
connectedCallback() {
|
|
26
22
|
super.connectedCallback(), this.classList.add("gui-number", "gui-field"), this.adapter.context = this.formContext, this.adapter.init(this.widget), this.subscriptions.push(
|
|
27
23
|
this.adapter.templateDataChanged$.subscribe(() => this.requestUpdate())
|
|
@@ -34,38 +30,38 @@ class s extends h {
|
|
|
34
30
|
.label=${this.adapter.templateData.label}
|
|
35
31
|
.hint=${this.adapter.templateData.hint}
|
|
36
32
|
.errors=${this.adapter.templateData.errors}
|
|
37
|
-
|
|
33
|
+
.touched=${this.adapter.templateData.touched}
|
|
38
34
|
?required=${this.adapter.templateData.validator?.required}
|
|
39
35
|
?disabled=${this.adapter.templateData.disabled}
|
|
40
36
|
?readonly=${this.adapter.templateData.readonly}
|
|
41
|
-
.value=${this.adapter.templateData.value}
|
|
37
|
+
.value=${D(this.adapter.templateData.value)}
|
|
42
38
|
.step=${this.adapter.templateData.step}
|
|
43
39
|
.minimum=${this.adapter.templateData.minimum}
|
|
44
40
|
.maximum=${this.adapter.templateData.maximum}
|
|
45
41
|
.autoGrow=${this.adapter.templateData.autoGrow}
|
|
46
42
|
.placeholder=${this.adapter.templateData.placeholder}
|
|
47
43
|
.autocomplete=${this.adapter.templateData.autocomplete}
|
|
48
|
-
@input=${this.valueChanged}
|
|
49
|
-
@blur=${() => this.adapter.onBlur()}
|
|
44
|
+
@gui-input=${this.valueChanged}
|
|
45
|
+
@gui-blur=${() => this.adapter.onBlur()}
|
|
50
46
|
></gui-number>
|
|
51
47
|
`;
|
|
52
48
|
}
|
|
53
49
|
valueChanged(e) {
|
|
54
|
-
const
|
|
55
|
-
this.adapter.valueChanged(
|
|
50
|
+
const a = e.detail.value;
|
|
51
|
+
this.adapter.valueChanged(a);
|
|
56
52
|
}
|
|
57
53
|
disconnectedCallback() {
|
|
58
54
|
super.disconnectedCallback(), this.adapter.destroy(), f(this.subscriptions);
|
|
59
55
|
}
|
|
60
56
|
}
|
|
61
57
|
d([
|
|
62
|
-
n({ context:
|
|
58
|
+
n({ context: l }),
|
|
63
59
|
b({ attribute: !1 })
|
|
64
|
-
],
|
|
60
|
+
], p.prototype, "formContext");
|
|
65
61
|
d([
|
|
66
62
|
m({ context: u })
|
|
67
|
-
],
|
|
68
|
-
$("gui-number-input",
|
|
63
|
+
], p.prototype, "adapter");
|
|
64
|
+
$("gui-number-input", p);
|
|
69
65
|
export {
|
|
70
|
-
|
|
66
|
+
p as NumberElement
|
|
71
67
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@golemui/gui-lit",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.0-rc.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -25,11 +25,11 @@
|
|
|
25
25
|
"*.md"
|
|
26
26
|
],
|
|
27
27
|
"peerDependencies": {
|
|
28
|
-
"@golemui/lit": "
|
|
29
|
-
"@golemui/core": "
|
|
30
|
-
"@golemui/gui-components": "
|
|
31
|
-
"@golemui/gui-shared": "
|
|
32
|
-
"@golemui/gui-validators": "
|
|
28
|
+
"@golemui/lit": "2.0.0-rc.0",
|
|
29
|
+
"@golemui/core": "2.0.0-rc.0",
|
|
30
|
+
"@golemui/gui-components": "2.0.0-rc.0",
|
|
31
|
+
"@golemui/gui-shared": "2.0.0-rc.0",
|
|
32
|
+
"@golemui/gui-validators": "2.0.0-rc.0",
|
|
33
33
|
"@lit/context": "^1.1.6",
|
|
34
34
|
"lit-html": "^3.3.1",
|
|
35
35
|
"lit": "^3.3.1",
|
|
@@ -1,44 +1,40 @@
|
|
|
1
1
|
import { InputWidgetAdapter as p, formContext as l, inputContext as n } from "@golemui/lit";
|
|
2
2
|
import "@golemui/gui-components/password";
|
|
3
3
|
import { consume as h, provide as u } from "@lit/context";
|
|
4
|
-
import { LitElement as
|
|
4
|
+
import { LitElement as m, html as c } from "lit";
|
|
5
5
|
import { property as b } from "lit/decorators.js";
|
|
6
|
-
import { unsubscribeAll as
|
|
6
|
+
import { unsubscribeAll as w, safeDefine as $ } from "@golemui/lit/internals";
|
|
7
7
|
import "rxjs";
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
import { live as f } from "lit/directives/live.js";
|
|
9
|
+
var D = Object.defineProperty, o = (r, e, a, g) => {
|
|
10
|
+
for (var t = void 0, s = r.length - 1, d; s >= 0; s--)
|
|
11
|
+
(d = r[s]) && (t = d(e, a, t) || t);
|
|
12
|
+
return t && D(e, a, t), t;
|
|
12
13
|
};
|
|
13
|
-
class i extends
|
|
14
|
+
class i extends m {
|
|
14
15
|
constructor() {
|
|
15
16
|
super(...arguments), this.adapter = new p(), this.subscriptions = [];
|
|
16
17
|
}
|
|
17
18
|
createRenderRoot() {
|
|
18
19
|
return this;
|
|
19
20
|
}
|
|
20
|
-
updated(e) {
|
|
21
|
-
super.updated(e);
|
|
22
|
-
const t = this.adapter.templateData.size;
|
|
23
|
-
t ? this.style.flex = String(t) : this.style.removeProperty("flex");
|
|
24
|
-
}
|
|
25
21
|
connectedCallback() {
|
|
26
22
|
super.connectedCallback(), this.classList.add("gui-password", "gui-field"), this.adapter.context = this.formContext, this.adapter.init(this.widget), this.subscriptions.push(
|
|
27
23
|
this.adapter.templateDataChanged$.subscribe(() => this.requestUpdate())
|
|
28
24
|
);
|
|
29
25
|
}
|
|
30
26
|
render() {
|
|
31
|
-
return super.render(),
|
|
27
|
+
return super.render(), c`
|
|
32
28
|
<gui-password
|
|
33
29
|
.uid=${this.widget.uid}
|
|
34
30
|
.label=${this.adapter.templateData.label}
|
|
35
31
|
.hint=${this.adapter.templateData.hint}
|
|
36
32
|
.errors=${this.adapter.templateData.errors}
|
|
37
|
-
|
|
33
|
+
.touched=${this.adapter.templateData.touched}
|
|
38
34
|
?required=${this.adapter.templateData.validator?.required}
|
|
39
35
|
?disabled=${this.adapter.templateData.disabled}
|
|
40
36
|
?readonly=${this.adapter.templateData.readonly}
|
|
41
|
-
.value=${this.adapter.templateData.value}
|
|
37
|
+
.value=${f(this.adapter.templateData.value)}
|
|
42
38
|
.icon=${this.adapter.templateData.icon}
|
|
43
39
|
.placeholder=${this.adapter.templateData.placeholder}
|
|
44
40
|
.autocomplete=${this.adapter.templateData.autocomplete}
|
|
@@ -46,17 +42,17 @@ class i extends c {
|
|
|
46
42
|
.hidePasswordIcon=${this.adapter.templateData.hidePasswordIcon}
|
|
47
43
|
.showPasswordLabel=${this.adapter.templateData.showPasswordLabel}
|
|
48
44
|
.hidePasswordLabel=${this.adapter.templateData.hidePasswordLabel}
|
|
49
|
-
@input=${this.valueChanged}
|
|
50
|
-
@blur=${() => this.adapter.onBlur()}
|
|
45
|
+
@gui-input=${this.valueChanged}
|
|
46
|
+
@gui-blur=${() => this.adapter.onBlur()}
|
|
51
47
|
></gui-password>
|
|
52
48
|
`;
|
|
53
49
|
}
|
|
54
50
|
valueChanged(e) {
|
|
55
|
-
const
|
|
56
|
-
this.adapter.valueChanged(
|
|
51
|
+
const a = e.detail.value;
|
|
52
|
+
this.adapter.valueChanged(a);
|
|
57
53
|
}
|
|
58
54
|
disconnectedCallback() {
|
|
59
|
-
super.disconnectedCallback(), this.adapter.destroy(),
|
|
55
|
+
super.disconnectedCallback(), this.adapter.destroy(), w(this.subscriptions);
|
|
60
56
|
}
|
|
61
57
|
}
|
|
62
58
|
o([
|
|
@@ -66,7 +62,7 @@ o([
|
|
|
66
62
|
o([
|
|
67
63
|
u({ context: n })
|
|
68
64
|
], i.prototype, "adapter");
|
|
69
|
-
|
|
65
|
+
$("gui-password-input", i);
|
|
70
66
|
export {
|
|
71
67
|
i as PasswordElement
|
|
72
68
|
};
|
|
@@ -3,25 +3,21 @@ import "@golemui/gui-components/radiogroup";
|
|
|
3
3
|
import { consume as u, provide as h } from "@lit/context";
|
|
4
4
|
import { LitElement as m, html as c } from "lit";
|
|
5
5
|
import { property as b } from "lit/decorators.js";
|
|
6
|
-
import { unsubscribeAll as
|
|
6
|
+
import { unsubscribeAll as g, safeDefine as f } from "@golemui/lit/internals";
|
|
7
7
|
import "rxjs";
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
import { live as v } from "lit/directives/live.js";
|
|
9
|
+
var $ = Object.defineProperty, s = (r, e, a, D) => {
|
|
10
|
+
for (var t = void 0, i = r.length - 1, p; i >= 0; i--)
|
|
11
|
+
(p = r[i]) && (t = p(e, a, t) || t);
|
|
12
|
+
return t && $(e, a, t), t;
|
|
12
13
|
};
|
|
13
|
-
class
|
|
14
|
+
class d extends m {
|
|
14
15
|
constructor() {
|
|
15
16
|
super(...arguments), this.adapter = new o(), this.subscriptions = [];
|
|
16
17
|
}
|
|
17
18
|
createRenderRoot() {
|
|
18
19
|
return this;
|
|
19
20
|
}
|
|
20
|
-
updated(e) {
|
|
21
|
-
super.updated(e);
|
|
22
|
-
const t = this.adapter.templateData.size;
|
|
23
|
-
t ? this.style.flex = String(t) : this.style.removeProperty("flex");
|
|
24
|
-
}
|
|
25
21
|
connectedCallback() {
|
|
26
22
|
super.connectedCallback(), this.classList.add("gui-radiogroup", "gui-field"), this.adapter.context = this.formContext, this.adapter.init(this.widget), this.subscriptions.push(
|
|
27
23
|
this.adapter.templateDataChanged$.subscribe(() => this.requestUpdate())
|
|
@@ -33,37 +29,37 @@ class s extends m {
|
|
|
33
29
|
.uid=${this.widget.uid}
|
|
34
30
|
.label=${this.adapter.templateData.label}
|
|
35
31
|
.errors=${this.adapter.templateData.errors}
|
|
36
|
-
|
|
32
|
+
.touched=${this.adapter.templateData.touched}
|
|
37
33
|
?required=${this.adapter.templateData.validator?.required}
|
|
38
34
|
?disabled=${this.adapter.templateData.disabled}
|
|
39
35
|
?readonly=${this.adapter.templateData.readonly}
|
|
40
|
-
.value=${this.adapter.templateData.value}
|
|
36
|
+
.value=${v(this.adapter.templateData.value)}
|
|
41
37
|
.hint=${this.adapter.templateData.hint}
|
|
42
38
|
.options=${this.adapter.templateData.options}
|
|
43
39
|
.labelField=${this.adapter.templateData.labelField}
|
|
44
40
|
.valueField=${this.adapter.templateData.valueField}
|
|
45
41
|
.direction=${this.adapter.templateData.direction}
|
|
46
|
-
@
|
|
47
|
-
@blur=${() => this.adapter.onBlur()}
|
|
42
|
+
@gui-input=${this.valueChanged}
|
|
43
|
+
@gui-blur=${() => this.adapter.onBlur()}
|
|
48
44
|
></gui-radiogroup>
|
|
49
45
|
`;
|
|
50
46
|
}
|
|
51
47
|
valueChanged(e) {
|
|
52
|
-
const
|
|
53
|
-
this.adapter.valueChanged(
|
|
48
|
+
const a = e.detail.value;
|
|
49
|
+
this.adapter.valueChanged(a);
|
|
54
50
|
}
|
|
55
51
|
disconnectedCallback() {
|
|
56
|
-
super.disconnectedCallback(), this.adapter.destroy(),
|
|
52
|
+
super.disconnectedCallback(), this.adapter.destroy(), g(this.subscriptions);
|
|
57
53
|
}
|
|
58
54
|
}
|
|
59
|
-
|
|
55
|
+
s([
|
|
60
56
|
u({ context: l }),
|
|
61
57
|
b({ attribute: !1 })
|
|
62
|
-
],
|
|
63
|
-
|
|
58
|
+
], d.prototype, "formContext");
|
|
59
|
+
s([
|
|
64
60
|
h({ context: n })
|
|
65
|
-
],
|
|
66
|
-
|
|
61
|
+
], d.prototype, "adapter");
|
|
62
|
+
f("gui-radiogroup-input", d);
|
|
67
63
|
export {
|
|
68
|
-
|
|
64
|
+
d as RadiogroupElement
|
|
69
65
|
};
|
|
@@ -5,23 +5,18 @@ import { LitElement as u, html as c } from "lit";
|
|
|
5
5
|
import { property as b } from "lit/decorators.js";
|
|
6
6
|
import { unsubscribeAll as D, safeDefine as $ } from "@golemui/lit/internals";
|
|
7
7
|
import "rxjs";
|
|
8
|
-
var g = Object.defineProperty, l = (
|
|
9
|
-
for (var a = void 0,
|
|
10
|
-
(
|
|
11
|
-
return a && g(t,
|
|
8
|
+
var g = Object.defineProperty, l = (e, t, d, f) => {
|
|
9
|
+
for (var a = void 0, r = e.length - 1, s; r >= 0; r--)
|
|
10
|
+
(s = e[r]) && (a = s(t, d, a) || a);
|
|
11
|
+
return a && g(t, d, a), a;
|
|
12
12
|
};
|
|
13
|
-
class
|
|
13
|
+
class i extends u {
|
|
14
14
|
constructor() {
|
|
15
15
|
super(...arguments), this.adapter = new p(), this.subscriptions = [];
|
|
16
16
|
}
|
|
17
17
|
createRenderRoot() {
|
|
18
18
|
return this;
|
|
19
19
|
}
|
|
20
|
-
updated(t) {
|
|
21
|
-
super.updated(t);
|
|
22
|
-
const e = this.adapter.templateData.size;
|
|
23
|
-
e ? this.style.flex = String(e) : this.style.removeProperty("flex");
|
|
24
|
-
}
|
|
25
20
|
connectedCallback() {
|
|
26
21
|
super.connectedCallback(), this.classList.add("gui-calendar", "gui-field"), this.adapter.context = this.formContext, this.adapter.init(this.widget), this.subscriptions.push(
|
|
27
22
|
this.adapter.templateDataChanged$.subscribe(() => this.requestUpdate())
|
|
@@ -34,7 +29,7 @@ class s extends u {
|
|
|
34
29
|
.label=${this.adapter.templateData.label}
|
|
35
30
|
.hint=${this.adapter.templateData.hint}
|
|
36
31
|
.errors=${this.adapter.templateData.errors}
|
|
37
|
-
|
|
32
|
+
.touched=${this.adapter.templateData.touched}
|
|
38
33
|
?required=${this.adapter.templateData.validator?.required}
|
|
39
34
|
?disabled=${this.adapter.templateData.disabled}
|
|
40
35
|
?readonly=${this.adapter.templateData.readonly}
|
|
@@ -64,9 +59,9 @@ class s extends u {
|
|
|
64
59
|
.editCommittedMessage=${this.adapter.templateData.editCommittedMessage}
|
|
65
60
|
.editCancelledMessage=${this.adapter.templateData.editCancelledMessage}
|
|
66
61
|
.localeId=${this.adapter.templateData.lang}
|
|
67
|
-
@
|
|
68
|
-
@
|
|
69
|
-
@blur=${() => this.adapter.onBlur()}
|
|
62
|
+
@gui-input=${this.valueChanged}
|
|
63
|
+
@gui-input-error=${this.onInputError}
|
|
64
|
+
@gui-blur=${() => this.adapter.onBlur()}
|
|
70
65
|
></gui-range-calendar>
|
|
71
66
|
`;
|
|
72
67
|
}
|
|
@@ -83,11 +78,11 @@ class s extends u {
|
|
|
83
78
|
l([
|
|
84
79
|
h({ context: n }),
|
|
85
80
|
b({ attribute: !1 })
|
|
86
|
-
],
|
|
81
|
+
], i.prototype, "formContext");
|
|
87
82
|
l([
|
|
88
83
|
m({ context: o })
|
|
89
|
-
],
|
|
90
|
-
$("gui-range-calendar-input",
|
|
84
|
+
], i.prototype, "adapter");
|
|
85
|
+
$("gui-range-calendar-input", i);
|
|
91
86
|
export {
|
|
92
|
-
|
|
87
|
+
i as RangeCalendarElement
|
|
93
88
|
};
|
|
@@ -1,27 +1,22 @@
|
|
|
1
1
|
import { InputWidgetAdapter as p, formContext as n, inputContext as o } from "@golemui/lit";
|
|
2
2
|
import "@golemui/gui-components/range-date-input";
|
|
3
|
-
import { consume as
|
|
3
|
+
import { consume as m, provide as h } from "@lit/context";
|
|
4
4
|
import { LitElement as u, html as c } from "lit";
|
|
5
5
|
import { property as b } from "lit/decorators.js";
|
|
6
6
|
import { unsubscribeAll as D, safeDefine as g } from "@golemui/lit/internals";
|
|
7
7
|
import "rxjs";
|
|
8
|
-
var $ = Object.defineProperty, l = (
|
|
9
|
-
for (var
|
|
10
|
-
(d = i
|
|
11
|
-
return
|
|
8
|
+
var $ = Object.defineProperty, l = (e, t, s, L) => {
|
|
9
|
+
for (var a = void 0, i = e.length - 1, d; i >= 0; i--)
|
|
10
|
+
(d = e[i]) && (a = d(t, s, a) || a);
|
|
11
|
+
return a && $(t, s, a), a;
|
|
12
12
|
};
|
|
13
|
-
class
|
|
13
|
+
class r extends u {
|
|
14
14
|
constructor() {
|
|
15
15
|
super(...arguments), this.adapter = new p(), this.subscriptions = [];
|
|
16
16
|
}
|
|
17
17
|
createRenderRoot() {
|
|
18
18
|
return this;
|
|
19
19
|
}
|
|
20
|
-
updated(t) {
|
|
21
|
-
super.updated(t);
|
|
22
|
-
const a = this.adapter.templateData.size;
|
|
23
|
-
a ? this.style.flex = String(a) : this.style.removeProperty("flex");
|
|
24
|
-
}
|
|
25
20
|
connectedCallback() {
|
|
26
21
|
super.connectedCallback(), this.classList.add("gui-range-date", "gui-field"), this.adapter.context = this.formContext, this.adapter.init(this.widget), this.subscriptions.push(
|
|
27
22
|
this.adapter.templateDataChanged$.subscribe(() => this.requestUpdate())
|
|
@@ -35,7 +30,7 @@ class s extends u {
|
|
|
35
30
|
.hint=${this.adapter.templateData.hint}
|
|
36
31
|
.icon=${this.adapter.templateData.icon}
|
|
37
32
|
.errors=${this.adapter.templateData.errors}
|
|
38
|
-
|
|
33
|
+
.touched=${this.adapter.templateData.touched}
|
|
39
34
|
?required=${this.adapter.templateData.validator?.required}
|
|
40
35
|
?disabled=${this.adapter.templateData.disabled}
|
|
41
36
|
?readonly=${this.adapter.templateData.readonly}
|
|
@@ -58,8 +53,8 @@ class s extends u {
|
|
|
58
53
|
.removePillAriaLabel=${this.adapter.templateData.removePillAriaLabel}
|
|
59
54
|
.startDateAriaLabel=${this.adapter.templateData.startDateAriaLabel}
|
|
60
55
|
.endDateAriaLabel=${this.adapter.templateData.endDateAriaLabel}
|
|
61
|
-
@
|
|
62
|
-
@
|
|
56
|
+
@gui-input=${this.valueChanged}
|
|
57
|
+
@gui-input-error=${this.onInputError}
|
|
63
58
|
></gui-range-date>
|
|
64
59
|
`;
|
|
65
60
|
}
|
|
@@ -74,13 +69,13 @@ class s extends u {
|
|
|
74
69
|
}
|
|
75
70
|
}
|
|
76
71
|
l([
|
|
77
|
-
|
|
72
|
+
m({ context: n }),
|
|
78
73
|
b({ attribute: !1 })
|
|
79
|
-
],
|
|
74
|
+
], r.prototype, "formContext");
|
|
80
75
|
l([
|
|
81
|
-
|
|
82
|
-
],
|
|
83
|
-
g("gui-range-date-input",
|
|
76
|
+
h({ context: o })
|
|
77
|
+
], r.prototype, "adapter");
|
|
78
|
+
g("gui-range-date-input", r);
|
|
84
79
|
export {
|
|
85
|
-
|
|
80
|
+
r as RangeDateInputElement
|
|
86
81
|
};
|
|
@@ -1,27 +1,22 @@
|
|
|
1
1
|
import { InputWidgetAdapter as d, formContext as o, inputContext as p } from "@golemui/lit";
|
|
2
2
|
import "@golemui/gui-components/range-date-picker";
|
|
3
|
-
import { consume as c, provide as
|
|
4
|
-
import { LitElement as b, html as
|
|
5
|
-
import { property as
|
|
6
|
-
import { unsubscribeAll as
|
|
3
|
+
import { consume as c, provide as u } from "@lit/context";
|
|
4
|
+
import { LitElement as b, html as m } from "lit";
|
|
5
|
+
import { property as $ } from "lit/decorators.js";
|
|
6
|
+
import { unsubscribeAll as g, safeDefine as h } from "@golemui/lit/internals";
|
|
7
7
|
import "rxjs";
|
|
8
|
-
var L = Object.defineProperty, l = (
|
|
9
|
-
for (var a = void 0,
|
|
10
|
-
(n = r
|
|
11
|
-
return a && L(e,
|
|
8
|
+
var L = Object.defineProperty, l = (t, e, s, A) => {
|
|
9
|
+
for (var a = void 0, r = t.length - 1, n; r >= 0; r--)
|
|
10
|
+
(n = t[r]) && (a = n(e, s, a) || a);
|
|
11
|
+
return a && L(e, s, a), a;
|
|
12
12
|
};
|
|
13
|
-
class
|
|
13
|
+
class i extends b {
|
|
14
14
|
constructor() {
|
|
15
15
|
super(...arguments), this.adapter = new d(), this.subscriptions = [];
|
|
16
16
|
}
|
|
17
17
|
createRenderRoot() {
|
|
18
18
|
return this;
|
|
19
19
|
}
|
|
20
|
-
updated(e) {
|
|
21
|
-
super.updated(e);
|
|
22
|
-
const t = this.adapter.templateData.size;
|
|
23
|
-
t ? this.style.flex = String(t) : this.style.removeProperty("flex");
|
|
24
|
-
}
|
|
25
20
|
connectedCallback() {
|
|
26
21
|
super.connectedCallback(), this.classList.add("gui-range-date-picker", "gui-field"), this.adapter.context = this.formContext, this.adapter.init(this.widget), this.subscriptions.push(
|
|
27
22
|
this.adapter.templateDataChanged$.subscribe(() => this.requestUpdate())
|
|
@@ -30,13 +25,13 @@ class s extends b {
|
|
|
30
25
|
render() {
|
|
31
26
|
super.render();
|
|
32
27
|
const e = this.adapter.templateData;
|
|
33
|
-
return
|
|
28
|
+
return m`
|
|
34
29
|
<gui-range-date-picker
|
|
35
30
|
.uid=${this.widget.uid}
|
|
36
31
|
.label=${e.label}
|
|
37
32
|
.hint=${e.hint}
|
|
38
33
|
.errors=${e.errors}
|
|
39
|
-
|
|
34
|
+
.touched=${e.touched}
|
|
40
35
|
?required=${e.validator?.required}
|
|
41
36
|
?disabled=${e.disabled}
|
|
42
37
|
?readonly=${e.readonly}
|
|
@@ -77,9 +72,9 @@ class s extends b {
|
|
|
77
72
|
.editStartedMessage=${e.editStartedMessage}
|
|
78
73
|
.editCommittedMessage=${e.editCommittedMessage}
|
|
79
74
|
.editCancelledMessage=${e.editCancelledMessage}
|
|
80
|
-
@
|
|
81
|
-
@blur=${() => this.adapter.onBlur()}
|
|
82
|
-
@
|
|
75
|
+
@gui-input-error=${this.onInputError}
|
|
76
|
+
@gui-blur=${() => this.adapter.onBlur()}
|
|
77
|
+
@gui-input=${this.valueChanged}
|
|
83
78
|
></gui-range-date-picker>
|
|
84
79
|
`;
|
|
85
80
|
}
|
|
@@ -90,17 +85,17 @@ class s extends b {
|
|
|
90
85
|
this.adapter.injectValidationIssues([e.detail.message]), this.adapter.onBlur();
|
|
91
86
|
}
|
|
92
87
|
disconnectedCallback() {
|
|
93
|
-
super.disconnectedCallback(), this.adapter.destroy(),
|
|
88
|
+
super.disconnectedCallback(), this.adapter.destroy(), g(this.subscriptions);
|
|
94
89
|
}
|
|
95
90
|
}
|
|
96
91
|
l([
|
|
97
92
|
c({ context: o }),
|
|
98
|
-
|
|
99
|
-
],
|
|
93
|
+
$({ attribute: !1 })
|
|
94
|
+
], i.prototype, "formContext");
|
|
100
95
|
l([
|
|
101
|
-
|
|
102
|
-
],
|
|
103
|
-
|
|
96
|
+
u({ context: p })
|
|
97
|
+
], i.prototype, "adapter");
|
|
98
|
+
h("gui-range-date-picker-input", i);
|
|
104
99
|
export {
|
|
105
|
-
|
|
100
|
+
i as RangeDatePickerElement
|
|
106
101
|
};
|
|
@@ -1,27 +1,22 @@
|
|
|
1
1
|
import { InputWidgetAdapter as d, formContext as o, inputContext as m } from "@golemui/lit";
|
|
2
2
|
import "@golemui/gui-components/range-date-time-calendar";
|
|
3
3
|
import { consume as u, provide as p } from "@lit/context";
|
|
4
|
-
import { LitElement as
|
|
5
|
-
import { property as
|
|
6
|
-
import { unsubscribeAll as
|
|
4
|
+
import { LitElement as b, html as c } from "lit";
|
|
5
|
+
import { property as $ } from "lit/decorators.js";
|
|
6
|
+
import { unsubscribeAll as h, safeDefine as g } from "@golemui/lit/internals";
|
|
7
7
|
import "rxjs";
|
|
8
|
-
var L = Object.defineProperty, l = (
|
|
9
|
-
for (var a = void 0,
|
|
10
|
-
(
|
|
11
|
-
return a && L(e,
|
|
8
|
+
var L = Object.defineProperty, l = (t, e, n, M) => {
|
|
9
|
+
for (var a = void 0, i = t.length - 1, s; i >= 0; i--)
|
|
10
|
+
(s = t[i]) && (a = s(e, n, a) || a);
|
|
11
|
+
return a && L(e, n, a), a;
|
|
12
12
|
};
|
|
13
|
-
class
|
|
13
|
+
class r extends b {
|
|
14
14
|
constructor() {
|
|
15
15
|
super(...arguments), this.adapter = new d(), this.subscriptions = [];
|
|
16
16
|
}
|
|
17
17
|
createRenderRoot() {
|
|
18
18
|
return this;
|
|
19
19
|
}
|
|
20
|
-
updated(e) {
|
|
21
|
-
super.updated(e);
|
|
22
|
-
const t = this.adapter.templateData.size;
|
|
23
|
-
t ? this.style.flex = String(t) : this.style.removeProperty("flex");
|
|
24
|
-
}
|
|
25
20
|
connectedCallback() {
|
|
26
21
|
super.connectedCallback(), this.classList.add("gui-range-date-time-calendar", "gui-field"), this.adapter.context = this.formContext, this.adapter.init(this.widget), this.subscriptions.push(
|
|
27
22
|
this.adapter.templateDataChanged$.subscribe(() => this.requestUpdate())
|
|
@@ -30,13 +25,13 @@ class s extends c {
|
|
|
30
25
|
render() {
|
|
31
26
|
super.render();
|
|
32
27
|
const e = this.adapter.templateData;
|
|
33
|
-
return
|
|
28
|
+
return c`
|
|
34
29
|
<gui-range-date-time-calendar
|
|
35
30
|
.uid=${this.widget.uid}
|
|
36
31
|
.label=${e.label}
|
|
37
32
|
.hint=${e.hint}
|
|
38
33
|
.errors=${e.errors}
|
|
39
|
-
|
|
34
|
+
.touched=${e.touched}
|
|
40
35
|
?required=${e.validator?.required}
|
|
41
36
|
?disabled=${e.disabled}
|
|
42
37
|
?readonly=${e.readonly}
|
|
@@ -76,9 +71,9 @@ class s extends c {
|
|
|
76
71
|
.editStartedMessage=${e.editStartedMessage}
|
|
77
72
|
.editCommittedMessage=${e.editCommittedMessage}
|
|
78
73
|
.editCancelledMessage=${e.editCancelledMessage}
|
|
79
|
-
@
|
|
80
|
-
@
|
|
81
|
-
@blur=${() => this.adapter.onBlur()}
|
|
74
|
+
@gui-input=${this.valueChanged}
|
|
75
|
+
@gui-input-error=${this.onInputError}
|
|
76
|
+
@gui-blur=${() => this.adapter.onBlur()}
|
|
82
77
|
></gui-range-date-time-calendar>
|
|
83
78
|
`;
|
|
84
79
|
}
|
|
@@ -89,17 +84,17 @@ class s extends c {
|
|
|
89
84
|
this.adapter.injectValidationIssues([e.detail.message]), this.adapter.onBlur();
|
|
90
85
|
}
|
|
91
86
|
disconnectedCallback() {
|
|
92
|
-
super.disconnectedCallback(), this.adapter.destroy(),
|
|
87
|
+
super.disconnectedCallback(), this.adapter.destroy(), h(this.subscriptions);
|
|
93
88
|
}
|
|
94
89
|
}
|
|
95
90
|
l([
|
|
96
91
|
u({ context: o }),
|
|
97
|
-
|
|
98
|
-
],
|
|
92
|
+
$({ attribute: !1 })
|
|
93
|
+
], r.prototype, "formContext");
|
|
99
94
|
l([
|
|
100
95
|
p({ context: m })
|
|
101
|
-
],
|
|
102
|
-
g("gui-range-date-time-calendar-input",
|
|
96
|
+
], r.prototype, "adapter");
|
|
97
|
+
g("gui-range-date-time-calendar-input", r);
|
|
103
98
|
export {
|
|
104
|
-
|
|
99
|
+
r as RangeDateTimeCalendarElement
|
|
105
100
|
};
|