@sankhyalabs/ezui 0.0.0-bugfix-dev-KB-52057.0 → 0.0.0-bugfix-dev-59880.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/ICustomRender-6fafffce.js +13 -0
- package/dist/cjs/ez-actions-button.cjs.entry.js +1 -0
- package/dist/cjs/ez-alert-list.cjs.entry.js +6 -4
- package/dist/cjs/ez-button.cjs.entry.js +2 -2
- package/dist/cjs/ez-collapsible-box.cjs.entry.js +1 -0
- package/dist/cjs/ez-combo-box.cjs.entry.js +1 -0
- package/dist/cjs/{ez-text-edit.cjs.entry.js → ez-custom-form-input_2.cjs.entry.js} +86 -0
- package/dist/cjs/ez-date-input.cjs.entry.js +1 -0
- package/dist/cjs/ez-form-view.cjs.entry.js +36 -4
- package/dist/cjs/ez-form.cjs.entry.js +51 -2
- package/dist/cjs/ez-grid.cjs.entry.js +322 -19
- package/dist/cjs/ez-list.cjs.entry.js +1 -1
- package/dist/cjs/ez-modal-container.cjs.entry.js +2 -2
- package/dist/cjs/ez-number-input.cjs.entry.js +9 -2
- package/dist/cjs/ez-search.cjs.entry.js +6 -2
- package/dist/cjs/ez-split-item.cjs.entry.js +2 -1
- package/dist/cjs/ezui.cjs.js +1 -1
- package/dist/cjs/index-a7b0c73d.js +4 -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.js +6 -4
- package/dist/collection/components/ez-button/ez-button.css +7 -0
- package/dist/collection/components/ez-button/ez-button.js +1 -1
- package/dist/collection/components/ez-date-input/ez-date-input.js +1 -0
- package/dist/collection/components/ez-form/ez-form.js +130 -4
- package/dist/collection/components/ez-form-view/custom-input/ez-custom-form-input.js +245 -0
- package/dist/collection/components/ez-form-view/ez-form-view.js +92 -2
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/NumberInput.tpl.js +3 -2
- package/dist/collection/components/ez-grid/controller/ag-grid/AgGridController.js +62 -4
- package/dist/collection/components/ez-grid/controller/ag-grid/GridEditionManager.js +35 -1
- package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomCellEditor.js +58 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomCellRender.js +40 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/components/test/constants/EzGridCustomCellEditorConstants.js +11 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/components/test/constants/EzGridCustomCellRenderConstants.js +11 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/EzCellEditor.js +6 -3
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/EzCellRender.js +40 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/IUICellRender.js +1 -0
- package/dist/collection/components/ez-grid/ez-grid.js +206 -2
- package/dist/collection/components/ez-grid/interfaces/ICustomFormatter.js +1 -0
- package/dist/collection/components/ez-grid/interfaces/index.js +1 -0
- package/dist/collection/components/ez-grid/subcomponents/selection-counter.js +3 -11
- package/dist/collection/components/ez-grid/subcomponents/utils/selectionCounterUtils.js +22 -0
- package/dist/collection/components/ez-grid/test/resources/gridDataUnit.js +19 -0
- package/dist/collection/components/ez-list/ez-list.css +6 -2
- package/dist/collection/components/ez-modal-container/ez-modal-container.css +4 -0
- package/dist/collection/components/ez-modal-container/ez-modal-container.js +1 -1
- package/dist/collection/components/ez-number-input/ez-number-input.js +12 -1
- package/dist/collection/components/ez-search/ez-search.js +5 -2
- package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.js +1 -1
- package/dist/collection/utils/customEditor/interfaces/ICustomEditor.js +5 -0
- package/dist/collection/utils/customEditor/interfaces/ICustomEditorInfo.js +1 -0
- package/dist/collection/utils/customRender/interfaces/ICustomRender.js +5 -0
- package/dist/collection/utils/customRender/interfaces/ICustomRenderInfo.js +1 -0
- package/dist/collection/utils/index.js +2 -0
- package/dist/custom-elements/index.d.ts +6 -0
- package/dist/custom-elements/index.js +539 -44
- package/dist/esm/ICustomRender-875b5a40.js +13 -0
- package/dist/esm/ez-actions-button.entry.js +1 -0
- package/dist/esm/ez-alert-list.entry.js +6 -4
- package/dist/esm/ez-button.entry.js +2 -2
- package/dist/esm/ez-collapsible-box.entry.js +1 -0
- package/dist/esm/ez-combo-box.entry.js +1 -0
- package/dist/esm/{ez-text-edit.entry.js → ez-custom-form-input_2.entry.js} +88 -3
- package/dist/esm/ez-date-input.entry.js +1 -0
- package/dist/esm/ez-form-view.entry.js +36 -4
- package/dist/esm/ez-form.entry.js +51 -2
- package/dist/esm/ez-grid.entry.js +322 -19
- package/dist/esm/ez-list.entry.js +1 -1
- package/dist/esm/ez-modal-container.entry.js +2 -2
- package/dist/esm/ez-number-input.entry.js +9 -2
- package/dist/esm/ez-search.entry.js +6 -2
- package/dist/esm/ez-split-item.entry.js +2 -1
- package/dist/esm/ezui.js +1 -1
- package/dist/esm/index-baa5e267.js +4 -4
- package/dist/esm/loader.js +1 -1
- package/dist/ezui/ezui.esm.js +1 -1
- package/dist/ezui/p-09de35a2.entry.js +1 -0
- package/dist/ezui/p-13d2fe2d.entry.js +1 -0
- package/dist/ezui/{p-384247cd.entry.js → p-1f96ba9a.entry.js} +2 -2
- package/dist/ezui/p-204b1439.entry.js +1 -0
- package/dist/ezui/p-2b8da3a4.entry.js +1 -0
- package/dist/ezui/p-30775e7f.entry.js +1 -0
- package/dist/ezui/p-4607fb89.js +1 -0
- package/dist/ezui/{p-2a1a0e04.entry.js → p-77362d3a.entry.js} +1 -1
- package/dist/ezui/{p-8defa6d3.entry.js → p-786559c5.entry.js} +1 -1
- package/dist/ezui/p-7922142b.entry.js +1 -0
- package/dist/ezui/p-84e439b9.entry.js +1 -0
- package/dist/ezui/p-922ac38b.entry.js +1 -0
- package/dist/ezui/p-bae4e180.entry.js +1 -0
- package/dist/ezui/p-bcb53f27.entry.js +1 -0
- package/dist/ezui/p-c942e4a7.entry.js +1 -0
- package/dist/ezui/p-e90dd4eb.entry.js +1 -0
- package/dist/types/components/ez-alert-list/ez-alert-list.d.ts +2 -2
- package/dist/types/components/ez-form/ez-form.d.ts +20 -1
- package/dist/types/components/ez-form-view/custom-input/ez-custom-form-input.d.ts +41 -0
- package/dist/types/components/ez-form-view/ez-form-view.d.ts +11 -0
- package/dist/types/components/ez-grid/controller/EzGridController.d.ts +29 -0
- package/dist/types/components/ez-grid/controller/ag-grid/AgGridController.d.ts +11 -0
- package/dist/types/components/ez-grid/controller/ag-grid/GridEditionManager.d.ts +7 -1
- package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomCellEditor.d.ts +19 -0
- package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomCellRender.d.ts +14 -0
- package/dist/types/components/ez-grid/controller/ag-grid/components/test/constants/EzGridCustomCellEditorConstants.d.ts +11 -0
- package/dist/types/components/ez-grid/controller/ag-grid/components/test/constants/EzGridCustomCellRenderConstants.d.ts +11 -0
- package/dist/types/components/ez-grid/controller/ag-grid/editor/EzCellEditor.d.ts +3 -0
- package/dist/types/components/ez-grid/controller/ag-grid/editor/EzCellRender.d.ts +15 -0
- package/dist/types/components/ez-grid/controller/ag-grid/editor/IUICellRender.d.ts +10 -0
- package/dist/types/components/ez-grid/ez-grid.d.ts +30 -1
- package/dist/types/components/ez-grid/interfaces/ICustomFormatter.d.ts +5 -0
- package/dist/types/components/ez-grid/interfaces/index.d.ts +1 -0
- package/dist/types/components/ez-grid/subcomponents/utils/selectionCounterUtils.d.ts +4 -0
- package/dist/types/components/ez-grid/test/resources/gridDataUnit.d.ts +2 -0
- package/dist/types/components/ez-number-input/ez-number-input.d.ts +1 -0
- package/dist/types/components.d.ts +120 -4
- package/dist/types/utils/customEditor/interfaces/ICustomEditor.d.ts +29 -0
- package/dist/types/utils/customEditor/interfaces/ICustomEditorInfo.d.ts +5 -0
- package/dist/types/utils/customRender/interfaces/ICustomRender.d.ts +29 -0
- package/dist/types/utils/customRender/interfaces/ICustomRenderInfo.d.ts +5 -0
- package/dist/types/utils/index.d.ts +2 -0
- package/package.json +1 -1
- package/react/components.d.ts +1 -0
- package/react/components.js +1 -0
- package/react/components.js.map +1 -1
- package/dist/ezui/p-0447d17c.entry.js +0 -1
- package/dist/ezui/p-20ec22c0.entry.js +0 -1
- package/dist/ezui/p-44c5b6a5.entry.js +0 -1
- package/dist/ezui/p-5ef056ce.entry.js +0 -1
- package/dist/ezui/p-86ff298d.entry.js +0 -1
- package/dist/ezui/p-99ead599.entry.js +0 -1
- package/dist/ezui/p-9aefaa52.entry.js +0 -1
- package/dist/ezui/p-9f1e89c9.entry.js +0 -1
- package/dist/ezui/p-b041333c.entry.js +0 -1
- package/dist/ezui/p-b567fa8c.entry.js +0 -1
- package/dist/ezui/p-bae3d0aa.entry.js +0 -1
- package/dist/ezui/p-db77a984.entry.js +0 -1
|
@@ -4,6 +4,7 @@ import { SelectionMode } from '@sankhyalabs/core/dist/dataunit/DataUnit';
|
|
|
4
4
|
import { A as ApplicationUtils } from './ApplicationUtils-eaf91331.js';
|
|
5
5
|
import './DialogType-54a62731.js';
|
|
6
6
|
import './CheckMode-bdb2ec19.js';
|
|
7
|
+
import { C as CustomEditorSource, a as CustomRenderSource } from './ICustomRender-875b5a40.js';
|
|
7
8
|
import { D as DISTINCT_FILTER_NAME_PREFIX, E as EZ_GRID_LOADING_SOURCE } from './constants-4e0d35b7.js';
|
|
8
9
|
import { b as buildFieldMetadata, R as RecordValidationProcessor } from './RecordValidationProcessor-b00b8b77.js';
|
|
9
10
|
|
|
@@ -119410,9 +119411,9 @@ class EzCellEditor {
|
|
|
119410
119411
|
init(params) {
|
|
119411
119412
|
const fieldName = params.column.getColId();
|
|
119412
119413
|
const dataUnit = params.context.dataUnit;
|
|
119413
|
-
|
|
119414
|
-
const builder = uiBuilders.get(
|
|
119415
|
-
this._gui = builder(
|
|
119414
|
+
this._fieldMetadata = buildEditorMetadata(dataUnit.getField(fieldName), params.eGridCell, dataUnit, params.context.editionManager);
|
|
119415
|
+
const builder = uiBuilders.get(this._fieldMetadata.userInterface) || buildTextInput;
|
|
119416
|
+
this._gui = builder(this._fieldMetadata);
|
|
119416
119417
|
if (this._gui.valueSetter != undefined) {
|
|
119417
119418
|
this._gui.valueSetter(params.value);
|
|
119418
119419
|
}
|
|
@@ -119436,10 +119437,147 @@ class EzCellEditor {
|
|
|
119436
119437
|
isPopup() {
|
|
119437
119438
|
return this._gui.isPopUp;
|
|
119438
119439
|
}
|
|
119440
|
+
getFieldMetadata() {
|
|
119441
|
+
return this._fieldMetadata;
|
|
119442
|
+
}
|
|
119443
|
+
}
|
|
119444
|
+
|
|
119445
|
+
class EzGridCustomCellEditor extends EzCellEditor {
|
|
119446
|
+
init(params) {
|
|
119447
|
+
var _a, _b;
|
|
119448
|
+
this._value = params.value;
|
|
119449
|
+
this._fieldName = params.column.getColId();
|
|
119450
|
+
this._customEditorInstance = params.customEditorsInfo.customEditor;
|
|
119451
|
+
super.init(params);
|
|
119452
|
+
this._defaultGui = this.getDefaultGui();
|
|
119453
|
+
const fieldMetadata = super.getFieldMetadata();
|
|
119454
|
+
this._params = {
|
|
119455
|
+
value: params.value,
|
|
119456
|
+
charPress: params.charPress,
|
|
119457
|
+
currentEditor: this._defaultGui,
|
|
119458
|
+
name: this._fieldName,
|
|
119459
|
+
source: CustomEditorSource.GRID,
|
|
119460
|
+
detailContext: params.customEditorsInfo.detailContext,
|
|
119461
|
+
setValue: (value) => this.setValue(value),
|
|
119462
|
+
getValue: () => this.getValue(),
|
|
119463
|
+
editorMetadata: {
|
|
119464
|
+
hidden: ((_a = fieldMetadata.props) === null || _a === void 0 ? void 0 : _a.visible) === false,
|
|
119465
|
+
label: fieldMetadata.label,
|
|
119466
|
+
userInterface: fieldMetadata.userInterface,
|
|
119467
|
+
props: fieldMetadata.props,
|
|
119468
|
+
optionLoader: fieldMetadata.optionLoader,
|
|
119469
|
+
options: ((_b = fieldMetadata.props) === null || _b === void 0 ? void 0 : _b.options) || {},
|
|
119470
|
+
}
|
|
119471
|
+
};
|
|
119472
|
+
}
|
|
119473
|
+
getDefaultGui() {
|
|
119474
|
+
const gui = super.getGui();
|
|
119475
|
+
gui.value = this._value;
|
|
119476
|
+
gui.onkeyup = (event) => {
|
|
119477
|
+
const value = event.target.value;
|
|
119478
|
+
this.setValue(value);
|
|
119479
|
+
};
|
|
119480
|
+
return gui;
|
|
119481
|
+
}
|
|
119482
|
+
getGui() {
|
|
119483
|
+
const editorElement = this._customEditorInstance.getEditorElement(this._params);
|
|
119484
|
+
if (!editorElement) {
|
|
119485
|
+
return this._defaultGui;
|
|
119486
|
+
}
|
|
119487
|
+
if (typeof editorElement === 'string') {
|
|
119488
|
+
const element = HTMLBuilder.parseElement(editorElement);
|
|
119489
|
+
return element;
|
|
119490
|
+
}
|
|
119491
|
+
return editorElement;
|
|
119492
|
+
}
|
|
119493
|
+
setValue(value) {
|
|
119494
|
+
this._value = value;
|
|
119495
|
+
}
|
|
119496
|
+
getValue() {
|
|
119497
|
+
return this._value;
|
|
119498
|
+
}
|
|
119499
|
+
}
|
|
119500
|
+
|
|
119501
|
+
class EzCellRender {
|
|
119502
|
+
init(params) {
|
|
119503
|
+
const span = document.createElement('span');
|
|
119504
|
+
this._currentParams = params;
|
|
119505
|
+
span.textContent = params.value;
|
|
119506
|
+
const fieldName = params.column.getColId();
|
|
119507
|
+
const dataUnit = params.context.dataUnit;
|
|
119508
|
+
this._fieldMetadata = buildEditorMetadata(dataUnit.getField(fieldName), params.eGridCell, dataUnit, params.context.editionManager);
|
|
119509
|
+
this._gui = span;
|
|
119510
|
+
}
|
|
119511
|
+
refresh() {
|
|
119512
|
+
try {
|
|
119513
|
+
this._currentParams.refreshCell();
|
|
119514
|
+
return true;
|
|
119515
|
+
}
|
|
119516
|
+
catch (_a) {
|
|
119517
|
+
return false;
|
|
119518
|
+
}
|
|
119519
|
+
}
|
|
119520
|
+
getGui() {
|
|
119521
|
+
return this._gui;
|
|
119522
|
+
}
|
|
119523
|
+
afterGuiAttached() {
|
|
119524
|
+
this.focusIn();
|
|
119525
|
+
}
|
|
119526
|
+
focusIn() {
|
|
119527
|
+
this._gui.focus();
|
|
119528
|
+
this._gui.setFocus({ selectText: true });
|
|
119529
|
+
}
|
|
119530
|
+
getValue() {
|
|
119531
|
+
return this._currentParams.getValue();
|
|
119532
|
+
}
|
|
119533
|
+
isPopup() {
|
|
119534
|
+
return this._gui.isPopUp;
|
|
119535
|
+
}
|
|
119536
|
+
getFieldMetadata() {
|
|
119537
|
+
return this._fieldMetadata;
|
|
119538
|
+
}
|
|
119539
|
+
}
|
|
119540
|
+
|
|
119541
|
+
class EzGridCustomCellRender extends EzCellRender {
|
|
119542
|
+
init(params) {
|
|
119543
|
+
var _a, _b;
|
|
119544
|
+
this._fieldName = params.column.getColId();
|
|
119545
|
+
this._customRenderInstance = params.customRendersInfo.customRender;
|
|
119546
|
+
super.init(params);
|
|
119547
|
+
const fieldMetadata = super.getFieldMetadata();
|
|
119548
|
+
this._params = {
|
|
119549
|
+
value: params.value,
|
|
119550
|
+
charPress: '',
|
|
119551
|
+
currentRender: super.getGui(),
|
|
119552
|
+
name: this._fieldName,
|
|
119553
|
+
source: CustomRenderSource.GRID,
|
|
119554
|
+
getValue: () => params.getValue(),
|
|
119555
|
+
detailContext: params.customRendersInfo.detailContext,
|
|
119556
|
+
renderMetadata: {
|
|
119557
|
+
hidden: ((_a = fieldMetadata.props) === null || _a === void 0 ? void 0 : _a.visible) === false,
|
|
119558
|
+
label: fieldMetadata.label,
|
|
119559
|
+
userInterface: fieldMetadata.userInterface,
|
|
119560
|
+
props: fieldMetadata.props,
|
|
119561
|
+
optionLoader: fieldMetadata.optionLoader,
|
|
119562
|
+
options: ((_b = fieldMetadata.props) === null || _b === void 0 ? void 0 : _b.options) || {},
|
|
119563
|
+
}
|
|
119564
|
+
};
|
|
119565
|
+
}
|
|
119566
|
+
getGui() {
|
|
119567
|
+
const editorElement = this._customRenderInstance.getRenderElement(this._params);
|
|
119568
|
+
if (!editorElement) {
|
|
119569
|
+
return super.getGui();
|
|
119570
|
+
}
|
|
119571
|
+
if (typeof editorElement === 'string') {
|
|
119572
|
+
const element = HTMLBuilder.parseElement(editorElement);
|
|
119573
|
+
return element;
|
|
119574
|
+
}
|
|
119575
|
+
return editorElement;
|
|
119576
|
+
}
|
|
119439
119577
|
}
|
|
119440
119578
|
|
|
119441
119579
|
class GridEditionManager {
|
|
119442
|
-
constructor(dataUnit, useEnterLikeTab, recordsValidator, editionIsDisabled) {
|
|
119580
|
+
constructor(dataUnit, useEnterLikeTab, recordsValidator, editionIsDisabled, customEditors, customRenders) {
|
|
119443
119581
|
this._dataUnit = dataUnit;
|
|
119444
119582
|
this._recordValidationProcessor = new RecordValidationProcessor(this._dataUnit, {
|
|
119445
119583
|
getRequiredFields: () => this.getRequiredFields(),
|
|
@@ -119448,6 +119586,8 @@ class GridEditionManager {
|
|
|
119448
119586
|
}, recordsValidator);
|
|
119449
119587
|
this._useEnterLikeTab = useEnterLikeTab;
|
|
119450
119588
|
this._editionIsDisabled = editionIsDisabled;
|
|
119589
|
+
this._customEditors = customEditors;
|
|
119590
|
+
this._customRenders = customRenders;
|
|
119451
119591
|
}
|
|
119452
119592
|
configureGrid(options) {
|
|
119453
119593
|
this._gridOptions = options;
|
|
@@ -119514,6 +119654,30 @@ class GridEditionManager {
|
|
|
119514
119654
|
col.suppressKeyboardEvent = (params) => {
|
|
119515
119655
|
return params.event.key === KeyCode.ENTER;
|
|
119516
119656
|
};
|
|
119657
|
+
col.cellEditorSelector = (params) => {
|
|
119658
|
+
var _a;
|
|
119659
|
+
if ((_a = this._customEditors) === null || _a === void 0 ? void 0 : _a.has(params.colDef.field)) {
|
|
119660
|
+
const customEditor = this._customEditors.get(params.colDef.field);
|
|
119661
|
+
return {
|
|
119662
|
+
component: EzGridCustomCellEditor,
|
|
119663
|
+
params: {
|
|
119664
|
+
customEditorsInfo: customEditor,
|
|
119665
|
+
}
|
|
119666
|
+
};
|
|
119667
|
+
}
|
|
119668
|
+
};
|
|
119669
|
+
col.cellRendererSelector = (params) => {
|
|
119670
|
+
var _a;
|
|
119671
|
+
if ((_a = this._customRenders) === null || _a === void 0 ? void 0 : _a.has(params.colDef.field)) {
|
|
119672
|
+
const customRender = this._customRenders.get(params.colDef.field);
|
|
119673
|
+
return {
|
|
119674
|
+
component: EzGridCustomCellRender,
|
|
119675
|
+
params: {
|
|
119676
|
+
customRendersInfo: customRender,
|
|
119677
|
+
}
|
|
119678
|
+
};
|
|
119679
|
+
}
|
|
119680
|
+
};
|
|
119517
119681
|
return col;
|
|
119518
119682
|
}
|
|
119519
119683
|
getRequiredFields() {
|
|
@@ -119655,6 +119819,12 @@ class GridEditionManager {
|
|
|
119655
119819
|
this._lastCellEdited = { rowIndex: event.rowIndex, column: event.column, rowPinned: undefined };
|
|
119656
119820
|
}
|
|
119657
119821
|
}
|
|
119822
|
+
setCellEditors(customEditors) {
|
|
119823
|
+
this._customEditors = customEditors;
|
|
119824
|
+
}
|
|
119825
|
+
setCellRenders(customRenders) {
|
|
119826
|
+
this._customRenders = customRenders;
|
|
119827
|
+
}
|
|
119658
119828
|
}
|
|
119659
119829
|
class TargetEdition {
|
|
119660
119830
|
constructor(rowIndex, column, backwards) {
|
|
@@ -119699,6 +119869,7 @@ class AgGridController {
|
|
|
119699
119869
|
this._gridConfig = [];
|
|
119700
119870
|
this._filteredColumns = new Map();
|
|
119701
119871
|
this._filterColumnleftPosition = 0;
|
|
119872
|
+
this._customFormatters = new Map();
|
|
119702
119873
|
this._enterprise = enterprise;
|
|
119703
119874
|
}
|
|
119704
119875
|
getGridConfig() {
|
|
@@ -119782,7 +119953,7 @@ class AgGridController {
|
|
|
119782
119953
|
this._doubleClickCallBack = options.onDoubleClick;
|
|
119783
119954
|
this._multipleSelection = options.allowMultipleSelection;
|
|
119784
119955
|
this._dataUnit = options.dataUnit;
|
|
119785
|
-
this._editionManager = new GridEditionManager(this._dataUnit, options.useEnterLikeTab, options.recordsValidator, options.editionIsDisabled);
|
|
119956
|
+
this._editionManager = new GridEditionManager(this._dataUnit, options.useEnterLikeTab, options.recordsValidator, options.editionIsDisabled, options.customEditors || this._customEditors, options.customRenders || this._customRenders);
|
|
119786
119957
|
this._statusResolver = options.statusResolver;
|
|
119787
119958
|
if (this._dataUnit) {
|
|
119788
119959
|
this._dataUnit.sortingProvider = this;
|
|
@@ -119814,6 +119985,13 @@ class AgGridController {
|
|
|
119814
119985
|
headerCheckStatusGetter: () => this.getSelectionHeaderStatus(),
|
|
119815
119986
|
headerCheckStatusSetter: (selectAll) => this.updateSelectionForAll(selectAll),
|
|
119816
119987
|
},
|
|
119988
|
+
processCellForClipboard: this.processFormatterCellCallback,
|
|
119989
|
+
defaultExcelExportParams: {
|
|
119990
|
+
processCellCallback: this.processFormatterCellCallback
|
|
119991
|
+
},
|
|
119992
|
+
defaultCsvExportParams: {
|
|
119993
|
+
processCellCallback: this.processFormatterCellCallback
|
|
119994
|
+
}
|
|
119817
119995
|
};
|
|
119818
119996
|
this.defineRowModelType(this._gridOptions, options);
|
|
119819
119997
|
this.setOptionsEvents(this._gridOptions);
|
|
@@ -119837,7 +120015,25 @@ class AgGridController {
|
|
|
119837
120015
|
this.selectRows((selection === null || selection === void 0 ? void 0 : selection.recordIds) || [], true);
|
|
119838
120016
|
}
|
|
119839
120017
|
this._gridOptions.api.setHeaderHeight(this.getHeaderRowHeight());
|
|
120018
|
+
this._customFormatters = options.customFormatters;
|
|
120019
|
+
}
|
|
120020
|
+
}
|
|
120021
|
+
processFormatterCellCallback(params) {
|
|
120022
|
+
const column = params.column.getColDef();
|
|
120023
|
+
if (typeof column.valueFormatter === 'function') {
|
|
120024
|
+
const valueParams = {
|
|
120025
|
+
value: params.value,
|
|
120026
|
+
data: params.node.data,
|
|
120027
|
+
node: params.node,
|
|
120028
|
+
colDef: column,
|
|
120029
|
+
column: params.column,
|
|
120030
|
+
api: params.api,
|
|
120031
|
+
columnApi: params.columnApi,
|
|
120032
|
+
context: params.context,
|
|
120033
|
+
};
|
|
120034
|
+
return column.valueFormatter(valueParams);
|
|
119840
120035
|
}
|
|
120036
|
+
return params.value;
|
|
119841
120037
|
}
|
|
119842
120038
|
setFilterColumnLeftPosition({ type, ePopup }) {
|
|
119843
120039
|
if (type === 'columnMenu') {
|
|
@@ -120187,7 +120383,7 @@ class AgGridController {
|
|
|
120187
120383
|
//Como vamos reordenar, precisamos considerar o deslocamento provocado por elas.
|
|
120188
120384
|
const columnsOffset = colDef.length - columns.length;
|
|
120189
120385
|
let sort = [];
|
|
120190
|
-
state.forEach((cfgColumn, index) => {
|
|
120386
|
+
state === null || state === void 0 ? void 0 : state.forEach((cfgColumn, index) => {
|
|
120191
120387
|
const colWidth = this.getColumnWidth(cfgColumn);
|
|
120192
120388
|
this._gridOptions.columnApi.moveColumn(cfgColumn.name, index + columnsOffset);
|
|
120193
120389
|
this._gridOptions.columnApi.setColumnWidth(cfgColumn.name, colWidth);
|
|
@@ -120290,6 +120486,13 @@ class AgGridController {
|
|
|
120290
120486
|
if (params.value instanceof Promise) {
|
|
120291
120487
|
return "Carregando...";
|
|
120292
120488
|
}
|
|
120489
|
+
const customFormatter = this._customFormatters.get(source.name);
|
|
120490
|
+
if (customFormatter) {
|
|
120491
|
+
const formattedValue = customFormatter.format(params.value, source, params.data.__record__id__);
|
|
120492
|
+
if (formattedValue) {
|
|
120493
|
+
return formattedValue;
|
|
120494
|
+
}
|
|
120495
|
+
}
|
|
120293
120496
|
if (this._dataUnit) {
|
|
120294
120497
|
return this._dataUnit.getFormattedValue(source.name, params.value);
|
|
120295
120498
|
}
|
|
@@ -120298,6 +120501,13 @@ class AgGridController {
|
|
|
120298
120501
|
cellStyle: this.getStyleByColumn(source),
|
|
120299
120502
|
});
|
|
120300
120503
|
}
|
|
120504
|
+
setCustomFormatters(customFormatters) {
|
|
120505
|
+
this._customFormatters = customFormatters;
|
|
120506
|
+
}
|
|
120507
|
+
refreshSelectedRows() {
|
|
120508
|
+
const selectedNodes = this._gridOptions.api.getSelectedNodes();
|
|
120509
|
+
this._gridOptions.api.redrawRows({ rowNodes: selectedNodes });
|
|
120510
|
+
}
|
|
120301
120511
|
getInitCellStyle() {
|
|
120302
120512
|
return {
|
|
120303
120513
|
'line-height': this.getRowHeight() - 1 + 'px',
|
|
@@ -120473,11 +120683,52 @@ class AgGridController {
|
|
|
120473
120683
|
const labelSize = (((_b = field === null || field === void 0 ? void 0 : field.label) === null || _b === void 0 ? void 0 : _b.length) || 0) * this.DEFAULT_FONT_SIZE + this.DEFAULT_ICON_SIZE;
|
|
120474
120684
|
return labelSize > this.DEFAULT_MAX_SIZE ? this.DEFAULT_MAX_SIZE : labelSize;
|
|
120475
120685
|
}
|
|
120686
|
+
setCellEditors(customEditors) {
|
|
120687
|
+
var _a;
|
|
120688
|
+
if (!this._editionManager) {
|
|
120689
|
+
this._customEditors = customEditors;
|
|
120690
|
+
return;
|
|
120691
|
+
}
|
|
120692
|
+
this._editionManager.setCellEditors(customEditors);
|
|
120693
|
+
(_a = this._gridOptions) === null || _a === void 0 ? void 0 : _a.api.redrawRows();
|
|
120694
|
+
}
|
|
120695
|
+
setCellRenders(customRenders) {
|
|
120696
|
+
var _a;
|
|
120697
|
+
if (!this._editionManager) {
|
|
120698
|
+
this._customRenders = customRenders;
|
|
120699
|
+
return;
|
|
120700
|
+
}
|
|
120701
|
+
this._editionManager.setCellRenders(customRenders);
|
|
120702
|
+
(_a = this._gridOptions) === null || _a === void 0 ? void 0 : _a.api.redrawRows();
|
|
120703
|
+
}
|
|
120704
|
+
}
|
|
120705
|
+
|
|
120706
|
+
function enableSelectAll(total) {
|
|
120707
|
+
return total !== undefined;
|
|
120708
|
+
}
|
|
120709
|
+
function buildSelectAllLabel(allRecordSelected, count, total) {
|
|
120710
|
+
if (allRecordSelected)
|
|
120711
|
+
return 'Selecionar apenas a página atual';
|
|
120712
|
+
if (total === undefined)
|
|
120713
|
+
return `Carregando todos os ${count} registros`;
|
|
120714
|
+
return `Selecionar todos os ${total} registros`;
|
|
120715
|
+
}
|
|
120716
|
+
function buildSelectAllTitle(total) {
|
|
120717
|
+
if (enableSelectAll(total))
|
|
120718
|
+
return '';
|
|
120719
|
+
return 'Aguarde o carregamento para selecionar o registro de todas as páginas';
|
|
120720
|
+
}
|
|
120721
|
+
function getText(selectionCount, allSelectedRecords) {
|
|
120722
|
+
if (allSelectedRecords) {
|
|
120723
|
+
return `Todos os <strong>${selectionCount} registros</strong> da grade estão selecionados.`;
|
|
120724
|
+
}
|
|
120725
|
+
const pluralCharacter = selectionCount > 1 ? "s" : "";
|
|
120726
|
+
return `Há <strong>${selectionCount} registro${pluralCharacter}</strong> selecionado${pluralCharacter} na grade.`;
|
|
120476
120727
|
}
|
|
120477
120728
|
|
|
120478
120729
|
const SelectionCounter = (props) => {
|
|
120479
120730
|
const { selectionCount, currentPageSelected, allRecordSelected, paginationInfo, canSelectAll, onSelectAll, onSelectPage, onClearAll, onClose } = props;
|
|
120480
|
-
const { total, hasMore } = paginationInfo || {};
|
|
120731
|
+
const { total, hasMore, count } = paginationInfo || {};
|
|
120481
120732
|
const shouldRenderSelectionButton = () => {
|
|
120482
120733
|
if ((!allRecordSelected && selectionCount === total) || (allRecordSelected && !hasMore))
|
|
120483
120734
|
return false;
|
|
@@ -120491,20 +120742,11 @@ const SelectionCounter = (props) => {
|
|
|
120491
120742
|
h("label", Object.assign({ innerHTML: getText(selectionCount, allRecordSelected), class: "ez-text ez-text--primary ez-text--medium ez-margin-right--medium ez-margin-top--medium" }, getElementID("ezGridSelectionCounter_label"))),
|
|
120492
120743
|
h("div", { class: "ez-flex ez-margin-right--medium" },
|
|
120493
120744
|
shouldRenderSelectionButton() &&
|
|
120494
|
-
h("ez-button", Object.assign({ class: "ez-margin-right--medium", label:
|
|
120495
|
-
h("ez-button", Object.assign({ class: "grid__btn-clear", label: "Limpar", mode: "link", onClick: onClearAll }, getElementID("ezGridSelectionCounter_clearAll"))))),
|
|
120745
|
+
h("ez-button", Object.assign({ title: buildSelectAllTitle(total), enabled: enableSelectAll(total), class: "ez-margin-right--medium", label: buildSelectAllLabel(allRecordSelected, count, total), mode: "link", onClick: allRecordSelected ? onSelectPage : onSelectAll }, getElementID(`ezGridSelectionCounter_select${allRecordSelected ? "Page" : "All"}`))),
|
|
120746
|
+
h("ez-button", Object.assign({ class: "grid__btn-clear", label: "Limpar Sele\u00E7\u00E3o", mode: "link", onClick: onClearAll }, getElementID("ezGridSelectionCounter_clearAll"))))),
|
|
120496
120747
|
h("button", Object.assign({ class: "grid__btn-close", title: "Fechar", onClick: onClose }, getElementID("ezGridSelectionCounter_close")),
|
|
120497
120748
|
h("ez-icon", { iconName: "close" })))));
|
|
120498
120749
|
};
|
|
120499
|
-
function getText(selectionCount, allSelectedRecords) {
|
|
120500
|
-
if (allSelectedRecords) {
|
|
120501
|
-
return `Todos os <strong>${selectionCount} registros</strong> da grade estão selecionados.`;
|
|
120502
|
-
}
|
|
120503
|
-
else {
|
|
120504
|
-
const pluralChar = selectionCount > 1 ? "s" : "";
|
|
120505
|
-
return `Há <strong>${selectionCount} registro${pluralChar}</strong> selecionado${pluralChar}.`;
|
|
120506
|
-
}
|
|
120507
|
-
}
|
|
120508
120750
|
function getElementID(sufix) {
|
|
120509
120751
|
return {
|
|
120510
120752
|
[ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: ElementIDUtils.getInternalIDInfo(sufix)
|
|
@@ -120684,6 +120926,8 @@ const EzGrid = class {
|
|
|
120684
120926
|
this.componentReady = createEvent(this, "componentReady", 7);
|
|
120685
120927
|
this._gridController = new AgGridController(false);
|
|
120686
120928
|
this._messageFilterAppliedSuccess = 'Filtro de coluna aplicado com sucesso!';
|
|
120929
|
+
this._customEditor = new Map();
|
|
120930
|
+
this._customRenders = new Map();
|
|
120687
120931
|
this._paginationInfo = undefined;
|
|
120688
120932
|
this._paginationChangedByKeyboard = true;
|
|
120689
120933
|
this._showSelectionCounter = false;
|
|
@@ -120691,6 +120935,7 @@ const EzGrid = class {
|
|
|
120691
120935
|
this._currentPageSelected = undefined;
|
|
120692
120936
|
this._selectionCount = undefined;
|
|
120693
120937
|
this._hasLeftButtons = false;
|
|
120938
|
+
this._customFormatters = new Map();
|
|
120694
120939
|
this.multipleSelection = undefined;
|
|
120695
120940
|
this.config = undefined;
|
|
120696
120941
|
this.selectionToastConfig = undefined;
|
|
@@ -120762,6 +121007,63 @@ const EzGrid = class {
|
|
|
120762
121007
|
async filterColumns(search) {
|
|
120763
121008
|
return Promise.resolve(this._gridController.getColumnsState().filter(col => matches(col.label, search)));
|
|
120764
121009
|
}
|
|
121010
|
+
/**
|
|
121011
|
+
* Registra um editor customizado para campos da grade e formulário.
|
|
121012
|
+
*/
|
|
121013
|
+
async addCustomEditor(fieldName, customEditor, detailContext) {
|
|
121014
|
+
const newCustomEditor = new Map(this._customEditor);
|
|
121015
|
+
newCustomEditor.set(fieldName, {
|
|
121016
|
+
customEditor,
|
|
121017
|
+
detailContext,
|
|
121018
|
+
});
|
|
121019
|
+
this._customEditor = newCustomEditor;
|
|
121020
|
+
this._gridController.setCellEditors(newCustomEditor);
|
|
121021
|
+
}
|
|
121022
|
+
/**
|
|
121023
|
+
* Registra um render customizado para colunas da grid.
|
|
121024
|
+
*/
|
|
121025
|
+
async addGridCustomRender(fieldName, customRender, detailContext) {
|
|
121026
|
+
const newCustomRenders = new Map(this._customRenders);
|
|
121027
|
+
newCustomRenders.set(fieldName, { customRender, detailContext });
|
|
121028
|
+
this._customRenders = newCustomRenders;
|
|
121029
|
+
this._gridController.setCellRenders(newCustomRenders);
|
|
121030
|
+
}
|
|
121031
|
+
/**
|
|
121032
|
+
* Registra um formatador de valores para uma coluna da grid.
|
|
121033
|
+
*/
|
|
121034
|
+
async addCustomValueFormatter(columnName, customFormatter) {
|
|
121035
|
+
if (!columnName || !customFormatter) {
|
|
121036
|
+
return;
|
|
121037
|
+
}
|
|
121038
|
+
const newCustomFormatters = new Map(this._customFormatters);
|
|
121039
|
+
newCustomFormatters.set(columnName, customFormatter);
|
|
121040
|
+
this._customFormatters = newCustomFormatters;
|
|
121041
|
+
this._gridController.setCustomFormatters(newCustomFormatters);
|
|
121042
|
+
}
|
|
121043
|
+
/**
|
|
121044
|
+
* Remove o formatador de valores de uma coluna da grid.
|
|
121045
|
+
*/
|
|
121046
|
+
async removeCustomValueFormatter(columnName) {
|
|
121047
|
+
if (!columnName) {
|
|
121048
|
+
return;
|
|
121049
|
+
}
|
|
121050
|
+
const newCustomFormatters = new Map(this._customFormatters);
|
|
121051
|
+
newCustomFormatters.delete(columnName);
|
|
121052
|
+
this._customFormatters = newCustomFormatters;
|
|
121053
|
+
this._gridController.setCustomFormatters(newCustomFormatters);
|
|
121054
|
+
}
|
|
121055
|
+
/**
|
|
121056
|
+
* Atualiza linhas da grade.
|
|
121057
|
+
*/
|
|
121058
|
+
async refreshSelectedRows() {
|
|
121059
|
+
this._gridController.refreshSelectedRows();
|
|
121060
|
+
}
|
|
121061
|
+
/**
|
|
121062
|
+
* Retorna o formatador customizado da coluna caso exista.
|
|
121063
|
+
*/
|
|
121064
|
+
async getCustomValueFormatter(columnName) {
|
|
121065
|
+
return this._customFormatters.get(columnName);
|
|
121066
|
+
}
|
|
120765
121067
|
observeConfig(config) {
|
|
120766
121068
|
this._gridController.setColumnsState(config === null || config === void 0 ? void 0 : config.columns);
|
|
120767
121069
|
}
|
|
@@ -120963,7 +121265,8 @@ const EzGrid = class {
|
|
|
120963
121265
|
statusResolver: this.statusResolver,
|
|
120964
121266
|
useEnterLikeTab: this.useEnterLikeTab,
|
|
120965
121267
|
recordsValidator: this.recordsValidator,
|
|
120966
|
-
editionIsDisabled: () => !this.canEdit
|
|
121268
|
+
editionIsDisabled: () => !this.canEdit,
|
|
121269
|
+
customFormatters: this._customFormatters
|
|
120967
121270
|
});
|
|
120968
121271
|
if (this.config) {
|
|
120969
121272
|
this.observeConfig(this.config);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as registerInstance, c as createEvent, h, F as Fragment, H as Host } from './index-baa5e267.js';
|
|
2
2
|
import { StringUtils, ElementIDUtils } from '@sankhyalabs/core';
|
|
3
3
|
|
|
4
|
-
const ezListCss = ":host {\n /* @doc Define a camada de visibilidae do componente. */\n --ez-list__host--z-index: var(--visible, 1);\n\n /* @doc Define o raio da borda do componente. */\n --ez-list__host--border-radius: var(--border--radius-medium, 12px);\n\n /* @doc Define o espaçamento entre a lista e o componente. */\n --ez-list__host--padding: var(--space--medium, 12px);\n\n /* @doc Define o espaçamento interno do ícone. */\n --ez-list__icon--padding: var(--space--small, 6px);\n\n /* @doc Define a cor do ícone de arrasto do item da lista. */\n --ez-list__icon--color: #AFB6C0;\n\n /* @doc Define o espaçamento externo do item da lista. */\n --ez-list__item--margin: 0 var(--space--small, 6px);\n\n /* @doc Define a cor do texto do item da lista. */\n --ez-list__item--color: var(--title--primary, #2b3a54);\n\n /* @doc Define o estilo borda inferior do item da lista. */\n --ez-list__item--border-bottom;\n\n /* @doc Define a cor da borda inferior do item da lista. */\n --ez-list__item--border-bottom-color;\n\n /* @doc Define o estilo do texto do item da lista. */\n --ez-list__item--font-family: var(--font-pattern, \"Roboto\");\n\n /* @doc Define o tamanho do texto do item da lista. */\n --ez-list__item--font-size: var(--text--medium, 14px);\n \n /* @doc Define o tipo da quebra de linha do item da lista. */\n --ez-list__item--white-space: var(--ez-list__item--white-space, nowrap);\n\n /* @doc Define o espaçamento lateral direito para items selecionados. */\n --ez-list__selectable--padding-right: var(--space--small, 6px);\n \n /* @doc Define o espaçamento lateral esquerdo para items selecionados. */\n --ez-list__selectable--padding-left: var(--space--small, 6px);\n\n /*@doc Define o raio da borda de items selecionados.*/\n --ez-list__selected-item--border-radius: var(--border--radius-small, 6px);\n \n /*@doc Define a cor de fundo de items selecionados.*/\n --ez-list__selected-item--background-color: var(--color--primary-300, #E2F4EF);\n\n /* @doc Define o estilo do texto do grupo da lista. */\n --ez-list__group--font-family: var(--font-pattern, \"Roboto\");\n \n /* @doc Define o tamanho do texto do grupo da lista. */\n --ez-list__group--font-size: var(--text--medium, 14px);\n \n /* @doc Define o peso do texto do grupo da lista. */\n --ez-list__group--font-weight: var(--text-weight--large, 600);\n \n /* @doc Define o espaçamento inferior do grupo da lista. */\n --ez-list__group--padding-bottom: var(--space-small, 6px);\n\n /* @doc Define o estilo do texto da área de transferência de grupos. */\n --ez-list__group-overlay--font-family: var(--font-pattern, \"Roboto\");\n\n /* @doc Define o tamanho do texto da área de transferência de grupos. */\n --ez-list__group-overlay--font-size: var(--text--medium, 14px);\n \n /* @doc Define a cor da borda pontilhada sobre os elementos da lista. */\n --ez-list__over--border--color: var(--color--primary, #008561);\n\n /*@doc Define a altura do container para arrasto para última posição .*/\n --ez-list__last-droppable-space--height: var(--space--small, 6px);\n \n /*@doc Define o espaçamento do container de itens arrastáveis .*/\n --ez-list__draggable-list--padding-bottom: var(--space--small, 6px);\n\n /* @doc Define a imagem do ícone de drag. */\n --ez-list__draggable-icon--image: url('data:image/svg+xml;utf8,<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m 6.75,2.25 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z\"/></svg>');\n\n /* scrollbar */\n /*@doc Define a cor da barra de rolagem do componente.*/\n --ez-list__scrollbar--color-default: var(--scrollbar--default, #626e82);\n /*@doc Define a cor de fundo da barra de rolagem do componente.*/\n --ez-list__scrollbar--color-background: var(--scrollbar--background, #E5EAF0);\n /*@doc Define a cor do hover na barra de rolagem do componente.*/\n --ez-list__scrollbar--color-hover: var(--scrollbar--hover, #2B3A54);\n /*@doc Define a cor do active na barra de rolagem do componente.*/\n --ez-list__scrollbar--color-clicked: var(--scrollbar--clicked, #a2abb9);\n /*@doc Define o raio da borda da barra de rolagem do componente.*/\n --ez-list__scrollbar--border-radius: var(--border--radius-small, 6px);\n /*@doc Define a largura da barra de rolagem do componente.*/\n --ez-list__scrollbar--width: var(--space--medium, 12px);\n\n max-height: 100%;\n width: 100%;\n background-color: #fff;\n display: flex;\n\n /*public*/\n z-index: var(--ez-list__host--z-index);\n}\n\np {\n margin: 0;\n}\n\n.draggable {\n /* private */\n width: 100%;\n display: grid;\n grid-template-columns: minmax(0px, auto) minmax(0px, auto);\n place-items: center;\n border-top: 1px dashed #fff;\n justify-content: space-between;\n\n /*public*/\n font-family: var(--ez-list__item--font-family);\n font-size: var(--ez-list__item--font-size);\n}\n\n.dragging {\n background: #FFFFFF;\n /* Primary/color--primary */\n\n border: 1px solid #008561;\n box-sizing: border-box;\n box-shadow: 0px 0px 16px rgba(0, 38, 111, 0.122);\n border-radius: 6px;\n}\n\n.selectable {\n cursor: pointer;\n\n /*public*/\n padding-right: var(--ez-list__selectable--padding-right);\n padding-left: var(--ez-list__selectable--padding-left);\n}\n\n.selectable-container {\n margin: 0px !important;\n}\n\n.hover-feedback:hover {\n background-color: var(--background--medium);\n border-radius: var(--border--radius-regular);\n}\n\n.item-content {\n display: flex;\n overflow: hidden;\n justify-content: flex-start;\n width: 100%;\n}\n\n.draggable-list {\n padding: 0;\n margin: 0;\n width: 100%;\n max-height: 100%;\n scrollbar-width: thin;\n \n /*public*/\n color: var(--text-color);\n scrollbar-color: var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background);\n}\n\n.draggable-list li {\n display: flex;\n \n /*public*/\n padding: var(--space--2xs, 8px) var(--space--3xs, 4px);\n margin: var(--ez-list__item--margin);\n font-family: var(--ez-list__item--font-family);\n font-size: var(--ez-list__item--font-size);\n color: var(--ez-list__item--color);\n border-bottom: var(--ez-list__item--border-bottom, none) var(--ez-list__item--border-bottom-color);\n}\n\n.over {\n /*public*/\n border-top: 1px dashed var(--ez-list__over--border--color);\n}\n\n.last-droppable-space {\n /*public*/\n height: var(--ez-list__last-droppable-space--height);\n}\n\n.draggable-selected {\n /*public*/\n background-color: var(--background--strong) !important;\n}\n\n.draggable-selected div:hover {\n /*public*/\n background-color: var(--background--strong) !important;\n}\n\n.draggable-list::-webkit-scrollbar {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n width: var(--ez-list__scrollbar--width);\n max-width: var(--ez-list__scrollbar--width);\n min-width: var(--ez-list__scrollbar--width);\n}\n\n.draggable-list::-webkit-scrollbar-track {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.draggable-list::-webkit-scrollbar-thumb {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-default);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.draggable-list::-webkit-scrollbar-thumb:vertical:hover,\n.draggable-list::-webkit-scrollbar-thumb:horizontal:hover {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-hover);\n}\n\n.draggable-list::-webkit-scrollbar-thumb:vertical:active,\n.draggable-list::-webkit-scrollbar-thumb:horizontal:active {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-clicked);\n}\n\n.draggable-icon {\n align-items: flex-start;\n display: flex;\n outline: none;\n border: none;\n background-color: unset;\n}\n\n.draggable-icon::after {\n content: '';\n display: flex;\n width: 18px;\n height: 18px;\n\n /*public*/\n background-color: var(--ez-list__icon--color);\n -webkit-mask-image: var(--ez-list__draggable-icon--image);\n mask-image: var(--ez-list__draggable-icon--image);\n}\n\n* {\n box-sizing: border-box;\n}\n\n.checkbox {\n width: fit-content;\n}\n\n.text--ellipsis {\n overflow: hidden;\n text-overflow: ellipsis;\n \n /*public*/\n white-space: var(--ez-list__item--white-space);\n}\n\n.group-container {\n display: flex;\n flex-direction: column;\n max-height: 100%;\n overflow-y: auto;\n outline: none;\n width: 100%;\n scrollbar-width: thin;\n\n /*public*/\n scrollbar-color: var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background);\n}\n\n.group-name {\n -webkit-user-select: none;\n -moz-user-select: -moz-none;\n -ms-user-select: none;\n user-select: none;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n\n /*public*/\n color: var(--title--primary);\n font-family: var(--ez-list__group--font-family);\n font-size: var(--ez-list__group--font-size);\n font-weight: var(--ez-list__group--font-weight);\n padding-bottom: var(--ez-list__group--padding-bottom);\n}\n\n.group {\n display: flex;\n flex-direction: column;\n}\n\n.group-container::-webkit-scrollbar {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n width: var(--ez-list__scrollbar--width);\n max-width: var(--ez-list__scrollbar--width);\n min-width: var(--ez-list__scrollbar--width);\n}\n\n.group-container::-webkit-scrollbar-track {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.group-container::-webkit-scrollbar-thumb {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-default);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.group-container::-webkit-scrollbar-thumb:vertical:hover,\n.group-container::-webkit-scrollbar-thumb:horizontal:hover {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-hover);\n}\n\n.group-container::-webkit-scrollbar-thumb:vertical:active,\n.group-container::-webkit-scrollbar-thumb:horizontal:active {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-clicked);\n}\n\n.section-container {\n display: flex;\n position: relative;\n height: 100%;\n}\n\n.items-container {\n width: 100%;\n max-height: 100%;\n outline: none;\n scrollbar-width: thin;\n\n /*public*/\n scrollbar-color: var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background);\n}\n\n.group-items-container {\n width: 100%;\n max-height: 100%;\n height: 100%;\n outline: none;\n}\n\n.items-container::-webkit-scrollbar {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n width: var(--ez-list__scrollbar--width);\n max-width: var(--ez-list__scrollbar--width);\n min-width: var(--ez-list__scrollbar--width);\n}\n\n.items-container::-webkit-scrollbar-track {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.items-container::-webkit-scrollbar-thumb {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-default);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.items-container::-webkit-scrollbar-thumb:vertical:hover,\n.items-container::-webkit-scrollbar-thumb:horizontal:hover {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-hover);\n}\n\n.items-container::-webkit-scrollbar-thumb:vertical:active,\n.items-container::-webkit-scrollbar-thumb:horizontal:active {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-clicked);\n}\n\n.group-overlay {\n background: rgba(226, 244, 239, 0.8);\n border: 1px solid #008561;\n border-radius: 8px;\n position: absolute;\n display: none;\n place-items: center;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n z-index: 2;\n margin: 0;\n cursor: pointer;\n\n /*public*/\n font-family: var(--ez-list__group-overlay--font-family);\n font-size: var(--ez-list__group-overlay--font-size);\n}\n\n.presetedHeight {\n min-height: 100px;\n}\n\n.overlay-text {\n position: absolute;\n top: 50%;\n left: 50%;\n font-size: 50px;\n color: white;\n transform: translate(-50%, -50%);\n -ms-transform: translate(-50%, -50%);\n}\n\n.selected-item {\n /*public*/\n background: var(--ez-list__selected-item--background-color);\n border-radius: var(--ez-list__selected-item--border-radius);\n}\n\n.slot-item {\n align-items: flex-end;\n}\n\n.overGroup {\n background: rgba(226, 244, 239, 0.8);\n border: 1px solid #008561;\n box-sizing: border-box;\n border-radius: 8px;\n padding-top: 6px;\n}";
|
|
4
|
+
const ezListCss = ":host {\n /* @doc Define a camada de visibilidae do componente. */\n --ez-list__host--z-index: var(--visible, 1);\n\n /* @doc Define o raio da borda do componente. */\n --ez-list__host--border-radius: var(--border--radius-medium, 12px);\n\n /* @doc Define o espaçamento entre a lista e o componente. */\n --ez-list__host--padding: var(--space--medium, 12px);\n\n /* @doc Define o espaçamento interno do ícone. */\n --ez-list__icon--padding: var(--space--small, 6px);\n\n /* @doc Define a cor do ícone de arrasto do item da lista. */\n --ez-list__icon--color: #AFB6C0;\n\n /* @doc Define o espaçamento externo do item da lista. */\n --ez-list__item--margin: 0 var(--space--small, 6px);\n\n /* @doc Define a cor do texto do item da lista. */\n --ez-list__item--color: var(--title--primary, #2b3a54);\n\n /* @doc Define o estilo borda inferior do item da lista. */\n --ez-list__item--border-bottom;\n\n /* @doc Define a cor da borda inferior do item da lista. */\n --ez-list__item--border-bottom-color;\n\n /* @doc Define o estilo do texto do item da lista. */\n --ez-list__item--font-family: var(--font-pattern, \"Roboto\");\n\n /* @doc Define o tamanho do texto do item da lista. */\n --ez-list__item--font-size: var(--text--medium, 14px);\n \n /* @doc Define o tipo da quebra de linha do item da lista. */\n --ez-list__item--white-space: var(--ez-list__item--white-space, nowrap);\n\n /* @doc Define o espaçamento lateral direito para items selecionados. */\n --ez-list__selectable--padding-right: var(--space--small, 6px);\n \n /* @doc Define o espaçamento lateral esquerdo para items selecionados. */\n --ez-list__selectable--padding-left: var(--space--small, 6px);\n\n /*@doc Define o raio da borda de items selecionados.*/\n --ez-list__selected-item--border-radius: var(--border--radius-small, 6px);\n \n /*@doc Define a cor de fundo de items selecionados.*/\n --ez-list__selected-item--background-color: var(--color--primary-300, #E2F4EF);\n\n /* @doc Define o estilo do texto do grupo da lista. */\n --ez-list__group--font-family: var(--font-pattern, \"Roboto\");\n \n /* @doc Define o tamanho do texto do grupo da lista. */\n --ez-list__group--font-size: var(--text--medium, 14px);\n \n /* @doc Define o peso do texto do grupo da lista. */\n --ez-list__group--font-weight: var(--text-weight--large, 600);\n \n /* @doc Define o espaçamento inferior do grupo da lista. */\n --ez-list__group--padding-bottom: var(--space-small, 6px);\n\n /* @doc Define o estilo do texto da área de transferência de grupos. */\n --ez-list__group-overlay--font-family: var(--font-pattern, \"Roboto\");\n\n /* @doc Define o tamanho do texto da área de transferência de grupos. */\n --ez-list__group-overlay--font-size: var(--text--medium, 14px);\n \n /* @doc Define a cor da borda pontilhada sobre os elementos da lista. */\n --ez-list__over--border--color: var(--color--primary, #008561);\n\n /*@doc Define a altura do container para arrasto para última posição .*/\n --ez-list__last-droppable-space--height: var(--space--small, 6px);\n \n /*@doc Define o espaçamento do container de itens arrastáveis .*/\n --ez-list__draggable-list--padding-bottom: var(--space--small, 6px);\n\n /* @doc Define a imagem do ícone de drag. */\n --ez-list__draggable-icon--image: url('data:image/svg+xml;utf8,<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m 6.75,2.25 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z\"/></svg>');\n\n /* scrollbar */\n /*@doc Define a cor da barra de rolagem do componente.*/\n --ez-list__scrollbar--color-default: var(--scrollbar--default, #626e82);\n /*@doc Define a cor de fundo da barra de rolagem do componente.*/\n --ez-list__scrollbar--color-background: var(--scrollbar--background, #E5EAF0);\n /*@doc Define a cor do hover na barra de rolagem do componente.*/\n --ez-list__scrollbar--color-hover: var(--scrollbar--hover, #2B3A54);\n /*@doc Define a cor do active na barra de rolagem do componente.*/\n --ez-list__scrollbar--color-clicked: var(--scrollbar--clicked, #a2abb9);\n /*@doc Define o raio da borda da barra de rolagem do componente.*/\n --ez-list__scrollbar--border-radius: var(--border--radius-small, 6px);\n /*@doc Define a largura da barra de rolagem do componente.*/\n --ez-list__scrollbar--width: var(--space--medium, 12px);\n\n max-height: 100%;\n width: 100%;\n background-color: #fff;\n display: flex;\n\n /*public*/\n z-index: var(--ez-list__host--z-index);\n}\n\np {\n margin: 0;\n}\n\n.draggable {\n /* private */\n width: 100%;\n display: grid;\n grid-template-columns: minmax(0px, auto) minmax(0px, auto);\n place-items: center;\n border-top: 1px dashed #fff;\n justify-content: space-between;\n\n /*public*/\n font-family: var(--ez-list__item--font-family);\n font-size: var(--ez-list__item--font-size);\n}\n\n.dragging {\n background: #FFFFFF;\n /* Primary/color--primary */\n\n border: 1px solid #008561;\n box-sizing: border-box;\n box-shadow: 0px 0px 16px rgba(0, 38, 111, 0.122);\n border-radius: 6px;\n}\n\n.selectable {\n cursor: pointer;\n\n /*public*/\n padding-right: var(--ez-list__selectable--padding-right);\n padding-left: var(--ez-list__selectable--padding-left);\n}\n\n.selectable-container {\n margin: 0px !important;\n}\n\n.hover-feedback:hover {\n background-color: var(--background--medium);\n border-radius: var(--border--radius-regular);\n}\n\n.item-content {\n display: flex;\n overflow: hidden;\n justify-content: flex-start;\n width: 100%;\n}\n\n.draggable-list {\n padding: 0;\n margin: 0;\n width: 100%;\n max-height: 100%;\n scrollbar-width: thin;\n \n /*public*/\n color: var(--text-color);\n scrollbar-color: var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background);\n}\n\n.draggable-list li {\n display: flex;\n \n /*public*/\n font-family: var(--ez-list__item--font-family);\n font-size: var(--ez-list__item--font-size);\n color: var(--ez-list__item--color);\n border-bottom: var(--ez-list__item--border-bottom, none) var(--ez-list__item--border-bottom-color);\n}\n\n.draggable-list li > div {\n /*public*/\n padding: var(--space--2xs, 8px) var(--space--3xs, 4px);\n margin: var(--ez-list__item--margin);\n}\n\n.over {\n /*public*/\n border-top: 1px dashed var(--ez-list__over--border--color);\n}\n\n.last-droppable-space {\n /*public*/\n height: var(--ez-list__last-droppable-space--height);\n}\n\n.draggable-selected {\n /*public*/\n background-color: var(--background--strong) !important;\n}\n\n.draggable-selected div:hover {\n /*public*/\n background-color: var(--background--strong) !important;\n}\n\n.draggable-list::-webkit-scrollbar {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n width: var(--ez-list__scrollbar--width);\n max-width: var(--ez-list__scrollbar--width);\n min-width: var(--ez-list__scrollbar--width);\n}\n\n.draggable-list::-webkit-scrollbar-track {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.draggable-list::-webkit-scrollbar-thumb {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-default);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.draggable-list::-webkit-scrollbar-thumb:vertical:hover,\n.draggable-list::-webkit-scrollbar-thumb:horizontal:hover {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-hover);\n}\n\n.draggable-list::-webkit-scrollbar-thumb:vertical:active,\n.draggable-list::-webkit-scrollbar-thumb:horizontal:active {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-clicked);\n}\n\n.draggable-icon {\n align-items: flex-start;\n display: flex;\n outline: none;\n border: none;\n background-color: unset;\n}\n\n.draggable-icon::after {\n content: '';\n display: flex;\n width: 18px;\n height: 18px;\n\n /*public*/\n background-color: var(--ez-list__icon--color);\n -webkit-mask-image: var(--ez-list__draggable-icon--image);\n mask-image: var(--ez-list__draggable-icon--image);\n}\n\n* {\n box-sizing: border-box;\n}\n\n.checkbox {\n width: fit-content;\n}\n\n.text--ellipsis {\n overflow: hidden;\n text-overflow: ellipsis;\n \n /*public*/\n white-space: var(--ez-list__item--white-space);\n}\n\n.group-container {\n display: flex;\n flex-direction: column;\n max-height: 100%;\n overflow-y: auto;\n outline: none;\n width: 100%;\n scrollbar-width: thin;\n\n /*public*/\n scrollbar-color: var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background);\n}\n\n.group-name {\n -webkit-user-select: none;\n -moz-user-select: -moz-none;\n -ms-user-select: none;\n user-select: none;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n\n /*public*/\n color: var(--title--primary);\n font-family: var(--ez-list__group--font-family);\n font-size: var(--ez-list__group--font-size);\n font-weight: var(--ez-list__group--font-weight);\n padding-bottom: var(--ez-list__group--padding-bottom);\n}\n\n.group {\n display: flex;\n flex-direction: column;\n}\n\n.group-container::-webkit-scrollbar {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n width: var(--ez-list__scrollbar--width);\n max-width: var(--ez-list__scrollbar--width);\n min-width: var(--ez-list__scrollbar--width);\n}\n\n.group-container::-webkit-scrollbar-track {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.group-container::-webkit-scrollbar-thumb {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-default);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.group-container::-webkit-scrollbar-thumb:vertical:hover,\n.group-container::-webkit-scrollbar-thumb:horizontal:hover {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-hover);\n}\n\n.group-container::-webkit-scrollbar-thumb:vertical:active,\n.group-container::-webkit-scrollbar-thumb:horizontal:active {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-clicked);\n}\n\n.section-container {\n display: flex;\n position: relative;\n height: 100%;\n}\n\n.items-container {\n width: 100%;\n max-height: 100%;\n outline: none;\n scrollbar-width: thin;\n\n /*public*/\n scrollbar-color: var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background);\n}\n\n.group-items-container {\n width: 100%;\n max-height: 100%;\n height: 100%;\n outline: none;\n}\n\n.items-container::-webkit-scrollbar {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n width: var(--ez-list__scrollbar--width);\n max-width: var(--ez-list__scrollbar--width);\n min-width: var(--ez-list__scrollbar--width);\n}\n\n.items-container::-webkit-scrollbar-track {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-background);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.items-container::-webkit-scrollbar-thumb {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-default);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.items-container::-webkit-scrollbar-thumb:vertical:hover,\n.items-container::-webkit-scrollbar-thumb:horizontal:hover {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-hover);\n}\n\n.items-container::-webkit-scrollbar-thumb:vertical:active,\n.items-container::-webkit-scrollbar-thumb:horizontal:active {\n /*public*/\n background-color: var(--ez-list__scrollbar--color-clicked);\n}\n\n.group-overlay {\n background: rgba(226, 244, 239, 0.8);\n border: 1px solid #008561;\n border-radius: 8px;\n position: absolute;\n display: none;\n place-items: center;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n z-index: 2;\n margin: 0;\n cursor: pointer;\n\n /*public*/\n font-family: var(--ez-list__group-overlay--font-family);\n font-size: var(--ez-list__group-overlay--font-size);\n}\n\n.presetedHeight {\n min-height: 100px;\n}\n\n.overlay-text {\n position: absolute;\n top: 50%;\n left: 50%;\n font-size: 50px;\n color: white;\n transform: translate(-50%, -50%);\n -ms-transform: translate(-50%, -50%);\n}\n\n.selected-item {\n /*public*/\n background: var(--ez-list__selected-item--background-color);\n border-radius: var(--ez-list__selected-item--border-radius);\n}\n\n.slot-item {\n align-items: flex-end;\n}\n\n.overGroup {\n background: rgba(226, 244, 239, 0.8);\n border: 1px solid #008561;\n box-sizing: border-box;\n border-radius: 8px;\n padding-top: 6px;\n}";
|
|
5
5
|
|
|
6
6
|
const EzList = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -18,7 +18,7 @@ var ModalButtonStatus;
|
|
|
18
18
|
})(ModalButtonStatus || (ModalButtonStatus = {}));
|
|
19
19
|
const ModalButtonStatus$1 = ModalButtonStatus;
|
|
20
20
|
|
|
21
|
-
const ezModalContainerCss = ".sc-ez-modal-container-h{--ez-modal-container-overflow-y:auto;--ez-modal-container-overflow-x:clip;display:grid;grid-template-rows:0 auto 1fr auto 0;width:100%;height:100%}.ez-modal-container__header.sc-ez-modal-container{display:flex;flex-wrap:nowrap;flex-direction:row;justify-content:space-between}.ez-modal-container__content.sc-ez-modal-container{overflow-y:var(--ez-modal-container-overflow-y);overflow-x:var(--ez-modal-container-overflow-x)}.ez-modal-container__content.sc-ez-modal-container::-webkit-scrollbar{width:var(--space--small);min-width:var(--space--small);max-width:var(--space--small)}.ez-modal-container__footer.sc-ez-modal-container{display:flex;flex-direction:row;justify-content:flex-end;gap:var(--space--medium);width:100%;padding-top:var(--space--small, 6px)}.ez-modal-container__title.sc-ez-modal-container{display:grid}.ez-modal-container__close-button.sc-ez-modal-container{cursor:pointer;background-color:transparent;border:none}.ez-modal-container__close-icon.sc-ez-modal-container{--icon--color:var(--title--primary, #2B3A54)}.ez-modal-container__focus-ctrl.sc-ez-modal-container{height:0px;background-color:transparent;border:none}";
|
|
21
|
+
const ezModalContainerCss = ".sc-ez-modal-container-h{--ez-modal-container-overflow-y:auto;--ez-modal-container-overflow-x:clip;display:grid;grid-template-rows:0 auto 1fr auto 0;width:100%;height:100%}.ez-modal-container__header-container.sc-ez-modal-container{outline:none}.ez-modal-container__header.sc-ez-modal-container{display:flex;flex-wrap:nowrap;flex-direction:row;justify-content:space-between}.ez-modal-container__content.sc-ez-modal-container{overflow-y:var(--ez-modal-container-overflow-y);overflow-x:var(--ez-modal-container-overflow-x)}.ez-modal-container__content.sc-ez-modal-container::-webkit-scrollbar{width:var(--space--small);min-width:var(--space--small);max-width:var(--space--small)}.ez-modal-container__footer.sc-ez-modal-container{display:flex;flex-direction:row;justify-content:flex-end;gap:var(--space--medium);width:100%;padding-top:var(--space--small, 6px)}.ez-modal-container__title.sc-ez-modal-container{display:grid}.ez-modal-container__close-button.sc-ez-modal-container{cursor:pointer;background-color:transparent;border:none}.ez-modal-container__close-icon.sc-ez-modal-container{--icon--color:var(--title--primary, #2B3A54)}.ez-modal-container__focus-ctrl.sc-ez-modal-container{height:0px;background-color:transparent;border:none}";
|
|
22
22
|
|
|
23
23
|
const EzModalContainer = class {
|
|
24
24
|
constructor(hostRef) {
|
|
@@ -67,7 +67,7 @@ const EzModalContainer = class {
|
|
|
67
67
|
this._closeButton.focus();
|
|
68
68
|
}
|
|
69
69
|
render() {
|
|
70
|
-
return (h(Host, null, h("button", { class: "ez-modal-container__focus-ctrl", onFocusin: () => this.focusLast() }), h("div", { ref: ref => this._modalRef = ref, tabIndex: -1 }, this.showTitleBar && (h("div", { class: "ez-modal-container__header ez-margin-bottom--large" }, 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))), 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", { class: "ez-modal-container__content" }, h("slot", null)), h("div", { class: "ez-modal-container__footer" }, this.cancelIsVisible() && (h("ez-button", { label: this.cancelButtonLabel, enabled: this.cancelButtonStatus !== ModalButtonStatus$1.DISABLED, onClick: () => this.ezModalAction.emit(ModalAction$1.CANCEL) })), this.okIsVisible() && (h("ez-button", { ref: ref => this._okButton = ref, class: "ez-button--primary", label: this.okButtonLabel, enabled: this.okButtonStatus !== ModalButtonStatus$1.DISABLED, onClick: () => this.ezModalAction.emit(ModalAction$1.OK) }))), h("button", { class: "ez-modal-container__focus-ctrl", onFocusin: () => this.focusFirst() })));
|
|
70
|
+
return (h(Host, null, h("button", { class: "ez-modal-container__focus-ctrl", onFocusin: () => this.focusLast() }), h("div", { ref: ref => this._modalRef = ref, tabIndex: -1, class: "ez-modal-container__header-container" }, this.showTitleBar && (h("div", { class: "ez-modal-container__header ez-margin-bottom--large" }, 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))), 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", { class: "ez-modal-container__content" }, h("slot", null)), h("div", { class: "ez-modal-container__footer" }, this.cancelIsVisible() && (h("ez-button", { label: this.cancelButtonLabel, enabled: this.cancelButtonStatus !== ModalButtonStatus$1.DISABLED, onClick: () => this.ezModalAction.emit(ModalAction$1.CANCEL) })), this.okIsVisible() && (h("ez-button", { ref: ref => this._okButton = ref, class: "ez-button--primary", label: this.okButtonLabel, enabled: this.okButtonStatus !== ModalButtonStatus$1.DISABLED, onClick: () => this.ezModalAction.emit(ModalAction$1.OK) }))), h("button", { class: "ez-modal-container__focus-ctrl", onFocusin: () => this.focusFirst() })));
|
|
71
71
|
}
|
|
72
72
|
get _element() { return getElement(this); }
|
|
73
73
|
};
|
|
@@ -89,12 +89,17 @@ const EzNumberInput = class {
|
|
|
89
89
|
}
|
|
90
90
|
this._changePending = false;
|
|
91
91
|
}
|
|
92
|
+
observePrecision() {
|
|
93
|
+
if (this._textInput) {
|
|
94
|
+
this.setInputValue();
|
|
95
|
+
}
|
|
96
|
+
}
|
|
92
97
|
validateValue(value) {
|
|
93
98
|
return isNaN(value) || value === undefined ? null : value;
|
|
94
99
|
}
|
|
95
100
|
getTextValue(value) {
|
|
96
101
|
if (value != undefined) {
|
|
97
|
-
return this.precision
|
|
102
|
+
return this.precision >= 0 ? NumberUtils.format(value.toString(), Number(this.precision), Number(this.prettyPrecision)) : value.toString();
|
|
98
103
|
}
|
|
99
104
|
return undefined;
|
|
100
105
|
}
|
|
@@ -172,7 +177,9 @@ const EzNumberInput = class {
|
|
|
172
177
|
static get watchers() { return {
|
|
173
178
|
"label": ["observeLabel"],
|
|
174
179
|
"errorMessage": ["observeErrorMessage"],
|
|
175
|
-
"value": ["observeValue"]
|
|
180
|
+
"value": ["observeValue"],
|
|
181
|
+
"precision": ["observePrecision"],
|
|
182
|
+
"prettyPrecision": ["observePrecision"]
|
|
176
183
|
}; }
|
|
177
184
|
};
|
|
178
185
|
EzNumberInput.style = ezNumberInputCss;
|
|
@@ -4,6 +4,7 @@ import { ObjectUtils, StringUtils, FloatingManager, ElementIDUtils } from '@sank
|
|
|
4
4
|
import { A as ApplicationUtils } from './ApplicationUtils-eaf91331.js';
|
|
5
5
|
import './DialogType-54a62731.js';
|
|
6
6
|
import './CheckMode-bdb2ec19.js';
|
|
7
|
+
import './ICustomRender-875b5a40.js';
|
|
7
8
|
import { R as REQUIRED_INFO } from './constants-4e0d35b7.js';
|
|
8
9
|
|
|
9
10
|
const ezSearchCss = ":host{--ez-search--height:42px;--ez-search--width:100%;--ez-search__icon--width:48px;--ez-search--border-radius:var(--border--radius-medium, 12px);--ez-search--border-radius-small:var(--border--radius-small, 6px);--ez-search--font-size:var(--text--medium, 14px);--ez-search--font-family:var(--font-pattern, Arial);--ez-search--font-weight--large:var(--text-weight--large, 500);--ez-search--font-weight--medium:var(--text-weight--medium, 400);--ez-search--background-color--xlight:var(--background--xlight, #fff);--ez-search--background-medium:var(--background--medium, #f0f3f7);--ez-search--line-height:calc(var(--text--medium, 14px) + 4px);--ez-search__input--background-color:var(--background--medium, #e0e0e0);--ez-search__input--border:var(--border--medium, 2px solid);--ez-search__input--border-color:var(--ez-search__input--background-color);--ez-search__input--focus--border-color:var(--color--primary, #008561);--ez-search__input--disabled--background-color:var(--color--disable-secondary, #F2F5F8);--ez-search__input--disabled--color:var(--text--disable, #AFB6C0);--ez-search__input--error--border-color:#CC2936;--ez-search__btn--color:var(--title--primary, #2B3A54);--ez-search__btn-disabled--color:var(--text--disable, #AFB6C0);--ez-search__btn-hover--color:var(--color--primary, #4e4e4e);--ez-search__label--color:var(--title--primary, #2B3A54);--ez-search__list-title--primary:var(--title--primary, #2B3A54);--ez-search__list-text--primary:var(--text--primary, #626e82);--ez-search__list-height:calc(var(--ez-search--font-size) + var(--ez-search--space--medium) + 4px);--ez-search__list-min-width:64px;--ez-search--space--medium:var(--space--medium, 12px);--ez-search--space--small:var(--space--small, 6px);--ez-search__scrollbar--color-default:var(--scrollbar--default, #626e82);--ez-search__scrollbar--color-background:var(--scrollbar--background, #E5EAF0);--ez-search__scrollbar--color-hover:var(--scrollbar--hover, #2B3A54);--ez-search__scrollbar--color-clicked:var(--scrollbar--clicked, #a2abb9);--ez-search__scrollbar--border-radius:var(--border--radius-small, 6px);--ez-search__scrollbar--width:var(--space--medium, 12px);display:flex;flex-wrap:wrap;position:relative;width:var(--ez-search--width)}ez-icon{--ez-icon--color:inherit;font-weight:var(--text-weight--large, 600)}.suppressed-search-input{--ez-text-input__input--border-color:var(--color--strokes, #dce0e8);--ez-text-input__input--disabled--background-color:var(--background--xlight, #fff);--ez-text-input__input--disabled--color:var(--title--primary, #2B3A54)}.list-container{min-width:var(--ez-search__list-min-width);overflow:auto;position:relative;width:100%}.list-wrapper{display:flex;flex-direction:column;box-sizing:border-box;width:0;z-index:var(--more-visible, 2);max-height:350px;min-width:150px;background-color:var(--ez-search--background-color--xlight);border-radius:var(--ez-search--border-radius);box-shadow:var(--shadow, 0px 0px 16px 0px #000);padding:var(--ez-search--space--small)}.list-options{box-sizing:border-box;width:100%;height:100%;padding:0;display:flex;flex-direction:column;scroll-behavior:smooth;overflow:auto;scrollbar-width:thin;gap:3px;scrollbar-color:var(--ez-search__scrollbar--color-clicked) var(--ez-search__scrollbar--color-background)}.list-options::-webkit-scrollbar{background-color:var(--ez-search__scrollbar--color-background);width:var(--ez-search__scrollbar--width);max-width:var(--ez-search__scrollbar--width);min-width:var(--ez-search__scrollbar--width)}.list-options::-webkit-scrollbar-track{background-color:var(--ez-search__scrollbar--color-background);border-radius:var(--ez-search__scrollbar--border-radius)}.list-options::-webkit-scrollbar-thumb{background-color:var(--ez-search__scrollbar--color-default);border-radius:var(--ez-search__scrollbar--border-radius)}.list-options::-webkit-scrollbar-thumb:vertical:hover,.list-options::-webkit-scrollbar-thumb:horizontal:hover{background-color:var(--ez-search__scrollbar--color-hover)}.list-options::-webkit-scrollbar-thumb:vertical:active,.list-options::-webkit-scrollbar-thumb:horizontal:active{background-color:var(--ez-search__scrollbar--color-clicked)}.item{display:flex;align-items:center;width:100%;box-sizing:border-box;list-style-type:none;cursor:pointer;border-radius:var(--ez-search--border-radius-small);padding:var(--ez-search--space--small);gap:var(--space--small, 6px)}.item__value,.item__label{flex-basis:auto;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:var(--ez-search__list-title--primary);font-family:var(--ez-search--font-family);font-size:var(--ez-search--font-size);line-height:var(--ez-search--line-height)}.item__label{font-weight:var(--ez-search--font-weight--medium)}.item__label--bold{font-weight:var(--ez-search--font-weight--large)}.item__value{text-align:center;color:var(--ez-search__list-text--primary);font-weight:var(--ez-search--font-weight--large)}.item__value--hidden{visibility:hidden;position:absolute;white-space:nowrap;z-index:-1;top:0;left:0}.item__label{text-align:left}.message{text-align:center;display:flex;justify-content:center;align-items:center;list-style-type:none;min-height:var(--ez-search__list-height)}.message__no-result{color:var(--ez-search__list-title--primary);font-family:var(--ez-search--font-family);font-size:var(--ez-search--font-size)}.message__loading{border-radius:50%;width:14px;height:14px;-webkit-animation:spin 1s linear infinite;animation:spin 1s linear infinite;border:3px solid var(--ez-search__list-title--primary);border-top:3px solid transparent}.item__list>li:hover{background-color:var(--ez-search--background-medium)}.preselected{background-color:var(--background--medium)}.btn{outline:none;border:none;background:none;cursor:pointer;color:var(--ez-search__btn--color)}.btn:disabled{cursor:unset;color:var(--ez-search__btn-disabled--color)}.btn:disabled:hover{cursor:unset;color:var(--ez-search__btn-disabled--color)}.btn:hover{color:var(--ez-search__btn-hover--color)}.btn__close{visibility:hidden}ez-text-input:hover .btn__close,ez-text-input:focus .btn__close{visibility:visible}@-webkit-keyframes spin{0%{-webkit-transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg)}}@keyframes spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}";
|
|
@@ -315,9 +316,12 @@ const EzSearch = class {
|
|
|
315
316
|
}
|
|
316
317
|
scrollToOption(opt) {
|
|
317
318
|
window.requestAnimationFrame(() => {
|
|
318
|
-
const liElem = (opt === null || opt === void 0 ? void 0 : opt.value)
|
|
319
|
-
|
|
319
|
+
const liElem = (opt === null || opt === void 0 ? void 0 : opt.value)
|
|
320
|
+
? this._optionsList.querySelector(`div#item_${opt.value.replace(/([ #;&,.+*~':"!^$[\]()=<>|/\\])/g, '\\$1')}`)
|
|
321
|
+
: undefined;
|
|
322
|
+
if (liElem) {
|
|
320
323
|
liElem.scrollIntoView({ behavior: "smooth", block: "nearest" });
|
|
324
|
+
}
|
|
321
325
|
});
|
|
322
326
|
}
|
|
323
327
|
selectCurrentOption() {
|