@sankhyalabs/ezui 2.3.0 → 2.3.2
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/README.md +1 -0
- package/dist/cjs/ez-actions-button.cjs.entry.js +12 -8
- package/dist/cjs/ez-button.cjs.entry.js +5 -5
- package/dist/cjs/ez-calendar.cjs.entry.js +10 -13
- package/dist/cjs/ez-check.cjs.entry.js +5 -8
- package/dist/cjs/ez-chip.cjs.entry.js +4 -4
- package/dist/cjs/ez-collapsible-box.cjs.entry.js +14 -14
- package/dist/cjs/ez-combo-box.cjs.entry.js +11 -11
- package/dist/cjs/ez-date-input.cjs.entry.js +5 -5
- package/dist/cjs/ez-date-time-input.cjs.entry.js +7 -7
- package/dist/cjs/ez-dialog.cjs.entry.js +4 -7
- package/dist/cjs/ez-filter-input.cjs.entry.js +6 -6
- package/dist/cjs/ez-form.cjs.entry.js +4 -7
- package/dist/cjs/ez-grid.cjs.entry.js +93 -19
- package/dist/cjs/ez-icon.cjs.entry.js +3 -3
- package/dist/cjs/ez-list.cjs.entry.js +71 -71
- package/dist/cjs/ez-loading-bar.cjs.entry.js +8 -4
- package/dist/cjs/ez-modal-container.cjs.entry.js +2 -2
- package/dist/cjs/ez-modal.cjs.entry.js +6 -6
- package/dist/cjs/ez-number-input.cjs.entry.js +5 -5
- package/dist/cjs/ez-popover.cjs.entry.js +8 -10
- package/dist/cjs/ez-popup.cjs.entry.js +4 -5
- package/dist/cjs/ez-radio-button.cjs.entry.js +3 -3
- package/dist/cjs/ez-scroller.cjs.entry.js +2 -7
- package/dist/cjs/ez-search.cjs.entry.js +13 -14
- package/dist/cjs/ez-text-area.cjs.entry.js +7 -7
- package/dist/cjs/ez-text-edit.cjs.entry.js +1 -1
- package/dist/cjs/ez-text-input.cjs.entry.js +7 -7
- package/dist/cjs/ez-time-input.cjs.entry.js +6 -6
- package/dist/cjs/ez-toast.cjs.entry.js +5 -5
- package/dist/cjs/ez-upload.cjs.entry.js +5 -5
- package/dist/cjs/ez-view-stack.cjs.entry.js +2 -2
- package/dist/cjs/ezui.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/ez-actions-button/ez-actions-button.js +27 -22
- package/dist/collection/components/ez-button/ez-button.js +15 -15
- package/dist/collection/components/ez-calendar/ez-calendar.js +18 -21
- package/dist/collection/components/ez-card-item/ez-card-item.js +2 -2
- package/dist/collection/components/ez-check/ez-check.js +28 -22
- package/dist/collection/components/ez-chip/ez-chip.js +15 -15
- package/dist/collection/components/ez-collapsible-box/ez-collapsible-box.js +28 -28
- package/dist/collection/components/ez-combo-box/ez-combo-box.js +42 -33
- package/dist/collection/components/ez-date-input/ez-date-input.js +18 -18
- package/dist/collection/components/ez-date-time-input/ez-date-time-input.js +21 -21
- package/dist/collection/components/ez-dialog/ez-dialog.js +13 -35
- package/dist/collection/components/ez-filter-input/ez-filter-input.js +18 -35
- package/dist/collection/components/ez-form/ez-form.js +8 -43
- package/dist/collection/components/ez-grid/controller/ag-grid/AgGridController.js +63 -1
- package/dist/collection/components/ez-grid/ez-grid.js +57 -44
- package/dist/collection/components/ez-icon/ez-icon.js +11 -11
- package/dist/collection/components/ez-list/ez-list.js +112 -93
- package/dist/collection/components/ez-loading-bar/ez-loading-bar.js +10 -6
- package/dist/collection/components/ez-modal/ez-modal.js +14 -14
- package/dist/collection/components/ez-modal-container/ez-modal-container.js +16 -16
- package/dist/collection/components/ez-number-input/ez-number-input.js +20 -20
- package/dist/collection/components/ez-popover/ez-popover.js +22 -24
- package/dist/collection/components/ez-popup/ez-popup.js +16 -17
- package/dist/collection/components/ez-radio-button/ez-radio-button.js +8 -8
- package/dist/collection/components/ez-scroller/ez-scroller.js +6 -12
- package/dist/collection/components/ez-search/ez-search.js +42 -46
- package/dist/collection/components/ez-tabselector/ez-tabselector.js +2 -2
- package/dist/collection/components/ez-text-area/ez-text-area.js +20 -37
- package/dist/collection/components/ez-text-edit/ez-text-edit.js +6 -6
- package/dist/collection/components/ez-text-input/ez-text-input.js +21 -38
- package/dist/collection/components/ez-time-input/ez-time-input.js +20 -20
- package/dist/collection/components/ez-toast/ez-toast.js +12 -12
- package/dist/collection/components/ez-upload/ez-upload.js +14 -14
- package/dist/collection/components/ez-view-stack/ez-view-stack.js +4 -4
- package/dist/custom-elements/index.js +344 -283
- package/dist/esm/ez-actions-button.entry.js +12 -8
- package/dist/esm/ez-button.entry.js +5 -5
- package/dist/esm/ez-calendar.entry.js +10 -13
- package/dist/esm/ez-check.entry.js +5 -8
- package/dist/esm/ez-chip.entry.js +4 -4
- package/dist/esm/ez-collapsible-box.entry.js +14 -14
- package/dist/esm/ez-combo-box.entry.js +11 -11
- package/dist/esm/ez-date-input.entry.js +5 -5
- package/dist/esm/ez-date-time-input.entry.js +7 -7
- package/dist/esm/ez-dialog.entry.js +4 -7
- package/dist/esm/ez-filter-input.entry.js +6 -6
- package/dist/esm/ez-form.entry.js +4 -7
- package/dist/esm/ez-grid.entry.js +93 -19
- package/dist/esm/ez-icon.entry.js +3 -3
- package/dist/esm/ez-list.entry.js +71 -71
- package/dist/esm/ez-loading-bar.entry.js +8 -4
- package/dist/esm/ez-modal-container.entry.js +2 -2
- package/dist/esm/ez-modal.entry.js +6 -6
- package/dist/esm/ez-number-input.entry.js +5 -5
- package/dist/esm/ez-popover.entry.js +8 -10
- package/dist/esm/ez-popup.entry.js +4 -5
- package/dist/esm/ez-radio-button.entry.js +3 -3
- package/dist/esm/ez-scroller.entry.js +2 -7
- package/dist/esm/ez-search.entry.js +13 -14
- package/dist/esm/ez-text-area.entry.js +7 -7
- package/dist/esm/ez-text-edit.entry.js +1 -1
- package/dist/esm/ez-text-input.entry.js +7 -7
- package/dist/esm/ez-time-input.entry.js +6 -6
- package/dist/esm/ez-toast.entry.js +5 -5
- package/dist/esm/ez-upload.entry.js +5 -5
- package/dist/esm/ez-view-stack.entry.js +2 -2
- 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-1214c5ce.entry.js +1 -0
- package/dist/ezui/{p-77b7b623.entry.js → p-19a38745.entry.js} +1 -1
- package/dist/ezui/p-2af9fe67.entry.js +1 -0
- package/dist/ezui/p-642c530f.entry.js +1 -0
- package/dist/ezui/p-96265e26.entry.js +1 -0
- package/dist/ezui/p-b47eb5d4.entry.js +1 -0
- package/dist/ezui/{p-855f99f8.entry.js → p-ccbe8272.entry.js} +1 -1
- package/dist/ezui/p-e60e7308.entry.js +1 -0
- package/dist/ezui/p-ede1328a.entry.js +1 -0
- package/dist/ezui/p-f6111077.entry.js +1 -0
- package/dist/types/components/ez-actions-button/ez-actions-button.d.ts +15 -14
- package/dist/types/components/ez-button/ez-button.d.ts +10 -10
- package/dist/types/components/ez-calendar/ez-calendar.d.ts +11 -14
- package/dist/types/components/ez-card-item/ez-card-item.d.ts +7 -0
- package/dist/types/components/ez-check/ez-check.d.ts +11 -13
- package/dist/types/components/ez-chip/ez-chip.d.ts +15 -14
- package/dist/types/components/ez-collapsible-box/ez-collapsible-box.d.ts +25 -25
- package/dist/types/components/ez-combo-box/ez-combo-box.d.ts +21 -20
- package/dist/types/components/ez-date-input/ez-date-input.d.ts +16 -17
- package/dist/types/components/ez-date-time-input/ez-date-time-input.d.ts +18 -19
- package/dist/types/components/ez-dialog/ez-dialog.d.ts +13 -16
- package/dist/types/components/ez-filter-input/ez-filter-input.d.ts +12 -17
- package/dist/types/components/ez-form/ez-form.d.ts +7 -5
- package/dist/types/components/ez-grid/controller/EzGridController.d.ts +10 -2
- package/dist/types/components/ez-grid/controller/ag-grid/AgGridController.d.ts +4 -0
- package/dist/types/components/ez-grid/ez-grid.d.ts +38 -39
- package/dist/types/components/ez-icon/ez-icon.d.ts +4 -4
- package/dist/types/components/ez-list/ez-list.d.ts +29 -32
- package/dist/types/components/ez-loading-bar/ez-loading-bar.d.ts +6 -0
- package/dist/types/components/ez-modal/ez-modal.d.ts +15 -15
- package/dist/types/components/ez-modal-container/ez-modal-container.d.ts +10 -10
- package/dist/types/components/ez-number-input/ez-number-input.d.ts +18 -24
- package/dist/types/components/ez-popover/ez-popover.d.ts +13 -16
- package/dist/types/components/ez-popup/ez-popup.d.ts +12 -13
- package/dist/types/components/ez-radio-button/ez-radio-button.d.ts +8 -8
- package/dist/types/components/ez-scroller/ez-scroller.d.ts +3 -4
- package/dist/types/components/ez-search/ez-search.d.ts +27 -31
- package/dist/types/components/ez-tabselector/ez-tabselector.d.ts +4 -7
- package/dist/types/components/ez-text-area/ez-text-area.d.ts +12 -16
- package/dist/types/components/ez-text-edit/ez-text-edit.d.ts +5 -5
- package/dist/types/components/ez-text-input/ez-text-input.d.ts +14 -19
- package/dist/types/components/ez-time-input/ez-time-input.d.ts +16 -17
- package/dist/types/components/ez-toast/ez-toast.d.ts +7 -7
- package/dist/types/components/ez-upload/ez-upload.d.ts +11 -12
- package/dist/types/components/ez-view-stack/ez-view-stack.d.ts +2 -2
- package/dist/types/components.d.ts +514 -529
- package/package.json +2 -2
- package/dist/ezui/p-0fb5f4be.entry.js +0 -1
- package/dist/ezui/p-1ba371a3.entry.js +0 -1
- package/dist/ezui/p-42c6493e.entry.js +0 -1
- package/dist/ezui/p-6700360e.entry.js +0 -1
- package/dist/ezui/p-8c2105a5.entry.js +0 -1
- package/dist/ezui/p-cba61296.entry.js +0 -1
- package/dist/ezui/p-ed2135a5.entry.js +0 -1
- package/dist/ezui/p-f6afdc4d.entry.js +0 -1
|
@@ -114792,6 +114792,7 @@ class AgGridController {
|
|
|
114792
114792
|
sortingOrder: ['desc', 'asc', null],
|
|
114793
114793
|
columnDefs: this._colDefs,
|
|
114794
114794
|
blockLoadDebounceMillis: this.BLOCK_LOAD_DEBOUNCE,
|
|
114795
|
+
navigateToNextCell: this.navigateToNextCell.bind(this),
|
|
114795
114796
|
getRowNodeId: this._dataUnit ? (params) => typeof params === "string" ? params : params[this._idAttribName] : undefined,
|
|
114796
114797
|
getMainMenuItems: (params) => {
|
|
114797
114798
|
const column = params.column;
|
|
@@ -114831,6 +114832,45 @@ class AgGridController {
|
|
|
114831
114832
|
getRowHeight() {
|
|
114832
114833
|
return this.DEFAULT_ROW_HEIGHT;
|
|
114833
114834
|
}
|
|
114835
|
+
navigateToNextCell(params) {
|
|
114836
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
114837
|
+
switch (params.key) {
|
|
114838
|
+
case 'ArrowUp':
|
|
114839
|
+
if (((_a = this._dataUnit) === null || _a === void 0 ? void 0 : _a.hasPrevious()) === false) {
|
|
114840
|
+
return null;
|
|
114841
|
+
}
|
|
114842
|
+
this._gridOptions.api.deselectAll();
|
|
114843
|
+
if (((_b = params.nextCellPosition) === null || _b === void 0 ? void 0 : _b.rowIndex) < 0) {
|
|
114844
|
+
(_c = this._dataUnit) === null || _c === void 0 ? void 0 : _c.previousRecord();
|
|
114845
|
+
return null;
|
|
114846
|
+
}
|
|
114847
|
+
else {
|
|
114848
|
+
(_d = this._dataUnit) === null || _d === void 0 ? void 0 : _d.setSelectionByIndex([params.nextCellPosition.rowIndex]);
|
|
114849
|
+
return params.nextCellPosition;
|
|
114850
|
+
}
|
|
114851
|
+
case 'ArrowDown':
|
|
114852
|
+
if (((_e = this._dataUnit) === null || _e === void 0 ? void 0 : _e.hasNext()) === false) {
|
|
114853
|
+
return null;
|
|
114854
|
+
}
|
|
114855
|
+
this._gridOptions.api.deselectAll();
|
|
114856
|
+
if ((_f = params.nextCellPosition) === null || _f === void 0 ? void 0 : _f.rowIndex) {
|
|
114857
|
+
(_g = this._dataUnit) === null || _g === void 0 ? void 0 : _g.setSelectionByIndex([params.nextCellPosition.rowIndex]);
|
|
114858
|
+
}
|
|
114859
|
+
else {
|
|
114860
|
+
(_h = this._dataUnit) === null || _h === void 0 ? void 0 : _h.nextRecord();
|
|
114861
|
+
}
|
|
114862
|
+
return params.nextCellPosition;
|
|
114863
|
+
case "ArrowLeft":
|
|
114864
|
+
case "ArrowRight":
|
|
114865
|
+
if (((_j = params.nextCellPosition) === null || _j === void 0 ? void 0 : _j.column.colDef.headerName) !== "") {
|
|
114866
|
+
return params.nextCellPosition;
|
|
114867
|
+
}
|
|
114868
|
+
else {
|
|
114869
|
+
return null;
|
|
114870
|
+
}
|
|
114871
|
+
}
|
|
114872
|
+
return null;
|
|
114873
|
+
}
|
|
114834
114874
|
setOptionsEvents(opt) {
|
|
114835
114875
|
opt.onSortChanged = e => this.onCallStateChange("sort", e);
|
|
114836
114876
|
opt.onColumnResized = e => this.onCallStateChange("columnResize", e);
|
|
@@ -114891,7 +114931,14 @@ class AgGridController {
|
|
|
114891
114931
|
throw new Error("Erro interno: Grid ainda não inicializado.");
|
|
114892
114932
|
}
|
|
114893
114933
|
this._gridOptions.api.forEachNode(node => {
|
|
114894
|
-
|
|
114934
|
+
var _a;
|
|
114935
|
+
if (rowIds && rowIds.includes(node.id)) {
|
|
114936
|
+
node.setSelected(true);
|
|
114937
|
+
(_a = this._gridOptions.api) === null || _a === void 0 ? void 0 : _a.ensureNodeVisible(node);
|
|
114938
|
+
}
|
|
114939
|
+
else {
|
|
114940
|
+
node.setSelected(false);
|
|
114941
|
+
}
|
|
114895
114942
|
});
|
|
114896
114943
|
const selectionHeader = this._gridOptions.context.selectionHeader;
|
|
114897
114944
|
if (selectionHeader) {
|
|
@@ -114937,6 +114984,21 @@ class AgGridController {
|
|
|
114937
114984
|
}
|
|
114938
114985
|
this._gridOptions.api.refreshServerSide({ purge: false });
|
|
114939
114986
|
}
|
|
114987
|
+
setFocusFirstRow() {
|
|
114988
|
+
const firstRow = this._gridOptions.api.getDisplayedRowAtIndex(0);
|
|
114989
|
+
this.setFocusOnRow(firstRow.rowIndex);
|
|
114990
|
+
}
|
|
114991
|
+
setFocusLastRow() {
|
|
114992
|
+
const lastRow = this._gridOptions.api.getDisplayedRowAtIndex(this._gridOptions.api.getLastDisplayedRow());
|
|
114993
|
+
this.setFocusOnRow(lastRow.rowIndex);
|
|
114994
|
+
}
|
|
114995
|
+
setFocusOnRow(rowIndex) {
|
|
114996
|
+
let displayedColumns = this._gridOptions.columnApi.getAllDisplayedColumns();
|
|
114997
|
+
let firstCell = displayedColumns.find((column) => column.getColDef().headerName !== "");
|
|
114998
|
+
this._gridOptions.api.ensureColumnVisible(firstCell);
|
|
114999
|
+
this._gridOptions.api.ensureIndexVisible(rowIndex);
|
|
115000
|
+
this._gridOptions.api.setFocusedCell(rowIndex, firstCell);
|
|
115001
|
+
}
|
|
114940
115002
|
setColumnsDef(cols) {
|
|
114941
115003
|
const newColDefs = [Object.assign({ colId: this.CHECK_BOX_COL_ID, headerName: "", checkboxSelection: true, width: 28, suppressMovable: true, suppressAutoSize: true, suppressMenu: true, lockPosition: true, pinned: true }, this._multipleSelection && { headerComponent: "ezGridHeaderComponent", headerClass: "ag-column-select-header" })];
|
|
114942
115004
|
if (this._statusResolver != undefined) {
|
|
@@ -115205,53 +115267,53 @@ let EzGrid = class {
|
|
|
115205
115267
|
this.ezDoubleClick = createEvent(this, "ezDoubleClick", 7);
|
|
115206
115268
|
this.configChange = createEvent(this, "configChange", 7);
|
|
115207
115269
|
this._gridController = new AgGridController(false);
|
|
115270
|
+
this._paginationChangedByKeyboard = true;
|
|
115208
115271
|
}
|
|
115209
115272
|
/**
|
|
115210
|
-
|
|
115211
|
-
|
|
115273
|
+
* Aplica a definição de colunas.
|
|
115274
|
+
*/
|
|
115212
115275
|
async setColumnsDef(cols) {
|
|
115213
115276
|
this._gridController.setColumnsDef(cols);
|
|
115214
115277
|
}
|
|
115215
115278
|
/**
|
|
115216
|
-
|
|
115217
|
-
|
|
115279
|
+
* Adiciona item de menu nas colunas.
|
|
115280
|
+
*/
|
|
115218
115281
|
async addColumnMenuItem(label, name, action) {
|
|
115219
115282
|
this._gridController.addColumnMenuItem({ label, name, action });
|
|
115220
115283
|
}
|
|
115221
115284
|
/**
|
|
115222
|
-
|
|
115223
|
-
|
|
115285
|
+
* Aplica o estado das colunas.
|
|
115286
|
+
*/
|
|
115224
115287
|
async setColumnsState(state) {
|
|
115225
115288
|
this._gridController.setColumnsState(state);
|
|
115226
115289
|
}
|
|
115227
115290
|
/**
|
|
115228
|
-
|
|
115229
|
-
|
|
115230
|
-
*/
|
|
115291
|
+
* Insere os registros no ez-grid.
|
|
115292
|
+
*/
|
|
115231
115293
|
async setData(data) {
|
|
115232
115294
|
this._gridController.setData(data);
|
|
115233
115295
|
}
|
|
115234
115296
|
/**
|
|
115235
|
-
|
|
115236
|
-
|
|
115297
|
+
* Obtém as linhas selecionadas.
|
|
115298
|
+
*/
|
|
115237
115299
|
async getSelection() {
|
|
115238
115300
|
return Promise.resolve(this._gridController.getSelection());
|
|
115239
115301
|
}
|
|
115240
115302
|
/**
|
|
115241
|
-
|
|
115242
|
-
|
|
115303
|
+
* Obtém o estado atual das colunas.
|
|
115304
|
+
*/
|
|
115243
115305
|
async getColumnsState() {
|
|
115244
115306
|
return Promise.resolve(this._gridController.getColumnsState());
|
|
115245
115307
|
}
|
|
115246
115308
|
/**
|
|
115247
|
-
|
|
115248
|
-
|
|
115309
|
+
* Obtém a lista de definição de colunas.
|
|
115310
|
+
*/
|
|
115249
115311
|
async getColumns() {
|
|
115250
115312
|
return Promise.resolve(this._gridController.getColumnsDef());
|
|
115251
115313
|
}
|
|
115252
115314
|
/**
|
|
115253
|
-
|
|
115254
|
-
|
|
115315
|
+
* Aplica um filtro rápido.
|
|
115316
|
+
*/
|
|
115255
115317
|
async quickFilter(term) {
|
|
115256
115318
|
this._gridController.quickFilter(term);
|
|
115257
115319
|
}
|
|
@@ -115329,7 +115391,17 @@ let EzGrid = class {
|
|
|
115329
115391
|
this._gridController.initDatagrid(this._container, {
|
|
115330
115392
|
onColumnStateChange: (type, state, info) => this.onColumnStateChange(type, state, info),
|
|
115331
115393
|
onSelectionChange: (selection) => this.ezSelectionChange.emit(selection),
|
|
115332
|
-
onPaginationChange: (paginationInfo) =>
|
|
115394
|
+
onPaginationChange: (paginationInfo) => {
|
|
115395
|
+
var _a;
|
|
115396
|
+
if (((_a = this._paginationInfo) === null || _a === void 0 ? void 0 : _a.currentPage) > paginationInfo.currentPage && this._paginationChangedByKeyboard) {
|
|
115397
|
+
this._gridController.setFocusLastRow();
|
|
115398
|
+
}
|
|
115399
|
+
else {
|
|
115400
|
+
this._gridController.setFocusFirstRow();
|
|
115401
|
+
this._paginationChangedByKeyboard = true;
|
|
115402
|
+
}
|
|
115403
|
+
this._paginationInfo = paginationInfo;
|
|
115404
|
+
},
|
|
115333
115405
|
onDoubleClick: (row) => {
|
|
115334
115406
|
this.ezDoubleClick.emit(row);
|
|
115335
115407
|
},
|
|
@@ -115352,11 +115424,13 @@ let EzGrid = class {
|
|
|
115352
115424
|
previousPage() {
|
|
115353
115425
|
if (this.dataUnit) {
|
|
115354
115426
|
this.dataUnit.previousPage();
|
|
115427
|
+
this._paginationChangedByKeyboard = false;
|
|
115355
115428
|
}
|
|
115356
115429
|
}
|
|
115357
115430
|
nextPage() {
|
|
115358
115431
|
if (this.dataUnit) {
|
|
115359
115432
|
this.dataUnit.nextPage();
|
|
115433
|
+
this._paginationChangedByKeyboard = false;
|
|
115360
115434
|
}
|
|
115361
115435
|
}
|
|
115362
115436
|
getPaginationControl() {
|
|
@@ -7,12 +7,12 @@ let EzIcon = class {
|
|
|
7
7
|
constructor(hostRef) {
|
|
8
8
|
registerInstance(this, hostRef);
|
|
9
9
|
/**
|
|
10
|
-
*
|
|
10
|
+
* Define o tamanho do ícone.
|
|
11
11
|
*/
|
|
12
|
-
this.size =
|
|
12
|
+
this.size = "medium";
|
|
13
13
|
}
|
|
14
14
|
isSprite() {
|
|
15
|
-
return this.href && this.href.indexOf(
|
|
15
|
+
return this.href && this.href.indexOf("#") > -1;
|
|
16
16
|
}
|
|
17
17
|
getIconClassName() {
|
|
18
18
|
return `ez-icon-${this.iconName}`;
|
|
@@ -10,64 +10,42 @@ let EzList = class {
|
|
|
10
10
|
this._listGroupItems = [];
|
|
11
11
|
this._listItemsHistory = [];
|
|
12
12
|
/**
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
* Define a lista inicial do componente.
|
|
14
|
+
*/
|
|
15
15
|
this.dataSource = [];
|
|
16
16
|
/**
|
|
17
|
-
|
|
18
|
-
|
|
17
|
+
* Se true os grupos serão exibidos.
|
|
18
|
+
*/
|
|
19
19
|
this.useGroups = false;
|
|
20
20
|
/**
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
* Se true habilita `drag and drop` para os itens.
|
|
22
|
+
*/
|
|
23
23
|
this.ezDraggable = false;
|
|
24
24
|
/**
|
|
25
|
-
|
|
26
|
-
|
|
25
|
+
* Se true os itens serão selecionáveis.
|
|
26
|
+
*/
|
|
27
27
|
this.ezSelectable = false;
|
|
28
28
|
}
|
|
29
|
-
createList() {
|
|
30
|
-
if (this.useGroups) {
|
|
31
|
-
let list = [...this.dataSource];
|
|
32
|
-
list.forEach(itemGroup => {
|
|
33
|
-
this.sortGroup(itemGroup);
|
|
34
|
-
});
|
|
35
|
-
this._listGroupItems = list;
|
|
36
|
-
}
|
|
37
|
-
else {
|
|
38
|
-
this._listItems = this._listItemsHistory.length > 0 ? this._listItemsHistory : [...this.dataSource];
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
sortGroup(itemGroup) {
|
|
42
|
-
if (itemGroup.sort) {
|
|
43
|
-
itemGroup.items.sort(function (a, b) {
|
|
44
|
-
return a.label < b.label ? -1 : a.label > b.label ? 1 : 0;
|
|
45
|
-
});
|
|
46
|
-
if (itemGroup.sort === "DSC") {
|
|
47
|
-
itemGroup.items.reverse();
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
29
|
/**
|
|
52
|
-
|
|
53
|
-
|
|
30
|
+
* Limpa o histórico da lista.
|
|
31
|
+
*/
|
|
54
32
|
async clearHistory() {
|
|
55
33
|
this._listItemsHistory = [];
|
|
56
34
|
}
|
|
57
35
|
/**
|
|
58
|
-
|
|
59
|
-
|
|
36
|
+
* Traz o conteúdo da lista para a área visível.
|
|
37
|
+
*/
|
|
60
38
|
async scrollToTop() {
|
|
61
39
|
if (this.useGroups) {
|
|
62
|
-
this._element.shadowRoot.querySelector(
|
|
40
|
+
this._element.shadowRoot.querySelector(".group-container").scrollTop = 0;
|
|
63
41
|
}
|
|
64
42
|
else {
|
|
65
|
-
this._element.shadowRoot.querySelector(
|
|
43
|
+
this._element.shadowRoot.querySelector(".items-container").scrollTop = 0;
|
|
66
44
|
}
|
|
67
45
|
}
|
|
68
46
|
/**
|
|
69
|
-
|
|
70
|
-
|
|
47
|
+
* Aplica seleção nas linhas da lista.
|
|
48
|
+
*/
|
|
71
49
|
async setSelection(selectedItem, scrollToOption) {
|
|
72
50
|
if (selectedItem && this.ezSelectable) {
|
|
73
51
|
if (this.useGroups) {
|
|
@@ -98,8 +76,8 @@ let EzList = class {
|
|
|
98
76
|
}
|
|
99
77
|
if (scrollToOption) {
|
|
100
78
|
let liElem = this.useGroups ?
|
|
101
|
-
this._groupContainer.querySelector(
|
|
102
|
-
: this._itemContainer.querySelector(
|
|
79
|
+
this._groupContainer.querySelector("li#item_" + this.getItemId(selectedItem.label))
|
|
80
|
+
: this._itemContainer.querySelector("li#item_" + this.getItemId(selectedItem.label));
|
|
103
81
|
if (liElem) {
|
|
104
82
|
liElem.scrollIntoView();
|
|
105
83
|
}
|
|
@@ -109,27 +87,9 @@ let EzList = class {
|
|
|
109
87
|
this.removeSelection();
|
|
110
88
|
}
|
|
111
89
|
}
|
|
112
|
-
removeSelection() {
|
|
113
|
-
if (this.useGroups) {
|
|
114
|
-
let newList = [...this._listGroupItems];
|
|
115
|
-
newList.forEach(groupItem => {
|
|
116
|
-
groupItem.items.forEach(item => {
|
|
117
|
-
item.selected = false;
|
|
118
|
-
});
|
|
119
|
-
});
|
|
120
|
-
this._listGroupItems = newList;
|
|
121
|
-
}
|
|
122
|
-
else {
|
|
123
|
-
let newList = [...this._listItems];
|
|
124
|
-
newList.forEach(item => {
|
|
125
|
-
item.selected = false;
|
|
126
|
-
});
|
|
127
|
-
this._listItems = newList;
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
90
|
/**
|
|
131
|
-
*
|
|
132
|
-
|
|
91
|
+
* Obtém o item selecionado.
|
|
92
|
+
*/
|
|
133
93
|
async getSelection() {
|
|
134
94
|
let selectedItem;
|
|
135
95
|
if (this.useGroups) {
|
|
@@ -148,7 +108,7 @@ let EzList = class {
|
|
|
148
108
|
return selectedItem;
|
|
149
109
|
}
|
|
150
110
|
/**
|
|
151
|
-
*
|
|
111
|
+
* Obtém a lista de items ou grupos.
|
|
152
112
|
*/
|
|
153
113
|
async getList() {
|
|
154
114
|
if (this.useGroups) {
|
|
@@ -156,6 +116,46 @@ let EzList = class {
|
|
|
156
116
|
}
|
|
157
117
|
return this._listItems;
|
|
158
118
|
}
|
|
119
|
+
createList() {
|
|
120
|
+
if (this.useGroups) {
|
|
121
|
+
let list = this.dataSource.map(item => item);
|
|
122
|
+
list.forEach(itemGroup => {
|
|
123
|
+
this.sortGroup(itemGroup);
|
|
124
|
+
});
|
|
125
|
+
this._listGroupItems = list;
|
|
126
|
+
}
|
|
127
|
+
else {
|
|
128
|
+
this._listItems = this._listItemsHistory.length > 0 ? this._listItemsHistory : this.dataSource.map(item => item);
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
sortGroup(itemGroup) {
|
|
132
|
+
if (itemGroup.sort) {
|
|
133
|
+
itemGroup.items.sort(function (a, b) {
|
|
134
|
+
return a.label < b.label ? -1 : a.label > b.label ? 1 : 0;
|
|
135
|
+
});
|
|
136
|
+
if (itemGroup.sort === "DSC") {
|
|
137
|
+
itemGroup.items.reverse();
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
removeSelection() {
|
|
142
|
+
if (this.useGroups) {
|
|
143
|
+
let newList = [...this._listGroupItems];
|
|
144
|
+
newList.forEach(groupItem => {
|
|
145
|
+
groupItem.items.forEach(item => {
|
|
146
|
+
item.selected = false;
|
|
147
|
+
});
|
|
148
|
+
});
|
|
149
|
+
this._listGroupItems = newList;
|
|
150
|
+
}
|
|
151
|
+
else {
|
|
152
|
+
let newList = [...this._listItems];
|
|
153
|
+
newList.forEach(item => {
|
|
154
|
+
item.selected = false;
|
|
155
|
+
});
|
|
156
|
+
this._listItems = newList;
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
159
|
componentWillLoad() {
|
|
160
160
|
this._listItemsHistory = [];
|
|
161
161
|
}
|
|
@@ -278,7 +278,7 @@ let EzList = class {
|
|
|
278
278
|
}
|
|
279
279
|
addOverClass(element) {
|
|
280
280
|
if ((element === null || element === void 0 ? void 0 : element.__proto__) == HTMLDivElement.prototype && element.classList.contains("draggable")) {
|
|
281
|
-
element.classList.add(
|
|
281
|
+
element.classList.add("over");
|
|
282
282
|
}
|
|
283
283
|
else if ((element === null || element === void 0 ? void 0 : element.parentElement) && !element.parentElement.classList.contains("draggable-list")) {
|
|
284
284
|
this.addOverClass(element.parentElement);
|
|
@@ -303,21 +303,21 @@ let EzList = class {
|
|
|
303
303
|
let overCollection;
|
|
304
304
|
let overLastDroppableCollection;
|
|
305
305
|
if (this.useGroups) {
|
|
306
|
-
overCollection = (_a = this._groupContainer) === null || _a === void 0 ? void 0 : _a.getElementsByClassName(
|
|
307
|
-
overLastDroppableCollection = this._groupContainer.getElementsByClassName(
|
|
306
|
+
overCollection = (_a = this._groupContainer) === null || _a === void 0 ? void 0 : _a.getElementsByClassName("over");
|
|
307
|
+
overLastDroppableCollection = this._groupContainer.getElementsByClassName("last-droppable-space");
|
|
308
308
|
}
|
|
309
309
|
else {
|
|
310
|
-
overCollection = (_b = this._itemContainer) === null || _b === void 0 ? void 0 : _b.getElementsByClassName(
|
|
311
|
-
overLastDroppableCollection = this._itemContainer.getElementsByClassName(
|
|
310
|
+
overCollection = (_b = this._itemContainer) === null || _b === void 0 ? void 0 : _b.getElementsByClassName("over");
|
|
311
|
+
overLastDroppableCollection = this._itemContainer.getElementsByClassName("last-droppable-space");
|
|
312
312
|
}
|
|
313
313
|
if (overCollection) {
|
|
314
314
|
Array.from(overCollection).forEach(function (element) {
|
|
315
|
-
element.classList.remove(
|
|
315
|
+
element.classList.remove("over");
|
|
316
316
|
});
|
|
317
317
|
}
|
|
318
318
|
if (overLastDroppableCollection) {
|
|
319
319
|
Array.from(overLastDroppableCollection).forEach(function (element) {
|
|
320
|
-
element.classList.remove(
|
|
320
|
+
element.classList.remove("over");
|
|
321
321
|
});
|
|
322
322
|
}
|
|
323
323
|
}
|
|
@@ -468,7 +468,7 @@ let EzList = class {
|
|
|
468
468
|
onDragOverLastIndex(ev) {
|
|
469
469
|
ev.preventDefault();
|
|
470
470
|
if (this._dragStartItem) {
|
|
471
|
-
ev.target.classList.add(
|
|
471
|
+
ev.target.classList.add("over");
|
|
472
472
|
ev.stopPropagation();
|
|
473
473
|
}
|
|
474
474
|
}
|
|
@@ -494,7 +494,7 @@ let EzList = class {
|
|
|
494
494
|
return (h(Host, { ref: (el) => this._element = el }, this.useGroups ?
|
|
495
495
|
h("div", { class: "group-container", ref: (el) => this._groupContainer = el, tabIndex: 0, onKeyDown: (event) => { this.keyDownHandler(event); } }, this._listGroupItems.map(group => {
|
|
496
496
|
return h("div", { id: this.getDivGroupId(group.group), class: "group", key: group.group + group.items.length, onDrop: () => this.onDropGroup(group) }, h("label", { draggable: false, class: "group-name" }, group.group), h("section", { class: "section-container", onDragOver: (ev) => ev.preventDefault() }, h("div", { class: "group-items-container" }, h("div", { class: "draggable-list" }, group.items.map((item, index) => {
|
|
497
|
-
return h("li", { id:
|
|
497
|
+
return h("li", { id: "item_" + this.getItemId(item.label), class: this.ezSelectable ? "selectable-container" : "", key: "item_" + this.getItemId(item.label) }, h("div", { class: "draggable" + (item.selected == true ? " selected-item " : "") + (this.ezSelectable == true ? " selectable " : ""), onClick: () => { this.setSelection(item); }, onDragLeave: () => { group.sort ? undefined : this.removeOverClass(); }, onDragEnd: () => this.onDragEnd(), onDragStart: () => this.onDragStart(item, group, index), onDragOver: (event) => { group.sort ? undefined : this.onDragOverItem(event); }, onDrop: (event) => this.onDrop(event, { groupName: group.group, item: item, index: index }), draggable: this.ezDraggable }, h("div", { class: "item-content" }, this.ezDraggable ? h("span", { class: "draggable-icon" }) : undefined, h("p", { title: item.label, class: "person-name text--ellipsis" }, item.label)), this.itemSlotBuilder ?
|
|
498
498
|
h("div", { class: "slot-item" }, this.itemSlotBuilder(item, group))
|
|
499
499
|
: undefined));
|
|
500
500
|
})), h("div", { class: "last-droppable-space", onDragLeave: () => this.removeOverClass(), onDragOver: (event) => { this.onDragOverLastIndex(event); }, onDragEnd: () => this.onDragEnd(), onDrop: (event) => this.onDropLastIndex(event, group) })), group.sort ?
|
|
@@ -503,7 +503,7 @@ let EzList = class {
|
|
|
503
503
|
}))
|
|
504
504
|
:
|
|
505
505
|
h("div", { class: "items-container", ref: (el) => this._itemContainer = el, tabIndex: 0, onKeyDown: (event) => { this.keyDownHandler(event); } }, h("div", { class: "draggable-list" }, this._listItems.map((item, index) => {
|
|
506
|
-
return h("li", { id:
|
|
506
|
+
return h("li", { id: "item_" + this.getItemId(item.label), class: this.ezSelectable ? "selectable-container" : "", key: "item_" + this.getItemId(item.label) }, h("div", { class: "draggable" + (item.selected == true ? " selected-item " : "") + (this.ezSelectable == true ? " selectable " : ""), onDragStart: () => this.onDragStart({ item: item, index: index }), onClick: () => { this.setSelection(item); }, onDragLeave: () => this.removeOverClass(), onDragOver: (event) => this.onDragOverItem(event), onDragEnd: () => this.onDragEnd(), onDrop: (event) => this.onDrop(event, { item: item, index: index }), draggable: this.ezDraggable }, h("div", { class: "item-content" }, this.ezDraggable ? h("span", { class: "draggable-icon" }) : undefined, h("p", { title: item.label, class: "person-name text--ellipsis" }, item.label)), this.itemSlotBuilder ?
|
|
507
507
|
h("div", null, this.itemSlotBuilder(item))
|
|
508
508
|
: undefined));
|
|
509
509
|
}), h("div", { class: "last-droppable-space", onDragLeave: () => this.removeOverClass(), onDragOver: (event) => { this.onDragOverLastIndex(event); }, onDragEnd: () => this.onDragEnd(), onDrop: (event) => this.onDropLastIndex(event) })))));
|
|
@@ -7,13 +7,17 @@ let EzLoadingBar = class {
|
|
|
7
7
|
registerInstance(this, hostRef);
|
|
8
8
|
this._showLoading = true;
|
|
9
9
|
}
|
|
10
|
-
|
|
10
|
+
/**
|
|
11
|
+
* Oculta o ez-loading-bar.
|
|
12
|
+
*/
|
|
13
|
+
async hide() {
|
|
11
14
|
this._showLoading = false;
|
|
12
|
-
return Promise.resolve();
|
|
13
15
|
}
|
|
14
|
-
|
|
16
|
+
/**
|
|
17
|
+
* Exibe o ez-loading-bar.
|
|
18
|
+
*/
|
|
19
|
+
async show() {
|
|
15
20
|
this._showLoading = true;
|
|
16
|
-
return Promise.resolve();
|
|
17
21
|
}
|
|
18
22
|
render() {
|
|
19
23
|
return (h(Host, null, this._showLoading && h("div", { class: "loading-bar" }, h("div", { class: "loading-bar__container" }))));
|
|
@@ -24,7 +24,7 @@ let EzModalContainer = class {
|
|
|
24
24
|
registerInstance(this, hostRef);
|
|
25
25
|
this.ezModalAction = createEvent(this, "ezModalAction", 7);
|
|
26
26
|
/**
|
|
27
|
-
*
|
|
27
|
+
* Define se o cabeçalho será mostrado.
|
|
28
28
|
*/
|
|
29
29
|
this.showTitleBar = true;
|
|
30
30
|
}
|
|
@@ -46,7 +46,7 @@ let EzModalContainer = class {
|
|
|
46
46
|
this._closeButton.focus();
|
|
47
47
|
}
|
|
48
48
|
render() {
|
|
49
|
-
return (h(Host, null, h("button", { class: "ez-modal-container__focus-ctrl", onFocusin: evt => this.focusLast(evt) }), this.showTitleBar && h("div", { class: "ez-modal-container__header ez-margin-bottom--large ez-align--middle" }, h("div", { class: "ez-col ez-align--middle ez-modal-container__title" }, h("h2", { class: "ez-text ez-title--large ez-title--primary ez-text--bold ez-margin-vertical--extra-small" }, this.modalTitle), this.modalSubTitle ? h("div", { class: "ez-text ez-text--medium ez-text--primary ez-margin-vertical--extra-small" }, this.modalSubTitle) : undefined), h("button", { ref: ref => this._closeButton = ref, class: "ez-modal-container__close-button", onClick: () => this.ezModalAction.emit(ModalAction$1.CLOSE) }, h("ez-icon", { class: "ez-modal-container__close-icon", size: "medium", iconName: "close" }))), h("div", null, h("slot", null)), h("div", { class:
|
|
49
|
+
return (h(Host, null, h("button", { class: "ez-modal-container__focus-ctrl", onFocusin: evt => this.focusLast(evt) }), this.showTitleBar && h("div", { class: "ez-modal-container__header ez-margin-bottom--large ez-align--middle" }, h("div", { class: "ez-col ez-align--middle ez-modal-container__title" }, h("h2", { class: "ez-text ez-title--large ez-title--primary ez-text--bold ez-margin-vertical--extra-small" }, this.modalTitle), this.modalSubTitle ? h("div", { class: "ez-text ez-text--medium ez-text--primary ez-margin-vertical--extra-small" }, this.modalSubTitle) : undefined), h("button", { ref: ref => this._closeButton = ref, class: "ez-modal-container__close-button", onClick: () => this.ezModalAction.emit(ModalAction$1.CLOSE) }, h("ez-icon", { class: "ez-modal-container__close-icon", size: "medium", iconName: "close" }))), h("div", null, h("slot", null)), h("div", { class: "ez-col ez-margin-left--auto" }, this.cancelIsVisible() ? h("ez-button", { label: this.cancelButtonLabel, enabled: this.cancelButtonStatus !== ModalButtonStatus$1.DISABLED, onClick: () => this.ezModalAction.emit(ModalAction$1.CANCEL) }) : undefined, this.okIsVisible() ? h("ez-button", { ref: ref => this._okButton = ref, label: this.okButtonLabel, enabled: this.okButtonStatus !== ModalButtonStatus$1.DISABLED, class: "ez-button--primary ez-margin-left--medium", onClick: () => this.ezModalAction.emit(ModalAction$1.OK) }) : undefined), h("button", { class: "ez-modal-container__focus-ctrl", onFocusin: evt => this.focusFirst(evt) })));
|
|
50
50
|
}
|
|
51
51
|
};
|
|
52
52
|
EzModalContainer.style = ezModalContainerCss;
|
|
@@ -8,16 +8,16 @@ let EzModal = class {
|
|
|
8
8
|
this.ezCloseModal = createEvent(this, "ezCloseModal", 7);
|
|
9
9
|
this.ezOpenModal = createEvent(this, "ezOpenModal", 7);
|
|
10
10
|
/**
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
* Define se o ez-modal está aberto.
|
|
12
|
+
*/
|
|
13
13
|
this.opened = true;
|
|
14
14
|
/**
|
|
15
|
-
|
|
16
|
-
|
|
15
|
+
* Define se o ez-modal será fechado ao clicar `ESC`.
|
|
16
|
+
*/
|
|
17
17
|
this.closeEsc = false;
|
|
18
18
|
/**
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
* Define se o modal será fechado ao clicar fora do conteúdo.
|
|
20
|
+
*/
|
|
21
21
|
this.closeOutsideClick = false;
|
|
22
22
|
this.handleKeyboardEvent = (ev) => {
|
|
23
23
|
if ((ev === null || ev === void 0 ? void 0 : ev.key) === "Escape" && this.closeEsc) {
|
|
@@ -12,28 +12,28 @@ let EzNumberInput = class {
|
|
|
12
12
|
this.ezCancelWaitingChange = createEvent(this, "ezCancelWaitingChange", 7);
|
|
13
13
|
this._focused = false;
|
|
14
14
|
/**
|
|
15
|
-
*
|
|
15
|
+
* Se false, o usuário não pode interagir com o campo.
|
|
16
16
|
*/
|
|
17
17
|
this.enabled = true;
|
|
18
18
|
/**
|
|
19
|
-
* Define o
|
|
19
|
+
* Define o tamanho do campo.
|
|
20
20
|
*/
|
|
21
21
|
this.mode = "regular";
|
|
22
22
|
}
|
|
23
23
|
/**
|
|
24
|
-
*
|
|
24
|
+
* Aplica o foco no campo.
|
|
25
25
|
*/
|
|
26
26
|
async setFocus() {
|
|
27
27
|
this._textInput.setFocus();
|
|
28
28
|
}
|
|
29
29
|
/**
|
|
30
|
-
* Remove o foco
|
|
30
|
+
* Remove o foco do campo.
|
|
31
31
|
*/
|
|
32
32
|
async setBlur() {
|
|
33
33
|
this._textInput.setBlur();
|
|
34
34
|
}
|
|
35
35
|
/**
|
|
36
|
-
* Retorna
|
|
36
|
+
* Retorna se o conteúdo é inválido.
|
|
37
37
|
*/
|
|
38
38
|
async isInvalid() {
|
|
39
39
|
return typeof this.errorMessage === "string" && this.errorMessage.trim() !== "";
|
|
@@ -9,29 +9,27 @@ let EzPopover = class {
|
|
|
9
9
|
this.ezVisibilityChange = createEvent(this, "ezVisibilityChange", 7);
|
|
10
10
|
this._firstRender = true;
|
|
11
11
|
/**
|
|
12
|
-
*
|
|
13
|
-
* quando o método show() for acionado.
|
|
12
|
+
* Define que será fechado automaticamente quando o usuário clicar fora do conteúdo.
|
|
14
13
|
*/
|
|
15
14
|
this.autoClose = true;
|
|
16
15
|
/**
|
|
17
|
-
*
|
|
16
|
+
* Define a distância do topo. Devem ser usados valores válidos de CSS.
|
|
18
17
|
*/
|
|
19
18
|
this.top = "0px";
|
|
20
19
|
/**
|
|
21
|
-
*
|
|
20
|
+
* Define a distância do lado esquerdo. Devem ser usados valores válidos de CSS.
|
|
22
21
|
*/
|
|
23
22
|
this.left = "0px";
|
|
24
23
|
/**
|
|
25
|
-
*
|
|
24
|
+
* Define a distância de baixo. Devem ser usados valores válidos de CSS.
|
|
26
25
|
*/
|
|
27
26
|
this.bottom = "0px";
|
|
28
27
|
/**
|
|
29
|
-
*
|
|
28
|
+
* Define a distância do lado direito. Devem ser usados valores válidos de CSS.
|
|
30
29
|
*/
|
|
31
30
|
this.right = "0px";
|
|
32
31
|
/**
|
|
33
32
|
* Ajusta o comportamento da largura do popover.
|
|
34
|
-
* Opções: "100% e "fit-content" (default)
|
|
35
33
|
*/
|
|
36
34
|
this.boxWidth = "fit-content";
|
|
37
35
|
this.innerClickTest = (_popOvercontainer, node, eventOrigin) => {
|
|
@@ -82,7 +80,7 @@ let EzPopover = class {
|
|
|
82
80
|
}
|
|
83
81
|
}
|
|
84
82
|
/**
|
|
85
|
-
* Atualiza a posição do popover
|
|
83
|
+
* Atualiza a posição do popover.
|
|
86
84
|
*/
|
|
87
85
|
async updatePosition(top = this.top, left = this.left, bottom = this.bottom, right = this.right) {
|
|
88
86
|
const floatingOptions = {
|
|
@@ -97,7 +95,7 @@ let EzPopover = class {
|
|
|
97
95
|
FloatingManager.updateFloatPosition(this._box, this._container, floatingOptions);
|
|
98
96
|
}
|
|
99
97
|
/**
|
|
100
|
-
*
|
|
98
|
+
* Exibe o ez-popover.
|
|
101
99
|
*/
|
|
102
100
|
async show(top = this.top, left = this.left, bottom = this.bottom, right = this.right) {
|
|
103
101
|
const floatingOptions = {
|
|
@@ -113,7 +111,7 @@ let EzPopover = class {
|
|
|
113
111
|
this.opened = true;
|
|
114
112
|
}
|
|
115
113
|
/**
|
|
116
|
-
*
|
|
114
|
+
* Oculta o ez-popover.
|
|
117
115
|
*/
|
|
118
116
|
async hide() {
|
|
119
117
|
if (this._floatingID !== undefined) {
|
|
@@ -14,20 +14,19 @@ let EzPopup = class {
|
|
|
14
14
|
"x-large": "col--sd-11"
|
|
15
15
|
};
|
|
16
16
|
/**
|
|
17
|
-
* Define
|
|
18
|
-
* compreendidos em [x-small | small | medium | large | x-large].
|
|
17
|
+
* Define a largura do ez-popup.
|
|
19
18
|
*/
|
|
20
19
|
this.size = "medium";
|
|
21
20
|
/**
|
|
22
|
-
*
|
|
21
|
+
* Define se o ez-popover está aberto.
|
|
23
22
|
*/
|
|
24
23
|
this.opened = false;
|
|
25
24
|
/**
|
|
26
|
-
* Define se o componente utilizará
|
|
25
|
+
* Define se o componente utilizará cabeçalho.
|
|
27
26
|
*/
|
|
28
27
|
this.useHeader = true;
|
|
29
28
|
/**
|
|
30
|
-
* Define
|
|
29
|
+
* Define altura do componente.
|
|
31
30
|
*/
|
|
32
31
|
this.heightMode = "full";
|
|
33
32
|
}
|