@sankhyalabs/ezui 0.0.0-bugfix-dev-KB-77369.0 → 0.0.0-bugfix-dev-KB-77126.1
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/{DataBinder-aff1dcc7.js → DataBinder-3b083480.js} +1 -1
- package/dist/cjs/ez-chart.cjs.entry.js +1 -1
- package/dist/cjs/ez-dialog.cjs.entry.js +1 -1
- package/dist/cjs/ez-form-view.cjs.entry.js +2 -2
- package/dist/cjs/ez-form.cjs.entry.js +2 -1
- package/dist/cjs/ez-grid.cjs.entry.js +14425 -70514
- package/dist/cjs/ez-modal.cjs.entry.js +1 -1
- package/dist/cjs/ez-popup.cjs.entry.js +1 -1
- package/dist/cjs/ez-text-input.cjs.entry.js +41 -4
- package/dist/cjs/ezui.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/ez-dialog/ez-dialog.css +3 -3
- package/dist/collection/components/ez-form/ez-form.js +1 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/TextInput.tpl.js +2 -2
- package/dist/collection/components/ez-grid/controller/ag-grid/AgGridController.js +28 -11
- package/dist/collection/components/ez-grid/controller/ag-grid/DataSource.js +5 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/GridEditionManager.js +1 -1
- package/dist/collection/components/ez-grid/ez-grid.js +7 -2
- package/dist/collection/components/ez-modal/ez-modal.css +0 -4
- package/dist/collection/components/ez-modal/ez-modal.js +2 -2
- package/dist/collection/components/ez-popup/ez-popup.css +1 -1
- package/dist/collection/components/ez-text-input/ez-text-input.js +59 -4
- package/dist/collection/utils/interfaces/AbstractFieldMetadata.js +1 -1
- package/dist/custom-elements/index.js +12598 -68649
- package/dist/esm/{DataBinder-bd240826.js → DataBinder-02fa9bb9.js} +1 -1
- package/dist/esm/ez-chart.entry.js +1 -1
- package/dist/esm/ez-dialog.entry.js +1 -1
- package/dist/esm/ez-form-view.entry.js +2 -2
- package/dist/esm/ez-form.entry.js +2 -1
- package/dist/esm/ez-grid.entry.js +14425 -70514
- package/dist/esm/ez-modal.entry.js +1 -1
- package/dist/esm/ez-popup.entry.js +1 -1
- package/dist/esm/ez-text-input.entry.js +41 -4
- package/dist/esm/ezui.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/ezui/ezui.esm.js +1 -1
- package/dist/ezui/p-2aa8e4b2.entry.js +1 -0
- package/dist/ezui/p-3175fe8c.entry.js +1 -0
- package/dist/ezui/p-8d0f02c7.entry.js +309 -0
- package/dist/ezui/{p-7bfae0fc.entry.js → p-91266ddd.entry.js} +1 -1
- package/dist/ezui/p-a5b91a77.entry.js +1 -0
- package/dist/ezui/p-abce5219.entry.js +1 -0
- package/dist/ezui/p-cd2e78f0.entry.js +1 -0
- package/dist/ezui/p-e5e16038.entry.js +1 -0
- package/dist/types/components/ez-form-view/fieldbuilder/templates/TextInput.tpl.d.ts +1 -1
- package/dist/types/components/ez-grid/controller/EzGridController.d.ts +2 -0
- package/dist/types/components/ez-grid/controller/ag-grid/AgGridController.d.ts +3 -2
- package/dist/types/components/ez-grid/controller/ag-grid/DataSource.d.ts +2 -1
- package/dist/types/components/ez-grid/controller/ag-grid/GridEditionManager.d.ts +1 -1
- package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomCellEditor.d.ts +1 -1
- package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomCellRender.d.ts +1 -1
- package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.d.ts +1 -1
- package/dist/types/components/ez-grid/controller/ag-grid/components/cellRendererStatus.d.ts +1 -1
- package/dist/types/components/ez-grid/controller/ag-grid/components/selectionHeader.d.ts +1 -1
- package/dist/types/components/ez-grid/controller/ag-grid/editor/EzCellEditor.d.ts +1 -1
- package/dist/types/components/ez-grid/controller/ag-grid/editor/EzCellRender.d.ts +1 -1
- package/dist/types/components/ez-grid/controller/ag-grid/mock/Server.d.ts +1 -1
- package/dist/types/components/ez-grid/ez-grid.d.ts +1 -1
- package/dist/types/components/ez-modal/ez-modal.d.ts +1 -1
- package/dist/types/components/ez-text-input/ez-text-input.d.ts +5 -0
- package/dist/types/components.d.ts +10 -2
- package/package.json +11 -4
- package/dist/ezui/p-03a2c7d1.entry.js +0 -1
- package/dist/ezui/p-5b205c80.entry.js +0 -1
- package/dist/ezui/p-9ceefe4d.entry.js +0 -1
- package/dist/ezui/p-b0a5c2cd.entry.js +0 -304
- package/dist/ezui/p-b54e17d2.entry.js +0 -1
- package/dist/ezui/p-cdc472cc.entry.js +0 -1
- package/dist/ezui/p-fec696ab.entry.js +0 -1
- /package/dist/ezui/{p-81f06699.js → p-455e737c.js} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as i,h as o,F as e,H as l,g as p}from"./p-23a36bb6.js";import{KeyboardManager as d,FloatingManager as s}from"@sankhyalabs/core";const n=class{constructor(o){t(this,o),this.ezClosePopup=i(this,"ezClosePopup",7),this.ezPopupAction=i(this,"ezPopupAction",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,this.enabledScroll=!1}observeConfig(){this.manageOverflow()}componentDidLoad(){this.opened&&this._popupRef&&this._popupRef.focus(),new d({propagate:!1,element:this._element}).bind("Enter",this.ezPopupAction.emit.bind("OK")).bind("Escape",(()=>this.closePopup())).bind("Esc",(()=>this.closePopup()))}closePopup(){this.opened=!1,this.manageOverflow(),this.ezClosePopup.emit()}manageOverflow(){window.document.body.style.overflow=this.opened?"hidden":""}manageOverlay(){this.opened?this._overlayId=s.subscribeOverlayControl(this._popupRef):s.unsubscribeOverlayControl(this._popupRef||this._overlayId)}popUpFocus(){this.opened&&requestAnimationFrame((()=>{const t=this._element.shadowRoot.querySelector("ez-modal-container");this._popupRef&&null===t&&this._popupRef.focus()}))}getGridSize(){return this._sizeClasses[this.size]||this._sizeClasses.medium}handlePopupHeight(){return"auto"===this.heightMode?"popup__container--auto":""}handlePopupOverflowY(){return this.enabledScroll?"popup__overflow-y--auto":""}componentDidRender(){this.manageOverlay(),this.popUpFocus()}render(){return o(l,null,this.opened?o("div",{class:"overlay",ref:t=>this._popupRef=t,tabIndex:-1},o("div",{class:"popup col "+this.getGridSize()},o("div",{class:`popup__container ${this.handlePopupHeight()} ${this.handlePopupOverflowY()}`},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)}get _element(){return p(this)}static get watchers(){return{opened:["observeConfig"]}}};n.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--large, 20px);--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__overflow-y--auto{overflow-y: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{n as ez_popup}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { IFormViewField } from "../../interfaces/IFormViewField";
|
|
2
|
-
export declare const buildTextInput: ({ name, label, readOnly, contextName, canShowError }: IFormViewField) => HTMLElement;
|
|
2
|
+
export declare const buildTextInput: ({ name, label, readOnly, contextName, canShowError, props }: IFormViewField) => HTMLElement;
|
|
@@ -163,6 +163,8 @@ export default interface EzGridController {
|
|
|
163
163
|
setFocus(): void;
|
|
164
164
|
savingCanceled(fields: Array<IInvalidField>, recordId: string): void;
|
|
165
165
|
destroy(): void;
|
|
166
|
+
registryListeners(): void;
|
|
167
|
+
resetPaginationState(): void;
|
|
166
168
|
stopEdit(): void;
|
|
167
169
|
/**
|
|
168
170
|
Remove coluna de seleção por checkbox
|
|
@@ -18,7 +18,6 @@ export default class AgGridController implements EzGridController, SortingProvid
|
|
|
18
18
|
private _columnStateChangeCallback;
|
|
19
19
|
private _selectionChangeCallback;
|
|
20
20
|
private _doubleClickCallBack;
|
|
21
|
-
private _enterprise;
|
|
22
21
|
private _menuItems;
|
|
23
22
|
private _multipleSelection;
|
|
24
23
|
private _dataUnit;
|
|
@@ -44,7 +43,7 @@ export default class AgGridController implements EzGridController, SortingProvid
|
|
|
44
43
|
private handleFilteredColumnsChanged;
|
|
45
44
|
clearFilter(): void;
|
|
46
45
|
private showFilterColumn;
|
|
47
|
-
constructor(
|
|
46
|
+
constructor(_enterprise: boolean);
|
|
48
47
|
getGridConfig(): Array<EzGridColumnConfig>;
|
|
49
48
|
locateColumn(columnName: string): void;
|
|
50
49
|
getSort(_dataUnitName: string, defaultSorting: Array<Sort>): Array<Sort>;
|
|
@@ -127,5 +126,7 @@ export default class AgGridController implements EzGridController, SortingProvid
|
|
|
127
126
|
clearInvalidCells(stopEdition?: boolean): void;
|
|
128
127
|
processContinuousInsert(): void;
|
|
129
128
|
destroy(): void;
|
|
129
|
+
registryListeners(): void;
|
|
130
|
+
resetPaginationState(): void;
|
|
130
131
|
stopEdit(): void;
|
|
131
132
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IServerSideDatasource, IServerSideGetRowsParams } from "ag-grid-community";
|
|
1
|
+
import { IServerSideDatasource, IServerSideGetRowsParams } from "@ag-grid-community/core";
|
|
2
2
|
import { DataUnit, QuickFilter } from '@sankhyalabs/core';
|
|
3
3
|
import EzGridController, { EzGridColumn, EzGridOptions } from "../EzGridController";
|
|
4
4
|
export default class DataSource implements IServerSideDatasource {
|
|
@@ -41,5 +41,6 @@ export default class DataSource implements IServerSideDatasource {
|
|
|
41
41
|
needReload(currentLoading: IServerSideGetRowsParams): boolean;
|
|
42
42
|
private callbackGetRows;
|
|
43
43
|
destroy(): void;
|
|
44
|
+
registryListeners(): void;
|
|
44
45
|
buildColumnDefs(): Array<EzGridColumn>;
|
|
45
46
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DataUnit, Record } from '@sankhyalabs/core';
|
|
2
|
-
import { CellPosition, ColDef, GridApi, GridOptions } from
|
|
2
|
+
import { CellPosition, ColDef, GridApi, GridOptions } from "@ag-grid-community/core";
|
|
3
3
|
import { IRecordValidator } from '../../../../utils/form/interfaces';
|
|
4
4
|
import { ICustomEditorInfo } from '../../../../utils/customEditor/interfaces/ICustomEditorInfo';
|
|
5
5
|
import { ICustomRenderInfo } from '../../../../utils/customRender/interfaces/ICustomRenderInfo';
|
package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomCellEditor.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ICellEditorParams } from "ag-grid-community";
|
|
1
|
+
import { ICellEditorParams } from "@ag-grid-community/core";
|
|
2
2
|
import { ICustomEditorInfo } from "../../../../../utils/customEditor/interfaces/ICustomEditorInfo";
|
|
3
3
|
import EzCellEditor from "../editor/EzCellEditor";
|
|
4
4
|
interface CustomParamsEditor {
|
package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomCellRender.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ICellRendererParams } from "ag-grid-community";
|
|
1
|
+
import { ICellRendererParams } from "@ag-grid-community/core";
|
|
2
2
|
import EzCellRender from "../editor/EzCellRender";
|
|
3
3
|
import { ICustomRenderInfo } from "../../../../../utils/customRender/interfaces/ICustomRenderInfo";
|
|
4
4
|
interface CustomParamsRender {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ICellRendererComp, ICellRendererParams } from "ag-grid-community";
|
|
1
|
+
import { ICellRendererComp, ICellRendererParams } from "@ag-grid-community/core";
|
|
2
2
|
export declare class CellRendererStatus implements ICellRendererComp {
|
|
3
3
|
private readonly DEFAULT_COLOR;
|
|
4
4
|
private _eGui;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ICellEditorComp, ICellEditorParams } from "ag-grid-community";
|
|
1
|
+
import { ICellEditorComp, ICellEditorParams } from "@ag-grid-community/core";
|
|
2
2
|
import { Record } from "@sankhyalabs/core";
|
|
3
3
|
import { IEditorMetadata } from "./IEditorMetadata";
|
|
4
4
|
export default class EzCellEditor implements ICellEditorComp {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ICellRendererComp, ICellRendererParams } from "ag-grid-community";
|
|
1
|
+
import { ICellRendererComp, ICellRendererParams } from "@ag-grid-community/core";
|
|
2
2
|
import { IEditorMetadata } from "./IEditorMetadata";
|
|
3
3
|
export default class EzCellRender implements ICellRendererComp {
|
|
4
4
|
private _gui;
|
|
@@ -13,7 +13,6 @@ export declare class EzGrid {
|
|
|
13
13
|
private _gridSelectionCounter;
|
|
14
14
|
private _resizeObserver;
|
|
15
15
|
private _messageFilterAppliedSuccess;
|
|
16
|
-
private _gridApi;
|
|
17
16
|
private _filterColumn;
|
|
18
17
|
private _refPaginationLabel;
|
|
19
18
|
private _refPaginationLabelTooltip;
|
|
@@ -217,6 +216,7 @@ export declare class EzGrid {
|
|
|
217
216
|
private _hidePaginationDescription;
|
|
218
217
|
private _showPaginationDescription;
|
|
219
218
|
disconnectedCallback(): void;
|
|
219
|
+
connectedCallback(): void;
|
|
220
220
|
componentWillRender(): void;
|
|
221
221
|
componentDidRender(): void;
|
|
222
222
|
componentWillLoad(): void;
|
|
@@ -34,6 +34,10 @@ export declare class EzTextInput {
|
|
|
34
34
|
* Aplica uma máscara no conteúdo conforme o padrão estabelecido
|
|
35
35
|
*/
|
|
36
36
|
mask: string;
|
|
37
|
+
/**
|
|
38
|
+
* Para remover a máscara quando fizer um apply no formulário.
|
|
39
|
+
*/
|
|
40
|
+
cleanValueMask: boolean;
|
|
37
41
|
/**
|
|
38
42
|
* Se false deixa de exibir a mensagem de erro dentro do campo.
|
|
39
43
|
*/
|
|
@@ -81,6 +85,7 @@ export declare class EzTextInput {
|
|
|
81
85
|
handleFocusout(): void;
|
|
82
86
|
isValidValue(value: string): boolean;
|
|
83
87
|
controlChangeValue(): void;
|
|
88
|
+
applyMask(value: string): string;
|
|
84
89
|
handleChange(): void;
|
|
85
90
|
handleSlotChange(ev: Event): void;
|
|
86
91
|
doFocus(): void;
|
|
@@ -1113,7 +1113,7 @@ export namespace Components {
|
|
|
1113
1113
|
/**
|
|
1114
1114
|
* Define o tipo de scrim a ser aplicado no overlay do modal
|
|
1115
1115
|
*/
|
|
1116
|
-
"scrim": "medium" | "light"
|
|
1116
|
+
"scrim": "medium" | "light";
|
|
1117
1117
|
}
|
|
1118
1118
|
interface EzModalContainer {
|
|
1119
1119
|
/**
|
|
@@ -1677,6 +1677,10 @@ export namespace Components {
|
|
|
1677
1677
|
* Se false deixa de exibir a mensagem de erro dentro do campo.
|
|
1678
1678
|
*/
|
|
1679
1679
|
"canShowError": boolean;
|
|
1680
|
+
/**
|
|
1681
|
+
* Para remover a máscara quando fizer um apply no formulário.
|
|
1682
|
+
*/
|
|
1683
|
+
"cleanValueMask": boolean;
|
|
1680
1684
|
/**
|
|
1681
1685
|
* Se false o usuário não pode interagir com o campo.
|
|
1682
1686
|
*/
|
|
@@ -3456,7 +3460,7 @@ declare namespace LocalJSX {
|
|
|
3456
3460
|
/**
|
|
3457
3461
|
* Define o tipo de scrim a ser aplicado no overlay do modal
|
|
3458
3462
|
*/
|
|
3459
|
-
"scrim"?: "medium" | "light"
|
|
3463
|
+
"scrim"?: "medium" | "light";
|
|
3460
3464
|
}
|
|
3461
3465
|
interface EzModalContainer {
|
|
3462
3466
|
/**
|
|
@@ -4002,6 +4006,10 @@ declare namespace LocalJSX {
|
|
|
4002
4006
|
* Se false deixa de exibir a mensagem de erro dentro do campo.
|
|
4003
4007
|
*/
|
|
4004
4008
|
"canShowError"?: boolean;
|
|
4009
|
+
/**
|
|
4010
|
+
* Para remover a máscara quando fizer um apply no formulário.
|
|
4011
|
+
*/
|
|
4012
|
+
"cleanValueMask"?: boolean;
|
|
4005
4013
|
/**
|
|
4006
4014
|
* Se false o usuário não pode interagir com o campo.
|
|
4007
4015
|
*/
|
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-77126.1",
|
|
4
4
|
"description": "Biblioteca de componentes Sankhya.",
|
|
5
5
|
"main": "dist/index.cjs.js",
|
|
6
6
|
"module": "dist/custom-elements/index.js",
|
|
@@ -46,9 +46,17 @@
|
|
|
46
46
|
"author": "",
|
|
47
47
|
"license": "ISC",
|
|
48
48
|
"devDependencies": {
|
|
49
|
+
"@ag-grid-community/core": "^28.1.1",
|
|
50
|
+
"@ag-grid-community/styles": "^28.1.1",
|
|
51
|
+
"@ag-grid-enterprise/clipboard": "^28.1.1",
|
|
52
|
+
"@ag-grid-enterprise/core": "^28.1.1",
|
|
53
|
+
"@ag-grid-enterprise/menu": "^28.1.1",
|
|
54
|
+
"@ag-grid-enterprise/range-selection": "^28.1.1",
|
|
55
|
+
"@ag-grid-enterprise/server-side-row-model": "^28.1.1",
|
|
49
56
|
"@babel/preset-env": "^7.16.11",
|
|
50
57
|
"@commitlint/cli": "^18.4.3",
|
|
51
58
|
"@commitlint/config-conventional": "^18.4.3",
|
|
59
|
+
"@rollup/plugin-strip": "^3.0.4",
|
|
52
60
|
"@sankhyalabs/core": "^5.16.0",
|
|
53
61
|
"@sankhyalabs/docscss": "^1.0.4",
|
|
54
62
|
"@sankhyalabs/ez-design": "^4.0.0",
|
|
@@ -62,8 +70,6 @@
|
|
|
62
70
|
"@types/jest": "^26.0.20",
|
|
63
71
|
"@types/puppeteer": "^5.4.2",
|
|
64
72
|
"@types/uuid": "^9.0.2",
|
|
65
|
-
"ag-grid-community": "^28.1.1",
|
|
66
|
-
"ag-grid-enterprise": "^28.1.1",
|
|
67
73
|
"gulp": "^4.0.2",
|
|
68
74
|
"gulp-run": "^1.7.1",
|
|
69
75
|
"gulp-watch": "^5.0.1",
|
|
@@ -100,5 +106,6 @@
|
|
|
100
106
|
},
|
|
101
107
|
"resolutions": {
|
|
102
108
|
"postcss": "8.1.7"
|
|
103
|
-
}
|
|
109
|
+
},
|
|
110
|
+
"dependencies": {}
|
|
104
111
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,c as i,h as e,H as o,g as r}from"./p-23a36bb6.js";import{MaskFormatter as s,ElementIDUtils as n}from"@sankhyalabs/core";const a=class{constructor(e){t(this,e),this.ezChange=i(this,"ezChange",7),this.label=void 0,this.value=void 0,this.enabled=!0,this.errorMessage=void 0,this.mask=void 0,this.canShowError=!0,this.restrict=void 0,this.mode="regular",this.noBorder=!1,this.password=!1,this.autoFocus=!1}observeErrorMessage(){this._inputElem&&this.isInvalid().then((t=>{var i,e;t?(this._inputElem.classList.add("hasError"),null===(i=this._messageBoxElem)||void 0===i||i.classList.add("hasError")):(this._inputElem.classList.remove("hasError"),null===(e=this._messageBoxElem)||void 0===e||e.classList.remove("hasError"))}))}observeMask(){this.mask&&(null==this._maskFormatter?this._maskFormatter=new s(this.mask):this._maskFormatter.mask=this.mask)}observeValue(t,i){this._inputElem&&t!=i&&(this._inputElem.value=this.value||"",this.handleChange(),this.adjustFloatingLabel(),this.isSlaveMode()||(this.errorMessage="",this.ezChange.emit(this.value)))}adjustFloatingLabel(){if(this.label&&this._labelElem){this._inputElem&&!this._inputElem.classList.contains("input--with--label")&&this._inputElem.classList.add("input--with--label");const t=this.value&&this.value.toString().length>0,i=this._labelElem.classList.contains("input__label--floated");t||this.isFocused()?i||this._labelElem.classList.add("input__label--floated"):i&&this._labelElem.classList.remove("input__label--floated")}}isFocused(){return null!==this._hostElement.shadowRoot.activeElement}isSlaveMode(){var t,i;return"true"===(null===(i=null===(t=this._hostElement)||void 0===t?void 0:t.dataset)||void 0===i?void 0:i.slaveMode)}adjustColorContentSlot(t=""){this._contentLeftSlot&&(this._contentLeftSlot.style.color=t)}adjustBorderInput(){this.noBorder&&this._inputElem.classList.add("input__slim--noborder")}async setFocus(t){const{selectText:i}=t||{};i&&this._inputElem.select(),this._inputElem.focus()}async setBlur(){this._inputElem.blur()}async isInvalid(){return"string"==typeof this.errorMessage&&""!==this.errorMessage.trim()}handleFocusout(){const t=this._inputElem.value;if(t&&this._maskFormatter)try{this._inputElem.value=this._maskFormatter.format(t)}catch(t){this.errorMessage=t.message}this.controlChangeValue(),this.adjustFloatingLabel(),this.adjustColorContentSlot()}isValidValue(t){return!this.restrict||Array.from(t).reduce(((t,i)=>t&&this.restrict.indexOf(i)>-1),!0)}controlChangeValue(){this._inputElem&&(this.value||"")!==this._inputElem.value&&(this.value=this._inputElem.value)}handleChange(){if(!this._inputElem)return;const t=this._inputElem.value;this.isValidValue(t)?this._lastValidValue=t:this._inputElem.value=null==this._lastValidValue?"":this._lastValidValue,this.controlChangeValue()}handleSlotChange(t){const i=t.target,e=i.assignedElements()[0];e&&(e.style.position="absolute",e.style.display="flex",e.style.alignItems="center",e.style.justifyContent="center",e.style.overflow="hidden",e.style.top="0px",e.style.width="var(--ez-text-input__icon--width)",e.style.height="slim"!=this.mode?"var(--ez-text-input--height)":"var(--ez-text-input--height--slim)","leftIcon"==i.name?(e.style.left="0px",e.style.borderRadius="var(--ez-text-input--border-radius) 0 0 var(--ez-text-input--border-radius)",this._inputElem.classList.add("icon--left"),this._labelElem&&this._labelElem.classList.add("input__label--left"),this._contentLeftSlot=e):"rightIcon"==i.name&&(e.style.right="0px",e.style.borderRadius="0 var(--ez-text-input--border-radius) var(--ez-text-input--border-radius) 0",this._inputElem.classList.add("icon--right"),this._labelElem&&this._labelElem.classList.add("input__label--right")),i.name&&n.addIDInfo(e,i.name)),this.observeErrorMessage()}doFocus(){this.label&&this._labelElem&&!this._labelElem.classList.contains("input__label--floated")&&this._labelElem.classList.add("input__label--floated"),this.adjustColorContentSlot("var(--ez-text-input__input--focus--icon-color)")}componentDidLoad(){this.observeErrorMessage(),this.observeMask(),this.adjustFloatingLabel(),this.adjustBorderInput(),this.autoFocus&&requestAnimationFrame((()=>{this.setFocus({selectText:!0})})),this._inputElem.addEventListener("focus",(()=>{this._inputElem.setSelectionRange(0,this._inputElem.value.length)}))}componentWillLoad(){if(this.observeMask(),this.value){if(this._maskFormatter)try{this.value=this._maskFormatter.format(this.value)}catch(t){this.errorMessage=t.message}this.isValidValue(this.value)||(this._lastValidValue="",this.value="")}}render(){return n.addIDInfoIfNotExists(this._hostElement,"input"),e(o,{style:this._hostElement.classList.contains("grid_editor")?{height:"100%"}:null},e("slot",{name:"leftIcon",onSlotchange:t=>{this.handleSlotChange(t)}}),this.label&&"slim"!=this.mode?e("label",{ref:t=>this._labelElem=t,class:this.enabled?"input__label":"input__label input__label--disabled",onClick:()=>this._inputElem.focus(),title:this.label},this.label):null,e("input",{"data-element-id":n.getInternalIDInfo("input"),onFocus:()=>this.doFocus(),ref:t=>this._inputElem=t,type:this.password?"password":"text",class:"slim"===this.mode?"input--slim":"",placeholder:"slim"===this.mode&&this.label?this.label:"",value:this.value,disabled:!this.enabled,onInput:()=>{this.handleChange()},onFocusout:()=>{this.handleFocusout()}}),e("slot",{name:"rightIcon",onSlotchange:t=>{this.handleSlotChange(t)}}),this.canShowError&&"slim"!=this.mode&&e("span",{class:"message-box",ref:t=>this._messageBoxElem=t,title:this.errorMessage,"data-element-id":n.getInternalIDInfo("message_box")},this.errorMessage))}get _hostElement(){return r(this)}static get watchers(){return{errorMessage:["observeErrorMessage"],mask:["observeMask"],value:["observeValue"]}}};a.style=":host{--ez-text-input--height:42px;--ez-text-input--width:100%;--ez-text-input__icon--width:48px;--ez-text-input--height--slim:32px;--ez-text-input--border-radius:var(--border--radius-medium, 12px);--ez-text-input--font-size:var(--text--medium, 14px);--ez-text-input--font-family:var(--font-pattern, Arial);--ez-text-input--font-weight:var(--text-weight--medium, 400);--ez-text-input--color:var(--title--primary, #2B3A54);--ez-text-input__input--background-color:var(--background--light, #ffffff);--ez-text-input__input--border:var(--border--small, 1px solid);--ez-text-input__input--border-color:var(--color--strokes,#DCE0E8);--ez-text-input__input--focus--border-color:var(--color--primary, #008561);--ez-text-input__input--disabled--background-color:var(--background--medium, #F0F3F7);--ez-text-input__input--disabled--color:var(--text--primary, #626E82);--ez-text-input__input--error--border-color:var(--color-alert--error-800,#BD0025);--ez-text-input__input--noborder-color:white;--ez-text-input__input--padding:var(--space--medium, 6px);--ez-text-input__placeholder--color:var(--text--secondary, #a2abb9);--ez-text-input__message_box--font-size:var(--text--extra-small, 10px);--ez-text-input__message_box--info--color:var(--color--success, #22085d);--ez-text-input__message_box--error--color:var(--color-alert--error-800,#BD0025);--ez-text-input__label--floating--top:6px;--ez-text-input__label--padding-top:12px;--ez-text-input__label--padding-left:14px;--ez-text-input__label--padding-right:12px;--ez-text-input__input--focus--icon-color:var(--title--primary, #2B3A54);--ez-text-input__input--disabled--focus--icon-color:var(--text--primary, #626E82);display:flex;flex-wrap:wrap;position:relative;width:var(--ez-text-input--width)}:host(.grid_editor){--ez-text-input--height--slim:25px}input{width:100%;box-sizing:border-box;height:var(--ez-text-input--height);border-radius:var(--ez-text-input--border-radius);font-family:var(--ez-text-input--font-family);font-size:var(--ez-text-input--font-size);border:var(--ez-text-input__input--border);border-color:var(--ez-text-input__input--border-color);background-color:var(--ez-text-input__input--background-color);color:var(--ez-text-input--color);font-weight:var(--ez-text-input--font-weight);padding:var(--ez-text-input__input--padding)}input:disabled{background-color:var(--ez-text-input__input--disabled--background-color);color:var(--ez-text-input__input--disabled--color);cursor:not-allowed}input:focus{outline:none;border-color:var(--ez-text-input__input--focus--border-color)}input.icon--left{padding-left:var(--ez-text-input__icon--width)}input.icon--right{padding-right:var(--ez-text-input__icon--width)}input.hasError{color:var(--ez-text-input--color);border-color:var(--ez-text-input__input--error--border-color)}input:disabled.hasError{color:var(--ez-text-input__input--disabled--color)}input.text--right{text-align:right}input:disabled,input:read-only{cursor:not-allowed}.message-box{min-height:14px;min-width:100%;margin-top:3px;line-height:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:var(--ez-text-input--font-family);font-size:var(--ez-text-input__message_box--font-size);color:var(--ez-text-input__message_box--info--color)}.hasError{color:var(--ez-text-input__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(--ez-text-input__label--padding-right));left:var(--ez-text-input--space--medium);font-family:var(--ez-text-input--font-family);font-size:var(--ez-text-input--font-size);font-weight:var(--ez-text-input--font-weight);color:var(--ez-text-input--color);top:var(--ez-text-input__label--padding-top);left:var(--ez-text-input__label--padding-left);padding-right:var(--ez-text-input__label--padding-right)}.input__label--floated{font-family:var(--ez-text-input--font-family);font-size:var(--text--extra-small);color:var(--text--primary);top:var(--ez-text-input__label--floating--top)}.input__label--disabled{color:var(--ez-text-input__input--disabled--color);cursor:not-allowed}.input__label--left{text-align:left;left:calc(var(--ez-text-input__icon--width) + 2px);width:calc(100% - var(--ez-text-input__icon--width))}.input__label--right{right:var(--ez-text-input__icon--width);width:calc(100% - var(--ez-text-input__icon--width))}.input__label--left.input__label--right{left:calc(var(--ez-text-input__icon--width) + 2px);width:calc(100% - var(--ez-text-input__icon--width) * 2)}.input--with--label{padding-bottom:0}.input--slim{padding-top:var(--space--small, 3px);padding-bottom:var(--space--small, 3px);height:var(--ez-text-input--height--slim)}.input__slim--title{font-size:16px;font-weight:bold}.input--slim::-webkit-input-placeholder,.input--slim:-moz-placeholder,.input--slim::-moz-placeholder,.input--slim:-ms-input-placeholder,.input--slim::placeholder{font-family:var(--ez-text-input--font-family);font-size:var(--ez-text-input--font-size);font-weight:var(--ez-text-input--font-weight);color:var(--ez-text-input__placeholder--color)}.input--slim:disabled::-webkit-input-placeholder,.input--slim:disabled:-moz-placeholder,.input--slim:disabled::-moz-placeholder,.input--slim:disabled:-ms-input-placeholder,.input--slim:disabled::placeholder{color:var(--ez-text-input__input--disabled--color)}input.input__slim--noborder{box-shadow:0 0 0 0;border:0 none;outline:0;background:var(--ez-text-input__input--noborder-color)}";export{a as ez_text_input}
|