@ganpatiinfo/gids-core-web 8.2.0 → 10.0.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/dist/css/index.css +1919 -0
- package/dist/css/index.css.map +1 -1
- package/dist/custom-elements.json +332 -0
- package/dist/gids-activity-gauge.d.ts +11 -0
- package/dist/gids-activity-gauge.js +1 -0
- package/dist/gids-bar-chart.d.ts +11 -0
- package/dist/gids-bar-chart.js +1 -0
- package/dist/gids-calendar-header-panel.d.ts +11 -0
- package/dist/gids-calendar-header-panel.js +1 -0
- package/dist/gids-calendar-month-list.d.ts +11 -0
- package/dist/gids-calendar-month-list.js +1 -0
- package/dist/gids-calendar-year-list.d.ts +11 -0
- package/dist/gids-calendar-year-list.js +1 -0
- package/dist/gids-calendar.d.ts +11 -0
- package/dist/gids-calendar.js +1 -0
- package/dist/gids-chart-legend-item.d.ts +11 -0
- package/dist/gids-chart-legend-item.js +1 -0
- package/dist/gids-chart-legend.d.ts +11 -0
- package/dist/gids-chart-legend.js +1 -0
- package/dist/gids-chart.d.ts +11 -0
- package/dist/gids-chart.js +1 -0
- package/dist/gids-chevron-button.d.ts +11 -0
- package/dist/gids-chevron-button.js +1 -0
- package/dist/gids-dot.d.ts +11 -0
- package/dist/gids-dot.js +1 -0
- package/dist/gids-dropdown-field.d.ts +11 -0
- package/dist/gids-dropdown-field.js +1 -0
- package/dist/gids-dropdown-picker.d.ts +11 -0
- package/dist/gids-dropdown-picker.js +1 -0
- package/dist/gids-dropdown.d.ts +11 -0
- package/dist/gids-dropdown.js +1 -0
- package/dist/gids-field.d.ts +1 -1
- package/dist/gids-field.js +1 -1
- package/dist/gids-icon.d.ts +1 -1
- package/dist/gids-icon.js +1 -1
- package/dist/gids-input.d.ts +1 -1
- package/dist/gids-input.js +1 -1
- package/dist/gids-level-gauge.d.ts +11 -0
- package/dist/gids-level-gauge.js +1 -0
- package/dist/gids-line-chart.d.ts +11 -0
- package/dist/gids-line-chart.js +1 -0
- package/dist/gids-notification.d.ts +1 -1
- package/dist/gids-notification.js +1 -1
- package/dist/gids-overflow-container.d.ts +1 -1
- package/dist/gids-overflow-container.js +1 -1
- package/dist/gids-overlay-provider.d.ts +1 -1
- package/dist/gids-overlay-provider.js +1 -1
- package/dist/gids-password-field.d.ts +1 -1
- package/dist/gids-password-field.js +1 -1
- package/dist/gids-pie-chart.d.ts +11 -0
- package/dist/gids-pie-chart.js +1 -0
- package/dist/gids-popover.d.ts +11 -0
- package/dist/gids-popover.js +1 -0
- package/dist/gids-progress-circle.d.ts +11 -0
- package/dist/gids-progress-circle.js +1 -0
- package/dist/gids-scrim.d.ts +1 -1
- package/dist/gids-scrim.js +1 -1
- package/dist/gids-snackbar.d.ts +1 -1
- package/dist/gids-snackbar.js +1 -1
- package/dist/gids-text-field.d.ts +1 -1
- package/dist/gids-text-field.js +1 -1
- package/dist/gids-toggle-button.d.ts +1 -1
- package/dist/gids-toggle-button.js +1 -1
- package/dist/gids-tooltip.d.ts +11 -0
- package/dist/gids-tooltip.js +1 -0
- package/dist/index.js +1 -1
- package/dist/p-9_mrQ7ac.js +1 -0
- package/dist/p-B81J5HCC.js +1 -0
- package/dist/p-B8kX8Vqv.js +1 -0
- package/dist/p-BFHWXEeg.js +1 -0
- package/dist/p-B_HaXpJZ.js +1 -0
- package/dist/p-BaO-kEWS.js +1 -0
- package/dist/p-BiPAgxAQ.js +1 -0
- package/dist/p-Bmb-HiXg.js +1 -0
- package/dist/{p-veoOgDXg.js → p-BnL97lOW.js} +1 -1
- package/dist/{p-DjvDBWCb.js → p-BvYnawkJ.js} +1 -1
- package/dist/p-CIP0xyhD.js +1 -0
- package/dist/p-CJzporPT.js +1 -0
- package/dist/p-CPSHPtGE.js +1 -0
- package/dist/p-CRngHsR7.js +1 -0
- package/dist/p-Ct3Ixgvf.js +1 -0
- package/dist/p-D93TNeOt.js +1 -0
- package/dist/p-DKsrt7dx.js +1 -0
- package/dist/p-DZWWuJac.js +1 -0
- package/dist/p-D_wcwB7E.js +1 -0
- package/dist/p-Dehss-X0.js +1 -0
- package/dist/{p-Bg3lw2Ae.js → p-DfFqFdmS.js} +1 -1
- package/dist/p-KxRqlvSh.js +1 -0
- package/dist/p-MgTlrSP_.js +1 -0
- package/dist/p-a3JfEYJp.js +1 -0
- package/dist/p-h6alWGT8.js +1 -0
- package/dist/p-quZYWCxU.js +1 -0
- package/dist/p-tyIgTtUC.js +1 -0
- package/dist/p-uqSjmNkw.js +1 -0
- package/dist/types/components/html/GidsButton/GidsButton.d.ts +1 -1
- package/dist/types/components/html/GidsCalendarCell/GidsCalendarCell.d.ts +7 -0
- package/dist/types/components/html/GidsCalendarDayCell/GidsCalendarDayCell.d.ts +4 -0
- package/dist/types/components/html/GidsDropdownItem/GidsDropdownItem.d.ts +9 -0
- package/dist/types/components/html/GidsDropdownMenu/GidsDropdownMenu.d.ts +6 -0
- package/dist/types/components/html/GidsDropdownMenuGroup/GidsDropdownMenuGroup.d.ts +5 -0
- package/dist/types/components/html/GidsEditButton/GidsEditButton.d.ts +7 -0
- package/dist/types/components/html/GidsListItem/GidsListItem.d.ts +11 -0
- package/dist/types/components/html/GidsMenu/GidsMenu.d.ts +6 -0
- package/dist/types/components/html/GidsMenuGroup/GidsMenuGroup.d.ts +5 -0
- package/dist/types/components/html/GidsPageTitle/GidsPageTitle.d.ts +4 -0
- package/dist/types/components/shared/GidsFloatingElementManager.d.ts +57 -0
- package/dist/types/components/shared/GidsFloatingElementTypes.d.ts +4 -0
- package/dist/types/components/webComponents/GidsActivityGauge/GidsActivityGauge.d.ts +23 -0
- package/dist/types/components/webComponents/GidsBarChart/GidsBarChart.d.ts +27 -0
- package/dist/types/components/webComponents/GidsCalendar/GidsCalendar.d.ts +34 -0
- package/dist/types/components/webComponents/GidsCalendarHeaderPanel/GidsCalendarHeaderPanel.d.ts +67 -0
- package/dist/types/components/webComponents/GidsCalendarMonthList/GidsCalendarMonthList.d.ts +26 -0
- package/dist/types/components/webComponents/GidsCalendarYearList/GidsCalendarYearList.d.ts +31 -0
- package/dist/types/components/webComponents/GidsChart/GidsChart.d.ts +19 -0
- package/dist/types/components/webComponents/GidsChartLegend/GidsChartLegend.d.ts +7 -0
- package/dist/types/components/webComponents/GidsChartLegendItem/GidsChartLegendItem.d.ts +9 -0
- package/dist/types/components/webComponents/GidsChevronButton/GidsChevronButton.d.ts +21 -0
- package/dist/types/components/webComponents/GidsDot/GidsDot.d.ts +17 -0
- package/dist/types/components/webComponents/GidsDropdown/GidsDropdown.d.ts +78 -0
- package/dist/types/components/webComponents/GidsDropdownField/GidsDropdownField.d.ts +37 -0
- package/dist/types/components/webComponents/GidsDropdownPicker/GidsDropdownPicker.d.ts +52 -0
- package/dist/types/components/webComponents/GidsLevelGauge/GidsLevelGauge.d.ts +22 -0
- package/dist/types/components/webComponents/GidsLineChart/GidsLineChart.d.ts +27 -0
- package/dist/types/components/webComponents/GidsPieChart/GidsPieChart.d.ts +23 -0
- package/dist/types/components/webComponents/GidsPopover/GidsPopover.d.ts +24 -0
- package/dist/types/components/webComponents/GidsProgressCircle/GidsProgressCircle.d.ts +24 -0
- package/dist/types/components/webComponents/GidsTooltip/GidsTooltip.d.ts +23 -0
- package/dist/types/components.d.ts +1420 -64
- package/dist/types/index.d.ts +2 -0
- package/dist/types/utils/childrenValidityUtils.d.ts +8 -0
- package/dist-bundled/es/gids-activity-gauge.js +6 -0
- package/dist-bundled/es/gids-bar-chart.js +6 -0
- package/dist-bundled/es/gids-calendar-header-panel.js +6 -0
- package/dist-bundled/es/gids-calendar-month-list.js +6 -0
- package/dist-bundled/es/gids-calendar-year-list.js +6 -0
- package/dist-bundled/es/gids-calendar.js +153 -0
- package/dist-bundled/es/gids-chart-legend-item.js +6 -0
- package/dist-bundled/es/gids-chart-legend.js +6 -0
- package/dist-bundled/es/gids-chart.js +108 -0
- package/dist-bundled/es/gids-chevron-button.js +56 -0
- package/dist-bundled/es/gids-dot.js +6 -0
- package/dist-bundled/es/gids-dropdown-field.js +88 -0
- package/dist-bundled/es/gids-dropdown-picker.js +6 -0
- package/dist-bundled/es/gids-dropdown.js +6 -0
- package/dist-bundled/es/gids-field.js +1 -1
- package/dist-bundled/es/gids-icon.js +4 -30
- package/dist-bundled/es/gids-input.js +4 -4
- package/dist-bundled/es/gids-level-gauge.js +6 -0
- package/dist-bundled/es/gids-line-chart.js +6 -0
- package/dist-bundled/es/gids-notification.js +1 -1
- package/dist-bundled/es/gids-overflow-container.js +9 -9
- package/dist-bundled/es/gids-overlay-provider.js +17 -17
- package/dist-bundled/es/gids-password-field.js +21 -20
- package/dist-bundled/es/gids-pie-chart.js +6 -0
- package/dist-bundled/es/gids-popover.js +110 -0
- package/dist-bundled/es/gids-progress-circle.js +6 -0
- package/dist-bundled/es/gids-scrim.js +7 -7
- package/dist-bundled/es/gids-snackbar.js +1 -1
- package/dist-bundled/es/gids-text-field.js +14 -13
- package/dist-bundled/es/gids-toggle-button.js +8 -8
- package/dist-bundled/es/gids-tooltip.js +66 -0
- package/dist-bundled/es/index.js +33 -19
- package/dist-bundled/es/p-9_mrQ7ac-If6e6cvJ.js +71 -0
- package/dist-bundled/es/p-B81J5HCC-Bkt2yXKi.js +47 -0
- package/dist-bundled/es/p-B8kX8Vqv-trBz4jdS.js +7 -0
- package/dist-bundled/es/p-BFHWXEeg-ByjSjz8i.js +133 -0
- package/dist-bundled/es/p-B_HaXpJZ-a2SDgQ0E.js +37 -0
- package/dist-bundled/es/p-BaO-kEWS-ZITkeP-j.js +241 -0
- package/dist-bundled/es/p-BiPAgxAQ-BtMBQpJY.js +31 -0
- package/dist-bundled/es/p-Bmb-HiXg-MyHWdhpw.js +80 -0
- package/dist-bundled/es/{p-veoOgDXg-DElc87c0.js → p-BnL97lOW-BO0p4EdC.js} +20 -13
- package/dist-bundled/es/{p-DjvDBWCb-C9js0PPL.js → p-BvYnawkJ-DohV9UNG.js} +10 -10
- package/dist-bundled/es/p-CIP0xyhD-D6y5soLj.js +180 -0
- package/dist-bundled/es/p-CJzporPT-I_OdjJsQ.js +92 -0
- package/dist-bundled/es/p-CPSHPtGE-C7baJgXR.js +115 -0
- package/dist-bundled/es/p-CRngHsR7-DL9wz3Z3.js +25 -0
- package/dist-bundled/es/p-Ct3Ixgvf-CNP_PKwP.js +646 -0
- package/dist-bundled/es/p-D93TNeOt-Vvshbux8.js +88 -0
- package/dist-bundled/es/{p-DybsMR13-DpmsG3Q1.js → p-DKsrt7dx-ImYLc4xz.js} +1 -1
- package/dist-bundled/es/p-DZWWuJac-DNQvnHAr.js +15 -0
- package/dist-bundled/es/p-D_wcwB7E-d3jYxfod.js +20 -0
- package/dist-bundled/es/p-Dehss-X0-Di5vMgvd.js +29 -0
- package/dist-bundled/es/{p-Bg3lw2Ae-CkC8nUqv.js → p-DfFqFdmS-DjI2pk-0.js} +6 -6
- package/dist-bundled/es/p-KxRqlvSh-JOFDmT0B.js +25 -0
- package/dist-bundled/es/p-MgTlrSP_-DifRVv94.js +70 -0
- package/dist-bundled/es/p-a3JfEYJp-DyhDK6VZ.js +1128 -0
- package/dist-bundled/es/p-h6alWGT8-CSY2g3c8.js +67 -0
- package/dist-bundled/es/p-quZYWCxU-CPyWW0nv.js +56 -0
- package/dist-bundled/es/p-tyIgTtUC-C8jR4A5G.js +71 -0
- package/dist-bundled/es/p-uqSjmNkw-Cz2T86sC.js +55 -0
- package/dist-bundled/umd/gids-activity-gauge.umd.js +5 -0
- package/dist-bundled/umd/gids-bar-chart.umd.js +13 -0
- package/dist-bundled/umd/gids-calendar-header-panel.umd.js +5 -0
- package/dist-bundled/umd/gids-calendar-month-list.umd.js +5 -0
- package/dist-bundled/umd/gids-calendar-year-list.umd.js +5 -0
- package/dist-bundled/umd/gids-calendar.umd.js +5 -0
- package/dist-bundled/umd/gids-chart-legend-item.umd.js +5 -0
- package/dist-bundled/umd/gids-chart-legend.umd.js +5 -0
- package/dist-bundled/umd/gids-chart.umd.js +13 -0
- package/dist-bundled/umd/gids-chevron-button.umd.js +5 -0
- package/dist-bundled/umd/gids-dot.umd.js +5 -0
- package/dist-bundled/umd/gids-dropdown-field.umd.js +5 -0
- package/dist-bundled/umd/gids-dropdown-picker.umd.js +5 -0
- package/dist-bundled/umd/gids-dropdown.umd.js +5 -0
- package/dist-bundled/umd/gids-field.umd.js +2 -2
- package/dist-bundled/umd/gids-icon.umd.js +2 -2
- package/dist-bundled/umd/gids-input.umd.js +2 -2
- package/dist-bundled/umd/gids-level-gauge.umd.js +5 -0
- package/dist-bundled/umd/gids-line-chart.umd.js +5 -0
- package/dist-bundled/umd/gids-notification.umd.js +2 -2
- package/dist-bundled/umd/gids-overflow-container.umd.js +2 -2
- package/dist-bundled/umd/gids-overlay-provider.umd.js +2 -2
- package/dist-bundled/umd/gids-password-field.umd.js +2 -2
- package/dist-bundled/umd/gids-pie-chart.umd.js +5 -0
- package/dist-bundled/umd/gids-popover.umd.js +5 -0
- package/dist-bundled/umd/gids-progress-circle.umd.js +5 -0
- package/dist-bundled/umd/gids-scrim.umd.js +2 -2
- package/dist-bundled/umd/gids-snackbar.umd.js +2 -2
- package/dist-bundled/umd/gids-text-field.umd.js +2 -2
- package/dist-bundled/umd/gids-toggle-button.umd.js +3 -3
- package/dist-bundled/umd/gids-tooltip.umd.js +5 -0
- package/dist-bundled/umd/index.umd.js +2 -2
- package/dist-bundled/umd-complete/gids-core-web.umd.js +11 -3
- package/package.json +422 -262
- package/dist/p-CWdkmFbc.js +0 -1
- package/dist/p-DijVkS9b.js +0 -1
- package/dist/p-DybsMR13.js +0 -1
- package/dist/p-ibikYq-w.js +0 -1
- package/dist-bundled/es/p-CWdkmFbc-D89ZE8Mi.js +0 -24
- package/dist-bundled/es/p-DijVkS9b-CtFkEtlE.js +0 -35
- package/dist-bundled/es/p-ibikYq-w-BsGxk8ro.js +0 -635
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { _ as C, u as y, T as o, L as w, P as f } from "./p-Ct3Ixgvf-CNP_PKwP.js";
|
|
2
2
|
import { i as x } from "./p-B2zUuNXz-BLBgQDu7.js";
|
|
3
3
|
import { e as N, n as g } from "./p-CVtNa0cL-sSVeJsR3.js";
|
|
4
|
-
import { d as p } from "./p-
|
|
5
|
-
import {
|
|
4
|
+
import { d as p } from "./p-BnL97lOW-BO0p4EdC.js";
|
|
5
|
+
import { o as u } from "./p-KxRqlvSh-JOFDmT0B.js";
|
|
6
6
|
import { c as h } from "./clsx-OuTLNxxd.js";
|
|
7
7
|
const Q = ({ appearance: t }, e) => h("gids-snackbar-container", {
|
|
8
8
|
// 'gids-snackbar-container--appearance-default': appearance === 'default' // its a default
|
|
@@ -24,7 +24,7 @@ const Q = ({ appearance: t }, e) => h("gids-snackbar-container", {
|
|
|
24
24
|
default:
|
|
25
25
|
return;
|
|
26
26
|
}
|
|
27
|
-
},
|
|
27
|
+
}, P = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
28
28
|
__proto__: null,
|
|
29
29
|
getGidsSnackbarContainerClassNames: Q,
|
|
30
30
|
getSnackbarContainerIconNames: S
|
|
@@ -66,7 +66,7 @@ const Q = ({ appearance: t }, e) => h("gids-snackbar-container", {
|
|
|
66
66
|
default:
|
|
67
67
|
return "component-exit-bottom-center";
|
|
68
68
|
}
|
|
69
|
-
},
|
|
69
|
+
}, j = ({ position: t, id: e, exitingComponents: n }) => n.includes(e) ? v(t) : b(t), M = ({ position: t }) => {
|
|
70
70
|
switch (t) {
|
|
71
71
|
case "bottom-left":
|
|
72
72
|
return "common-component-stack component-stack-bottom-left";
|
|
@@ -87,7 +87,7 @@ const Q = ({ appearance: t }, e) => h("gids-snackbar-container", {
|
|
|
87
87
|
}
|
|
88
88
|
}, O = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
89
89
|
__proto__: null,
|
|
90
|
-
getComponentClasses:
|
|
90
|
+
getComponentClasses: j,
|
|
91
91
|
getComponentEntryClasses: b,
|
|
92
92
|
getComponentExitClasses: v,
|
|
93
93
|
getComponentStackClasses: M
|
|
@@ -115,20 +115,20 @@ const Q = ({ appearance: t }, e) => h("gids-snackbar-container", {
|
|
|
115
115
|
__proto__: null,
|
|
116
116
|
getGidsNotificationContainerClassNames: T,
|
|
117
117
|
getNotificationContainerIconNames: I
|
|
118
|
-
}, Symbol.toStringTag, { value: "Module" })), { getGidsSnackbarContainerClassNames: z, getSnackbarContainerIconNames: L } =
|
|
118
|
+
}, Symbol.toStringTag, { value: "Module" })), { getGidsSnackbarContainerClassNames: z, getSnackbarContainerIconNames: L } = P, X = ({ appearance: t = "default", children: e, button: n, class: i, ...a }) => {
|
|
119
119
|
const r = L(t);
|
|
120
120
|
return o("div", { ...a, class: z({ appearance: t }, i) }, o("div", { class: "gids-snackbar-container__content" }, t !== "default" && r != null ? o(p, { name: r, alt: "", appearance: "filled", size: "md", class: "gids-snackbar-container__icon" }) : null, typeof e == "string" ? o("p", null, e) : e), n);
|
|
121
|
-
}, { getGidsNotificationContainerClassNames:
|
|
122
|
-
const c =
|
|
123
|
-
return o("div", { class:
|
|
124
|
-
}, { getComponentClasses: B, getComponentStackClasses: G } = O, _ =
|
|
121
|
+
}, { getGidsNotificationContainerClassNames: Y, getNotificationContainerIconNames: E } = q, R = ({ notificationTitle: t, children: e, button: n, appearance: i = "default", pronunciation: a = "standard", onCloseNotificationClick: r, class: s, ...m }) => {
|
|
122
|
+
const c = E(i);
|
|
123
|
+
return o("div", { class: Y({ appearance: i }, s), ...m }, i !== "default" && c ? o("div", { class: "gids-notification-container__leading-icon-wrapper" }, o(p, { size: "md", name: c, alt: "", appearance: "filled" })) : null, o("div", { class: "gids-notification-container__content-wrapper" }, o("div", { class: "gids-notification-container__top-content" }, o("div", { class: "gids-notification-container__text-content" }, t != null && t !== "" ? o("span", { class: "gids-notification-container__title" }, t) : null, e ? typeof e == "string" ? o("p", null, e) : e : null), a === "standard" ? o("div", { class: "gids-notification-container__cross-btn-wrapper" }, o(u, { size: "sm", appearance: "subtle", width: "intrinsic", leadingIcon: o(p, { name: "cross", size: "md", appearance: "regular" }), onClick: r })) : null), n ? o("div", { class: "gids-notification-container__bottom-content" }, n) : null));
|
|
124
|
+
}, { getComponentClasses: B, getComponentStackClasses: G } = O, _ = C(class extends y {
|
|
125
125
|
constructor(t) {
|
|
126
126
|
super(), t !== !1 && this.__registerHost(), this.__attachShadow(), this._parentOverlayProvider = null, this._componentQueue = [], this._allowedComponentQueue = [], this._exitingComponents = [], this._renderSnackbar = (e, n) => {
|
|
127
127
|
const { id: i, message: a, appearance: r, buttonLabel: s, onButtonClick: m } = e;
|
|
128
|
-
return o(
|
|
128
|
+
return o(X, { key: i, class: n, children: a, appearance: r, button: s != null && s !== "" ? o(u, { appearance: "subtle", onClick: m }, s) : void 0 });
|
|
129
129
|
}, this._renderNotification = (e, n) => {
|
|
130
130
|
const { id: i, notificationTitle: a, message: r, pronunciation: s, appearance: m, buttonLabel: c, onButtonClick: l, timerInMs: d } = e;
|
|
131
|
-
return o(
|
|
131
|
+
return o(R, { key: i, class: n, notificationTitle: a, children: r, pronunciation: s, appearance: m, onCloseNotificationClick: () => this.removeComponent(e, d || 0, !0), button: c != null && c !== "" ? o(u, { appearance: "default", size: "sm", onClick: l }, c) : void 0 });
|
|
132
132
|
}, this._renderComponent = (e) => {
|
|
133
133
|
const { componentName: n, position: i = "bottom-center", id: a } = e, r = B({ position: i, id: a, exitingComponents: this._exitingComponents });
|
|
134
134
|
return n == null || n === "snackbar" ? this._renderSnackbar(e, r) : n === "notification" ? this._renderNotification(e, r) : null;
|
|
@@ -187,7 +187,7 @@ const Q = ({ appearance: t }, e) => h("gids-snackbar-container", {
|
|
|
187
187
|
}
|
|
188
188
|
render() {
|
|
189
189
|
const t = this._allowedComponentQueue[0]?.position || "bottom-center";
|
|
190
|
-
return o(w, { key: "
|
|
190
|
+
return o(w, { key: "c130346274545aa8cb3b12390fa28f65b612dcd9" }, o("slot", { key: "6bfbde0f8f8a9cc75e3236ac806d762a9f2e0049" }), this._isRoot() ? o("div", { class: G({ position: t }) }, [...this._allowedComponentQueue].reverse().map(((e) => this._renderComponent(e)))) : null);
|
|
191
191
|
}
|
|
192
192
|
get _el() {
|
|
193
193
|
return this;
|
|
@@ -196,13 +196,13 @@ const Q = ({ appearance: t }, e) => h("gids-snackbar-container", {
|
|
|
196
196
|
return ".common-component-stack{display:flex;flex-direction:column;position:fixed;gap:var(--gids-gap-200);min-width:var(--gids-width-2-xs);max-width:var(--gids-width-md);width:100%}.component-stack-bottom-left{justify-self:left;bottom:var(--gids-padding-vertical-edge-to-element-250);left:var(--gids-padding-vertical-edge-to-element-250)}.component-stack-bottom-right{justify-self:right;bottom:var(--gids-padding-vertical-edge-to-element-250);right:var(--gids-padding-vertical-edge-to-element-250)}.component-stack-middle-left{top:50%;justify-self:left;align-self:center;left:var(--gids-padding-vertical-edge-to-element-250)}.component-stack-middle-right{top:50%;justify-self:right;align-self:center;right:var(--gids-padding-vertical-edge-to-element-250)}.component-stack-top-center{justify-self:center;top:var(--gids-padding-vertical-edge-to-element-250)}.component-stack-top-left{justify-self:left;top:var(--gids-padding-vertical-edge-to-element-250);left:var(--gids-padding-vertical-edge-to-element-250)}.component-stack-top-right{justify-self:right;top:var(--gids-padding-vertical-edge-to-element-250);right:var(--gids-padding-vertical-edge-to-element-250)}.component-stack-bottom-center{justify-self:center;bottom:var(--gids-padding-vertical-edge-to-element-250)}.component-enter-bottom-left{animation-name:left-to-right-visible;animation-duration:0.3s;animation-fill-mode:forwards}.component-enter-bottom-right{animation-name:right-to-left-visible;animation-duration:0.3s;animation-fill-mode:forwards}.component-enter-middle-left{animation-name:left-to-right-visible;animation-duration:0.3s;animation-fill-mode:forwards}.component-enter-middle-right{animation-name:right-to-left-visible;animation-duration:0.3s;animation-fill-mode:forwards}.component-enter-top-center{animation-name:slide-up-invisible;animation-duration:0.3s;animation-fill-mode:forwards}.component-enter-top-left{animation-name:left-to-right-visible;animation-duration:0.3s;animation-fill-mode:forwards}.component-enter-top-right{animation-name:right-to-left-visible;animation-duration:0.3s;animation-fill-mode:forwards}.component-enter-bottom-center{animation-name:slide-up-visible;animation-duration:0.3s;animation-fill-mode:forwards}.component-exit-bottom-left{animation-name:right-to-left-invisible;animation-duration:0.3s;animation-fill-mode:forwards}.component-exit-bottom-right{animation-name:left-to-right-invisible;animation-duration:0.3s;animation-fill-mode:forwards}.component-exit-middle-left{animation-name:right-to-left-invisible;animation-duration:0.3s;animation-fill-mode:forwards}.component-exit-middle-right{animation-name:left-to-right-invisible;animation-duration:0.3s;animation-fill-mode:forwards}.component-exit-top-center{animation-name:slide-down-visible;animation-duration:0.3s;animation-fill-mode:forwards}.component-exit-top-left{animation-name:right-to-left-invisible;animation-duration:0.3s;animation-fill-mode:forwards}.component-exit-top-right{animation-name:left-to-right-invisible;animation-duration:0.3s;animation-fill-mode:forwards}.component-exit-bottom-center{animation-name:slide-down-invisible;animation-duration:0.3s;animation-fill-mode:forwards}@keyframes slide-up-visible{0%{opacity:0;transform:translateY(100%)}100%{opacity:1;transform:translateY(0)}}@keyframes slide-down-invisible{0%{opacity:1;transform:translateY(0)}100%{opacity:0;transform:translateY(100%)}}@keyframes slide-up-invisible{0%{opacity:0;transform:translateY(-100%)}100%{opacity:1;transform:translateY(0)}}@keyframes slide-down-visible{0%{opacity:1;transform:translateY(0)}100%{opacity:0;transform:translateY(-100%)}}@keyframes left-to-right-visible{0%{opacity:0;transform:translateX(-100%)}100%{opacity:1;transform:translateX(0)}}@keyframes right-to-left-invisible{0%{opacity:1;transform:translateX(0)}100%{opacity:0;transform:translateX(-100%)}}@keyframes right-to-left-visible{0%{opacity:0;transform:translateX(100%)}100%{opacity:1;transform:translateX(0)}}@keyframes left-to-right-invisible{0%{opacity:1;transform:translateX(0)}100%{opacity:0;transform:translateX(100%)}}";
|
|
197
197
|
}
|
|
198
198
|
}, [257, "gids-overlay-provider", { _componentQueue: [32], _allowedComponentQueue: [32], _exitingComponents: [32], queueComponent: [64] }]);
|
|
199
|
-
function
|
|
199
|
+
function k() {
|
|
200
200
|
typeof customElements < "u" && ["gids-overlay-provider"].forEach(((t) => {
|
|
201
201
|
t === "gids-overlay-provider" && (customElements.get(f(t)) || customElements.define(f(t), _));
|
|
202
202
|
}));
|
|
203
203
|
}
|
|
204
|
-
|
|
205
|
-
const K = _, U =
|
|
204
|
+
k();
|
|
205
|
+
const K = _, U = k;
|
|
206
206
|
export {
|
|
207
207
|
K as GidsOverlayProvider,
|
|
208
208
|
U as defineCustomElement
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { _ as y, u as S, q as w, M as T, T as i, L as x, P as h } from "./p-Ct3Ixgvf-CNP_PKwP.js";
|
|
2
2
|
import { i as C } from "./p-B2zUuNXz-BLBgQDu7.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
3
|
+
import { a as L } from "./p-CRngHsR7-DL9wz3Z3.js";
|
|
4
|
+
import { r as O } from "./p-DZWWuJac-DNQvnHAr.js";
|
|
5
|
+
import { o as F } from "./p-KxRqlvSh-JOFDmT0B.js";
|
|
6
|
+
import { g as k, d as j } from "./p-BnL97lOW-BO0p4EdC.js";
|
|
7
|
+
import { h as E } from "./p-BvYnawkJ-DohV9UNG.js";
|
|
8
|
+
import { r as G } from "./p-DfFqFdmS-DjI2pk-0.js";
|
|
8
9
|
import { c as g } from "./clsx-OuTLNxxd.js";
|
|
9
10
|
const f = /[A-Z]/, p = /[a-z]/, b = /[0-9]/, q = /[^A-Za-z0-9]/, z = ({ text: e, meterRules: t = [], textMinLength: s = 0 }) => {
|
|
10
11
|
if (!e || e === "")
|
|
@@ -76,13 +77,13 @@ const f = /[A-Z]/, p = /[a-z]/, b = /[0-9]/, q = /[^A-Za-z0-9]/, z = ({ text: e,
|
|
|
76
77
|
defaultMeterRules: R(t),
|
|
77
78
|
defaultRequirementsMeterRules: t
|
|
78
79
|
};
|
|
79
|
-
},
|
|
80
|
+
}, $ = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
80
81
|
__proto__: null,
|
|
81
82
|
checkRequirementRuleSatisfied: I,
|
|
82
83
|
getDefaultRulesAndRequirementsForMeters: m,
|
|
83
84
|
getMeterRulesFromRequirements: R,
|
|
84
85
|
minLengthRuleCanBeApplied: o
|
|
85
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
86
|
+
}, Symbol.toStringTag, { value: "Module" })), N = (e) => {
|
|
86
87
|
switch (e) {
|
|
87
88
|
case "error":
|
|
88
89
|
return "danger";
|
|
@@ -97,7 +98,7 @@ const f = /[A-Z]/, p = /[a-z]/, b = /[0-9]/, q = /[^A-Za-z0-9]/, z = ({ text: e,
|
|
|
97
98
|
}
|
|
98
99
|
}, V = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
99
100
|
__proto__: null,
|
|
100
|
-
getRequirementsMeterLabelLeadingIcon:
|
|
101
|
+
getRequirementsMeterLabelLeadingIcon: N
|
|
101
102
|
}, Symbol.toStringTag, { value: "Module" })), D = (e) => {
|
|
102
103
|
switch (e) {
|
|
103
104
|
case "error":
|
|
@@ -132,14 +133,14 @@ const f = /[A-Z]/, p = /[a-z]/, b = /[0-9]/, q = /[^A-Za-z0-9]/, z = ({ text: e,
|
|
|
132
133
|
return s.length > 0 ? i("div", { class: te(n) }, (() => {
|
|
133
134
|
const r = s.length, l = se({ text: e, textMinLength: t, meterRules: s }), u = re({ textScore: l, maxScore: r });
|
|
134
135
|
return Array.from({ length: r }, ((_, c) => {
|
|
135
|
-
const d = c + 1,
|
|
136
|
-
return s[d] === "include-min-length" ? o({ requirementRule: "include-min-length", textMinLength: t }) ? a(d, u,
|
|
136
|
+
const d = c + 1, v = d <= l;
|
|
137
|
+
return s[d] === "include-min-length" ? o({ requirementRule: "include-min-length", textMinLength: t }) ? a(d, u, v) : null : a(d, u, v);
|
|
137
138
|
}));
|
|
138
139
|
})()) : null;
|
|
139
140
|
}, { getGidsRequirementsMeterLabelClassNames: ne } = J, { getRequirementsMeterLabelLeadingIcon: le } = V, ae = (e) => {
|
|
140
141
|
const { label: t, status: s = "default", leadingIconVisible: n = !0, class: a } = e, r = le(s);
|
|
141
142
|
return i("div", { class: ne({ status: s }, a) }, n && s && r ? i(j, { name: r, size: "sm", appearance: "filled" }) : null, t && t !== "" ? i("span", null, t) : null);
|
|
142
|
-
}, { checkRequirementRuleSatisfied: ue } =
|
|
143
|
+
}, { checkRequirementRuleSatisfied: ue } = $, { getGidsRequirementsMeterClassNames: de } = Q, oe = ({ requirements: e = [], text: t, textMinLength: s, class: n }) => {
|
|
143
144
|
const a = (r, l) => i(ae, { status: l ? "success" : "error", label: r.requirementText });
|
|
144
145
|
return i("div", { class: de(n) }, e.map(((r) => {
|
|
145
146
|
if (r?.requirementText != null && r?.requirementRule != null) {
|
|
@@ -148,9 +149,9 @@ const f = /[A-Z]/, p = /[a-z]/, b = /[0-9]/, q = /[^A-Za-z0-9]/, z = ({ text: e,
|
|
|
148
149
|
}
|
|
149
150
|
return null;
|
|
150
151
|
})));
|
|
151
|
-
}, { inputToGidsFieldStatusForPassword: ce } = ee, M =
|
|
152
|
+
}, { inputToGidsFieldStatusForPassword: ce } = ee, M = y(class extends S {
|
|
152
153
|
constructor(e) {
|
|
153
|
-
super(), e !== !1 && this.__registerHost(), this.gidsPasswordFieldClear =
|
|
154
|
+
super(), e !== !1 && this.__registerHost(), this.gidsPasswordFieldClear = w(this, "gidsPasswordFieldClear"), this.gidsPasswordFieldRevealPassword = w(this, "gidsPasswordFieldRevealPassword"), this.isPasswordRevealed = !1, this.meterRules = [], this.requirementsMeterRequirements = [], this.requirements = [], this.#t = k(), this._handleDismiss = () => {
|
|
154
155
|
const t = this.#e?.querySelector("input.gids-input__control");
|
|
155
156
|
t && (t.value = "", t.dispatchEvent(new globalThis.Event("input", { bubbles: !0 }))), this.value = "", this.gidsPasswordFieldClear.emit();
|
|
156
157
|
}, this._handleRevealPassword = () => {
|
|
@@ -170,7 +171,7 @@ const f = /[A-Z]/, p = /[a-z]/, b = /[0-9]/, q = /[^A-Za-z0-9]/, z = ({ text: e,
|
|
|
170
171
|
}
|
|
171
172
|
_startSlotContentObserver() {
|
|
172
173
|
this._slotContentObserver = new MutationObserver((() => {
|
|
173
|
-
|
|
174
|
+
T(this);
|
|
174
175
|
})), this._slotContentObserver.observe(this._el, { childList: !0, subtree: !1, attributes: !0, attributeFilter: ["slot"] });
|
|
175
176
|
}
|
|
176
177
|
handleRequirementsChange(e) {
|
|
@@ -190,7 +191,7 @@ const f = /[A-Z]/, p = /[a-z]/, b = /[0-9]/, q = /[^A-Za-z0-9]/, z = ({ text: e,
|
|
|
190
191
|
#e;
|
|
191
192
|
render() {
|
|
192
193
|
const { id: e, ...t } = this.inputProps ?? {}, s = e ?? this.#t, n = this.showClearButton && this.value !== void 0 && this.value.length > 0, a = this.showRevealPasswordButton, r = { ...t }, l = r?.placeholder !== void 0 && r.placeholder !== null && r.placeholder != "" ? r.placeholder : "Enter password", u = this.isPasswordRevealed, _ = this.meterRules, c = this.textMinLength !== void 0 ? this.textMinLength : 8;
|
|
193
|
-
return i(
|
|
194
|
+
return i(x, { key: "20e80248a1bf89a1fbcc45afde2d53bd51fbdbcc" }, i("gids-field", { key: "f3b8a64102cca5dc4342cc06c24c42ade33ff182", disabled: this.disabled, count: void 0, helperText: this.helperText, statusText: this.statusText, status: ce(this.status) }, i(L, { key: "49d56818bb59470c86a1375540849ac72a85ec39", slot: "label", disabled: this.disabled, info: i("slot", { name: "info" }), fieldRequirement: this.fieldRequirement, fieldRequirementOptionalText: this.fieldRequirementOptionalText, fieldRequirementRequiredText: this.fieldRequirementRequiredText, isLabelSentence: this.isLabelSentence, htmlFor: s }, this.label), i("gids-input", { key: "b4c52f50b940fd6d9bf8102cd8e9982827348294", ref: (d) => this.#e = d, appearance: "default", status: this.status, loading: this.loading, value: this.value, defaultValue: this.defaultValue, name: this.name, required: this.required, disabled: this.disabled, readOnly: this.readOnly, leadingLabel: void 0, trailingLabel: void 0, onFocus: this._handleInputFocusAndBlur, onBlur: this._handleInputFocusAndBlur, onInput: this._handleInput, inputProps: { ...r, placeholder: l, type: u ? "text" : "password", id: s, maxLength: this.maxLength } }, i("slot", { key: "125c163e6d2b647aee98931303cd133e67ccdd75", name: "leadingIcon" }), i("slot", { key: "137a5bf21cd658dc4eca833fb09954b3b68393d4", name: "leadingAccessory" }), i("div", { key: "4e87732b5d198ac176dc0fc68a99cb4b82cbcdf4", slot: "trailingAccessory", class: "gids-password-field__trailing-accessory" }, n && i(O, { key: "a8016058d8823a75c0188fe707f39aad1834a6e6", label: "clear text", size: "lg", onPressDismiss: this._handleDismiss }), a && i(F, { key: "3bfe55f6787c42df0a9a9351ac96b12fa90826ab", appearance: "default", size: "xs", width: "intrinsic", disabled: this.disabled, onClick: this._handleRevealPassword }, u ? "Hide" : "Show")))), i("div", { key: "d2b12032cafa7414481251d9b2c5cacc94bcf745", class: "gids-password-field__meters-container" }, i(ie, { key: "5aa93ffa5361c3b4d5b8f9d7fd13ff6628821ebe", meterRules: _, text: this.value, textMinLength: c }), i(oe, { key: "96131ad3f4c4318450952b2c6b8325d2bd567cf6", requirements: this.requirementsMeterRequirements, text: this.value, textMinLength: c })));
|
|
194
195
|
}
|
|
195
196
|
get _el() {
|
|
196
197
|
return this;
|
|
@@ -199,7 +200,7 @@ const f = /[A-Z]/, p = /[a-z]/, b = /[0-9]/, q = /[^A-Za-z0-9]/, z = ({ text: e,
|
|
|
199
200
|
return { requirements: [{ handleRequirementsChange: 0 }], textMinLength: [{ handleRequirementsChange: 0 }] };
|
|
200
201
|
}
|
|
201
202
|
}, [260, "gids-password-field", { label: [513], showClearButton: [516, "show-clear-button"], showRevealPasswordButton: [516, "show-reveal-password-button"], helperText: [513, "helper-text"], statusText: [513, "status-text"], status: [513], loading: [516], name: [513], required: [516], maxLength: [514, "maxlength"], value: [1], defaultValue: [513, "default-value"], disabled: [516], readOnly: [516, "readonly"], inputProps: [16], fieldRequirement: [513, "field-requirement"], fieldRequirementOptionalText: [1, "field-requirement-optional-text"], fieldRequirementRequiredText: [1, "field-requirement-required-text"], isLabelSentence: [16], textMinLength: [514, "text-min-length"], requirements: [16], isPasswordRevealed: [32], meterRules: [32], requirementsMeterRequirements: [32] }, void 0, { requirements: [{ handleRequirementsChange: 0 }], textMinLength: [{ handleRequirementsChange: 0 }] }]);
|
|
202
|
-
function
|
|
203
|
+
function P() {
|
|
203
204
|
typeof customElements < "u" && ["gids-password-field", "gids-field", "gids-input"].forEach(((e) => {
|
|
204
205
|
switch (e) {
|
|
205
206
|
case "gids-password-field":
|
|
@@ -213,9 +214,9 @@ function y() {
|
|
|
213
214
|
}
|
|
214
215
|
}));
|
|
215
216
|
}
|
|
216
|
-
|
|
217
|
-
const
|
|
217
|
+
P();
|
|
218
|
+
const ve = M, we = P;
|
|
218
219
|
export {
|
|
219
|
-
|
|
220
|
+
ve as GidsPasswordField,
|
|
220
221
|
we as defineCustomElement
|
|
221
222
|
};
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { _ as v, u as p, T as a, L as f, P as l } from "./p-Ct3Ixgvf-CNP_PKwP.js";
|
|
2
|
+
import { g as E } from "./p-a3JfEYJp-DyhDK6VZ.js";
|
|
3
|
+
import { o as b } from "./p-B8kX8Vqv-trBz4jdS.js";
|
|
4
|
+
const h = v(class extends p {
|
|
5
|
+
constructor(e) {
|
|
6
|
+
super(), e !== !1 && this.__registerHost(), this.__attachShadow(), this.placement = "bottom", this.previouslyFocusedElement = null, this.focusableElements = [], this.handleToggleEvent = (t) => {
|
|
7
|
+
t.stopPropagation();
|
|
8
|
+
const n = this.floatingElementManager.isVisible();
|
|
9
|
+
this.floatingElementManager.toggle(), !n && this.floatingElementManager.isVisible() ? this.onPopoverShow() : n && !this.floatingElementManager.isVisible() && this.onPopoverHide();
|
|
10
|
+
}, this.handleDocumentClick = (t) => {
|
|
11
|
+
this.floatingElementManager.isVisible() && !this._el.contains(t.target) && (this.floatingElementManager.hide(), this.onPopoverHide());
|
|
12
|
+
}, this.handleKeyDown = (t) => {
|
|
13
|
+
if (this.floatingElementManager.isVisible()) return t.key === "Escape" ? (t.preventDefault(), this.floatingElementManager.hide(), void this.onPopoverHide()) : void (t.key === "Tab" && this.trapFocus(t));
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
componentDidLoad() {
|
|
17
|
+
this.floatingElementManager = new E(this._el, { htmlFor: this.htmlFor, placement: this.placement, showWithoutDelay: !0, floatingElementSelector: "#popover", arrowElementSelector: "#arrow", visibilityClass: "gids-popover--visible", elementType: b.POPOVER, getAnchorElementFromSlot: (e) => e.querySelector('slot[name="anchor"]')?.assignedElements()[0] || null }), this.floatingElementManager.initialize(), this.setupEventListeners();
|
|
18
|
+
}
|
|
19
|
+
setupEventListeners() {
|
|
20
|
+
const e = this.floatingElementManager.getAnchorElement();
|
|
21
|
+
e && (e.addEventListener("click", this.handleToggleEvent), document.addEventListener("click", this.handleDocumentClick), document.addEventListener("keydown", this.handleKeyDown));
|
|
22
|
+
}
|
|
23
|
+
onPopoverShow() {
|
|
24
|
+
this.previouslyFocusedElement = document.activeElement, this.updateFocusableElements(), setTimeout((() => {
|
|
25
|
+
this.focusableElements.length > 0 && this.focusableElements[0] && this.focusableElements[0].focus();
|
|
26
|
+
}), 50);
|
|
27
|
+
}
|
|
28
|
+
onPopoverHide() {
|
|
29
|
+
this.previouslyFocusedElement && (this.previouslyFocusedElement.focus(), this.previouslyFocusedElement = null);
|
|
30
|
+
}
|
|
31
|
+
updateFocusableElements() {
|
|
32
|
+
const e = this._el.shadowRoot?.querySelector("#popover");
|
|
33
|
+
if (!e) return;
|
|
34
|
+
const t = [], n = c(e);
|
|
35
|
+
t.push(...n);
|
|
36
|
+
const o = this._el.shadowRoot?.querySelector("slot:not([name])");
|
|
37
|
+
o && o.assignedElements({ flatten: !0 }).forEach(((i) => {
|
|
38
|
+
const s = c(i);
|
|
39
|
+
t.push(...s);
|
|
40
|
+
})), this.focusableElements = t.sort(((i, s) => {
|
|
41
|
+
const r = i.compareDocumentPosition(s), u = !!(r & Node.DOCUMENT_POSITION_FOLLOWING), m = !!(r & Node.DOCUMENT_POSITION_PRECEDING);
|
|
42
|
+
return u ? -1 : m ? 1 : 0;
|
|
43
|
+
}));
|
|
44
|
+
}
|
|
45
|
+
trapFocus(e) {
|
|
46
|
+
if (this.focusableElements.length === 0) return;
|
|
47
|
+
const t = this.focusableElements[0], n = this.focusableElements[this.focusableElements.length - 1];
|
|
48
|
+
let o = document.activeElement;
|
|
49
|
+
if (o === this._el) {
|
|
50
|
+
const s = this._el.shadowRoot?.activeElement;
|
|
51
|
+
s !== null && (o = s);
|
|
52
|
+
}
|
|
53
|
+
const i = this.focusableElements.indexOf(o) !== -1;
|
|
54
|
+
e.shiftKey ? o !== t && i || (e.preventDefault(), n && n.focus()) : o !== n && i || (e.preventDefault(), t && t.focus());
|
|
55
|
+
}
|
|
56
|
+
placementChanged(e) {
|
|
57
|
+
this.floatingElementManager?.updateConfig({ placement: e }), this.floatingElementManager?.isVisible() && this.floatingElementManager?.reposition();
|
|
58
|
+
}
|
|
59
|
+
htmlForChanged(e) {
|
|
60
|
+
this.floatingElementManager?.updateConfig({ htmlFor: e }), this.cleanupEventListeners(), this.floatingElementManager?.initialize(), this.setupEventListeners();
|
|
61
|
+
}
|
|
62
|
+
cleanupEventListeners() {
|
|
63
|
+
const e = this.floatingElementManager?.getAnchorElement();
|
|
64
|
+
e && e.removeEventListener("click", this.handleToggleEvent), document.removeEventListener("click", this.handleDocumentClick), document.removeEventListener("keydown", this.handleKeyDown);
|
|
65
|
+
}
|
|
66
|
+
render() {
|
|
67
|
+
return a(f, { key: "4147e2407a0e2592d65db07e6d92dcbd37e52b5d" }, a("slot", { key: "82f2de1b78ee81f7b2363a2fbf4fc80029c6529f", name: "anchor" }), a("div", { key: "371b9c7c170bf8621e2a847eca6771e140ee161e", id: "popover", part: "popover", role: "dialog", "aria-modal": "true", tabindex: "-1" }, a("span", { key: "19dbf2c247353839c075674f068f2d435a23bec1", id: "arrow" }), a("div", { key: "374d276cdd13093c74b8a35d7447c328f4f90d0c" }, a("slot", { key: "45d5f02df1f6aa160d080a5f5a10e0ba9e6aa8f8" }))));
|
|
68
|
+
}
|
|
69
|
+
disconnectedCallback() {
|
|
70
|
+
this.cleanupEventListeners(), this.floatingElementManager?.destroy();
|
|
71
|
+
}
|
|
72
|
+
get _el() {
|
|
73
|
+
return this;
|
|
74
|
+
}
|
|
75
|
+
static get watchers() {
|
|
76
|
+
return { placement: [{ placementChanged: 0 }], htmlFor: [{ htmlForChanged: 0 }] };
|
|
77
|
+
}
|
|
78
|
+
static get style() {
|
|
79
|
+
return "gids-popover{--gidsPopover-background:var(--gids-elevation-surface-overlay-default);--gidsPopover-text-color:var(--gids-color-text-default);--gidsPopover-padding:var(--gids-padding-vertical-edge-to-element-200) var(--gids-padding-horizontal-edge-to-element-300);--gidsPopover-border-radius:var(--gids-border-radius-lg);--gidsPopover-tip-border-radius:2px;--gidsPopover-tip-size:12px;--gidsPopover-shadow:var(--gids-elevation-shadow-overlay);--gidsFloatingElement-background:var(--gidsPopover-background);--gidsFloatingElement-tip-border-radius:var(--gidsPopover-tip-border-radius)}[part=popover]{font-family:var(--gids-typography-label-small__font-family);font-size:var(--gids-typography-label-small__font-size);font-weight:var(--gids-typography-label-small__font-weight);letter-spacing:var(--gids-typography-label-small__letter-spacing);line-height:var(--gids-typography-label-small__line-height);text-transform:var(--gids-typography-label-small__text-transform, inherit);font-variant-caps:var(--gids-typography-label-small__font-variant-caps, inherit);position:absolute;display:inline-block;background-color:var(--gidsPopover-background);color:var(--gidsPopover-text-color);border-radius:var(--gidsPopover-border-radius);box-shadow:var(--gidsPopover-shadow);z-index:1000;opacity:0;pointer-events:none;outline:none}[part=popover]:focus{outline:none}[part=popover].gids-popover--visible{pointer-events:initial;opacity:1}[part=popover] span#arrow{position:absolute;height:var(--gidsPopover-tip-size);width:var(--gidsPopover-tip-size);background-color:var(--gidsPopover-background)}";
|
|
80
|
+
}
|
|
81
|
+
}, [257, "gids-popover", { htmlFor: [513, "for"], placement: [513] }, void 0, { placement: [{ placementChanged: 0 }], htmlFor: [{ htmlForChanged: 0 }] }]), d = (e) => {
|
|
82
|
+
if (!(e instanceof p) || e.tabIndex === -1 || e.hasAttribute("disabled")) return !1;
|
|
83
|
+
const t = getComputedStyle(e);
|
|
84
|
+
if (t.display === "none" || t.visibility === "hidden" || e.hidden) return !1;
|
|
85
|
+
try {
|
|
86
|
+
const n = e.tabIndex;
|
|
87
|
+
e.tabIndex = -1, e.focus();
|
|
88
|
+
const o = document.activeElement === e;
|
|
89
|
+
return e.tabIndex = n, o && e.blur(), o;
|
|
90
|
+
} catch {
|
|
91
|
+
return !1;
|
|
92
|
+
}
|
|
93
|
+
}, c = (e) => {
|
|
94
|
+
const t = document.createTreeWalker(e, NodeFilter.SHOW_ELEMENT, { acceptNode: (i) => d(i) ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP }), n = [];
|
|
95
|
+
d(e) && n.push(e);
|
|
96
|
+
let o = t.nextNode();
|
|
97
|
+
for (; o !== null; ) n.push(o), o = t.nextNode();
|
|
98
|
+
return n;
|
|
99
|
+
};
|
|
100
|
+
function g() {
|
|
101
|
+
typeof customElements < "u" && ["gids-popover"].forEach(((e) => {
|
|
102
|
+
e === "gids-popover" && (customElements.get(l(e)) || customElements.define(l(e), h));
|
|
103
|
+
}));
|
|
104
|
+
}
|
|
105
|
+
g();
|
|
106
|
+
const k = h, F = g;
|
|
107
|
+
export {
|
|
108
|
+
k as GidsPopover,
|
|
109
|
+
F as defineCustomElement
|
|
110
|
+
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { _ as o, u as c, T as e, P as t } from "./p-Ct3Ixgvf-CNP_PKwP.js";
|
|
2
2
|
import { i as l } from "./p-B2zUuNXz-BLBgQDu7.js";
|
|
3
3
|
import { c as n } from "./clsx-OuTLNxxd.js";
|
|
4
4
|
const d = (s) => n("gids-scrim", s), m = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
5
5
|
__proto__: null,
|
|
6
6
|
getGidsScrimClassNames: d
|
|
7
|
-
}, Symbol.toStringTag, { value: "Module" })), { getGidsScrimClassNames: a } = m,
|
|
7
|
+
}, Symbol.toStringTag, { value: "Module" })), { getGidsScrimClassNames: a } = m, i = o(class extends c {
|
|
8
8
|
constructor(s) {
|
|
9
9
|
super(), s !== !1 && this.__registerHost(), this.__attachShadow(), this.activeClasses = "";
|
|
10
10
|
}
|
|
@@ -16,7 +16,7 @@ const d = (s) => n("gids-scrim", s), m = /* @__PURE__ */ Object.freeze(/* @__PUR
|
|
|
16
16
|
s !== void 0 && this._el.shadowRoot?.adoptedStyleSheets.push(s), this.activeClasses = a(this.extraClasses);
|
|
17
17
|
}
|
|
18
18
|
render() {
|
|
19
|
-
return e("div", { key: "
|
|
19
|
+
return e("div", { key: "bb28bc59d4522f27c3637774153603462d628be0", class: this.activeClasses, part: "root" }, e("slot", { key: "24becefcfa3a4842163b62a255266d71dd27d765" }));
|
|
20
20
|
}
|
|
21
21
|
get _el() {
|
|
22
22
|
return this;
|
|
@@ -28,13 +28,13 @@ const d = (s) => n("gids-scrim", s), m = /* @__PURE__ */ Object.freeze(/* @__PUR
|
|
|
28
28
|
return ".gids-scrim{display:flex;flex-direction:column;background-color:var(--gids-color-background-scrim);height:100vh !important;position:absolute;top:0;bottom:0;left:0;right:0;z-index:1001;align-items:center;justify-content:center;backdrop-filter:blur(12)}";
|
|
29
29
|
}
|
|
30
30
|
}, [257, "gids-scrim", { extraClasses: [513, "extra-classes"], activeClasses: [32] }, void 0, { extraClasses: [{ handleExtraClassesChange: 0 }] }]);
|
|
31
|
-
function
|
|
31
|
+
function r() {
|
|
32
32
|
typeof customElements < "u" && ["gids-scrim"].forEach(((s) => {
|
|
33
|
-
s === "gids-scrim" && (customElements.get(t(s)) || customElements.define(t(s),
|
|
33
|
+
s === "gids-scrim" && (customElements.get(t(s)) || customElements.define(t(s), i));
|
|
34
34
|
}));
|
|
35
35
|
}
|
|
36
|
-
|
|
37
|
-
const f =
|
|
36
|
+
r();
|
|
37
|
+
const f = i, C = r;
|
|
38
38
|
export {
|
|
39
39
|
f as GidsScrim,
|
|
40
40
|
C as defineCustomElement
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { _ as u, u as h, q as c, M as f, T as i, P as s } from "./p-Ct3Ixgvf-CNP_PKwP.js";
|
|
2
2
|
import { i as b } from "./p-B2zUuNXz-BLBgQDu7.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
3
|
+
import { a as m } from "./p-CRngHsR7-DL9wz3Z3.js";
|
|
4
|
+
import { r as p } from "./p-DZWWuJac-DNQvnHAr.js";
|
|
5
|
+
import { h as g } from "./p-BvYnawkJ-DohV9UNG.js";
|
|
6
|
+
import { r as x } from "./p-DfFqFdmS-DjI2pk-0.js";
|
|
7
|
+
import { g as _ } from "./p-BnL97lOW-BO0p4EdC.js";
|
|
7
8
|
const v = (e, t) => {
|
|
8
9
|
if (!(e === void 0 || t === void 0))
|
|
9
10
|
return `${e} / ${Math.max(t, 0)}`;
|
|
@@ -16,16 +17,16 @@ const v = (e, t) => {
|
|
|
16
17
|
default:
|
|
17
18
|
return "default";
|
|
18
19
|
}
|
|
19
|
-
},
|
|
20
|
+
}, n = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
20
21
|
__proto__: null,
|
|
21
22
|
formatCharCount: v,
|
|
22
23
|
inputToGidsFieldStatus: T
|
|
23
|
-
}, Symbol.toStringTag, { value: "Module" })), { inputToGidsFieldStatus: y } =
|
|
24
|
+
}, Symbol.toStringTag, { value: "Module" })), { inputToGidsFieldStatus: y } = n, q = (e) => e === "implicit" || e === void 0 ? "implicit" : y(e), C = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
24
25
|
__proto__: null,
|
|
25
26
|
inputToGidsFieldStatus: q
|
|
26
|
-
}, Symbol.toStringTag, { value: "Module" })), { formatCharCount: F } =
|
|
27
|
+
}, Symbol.toStringTag, { value: "Module" })), { formatCharCount: F } = n, { inputToGidsFieldStatus: O } = C, a = u(class extends h {
|
|
27
28
|
constructor(e) {
|
|
28
|
-
super(), e !== !1 && this.__registerHost(), this.gidsTextFieldClear =
|
|
29
|
+
super(), e !== !1 && this.__registerHost(), this.gidsTextFieldClear = c(this, "gidsTextFieldClear"), this.#e = _(), this._handleDismiss = () => {
|
|
29
30
|
const t = this.#t?.querySelector("input.gids-input__control");
|
|
30
31
|
t && (t.value = "", t.dispatchEvent(new globalThis.Event("input", { bubbles: !0 }))), this.value = "", this.gidsTextFieldClear.emit();
|
|
31
32
|
}, this._handleInput = (t) => {
|
|
@@ -49,8 +50,8 @@ const v = (e, t) => {
|
|
|
49
50
|
#e;
|
|
50
51
|
#t;
|
|
51
52
|
render() {
|
|
52
|
-
const { id: e, ...t } = this.inputProps ?? {},
|
|
53
|
-
return i("gids-field", { key: "
|
|
53
|
+
const { id: e, ...t } = this.inputProps ?? {}, l = e ?? this.#e, d = this.showClearButton && this.value !== void 0 && this.value.length > 0;
|
|
54
|
+
return i("gids-field", { key: "d11133ec5a64d0bc929a2c09530e1c4b7040a441", disabled: this.disabled, count: F(this.value?.length, this.maxLength), helperText: this.helperText, statusText: this.statusText, status: O(this.status) }, i(m, { key: "edf0168bd4940b9f98fff8b7e03d865f46f4b6ac", slot: "label", disabled: this.disabled, info: i("slot", { name: "info" }), fieldRequirement: this.fieldRequirement, fieldRequirementOptionalText: this.fieldRequirementOptionalText, fieldRequirementRequiredText: this.fieldRequirementRequiredText, isLabelSentence: this.isLabelSentence, htmlFor: l }, this.label), i("gids-input", { key: "317347850ebc9f671a16c816807f9ca55f0f9fa6", ref: (o) => this.#t = o, appearance: this.appearance, status: this.status, loading: this.loading, value: this.value, defaultValue: this.defaultValue, name: this.name, required: this.required, disabled: this.disabled, readOnly: this.readOnly, leadingLabel: this.leadingLabel, trailingLabel: this.trailingLabel, onFocus: this._handleInputFocusAndBlur, onBlur: this._handleInputFocusAndBlur, onInput: this._handleInput, inputProps: { ...t, type: this.type, id: l, maxLength: this.maxLength } }, i("slot", { key: "87815f4d215bbb0c542457b9216f7446595d9ec2", name: "leadingIcon" }), i("slot", { key: "6648b1d8d3585e1df78039a356a297760272af4f", name: "leadingAccessory" }), d && i(p, { key: "7eba5acbfdfe1c9173d43bce1592f8e12c8602cb", label: "clear text", slot: "trailingAccessory", size: "lg", onPressDismiss: this._handleDismiss }), i("slot", { key: "85017d875b4390fec245b9da8409787a2bd86909", name: "trailingIcon" })));
|
|
54
55
|
}
|
|
55
56
|
get _el() {
|
|
56
57
|
return this;
|
|
@@ -71,8 +72,8 @@ function r() {
|
|
|
71
72
|
}));
|
|
72
73
|
}
|
|
73
74
|
r();
|
|
74
|
-
const
|
|
75
|
+
const P = a, G = r;
|
|
75
76
|
export {
|
|
76
|
-
|
|
77
|
+
P as GidsTextField,
|
|
77
78
|
G as defineCustomElement
|
|
78
79
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { a } from "./p-
|
|
1
|
+
import { _ as l, u as d, q as n, T as t, H as c, P as s } from "./p-Ct3Ixgvf-CNP_PKwP.js";
|
|
2
|
+
import { o as a } from "./p-KxRqlvSh-JOFDmT0B.js";
|
|
3
3
|
import { i as h } from "./p-B2zUuNXz-BLBgQDu7.js";
|
|
4
|
-
const i = l(class extends
|
|
4
|
+
const i = l(class extends d {
|
|
5
5
|
get selected() {
|
|
6
6
|
return this.#e ?? this.defaultSelected;
|
|
7
7
|
}
|
|
@@ -9,7 +9,7 @@ const i = l(class extends n {
|
|
|
9
9
|
this.#e = e === void 0 ? void 0 : !!e;
|
|
10
10
|
}
|
|
11
11
|
constructor(e) {
|
|
12
|
-
super(), e !== !1 && this.__registerHost(), this.__attachShadow(), this.select =
|
|
12
|
+
super(), e !== !1 && this.__registerHost(), this.__attachShadow(), this.select = n(this, "select"), this._toggle = this._toggle.bind(this);
|
|
13
13
|
}
|
|
14
14
|
#e;
|
|
15
15
|
connectedCallback() {
|
|
@@ -21,9 +21,9 @@ const i = l(class extends n {
|
|
|
21
21
|
this._el.selected = e, this.select?.emit(e);
|
|
22
22
|
}
|
|
23
23
|
render() {
|
|
24
|
-
return t(
|
|
24
|
+
return t(c, { key: "d95b05ee98862e9fa4ee50ae676fded8234de63d" }, t("style", { key: "844be4d370a1d44e4c18b828ed2cfab3bd702cfd" }, `:host {
|
|
25
25
|
display: ${this.width === "full" ? "block" : "inline-block"}
|
|
26
|
-
}`), t(a, { key: "
|
|
26
|
+
}`), t(a, { key: "510307e7bfce966e96422999f5309e0df3e62634", appearance: this.appearance, size: this.size, width: this.width, disabled: this.disabled, onClick: this._toggle, "aria-pressed": this.selected ? "true" : "false", leadingIcon: t("slot", { name: "leadingIcon" }), trailingIcon: t("slot", { name: "trailingIcon" }), forceIconOnly: this._onlyHasLeadingIcon() }, t("slot", { key: "38bff264ed88090ee4567650417ccb86805fca98" })));
|
|
27
27
|
}
|
|
28
28
|
_onlyHasLeadingIcon() {
|
|
29
29
|
const e = this._el.childNodes;
|
|
@@ -39,8 +39,8 @@ function o() {
|
|
|
39
39
|
}));
|
|
40
40
|
}
|
|
41
41
|
o();
|
|
42
|
-
const u = i,
|
|
42
|
+
const u = i, b = o;
|
|
43
43
|
export {
|
|
44
44
|
u as GidsToggleButton,
|
|
45
|
-
|
|
45
|
+
b as defineCustomElement
|
|
46
46
|
};
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { _ as n, u as l, T as e, L as s, P as i } from "./p-Ct3Ixgvf-CNP_PKwP.js";
|
|
2
|
+
import { g as r } from "./p-a3JfEYJp-DyhDK6VZ.js";
|
|
3
|
+
import { i as d } from "./p-B2zUuNXz-BLBgQDu7.js";
|
|
4
|
+
import { o as h } from "./p-B8kX8Vqv-trBz4jdS.js";
|
|
5
|
+
const o = n(class extends l {
|
|
6
|
+
constructor(t) {
|
|
7
|
+
super(), t !== !1 && this.__registerHost(), this.__attachShadow(), this.placement = "bottom", this.showWithoutDelay = !1, this.lockToMainAxis = !1, this.handleShowEvent = () => {
|
|
8
|
+
this.floatingElementManager.showAfterDelay();
|
|
9
|
+
}, this.handleHideEvent = () => {
|
|
10
|
+
this.floatingElementManager.hideAfterDelay();
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
connectedCallback() {
|
|
14
|
+
const t = d();
|
|
15
|
+
t !== void 0 && this._el.shadowRoot?.adoptedStyleSheets.push(t);
|
|
16
|
+
}
|
|
17
|
+
componentDidLoad() {
|
|
18
|
+
this.floatingElementManager = new r(this._el, { htmlFor: this.htmlFor, placement: this.placement, showWithoutDelay: this.showWithoutDelay, lockToMainAxis: this.lockToMainAxis, floatingElementSelector: "#tooltip", arrowElementSelector: "#arrow", visibilityClass: "gids-tooltip--visible", elementType: h.TOOLTIP, getAnchorElementFromSlot: (t) => t.querySelector("slot")?.assignedElements()[0] || null }), this.floatingElementManager.initialize(), this.setupEventListeners();
|
|
19
|
+
}
|
|
20
|
+
setupEventListeners() {
|
|
21
|
+
const t = this.floatingElementManager.getAnchorElement();
|
|
22
|
+
t && (t.addEventListener("mouseenter", this.handleShowEvent), t.addEventListener("focus", this.handleShowEvent), t.addEventListener("mouseleave", this.handleHideEvent), t.addEventListener("blur", this.handleHideEvent));
|
|
23
|
+
}
|
|
24
|
+
placementChanged(t) {
|
|
25
|
+
this.floatingElementManager?.updateConfig({ placement: t }), this.floatingElementManager?.isVisible() && this.floatingElementManager?.reposition();
|
|
26
|
+
}
|
|
27
|
+
showWithoutDelayChanged(t) {
|
|
28
|
+
this.floatingElementManager?.updateConfig({ showWithoutDelay: t });
|
|
29
|
+
}
|
|
30
|
+
lockToMainAxisChanged(t) {
|
|
31
|
+
this.floatingElementManager?.updateConfig({ lockToMainAxis: t });
|
|
32
|
+
}
|
|
33
|
+
htmlForChanged(t) {
|
|
34
|
+
this.floatingElementManager?.updateConfig({ htmlFor: t }), this.cleanupEventListeners(), this.floatingElementManager?.initialize(), this.setupEventListeners();
|
|
35
|
+
}
|
|
36
|
+
cleanupEventListeners() {
|
|
37
|
+
const t = this.floatingElementManager?.getAnchorElement();
|
|
38
|
+
t && (t.removeEventListener("mouseenter", this.handleShowEvent), t.removeEventListener("focus", this.handleShowEvent), t.removeEventListener("mouseleave", this.handleHideEvent), t.removeEventListener("blur", this.handleHideEvent));
|
|
39
|
+
}
|
|
40
|
+
render() {
|
|
41
|
+
return e(s, { key: "f9e6c76e1f2b3faa2c2ed5b1f5c28c4b11878819" }, e("slot", { key: "1c36da89ba7d6a20f0e5204d5c079dbc64226d56" }), e("span", { key: "ac4972259978f2e52fc15545a28dc2375ef370cd", id: "tooltip", part: "tooltip", role: "tooltip" }, e("span", { key: "49a7b319f5f0a87befe6e5d355d846dae12a9644", id: "arrow" }), this.tooltipText));
|
|
42
|
+
}
|
|
43
|
+
disconnectedCallback() {
|
|
44
|
+
this.cleanupEventListeners(), this.floatingElementManager?.destroy();
|
|
45
|
+
}
|
|
46
|
+
get _el() {
|
|
47
|
+
return this;
|
|
48
|
+
}
|
|
49
|
+
static get watchers() {
|
|
50
|
+
return { placement: [{ placementChanged: 0 }], showWithoutDelay: [{ showWithoutDelayChanged: 0 }], lockToMainAxis: [{ lockToMainAxisChanged: 0 }], htmlFor: [{ htmlForChanged: 0 }] };
|
|
51
|
+
}
|
|
52
|
+
static get style() {
|
|
53
|
+
return "gids-tooltip{--gidsTooltip-background:var(--gids-color-background-neutral-bold-default);--gidsTooltip-text-color:var(--gids-color-text-inverse);--gidsTooltip-padding:var(--gids-padding-vertical-edge-to-element-100) var(--gids-padding-horizontal-edge-to-element-200);--gidsTooltip-border-radius:var(--gids-border-radius-sm);--gidsTooltip-tip-border-radius:2px;--gidsTooltip-tip-size:12px;--gidsFloatingElement-background:var(--gidsTooltip-background);--gidsFloatingElement-tip-border-radius:var(--gidsTooltip-tip-border-radius)}[part=tooltip]{font-family:var(--gids-typography-label-small__font-family);font-size:var(--gids-typography-label-small__font-size);font-weight:var(--gids-typography-label-small__font-weight);letter-spacing:var(--gids-typography-label-small__letter-spacing);line-height:var(--gids-typography-label-small__line-height);text-transform:var(--gids-typography-label-small__text-transform, inherit);font-variant-caps:var(--gids-typography-label-small__font-variant-caps, inherit);position:absolute;display:inline-block;hyphens:auto;background-color:var(--gidsTooltip-background);color:var(--gidsTooltip-text-color);padding:var(--gidsTooltip-padding);border-radius:var(--gidsTooltip-border-radius);z-index:1000;opacity:0;pointer-events:none}[part=tooltip].gids-tooltip--visible{pointer-events:initial;opacity:1}[part=tooltip] span#arrow{position:absolute;height:var(--gidsTooltip-tip-size);width:var(--gidsTooltip-tip-size)}";
|
|
54
|
+
}
|
|
55
|
+
}, [257, "gids-tooltip", { htmlFor: [513, "for"], tooltipText: [513, "tooltip-text"], placement: [513], showWithoutDelay: [516, "show-without-delay"], lockToMainAxis: [4, "lock-to-main-axis"] }, void 0, { placement: [{ placementChanged: 0 }], showWithoutDelay: [{ showWithoutDelayChanged: 0 }], lockToMainAxis: [{ lockToMainAxisChanged: 0 }], htmlFor: [{ htmlForChanged: 0 }] }]);
|
|
56
|
+
function a() {
|
|
57
|
+
typeof customElements < "u" && ["gids-tooltip"].forEach(((t) => {
|
|
58
|
+
t === "gids-tooltip" && (customElements.get(i(t)) || customElements.define(i(t), o));
|
|
59
|
+
}));
|
|
60
|
+
}
|
|
61
|
+
a();
|
|
62
|
+
const f = o, v = a;
|
|
63
|
+
export {
|
|
64
|
+
f as GidsTooltip,
|
|
65
|
+
v as defineCustomElement
|
|
66
|
+
};
|