@sankhyalabs/ezui 2.10.0 → 2.11.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/cjs/ez-actions-button.cjs.entry.js +1 -1
- package/dist/cjs/ez-alert.cjs.entry.js +1 -1
- package/dist/cjs/ez-application.cjs.entry.js +1 -1
- package/dist/cjs/ez-breadcrumb.cjs.entry.js +1 -1
- package/dist/cjs/ez-button.cjs.entry.js +1 -1
- package/dist/cjs/ez-calendar.cjs.entry.js +1 -1
- package/dist/cjs/ez-card-item.cjs.entry.js +1 -1
- package/dist/cjs/ez-check.cjs.entry.js +1 -1
- package/dist/cjs/ez-chip.cjs.entry.js +1 -1
- package/dist/cjs/ez-collapsible-box.cjs.entry.js +1 -1
- package/dist/cjs/ez-combo-box.cjs.entry.js +1 -1
- package/dist/cjs/ez-date-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-date-time-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-dialog.cjs.entry.js +1 -1
- package/dist/cjs/ez-dropdown.cjs.entry.js +503 -0
- package/dist/cjs/ez-file-item.cjs.entry.js +1 -1
- package/dist/cjs/ez-filter-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-form.cjs.entry.js +1 -1
- package/dist/cjs/ez-grid.cjs.entry.js +1 -1
- package/dist/cjs/ez-icon.cjs.entry.js +1 -1
- package/dist/cjs/ez-list.cjs.entry.js +1 -1
- package/dist/cjs/ez-loading-bar.cjs.entry.js +1 -1
- package/dist/cjs/ez-modal-container.cjs.entry.js +1 -1
- package/dist/cjs/ez-modal.cjs.entry.js +1 -1
- package/dist/cjs/ez-number-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-popover.cjs.entry.js +1 -1
- package/dist/cjs/ez-popup.cjs.entry.js +1 -1
- package/dist/cjs/ez-radio-button.cjs.entry.js +1 -1
- package/dist/cjs/ez-scroller.cjs.entry.js +1 -1
- package/dist/cjs/ez-search.cjs.entry.js +1 -1
- package/dist/cjs/ez-sidebar-button.cjs.entry.js +1 -1
- package/dist/cjs/ez-tabselector.cjs.entry.js +1 -1
- package/dist/cjs/ez-text-area.cjs.entry.js +1 -1
- package/dist/cjs/ez-text-edit.cjs.entry.js +1 -1
- package/dist/cjs/ez-text-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-time-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-toast.cjs.entry.js +1 -1
- package/dist/cjs/ez-tree.cjs.entry.js +1 -1
- package/dist/cjs/ez-upload.cjs.entry.js +1 -1
- package/dist/cjs/ez-view-stack.cjs.entry.js +1 -1
- package/dist/cjs/ezui.cjs.js +2 -2
- package/dist/cjs/{index-8646c40d.js → index-fb179d74.js} +3 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/ez-dropdown/ez-dropdown.css +349 -0
- package/dist/collection/components/ez-dropdown/ez-dropdown.js +339 -0
- package/dist/collection/components/ez-dropdown/structure/DropdownItem.js +33 -0
- package/dist/collection/components/ez-dropdown/structure/SubmenuControl.js +241 -0
- package/dist/custom-elements/index.d.ts +6 -0
- package/dist/custom-elements/index.js +501 -2
- package/dist/esm/ez-actions-button.entry.js +1 -1
- package/dist/esm/ez-alert.entry.js +1 -1
- package/dist/esm/ez-application.entry.js +1 -1
- package/dist/esm/ez-breadcrumb.entry.js +1 -1
- package/dist/esm/ez-button.entry.js +1 -1
- package/dist/esm/ez-calendar.entry.js +1 -1
- package/dist/esm/ez-card-item.entry.js +1 -1
- package/dist/esm/ez-check.entry.js +1 -1
- package/dist/esm/ez-chip.entry.js +1 -1
- package/dist/esm/ez-collapsible-box.entry.js +1 -1
- package/dist/esm/ez-combo-box.entry.js +1 -1
- package/dist/esm/ez-date-input.entry.js +1 -1
- package/dist/esm/ez-date-time-input.entry.js +1 -1
- package/dist/esm/ez-dialog.entry.js +1 -1
- package/dist/esm/ez-dropdown.entry.js +499 -0
- package/dist/esm/ez-file-item.entry.js +1 -1
- package/dist/esm/ez-filter-input.entry.js +1 -1
- package/dist/esm/ez-form.entry.js +1 -1
- package/dist/esm/ez-grid.entry.js +1 -1
- package/dist/esm/ez-icon.entry.js +1 -1
- package/dist/esm/ez-list.entry.js +1 -1
- package/dist/esm/ez-loading-bar.entry.js +1 -1
- package/dist/esm/ez-modal-container.entry.js +1 -1
- package/dist/esm/ez-modal.entry.js +1 -1
- package/dist/esm/ez-number-input.entry.js +1 -1
- package/dist/esm/ez-popover.entry.js +1 -1
- package/dist/esm/ez-popup.entry.js +1 -1
- package/dist/esm/ez-radio-button.entry.js +1 -1
- package/dist/esm/ez-scroller.entry.js +1 -1
- package/dist/esm/ez-search.entry.js +1 -1
- package/dist/esm/ez-sidebar-button.entry.js +1 -1
- package/dist/esm/ez-tabselector.entry.js +1 -1
- package/dist/esm/ez-text-area.entry.js +1 -1
- package/dist/esm/ez-text-edit.entry.js +1 -1
- package/dist/esm/ez-text-input.entry.js +1 -1
- package/dist/esm/ez-time-input.entry.js +1 -1
- package/dist/esm/ez-toast.entry.js +1 -1
- package/dist/esm/ez-tree.entry.js +1 -1
- package/dist/esm/ez-upload.entry.js +1 -1
- package/dist/esm/ez-view-stack.entry.js +1 -1
- package/dist/esm/ezui.js +2 -2
- package/dist/esm/{index-7bc778b3.js → index-b77dcd0d.js} +3 -0
- package/dist/esm/loader.js +2 -2
- package/dist/ezui/ezui.esm.js +1 -1
- package/dist/ezui/{p-cfcc23e6.entry.js → p-07d07b75.entry.js} +1 -1
- package/dist/ezui/{p-7c227b86.entry.js → p-21782390.entry.js} +1 -1
- package/dist/ezui/{p-739d60d1.entry.js → p-22f06920.entry.js} +1 -1
- package/dist/ezui/{p-f6111077.entry.js → p-2686fa5b.entry.js} +1 -1
- package/dist/ezui/{p-b60fbad2.entry.js → p-297d4378.entry.js} +1 -1
- package/dist/ezui/p-42376b77.entry.js +1 -0
- package/dist/ezui/{p-f18f16e0.entry.js → p-42f85e36.entry.js} +1 -1
- package/dist/ezui/{p-171c3236.entry.js → p-46c3cd8e.entry.js} +1 -1
- package/dist/ezui/{p-32f9f83a.entry.js → p-4b93860c.entry.js} +1 -1
- package/dist/ezui/{p-7e496975.entry.js → p-52a18a6c.entry.js} +1 -1
- package/dist/ezui/{p-5dc3af60.entry.js → p-5d19cd0d.entry.js} +1 -1
- package/dist/ezui/{p-9def6fd0.entry.js → p-5e3079cb.entry.js} +1 -1
- package/dist/ezui/{p-ea877274.entry.js → p-620e71e2.entry.js} +1 -1
- package/dist/ezui/{p-04fab1e9.entry.js → p-6a53943d.entry.js} +1 -1
- package/dist/ezui/{p-1634c851.entry.js → p-6c43b275.entry.js} +1 -1
- package/dist/ezui/{p-3c7ea91b.js → p-6ccf5720.js} +1 -1
- package/dist/ezui/{p-123a2bd5.entry.js → p-6cdfe0db.entry.js} +1 -1
- package/dist/ezui/p-74a3f9d8.entry.js +1 -0
- package/dist/ezui/{p-a2e55b33.entry.js → p-7d8e693d.entry.js} +1 -1
- package/dist/ezui/{p-93bcc628.entry.js → p-7e9ab877.entry.js} +1 -1
- package/dist/ezui/{p-5c9ce8a7.entry.js → p-87dd65ba.entry.js} +1 -1
- package/dist/ezui/{p-f2627de5.entry.js → p-8c273b22.entry.js} +1 -1
- package/dist/ezui/{p-04a3b457.entry.js → p-9171043f.entry.js} +1 -1
- package/dist/ezui/{p-941e9792.entry.js → p-98c78c29.entry.js} +1 -1
- package/dist/ezui/{p-ddb1c350.entry.js → p-99e07a6b.entry.js} +1 -1
- package/dist/ezui/{p-6fd5e142.entry.js → p-a4405e80.entry.js} +1 -1
- package/dist/ezui/{p-f2c4e811.entry.js → p-a7380524.entry.js} +1 -1
- package/dist/ezui/{p-79e409c6.entry.js → p-a928ea8d.entry.js} +1 -1
- package/dist/ezui/{p-25e83e46.entry.js → p-b5efd273.entry.js} +1 -1
- package/dist/ezui/{p-9404f22b.entry.js → p-b7a8708e.entry.js} +1 -1
- package/dist/ezui/{p-46113d5a.entry.js → p-b9d91679.entry.js} +1 -1
- package/dist/ezui/{p-1a89d3ff.entry.js → p-ba7b2b8f.entry.js} +1 -1
- package/dist/ezui/{p-14a04845.entry.js → p-bdb5e325.entry.js} +1 -1
- package/dist/ezui/{p-50ae478a.entry.js → p-d04f3bb1.entry.js} +1 -1
- package/dist/ezui/{p-e613d9bf.entry.js → p-e3743d12.entry.js} +1 -1
- package/dist/ezui/{p-37335c51.entry.js → p-e628c8bd.entry.js} +1 -1
- package/dist/ezui/{p-ad5fe50b.entry.js → p-e881ec6d.entry.js} +1 -1
- package/dist/ezui/{p-3cfefc57.entry.js → p-e9b4b3bd.entry.js} +1 -1
- package/dist/ezui/{p-74c7f960.entry.js → p-f58201e8.entry.js} +1 -1
- package/dist/ezui/{p-a86d00b3.entry.js → p-f8f87959.entry.js} +1 -1
- package/dist/ezui/{p-9334a724.entry.js → p-fe1f0c92.entry.js} +1 -1
- package/dist/types/components/ez-dropdown/ez-dropdown.d.ts +58 -0
- package/dist/types/components/ez-dropdown/structure/DropdownItem.d.ts +28 -0
- package/dist/types/components/ez-dropdown/structure/SubmenuControl.d.ts +78 -0
- package/dist/types/components.d.ts +46 -0
- package/package.json +2 -2
- package/react/components.d.ts +1 -0
- package/react/components.js +1 -0
- package/react/components.js.map +1 -1
- package/dist/ezui/p-1cc11468.entry.js +0 -1
|
@@ -0,0 +1,503 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-fb179d74.js');
|
|
6
|
+
const core = require('@sankhyalabs/core');
|
|
7
|
+
|
|
8
|
+
const DropdownItem = ({ item, hasIcon, hasChildren, isLockedLevels, onSubActionClick }) => {
|
|
9
|
+
return (index.h("div", { class: "ez-dropdown__item-wrapper", title: item.label },
|
|
10
|
+
getContentLeft(item, hasIcon),
|
|
11
|
+
index.h("span", { class: "ez-dropdown__item-label" }, item.label),
|
|
12
|
+
getContentRight(item, hasChildren, isLockedLevels, onSubActionClick)));
|
|
13
|
+
};
|
|
14
|
+
const getContentLeft = (item, hasIcon) => {
|
|
15
|
+
if (item == undefined || !hasIcon) {
|
|
16
|
+
return;
|
|
17
|
+
}
|
|
18
|
+
if (item.iconName) {
|
|
19
|
+
return (index.h("ez-icon", Object.assign({ class: "ez-dropdown__icon-left", iconName: item.iconName, size: "medium" }, { [core.ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${item.id}_ezDropdownItemIcon` })));
|
|
20
|
+
}
|
|
21
|
+
return (index.h("ez-icon", { class: "ez-dropdown__icon-left ez-dropdown__hidden", size: "medium" }));
|
|
22
|
+
};
|
|
23
|
+
const getContentRight = (item, hasChildren, isLockedLevels, onClick) => {
|
|
24
|
+
var _a, _b;
|
|
25
|
+
if (item == undefined) {
|
|
26
|
+
return;
|
|
27
|
+
}
|
|
28
|
+
if (!((_a = item.children) === null || _a === void 0 ? void 0 : _a.length) && item.subAction != undefined && Object.keys(item.subAction).length > 0) {
|
|
29
|
+
return (index.h("span", Object.assign({ onClick: () => onClick(item), title: item.subAction.label, class: `ez-dropdown__link ez-dropdown__link--${item.subAction.type || "primary"}` }, { [core.ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${item.subAction.id}_ezDropdownItemSubAction` }), item.subAction.label));
|
|
30
|
+
}
|
|
31
|
+
if (isLockedLevels || !hasChildren) {
|
|
32
|
+
return;
|
|
33
|
+
}
|
|
34
|
+
if (((_b = item.children) === null || _b === void 0 ? void 0 : _b.length) > 0) {
|
|
35
|
+
return (index.h("ez-icon", Object.assign({ class: "ez-dropdown__icon-right", iconName: "chevron-right", size: "medium" }, { [core.ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${item.id}_ezDropdownIconOpenChildren` })));
|
|
36
|
+
}
|
|
37
|
+
return (index.h("ez-icon", { class: "ez-dropdown__icon-right ez-dropdown__hidden", size: "medium" }));
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
class SubmenuControl {
|
|
41
|
+
constructor() { }
|
|
42
|
+
//---------------------------------------------
|
|
43
|
+
// Public methods
|
|
44
|
+
//---------------------------------------------
|
|
45
|
+
/**
|
|
46
|
+
* Método responsável por fechar submenus abertos e abrir o submenu desejado.
|
|
47
|
+
* @param menu - Item de menu selecionado para abrir o submenu.
|
|
48
|
+
*/
|
|
49
|
+
show(menu) {
|
|
50
|
+
const submenu = menu === null || menu === void 0 ? void 0 : menu.querySelector(".ez-dropdown__submenu");
|
|
51
|
+
if (menu == undefined || submenu == undefined) {
|
|
52
|
+
return;
|
|
53
|
+
}
|
|
54
|
+
submenu.classList.remove("ez-dropdown__submenu--hide");
|
|
55
|
+
this.setPosition(menu);
|
|
56
|
+
this.setScrollContainer(menu);
|
|
57
|
+
this.setMaxHeight(submenu);
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Método responsável por fechar um determinado submenu aberto.
|
|
61
|
+
* @param menu - Item de menu selecionado com o submenu aberto.
|
|
62
|
+
*/
|
|
63
|
+
hide(menu) {
|
|
64
|
+
if (menu == undefined) {
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
const submenuSelector = ".ez-dropdown__submenu:not(.ez-dropdown__submenu--hide)";
|
|
68
|
+
const submenuElement = menu.querySelector(submenuSelector);
|
|
69
|
+
this.reset(submenuElement);
|
|
70
|
+
this.hideChild(submenuElement);
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Método responsável por fechar todos os submenus filhos de um determinado submenu.
|
|
74
|
+
* @param submenu - Elemento HTML do submenu pai.
|
|
75
|
+
*/
|
|
76
|
+
hideChild(submenu) {
|
|
77
|
+
if (submenu == undefined) {
|
|
78
|
+
return;
|
|
79
|
+
}
|
|
80
|
+
submenu.querySelectorAll(".ez-dropdown__submenu")
|
|
81
|
+
.forEach((child) => {
|
|
82
|
+
this.reset(child);
|
|
83
|
+
});
|
|
84
|
+
}
|
|
85
|
+
/**
|
|
86
|
+
* Método responsável por posicionar o submenu na tela.
|
|
87
|
+
* @param menu - Item da lista selecionado para abrir o submenu.
|
|
88
|
+
*/
|
|
89
|
+
setPosition(menu) {
|
|
90
|
+
const submenu = menu === null || menu === void 0 ? void 0 : menu.querySelector(".ez-dropdown__submenu");
|
|
91
|
+
const dropdown = menu === null || menu === void 0 ? void 0 : menu.closest(".ez-dropdown");
|
|
92
|
+
if (submenu == undefined || dropdown == undefined) {
|
|
93
|
+
return;
|
|
94
|
+
}
|
|
95
|
+
submenu.style.top = this.getPositionTop(menu);
|
|
96
|
+
submenu.style.left = this.getPositionRight(dropdown);
|
|
97
|
+
const bounding = submenu === null || submenu === void 0 ? void 0 : submenu.getBoundingClientRect();
|
|
98
|
+
const docWidth = document.body.clientWidth;
|
|
99
|
+
if ((bounding === null || bounding === void 0 ? void 0 : bounding.right) > docWidth) {
|
|
100
|
+
this.updatePosition(dropdown, submenu);
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* Método responsável por controlar a altura máxima do dropdown.
|
|
105
|
+
* @param element - Elemento HTML pai do dropdown que será renderizado.
|
|
106
|
+
*/
|
|
107
|
+
setMaxHeight(element) {
|
|
108
|
+
var _a;
|
|
109
|
+
const parentElement = (element === null || element === void 0 ? void 0 : element.shadowRoot) || element;
|
|
110
|
+
const dropdown = parentElement === null || parentElement === void 0 ? void 0 : parentElement.querySelector(".ez-dropdown");
|
|
111
|
+
const docHeight = document.body.clientHeight;
|
|
112
|
+
let submenu;
|
|
113
|
+
let bounding;
|
|
114
|
+
if ((parentElement === null || parentElement === void 0 ? void 0 : parentElement["tagName"]) != undefined) {
|
|
115
|
+
submenu = parentElement;
|
|
116
|
+
bounding = submenu === null || submenu === void 0 ? void 0 : submenu.getBoundingClientRect();
|
|
117
|
+
}
|
|
118
|
+
else {
|
|
119
|
+
bounding = dropdown === null || dropdown === void 0 ? void 0 : dropdown.getBoundingClientRect();
|
|
120
|
+
}
|
|
121
|
+
if (dropdown == undefined || bounding == undefined) {
|
|
122
|
+
return;
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* Menu aberto irá ultrapassar a altura da página?
|
|
126
|
+
*/
|
|
127
|
+
if ((bounding.y + bounding.height) > docHeight) {
|
|
128
|
+
/**
|
|
129
|
+
* Menu aberto é um submenu?
|
|
130
|
+
* Sim: realiza o calculo com base na altura do menu pai
|
|
131
|
+
* Não: recalcula a altura do menu para atualizar a barra de rolagem
|
|
132
|
+
*/
|
|
133
|
+
if (submenu != undefined) {
|
|
134
|
+
const dropdownParent = submenu.closest(".ez-dropdown");
|
|
135
|
+
const boundingParent = dropdownParent === null || dropdownParent === void 0 ? void 0 : dropdownParent.getBoundingClientRect();
|
|
136
|
+
const marginTop = parseFloat(((_a = getComputedStyle(submenu)) === null || _a === void 0 ? void 0 : _a.marginTop) || "0");
|
|
137
|
+
if (dropdownParent == undefined || boundingParent == undefined) {
|
|
138
|
+
return;
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* Submenu aberto ao ser reposicionado ficará acima da altura do menu pai?
|
|
142
|
+
* Sim: posiciona o submenu na altura do menu pai e recalcula a sua altura para atualizar a barra de rolagem
|
|
143
|
+
* Não: posiciona o submenu entre a altura do menu pai e o rodapé da página
|
|
144
|
+
*/
|
|
145
|
+
if ((boundingParent.y + bounding.height) > docHeight) {
|
|
146
|
+
submenu.style.top = (boundingParent.y - marginTop) + "px";
|
|
147
|
+
dropdown.style.maxHeight = (docHeight - boundingParent.y) + "px";
|
|
148
|
+
}
|
|
149
|
+
else {
|
|
150
|
+
submenu.style.top = (docHeight - bounding.height - marginTop) + "px";
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
else {
|
|
154
|
+
let maxHeight = docHeight - bounding.y;
|
|
155
|
+
if (maxHeight < 0) {
|
|
156
|
+
maxHeight = bounding.height - docHeight;
|
|
157
|
+
}
|
|
158
|
+
dropdown.style.maxHeight = maxHeight + "px";
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
this.setSpacerContainer(dropdown);
|
|
162
|
+
}
|
|
163
|
+
/**
|
|
164
|
+
* Método responsável por atribuir a classe de espaçamento entre o conteúdo e o scroll.
|
|
165
|
+
* @param dropdown - Elemento HTML pai do container que receberá a classe.
|
|
166
|
+
*/
|
|
167
|
+
setSpacerContainer(dropdown) {
|
|
168
|
+
const container = dropdown === null || dropdown === void 0 ? void 0 : dropdown.querySelector(".ez-dropdown__container");
|
|
169
|
+
if (container == undefined) {
|
|
170
|
+
return;
|
|
171
|
+
}
|
|
172
|
+
if (container.scrollHeight > container.clientHeight) {
|
|
173
|
+
container.classList.add("ez-dropdown__container--spacer");
|
|
174
|
+
}
|
|
175
|
+
else {
|
|
176
|
+
container.classList.remove("ez-dropdown__container--spacer");
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
/**
|
|
180
|
+
* Método responsável por resetar um determinado submenu aberto.
|
|
181
|
+
* @param submenu - Elemento HTML do submenu que será resetado.
|
|
182
|
+
*/
|
|
183
|
+
reset(submenu) {
|
|
184
|
+
if (submenu == undefined) {
|
|
185
|
+
return;
|
|
186
|
+
}
|
|
187
|
+
submenu.classList.add("ez-dropdown__submenu--hide");
|
|
188
|
+
submenu.style.left = "";
|
|
189
|
+
submenu.style.top = "";
|
|
190
|
+
const dropdown = submenu.querySelector(".ez-dropdown");
|
|
191
|
+
this.resetDropdown(dropdown);
|
|
192
|
+
}
|
|
193
|
+
/**
|
|
194
|
+
* Método responsável por resetar um determinado dropdown renderizado.
|
|
195
|
+
* @param dropdown - Elemento HTML do dropdown que será resetado.
|
|
196
|
+
*/
|
|
197
|
+
resetDropdown(dropdown) {
|
|
198
|
+
if (dropdown == undefined) {
|
|
199
|
+
return;
|
|
200
|
+
}
|
|
201
|
+
dropdown.style.maxHeight = "";
|
|
202
|
+
this.setSpacerContainer(dropdown);
|
|
203
|
+
}
|
|
204
|
+
//---------------------------------------------
|
|
205
|
+
// Private methods
|
|
206
|
+
//---------------------------------------------
|
|
207
|
+
/**
|
|
208
|
+
* Método responsável por controlar o scroll do container do submenu aberto.
|
|
209
|
+
* @param menu - Item da lista selecionado para abrir o submenu.
|
|
210
|
+
*/
|
|
211
|
+
setScrollContainer(menu) {
|
|
212
|
+
const container = menu === null || menu === void 0 ? void 0 : menu.closest(".ez-dropdown__container");
|
|
213
|
+
if (container == undefined) {
|
|
214
|
+
return;
|
|
215
|
+
}
|
|
216
|
+
container.onscroll = this.onScrollContainer.bind(this);
|
|
217
|
+
}
|
|
218
|
+
/**
|
|
219
|
+
* Método responsável por fechar os submenus filhos ao movimentar o scroll.
|
|
220
|
+
* @param event - Evento de scroll disparado pelo Elemento HTML pai.
|
|
221
|
+
*/
|
|
222
|
+
onScrollContainer(event) {
|
|
223
|
+
const target = event === null || event === void 0 ? void 0 : event.target;
|
|
224
|
+
this.hideChild(target);
|
|
225
|
+
}
|
|
226
|
+
/**
|
|
227
|
+
* Método responsável por retornar a posição superior (top) de um elemento HTML na tela.
|
|
228
|
+
* @param hostElement - Elemento HTML que será capturado o valor de sua posição superior (top) na tela.
|
|
229
|
+
* @returns Valor da posição superior (top) de um determinado elemento HTML.
|
|
230
|
+
*/
|
|
231
|
+
getPositionTop(hostElement) {
|
|
232
|
+
const boundingHost = hostElement === null || hostElement === void 0 ? void 0 : hostElement.getBoundingClientRect();
|
|
233
|
+
if (boundingHost == undefined) {
|
|
234
|
+
return;
|
|
235
|
+
}
|
|
236
|
+
return boundingHost.y + "px";
|
|
237
|
+
}
|
|
238
|
+
/**
|
|
239
|
+
* Método responsável por retornar a posição direita (right) de um elemento HTML na tela.
|
|
240
|
+
* @param hostElement - Elemento HTML que será capturado o valor de sua posição direita (right) na tela.
|
|
241
|
+
* @returns Valor da posição direita (right) de um determinado elemento HTML.
|
|
242
|
+
*/
|
|
243
|
+
getPositionRight(hostElement) {
|
|
244
|
+
const boundingHost = hostElement === null || hostElement === void 0 ? void 0 : hostElement.getBoundingClientRect();
|
|
245
|
+
if (boundingHost == undefined) {
|
|
246
|
+
return;
|
|
247
|
+
}
|
|
248
|
+
return (boundingHost.x + boundingHost.width) + "px";
|
|
249
|
+
}
|
|
250
|
+
/**
|
|
251
|
+
* Método responsável por retornar a posição esquerda (left) de um elemento HTML desconsiderando a largura de outro elemento HTML.
|
|
252
|
+
* @param hostElement - Elemento HTML que será capturado o valor de sua posição esquerda (left) na tela.
|
|
253
|
+
* @param targetElement - Elemento HTML que será capturado o valor de sua largura (width).
|
|
254
|
+
* @returns Valor da posição esquerda (left) de um determinado elemento HTML desconsiderando a largura de outro elemento HTML.
|
|
255
|
+
*/
|
|
256
|
+
getPositionLeft(hostElement, targetElement) {
|
|
257
|
+
const boundingHost = hostElement === null || hostElement === void 0 ? void 0 : hostElement.getBoundingClientRect();
|
|
258
|
+
const boundingTarget = targetElement === null || targetElement === void 0 ? void 0 : targetElement.getBoundingClientRect();
|
|
259
|
+
if (boundingHost == undefined || boundingTarget == undefined) {
|
|
260
|
+
return;
|
|
261
|
+
}
|
|
262
|
+
return (boundingHost.x - boundingTarget.width) + "px";
|
|
263
|
+
}
|
|
264
|
+
/**
|
|
265
|
+
* Método responsável por atualizar a posição de um elemento HTML que renderizou fora da tela.
|
|
266
|
+
* @param hostElement - Elemento HTML que será a referência de posição dentro da tela.
|
|
267
|
+
* @param targetElement - Elemento HTML que será reposicionado na tela.
|
|
268
|
+
*/
|
|
269
|
+
updatePosition(hostElement, targetElement) {
|
|
270
|
+
const boundingHost = hostElement === null || hostElement === void 0 ? void 0 : hostElement.getBoundingClientRect();
|
|
271
|
+
const boundingTarget = targetElement === null || targetElement === void 0 ? void 0 : targetElement.getBoundingClientRect();
|
|
272
|
+
if (boundingHost == undefined || boundingTarget == undefined) {
|
|
273
|
+
return;
|
|
274
|
+
}
|
|
275
|
+
if (boundingHost.x < boundingTarget.right) {
|
|
276
|
+
targetElement.style.left = this.getPositionLeft(hostElement, targetElement);
|
|
277
|
+
this.updatePosition(hostElement, targetElement);
|
|
278
|
+
}
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
const ezDropdownCss = ":host{--ez-dropdown--z-index:var(--more-visible, 2);--ez-dropdown--padding:var(--space--small, 6px);--ez-dropdown--box-shadow:var(--shadow--medium, 0px 8px 24px rgba(0, 38, 111, 0.1));--ez-dropdown--border-radius:var(--border--radius-medium, 12px);--ez-dropdown--background-color:var(--background--xlight, #fff);--ez-dropdown--font-family:var(--font-pattern, 'Roboto');--ez-dropdown--max-width:320px;--ez-dropdown--max-height:440px;--ez-dropdown__item--padding:var(--space--small, 6px);--ez-dropdown__item--gap:var(--space--small, 6px);--ez-dropdown__item--border-radius:var(--border--radius-small, 6px);--ez-dropdown__item--color:var(--title--primary, #2b3a54);--ez-dropdown__item--font-weight:var(--text-weight--medium, 400);--ez-dropdown__item--font-size:var(--text--medium, 14px);--ez-dropdown__item--line-height:calc(var(--ez-dropdown__item--font-size) + 4px);--ez-dropdown__item--background-color:var(--background--medium, #f0f3f7);--ez-dropdown__item--transition:var(--transition, .2s linear);--ez-dropdown__item-label--margin-right:var(--space--medium, 12px);--ez-dropdown__icon--size:var(--icon--medium, 18px);--ez-dropdown__divider--background-color:var(--color--disable-secondary, #f2f5f8);--ez-dropdown__divider--margin:var(--space--extra-small, 3px) 0;--ez-dropdown__group-label--color:var(--text--secondary, #A2ABB9);--ez-dropdown__group-label--font-weight:var(--text-weight--large, 600);--ez-dropdown__group-label--font-size:var(--text--small, 12px);--ez-dropdown__group-label--line-height:var(--text--medium, 14px);--ez-dropdown__group-label--padding:var(--space--small, 6px);--ez-dropdown__submenu--z-index:var(--most-visible, 3);--ez-dropdown__link--font-weight:var(--text-weight--large, 600);--ez-dropdown__link--primary--color:var(--color--primary, #008561);--ez-dropdown__link--critical--color:var(--color-alert--error-800, #BD0025);--ez-dropdown__scrollbar--color-default:var(--scrollbar--default, #626e82);--ez-dropdown__scrollbar--color-background:var(--scrollbar--background, #E5EAF0);--ez-dropdown__scrollbar--color-hover:var(--scrollbar--hover, #2B3A54);--ez-dropdown__scrollbar--color-clicked:var(--scrollbar--clicked, #a2abb9);--ez-dropdown__scrollbar--border-radius:var(--border--radius-small, 6px);--ez-dropdown__scrollbar--width:var(--space--small, 6px);--ez-dropdown__scrollbar--padding-right:var(--space--extra-small, 3px);display:flex;flex-direction:column;height:fit-content;user-select:none;box-sizing:border-box;position:fixed;z-index:var(--ez-dropdown--z-index)}:host *{box-sizing:border-box}.ez-dropdown{display:flex;padding:var(--ez-dropdown--padding);box-shadow:var(--ez-dropdown--box-shadow);border-radius:var(--ez-dropdown--border-radius);background-color:var(--ez-dropdown--background-color);max-width:var(--ez-dropdown--max-width);max-height:var(--ez-dropdown--max-height)}.ez-dropdown *{font-family:var(--ez-dropdown--font-family)}.ez-dropdown__container{display:flex;flex-direction:column;overflow-y:auto;scrollbar-width:thin;flex:auto;scrollbar-color:var(--ez-dropdown__scrollbar--color-clicked) var(--ez-dropdown__scrollbar--color-background)}.ez-dropdown__container::-webkit-scrollbar{background-color:var(--ez-dropdown__scrollbar--color-background);width:var(--ez-dropdown__scrollbar--width);max-width:var(--ez-dropdown__scrollbar--width);min-width:var(--ez-dropdown__scrollbar--width)}.ez-dropdown__container::-webkit-scrollbar-track{background-color:var(--ez-dropdown__scrollbar--color-background);border-radius:var(--ez-dropdown__scrollbar--border-radius)}.ez-dropdown__container::-webkit-scrollbar-thumb{background-color:var(--ez-dropdown__scrollbar--color-default);border-radius:var(--ez-dropdown__scrollbar--border-radius)}.ez-dropdown__container::-webkit-scrollbar-thumb:vertical:hover,.ez-dropdown__container::-webkit-scrollbar-thumb:horizontal:hover{background-color:var(--ez-dropdown__scrollbar--color-hover)}.ez-dropdown__container::-webkit-scrollbar-thumb:vertical:active,.ez-dropdown__container::-webkit-scrollbar-thumb:horizontal:active{background-color:var(--ez-dropdown__scrollbar--color-clicked)}.ez-dropdown__container--spacer{padding-right:var(--ez-dropdown__scrollbar--padding-right)}.ez-dropdown__item{display:flex;align-items:center;background-color:transparent;border-radius:var(--ez-dropdown__item--border-radius);transition:var(--ez-dropdown__item--transition)}.ez-dropdown__item:hover{background-color:var(--ez-dropdown__item--background-color)}.ez-dropdown__item-wrapper{display:flex;align-items:center;position:relative;cursor:pointer;width:100%;margin:0;white-space:nowrap;gap:var(--ez-dropdown__item--gap);color:var(--ez-dropdown__item--color);font-weight:var(--ez-dropdown__item--font-weight);font-size:var(--ez-dropdown__item--font-size);line-height:var(--ez-dropdown__item--line-height);padding:var(--ez-dropdown__item--padding)}.ez-dropdown__item-wrapper ez-icon{display:flex;justify-content:center;align-items:center;width:var(--ez-dropdown__icon--size);height:var(--ez-dropdown__icon--size);min-width:var(--ez-dropdown__icon--size);min-height:var(--ez-dropdown__icon--size)}.ez-dropdown__item-content{display:flex;align-items:center;flex:auto;overflow:hidden;gap:var(--ez-dropdown__item--gap)}.ez-dropdown__item-label{text-align:left;text-overflow:ellipsis;overflow:hidden;flex:auto}.ez-dropdown__item-label:not(:last-child){margin-right:var(--ez-dropdown__item-label--margin-right)}.ez-dropdown__item-content+.ez-dropdown__link{margin-left:var(--ez-dropdown__item-label--margin-right);margin-right:var(--ez-dropdown__item--padding)}.ez-dropdown__item-builder{flex:auto}.ez-dropdown__divider{width:100%;height:2px;border-radius:1px;border:none;display:block;background-color:var(--ez-dropdown__divider--background-color);margin:var(--ez-dropdown__divider--margin)}.ez-dropdown__hidden{visibility:hidden}.ez-dropdown__group{display:flex;flex-direction:column}.ez-dropdown__group-label{display:block;width:100%;text-align:left;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--ez-dropdown__group-label--color);font-weight:var(--ez-dropdown__group-label--font-weight);font-size:var(--ez-dropdown__group-label--font-size);line-height:var(--ez-dropdown__group-label--line-height);padding:var(--ez-dropdown__group-label--padding)}.ez-dropdown__icon-right{margin-left:auto}.ez-dropdown__submenu{position:fixed;z-index:var(--ez-dropdown__submenu--z-index);margin-top:calc(var(--ez-dropdown__item--padding) * -1)}.ez-dropdown__submenu--hide{display:none}.ez-dropdown__link{display:block;margin-left:auto;cursor:pointer;text-overflow:ellipsis;overflow:hidden;font-weight:var(--ez-dropdown__link--font-weight);max-width:calc(var(--ez-dropdown--max-width) * 0.43)}.ez-dropdown__link--primary{color:var(--ez-dropdown__link--primary--color)}.ez-dropdown__link--critical{color:var(--ez-dropdown__link--critical--color)}.ez-dropdown__link:hover{text-decoration:underline}";
|
|
283
|
+
|
|
284
|
+
let EzDropdown = class {
|
|
285
|
+
constructor(hostRef) {
|
|
286
|
+
index.registerInstance(this, hostRef);
|
|
287
|
+
this.ezClick = index.createEvent(this, "ezClick", 7);
|
|
288
|
+
this.ezSubActionClick = index.createEvent(this, "ezSubActionClick", 7);
|
|
289
|
+
this._itemList = {};
|
|
290
|
+
this._submenuList = [];
|
|
291
|
+
this._openedMenuList = {};
|
|
292
|
+
/**
|
|
293
|
+
* Limitador de níveis de menu + submenu.
|
|
294
|
+
* Valor 0, null ou undefined desativa o limitador.
|
|
295
|
+
*/
|
|
296
|
+
this._levelLimits = 3;
|
|
297
|
+
/**
|
|
298
|
+
* Lista de itens que vão ser apresentados no dropdown.
|
|
299
|
+
*/
|
|
300
|
+
this.items = [];
|
|
301
|
+
}
|
|
302
|
+
//---------------------------------------------
|
|
303
|
+
// Private methods
|
|
304
|
+
//---------------------------------------------
|
|
305
|
+
defaultItemBuilder(item, isLockedLevels, hasIcon, hasChildren) {
|
|
306
|
+
return (index.h(DropdownItem, { item: item, hasIcon: hasIcon, hasChildren: hasChildren, isLockedLevels: isLockedLevels, onSubActionClick: this.onSubActionClick.bind(this) }));
|
|
307
|
+
}
|
|
308
|
+
getMaxOrder(items) {
|
|
309
|
+
if (items == undefined || items.length === 0) {
|
|
310
|
+
return -1;
|
|
311
|
+
}
|
|
312
|
+
return Math.max(...items.map((item) => {
|
|
313
|
+
var _a;
|
|
314
|
+
const order = (_a = item.group) === null || _a === void 0 ? void 0 : _a["order"];
|
|
315
|
+
return order != undefined && order >= 0 ? order : -1;
|
|
316
|
+
}));
|
|
317
|
+
}
|
|
318
|
+
hasIcon(items) {
|
|
319
|
+
return items === null || items === void 0 ? void 0 : items.some((item) => (item.iconName || "") !== "");
|
|
320
|
+
}
|
|
321
|
+
hasGroup(items) {
|
|
322
|
+
return items === null || items === void 0 ? void 0 : items.some((item) => (item.group || "") !== "");
|
|
323
|
+
}
|
|
324
|
+
hasChildren(items) {
|
|
325
|
+
return items === null || items === void 0 ? void 0 : items.some((item) => (item.children || []).length > 0);
|
|
326
|
+
}
|
|
327
|
+
isLockedLevels(level) {
|
|
328
|
+
if (!this._levelLimits) {
|
|
329
|
+
return false;
|
|
330
|
+
}
|
|
331
|
+
return level === (this._levelLimits + 1);
|
|
332
|
+
}
|
|
333
|
+
getItemsByGroup(items, level) {
|
|
334
|
+
let itemsByGroup = {};
|
|
335
|
+
const maxOrder = this.getMaxOrder(items);
|
|
336
|
+
items.forEach((item) => {
|
|
337
|
+
const label = item.group && item.group["label"] != undefined ? item.group["label"] || "noGroup" : item.group || "noGroup";
|
|
338
|
+
const order = item.group && item.group["order"] != undefined ? item.group["order"] : item.group ? (maxOrder + 1) : (maxOrder + 2);
|
|
339
|
+
let groupObj = itemsByGroup[label];
|
|
340
|
+
if (groupObj == undefined) {
|
|
341
|
+
groupObj = {
|
|
342
|
+
items: [],
|
|
343
|
+
order
|
|
344
|
+
};
|
|
345
|
+
}
|
|
346
|
+
this.validateItem(item, level);
|
|
347
|
+
groupObj.items.push(item);
|
|
348
|
+
itemsByGroup[label] = groupObj;
|
|
349
|
+
});
|
|
350
|
+
return core.ObjectUtils.sortByProperty(itemsByGroup, "order");
|
|
351
|
+
}
|
|
352
|
+
validateItem(item, level) {
|
|
353
|
+
if (this._itemList == undefined) {
|
|
354
|
+
this._itemList = {};
|
|
355
|
+
}
|
|
356
|
+
if (item.type == undefined) {
|
|
357
|
+
item.type = "item";
|
|
358
|
+
}
|
|
359
|
+
if (item.id == undefined) {
|
|
360
|
+
const itemId = `level_${level}_${item.type}`;
|
|
361
|
+
const counter = Object.keys(this._itemList).filter((key) => key.includes(itemId)).length;
|
|
362
|
+
item.id = `${itemId}_${counter + 1}`;
|
|
363
|
+
}
|
|
364
|
+
if (item.label == undefined) {
|
|
365
|
+
item.label = "";
|
|
366
|
+
}
|
|
367
|
+
if (item.subAction != undefined) {
|
|
368
|
+
if (item.subAction.id == undefined) {
|
|
369
|
+
const subId = `subAction_${item.id}`;
|
|
370
|
+
item.subAction.id = subId;
|
|
371
|
+
}
|
|
372
|
+
if (item.subAction.label == undefined) {
|
|
373
|
+
item.subAction.label = "";
|
|
374
|
+
}
|
|
375
|
+
}
|
|
376
|
+
if (this._itemList[item.id] == undefined) {
|
|
377
|
+
this._itemList[item.id] = {};
|
|
378
|
+
}
|
|
379
|
+
}
|
|
380
|
+
getItemsRender(groupItems, level, hasIcon, hasChildren) {
|
|
381
|
+
if (groupItems == undefined) {
|
|
382
|
+
return;
|
|
383
|
+
}
|
|
384
|
+
let counterLevel = level;
|
|
385
|
+
let isLockedLevels = false;
|
|
386
|
+
if (hasChildren) {
|
|
387
|
+
counterLevel++;
|
|
388
|
+
isLockedLevels = this.isLockedLevels(counterLevel);
|
|
389
|
+
}
|
|
390
|
+
return groupItems.map((item) => {
|
|
391
|
+
var _a;
|
|
392
|
+
return (item.type !== "divider"
|
|
393
|
+
? index.h("div", Object.assign({ ref: (ref) => this._itemList[item.id] = ref, class: "ez-dropdown__item", "data-level": level }, { [core.ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: core.ElementIDUtils.getInternalIDInfo(`${item.id}_ezDropdownItem`) }), index.h("div", { class: "ez-dropdown__item-content", onClick: (evt) => this.onItemClick(evt, item), onMouseOver: (evt) => this.onShowSubmenu(evt, item) }, this.itemBuilder
|
|
394
|
+
? index.h("div", { class: "ez-dropdown__item-builder", innerHTML: this.itemBuilder(item, level) })
|
|
395
|
+
: this.defaultItemBuilder(item, isLockedLevels, hasIcon, hasChildren)), ((_a = item.children) === null || _a === void 0 ? void 0 : _a.length) > 0 &&
|
|
396
|
+
!isLockedLevels &&
|
|
397
|
+
hasChildren &&
|
|
398
|
+
index.h("div", { ref: (ref) => this._submenuList.push(ref), class: "ez-dropdown__submenu ez-dropdown__submenu--hide" }, this.renderDropdown(item.children, counterLevel)))
|
|
399
|
+
: index.h("hr", Object.assign({ class: "ez-dropdown__divider" }, { [core.ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: `${item.id}_ezDropdownDivider` })));
|
|
400
|
+
});
|
|
401
|
+
}
|
|
402
|
+
renderDropdown(branchItems = this.items, level = 1) {
|
|
403
|
+
if (branchItems == undefined || this.isLockedLevels(level)) {
|
|
404
|
+
return;
|
|
405
|
+
}
|
|
406
|
+
const itemsByGroup = this.getItemsByGroup(branchItems, level);
|
|
407
|
+
const hasGroup = this.hasGroup(branchItems);
|
|
408
|
+
const hasIcon = this.hasIcon(branchItems);
|
|
409
|
+
const hasChildren = this.hasChildren(branchItems);
|
|
410
|
+
return (index.h("div", { class: "ez-dropdown", "data-level": level }, index.h("div", { class: "ez-dropdown__container" }, Object.keys(itemsByGroup)
|
|
411
|
+
.map((groupLabel) => {
|
|
412
|
+
return (index.h("div", Object.assign({ class: "ez-dropdown__group" }, { [core.ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: core.ElementIDUtils.getInternalIDInfo(`${groupLabel}_ezDropdownGroup`) }), groupLabel !== "noGroup" &&
|
|
413
|
+
index.h("label", { class: "ez-dropdown__group-label", title: groupLabel }, groupLabel), hasGroup &&
|
|
414
|
+
groupLabel === "noGroup" &&
|
|
415
|
+
index.h("hr", { class: "ez-dropdown__divider" }), this.getItemsRender(itemsByGroup[groupLabel].items, level, hasIcon, hasChildren)));
|
|
416
|
+
}))));
|
|
417
|
+
}
|
|
418
|
+
hasOpenedSubmenu(level) {
|
|
419
|
+
const openedLevels = Object.keys(this._openedMenuList);
|
|
420
|
+
return openedLevels.includes(level.toString())
|
|
421
|
+
|| openedLevels.some((openedLevel) => Number(openedLevel) > level);
|
|
422
|
+
}
|
|
423
|
+
hasSubmenuOpened() {
|
|
424
|
+
var _a;
|
|
425
|
+
return (_a = this._submenuList) === null || _a === void 0 ? void 0 : _a.some((submenu) => !submenu.classList.contains("ez-dropdown__submenu--hide"));
|
|
426
|
+
}
|
|
427
|
+
setEvents() {
|
|
428
|
+
document.removeEventListener('click', this.onHideAllSubmenu.bind(this));
|
|
429
|
+
document.addEventListener('click', this.onHideAllSubmenu.bind(this));
|
|
430
|
+
document.removeEventListener('scroll', this.onSubmenuReposition.bind(this));
|
|
431
|
+
document.addEventListener('scroll', this.onSubmenuReposition.bind(this));
|
|
432
|
+
}
|
|
433
|
+
//---------------------------------------------
|
|
434
|
+
// Event handlers
|
|
435
|
+
//---------------------------------------------
|
|
436
|
+
onShowSubmenu(evt, item) {
|
|
437
|
+
var _a;
|
|
438
|
+
if (evt == undefined) {
|
|
439
|
+
return;
|
|
440
|
+
}
|
|
441
|
+
const menu = this._itemList[item.id];
|
|
442
|
+
if (!(menu === null || menu === void 0 ? void 0 : menu.classList.contains("ez-dropdown__item"))) {
|
|
443
|
+
return;
|
|
444
|
+
}
|
|
445
|
+
const level = Number(menu.dataset.level || "0");
|
|
446
|
+
if (this.hasOpenedSubmenu(level)) {
|
|
447
|
+
this._submenuControl.hide(this._openedMenuList[level]);
|
|
448
|
+
delete this._openedMenuList[level];
|
|
449
|
+
}
|
|
450
|
+
if (!((_a = item.children) === null || _a === void 0 ? void 0 : _a.length)) {
|
|
451
|
+
return;
|
|
452
|
+
}
|
|
453
|
+
this._openedMenuList[menu.dataset.level] = menu;
|
|
454
|
+
this._submenuControl.show(menu);
|
|
455
|
+
}
|
|
456
|
+
onItemClick(evt, item) {
|
|
457
|
+
const target = evt === null || evt === void 0 ? void 0 : evt.target;
|
|
458
|
+
if (target === null || target === void 0 ? void 0 : target.classList.contains("ez-dropdown__link")) {
|
|
459
|
+
return;
|
|
460
|
+
}
|
|
461
|
+
this.value = item;
|
|
462
|
+
this.ezClick.emit(item);
|
|
463
|
+
}
|
|
464
|
+
onSubActionClick(item) {
|
|
465
|
+
this.ezSubActionClick.emit(item.subAction);
|
|
466
|
+
}
|
|
467
|
+
onHideAllSubmenu(evt = undefined) {
|
|
468
|
+
const target = evt === null || evt === void 0 ? void 0 : evt.target;
|
|
469
|
+
if (this.hasSubmenuOpened() && (target == undefined || (!target.closest(".ez-dropdown") && target.tagName !== "EZ-DROPDOWN"))) {
|
|
470
|
+
this._openedMenuList = {};
|
|
471
|
+
this._submenuList.forEach(this._submenuControl.reset.bind(this._submenuControl));
|
|
472
|
+
}
|
|
473
|
+
}
|
|
474
|
+
onSubmenuReposition() {
|
|
475
|
+
if (this._openedMenuList != undefined) {
|
|
476
|
+
Object.keys(this._openedMenuList).forEach((key) => {
|
|
477
|
+
const menu = this._openedMenuList[key];
|
|
478
|
+
this._submenuControl.setPosition(menu);
|
|
479
|
+
});
|
|
480
|
+
}
|
|
481
|
+
}
|
|
482
|
+
//---------------------------------------------
|
|
483
|
+
// Lifecycle web component
|
|
484
|
+
//---------------------------------------------
|
|
485
|
+
componentDidLoad() {
|
|
486
|
+
core.ElementIDUtils.addIDInfo(this._element);
|
|
487
|
+
this._submenuControl = new SubmenuControl();
|
|
488
|
+
this._submenuControl.setMaxHeight(this._element);
|
|
489
|
+
}
|
|
490
|
+
componentDidUpdate() {
|
|
491
|
+
this._submenuControl.setMaxHeight(this._element);
|
|
492
|
+
}
|
|
493
|
+
componentDidRender() {
|
|
494
|
+
this.setEvents();
|
|
495
|
+
}
|
|
496
|
+
render() {
|
|
497
|
+
return (index.h(index.Host, null, this.renderDropdown()));
|
|
498
|
+
}
|
|
499
|
+
get _element() { return index.getElement(this); }
|
|
500
|
+
};
|
|
501
|
+
EzDropdown.style = ezDropdownCss;
|
|
502
|
+
|
|
503
|
+
exports.ez_dropdown = EzDropdown;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-fb179d74.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
7
|
|
|
8
8
|
const ezFileItemCss = ":host{display:flex;width:100%;--ez-file-item--height:42px;--ez-file-item--padding:9px;--ez-file-item--border-radius:var(--border--radius-medium, 12px);--ez-file-item--border-color:var(--color--strokes, #DCE0E8);--ez-file-item--border-style:var(--border--small, 1px solid);--ez-file-item--font-family:var(--font-pattern, Arial);--ez-file-item--font-size:var(--text--medium, 14px);--ez-file-item--font-weight:var(--text-weight--medium, 400);--ez-file-item--color:var(--title--primary, #2B3A54);--ez-file-item__file-size--font-weight:var(--text-weight--large, 600);--ez-file-item__file-size--color:var(--color--primary, #008561);--ez-file-item__background-progress--color:var(--color--primary-300, E2F4EF);--ez-file-item--icon-color:var(--title--primary, #2B3A54)}.box{display:flex;box-sizing:border-box;position:relative;align-items:center;justify-content:space-between;width:100%;padding:var(--ez-file-item--padding);border:var(--ez-file-item--border-color) var(--ez-file-item--border-style);border-radius:var(--ez-file-item--border-radius);height:var(--ez-file-item--height)}.box::before{content:\"\";position:absolute;top:0;left:0;width:100%;height:100%;clip-path:inset(2px calc(var(--ez-file-item--upload-progress, 0%) + 2px) 2px 2px round calc(var(--ez-file-item--border-radius) - 4px));background-color:var(--ez-file-item__background-progress--color)}.content{display:flex;align-items:center;z-index:0;overflow:hidden}.file-name{text-overflow:ellipsis;overflow:hidden;white-space:nowrap;font-family:var(--ez-file-item--font-family);font-size:var(--ez-file-item--font-size);font-weight:var(--ez-file-item--font-weight);color:var(--ez-file-item--color)}.file-type-icon{flex-shrink:0;--ez-icon--color:var(--ez-file-item--icon-color);padding-right:var(--ez-file-item--padding)}.file-size{padding-left:2px;overflow:hidden;flex-shrink:0;white-space:nowrap;font-family:var(--ez-file-item--font-family);font-size:var(--ez-file-item--font-size);font-weight:var(--ez-file-item__file-size--font-weight);color:var(--ez-file-item__file-size--color)}.btn-remove{cursor:pointer;flex-shrink:0;--ez-icon--color:var(--ez-file-item--icon-color)}";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-fb179d74.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
7
|
const CSSVarsUtils = require('./CSSVarsUtils-af809e73.js');
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-fb179d74.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
7
|
const CheckMode = require('./CheckMode-ecb90b87.js');
|
|
8
8
|
const ApplicationUtils = require('./ApplicationUtils-350ac2ff.js');
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-fb179d74.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
7
|
|
|
8
8
|
const ezIconCss = ":host{display:flex;overflow:hidden;position:relative;--ez-icon--color:var(--icon--color, #ffffff)}svg{display:flex;justify-content:center;align-items:center;fill:var(--ez-icon--color)}.x-small{width:12px;height:12px}.small{width:16px;height:16px}.medium{width:20px;height:20px}.large{width:24px;height:24px}.x-large{width:30px;height:30px}[class^=\"ez-icon-\"],[class*=\" ez-icon-\"]{color:var(--ez-icon--color)}[class^=\"ez-icon-\"],[class*=\" ez-icon-\"]{font-family:'ez-icons' !important;font-size:16px;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.ez-icon-2chevron-down:before{content:\"\\ea01\"}.ez-icon-2chevron-up:before{content:\"\\ea02\"}.ez-icon-account-outline:before{content:\"\\ea03\"}.ez-icon-account:before{content:\"\\ea04\"}.ez-icon-actions-sprite-v1:before{content:\"\\ea05\"}.ez-icon-alert-circle-inverted:before{content:\"\\ea06\"}.ez-icon-alert-circle:before{content:\"\\ea07\"}.ez-icon-alert-mail:before{content:\"\\ea08\"}.ez-icon-alert-popup:before{content:\"\\ea09\"}.ez-icon-anexo:before{content:\"\\ea0a\"}.ez-icon-antecipação:before{content:\"\\ea0b\"}.ez-icon-apps:before{content:\"\\ea0c\"}.ez-icon-arrow_back:before{content:\"\\ea0d\"}.ez-icon-arrow_downward:before{content:\"\\ea0e\"}.ez-icon-baixa:before{content:\"\\ea0f\"}.ez-icon-balance:before{content:\"\\ea10\"}.ez-icon-bell-inverted:before{content:\"\\ea11\"}.ez-icon-bell:before{content:\"\\ea12\"}.ez-icon-boleto:before{content:\"\\ea13\"}.ez-icon-business-center:before{content:\"\\ea14\"}.ez-icon-calendar-clock:before{content:\"\\ea15\"}.ez-icon-calendar:before{content:\"\\ea16\"}.ez-icon-cash-remove:before{content:\"\\ea17\"}.ez-icon-check-circle-inverted:before{content:\"\\ea18\"}.ez-icon-check-circle:before{content:\"\\ea19\"}.ez-icon-check:before{content:\"\\ea1a\"}.ez-icon-chevron-down:before{content:\"\\ea1b\"}.ez-icon-chevron-left:before{content:\"\\ea1c\"}.ez-icon-chevron-right:before{content:\"\\ea1d\"}.ez-icon-chevron-up:before{content:\"\\ea1e\"}.ez-icon-circle--medium:before{content:\"\\ea1f\"}.ez-icon-circle:before{content:\"\\ea20\"}.ez-icon-cleaning:before{content:\"\\ea21\"}.ez-icon-clipboard:before{content:\"\\ea22\"}.ez-icon-close:before{content:\"\\ea23\"}.ez-icon-cobrar:before{content:\"\\ea24\"}.ez-icon-code:before{content:\"\\ea25\"}.ez-icon-configuration:before{content:\"\\ea26\"}.ez-icon-copy:before{content:\"\\ea27\"}.ez-icon-credit_card:before{content:\"\\ea28\"}.ez-icon-crop:before{content:\"\\ea29\"}.ez-icon-custom:before{content:\"\\ea2a\"}.ez-icon-delete:before{content:\"\\ea2b\"}.ez-icon-description:before{content:\"\\ea2c\"}.ez-icon-dividir:before{content:\"\\ea2d\"}.ez-icon-docx:before{content:\"\\ea2e\"}.ez-icon-dot-notification:before{content:\"\\ea2f\"}.ez-icon-dots-horizontal:before{content:\"\\ea30\"}.ez-icon-dots-vertical:before{content:\"\\ea31\"}.ez-icon-drag-indicator:before{content:\"\\ea32\"}.ez-icon-dual-chevron-down:before{content:\"\\ea33\"}.ez-icon-dual-chevron-up:before{content:\"\\ea34\"}.ez-icon-edit-file:before{content:\"\\ea35\"}.ez-icon-edit-table:before{content:\"\\ea36\"}.ez-icon-edit-time:before{content:\"\\ea37\"}.ez-icon-edit:before{content:\"\\ea38\"}.ez-icon-email:before{content:\"\\ea39\"}.ez-icon-estorno:before{content:\"\\ea3a\"}.ez-icon-exe:before{content:\"\\ea3b\"}.ez-icon-expand:before{content:\"\\ea3c\"}.ez-icon-expandir_card:before{content:\"\\ea3d\"}.ez-icon-extrato:before{content:\"\\ea3e\"}.ez-icon-eye-off:before{content:\"\\ea3f\"}.ez-icon-eye:before{content:\"\\ea40\"}.ez-icon-favorite:before{content:\"\\ea41\"}.ez-icon-figma:before{content:\"\\ea42\"}.ez-icon-file-download:before{content:\"\\ea43\"}.ez-icon-file-upload:before{content:\"\\ea44\"}.ez-icon-filter:before{content:\"\\ea45\"}.ez-icon-find-file:before{content:\"\\ea46\"}.ez-icon-find-page:before{content:\"\\ea47\"}.ez-icon-format-color-fill:before{content:\"\\ea48\"}.ez-icon-generic:before{content:\"\\ea49\"}.ez-icon-gif:before{content:\"\\ea4a\"}.ez-icon-graph_bar:before{content:\"\\ea4b\"}.ez-icon-handshake:before{content:\"\\ea4c\"}.ez-icon-help-inverted:before{content:\"\\ea4d\"}.ez-icon-help:before{content:\"\\ea4e\"}.ez-icon-hide_menu:before{content:\"\\ea4f\"}.ez-icon-home:before{content:\"\\ea50\"}.ez-icon-icons104:before{content:\"\\ea51\"}.ez-icon-language:before{content:\"\\ea52\"}.ez-icon-launch:before{content:\"\\ea53\"}.ez-icon-lightbulb:before{content:\"\\ea54\"}.ez-icon-list:before{content:\"\\ea55\"}.ez-icon-location:before{content:\"\\ea56\"}.ez-icon-lock-outline:before{content:\"\\ea57\"}.ez-icon-lock:before{content:\"\\ea58\"}.ez-icon-menu:before{content:\"\\ea59\"}.ez-icon-mid:before{content:\"\\ea5a\"}.ez-icon-minus:before{content:\"\\ea5b\"}.ez-icon-money-off:before{content:\"\\ea5c\"}.ez-icon-money:before{content:\"\\ea5d\"}.ez-icon-more:before{content:\"\\ea5e\"}.ez-icon-mp3:before{content:\"\\ea5f\"}.ez-icon-mp4:before{content:\"\\ea60\"}.ez-icon-north-west:before{content:\"\\ea61\"}.ez-icon-number:before{content:\"\\ea62\"}.ez-icon-ordem-ascendente:before{content:\"\\ea63\"}.ez-icon-ordem-descendente:before{content:\"\\ea64\"}.ez-icon-parcelar:before{content:\"\\ea65\"}.ez-icon-pause:before{content:\"\\ea66\"}.ez-icon-payments:before{content:\"\\ea67\"}.ez-icon-pdf:before{content:\"\\ea68\"}.ez-icon-play:before{content:\"\\ea69\"}.ez-icon-plus:before{content:\"\\ea6a\"}.ez-icon-png:before{content:\"\\ea6b\"}.ez-icon-power:before{content:\"\\ea6c\"}.ez-icon-pptx:before{content:\"\\ea6d\"}.ez-icon-print:before{content:\"\\ea6e\"}.ez-icon-push-pin:before{content:\"\\ea6f\"}.ez-icon-rateio:before{content:\"\\ea70\"}.ez-icon-receipt:before{content:\"\\ea71\"}.ez-icon-recolher_card:before{content:\"\\ea72\"}.ez-icon-restore:before{content:\"\\ea73\"}.ez-icon-return:before{content:\"\\ea74\"}.ez-icon-save:before{content:\"\\ea75\"}.ez-icon-search:before{content:\"\\ea76\"}.ez-icon-settings-inverted:before{content:\"\\ea77\"}.ez-icon-settings:before{content:\"\\ea78\"}.ez-icon-share:before{content:\"\\ea79\"}.ez-icon-shield:before{content:\"\\ea7a\"}.ez-icon-show_menu:before{content:\"\\ea7b\"}.ez-icon-south-east:before{content:\"\\ea7c\"}.ez-icon-sync:before{content:\"\\ea7d\"}.ez-icon-table:before{content:\"\\ea7e\"}.ez-icon-tag_code:before{content:\"\\ea7f\"}.ez-icon-text:before{content:\"\\ea80\"}.ez-icon-timeline:before{content:\"\\ea81\"}.ez-icon-timer-outline:before{content:\"\\ea82\"}.ez-icon-tune:before{content:\"\\ea83\"}.ez-icon-txt:before{content:\"\\ea84\"}.ez-icon-un-pin:before{content:\"\\ea85\"}.ez-icon-unfold_less:before{content:\"\\ea86\"}.ez-icon-unfold_more:before{content:\"\\ea87\"}.ez-icon-user-circle:before{content:\"\\ea88\"}.ez-icon-warning-outline:before{content:\"\\ea89\"}.ez-icon-warning_triangle:before{content:\"\\ea8a\"}.ez-icon-whatshot:before{content:\"\\ea8b\"}.ez-icon-xlsx:before{content:\"\\ea8c\"}.ez-icon-zip:before{content:\"\\ea8d\"}.x-small--font{font-size:12px}.small--font{font-size:16px}.medium--font{font-size:20px}.large--font{font-size:24px}.x-large--font{font-size:30px}";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-fb179d74.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
7
|
|
|
8
8
|
const ezListCss = ":host{--ez-list__host--z-index:var(--visible, 1);--ez-list__host--border-radius:var(--border--radius-medium, 12px);--ez-list__host--padding:var(--space--medium, 12px);--ez-list__icon--padding:var(--space--small, 6px);--ez-list__icon--color:#AFB6C0;--ez-list__item--margin:0 var(--space--small, 6px);--ez-list__item--color:var(--title--primary, #2b3a54);--ez-list__item--border-bottom:var(--border--small, 1px solid);--ez-list__item--border-color:var(--title--primary, #2b3a54);--ez-list__item--font-family:var(--font-pattern, \"Roboto\");--ez-list__item--font-size:var(--text--medium, 14px);--ez-list__selectable--padding-right:var(--space--small, 6px);--ez-list__selectable--padding-left:var(--space--small, 6px);--ez-list__selected-item--border-radius:var(--border--radius-small, 6px);--ez-list__selected-item--background-color:var(--color--primary-300, #E2F4EF);--ez-list__group--font-family:var(--font-pattern, \"Roboto\");--ez-list__group--font-size:var(--text--medium, 14px);--ez-list__group--font-weight:var(--text-weight--large, 600);--ez-list__group--padding-bottom:var(--space-small, 6px);--ez-list__group-overlay--font-family:var(--font-pattern, \"Roboto\");--ez-list__group-overlay--font-size:var(--text--medium, 14px);--ez-list__over--border--color:var(--color--primary, #008561);--ez-list__last-droppable-space--height:var(--space--small, 6px);--ez-list__draggable-list--padding-bottom:var(--space--small, 6px);--ez-list__draggable-icon--image:url('data:image/svg+xml;utf8,<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m 6.75,2.25 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z\"/></svg>');--ez-list__scrollbar--color-default:var(--scrollbar--default, #626e82);--ez-list__scrollbar--color-background:var(--scrollbar--background, #E5EAF0);--ez-list__scrollbar--color-hover:var(--scrollbar--hover, #2B3A54);--ez-list__scrollbar--color-clicked:var(--scrollbar--clicked, #a2abb9);--ez-list__scrollbar--border-radius:var(--border--radius-small, 6px);--ez-list__scrollbar--width:var(--space--medium, 12px);max-height:100%;width:100%;background-color:#fff;display:flex;z-index:var(--ez-list__host--z-index)}p{margin:0}.draggable{display:flex;align-items:center;border-top:1px dashed #fff;justify-content:space-between;background-color:#fff;flex:1;width:100%;font-family:var(--ez-list__item--font-family);font-size:var(--ez-list__item--font-size)}.dragging{background:#FFFFFF;border:1px solid #008561;box-sizing:border-box;box-shadow:0px 0px 16px rgba(0, 38, 111, 0.122);border-radius:6px}.selectable{cursor:pointer;padding-right:var(--ez-list__selectable--padding-right);padding-left:var(--ez-list__selectable--padding-left)}.selectable-container{margin:0px !important}.item-content{display:flex;justify-content:flex-start;align-items:center;width:100%}.group-container .item-content{max-width:calc(100% - 41px)}.items-container .item-content{max-width:calc(100% - 100px)}.draggable-list{padding:0;margin:0;width:100%;max-height:100%;scrollbar-width:thin;color:var(--text-color);scrollbar-color:var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background)}.draggable-list li{background-color:#fff;display:flex;height:32px;margin:var(--ez-list__item--margin);font-family:var(--ez-list__item--font-family);font-size:var(--ez-list__item--font-size);color:var(--ez-list__item--color)}.over{border-top:1px dashed var(--ez-list__over--border--color)}.last-droppable-space{height:var(--ez-list__last-droppable-space--height)}.draggable-selected{background-color:var(--background--strong) !important}.draggable-selected div:hover{background-color:var(--background--strong) !important}.draggable-list::-webkit-scrollbar{background-color:var(--ez-list__scrollbar--color-background);width:var(--ez-list__scrollbar--width);max-width:var(--ez-list__scrollbar--width);min-width:var(--ez-list__scrollbar--width)}.draggable-list::-webkit-scrollbar-track{background-color:var(--ez-list__scrollbar--color-background);border-radius:var(--ez-list__scrollbar--border-radius)}.draggable-list::-webkit-scrollbar-thumb{background-color:var(--ez-list__scrollbar--color-default);border-radius:var(--ez-list__scrollbar--border-radius)}.draggable-list::-webkit-scrollbar-thumb:vertical:hover,.draggable-list::-webkit-scrollbar-thumb:horizontal:hover{background-color:var(--ez-list__scrollbar--color-hover)}.draggable-list::-webkit-scrollbar-thumb:vertical:active,.draggable-list::-webkit-scrollbar-thumb:horizontal:active{background-color:var(--ez-list__scrollbar--color-clicked)}.draggable-icon{align-items:flex-start;display:flex;outline:none;border:none;background-color:unset}.draggable-icon::after{content:'';display:flex;width:18px;height:18px;background-color:var(--ez-list__icon--color);-webkit-mask-image:var(--ez-list__draggable-icon--image);mask-image:var(--ez-list__draggable-icon--image)}*{box-sizing:border-box}.checkbox{width:fit-content}.text--ellipsis{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.group-container{display:flex;flex-direction:column;max-height:100%;overflow-y:auto;outline:none;width:100%;scrollbar-width:thin;scrollbar-color:var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background)}.group-name{-webkit-user-select:none;-moz-user-select:-moz-none;-ms-user-select:none;user-select:none;font-family:var(--ez-list__group--font-family);font-size:var(--ez-list__group--font-size);font-weight:var(--ez-list__group--font-weight);padding-bottom:var(--ez-list__group--padding-bottom)}.group{display:flex;flex-direction:column}.group-container::-webkit-scrollbar{background-color:var(--ez-list__scrollbar--color-background);width:var(--ez-list__scrollbar--width);max-width:var(--ez-list__scrollbar--width);min-width:var(--ez-list__scrollbar--width)}.group-container::-webkit-scrollbar-track{background-color:var(--ez-list__scrollbar--color-background);border-radius:var(--ez-list__scrollbar--border-radius)}.group-container::-webkit-scrollbar-thumb{background-color:var(--ez-list__scrollbar--color-default);border-radius:var(--ez-list__scrollbar--border-radius)}.group-container::-webkit-scrollbar-thumb:vertical:hover,.group-container::-webkit-scrollbar-thumb:horizontal:hover{background-color:var(--ez-list__scrollbar--color-hover)}.group-container::-webkit-scrollbar-thumb:vertical:active,.group-container::-webkit-scrollbar-thumb:horizontal:active{background-color:var(--ez-list__scrollbar--color-clicked)}.section-container{display:flex;position:relative;height:100%}.items-container{width:100%;max-height:100%;overflow-y:auto;outline:none;scrollbar-width:thin;scrollbar-color:var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background)}.group-items-container{width:100%;max-height:100%;height:100%;outline:none}.items-container::-webkit-scrollbar{background-color:var(--ez-list__scrollbar--color-background);width:var(--ez-list__scrollbar--width);max-width:var(--ez-list__scrollbar--width);min-width:var(--ez-list__scrollbar--width)}.items-container::-webkit-scrollbar-track{background-color:var(--ez-list__scrollbar--color-background);border-radius:var(--ez-list__scrollbar--border-radius)}.items-container::-webkit-scrollbar-thumb{background-color:var(--ez-list__scrollbar--color-default);border-radius:var(--ez-list__scrollbar--border-radius)}.items-container::-webkit-scrollbar-thumb:vertical:hover,.items-container::-webkit-scrollbar-thumb:horizontal:hover{background-color:var(--ez-list__scrollbar--color-hover)}.items-container::-webkit-scrollbar-thumb:vertical:active,.items-container::-webkit-scrollbar-thumb:horizontal:active{background-color:var(--ez-list__scrollbar--color-clicked)}.group-overlay{background:rgba(226, 244, 239, 0.8);border:1px solid #008561;border-radius:8px;position:absolute;display:none;place-items:center;top:0;bottom:0;left:0;right:0;z-index:2;margin:0;cursor:pointer;font-family:var(--ez-list__group-overlay--font-family);font-size:var(--ez-list__group-overlay--font-size)}.presetedHeight{min-height:100px}.overlay-text{position:absolute;top:50%;left:50%;font-size:50px;color:white;transform:translate(-50%, -50%);-ms-transform:translate(-50%, -50%)}.selected-item{background:var(--ez-list__selected-item--background-color);border-radius:var(--ez-list__selected-item--border-radius)}.slot-item{align-items:flex-end}.overGroup{background:rgba(226, 244, 239, 0.8);border:1px solid #008561;box-sizing:border-box;border-radius:8px;padding-top:6px}";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-fb179d74.js');
|
|
6
6
|
|
|
7
7
|
const ezLoadingBarCss = ":host{position:fixed;top:0px;width:100%}.loading-bar{width:100%;margin:0 auto;position:absolute;background-color:var(--color--primary-300, #e2f4ef);height:5px}.loading-bar:before{content:'';position:absolute}.loading-bar__container{position:absolute;top:0;right:100%;bottom:0;left:0;background-color:var(--color--primary, #008561);width:0;animation:loading 2s linear infinite}@keyframes loading{0%{left:0%;right:100%;width:0%}25%{left:0%;right:75%;width:25%}50%{left:0%;right:50%;width:90%}70%{right:0%;left:75%;width:25%}100%{left:100%;right:0%;width:0%}}@-webkit-keyframes loading{0%{left:0%;right:100%;width:0%}25%{left:0%;right:75%;width:25%}50%{left:0%;right:50%;width:90%}70%{right:0%;left:75%;width:25%}100%{left:100%;right:0%;width:0%}}";
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-fb179d74.js');
|
|
6
6
|
|
|
7
7
|
const ezModalCss = ":host{--ez-modal-z-index:var(--most-visible, 3);--ez-modal-vertical-padding:var(--space--large, 24px);display:block}.modal{position:fixed;padding:var(--ez-modal-vertical-padding) 0;display:flex;top:0px;z-index:var(--ez-modal-z-index);left:0px;width:100%;box-sizing:border-box;height:100vh;backdrop-filter:blur(4px);background:rgba(0, 4, 12, 0.4)}@keyframes expand-modal--left{from{transform:translate(-100%)}}@keyframes expand-modal--right{from{transform:translate(100%)}}.modal__container{display:flex;flex-wrap:wrap;height:100%;box-sizing:border-box;width:100%;align-items:flex-start}.modal__container--right{animation:expand-modal--right .2s ease-in-out 1;justify-content:flex-end}.modal__container--left{animation:expand-modal--left .2s ease-in-out 1;justify-content:flex-start}.modal__content{display:flex;flex-wrap:wrap;box-sizing:border-box;max-height:100%;height:100%;overflow-y:auto;background-color:rgb(255, 255, 255);padding:24px;border-radius:12px 0px 0px 12px;box-shadow:rgb(0 38 111 / 12%) 0px 0px 16px 0px}.modal__content--right{border-radius:12px 0px 0px 12px}.modal__content--left{border-radius:0px 12px 12px 0px}.modal__box__container{display:flex;flex-wrap:wrap;background-color:#fff;width:100%;border-radius:12px}.row{width:100%;display:flex;flex-wrap:wrap}.col{display:flex;flex-wrap:wrap;align-self:flex-start;box-sizing:border-box}.col--stretch{align-self:stretch}.col--undefined{width:unset}.col--nowrap{flex-wrap:nowrap}@media screen and (min-width: 320px){.col--sd-1{width:8.33333%}.col--sd-2{width:16.66667%}.col--sd-3{width:25%}.col--sd-4{width:33.33333%}.col--sd-5{width:41.66667%}.col--sd-6{width:50%}.col--sd-7{width:58.33333%}.col--sd-8{width:66.66667%}.col--sd-9{width:75%}.col--sd-10{width:83.33333%}.col--sd-11{width:91.66667%}.col--sd-12{width:100%}}@media screen and (min-width: 480px){.col--pn-1{width:8.33333%}.col--pn-2{width:16.66667%}.col--pn-3{width:25%}.col--pn-4{width:33.33333%}.col--pn-5{width:41.66667%}.col--pn-6{width:50%}.col--pn-7{width:58.33333%}.col--pn-8{width:66.66667%}.col--pn-9{width:75%}.col--pn-10{width:83.33333%}.col--pn-11{width:91.66667%}.col--pn-12{width:100%}}@media screen and (min-width: 768px){.col--tb-1{width:8.33333%}.col--tb-2{width:16.66667%}.col--tb-3{width:25%}.col--tb-4{width:33.33333%}.col--tb-5{width:41.66667%}.col--tb-6{width:50%}.col--tb-7{width:58.33333%}.col--tb-8{width:66.66667%}.col--tb-9{width:75%}.col--tb-10{width:83.33333%}.col--tb-11{width:91.66667%}.col--tb-12{width:100%}}@media screen and (min-width: 992px){.col--md-1{width:8.33333%}.col--md-2{width:16.66667%}.col--md-3{width:25%}.col--md-4{width:33.33333%}.col--md-5{width:41.66667%}.col--md-6{width:50%}.col--md-7{width:58.33333%}.col--md-8{width:66.66667%}.col--md-9{width:75%}.col--md-10{width:83.33333%}.col--md-11{width:91.66667%}.col--md-12{width:100%}}@media screen and (min-width: 1200px){.col--ld-1{width:8.33333%}.col--ld-2{width:16.66667%}.col--ld-3{width:25%}.col--ld-4{width:33.33333%}.col--ld-5{width:41.66667%}.col--ld-6{width:50%}.col--ld-7{width:58.33333%}.col--ld-8{width:66.66667%}.col--ld-9{width:75%}.col--ld-10{width:83.33333%}.col--ld-11{width:91.66667%}.col--ld-12{width:100%}}";
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-fb179d74.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
7
|
const CSSVarsUtils = require('./CSSVarsUtils-af809e73.js');
|
|
8
8
|
|