@statistikzh/leu 0.6.0 → 0.7.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 +14 -0
- package/dist/Accordion.d.ts +1 -1
- package/dist/Accordion.js +1 -1
- package/dist/Breadcrumb.d.ts +1 -1
- package/dist/Breadcrumb.d.ts.map +1 -1
- package/dist/Breadcrumb.js +3 -1
- package/dist/{Button-9692e403.d.ts → Button-7370f901.d.ts} +2 -2
- package/dist/Button-7370f901.d.ts.map +1 -0
- package/dist/{Button-9692e403.js → Button-7370f901.js} +1 -1
- package/dist/Button.d.ts +1 -1
- package/dist/Button.js +2 -2
- package/dist/ButtonGroup.d.ts +1 -1
- package/dist/ButtonGroup.d.ts.map +1 -1
- package/dist/ButtonGroup.js +1 -1
- package/dist/Checkbox.d.ts +1 -1
- package/dist/Checkbox.d.ts.map +1 -1
- package/dist/Checkbox.js +3 -1
- package/dist/CheckboxGroup.d.ts +1 -1
- package/dist/CheckboxGroup.d.ts.map +1 -1
- package/dist/CheckboxGroup.js +3 -1
- package/dist/Chip.d.ts +1 -1
- package/dist/Chip.d.ts.map +1 -1
- package/dist/Chip.js +19 -17
- package/dist/ChipGroup.d.ts +8 -2
- package/dist/ChipGroup.d.ts.map +1 -1
- package/dist/ChipGroup.js +32 -5
- package/dist/ChipLink.js +1 -1
- package/dist/ChipRemovable.js +1 -1
- package/dist/ChipSelectable.d.ts +3 -1
- package/dist/ChipSelectable.d.ts.map +1 -1
- package/dist/ChipSelectable.js +13 -11
- package/dist/Dropdown.d.ts +1 -1
- package/dist/Dropdown.d.ts.map +1 -1
- package/dist/Dropdown.js +2 -2
- package/dist/Icon.d.ts +98 -2
- package/dist/Icon.d.ts.map +1 -1
- package/dist/Icon.js +1 -1
- package/dist/Input.d.ts +7 -2
- package/dist/Input.d.ts.map +1 -1
- package/dist/Input.js +16 -3
- package/dist/{LeuElement-6de6f209.d.ts → LeuElement-ba5ea33d.d.ts} +2 -2
- package/dist/LeuElement-ba5ea33d.d.ts.map +1 -0
- package/dist/LeuElement-ba5ea33d.js +49 -0
- package/dist/Menu.d.ts +2 -2
- package/dist/Menu.js +1 -1
- package/dist/MenuItem.d.ts +2 -2
- package/dist/MenuItem.js +1 -1
- package/dist/Pagination.d.ts +1 -1
- package/dist/Pagination.js +2 -2
- package/dist/Popup.d.ts +1 -1
- package/dist/Popup.d.ts.map +1 -1
- package/dist/Popup.js +3 -1
- package/dist/Radio.d.ts +1 -1
- package/dist/Radio.d.ts.map +1 -1
- package/dist/Radio.js +3 -1
- package/dist/RadioGroup.d.ts +1 -1
- package/dist/RadioGroup.d.ts.map +1 -1
- package/dist/RadioGroup.js +19 -8
- package/dist/ScrollTop.d.ts +1 -1
- package/dist/ScrollTop.js +2 -2
- package/dist/Select.d.ts +1 -1
- package/dist/Select.d.ts.map +1 -1
- package/dist/Select.js +4 -2
- package/dist/Table.d.ts +1 -1
- package/dist/Table.d.ts.map +1 -1
- package/dist/Table.js +4 -3
- package/dist/VisuallyHidden.d.ts +1 -1
- package/dist/VisuallyHidden.d.ts.map +1 -1
- package/dist/VisuallyHidden.js +5 -3
- package/dist/index.d.ts +2 -2
- package/dist/index.js +3 -3
- package/dist/leu-accordion.js +1 -1
- package/dist/leu-breadcrumb.js +1 -1
- package/dist/leu-button-group.js +1 -1
- package/dist/leu-button.d.ts +1 -1
- package/dist/leu-button.js +2 -2
- package/dist/leu-checkbox-group.js +1 -1
- package/dist/leu-checkbox.js +1 -1
- package/dist/leu-chip-group.js +1 -1
- package/dist/leu-chip-link.js +1 -1
- package/dist/leu-chip-removable.js +1 -1
- package/dist/leu-chip-selectable.js +1 -1
- package/dist/leu-dropdown.js +2 -2
- package/dist/leu-icon.js +1 -1
- package/dist/leu-input.js +1 -1
- package/dist/leu-menu-item.js +1 -1
- package/dist/leu-menu.js +1 -1
- package/dist/leu-pagination.js +2 -2
- package/dist/leu-popup.js +1 -1
- package/dist/leu-radio-group.js +1 -1
- package/dist/leu-radio.js +1 -1
- package/dist/leu-scroll-top.js +2 -2
- package/dist/leu-select.js +2 -2
- package/dist/leu-table.js +2 -2
- package/dist/leu-visually-hidden.js +1 -1
- package/dist/vscode.html-custom-data.json +18 -5
- package/dist/vue/index.d.ts +21 -9
- package/dist/web-types.json +211 -232
- package/package.json +3 -3
- package/src/components/chip/ChipGroup.js +28 -4
- package/src/components/chip/ChipSelectable.js +12 -10
- package/src/components/chip/chip.css +16 -16
- package/src/components/chip/stories/chip-group.stories.js +6 -9
- package/src/components/chip/stories/chip-selectable.stories.js +1 -1
- package/src/components/chip/test/chip-group.test.js +67 -0
- package/src/components/chip/test/chip-selectable.test.js +7 -7
- package/src/components/input/Input.js +14 -1
- package/src/components/input/stories/input.stories.js +3 -3
- package/src/components/input/test/input.test.js +20 -0
- package/src/components/radio/RadioGroup.js +12 -9
- package/dist/Button-9692e403.d.ts.map +0 -1
- package/dist/LeuElement-6de6f209.d.ts.map +0 -1
- package/dist/LeuElement-6de6f209.js +0 -43
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.7.0](https://github.com/statistikZH/leu/compare/v0.6.0...v0.7.0) (2024-07-08)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* **chip-group:** implement value setter ([dd1557a](https://github.com/statistikZH/leu/commit/dd1557ab1063ec7421a74057c489529b26e6d805))
|
|
9
|
+
* **input:** add inputAsNumber getter that matches the native inputs method with the same name ([552f1ff](https://github.com/statistikZH/leu/commit/552f1ff18680c6a2866c7813fe40c462ea834802))
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
### Bug Fixes
|
|
13
|
+
|
|
14
|
+
* **chip-group:** handle the chip children during the event capture phase ([552f1ff](https://github.com/statistikZH/leu/commit/552f1ff18680c6a2866c7813fe40c462ea834802))
|
|
15
|
+
* **radio-group:** handle the radio children during the event capture phase ([552f1ff](https://github.com/statistikZH/leu/commit/552f1ff18680c6a2866c7813fe40c462ea834802))
|
|
16
|
+
|
|
3
17
|
## [0.6.0](https://github.com/statistikZH/leu/compare/v0.5.1...v0.6.0) (2024-07-01)
|
|
4
18
|
|
|
5
19
|
|
package/dist/Accordion.d.ts
CHANGED
|
@@ -28,5 +28,5 @@ export class LeuAccordion extends LeuElement {
|
|
|
28
28
|
_handleToggleClick(): void;
|
|
29
29
|
render(): import("lit-html").TemplateResult;
|
|
30
30
|
}
|
|
31
|
-
import { L as LeuElement } from './LeuElement-
|
|
31
|
+
import { L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
32
32
|
//# sourceMappingURL=Accordion.d.ts.map
|
package/dist/Accordion.js
CHANGED
package/dist/Breadcrumb.d.ts
CHANGED
|
@@ -64,6 +64,6 @@ export class LeuBreadcrumb extends LeuElement {
|
|
|
64
64
|
renderDropdown(): import("lit-html").TemplateResult<1> | typeof nothing;
|
|
65
65
|
render(): import("lit-html").TemplateResult<1> | typeof nothing;
|
|
66
66
|
}
|
|
67
|
-
import { L as LeuElement } from './LeuElement-
|
|
67
|
+
import { L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
68
68
|
import { nothing } from 'lit';
|
|
69
69
|
//# sourceMappingURL=Breadcrumb.d.ts.map
|
package/dist/Breadcrumb.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Breadcrumb.d.ts","sourceRoot":"","sources":["Breadcrumb.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Breadcrumb.d.ts","sourceRoot":"","sources":["Breadcrumb.js"],"names":[],"mappings":"AAyHA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH;IAOM,yBAA+C;IAO7C,uBAAyB;IACzB,0BAA6B;IAY7B,qBAAqB;IASvB,yBAA4C;IAW9C,aAAe;IACf,wDAAwD;IACxD,UADW,OAAO,CACG;IAErB,gBAAgB;IAChB,iEAAgC;IAehC,+BAEQ;IAEV,qBAEC;IACD,+CAOC;IAOD,gBAAgB;IAChB,sBAEC;IAED,gBAAgB;IAChB,4BAEC;IACD;;;;;OAKG;IACH,eAFa,IAAI,CA4BhB;IACD;;;OAGG;IACH,wEAqCC;IACD,gEAmCC;CACF;gCA3WqD,0BAA0B;wBAC7C,KAAK"}
|
package/dist/Breadcrumb.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as _defineProperty, L as LeuElement } from './LeuElement-
|
|
1
|
+
import { _ as _defineProperty, L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
2
2
|
import { css, nothing, html } from 'lit';
|
|
3
3
|
import { createRef, ref } from 'lit/directives/ref.js';
|
|
4
4
|
import { classMap } from 'lit/directives/class-map.js';
|
|
@@ -20,6 +20,8 @@ var css_248z = css`:host,
|
|
|
20
20
|
--breadcrumb-font-regular: var(--leu-font-family-regular);
|
|
21
21
|
--breadcrumb-font-black: var(--leu-font-family-black);
|
|
22
22
|
|
|
23
|
+
font-family: var(--leu-font-family-regular);
|
|
24
|
+
|
|
23
25
|
font-family: var(--breadcrumb-font-regular);
|
|
24
26
|
line-height: 1.5;
|
|
25
27
|
color: var(--leu-color-black-100);
|
|
@@ -77,7 +77,7 @@ declare class LeuButton extends LeuElement {
|
|
|
77
77
|
declare const BUTTON_SIZES: string[];
|
|
78
78
|
declare const BUTTON_TYPES: string[];
|
|
79
79
|
declare const BUTTON_EXPANDED_OPTIONS: string[];
|
|
80
|
-
import { L as LeuElement } from './LeuElement-
|
|
80
|
+
import { L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
81
81
|
import { nothing } from 'lit';
|
|
82
82
|
export { BUTTON_VARIANTS as B, HasSlotController as H, LeuButton as L, BUTTON_SIZES as a, BUTTON_TYPES as b, BUTTON_EXPANDED_OPTIONS as c };
|
|
83
|
-
//# sourceMappingURL=Button-
|
|
83
|
+
//# sourceMappingURL=Button-7370f901.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Button-7370f901.d.ts","sourceRoot":"","sources":["Button-7370f901.js"],"names":[],"mappings":";;;iCAaa,OAAO,KAAK,EAAE,kBAAkB;AAyW7C,wCAA0D;AAhX1D;;;GAGG;AAEH;;;;GAIG;AACH;IACE,uCAcC;IAHC,UAAgB;IAEhB,eAA0B;IAG5B;;;OAGG;IACH,uBAeC;IAED;;;;OAIG;IACH,qBAEC;IAED;;;OAGG;IACH,gCAEC;IACD,sBAEC;IACD,yBAEC;CACF;AAmTD;;;;;GAKG;AACH;IAQI,WAAiB;IACjB,qBAAqB;IACrB,MADW,MAAM,CACI;IACrB,qBAAqB;IACrB,SADW,MAAM,CACO;IACxB,4CAA4C;IAC5C,MADW,QAAQ,GAAG,QAAQ,GAAG,OAAO,CACpB;IAEpB,qBAAqB;IACrB,eADW,MAAM,CACa;IAE9B,sBAAsB;IACtB,UADW,OAAO,CACG;IACrB,+EAA+E;IAC/E,OADW,OAAO,CACA;IAClB,sBAAsB;IACtB,QADW,OAAO,CACC;IACnB,wDAAwD;IACxD,UADW,OAAO,CACG;IAErB,gGAAgG;IAChG,OADW,OAAO,CACA;IAElB;;;OAGG;IACH,UAFU,CAAC,MAAM,GAAG,OAAO,GAAG,SAAS,CAAC,CAEf;IAE3B,6EAOC;IACD;;;MAaC;IACD,0BAEC;IACD,+CAiCC;CACF;AA7GD,qCAA0C;AAE1C,qCAAmD;AAEnD,gDAAkD;gCA5XI,0BAA0B;wBAC7C,KAAK"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as _defineProperty, L as LeuElement } from './LeuElement-
|
|
1
|
+
import { _ as _defineProperty, L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
2
2
|
import { css, html, nothing } from 'lit';
|
|
3
3
|
import { classMap } from 'lit/directives/class-map.js';
|
|
4
4
|
import { ifDefined } from 'lit/directives/if-defined.js';
|
package/dist/Button.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { c as BUTTON_EXPANDED_OPTIONS, a as BUTTON_SIZES, b as BUTTON_TYPES, B as BUTTON_VARIANTS, L as LeuButton } from "./Button-
|
|
1
|
+
export { c as BUTTON_EXPANDED_OPTIONS, a as BUTTON_SIZES, b as BUTTON_TYPES, B as BUTTON_VARIANTS, L as LeuButton } from "./Button-7370f901.js";
|
|
2
2
|
//# sourceMappingURL=Button.d.ts.map
|
package/dist/Button.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import './LeuElement-
|
|
1
|
+
import './LeuElement-ba5ea33d.js';
|
|
2
2
|
import 'lit';
|
|
3
3
|
import 'lit/directives/class-map.js';
|
|
4
4
|
import 'lit/directives/if-defined.js';
|
|
5
5
|
import './Icon.js';
|
|
6
|
-
export { c as BUTTON_EXPANDED_OPTIONS, a as BUTTON_SIZES, b as BUTTON_TYPES, B as BUTTON_VARIANTS, L as LeuButton } from './Button-
|
|
6
|
+
export { c as BUTTON_EXPANDED_OPTIONS, a as BUTTON_SIZES, b as BUTTON_TYPES, B as BUTTON_VARIANTS, L as LeuButton } from './Button-7370f901.js';
|
package/dist/ButtonGroup.d.ts
CHANGED
|
@@ -20,5 +20,5 @@ export class LeuButtonGroup extends LeuElement {
|
|
|
20
20
|
_handleButtonClick(button: any): void;
|
|
21
21
|
render(): import("lit-html").TemplateResult<1>;
|
|
22
22
|
}
|
|
23
|
-
import { L as LeuElement } from './LeuElement-
|
|
23
|
+
import { L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
24
24
|
//# sourceMappingURL=ButtonGroup.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonGroup.d.ts","sourceRoot":"","sources":["ButtonGroup.js"],"names":[],"mappings":"AAeA;;;;;GAKG;AACH;IAME;;;OAGG;IACH,
|
|
1
|
+
{"version":3,"file":"ButtonGroup.d.ts","sourceRoot":"","sources":["ButtonGroup.js"],"names":[],"mappings":"AAeA;;;;;GAKG;AACH;IAME;;;OAGG;IACH,oCAFa,MAAM,CAIlB;IATC,cAAgB;IAclB,4BAMC;IAVD,oBAGC;IAQD,0BA+BC;IAED;;OAEG;IACH,sCAWC;IACD,+CAMC;CACF;gCApGqD,0BAA0B"}
|
package/dist/ButtonGroup.js
CHANGED
package/dist/Checkbox.d.ts
CHANGED
|
@@ -10,5 +10,5 @@ export class LeuCheckbox extends LeuElement {
|
|
|
10
10
|
handleInput(event: any): void;
|
|
11
11
|
render(): import("lit-html").TemplateResult<1>;
|
|
12
12
|
}
|
|
13
|
-
import { L as LeuElement } from './LeuElement-
|
|
13
|
+
import { L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
14
14
|
//# sourceMappingURL=Checkbox.d.ts.map
|
package/dist/Checkbox.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Checkbox.d.ts","sourceRoot":"","sources":["Checkbox.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Checkbox.d.ts","sourceRoot":"","sources":["Checkbox.js"],"names":[],"mappings":"AAiGA;;GAEG;AACH;IAGI,iBAAoB;IACpB,kBAAqB;IACrB,aAAc;IACd,cAAe;IAEjB,+BAIC;IACD,8BAEC;IACD,+CAgBC;CACF;gCArIqD,0BAA0B"}
|
package/dist/Checkbox.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as _defineProperty, L as LeuElement } from './LeuElement-
|
|
1
|
+
import { _ as _defineProperty, L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
2
2
|
import { css, html } from 'lit';
|
|
3
3
|
import { LeuIcon } from './Icon.js';
|
|
4
4
|
|
|
@@ -20,6 +20,8 @@ var css_248z = css`:host {
|
|
|
20
20
|
align-items: flex-start;
|
|
21
21
|
gap: 0.5rem;
|
|
22
22
|
|
|
23
|
+
font-family: var(--leu-font-family-regular);
|
|
24
|
+
|
|
23
25
|
font-family: var(--checkbox-font-regular);
|
|
24
26
|
}
|
|
25
27
|
|
package/dist/CheckboxGroup.d.ts
CHANGED
|
@@ -9,5 +9,5 @@ export class LeuCheckboxGroup extends LeuElement {
|
|
|
9
9
|
handleItems(): void;
|
|
10
10
|
render(): import("lit-html").TemplateResult<1>;
|
|
11
11
|
}
|
|
12
|
-
import { L as LeuElement } from './LeuElement-
|
|
12
|
+
import { L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
13
13
|
//# sourceMappingURL=CheckboxGroup.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CheckboxGroup.d.ts","sourceRoot":"","sources":["CheckboxGroup.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CheckboxGroup.d.ts","sourceRoot":"","sources":["CheckboxGroup.js"],"names":[],"mappings":"AAqCA;;GAEG;AACH;IAGI,oBAA+B;IAC/B,aAAe;IAEjB,mBAEC;IACD,yBAEC;IACD,oBAEC;IACD,+CAWC;CACF;gCAnEqD,0BAA0B"}
|
package/dist/CheckboxGroup.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as _defineProperty, L as LeuElement } from './LeuElement-
|
|
1
|
+
import { _ as _defineProperty, L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
2
2
|
import { css, html } from 'lit';
|
|
3
3
|
import { classMap } from 'lit/directives/class-map.js';
|
|
4
4
|
|
|
@@ -6,6 +6,8 @@ var css_248z = css`:host {
|
|
|
6
6
|
--group-font-regular: var(--leu-font-family-regular);
|
|
7
7
|
--group-font-black: var(--leu-font-family-black);
|
|
8
8
|
|
|
9
|
+
font-family: var(--leu-font-family-regular);
|
|
10
|
+
|
|
9
11
|
font-family: var(--group-font-regular);
|
|
10
12
|
}
|
|
11
13
|
|
package/dist/Chip.d.ts
CHANGED
package/dist/Chip.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Chip.d.ts","sourceRoot":"","sources":["Chip.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Chip.d.ts","sourceRoot":"","sources":["Chip.js"],"names":[],"mappings":"AAwJA;IAGI,kBAAqB;CAExB;gCA7JqD,0BAA0B"}
|
package/dist/Chip.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as _defineProperty, L as LeuElement } from './LeuElement-
|
|
1
|
+
import { _ as _defineProperty, L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
2
2
|
import { css } from 'lit';
|
|
3
3
|
|
|
4
4
|
var css_248z = css`:host,
|
|
@@ -11,17 +11,17 @@ var css_248z = css`:host,
|
|
|
11
11
|
:host {
|
|
12
12
|
--chip-background-color-default: var(--leu-color-black-transp-10);
|
|
13
13
|
--chip-background-color-hover: var(--leu-color-black-transp-20);
|
|
14
|
-
--chip-background-color-
|
|
15
|
-
--chip-background-color-
|
|
14
|
+
--chip-background-color-checked: var(--leu-color-black-100);
|
|
15
|
+
--chip-background-color-checked-hover: var(--leu-color-black-transp-80);
|
|
16
16
|
|
|
17
17
|
--chip-color-default: var(--leu-color-black-transp-60);
|
|
18
18
|
--chip-color-hover: var(--leu-color-black-100);
|
|
19
|
-
--chip-color-
|
|
19
|
+
--chip-color-checked: var(--leu-color-black-0);
|
|
20
20
|
|
|
21
21
|
--chip-radio-border-default: var(--leu-color-black-transp-40);
|
|
22
|
-
--chip-radio-border-
|
|
22
|
+
--chip-radio-border-checked: var(--leu-color-black-0);
|
|
23
23
|
--chip-radio-background-default: var(--leu-color-black-0);
|
|
24
|
-
--chip-radio-background-
|
|
24
|
+
--chip-radio-background-checked: var(--leu-color-func-cyan);
|
|
25
25
|
|
|
26
26
|
--chip-font-regular: var(--leu-font-family-regular);
|
|
27
27
|
--chip-font-black: var(--leu-font-family-black);
|
|
@@ -33,6 +33,8 @@ var css_248z = css`:host,
|
|
|
33
33
|
|
|
34
34
|
--leu-icon-size: 1rem;
|
|
35
35
|
|
|
36
|
+
font-family: var(--leu-font-family-regular);
|
|
37
|
+
|
|
36
38
|
font-family: var(--chip-font-regular);
|
|
37
39
|
|
|
38
40
|
/* Allow shrinking to achieve text truncation (ellipsis) */
|
|
@@ -45,14 +47,14 @@ var css_248z = css`:host,
|
|
|
45
47
|
|
|
46
48
|
--chip-color-default: var(--leu-color-black-0);
|
|
47
49
|
--chip-color-hover: var(--leu-color-black-0);
|
|
48
|
-
--chip-color-
|
|
50
|
+
--chip-color-checked: var(--leu-color-black-0);
|
|
49
51
|
}
|
|
50
52
|
|
|
51
|
-
:host([
|
|
52
|
-
--chip-background-color: var(--chip-background-color-
|
|
53
|
-
--chip-color: var(--chip-color-
|
|
54
|
-
--chip-radio-border: var(--chip-radio-border-
|
|
55
|
-
--chip-radio-background: var(--chip-radio-background-
|
|
53
|
+
:host([checked]) {
|
|
54
|
+
--chip-background-color: var(--chip-background-color-checked);
|
|
55
|
+
--chip-color: var(--chip-color-checked);
|
|
56
|
+
--chip-radio-border: var(--chip-radio-border-checked);
|
|
57
|
+
--chip-radio-background: var(--chip-radio-background-checked);
|
|
56
58
|
}
|
|
57
59
|
|
|
58
60
|
.button {
|
|
@@ -101,10 +103,10 @@ var css_248z = css`:host,
|
|
|
101
103
|
text-decoration: none;
|
|
102
104
|
}
|
|
103
105
|
|
|
104
|
-
:host([
|
|
105
|
-
:host([
|
|
106
|
-
--chip-background-color: var(--chip-background-color-
|
|
107
|
-
--chip-color: var(--chip-color-
|
|
106
|
+
:host([checked]) .button:hover,
|
|
107
|
+
:host([checked]) .button:focus-visible {
|
|
108
|
+
--chip-background-color: var(--chip-background-color-checked-hover);
|
|
109
|
+
--chip-color: var(--chip-color-checked);
|
|
108
110
|
}
|
|
109
111
|
|
|
110
112
|
:host([href][size="large"]) .button {
|
|
@@ -132,7 +134,7 @@ var css_248z = css`:host,
|
|
|
132
134
|
border-radius: 50%;
|
|
133
135
|
}
|
|
134
136
|
|
|
135
|
-
:host([variant="radio"][
|
|
137
|
+
:host([variant="radio"][checked]) .button::before {
|
|
136
138
|
border-width: 3px;
|
|
137
139
|
}
|
|
138
140
|
|
package/dist/ChipGroup.d.ts
CHANGED
|
@@ -10,7 +10,13 @@ export class LeuChipGroup extends LeuElement {
|
|
|
10
10
|
label: string;
|
|
11
11
|
/** @type {"single" | "multiple" | "none"} */
|
|
12
12
|
selectionMode: "single" | "multiple" | "none";
|
|
13
|
-
|
|
13
|
+
/**
|
|
14
|
+
* Checks the items with the given values.
|
|
15
|
+
* If the selectionMode is single, only the first item with the given value is checked.
|
|
16
|
+
* @param {string[]} valueList
|
|
17
|
+
*/
|
|
18
|
+
set value(valueList: string[]);
|
|
19
|
+
get value(): string[];
|
|
14
20
|
/**
|
|
15
21
|
* Determines the heading tag of the accordion toggle.
|
|
16
22
|
* The headingLevel shouldn't be used directly to render the heading tag
|
|
@@ -26,5 +32,5 @@ export const SELECTION_MODES: Readonly<{
|
|
|
26
32
|
multiple: "multiple";
|
|
27
33
|
none: "none";
|
|
28
34
|
}>;
|
|
29
|
-
import { L as LeuElement } from './LeuElement-
|
|
35
|
+
import { L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
30
36
|
//# sourceMappingURL=ChipGroup.d.ts.map
|
package/dist/ChipGroup.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChipGroup.d.ts","sourceRoot":"","sources":["ChipGroup.js"],"names":[],"mappings":"AA8BA;;;;GAIG;AACH;IAiBM,aAAkB;IAEpB,kBAAqB;IACrB,qBAAqB;IACrB,cAAe;IAKf,6CAA6C;IAC7C,eADW,QAAQ,GAAG,UAAU,GAAG,MAAM,CACA;
|
|
1
|
+
{"version":3,"file":"ChipGroup.d.ts","sourceRoot":"","sources":["ChipGroup.js"],"names":[],"mappings":"AA8BA;;;;GAIG;AACH;IAiBM,aAAkB;IAEpB,kBAAqB;IACrB,qBAAqB;IACrB,cAAe;IAKf,6CAA6C;IAC7C,eADW,QAAQ,GAAG,UAAU,GAAG,MAAM,CACA;IA0B3C;;;;OAIG;IACH,+BAQC;IAjBD,sBAEC;IAiBD;;;;;;OAMG;IACH,yBAMC;IACD,4CAeC;CACF;AA7GD;;;;GAIG;gCA5BmD,0BAA0B"}
|
package/dist/ChipGroup.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as _defineProperty, L as LeuElement } from './LeuElement-
|
|
1
|
+
import { _ as _defineProperty, L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
2
2
|
import { html, unsafeStatic } from 'lit/static-html.js';
|
|
3
3
|
import { css } from 'lit';
|
|
4
4
|
|
|
@@ -40,7 +40,7 @@ class LeuChipGroup extends LeuElement {
|
|
|
40
40
|
_defineProperty(this, "handleInput", e => {
|
|
41
41
|
if (this.selectionMode === SELECTION_MODES.single) {
|
|
42
42
|
this.items.forEach(item => {
|
|
43
|
-
item.
|
|
43
|
+
item.checked = item === e.target; // eslint-disable-line no-param-reassign
|
|
44
44
|
});
|
|
45
45
|
}
|
|
46
46
|
});
|
|
@@ -64,14 +64,41 @@ class LeuChipGroup extends LeuElement {
|
|
|
64
64
|
}
|
|
65
65
|
connectedCallback() {
|
|
66
66
|
super.connectedCallback();
|
|
67
|
-
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* It is technically possible to add an event listener to the host element
|
|
70
|
+
* before it is connected to the dom. In that case the outside event listener would
|
|
71
|
+
* be called before the following event listener. But at this point multiple
|
|
72
|
+
* radio chips could be selected at the same time because `handleInput` hasn't been
|
|
73
|
+
* called yet. That's why we use the capture phase.
|
|
74
|
+
*/
|
|
75
|
+
this.addEventListener("input", this.handleInput, {
|
|
76
|
+
capture: true
|
|
77
|
+
});
|
|
68
78
|
}
|
|
69
79
|
disconnectedCallback() {
|
|
70
80
|
super.disconnectedCallback();
|
|
71
|
-
this.removeEventListener("input", this.handleInput
|
|
81
|
+
this.removeEventListener("input", this.handleInput, {
|
|
82
|
+
capture: true
|
|
83
|
+
});
|
|
72
84
|
}
|
|
73
85
|
get value() {
|
|
74
|
-
return this.items.filter(i => i.
|
|
86
|
+
return this.items.filter(i => i.checked).map(i => i.value);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
/**
|
|
90
|
+
* Checks the items with the given values.
|
|
91
|
+
* If the selectionMode is single, only the first item with the given value is checked.
|
|
92
|
+
* @param {string[]} valueList
|
|
93
|
+
*/
|
|
94
|
+
set value(valueList) {
|
|
95
|
+
let hasChanged = false;
|
|
96
|
+
for (const item of this.items) {
|
|
97
|
+
item.checked = hasChanged ? false : valueList.includes(item.value);
|
|
98
|
+
if (this.selectionMode === SELECTION_MODES.single && item.checked) {
|
|
99
|
+
hasChanged = true;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
75
102
|
}
|
|
76
103
|
|
|
77
104
|
/**
|
package/dist/ChipLink.js
CHANGED
package/dist/ChipRemovable.js
CHANGED
package/dist/ChipSelectable.d.ts
CHANGED
|
@@ -4,6 +4,8 @@
|
|
|
4
4
|
* @slot - The content of the chip
|
|
5
5
|
* @prop {keyof typeof SIZES} size - The size of the chip. Not supported for radio variant.
|
|
6
6
|
* @prop {keyof typeof VARIANTS} variant - `toggle` or `radio`. Determines if only one or multiple chips can be selected.
|
|
7
|
+
* @prop {boolean} checked - Whether the chip is selected.
|
|
8
|
+
* @prop {string} value - The value of the chip.
|
|
7
9
|
*/
|
|
8
10
|
export class LeuChipSelectable extends LeuChipBase {
|
|
9
11
|
size: string;
|
|
@@ -14,7 +16,7 @@ export class LeuChipSelectable extends LeuChipBase {
|
|
|
14
16
|
* @default "toggle"
|
|
15
17
|
*/
|
|
16
18
|
variant: string;
|
|
17
|
-
|
|
19
|
+
checked: boolean;
|
|
18
20
|
handleClick(): void;
|
|
19
21
|
render(): import("lit-html").TemplateResult<1>;
|
|
20
22
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChipSelectable.d.ts","sourceRoot":"","sources":["ChipSelectable.js"],"names":[],"mappings":"AAaA
|
|
1
|
+
{"version":3,"file":"ChipSelectable.d.ts","sourceRoot":"","sources":["ChipSelectable.js"],"names":[],"mappings":"AAaA;;;;;;;;GAQG;AACH;IAGI,aAAyB;IAEzB;;;;;OAKG;IACH,gBAA8B;IAC9B,iBAAoB;IAKtB,oBAiBC;IACD,+CAQC;CACF;;;;;;;;;4BAhE2B,WAAW"}
|
package/dist/ChipSelectable.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as _defineProperty } from './LeuElement-
|
|
1
|
+
import { _ as _defineProperty } from './LeuElement-ba5ea33d.js';
|
|
2
2
|
import { html } from 'lit';
|
|
3
3
|
import { LeuChipBase } from './Chip.js';
|
|
4
4
|
|
|
@@ -17,6 +17,8 @@ const VARIANTS = {
|
|
|
17
17
|
* @slot - The content of the chip
|
|
18
18
|
* @prop {keyof typeof SIZES} size - The size of the chip. Not supported for radio variant.
|
|
19
19
|
* @prop {keyof typeof VARIANTS} variant - `toggle` or `radio`. Determines if only one or multiple chips can be selected.
|
|
20
|
+
* @prop {boolean} checked - Whether the chip is selected.
|
|
21
|
+
* @prop {string} value - The value of the chip.
|
|
20
22
|
*/
|
|
21
23
|
class LeuChipSelectable extends LeuChipBase {
|
|
22
24
|
constructor() {
|
|
@@ -30,23 +32,23 @@ class LeuChipSelectable extends LeuChipBase {
|
|
|
30
32
|
* @default "toggle"
|
|
31
33
|
*/
|
|
32
34
|
this.variant = VARIANTS.toggle;
|
|
33
|
-
this.
|
|
35
|
+
this.checked = false;
|
|
34
36
|
if (this.variant === VARIANTS.radio && this.size === SIZES.small) {
|
|
35
37
|
console.warn("Small size has no effect on radio variant");
|
|
36
38
|
}
|
|
37
39
|
}
|
|
38
40
|
handleClick() {
|
|
39
|
-
let
|
|
41
|
+
let nextcheckedState = this.checked;
|
|
40
42
|
if (this.variant === VARIANTS.radio) {
|
|
41
|
-
|
|
43
|
+
nextcheckedState = true;
|
|
42
44
|
} else {
|
|
43
|
-
|
|
45
|
+
nextcheckedState = !this.checked;
|
|
44
46
|
}
|
|
45
|
-
if (
|
|
46
|
-
this.
|
|
47
|
+
if (nextcheckedState !== this.checked) {
|
|
48
|
+
this.checked = nextcheckedState;
|
|
47
49
|
this.dispatchEvent(new CustomEvent("input", {
|
|
48
50
|
detail: {
|
|
49
|
-
|
|
51
|
+
checked: this.checked
|
|
50
52
|
},
|
|
51
53
|
bubbles: true,
|
|
52
54
|
composed: true
|
|
@@ -55,9 +57,9 @@ class LeuChipSelectable extends LeuChipBase {
|
|
|
55
57
|
}
|
|
56
58
|
render() {
|
|
57
59
|
return html`<button
|
|
58
|
-
@click=${
|
|
60
|
+
@click=${() => this.handleClick()}
|
|
59
61
|
class="button"
|
|
60
|
-
aria-pressed=${this.
|
|
62
|
+
aria-pressed=${this.checked ? "true" : "false"}
|
|
61
63
|
>
|
|
62
64
|
<span class="label"><slot></slot></span>
|
|
63
65
|
</button>`;
|
|
@@ -73,7 +75,7 @@ _defineProperty(LeuChipSelectable, "properties", {
|
|
|
73
75
|
type: String,
|
|
74
76
|
reflect: true
|
|
75
77
|
},
|
|
76
|
-
|
|
78
|
+
checked: {
|
|
77
79
|
type: Boolean,
|
|
78
80
|
reflect: true
|
|
79
81
|
},
|
package/dist/Dropdown.d.ts
CHANGED
|
@@ -15,5 +15,5 @@ export class LeuDropdown extends LeuElement {
|
|
|
15
15
|
_getMenu(): any;
|
|
16
16
|
render(): import("lit-html").TemplateResult<1>;
|
|
17
17
|
}
|
|
18
|
-
import { L as LeuElement } from './LeuElement-
|
|
18
|
+
import { L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
19
19
|
//# sourceMappingURL=Dropdown.d.ts.map
|
package/dist/Dropdown.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Dropdown.d.ts","sourceRoot":"","sources":["Dropdown.js"],"names":[],"mappings":"AAkCA;;GAEG;AACH;IAMQ,kBAAqB;IAqBzB,cAAe;IAGf,kEAAkE;IAClE,YADW,OAAO,oBAAoB,EAAE,GAAG,CAAC,iBAAiB,CAAC,CACjC;IAkB/B,gCAIC;IACD,iDAYC;IACD,2BAEC;IAED;;OAEG;IACH,
|
|
1
|
+
{"version":3,"file":"Dropdown.d.ts","sourceRoot":"","sources":["Dropdown.js"],"names":[],"mappings":"AAkCA;;GAEG;AACH;IAMQ,kBAAqB;IAqBzB,cAAe;IAGf,kEAAkE;IAClE,YADW,OAAO,oBAAoB,EAAE,GAAG,CAAC,iBAAiB,CAAC,CACjC;IAkB/B,gCAIC;IACD,iDAYC;IACD,2BAEC;IAED;;OAEG;IACH,gBAEC;IACD,+CA6BC;CACF;gCAhJqD,0BAA0B"}
|
package/dist/Dropdown.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { _ as _defineProperty, L as LeuElement } from './LeuElement-
|
|
1
|
+
import { _ as _defineProperty, L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
2
2
|
import { css, html, nothing } from 'lit';
|
|
3
3
|
import { createRef, ref } from 'lit/directives/ref.js';
|
|
4
|
-
import { H as HasSlotController, L as LeuButton } from './Button-
|
|
4
|
+
import { H as HasSlotController, L as LeuButton } from './Button-7370f901.js';
|
|
5
5
|
import { LeuMenu } from './Menu.js';
|
|
6
6
|
import { LeuMenuItem } from './MenuItem.js';
|
|
7
7
|
import { LeuPopup } from './Popup.js';
|
package/dist/Icon.d.ts
CHANGED
|
@@ -1,4 +1,100 @@
|
|
|
1
|
-
export type IconPathName =
|
|
1
|
+
export type IconPathName = keyof {
|
|
2
|
+
addNew: string;
|
|
3
|
+
angleDropDown: string;
|
|
4
|
+
angleDropup: string;
|
|
5
|
+
angleLeft: string;
|
|
6
|
+
angleRight: string;
|
|
7
|
+
arrowDown: string;
|
|
8
|
+
arrowLeft: string;
|
|
9
|
+
arrowRight: string;
|
|
10
|
+
arrowUp: string;
|
|
11
|
+
calendar: string;
|
|
12
|
+
caution: string;
|
|
13
|
+
chatMessage: string;
|
|
14
|
+
check: string;
|
|
15
|
+
clear: string;
|
|
16
|
+
close: string;
|
|
17
|
+
conference: string;
|
|
18
|
+
confirm: string;
|
|
19
|
+
confirmPlain: string;
|
|
20
|
+
delete: string;
|
|
21
|
+
documents: string;
|
|
22
|
+
download: string;
|
|
23
|
+
edit: string;
|
|
24
|
+
email: string;
|
|
25
|
+
file: string;
|
|
26
|
+
fileOutline: string;
|
|
27
|
+
files: string;
|
|
28
|
+
filter: string;
|
|
29
|
+
floppy: string;
|
|
30
|
+
forward: string;
|
|
31
|
+
getInformation: string;
|
|
32
|
+
hide: string;
|
|
33
|
+
home: string;
|
|
34
|
+
link: string;
|
|
35
|
+
list: string;
|
|
36
|
+
lock: string;
|
|
37
|
+
location: string;
|
|
38
|
+
login: string;
|
|
39
|
+
logout: string;
|
|
40
|
+
map: string;
|
|
41
|
+
mapLocateMe: string;
|
|
42
|
+
mapLocation: string;
|
|
43
|
+
mapNavigation: string;
|
|
44
|
+
mapPin: string;
|
|
45
|
+
menu: string;
|
|
46
|
+
menuOverflow: string;
|
|
47
|
+
minus: string;
|
|
48
|
+
openMail: string;
|
|
49
|
+
overflow: string;
|
|
50
|
+
paperplane: string;
|
|
51
|
+
paragraph: string;
|
|
52
|
+
phoneCall: string;
|
|
53
|
+
pin: string;
|
|
54
|
+
plus: string;
|
|
55
|
+
print: string;
|
|
56
|
+
remove: string;
|
|
57
|
+
resizeText: string;
|
|
58
|
+
search: string;
|
|
59
|
+
show: string;
|
|
60
|
+
time: string;
|
|
61
|
+
upload: string;
|
|
62
|
+
cc: string;
|
|
63
|
+
fastForward: string;
|
|
64
|
+
fastRewind: string;
|
|
65
|
+
fullScreen: string;
|
|
66
|
+
next: string;
|
|
67
|
+
pause: string;
|
|
68
|
+
play: string;
|
|
69
|
+
playButton: string;
|
|
70
|
+
previews: string;
|
|
71
|
+
skipNext: string;
|
|
72
|
+
skipPrevious: string;
|
|
73
|
+
stop: string;
|
|
74
|
+
comment: string;
|
|
75
|
+
facebook: string;
|
|
76
|
+
google: string;
|
|
77
|
+
instagram: string;
|
|
78
|
+
kununu: string;
|
|
79
|
+
like: string;
|
|
80
|
+
linkedin: string;
|
|
81
|
+
love: string;
|
|
82
|
+
repost: string;
|
|
83
|
+
share: string;
|
|
84
|
+
snapchat: string;
|
|
85
|
+
twitter: string;
|
|
86
|
+
user: string;
|
|
87
|
+
users: string;
|
|
88
|
+
vote: string;
|
|
89
|
+
xing: string;
|
|
90
|
+
youtube: string;
|
|
91
|
+
youtubeLogo: string;
|
|
92
|
+
smileyThrilled: string;
|
|
93
|
+
smileySmile: string;
|
|
94
|
+
smileyIndifferent: string;
|
|
95
|
+
smileySad: string;
|
|
96
|
+
smileyDevastated: string;
|
|
97
|
+
};
|
|
2
98
|
/**
|
|
3
99
|
* A component to render all defined zhWeb icons.
|
|
4
100
|
* The `fill` of the icon is set to `currentColor` and
|
|
@@ -16,5 +112,5 @@ export class LeuIcon extends LeuElement {
|
|
|
16
112
|
name: any | "";
|
|
17
113
|
render(): import("lit-html").TemplateResult<1>;
|
|
18
114
|
}
|
|
19
|
-
import { L as LeuElement } from './LeuElement-
|
|
115
|
+
import { L as LeuElement } from './LeuElement-ba5ea33d.js';
|
|
20
116
|
//# sourceMappingURL=Icon.d.ts.map
|
package/dist/Icon.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Icon.d.ts","sourceRoot":"","sources":["Icon.js"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"Icon.d.ts","sourceRoot":"","sources":["Icon.js"],"names":[],"mappings":"2BAca;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAAW;AAwGxB;;;;;;;;;GASG;AACH;IAII;;OAEG;IACH,MAFU,MAAiC,EAAE,CAE/B;IAEhB,+CAiBC;CACF;gCA3JqD,0BAA0B"}
|
package/dist/Icon.js
CHANGED