@sankhyalabs/ezui 1.1.158-beta.2 → 1.1.158-beta.5
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/CSSVarsUtils-09b431cc.js +55 -0
- package/dist/cjs/ez-actions-button.cjs.entry.js +97 -0
- 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-filter-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-grid.cjs.entry.js +1 -0
- package/dist/cjs/ez-number-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-search.cjs.entry.js +1 -1
- package/dist/cjs/ez-time-input.cjs.entry.js +1 -1
- package/dist/cjs/ezui.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/ez-actions-button/ez-actions-button.css +49 -0
- package/dist/collection/components/ez-actions-button/ez-actions-button.js +174 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/DataSource.js +1 -0
- package/dist/collection/utils/CSSVarsUtils.js +34 -0
- package/dist/custom-elements/index.d.ts +6 -0
- package/dist/custom-elements/index.js +186 -60
- package/dist/esm/CSSVarsUtils-499b75c2.js +53 -0
- package/dist/esm/ez-actions-button.entry.js +93 -0
- 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-filter-input.entry.js +1 -1
- package/dist/esm/ez-grid.entry.js +1 -0
- package/dist/esm/ez-number-input.entry.js +1 -1
- package/dist/esm/ez-search.entry.js +1 -1
- package/dist/esm/ez-time-input.entry.js +1 -1
- package/dist/esm/ezui.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/ezui/ezui.esm.js +1 -1
- package/dist/ezui/{p-4fdceb7d.entry.js → p-077d3bee.entry.js} +1 -1
- package/dist/ezui/{p-49fdfa4b.entry.js → p-1cd17b3d.entry.js} +1 -1
- package/dist/ezui/p-3263a002.js +1 -0
- package/dist/ezui/{p-31f06c15.entry.js → p-43bdfabf.entry.js} +1 -1
- package/dist/ezui/{p-2f34453f.entry.js → p-69dc6352.entry.js} +1 -1
- package/dist/ezui/{p-fc9b9487.entry.js → p-8e25e469.entry.js} +1 -1
- package/dist/ezui/{p-ec21ecce.entry.js → p-b10095df.entry.js} +1 -1
- package/dist/ezui/{p-6d4b1628.entry.js → p-c29ed278.entry.js} +1 -1
- package/dist/ezui/p-db2da24a.entry.js +1 -0
- package/dist/ezui/{p-91377c65.entry.js → p-ebd2eb35.entry.js} +1 -1
- package/dist/types/components/ez-actions-button/ez-actions-button.d.ts +37 -0
- package/dist/types/components.d.ts +42 -0
- package/dist/types/utils/CSSVarsUtils.d.ts +1 -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/cjs/CSSVarsUtils-1034b7b6.js +0 -21
- package/dist/esm/CSSVarsUtils-eb4c5af6.js +0 -19
- package/dist/ezui/p-933a7475.js +0 -1
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
class CSSVarsUtils {
|
|
4
|
+
static applyVarsTextInput(host, child) {
|
|
5
|
+
if (child) {
|
|
6
|
+
CSSVarsUtils.applyIfExists(host, child, '--ez-text-input__input--background-color');
|
|
7
|
+
CSSVarsUtils.applyIfExists(host, child, '--ez-text-input__input--border-color');
|
|
8
|
+
CSSVarsUtils.applyIfExists(host, child, '--ez-text-input--height');
|
|
9
|
+
CSSVarsUtils.applyIfExists(host, child, '--ez-text-input__input--disabled--background-color');
|
|
10
|
+
CSSVarsUtils.applyIfExists(host, child, '--ez-text-input__input--disabled--color');
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
static applyVarsButton(host, child) {
|
|
14
|
+
if (child) {
|
|
15
|
+
["--ez-button--min-width",
|
|
16
|
+
"--ez-button--height",
|
|
17
|
+
"--ez-button__icon--width",
|
|
18
|
+
"--ez-button__inline__icon--padding",
|
|
19
|
+
"--ez-button--padding-top",
|
|
20
|
+
"--ez-button--padding-bottom",
|
|
21
|
+
"--ez-button--padding-right",
|
|
22
|
+
"--ez-button--padding-left",
|
|
23
|
+
"--ez-button--color",
|
|
24
|
+
"--ez-button--font-size",
|
|
25
|
+
"--ez-button--font-family",
|
|
26
|
+
"--ez-button--font-weight",
|
|
27
|
+
"--ez-button--background-color",
|
|
28
|
+
"--ez-button--border-radius",
|
|
29
|
+
"--ez-button--border",
|
|
30
|
+
"--ez-button--hover-color",
|
|
31
|
+
"--ez-button--hover--background-color",
|
|
32
|
+
"--ez-button--disabled-color",
|
|
33
|
+
"--ez-button--disabled--background-color",
|
|
34
|
+
"--ez-button--focus--border",
|
|
35
|
+
"--ez-button--focus--box-shadow",
|
|
36
|
+
"--ez-button--active-color",
|
|
37
|
+
"--ez-button--active--background-color",
|
|
38
|
+
"--ez-button--link-color",
|
|
39
|
+
"--ez-button--link--hover-color",
|
|
40
|
+
"--ez-button--link--small--font-size",
|
|
41
|
+
"--ez-button--link--medium--font-size",
|
|
42
|
+
"--ez-button--link--large--font-size",].forEach(prop => {
|
|
43
|
+
CSSVarsUtils.applyIfExists(host, child, prop);
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
static applyIfExists(host, element, varName) {
|
|
48
|
+
const prop = getComputedStyle(host).getPropertyValue(varName);
|
|
49
|
+
if (prop) {
|
|
50
|
+
element.style.setProperty(varName, prop);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
exports.CSSVarsUtils = CSSVarsUtils;
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-c15a9551.js');
|
|
6
|
+
const core = require('@sankhyalabs/core');
|
|
7
|
+
require('./ApplicationUtils-4a223c7a.js');
|
|
8
|
+
const CSSVarsUtils = require('./CSSVarsUtils-09b431cc.js');
|
|
9
|
+
|
|
10
|
+
const ezActionsButtonCss = ":host{--ez-actions-button__box--border-radius:var(--border--radius-medium, 12px);--ez-actions-button__box--box-shadow:var(--shadow, 0px 0px 16px 0px #000);--ez-actions-button__box--background-color:var(--background--xlight, #fff);--ez-actions-button__box--padding:var(--space-small, 6px);--ez-actions-button__box--top-margin:var(--space-extra-small, 3px);--ez-actions-button__action--min-width:400px;--ez-actions-button__action--background-color:var(--background--xlight, #fff);display:flex;flex-direction:column;height:fit-content;user-select:none}.actions-list{display:flex;flex-direction:column;position:absolute;width:fit-content;height:fit-content;z-index:var(--more-visible, 1);padding:var(--ez-actions-button__box--padding);margin-top:var(--ez-actions-button__box--top-margin);background-color:var(--ez-actions-button__box--background-color);border-radius:var(--ez-actions-button__box--border-radius);box-shadow:var(--ez-actions-button__box--box-shadow)}.btn-action{--ez-button--min-width:var(--ez-actions-button__action--min-width);--ez-button--background-color:var(--ez-actions-button__action--background-color)}";
|
|
11
|
+
|
|
12
|
+
let EzActionsButton = class {
|
|
13
|
+
constructor(hostRef) {
|
|
14
|
+
index.registerInstance(this, hostRef);
|
|
15
|
+
this.ezAction = index.createEvent(this, "ezAction", 7);
|
|
16
|
+
/**
|
|
17
|
+
* Deixa o campo disponível ou não para interação com usuário.
|
|
18
|
+
*/
|
|
19
|
+
this.enabled = true;
|
|
20
|
+
this.innerClickTest = (floatingContainer, node) => {
|
|
21
|
+
if (node && floatingContainer) {
|
|
22
|
+
const children = floatingContainer.children;
|
|
23
|
+
for (let i = 0; i < children.length; i++) {
|
|
24
|
+
if (children[i].shadowRoot.contains(node)) {
|
|
25
|
+
return true;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
return false;
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
showActions() {
|
|
33
|
+
if (!this.enabled) {
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
this._floatingID = core.FloatingManager.float(this._actionsList, this._listContainer, { autoClose: true, innerClickTest: this.innerClickTest });
|
|
37
|
+
const docWidth = window.innerWidth || document.documentElement.clientWidth;
|
|
38
|
+
const bounding = this._actionsList.getBoundingClientRect();
|
|
39
|
+
if (bounding.right > docWidth) {
|
|
40
|
+
core.FloatingManager.updateFloatPosition(this._actionsList, this._listContainer, { autoClose: true, innerClickTest: this.innerClickTest, left: (docWidth - bounding.width) + "px" });
|
|
41
|
+
}
|
|
42
|
+
window.requestAnimationFrame(() => {
|
|
43
|
+
this._actionsList.scrollIntoView({ behavior: "smooth", block: "nearest", inline: "nearest" });
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
hideActions() {
|
|
47
|
+
if (this._floatingID !== undefined) {
|
|
48
|
+
core.FloatingManager.close(this._floatingID);
|
|
49
|
+
}
|
|
50
|
+
this._floatingID = undefined;
|
|
51
|
+
}
|
|
52
|
+
//---------------------------------------------
|
|
53
|
+
// Event handlers
|
|
54
|
+
//---------------------------------------------
|
|
55
|
+
handlerButtonClick() {
|
|
56
|
+
this.showActions();
|
|
57
|
+
}
|
|
58
|
+
actionClick(action) {
|
|
59
|
+
this.hideActions();
|
|
60
|
+
this.ezAction.emit(action);
|
|
61
|
+
}
|
|
62
|
+
//---------------------------------------------
|
|
63
|
+
// Lifecycle web component
|
|
64
|
+
//---------------------------------------------
|
|
65
|
+
componentWillLoad() {
|
|
66
|
+
if (this.actions === undefined) {
|
|
67
|
+
this.actions = [];
|
|
68
|
+
const optionsTags = this._element.querySelectorAll("action");
|
|
69
|
+
if (optionsTags) {
|
|
70
|
+
optionsTags.forEach((e) => {
|
|
71
|
+
let label = e.innerText;
|
|
72
|
+
let value = e.getAttribute("value");
|
|
73
|
+
if (!value) {
|
|
74
|
+
value = label;
|
|
75
|
+
}
|
|
76
|
+
this.actions.push({ label, value });
|
|
77
|
+
e.hidden = true;
|
|
78
|
+
});
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
componentDidLoad() {
|
|
83
|
+
CSSVarsUtils.CSSVarsUtils.applyVarsButton(this._element, this._button);
|
|
84
|
+
}
|
|
85
|
+
componentDidRender() {
|
|
86
|
+
if (this._floatingID === undefined) {
|
|
87
|
+
this._actionsList.remove();
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
render() {
|
|
91
|
+
return (index.h(index.Host, null, index.h("ez-button", { ref: elem => this._button = elem, enabled: this.enabled, mode: "icon", iconName: "dots-vertical", size: this.size, onClick: () => this.handlerButtonClick() }), index.h("section", { class: "list-container", ref: elem => this._listContainer = elem }, index.h("div", { class: "actions-list", ref: elem => this._actionsList = elem }, this.actions.map(action => index.h("ez-button", { class: "btn-action", size: "small", label: action.label, onClick: () => this.actionClick(action) }))))));
|
|
92
|
+
}
|
|
93
|
+
get _element() { return index.getElement(this); }
|
|
94
|
+
};
|
|
95
|
+
EzActionsButton.style = ezActionsButtonCss;
|
|
96
|
+
|
|
97
|
+
exports.ez_actions_button = EzActionsButton;
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-c15a9551.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
|
-
const CSSVarsUtils = require('./CSSVarsUtils-
|
|
7
|
+
const CSSVarsUtils = require('./CSSVarsUtils-09b431cc.js');
|
|
8
8
|
|
|
9
9
|
const ezComboBoxCss = ":host{--ez-combo-box--height:42px;--ez-combo-box--width:100%;--ez-combo-box__icon--width:48px;--ez-combo-box--border-radius:var(--border--radius-medium, 12px);--ez-combo-box--border-radius-small:var(--border--radius-small, 6px);--ez-combo-box--font-size:var(--text--medium, 14px);--ez-combo-box--font-family:var(--font-pattern, Arial);--ez-combo-box--font-weight--large:var(--text-weight--large, 500);--ez-combo-box--font-weight--medium:var(--text-weight--medium, 400);--ez-combo-box--background-color--xlight:var(--background--xlight, #fff);--ez-combo-box--background-medium:var(--background--medium, #f0f3f7);--ez-combo-box__input--background-color:var(--background--medium, #e0e0e0);--ez-combo-box__input--border:var(--border--medium, 2px solid);--ez-combo-box__input--border-color:var(--ez-combo-box__input--background-color);--ez-combo-box__input--focus--border-color:var(--color--primary, #008561);--ez-combo-box__input--disabled--background-color:var(--color--disable-secondary, #F2F5F8);--ez-combo-box__input--disabled--color:var(--text--disable, #AFB6C0);--ez-combo-box__input--error--border-color:#CC2936;--ez-combo-box__btn--color:var(--text--primary, #626e82);--ez-combo-box__btn-disabled--color:var(--text--disable, #AFB6C0);--ez-combo-box__btn-hover--color:var(--color--primary, #4e4e4e);--ez-combo-box__label--color:var(--title--primary, #919191);--ez-combo-box__list-text--primary:var(--text--primary, #626e82);--ez-combo-box__list-height:calc(var(--ez-combo-box--font-size) + var(--ez-combo-box--space--medium));--ez-combo-box--space--medium:var(--space--medium, 12px);--ez-combo-box--space--small:var(--space--small, 6px);display:flex;flex-wrap:wrap;position:relative;width:var(--ez-combo-box--width)}ez-icon{--ez-icon--color:inherit}.suppressed-search-input{--ez-text-input__input--border-color:var(--color--strokes, #dce0e8);--ez-text-input__input--disabled--background-color:var(--background--xlight, #fff);--ez-text-input__input--disabled--color:var(--title--primary, #000)}.list-container{position:relative;width:100%}.options-list{box-sizing:border-box;width:100%;z-index:var(--more-visible, 2);display:flex;flex-direction:column;background-color:var(--ez-combo-box--background-color--xlight);padding:var(--ez-combo-box--space--small);border-radius:var(--ez-combo-box--border-radius);box-shadow:var(--shadow, 0px 0px 16px 0px #000);scroll-behavior:smooth;max-height:calc(4*var(--ez-combo-box__list-height) + 2*var(--ez-combo-box--space--small));overflow:auto}.item{text-align:left;display:flex;justify-content:space-between;align-items:center;border-radius:var(--ez-combo-box--border-radius-small);padding:0 var(--ez-combo-box--space--small);list-style-type:none;min-height:var(--ez-combo-box__list-height)}.item--label{text-align:left;flex-basis:85%;flex-grow:1;color:var(--ez-combo-box__list-text--primary);font-weight:var(--ez-combo-box--font-weight--large);font-family:var(--ez-combo-box--font-family);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.item--value{text-align:right;flex-basis:15%;flex-grow:0;color:var(--ez-combo-box__list-text--primary);font-weight:var(--ez-combo-box--font-weight--large);font-family:var(--ez-combo-box--font-family);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.message{text-align:center;display:flex;justify-content:center;align-items:center;list-style-type:none;padding:var(--ez-combo-box--space--small);border-radius:var(--ez-combo-box--border-radius-small);min-height:var(--ez-combo-box__list-height)}.message--no-result{color:var(--ez-combo-box__list-text--primary);font-family:var(--ez-combo-box--font-family)}.message--loading{border:2px solid var(--color--secondary-700);border-top:2px solid transparent;border-radius:50%;width:20px;height:20px;-webkit-animation:spin 1s linear infinite;animation:spin 1s linear infinite}li:hover{background-color:var(--ez-combo-box--background-medium)}.preselected{background-color:var(--background--medium)}.btn{outline:none;border:none;background:none;cursor:pointer;color:var(--ez-combo-box__btn--color)}.btn:disabled{color:var(--ez-combo-box__btn-disabled--color);cursor:unset}.btn:disabled:hover{color:var(--ez-combo-box__btn-disabled--color);cursor:unset}.btn:hover{color:var(--ez-combo-box__btn-hover--color)}@-webkit-keyframes spin{0%{-webkit-transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg)}}@keyframes spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}";
|
|
10
10
|
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-c15a9551.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
|
-
const CSSVarsUtils = require('./CSSVarsUtils-
|
|
7
|
+
const CSSVarsUtils = require('./CSSVarsUtils-09b431cc.js');
|
|
8
8
|
|
|
9
9
|
const ezDateInputCss = ":host{display:block;width:100%;--ez-date-input__input--background-color:var(--background--medium, #e0e0e0);--ez-date-input__input--border-color:var(--ez-date-input__input--background-color);--ez-date-input__calendar-image:url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" version=\"1.1\" height=\"16px\" width=\"15px\"><path d=\"M 3.171875,5.25 C 2.6485088,5.25 2.21875,5.6797588 2.21875,6.203125 2.21875,6.7264912 2.6485088,7.15625 3.171875,7.15625 3.6952412,7.15625 4.125,6.7264912 4.125,6.203125 4.125,5.6797588 3.6952412,5.25 3.171875,5.25 Z m 2.875,0 C 5.5235088,5.25 5.09375,5.6797588 5.09375,6.203125 5.09375,6.7264912 5.5235088,7.15625 6.046875,7.15625 6.5702412,7.15625 7,6.7264912 7,6.203125 7,5.6797588 6.5702412,5.25 6.046875,5.25 Z m 2.875,0 c -0.5233662,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.4297588,0.953125 0.953125,0.953125 0.5233662,0 0.9511719,-0.4297588 0.9511719,-0.953125 C 9.8730469,5.6797588 9.4452412,5.25 8.921875,5.25 Z m 2.873047,0 c -0.523366,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.429759,0.953125 0.953125,0.953125 0.523366,0 0.953125,-0.4297588 0.953125,-0.953125 C 12.748047,5.6797588 12.318288,5.25 11.794922,5.25 Z M 3.171875,8.1230469 c -0.5233662,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.4297588,0.9531251 0.953125,0.9531251 0.5233662,0 0.953125,-0.4297589 0.953125,-0.9531251 0,-0.5233662 -0.4297588,-0.953125 -0.953125,-0.953125 z m 2.875,0 c -0.5233662,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.4297588,0.9531251 0.953125,0.9531251 C 6.5702412,10.029297 7,9.5995381 7,9.0761719 7,8.5528057 6.5702412,8.1230469 6.046875,8.1230469 Z m 2.8554688,0 c -0.5233663,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.4297587,0.9531251 0.953125,0.9531251 0.5233661,0 0.9531249,-0.4297589 0.953125,-0.9531251 0,-0.5233662 -0.4297588,-0.953125 -0.953125,-0.953125 z m 2.9003902,0 c -0.523366,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.429759,0.9531251 0.953125,0.9531251 0.523367,0 0.953125,-0.4297589 0.953125,-0.9531251 0,-0.5233662 -0.429758,-0.953125 -0.953125,-0.953125 z M 3.171875,10.998047 c -0.5233662,0 -0.953125,0.429759 -0.953125,0.953125 0,0.523366 0.4297588,0.953125 0.953125,0.953125 0.5233662,0 0.953125,-0.429759 0.953125,-0.953125 0,-0.523366 -0.4297588,-0.953125 -0.953125,-0.953125 z m 2.875,0 c -0.5233662,0 -0.953125,0.429759 -0.953125,0.953125 0,0.523366 0.4297588,0.953125 0.953125,0.953125 C 6.5702412,12.904297 7,12.474538 7,11.951172 7,11.427806 6.5702412,10.998047 6.046875,10.998047 Z m 2.8554688,0 c -0.5233663,0 -0.953125,0.429759 -0.953125,0.953125 0,0.523366 0.4297587,0.953125 0.953125,0.953125 0.5233661,0 0.9531249,-0.429759 0.953125,-0.953125 0,-0.523366 -0.4297588,-0.953125 -0.953125,-0.953125 z m 2.9003902,0 c -0.523366,0 -0.953125,0.429759 -0.953125,0.953125 0,0.523366 0.429759,0.953125 0.953125,0.953125 0.523367,0 0.953125,-0.429759 0.953125,-0.953125 0,-0.523366 -0.429758,-0.953125 -0.953125,-0.953125 z M 3.5,0 c -0.554,0 -1,0.446 -1,1 v 0.050781 C 1.0853217,1.2909766 0,2.5186658 0,4 v 9 c 0,1.652487 1.3475134,3 3,3 h 9 c 1.652487,0 3,-1.347513 3,-3 V 4 C 15,2.5186658 13.914678,1.2909766 12.5,1.0507812 V 1 c 0,-0.554 -0.446,-1 -1,-1 -0.554,0 -1,0.446 -1,1 h -2 c 0,-0.554 -0.446,-1 -1,-1 -0.554,0 -1,0.446 -1,1 h -2 C 4.5,0.446 4.054,0 3.5,0 Z m 1,2.0996094 h 2 v 0.640625 c 0,0.554 0.446,1 1,1 0.554,0 1,-0.446 1,-1 v -0.640625 h 2 v 0.640625 c 0,0.554 0.446,1 1,1 0.554,0 1,-0.446 1,-1 V 2.1738281 C 13.311725,2.3905225 13.900391,3.11278 13.900391,4 v 9 c 0,1.062113 -0.838278,1.900391 -1.900391,1.900391 H 3 C 1.9378864,14.900391 1.0996094,14.062113 1.0996094,13 V 4 C 1.0996094,3.11278 1.6882747,2.3905225 2.5,2.1738281 v 0.5664063 c 0,0.554 0.446,1 1,1 0.554,0 1,-0.446 1,-1 z\"/></svg>')}.btn-open-cal{outline:none;border:none;background-color:unset;cursor:pointer}.btn-open-cal:disabled{cursor:unset}.btn-open-cal::after{content:'';display:flex;background-color:var(--text--primary, #008561);width:15px;height:16px;-webkit-mask-image:var(--ez-date-input__calendar-image);mask-image:var(--ez-date-input__calendar-image)}.btn-open-cal:disabled:after{background-color:var(--text--disable, #AFB6C0)}.btn-open-cal:enabled:hover::after{background-color:var(--color--primary, #4e4e4e)}ez-text-input{--text-input__input--background-color:var(--ez-date-input__input--background-color, #FFFFFF);--text-input__input--border-color:var(--ez-date-input__input--border-color, #DCE0E8)}";
|
|
10
10
|
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-c15a9551.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
|
-
const CSSVarsUtils = require('./CSSVarsUtils-
|
|
7
|
+
const CSSVarsUtils = require('./CSSVarsUtils-09b431cc.js');
|
|
8
8
|
|
|
9
9
|
const ezDateTimeInputCss = ":host{display:block;width:100%;--ez-date-input__input--background-color:var(--background--medium, #e0e0e0);--ez-date-input__input--border-color:var(--ez-date-input__input--background-color);--ez-date-input__calendar-image:url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" version=\"1.1\" height=\"16px\" width=\"15px\"><path d=\"M 3.171875,5.25 C 2.6485088,5.25 2.21875,5.6797588 2.21875,6.203125 2.21875,6.7264912 2.6485088,7.15625 3.171875,7.15625 3.6952412,7.15625 4.125,6.7264912 4.125,6.203125 4.125,5.6797588 3.6952412,5.25 3.171875,5.25 Z m 2.875,0 C 5.5235088,5.25 5.09375,5.6797588 5.09375,6.203125 5.09375,6.7264912 5.5235088,7.15625 6.046875,7.15625 6.5702412,7.15625 7,6.7264912 7,6.203125 7,5.6797588 6.5702412,5.25 6.046875,5.25 Z m 2.875,0 c -0.5233662,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.4297588,0.953125 0.953125,0.953125 0.5233662,0 0.9511719,-0.4297588 0.9511719,-0.953125 C 9.8730469,5.6797588 9.4452412,5.25 8.921875,5.25 Z m 2.873047,0 c -0.523366,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.429759,0.953125 0.953125,0.953125 0.523366,0 0.953125,-0.4297588 0.953125,-0.953125 C 12.748047,5.6797588 12.318288,5.25 11.794922,5.25 Z M 3.171875,8.1230469 c -0.5233662,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.4297588,0.9531251 0.953125,0.9531251 0.5233662,0 0.953125,-0.4297589 0.953125,-0.9531251 0,-0.5233662 -0.4297588,-0.953125 -0.953125,-0.953125 z m 2.875,0 c -0.5233662,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.4297588,0.9531251 0.953125,0.9531251 C 6.5702412,10.029297 7,9.5995381 7,9.0761719 7,8.5528057 6.5702412,8.1230469 6.046875,8.1230469 Z m 2.8554688,0 c -0.5233663,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.4297587,0.9531251 0.953125,0.9531251 0.5233661,0 0.9531249,-0.4297589 0.953125,-0.9531251 0,-0.5233662 -0.4297588,-0.953125 -0.953125,-0.953125 z m 2.9003902,0 c -0.523366,0 -0.953125,0.4297588 -0.953125,0.953125 0,0.5233662 0.429759,0.9531251 0.953125,0.9531251 0.523367,0 0.953125,-0.4297589 0.953125,-0.9531251 0,-0.5233662 -0.429758,-0.953125 -0.953125,-0.953125 z M 3.171875,10.998047 c -0.5233662,0 -0.953125,0.429759 -0.953125,0.953125 0,0.523366 0.4297588,0.953125 0.953125,0.953125 0.5233662,0 0.953125,-0.429759 0.953125,-0.953125 0,-0.523366 -0.4297588,-0.953125 -0.953125,-0.953125 z m 2.875,0 c -0.5233662,0 -0.953125,0.429759 -0.953125,0.953125 0,0.523366 0.4297588,0.953125 0.953125,0.953125 C 6.5702412,12.904297 7,12.474538 7,11.951172 7,11.427806 6.5702412,10.998047 6.046875,10.998047 Z m 2.8554688,0 c -0.5233663,0 -0.953125,0.429759 -0.953125,0.953125 0,0.523366 0.4297587,0.953125 0.953125,0.953125 0.5233661,0 0.9531249,-0.429759 0.953125,-0.953125 0,-0.523366 -0.4297588,-0.953125 -0.953125,-0.953125 z m 2.9003902,0 c -0.523366,0 -0.953125,0.429759 -0.953125,0.953125 0,0.523366 0.429759,0.953125 0.953125,0.953125 0.523367,0 0.953125,-0.429759 0.953125,-0.953125 0,-0.523366 -0.429758,-0.953125 -0.953125,-0.953125 z M 3.5,0 c -0.554,0 -1,0.446 -1,1 v 0.050781 C 1.0853217,1.2909766 0,2.5186658 0,4 v 9 c 0,1.652487 1.3475134,3 3,3 h 9 c 1.652487,0 3,-1.347513 3,-3 V 4 C 15,2.5186658 13.914678,1.2909766 12.5,1.0507812 V 1 c 0,-0.554 -0.446,-1 -1,-1 -0.554,0 -1,0.446 -1,1 h -2 c 0,-0.554 -0.446,-1 -1,-1 -0.554,0 -1,0.446 -1,1 h -2 C 4.5,0.446 4.054,0 3.5,0 Z m 1,2.0996094 h 2 v 0.640625 c 0,0.554 0.446,1 1,1 0.554,0 1,-0.446 1,-1 v -0.640625 h 2 v 0.640625 c 0,0.554 0.446,1 1,1 0.554,0 1,-0.446 1,-1 V 2.1738281 C 13.311725,2.3905225 13.900391,3.11278 13.900391,4 v 9 c 0,1.062113 -0.838278,1.900391 -1.900391,1.900391 H 3 C 1.9378864,14.900391 1.0996094,14.062113 1.0996094,13 V 4 C 1.0996094,3.11278 1.6882747,2.3905225 2.5,2.1738281 v 0.5664063 c 0,0.554 0.446,1 1,1 0.554,0 1,-0.446 1,-1 z\"/></svg>')}.btn-open-cal{outline:none;border:none;background-color:unset;cursor:pointer}.btn-open-cal:disabled{cursor:unset}.btn-open-cal::after{content:'';display:flex;background-color:var(--text--primary, #008561);width:15px;height:16px;-webkit-mask-image:var(--ez-date-input__calendar-image);mask-image:var(--ez-date-input__calendar-image)}.btn-open-cal:disabled:after{background-color:var(--text--disable, #AFB6C0)}.btn-open-cal:enabled:hover::after{background-color:var(--color--primary, #4e4e4e)}ez-text-input{--text-input__input--background-color:var(--ez-date-input__input--background-color, #FFFFFF);--text-input__input--border-color:var(--ez-date-input__input--border-color, #DCE0E8)}";
|
|
10
10
|
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-c15a9551.js');
|
|
6
|
-
const CSSVarsUtils = require('./CSSVarsUtils-
|
|
6
|
+
const CSSVarsUtils = require('./CSSVarsUtils-09b431cc.js');
|
|
7
7
|
|
|
8
8
|
const ezFilterInputCss = ":host{display:block;width:100%}";
|
|
9
9
|
|
|
@@ -114611,6 +114611,7 @@ class DataSource {
|
|
|
114611
114611
|
case core.Action.DATA_SAVED:
|
|
114612
114612
|
case core.Action.EDITION_CANCELED:
|
|
114613
114613
|
case core.Action.DATA_CHANGED:
|
|
114614
|
+
this._controller.refresh();
|
|
114614
114615
|
break;
|
|
114615
114616
|
case core.Action.SELECTION_CHANGED:
|
|
114616
114617
|
case core.Action.NEXT_SELECTED:
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-c15a9551.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
|
-
const CSSVarsUtils = require('./CSSVarsUtils-
|
|
7
|
+
const CSSVarsUtils = require('./CSSVarsUtils-09b431cc.js');
|
|
8
8
|
|
|
9
9
|
const ezNumberInputCss = ":host{display:block;width:100%}";
|
|
10
10
|
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-c15a9551.js');
|
|
6
|
-
const CSSVarsUtils = require('./CSSVarsUtils-
|
|
6
|
+
const CSSVarsUtils = require('./CSSVarsUtils-09b431cc.js');
|
|
7
7
|
|
|
8
8
|
const ezSearchCss = ":host{width:100%}";
|
|
9
9
|
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-c15a9551.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
|
-
const CSSVarsUtils = require('./CSSVarsUtils-
|
|
7
|
+
const CSSVarsUtils = require('./CSSVarsUtils-09b431cc.js');
|
|
8
8
|
|
|
9
9
|
const ezTimeInputCss = ":host{display:flex;flex-wrap:wrap;position:relative;width:100%}";
|
|
10
10
|
|
package/dist/cjs/ezui.cjs.js
CHANGED
|
@@ -15,5 +15,5 @@ const patchBrowser = () => {
|
|
|
15
15
|
};
|
|
16
16
|
|
|
17
17
|
patchBrowser().then(options => {
|
|
18
|
-
return index.bootstrapLazy([["ez-
|
|
18
|
+
return index.bootstrapLazy([["ez-grid.cjs",[[6,"ez-grid",{"multipleSelection":[4,"multiple-selection"],"config":[1040],"serverUrl":[1,"server-url"],"dataUnit":[16],"_paginationInfo":[32],"_popUpGridConfig":[32],"setColumnsDef":[64],"addColumnMenuItem":[64],"setColumnsState":[64],"setData":[64],"getSelection":[64],"getColumnsState":[64],"getColumns":[64],"quickFilter":[64],"openGridConfig":[64]}]]],["ez-actions-button.cjs",[[1,"ez-actions-button",{"enabled":[516],"actions":[1040],"size":[513]}]]],["ez-dialog.cjs",[[1,"ez-dialog",{"confirm":[1028],"critical":[1028],"message":[1025],"opened":[1540],"personalizedIconPath":[1025,"personalized-icon-path"],"ezTitle":[1025,"ez-title"],"handleButtonClick":[64],"show":[64]}]]],["ez-filter-input.cjs",[[1,"ez-filter-input",{"label":[1],"value":[1537],"enabled":[4],"loading":[516],"errorMessage":[1537,"error-message"],"restrict":[1],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-chip.cjs",[[1,"ez-chip",{"label":[513],"enabled":[516],"removePosition":[513,"remove-position"],"mode":[513],"value":[1540],"setFocus":[64],"setBlur":[64]}]]],["ez-application.cjs",[[0,"ez-application"]]],["ez-card-item.cjs",[[1,"ez-card-item",{"item":[16]}]]],["ez-loading-bar.cjs",[[1,"ez-loading-bar",{"_showLoading":[32],"hide":[64],"show":[64]}]]],["ez-popover.cjs",[[1,"ez-popover",{"autoClose":[516,"auto-close"],"top":[1537],"left":[1537],"bottom":[1537],"right":[1537],"boxWidth":[513,"box-width"],"opened":[1540],"innerElement":[1537,"inner-element"],"updatePosition":[64],"show":[64],"hide":[64]}]]],["ez-popup.cjs",[[1,"ez-popup",{"size":[1],"opened":[1540],"useHeader":[1540,"use-header"],"ezTitle":[1,"ez-title"]}]]],["ez-toast.cjs",[[1,"ez-toast",{"message":[1025],"fadeTime":[1026,"fade-time"],"useIcon":[1028,"use-icon"],"canClose":[1028,"can-close"],"show":[64]}]]],["ez-view-stack.cjs",[[0,"ez-view-stack",{"show":[64],"getSelectedIndex":[64]}]]],["grid-config.cjs",[[2,"grid-config",{"selectedTab":[1025,"selected-tab"],"columns":[1040],"config":[1040]}]]],["ez-search.cjs",[[1,"ez-search",{"value":[1537],"label":[1537],"enabled":[1540],"errorMessage":[1537,"error-message"],"optionLoader":[16],"showSelectedValue":[4,"show-selected-value"],"showOptionValue":[4,"show-option-value"],"suppressEmptyOption":[4,"suppress-empty-option"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-date-input.cjs",[[1,"ez-date-input",{"label":[513],"value":[1040],"enabled":[516],"errorMessage":[1537,"error-message"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-time-input.cjs",[[1,"ez-time-input",{"label":[513],"viewValue":[1537,"view-value"],"value":[1026],"enabled":[516],"errorMessage":[1537,"error-message"],"showSeconds":[516,"show-seconds"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-collapsible-box.cjs",[[1,"ez-collapsible-box",{"value":[1540],"label":[513],"headerSize":[513,"header-size"],"iconPlacement":[513,"icon-placement"],"stretchTitle":[516,"stretch-title"],"showHide":[64]}]]],["ez-number-input.cjs",[[1,"ez-number-input",{"label":[1],"value":[1538],"enabled":[4],"errorMessage":[1537,"error-message"],"precision":[2],"prettyPrecision":[2,"pretty-precision"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-modal.cjs",[[1,"ez-modal",{"modalSize":[1,"modal-size"],"align":[1],"opened":[1028],"closeEsc":[4,"close-esc"],"closeOutsideClick":[4,"close-outside-click"]}]]],["ez-list.cjs",[[1,"ez-list",{"dataSource":[1040],"useGroups":[1540,"use-groups"],"ezDraggable":[1028,"ez-draggable"],"ezSelectable":[1028,"ez-selectable"],"itemSlotBuilder":[1040],"_listItems":[32],"_listGroupItems":[32],"clearHistory":[64],"scrollToTop":[64],"setSelection":[64],"getSelection":[64],"getList":[64]}]]],["ez-calendar.cjs",[[1,"ez-calendar",{"value":[1040],"floating":[516],"time":[516],"showSeconds":[516,"show-seconds"],"show":[64],"fitVertical":[64],"hide":[64]}]]],["ez-date-time-input.cjs",[[1,"ez-date-time-input",{"label":[513],"value":[1040],"enabled":[516],"errorMessage":[1537,"error-message"],"showSeconds":[516,"show-seconds"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-text-area.cjs",[[1,"ez-text-area",{"label":[513],"value":[1537],"enabled":[516],"loading":[516],"errorMessage":[1537,"error-message"],"rows":[1538],"canShowError":[516,"can-show-error"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-upload.cjs",[[1,"ez-upload",{"label":[1],"enabled":[4],"maxFileSize":[2,"max-file-size"],"maxFiles":[2,"max-files"],"requestHeaders":[8,"request-headers"],"urlUpload":[1,"url-upload"],"urlDelete":[1,"url-delete"],"value":[1040],"addFiles":[64],"setFocus":[64],"setBlur":[64]}]]],["ez-check.cjs",[[1,"ez-check",{"label":[513],"value":[1540],"enabled":[1540],"mode":[513],"getMode":[64],"setFocus":[64]}]]],["ez-tabselector.cjs",[[1,"ez-tabselector",{"selectedIndex":[1538,"selected-index"],"selectedTab":[1537,"selected-tab"],"tabs":[1]}]]],["ez-icon.cjs",[[1,"ez-icon",{"size":[513],"href":[513],"iconName":[513,"icon-name"]}]]],["ez-form.cjs",[[0,"ez-form",{"dataUnit":[1040],"config":[16],"submit":[64],"cancel":[64],"validate":[64]}]]],["ez-button.cjs",[[1,"ez-button",{"label":[513],"enabled":[516],"mode":[513],"image":[513],"iconName":[513,"icon-name"],"size":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-text-input.cjs",[[1,"ez-text-input",{"label":[513],"value":[1537],"enabled":[516],"loading":[516],"errorMessage":[1537,"error-message"],"mask":[1],"canShowError":[516,"can-show-error"],"restrict":[1],"mode":[513],"slaveMode":[516,"slave-mode"],"setFocus":[64],"setBlur":[64]}]]],["ez-combo-box.cjs",[[1,"ez-combo-box",{"value":[1537],"label":[513],"enabled":[516],"options":[1040],"errorMessage":[1537,"error-message"],"searchMode":[4,"search-mode"],"showSelectedValue":[4,"show-selected-value"],"showOptionValue":[4,"show-option-value"],"suppressSearch":[4,"suppress-search"],"optionLoader":[16],"suppressEmptyOption":[4,"suppress-empty-option"],"canShowError":[516,"can-show-error"],"mode":[513],"_preSelection":[32],"_visibleOptions":[32],"_startLoading":[32],"_showLoading":[32],"setFocus":[64],"setBlur":[64]}]]],["select-box.cjs",[[1,"select-box",{"selectedOption":[1,"selected-option"]}]]]], options);
|
|
19
19
|
});
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -14,7 +14,7 @@ const patchEsm = () => {
|
|
|
14
14
|
const defineCustomElements = (win, options) => {
|
|
15
15
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
16
16
|
return patchEsm().then(() => {
|
|
17
|
-
return index.bootstrapLazy([["ez-
|
|
17
|
+
return index.bootstrapLazy([["ez-grid.cjs",[[6,"ez-grid",{"multipleSelection":[4,"multiple-selection"],"config":[1040],"serverUrl":[1,"server-url"],"dataUnit":[16],"_paginationInfo":[32],"_popUpGridConfig":[32],"setColumnsDef":[64],"addColumnMenuItem":[64],"setColumnsState":[64],"setData":[64],"getSelection":[64],"getColumnsState":[64],"getColumns":[64],"quickFilter":[64],"openGridConfig":[64]}]]],["ez-actions-button.cjs",[[1,"ez-actions-button",{"enabled":[516],"actions":[1040],"size":[513]}]]],["ez-dialog.cjs",[[1,"ez-dialog",{"confirm":[1028],"critical":[1028],"message":[1025],"opened":[1540],"personalizedIconPath":[1025,"personalized-icon-path"],"ezTitle":[1025,"ez-title"],"handleButtonClick":[64],"show":[64]}]]],["ez-filter-input.cjs",[[1,"ez-filter-input",{"label":[1],"value":[1537],"enabled":[4],"loading":[516],"errorMessage":[1537,"error-message"],"restrict":[1],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-chip.cjs",[[1,"ez-chip",{"label":[513],"enabled":[516],"removePosition":[513,"remove-position"],"mode":[513],"value":[1540],"setFocus":[64],"setBlur":[64]}]]],["ez-application.cjs",[[0,"ez-application"]]],["ez-card-item.cjs",[[1,"ez-card-item",{"item":[16]}]]],["ez-loading-bar.cjs",[[1,"ez-loading-bar",{"_showLoading":[32],"hide":[64],"show":[64]}]]],["ez-popover.cjs",[[1,"ez-popover",{"autoClose":[516,"auto-close"],"top":[1537],"left":[1537],"bottom":[1537],"right":[1537],"boxWidth":[513,"box-width"],"opened":[1540],"innerElement":[1537,"inner-element"],"updatePosition":[64],"show":[64],"hide":[64]}]]],["ez-popup.cjs",[[1,"ez-popup",{"size":[1],"opened":[1540],"useHeader":[1540,"use-header"],"ezTitle":[1,"ez-title"]}]]],["ez-toast.cjs",[[1,"ez-toast",{"message":[1025],"fadeTime":[1026,"fade-time"],"useIcon":[1028,"use-icon"],"canClose":[1028,"can-close"],"show":[64]}]]],["ez-view-stack.cjs",[[0,"ez-view-stack",{"show":[64],"getSelectedIndex":[64]}]]],["grid-config.cjs",[[2,"grid-config",{"selectedTab":[1025,"selected-tab"],"columns":[1040],"config":[1040]}]]],["ez-search.cjs",[[1,"ez-search",{"value":[1537],"label":[1537],"enabled":[1540],"errorMessage":[1537,"error-message"],"optionLoader":[16],"showSelectedValue":[4,"show-selected-value"],"showOptionValue":[4,"show-option-value"],"suppressEmptyOption":[4,"suppress-empty-option"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-date-input.cjs",[[1,"ez-date-input",{"label":[513],"value":[1040],"enabled":[516],"errorMessage":[1537,"error-message"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-time-input.cjs",[[1,"ez-time-input",{"label":[513],"viewValue":[1537,"view-value"],"value":[1026],"enabled":[516],"errorMessage":[1537,"error-message"],"showSeconds":[516,"show-seconds"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-collapsible-box.cjs",[[1,"ez-collapsible-box",{"value":[1540],"label":[513],"headerSize":[513,"header-size"],"iconPlacement":[513,"icon-placement"],"stretchTitle":[516,"stretch-title"],"showHide":[64]}]]],["ez-number-input.cjs",[[1,"ez-number-input",{"label":[1],"value":[1538],"enabled":[4],"errorMessage":[1537,"error-message"],"precision":[2],"prettyPrecision":[2,"pretty-precision"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-modal.cjs",[[1,"ez-modal",{"modalSize":[1,"modal-size"],"align":[1],"opened":[1028],"closeEsc":[4,"close-esc"],"closeOutsideClick":[4,"close-outside-click"]}]]],["ez-list.cjs",[[1,"ez-list",{"dataSource":[1040],"useGroups":[1540,"use-groups"],"ezDraggable":[1028,"ez-draggable"],"ezSelectable":[1028,"ez-selectable"],"itemSlotBuilder":[1040],"_listItems":[32],"_listGroupItems":[32],"clearHistory":[64],"scrollToTop":[64],"setSelection":[64],"getSelection":[64],"getList":[64]}]]],["ez-calendar.cjs",[[1,"ez-calendar",{"value":[1040],"floating":[516],"time":[516],"showSeconds":[516,"show-seconds"],"show":[64],"fitVertical":[64],"hide":[64]}]]],["ez-date-time-input.cjs",[[1,"ez-date-time-input",{"label":[513],"value":[1040],"enabled":[516],"errorMessage":[1537,"error-message"],"showSeconds":[516,"show-seconds"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-text-area.cjs",[[1,"ez-text-area",{"label":[513],"value":[1537],"enabled":[516],"loading":[516],"errorMessage":[1537,"error-message"],"rows":[1538],"canShowError":[516,"can-show-error"],"mode":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-upload.cjs",[[1,"ez-upload",{"label":[1],"enabled":[4],"maxFileSize":[2,"max-file-size"],"maxFiles":[2,"max-files"],"requestHeaders":[8,"request-headers"],"urlUpload":[1,"url-upload"],"urlDelete":[1,"url-delete"],"value":[1040],"addFiles":[64],"setFocus":[64],"setBlur":[64]}]]],["ez-check.cjs",[[1,"ez-check",{"label":[513],"value":[1540],"enabled":[1540],"mode":[513],"getMode":[64],"setFocus":[64]}]]],["ez-tabselector.cjs",[[1,"ez-tabselector",{"selectedIndex":[1538,"selected-index"],"selectedTab":[1537,"selected-tab"],"tabs":[1]}]]],["ez-icon.cjs",[[1,"ez-icon",{"size":[513],"href":[513],"iconName":[513,"icon-name"]}]]],["ez-form.cjs",[[0,"ez-form",{"dataUnit":[1040],"config":[16],"submit":[64],"cancel":[64],"validate":[64]}]]],["ez-button.cjs",[[1,"ez-button",{"label":[513],"enabled":[516],"mode":[513],"image":[513],"iconName":[513,"icon-name"],"size":[513],"setFocus":[64],"setBlur":[64]}]]],["ez-text-input.cjs",[[1,"ez-text-input",{"label":[513],"value":[1537],"enabled":[516],"loading":[516],"errorMessage":[1537,"error-message"],"mask":[1],"canShowError":[516,"can-show-error"],"restrict":[1],"mode":[513],"slaveMode":[516,"slave-mode"],"setFocus":[64],"setBlur":[64]}]]],["ez-combo-box.cjs",[[1,"ez-combo-box",{"value":[1537],"label":[513],"enabled":[516],"options":[1040],"errorMessage":[1537,"error-message"],"searchMode":[4,"search-mode"],"showSelectedValue":[4,"show-selected-value"],"showOptionValue":[4,"show-option-value"],"suppressSearch":[4,"suppress-search"],"optionLoader":[16],"suppressEmptyOption":[4,"suppress-empty-option"],"canShowError":[516,"can-show-error"],"mode":[513],"_preSelection":[32],"_visibleOptions":[32],"_startLoading":[32],"_showLoading":[32],"setFocus":[64],"setBlur":[64]}]]],["select-box.cjs",[[1,"select-box",{"selectedOption":[1,"selected-option"]}]]]], options);
|
|
18
18
|
});
|
|
19
19
|
};
|
|
20
20
|
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"./components/ez-form/ez-form.js",
|
|
7
7
|
"./components/ez-list/ez-list.js",
|
|
8
8
|
"./components/ez-upload/ez-upload.js",
|
|
9
|
+
"./components/ez-actions-button/ez-actions-button.js",
|
|
9
10
|
"./components/ez-application/ez-application.js",
|
|
10
11
|
"./components/ez-button/ez-button.js",
|
|
11
12
|
"./components/ez-calendar/ez-calendar.js",
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
:host {
|
|
2
|
+
/* box */
|
|
3
|
+
/*@doc Define o raio da borda do popover.*/
|
|
4
|
+
--ez-actions-button__box--border-radius: var(--border--radius-medium, 12px);
|
|
5
|
+
/*@doc Define a sombra do popover.*/
|
|
6
|
+
--ez-actions-button__box--box-shadow: var(--shadow, 0px 0px 16px 0px #000);
|
|
7
|
+
/*@doc Define a cor de fundo do popover.*/
|
|
8
|
+
--ez-actions-button__box--background-color: var(--background--xlight, #fff);
|
|
9
|
+
/*@doc Define o espaçamento interno do popover*/
|
|
10
|
+
--ez-actions-button__box--padding: var(--space-small, 6px);
|
|
11
|
+
/*@doc Define a distancia entre o botão e o popover*/
|
|
12
|
+
--ez-actions-button__box--top-margin: var(--space-extra-small, 3px);
|
|
13
|
+
|
|
14
|
+
/* action */
|
|
15
|
+
--ez-actions-button__action--min-width: 400px;
|
|
16
|
+
--ez-actions-button__action--background-color: var(--background--xlight, #fff);
|
|
17
|
+
|
|
18
|
+
/***************
|
|
19
|
+
host style
|
|
20
|
+
***************/
|
|
21
|
+
/*private*/
|
|
22
|
+
display: flex;
|
|
23
|
+
flex-direction: column;
|
|
24
|
+
height: fit-content;
|
|
25
|
+
user-select: none;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.actions-list {
|
|
29
|
+
/*private*/
|
|
30
|
+
display: flex;
|
|
31
|
+
flex-direction: column;
|
|
32
|
+
position: absolute;
|
|
33
|
+
width: fit-content;
|
|
34
|
+
height: fit-content;
|
|
35
|
+
|
|
36
|
+
/*public*/
|
|
37
|
+
z-index: var(--more-visible, 1);
|
|
38
|
+
padding: var(--ez-actions-button__box--padding);
|
|
39
|
+
margin-top: var(--ez-actions-button__box--top-margin);
|
|
40
|
+
background-color: var(--ez-actions-button__box--background-color);
|
|
41
|
+
border-radius: var(--ez-actions-button__box--border-radius);
|
|
42
|
+
box-shadow: var(--ez-actions-button__box--box-shadow);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.btn-action {
|
|
46
|
+
/*private*/
|
|
47
|
+
--ez-button--min-width: var(--ez-actions-button__action--min-width);
|
|
48
|
+
--ez-button--background-color: var(--ez-actions-button__action--background-color);
|
|
49
|
+
}
|
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
import { FloatingManager } from '@sankhyalabs/core';
|
|
2
|
+
import { Component, Element, Event, h, Host, Prop } from '@stencil/core';
|
|
3
|
+
import { CSSVarsUtils } from '../../utils';
|
|
4
|
+
export class EzActionsButton {
|
|
5
|
+
constructor() {
|
|
6
|
+
/**
|
|
7
|
+
* Deixa o campo disponível ou não para interação com usuário.
|
|
8
|
+
*/
|
|
9
|
+
this.enabled = true;
|
|
10
|
+
this.innerClickTest = (floatingContainer, node) => {
|
|
11
|
+
if (node && floatingContainer) {
|
|
12
|
+
const children = floatingContainer.children;
|
|
13
|
+
for (let i = 0; i < children.length; i++) {
|
|
14
|
+
if (children[i].shadowRoot.contains(node)) {
|
|
15
|
+
return true;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
return false;
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
showActions() {
|
|
23
|
+
if (!this.enabled) {
|
|
24
|
+
return;
|
|
25
|
+
}
|
|
26
|
+
this._floatingID = FloatingManager.float(this._actionsList, this._listContainer, { autoClose: true, innerClickTest: this.innerClickTest });
|
|
27
|
+
const docWidth = window.innerWidth || document.documentElement.clientWidth;
|
|
28
|
+
const bounding = this._actionsList.getBoundingClientRect();
|
|
29
|
+
if (bounding.right > docWidth) {
|
|
30
|
+
FloatingManager.updateFloatPosition(this._actionsList, this._listContainer, { autoClose: true, innerClickTest: this.innerClickTest, left: (docWidth - bounding.width) + "px" });
|
|
31
|
+
}
|
|
32
|
+
window.requestAnimationFrame(() => {
|
|
33
|
+
this._actionsList.scrollIntoView({ behavior: "smooth", block: "nearest", inline: "nearest" });
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
hideActions() {
|
|
37
|
+
if (this._floatingID !== undefined) {
|
|
38
|
+
FloatingManager.close(this._floatingID);
|
|
39
|
+
}
|
|
40
|
+
this._floatingID = undefined;
|
|
41
|
+
}
|
|
42
|
+
//---------------------------------------------
|
|
43
|
+
// Event handlers
|
|
44
|
+
//---------------------------------------------
|
|
45
|
+
handlerButtonClick() {
|
|
46
|
+
this.showActions();
|
|
47
|
+
}
|
|
48
|
+
actionClick(action) {
|
|
49
|
+
this.hideActions();
|
|
50
|
+
this.ezAction.emit(action);
|
|
51
|
+
}
|
|
52
|
+
//---------------------------------------------
|
|
53
|
+
// Lifecycle web component
|
|
54
|
+
//---------------------------------------------
|
|
55
|
+
componentWillLoad() {
|
|
56
|
+
if (this.actions === undefined) {
|
|
57
|
+
this.actions = [];
|
|
58
|
+
const optionsTags = this._element.querySelectorAll("action");
|
|
59
|
+
if (optionsTags) {
|
|
60
|
+
optionsTags.forEach((e) => {
|
|
61
|
+
let label = e.innerText;
|
|
62
|
+
let value = e.getAttribute("value");
|
|
63
|
+
if (!value) {
|
|
64
|
+
value = label;
|
|
65
|
+
}
|
|
66
|
+
this.actions.push({ label, value });
|
|
67
|
+
e.hidden = true;
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
componentDidLoad() {
|
|
73
|
+
CSSVarsUtils.applyVarsButton(this._element, this._button);
|
|
74
|
+
}
|
|
75
|
+
componentDidRender() {
|
|
76
|
+
if (this._floatingID === undefined) {
|
|
77
|
+
this._actionsList.remove();
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
render() {
|
|
81
|
+
return (h(Host, null,
|
|
82
|
+
h("ez-button", { ref: elem => this._button = elem, enabled: this.enabled, mode: "icon", iconName: "dots-vertical", size: this.size, onClick: () => this.handlerButtonClick() }),
|
|
83
|
+
h("section", { class: "list-container", ref: elem => this._listContainer = elem },
|
|
84
|
+
h("div", { class: "actions-list", ref: elem => this._actionsList = elem }, this.actions.map(action => h("ez-button", { class: "btn-action", size: "small", label: action.label, onClick: () => this.actionClick(action) }))))));
|
|
85
|
+
}
|
|
86
|
+
static get is() { return "ez-actions-button"; }
|
|
87
|
+
static get encapsulation() { return "shadow"; }
|
|
88
|
+
static get originalStyleUrls() { return {
|
|
89
|
+
"$": ["ez-actions-button.css"]
|
|
90
|
+
}; }
|
|
91
|
+
static get styleUrls() { return {
|
|
92
|
+
"$": ["ez-actions-button.css"]
|
|
93
|
+
}; }
|
|
94
|
+
static get properties() { return {
|
|
95
|
+
"enabled": {
|
|
96
|
+
"type": "boolean",
|
|
97
|
+
"mutable": false,
|
|
98
|
+
"complexType": {
|
|
99
|
+
"original": "boolean",
|
|
100
|
+
"resolved": "boolean",
|
|
101
|
+
"references": {}
|
|
102
|
+
},
|
|
103
|
+
"required": false,
|
|
104
|
+
"optional": false,
|
|
105
|
+
"docs": {
|
|
106
|
+
"tags": [],
|
|
107
|
+
"text": "Deixa o campo dispon\u00EDvel ou n\u00E3o para intera\u00E7\u00E3o com usu\u00E1rio."
|
|
108
|
+
},
|
|
109
|
+
"attribute": "enabled",
|
|
110
|
+
"reflect": true,
|
|
111
|
+
"defaultValue": "true"
|
|
112
|
+
},
|
|
113
|
+
"actions": {
|
|
114
|
+
"type": "unknown",
|
|
115
|
+
"mutable": true,
|
|
116
|
+
"complexType": {
|
|
117
|
+
"original": "Array<Action>",
|
|
118
|
+
"resolved": "Action[]",
|
|
119
|
+
"references": {
|
|
120
|
+
"Array": {
|
|
121
|
+
"location": "global"
|
|
122
|
+
},
|
|
123
|
+
"Action": {
|
|
124
|
+
"location": "local"
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
},
|
|
128
|
+
"required": false,
|
|
129
|
+
"optional": false,
|
|
130
|
+
"docs": {
|
|
131
|
+
"tags": [],
|
|
132
|
+
"text": "Array no formato \"{value: string, label: string}\" que alimenta a lista de a\u00E7\u00F5es"
|
|
133
|
+
}
|
|
134
|
+
},
|
|
135
|
+
"size": {
|
|
136
|
+
"type": "string",
|
|
137
|
+
"mutable": false,
|
|
138
|
+
"complexType": {
|
|
139
|
+
"original": "\"small\" | \"medium\" | \"large\" | undefined",
|
|
140
|
+
"resolved": "\"large\" | \"medium\" | \"small\"",
|
|
141
|
+
"references": {}
|
|
142
|
+
},
|
|
143
|
+
"required": false,
|
|
144
|
+
"optional": false,
|
|
145
|
+
"docs": {
|
|
146
|
+
"tags": [],
|
|
147
|
+
"text": "\u00C9 poss\u00EDvel escolher entre [small,medium,large]"
|
|
148
|
+
},
|
|
149
|
+
"attribute": "size",
|
|
150
|
+
"reflect": true
|
|
151
|
+
}
|
|
152
|
+
}; }
|
|
153
|
+
static get events() { return [{
|
|
154
|
+
"method": "ezAction",
|
|
155
|
+
"name": "ezAction",
|
|
156
|
+
"bubbles": true,
|
|
157
|
+
"cancelable": true,
|
|
158
|
+
"composed": true,
|
|
159
|
+
"docs": {
|
|
160
|
+
"tags": [],
|
|
161
|
+
"text": "Evento que \u00E9 disparado ao acionar uma a\u00E7\u00E3o"
|
|
162
|
+
},
|
|
163
|
+
"complexType": {
|
|
164
|
+
"original": "Action",
|
|
165
|
+
"resolved": "Action",
|
|
166
|
+
"references": {
|
|
167
|
+
"Action": {
|
|
168
|
+
"location": "local"
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
}]; }
|
|
173
|
+
static get elementRef() { return "_element"; }
|
|
174
|
+
}
|