@sankhyalabs/ezui 1.1.14 → 1.1.18
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-action-chip.cjs.entry.js +1 -1
- package/dist/cjs/ez-button_14.cjs.entry.js +17 -16
- package/dist/cjs/ez-label-chip.cjs.entry.js +1 -1
- package/dist/cjs/ez-modal.cjs.entry.js +12 -12
- package/dist/cjs/ez-number-input.cjs.entry.js +3 -1
- package/dist/cjs/ez-time-input.cjs.entry.js +1 -1
- package/dist/cjs/ezui.cjs.js +2 -2
- package/dist/cjs/form-metadata.cjs.entry.js +1 -1
- package/dist/cjs/{index-9403fe8f.js → index-b0ab12a1.js} +73 -21
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/ez-modal/ez-modal.css +216 -6
- package/dist/collection/components/ez-modal/ez-modal.js +12 -12
- package/dist/collection/components/ez-number-input/ez-number-input.js +18 -1
- package/dist/collection/components/ez-search/ez-search.js +28 -14
- package/dist/collection/components/ez-text-area/ez-text-area.js +1 -0
- package/dist/collection/components/ez-text-input/ez-text-input.css +2 -0
- package/dist/custom-elements/index.js +29 -26
- package/dist/esm/ez-action-chip.entry.js +1 -1
- package/dist/esm/ez-button_14.entry.js +17 -16
- package/dist/esm/ez-label-chip.entry.js +1 -1
- package/dist/esm/ez-modal.entry.js +12 -12
- package/dist/esm/ez-number-input.entry.js +3 -1
- package/dist/esm/ez-time-input.entry.js +1 -1
- package/dist/esm/ezui.js +2 -2
- package/dist/esm/form-metadata.entry.js +1 -1
- package/dist/esm/{index-95bb3fd9.js → index-93e65e82.js} +73 -21
- package/dist/esm/loader.js +2 -2
- package/dist/ezui/ezui.esm.js +1 -1
- package/dist/ezui/{p-172bb08b.entry.js → p-0635823b.entry.js} +1 -1
- package/dist/ezui/p-0e84340a.entry.js +1 -0
- package/dist/ezui/{p-fa260f22.entry.js → p-104e9734.entry.js} +1 -1
- package/dist/ezui/p-2712c0fb.entry.js +1 -0
- package/dist/ezui/{p-22b82efb.entry.js → p-95d21a40.entry.js} +1 -1
- package/dist/ezui/{p-dd4331b7.entry.js → p-9f167da7.entry.js} +1 -1
- package/dist/ezui/p-c3ca8f26.js +1 -0
- package/dist/ezui/{p-61829528.entry.js → p-fcbd6b80.entry.js} +1 -1
- package/dist/types/components/ez-modal/ez-modal.d.ts +0 -1
- package/dist/types/components/ez-number-input/ez-number-input.d.ts +5 -0
- package/dist/types/components/ez-search/ez-search.d.ts +5 -0
- package/dist/types/components.d.ts +5 -0
- package/dist/types/stencil-public-runtime.d.ts +183 -182
- package/package.json +1 -1
- package/dist/ezui/p-185c57f4.js +0 -1
- package/dist/ezui/p-77fdb4fd.entry.js +0 -1
- package/dist/ezui/p-f6fd31ab.entry.js +0 -1
|
@@ -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-b0ab12a1.js');
|
|
6
6
|
|
|
7
7
|
const ezActionChipCss = ":host{--ac--height:36px;--ac--width:100%;--ac__icon--width:48px;--ac--border-radius:var(--border--radius-large, 24px);--ac--font-size:var(--text--medium, 14px);--ac--font-family:var(--font-pattern, Arial);--ac--font-weight:var(--text-weight--large, 500);--ac--space--medium:var(--space--medium, 6px);--ac__border:1px solid;--ac__border-color-strokes:var(--color--strokes, #DCE0E8);--ac__label--title--primary:var(--title--primary, #919191);--ac__label--color-primary:var(--color--primary, #008561);--ac__label-color--disable-secondary:var(--color--disable-secondary, #F2F5F8);--ac__label--background-color:#0085610F;--ac__label__default--background-color--hover:var(--color--primary-200, #f2faf8);--ac__label__default--border-color--hover:var(--color--primary-600, #007a5a);--ac__label--text--disabled:var(--text--disable, #AFB6C0);--ac__label--text--primary:var(--text--primary, #626e82);--ac__message_box--font-size:var(--text--small, 12px);--ac__message_box--info--color:var(--color--success, #22085d);--ac__message_box--error--color:var(--color--error, #FF0000);width:100%}.padding-right--small{padding-right:var(--ac--space--medium)}.padding-left--small{padding-left:var(--ac--space--medium)}.label__container{width:fit-content;display:flex;flex-wrap:wrap;position:relative;align-items:center;align-self:center;color:var(--ac__label--title--primary);fill:var(--ac__label--title--primary);border:var(--ac__border);border-radius:var(--ac--border-radius);border-color:var( --ac__border-color-strokes);padding-right:var(--space--large, 12px);padding-left:var(--space--large, 12px);cursor:pointer}.label__container:hover{border-color:var(--ac__label__default--border-color--hover);background-color:var(--ac__label__default--background-color--hover)}.label__container--active:hover{border-color:var(--ac__label__active--background-color--hover);background-color:var(--ac__label__active--background-color--hover)}label{display:flex;align-items:center;width:calc(100% - var(--ac__icon--width));width:fit-content;font-weight:var(--text-weight--large, 600);cursor:pointer;height:var(--ac--height);font-family:var(--ac--font-family);font-size:var(--ac--font-size)}";
|
|
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-b0ab12a1.js');
|
|
6
6
|
const RequestMetadata = require('./RequestMetadata-2cd01e8a.js');
|
|
7
7
|
const DataUnit = require('./DataUnit-c7a3b17b.js');
|
|
8
8
|
|
|
@@ -2501,6 +2501,7 @@ const EzSearch = class {
|
|
|
2501
2501
|
constructor(hostRef) {
|
|
2502
2502
|
index.registerInstance(this, hostRef);
|
|
2503
2503
|
this.ezChange = index.createEvent(this, "ezChange", 7);
|
|
2504
|
+
this.showPopup = index.createEvent(this, "showPopup", 7);
|
|
2504
2505
|
this._options = [];
|
|
2505
2506
|
this._classSelect = 'list-container--4row';
|
|
2506
2507
|
/**
|
|
@@ -2746,28 +2747,27 @@ const EzSearch = class {
|
|
|
2746
2747
|
let key = this.buildId();
|
|
2747
2748
|
this.saveStorageItem(key, this._inputElem.value);
|
|
2748
2749
|
/* load data */
|
|
2749
|
-
|
|
2750
|
-
this._loadDataFunction(this._inputElem.value, (serverData) => { this.populateOptions(serverData); });
|
|
2751
|
-
}
|
|
2750
|
+
this.load('PREDICTIVE');
|
|
2752
2751
|
}, 200);
|
|
2753
2752
|
}
|
|
2753
|
+
load(mode) {
|
|
2754
|
+
if (this.loadexecutor) {
|
|
2755
|
+
this._loadDataFunction({ mode, argument: this._inputElem.value }, (serverData) => { this.populateOptions(serverData); });
|
|
2756
|
+
}
|
|
2757
|
+
}
|
|
2754
2758
|
normalizeResult(data) {
|
|
2755
|
-
let options = [];
|
|
2756
2759
|
if (data instanceof Array) {
|
|
2760
|
+
let options = [];
|
|
2757
2761
|
options = data;
|
|
2762
|
+
this._options = [{ value: '', label: '' }].concat(options);
|
|
2763
|
+
this.buildOptions();
|
|
2758
2764
|
}
|
|
2759
2765
|
else {
|
|
2760
|
-
if (data
|
|
2761
|
-
|
|
2762
|
-
|
|
2763
|
-
newOption.value = key;
|
|
2764
|
-
newOption.label = data[key];
|
|
2765
|
-
options.push(newOption);
|
|
2766
|
-
}
|
|
2766
|
+
if (data === null || data === void 0 ? void 0 : data.value) {
|
|
2767
|
+
this.value = data.value;
|
|
2768
|
+
this._inputElem.value = data.value;
|
|
2767
2769
|
}
|
|
2768
2770
|
}
|
|
2769
|
-
this._options = [{ value: '', label: '' }].concat(options);
|
|
2770
|
-
this.buildOptions();
|
|
2771
2771
|
}
|
|
2772
2772
|
populateOptions(serverData) {
|
|
2773
2773
|
if (serverData instanceof Promise) {
|
|
@@ -2814,7 +2814,7 @@ const EzSearch = class {
|
|
|
2814
2814
|
}
|
|
2815
2815
|
render() {
|
|
2816
2816
|
var _a;
|
|
2817
|
-
return (index.h(index.Host, null, index.h("ez-text-input", { ref: (el) => { this._inputElem = el; }, label: this.label, enabled: this.enabled, onFocus: () => { this.handleFocus(); }, onInput: () => { this.handleChange(); }, onKeyDown: event => this.keyDownHandler(event), errormessage: this.errormessage }, index.h("button", { disabled: !this.enabled, tabindex: -1, class: "btn-open-search", onClick: () => {
|
|
2817
|
+
return (index.h(index.Host, null, index.h("ez-text-input", { ref: (el) => { this._inputElem = el; }, label: this.label, enabled: this.enabled, onFocus: () => { this.handleFocus(); }, onInput: () => { this.handleChange(); }, onKeyDown: event => this.keyDownHandler(event), errormessage: this.errormessage }, index.h("button", { disabled: !this.enabled, tabindex: -1, class: "btn-open-search", onClick: () => { this.load('ADVANCED'); this.showPopup.emit(); }, slot: "leftIcon" })), index.h("ez-popover", { boxwidth: '100%', ref: el => this._popover = el }, index.h("div", { class: 'list-container', ref: (el) => this._divElem = el }, (_a = this._visibleOptions) === null || _a === void 0 ? void 0 : _a.map((opt, index) => this.buildItem(opt, index))))));
|
|
2818
2818
|
}
|
|
2819
2819
|
;
|
|
2820
2820
|
get el() { return index.getElement(this); }
|
|
@@ -3059,6 +3059,7 @@ const EzTextArea = class {
|
|
|
3059
3059
|
this._inputElem.value = this.value;
|
|
3060
3060
|
this.handleChange();
|
|
3061
3061
|
this.adjustFloatingLabel();
|
|
3062
|
+
this.ezChange.emit(this.value);
|
|
3062
3063
|
}
|
|
3063
3064
|
adjustFloatingLabel() {
|
|
3064
3065
|
if (this.label) {
|
|
@@ -3135,7 +3136,7 @@ function isValidNumber(strValue) {
|
|
|
3135
3136
|
return strValue && /^-?\d*[.,]?\d*$/.test(strValue);
|
|
3136
3137
|
}
|
|
3137
3138
|
|
|
3138
|
-
const ezTextInputCss = ":host{--it--height:42px;--it--width:100%;--it__icon--width:48px;--it--border-radius:var(--border--radius-medium, 12px);--it--font-size:var(--text--medium, 14px);--it--font-family:var(--font-pattern, Arial);--it--font-weight:var(--text-weight--large, 500);--it--color:var(--title--primary, #000);--it__input--background-color:var(--background--medium, #e0e0e0);--it__input--border:var(--border--medium, 2px solid);--it__input--border-color:var(--it__input--background-color);--it__input--focus--border-color:var(--color--primary, #008561);--it__input--disabled--background-color:var(--color--disable-secondary, #F2F5F8);--it__input--disabled--color:var(--text--disable, #AFB6C0);--it__input--error--border-color:#CC2936;--it__message_box--font-size:var(--text--small, 12px);--it__message_box--info--color:var(--color--success, #22085d);--it__message_box--error--color:var(--color--error, #FF0000);--it__label--floating--top:6px;--it__label--padding-top:12px;--it__label--padding-left:14px;--it__label--padding-right:12px;display:flex;flex-wrap:wrap;position:relative;width:var(--it--width)}input{width:100%;box-sizing:border-box;padding:var(--space--medium, 6px);font-weight:var(--text-weight--large, 600);height:var(--it--height);border-radius:var(--it--border-radius);font-family:var(--it--font-family);font-size:var(--it--font-size);border:var(--it__input--border);border-color:var(--it__input--border-color);background-color:var(--it__input--background-color);color:var(--it--color)}input:disabled{background-color:var(--it__input--disabled--background-color);color:var(--it__input--disabled--color)}input:focus{outline:none;border-color:var(--it__input--focus--border-color)}input.icon--left{padding-left:var(--it__icon--width)}input.icon--right{padding-right:var(--it__icon--width)}input.hasError{color:var(--it--color);border-color:var(--it__input--error--border-color)}input.text--right{text-align:right}.message-box{min-height:16px;min-width:100%;margin-top:2px;line-height:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:var(--it--font-family);font-size:var(--it__message_box--font-size);color:var(--it__message_box--info--color)}.hasError{color:var(--it__message_box--error--color)}.input__label{box-sizing:border-box;position:absolute;z-index:var(--visible);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;-webkit-transition:font-size .05s, top .05s;transition:font-size .05s, top .05s;width:calc(100% - var(--it__label--padding-right));left:var(--it--space--medium);font-family:var(--it--font-family);font-size:var(--it--font-size);font-weight:var(--it--font-weight);color:var(--it--color);top:var(--it__label--padding-top);left:var(--it__label--padding-left);padding-right:var(--it__label--padding-right)}.input__label--floated{font-family:var(--it--font-family);font-size:var(--text--extra-small);color:var(--text--primary);top:var(--it__label--floating--top)}.input__label--disabled{color:var(--it__input--disabled--color)}.input__label--left{left:calc(var(--it__icon--width) + 2px);width:calc(100% - var(--it__icon--width))}.input__label--right{right:var(--it__icon--width);width:calc(100% - var(--it__icon--width))}.input__label--left.input__label--right{left:calc(var(--it__icon--width) + 2px);width:calc(100% - var(--it__icon--width) * 2)}.input--with--label{padding-bottom:0}";
|
|
3139
|
+
const ezTextInputCss = ":host{--it--height:42px;--it--width:100%;--it__icon--width:48px;--it--border-radius:var(--border--radius-medium, 12px);--it--font-size:var(--text--medium, 14px);--it--font-family:var(--font-pattern, Arial);--it--font-weight:var(--text-weight--large, 500);--it--color:var(--title--primary, #000);--it__input--background-color:var(--background--medium, #e0e0e0);--it__input--border:var(--border--medium, 2px solid);--it__input--border-color:var(--it__input--background-color);--it__input--focus--border-color:var(--color--primary, #008561);--it__input--disabled--background-color:var(--color--disable-secondary, #F2F5F8);--it__input--disabled--color:var(--text--disable, #AFB6C0);--it__input--error--border-color:#CC2936;--it__message_box--font-size:var(--text--small, 12px);--it__message_box--info--color:var(--color--success, #22085d);--it__message_box--error--color:var(--color--error, #FF0000);--it__label--floating--top:6px;--it__label--padding-top:12px;--it__label--padding-left:14px;--it__label--padding-right:12px;display:flex;flex-wrap:wrap;position:relative;width:var(--it--width)}input{width:100%;box-sizing:border-box;padding:var(--space--medium, 6px);font-weight:var(--text-weight--large, 600);height:var(--it--height);border-radius:var(--it--border-radius);font-family:var(--it--font-family);font-size:var(--it--font-size);border:var(--it__input--border);border-color:var(--it__input--border-color);background-color:var(--it__input--background-color);color:var(--it--color)}input:disabled{background-color:var(--it__input--disabled--background-color);color:var(--it__input--disabled--color)}input:focus{outline:none;border-color:var(--it__input--focus--border-color)}input.icon--left{padding-left:var(--it__icon--width)}input.icon--right{padding-right:var(--it__icon--width)}input.hasError{color:var(--it--color);border-color:var(--it__input--error--border-color)}input.text--right{text-align:right}.message-box{min-height:16px;min-width:100%;margin-top:2px;line-height:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:var(--it--font-family);font-size:var(--it__message_box--font-size);color:var(--it__message_box--info--color)}.hasError{color:var(--it__message_box--error--color)}.input__label{box-sizing:border-box;position:absolute;z-index:var(--visible);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;-webkit-transition:font-size .05s, top .05s;transition:font-size .05s, top .05s;width:calc(100% - var(--it__label--padding-right));left:var(--it--space--medium);font-family:var(--it--font-family);font-size:var(--it--font-size);font-weight:var(--it--font-weight);color:var(--it--color);top:var(--it__label--padding-top);left:var(--it__label--padding-left);padding-right:var(--it__label--padding-right)}.input__label--floated{font-family:var(--it--font-family);font-size:var(--text--extra-small);color:var(--text--primary);top:var(--it__label--floating--top)}.input__label--disabled{color:var(--it__input--disabled--color)}.input__label--left{text-align:left;left:calc(var(--it__icon--width) + 2px);width:calc(100% - var(--it__icon--width))}.input__label--right{right:var(--it__icon--width);width:calc(100% - var(--it__icon--width))}.input__label--left.input__label--right{left:calc(var(--it__icon--width) + 2px);width:calc(100% - var(--it__icon--width) * 2)}.input--with--label{padding-bottom:0}";
|
|
3139
3140
|
|
|
3140
3141
|
const EzTextInput = class {
|
|
3141
3142
|
constructor(hostRef) {
|
|
@@ -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-b0ab12a1.js');
|
|
6
6
|
|
|
7
7
|
const ezLabelChipCss = ":host{--lc--height:36px;--lc--width:100%;--lc__icon--width:48px;--lc--border-radius:var(--border--radius-large, 24px);--lc--font-size:var(--text--medium, 14px);--lc--font-family:var(--font-pattern, Arial);--lc--font-weight:var(--text-weight--large, 500);--lc--space--medium:var(--space--medium, 6px);--lc__border:1px solid;--lc__border-color-strokes:var(--color--strokes, #DCE0E8);--lc__label--title--primary:var(--title--primary, #919191);--lc__label--color-primary:var(--color--primary, #008561);--lc__label-color--disable-secondary:var(--color--disable-secondary, #F2F5F8);--lc__label--background-color:#0085610F;--lc__label__default--background-color--hover:var(--color--primary-200, #f2faf8);--lc__label__default--border-color--hover:var(--color--primary-600, #007a5a);--lc__label--text--disabled:var(--text--disable, #AFB6C0);--lc__label--text--primary:var(--text--primary, #626e82);--lc__message_box--font-size:var(--text--small, 12px);--lc__message_box--info--color:var(--color--success, #22085d);--lc__message_box--error--color:var(--color--error, #FF0000);width:100%}.padding-right--small{padding-right:var(--lc--space--medium)}.padding-left--small{padding-left:var(--lc--space--medium)}.label__container{width:fit-content;display:flex;flex-wrap:wrap;position:relative;align-items:center;align-self:center;color:var(--lc__label--title--primary);fill:var(--lc__label--title--primary);border:var(--lc__border);border-radius:var(--lc--border-radius);border-color:var( --lc__border-color-strokes);padding-right:var(--space--large, 12px);padding-left:var(--space--large, 12px)}.label__container:hover{border-color:var(--lc__label__default--border-color--hover);background-color:var(--lc__label__default--background-color--hover)}.label__container--active{width:fit-content;display:flex;flex-wrap:wrap;position:relative;align-items:center;align-self:center;border:var(--lc__border);border-radius:var(--lc--border-radius);padding-right:var(--space--large, 12px);padding-left:var(--space--large, 12px);fill:var(--lc__label--color-primary);color:var(--lc__label--color-primary);border-color:var(--lc__label--background-color);background-color:var(--lc__label--background-color)}.label__container--disabled{width:fit-content;display:flex;flex-wrap:wrap;position:relative;align-items:center;align-self:center;border:var(--lc__border);border-color:var(--lc__label-color--disable-secondary);border-radius:var(--lc--border-radius);padding-right:var(--space--large, 12px);padding-left:var(--space--large, 12px);fill:var(--lc__label--text--disabled);color:var(--lc__label--text--disabled);background-color:var(--lc__label-color--disable-secondary)}label{display:flex;align-items:center;width:calc(100% - var(--lc__icon--width));width:fit-content;font-weight:var(--text-weight--large, 600);cursor:pointer;height:var(--lc--height);font-family:var(--lc--font-family);font-size:var(--lc--font-size)}.label__icon{display:flex;cursor:pointer}";
|
|
8
8
|
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-b0ab12a1.js');
|
|
6
6
|
|
|
7
|
-
const ezModalCss = ":host{--modal-z-index:var(--most-visible, 3);--modal-vertical-padding:var(--space--extra-large, 48px);display:block}.modal{position:fixed;padding:var(--modal-vertical-padding) 0;display:flex;top:0px;z-index:var(--modal-z-index);left:0px;width:100%;height:100vh;backdrop-filter:blur(4px);background:rgb(0 4 12 / 40%)}@keyframes expand-modal--left{from{transform:translate(-100%)}}@keyframes expand-modal--right{from{transform:translate(100%)}}.modal__container{display:flex;flex-wrap:wrap;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;max-height:89.6vh;overflow-y:auto;background-color:#fff;padding:24px;border-radius:12px 0px 0px 12px;box-shadow:0px 0px 16px 0px rgba(0, 38, 111, 0.12)}.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}.
|
|
7
|
+
const ezModalCss = ":host{--modal-z-index:var(--most-visible, 3);--modal-vertical-padding:var(--space--extra-large, 48px);display:block}.modal{position:fixed;padding:var(--modal-vertical-padding) 0;display:flex;top:0px;z-index:var(--modal-z-index);left:0px;width:100%;height:100vh;backdrop-filter:blur(4px);background:rgb(0 4 12 / 40%)}@keyframes expand-modal--left{from{transform:translate(-100%)}}@keyframes expand-modal--right{from{transform:translate(100%)}}.modal__container{display:flex;flex-wrap:wrap;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;max-height:89.6vh;overflow-y:auto;background-color:#fff;padding:24px;border-radius:12px 0px 0px 12px;box-shadow:0px 0px 16px 0px rgba(0, 38, 111, 0.12)}.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
|
|
|
9
9
|
const EzModal = class {
|
|
10
10
|
constructor(hostRef) {
|
|
@@ -30,13 +30,13 @@ const EzModal = class {
|
|
|
30
30
|
}
|
|
31
31
|
};
|
|
32
32
|
}
|
|
33
|
-
handleClickOverlay(ev) {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
}
|
|
33
|
+
// handleClickOverlay(ev) {
|
|
34
|
+
// ev?.stopPropagation();
|
|
35
|
+
// if (ev instanceof PointerEvent && this.closeoutsideclick) {
|
|
36
|
+
// this.oppened = false;
|
|
37
|
+
// this.ezChange.emit(this.oppened);
|
|
38
|
+
// }
|
|
39
|
+
// }
|
|
40
40
|
handleOppenedChange() {
|
|
41
41
|
if (this.oppened) {
|
|
42
42
|
document.addEventListener('keydown', this.handleKeyboardEvent);
|
|
@@ -96,11 +96,11 @@ const EzModal = class {
|
|
|
96
96
|
//Ainda teremos ajustes visuais
|
|
97
97
|
render() {
|
|
98
98
|
return (index.h(index.Host, null, this.oppened ?
|
|
99
|
-
index.h("div", { class: 'modal' /* ref={el => this._overlay = el}
|
|
99
|
+
index.h("div", { class: 'modal' /* ref={el => this._overlay = el} */ /* onClick={(ev) => this.handleClickOverlay(ev)} */ }, this.align === 'left'
|
|
100
100
|
?
|
|
101
|
-
index.h("div", {
|
|
101
|
+
index.h("div", { class: "modal__container modal__container--left" }, index.h("div", { class: "modal__content modal__content--left " + this.modalsize }, index.h("slot", null)))
|
|
102
102
|
: undefined, this.align === 'right' ?
|
|
103
|
-
index.h("div", {
|
|
103
|
+
index.h("div", { class: "modal__container modal__container--right" }, index.h("div", { class: "modal__content modal__content--right " + this.modalsize }, index.h("slot", null)))
|
|
104
104
|
: undefined)
|
|
105
105
|
: undefined));
|
|
106
106
|
}
|
|
@@ -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-b0ab12a1.js');
|
|
6
6
|
const RequestMetadata = require('./RequestMetadata-2cd01e8a.js');
|
|
7
7
|
|
|
8
8
|
const ezNumberInputCss = ":host{--ni--height:42px;--ni--width:100%;--ni__icon--width:48px;--ni--border-radius:var(--border--radius-medium, 12px);--ni--font-size:var(--text--medium, 14px);--ni--font-family:var(--font-pattern, Arial);--ni__input--background-color:var(--background--medium, #e0e0e0);--ni__input--border:var(--border--medium, 2px solid);--ni__input--border-color:var(--ni__input--background-color);--ni__input--focus--border-color:var(--color--primary, #008561);--ni__input--disabled--background-color:var(--color--disable-secondary, #F2F5F8);--ni__input--disabled--color:var(--text--disable, #AFB6C0);--ni__input--error--border-color:#CC2936;--ni__placeholder--disabled--color:var(--text--disable, #AFB6C0);--ni__placeholder--color:var(--title--primary, #919191);--ni__placeholder--font-weight:var(--text-weight--large, 500);--ni__message_box--font-size:var(--text--small, 12px);--ni__message_box--info--color:var(--color--success, #22085d);--ni__message_box--error--color:var(--color--error, #FF0000);display:flex;flex-wrap:wrap;position:relative;width:var(--ni--width)}.invisible{visibility:hidden}input{width:100%;box-sizing:border-box;padding:var(--space--medium);height:var(--ni--height);border-radius:var(--ni--border-radius);font-family:var(--ni--font-family);font-size:var(--ni--font-size);border:var(--ni__input--border);border-color:var(--ni__input--border-color);background-color:var(--ni__input--background-color);font-weight:var(--text-weight--large)}input:disabled{background-color:var(--ni__input--disabled--background-color);color:var(--ni__input--disabled--color)}input:focus{outline:none;border-color:var(--ni__input--focus--border-color)}input.icon--left{padding-left:var(--ni__icon--width)}input.icon--right{padding-right:var(--ni__icon--width)}input::placeholder{color:var(--ni__placeholder--color);font-weight:var(--ni__placeholder--font-weight)}input:disabled::placeholder{color:var(--ni__placeholder--disabled--color)}input.hasError{color:inherit;border-color:var(--ni__input--error--border-color)}input.text--right{text-align:right}.message-box{min-height:16px;min-width:100%;margin-top:2px;line-height:12px;font-family:var(--ni--font-family);font-size:var(--ni__message_box--font-size);color:var(--ni__message_box--info--color)}.hasError{color:var(--ni__message_box--error--color)}.input__label{font-size:var(--text--medium);font-weight:var(--text-weight--large);left:var(--space--medium);position:absolute;color:var(--title--primary);top:var(--space--medium);font-family:var(--ni--font-family);-webkit-transition:font-size .3s, top .3s;transition:font-size .3s, top .3s;z-index:var(--visible)}.input__label--floated{font-family:var(--ni--font-family);font-size:var(--text--extra-small);top:var(--space--small);color:var(--text--primary)}.input__label--left{left:var(--ni__icon--width)}.input--with--label{padding-bottom:0}";
|
|
@@ -10,6 +10,7 @@ const ezNumberInputCss = ":host{--ni--height:42px;--ni--width:100%;--ni__icon--w
|
|
|
10
10
|
const NumberInput = class {
|
|
11
11
|
constructor(hostRef) {
|
|
12
12
|
index.registerInstance(this, hostRef);
|
|
13
|
+
this.ezChange = index.createEvent(this, "ezChange", 7);
|
|
13
14
|
/**
|
|
14
15
|
* Deixa o campo disponível ou não para digitação.
|
|
15
16
|
*/
|
|
@@ -202,6 +203,7 @@ const NumberInput = class {
|
|
|
202
203
|
}
|
|
203
204
|
this.strvalue = this._inputElem.value;
|
|
204
205
|
}
|
|
206
|
+
this.ezChange.emit({ strValue: this.strvalue, value: this.value });
|
|
205
207
|
this.adjustFloatingLabel();
|
|
206
208
|
}
|
|
207
209
|
settingValue() {
|
|
@@ -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-b0ab12a1.js');
|
|
6
6
|
const RequestMetadata = require('./RequestMetadata-2cd01e8a.js');
|
|
7
7
|
|
|
8
8
|
const ezTimeInputCss = ":host{--eztime--height:42px;--eztime--width:100%;--eztime__icon--width:48px;--eztime--border-radius:var(--border--radius-medium, 12px);--eztime--font-size:var(--text--medium, 14px);--eztime--font-family:var(--font-pattern, Arial);--eztime--font-weight:var(--text-weight--large, 500);--eztime--space--medium:var(--space--medium, 6px);--eztime__input--background-color:var(--background--medium, #e0e0e0);--eztime__input--border:var(--border--medium, 2px solid);--eztime__input--border-color:var(--eztime__input--background-color);--eztime__input--focus--border-color:var(--color--primary, #008561);--eztime__input--disabled--background-color:var(--color--disable-secondary, #F2F5F8);--eztime__input--disabled--color:var(--text--disable, #AFB6C0);--eztime__input--error--border-color:#CC2936;--eztime__label--color:var(--title--primary, #919191);--eztime__message_box--font-size:var(--text--small, 12px);--eztime__message_box--info--color:var(--color--success, #22085d);--eztime__message_box--error--color:var(--color--error, #FF0000);display:flex;flex-wrap:wrap;position:relative;width:var(--eztime--width)}.invisible{visibility:hidden}input{width:100%;box-sizing:border-box;padding:var(--space--medium, 6px);font-weight:var(--text-weight--large, 600);height:var(--eztime--height);border-radius:var(--eztime--border-radius);font-family:var(--eztime--font-family);font-size:var(--eztime--font-size);border:var(--eztime__input--border);border-color:var(--eztime__input--border-color);background-color:var(--eztime__input--background-color)}input:disabled{background-color:var(--eztime__input--disabled--background-color);color:var(--eztime__input--disabled--color)}input:focus{outline:none;border-color:var(--eztime__input--focus--border-color)}input.icon--left{padding-left:var(--eztime__icon--width)}input.icon--right{padding-right:var(--eztime__icon--width)}input::placeholder{color:var(--eztime__placeholder--color);font-weight:var(--eztime__placeholder--font-weight)}input:disabled::placeholder{color:var(--eztime__placeholder--disabled--color)}input.hasError{color:inherit;border-color:var(--eztime__input--error--border-color)}input.text--right{text-align:right}.message-box{min-height:16px;min-width:100%;margin-top:2px;line-height:12px;font-family:var(--eztime--font-family);font-size:var(--eztime__message_box--font-size);color:var(--eztime__message_box--info--color)}.hasError{color:var(--eztime__message_box--error--color)}.input__label{font-size:var(--eztime--font-size);font-weight:var(--eztime--font-weight);position:absolute;color:var(it__label--color);top:var(--eztime--space--medium);font-family:var(--eztime--font-family);-webkit-transition:font-size .3s, top .3s;transition:font-size .3s, top .3s;z-index:var(--visible);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;left:var(--eztime__icon--width);width:calc(100% - 10px - var(--eztime__icon--width))}.input__label--floated{font-family:var(--eztime--font-family);font-size:var(--text--extra-small);top:var(--space--small);color:var(--text--primary)}.input__label--left{left:var(--eztime__icon--width);width:calc(100% - 10px - var(--eztime__icon--width))}.input__label--right{padding-right:var(--eztime__icon--width);width:calc(100% - 10px - var(--eztime__icon--width))}.input--with--label{padding-bottom:0}";
|
package/dist/cjs/ezui.cjs.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
3
|
+
const index = require('./index-b0ab12a1.js');
|
|
4
4
|
|
|
5
5
|
/*
|
|
6
|
-
Stencil Client Patch Browser v2.
|
|
6
|
+
Stencil Client Patch Browser v2.8.1 | MIT Licensed | https://stenciljs.com
|
|
7
7
|
*/
|
|
8
8
|
const patchBrowser = () => {
|
|
9
9
|
const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('ezui.cjs.js', document.baseURI).href));
|
|
@@ -31,8 +31,8 @@ const doc = win.document || { head: {} };
|
|
|
31
31
|
const plt = {
|
|
32
32
|
$flags$: 0,
|
|
33
33
|
$resourcesUrl$: '',
|
|
34
|
-
jmp: h => h(),
|
|
35
|
-
raf: h => requestAnimationFrame(h),
|
|
34
|
+
jmp: (h) => h(),
|
|
35
|
+
raf: (h) => requestAnimationFrame(h),
|
|
36
36
|
ael: (el, eventName, listener, opts) => el.addEventListener(eventName, listener, opts),
|
|
37
37
|
rel: (el, eventName, listener, opts) => el.removeEventListener(eventName, listener, opts),
|
|
38
38
|
ce: (eventName, opts) => new CustomEvent(eventName, opts),
|
|
@@ -41,7 +41,7 @@ const promiseResolve = (v) => Promise.resolve(v);
|
|
|
41
41
|
const supportsConstructibleStylesheets = /*@__PURE__*/ (() => {
|
|
42
42
|
try {
|
|
43
43
|
new CSSStyleSheet();
|
|
44
|
-
return typeof
|
|
44
|
+
return typeof new CSSStyleSheet().replace === 'function';
|
|
45
45
|
}
|
|
46
46
|
catch (e) { }
|
|
47
47
|
return false;
|
|
@@ -199,7 +199,7 @@ const h = (nodeName, vnodeData, ...children) => {
|
|
|
199
199
|
typeof classData !== 'object'
|
|
200
200
|
? classData
|
|
201
201
|
: Object.keys(classData)
|
|
202
|
-
.filter(k => classData[k])
|
|
202
|
+
.filter((k) => classData[k])
|
|
203
203
|
.join(' ');
|
|
204
204
|
}
|
|
205
205
|
}
|
|
@@ -282,8 +282,8 @@ const setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
|
282
282
|
const classList = elm.classList;
|
|
283
283
|
const oldClasses = parseClassList(oldValue);
|
|
284
284
|
const newClasses = parseClassList(newValue);
|
|
285
|
-
classList.remove(...oldClasses.filter(c => c && !newClasses.includes(c)));
|
|
286
|
-
classList.add(...newClasses.filter(c => c && !oldClasses.includes(c)));
|
|
285
|
+
classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
|
|
286
|
+
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
287
287
|
}
|
|
288
288
|
else if (memberName === 'style') {
|
|
289
289
|
// update style attribute, css properties and values
|
|
@@ -318,7 +318,9 @@ const setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
|
318
318
|
newValue(elm);
|
|
319
319
|
}
|
|
320
320
|
}
|
|
321
|
-
else if ((!isProp ) &&
|
|
321
|
+
else if ((!isProp ) &&
|
|
322
|
+
memberName[0] === 'o' &&
|
|
323
|
+
memberName[1] === 'n') {
|
|
322
324
|
// Event Handlers
|
|
323
325
|
// so if the member name starts with "on" and the 3rd characters is
|
|
324
326
|
// a capital letter, and it's not already a member on the element,
|
|
@@ -419,7 +421,9 @@ const updateElement = (oldVnode, newVnode, isSvgMode, memberName) => {
|
|
|
419
421
|
// if the element passed in is a shadow root, which is a document fragment
|
|
420
422
|
// then we want to be adding attrs/props to the shadow root's "host" element
|
|
421
423
|
// if it's not a shadow root, then we add attrs/props to the same element
|
|
422
|
-
const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host
|
|
424
|
+
const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host
|
|
425
|
+
? newVnode.$elm$.host
|
|
426
|
+
: newVnode.$elm$;
|
|
423
427
|
const oldVnodeAttrs = (oldVnode && oldVnode.$attrs$) || EMPTY_OBJ;
|
|
424
428
|
const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;
|
|
425
429
|
{
|
|
@@ -705,6 +709,13 @@ const createEvent = (ref, name, flags) => {
|
|
|
705
709
|
},
|
|
706
710
|
};
|
|
707
711
|
};
|
|
712
|
+
/**
|
|
713
|
+
* Helper function to create & dispatch a custom Event on a provided target
|
|
714
|
+
* @param elm the target of the Event
|
|
715
|
+
* @param name the name to give the custom Event
|
|
716
|
+
* @param opts options for configuring a custom Event
|
|
717
|
+
* @returns the custom Event
|
|
718
|
+
*/
|
|
708
719
|
const emitEvent = (elm, name, opts) => {
|
|
709
720
|
const ev = plt.ce(name, opts);
|
|
710
721
|
elm.dispatchEvent(ev);
|
|
@@ -712,7 +723,7 @@ const emitEvent = (elm, name, opts) => {
|
|
|
712
723
|
};
|
|
713
724
|
const attachToAncestor = (hostRef, ancestorComponent) => {
|
|
714
725
|
if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent['s-p']) {
|
|
715
|
-
ancestorComponent['s-p'].push(new Promise(r => (hostRef.$onRenderResolve$ = r)));
|
|
726
|
+
ancestorComponent['s-p'].push(new Promise((r) => (hostRef.$onRenderResolve$ = r)));
|
|
716
727
|
}
|
|
717
728
|
};
|
|
718
729
|
const scheduleUpdate = (hostRef, isInitialLoad) => {
|
|
@@ -762,7 +773,7 @@ const updateComponent = async (hostRef, instance, isInitialLoad) => {
|
|
|
762
773
|
// ok, so turns out there are some child host elements
|
|
763
774
|
// waiting on this parent element to load
|
|
764
775
|
// let's fire off all update callbacks waiting
|
|
765
|
-
rc.map(cb => cb());
|
|
776
|
+
rc.map((cb) => cb());
|
|
766
777
|
elm['s-rc'] = undefined;
|
|
767
778
|
}
|
|
768
779
|
endRender();
|
|
@@ -857,7 +868,8 @@ const forceUpdate = (ref) => {
|
|
|
857
868
|
{
|
|
858
869
|
const hostRef = getHostRef(ref);
|
|
859
870
|
const isConnected = hostRef.$hostElement$.isConnected;
|
|
860
|
-
if (isConnected &&
|
|
871
|
+
if (isConnected &&
|
|
872
|
+
(hostRef.$flags$ & (2 /* hasRendered */ | 16 /* isQueuedForUpdate */)) === 2 /* hasRendered */) {
|
|
861
873
|
scheduleUpdate(hostRef, false);
|
|
862
874
|
}
|
|
863
875
|
// Returns "true" when the forced update was successfully scheduled
|
|
@@ -886,7 +898,8 @@ const safeCall = (instance, method, arg) => {
|
|
|
886
898
|
const then = (promise, thenFn) => {
|
|
887
899
|
return promise && promise.then ? promise.then(thenFn) : thenFn();
|
|
888
900
|
};
|
|
889
|
-
const addHydratedFlag = (elm) =>
|
|
901
|
+
const addHydratedFlag = (elm) => elm.classList.add('hydrated')
|
|
902
|
+
;
|
|
890
903
|
const parsePropertyValue = (propValue, propType) => {
|
|
891
904
|
// ensure this value is of the correct prop type
|
|
892
905
|
if (propValue != null && !isComplexType(propValue)) {
|
|
@@ -930,7 +943,7 @@ const setValue = (ref, propName, newVal, cmpMeta) => {
|
|
|
930
943
|
const watchMethods = cmpMeta.$watchers$[propName];
|
|
931
944
|
if (watchMethods) {
|
|
932
945
|
// this instance is watching for when this property changed
|
|
933
|
-
watchMethods.map(watchMethodName => {
|
|
946
|
+
watchMethods.map((watchMethodName) => {
|
|
934
947
|
try {
|
|
935
948
|
// fire off each of the watch methods that are watching this property
|
|
936
949
|
instance[watchMethodName](newVal, oldVal, propName);
|
|
@@ -960,7 +973,8 @@ const proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
960
973
|
const members = Object.entries(cmpMeta.$members$);
|
|
961
974
|
const prototype = Cstr.prototype;
|
|
962
975
|
members.map(([memberName, [memberFlags]]) => {
|
|
963
|
-
if ((memberFlags & 31 /* Prop */ ||
|
|
976
|
+
if ((memberFlags & 31 /* Prop */ ||
|
|
977
|
+
((flags & 2 /* proxyState */) && memberFlags & 32 /* State */))) {
|
|
964
978
|
// proxyComponent - prop
|
|
965
979
|
Object.defineProperty(prototype, memberName, {
|
|
966
980
|
get() {
|
|
@@ -975,7 +989,8 @@ const proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
975
989
|
enumerable: true,
|
|
976
990
|
});
|
|
977
991
|
}
|
|
978
|
-
else if (flags & 1 /* isElementConstructor */ &&
|
|
992
|
+
else if (flags & 1 /* isElementConstructor */ &&
|
|
993
|
+
memberFlags & 64 /* Method */) {
|
|
979
994
|
// proxyComponent - method
|
|
980
995
|
Object.defineProperty(prototype, memberName, {
|
|
981
996
|
value(...args) {
|
|
@@ -990,6 +1005,43 @@ const proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
990
1005
|
prototype.attributeChangedCallback = function (attrName, _oldValue, newValue) {
|
|
991
1006
|
plt.jmp(() => {
|
|
992
1007
|
const propName = attrNameToPropName.get(attrName);
|
|
1008
|
+
// In a webcomponent lifecyle the attributeChangedCallback runs prior to connectedCallback
|
|
1009
|
+
// in the case where an attribute was set inline.
|
|
1010
|
+
// ```html
|
|
1011
|
+
// <my-component some-attribute="some-value"></my-component>
|
|
1012
|
+
// ```
|
|
1013
|
+
//
|
|
1014
|
+
// There is an edge case where a developer sets the attribute inline on a custom element and then programatically
|
|
1015
|
+
// changes it before it has been upgraded as shown below:
|
|
1016
|
+
//
|
|
1017
|
+
// ```html
|
|
1018
|
+
// <!-- this component has _not_ been upgraded yet -->
|
|
1019
|
+
// <my-component id="test" some-attribute="some-value"></my-component>
|
|
1020
|
+
// <script>
|
|
1021
|
+
// // grab non-upgraded component
|
|
1022
|
+
// el = document.querySelector("#test");
|
|
1023
|
+
// el.someAttribute = "another-value";
|
|
1024
|
+
// // upgrade component
|
|
1025
|
+
// cutsomElements.define('my-component', MyComponent);
|
|
1026
|
+
// </script>
|
|
1027
|
+
// ```
|
|
1028
|
+
// In this case if we do not unshadow here and use the value of the shadowing property, attributeChangedCallback
|
|
1029
|
+
// will be called with `newValue = "some-value"` and will set the shadowed property (this.someAttribute = "another-value")
|
|
1030
|
+
// to the value that was set inline i.e. "some-value" from above example. When
|
|
1031
|
+
// the connectedCallback attempts to unshadow it will use "some-value" as the intial value rather than "another-value"
|
|
1032
|
+
//
|
|
1033
|
+
// The case where the attribute was NOT set inline but was not set programmatically shall be handled/unshadowed
|
|
1034
|
+
// by connectedCallback as this attributeChangedCallback will not fire.
|
|
1035
|
+
//
|
|
1036
|
+
// https://developers.google.com/web/fundamentals/web-components/best-practices#lazy-properties
|
|
1037
|
+
//
|
|
1038
|
+
// TODO(STENCIL-16) we should think about whether or not we actually want to be reflecting the attributes to
|
|
1039
|
+
// properties here given that this goes against best practices outlined here
|
|
1040
|
+
// https://developers.google.com/web/fundamentals/web-components/best-practices#avoid-reentrancy
|
|
1041
|
+
if (this.hasOwnProperty(propName)) {
|
|
1042
|
+
newValue = this[propName];
|
|
1043
|
+
delete this[propName];
|
|
1044
|
+
}
|
|
993
1045
|
this[propName] = newValue === null && typeof this[propName] === 'boolean' ? false : newValue;
|
|
994
1046
|
});
|
|
995
1047
|
};
|
|
@@ -1026,7 +1078,7 @@ const initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId, Cstr) =>
|
|
|
1026
1078
|
endLoad();
|
|
1027
1079
|
}
|
|
1028
1080
|
if (!Cstr.isProxied) {
|
|
1029
|
-
// we'
|
|
1081
|
+
// we've never proxied this Constructor before
|
|
1030
1082
|
// let's add the getters/setters to its prototype before
|
|
1031
1083
|
// the first time we create an instance of the implementation
|
|
1032
1084
|
{
|
|
@@ -1146,7 +1198,7 @@ const bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1146
1198
|
let isBootstrapping = true;
|
|
1147
1199
|
Object.assign(plt, options);
|
|
1148
1200
|
plt.$resourcesUrl$ = new URL(options.resourcesUrl || './', doc.baseURI).href;
|
|
1149
|
-
lazyBundles.map(lazyBundle => lazyBundle[1].map(compactMeta => {
|
|
1201
|
+
lazyBundles.map((lazyBundle) => lazyBundle[1].map((compactMeta) => {
|
|
1150
1202
|
const cmpMeta = {
|
|
1151
1203
|
$flags$: compactMeta[0],
|
|
1152
1204
|
$tagName$: compactMeta[1],
|
|
@@ -1216,7 +1268,7 @@ const bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1216
1268
|
// Process deferred connectedCallbacks now all components have been registered
|
|
1217
1269
|
isBootstrapping = false;
|
|
1218
1270
|
if (deferredConnectedCallbacks.length) {
|
|
1219
|
-
deferredConnectedCallbacks.map(host => host.connectedCallback());
|
|
1271
|
+
deferredConnectedCallbacks.map((host) => host.connectedCallback());
|
|
1220
1272
|
}
|
|
1221
1273
|
else {
|
|
1222
1274
|
{
|
|
@@ -1237,10 +1289,10 @@ const registerHost = (elm, cmpMeta) => {
|
|
|
1237
1289
|
$instanceValues$: new Map(),
|
|
1238
1290
|
};
|
|
1239
1291
|
{
|
|
1240
|
-
hostRef.$onInstancePromise$ = new Promise(r => (hostRef.$onInstanceResolve$ = r));
|
|
1292
|
+
hostRef.$onInstancePromise$ = new Promise((r) => (hostRef.$onInstanceResolve$ = r));
|
|
1241
1293
|
}
|
|
1242
1294
|
{
|
|
1243
|
-
hostRef.$onReadyPromise$ = new Promise(r => (hostRef.$onReadyResolve$ = r));
|
|
1295
|
+
hostRef.$onReadyPromise$ = new Promise((r) => (hostRef.$onReadyResolve$ = r));
|
|
1244
1296
|
elm['s-p'] = [];
|
|
1245
1297
|
elm['s-rc'] = [];
|
|
1246
1298
|
}
|
|
@@ -1261,7 +1313,7 @@ const loadModule = (cmpMeta, hostRef, hmrVersionId) => {
|
|
|
1261
1313
|
/* webpackInclude: /\.entry\.js$/ */
|
|
1262
1314
|
/* webpackExclude: /\.system\.entry\.js$/ */
|
|
1263
1315
|
/* webpackMode: "lazy" */
|
|
1264
|
-
`./${bundleId}.entry.js${''}`)); }).then(importedModule => {
|
|
1316
|
+
`./${bundleId}.entry.js${''}`)); }).then((importedModule) => {
|
|
1265
1317
|
{
|
|
1266
1318
|
cmpModules.set(bundleId, importedModule);
|
|
1267
1319
|
}
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-b0ab12a1.js');
|
|
6
6
|
|
|
7
7
|
/*
|
|
8
|
-
Stencil Client Patch Esm v2.
|
|
8
|
+
Stencil Client Patch Esm v2.8.1 | MIT Licensed | https://stenciljs.com
|
|
9
9
|
*/
|
|
10
10
|
const patchEsm = () => {
|
|
11
11
|
return index.promiseResolve();
|