@sankhyalabs/ezui 0.0.0-bugfix-dev-KB-9999.0 → 0.0.0-bugfix-dev-KB-46291.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{CSSVarsUtils-b136a156.js → CSSVarsUtils-10c9d5b4.js} +13 -0
- package/dist/cjs/ez-actions-button.cjs.entry.js +1 -1
- package/dist/cjs/ez-alert-list.cjs.entry.js +1 -1
- package/dist/cjs/ez-card-item_3.cjs.entry.js +6 -5
- package/dist/cjs/ez-combo-box.cjs.entry.js +7 -6
- 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-form-view.cjs.entry.js +30 -13
- package/dist/cjs/ez-grid.cjs.entry.js +90 -10
- package/dist/cjs/ez-icon.cjs.entry.js +1 -1
- package/dist/cjs/ez-multi-selection-list.cjs.entry.js +2 -10
- package/dist/cjs/ez-number-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-popup.cjs.entry.js +1 -1
- package/dist/cjs/ez-search.cjs.entry.js +4 -5
- package/dist/cjs/ez-split-button.cjs.entry.js +147 -0
- package/dist/cjs/ez-split-item.cjs.entry.js +11 -2
- package/dist/cjs/ez-split-panel.cjs.entry.js +6 -5
- package/dist/cjs/ez-time-input.cjs.entry.js +1 -1
- package/dist/cjs/ezui.cjs.js +1 -1
- package/dist/cjs/index-a7b0c73d.js +8 -4
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/ez-alert-list/ez-alert-list.css +1 -1
- package/dist/collection/components/ez-card-item/ez-card-item.css +19 -5
- package/dist/collection/components/ez-card-item/ez-card-item.js +22 -3
- package/dist/collection/components/ez-collapsible-box/ez-collapsible-box.css +1 -0
- package/dist/collection/components/ez-combo-box/ez-combo-box.js +6 -5
- package/dist/collection/components/ez-form-view/ez-form-view.css +17 -1
- package/dist/collection/components/ez-form-view/ez-form-view.js +22 -5
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/CheckBox.tpl.js +1 -1
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/ComboBox.tpl.js +1 -1
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/DateInput.tpl.js +3 -3
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/NumberInput.tpl.js +1 -1
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/SearchInput.tpl.js +1 -1
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/TextInput.tpl.js +1 -1
- package/dist/collection/components/ez-grid/controller/ag-grid/AgGridController.js +5 -1
- package/dist/collection/components/ez-grid/controller/ag-grid/DataSource.js +2 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/DataSourceInterceptor.js +21 -0
- package/dist/collection/components/ez-grid/ez-grid.css +25 -2
- package/dist/collection/components/ez-grid/ez-grid.js +65 -8
- package/dist/collection/components/ez-icon/ez-icon.css +118 -116
- package/dist/collection/components/ez-multi-selection-list/ez-multi-selection-list.js +2 -10
- package/dist/collection/components/ez-popup/ez-popup.css +2 -4
- package/dist/collection/components/ez-search/ez-search.js +3 -4
- package/dist/collection/components/ez-split-button/ez-split-button.css +229 -0
- package/dist/collection/components/ez-split-button/ez-split-button.js +436 -0
- package/dist/collection/components/ez-split-button/test/dropdownItems.js +42 -0
- package/dist/collection/components/ez-split-panel/ez-split-panel.css +0 -1
- package/dist/collection/components/ez-split-panel/ez-split-panel.js +5 -4
- package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.css +15 -4
- package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.js +27 -2
- package/dist/collection/utils/CSSVarsUtils.js +13 -0
- package/dist/custom-elements/index.d.ts +6 -0
- package/dist/custom-elements/index.js +309 -58
- package/dist/esm/{CSSVarsUtils-a97cfa29.js → CSSVarsUtils-71ce76be.js} +13 -0
- package/dist/esm/ez-actions-button.entry.js +1 -1
- package/dist/esm/ez-alert-list.entry.js +1 -1
- package/dist/esm/ez-card-item_3.entry.js +6 -5
- package/dist/esm/ez-combo-box.entry.js +7 -6
- 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-form-view.entry.js +31 -14
- package/dist/esm/ez-grid.entry.js +91 -11
- package/dist/esm/ez-icon.entry.js +1 -1
- package/dist/esm/ez-multi-selection-list.entry.js +2 -10
- package/dist/esm/ez-number-input.entry.js +1 -1
- package/dist/esm/ez-popup.entry.js +1 -1
- package/dist/esm/ez-search.entry.js +4 -5
- package/dist/esm/ez-split-button.entry.js +143 -0
- package/dist/esm/ez-split-item.entry.js +12 -3
- package/dist/esm/ez-split-panel.entry.js +6 -5
- package/dist/esm/ez-time-input.entry.js +1 -1
- package/dist/esm/ezui.js +1 -1
- package/dist/esm/index-baa5e267.js +8 -4
- package/dist/esm/loader.js +1 -1
- package/dist/ezui/ezui.esm.js +1 -1
- package/dist/ezui/{p-300bf244.entry.js → p-07cbffce.entry.js} +1 -1
- package/dist/ezui/p-248319e4.entry.js +1 -0
- package/dist/ezui/p-2eb8f73b.entry.js +1 -0
- package/dist/ezui/{p-40f72de4.entry.js → p-784fe207.entry.js} +1 -1
- package/dist/ezui/p-7af81663.entry.js +1 -0
- package/dist/ezui/p-7bc07c31.entry.js +1 -0
- package/dist/ezui/p-801fd0f8.entry.js +1 -0
- package/dist/ezui/{p-940ed30b.entry.js → p-8e7031a0.entry.js} +1 -1
- package/dist/ezui/{p-eb36f072.entry.js → p-99ead599.entry.js} +1 -1
- package/dist/ezui/{p-7eb3e1a5.js → p-9e11fc7b.js} +1 -1
- package/dist/ezui/{p-672dd122.entry.js → p-9f1e89c9.entry.js} +1 -1
- package/dist/ezui/{p-ab629244.entry.js → p-a332a654.entry.js} +2 -2
- package/dist/ezui/{p-02c8831a.entry.js → p-abc23d6f.entry.js} +1 -1
- package/dist/ezui/{p-50186acb.entry.js → p-af95cd16.entry.js} +1 -1
- package/dist/ezui/{p-18e7870d.entry.js → p-b567fa8c.entry.js} +1 -1
- package/dist/ezui/p-b9fbf4e7.entry.js +1 -0
- package/dist/ezui/p-db77a984.entry.js +1 -0
- package/dist/ezui/{p-9cad9b6e.entry.js → p-e85c48d7.entry.js} +1 -1
- package/dist/types/components/ez-card-item/ez-card-item.d.ts +4 -0
- package/dist/types/components/ez-combo-box/ez-combo-box.d.ts +1 -0
- package/dist/types/components/ez-form-view/ez-form-view.d.ts +3 -0
- package/dist/types/components/ez-grid/controller/EzGridController.d.ts +1 -0
- package/dist/types/components/ez-grid/controller/ag-grid/AgGridController.d.ts +1 -0
- package/dist/types/components/ez-grid/controller/ag-grid/DataSourceInterceptor.d.ts +8 -0
- package/dist/types/components/ez-grid/ez-grid.d.ts +15 -2
- package/dist/types/components/ez-multi-selection-list/ez-multi-selection-list.d.ts +0 -1
- package/dist/types/components/ez-split-button/ez-split-button.d.ts +89 -0
- package/dist/types/components/ez-split-button/test/dropdownItems.d.ts +2 -0
- package/dist/types/components/ez-split-panel/structure/item/ez-split-item.d.ts +10 -0
- package/dist/types/components.d.ts +131 -0
- package/dist/types/utils/CSSVarsUtils.d.ts +1 -0
- package/package.json +3 -2
- package/react/components.d.ts +1 -0
- package/react/components.js +1 -0
- package/react/components.js.map +1 -1
- package/dist/ezui/p-13dbad96.entry.js +0 -1
- package/dist/ezui/p-428a05fe.entry.js +0 -1
- package/dist/ezui/p-60848ef6.entry.js +0 -1
- package/dist/ezui/p-cd0499a2.entry.js +0 -1
- package/dist/ezui/p-e52cbcc7.entry.js +0 -1
- package/dist/ezui/p-e562d05e.entry.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as i,h as o,F as e,H as l}from"./p-23a36bb6.js";import{FloatingManager as d}from"@sankhyalabs/core";const p=class{constructor(o){t(this,o),this.ezClosePopup=i(this,"ezClosePopup",7),this._sizeClasses={"x-small":"col--sd-3 ez-popup__size-limit--x-small",small:"col--sd-5",medium:"col--sd-6",large:"col--sd-9","x-large":"col--sd-11",default:"ez-popup__size-limit--x-small"},this.size="medium",this.opened=!1,this.useHeader=!0,this.heightMode="full",this.ezTitle=void 0}observeConfig(){this.manageOverflow()}manageOverflow(){window.document.body.style.overflow=this.opened?"hidden":""}manageOverlay(){this.opened?this._overlayId=d.subscribeOverlayControl(this._modalRef):d.unsubscribeOverlayControl(this._modalRef||this._overlayId)}getGridSize(){return this._sizeClasses[this.size]||this._sizeClasses.medium}componentDidRender(){this._container&&this._container.focus(),this.manageOverlay()}render(){return o(l,null,this.opened?o("div",{class:"overlay",ref:t=>this._modalRef=t},o("div",{class:"popup col "+this.getGridSize()},o("div",{class:"popup__container "+("auto"===this.heightMode?"popup__container--auto":""),ref:t=>this._container=t,tabIndex:-1},o("div",{class:"popup__content"},o("div",{class:"popup__header "+(this.useHeader?"popup__header--padding":"")},this.useHeader&&o(e,null,!!this.ezTitle&&o("div",{class:"popup__title"},this.ezTitle),o("button",{class:this.ezTitle?"btn-close":"btn-close btn-close--solo",onClick:()=>{this.opened=!1,this.ezClosePopup.emit()}}))),o("div",{class:"popup__expandable-content"},o("slot",null)))))):void 0)}static get watchers(){return{opened:["observeConfig"]}}};p.style=':host{display:flex;--ez-popup-z-index:var(--elevation--24, 24);--ez-popup__container--color:var(--title--primary, #2b3a54);--ez-popup__container--padding:var(--space--large, 24px);--ez-popup__header--padding-bottom:var(--space--medium, 12px);--ez-popup__title--font-family:var(--font-pattern, "Roboto");--ez-popup__title--font-size:var(--title--extra-large, 24px);--ez-popup__title--color:var(--title--primary, #2b3a54);--ez-popup__title--font-weight:var(--text-weight--large, 600);--ez-popup__btn__close--icon-color:var(--title--primary, #2b3a54);--ez-popup__btn__close--icon:url(\'data:image/svg+xml;utf8,<svg width="14" height="14" viewBox="0 0 14 14" xmlns="http://www.w3.org/2000/svg"><path d="M 8.2421753,6.9944578 13.743748,1.4930784 C 13.907781,1.3290628 14,1.1065946 14,0.87462511 14,0.64266712 13.907782,0.42019873 13.743748,0.25617155 13.579712,0.09215597 13.35727,6.48e-8 13.125266,6.48e-8 12.89338,6.48e-8 12.670821,0.09215634 12.506787,0.25617155 L 7.005215,5.7575508 1.5035972,0.25617155 C 1.3395631,0.09215597 1.1170968,6.48e-8 0.88511716,6.48e-8 0.65314917,6.48e-8 0.4306712,0.09215597 0.26663695,0.25617155 0.10260271,0.42019873 0.01045441,0.64266712 0.01045441,0.87462511 c 0,0.23196949 0.0921483,0.45443769 0.25618254,0.61845329 L 5.7682546,6.9944578 0.26663695,12.497027 c -0.0834745,0.08067 -0.15003245,0.1772 -0.19581514,0.283871 C 0.02505077,12.887561 9.831648e-4,13.002399 2.950369e-5,13.118395 -9.2415746e-4,13.234504 0.02125019,13.349689 0.06527245,13.457057 c 0.04401053,0.107479 0.10898307,0.205064 0.1911168,0.287137 0.0821454,0.08208 0.17979645,0.146888 0.28727561,0.190839 0.10747906,0.04395 0.22262954,0.06598 0.33872417,0.06493 0.116095,-10e-4 0.23082547,-0.0253 0.33747687,-0.07112 0.1066637,-0.04593 0.2031133,-0.112615 0.2837313,-0.196086 L 7.005215,8.2313646 12.506787,13.732768 c 0.164034,0.164027 0.386593,0.256125 0.618479,0.256125 0.232004,0 0.454446,-0.09209 0.618482,-0.256125 C 13.907781,13.568741 14,13.346308 14,13.114315 14,12.882323 13.90779,12.659888 13.743748,12.495861 Z"/></svg>\')}.overlay{position:fixed;display:flex;top:0px;z-index:var(--ez-popup-z-index, 24);left:0px;width:100%;align-items:center;justify-content:center;box-sizing:border-box;height:100vh;backdrop-filter:blur(4px);background:rgba(0, 4, 12, 0.4)}.popup{display:flex;height:100%;align-items:center;justify-content:center;box-sizing:border-box}.popup__container{width:100%;max-height:90%;height:100%;display:flex;flex-wrap:wrap;overflow:hidden;outline:none;background:#FFFF;color:var(--ez-popup__container--color);border-radius:12px;box-shadow:0px 0px 16px rgba(0, 38, 111, 0.122);box-sizing:border-box;padding:var(--ez-popup__container--padding)}.popup__container--auto{height:auto}.popup__content{box-sizing:border-box;
|
|
1
|
+
import{r as t,c as i,h as o,F as e,H as l}from"./p-23a36bb6.js";import{FloatingManager as d}from"@sankhyalabs/core";const p=class{constructor(o){t(this,o),this.ezClosePopup=i(this,"ezClosePopup",7),this._sizeClasses={"x-small":"col--sd-3 ez-popup__size-limit--x-small",small:"col--sd-5",medium:"col--sd-6",large:"col--sd-9","x-large":"col--sd-11",default:"ez-popup__size-limit--x-small"},this.size="medium",this.opened=!1,this.useHeader=!0,this.heightMode="full",this.ezTitle=void 0}observeConfig(){this.manageOverflow()}manageOverflow(){window.document.body.style.overflow=this.opened?"hidden":""}manageOverlay(){this.opened?this._overlayId=d.subscribeOverlayControl(this._modalRef):d.unsubscribeOverlayControl(this._modalRef||this._overlayId)}getGridSize(){return this._sizeClasses[this.size]||this._sizeClasses.medium}componentDidRender(){this._container&&this._container.focus(),this.manageOverlay()}render(){return o(l,null,this.opened?o("div",{class:"overlay",ref:t=>this._modalRef=t},o("div",{class:"popup col "+this.getGridSize()},o("div",{class:"popup__container "+("auto"===this.heightMode?"popup__container--auto":""),ref:t=>this._container=t,tabIndex:-1},o("div",{class:"popup__content"},o("div",{class:"popup__header "+(this.useHeader?"popup__header--padding":"")},this.useHeader&&o(e,null,!!this.ezTitle&&o("div",{class:"popup__title"},this.ezTitle),o("button",{class:this.ezTitle?"btn-close":"btn-close btn-close--solo",onClick:()=>{this.opened=!1,this.ezClosePopup.emit()}}))),o("div",{class:"popup__expandable-content"},o("slot",null)))))):void 0)}static get watchers(){return{opened:["observeConfig"]}}};p.style=':host{display:flex;--ez-popup-z-index:var(--elevation--24, 24);--ez-popup__container--color:var(--title--primary, #2b3a54);--ez-popup__container--padding:var(--space--large, 24px);--ez-popup__header--padding-bottom:var(--space--medium, 12px);--ez-popup__title--font-family:var(--font-pattern, "Roboto");--ez-popup__title--font-size:var(--title--extra-large, 24px);--ez-popup__title--color:var(--title--primary, #2b3a54);--ez-popup__title--font-weight:var(--text-weight--large, 600);--ez-popup__btn__close--icon-color:var(--title--primary, #2b3a54);--ez-popup__btn__close--icon:url(\'data:image/svg+xml;utf8,<svg width="14" height="14" viewBox="0 0 14 14" xmlns="http://www.w3.org/2000/svg"><path d="M 8.2421753,6.9944578 13.743748,1.4930784 C 13.907781,1.3290628 14,1.1065946 14,0.87462511 14,0.64266712 13.907782,0.42019873 13.743748,0.25617155 13.579712,0.09215597 13.35727,6.48e-8 13.125266,6.48e-8 12.89338,6.48e-8 12.670821,0.09215634 12.506787,0.25617155 L 7.005215,5.7575508 1.5035972,0.25617155 C 1.3395631,0.09215597 1.1170968,6.48e-8 0.88511716,6.48e-8 0.65314917,6.48e-8 0.4306712,0.09215597 0.26663695,0.25617155 0.10260271,0.42019873 0.01045441,0.64266712 0.01045441,0.87462511 c 0,0.23196949 0.0921483,0.45443769 0.25618254,0.61845329 L 5.7682546,6.9944578 0.26663695,12.497027 c -0.0834745,0.08067 -0.15003245,0.1772 -0.19581514,0.283871 C 0.02505077,12.887561 9.831648e-4,13.002399 2.950369e-5,13.118395 -9.2415746e-4,13.234504 0.02125019,13.349689 0.06527245,13.457057 c 0.04401053,0.107479 0.10898307,0.205064 0.1911168,0.287137 0.0821454,0.08208 0.17979645,0.146888 0.28727561,0.190839 0.10747906,0.04395 0.22262954,0.06598 0.33872417,0.06493 0.116095,-10e-4 0.23082547,-0.0253 0.33747687,-0.07112 0.1066637,-0.04593 0.2031133,-0.112615 0.2837313,-0.196086 L 7.005215,8.2313646 12.506787,13.732768 c 0.164034,0.164027 0.386593,0.256125 0.618479,0.256125 0.232004,0 0.454446,-0.09209 0.618482,-0.256125 C 13.907781,13.568741 14,13.346308 14,13.114315 14,12.882323 13.90779,12.659888 13.743748,12.495861 Z"/></svg>\')}.overlay{position:fixed;display:flex;top:0px;z-index:var(--ez-popup-z-index, 24);left:0px;width:100%;align-items:center;justify-content:center;box-sizing:border-box;height:100vh;backdrop-filter:blur(4px);background:rgba(0, 4, 12, 0.4)}.popup{display:flex;height:100%;align-items:center;justify-content:center;box-sizing:border-box}.popup__container{width:100%;max-height:90%;height:100%;display:flex;flex-wrap:wrap;overflow:hidden;outline:none;background:#FFFF;color:var(--ez-popup__container--color);border-radius:12px;box-shadow:0px 0px 16px rgba(0, 38, 111, 0.122);box-sizing:border-box;padding:var(--ez-popup__container--padding)}.popup__container--auto{height:auto}.popup__content{box-sizing:border-box;height:100%;width:100%}.popup__expandable-content{box-sizing:border-box;width:100%;height:calc(100% - 44px)}.popup__header{width:100%;display:flex}.popup__header--padding{padding-bottom:var(--ez-popup__header--padding-bottom)}.popup__title{display:flex;margin:0;width:100%;font-family:var(--ez-popup__title--font-family);font-size:var(--ez-popup__title--font-size);font-weight:var(--ez-popup__title--font-weight);color:var(--ez-popup__title--color);line-height:1.3}.btn-close{justify-content:flex-end;align-self:flex-start;align-items:flex-start;display:flex;outline:none;border:none;background-color:unset;cursor:pointer}.btn-close::after{content:\'\';display:flex;background-color:var(--ez-popup__btn__close--icon-color);width:14px;height:14px;-webkit-mask-image:var(--ez-popup__btn__close--icon);mask-image:var(--ez-popup__btn__close--icon)}.btn-close--solo{width:100%}.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}.ez-popup__size-limit--x-small{min-width:350px;max-width:560px}@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%}}';export{p as ez_popup}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as i,h as e,H as s,g as n}from"./p-23a36bb6.js";import{DateUtils as a,TimeFormatter as o,ElementIDUtils as h}from"@sankhyalabs/core";import{C as r}from"./p-
|
|
1
|
+
import{r as t,c as i,h as e,H as s,g as n}from"./p-23a36bb6.js";import{DateUtils as a,TimeFormatter as o,ElementIDUtils as h}from"@sankhyalabs/core";import{C as r}from"./p-9e11fc7b.js";const l=class{constructor(e){t(this,e),this.ezChange=i(this,"ezChange",7),this.ezStartChange=i(this,"ezStartChange",7),this.ezCancelWaitingChange=i(this,"ezCancelWaitingChange",7),this._changePending=!1,this._focused=!1,this._valuePromiseCallbacks=[],this.label=void 0,this.value=void 0,this.enabled=!0,this.errorMessage=void 0,this.showSeconds=!1,this.mode="regular",this.canShowError=!0}observeLabel(){this._textInput&&(this._textInput.label=this.label)}observeErrorMessage(){var t;this._textInput&&(this._textInput.errorMessage=this.errorMessage,(null===(t=this.errorMessage)||void 0===t?void 0:t.trim())||this.setInputValue())}observeValue(t,i){if(this._textInput&&t!=i){const e=a.validateDate(t,!0),s=a.validateDate(i,!0);if((null==e?void 0:e.getTime())!==(null==s?void 0:s.getTime())){const t=this.getTextValue(e)||"";!this.getParsedDateTime(t)&&this._focused||(this._textInput.value||"")===t||(this._textInput.value=t,this._focused=!1,this.errorMessage=""),this.ezChange.emit(null===e?void 0:e)}}this._changePending=!1}async setFocus(){this._textInput.setFocus()}async setBlur(){this._textInput.setBlur()}async isInvalid(){return"string"==typeof this.errorMessage&&""!==this.errorMessage.trim()}async getValueAsync(){return this._changePending?new Promise((t=>{this._valuePromiseCallbacks.push(t)})):Promise.resolve(this.value)}handleKeyDown(t){const i=this._textInput.shadowRoot.querySelector("input");if(t.shiftKey&&"Tab"===t.key){if(i.selectionStart>0){let e=i.value.lastIndexOf(" ",i.selectionStart);-1!==e&&(i.setSelectionRange(0,e),t.preventDefault())}}else if("Tab"===t.key&&i.value.length!==i.selectionEnd){let e=i.value.indexOf(" ",i.selectionEnd);e=-1===e?i.selectionEnd:e+1,i.setSelectionRange(e,i.value.length),t.preventDefault()}}handleFocus(){const t=this._textInput.shadowRoot.querySelector("input");if(t.selectionStart!==t.selectionEnd){let i=t.value.indexOf(" ",t.selectionStart);i=-1===i?t.value.length:i,t.setSelectionRange(0,i)}}handleClick(){const t=this._textInput.shadowRoot.querySelector("input");let i=t.value.lastIndexOf(" ",t.selectionEnd);i=-1===i?0:i+1,i=i>t.selectionEnd?0:i;let e=0===i?t.value.indexOf(" "):t.value.length;t.setSelectionRange(i,e)}changeValue(t){const i=a.validateDate(this.value,!0),e=a.validateDate(t,!0);(null==i?void 0:i.getTime())!==(null==e?void 0:e.getTime())&&(this.value=e)}showCalendar(){let t;this.isFixed()?(t=29,this._calendar.fitHorizontal(0)):t=this.errorMessage||"slim"===this.mode?6:-13,this._calendar.fitVertical(t,this._elem.clientHeight),this._calendar.style.visibility="inherit"}hideCalendar(){this.changeValue(this._calendar.value),this._calendar.hide()}getParsedDateTime(t){var i,e;if(void 0===t&&(t=(null===(e=null===(i=this._textInput)||void 0===i?void 0:i.value)||void 0===e?void 0:e.trim())||""),!t)return;const s=t.split(" "),n=s.length>0?s[0]:t,h=o.prepareValue(s[1]?s[1]:"",this.showSeconds);return a.strToDate(n+(h&&" "+h))}handleBlur(){var t,i;if(this._changePending)try{const e=(null===(i=null===(t=this._textInput)||void 0===t?void 0:t.value)||void 0===i?void 0:i.trim())||"",s=this.getParsedDateTime();if(s||!e){this.errorMessage="";const t=a.validateDate(this.value,!0),i=a.validateDate(s,!0);(null==t?void 0:t.getTime())===(null==i?void 0:i.getTime())?(i&&(this._textInput.value=this.getTextValue(i)||"",this._focused=!1),this.ezCancelWaitingChange.emit()):this.changeValue(i)}else this.changeValue(void 0),this.ezCancelWaitingChange.emit(),this.errorMessage="O valor digitado não é uma data válida"}finally{for(const t of this._valuePromiseCallbacks)t(this.value);this._valuePromiseCallbacks=[]}}getTextValue(t){if(t)return a.formatDateTime(t,this.showSeconds)}handleInput(t){const i=this.getParsedDateTime(),e=a.validateDate(this.value,!0),s=a.validateDate(i,!0);(null==e?void 0:e.getTime())!==(null==s?void 0:s.getTime())&&(this._changePending=!0,this._focused=!0,this.ezStartChange.emit({waitmessage:"",blocking:!1})),"H"!==t.data&&"h"!==t.data||this.changeValue(new Date)}setInputValue(){const t=this.getTextValue(this.value)||"";(this._textInput.value||"")!==t&&(this._textInput.value=t)}isFixed(){return"true"===this._elem.dataset.isFixed}componentDidLoad(){r.applyVarsTextInput(this._elem,this._textInput),this.setInputValue()}render(){return h.addIDInfoIfNotExists(this._elem,"input"),e(s,null,e("ez-text-input",{"data-element-id":h.getInternalIDInfo("textInput"),ref:t=>this._textInput=t,"data-slave-mode":"true",label:this.label,restrict:"0123456789/: ",enabled:this.enabled,errorMessage:this.errorMessage,mode:this.mode,onKeyDown:t=>{this.handleKeyDown(t)},onBlur:()=>this.handleBlur(),onInput:t=>this.handleInput(t),onFocus:()=>this.handleFocus(),onClick:()=>this.handleClick(),canShowError:this.canShowError},e("button",{disabled:!this.enabled,tabindex:-1,class:"btn-open-cal",onClick:()=>this.showCalendar(),slot:"leftIcon"})),e("ez-calendar",{ref:t=>this._calendar=t,"data-element-id":h.getInternalIDInfo("calendar"),onEzChange:t=>{this.hideCalendar(),t.stopPropagation()},floating:!0,time:!0,showSeconds:this.showSeconds,"data-is-fixed":this._elem.dataset.isFixed}))}get _elem(){return n(this)}static get watchers(){return{label:["observeLabel"],errorMessage:["observeErrorMessage"],value:["observeValue"]}}};l.style=':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)}';export{l as ez_date_time_input}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as s,h as i,g as e}from"./p-23a36bb6.js";import{NumberUtils as h,ElementIDUtils as r}from"@sankhyalabs/core";import{C as o}from"./p-
|
|
1
|
+
import{r as t,c as s,h as i,g as e}from"./p-23a36bb6.js";import{NumberUtils as h,ElementIDUtils as r}from"@sankhyalabs/core";import{C as o}from"./p-9e11fc7b.js";const a=class{constructor(i){t(this,i),this.ezChange=s(this,"ezChange",7),this.ezStartChange=s(this,"ezStartChange",7),this.ezCancelWaitingChange=s(this,"ezCancelWaitingChange",7),this._focused=!1,this._changePending=!1,this._valuePromiseCallbacks=[],this.label=void 0,this.value=void 0,this.enabled=!0,this.canShowError=!0,this.errorMessage=void 0,this.precision=void 0,this.prettyPrecision=void 0,this.mode="regular"}async setFocus(t){this._textInput.setFocus(t)}async setBlur(){this._textInput.setBlur()}async isInvalid(){return"string"==typeof this.errorMessage&&""!==this.errorMessage.trim()}async getValueAsync(){return this._changePending?new Promise((t=>{this._valuePromiseCallbacks.push(t)})):Promise.resolve(this.value)}observeLabel(){this._textInput&&(this._textInput.label=this.label)}observeErrorMessage(){var t;this._textInput&&(this._textInput.errorMessage=this.errorMessage,(null===(t=this.errorMessage)||void 0===t?void 0:t.trim())||this.setInputValue())}observeValue(t,s){if(this._textInput&&t!=s){const i=this.validateValue(t),e=this.validateValue(s);if(null===i&&(this._textInput.value=""),i!=e){const t=this.getTextValue(i)||"";(this._textInput.value||"")!==t&&(void 0===this.getParsedNumber(t)&&this._focused||(this._textInput.value=t,this._focused=!1,this.errorMessage="")),this.ezChange.emit(null===i?void 0:i)}}this._changePending=!1}validateValue(t){return isNaN(t)||void 0===t?null:t}getTextValue(t){if(null!=t)return this.precision>0?h.format(t.toString(),Number(this.precision),Number(this.prettyPrecision)):t.toString()}changeValue(t){this.errorMessage="",this.value!=t?this.value=void 0===t?null:t:(this.setInputValue(),this.ezCancelWaitingChange.emit())}setError(t){this.value=null,this.errorMessage=t,this.ezCancelWaitingChange.emit()}handleBlur(){if(this._changePending)try{const t=this.getParsedNumber();if(void 0!==t&&isNaN(t))this.setError("O valor digitado não é um número válido");else try{this.changeValue(t)}catch(t){return void this.setError(t.message)}}finally{for(const t of this._valuePromiseCallbacks)t(this.value);this._valuePromiseCallbacks=[]}}handleInput(){this.getParsedNumber()!==this.value&&(this._focused=!0,this._changePending=!0,this.ezStartChange.emit({waitmessage:"",blocking:!1}))}getParsedNumber(t){var s;return void 0===t&&(t=null===(s=this._textInput)||void 0===s?void 0:s.value),(null==t?void 0:t.trim())?h.stringToNumber(t):void 0}setInputValue(){const t=this.getTextValue(this.value)||"";(this._textInput.value||"")!==t&&(this._textInput.value=t)}componentDidLoad(){o.applyVarsTextInput(this._elem,this._textInput),this.setInputValue()}render(){return r.addIDInfoIfNotExists(this._elem,"input"),i("ez-text-input",{class:"number__input","data-element-id":r.getInternalIDInfo("textInput"),ref:t=>this._textInput=t,"data-slave-mode":"true",label:this.label,onBlur:()=>this.handleBlur(),onInput:()=>this.handleInput(),restrict:this.precision>0?"0123456789-,.":"0123456789-",enabled:this.enabled,errorMessage:this.errorMessage,mode:this.mode,canShowError:this.canShowError})}get _elem(){return e(this)}static get watchers(){return{label:["observeLabel"],errorMessage:["observeErrorMessage"],value:["observeValue"]}}};a.style=":host{display:block;width:100%}.number__input{height:100%}";export{a as ez_number_input}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as o,h as i,g as e}from"./p-23a36bb6.js";import{ElementIDUtils as n}from"@sankhyalabs/core";const r=class{constructor(i){t(this,i),this.buttonClick=o(this,"buttonClick",7),this.dropdownItemClick=o(this,"dropdownItemClick",7),this.dropdownSubActionClick=o(this,"dropdownSubActionClick",7),this.rightDefaultTitle="Mais opções",this.show=!1,this.enabled=!0,this.iconName=void 0,this.image=void 0,this.items=void 0,this.label=void 0,this.leftTitle=void 0,this.rightTitle="Mais opções",this.mode="default",this.size="medium"}async setBlur(){this.leftButton.blur(),this.rightButton.blur()}async setLeftButtonFocus(){this.leftButton.focus()}async setRightButtonFocus(){this.rightButton.focus()}clickListener(t){this.enabled||(t.preventDefault(),t.stopPropagation(),t.stopImmediatePropagation())}getIconSize(t="medium"){var o;const i=null===(o=this.size)||void 0===o?void 0:o.toLowerCase();return["medium","large"].includes(i)?i:t}closeDropdown(){this.show=!1}toggleDropdown(){this.show=!this.show}handleButtonClick(){this.buttonClick.emit()}handleDropdownItemClick(t){this.dropdownItemClick.emit(t.detail),t.stopPropagation(),this.closeDropdown()}handleDropdownSubActionClick(t){this.dropdownSubActionClick.emit(t.detail),t.stopPropagation(),this.closeDropdown()}positionDropdown(){const{rightButton:t,dropdownParent:o}=this,i=t.getBoundingClientRect(),e=o.getBoundingClientRect(),n=window.innerHeight-i.bottom,r=i.top,l=window.innerWidth-i.right<e.width&&i.left>e.width;let s=`${i.bottom+window.scrollY}px`,d=`${i.left+window.scrollX}px`,a="auto";n<e.height&&r>e.height&&(a=window.innerHeight-i.top-window.scrollY+"px",s="auto",o.style.maxHeight=`${r}px`),l&&(d=`${i.right-e.width+window.scrollX}px`),o.style.top=s,o.style.bottom=a,o.style.left=d}setEvents(){window.removeEventListener("scroll",this.positionDropdown.bind(this)),window.addEventListener("scroll",this.positionDropdown.bind(this))}componentWillLoad(){this.setEvents()}componentDidLoad(){this._element&&n.addIDInfo(this._element),this.leftButton&&n.addIDInfo(this.leftButton,"left-button",{id:"embedded"}),this.rightButton&&n.addIDInfo(this.rightButton,"right-button",{id:"embedded"}),this.positionDropdown()}componentDidUpdate(){this.positionDropdown()}render(){const t=this.shouldShowIconOnLeftButton(),o=this.shouldShowLabelOnLeftButton(),e=this.getIconSize();return i("div",{class:"label-icon"},i("button",{class:`ez-split-button__left-button ${e} ${this.mode}`,title:this.leftTitle||this.label,type:"button",disabled:!this.enabled,onClick:()=>{this.handleButtonClick()},ref:t=>this.leftButton=t},t&&i("ez-icon",{href:this.image,iconName:this.iconName,size:e}),o&&i("label",{title:this.leftTitle||this.label},this.label)),i("div",{class:"dropdown"},i("button",{class:`ez-split-button__right-button ${e} ez-split-button__right-button--${e} ez-split-button__right-button--divider`,title:this.rightTitle||this.rightDefaultTitle,type:"button",disabled:!this.enabled,onClick:()=>{this.toggleDropdown()},ref:t=>this.rightButton=t},i("ez-icon",{class:"ez-split-button__right-button-container "+(e?`btn-icon--${e}`:""),iconName:"chevron-down",size:e})),i("div",{class:`dropdown-content dropdown-content--${this.size}`,ref:t=>this.dropdownParent=t},this.show&&i("ez-dropdown",{items:this.items,onClick:t=>{t.stopPropagation()},onEzOutsideClick:()=>{this.closeDropdown()},onEzClick:t=>{this.handleDropdownItemClick(t)},onEzSubActionClick:t=>{this.handleDropdownSubActionClick(t)}}))))}shouldShowLabelOnLeftButton(){return["icon-left","default"].includes(this.mode)}shouldShowIconOnLeftButton(){return["icon-left","icon-only"].includes(this.mode)}get _element(){return e(this)}};r.style=":host{--ez-split-button--min-width:24;--ez-split-button--width:'auto';--ez-split-button__medium--height:32px;--ez-split-button__large--height:42px;--ez-split-button__medium-icon--width:40px;--ez-split-button__large-icon--width:44px;--ez-split-button__inline__icon--gap:6px;--ez-split-button__label--padding-top:0px;--ez-split-button__label--padding-bottom:0px;--ez-split-button__right-button--padding-left:8px;--ez-split-button--color:var(--title--primary, #FFF);--ez-split-button--font-size:var(--text--medium, 14px);--ez-split-button--font-family:var(--font-pattern, Arial);--ez-split-button--font-weight:var(--text-weight--large);--ez-split-button--background-color:var(--background--medium, #008561);--ez-split-button--border-radius:var(--border--radius-large, 12px);--ez-split-button--border:none;--ez-split-button--justify-content:center;--ez-split-button--hover-color:var(--color--primary-600);--ez-split-button--hover--background-color:var(--background--medium, var(--ez-split-button--background-color));--ez-split-button--disabled-color:var(--text--disable);--ez-split-button--disabled--background-color:var(--color--disable-secondary);--ez-split-button--focus--border:var(--border--medium, 2px) var(--color--primary-300);--ez-split-button--focus--box-shadow:none;--ez-split-button--active-color:var(--color--primary-700);--ez-split-button--active--background-color:var(--background--strong)}ez-icon{--ez-icon--color:inherit}button{position:relative;display:flex;align-items:center;margin:0;cursor:pointer;transition:background-color 0.2s linear;white-space:nowrap;min-width:var(--ez-split-button--min-width);width:var(--ez-split-button--width);height:var(--ez-split-button__medium--height);font-family:var(--ez-split-button--font-family);font-size:var(--ez-split-button--font-size);font-weight:var(--ez-split-button--font-weight);padding:var(--ez-split-button__label--padding-top) 0 var(--ez-split-button__label--padding-bottom) 0;border-top-left-radius:var(--ez-split-button--border-radius);border-bottom-left-radius:var(--ez-split-button--border-radius);background-color:var(--ez-split-button--background-color);color:var(--ez-split-button--color);fill:var(--ez-split-button--color);border:var(--ez-split-button--border);justify-content:var(--ez-split-button--justify-content)}label{cursor:pointer}button:active{outline:none;box-shadow:none;background-color:var(--ez-split-button--active--background-color);color:var(--ez-split-button--active-color);fill:var(--ez-split-button--active-color);--ez-icon--color:var(--ez-split-button--active-color)}.ez-split-button__left-button:focus,.ez-split-button__right-button:focus{outline:var(--ez-split-button--focus--border);box-shadow:var(--ez-split-button--focus--box-shadow)}.ez-split-button__left-button:hover,.ez-split-button__right-button:hover{outline:none;background-color:var(--ez-split-button--hover--background-color);color:var(--ez-split-button--hover-color);fill:var(--ez-split-button--hover-color);--ez-icon--color:var(--ez-split-button--hover-color)}.ez-split-button__left-button:disabled,.ez-split-button__left-button:disabled label,.ez-split-button__right-button:disabled{background-color:var(--ez-split-button--disabled--background-color);color:var(--ez-split-button--disabled-color);fill:var(--ez-split-button--disabled-color);border:none;--ez-icon--color:var(--ez-split-button--disabled-color);cursor:not-allowed}button.large{height:var(--ez-split-button__large--height)}button.medium{height:var(--ez-split-button__medium--height)}.default label{padding:var(--ez-split-button__label--padding-top) 12px var(--ez-split-button__label--padding-bottom) 20px}.icon-left{gap:var(--ez-split-button__inline__icon--gap)}.icon-left label{padding-right:12px}.icon-left ez-icon{padding-left:20px}.icon-only{padding-left:12px;padding-right:12px}.ez-split-button__right-button{border-top-right-radius:var(--ez-split-button--border-radius);border-bottom-right-radius:var(--ez-split-button--border-radius);border-top-left-radius:0;border-bottom-left-radius:0}.ez-split-button__right-button--medium{min-width:var(--ez-split-button__medium-icon--width)}.ez-split-button__right-button--large{min-width:var(--ez-split-button__large-icon--width)}.ez-split-button__right-button--divider{top:10%;bottom:10%}.ez-split-button__right-button--divider:before{content:\"\";position:absolute;left:0;border-left:1px solid rgba(0, 0, 0, 20%);border-radius:2px;height:75%}.btn-icon--medium{min-width:--ez-split-button__medium-icon--width}.btn-icon--large{min-width:--ez-split-button__large-icon--width}.ez-split-button__right-button-container{position:absolute;left:0;padding-left:var(--ez-split-button__right-button--padding-left)}.label-icon{display:flex;flex-direction:row;align-items:center;color:var(--ez-split-button--color)}.label-icon:active{color:var(--ez-split-button--active-color);fill:var(--ez-split-button--active-color);--ez-icon--color:var(--ez-split-button--active-color)}.dropdown{display:flex}.dropdown-content{display:block;position:absolute;background-color:#f1f1f1;min-width:160px;z-index:--ez-elevation--8;border-radius:var(--ez-split-button--border-radius)}.dropdown-content>ez-dropdown{position:relative}";export{r as ez_split_button}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as e,r as a,c as t,g as l,H as r}from"./p-23a36bb6.js";import{ObjectUtils as n,UserInterface as o,ElementIDUtils as i}from"@sankhyalabs/core";import{R as s}from"./p-05e1f4e7.js";import{C as d}from"./p-b853763b.js";function c(a,t,l,r,n){return e("div",{class:"ez-col ez-col--sd-12 ez-align--middle ez-padding-horizontal--small ez-padding-bottom--large"},e("ez-check",{enabled:!l,label:t,mode:n?d.SWITCH:d.REGULAR,"data-field-name":a,"data-context-name":r,key:a}))}function m(a,t,l,r,n,o,i){return e("div",{class:"ez-col ez-col--sd-12 ez-padding-horizontal--small"},e("ez-number-input",{enabled:!l,label:t,precision:r,prettyPrecision:n,"data-field-name":a,"data-context-name":o,key:a,canShowError:i}))}const h=({name:a,label:t,readOnly:l,contextName:r,canShowError:n})=>e("div",{class:"ez-col ez-col--sd-12 ez-padding-horizontal--small"},e("ez-text-input",{label:t,"data-field-name":a,"data-context-name":r,key:a,enabled:!l,canShowError:n})),p=new Map;p.set(o.CHECKBOX,(e=>c(e.name,e.label,e.readOnly,e.contextName,!1))),p.set(o.SWITCH,(e=>c(e.name,e.label,e.readOnly,e.contextName,!0))),p.set(o.OPTIONSELECTOR,(({name:a,label:t,readOnly:l,required:r,props:n,contextName:o,canShowError:i})=>{const s=null==n?void 0:n.options;let d;if("string"==typeof s){const e=JSON.parse(s);d=Object.keys(e).map((a=>({value:a,label:e[a]})))}else d=s;return e("div",{class:"ez-col ez-col--sd-12 ez-padding-horizontal--small"},e("ez-combo-box",{enabled:!l,suppressEmptyOption:r,label:t,"data-field-name":a,"data-context-name":o,key:a,options:d,canShowError:i}))})),p.set(o.DATE,(({name:a,label:t,readOnly:l,canShowError:r})=>e("div",{class:"ez-col ez-col--sd-12 ez-padding-horizontal--small"},e("ez-date-input",{enabled:!l,label:t,"data-field-name":a,key:a,canShowError:r})))),p.set(o.TIME,(({name:a,label:t,readOnly:l,canShowError:r})=>e("div",{class:"ez-col ez-col--sd-12 ez-padding-horizontal--small"},e("ez-time-input",{enabled:!l,label:t,"data-field-name":a,key:a,canShowError:r})))),p.set(o.DATETIME,(({name:a,label:t,readOnly:l,contextName:r,canShowError:n})=>e("div",{class:"ez-col ez-col--sd-12 ez-padding-horizontal--small"},e("ez-date-time-input",{enabled:!l,label:t,"data-field-name":a,"data-context-name":r,key:a,canShowError:n})))),p.set(o.FILE,(({name:a,label:t,readOnly:l,contextName:r,props:o})=>{const i=n.removeEmptyValues({subTitle:o.subTitle,requestHeaders:Object.assign(Object.assign({},o.STORAGESTRATEGY&&{STORAGESTRATEGY:o.STORAGESTRATEGY}),o.INTERNAL_FILENAME&&{INTERNAL_FILENAME:o.INTERNAL_FILENAME})});return e("div",{class:"ez-col ez-col--sd-12 ez-padding-horizontal--small"},e("ez-upload",Object.assign({enabled:!l,label:t,"data-field-name":a,"data-context-name":r,key:a},i)))})),p.set(o.DECIMALNUMBER,(({name:e,label:a,readOnly:t,props:l,contextName:r,canShowError:n})=>{const o=Number((null==l?void 0:l.precision)||2);return m(e,a,t,o,Number((null==l?void 0:l.prettyPrecision)||o),r,n)})),p.set(o.INTEGERNUMBER,(({name:e,label:a,readOnly:t,contextName:l,canShowError:r})=>m(e,a,t,0,0,l,r))),p.set(o.SEARCH,(({name:a,label:t,readOnly:l,required:r,contextName:n,canShowError:o,optionLoader:i})=>e("div",{class:"ez-col ez-col--sd-12 ez-padding-horizontal--small"},e("ez-search",{enabled:!l,suppressEmptyOption:r,label:t,"data-field-name":a,"data-context-name":n,key:a,canShowError:o,optionLoader:i})))),p.set(o.LONGTEXT,(({name:a,label:t,readOnly:l,contextName:r,rows:n,canShowError:o})=>e("div",{class:"ez-col ez-col--sd-12 ez-padding-horizontal--small",key:a},e("ez-text-area",{enabled:!l,label:t,"data-field-name":a,"data-context-name":r,rows:n,canShowError:o}))));class z{constructor(e){this.elem=e}addRightElement(e){this.removeRightElement(),e.classList.add("ez-padding-left--small"),e.setAttribute("data-custom-item","true"),this.elem.classList.add("ez-col--nowrap"),this.elem.appendChild(e)}removeRightElement(){Array.from(this.elem.querySelectorAll('[data-custom-item="true"]')).forEach((e=>e.remove()))}get fieldName(){return this.elem.getAttribute("data-form-item")}}class u{constructor(e,a){this.items=new Map,this.formId=a,e.forEach((e=>{const a=new z(e);this.items.set(a.fieldName,a)}))}getItem(e){return this.items.get(e)}get formName(){return this.formId}}const b=class{constructor(e){a(this,e),this.ezContentReady=t(this,"ezContentReady",7),this.formItemsReady=t(this,"formItemsReady",7),this.fields=void 0}async showUp(){this._element.scrollIntoView({behavior:"smooth",block:"start"})}groupFields(e){const a=new Map;return e.forEach((e=>{const t=e.group;if(t){let l=a.get(t);null==l&&(l=[],a.set(t,l)),l.push(e)}else a.set(e.name,e)})),a}componentDidRender(){this.ezContentReady.emit(Array.from(this._element.querySelectorAll("[data-field-name]")));const e=new u(Array.from(this._element.querySelectorAll("[data-form-item]")));this.formItemsReady.emit(e)}isItemFullWidth(e){return[o.FILE,o.LONGTEXT].includes(e)}buildFormItemElement(a,t=""){return this.isItemFullWidth(a.userInterface)&&(t+=" input-full_width"),e("div",{class:t},(e=>{const a=p.get(e.userInterface)||h,t=e.required?`${e.label}${s}`:e.label,l=a(Object.assign(Object.assign({},e),{label:t}));return l.t["data-form-item"]=e.name,l})(a))}render(){if(i.addIDInfoIfNotExists(this._element,"ezFormView"),null==this.fields)return;let a=[],t=Array.from(this.groupFields(this.fields).entries()).map((([t,l])=>{if(Array.isArray(l))return e("ez-collapsible-box",{id:`group-${t}`,label:t,"header-size":"large",key:t},e("div",{class:"form-view__content"},l.map((e=>this.buildFormItemElement(e)))));a.push(l)})),l=a.map((e=>this.buildFormItemElement(e))),n=e("div",{class:"form-view__content"},l);return e(r,null,n,t)}get _element(){return l(this)}};b.style=".sc-ez-form-view-h{display:flex;flex-wrap:wrap;width:100%;--ez-form-view__item--min-width:220px;--ez-form-view__item--sapce-width:5px}.form-view__content.sc-ez-form-view{display:grid;grid-template-columns:repeat(auto-fill, minmax(var(--ez-form-view__item--min-width), 1fr));gap:var(--ez-form-view__item--sapce-width);width:100%}.input-full_width.sc-ez-form-view{grid-column:1 / -1;width:100%}";export{b as ez_form_view}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as s,h as i,H as e,g as h}from"./p-23a36bb6.js";import{TimeFormatter as r,MaskFormatter as
|
|
1
|
+
import{r as t,c as s,h as i,H as e,g as h}from"./p-23a36bb6.js";import{TimeFormatter as r,MaskFormatter as o,NumberUtils as a,ElementIDUtils as n}from"@sankhyalabs/core";import{C as l}from"./p-9e11fc7b.js";const u=class{constructor(i){t(this,i),this.ezChange=s(this,"ezChange",7),this.ezStartChange=s(this,"ezStartChange",7),this.ezCancelWaitingChange=s(this,"ezCancelWaitingChange",7),this.label=void 0,this.value=void 0,this.enabled=!0,this.errorMessage=void 0,this.showSeconds=!1,this.mode="regular",this.canShowError=!0}observeErrorMessage(){var t;this._textInput&&(this._textInput.errorMessage=this.errorMessage,(null===(t=this.errorMessage)||void 0===t?void 0:t.trim())||(this.prepareValue(this._viewValue),(this._textInput.value||"")!==this._viewValue&&(this._textInput.value=this._viewValue)))}observeShowSeconds(){this.prepareMask(this.showSeconds?"##:##:##":"##:##")}observeValue(t,s){if(this._textInput&&t!=s){let i=this.validateValue(t);i!=this.validateValue(s)&&(this._viewValue=null==i?"":i.toString(),this.prepareValue(this._viewValue),this._viewValue&&!r.validateTime(this._viewValue,this.showSeconds)?(this.setError("Favor inserir um horário válido."),i=void 0):this.setError(""),this.ezChange.emit(null===i?void 0:i))}}prepareMask(t){null==this._maskFormatter?this._maskFormatter=new o(t):this._maskFormatter.mask=t}validateValue(t){return isNaN(t)||void 0===t?null:t}setError(t){this.errorMessage=t,this._textInput&&(null==t?void 0:t.trim())&&this.ezCancelWaitingChange.emit()}getViewValue(){return this._viewValue}prepareValue(t){try{this._viewValue=r.prepareValue(t,this.showSeconds),this._textInput&&this._textInput.value!==this._viewValue&&(this._textInput.value=this._viewValue)}catch(t){this.setError(t.message)}}async setFocus({selectText:t}){this._textInput.setFocus({selectText:t})}async setBlur(){this._textInput.setBlur()}async isInvalid(){return"string"==typeof this.errorMessage&&""!==this.errorMessage.trim()}handleBlur(){if(this._textInput){this._viewValue=this._textInput.value,this.prepareValue(this._viewValue);const t=a.stringToNumber(this._viewValue.replace(/\D/g,""));this.value=["string","number"].includes(typeof t)?t:null}}handleInput(){const t=this._textInput.value;["string","number"].includes(typeof t)&&a.stringToNumber(t.replace(/\D/g,""))!==this.value&&this.ezStartChange.emit({waitmessage:"",blocking:!1})}componentDidLoad(){l.applyVarsTextInput(this._elem,this._textInput)}componentWillLoad(){this.observeShowSeconds(),this.value?this.prepareValue(this.value.toString()):this._viewValue&&this.prepareValue(this._viewValue)}render(){return n.addIDInfoIfNotExists(this._elem,"input"),i(e,null,i("ez-text-input",{class:"time__input","data-element-id":n.getInternalIDInfo("textInput"),ref:t=>this._textInput=t,"data-slave-mode":"true",value:this._viewValue,enabled:this.enabled,label:this.label,restrict:"0123456789:",onBlur:()=>this.handleBlur(),onInput:()=>this.handleInput(),errorMessage:this.errorMessage,mode:this.mode,canShowError:this.canShowError},i("ez-icon",{slot:"leftIcon",iconName:"timer-outline"})))}static get assetsDirs(){return["../assets"]}get _elem(){return h(this)}static get watchers(){return{errorMessage:["observeErrorMessage"],showSeconds:["observeShowSeconds"],value:["observeValue"]}}};u.style=":host{display:flex;flex-wrap:wrap;position:relative;width:100%}.time__input{height:100%}";export{u as ez_time_input}
|
|
@@ -20,6 +20,10 @@ export declare class EzCardItem {
|
|
|
20
20
|
* `{title: string, key: string, details: any}`.
|
|
21
21
|
*/
|
|
22
22
|
item: CardItem;
|
|
23
|
+
/**
|
|
24
|
+
* Determina se a chave do item deve ser exibida.
|
|
25
|
+
*/
|
|
26
|
+
enableKey: boolean;
|
|
23
27
|
/**
|
|
24
28
|
* Emitido sempre que o ez-card é clicado.
|
|
25
29
|
*/
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { EventEmitter } from '../../stencil-public-runtime';
|
|
2
2
|
import { IFormViewField } from './interfaces/IFormViewField';
|
|
3
|
+
import { UserInterface } from '@sankhyalabs/core';
|
|
3
4
|
import { FormItems } from './structure';
|
|
4
5
|
export declare class EzFormView {
|
|
5
6
|
_element: HTMLEzFormViewElement;
|
|
@@ -18,5 +19,7 @@ export declare class EzFormView {
|
|
|
18
19
|
showUp(): Promise<void>;
|
|
19
20
|
private groupFields;
|
|
20
21
|
componentDidRender(): void;
|
|
22
|
+
isItemFullWidth(userInterface: UserInterface): boolean;
|
|
23
|
+
buildFormItemElement(item: IFormViewField, classItem?: string): any;
|
|
21
24
|
render(): any;
|
|
22
25
|
}
|
|
@@ -109,6 +109,7 @@ export default interface EzGridController {
|
|
|
109
109
|
locateColumn(columnName: string): void;
|
|
110
110
|
configFilterColumn(filterColumn: FilterCollumn): any;
|
|
111
111
|
getFilter(): Array<Filter> | undefined;
|
|
112
|
+
clearFilter(): void;
|
|
112
113
|
}
|
|
113
114
|
/**
|
|
114
115
|
* Carrega as informações necessárias para contextualizar corretamente a instância.
|
|
@@ -32,6 +32,7 @@ export default class AgGridController implements EzGridController, SortingProvid
|
|
|
32
32
|
private _editionManager;
|
|
33
33
|
configFilterColumn(filterColumn: HTMLFilterColumnElement): void;
|
|
34
34
|
private handleFilteredColumnsChanged;
|
|
35
|
+
clearFilter(): void;
|
|
35
36
|
private showFilterColumn;
|
|
36
37
|
constructor(enterprise: boolean);
|
|
37
38
|
getGridConfig(): Array<EzGridColumnConfig>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { DUActionInterceptor, DataUnitAction } from "@sankhyalabs/core";
|
|
2
|
+
import EzGridController from "../EzGridController";
|
|
3
|
+
export declare class DataSourceInterceptor implements DUActionInterceptor {
|
|
4
|
+
private _controller;
|
|
5
|
+
constructor(controller: EzGridController);
|
|
6
|
+
private clearColumnFilter;
|
|
7
|
+
interceptAction(action: DataUnitAction): DataUnitAction | Promise<DataUnitAction>;
|
|
8
|
+
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { DataUnit } from '@sankhyalabs/core';
|
|
2
2
|
import { EventEmitter } from '../../stencil-public-runtime';
|
|
3
|
+
import { IRecordValidator } from '../../utils/form/interfaces';
|
|
3
4
|
import { IMultiSelectionListDataSource } from '../ez-multi-selection-list/interfaces/IMultiSelectionListDataSource';
|
|
4
|
-
import { EzGridColumn, EzGridColumnConfig,
|
|
5
|
+
import { EzGridColumStateEvent, EzGridColumn, EzGridColumnConfig, IGridConfig, IStatusResolver, StatusResolverFunction } from './controller/EzGridController';
|
|
5
6
|
import { ISelection, ISelectionToastConfig } from './interfaces';
|
|
6
|
-
import { IRecordValidator } from '../../utils/form/interfaces';
|
|
7
7
|
export declare class EzGrid {
|
|
8
8
|
private _container;
|
|
9
9
|
private _refPaginationControl;
|
|
@@ -13,6 +13,9 @@ export declare class EzGrid {
|
|
|
13
13
|
private _messageFilterAppliedSuccess;
|
|
14
14
|
private _gridApi;
|
|
15
15
|
private _filterColumn;
|
|
16
|
+
private _refPaginationLabel;
|
|
17
|
+
private _refPaginationLabelTooltip;
|
|
18
|
+
private _headerOverflowWatcher;
|
|
16
19
|
_element: HTMLElement;
|
|
17
20
|
private _paginationInfo;
|
|
18
21
|
private _paginationChangedByKeyboard;
|
|
@@ -123,6 +126,7 @@ export declare class EzGrid {
|
|
|
123
126
|
*/
|
|
124
127
|
filterColumns(search: string): Promise<Array<EzGridColumn>>;
|
|
125
128
|
observeConfig(config: IGridConfig): void;
|
|
129
|
+
updatePaginationTooltip(): void;
|
|
126
130
|
onSelectionChange(evt: CustomEvent): void;
|
|
127
131
|
private setSelection;
|
|
128
132
|
private onSelectAllRecords;
|
|
@@ -140,6 +144,15 @@ export declare class EzGrid {
|
|
|
140
144
|
private resetPaginationState;
|
|
141
145
|
private getPaginationControl;
|
|
142
146
|
componentDidLoad(): void;
|
|
147
|
+
private _getActualPageLabel;
|
|
148
|
+
private _getRemainingPageLabel;
|
|
149
|
+
private _getPaginationTooltip;
|
|
150
|
+
private _initHeaderOverflowWatcher;
|
|
151
|
+
private buildOverFlowWatcherParams;
|
|
152
|
+
private handleOverFlow;
|
|
153
|
+
private _hidePaginationDescription;
|
|
154
|
+
private _showPaginationDescription;
|
|
155
|
+
disconnectedCallback(): void;
|
|
143
156
|
componentWillRender(): void;
|
|
144
157
|
componentDidRender(): void;
|
|
145
158
|
componentWillLoad(): void;
|
|
@@ -58,7 +58,6 @@ export declare class EzMuiltiSelectionList {
|
|
|
58
58
|
private handleSearchOnOption;
|
|
59
59
|
private handleChangeSelectAllItems;
|
|
60
60
|
private handleChangeSelectedItem;
|
|
61
|
-
private clearInputs;
|
|
62
61
|
private buildViewList;
|
|
63
62
|
private buildDeleteIconSlot;
|
|
64
63
|
private buildInitViewWithDataSource;
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { EventEmitter } from '../../stencil-public-runtime';
|
|
2
|
+
import { IDropdownItem, IDropdownSubAction } from '../ez-dropdown/structure/DropdownItem';
|
|
3
|
+
export declare class EzSplitButton {
|
|
4
|
+
_element: HTMLElement;
|
|
5
|
+
private leftButton;
|
|
6
|
+
private rightButton;
|
|
7
|
+
private dropdownParent;
|
|
8
|
+
private rightDefaultTitle;
|
|
9
|
+
private show;
|
|
10
|
+
/**
|
|
11
|
+
* Se false o usuário não pode interagir com o botão.
|
|
12
|
+
*/
|
|
13
|
+
enabled: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* Define o ícone a ser usado da biblioteca de ícones: [ez-icons](https://gilded-nasturtium-6b64dd.netlify.app/docs/components/layout-doc/icons/)
|
|
16
|
+
*/
|
|
17
|
+
iconName: string;
|
|
18
|
+
/**
|
|
19
|
+
* Define o caminho usado nos modos `icon-only` e `icon-left` para imagens não contempladas na biblioteca de ícones.
|
|
20
|
+
*/
|
|
21
|
+
image: string;
|
|
22
|
+
/**
|
|
23
|
+
* Define o conteúdo do dropdown.
|
|
24
|
+
*/
|
|
25
|
+
items: Array<IDropdownItem>;
|
|
26
|
+
/**
|
|
27
|
+
* Texto a ser apresentado como label do botão.
|
|
28
|
+
*/
|
|
29
|
+
label: string;
|
|
30
|
+
/**
|
|
31
|
+
* Texto a ser apresentado como title do botão principal
|
|
32
|
+
*/
|
|
33
|
+
leftTitle: string;
|
|
34
|
+
/**
|
|
35
|
+
* Texto a ser apresentado como title do botão dropdown
|
|
36
|
+
*/
|
|
37
|
+
rightTitle: string;
|
|
38
|
+
/**
|
|
39
|
+
* Define o modo de uso do botão.
|
|
40
|
+
*/
|
|
41
|
+
mode: 'default' | 'icon-only' | 'icon-left';
|
|
42
|
+
/**
|
|
43
|
+
* Define o tamanho do ez-split-button.
|
|
44
|
+
*/
|
|
45
|
+
size: 'medium' | 'large';
|
|
46
|
+
/**
|
|
47
|
+
* Emitido quando o botão principal é clicado
|
|
48
|
+
*/
|
|
49
|
+
buttonClick: EventEmitter<void>;
|
|
50
|
+
/**
|
|
51
|
+
* Emitido quando um item do dropdown é clicado
|
|
52
|
+
*/
|
|
53
|
+
dropdownItemClick: EventEmitter<IDropdownItem>;
|
|
54
|
+
/**
|
|
55
|
+
* Emitido quando uma subAction de um item do dropdown é clicada
|
|
56
|
+
*/
|
|
57
|
+
dropdownSubActionClick: EventEmitter<IDropdownSubAction>;
|
|
58
|
+
/**
|
|
59
|
+
* Remove o foco de ambos os botões.
|
|
60
|
+
*/
|
|
61
|
+
setBlur(): Promise<void>;
|
|
62
|
+
/**
|
|
63
|
+
* Aplica o foco no botão principal.
|
|
64
|
+
*/
|
|
65
|
+
setLeftButtonFocus(): Promise<void>;
|
|
66
|
+
/**
|
|
67
|
+
* Aplica o foco no botão do dropdown.
|
|
68
|
+
*/
|
|
69
|
+
setRightButtonFocus(): Promise<void>;
|
|
70
|
+
clickListener(evt: MouseEvent): void;
|
|
71
|
+
private getIconSize;
|
|
72
|
+
private closeDropdown;
|
|
73
|
+
private toggleDropdown;
|
|
74
|
+
private handleButtonClick;
|
|
75
|
+
private handleDropdownItemClick;
|
|
76
|
+
private handleDropdownSubActionClick;
|
|
77
|
+
/**
|
|
78
|
+
* Método responsável em posicionar o dropdown na tela.
|
|
79
|
+
* Faz com que o dropdown se ajuste automaticamente ao espaco na tela
|
|
80
|
+
*/
|
|
81
|
+
private positionDropdown;
|
|
82
|
+
private setEvents;
|
|
83
|
+
componentWillLoad(): void;
|
|
84
|
+
componentDidLoad(): void;
|
|
85
|
+
componentDidUpdate(): void;
|
|
86
|
+
render(): any;
|
|
87
|
+
private shouldShowLabelOnLeftButton;
|
|
88
|
+
private shouldShowIconOnLeftButton;
|
|
89
|
+
}
|
|
@@ -16,5 +16,15 @@ export declare class SplitItem {
|
|
|
16
16
|
* Alterna a visibilidade do painel.
|
|
17
17
|
*/
|
|
18
18
|
toggleExpandItem(): void;
|
|
19
|
+
/**
|
|
20
|
+
* Define o tamanho inicial do painel.
|
|
21
|
+
* @values '%', 'fr'
|
|
22
|
+
*/
|
|
23
|
+
size?: string;
|
|
24
|
+
/**
|
|
25
|
+
* Referência ao elemento que contém o slot.
|
|
26
|
+
**/
|
|
27
|
+
private _slot;
|
|
28
|
+
componentDidLoad(): void;
|
|
19
29
|
render(): any;
|
|
20
30
|
}
|
|
@@ -233,6 +233,10 @@ export namespace Components {
|
|
|
233
233
|
"value": Date;
|
|
234
234
|
}
|
|
235
235
|
interface EzCardItem {
|
|
236
|
+
/**
|
|
237
|
+
* Determina se a chave do item deve ser exibida.
|
|
238
|
+
*/
|
|
239
|
+
"enableKey": boolean;
|
|
236
240
|
/**
|
|
237
241
|
* Determina o conteúdo do card. Deve conter um objeto no formato: `{title: string, key: string, details: any}`.
|
|
238
242
|
*/
|
|
@@ -1242,6 +1246,56 @@ export namespace Components {
|
|
|
1242
1246
|
*/
|
|
1243
1247
|
"width": string;
|
|
1244
1248
|
}
|
|
1249
|
+
interface EzSplitButton {
|
|
1250
|
+
/**
|
|
1251
|
+
* Se false o usuário não pode interagir com o botão.
|
|
1252
|
+
*/
|
|
1253
|
+
"enabled": boolean;
|
|
1254
|
+
/**
|
|
1255
|
+
* Define o ícone a ser usado da biblioteca de ícones: [ez-icons](https://gilded-nasturtium-6b64dd.netlify.app/docs/components/layout-doc/icons/)
|
|
1256
|
+
*/
|
|
1257
|
+
"iconName": string;
|
|
1258
|
+
/**
|
|
1259
|
+
* Define o caminho usado nos modos `icon-only` e `icon-left` para imagens não contempladas na biblioteca de ícones.
|
|
1260
|
+
*/
|
|
1261
|
+
"image": string;
|
|
1262
|
+
/**
|
|
1263
|
+
* Define o conteúdo do dropdown.
|
|
1264
|
+
*/
|
|
1265
|
+
"items": Array<IDropdownItem>;
|
|
1266
|
+
/**
|
|
1267
|
+
* Texto a ser apresentado como label do botão.
|
|
1268
|
+
*/
|
|
1269
|
+
"label": string;
|
|
1270
|
+
/**
|
|
1271
|
+
* Texto a ser apresentado como title do botão principal
|
|
1272
|
+
*/
|
|
1273
|
+
"leftTitle": string;
|
|
1274
|
+
/**
|
|
1275
|
+
* Define o modo de uso do botão.
|
|
1276
|
+
*/
|
|
1277
|
+
"mode": 'default' | 'icon-only' | 'icon-left';
|
|
1278
|
+
/**
|
|
1279
|
+
* Texto a ser apresentado como title do botão dropdown
|
|
1280
|
+
*/
|
|
1281
|
+
"rightTitle": string;
|
|
1282
|
+
/**
|
|
1283
|
+
* Remove o foco de ambos os botões.
|
|
1284
|
+
*/
|
|
1285
|
+
"setBlur": () => Promise<void>;
|
|
1286
|
+
/**
|
|
1287
|
+
* Aplica o foco no botão principal.
|
|
1288
|
+
*/
|
|
1289
|
+
"setLeftButtonFocus": () => Promise<void>;
|
|
1290
|
+
/**
|
|
1291
|
+
* Aplica o foco no botão do dropdown.
|
|
1292
|
+
*/
|
|
1293
|
+
"setRightButtonFocus": () => Promise<void>;
|
|
1294
|
+
/**
|
|
1295
|
+
* Define o tamanho do ez-split-button.
|
|
1296
|
+
*/
|
|
1297
|
+
"size": 'medium' | 'large';
|
|
1298
|
+
}
|
|
1245
1299
|
interface EzSplitItem {
|
|
1246
1300
|
/**
|
|
1247
1301
|
* Define se o item pode ser expandido
|
|
@@ -1251,6 +1305,11 @@ export namespace Components {
|
|
|
1251
1305
|
* Define um título para o painel.
|
|
1252
1306
|
*/
|
|
1253
1307
|
"label": string;
|
|
1308
|
+
/**
|
|
1309
|
+
* Define o tamanho inicial do painel.
|
|
1310
|
+
* @values '%', 'fr'
|
|
1311
|
+
*/
|
|
1312
|
+
"size"?: string;
|
|
1254
1313
|
}
|
|
1255
1314
|
interface EzSplitPanel {
|
|
1256
1315
|
/**
|
|
@@ -1715,6 +1774,10 @@ export interface EzSidebarButtonCustomEvent<T> extends CustomEvent<T> {
|
|
|
1715
1774
|
detail: T;
|
|
1716
1775
|
target: HTMLEzSidebarButtonElement;
|
|
1717
1776
|
}
|
|
1777
|
+
export interface EzSplitButtonCustomEvent<T> extends CustomEvent<T> {
|
|
1778
|
+
detail: T;
|
|
1779
|
+
target: HTMLEzSplitButtonElement;
|
|
1780
|
+
}
|
|
1718
1781
|
export interface EzTabselectorCustomEvent<T> extends CustomEvent<T> {
|
|
1719
1782
|
detail: T;
|
|
1720
1783
|
target: HTMLEzTabselectorElement;
|
|
@@ -1970,6 +2033,12 @@ declare global {
|
|
|
1970
2033
|
prototype: HTMLEzSkeletonElement;
|
|
1971
2034
|
new (): HTMLEzSkeletonElement;
|
|
1972
2035
|
};
|
|
2036
|
+
interface HTMLEzSplitButtonElement extends Components.EzSplitButton, HTMLStencilElement {
|
|
2037
|
+
}
|
|
2038
|
+
var HTMLEzSplitButtonElement: {
|
|
2039
|
+
prototype: HTMLEzSplitButtonElement;
|
|
2040
|
+
new (): HTMLEzSplitButtonElement;
|
|
2041
|
+
};
|
|
1973
2042
|
interface HTMLEzSplitItemElement extends Components.EzSplitItem, HTMLStencilElement {
|
|
1974
2043
|
}
|
|
1975
2044
|
var HTMLEzSplitItemElement: {
|
|
@@ -2086,6 +2155,7 @@ declare global {
|
|
|
2086
2155
|
"ez-search": HTMLEzSearchElement;
|
|
2087
2156
|
"ez-sidebar-button": HTMLEzSidebarButtonElement;
|
|
2088
2157
|
"ez-skeleton": HTMLEzSkeletonElement;
|
|
2158
|
+
"ez-split-button": HTMLEzSplitButtonElement;
|
|
2089
2159
|
"ez-split-item": HTMLEzSplitItemElement;
|
|
2090
2160
|
"ez-split-panel": HTMLEzSplitPanelElement;
|
|
2091
2161
|
"ez-tabselector": HTMLEzTabselectorElement;
|
|
@@ -2283,6 +2353,10 @@ declare namespace LocalJSX {
|
|
|
2283
2353
|
"value"?: Date;
|
|
2284
2354
|
}
|
|
2285
2355
|
interface EzCardItem {
|
|
2356
|
+
/**
|
|
2357
|
+
* Determina se a chave do item deve ser exibida.
|
|
2358
|
+
*/
|
|
2359
|
+
"enableKey"?: boolean;
|
|
2286
2360
|
/**
|
|
2287
2361
|
* Determina o conteúdo do card. Deve conter um objeto no formato: `{title: string, key: string, details: any}`.
|
|
2288
2362
|
*/
|
|
@@ -3251,6 +3325,56 @@ declare namespace LocalJSX {
|
|
|
3251
3325
|
*/
|
|
3252
3326
|
"width"?: string;
|
|
3253
3327
|
}
|
|
3328
|
+
interface EzSplitButton {
|
|
3329
|
+
/**
|
|
3330
|
+
* Se false o usuário não pode interagir com o botão.
|
|
3331
|
+
*/
|
|
3332
|
+
"enabled"?: boolean;
|
|
3333
|
+
/**
|
|
3334
|
+
* Define o ícone a ser usado da biblioteca de ícones: [ez-icons](https://gilded-nasturtium-6b64dd.netlify.app/docs/components/layout-doc/icons/)
|
|
3335
|
+
*/
|
|
3336
|
+
"iconName"?: string;
|
|
3337
|
+
/**
|
|
3338
|
+
* Define o caminho usado nos modos `icon-only` e `icon-left` para imagens não contempladas na biblioteca de ícones.
|
|
3339
|
+
*/
|
|
3340
|
+
"image"?: string;
|
|
3341
|
+
/**
|
|
3342
|
+
* Define o conteúdo do dropdown.
|
|
3343
|
+
*/
|
|
3344
|
+
"items"?: Array<IDropdownItem>;
|
|
3345
|
+
/**
|
|
3346
|
+
* Texto a ser apresentado como label do botão.
|
|
3347
|
+
*/
|
|
3348
|
+
"label"?: string;
|
|
3349
|
+
/**
|
|
3350
|
+
* Texto a ser apresentado como title do botão principal
|
|
3351
|
+
*/
|
|
3352
|
+
"leftTitle"?: string;
|
|
3353
|
+
/**
|
|
3354
|
+
* Define o modo de uso do botão.
|
|
3355
|
+
*/
|
|
3356
|
+
"mode"?: 'default' | 'icon-only' | 'icon-left';
|
|
3357
|
+
/**
|
|
3358
|
+
* Emitido quando o botão principal é clicado
|
|
3359
|
+
*/
|
|
3360
|
+
"onButtonClick"?: (event: EzSplitButtonCustomEvent<void>) => void;
|
|
3361
|
+
/**
|
|
3362
|
+
* Emitido quando um item do dropdown é clicado
|
|
3363
|
+
*/
|
|
3364
|
+
"onDropdownItemClick"?: (event: EzSplitButtonCustomEvent<IDropdownItem>) => void;
|
|
3365
|
+
/**
|
|
3366
|
+
* Emitido quando uma subAction de um item do dropdown é clicada
|
|
3367
|
+
*/
|
|
3368
|
+
"onDropdownSubActionClick"?: (event: EzSplitButtonCustomEvent<IDropdownSubAction>) => void;
|
|
3369
|
+
/**
|
|
3370
|
+
* Texto a ser apresentado como title do botão dropdown
|
|
3371
|
+
*/
|
|
3372
|
+
"rightTitle"?: string;
|
|
3373
|
+
/**
|
|
3374
|
+
* Define o tamanho do ez-split-button.
|
|
3375
|
+
*/
|
|
3376
|
+
"size"?: 'medium' | 'large';
|
|
3377
|
+
}
|
|
3254
3378
|
interface EzSplitItem {
|
|
3255
3379
|
/**
|
|
3256
3380
|
* Define se o item pode ser expandido
|
|
@@ -3260,6 +3384,11 @@ declare namespace LocalJSX {
|
|
|
3260
3384
|
* Define um título para o painel.
|
|
3261
3385
|
*/
|
|
3262
3386
|
"label"?: string;
|
|
3387
|
+
/**
|
|
3388
|
+
* Define o tamanho inicial do painel.
|
|
3389
|
+
* @values '%', 'fr'
|
|
3390
|
+
*/
|
|
3391
|
+
"size"?: string;
|
|
3263
3392
|
}
|
|
3264
3393
|
interface EzSplitPanel {
|
|
3265
3394
|
/**
|
|
@@ -3582,6 +3711,7 @@ declare namespace LocalJSX {
|
|
|
3582
3711
|
"ez-search": EzSearch;
|
|
3583
3712
|
"ez-sidebar-button": EzSidebarButton;
|
|
3584
3713
|
"ez-skeleton": EzSkeleton;
|
|
3714
|
+
"ez-split-button": EzSplitButton;
|
|
3585
3715
|
"ez-split-item": EzSplitItem;
|
|
3586
3716
|
"ez-split-panel": EzSplitPanel;
|
|
3587
3717
|
"ez-tabselector": EzTabselector;
|
|
@@ -3638,6 +3768,7 @@ declare module "@stencil/core" {
|
|
|
3638
3768
|
"ez-search": LocalJSX.EzSearch & JSXBase.HTMLAttributes<HTMLEzSearchElement>;
|
|
3639
3769
|
"ez-sidebar-button": LocalJSX.EzSidebarButton & JSXBase.HTMLAttributes<HTMLEzSidebarButtonElement>;
|
|
3640
3770
|
"ez-skeleton": LocalJSX.EzSkeleton & JSXBase.HTMLAttributes<HTMLEzSkeletonElement>;
|
|
3771
|
+
"ez-split-button": LocalJSX.EzSplitButton & JSXBase.HTMLAttributes<HTMLEzSplitButtonElement>;
|
|
3641
3772
|
"ez-split-item": LocalJSX.EzSplitItem & JSXBase.HTMLAttributes<HTMLEzSplitItemElement>;
|
|
3642
3773
|
"ez-split-panel": LocalJSX.EzSplitPanel & JSXBase.HTMLAttributes<HTMLEzSplitPanelElement>;
|
|
3643
3774
|
"ez-tabselector": LocalJSX.EzTabselector & JSXBase.HTMLAttributes<HTMLEzTabselectorElement>;
|
|
@@ -2,5 +2,6 @@ export default class CSSVarsUtils {
|
|
|
2
2
|
static applyCSSVars(document: DocumentOrShadowRoot, host: HTMLElement, child: HTMLElement): void;
|
|
3
3
|
static applyVarsTextInput(host: HTMLElement, child: HTMLElement): void;
|
|
4
4
|
static applyVarsButton(host: HTMLElement, child: HTMLElement): void;
|
|
5
|
+
static applyVarsGrid(host: HTMLElement, child: HTMLElement): void;
|
|
5
6
|
private static applyIfExists;
|
|
6
7
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sankhyalabs/ezui",
|
|
3
|
-
"version": "0.0.0-bugfix-dev-KB-
|
|
3
|
+
"version": "0.0.0-bugfix-dev-KB-46291.0",
|
|
4
4
|
"description": "Biblioteca de componentes Sankhya.",
|
|
5
5
|
"main": "dist/index.cjs.js",
|
|
6
6
|
"module": "dist/custom-elements/index.js",
|
|
@@ -22,6 +22,7 @@
|
|
|
22
22
|
"build.with.peerdeps": "stencil build --docs --prod --force-peer-deps",
|
|
23
23
|
"start": "stencil build --dev --watch --serve --force-peer-deps",
|
|
24
24
|
"test": "stencil test --spec --e2e --logHeapUsage --runInBand --coverage --silent --testResultsProcessor jest-sonar-reporter",
|
|
25
|
+
"test.watch": "stencil test --spec --e2e --watchAll",
|
|
25
26
|
"generate": "stencil generate",
|
|
26
27
|
"storybook": "npm run start.storybook",
|
|
27
28
|
"build.watch": "stencil build --dev --watch --force-peer-deps",
|
|
@@ -48,7 +49,7 @@
|
|
|
48
49
|
"@babel/preset-env": "^7.16.11",
|
|
49
50
|
"@commitlint/cli": "^18.4.3",
|
|
50
51
|
"@commitlint/config-conventional": "^18.4.3",
|
|
51
|
-
"@sankhyalabs/core": "^5.
|
|
52
|
+
"@sankhyalabs/core": "^5.16.0",
|
|
52
53
|
"@sankhyalabs/docscss": "^1.0.4",
|
|
53
54
|
"@sankhyalabs/ez-design": "^4.0.0",
|
|
54
55
|
"@sankhyalabs/skippeerdeps": "^1.0.2",
|