@sankhyalabs/ezui 0.0.0-bugfix-dev-KB-6165.0 → 0.0.0-bugfix-dev-KB-17130.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/README.md +8 -10
- package/dist/cjs/{ApplicationUtils-2e444734.js → ApplicationUtils-c9d1205c.js} +56 -6
- package/dist/cjs/{RecordValidationProcessor-edd23705.js → RecordValidationProcessor-4c893e04.js} +1 -1
- package/dist/cjs/{constants-3a1d64fb.js → constants-2714478b.js} +2 -0
- package/dist/cjs/ez-actions-button.cjs.entry.js +56 -28
- package/dist/cjs/ez-alert-list.cjs.entry.js +148 -0
- package/dist/cjs/ez-alert.cjs.entry.js +1 -1
- package/dist/cjs/ez-application.cjs.entry.js +1 -1
- package/dist/cjs/ez-badge.cjs.entry.js +1 -1
- package/dist/cjs/ez-breadcrumb.cjs.entry.js +1 -1
- package/dist/cjs/ez-button.cjs.entry.js +1 -1
- package/dist/cjs/ez-calendar.cjs.entry.js +1 -1
- package/dist/cjs/ez-card-item_3.cjs.entry.js +182 -0
- package/dist/cjs/ez-check.cjs.entry.js +1 -1
- package/dist/cjs/ez-chip.cjs.entry.js +1 -1
- package/dist/cjs/ez-collapsible-box.cjs.entry.js +3 -4
- package/dist/cjs/ez-combo-box.cjs.entry.js +17 -152
- package/dist/cjs/ez-date-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-date-time-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-dialog.cjs.entry.js +31 -5
- package/dist/cjs/ez-dropdown.cjs.entry.js +12 -6
- package/dist/cjs/ez-file-item.cjs.entry.js +1 -1
- package/dist/cjs/ez-form-view.cjs.entry.js +44 -3
- package/dist/cjs/ez-form.cjs.entry.js +36 -4
- package/dist/cjs/ez-grid.cjs.entry.js +246 -64
- package/dist/cjs/ez-guide-navigator.cjs.entry.js +7 -1
- package/dist/cjs/ez-icon.cjs.entry.js +2 -2
- package/dist/cjs/ez-list.cjs.entry.js +5 -3
- package/dist/cjs/ez-loading-bar.cjs.entry.js +1 -1
- package/dist/cjs/ez-modal-container.cjs.entry.js +1 -1
- package/dist/cjs/ez-modal.cjs.entry.js +2 -2
- package/dist/cjs/ez-multi-selection-list.cjs.entry.js +23 -10
- package/dist/cjs/ez-number-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-popover.cjs.entry.js +1 -1
- package/dist/cjs/ez-popup.cjs.entry.js +2 -2
- package/dist/cjs/ez-radio-button.cjs.entry.js +1 -1
- package/dist/cjs/ez-scroller_3.cjs.entry.js +8 -6
- package/dist/cjs/ez-search.cjs.entry.js +615 -32
- package/dist/cjs/ez-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/ez-split-item.cjs.entry.js +19 -0
- package/dist/cjs/ez-split-panel.cjs.entry.js +776 -0
- package/dist/cjs/ez-tabselector.cjs.entry.js +1 -1
- package/dist/cjs/ez-text-area.cjs.entry.js +1 -1
- package/dist/cjs/ez-text-edit.cjs.entry.js +2 -2
- package/dist/cjs/ez-text-input.cjs.entry.js +3 -2
- package/dist/cjs/ez-time-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-toast.cjs.entry.js +1 -1
- package/dist/cjs/ez-upload.cjs.entry.js +2 -2
- package/dist/cjs/ez-view-stack.cjs.entry.js +1 -1
- package/dist/cjs/ezui.cjs.js +2 -2
- package/dist/cjs/filter-column.cjs.entry.js +47 -12
- package/dist/cjs/{index-1064511f.js → index-a7b0c73d.js} +16 -6
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +6 -3
- package/dist/collection/components/ez-actions-button/ez-actions-button.css +17 -3
- package/dist/collection/components/ez-actions-button/ez-actions-button.js +105 -27
- package/dist/collection/components/ez-alert-list/ez-alert-list.css +87 -0
- package/dist/collection/components/ez-alert-list/ez-alert-list.js +268 -0
- package/dist/collection/components/ez-card-item/ez-card-item.css +17 -0
- package/dist/collection/components/ez-collapsible-box/ez-collapsible-box.css +1 -1
- package/dist/collection/components/ez-collapsible-box/ez-collapsible-box.js +0 -1
- package/dist/collection/components/ez-combo-box/ez-combo-box.js +71 -169
- package/dist/collection/components/ez-dialog/ez-dialog.css +1 -1
- package/dist/collection/components/ez-dialog/ez-dialog.js +39 -4
- package/dist/collection/components/ez-dropdown/ez-dropdown.css +4 -3
- package/dist/collection/components/ez-dropdown/ez-dropdown.js +33 -4
- package/dist/collection/components/ez-form/ez-form.js +93 -0
- package/dist/collection/components/ez-form-view/ez-form-view.js +23 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/FieldBuilder.js +4 -1
- package/dist/collection/components/ez-form-view/structure/index.js +34 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/AgGridController.js +21 -9
- package/dist/collection/components/ez-grid/controller/ag-grid/DataSource.js +23 -1
- package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.js +1 -1
- package/dist/collection/components/ez-grid/controller/ag-grid/components/cellRendererStatus.js +1 -1
- package/dist/collection/components/ez-grid/ez-grid.css +1 -4
- package/dist/collection/components/ez-grid/ez-grid.js +91 -51
- package/dist/collection/components/ez-grid/interfaces/IColumnFilter.js +1 -0
- package/dist/collection/components/ez-grid/interfaces/index.js +1 -0
- package/dist/collection/components/ez-grid/subcomponents/filter-column.js +66 -12
- package/dist/collection/components/ez-grid/utils/ColumnFilterManager.js +62 -0
- package/dist/collection/components/ez-grid/utils/InMemoryFilterColumnDataSource.js +94 -0
- package/dist/collection/components/ez-grid/utils/index.js +1 -0
- package/dist/collection/components/ez-guide-navigator/ez-guide-navigator.js +22 -0
- package/dist/collection/components/ez-icon/ez-icon.css +148 -139
- package/dist/collection/components/ez-list/ez-list.css +12 -7
- package/dist/collection/components/ez-list/ez-list.js +3 -1
- package/dist/collection/components/ez-modal/ez-modal.css +1 -1
- package/dist/collection/components/ez-multi-selection-list/ez-multi-selection-list.js +41 -10
- package/dist/collection/components/ez-popup/ez-popup.css +2 -2
- package/dist/collection/components/ez-search/ez-search.css +330 -0
- package/dist/collection/components/ez-search/ez-search.js +746 -55
- package/dist/collection/components/ez-split-panel/ez-split-panel.css +8 -0
- package/dist/collection/components/ez-split-panel/ez-split-panel.js +122 -0
- package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.css +12 -0
- package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.js +17 -0
- package/dist/collection/components/ez-text-input/ez-text-input.js +20 -1
- package/dist/collection/components/ez-tree/ez-tree.css +33 -0
- package/dist/collection/components/ez-tree/subcomponents/TreeItem.js +3 -3
- package/dist/collection/utils/ApplicationUtils.js +56 -6
- package/dist/collection/utils/constants.js +1 -0
- package/dist/collection/utils/form/DataBinder.js +12 -1
- package/dist/collection/utils/interfaces/IAction.js +1 -0
- package/dist/custom-elements/index.d.ts +18 -0
- package/dist/custom-elements/index.js +2138 -339
- package/dist/esm/{ApplicationUtils-d9a34a16.js → ApplicationUtils-eaf91331.js} +56 -6
- package/dist/esm/{RecordValidationProcessor-abc814af.js → RecordValidationProcessor-b00b8b77.js} +1 -1
- package/dist/esm/constants-4e0d35b7.js +5 -0
- package/dist/esm/ez-actions-button.entry.js +56 -28
- package/dist/esm/ez-alert-list.entry.js +144 -0
- package/dist/esm/ez-alert.entry.js +1 -1
- package/dist/esm/ez-application.entry.js +1 -1
- package/dist/esm/ez-badge.entry.js +1 -1
- package/dist/esm/ez-breadcrumb.entry.js +1 -1
- package/dist/esm/ez-button.entry.js +1 -1
- package/dist/esm/ez-calendar.entry.js +1 -1
- package/dist/esm/ez-card-item_3.entry.js +176 -0
- package/dist/esm/ez-check.entry.js +1 -1
- package/dist/esm/ez-chip.entry.js +1 -1
- package/dist/esm/ez-collapsible-box.entry.js +3 -4
- package/dist/esm/ez-combo-box.entry.js +18 -153
- package/dist/esm/ez-date-input.entry.js +1 -1
- package/dist/esm/ez-date-time-input.entry.js +1 -1
- package/dist/esm/ez-dialog.entry.js +31 -5
- package/dist/esm/ez-dropdown.entry.js +12 -6
- package/dist/esm/ez-file-item.entry.js +1 -1
- package/dist/esm/ez-form-view.entry.js +44 -3
- package/dist/esm/ez-form.entry.js +36 -4
- package/dist/esm/ez-grid.entry.js +247 -65
- package/dist/esm/ez-guide-navigator.entry.js +7 -1
- package/dist/esm/ez-icon.entry.js +2 -2
- package/dist/esm/ez-list.entry.js +5 -3
- package/dist/esm/ez-loading-bar.entry.js +1 -1
- package/dist/esm/ez-modal-container.entry.js +1 -1
- package/dist/esm/ez-modal.entry.js +2 -2
- package/dist/esm/ez-multi-selection-list.entry.js +23 -10
- package/dist/esm/ez-number-input.entry.js +1 -1
- package/dist/esm/ez-popover.entry.js +1 -1
- package/dist/esm/ez-popup.entry.js +2 -2
- package/dist/esm/ez-radio-button.entry.js +1 -1
- package/dist/esm/ez-scroller_3.entry.js +8 -6
- package/dist/esm/ez-search.entry.js +616 -33
- package/dist/esm/ez-skeleton.entry.js +1 -1
- package/dist/esm/ez-split-item.entry.js +15 -0
- package/dist/esm/ez-split-panel.entry.js +772 -0
- package/dist/esm/ez-tabselector.entry.js +1 -1
- package/dist/esm/ez-text-area.entry.js +1 -1
- package/dist/esm/ez-text-edit.entry.js +2 -2
- package/dist/esm/ez-text-input.entry.js +3 -2
- package/dist/esm/ez-time-input.entry.js +1 -1
- package/dist/esm/ez-toast.entry.js +1 -1
- package/dist/esm/ez-upload.entry.js +2 -2
- package/dist/esm/ez-view-stack.entry.js +1 -1
- package/dist/esm/ezui.js +3 -3
- package/dist/esm/filter-column.entry.js +47 -12
- package/dist/esm/{index-296b8458.js → index-baa5e267.js} +16 -6
- package/dist/esm/loader.js +3 -3
- package/dist/ezui/ezui.esm.js +1 -1
- package/dist/ezui/{p-5cef0264.entry.js → p-0306dff7.entry.js} +1 -1
- package/dist/ezui/p-0447d17c.entry.js +1 -0
- package/dist/ezui/{p-86a2036d.js → p-04f24913.js} +1 -1
- package/dist/ezui/p-05e1f4e7.js +1 -0
- package/dist/ezui/p-072e6347.entry.js +1 -0
- package/dist/ezui/p-133fae4a.entry.js +1 -0
- package/dist/ezui/{p-f4208819.entry.js → p-17be134a.entry.js} +1 -1
- package/dist/ezui/{p-cd19a6f8.entry.js → p-1e7a8633.entry.js} +1 -1
- package/dist/ezui/{p-60ba28ea.entry.js → p-1f50fa05.entry.js} +1 -1
- package/dist/ezui/{p-a5e09759.entry.js → p-20ec22c0.entry.js} +1 -1
- package/dist/ezui/p-2187f86c.js +1 -0
- package/dist/ezui/{p-e318d280.js → p-23a36bb6.js} +1 -1
- package/dist/ezui/{p-ce035beb.entry.js → p-24d3fede.entry.js} +1 -1
- package/dist/ezui/p-2a1a0e04.entry.js +1 -0
- package/dist/ezui/p-40f72de4.entry.js +1 -0
- package/dist/ezui/p-43b03119.entry.js +1 -0
- package/dist/ezui/{p-9b347f04.entry.js → p-44caad9a.entry.js} +1 -1
- package/dist/ezui/p-49456b34.entry.js +1 -0
- package/dist/ezui/p-4a7f113d.entry.js +1 -0
- package/dist/ezui/p-51c5e071.entry.js +1 -0
- package/dist/ezui/{p-ccb4ccd9.entry.js → p-555c9018.entry.js} +1 -1
- package/dist/ezui/{p-d43b22f3.entry.js → p-596634e9.entry.js} +1 -1
- package/dist/ezui/p-5bd5e68f.entry.js +1 -0
- package/dist/ezui/{p-a01068e1.entry.js → p-5d692ed1.entry.js} +1 -1
- package/dist/ezui/{p-95426f93.entry.js → p-5d86cca9.entry.js} +1 -1
- package/dist/ezui/p-5e1d036e.entry.js +1 -0
- package/dist/ezui/{p-7525e604.entry.js → p-5ed81457.entry.js} +1 -1
- package/dist/ezui/{p-c49dbf23.entry.js → p-650e4b6d.entry.js} +1 -1
- package/dist/ezui/{p-fd54b5b4.entry.js → p-6e2f8e6b.entry.js} +2 -2
- package/dist/ezui/p-6e429cff.entry.js +1 -0
- package/dist/ezui/p-76ba9d67.entry.js +1 -0
- package/dist/ezui/{p-37673563.entry.js → p-77a4bd35.entry.js} +1 -1
- package/dist/ezui/p-796c1a88.entry.js +1 -0
- package/dist/ezui/{p-5d6f2550.entry.js → p-85c8baae.entry.js} +1 -1
- package/dist/ezui/{p-fa571a4e.entry.js → p-8becebf8.entry.js} +1 -1
- package/dist/ezui/p-8defa6d3.entry.js +1 -0
- package/dist/ezui/{p-391de0e4.entry.js → p-9050d2cd.entry.js} +1 -1
- package/dist/ezui/{p-028f264f.entry.js → p-9cad9b6e.entry.js} +1 -1
- package/dist/ezui/{p-b11f035c.entry.js → p-9f5fa3f9.entry.js} +1 -1
- package/dist/ezui/p-a08b309b.entry.js +1 -0
- package/dist/ezui/{p-2da09f70.entry.js → p-a80b1287.entry.js} +1 -1
- package/dist/ezui/p-af15c277.entry.js +1 -0
- package/dist/ezui/{p-32b4163f.entry.js → p-b041333c.entry.js} +1 -1
- package/dist/ezui/p-ba875f37.entry.js +1 -0
- package/dist/ezui/p-bc2f844e.entry.js +1 -0
- package/dist/ezui/{p-e2dfd935.entry.js → p-c0f1715f.entry.js} +1 -1
- package/dist/ezui/{p-83885b21.entry.js → p-cc2dc4f4.entry.js} +1 -1
- package/dist/ezui/p-d6ffe679.entry.js +1 -0
- package/dist/ezui/p-eb36f072.entry.js +1 -0
- package/dist/ezui/p-f56dd1da.entry.js +1 -0
- package/dist/types/components/ez-actions-button/ez-actions-button.d.ts +15 -7
- package/dist/types/components/ez-alert-list/ez-alert-list.d.ts +76 -0
- package/dist/types/components/ez-combo-box/ez-combo-box.d.ts +12 -15
- package/dist/types/components/ez-dialog/ez-dialog.d.ts +8 -2
- package/dist/types/components/ez-dropdown/ez-dropdown.d.ts +5 -0
- package/dist/types/components/ez-form/ez-form.d.ts +19 -1
- package/dist/types/components/ez-form-view/ez-form-view.d.ts +5 -0
- package/dist/types/components/ez-form-view/structure/index.d.ts +15 -0
- package/dist/types/components/ez-grid/controller/EzGridController.d.ts +9 -6
- package/dist/types/components/ez-grid/controller/ag-grid/AgGridController.d.ts +2 -3
- package/dist/types/components/ez-grid/controller/ag-grid/DataSource.d.ts +1 -0
- package/dist/types/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.d.ts +1 -1
- package/dist/types/components/ez-grid/ez-grid.d.ts +13 -5
- package/dist/types/components/ez-grid/interfaces/IColumnFilter.d.ts +4 -0
- package/dist/types/components/ez-grid/interfaces/index.d.ts +1 -0
- package/dist/types/components/ez-grid/subcomponents/filter-column.d.ts +8 -0
- package/dist/types/components/ez-grid/utils/ColumnFilterManager.d.ts +9 -0
- package/dist/types/components/ez-grid/utils/InMemoryFilterColumnDataSource.d.ts +19 -0
- package/dist/types/components/ez-grid/utils/index.d.ts +1 -0
- package/dist/types/components/ez-guide-navigator/ez-guide-navigator.d.ts +4 -0
- package/dist/types/components/ez-guide-navigator/interfaces/IGuideItem.d.ts +1 -0
- package/dist/types/components/ez-multi-selection-list/ez-multi-selection-list.d.ts +4 -0
- package/dist/types/components/ez-multi-selection-list/interfaces/IMultiSelectionListDataSource.d.ts +2 -0
- package/dist/types/components/ez-search/ez-search.d.ts +112 -10
- package/dist/types/components/ez-split-panel/structure/item/ez-split-item.d.ts +3 -0
- package/dist/types/components/ez-text-input/ez-text-input.d.ts +4 -0
- package/dist/types/components/ez-tree/interfaces/ITreeItem.d.ts +1 -0
- package/dist/types/components/ez-tree/subcomponents/TreeItem.d.ts +1 -0
- package/dist/types/components.d.ts +236 -17
- package/dist/types/utils/ApplicationUtils.d.ts +24 -0
- package/dist/types/utils/constants.d.ts +1 -0
- package/dist/types/utils/form/DataBinder.d.ts +1 -0
- package/dist/types/utils/index.d.ts +1 -0
- package/dist/types/utils/interfaces/AbstractFieldMetadata.d.ts +2 -1
- package/dist/types/utils/interfaces/IAction.d.ts +7 -0
- package/package.json +4 -3
- package/react/components.d.ts +3 -0
- package/react/components.js +3 -0
- package/react/components.js.map +1 -1
- package/dist/cjs/ez-card-item.cjs.entry.js +0 -52
- package/dist/cjs/ez-filter-input_2.cjs.entry.js +0 -137
- package/dist/esm/constants-6dab64f7.js +0 -4
- package/dist/esm/ez-card-item.entry.js +0 -48
- package/dist/esm/ez-filter-input_2.entry.js +0 -132
- package/dist/ezui/p-050247dc.entry.js +0 -1
- package/dist/ezui/p-1e7c4986.entry.js +0 -1
- package/dist/ezui/p-244dfe8a.entry.js +0 -1
- package/dist/ezui/p-27a01a26.js +0 -1
- package/dist/ezui/p-2a0e1679.entry.js +0 -1
- package/dist/ezui/p-4535da17.entry.js +0 -1
- package/dist/ezui/p-4c8b029b.entry.js +0 -1
- package/dist/ezui/p-4e31b69b.entry.js +0 -1
- package/dist/ezui/p-5495fa45.entry.js +0 -1
- package/dist/ezui/p-5ce6548c.entry.js +0 -1
- package/dist/ezui/p-68352e41.entry.js +0 -1
- package/dist/ezui/p-87e85160.entry.js +0 -1
- package/dist/ezui/p-8bd3903b.entry.js +0 -1
- package/dist/ezui/p-90fa4cb3.entry.js +0 -1
- package/dist/ezui/p-9285b53e.entry.js +0 -1
- package/dist/ezui/p-a510a4c5.entry.js +0 -1
- package/dist/ezui/p-d51aa09b.entry.js +0 -1
- package/dist/ezui/p-db528b31.entry.js +0 -1
- package/dist/ezui/p-e67d0bd5.entry.js +0 -1
- package/dist/ezui/p-e7fa0ad6.entry.js +0 -1
- package/dist/ezui/p-f15ec3bb.js +0 -1
- package/dist/ezui/p-ff82b176.entry.js +0 -1
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Bibliteca de componentes EzUI
|
|
2
2
|
|
|
3
|
-
[](https://gitlab.sankhya.com.br/dti/design-system/ez-ui/-/commits/master)
|
|
4
4
|
|
|
5
5
|
Esse projeto é constituído por um monorepo com a seguinte hierarquia:
|
|
6
6
|
|
|
@@ -69,12 +69,10 @@ o build do ezui, link do react-output e ezui, build do react-output e a disponib
|
|
|
69
69
|
- `npm run build`
|
|
70
70
|
|
|
71
71
|
## Para conhecer detalhes do projeto acesse:
|
|
72
|
-
- [Olá EZUi](https://
|
|
73
|
-
- [Diretrizes de codificação](https://
|
|
74
|
-
- [Diretrizes de componentização](https://
|
|
75
|
-
- [Diretrizes de documentação](https://
|
|
76
|
-
- [Link ente projetos](https://
|
|
77
|
-
- [Definindo bons data-element-id de testabilidade no design system](https://
|
|
78
|
-
- [Criando exemplos de componentes](https://
|
|
79
|
-
|
|
80
|
-
|
|
72
|
+
- [Olá EZUi](https://gitlab.sankhya.com.br/dti/design-system/ez-ui/-/wikis/Ol%C3%A1-EzUI)
|
|
73
|
+
- [Diretrizes de codificação](https://gitlab.sankhya.com.br/dti/design-system/ez-ui/-/wikis/Diretrizes-de-codifica%C3%A7%C3%A3o)
|
|
74
|
+
- [Diretrizes de componentização](https://gitlab.sankhya.com.br/dti/design-system/ez-ui/-/wikis/Diretrizes-de-componentiza%C3%A7%C3%A3o)
|
|
75
|
+
- [Diretrizes de documentação](https://gitlab.sankhya.com.br/dti/design-system/ez-ui/-/wikis/Diretrizes-de-documenta%C3%A7%C3%A3o)
|
|
76
|
+
- [Link ente projetos](https://gitlab.sankhya.com.br/dti/design-system/ez-ui/-/wikis/Link-ente-projetos)
|
|
77
|
+
- [Definindo bons data-element-id de testabilidade no design system](https://gitlab.sankhya.com.br/dti/design-system/ez-ui/-/wikis/Definindo-bons-data-element-id-de-testabilidade-no-design-system)
|
|
78
|
+
- [Criando exemplos de componentes](https://gitlab.sankhya.com.br/dti/design-system/ez-ui/-/wikis/Criando-exemplos-de-componentes)
|
|
@@ -73,12 +73,13 @@ class ApplicationUtils {
|
|
|
73
73
|
options = Object.assign(Object.assign({}, ApplicationUtils.defaultMessageOptions), options);
|
|
74
74
|
}
|
|
75
75
|
return new Promise(resolve => {
|
|
76
|
-
let dialog = document.
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
76
|
+
let dialog = document.createElement("ez-dialog");
|
|
77
|
+
window.document.body.appendChild(dialog);
|
|
78
|
+
dialog.show(title, message, dialogType, confirm, icon, options.labelCancel, options.labelConfirm, options.btnConfirmDanger, options.beforeClose)
|
|
79
|
+
.then(ok => {
|
|
80
|
+
dialog.remove();
|
|
81
|
+
return resolve(ok);
|
|
82
|
+
});
|
|
82
83
|
});
|
|
83
84
|
}
|
|
84
85
|
static async alert(title, message, icon = null, options = ApplicationUtils.defaultMessageOptions) {
|
|
@@ -123,6 +124,33 @@ class ApplicationUtils {
|
|
|
123
124
|
}
|
|
124
125
|
toast.show(message, 5000, useIcon, options.canClose);
|
|
125
126
|
}
|
|
127
|
+
static isModalContent(content) {
|
|
128
|
+
return content instanceof HTMLElement && content.tagName === 'EZ-MODAL-CONTAINER';
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* Exibe um popup configurado com os parâmetros informados e retorna um callBack
|
|
132
|
+
* para removêlo da DOM quando necessário.
|
|
133
|
+
*
|
|
134
|
+
* @param popupProps
|
|
135
|
+
*/
|
|
136
|
+
static async showPopup(popupProps) {
|
|
137
|
+
var _a, _b;
|
|
138
|
+
const popup = document.createElement("ez-popup");
|
|
139
|
+
window.document.body.appendChild(popup);
|
|
140
|
+
const { content } = popupProps;
|
|
141
|
+
popup.setAttribute('id', v4());
|
|
142
|
+
popup.heightMode = (_a = popupProps.size) !== null && _a !== void 0 ? _a : "auto";
|
|
143
|
+
popup.opened = true;
|
|
144
|
+
if (ApplicationUtils.isModalContent(content)) {
|
|
145
|
+
popup.appendChild(content);
|
|
146
|
+
popup.useHeader = false;
|
|
147
|
+
}
|
|
148
|
+
else {
|
|
149
|
+
popup.ezTitle = (_b = popupProps.title) !== null && _b !== void 0 ? _b : "";
|
|
150
|
+
popup.innerHTML = content;
|
|
151
|
+
}
|
|
152
|
+
return () => popup.remove();
|
|
153
|
+
}
|
|
126
154
|
static async showModal(modalProps) {
|
|
127
155
|
modalProps = Object.assign(Object.assign({}, ApplicationUtils.defaultModalProps), modalProps);
|
|
128
156
|
const modal = document.createElement("ez-modal");
|
|
@@ -143,6 +171,21 @@ class ApplicationUtils {
|
|
|
143
171
|
modal.opened = true;
|
|
144
172
|
return () => modal.remove();
|
|
145
173
|
}
|
|
174
|
+
static showAlerts(props) {
|
|
175
|
+
const alertListId = 'EzAlertList';
|
|
176
|
+
let alertList = document.getElementById(alertListId);
|
|
177
|
+
if (!alertList) {
|
|
178
|
+
alertList = document.createElement('ez-alert-list');
|
|
179
|
+
alertList.setAttribute("id", alertListId);
|
|
180
|
+
window.document.body.appendChild(alertList);
|
|
181
|
+
}
|
|
182
|
+
props = Object.assign(Object.assign({}, ApplicationUtils.defaultAlertListProps), props);
|
|
183
|
+
alertList.itemRightSlotBuilder = props.itemRightSlotBuilder;
|
|
184
|
+
alertList.enableDragAndDrop = props.enableDragAndDrop;
|
|
185
|
+
alertList.enableExpand = props.enableExpand;
|
|
186
|
+
alertList.opened = props.opened;
|
|
187
|
+
alertList.alerts = props.alerts;
|
|
188
|
+
}
|
|
146
189
|
}
|
|
147
190
|
ApplicationUtils.defaultMessageOptions = {
|
|
148
191
|
canClose: true,
|
|
@@ -158,5 +201,12 @@ ApplicationUtils.defaultModalProps = {
|
|
|
158
201
|
closeOutsideClick: true,
|
|
159
202
|
closeEsc: true
|
|
160
203
|
};
|
|
204
|
+
ApplicationUtils.defaultAlertListProps = {
|
|
205
|
+
alerts: [],
|
|
206
|
+
enableDragAndDrop: true,
|
|
207
|
+
enableExpand: true,
|
|
208
|
+
itemRightSlotBuilder: null,
|
|
209
|
+
opened: true
|
|
210
|
+
};
|
|
161
211
|
|
|
162
212
|
exports.ApplicationUtils = ApplicationUtils;
|
package/dist/cjs/{RecordValidationProcessor-edd23705.js → RecordValidationProcessor-4c893e04.js}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
const core = require('@sankhyalabs/core');
|
|
4
|
-
const ApplicationUtils = require('./ApplicationUtils-
|
|
4
|
+
const ApplicationUtils = require('./ApplicationUtils-c9d1205c.js');
|
|
5
5
|
|
|
6
6
|
const buildFieldMetadata = (descriptor, config) => {
|
|
7
7
|
let { name, label, group } = Object.assign({}, config);
|
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
const REQUIRED_INFO = " (obrigatório) *";
|
|
4
4
|
const DISTINCT_FILTER_NAME_PREFIX = 'FILTRO_COLUNA_';
|
|
5
|
+
const EZ_GRID_LOADING_SOURCE = "EZ_GRID_LOADING_SOURCE";
|
|
5
6
|
|
|
6
7
|
exports.DISTINCT_FILTER_NAME_PREFIX = DISTINCT_FILTER_NAME_PREFIX;
|
|
8
|
+
exports.EZ_GRID_LOADING_SOURCE = EZ_GRID_LOADING_SOURCE;
|
|
7
9
|
exports.REQUIRED_INFO = REQUIRED_INFO;
|
|
@@ -2,19 +2,21 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-a7b0c73d.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
|
-
require('./ApplicationUtils-
|
|
7
|
+
require('./ApplicationUtils-c9d1205c.js');
|
|
8
8
|
const CSSVarsUtils = require('./CSSVarsUtils-b136a156.js');
|
|
9
9
|
require('./DialogType-2114c337.js');
|
|
10
10
|
require('./CheckMode-ecb90b87.js');
|
|
11
11
|
|
|
12
|
-
const ezActionsButtonCss = ":host{--ez-actions-button__actions-list--border-radius:var(--border--radius-medium, 12px);--ez-actions-button__actions-list--box-shadow:var(--shadow, 0px 0px 16px 0px #000);--ez-actions-button__actions-list--background-color:var(--background--xlight, #fff);--ez-actions-button__actions-list--padding:var(--space--small, 6px);--ez-actions-button__actions-list--top-margin:var(--space-small, 6px);--ez-actions-button__btn-action--min-width:'auto';--ez-actions-button__btn-action--background-color:var(--background--xlight, #fff);display:flex;flex-direction:column;height:fit-content;user-select:none}.ez-actions-button__actions-list{display:flex;flex-direction:column;position:fixed;width:fit-content;height:fit-content;z-index:var(--
|
|
12
|
+
const ezActionsButtonCss = ":host{--ez-actions-button__actions-list--border-radius:var(--border--radius-medium, 12px);--ez-actions-button__actions-list--box-shadow:var(--shadow, 0px 0px 16px 0px #000);--ez-actions-button__actions-list--background-color:var(--background--xlight, #fff);--ez-actions-button__actions-list--padding:var(--space--small, 6px);--ez-actions-button__actions-list--top-margin:var(--space-small, 6px);--ez-actions-button__actions-list--z-index:var(--ez-elevation--8, 8);--ez-actions-button__actions-max-height:415px;--ez-actions-button__btn-action--min-width:'auto';--ez-actions-button__btn-action--background-color:var(--background--xlight, #fff);display:flex;flex-direction:column;height:fit-content;user-select:none}.ez-actions-button__actions-list{display:flex;flex-direction:column;position:fixed;width:fit-content;height:fit-content;overflow-y:auto;scrollbar-width:thin;z-index:var(--ez-actions-button__actions-list--z-index);padding:var(--ez-actions-button__actions-list--padding);margin-top:var(--ez-actions-button__actions-list--top-margin);background-color:var(--ez-actions-button__actions-list--background-color);border-radius:var(--ez-actions-button__actions-list--border-radius);box-shadow:var(--ez-actions-button__actions-list--box-shadow)}.ez-actions-button__actions-list--max-height{max-height:var(--ez-actions-button__actions-max-height)}.ez-actions-button__actions-list--lowered{margin-top:calc(var(--ez-actions-button__actions-list--top-margin) + 6px)}.ez-actions-button__btn-action{--ez-button--justify-content:flex-start;--ez-button--width:100%;--ez-button--min-width:var(--ez-actions-button__btn-action--min-width);--ez-button--background-color:var(--ez-actions-button__btn-action--background-color);--ez-button--font-weight:var(--text-weight--medium, 400);--ez-button--padding-left:var(--space--medium, 12px);--ez-button--padding-right:var(--space--medium, 12px)}.ez-actions-button__btn-action--spaced{--ez-button--padding-left:calc(var(--space--medium, 12px) + 24px)}.ez-actions-button__icon-right{margin-left:var(--space--small, 6px)}.ez-actions-button__icon-check,.ez-actions-button__icon-item{position:absolute;left:var(--space--medium, 12px)}.ez-actions-button__icon-check{color:var(--ez-button--hover-color)}.ez-actions-button__arrow{position:absolute;border-left:10px solid transparent;border-right:10px solid transparent;width:0;height:0;z-index:calc(var(--ez-actions-button__actions-list--z-index) + 1);border-bottom:15px solid var(--ez-actions-button__btn-action--background-color)}.ez-actions-button__arrow--upped{margin-top:calc((var(--ez-actions-button__actions-list--top-margin) + 2px) * -1)}.ez-actions-button__arrow--small{margin-left:6px}.ez-actions-button__arrow--medium{margin-left:11px}.ez-actions-button__arrow--large{margin-left:13px}.ez-actions-button__arrow:only-child{display:none}.ez-actions-button__btn-transparent{--ez-button--background-color:transparent;--ez-button--hover--background-color:transparent;--ez-button--active--background-color:transparent;--ez-button--focus--border:none}.ez-actions-button__btn-label{--ez-button--padding-left:var(--space--medium, 12px);--ez-button--padding-right:var(--space--medium, 12px)}.ez-actions-button__list-container{position:relative}.ez-actions-button--bottom-padding{padding-bottom:var(--space--small, 6px)}";
|
|
13
13
|
|
|
14
14
|
const EzActionsButton = class {
|
|
15
15
|
constructor(hostRef) {
|
|
16
16
|
index.registerInstance(this, hostRef);
|
|
17
17
|
this.ezAction = index.createEvent(this, "ezAction", 7);
|
|
18
|
+
this.ezPopoverOpen = index.createEvent(this, "ezPopoverOpen", 7);
|
|
19
|
+
this.ezDisconnectedActionButtons = index.createEvent(this, "ezDisconnectedActionButtons", 7);
|
|
18
20
|
this._arrowOffset = 5;
|
|
19
21
|
this.innerClickCheck = (floatingContainer, node) => {
|
|
20
22
|
var _a;
|
|
@@ -28,6 +30,12 @@ const EzActionsButton = class {
|
|
|
28
30
|
return true;
|
|
29
31
|
}
|
|
30
32
|
}
|
|
33
|
+
do {
|
|
34
|
+
if (floatingContainer.contains(node)) {
|
|
35
|
+
return true;
|
|
36
|
+
}
|
|
37
|
+
node = node.offsetParent;
|
|
38
|
+
} while (node != undefined && node != document.getRootNode());
|
|
31
39
|
}
|
|
32
40
|
return false;
|
|
33
41
|
};
|
|
@@ -51,6 +59,25 @@ const EzActionsButton = class {
|
|
|
51
59
|
}
|
|
52
60
|
this._floatingID = undefined;
|
|
53
61
|
}
|
|
62
|
+
/**
|
|
63
|
+
* Apresenta a lista de ações.
|
|
64
|
+
*/
|
|
65
|
+
async showActions() {
|
|
66
|
+
if (!this.enabled) {
|
|
67
|
+
return;
|
|
68
|
+
}
|
|
69
|
+
const options = this.getFloatOptions();
|
|
70
|
+
this._floatingID = core.FloatingManager.float(this._actionsList, this._listContainer, options);
|
|
71
|
+
const sideLimit = this.getSideLimit();
|
|
72
|
+
if (sideLimit != undefined) {
|
|
73
|
+
options.left = sideLimit;
|
|
74
|
+
core.FloatingManager.updateFloatPosition(this._actionsList, this._listContainer, options);
|
|
75
|
+
}
|
|
76
|
+
window.requestAnimationFrame(() => {
|
|
77
|
+
this._actionsList.scrollIntoView({ behavior: "smooth", block: "nearest", inline: "nearest" });
|
|
78
|
+
});
|
|
79
|
+
this.ezPopoverOpen.emit(this._actionsList);
|
|
80
|
+
}
|
|
54
81
|
/**
|
|
55
82
|
* Verifica se a lista de ações está aberta.
|
|
56
83
|
*/
|
|
@@ -63,7 +90,8 @@ const EzActionsButton = class {
|
|
|
63
90
|
innerClickTest: this.innerClickCheck,
|
|
64
91
|
isFixed: true,
|
|
65
92
|
top: this.getPositionTop(),
|
|
66
|
-
left: this.getPositionLeft()
|
|
93
|
+
left: this.getPositionLeft(),
|
|
94
|
+
backClickListener: () => this._floatingID = undefined
|
|
67
95
|
};
|
|
68
96
|
}
|
|
69
97
|
getSideLimit() {
|
|
@@ -75,21 +103,6 @@ const EzActionsButton = class {
|
|
|
75
103
|
}
|
|
76
104
|
return;
|
|
77
105
|
}
|
|
78
|
-
showActions() {
|
|
79
|
-
if (!this.enabled) {
|
|
80
|
-
return;
|
|
81
|
-
}
|
|
82
|
-
const options = this.getFloatOptions();
|
|
83
|
-
this._floatingID = core.FloatingManager.float(this._actionsList, this._listContainer, options);
|
|
84
|
-
const sideLimit = this.getSideLimit();
|
|
85
|
-
if (sideLimit != undefined) {
|
|
86
|
-
options.left = sideLimit;
|
|
87
|
-
core.FloatingManager.updateFloatPosition(this._actionsList, this._listContainer, options);
|
|
88
|
-
}
|
|
89
|
-
window.requestAnimationFrame(() => {
|
|
90
|
-
this._actionsList.scrollIntoView({ behavior: "smooth", block: "nearest", inline: "nearest" });
|
|
91
|
-
});
|
|
92
|
-
}
|
|
93
106
|
updatePosition() {
|
|
94
107
|
if (!this.enabled || this._floatingID == undefined) {
|
|
95
108
|
return;
|
|
@@ -172,14 +185,18 @@ const EzActionsButton = class {
|
|
|
172
185
|
}
|
|
173
186
|
}
|
|
174
187
|
}
|
|
188
|
+
disconnectedCallback() {
|
|
189
|
+
this.ezDisconnectedActionButtons.emit();
|
|
190
|
+
}
|
|
175
191
|
componentDidLoad() {
|
|
176
192
|
CSSVarsUtils.CSSVarsUtils.applyVarsButton(this._element, this._button);
|
|
177
193
|
core.ElementIDUtils.addIDInfo(this._element);
|
|
178
194
|
this.controlScrollPage();
|
|
179
195
|
}
|
|
180
196
|
componentDidRender() {
|
|
197
|
+
var _a;
|
|
181
198
|
if (this._floatingID == undefined) {
|
|
182
|
-
this._actionsList.remove();
|
|
199
|
+
(_a = this._actionsList) === null || _a === void 0 ? void 0 : _a.remove();
|
|
183
200
|
}
|
|
184
201
|
if (this.hasLabelOrCheckOption()) {
|
|
185
202
|
if (!!this.value) {
|
|
@@ -190,20 +207,31 @@ const EzActionsButton = class {
|
|
|
190
207
|
}
|
|
191
208
|
}
|
|
192
209
|
}
|
|
210
|
+
buildActionElement(action) {
|
|
211
|
+
var _a;
|
|
212
|
+
if (!action) {
|
|
213
|
+
return;
|
|
214
|
+
}
|
|
215
|
+
if (action.itemBuilder != undefined) {
|
|
216
|
+
const customContent = action.itemBuilder(this._element, action);
|
|
217
|
+
if (typeof customContent === "string") {
|
|
218
|
+
return index.h("div", { class: "ez-actions-button__btn-action", innerHTML: customContent });
|
|
219
|
+
}
|
|
220
|
+
return customContent;
|
|
221
|
+
}
|
|
222
|
+
return index.h("ez-button", { size: "small", label: action.label, onClick: () => this.actionClick(action), enabled: action.enabled, class: "ez-actions-button__btn-action" +
|
|
223
|
+
(this.checkOption || this.hasIconName() ? " ez-actions-button__btn-action--spaced" : "") }, this.checkOption && ((_a = this._selectedAction) === null || _a === void 0 ? void 0 : _a.value) === action.value &&
|
|
224
|
+
index.h("ez-icon", { class: "ez-actions-button__icon-check", slot: "leftIcon", size: "small", iconName: "check" }), !this.checkOption && action.iconName &&
|
|
225
|
+
index.h("ez-icon", { class: "ez-actions-button__icon-item", slot: "leftIcon", size: "small", iconName: action.iconName }));
|
|
226
|
+
}
|
|
193
227
|
render() {
|
|
194
228
|
var _a;
|
|
195
229
|
return (index.h(index.Host, null, index.h("ez-button", { ref: elem => this._button = elem, class: (this.isTransparent ? "ez-actions-button__btn-transparent" : "") +
|
|
196
230
|
(this.showLabel ? " ez-actions-button__btn-label" : ""), label: this.showLabel && ((_a = this._selectedAction) === null || _a === void 0 ? void 0 : _a.label), enabled: this.enabled, mode: this.showLabel ? undefined : "icon", iconName: this.showLabel ? "" : this.displayIcon || "dots-vertical", size: this.size, onClick: () => this.handlerButtonClick() }, this.showLabel &&
|
|
197
231
|
index.h("ez-icon", { class: "ez-actions-button__icon-right", slot: "rightIcon", iconName: this.displayIcon || "dots-vertical" })), index.h("section", { class: "ez-actions-button__list-container", ref: elem => this._listContainer = elem }, this.arrowActive &&
|
|
198
232
|
index.h("div", { class: "ez-actions-button__arrow ez-actions-button__arrow--" + (this.size || "small") +
|
|
199
|
-
(this.isTransparent ? " ez-actions-button__arrow--upped" : "") }), index.h("div", { ref: elem => this._actionsList = elem, class: "ez-actions-button__actions-list" +
|
|
200
|
-
(this.arrowActive && !this.isTransparent ? " ez-actions-button__actions-list--lowered" : "") }, this.actions.map(action =>
|
|
201
|
-
var _a;
|
|
202
|
-
return index.h("ez-button", { size: "small", label: action.label, onClick: () => this.actionClick(action), enabled: action.enabled, class: "ez-actions-button__btn-action" +
|
|
203
|
-
(this.checkOption || this.hasIconName() ? " ez-actions-button__btn-action--spaced" : "") }, this.checkOption && ((_a = this._selectedAction) === null || _a === void 0 ? void 0 : _a.value) === action.value &&
|
|
204
|
-
index.h("ez-icon", { class: "ez-actions-button__icon-check", slot: "leftIcon", size: "small", iconName: "check" }), !this.checkOption && action.iconName &&
|
|
205
|
-
index.h("ez-icon", { class: "ez-actions-button__icon-item", slot: "leftIcon", size: "small", iconName: action.iconName }));
|
|
206
|
-
})))));
|
|
233
|
+
(this.isTransparent ? " ez-actions-button__arrow--upped" : "") }), index.h("div", { ref: elem => this._actionsList = elem, class: "ez-actions-button__actions-list ez-actions-button__actions-list--max-height" +
|
|
234
|
+
(this.arrowActive && !this.isTransparent ? " ez-actions-button__actions-list--lowered" : "") }, this.actions.map(action => this.buildActionElement(action))))));
|
|
207
235
|
}
|
|
208
236
|
get _element() { return index.getElement(this); }
|
|
209
237
|
};
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-a7b0c73d.js');
|
|
6
|
+
const core = require('@sankhyalabs/core');
|
|
7
|
+
|
|
8
|
+
const ezAlertListCss = ":host {\n display: flex;\n\n /* Alert List */\n \n /*@doc Define a largura da lista minimizado */\n --ez-alert-list__container--width: 680px;\n /*@doc Define a altura da lista minimizado */\n --ez-alert-list__container--height: 220px;\n \n /*@doc Define a largura da lista maximizada */\n --ez-alert-list__container--width--expanded: 920px;\n /*@doc Define a altura da lista maximizada */\n --ez-alert-list__container--height--expanded: 540px;\n\n /* Title */\n /*@doc Define a fonte do título do componente */\n --ez-alert-list__title--font-family: var(--font-pattern, \"Roboto\");\n /*@doc Define o tamanho da fonte do título do popup.*/\n --ez-alert-list__title--font-size: var(--title--large, 20px);\n /*@doc Define a cor da fonte do título do popup.*/\n --ez-alert-list__title--color: var(--title--primary, #2b3a54);\n /*@doc Define o peso da fonte do título do popup.*/\n --ez-alert-list__title--font-weight: var(--text-weight--extra-large, 700);\n\n /* @doc Define a borda inferior do item da lista. */\n --ez-list__item--border-bottom: var(--border--small, 1px solid);\n\n /* @doc Define a cor da borda inferior do item da lista. */\n --ez-list__item--border-bottom-color: var(--color--strokes, #DCE0E8);\n\n /* @doc Define o tipo da quebra de linha do item da lista. */\n --ez-list__item--white-space: break-space;\n}\n\n.alert-list__content {\n display: flex;\n flex-direction: column;\n \n gap: var(--space--xs);\n margin: var(--space--large, 24px);\n width: 100%;\n}\n\n.alert-list__container {\n z-index: var(--more-visible--2x, 3);\n display: flex;\n height: var(--ez-alert-list__container--height);\n width: var(--ez-alert-list__container--width);\n border-radius: var(--border--radius-medium);\n background-color: var(--background--xlight);\n box-shadow: var(--shadow--medium);\n\n &.expanded {\n height: var(--ez-alert-list__container--height--expanded);\n width: var(--ez-alert-list__container--width--expanded);\n }\n\n @media (max-height: 640px) {\n max-height: calc(100vh - var(--space--3xl));\n } \n}\n\n.alert-list__header {\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: space-between;\n}\n\n.alert-list__title {\n font-family: var(--ez-alert-list__title--font-family);\n font-size: var(--ez-alert-list__title--font-size);\n font-weight: var(--ez-alert-list__title--font-weight);\n color: var(--ez-alert-list__title--color);\n}\n\n.alert-list__header__buttons {\n display: flex;\n gap: var(--space--xs);\n}\n\n.alert-list__expandable-content {\n overflow-y: auto;\n scrollbar-width: thin;\n}\n\n";
|
|
9
|
+
|
|
10
|
+
const EzAlertList = class {
|
|
11
|
+
constructor(hostRef) {
|
|
12
|
+
index.registerInstance(this, hostRef);
|
|
13
|
+
this.alerts = [];
|
|
14
|
+
this.enableDragAndDrop = undefined;
|
|
15
|
+
this.enableExpand = true;
|
|
16
|
+
this.itemRightSlotBuilder = undefined;
|
|
17
|
+
this.opened = true;
|
|
18
|
+
this.expanded = false;
|
|
19
|
+
}
|
|
20
|
+
observeOpened() {
|
|
21
|
+
this.manageOverlay();
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Retorna o id do alerta a partir do título e do índice.
|
|
25
|
+
*/
|
|
26
|
+
alertId(title, index) {
|
|
27
|
+
const concatTitle = (title) => { var _a; return (_a = title === null || title === void 0 ? void 0 : title.split(' ').join('-')) !== null && _a !== void 0 ? _a : ""; };
|
|
28
|
+
return `alert-${index}-${concatTitle(title)}`;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Retorna o título do alerta a partir do id.
|
|
32
|
+
*/
|
|
33
|
+
getAlertTitle(id) {
|
|
34
|
+
var _a;
|
|
35
|
+
return (_a = this.alerts.find((alert, index) => this.alertId(alert.title, index) === id)) === null || _a === void 0 ? void 0 : _a.title;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Retorna o texto do título do alerta.
|
|
39
|
+
*/
|
|
40
|
+
getTitleText(item) {
|
|
41
|
+
var _a;
|
|
42
|
+
const title = (_a = this.getAlertTitle(item.id)) !== null && _a !== void 0 ? _a : '';
|
|
43
|
+
return `${title}${(title && item.label) ? ':' : ''}`;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Gerencia a exibição do conteúdo expandido.
|
|
47
|
+
*/
|
|
48
|
+
toggleExpandContainer() {
|
|
49
|
+
if (!this.enableExpand) {
|
|
50
|
+
return;
|
|
51
|
+
}
|
|
52
|
+
this.expanded = !this.expanded;
|
|
53
|
+
this._container.classList.toggle('expanded', this.expanded);
|
|
54
|
+
if (this.expanded) {
|
|
55
|
+
this.updatePosition(this.getBoundingRight(), this.getBoundingBottom());
|
|
56
|
+
}
|
|
57
|
+
else {
|
|
58
|
+
this.updatePosition(`10px`, `10px`);
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Gerencia a exibição do overlay usando FloatingManager do Core.
|
|
63
|
+
*/
|
|
64
|
+
async manageOverlay() {
|
|
65
|
+
if (this.opened) {
|
|
66
|
+
this._overlayId = core.FloatingManager.float(this._container, this._overlayRef, this.getFloatOptions());
|
|
67
|
+
}
|
|
68
|
+
else {
|
|
69
|
+
core.FloatingManager.close(this._overlayId);
|
|
70
|
+
this._overlayId = undefined;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Atualiza a posição da lista.
|
|
75
|
+
*/
|
|
76
|
+
updatePosition(right, bottom) {
|
|
77
|
+
core.FloatingManager.updateFloatPosition(this._container, this._overlayRef, Object.assign(Object.assign({}, this.getFloatOptions()), { right,
|
|
78
|
+
bottom }));
|
|
79
|
+
}
|
|
80
|
+
;
|
|
81
|
+
/**
|
|
82
|
+
* Retorna valores padrões do componente
|
|
83
|
+
*/
|
|
84
|
+
getFloatOptions() {
|
|
85
|
+
return {
|
|
86
|
+
autoClose: false,
|
|
87
|
+
isFixed: false,
|
|
88
|
+
bottom: '10px',
|
|
89
|
+
right: '10px',
|
|
90
|
+
};
|
|
91
|
+
}
|
|
92
|
+
;
|
|
93
|
+
/**
|
|
94
|
+
* Retorna o valor para o alinhamento horizontal do componente.
|
|
95
|
+
*/
|
|
96
|
+
getBoundingRight() {
|
|
97
|
+
const docWidth = document.body.clientWidth;
|
|
98
|
+
const boxWidth = this._container.getBoundingClientRect().width;
|
|
99
|
+
return ((docWidth - boxWidth) / 2) + 'px';
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* Retorna o valor para o alinhamento vertical do componente.
|
|
103
|
+
*/
|
|
104
|
+
getBoundingBottom() {
|
|
105
|
+
const docHeight = document.body.clientHeight;
|
|
106
|
+
const boxHeight = this._container.getBoundingClientRect().height;
|
|
107
|
+
return ((docHeight - boxHeight) / 2) + 'px';
|
|
108
|
+
}
|
|
109
|
+
componentDidRender() {
|
|
110
|
+
this.manageOverlay();
|
|
111
|
+
if (this.opened) {
|
|
112
|
+
this._container.focus();
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
componentWillLoad() {
|
|
116
|
+
this.dataElementId = core.ElementIDUtils.addIDInfo(this._element, 'EzAlertList');
|
|
117
|
+
}
|
|
118
|
+
render() {
|
|
119
|
+
return (index.h(index.Host, Object.assign({}, { [core.ElementIDUtils.DATA_ELEMENT_ID_ATTRIBUTE_NAME]: this.dataElementId }), index.h("div", { ref: elem => (this._overlayRef = elem) }, index.h("div", { class: `alert-list__container ${this.expanded ? 'expanded' : ''}`, ref: elem => (this._container = elem) }, index.h("div", { class: "alert-list__content" }, index.h("div", { class: "alert-list__header" }, index.h("div", { class: "alert-list__title" }, `Avisos (${this.alerts.length})`), index.h("div", { class: "alert-list__header__buttons" }, this.enableExpand && (index.h("ez-button", { mode: "icon", size: "small", iconName: "expand", onClick: () => this.toggleExpandContainer(), "data-element-id": core.ElementIDUtils.getInternalIDInfo('expandButton'), title: this.expanded ? 'Resumir' : 'Expandir' })), index.h("ez-button", { mode: "icon", size: "small", iconName: "close", "data-element-id": core.ElementIDUtils.getInternalIDInfo('closeButton'), onClick: () => {
|
|
120
|
+
this.opened = false;
|
|
121
|
+
}, title: 'Fechar' }))), index.h("div", { class: "alert-list__expandable-content" }, index.h("ez-list", { hoverFeedback: true, itemLeftSlotBuilder: item => {
|
|
122
|
+
return (index.h("a", { href: "#", style: {
|
|
123
|
+
fontFamily: "var(--font-pattern, 'Roboto')",
|
|
124
|
+
fontSize: 'var(--text--medium, 14px)',
|
|
125
|
+
fontWeight: 'var(--text-weight--medium, 400)',
|
|
126
|
+
color: 'var(--color--primary, #008561)',
|
|
127
|
+
marginRight: '4px',
|
|
128
|
+
cursor: 'pointer',
|
|
129
|
+
display: 'flex',
|
|
130
|
+
width: 'max-content',
|
|
131
|
+
textDecoration: 'none'
|
|
132
|
+
} }, this.getTitleText(item)));
|
|
133
|
+
}, dataSource: this.alerts.map((alert, index) => {
|
|
134
|
+
var _a;
|
|
135
|
+
return {
|
|
136
|
+
id: this.alertId(alert.title, index),
|
|
137
|
+
label: (_a = alert.detail) !== null && _a !== void 0 ? _a : "",
|
|
138
|
+
};
|
|
139
|
+
}) })))))));
|
|
140
|
+
}
|
|
141
|
+
get _element() { return index.getElement(this); }
|
|
142
|
+
static get watchers() { return {
|
|
143
|
+
"opened": ["observeOpened"]
|
|
144
|
+
}; }
|
|
145
|
+
};
|
|
146
|
+
EzAlertList.style = ezAlertListCss;
|
|
147
|
+
|
|
148
|
+
exports.ez_alert_list = EzAlertList;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-a7b0c73d.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
7
|
|
|
8
8
|
const ezAlertCss = ":host{--ez-alert-alert-container--padding-up-down:var(--space--small, 6px);--ez-alert-alert-container--padding-right-left:var(--space--medium, 12px);--ez-alert-alert-container--gap:var(--space--medium, 12px);--ez-alert-alert-container--border-radius:var(--border--radius-medium, 12px);--ez-alert-alert-container--font-color-warn:var(--color--alert-warning-900, #8C6B00);--ez-alert-alert-container--icon-warn:var(--color--alert-warning-900, #8C6B00);--ez-alert-alert-container--background-color-warn:var(--color--alert-warning-200, #FFF7D5);--ez-alert-alert-container--font-color-critical:var(--color--alert-error, #BD0025);--ez-alert-alert-container--icon-critical:var(--color--alert-error, #BD0025);--ez-alert-alert-container--background-color-critical:var(--color--alert-error-200, #F7E0E5);--ez-alert-alert-container--font-color-success:var(--color--alert-success, #157A00);--ez-alert-alert-container--icon-success:var(--color--alert-success, #157A00);--ez-alert-alert-container--background-color-success:var(--color--alert-success-200, #E7F6E0);font-size:var(--text--small, 12px);font-family:var(--font-pattern, \"Roboto\");width:100%;hyphens:auto;display:block}.alert-container{display:flex;align-items:center;gap:var(--ez-alert-alert-container--gap);padding:var(--ez-alert-alert-container--padding-up-down) var(--ez-alert-alert-container--padding-right-left);border-radius:var(--ez-alert-alert-container--border-radius)}.warn{background-color:var(--ez-alert-alert-container--background-color-warn);color:var(--ez-alert-alert-container--font-color-warn)}.critical{background-color:var(--ez-alert-alert-container--background-color-critical);color:var(--ez-alert-alert-container--font-color-critical)}.success{background-color:var(--ez-alert-alert-container--background-color-success);color:var(--ez-alert-alert-container--font-color-success)}ez-icon{--ez-icon--color:inherit}.alert-container__icon-warn{--ez-icon--color:var(--ez-alert-alert-container--icon-warn)}.alert-container__icon-critical{--ez-icon--color:var(--ez-alert-alert-container--icon-critical)}.alert-container__icon-success{--ez-icon--color:var(--ez-alert-alert-container--icon-success)}";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-a7b0c73d.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
7
|
|
|
8
8
|
const ezButtonCss = ":host{--ez-button--min-width:100px;--ez-button--width:'auto';--ez-button--height:42px;--ez-button__icon--width:18px;--ez-button__inline__icon--padding:12px;--ez-button--padding-top:0px;--ez-button--padding-bottom:0px;--ez-button--padding-right:var(--space--large, 24px);--ez-button--padding-left:var(--space--large, 24px);--ez-button--color:var(--title--primary, #FFF);--ez-button--font-size:var(--text--medium, 14px);--ez-button--font-family:var(--font-pattern, Arial);--ez-button--font-weight:var(--text-weight--large);--ez-button--background-color:var(--background--medium, #c0c0c0);--ez-button--border-radius:var(--border--radius-large, 12px);--ez-button--border:none;--ez-button--justify-content:center;--ez-button--hover-color:var(--color--primary-600);--ez-button--hover--background-color:var(--background--medium, var(--ez-button--background-color));--ez-button--disabled-color:var(--text--disable);--ez-button--disabled--background-color:var(--color--disable-secondary);--ez-button--focus--border:var(--border--xlarge, 4px solid) var(--color--primary-300);--ez-button--focus--box-shadow:none;--ez-button--active-color:var(--color--primary-700);--ez-button--active--background-color:var(--background--strong);--ez-button--link-color:var(--color--primary, '#008561');--ez-button--link--hover-color:var(--color--primary-700, '#1C1D22');--ez-button--link--small--font-size:var(--text--small, 12px);--ez-button--link--medium--font-size:var(--text--medium, 14px);--ez-button--link--large--font-size:var(--text--large, 16px)}ez-icon{--ez-icon--color:inherit}button{position:relative;display:flex;align-items:center;margin:0;cursor:pointer;transition:background-color 0.2s linear;white-space:nowrap;min-width:var(--ez-button--min-width);width:var(--ez-button--width);height:var(--ez-button--height);font-family:var(--ez-button--font-family);font-size:var(--ez-button--font-size);font-weight:var(--ez-button--font-weight);padding:var(--ez-button--padding-top) var(--ez-button--padding-right) var(--ez-button--padding-bottom) var(--ez-button--padding-left);border-radius:var(--ez-button--border-radius);background-color:var(--ez-button--background-color);color:var(--ez-button--color);fill:var(--ez-button--color);border:var(--ez-button--border);justify-content:var(--ez-button--justify-content)}button:focus{outline:var(--ez-button--focus--border);box-shadow:var(--ez-button--focus--box-shadow)}button:hover{outline:none;background-color:var(--ez-button--hover--background-color);color:var(--ez-button--hover-color);fill:var(--ez-button--hover-color);--ez-icon--color:var(--ez-button--hover-color)}button:active{outline:none;box-shadow:none;background-color:var(--ez-button--active--background-color);color:var(--ez-button--active-color);fill:var(--ez-button--active-color);--ez-icon--color:var(--ez-button--active-color)}button:disabled{background-color:var(--ez-button--disabled--background-color);color:var(--ez-button--disabled-color);fill:var(--ez-button--disabled-color);border:none;--ez-icon--color:var(--ez-button--disabled-color);cursor:no-drop}.small{height:32px;--ez-button--font-size:var(--text--small, 12px)}.medium{height:42px}.large{height:46px}.btn-icon{padding:0px}.btn-icon--medium{width:42px;min-width:42px;height:42px}.btn-icon--small{width:32px;min-width:32px;height:32px}.btn-icon--large{width:46px;min-width:46px;height:46px}.label-icon{display:flex;flex-direction:column;align-items:center;color:var(--ez-button--color)}.label-icon:hover{color:var(--ez-button--hover-color);fill:var(--ez-button--hover-color);--ez-icon--color:var(--ez-button--hover-color)}.label-icon:active{color:var(--ez-button--active-color);fill:var(--ez-button--active-color);--ez-icon--color:var(--ez-button--active-color)}.label-icon label{max-width:150px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;cursor:pointer;font-family:var(--ez-button--font-family);font-size:var(--ez-button--font-size);font-weight:var(--ez-button--font-weight);user-select:none}button:disabled+label{max-width:150px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;cursor:pointer;font-family:var(--ez-button--font-family);font-size:var(--ez-button--font-size);font-weight:var(--ez-button--font-weight);color:var(--ez-button--disabled-color);cursor:no-drop}div.label-icon{cursor:pointer}div.label-icon,button:disabled{cursor:no-drop}a{font-family:var(--ez-button--font-family);font-weight:var(--ez-button--font-weight);color:var(--ez-button--link-color);cursor:pointer;display:flex;align-items:center;justify-content:center;}a:hover{color:var(--ez-button--link--hover-color)}a.small{font-size:var(--ez-button--link--small--font-size);line-height:var(--ez-button--link--small--font-size)}a.medium{font-size:var(--ez-button--link--medium--font-size);line-height:var(--ez-button--link--medium--font-size)}a.large{font-size:var(--ez-button--link--large--font-size);line-height:var(--ez-button--link--large--font-size)}";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-a7b0c73d.js');
|
|
6
6
|
const core = require('@sankhyalabs/core');
|
|
7
7
|
|
|
8
8
|
const ezCalendarCss = ":host{--ez-calendar--font-family:var(--font-pattern, Arial);--ez-calendar--color:var(--title--primary, #626e82);--ez-calendar--text-shadow:var(--text-shadow, 0 0 0 #353535, 0 0 1px transparent);--ez-calendar__body--background-color:var(--background--xlight, #FFF);--ez-calendar__time--background-color:var(--background--xlight, #FAFAFA);--ez-calendar__body--padding:var(--space--medium, 12px) var(--space--small, 6px);--ez-calendar__body--border-radius:var(--border--radius-medium, 12px);--ez-calendar__body--shadow:var(--shadow, 0px 0px 16px 0px #000);--ez-container--z-index:var(--more-visible, 2);--ez-calendar__header-line--stroke:1px;--ez-calendar__header-line--color:var(--color--strokes, #C0C0C0);--ez-calendar__nav-btn--fill:var(--text--primary, #008561);--ez-calendar__nav-btn--hover--fill:var(--color--primary, #350404);--ez-calendar__nav-btn--width:10px;--ez-calendar__nav-btn--height:16px;--ez-calendar__nav-btn--previous-image:url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" version=\"1.1\" height=\"16px\" width=\"10px\"><path d=\"M 9.7808475,13.860393 3.9204526,8.0000004 9.7808475,2.0624965 7.9301965,0.28895552 0.21915255,8.0000004 7.9301965,15.711044 Z\"/></svg>');--ez-calendar__nav-btn--next-image:url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" version=\"1.1\" height=\"16px\" width=\"10px\"><path d=\"M 0.21915251,13.860393 6.0795475,8.0000007 0.21915251,2.0624968 2.0698036,0.28895588 9.7808475,8.0000007 2.0698036,15.711044 Z\"/></svg>');--ez-calendar__cell--margin:0px 1.5px;--ez-calendar__cell--width:var(--space--large, 24px);--ez-calendar__cell--padding:1.5px 0px;--ez-calendar__cell--border-radius:var(--border--radius-small, 6px);--ez-calendar__cell--over--background-color:var(--color--primary, #E2F4EF);--ez-calendar__cell--over--color:var(--color--primary-300, #008561);--ez-calendar__cell--outset--color:var(--color--disable-primary, #E5EAF0);--ez-calendar__cell--selected--background-color:var(--color--primary, #008561);--ez-calendar__cell--selected--color:var(--color--inverted, #FFF);--ez-calendar__btn-today--color:var(--color--primary);--ez-calendar__btn-today--hover--background-color:var(--color--primary-300, #E2F4EF);--ez-calendar__btn-today--border-radius:var(--border--radius-small, 6px);position:relative;display:flex;user-select:none}.calendar__container{display:flex;z-index:var(--more-visible, 2)}.calendar{display:flex;flex-direction:column;z-index:var(--more-visible, 2);background-color:var(--ez-calendar__body--background-color);padding:var(--ez-calendar__body--padding);border-radius:var(--ez-calendar__body--border-radius);box-shadow:var(--ez-calendar__body--shadow)}.calendar__header{display:flex;justify-content:space-between;padding-bottom:var(--space--small, 6px);margin:0px var(--space--, 12px) var(--space--small, 6px) var(--space--, 12px);font-family:var(--ez-calendar--font-family);color:var(--ez-calendar--color);text-shadow:var(--ez-calendar--text-shadow);border-bottom:solid var(--ez-calendar__header-line--stroke) var(--ez-calendar__header-line--color)}.calendar__btn-next,.calendar__btn-previous{outline:none;border:none;background-color:unset;cursor:pointer;padding:0px}.calendar__btn-next::after,.calendar__btn-previous::after{content:'';display:flex;background-color:var(--ez-calendar__nav-btn--fill);width:var(--ez-calendar__nav-btn--width);height:var(--ez-calendar__nav-btn--height)}.calendar__btn-previous::after{-webkit-mask-image:var(--ez-calendar__nav-btn--previous-image);mask-image:var(--ez-calendar__nav-btn--previous-image)}.calendar__btn-next::after{-webkit-mask-image:var(--ez-calendar__nav-btn--next-image);mask-image:var(--ez-calendar__nav-btn--next-image)}.calendar__btn-next:hover::after,.calendar__btn-previous:hover::after{background-color:var(--ez-calendar__nav-btn--hover--fill)}.calendar__lbl-month{font-weight:var(--text-weight--extra-large, 700);font-size:var(--title--small, 14px);font-family:var(--ez-calendar--font-family);color:var(--ez-calendar--color);text-shadow:var(--ez-calendar--text-shadow)}.calendar__line{display:flex;padding:0px;margin:0px}.calendar__cell{display:flex;justify-content:center;align-content:center;cursor:pointer;font-size:var(--text--extra-small, 10px);font-family:var(--ez-calendar--font-family);color:var(--ez-calendar--color);text-shadow:var(--ez-calendar--text-shadow);padding:var(--ez-calendar__cell--padding);margin:var(--ez-calendar__cell--margin);min-width:var(--ez-calendar__cell--width);border-radius:var(--ez-calendar__cell--border-radius)}.calendar__cell:hover{background-color:var(--ez-calendar__cell--over--background-color);color:var(--ez-calendar__cell--over--color)}.calendar__cell--secondary{color:var(--ez-calendar__cell--outset--color)}.calendar__cell--unselectable:hover{background-color:unset;border-radius:unset;cursor:unset;color:var(--ez-calendar--color)}.calendar__cell--unselectable{font-weight:var(--text-weight--large, 600);font-family:var(--ez-calendar--font-family);color:var(--ez-calendar--color);text-shadow:var(--ez-calendar--text-shadow)}.calendar__cell--selected,.calendar__cell--selected:hover{background-color:var(--ez-calendar__cell--selected--background-color);color:var(--ez-calendar__cell--selected--color)}.calendar__footer{display:flex;flex-direction:column}.calendar__btn-today{border:none;background-color:unset;cursor:pointer;padding:0px;font-weight:var(--text-weight--large, 600);font-size:var(--title--extra-small, 12px);font-family:var(--ez-calendar--font-family);text-shadow:var(--ez-calendar--text-shadow);color:var(--ez-calendar__btn-today--color);border-radius:var(--ez-calendar__btn-today--border-radius)}.calendar__btn-today:hover{background-color:var(--ez-calendar__btn-today--hover--background-color)}section{display:flex}.calendar-time{margin-left:-10px;display:flex;flex-direction:column;padding:12px 0px 0px 10px;background-color:var(--ez-calendar__time--background-color);border-top-right-radius:var(--ez-calendar__body--border-radius);border-bottom-right-radius:var(--ez-calendar__body--border-radius);box-shadow:var(--ez-calendar__body--shadow)}.calendar__column{height:136px;padding:0px;margin:0px;overflow:auto;scrollbar-width:none}.calendar__column::-webkit-scrollbar{width:0px;max-width:0px;min-width:0px}.calendar-time__header{display:flex;justify-content:space-between;padding-left:var(--space--small, 6px);padding-right:var(--space--small, 6px);padding-bottom:var(--space--small, 6px);margin:0px var(--space--, 12px) var(--space--small, 6px) var(--space--, 12px);font-weight:var(--text-weight--extra-large, 700);font-size:var(--title--small, 14px);text-shadow:var(--ez-calendar--text-shadow);border-bottom:solid var(--ez-calendar__header-line--stroke) var(--ez-calendar__header-line--color);font-family:var(--ez-calendar--font-family);color:var(--ez-calendar--color);text-shadow:var(--ez-calendar--text-shadow)}.separatorTime{color:#A2ABB9;padding:0px 1px;line-height:16px;font-size:17px;font-weight:normal}.endHidden{-webkit-mask-image:linear-gradient(180deg, #000 calc(100% - 48px), transparent 100%)}.calendar__column .calendar__cell{margin:0px;padding:1.5px 1.5px}";
|