@zanichelli/albe-web-components 10.0.0 → 10.0.2
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/dist/cjs/{index-ddde2452.js → index-382f3d09.js} +5 -1
- package/dist/cjs/{index-1f3f3a0c.js → index-d6f00e52.js} +1 -1
- package/dist/cjs/z-accordion.cjs.entry.js +1 -1
- package/dist/cjs/z-carousel.cjs.entry.js +5 -1
- package/dist/cjs/z-navigation-tabs.cjs.entry.js +3 -3
- package/dist/cjs/z-panel-elem.cjs.entry.js +1 -1
- package/dist/cjs/z-table.cjs.entry.js +2 -2
- package/dist/cjs/z-td.cjs.entry.js +1 -1
- package/dist/cjs/z-tr.cjs.entry.js +2 -2
- package/dist/collection/components/navigation/tabs/z-navigation-tabs/index.js +4 -2
- package/dist/collection/components/navigation/tabs/z-navigation-tabs/styles.css +6 -8
- package/dist/collection/components/panel/z-panel-elem/index.js +1 -1
- package/dist/collection/components/table/cells/z-td/index.js +5 -1
- package/dist/collection/components/z-accordion/index.js +10 -2
- package/dist/collection/components/z-accordion/styles.css +21 -10
- package/dist/collection/components/z-carousel/index.js +6 -2
- package/dist/esm/{index-49dfba34.js → index-7081487e.js} +5 -1
- package/dist/esm/{index-1b2e3e53.js → index-8009e286.js} +1 -1
- package/dist/esm/z-accordion.entry.js +1 -1
- package/dist/esm/z-carousel.entry.js +6 -2
- package/dist/esm/z-navigation-tabs.entry.js +3 -3
- package/dist/esm/z-panel-elem.entry.js +1 -1
- package/dist/esm/z-table.entry.js +2 -2
- package/dist/esm/z-td.entry.js +1 -1
- package/dist/esm/z-tr.entry.js +2 -2
- package/dist/types/components/navigation/tabs/z-navigation-tabs/index.d.ts +2 -0
- package/dist/types/components/table/cells/z-td/index.d.ts +1 -0
- package/dist/types/components/z-accordion/index.d.ts +10 -2
- package/dist/web-components-library/p-0513242d.entry.js +1 -0
- package/dist/web-components-library/{p-dd3e0b4e.js → p-32410a6d.js} +1 -1
- package/dist/web-components-library/p-3b1b8e14.entry.js +1 -0
- package/dist/web-components-library/p-5445a3fe.entry.js +1 -0
- package/dist/web-components-library/{p-2d0ac109.entry.js → p-63119a07.entry.js} +1 -1
- package/dist/web-components-library/p-a8e23721.entry.js +1 -0
- package/dist/web-components-library/p-b3ad3811.js +1 -0
- package/dist/web-components-library/p-c4263223.entry.js +1 -0
- package/dist/web-components-library/p-e3117771.entry.js +1 -0
- package/dist/web-components-library/web-components-library.css +1 -1
- package/dist/web-components-library/web-components-library.esm.js +1 -1
- package/package.json +2 -2
- package/www/build/p-0513242d.entry.js +1 -0
- package/www/build/{p-d8829c48.js → p-131fdff2.js} +1 -1
- package/www/build/{p-dd3e0b4e.js → p-32410a6d.js} +1 -1
- package/www/build/p-3b1b8e14.entry.js +1 -0
- package/www/build/p-5445a3fe.entry.js +1 -0
- package/www/build/{p-2d0ac109.entry.js → p-63119a07.entry.js} +1 -1
- package/www/build/p-a8e23721.entry.js +1 -0
- package/www/build/p-b3ad3811.js +1 -0
- package/www/build/p-c4263223.entry.js +1 -0
- package/www/build/p-e3117771.entry.js +1 -0
- package/www/build/{p-ac088d9a.css → p-e4fadcc0.css} +1 -1
- package/www/build/web-components-library.css +1 -1
- package/www/build/web-components-library.esm.js +1 -1
- package/www/index.html +1 -1
- package/CHANGELOG.md +0 -2711
- package/dist/web-components-library/p-293e2bfc.entry.js +0 -1
- package/dist/web-components-library/p-386bdb7f.entry.js +0 -1
- package/dist/web-components-library/p-6302304b.entry.js +0 -1
- package/dist/web-components-library/p-c250c443.js +0 -1
- package/dist/web-components-library/p-c97d133c.entry.js +0 -1
- package/dist/web-components-library/p-d8de02a7.entry.js +0 -1
- package/dist/web-components-library/p-dd17b462.entry.js +0 -1
- package/src-react/index.ts +0 -1
- package/www/build/p-293e2bfc.entry.js +0 -1
- package/www/build/p-386bdb7f.entry.js +0 -1
- package/www/build/p-6302304b.entry.js +0 -1
- package/www/build/p-c250c443.js +0 -1
- package/www/build/p-c97d133c.entry.js +0 -1
- package/www/build/p-d8de02a7.entry.js +0 -1
- package/www/build/p-dd17b462.entry.js +0 -1
|
@@ -33,11 +33,15 @@ const ZTd = class {
|
|
|
33
33
|
}
|
|
34
34
|
this.colspanChange.emit(this.colspan || 1);
|
|
35
35
|
}
|
|
36
|
+
onMenuButtonClick(ev) {
|
|
37
|
+
ev.stopPropagation();
|
|
38
|
+
this.popoverEl.open = !this.popoverEl.open;
|
|
39
|
+
}
|
|
36
40
|
componentWillLoad() {
|
|
37
41
|
this.updateColspan();
|
|
38
42
|
}
|
|
39
43
|
render() {
|
|
40
|
-
return (index.h(index.Host, { role: "cell", "menu-open": this.isMenuOpen }, index.h("slot", null), this.showMenu && (index.h("div", { class: "cell--menu-container prevent-expand" }, index.h("z-button", { variant: index$1.ButtonVariant.TERTIARY, icon: "contextual-menu", size: index$1.ControlSize.X_SMALL, ref: (el) => (this.menuTrigger = el), onClick:
|
|
44
|
+
return (index.h(index.Host, { role: "cell", "menu-open": this.isMenuOpen }, index.h("slot", null), this.showMenu && (index.h("div", { class: "cell--menu-container prevent-expand" }, index.h("z-button", { variant: index$1.ButtonVariant.TERTIARY, icon: "contextual-menu", size: index$1.ControlSize.X_SMALL, ref: (el) => (this.menuTrigger = el), onClick: this.onMenuButtonClick.bind(this) }), index.h("z-popover", { ref: (el) => (this.popoverEl = el), bindTo: this.menuTrigger, onOpenChange: (event) => (this.isMenuOpen = event.detail.open) }, index.h("slot", { name: "contextual-menu" }))))));
|
|
41
45
|
}
|
|
42
46
|
get host() { return index.getElement(this); }
|
|
43
47
|
static get watchers() { return {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
const index = require('./index-e3299e0a.js');
|
|
4
4
|
const utils = require('./utils-4ac02425.js');
|
|
5
|
-
require('./index-
|
|
5
|
+
require('./index-382f3d09.js');
|
|
6
6
|
require('./index-4edb3854.js');
|
|
7
7
|
|
|
8
8
|
const stylesCss = ":host{--columns:1;display:grid;min-width:max-content;box-sizing:border-box;grid-auto-flow:column;grid-template-columns:var(--z-table--expand-button-size, 0) repeat(var(--columns), minmax(128px, 1fr))}*{box-sizing:border-box}.z-tr--expand-button-container,::slotted(*){border-bottom:var(--z-table--cells-bottom-border-size, var(--border-size-small)) solid var(--color-surface03)}::slotted(*:not(:last-child)){border-right:var(--z-table--cell-left-border, none)}:host([expandable]){--show-expandable-button:visible;cursor:pointer}:host([expandable]) ::slotted(*){grid-row:1}:host([expandable]) ::slotted(:nth-last-child(2)){border-right:none}:host([expandable]) ::slotted(*:last-child){border-left:0;grid-column:1 / span calc(var(--columns) + 1);grid-row:2}:host([expandable]:not([expanded])) ::slotted(*:last-child){display:none}:host([expanded]){margin-bottom:4px;box-shadow:0 4px 4px -2px var(--shadow-color-base)}:host([expanded]) .z-tr--expand-button-container,:host([expanded]) ::slotted(*){background-color:var(--color-surface02)}.z-tr--expand-button-container{display:flex;align-items:center;justify-content:center;background-color:var(--z-table--cells-background, var(--color-surface01))}.z-tr--expand-button-container button{display:flex;align-items:center;justify-content:center;padding:0;border:none;margin:auto;appearance:none;background:transparent;cursor:pointer;visibility:var(--show-expandable-button, hidden)}.z-tr--expand-button-container button:focus{box-shadow:var(--shadow-focus-primary);outline:none}.z-tr--expand-button-container button z-icon{--z-icon-width:16px;--z-icon-height:16px}";
|
|
@@ -5,7 +5,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
const index = require('./index-e3299e0a.js');
|
|
6
6
|
const index$1 = require('./index-e8ce94a1.js');
|
|
7
7
|
|
|
8
|
-
const stylesCss = ":host,:host *,:host ::slotted(*){box-sizing:border-box}:host{--z-accordion-highlight-color:transparent;--z-accordion-bg:var(--color-surface01);display:block;border-top:var(--border-size-small) solid var(--color-surface03);border-bottom:var(--border-size-small) solid var(--color-surface03);
|
|
8
|
+
const stylesCss = ":host,:host *,:host ::slotted(*){box-sizing:border-box}:host{--z-accordion-highlight-color:transparent;--z-accordion-bg:var(--color-surface01);--z-accordion-label-color:var(--color-text01);--z-accordion-disabled-label-color:var(--color-text03);--z-accordion-content-bg:var(--color-surface01);--z-accordion-content-fg:var(--color-text01);--z-accordion-hover-color:var(--color-surface03);--z-accordion-left-padding:calc(var(--space-unit) * 2);--z-accordion-right-padding:var(--space-unit);--z-accordion-label-font-weight:var(--font-sb);display:block;border-top:var(--border-size-small) solid var(--color-surface03);border-bottom:var(--border-size-small) solid var(--color-surface03);font-family:var(--font-family-sans);font-weight:var(--font-rg)}:host([variant=\"background\"]){border:var(--border-size-small) solid var(--color-surface03);border-radius:var(--border-radius)}:host([variant=\"background\"][shadow]){box-shadow:var(--shadow-2)}details{background-color:transparent}summary{--summary-x-small-height:32px;--summary-small-height:36px;--summary-big-height:44px;--summary-height:var(--summary-big-height);--summary-y-padding:var(--space-unit);position:relative;display:flex;height:var(--summary-height);align-items:center;padding:var(--summary-y-padding) var(--z-accordion-right-padding) var(--summary-y-padding)\n var(--z-accordion-left-padding);background-color:var(--z-accordion-bg);column-gap:var(--space-unit);cursor:pointer;list-style:none}:host([size=\"x-small\"]) summary{--summary-height:var(--summary-x-small-height)}:host([size=\"small\"]) summary{--summary-height:var(--summary-small-height)}:host(:is([size=\"x-small\"],[size=\"small\"])) summary{--summary-y-padding:calc(var(--space-unit) / 2)}:host([variant=\"background\"]) summary{padding-right:calc(var(--space-unit) * 2);border-radius:calc(var(--border-radius) - var(--border-size-small))}:host([variant=\"background\"][open]) summary{border-bottom-left-radius:0;border-bottom-right-radius:0}:host([is-disabled]) summary{cursor:default}summary:focus:focus-visible{background-color:var(--color-surface03);box-shadow:var(--shadow-focus-primary);outline:none}summary::before,:host([highlight][variant=\"background\"]) .z-accordion-content::before{position:absolute;top:0;left:0;display:block;width:var(--space-unit);height:100%;content:\"\"}:host([highlight][variant=\"background\"]) summary::before{border-top-left-radius:calc(var(--border-radius) - var(--border-size-small))}:host([highlight][variant=\"background\"]:not([open])) summary::before,:host([highlight][variant=\"background\"][open]) .z-accordion-content::before{border-bottom-left-radius:calc(var(--border-radius) - var(--border-size-small))}:host([highlight]) summary::before,:host([highlight][variant=\"background\"]) .z-accordion-content::before{background-color:var(--z-accordion-highlight-color, transparent)}:host([is-disabled][highlight]) summary::before,:host([is-disabled][highlight][variant=\"background\"]) .z-accordion-content::before{background-color:var(--z-accordion-disabled-label-color)}summary>z-icon{fill:var(--z-accordion-label-color)}:host([is-disabled]) summary>z-icon{fill:var(--z-accordion-disabled-label-color)}.z-accordion-label{color:var(--z-accordion-label-color);font-size:var(--font-size-3);font-weight:var(--z-accordion-label-font-weight)}:host([size=\"x-small\"]) .z-accordion-label{font-size:var(--font-size-2)}:host([size=\"x-small\"]) :is(.z-accordion-label-icon,.z-accordion-chevron){--z-icon-width:16px;--z-icon-height:16px}.z-accordion-tags{display:flex;align-items:center;column-gap:calc(var(--space-unit) / 2)}summary z-icon.z-accordion-chevron{margin-left:auto}.z-accordion-content{position:relative;padding:var(--space-unit) var(--space-unit) calc(var(--space-unit) * 2) calc(var(--space-unit) * 2);background-color:var(--z-accordion-content-bg);color:var(--z-accordion-content-fg);font-size:var(--font-size-2);}:host(:is([size=\"x-small\"],[size=\"small\"])) .z-accordion-content{padding-bottom:var(--space-unit)}:host([size=\"x-small\"]) .z-accordion-content{font-size:var(--font-size-1)}:host([variant=\"background\"]) .z-accordion-content{padding-right:calc(var(--space-unit) * 2)}:host([is-disabled]) .z-accordion-label{color:var(--z-accordion-disabled-label-color)}:host([is-disabled]) .z-accordion-tags ::slotted(z-tag[slot=\"tag\"]){--z-tag-bg:var(--z-accordion-disabled-label-color) !important;--z-tag-text-color:var(--color-text-inverse) !important}@media (hover: hover){summary:focus:focus-visible{position:relative;z-index:1}:host(:not([is-disabled])) summary:hover{background-color:var(--z-accordion-hover-color)}:host(:not([is-disabled])) summary:hover .z-accordion-label{text-decoration:underline}}@media (hover: none){:host([size]) summary{--summary-height:var(--summary-big-height);--summary-y-padding:var(--space-unit)}:host([size]) .z-accordion-label{font-size:var(--font-size-3)}:host([size]) .z-accordion-content{font-size:var(--font-size-2)}:host([size]) :is(.z-accordion-label-icon,.z-accordion-chevron){--z-icon-width:18px;--z-icon-height:18px}}z-accordion+z-accordion{border-top:none}z-accordion[variant=\"background\"]+z-accordion[variant=\"background\"]{border-radius:0}z-accordion[variant=\"background\"]:first-of-type:not(:last-of-type){border-bottom-left-radius:0;border-bottom-right-radius:0}z-accordion[variant=\"background\"]+z-accordion[variant=\"background\"]:last-of-type{border-bottom-left-radius:var(--border-radius);border-bottom-right-radius:var(--border-radius)}z-accordion[variant=\"background\"]:first-of-type:not(:last-of-type)::part(summary){border-bottom-left-radius:0;border-bottom-right-radius:0}z-accordion[variant=\"background\"]+z-accordion[variant=\"background\"]::part(summary){border-radius:0}z-accordion[variant=\"background\"]+z-accordion[variant=\"background\"]:last-of-type:not([open])::part(summary){border-bottom-left-radius:calc(var(--border-radius) - var(--border-size-small));border-bottom-right-radius:calc(var(--border-radius) - var(--border-size-small))}";
|
|
9
9
|
|
|
10
10
|
const ZAccordion = class {
|
|
11
11
|
constructor(hostRef) {
|
|
@@ -128,12 +128,16 @@ const ZCarousel = class {
|
|
|
128
128
|
}
|
|
129
129
|
this.itemsContainer.addEventListener("scroll", this.checkNavigationValidity.bind(this), { passive: true });
|
|
130
130
|
this.checkNavigationValidity();
|
|
131
|
+
this.items.forEach((item) => {
|
|
132
|
+
item.setAttribute("role", "group");
|
|
133
|
+
item.setAttribute("aria-roledescription", "slide");
|
|
134
|
+
});
|
|
131
135
|
}
|
|
132
136
|
render() {
|
|
133
137
|
if (this.isLoading) {
|
|
134
138
|
return (index.h(index.Host, null, this.label && index.h("div", { class: "heading-4 z-carousel-title" }, this.label), index.h("div", { style: { height: `${this.ghostLoadingHeight}px` } }, index.h("z-ghost-loading", null), index.h("div", { class: "loading-items-container" }, index.h("slot", null)))));
|
|
135
139
|
}
|
|
136
|
-
return (index.h(index.Host, null, index.h("div", { class: "z-carousel-container" }, this.label && index.h("div", { class: "heading-4 z-carousel-title" }, this.label), index.h("div", { class: "z-carousel-wrapper" }, this.arrowsPosition === index$1.CarouselArrowsPosition.OVER && (index.h("z-button", { size: index$1.
|
|
140
|
+
return (index.h(index.Host, null, index.h("div", { class: "z-carousel-container", role: "group", "aria-roledescription": "carousel", "aria-label": this.label || "Carousel" }, this.label && index.h("div", { class: "heading-4 z-carousel-title" }, this.label), index.h("div", { class: "z-carousel-wrapper" }, this.arrowsPosition === index$1.CarouselArrowsPosition.OVER && (index.h("z-button", { size: index$1.ControlSize.SMALL, "data-direction": "prev", icon: "chevron-left", onClick: this.onPrev.bind(this), disabled: !this.canNavigatePrev, ariaLabel: this.single ? "Mostra l'elemento precedente" : "Mostra gli elementi precedenti" })), index.h("ul", { class: "z-carousel-items-container", "aria-atomic": "false", "aria-live": "polite" }, index.h("slot", null)), this.arrowsPosition === index$1.CarouselArrowsPosition.OVER && (index.h("z-button", { size: index$1.ControlSize.SMALL, "data-direction": "next", icon: "chevron-right", onClick: this.onNext.bind(this), disabled: !this.canNavigateNext, ariaLabel: this.single ? "Mostra l'elemento successivo" : "Mostra gli elementi successivi" })))), this.canShowFooter() && (index.h("div", { class: "z-carousel-footer" }, this.arrowsPosition === index$1.CarouselArrowsPosition.BOTTOM && (index.h("z-button", { size: index$1.ControlSize.SMALL, variant: index$1.ButtonVariant.TERTIARY, icon: "arrow-simple-left-filled", onClick: this.onPrev.bind(this), disabled: !this.canNavigatePrev, ariaLabel: this.single ? "Mostra l'elemento precedente" : "Mostra gli elementi precedenti" })), this.progressMode === index$1.CarouselProgressMode.DOTS && this.single && this.items && (index.h("div", { class: "dots-progress" }, this.items.map((_item, key) => (index.h("button", { type: "button", class: { current: this.highlightedIndicator === key }, "aria-label": this.highlightedIndicator === key ? "Elemento corrente" : `Spostati all'elemento ${key + 1}`, onClick: () => this.goTo(key) }, index.h("z-icon", { name: this.highlightedIndicator === key ? "white-circle-filled" : "black-circle-filled" })))))), this.progressMode === index$1.CarouselProgressMode.NUMBERS && this.single && this.items && (index.h("div", { class: "numbers-progress interactive-3" }, index.h("span", { class: "current" }, this.current + 1), index.h("span", null, "di"), index.h("span", null, this.items.length))), this.arrowsPosition === index$1.CarouselArrowsPosition.BOTTOM && (index.h("z-button", { size: index$1.ControlSize.SMALL, variant: index$1.ButtonVariant.TERTIARY, icon: "arrow-simple-right-filled", onClick: this.onNext.bind(this), disabled: !this.canNavigateNext, ariaLabel: this.single ? "Mostra l'elemento successivo" : "Mostra gli elementi successivi" }))))));
|
|
137
141
|
}
|
|
138
142
|
get hostElement() { return index.getElement(this); }
|
|
139
143
|
static get watchers() { return {
|
|
@@ -5,7 +5,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
const index = require('./index-e3299e0a.js');
|
|
6
6
|
const index$1 = require('./index-e8ce94a1.js');
|
|
7
7
|
|
|
8
|
-
const stylesCss = ":host{position:relative;z-index:0;display:flex;overflow:hidden;flex-direction:row;font-family:var(--font-family-sans);font-weight:var(--font-rg)}:host,:host *,::slotted(*){box-sizing:border-box}::-webkit-scrollbar{display:none}.navigation-button{position:absolute;z-index:1;display:flex;align-items:center;justify-content:center;padding:0;border:none;margin:0;background:var(--
|
|
8
|
+
const stylesCss = ":host{--z-navigation-tabs-nav-buttons-bg:var(--color-white);--z-navigation-tabs-nav-buttons-fg:var(--color-primary01);position:relative;z-index:0;display:flex;overflow:hidden;flex-direction:row;font-family:var(--font-family-sans);font-weight:var(--font-rg)}:host,:host *,::slotted(*){box-sizing:border-box}::-webkit-scrollbar{display:none}.navigation-button{position:absolute;z-index:1;display:flex;align-items:center;justify-content:center;padding:0;border:none;margin:0;background:var(--z-navigation-tabs-nav-buttons-bg);border-radius:var(--border-no-radius);box-shadow:0 0 4px 1px var(--shadow-color-base);cursor:pointer;fill:var(--z-navigation-tabs-nav-buttons-fg);outline:none}.navigation-button:disabled{display:none}nav{display:flex;overflow:auto;align-items:center;justify-content:flex-start;scroll-behavior:smooth;scrollbar-width:none}:host([orientation=\"horizontal\"]) nav{width:100%}:host([orientation=\"horizontal\"]) .navigation-button{top:0;width:calc(var(--space-unit) * 4);height:100%}:host([orientation=\"horizontal\"]) .navigation-button:first-child{left:0}:host([orientation=\"horizontal\"]) .navigation-button:last-child{right:0}:host([orientation=\"vertical\"]){width:fit-content;flex-direction:column}:host([orientation=\"vertical\"]) nav{height:100%;flex-direction:column;align-items:stretch}:host([orientation=\"vertical\"]) .navigation-button{left:0;width:100%;height:calc(var(--space-unit) * 4)}:host([orientation=\"vertical\"]) .navigation-button:first-child{top:0}:host([orientation=\"vertical\"]) .navigation-button:last-child{bottom:0}:host([size=\"small\"][orientation=\"vertical\"]) .navigation-button{height:calc(var(--space-unit) * 4)}";
|
|
9
9
|
|
|
10
10
|
const ZNavigationTabs = class {
|
|
11
11
|
constructor(hostRef) {
|
|
@@ -174,9 +174,9 @@ const ZNavigationTabs = class {
|
|
|
174
174
|
return (index.h(index.Host, { class: {
|
|
175
175
|
"interactive-2": this.size === index$1.NavigationTabsSize.SMALL,
|
|
176
176
|
"interactive-1": this.size !== index$1.NavigationTabsSize.SMALL,
|
|
177
|
-
}, scrollable: this.canNavigate }, this.canNavigate && (index.h("button", { class: "navigation-button", onClick: this.navigateBackwards.bind(this), tabindex: "-1", disabled: !this.canNavigatePrev }, index.h("z-icon", { name: this.orientation === index$1.NavigationTabsOrientation.HORIZONTAL ? "chevron-left" : "chevron-up", width: 16, height: 16 }))), index.h("nav", { role: "tablist", "aria-label": this.ariaLabel, ref: (el) => (this.tabsNav = el !== null && el !== void 0 ? el : this.tabsNav), onScroll: this.checkScrollEnabled.bind(this), "aria-orientation": this.orientation }, index.h("slot", null)), this.canNavigate && (index.h("button", { class: "navigation-button", onClick: this.navigateForward.bind(this), onKeyDown: (e) => {
|
|
177
|
+
}, scrollable: this.canNavigate }, this.canNavigate && (index.h("button", { class: "navigation-button", onClick: this.navigateBackwards.bind(this), tabindex: "-1", disabled: !this.canNavigatePrev, "aria-label": "Mostra elementi precedenti" }, index.h("z-icon", { name: this.orientation === index$1.NavigationTabsOrientation.HORIZONTAL ? "chevron-left" : "chevron-up", width: 16, height: 16 }))), index.h("nav", { role: "tablist", "aria-label": this.ariaLabel, ref: (el) => (this.tabsNav = el !== null && el !== void 0 ? el : this.tabsNav), onScroll: this.checkScrollEnabled.bind(this), "aria-orientation": this.orientation }, index.h("slot", null)), this.canNavigate && (index.h("button", { class: "navigation-button", onClick: this.navigateForward.bind(this), onKeyDown: (e) => {
|
|
178
178
|
this.navigateThroughTabs(e);
|
|
179
|
-
}, tabindex: "-1", disabled: !this.canNavigateNext }, index.h("z-icon", { name: this.orientation === index$1.NavigationTabsOrientation.HORIZONTAL ? "chevron-right" : "chevron-down", width: 16, height: 16 })))));
|
|
179
|
+
}, tabindex: "-1", disabled: !this.canNavigateNext, "aria-label": "Mostra elementi successivi" }, index.h("z-icon", { name: this.orientation === index$1.NavigationTabsOrientation.HORIZONTAL ? "chevron-right" : "chevron-down", width: 16, height: 16 })))));
|
|
180
180
|
}
|
|
181
181
|
get host() { return index.getElement(this); }
|
|
182
182
|
static get watchers() { return {
|
|
@@ -26,7 +26,7 @@ const ZPanelElem = class {
|
|
|
26
26
|
"z-link": true,
|
|
27
27
|
"z-link-disabled": this.isdisabled,
|
|
28
28
|
"z-link-icon": true,
|
|
29
|
-
}, id: elemId + "link_id", href: this.url, target: this.target }, index.h("z-icon", {
|
|
29
|
+
}, id: elemId + "link_id", href: this.url, target: this.target }, index.h("z-icon", { height: 14, width: 14, name: this.linkicon }), this.linklabel)), this.descrSlotName && (index.h("div", { class: "panel-elem-desc" }, index.h("slot", { name: this.descrSlotName })))));
|
|
30
30
|
}
|
|
31
31
|
};
|
|
32
32
|
ZPanelElem.style = stylesCss;
|
|
@@ -5,12 +5,12 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
const index = require('./index-e3299e0a.js');
|
|
6
6
|
require('./index-23d8692f.js');
|
|
7
7
|
require('./index-a9764c98.js');
|
|
8
|
-
require('./index-
|
|
8
|
+
require('./index-d6f00e52.js');
|
|
9
9
|
require('./index-92a9f89e.js');
|
|
10
10
|
require('./utils-4ac02425.js');
|
|
11
11
|
require('./index-e8ce94a1.js');
|
|
12
12
|
require('./breakpoints-ebe1a437.js');
|
|
13
|
-
require('./index-
|
|
13
|
+
require('./index-382f3d09.js');
|
|
14
14
|
require('./index-4edb3854.js');
|
|
15
15
|
|
|
16
16
|
const stylesCss = ":host{--z-table--cells-padding:calc(var(--space-unit) * 2);position:relative;display:block;overflow:auto;max-width:100%;box-sizing:border-box;background-color:var(--color-surface01)}:host([expandable]){--z-table--expand-button-size:40px}:host([bordered]){--z-table--cell-left-border:1px solid var(--color-surface03)}.table{min-width:max-content}";
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-d6f00e52.js');
|
|
6
6
|
require('./index-e3299e0a.js');
|
|
7
7
|
require('./utils-4ac02425.js');
|
|
8
8
|
require('./index-e8ce94a1.js');
|
|
9
9
|
require('./breakpoints-ebe1a437.js');
|
|
10
|
-
require('./index-
|
|
10
|
+
require('./index-382f3d09.js');
|
|
11
11
|
require('./index-4edb3854.js');
|
|
12
12
|
|
|
13
13
|
|
|
@@ -3,6 +3,8 @@ import { NavigationTabsSize, NavigationTabsOrientation, NavigationTabsKeyboardEv
|
|
|
3
3
|
/**
|
|
4
4
|
* Navigation tabs component.
|
|
5
5
|
* @slot - Main slot. Use `z-navigation-tab` or `z-navigation-tab-link` components as children.
|
|
6
|
+
* @cssprop --z-navigation-tabs-nav-buttons-bg - Navigation buttons background color.
|
|
7
|
+
* @cssprop --z-navigation-tabs-nav-buttons-fg - Navigation buttons foreground color.
|
|
6
8
|
*/
|
|
7
9
|
export class ZNavigationTabs {
|
|
8
10
|
constructor() {
|
|
@@ -170,9 +172,9 @@ export class ZNavigationTabs {
|
|
|
170
172
|
return (h(Host, { class: {
|
|
171
173
|
"interactive-2": this.size === NavigationTabsSize.SMALL,
|
|
172
174
|
"interactive-1": this.size !== NavigationTabsSize.SMALL,
|
|
173
|
-
}, scrollable: this.canNavigate }, this.canNavigate && (h("button", { class: "navigation-button", onClick: this.navigateBackwards.bind(this), tabindex: "-1", disabled: !this.canNavigatePrev }, h("z-icon", { name: this.orientation === NavigationTabsOrientation.HORIZONTAL ? "chevron-left" : "chevron-up", width: 16, height: 16 }))), h("nav", { role: "tablist", "aria-label": this.ariaLabel, ref: (el) => (this.tabsNav = el !== null && el !== void 0 ? el : this.tabsNav), onScroll: this.checkScrollEnabled.bind(this), "aria-orientation": this.orientation }, h("slot", null)), this.canNavigate && (h("button", { class: "navigation-button", onClick: this.navigateForward.bind(this), onKeyDown: (e) => {
|
|
175
|
+
}, scrollable: this.canNavigate }, this.canNavigate && (h("button", { class: "navigation-button", onClick: this.navigateBackwards.bind(this), tabindex: "-1", disabled: !this.canNavigatePrev, "aria-label": "Mostra elementi precedenti" }, h("z-icon", { name: this.orientation === NavigationTabsOrientation.HORIZONTAL ? "chevron-left" : "chevron-up", width: 16, height: 16 }))), h("nav", { role: "tablist", "aria-label": this.ariaLabel, ref: (el) => (this.tabsNav = el !== null && el !== void 0 ? el : this.tabsNav), onScroll: this.checkScrollEnabled.bind(this), "aria-orientation": this.orientation }, h("slot", null)), this.canNavigate && (h("button", { class: "navigation-button", onClick: this.navigateForward.bind(this), onKeyDown: (e) => {
|
|
174
176
|
this.navigateThroughTabs(e);
|
|
175
|
-
}, tabindex: "-1", disabled: !this.canNavigateNext }, h("z-icon", { name: this.orientation === NavigationTabsOrientation.HORIZONTAL ? "chevron-right" : "chevron-down", width: 16, height: 16 })))));
|
|
177
|
+
}, tabindex: "-1", disabled: !this.canNavigateNext, "aria-label": "Mostra elementi successivi" }, h("z-icon", { name: this.orientation === NavigationTabsOrientation.HORIZONTAL ? "chevron-right" : "chevron-down", width: 16, height: 16 })))));
|
|
176
178
|
}
|
|
177
179
|
static get is() { return "z-navigation-tabs"; }
|
|
178
180
|
static get encapsulation() { return "shadow"; }
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
:host {
|
|
2
|
+
--z-navigation-tabs-nav-buttons-bg: var(--color-white);
|
|
3
|
+
--z-navigation-tabs-nav-buttons-fg: var(--color-primary01);
|
|
4
|
+
|
|
2
5
|
position: relative;
|
|
3
6
|
z-index: 0;
|
|
4
7
|
display: flex;
|
|
@@ -27,19 +30,14 @@
|
|
|
27
30
|
padding: 0;
|
|
28
31
|
border: none;
|
|
29
32
|
margin: 0;
|
|
30
|
-
background: var(--
|
|
33
|
+
background: var(--z-navigation-tabs-nav-buttons-bg);
|
|
31
34
|
border-radius: var(--border-no-radius);
|
|
32
|
-
box-shadow: 0 0 4px 1px (--shadow-color-base);
|
|
35
|
+
box-shadow: 0 0 4px 1px var(--shadow-color-base);
|
|
33
36
|
cursor: pointer;
|
|
34
|
-
fill: var(--
|
|
37
|
+
fill: var(--z-navigation-tabs-nav-buttons-fg);
|
|
35
38
|
outline: none;
|
|
36
39
|
}
|
|
37
40
|
|
|
38
|
-
.navigation-button:focus:focus-visible {
|
|
39
|
-
box-shadow: inset 0 0 4px 3px var(--color-highlight);
|
|
40
|
-
fill: var(--color-primary01);
|
|
41
|
-
}
|
|
42
|
-
|
|
43
41
|
.navigation-button:disabled {
|
|
44
42
|
display: none;
|
|
45
43
|
}
|
|
@@ -21,7 +21,7 @@ export class ZPanelElem {
|
|
|
21
21
|
"z-link": true,
|
|
22
22
|
"z-link-disabled": this.isdisabled,
|
|
23
23
|
"z-link-icon": true,
|
|
24
|
-
}, id: elemId + "link_id", href: this.url, target: this.target }, h("z-icon", {
|
|
24
|
+
}, id: elemId + "link_id", href: this.url, target: this.target }, h("z-icon", { height: 14, width: 14, name: this.linkicon }), this.linklabel)), this.descrSlotName && (h("div", { class: "panel-elem-desc" }, h("slot", { name: this.descrSlotName })))));
|
|
25
25
|
}
|
|
26
26
|
static get is() { return "z-panel-elem"; }
|
|
27
27
|
static get encapsulation() { return "scoped"; }
|
|
@@ -30,11 +30,15 @@ export class ZTd {
|
|
|
30
30
|
}
|
|
31
31
|
this.colspanChange.emit(this.colspan || 1);
|
|
32
32
|
}
|
|
33
|
+
onMenuButtonClick(ev) {
|
|
34
|
+
ev.stopPropagation();
|
|
35
|
+
this.popoverEl.open = !this.popoverEl.open;
|
|
36
|
+
}
|
|
33
37
|
componentWillLoad() {
|
|
34
38
|
this.updateColspan();
|
|
35
39
|
}
|
|
36
40
|
render() {
|
|
37
|
-
return (h(Host, { role: "cell", "menu-open": this.isMenuOpen }, h("slot", null), this.showMenu && (h("div", { class: "cell--menu-container prevent-expand" }, h("z-button", { variant: ButtonVariant.TERTIARY, icon: "contextual-menu", size: ControlSize.X_SMALL, ref: (el) => (this.menuTrigger = el), onClick:
|
|
41
|
+
return (h(Host, { role: "cell", "menu-open": this.isMenuOpen }, h("slot", null), this.showMenu && (h("div", { class: "cell--menu-container prevent-expand" }, h("z-button", { variant: ButtonVariant.TERTIARY, icon: "contextual-menu", size: ControlSize.X_SMALL, ref: (el) => (this.menuTrigger = el), onClick: this.onMenuButtonClick.bind(this) }), h("z-popover", { ref: (el) => (this.popoverEl = el), bindTo: this.menuTrigger, onOpenChange: (event) => (this.isMenuOpen = event.detail.open) }, h("slot", { name: "contextual-menu" }))))));
|
|
38
42
|
}
|
|
39
43
|
static get is() { return "z-td"; }
|
|
40
44
|
static get encapsulation() { return "shadow"; }
|
|
@@ -5,8 +5,16 @@ import { ControlSize, AccordionVariant } from "../../beans";
|
|
|
5
5
|
*
|
|
6
6
|
* @slot - Slot for the main content.
|
|
7
7
|
* @slot tag - Slot for tags.
|
|
8
|
-
* @cssprop --z-accordion-highlight-color - Color of the highlight band on the
|
|
9
|
-
* @cssprop --z-accordion-bg - Background color of the
|
|
8
|
+
* @cssprop --z-accordion-highlight-color - Color of the highlight band on the summary's left edge. Only applies when `highlight` is true. Default: `transparent`.
|
|
9
|
+
* @cssprop --z-accordion-bg - Background color of the summary. Default: `--color-surface02`.
|
|
10
|
+
* @cssprop --z-accordion-label-color - Label color. Default: `--color-text01`.
|
|
11
|
+
* @cssprop --z-accordion-disabled-label-color - Label color when disabled. Default: `--color-text03`.
|
|
12
|
+
* @cssprop --z-accordion-content-bg - Background color of the accordion. Default: `--color-surface02`.
|
|
13
|
+
* @cssprop --z-accordion-content-fg - Content text color. Default: `--color-text01`.
|
|
14
|
+
* @cssprop --z-accordion-hover-color - Hover color of the summary. Default: `--color-surface03`.
|
|
15
|
+
* @cssprop --z-accordion-left-padding - Left padding of the summary. Default: `--space-unit` * 2.
|
|
16
|
+
* @cssprop --z-accordion-right-padding - Right padding of the summary. Default: `--space-unit`.
|
|
17
|
+
* @cssprop --z-accordion-label-font-weight - Font weight of the summary label. Default: `--font-sb`.
|
|
10
18
|
*/
|
|
11
19
|
export class ZAccordion {
|
|
12
20
|
constructor() {
|
|
@@ -7,11 +7,18 @@
|
|
|
7
7
|
:host {
|
|
8
8
|
--z-accordion-highlight-color: transparent;
|
|
9
9
|
--z-accordion-bg: var(--color-surface01);
|
|
10
|
+
--z-accordion-label-color: var(--color-text01);
|
|
11
|
+
--z-accordion-disabled-label-color: var(--color-text03);
|
|
12
|
+
--z-accordion-content-bg: var(--color-surface01);
|
|
13
|
+
--z-accordion-content-fg: var(--color-text01);
|
|
14
|
+
--z-accordion-hover-color: var(--color-surface03);
|
|
15
|
+
--z-accordion-left-padding: calc(var(--space-unit) * 2);
|
|
16
|
+
--z-accordion-right-padding: var(--space-unit);
|
|
17
|
+
--z-accordion-label-font-weight: var(--font-sb);
|
|
10
18
|
|
|
11
19
|
display: block;
|
|
12
20
|
border-top: var(--border-size-small) solid var(--color-surface03);
|
|
13
21
|
border-bottom: var(--border-size-small) solid var(--color-surface03);
|
|
14
|
-
background-color: var(--z-accordion-bg);
|
|
15
22
|
font-family: var(--font-family-sans);
|
|
16
23
|
font-weight: var(--font-rg);
|
|
17
24
|
}
|
|
@@ -40,7 +47,9 @@ summary {
|
|
|
40
47
|
display: flex;
|
|
41
48
|
height: var(--summary-height);
|
|
42
49
|
align-items: center;
|
|
43
|
-
padding: var(--summary-y-padding) var(--
|
|
50
|
+
padding: var(--summary-y-padding) var(--z-accordion-right-padding) var(--summary-y-padding)
|
|
51
|
+
var(--z-accordion-left-padding);
|
|
52
|
+
background-color: var(--z-accordion-bg);
|
|
44
53
|
column-gap: var(--space-unit);
|
|
45
54
|
cursor: pointer;
|
|
46
55
|
list-style: none;
|
|
@@ -109,21 +118,21 @@ summary::before,
|
|
|
109
118
|
|
|
110
119
|
:host([is-disabled][highlight]) summary::before,
|
|
111
120
|
:host([is-disabled][highlight][variant="background"]) .z-accordion-content::before {
|
|
112
|
-
background-color: var(--color
|
|
121
|
+
background-color: var(--z-accordion-disabled-label-color);
|
|
113
122
|
}
|
|
114
123
|
|
|
115
124
|
summary > z-icon {
|
|
116
|
-
fill: var(--color
|
|
125
|
+
fill: var(--z-accordion-label-color);
|
|
117
126
|
}
|
|
118
127
|
|
|
119
128
|
:host([is-disabled]) summary > z-icon {
|
|
120
|
-
fill: var(--color
|
|
129
|
+
fill: var(--z-accordion-disabled-label-color);
|
|
121
130
|
}
|
|
122
131
|
|
|
123
132
|
.z-accordion-label {
|
|
124
|
-
color: var(--color
|
|
133
|
+
color: var(--z-accordion-label-color);
|
|
125
134
|
font-size: var(--font-size-3); /* for "small" and "big" sizes */
|
|
126
|
-
font-weight: var(--font-
|
|
135
|
+
font-weight: var(--z-accordion-label-font-weight);
|
|
127
136
|
}
|
|
128
137
|
|
|
129
138
|
:host([size="x-small"]) .z-accordion-label {
|
|
@@ -148,6 +157,8 @@ summary z-icon.z-accordion-chevron {
|
|
|
148
157
|
.z-accordion-content {
|
|
149
158
|
position: relative;
|
|
150
159
|
padding: var(--space-unit) var(--space-unit) calc(var(--space-unit) * 2) calc(var(--space-unit) * 2);
|
|
160
|
+
background-color: var(--z-accordion-content-bg);
|
|
161
|
+
color: var(--z-accordion-content-fg);
|
|
151
162
|
font-size: var(--font-size-2); /* for "small" and "big" sizes */
|
|
152
163
|
}
|
|
153
164
|
|
|
@@ -164,11 +175,11 @@ summary z-icon.z-accordion-chevron {
|
|
|
164
175
|
}
|
|
165
176
|
|
|
166
177
|
:host([is-disabled]) .z-accordion-label {
|
|
167
|
-
color: var(--color
|
|
178
|
+
color: var(--z-accordion-disabled-label-color);
|
|
168
179
|
}
|
|
169
180
|
|
|
170
181
|
:host([is-disabled]) .z-accordion-tags ::slotted(z-tag[slot="tag"]) {
|
|
171
|
-
--z-tag-bg: var(--color
|
|
182
|
+
--z-tag-bg: var(--z-accordion-disabled-label-color) !important;
|
|
172
183
|
--z-tag-text-color: var(--color-text-inverse) !important;
|
|
173
184
|
}
|
|
174
185
|
|
|
@@ -180,7 +191,7 @@ summary z-icon.z-accordion-chevron {
|
|
|
180
191
|
}
|
|
181
192
|
|
|
182
193
|
:host(:not([is-disabled])) summary:hover {
|
|
183
|
-
background-color: var(--color
|
|
194
|
+
background-color: var(--z-accordion-hover-color);
|
|
184
195
|
}
|
|
185
196
|
|
|
186
197
|
:host(:not([is-disabled])) summary:hover .z-accordion-label {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h, Host } from "@stencil/core";
|
|
2
|
-
import { CarouselArrowsPosition, CarouselProgressMode, ButtonVariant,
|
|
2
|
+
import { CarouselArrowsPosition, CarouselProgressMode, ButtonVariant, ControlSize } from "../../beans";
|
|
3
3
|
/**
|
|
4
4
|
* ZCarousel component.
|
|
5
5
|
* @cssprop --z-carousel-gutter - The gutter between items.
|
|
@@ -124,12 +124,16 @@ export class ZCarousel {
|
|
|
124
124
|
}
|
|
125
125
|
this.itemsContainer.addEventListener("scroll", this.checkNavigationValidity.bind(this), { passive: true });
|
|
126
126
|
this.checkNavigationValidity();
|
|
127
|
+
this.items.forEach((item) => {
|
|
128
|
+
item.setAttribute("role", "group");
|
|
129
|
+
item.setAttribute("aria-roledescription", "slide");
|
|
130
|
+
});
|
|
127
131
|
}
|
|
128
132
|
render() {
|
|
129
133
|
if (this.isLoading) {
|
|
130
134
|
return (h(Host, null, this.label && h("div", { class: "heading-4 z-carousel-title" }, this.label), h("div", { style: { height: `${this.ghostLoadingHeight}px` } }, h("z-ghost-loading", null), h("div", { class: "loading-items-container" }, h("slot", null)))));
|
|
131
135
|
}
|
|
132
|
-
return (h(Host, null, h("div", { class: "z-carousel-container" }, this.label && h("div", { class: "heading-4 z-carousel-title" }, this.label), h("div", { class: "z-carousel-wrapper" }, this.arrowsPosition === CarouselArrowsPosition.OVER && (h("z-button", { size:
|
|
136
|
+
return (h(Host, null, h("div", { class: "z-carousel-container", role: "group", "aria-roledescription": "carousel", "aria-label": this.label || "Carousel" }, this.label && h("div", { class: "heading-4 z-carousel-title" }, this.label), h("div", { class: "z-carousel-wrapper" }, this.arrowsPosition === CarouselArrowsPosition.OVER && (h("z-button", { size: ControlSize.SMALL, "data-direction": "prev", icon: "chevron-left", onClick: this.onPrev.bind(this), disabled: !this.canNavigatePrev, ariaLabel: this.single ? "Mostra l'elemento precedente" : "Mostra gli elementi precedenti" })), h("ul", { class: "z-carousel-items-container", "aria-atomic": "false", "aria-live": "polite" }, h("slot", null)), this.arrowsPosition === CarouselArrowsPosition.OVER && (h("z-button", { size: ControlSize.SMALL, "data-direction": "next", icon: "chevron-right", onClick: this.onNext.bind(this), disabled: !this.canNavigateNext, ariaLabel: this.single ? "Mostra l'elemento successivo" : "Mostra gli elementi successivi" })))), this.canShowFooter() && (h("div", { class: "z-carousel-footer" }, this.arrowsPosition === CarouselArrowsPosition.BOTTOM && (h("z-button", { size: ControlSize.SMALL, variant: ButtonVariant.TERTIARY, icon: "arrow-simple-left-filled", onClick: this.onPrev.bind(this), disabled: !this.canNavigatePrev, ariaLabel: this.single ? "Mostra l'elemento precedente" : "Mostra gli elementi precedenti" })), this.progressMode === CarouselProgressMode.DOTS && this.single && this.items && (h("div", { class: "dots-progress" }, this.items.map((_item, key) => (h("button", { type: "button", class: { current: this.highlightedIndicator === key }, "aria-label": this.highlightedIndicator === key ? "Elemento corrente" : `Spostati all'elemento ${key + 1}`, onClick: () => this.goTo(key) }, h("z-icon", { name: this.highlightedIndicator === key ? "white-circle-filled" : "black-circle-filled" })))))), this.progressMode === CarouselProgressMode.NUMBERS && this.single && this.items && (h("div", { class: "numbers-progress interactive-3" }, h("span", { class: "current" }, this.current + 1), h("span", null, "di"), h("span", null, this.items.length))), this.arrowsPosition === CarouselArrowsPosition.BOTTOM && (h("z-button", { size: ControlSize.SMALL, variant: ButtonVariant.TERTIARY, icon: "arrow-simple-right-filled", onClick: this.onNext.bind(this), disabled: !this.canNavigateNext, ariaLabel: this.single ? "Mostra l'elemento successivo" : "Mostra gli elementi successivi" }))))));
|
|
133
137
|
}
|
|
134
138
|
static get is() { return "z-carousel"; }
|
|
135
139
|
static get originalStyleUrls() {
|
|
@@ -31,11 +31,15 @@ const ZTd = class {
|
|
|
31
31
|
}
|
|
32
32
|
this.colspanChange.emit(this.colspan || 1);
|
|
33
33
|
}
|
|
34
|
+
onMenuButtonClick(ev) {
|
|
35
|
+
ev.stopPropagation();
|
|
36
|
+
this.popoverEl.open = !this.popoverEl.open;
|
|
37
|
+
}
|
|
34
38
|
componentWillLoad() {
|
|
35
39
|
this.updateColspan();
|
|
36
40
|
}
|
|
37
41
|
render() {
|
|
38
|
-
return (h(Host, { role: "cell", "menu-open": this.isMenuOpen }, h("slot", null), this.showMenu && (h("div", { class: "cell--menu-container prevent-expand" }, h("z-button", { variant: ButtonVariant.TERTIARY, icon: "contextual-menu", size: ControlSize.X_SMALL, ref: (el) => (this.menuTrigger = el), onClick:
|
|
42
|
+
return (h(Host, { role: "cell", "menu-open": this.isMenuOpen }, h("slot", null), this.showMenu && (h("div", { class: "cell--menu-container prevent-expand" }, h("z-button", { variant: ButtonVariant.TERTIARY, icon: "contextual-menu", size: ControlSize.X_SMALL, ref: (el) => (this.menuTrigger = el), onClick: this.onMenuButtonClick.bind(this) }), h("z-popover", { ref: (el) => (this.popoverEl = el), bindTo: this.menuTrigger, onOpenChange: (event) => (this.isMenuOpen = event.detail.open) }, h("slot", { name: "contextual-menu" }))))));
|
|
39
43
|
}
|
|
40
44
|
get host() { return getElement(this); }
|
|
41
45
|
static get watchers() { return {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-a2ca4b97.js';
|
|
2
2
|
import { r as randomId } from './utils-4d2d99d9.js';
|
|
3
|
-
import './index-
|
|
3
|
+
import './index-7081487e.js';
|
|
4
4
|
import './index-cfd94e05.js';
|
|
5
5
|
|
|
6
6
|
const stylesCss = ":host{--columns:1;display:grid;min-width:max-content;box-sizing:border-box;grid-auto-flow:column;grid-template-columns:var(--z-table--expand-button-size, 0) repeat(var(--columns), minmax(128px, 1fr))}*{box-sizing:border-box}.z-tr--expand-button-container,::slotted(*){border-bottom:var(--z-table--cells-bottom-border-size, var(--border-size-small)) solid var(--color-surface03)}::slotted(*:not(:last-child)){border-right:var(--z-table--cell-left-border, none)}:host([expandable]){--show-expandable-button:visible;cursor:pointer}:host([expandable]) ::slotted(*){grid-row:1}:host([expandable]) ::slotted(:nth-last-child(2)){border-right:none}:host([expandable]) ::slotted(*:last-child){border-left:0;grid-column:1 / span calc(var(--columns) + 1);grid-row:2}:host([expandable]:not([expanded])) ::slotted(*:last-child){display:none}:host([expanded]){margin-bottom:4px;box-shadow:0 4px 4px -2px var(--shadow-color-base)}:host([expanded]) .z-tr--expand-button-container,:host([expanded]) ::slotted(*){background-color:var(--color-surface02)}.z-tr--expand-button-container{display:flex;align-items:center;justify-content:center;background-color:var(--z-table--cells-background, var(--color-surface01))}.z-tr--expand-button-container button{display:flex;align-items:center;justify-content:center;padding:0;border:none;margin:auto;appearance:none;background:transparent;cursor:pointer;visibility:var(--show-expandable-button, hidden)}.z-tr--expand-button-container button:focus{box-shadow:var(--shadow-focus-primary);outline:none}.z-tr--expand-button-container button z-icon{--z-icon-width:16px;--z-icon-height:16px}";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as registerInstance, c as createEvent, h } from './index-a2ca4b97.js';
|
|
2
2
|
import { e as ControlSize, _ as AccordionVariant } from './index-03c8b0f0.js';
|
|
3
3
|
|
|
4
|
-
const stylesCss = ":host,:host *,:host ::slotted(*){box-sizing:border-box}:host{--z-accordion-highlight-color:transparent;--z-accordion-bg:var(--color-surface01);display:block;border-top:var(--border-size-small) solid var(--color-surface03);border-bottom:var(--border-size-small) solid var(--color-surface03);
|
|
4
|
+
const stylesCss = ":host,:host *,:host ::slotted(*){box-sizing:border-box}:host{--z-accordion-highlight-color:transparent;--z-accordion-bg:var(--color-surface01);--z-accordion-label-color:var(--color-text01);--z-accordion-disabled-label-color:var(--color-text03);--z-accordion-content-bg:var(--color-surface01);--z-accordion-content-fg:var(--color-text01);--z-accordion-hover-color:var(--color-surface03);--z-accordion-left-padding:calc(var(--space-unit) * 2);--z-accordion-right-padding:var(--space-unit);--z-accordion-label-font-weight:var(--font-sb);display:block;border-top:var(--border-size-small) solid var(--color-surface03);border-bottom:var(--border-size-small) solid var(--color-surface03);font-family:var(--font-family-sans);font-weight:var(--font-rg)}:host([variant=\"background\"]){border:var(--border-size-small) solid var(--color-surface03);border-radius:var(--border-radius)}:host([variant=\"background\"][shadow]){box-shadow:var(--shadow-2)}details{background-color:transparent}summary{--summary-x-small-height:32px;--summary-small-height:36px;--summary-big-height:44px;--summary-height:var(--summary-big-height);--summary-y-padding:var(--space-unit);position:relative;display:flex;height:var(--summary-height);align-items:center;padding:var(--summary-y-padding) var(--z-accordion-right-padding) var(--summary-y-padding)\n var(--z-accordion-left-padding);background-color:var(--z-accordion-bg);column-gap:var(--space-unit);cursor:pointer;list-style:none}:host([size=\"x-small\"]) summary{--summary-height:var(--summary-x-small-height)}:host([size=\"small\"]) summary{--summary-height:var(--summary-small-height)}:host(:is([size=\"x-small\"],[size=\"small\"])) summary{--summary-y-padding:calc(var(--space-unit) / 2)}:host([variant=\"background\"]) summary{padding-right:calc(var(--space-unit) * 2);border-radius:calc(var(--border-radius) - var(--border-size-small))}:host([variant=\"background\"][open]) summary{border-bottom-left-radius:0;border-bottom-right-radius:0}:host([is-disabled]) summary{cursor:default}summary:focus:focus-visible{background-color:var(--color-surface03);box-shadow:var(--shadow-focus-primary);outline:none}summary::before,:host([highlight][variant=\"background\"]) .z-accordion-content::before{position:absolute;top:0;left:0;display:block;width:var(--space-unit);height:100%;content:\"\"}:host([highlight][variant=\"background\"]) summary::before{border-top-left-radius:calc(var(--border-radius) - var(--border-size-small))}:host([highlight][variant=\"background\"]:not([open])) summary::before,:host([highlight][variant=\"background\"][open]) .z-accordion-content::before{border-bottom-left-radius:calc(var(--border-radius) - var(--border-size-small))}:host([highlight]) summary::before,:host([highlight][variant=\"background\"]) .z-accordion-content::before{background-color:var(--z-accordion-highlight-color, transparent)}:host([is-disabled][highlight]) summary::before,:host([is-disabled][highlight][variant=\"background\"]) .z-accordion-content::before{background-color:var(--z-accordion-disabled-label-color)}summary>z-icon{fill:var(--z-accordion-label-color)}:host([is-disabled]) summary>z-icon{fill:var(--z-accordion-disabled-label-color)}.z-accordion-label{color:var(--z-accordion-label-color);font-size:var(--font-size-3);font-weight:var(--z-accordion-label-font-weight)}:host([size=\"x-small\"]) .z-accordion-label{font-size:var(--font-size-2)}:host([size=\"x-small\"]) :is(.z-accordion-label-icon,.z-accordion-chevron){--z-icon-width:16px;--z-icon-height:16px}.z-accordion-tags{display:flex;align-items:center;column-gap:calc(var(--space-unit) / 2)}summary z-icon.z-accordion-chevron{margin-left:auto}.z-accordion-content{position:relative;padding:var(--space-unit) var(--space-unit) calc(var(--space-unit) * 2) calc(var(--space-unit) * 2);background-color:var(--z-accordion-content-bg);color:var(--z-accordion-content-fg);font-size:var(--font-size-2);}:host(:is([size=\"x-small\"],[size=\"small\"])) .z-accordion-content{padding-bottom:var(--space-unit)}:host([size=\"x-small\"]) .z-accordion-content{font-size:var(--font-size-1)}:host([variant=\"background\"]) .z-accordion-content{padding-right:calc(var(--space-unit) * 2)}:host([is-disabled]) .z-accordion-label{color:var(--z-accordion-disabled-label-color)}:host([is-disabled]) .z-accordion-tags ::slotted(z-tag[slot=\"tag\"]){--z-tag-bg:var(--z-accordion-disabled-label-color) !important;--z-tag-text-color:var(--color-text-inverse) !important}@media (hover: hover){summary:focus:focus-visible{position:relative;z-index:1}:host(:not([is-disabled])) summary:hover{background-color:var(--z-accordion-hover-color)}:host(:not([is-disabled])) summary:hover .z-accordion-label{text-decoration:underline}}@media (hover: none){:host([size]) summary{--summary-height:var(--summary-big-height);--summary-y-padding:var(--space-unit)}:host([size]) .z-accordion-label{font-size:var(--font-size-3)}:host([size]) .z-accordion-content{font-size:var(--font-size-2)}:host([size]) :is(.z-accordion-label-icon,.z-accordion-chevron){--z-icon-width:18px;--z-icon-height:18px}}z-accordion+z-accordion{border-top:none}z-accordion[variant=\"background\"]+z-accordion[variant=\"background\"]{border-radius:0}z-accordion[variant=\"background\"]:first-of-type:not(:last-of-type){border-bottom-left-radius:0;border-bottom-right-radius:0}z-accordion[variant=\"background\"]+z-accordion[variant=\"background\"]:last-of-type{border-bottom-left-radius:var(--border-radius);border-bottom-right-radius:var(--border-radius)}z-accordion[variant=\"background\"]:first-of-type:not(:last-of-type)::part(summary){border-bottom-left-radius:0;border-bottom-right-radius:0}z-accordion[variant=\"background\"]+z-accordion[variant=\"background\"]::part(summary){border-radius:0}z-accordion[variant=\"background\"]+z-accordion[variant=\"background\"]:last-of-type:not([open])::part(summary){border-bottom-left-radius:calc(var(--border-radius) - var(--border-size-small));border-bottom-right-radius:calc(var(--border-radius) - var(--border-size-small))}";
|
|
5
5
|
|
|
6
6
|
const ZAccordion = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-a2ca4b97.js';
|
|
2
|
-
import { R as CarouselArrowsPosition, U as CarouselProgressMode,
|
|
2
|
+
import { R as CarouselArrowsPosition, U as CarouselProgressMode, e as ControlSize, B as ButtonVariant } from './index-03c8b0f0.js';
|
|
3
3
|
|
|
4
4
|
const stylesCss = "z-carousel{font-family:var(--font-family-sans);font-weight:var(--font-rg);--z-carousel-gutter:0}z-carousel[single],z-carousel[single=\"true\"]{display:flex;flex-direction:column;align-items:center;justify-content:center}z-carousel[single=\"true\"] .z-carousel-container,z-carousel[single] .z-carousel-container{width:fit-content;max-width:100%}z-carousel .loading-items-container{display:none}z-carousel .z-carousel-container{display:flex;flex-direction:column}z-carousel .z-carousel-wrapper{position:relative}z-carousel .z-carousel-title{margin-bottom:var(--space-unit);color:var(--gray800)}z-carousel .z-carousel-items-container{display:flex;max-width:100%;flex-direction:row;margin:0;list-style:none;-ms-overflow-style:none;overflow-x:scroll;padding-inline-start:0;scroll-snap-type:x mandatory;scrollbar-width:none;}z-carousel .z-carousel-items-container::-webkit-scrollbar{display:none}z-carousel .z-carousel-items-container>*:not(:last-child){margin-right:var(--z-carousel-gutter)}z-carousel[single=\"true\"] .z-carousel-items-container>*:not(:last-child),z-carousel[single] .z-carousel-items-container>*:not(:last-child){margin-right:0}z-carousel .z-carousel-items-container>li{scroll-snap-align:center}z-button[data-direction]{--z-icon-width:32px;--z-icon-height:32px;position:absolute;bottom:50%;transform:translateY(50%)}z-button[data-direction=\"next\"]{right:0}z-carousel .z-carousel-footer{display:flex;flex-direction:row;align-items:center;justify-content:center;margin-top:var(--space-unit)}z-carousel .z-carousel-footer .numbers-progress,z-carousel .z-carousel-footer .dots-progress{display:flex;align-items:center;justify-content:center}z-carousel .z-carousel-footer .dots-progress button{display:flex;align-items:center;padding:0;border:none;margin:0;background-color:transparent}z-carousel .z-carousel-footer .dots-progress button:not(.current){cursor:pointer}z-carousel .z-carousel-footer .numbers-progress{margin:0 calc(var(--space-unit) / 2);column-gap:calc(var(--space-unit) / 2)}z-carousel .z-carousel-footer .numbers-progress .current{font-weight:var(--font-sb)}z-carousel .z-carousel-footer .dots-progress button.current z-icon{fill:var(--gray800)}z-carousel .z-carousel-footer .dots-progress button:not(.current) z-icon{fill:var(--gray200)}";
|
|
5
5
|
|
|
@@ -124,12 +124,16 @@ const ZCarousel = class {
|
|
|
124
124
|
}
|
|
125
125
|
this.itemsContainer.addEventListener("scroll", this.checkNavigationValidity.bind(this), { passive: true });
|
|
126
126
|
this.checkNavigationValidity();
|
|
127
|
+
this.items.forEach((item) => {
|
|
128
|
+
item.setAttribute("role", "group");
|
|
129
|
+
item.setAttribute("aria-roledescription", "slide");
|
|
130
|
+
});
|
|
127
131
|
}
|
|
128
132
|
render() {
|
|
129
133
|
if (this.isLoading) {
|
|
130
134
|
return (h(Host, null, this.label && h("div", { class: "heading-4 z-carousel-title" }, this.label), h("div", { style: { height: `${this.ghostLoadingHeight}px` } }, h("z-ghost-loading", null), h("div", { class: "loading-items-container" }, h("slot", null)))));
|
|
131
135
|
}
|
|
132
|
-
return (h(Host, null, h("div", { class: "z-carousel-container" }, this.label && h("div", { class: "heading-4 z-carousel-title" }, this.label), h("div", { class: "z-carousel-wrapper" }, this.arrowsPosition === CarouselArrowsPosition.OVER && (h("z-button", { size:
|
|
136
|
+
return (h(Host, null, h("div", { class: "z-carousel-container", role: "group", "aria-roledescription": "carousel", "aria-label": this.label || "Carousel" }, this.label && h("div", { class: "heading-4 z-carousel-title" }, this.label), h("div", { class: "z-carousel-wrapper" }, this.arrowsPosition === CarouselArrowsPosition.OVER && (h("z-button", { size: ControlSize.SMALL, "data-direction": "prev", icon: "chevron-left", onClick: this.onPrev.bind(this), disabled: !this.canNavigatePrev, ariaLabel: this.single ? "Mostra l'elemento precedente" : "Mostra gli elementi precedenti" })), h("ul", { class: "z-carousel-items-container", "aria-atomic": "false", "aria-live": "polite" }, h("slot", null)), this.arrowsPosition === CarouselArrowsPosition.OVER && (h("z-button", { size: ControlSize.SMALL, "data-direction": "next", icon: "chevron-right", onClick: this.onNext.bind(this), disabled: !this.canNavigateNext, ariaLabel: this.single ? "Mostra l'elemento successivo" : "Mostra gli elementi successivi" })))), this.canShowFooter() && (h("div", { class: "z-carousel-footer" }, this.arrowsPosition === CarouselArrowsPosition.BOTTOM && (h("z-button", { size: ControlSize.SMALL, variant: ButtonVariant.TERTIARY, icon: "arrow-simple-left-filled", onClick: this.onPrev.bind(this), disabled: !this.canNavigatePrev, ariaLabel: this.single ? "Mostra l'elemento precedente" : "Mostra gli elementi precedenti" })), this.progressMode === CarouselProgressMode.DOTS && this.single && this.items && (h("div", { class: "dots-progress" }, this.items.map((_item, key) => (h("button", { type: "button", class: { current: this.highlightedIndicator === key }, "aria-label": this.highlightedIndicator === key ? "Elemento corrente" : `Spostati all'elemento ${key + 1}`, onClick: () => this.goTo(key) }, h("z-icon", { name: this.highlightedIndicator === key ? "white-circle-filled" : "black-circle-filled" })))))), this.progressMode === CarouselProgressMode.NUMBERS && this.single && this.items && (h("div", { class: "numbers-progress interactive-3" }, h("span", { class: "current" }, this.current + 1), h("span", null, "di"), h("span", null, this.items.length))), this.arrowsPosition === CarouselArrowsPosition.BOTTOM && (h("z-button", { size: ControlSize.SMALL, variant: ButtonVariant.TERTIARY, icon: "arrow-simple-right-filled", onClick: this.onNext.bind(this), disabled: !this.canNavigateNext, ariaLabel: this.single ? "Mostra l'elemento successivo" : "Mostra gli elementi successivi" }))))));
|
|
133
137
|
}
|
|
134
138
|
get hostElement() { return getElement(this); }
|
|
135
139
|
static get watchers() { return {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host, g as getElement } from './index-a2ca4b97.js';
|
|
2
2
|
import { N as NavigationTabsOrientation, a as NavigationTabsSize, g as KeyboardCode, b as NavigationTabsKeyboardEvents } from './index-03c8b0f0.js';
|
|
3
3
|
|
|
4
|
-
const stylesCss = ":host{position:relative;z-index:0;display:flex;overflow:hidden;flex-direction:row;font-family:var(--font-family-sans);font-weight:var(--font-rg)}:host,:host *,::slotted(*){box-sizing:border-box}::-webkit-scrollbar{display:none}.navigation-button{position:absolute;z-index:1;display:flex;align-items:center;justify-content:center;padding:0;border:none;margin:0;background:var(--
|
|
4
|
+
const stylesCss = ":host{--z-navigation-tabs-nav-buttons-bg:var(--color-white);--z-navigation-tabs-nav-buttons-fg:var(--color-primary01);position:relative;z-index:0;display:flex;overflow:hidden;flex-direction:row;font-family:var(--font-family-sans);font-weight:var(--font-rg)}:host,:host *,::slotted(*){box-sizing:border-box}::-webkit-scrollbar{display:none}.navigation-button{position:absolute;z-index:1;display:flex;align-items:center;justify-content:center;padding:0;border:none;margin:0;background:var(--z-navigation-tabs-nav-buttons-bg);border-radius:var(--border-no-radius);box-shadow:0 0 4px 1px var(--shadow-color-base);cursor:pointer;fill:var(--z-navigation-tabs-nav-buttons-fg);outline:none}.navigation-button:disabled{display:none}nav{display:flex;overflow:auto;align-items:center;justify-content:flex-start;scroll-behavior:smooth;scrollbar-width:none}:host([orientation=\"horizontal\"]) nav{width:100%}:host([orientation=\"horizontal\"]) .navigation-button{top:0;width:calc(var(--space-unit) * 4);height:100%}:host([orientation=\"horizontal\"]) .navigation-button:first-child{left:0}:host([orientation=\"horizontal\"]) .navigation-button:last-child{right:0}:host([orientation=\"vertical\"]){width:fit-content;flex-direction:column}:host([orientation=\"vertical\"]) nav{height:100%;flex-direction:column;align-items:stretch}:host([orientation=\"vertical\"]) .navigation-button{left:0;width:100%;height:calc(var(--space-unit) * 4)}:host([orientation=\"vertical\"]) .navigation-button:first-child{top:0}:host([orientation=\"vertical\"]) .navigation-button:last-child{bottom:0}:host([size=\"small\"][orientation=\"vertical\"]) .navigation-button{height:calc(var(--space-unit) * 4)}";
|
|
5
5
|
|
|
6
6
|
const ZNavigationTabs = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -170,9 +170,9 @@ const ZNavigationTabs = class {
|
|
|
170
170
|
return (h(Host, { class: {
|
|
171
171
|
"interactive-2": this.size === NavigationTabsSize.SMALL,
|
|
172
172
|
"interactive-1": this.size !== NavigationTabsSize.SMALL,
|
|
173
|
-
}, scrollable: this.canNavigate }, this.canNavigate && (h("button", { class: "navigation-button", onClick: this.navigateBackwards.bind(this), tabindex: "-1", disabled: !this.canNavigatePrev }, h("z-icon", { name: this.orientation === NavigationTabsOrientation.HORIZONTAL ? "chevron-left" : "chevron-up", width: 16, height: 16 }))), h("nav", { role: "tablist", "aria-label": this.ariaLabel, ref: (el) => (this.tabsNav = el !== null && el !== void 0 ? el : this.tabsNav), onScroll: this.checkScrollEnabled.bind(this), "aria-orientation": this.orientation }, h("slot", null)), this.canNavigate && (h("button", { class: "navigation-button", onClick: this.navigateForward.bind(this), onKeyDown: (e) => {
|
|
173
|
+
}, scrollable: this.canNavigate }, this.canNavigate && (h("button", { class: "navigation-button", onClick: this.navigateBackwards.bind(this), tabindex: "-1", disabled: !this.canNavigatePrev, "aria-label": "Mostra elementi precedenti" }, h("z-icon", { name: this.orientation === NavigationTabsOrientation.HORIZONTAL ? "chevron-left" : "chevron-up", width: 16, height: 16 }))), h("nav", { role: "tablist", "aria-label": this.ariaLabel, ref: (el) => (this.tabsNav = el !== null && el !== void 0 ? el : this.tabsNav), onScroll: this.checkScrollEnabled.bind(this), "aria-orientation": this.orientation }, h("slot", null)), this.canNavigate && (h("button", { class: "navigation-button", onClick: this.navigateForward.bind(this), onKeyDown: (e) => {
|
|
174
174
|
this.navigateThroughTabs(e);
|
|
175
|
-
}, tabindex: "-1", disabled: !this.canNavigateNext }, h("z-icon", { name: this.orientation === NavigationTabsOrientation.HORIZONTAL ? "chevron-right" : "chevron-down", width: 16, height: 16 })))));
|
|
175
|
+
}, tabindex: "-1", disabled: !this.canNavigateNext, "aria-label": "Mostra elementi successivi" }, h("z-icon", { name: this.orientation === NavigationTabsOrientation.HORIZONTAL ? "chevron-right" : "chevron-down", width: 16, height: 16 })))));
|
|
176
176
|
}
|
|
177
177
|
get host() { return getElement(this); }
|
|
178
178
|
static get watchers() { return {
|
|
@@ -22,7 +22,7 @@ const ZPanelElem = class {
|
|
|
22
22
|
"z-link": true,
|
|
23
23
|
"z-link-disabled": this.isdisabled,
|
|
24
24
|
"z-link-icon": true,
|
|
25
|
-
}, id: elemId + "link_id", href: this.url, target: this.target }, h("z-icon", {
|
|
25
|
+
}, id: elemId + "link_id", href: this.url, target: this.target }, h("z-icon", { height: 14, width: 14, name: this.linkicon }), this.linklabel)), this.descrSlotName && (h("div", { class: "panel-elem-desc" }, h("slot", { name: this.descrSlotName })))));
|
|
26
26
|
}
|
|
27
27
|
};
|
|
28
28
|
ZPanelElem.style = stylesCss;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host, g as getElement } from './index-a2ca4b97.js';
|
|
2
2
|
import './index-6d83248c.js';
|
|
3
3
|
import './index-f171ca51.js';
|
|
4
|
-
import './index-
|
|
4
|
+
import './index-8009e286.js';
|
|
5
5
|
import './index-8c7b48bc.js';
|
|
6
6
|
import './utils-4d2d99d9.js';
|
|
7
7
|
import './index-03c8b0f0.js';
|
|
8
8
|
import './breakpoints-9b81eb1b.js';
|
|
9
|
-
import './index-
|
|
9
|
+
import './index-7081487e.js';
|
|
10
10
|
import './index-cfd94e05.js';
|
|
11
11
|
|
|
12
12
|
const stylesCss = ":host{--z-table--cells-padding:calc(var(--space-unit) * 2);position:relative;display:block;overflow:auto;max-width:100%;box-sizing:border-box;background-color:var(--color-surface01)}:host([expandable]){--z-table--expand-button-size:40px}:host([bordered]){--z-table--cell-left-border:1px solid var(--color-surface03)}.table{min-width:max-content}";
|
package/dist/esm/z-td.entry.js
CHANGED
package/dist/esm/z-tr.entry.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { Z as z_tr } from './index-
|
|
1
|
+
export { Z as z_tr } from './index-8009e286.js';
|
|
2
2
|
import './index-a2ca4b97.js';
|
|
3
3
|
import './utils-4d2d99d9.js';
|
|
4
4
|
import './index-03c8b0f0.js';
|
|
5
5
|
import './breakpoints-9b81eb1b.js';
|
|
6
|
-
import './index-
|
|
6
|
+
import './index-7081487e.js';
|
|
7
7
|
import './index-cfd94e05.js';
|