@sankhyalabs/sankhyablocks 1.3.34 → 1.4.0-beta.10
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/SnkMessageBuilder-6c2f7bcd.js +302 -0
- package/dist/cjs/_commonjsHelpers-537d719a.js +20 -0
- package/dist/cjs/configurableElementsStorage-93459c72.js +20 -0
- package/dist/cjs/constants-9056ca9e.js +84 -0
- package/dist/cjs/draggable.bundle-82a25c06.js +6886 -0
- package/dist/cjs/filter-item-type.enum-3daf58d3.js +16 -0
- package/dist/cjs/form-config-fetcher-2de7c16a.js +6895 -0
- package/dist/cjs/{index-1133bc2a.js → index-20e8b68a.js} +964 -209
- package/dist/cjs/loader.cjs.js +3 -3
- package/dist/cjs/sankhyablocks.cjs.js +3 -3
- package/dist/cjs/snk-application.cjs.entry.js +680 -6994
- package/dist/cjs/snk-config-modal.cjs.entry.js +62 -0
- package/dist/cjs/snk-config-options.cjs.entry.js +230 -0
- package/dist/cjs/snk-configurator_6.cjs.entry.js +1156 -0
- package/dist/cjs/snk-crud.cjs.entry.js +78 -0
- package/dist/cjs/snk-data-unit.cjs.entry.js +272 -0
- package/dist/cjs/snk-field-config_2.cjs.entry.js +135 -0
- package/dist/cjs/snk-filter-binary-select.cjs.entry.js +50 -0
- package/dist/cjs/snk-filter-detail.cjs.entry.js +106 -0
- package/dist/cjs/snk-filter-multi-select.cjs.entry.js +26 -0
- package/dist/cjs/snk-filter-number.cjs.entry.js +27 -0
- package/dist/cjs/snk-filter-period.cjs.entry.js +40 -0
- package/dist/cjs/snk-filter-personalized.cjs.entry.js +89 -0
- package/dist/cjs/snk-filter-search.cjs.entry.js +38 -0
- package/dist/cjs/snk-filter-text.cjs.entry.js +22 -0
- package/dist/cjs/snk-form-config.cjs.entry.js +957 -0
- package/dist/cjs/snk-form.cjs.entry.js +146 -0
- package/dist/cjs/snk-pesquisa.cjs.entry.js +1 -1
- package/dist/cjs/snk-tab-config.cjs.entry.js +321 -0
- package/dist/cjs/taskbar-elements-9a4b1e19.js +97 -0
- package/dist/cjs/taskbar-processor-6bd0d35c.js +47 -0
- package/dist/cjs/teste-pesquisa.cjs.entry.js +1 -1
- package/dist/collection/collection-manifest.json +45 -2
- package/dist/collection/components/snk-application/errorhandler/snk-error-handler.js +9 -2
- package/dist/collection/components/snk-application/snk-application.js +1346 -642
- package/dist/collection/components/snk-configurator/snk-configurator.js +261 -0
- package/dist/collection/components/snk-configurator/subcomponents/configModalProvider/configurableElementsStorage.js +16 -0
- package/dist/collection/components/snk-configurator/subcomponents/snk-config-modal/snk-config-modal.css +122 -0
- package/dist/collection/components/snk-configurator/subcomponents/snk-config-modal/snk-config-modal.js +137 -0
- package/dist/collection/components/snk-crud/snk-crud.css +6 -0
- package/dist/collection/components/snk-crud/snk-crud.js +232 -0
- package/dist/collection/components/snk-data-unit/snk-data-unit.css +6 -0
- package/dist/collection/components/snk-data-unit/snk-data-unit.js +517 -0
- package/dist/collection/components/snk-filter-bar/filter-item/dataunitfilter/data-unit-filter-builder.js +100 -0
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-binary-select.js +111 -0
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-multi-select.js +87 -0
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-number.js +88 -0
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-period.js +101 -0
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-personalized.js +180 -0
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-search.js +102 -0
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-text.js +63 -0
- package/dist/collection/components/snk-filter-bar/filter-item/filter-item-type.enum.js +12 -0
- package/dist/collection/components/snk-filter-bar/filter-item/snk-filter-detail.js +178 -0
- package/dist/collection/components/snk-filter-bar/filter-item/snk-filter-item.js +289 -0
- package/dist/collection/components/snk-filter-bar/filter-list/snk-filter-list.js +299 -0
- package/dist/collection/components/snk-filter-bar/filter-modal/snk-filter-modal.js +222 -0
- package/dist/collection/components/snk-filter-bar/snk-filter-bar.css +149 -0
- package/dist/collection/components/snk-filter-bar/snk-filter-bar.js +462 -0
- package/dist/collection/components/snk-form/snk-form.css +38 -0
- package/dist/collection/components/snk-form/snk-form.js +336 -0
- package/dist/collection/components/snk-form/subcomponents/snk-config-options/snk-config-options.css +9 -0
- package/dist/collection/components/snk-form/subcomponents/snk-config-options/snk-config-options.js +315 -0
- package/dist/collection/components/snk-form/subcomponents/snk-field-config/snk-field-config.css +164 -0
- package/dist/collection/components/snk-form/subcomponents/snk-field-config/snk-field-config.js +140 -0
- package/dist/collection/components/snk-form/subcomponents/snk-form-config/snk-form-config.css +185 -0
- package/dist/collection/components/snk-form/subcomponents/snk-form-config/snk-form-config.js +1062 -0
- package/dist/collection/components/snk-form/subcomponents/snk-tab-config/snk-tab-config.css +272 -0
- package/dist/collection/components/snk-form/subcomponents/snk-tab-config/snk-tab-config.js +476 -0
- package/dist/collection/components/snk-grid/snk-grid.css +18 -0
- package/dist/collection/components/snk-grid/snk-grid.js +273 -0
- package/dist/collection/components/snk-pesquisa/snk-pesquisa.js +80 -79
- package/dist/collection/components/snk-taskbar/elements/taskbar-elements.js +90 -0
- package/dist/collection/components/snk-taskbar/processor/taskbar-processor.js +43 -0
- package/dist/collection/components/snk-taskbar/snk-taskbar.css +3 -0
- package/dist/collection/components/snk-taskbar/snk-taskbar.js +339 -0
- package/dist/collection/components/teste-pesquisa/teste-pesquisa.js +12 -9
- package/dist/collection/lib/http/data-fetcher/DataFetcher.js +39 -14
- package/dist/collection/lib/http/data-fetcher/fetchers/dataunit-fetcher.js +87 -21
- package/dist/collection/lib/http/data-fetcher/fetchers/filter-bar-config-fetcher.js +62 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/form-config-fetcher.js +106 -3
- package/dist/collection/lib/http/data-fetcher/fetchers/grid-config-fetcher.js +4 -3
- package/dist/collection/lib/http/data-fetcher/fetchers/parameters-fecher.js +15 -15
- package/dist/collection/lib/http/data-fetcher/fetchers/resource-fetcher.js +9 -1
- package/dist/collection/lib/http/data-fetcher/fetchers/totals-fetcher.js +47 -0
- package/dist/collection/lib/index.js +2 -0
- package/dist/collection/lib/message/SnkMessageBuilder.js +130 -0
- package/dist/collection/lib/message/resources/crud-utils.msg.js +4 -0
- package/dist/collection/lib/message/resources/snk-configurator.msg.js +11 -0
- package/dist/collection/lib/message/resources/snk-data-unit.msg.js +23 -0
- package/dist/collection/lib/message/resources/snk-filter-bar.msg.js +30 -0
- package/dist/collection/lib/message/resources/snk-form.msg.js +67 -0
- package/dist/collection/lib/message/resources/snk-taskbar.msg.js +17 -0
- package/dist/collection/lib/utils/CrudUtils.js +73 -0
- package/dist/collection/lib/utils/constants.js +72 -0
- package/dist/components/SnkMessageBuilder.js +280 -0
- package/dist/components/_commonjsHelpers.js +17 -0
- package/dist/components/constants.js +74 -0
- package/dist/components/filter-item-type.enum.js +14 -0
- package/dist/components/form-config-fetcher.js +6889 -0
- package/dist/components/index.d.ts +26 -5
- package/dist/components/index.js +26 -0
- package/dist/components/snk-application2.js +681 -6980
- package/dist/components/snk-config-modal.d.ts +11 -0
- package/dist/components/snk-config-modal.js +6 -0
- package/dist/components/snk-config-modal2.js +91 -0
- package/dist/components/snk-config-options.d.ts +11 -0
- package/dist/components/snk-config-options.js +6 -0
- package/dist/components/snk-config-options2.js +245 -0
- package/dist/components/snk-configurator.d.ts +11 -0
- package/dist/components/snk-configurator.js +6 -0
- package/dist/components/snk-configurator2.js +212 -0
- package/dist/components/snk-crud.d.ts +11 -0
- package/dist/components/snk-crud.js +183 -0
- package/dist/components/snk-data-unit.d.ts +11 -0
- package/dist/components/snk-data-unit.js +294 -0
- package/dist/components/snk-field-config.d.ts +11 -0
- package/dist/components/snk-field-config.js +6 -0
- package/dist/components/snk-field-config2.js +70 -0
- package/dist/components/snk-filter-bar.d.ts +11 -0
- package/dist/components/snk-filter-bar.js +6 -0
- package/dist/components/snk-filter-bar2.js +516 -0
- package/dist/components/snk-filter-binary-select.d.ts +11 -0
- package/dist/components/snk-filter-binary-select.js +67 -0
- package/dist/components/snk-filter-detail.d.ts +11 -0
- package/dist/components/snk-filter-detail.js +6 -0
- package/dist/components/snk-filter-detail2.js +120 -0
- package/dist/components/snk-filter-item.d.ts +11 -0
- package/dist/components/snk-filter-item.js +6 -0
- package/dist/components/snk-filter-item2.js +194 -0
- package/dist/components/snk-filter-list.d.ts +11 -0
- package/dist/components/snk-filter-list.js +6 -0
- package/dist/components/snk-filter-list2.js +149 -0
- package/dist/components/snk-filter-modal.d.ts +11 -0
- package/dist/components/snk-filter-modal.js +6 -0
- package/dist/components/snk-filter-modal2.js +84 -0
- package/dist/components/snk-filter-multi-select.d.ts +11 -0
- package/dist/components/snk-filter-multi-select.js +43 -0
- package/dist/components/snk-filter-number.d.ts +11 -0
- package/dist/components/snk-filter-number.js +44 -0
- package/dist/components/snk-filter-period.d.ts +11 -0
- package/dist/components/snk-filter-period.js +57 -0
- package/dist/components/snk-filter-personalized.d.ts +11 -0
- package/dist/components/snk-filter-personalized.js +108 -0
- package/dist/components/snk-filter-search.d.ts +11 -0
- package/dist/components/snk-filter-search.js +55 -0
- package/dist/components/snk-filter-text.d.ts +11 -0
- package/dist/components/snk-filter-text.js +38 -0
- package/dist/components/snk-form-config.d.ts +11 -0
- package/dist/components/snk-form-config.js +6 -0
- package/dist/components/snk-form-config2.js +996 -0
- package/dist/components/snk-form.d.ts +11 -0
- package/dist/components/snk-form.js +6 -0
- package/dist/components/snk-form2.js +209 -0
- package/dist/components/snk-grid.d.ts +11 -0
- package/dist/components/snk-grid.js +6 -0
- package/dist/components/snk-grid2.js +152 -0
- package/dist/components/snk-tab-config.d.ts +11 -0
- package/dist/components/snk-tab-config.js +6 -0
- package/dist/components/snk-tab-config2.js +7220 -0
- package/dist/components/snk-taskbar.d.ts +11 -0
- package/dist/components/snk-taskbar.js +6 -0
- package/dist/components/snk-taskbar2.js +282 -0
- package/dist/components/taskbar-processor.js +45 -0
- package/dist/esm/SnkMessageBuilder-5792c260.js +280 -0
- package/dist/esm/_commonjsHelpers-9943807e.js +17 -0
- package/dist/esm/configurableElementsStorage-cdc144b5.js +18 -0
- package/dist/esm/constants-c6039d3d.js +74 -0
- package/dist/esm/draggable.bundle-41d56f06.js +6884 -0
- package/dist/esm/filter-item-type.enum-a79b2fa8.js +14 -0
- package/dist/esm/form-config-fetcher-96c6c2dc.js +6889 -0
- package/dist/esm/{index-ffda6382.js → index-e4121713.js} +963 -210
- package/dist/esm/loader.js +3 -3
- package/dist/esm/polyfills/css-shim.js +1 -1
- package/dist/esm/sankhyablocks.js +3 -3
- package/dist/esm/snk-application.entry.js +667 -6981
- package/dist/esm/snk-config-modal.entry.js +58 -0
- package/dist/esm/snk-config-options.entry.js +226 -0
- package/dist/esm/snk-configurator_6.entry.js +1147 -0
- package/dist/esm/snk-crud.entry.js +74 -0
- package/dist/esm/snk-data-unit.entry.js +268 -0
- package/dist/esm/snk-field-config_2.entry.js +130 -0
- package/dist/esm/snk-filter-binary-select.entry.js +46 -0
- package/dist/esm/snk-filter-detail.entry.js +102 -0
- package/dist/esm/snk-filter-multi-select.entry.js +22 -0
- package/dist/esm/snk-filter-number.entry.js +23 -0
- package/dist/esm/snk-filter-period.entry.js +36 -0
- package/dist/esm/snk-filter-personalized.entry.js +85 -0
- package/dist/esm/snk-filter-search.entry.js +34 -0
- package/dist/esm/snk-filter-text.entry.js +18 -0
- package/dist/esm/snk-form-config.entry.js +953 -0
- package/dist/esm/snk-form.entry.js +142 -0
- package/dist/esm/snk-pesquisa.entry.js +1 -1
- package/dist/esm/snk-tab-config.entry.js +317 -0
- package/dist/esm/taskbar-elements-e2ed0536.js +94 -0
- package/dist/esm/taskbar-processor-aa6772c9.js +45 -0
- package/dist/esm/teste-pesquisa.entry.js +1 -1
- package/dist/sankhyablocks/p-029ae4e4.entry.js +1 -0
- package/dist/sankhyablocks/p-03f9c407.js +1 -0
- package/dist/sankhyablocks/p-112455b1.js +1 -0
- package/dist/sankhyablocks/p-12ad2a19.entry.js +1 -0
- package/dist/sankhyablocks/p-1feabfc7.entry.js +1 -0
- package/dist/sankhyablocks/p-21c8929b.js +1 -0
- package/dist/sankhyablocks/p-2284c850.entry.js +1 -0
- package/dist/sankhyablocks/p-2b891c4a.entry.js +1 -0
- package/dist/sankhyablocks/p-2dc76d79.entry.js +1 -0
- package/dist/sankhyablocks/p-361299e8.js +26 -0
- package/dist/sankhyablocks/p-3a276f3d.entry.js +1 -0
- package/dist/sankhyablocks/p-400cc777.entry.js +1 -0
- package/dist/sankhyablocks/{p-2a7b4cb3.entry.js → p-44ce5b90.entry.js} +1 -1
- package/dist/sankhyablocks/p-521c96f0.entry.js +1 -0
- package/dist/sankhyablocks/{p-9520d78a.entry.js → p-6988f4a6.entry.js} +1 -1
- package/dist/sankhyablocks/p-776ff4d1.entry.js +1 -0
- package/dist/sankhyablocks/p-7b4a4a50.entry.js +1 -0
- package/dist/sankhyablocks/p-9ba3df4c.js +2 -0
- package/dist/sankhyablocks/p-9dc4426d.entry.js +1 -0
- package/dist/sankhyablocks/p-9dd2b8cb.js +1 -0
- package/dist/sankhyablocks/p-a17a4fca.entry.js +1 -0
- package/dist/sankhyablocks/p-a5b26df2.js +1 -0
- package/dist/sankhyablocks/p-b6d6b172.js +1 -0
- package/dist/sankhyablocks/p-cc4bef9f.entry.js +1 -0
- package/dist/sankhyablocks/p-d50651a3.js +1 -0
- package/dist/sankhyablocks/p-d690b6b5.entry.js +75 -0
- package/dist/sankhyablocks/p-d9fbb26f.js +1 -0
- package/dist/sankhyablocks/p-deb1f523.entry.js +1 -0
- package/dist/sankhyablocks/p-e871aa92.entry.js +1 -0
- package/dist/sankhyablocks/p-e9beab79.entry.js +1 -0
- package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
- package/dist/types/components/snk-application/errorhandler/snk-error-handler.d.ts +1 -0
- package/dist/types/components/snk-application/snk-application.d.ts +178 -26
- package/dist/types/components/snk-configurator/snk-configurator.d.ts +46 -0
- package/dist/types/components/snk-configurator/subcomponents/configModalProvider/configurableElementsStorage.d.ts +8 -0
- package/dist/types/components/snk-configurator/subcomponents/snk-config-modal/snk-config-modal.d.ts +38 -0
- package/dist/types/components/snk-crud/snk-crud.d.ts +50 -0
- package/dist/types/components/snk-data-unit/snk-data-unit.d.ts +92 -0
- package/dist/types/components/snk-filter-bar/filter-item/dataunitfilter/data-unit-filter-builder.d.ts +4 -0
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-binary-select.d.ts +13 -0
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-multi-select.d.ts +9 -0
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-number.d.ts +9 -0
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-period.d.ts +15 -0
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-personalized.d.ts +24 -0
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-search.d.ts +11 -0
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-text.d.ts +8 -0
- package/dist/types/components/snk-filter-bar/filter-item/filter-item-type.enum.d.ts +11 -0
- package/dist/types/components/snk-filter-bar/filter-item/snk-filter-detail.d.ts +20 -0
- package/dist/types/components/snk-filter-bar/filter-item/snk-filter-item.d.ts +40 -0
- package/dist/types/components/snk-filter-bar/filter-list/snk-filter-list.d.ts +45 -0
- package/dist/types/components/snk-filter-bar/filter-modal/snk-filter-modal.d.ts +26 -0
- package/dist/types/components/snk-filter-bar/snk-filter-bar.d.ts +65 -0
- package/dist/types/components/snk-form/snk-form.d.ts +71 -0
- package/dist/types/components/snk-form/subcomponents/snk-config-options/snk-config-options.d.ts +51 -0
- package/dist/types/components/snk-form/subcomponents/snk-field-config/snk-field-config.d.ts +32 -0
- package/dist/types/components/snk-form/subcomponents/snk-form-config/snk-form-config.d.ts +139 -0
- package/dist/types/components/snk-form/subcomponents/snk-tab-config/snk-tab-config.d.ts +97 -0
- package/dist/types/components/snk-grid/snk-grid.d.ts +59 -0
- package/dist/types/components/snk-taskbar/elements/taskbar-elements.d.ts +30 -0
- package/dist/types/components/snk-taskbar/processor/taskbar-processor.d.ts +12 -0
- package/dist/types/components/snk-taskbar/snk-taskbar.d.ts +92 -0
- package/dist/types/components.d.ts +1100 -12
- package/dist/types/lib/http/data-fetcher/DataFetcher.d.ts +7 -6
- package/dist/types/lib/http/data-fetcher/fetchers/dataunit-fetcher.d.ts +3 -0
- package/dist/types/lib/http/data-fetcher/fetchers/filter-bar-config-fetcher.d.ts +6 -0
- package/dist/types/lib/http/data-fetcher/fetchers/form-config-fetcher.d.ts +21 -3
- package/dist/types/lib/http/data-fetcher/fetchers/grid-config-fetcher.d.ts +1 -1
- package/dist/types/lib/http/data-fetcher/fetchers/parameters-fecher.d.ts +7 -7
- package/dist/types/lib/http/data-fetcher/fetchers/resource-fetcher.d.ts +1 -0
- package/dist/types/lib/http/data-fetcher/fetchers/totals-fetcher.d.ts +8 -0
- package/dist/types/lib/index.d.ts +2 -0
- package/dist/types/lib/message/SnkMessageBuilder.d.ts +42 -0
- package/dist/types/lib/message/resources/crud-utils.msg.d.ts +2 -0
- package/dist/types/lib/message/resources/snk-configurator.msg.d.ts +2 -0
- package/dist/types/lib/message/resources/snk-data-unit.msg.d.ts +2 -0
- package/dist/types/lib/message/resources/snk-filter-bar.msg.d.ts +2 -0
- package/dist/types/lib/message/resources/snk-form.msg.d.ts +5 -0
- package/dist/types/lib/message/resources/snk-taskbar.msg.d.ts +2 -0
- package/dist/types/lib/utils/CrudUtils.d.ts +6 -0
- package/dist/types/lib/utils/constants.d.ts +76 -0
- package/dist/types/lib/utils/pesquisa.d.ts +2 -1
- package/dist/types/stencil-public-runtime.d.ts +15 -4
- package/loader/package.json +1 -0
- package/package.json +6 -5
- package/react/components.d.ts +23 -0
- package/react/components.js +23 -0
- package/react/components.js.map +1 -1
- package/dist/sankhyablocks/p-98e8490d.entry.js +0 -69
- package/dist/sankhyablocks/p-edcb9d8e.js +0 -2
|
@@ -5,47 +5,491 @@
|
|
|
5
5
|
* It contains typing information for all components that exist in this project.
|
|
6
6
|
*/
|
|
7
7
|
import { HTMLStencilElement, JSXBase } from "./stencil-public-runtime";
|
|
8
|
+
import { SnkMessageBuilder } from "./lib/message/SnkMessageBuilder";
|
|
8
9
|
import { AutorizationType } from "./lib/http/data-fetcher/fetchers/auth-fetcher";
|
|
9
|
-
import { DataUnit } from "@sankhyalabs/core";
|
|
10
|
-
import { MessageOptions } from "@sankhyalabs/ezui/dist/collection/utils";
|
|
11
|
-
import {
|
|
12
|
-
import { IGridConfig } from "@sankhyalabs/ezui/dist/types/components/ez-grid/controller/EzGridController";
|
|
13
|
-
import {
|
|
10
|
+
import { DataUnit, Filter } from "@sankhyalabs/core";
|
|
11
|
+
import { DialogType, MessageOptions } from "@sankhyalabs/ezui/dist/collection/utils";
|
|
12
|
+
import { IFieldConfig, IFormConfig, IRecordValidator } from "@sankhyalabs/ezui/dist/types/components/ez-form/ez-form";
|
|
13
|
+
import { IGridConfig, IStatusResolver } from "@sankhyalabs/ezui/dist/types/components/ez-grid/controller/EzGridController";
|
|
14
|
+
import { IUserConfig } from "./lib/http/data-fetcher/fetchers/form-config-fetcher";
|
|
15
|
+
import { SnkFilterItemConfig } from "./components/snk-filter-bar/filter-item/snk-filter-item";
|
|
16
|
+
import { IOption, ISearchArgument } from "@sankhyalabs/ezui/dist/types/components/ez-combo-box/ez-combo-box";
|
|
14
17
|
import { SearchCriteria } from "./lib/http/data-fetcher/fetchers/pesquisa-fetcher";
|
|
18
|
+
import { IConfigModal } from "./components/snk-configurator/subcomponents/snk-config-modal/snk-config-modal";
|
|
19
|
+
import { Action, TaskbarManager } from "./components/snk-taskbar/snk-taskbar";
|
|
20
|
+
import { DataState } from "./components/snk-data-unit/snk-data-unit";
|
|
21
|
+
import { SnkFilterItemConfig as SnkFilterItemConfig1 } from "./components/snk-filter-bar/filter-item/snk-filter-item";
|
|
22
|
+
import { ListItem } from "./components/snk-filter-bar/filter-list/snk-filter-list";
|
|
23
|
+
import { ModalItem } from "./components/snk-filter-bar/filter-modal/snk-filter-modal";
|
|
24
|
+
import { ModalAction } from "@sankhyalabs/ezui/dist/collection/components/ez-modal-container";
|
|
25
|
+
import { ITab } from "./components/snk-form/subcomponents/snk-tab-config/snk-tab-config";
|
|
26
|
+
import { Action as Action1, CustomButton } from "./components/snk-taskbar/snk-taskbar";
|
|
15
27
|
export namespace Components {
|
|
16
28
|
interface SnkApplication {
|
|
29
|
+
/**
|
|
30
|
+
* Mostra o diálogo de alerta de acordo com os parâmetros passados.
|
|
31
|
+
*/
|
|
17
32
|
"alert": (title: string, message: string, icon?: string, options?: MessageOptions) => Promise<boolean>;
|
|
33
|
+
"closeModal": () => Promise<void>;
|
|
34
|
+
/**
|
|
35
|
+
* Fecha o popup, liberando o conteúdo.
|
|
36
|
+
*/
|
|
18
37
|
"closePopUp": () => Promise<void>;
|
|
19
|
-
|
|
20
|
-
|
|
38
|
+
/**
|
|
39
|
+
* Usado para salvar as configurações dos blocos de construção.
|
|
40
|
+
*/
|
|
41
|
+
"configName": string;
|
|
42
|
+
/**
|
|
43
|
+
* Exibe um diálogo de confirmação
|
|
44
|
+
*/
|
|
45
|
+
"confirm": (title: string, message: string, icon?: string, dialogType?: DialogType, options?: MessageOptions) => Promise<boolean>;
|
|
46
|
+
/**
|
|
47
|
+
* Cria o DataUnit a partir do nome da entidade. É possível armazená-lo no cache passando o dataUnitName, assim, se mais de uma chamada for feita, o mesmo DataUnit será usado
|
|
48
|
+
*/
|
|
49
|
+
"createDataunit": (entityName: string, dataUnitName?: string) => Promise<DataUnit>;
|
|
50
|
+
/**
|
|
51
|
+
* Mostra o diálogo de erro de acordo com os parâmetros passados.
|
|
52
|
+
*/
|
|
21
53
|
"error": (title: string, message: string, icon?: string, options?: MessageOptions) => Promise<boolean>;
|
|
22
|
-
"
|
|
54
|
+
"executePreparedSearch": (mode: string, argument: string, options: any) => Promise<Array<IOption> | IOption>;
|
|
55
|
+
"executeSearch": (searchArgument: ISearchArgument, fieldName: string, dataUnit: DataUnit) => Promise<Array<IOption> | IOption>;
|
|
56
|
+
/**
|
|
57
|
+
* Busca a configuração padrão de formulário.
|
|
58
|
+
*/
|
|
59
|
+
"fetchDefaultConfig": (name: string) => Promise<IFormConfig>;
|
|
60
|
+
/**
|
|
61
|
+
* Busca a configuração de formulário do usuário.
|
|
62
|
+
*/
|
|
63
|
+
"fetchLegacyConfig": (name: string) => Promise<IFormConfig>;
|
|
64
|
+
/**
|
|
65
|
+
* Busca lista de configurações de formulário do usuário.
|
|
66
|
+
*/
|
|
67
|
+
"fetchUserAvailableConfigs": (name: string) => Promise<Array<IUserConfig>>;
|
|
68
|
+
/**
|
|
69
|
+
* Retorna todos os acessos do usuário logado.
|
|
70
|
+
*/
|
|
23
71
|
"getAllAccess": () => Promise<any>;
|
|
72
|
+
/**
|
|
73
|
+
* Acessa informações de contexto "empurrados" na abertura da tela
|
|
74
|
+
*/
|
|
24
75
|
"getAttributeFromHTMLWrapper": (attribName: string) => Promise<string>;
|
|
76
|
+
/**
|
|
77
|
+
* Retorna o valor de um parâmetro do tipo booleano.
|
|
78
|
+
*/
|
|
25
79
|
"getBooleanParam": (name: string) => Promise<boolean>;
|
|
80
|
+
/**
|
|
81
|
+
* Retorna a configuração de um recurso por service broker Veja também o método "loadConfig"
|
|
82
|
+
*/
|
|
26
83
|
"getConfig": (key: string) => Promise<any>;
|
|
84
|
+
/**
|
|
85
|
+
* Obtem um DataUnit do cache ou cria um caso ainda não tenha sido criado.
|
|
86
|
+
*/
|
|
87
|
+
"getDataUnit": (entityName: string, dataUnitName: string) => Promise<DataUnit>;
|
|
88
|
+
/**
|
|
89
|
+
* Retorna o valor de um parâmetro do tipo data.
|
|
90
|
+
*/
|
|
27
91
|
"getDateParam": (name: string) => Promise<Date>;
|
|
92
|
+
/**
|
|
93
|
+
* Obtém as configurações da barra de filtros
|
|
94
|
+
*/
|
|
95
|
+
"getFilterBarConfig": (name: string) => Promise<Array<SnkFilterItemConfig>>;
|
|
96
|
+
/**
|
|
97
|
+
* Retorna o valor de um parâmetro do tipo Decimal.
|
|
98
|
+
*/
|
|
28
99
|
"getFloatParam": (name: string) => Promise<number>;
|
|
100
|
+
/**
|
|
101
|
+
* Retorna o valor de um parâmetro do tipo Inteiro.
|
|
102
|
+
*/
|
|
29
103
|
"getIntParam": (name: string) => Promise<number>;
|
|
104
|
+
/**
|
|
105
|
+
* Retorna o resourceID da tela em questão.
|
|
106
|
+
*/
|
|
30
107
|
"getResourceID": () => Promise<string>;
|
|
108
|
+
/**
|
|
109
|
+
* Retorna o valor de um parâmetro do tipo string.
|
|
110
|
+
*/
|
|
31
111
|
"getStringParam": (name: string) => Promise<string>;
|
|
112
|
+
/**
|
|
113
|
+
* Retorna o resourceID da tela em questão.
|
|
114
|
+
*/
|
|
115
|
+
"getUserID": () => Promise<string>;
|
|
116
|
+
/**
|
|
117
|
+
* Se o usuário logado tem permissão pra determinada ação.
|
|
118
|
+
*/
|
|
32
119
|
"hasAccess": (access: AutorizationType) => Promise<boolean>;
|
|
120
|
+
/**
|
|
121
|
+
* Mostra uma informação efêmera (de segundo plano).
|
|
122
|
+
*/
|
|
33
123
|
"info": (message: string, options?: MessageOptions) => Promise<void>;
|
|
34
124
|
"isDebugMode": () => Promise<boolean>;
|
|
125
|
+
/**
|
|
126
|
+
* Caso o usuário logado seja o SUP.
|
|
127
|
+
*/
|
|
35
128
|
"isUserSup": () => Promise<boolean>;
|
|
36
|
-
|
|
37
|
-
|
|
129
|
+
/**
|
|
130
|
+
* Busca a configuração de formulário.
|
|
131
|
+
*/
|
|
132
|
+
"loadFormConfig": (name: string) => Promise<IFormConfig>;
|
|
133
|
+
/**
|
|
134
|
+
* Busca a configuração de grade.
|
|
135
|
+
*/
|
|
136
|
+
"loadGridConfig": (name: string) => Promise<IGridConfig>;
|
|
137
|
+
/**
|
|
138
|
+
* Busca os totalizadores da grade.
|
|
139
|
+
*/
|
|
140
|
+
"loadTotals": (name: string, resourceID: string, filters: Array<Filter>) => Promise<Map<string, number>>;
|
|
141
|
+
/**
|
|
142
|
+
* Exibe um diálogo de mensagem comum
|
|
143
|
+
*/
|
|
144
|
+
"message": (title: string, message: string, icon?: string, options?: MessageOptions) => Promise<boolean>;
|
|
145
|
+
/**
|
|
146
|
+
* messagesBuilder é um utilitário responsável por flexibilizar e padronizar o uso de mensagens nos blocos de construção.
|
|
147
|
+
*/
|
|
148
|
+
"messagesBuilder": SnkMessageBuilder;
|
|
149
|
+
/**
|
|
150
|
+
* Abre determinada tela, repassando pkObject
|
|
151
|
+
*/
|
|
38
152
|
"openApp": (resourceId: string, pkObject: Object) => Promise<void>;
|
|
153
|
+
/**
|
|
154
|
+
* Salva a configuração de determinado recurso.
|
|
155
|
+
*/
|
|
39
156
|
"saveConfig": (key: string, data: Object) => Promise<any>;
|
|
157
|
+
/**
|
|
158
|
+
* Salva as configurações da barra de filtros
|
|
159
|
+
*/
|
|
160
|
+
"saveFilterBarConfig": (config: Array<SnkFilterItemConfig>, name: string) => Promise<boolean>;
|
|
161
|
+
/**
|
|
162
|
+
* Salva a configuração de formulário.
|
|
163
|
+
*/
|
|
164
|
+
"saveFormConfig": (config: IFormConfig, name: string) => Promise<boolean>;
|
|
165
|
+
/**
|
|
166
|
+
* Salva a configuração de grade.
|
|
167
|
+
*/
|
|
40
168
|
"saveGridConfig": (config: IGridConfig) => Promise<boolean>;
|
|
41
|
-
"
|
|
169
|
+
"showModal": (content: HTMLElement) => Promise<void>;
|
|
170
|
+
/**
|
|
171
|
+
* Mostra o conteúdo passado em um Popup
|
|
172
|
+
*/
|
|
173
|
+
"showPopUp": (content: HTMLElement, size?: string) => Promise<void>;
|
|
174
|
+
/**
|
|
175
|
+
* Mostra o diálogo de sucesso de acordo com os parâmetros passados.
|
|
176
|
+
*/
|
|
177
|
+
"success": (title: string, message: string, icon?: string, options?: MessageOptions) => Promise<boolean>;
|
|
178
|
+
/**
|
|
179
|
+
* Verifica se a licença do cliente tem determinado opcional (produto)
|
|
180
|
+
*/
|
|
42
181
|
"temOpcional": (opcional: string) => Promise<boolean>;
|
|
43
182
|
}
|
|
183
|
+
interface SnkConfigModal {
|
|
184
|
+
/**
|
|
185
|
+
* Nome usado para guardar/recuperar as configurações do formulário
|
|
186
|
+
*/
|
|
187
|
+
"configName": string;
|
|
188
|
+
/**
|
|
189
|
+
* Define se o modo grid está ativo.
|
|
190
|
+
*/
|
|
191
|
+
"gridMode": boolean;
|
|
192
|
+
}
|
|
193
|
+
interface SnkConfigOptions {
|
|
194
|
+
/**
|
|
195
|
+
* Repositório de dados responsável por controlar a manipulação dos dados
|
|
196
|
+
*/
|
|
197
|
+
"dataUnit": DataUnit;
|
|
198
|
+
/**
|
|
199
|
+
* Armazena as propriedades do campo
|
|
200
|
+
*/
|
|
201
|
+
"fieldConfig": IFieldConfig;
|
|
202
|
+
/**
|
|
203
|
+
* Armazena a chave de opções de configuração
|
|
204
|
+
*/
|
|
205
|
+
"idConfig": string;
|
|
206
|
+
}
|
|
207
|
+
interface SnkConfigurator {
|
|
208
|
+
/**
|
|
209
|
+
* Nome usado para guardar/recuperar as configurações do formulário
|
|
210
|
+
*/
|
|
211
|
+
"configName": string;
|
|
212
|
+
/**
|
|
213
|
+
* Define se o campo está habilitado.
|
|
214
|
+
*/
|
|
215
|
+
"enabled": boolean;
|
|
216
|
+
/**
|
|
217
|
+
* Nome do componente que será vinculado ao `data-configurator-parent` para controlar o modal de configurações.
|
|
218
|
+
*/
|
|
219
|
+
"name": string;
|
|
220
|
+
}
|
|
221
|
+
interface SnkCrud {
|
|
222
|
+
/**
|
|
223
|
+
* Ações a serem colocadas no botão "Mais opções".
|
|
224
|
+
*/
|
|
225
|
+
"actionsList": Array<Action>;
|
|
226
|
+
/**
|
|
227
|
+
* Usado para salvar as configurações dos blocos de construção.
|
|
228
|
+
*/
|
|
229
|
+
"configName": string;
|
|
230
|
+
/**
|
|
231
|
+
* Usado para alternar a visão entre GRID e FORM externamente.
|
|
232
|
+
*/
|
|
233
|
+
"goToView": (mode: string) => Promise<void>;
|
|
234
|
+
/**
|
|
235
|
+
* Validador responsável por checar a integridade das informações do registro
|
|
236
|
+
*/
|
|
237
|
+
"recordsValidator": IRecordValidator;
|
|
238
|
+
/**
|
|
239
|
+
* Configuração do valor da coluna de status. Exemplo: { "RECDESP": { "-1" : "#BD0025", "1" : "#157A00" } }
|
|
240
|
+
*/
|
|
241
|
+
"statusResolver": IStatusResolver;
|
|
242
|
+
/**
|
|
243
|
+
* Gerenciador das barras de tarefas. É possível determinar botões específicos ou mesmo gerenciar o estado dos botões.
|
|
244
|
+
*/
|
|
245
|
+
"taskbarManager": TaskbarManager;
|
|
246
|
+
}
|
|
247
|
+
interface SnkDataUnit {
|
|
248
|
+
/**
|
|
249
|
+
* Executado após a ação de salvar
|
|
250
|
+
*/
|
|
251
|
+
"afterSave": (dataUnit: DataUnit) => void;
|
|
252
|
+
/**
|
|
253
|
+
* Executado imediatamente antes da ação de salvar as alterações. Útil no caso de validações por exemplo. Caso retorne "false" (ou a promessa se resolva como false), cancela a ação.
|
|
254
|
+
*/
|
|
255
|
+
"beforeSave": (dataUnit: DataUnit) => boolean | Promise<boolean>;
|
|
256
|
+
/**
|
|
257
|
+
* O estato atual dos dados, isto é se há alteração, insersão, as linhas selecionadas, etc.
|
|
258
|
+
*/
|
|
259
|
+
"dataState": DataState;
|
|
260
|
+
/**
|
|
261
|
+
* Uma vez instanciado, pode-se obter o dataUnit por esta propriedade
|
|
262
|
+
*/
|
|
263
|
+
"dataUnit": DataUnit;
|
|
264
|
+
/**
|
|
265
|
+
* Este atributo é usado para criar o dataUnit uma única vez. Se omitido será usado o próprio nome da entidade.
|
|
266
|
+
*/
|
|
267
|
+
"dataUnitName": string;
|
|
268
|
+
/**
|
|
269
|
+
* Determina qual a entidade representa os dados em questão.
|
|
270
|
+
*/
|
|
271
|
+
"entityName": string;
|
|
272
|
+
/**
|
|
273
|
+
* Pode-se obter o dataUnit através desse método. Outra forma, é ouvir o evento de
|
|
274
|
+
* @returns dataUnit
|
|
275
|
+
*/
|
|
276
|
+
"getDataUnit": () => Promise<DataUnit>;
|
|
277
|
+
/**
|
|
278
|
+
* Determina quantas linhas são retornadas por página
|
|
279
|
+
*/
|
|
280
|
+
"pageSize": number;
|
|
281
|
+
}
|
|
282
|
+
interface SnkFieldConfig {
|
|
283
|
+
/**
|
|
284
|
+
* Armazena as propriedades do campo
|
|
285
|
+
*/
|
|
286
|
+
"fieldConfig": IFieldConfig;
|
|
287
|
+
/**
|
|
288
|
+
* Define se o popover de configuração está ativo.
|
|
289
|
+
*/
|
|
290
|
+
"isConfigActive": Boolean;
|
|
291
|
+
/**
|
|
292
|
+
* Define se o componente está em modo de inserção
|
|
293
|
+
*/
|
|
294
|
+
"modeInsertion": boolean;
|
|
295
|
+
}
|
|
296
|
+
interface SnkFilterBar {
|
|
297
|
+
/**
|
|
298
|
+
* Eventualmente poderemos ter mais de uma barra de filtros. Essa propriedade serve para separar a configuração de cada uma.
|
|
299
|
+
*/
|
|
300
|
+
"configName": string;
|
|
301
|
+
/**
|
|
302
|
+
* Recebe o DataUnit do ambiente. Se não for informado, procura pela referência do SnkDataUnit. Necessário para se registrar como provedor de filtros.
|
|
303
|
+
*/
|
|
304
|
+
"dataUnit": DataUnit;
|
|
305
|
+
/**
|
|
306
|
+
* Lista de todos os filtros disponíveis ao usuário.
|
|
307
|
+
*/
|
|
308
|
+
"filterConfig": Array<SnkFilterItemConfig>;
|
|
309
|
+
}
|
|
310
|
+
interface SnkFilterBinarySelect {
|
|
311
|
+
"config": SnkFilterItemConfig;
|
|
312
|
+
"show": () => Promise<void>;
|
|
313
|
+
"value": any;
|
|
314
|
+
}
|
|
315
|
+
interface SnkFilterDetail {
|
|
316
|
+
"config": SnkFilterItemConfig;
|
|
317
|
+
"getMessage": (key: string, props?: any) => string;
|
|
318
|
+
"show": () => Promise<void>;
|
|
319
|
+
}
|
|
320
|
+
interface SnkFilterItem {
|
|
321
|
+
"config": SnkFilterItemConfig;
|
|
322
|
+
"getMessage": (key: string, props?: any) => string;
|
|
323
|
+
"hideDetail": () => Promise<void>;
|
|
324
|
+
"showUp": (open?: boolean) => Promise<void>;
|
|
325
|
+
}
|
|
326
|
+
interface SnkFilterList {
|
|
327
|
+
"buttonClass": string;
|
|
328
|
+
"emptyText": string;
|
|
329
|
+
"findFilterText": string;
|
|
330
|
+
"getMessage": (key: string, props?: any) => string;
|
|
331
|
+
"hideDetail": () => Promise<void>;
|
|
332
|
+
"iconName": string;
|
|
333
|
+
"items": Array<ListItem>;
|
|
334
|
+
"label": string;
|
|
335
|
+
}
|
|
336
|
+
interface SnkFilterModal {
|
|
337
|
+
"cancelButtonLabel": string;
|
|
338
|
+
"getMessage": (key: string, props?: any) => string;
|
|
339
|
+
"infoText": string;
|
|
340
|
+
"items": Array<ModalItem>;
|
|
341
|
+
"modalSubTitle": string;
|
|
342
|
+
"modalTitle": string;
|
|
343
|
+
"okButtonLabel": string;
|
|
344
|
+
"processModalAction": (action: ModalAction) => void;
|
|
345
|
+
"useSearch": boolean;
|
|
346
|
+
}
|
|
347
|
+
interface SnkFilterMultiSelect {
|
|
348
|
+
"config": SnkFilterItemConfig;
|
|
349
|
+
"show": () => Promise<void>;
|
|
350
|
+
"value": any;
|
|
351
|
+
}
|
|
352
|
+
interface SnkFilterNumber {
|
|
353
|
+
"config": SnkFilterItemConfig;
|
|
354
|
+
"show": () => Promise<void>;
|
|
355
|
+
"value": number;
|
|
356
|
+
}
|
|
357
|
+
interface SnkFilterPeriod {
|
|
358
|
+
"config": SnkFilterItemConfig;
|
|
359
|
+
"show": () => Promise<void>;
|
|
360
|
+
"value": any;
|
|
361
|
+
}
|
|
362
|
+
interface SnkFilterPersonalized {
|
|
363
|
+
"config": SnkFilterItemConfig;
|
|
364
|
+
"fix": ()=>void;
|
|
365
|
+
"show": () => Promise<void>;
|
|
366
|
+
"unfix": ()=>void;
|
|
367
|
+
"value": Array<IOption|boolean|string|number|Date>;
|
|
368
|
+
}
|
|
369
|
+
interface SnkFilterSearch {
|
|
370
|
+
"config": SnkFilterItemConfig;
|
|
371
|
+
"show": () => Promise<void>;
|
|
372
|
+
"value": IOption;
|
|
373
|
+
}
|
|
374
|
+
interface SnkFilterText {
|
|
375
|
+
"config": SnkFilterItemConfig;
|
|
376
|
+
"value": string;
|
|
377
|
+
}
|
|
378
|
+
interface SnkForm {
|
|
379
|
+
/**
|
|
380
|
+
* Lista de ações que devem ser usadas no botão "Mais opções"
|
|
381
|
+
*/
|
|
382
|
+
"actionsList": Array<Action>;
|
|
383
|
+
/**
|
|
384
|
+
* Nome usado para guardar/recuperar as configurações do formulário
|
|
385
|
+
*/
|
|
386
|
+
"configName": string;
|
|
387
|
+
/**
|
|
388
|
+
* Validador responsável por checar a integridade das informações do registro
|
|
389
|
+
*/
|
|
390
|
+
"recordsValidator": IRecordValidator;
|
|
391
|
+
/**
|
|
392
|
+
* Método responsável por setar as configurações do form.
|
|
393
|
+
*/
|
|
394
|
+
"setConfig": (config: IFormConfig) => Promise<void>;
|
|
395
|
+
/**
|
|
396
|
+
* Método responsável em abrir ou fechar o modal de configurações do form.
|
|
397
|
+
*/
|
|
398
|
+
"setShowFormConfig": (value: boolean) => Promise<void>;
|
|
399
|
+
/**
|
|
400
|
+
* Gerenciador das barras de tarefas. É possível determinar botões específicos ou mesmo gerenciar o estado dos botões.
|
|
401
|
+
*/
|
|
402
|
+
"taskbarManager": TaskbarManager;
|
|
403
|
+
}
|
|
404
|
+
interface SnkFormConfig {
|
|
405
|
+
/**
|
|
406
|
+
* Repositório de dados, controla a manipulação dos dados
|
|
407
|
+
*/
|
|
408
|
+
"dataUnit": DataUnit;
|
|
409
|
+
/**
|
|
410
|
+
* Campos de configuração de formulário.
|
|
411
|
+
*/
|
|
412
|
+
"formConfig": IFormConfig;
|
|
413
|
+
/**
|
|
414
|
+
* Representa o elemento pai do componente.
|
|
415
|
+
*/
|
|
416
|
+
"parentForm": HTMLSnkFormElement;
|
|
417
|
+
}
|
|
418
|
+
interface SnkGrid {
|
|
419
|
+
/**
|
|
420
|
+
* Lista de ações que devem ser usadas no botão "Mais opções"
|
|
421
|
+
*/
|
|
422
|
+
"actionsList": Array<Action>;
|
|
423
|
+
/**
|
|
424
|
+
* Nome usado para salvar/recuperar a configuração
|
|
425
|
+
*/
|
|
426
|
+
"configName": string;
|
|
427
|
+
/**
|
|
428
|
+
* Método responsável por setar as configurações da grade.
|
|
429
|
+
*/
|
|
430
|
+
"setConfig": (config: IGridConfig) => Promise<void>;
|
|
431
|
+
/**
|
|
432
|
+
* Método responsável em abrir ou fechar o modal de configurações da grade.
|
|
433
|
+
*/
|
|
434
|
+
"setShowGridConfig": (value: boolean) => Promise<void>;
|
|
435
|
+
/**
|
|
436
|
+
* Configuração do valor da coluna de status. Exemplo: { "RECDESP": { "-1" : "#BD0025", "1" : "#157A00" } }
|
|
437
|
+
*/
|
|
438
|
+
"statusResolver": IStatusResolver;
|
|
439
|
+
/**
|
|
440
|
+
* Gerenciador das barras de tarefas. É possível determinar botões específicos ou mesmo gerenciar o estado dos botões.
|
|
441
|
+
*/
|
|
442
|
+
"taskbarManager": TaskbarManager;
|
|
443
|
+
}
|
|
44
444
|
interface SnkPesquisa {
|
|
45
445
|
"argument": string;
|
|
46
446
|
"searchLoader": Function;
|
|
47
447
|
"selectItem": Function;
|
|
48
448
|
}
|
|
449
|
+
interface SnkTabConfig {
|
|
450
|
+
/**
|
|
451
|
+
* Define o index da aba selecionada.
|
|
452
|
+
*/
|
|
453
|
+
"selectedIndex": number;
|
|
454
|
+
/**
|
|
455
|
+
* Define a aba selecionada.
|
|
456
|
+
*/
|
|
457
|
+
"selectedTab": string;
|
|
458
|
+
/**
|
|
459
|
+
* Define o nome das abas do componente, separadas por vírgulas ",".
|
|
460
|
+
*/
|
|
461
|
+
"tabs": string;
|
|
462
|
+
}
|
|
463
|
+
interface SnkTaskbar {
|
|
464
|
+
/**
|
|
465
|
+
* Lista de ações que devem ser usadas no botão "Mais opções"
|
|
466
|
+
*/
|
|
467
|
+
"actionsList": Array<Action>;
|
|
468
|
+
/**
|
|
469
|
+
* Lista separada por virgula, contendo todos os elementos a serem criados
|
|
470
|
+
*/
|
|
471
|
+
"buttons": string;
|
|
472
|
+
/**
|
|
473
|
+
* Nome usado para guardar/recuperar as configurações do formulário
|
|
474
|
+
*/
|
|
475
|
+
"configName": string;
|
|
476
|
+
/**
|
|
477
|
+
* Mapa com definição de botões personalizados. A chave do mapa deve ser passada na lista "buttons" no lugar onde o botão irá aparecer.
|
|
478
|
+
*/
|
|
479
|
+
"customButtons": Map<string, CustomButton>;
|
|
480
|
+
/**
|
|
481
|
+
* Instância do DataUnit
|
|
482
|
+
*/
|
|
483
|
+
"dataUnit": DataUnit;
|
|
484
|
+
/**
|
|
485
|
+
* Array contendo todos os botões a serem desabilitados
|
|
486
|
+
*/
|
|
487
|
+
"disabledButtons": Array<string>;
|
|
488
|
+
/**
|
|
489
|
+
* Qual botão deve ter aparência primária
|
|
490
|
+
*/
|
|
491
|
+
"primaryButton": string;
|
|
492
|
+
}
|
|
49
493
|
interface TestePesquisa {
|
|
50
494
|
}
|
|
51
495
|
}
|
|
@@ -53,6 +497,62 @@ export interface SnkApplicationCustomEvent<T> extends CustomEvent<T> {
|
|
|
53
497
|
detail: T;
|
|
54
498
|
target: HTMLSnkApplicationElement;
|
|
55
499
|
}
|
|
500
|
+
export interface SnkConfigModalCustomEvent<T> extends CustomEvent<T> {
|
|
501
|
+
detail: T;
|
|
502
|
+
target: HTMLSnkConfigModalElement;
|
|
503
|
+
}
|
|
504
|
+
export interface SnkConfigOptionsCustomEvent<T> extends CustomEvent<T> {
|
|
505
|
+
detail: T;
|
|
506
|
+
target: HTMLSnkConfigOptionsElement;
|
|
507
|
+
}
|
|
508
|
+
export interface SnkConfiguratorCustomEvent<T> extends CustomEvent<T> {
|
|
509
|
+
detail: T;
|
|
510
|
+
target: HTMLSnkConfiguratorElement;
|
|
511
|
+
}
|
|
512
|
+
export interface SnkCrudCustomEvent<T> extends CustomEvent<T> {
|
|
513
|
+
detail: T;
|
|
514
|
+
target: HTMLSnkCrudElement;
|
|
515
|
+
}
|
|
516
|
+
export interface SnkDataUnitCustomEvent<T> extends CustomEvent<T> {
|
|
517
|
+
detail: T;
|
|
518
|
+
target: HTMLSnkDataUnitElement;
|
|
519
|
+
}
|
|
520
|
+
export interface SnkFieldConfigCustomEvent<T> extends CustomEvent<T> {
|
|
521
|
+
detail: T;
|
|
522
|
+
target: HTMLSnkFieldConfigElement;
|
|
523
|
+
}
|
|
524
|
+
export interface SnkFilterDetailCustomEvent<T> extends CustomEvent<T> {
|
|
525
|
+
detail: T;
|
|
526
|
+
target: HTMLSnkFilterDetailElement;
|
|
527
|
+
}
|
|
528
|
+
export interface SnkFilterItemCustomEvent<T> extends CustomEvent<T> {
|
|
529
|
+
detail: T;
|
|
530
|
+
target: HTMLSnkFilterItemElement;
|
|
531
|
+
}
|
|
532
|
+
export interface SnkFilterListCustomEvent<T> extends CustomEvent<T> {
|
|
533
|
+
detail: T;
|
|
534
|
+
target: HTMLSnkFilterListElement;
|
|
535
|
+
}
|
|
536
|
+
export interface SnkFormCustomEvent<T> extends CustomEvent<T> {
|
|
537
|
+
detail: T;
|
|
538
|
+
target: HTMLSnkFormElement;
|
|
539
|
+
}
|
|
540
|
+
export interface SnkFormConfigCustomEvent<T> extends CustomEvent<T> {
|
|
541
|
+
detail: T;
|
|
542
|
+
target: HTMLSnkFormConfigElement;
|
|
543
|
+
}
|
|
544
|
+
export interface SnkGridCustomEvent<T> extends CustomEvent<T> {
|
|
545
|
+
detail: T;
|
|
546
|
+
target: HTMLSnkGridElement;
|
|
547
|
+
}
|
|
548
|
+
export interface SnkTabConfigCustomEvent<T> extends CustomEvent<T> {
|
|
549
|
+
detail: T;
|
|
550
|
+
target: HTMLSnkTabConfigElement;
|
|
551
|
+
}
|
|
552
|
+
export interface SnkTaskbarCustomEvent<T> extends CustomEvent<T> {
|
|
553
|
+
detail: T;
|
|
554
|
+
target: HTMLSnkTaskbarElement;
|
|
555
|
+
}
|
|
56
556
|
declare global {
|
|
57
557
|
interface HTMLSnkApplicationElement extends Components.SnkApplication, HTMLStencilElement {
|
|
58
558
|
}
|
|
@@ -60,12 +560,150 @@ declare global {
|
|
|
60
560
|
prototype: HTMLSnkApplicationElement;
|
|
61
561
|
new (): HTMLSnkApplicationElement;
|
|
62
562
|
};
|
|
563
|
+
interface HTMLSnkConfigModalElement extends Components.SnkConfigModal, HTMLStencilElement {
|
|
564
|
+
}
|
|
565
|
+
var HTMLSnkConfigModalElement: {
|
|
566
|
+
prototype: HTMLSnkConfigModalElement;
|
|
567
|
+
new (): HTMLSnkConfigModalElement;
|
|
568
|
+
};
|
|
569
|
+
interface HTMLSnkConfigOptionsElement extends Components.SnkConfigOptions, HTMLStencilElement {
|
|
570
|
+
}
|
|
571
|
+
var HTMLSnkConfigOptionsElement: {
|
|
572
|
+
prototype: HTMLSnkConfigOptionsElement;
|
|
573
|
+
new (): HTMLSnkConfigOptionsElement;
|
|
574
|
+
};
|
|
575
|
+
interface HTMLSnkConfiguratorElement extends Components.SnkConfigurator, HTMLStencilElement {
|
|
576
|
+
}
|
|
577
|
+
var HTMLSnkConfiguratorElement: {
|
|
578
|
+
prototype: HTMLSnkConfiguratorElement;
|
|
579
|
+
new (): HTMLSnkConfiguratorElement;
|
|
580
|
+
};
|
|
581
|
+
interface HTMLSnkCrudElement extends Components.SnkCrud, HTMLStencilElement {
|
|
582
|
+
}
|
|
583
|
+
var HTMLSnkCrudElement: {
|
|
584
|
+
prototype: HTMLSnkCrudElement;
|
|
585
|
+
new (): HTMLSnkCrudElement;
|
|
586
|
+
};
|
|
587
|
+
interface HTMLSnkDataUnitElement extends Components.SnkDataUnit, HTMLStencilElement {
|
|
588
|
+
}
|
|
589
|
+
var HTMLSnkDataUnitElement: {
|
|
590
|
+
prototype: HTMLSnkDataUnitElement;
|
|
591
|
+
new (): HTMLSnkDataUnitElement;
|
|
592
|
+
};
|
|
593
|
+
interface HTMLSnkFieldConfigElement extends Components.SnkFieldConfig, HTMLStencilElement {
|
|
594
|
+
}
|
|
595
|
+
var HTMLSnkFieldConfigElement: {
|
|
596
|
+
prototype: HTMLSnkFieldConfigElement;
|
|
597
|
+
new (): HTMLSnkFieldConfigElement;
|
|
598
|
+
};
|
|
599
|
+
interface HTMLSnkFilterBarElement extends Components.SnkFilterBar, HTMLStencilElement {
|
|
600
|
+
}
|
|
601
|
+
var HTMLSnkFilterBarElement: {
|
|
602
|
+
prototype: HTMLSnkFilterBarElement;
|
|
603
|
+
new (): HTMLSnkFilterBarElement;
|
|
604
|
+
};
|
|
605
|
+
interface HTMLSnkFilterBinarySelectElement extends Components.SnkFilterBinarySelect, HTMLStencilElement {
|
|
606
|
+
}
|
|
607
|
+
var HTMLSnkFilterBinarySelectElement: {
|
|
608
|
+
prototype: HTMLSnkFilterBinarySelectElement;
|
|
609
|
+
new (): HTMLSnkFilterBinarySelectElement;
|
|
610
|
+
};
|
|
611
|
+
interface HTMLSnkFilterDetailElement extends Components.SnkFilterDetail, HTMLStencilElement {
|
|
612
|
+
}
|
|
613
|
+
var HTMLSnkFilterDetailElement: {
|
|
614
|
+
prototype: HTMLSnkFilterDetailElement;
|
|
615
|
+
new (): HTMLSnkFilterDetailElement;
|
|
616
|
+
};
|
|
617
|
+
interface HTMLSnkFilterItemElement extends Components.SnkFilterItem, HTMLStencilElement {
|
|
618
|
+
}
|
|
619
|
+
var HTMLSnkFilterItemElement: {
|
|
620
|
+
prototype: HTMLSnkFilterItemElement;
|
|
621
|
+
new (): HTMLSnkFilterItemElement;
|
|
622
|
+
};
|
|
623
|
+
interface HTMLSnkFilterListElement extends Components.SnkFilterList, HTMLStencilElement {
|
|
624
|
+
}
|
|
625
|
+
var HTMLSnkFilterListElement: {
|
|
626
|
+
prototype: HTMLSnkFilterListElement;
|
|
627
|
+
new (): HTMLSnkFilterListElement;
|
|
628
|
+
};
|
|
629
|
+
interface HTMLSnkFilterModalElement extends Components.SnkFilterModal, HTMLStencilElement {
|
|
630
|
+
}
|
|
631
|
+
var HTMLSnkFilterModalElement: {
|
|
632
|
+
prototype: HTMLSnkFilterModalElement;
|
|
633
|
+
new (): HTMLSnkFilterModalElement;
|
|
634
|
+
};
|
|
635
|
+
interface HTMLSnkFilterMultiSelectElement extends Components.SnkFilterMultiSelect, HTMLStencilElement {
|
|
636
|
+
}
|
|
637
|
+
var HTMLSnkFilterMultiSelectElement: {
|
|
638
|
+
prototype: HTMLSnkFilterMultiSelectElement;
|
|
639
|
+
new (): HTMLSnkFilterMultiSelectElement;
|
|
640
|
+
};
|
|
641
|
+
interface HTMLSnkFilterNumberElement extends Components.SnkFilterNumber, HTMLStencilElement {
|
|
642
|
+
}
|
|
643
|
+
var HTMLSnkFilterNumberElement: {
|
|
644
|
+
prototype: HTMLSnkFilterNumberElement;
|
|
645
|
+
new (): HTMLSnkFilterNumberElement;
|
|
646
|
+
};
|
|
647
|
+
interface HTMLSnkFilterPeriodElement extends Components.SnkFilterPeriod, HTMLStencilElement {
|
|
648
|
+
}
|
|
649
|
+
var HTMLSnkFilterPeriodElement: {
|
|
650
|
+
prototype: HTMLSnkFilterPeriodElement;
|
|
651
|
+
new (): HTMLSnkFilterPeriodElement;
|
|
652
|
+
};
|
|
653
|
+
interface HTMLSnkFilterPersonalizedElement extends Components.SnkFilterPersonalized, HTMLStencilElement {
|
|
654
|
+
}
|
|
655
|
+
var HTMLSnkFilterPersonalizedElement: {
|
|
656
|
+
prototype: HTMLSnkFilterPersonalizedElement;
|
|
657
|
+
new (): HTMLSnkFilterPersonalizedElement;
|
|
658
|
+
};
|
|
659
|
+
interface HTMLSnkFilterSearchElement extends Components.SnkFilterSearch, HTMLStencilElement {
|
|
660
|
+
}
|
|
661
|
+
var HTMLSnkFilterSearchElement: {
|
|
662
|
+
prototype: HTMLSnkFilterSearchElement;
|
|
663
|
+
new (): HTMLSnkFilterSearchElement;
|
|
664
|
+
};
|
|
665
|
+
interface HTMLSnkFilterTextElement extends Components.SnkFilterText, HTMLStencilElement {
|
|
666
|
+
}
|
|
667
|
+
var HTMLSnkFilterTextElement: {
|
|
668
|
+
prototype: HTMLSnkFilterTextElement;
|
|
669
|
+
new (): HTMLSnkFilterTextElement;
|
|
670
|
+
};
|
|
671
|
+
interface HTMLSnkFormElement extends Components.SnkForm, HTMLStencilElement {
|
|
672
|
+
}
|
|
673
|
+
var HTMLSnkFormElement: {
|
|
674
|
+
prototype: HTMLSnkFormElement;
|
|
675
|
+
new (): HTMLSnkFormElement;
|
|
676
|
+
};
|
|
677
|
+
interface HTMLSnkFormConfigElement extends Components.SnkFormConfig, HTMLStencilElement {
|
|
678
|
+
}
|
|
679
|
+
var HTMLSnkFormConfigElement: {
|
|
680
|
+
prototype: HTMLSnkFormConfigElement;
|
|
681
|
+
new (): HTMLSnkFormConfigElement;
|
|
682
|
+
};
|
|
683
|
+
interface HTMLSnkGridElement extends Components.SnkGrid, HTMLStencilElement {
|
|
684
|
+
}
|
|
685
|
+
var HTMLSnkGridElement: {
|
|
686
|
+
prototype: HTMLSnkGridElement;
|
|
687
|
+
new (): HTMLSnkGridElement;
|
|
688
|
+
};
|
|
63
689
|
interface HTMLSnkPesquisaElement extends Components.SnkPesquisa, HTMLStencilElement {
|
|
64
690
|
}
|
|
65
691
|
var HTMLSnkPesquisaElement: {
|
|
66
692
|
prototype: HTMLSnkPesquisaElement;
|
|
67
693
|
new (): HTMLSnkPesquisaElement;
|
|
68
694
|
};
|
|
695
|
+
interface HTMLSnkTabConfigElement extends Components.SnkTabConfig, HTMLStencilElement {
|
|
696
|
+
}
|
|
697
|
+
var HTMLSnkTabConfigElement: {
|
|
698
|
+
prototype: HTMLSnkTabConfigElement;
|
|
699
|
+
new (): HTMLSnkTabConfigElement;
|
|
700
|
+
};
|
|
701
|
+
interface HTMLSnkTaskbarElement extends Components.SnkTaskbar, HTMLStencilElement {
|
|
702
|
+
}
|
|
703
|
+
var HTMLSnkTaskbarElement: {
|
|
704
|
+
prototype: HTMLSnkTaskbarElement;
|
|
705
|
+
new (): HTMLSnkTaskbarElement;
|
|
706
|
+
};
|
|
69
707
|
interface HTMLTestePesquisaElement extends Components.TestePesquisa, HTMLStencilElement {
|
|
70
708
|
}
|
|
71
709
|
var HTMLTestePesquisaElement: {
|
|
@@ -74,31 +712,458 @@ declare global {
|
|
|
74
712
|
};
|
|
75
713
|
interface HTMLElementTagNameMap {
|
|
76
714
|
"snk-application": HTMLSnkApplicationElement;
|
|
715
|
+
"snk-config-modal": HTMLSnkConfigModalElement;
|
|
716
|
+
"snk-config-options": HTMLSnkConfigOptionsElement;
|
|
717
|
+
"snk-configurator": HTMLSnkConfiguratorElement;
|
|
718
|
+
"snk-crud": HTMLSnkCrudElement;
|
|
719
|
+
"snk-data-unit": HTMLSnkDataUnitElement;
|
|
720
|
+
"snk-field-config": HTMLSnkFieldConfigElement;
|
|
721
|
+
"snk-filter-bar": HTMLSnkFilterBarElement;
|
|
722
|
+
"snk-filter-binary-select": HTMLSnkFilterBinarySelectElement;
|
|
723
|
+
"snk-filter-detail": HTMLSnkFilterDetailElement;
|
|
724
|
+
"snk-filter-item": HTMLSnkFilterItemElement;
|
|
725
|
+
"snk-filter-list": HTMLSnkFilterListElement;
|
|
726
|
+
"snk-filter-modal": HTMLSnkFilterModalElement;
|
|
727
|
+
"snk-filter-multi-select": HTMLSnkFilterMultiSelectElement;
|
|
728
|
+
"snk-filter-number": HTMLSnkFilterNumberElement;
|
|
729
|
+
"snk-filter-period": HTMLSnkFilterPeriodElement;
|
|
730
|
+
"snk-filter-personalized": HTMLSnkFilterPersonalizedElement;
|
|
731
|
+
"snk-filter-search": HTMLSnkFilterSearchElement;
|
|
732
|
+
"snk-filter-text": HTMLSnkFilterTextElement;
|
|
733
|
+
"snk-form": HTMLSnkFormElement;
|
|
734
|
+
"snk-form-config": HTMLSnkFormConfigElement;
|
|
735
|
+
"snk-grid": HTMLSnkGridElement;
|
|
77
736
|
"snk-pesquisa": HTMLSnkPesquisaElement;
|
|
737
|
+
"snk-tab-config": HTMLSnkTabConfigElement;
|
|
738
|
+
"snk-taskbar": HTMLSnkTaskbarElement;
|
|
78
739
|
"teste-pesquisa": HTMLTestePesquisaElement;
|
|
79
740
|
}
|
|
80
741
|
}
|
|
81
742
|
declare namespace LocalJSX {
|
|
82
743
|
interface SnkApplication {
|
|
744
|
+
/**
|
|
745
|
+
* Usado para salvar as configurações dos blocos de construção.
|
|
746
|
+
*/
|
|
747
|
+
"configName"?: string;
|
|
748
|
+
/**
|
|
749
|
+
* messagesBuilder é um utilitário responsável por flexibilizar e padronizar o uso de mensagens nos blocos de construção.
|
|
750
|
+
*/
|
|
751
|
+
"messagesBuilder"?: SnkMessageBuilder;
|
|
83
752
|
/**
|
|
84
753
|
* Evento disparado quando a aplicação for carregada.
|
|
85
754
|
*/
|
|
86
755
|
"onApplicationLoaded"?: (event: SnkApplicationCustomEvent<boolean>) => void;
|
|
87
756
|
/**
|
|
88
|
-
* Evento
|
|
757
|
+
* Evento disparado ao iniciar a carga do componente
|
|
89
758
|
*/
|
|
90
759
|
"onApplicationLoading"?: (event: SnkApplicationCustomEvent<boolean>) => void;
|
|
91
760
|
}
|
|
761
|
+
interface SnkConfigModal {
|
|
762
|
+
/**
|
|
763
|
+
* Nome usado para guardar/recuperar as configurações do formulário
|
|
764
|
+
*/
|
|
765
|
+
"configName"?: string;
|
|
766
|
+
/**
|
|
767
|
+
* Define se o modo grid está ativo.
|
|
768
|
+
*/
|
|
769
|
+
"gridMode"?: boolean;
|
|
770
|
+
/**
|
|
771
|
+
* Evento disparado quando o modal é fechado.
|
|
772
|
+
*/
|
|
773
|
+
"onCancelConfig"?: (event: SnkConfigModalCustomEvent<void>) => void;
|
|
774
|
+
/**
|
|
775
|
+
* Evento disparado quando há alteração nas configurações.
|
|
776
|
+
*/
|
|
777
|
+
"onChangeConfig"?: (event: SnkConfigModalCustomEvent<IConfigModal>) => void;
|
|
778
|
+
}
|
|
779
|
+
interface SnkConfigOptions {
|
|
780
|
+
/**
|
|
781
|
+
* Repositório de dados responsável por controlar a manipulação dos dados
|
|
782
|
+
*/
|
|
783
|
+
"dataUnit"?: DataUnit;
|
|
784
|
+
/**
|
|
785
|
+
* Armazena as propriedades do campo
|
|
786
|
+
*/
|
|
787
|
+
"fieldConfig"?: IFieldConfig;
|
|
788
|
+
/**
|
|
789
|
+
* Armazena a chave de opções de configuração
|
|
790
|
+
*/
|
|
791
|
+
"idConfig"?: string;
|
|
792
|
+
/**
|
|
793
|
+
* Evento disparado ao realizar alguma alteração nos campos
|
|
794
|
+
*/
|
|
795
|
+
"onConfigOptionsChanged"?: (event: SnkConfigOptionsCustomEvent<any>) => void;
|
|
796
|
+
}
|
|
797
|
+
interface SnkConfigurator {
|
|
798
|
+
/**
|
|
799
|
+
* Nome usado para guardar/recuperar as configurações do formulário
|
|
800
|
+
*/
|
|
801
|
+
"configName"?: string;
|
|
802
|
+
/**
|
|
803
|
+
* Define se o campo está habilitado.
|
|
804
|
+
*/
|
|
805
|
+
"enabled"?: boolean;
|
|
806
|
+
/**
|
|
807
|
+
* Nome do componente que será vinculado ao `data-configurator-parent` para controlar o modal de configurações.
|
|
808
|
+
*/
|
|
809
|
+
"name"?: string;
|
|
810
|
+
/**
|
|
811
|
+
* Evento disparado quando há alteração no modo de visualização.
|
|
812
|
+
*/
|
|
813
|
+
"onChangeViewMode"?: (event: SnkConfiguratorCustomEvent<string>) => void;
|
|
814
|
+
}
|
|
815
|
+
interface SnkCrud {
|
|
816
|
+
/**
|
|
817
|
+
* Ações a serem colocadas no botão "Mais opções".
|
|
818
|
+
*/
|
|
819
|
+
"actionsList"?: Array<Action>;
|
|
820
|
+
/**
|
|
821
|
+
* Usado para salvar as configurações dos blocos de construção.
|
|
822
|
+
*/
|
|
823
|
+
"configName"?: string;
|
|
824
|
+
/**
|
|
825
|
+
* Emitido pela taskbar sempre que houver click de botão ou ação
|
|
826
|
+
*/
|
|
827
|
+
"onActionClick"?: (event: SnkCrudCustomEvent<string>) => void;
|
|
828
|
+
/**
|
|
829
|
+
* Validador responsável por checar a integridade das informações do registro
|
|
830
|
+
*/
|
|
831
|
+
"recordsValidator"?: IRecordValidator;
|
|
832
|
+
/**
|
|
833
|
+
* Configuração do valor da coluna de status. Exemplo: { "RECDESP": { "-1" : "#BD0025", "1" : "#157A00" } }
|
|
834
|
+
*/
|
|
835
|
+
"statusResolver"?: IStatusResolver;
|
|
836
|
+
/**
|
|
837
|
+
* Gerenciador das barras de tarefas. É possível determinar botões específicos ou mesmo gerenciar o estado dos botões.
|
|
838
|
+
*/
|
|
839
|
+
"taskbarManager"?: TaskbarManager;
|
|
840
|
+
}
|
|
841
|
+
interface SnkDataUnit {
|
|
842
|
+
/**
|
|
843
|
+
* Executado após a ação de salvar
|
|
844
|
+
*/
|
|
845
|
+
"afterSave"?: (dataUnit: DataUnit) => void;
|
|
846
|
+
/**
|
|
847
|
+
* Executado imediatamente antes da ação de salvar as alterações. Útil no caso de validações por exemplo. Caso retorne "false" (ou a promessa se resolva como false), cancela a ação.
|
|
848
|
+
*/
|
|
849
|
+
"beforeSave"?: (dataUnit: DataUnit) => boolean | Promise<boolean>;
|
|
850
|
+
/**
|
|
851
|
+
* O estato atual dos dados, isto é se há alteração, insersão, as linhas selecionadas, etc.
|
|
852
|
+
*/
|
|
853
|
+
"dataState"?: DataState;
|
|
854
|
+
/**
|
|
855
|
+
* Uma vez instanciado, pode-se obter o dataUnit por esta propriedade
|
|
856
|
+
*/
|
|
857
|
+
"dataUnit"?: DataUnit;
|
|
858
|
+
/**
|
|
859
|
+
* Este atributo é usado para criar o dataUnit uma única vez. Se omitido será usado o próprio nome da entidade.
|
|
860
|
+
*/
|
|
861
|
+
"dataUnitName"?: string;
|
|
862
|
+
/**
|
|
863
|
+
* Determina qual a entidade representa os dados em questão.
|
|
864
|
+
*/
|
|
865
|
+
"entityName"?: string;
|
|
866
|
+
/**
|
|
867
|
+
* Disparado quando se cancela uma insersão/cópia
|
|
868
|
+
*/
|
|
869
|
+
"onCancelEdition"?: (event: SnkDataUnitCustomEvent<void>) => void;
|
|
870
|
+
/**
|
|
871
|
+
* Disparado quando o há qualquer mudança de estado no DataUnit
|
|
872
|
+
*/
|
|
873
|
+
"onDataStateChange"?: (event: SnkDataUnitCustomEvent<DataState>) => void;
|
|
874
|
+
/**
|
|
875
|
+
* Disparado quando o DataUnit está pronto
|
|
876
|
+
*/
|
|
877
|
+
"onDataUnitReady"?: (event: SnkDataUnitCustomEvent<DataUnit>) => void;
|
|
878
|
+
/**
|
|
879
|
+
* Disparado quando um registro é adicionado ou copiado
|
|
880
|
+
*/
|
|
881
|
+
"onInsertionMode"?: (event: SnkDataUnitCustomEvent<void>) => void;
|
|
882
|
+
/**
|
|
883
|
+
* Determina quantas linhas são retornadas por página
|
|
884
|
+
*/
|
|
885
|
+
"pageSize"?: number;
|
|
886
|
+
}
|
|
887
|
+
interface SnkFieldConfig {
|
|
888
|
+
/**
|
|
889
|
+
* Armazena as propriedades do campo
|
|
890
|
+
*/
|
|
891
|
+
"fieldConfig"?: IFieldConfig;
|
|
892
|
+
/**
|
|
893
|
+
* Define se o popover de configuração está ativo.
|
|
894
|
+
*/
|
|
895
|
+
"isConfigActive"?: Boolean;
|
|
896
|
+
/**
|
|
897
|
+
* Define se o componente está em modo de inserção
|
|
898
|
+
*/
|
|
899
|
+
"modeInsertion"?: boolean;
|
|
900
|
+
/**
|
|
901
|
+
* Evento disparado ao pressionar button icon(onEzClickIcon)
|
|
902
|
+
*/
|
|
903
|
+
"onEzClickIcon"?: (event: SnkFieldConfigCustomEvent<Object>) => void;
|
|
904
|
+
}
|
|
905
|
+
interface SnkFilterBar {
|
|
906
|
+
/**
|
|
907
|
+
* Eventualmente poderemos ter mais de uma barra de filtros. Essa propriedade serve para separar a configuração de cada uma.
|
|
908
|
+
*/
|
|
909
|
+
"configName"?: string;
|
|
910
|
+
/**
|
|
911
|
+
* Recebe o DataUnit do ambiente. Se não for informado, procura pela referência do SnkDataUnit. Necessário para se registrar como provedor de filtros.
|
|
912
|
+
*/
|
|
913
|
+
"dataUnit"?: DataUnit;
|
|
914
|
+
/**
|
|
915
|
+
* Lista de todos os filtros disponíveis ao usuário.
|
|
916
|
+
*/
|
|
917
|
+
"filterConfig"?: Array<SnkFilterItemConfig>;
|
|
918
|
+
}
|
|
919
|
+
interface SnkFilterBinarySelect {
|
|
920
|
+
"config"?: SnkFilterItemConfig;
|
|
921
|
+
"value"?: any;
|
|
922
|
+
}
|
|
923
|
+
interface SnkFilterDetail {
|
|
924
|
+
"config"?: SnkFilterItemConfig;
|
|
925
|
+
"getMessage"?: (key: string, props?: any) => string;
|
|
926
|
+
"onFilterChange"?: (event: SnkFilterDetailCustomEvent<SnkFilterItemConfig>) => void;
|
|
927
|
+
}
|
|
928
|
+
interface SnkFilterItem {
|
|
929
|
+
"config"?: SnkFilterItemConfig;
|
|
930
|
+
"getMessage"?: (key: string, props?: any) => string;
|
|
931
|
+
"onFilterChange"?: (event: SnkFilterItemCustomEvent<SnkFilterItemConfig>) => void;
|
|
932
|
+
}
|
|
933
|
+
interface SnkFilterList {
|
|
934
|
+
"buttonClass"?: string;
|
|
935
|
+
"emptyText"?: string;
|
|
936
|
+
"findFilterText"?: string;
|
|
937
|
+
"getMessage"?: (key: string, props?: any) => string;
|
|
938
|
+
"iconName"?: string;
|
|
939
|
+
"items"?: Array<ListItem>;
|
|
940
|
+
"label"?: string;
|
|
941
|
+
"onSnkItemSelected"?: (event: SnkFilterListCustomEvent<string>) => void;
|
|
942
|
+
}
|
|
943
|
+
interface SnkFilterModal {
|
|
944
|
+
"cancelButtonLabel"?: string;
|
|
945
|
+
"getMessage"?: (key: string, props?: any) => string;
|
|
946
|
+
"infoText"?: string;
|
|
947
|
+
"items"?: Array<ModalItem>;
|
|
948
|
+
"modalSubTitle"?: string;
|
|
949
|
+
"modalTitle"?: string;
|
|
950
|
+
"okButtonLabel"?: string;
|
|
951
|
+
"processModalAction"?: (action: ModalAction) => void;
|
|
952
|
+
"useSearch"?: boolean;
|
|
953
|
+
}
|
|
954
|
+
interface SnkFilterMultiSelect {
|
|
955
|
+
"config"?: SnkFilterItemConfig;
|
|
956
|
+
"value"?: any;
|
|
957
|
+
}
|
|
958
|
+
interface SnkFilterNumber {
|
|
959
|
+
"config"?: SnkFilterItemConfig;
|
|
960
|
+
"value"?: number;
|
|
961
|
+
}
|
|
962
|
+
interface SnkFilterPeriod {
|
|
963
|
+
"config"?: SnkFilterItemConfig;
|
|
964
|
+
"value"?: any;
|
|
965
|
+
}
|
|
966
|
+
interface SnkFilterPersonalized {
|
|
967
|
+
"config"?: SnkFilterItemConfig;
|
|
968
|
+
"fix"?: ()=>void;
|
|
969
|
+
"unfix"?: ()=>void;
|
|
970
|
+
"value"?: Array<IOption|boolean|string|number|Date>;
|
|
971
|
+
}
|
|
972
|
+
interface SnkFilterSearch {
|
|
973
|
+
"config"?: SnkFilterItemConfig;
|
|
974
|
+
"value"?: IOption;
|
|
975
|
+
}
|
|
976
|
+
interface SnkFilterText {
|
|
977
|
+
"config"?: SnkFilterItemConfig;
|
|
978
|
+
"value"?: string;
|
|
979
|
+
}
|
|
980
|
+
interface SnkForm {
|
|
981
|
+
/**
|
|
982
|
+
* Lista de ações que devem ser usadas no botão "Mais opções"
|
|
983
|
+
*/
|
|
984
|
+
"actionsList"?: Array<Action>;
|
|
985
|
+
/**
|
|
986
|
+
* Nome usado para guardar/recuperar as configurações do formulário
|
|
987
|
+
*/
|
|
988
|
+
"configName"?: string;
|
|
989
|
+
/**
|
|
990
|
+
* Emitido sempre que houver click de botão ou ação
|
|
991
|
+
*/
|
|
992
|
+
"onActionClick"?: (event: SnkFormCustomEvent<string>) => void;
|
|
993
|
+
/**
|
|
994
|
+
* Evento disparado quando as configurações são alteradas.
|
|
995
|
+
*/
|
|
996
|
+
"onConfigChanged"?: (event: SnkFormCustomEvent<IFormConfig>) => void;
|
|
997
|
+
/**
|
|
998
|
+
* Emitido quando o botão de voltar é acionado
|
|
999
|
+
*/
|
|
1000
|
+
"onExit"?: (event: SnkFormCustomEvent<void>) => void;
|
|
1001
|
+
/**
|
|
1002
|
+
* Validador responsável por checar a integridade das informações do registro
|
|
1003
|
+
*/
|
|
1004
|
+
"recordsValidator"?: IRecordValidator;
|
|
1005
|
+
/**
|
|
1006
|
+
* Gerenciador das barras de tarefas. É possível determinar botões específicos ou mesmo gerenciar o estado dos botões.
|
|
1007
|
+
*/
|
|
1008
|
+
"taskbarManager"?: TaskbarManager;
|
|
1009
|
+
}
|
|
1010
|
+
interface SnkFormConfig {
|
|
1011
|
+
/**
|
|
1012
|
+
* Repositório de dados, controla a manipulação dos dados
|
|
1013
|
+
*/
|
|
1014
|
+
"dataUnit"?: DataUnit;
|
|
1015
|
+
/**
|
|
1016
|
+
* Campos de configuração de formulário.
|
|
1017
|
+
*/
|
|
1018
|
+
"formConfig"?: IFormConfig;
|
|
1019
|
+
/**
|
|
1020
|
+
* Evento disparado ao salvar as configurações.
|
|
1021
|
+
*/
|
|
1022
|
+
"onConfigChange"?: (event: SnkFormConfigCustomEvent<IFormConfig>) => void;
|
|
1023
|
+
/**
|
|
1024
|
+
* Representa o elemento pai do componente.
|
|
1025
|
+
*/
|
|
1026
|
+
"parentForm"?: HTMLSnkFormElement;
|
|
1027
|
+
}
|
|
1028
|
+
interface SnkGrid {
|
|
1029
|
+
/**
|
|
1030
|
+
* Lista de ações que devem ser usadas no botão "Mais opções"
|
|
1031
|
+
*/
|
|
1032
|
+
"actionsList"?: Array<Action>;
|
|
1033
|
+
/**
|
|
1034
|
+
* Nome usado para salvar/recuperar a configuração
|
|
1035
|
+
*/
|
|
1036
|
+
"configName"?: string;
|
|
1037
|
+
/**
|
|
1038
|
+
* Emitido sempre que houver click de botão ou ação
|
|
1039
|
+
*/
|
|
1040
|
+
"onActionClick"?: (event: SnkGridCustomEvent<string>) => void;
|
|
1041
|
+
/**
|
|
1042
|
+
* Evento disparado quando as configurações são alteradas.
|
|
1043
|
+
*/
|
|
1044
|
+
"onConfigChanged"?: (event: SnkGridCustomEvent<IGridConfig>) => void;
|
|
1045
|
+
/**
|
|
1046
|
+
* Emitido sempre que houver duplo click na grade
|
|
1047
|
+
*/
|
|
1048
|
+
"onGridDoubleClick"?: (event: SnkGridCustomEvent<void>) => void;
|
|
1049
|
+
/**
|
|
1050
|
+
* Configuração do valor da coluna de status. Exemplo: { "RECDESP": { "-1" : "#BD0025", "1" : "#157A00" } }
|
|
1051
|
+
*/
|
|
1052
|
+
"statusResolver"?: IStatusResolver;
|
|
1053
|
+
/**
|
|
1054
|
+
* Gerenciador das barras de tarefas. É possível determinar botões específicos ou mesmo gerenciar o estado dos botões.
|
|
1055
|
+
*/
|
|
1056
|
+
"taskbarManager"?: TaskbarManager;
|
|
1057
|
+
}
|
|
92
1058
|
interface SnkPesquisa {
|
|
93
1059
|
"argument"?: string;
|
|
94
1060
|
"searchLoader"?: Function;
|
|
95
1061
|
"selectItem"?: Function;
|
|
96
1062
|
}
|
|
1063
|
+
interface SnkTabConfig {
|
|
1064
|
+
/**
|
|
1065
|
+
* Evento emitido ao ocultar uma aba.
|
|
1066
|
+
*/
|
|
1067
|
+
"onCanStartDrag"?: (event: SnkTabConfigCustomEvent<any>) => void;
|
|
1068
|
+
/**
|
|
1069
|
+
* Evento emitido ao deletar uma aba.
|
|
1070
|
+
*/
|
|
1071
|
+
"onDeleteTab"?: (event: SnkTabConfigCustomEvent<any>) => void;
|
|
1072
|
+
/**
|
|
1073
|
+
* Evento emitido ao salvar uma alteração realizada no título da tab
|
|
1074
|
+
*/
|
|
1075
|
+
"onEditionTitleTab"?: (event: SnkTabConfigCustomEvent<any>) => void;
|
|
1076
|
+
/**
|
|
1077
|
+
* Evento emitido ao mover a aba mudando a sua ordem.
|
|
1078
|
+
*/
|
|
1079
|
+
"onEzOrderChange"?: (event: SnkTabConfigCustomEvent<number>) => void;
|
|
1080
|
+
/**
|
|
1081
|
+
* Evento emitido ao clicar para abrir o popup (ezTabChange). O detail desse evento carrega tanto o tabKey quanto o index da aba selecionada.
|
|
1082
|
+
*/
|
|
1083
|
+
"onEzTabChange"?: (event: SnkTabConfigCustomEvent<ITab>) => void;
|
|
1084
|
+
/**
|
|
1085
|
+
* Evento emitido ao ocultar uma aba.
|
|
1086
|
+
*/
|
|
1087
|
+
"onHideTab"?: (event: SnkTabConfigCustomEvent<any>) => void;
|
|
1088
|
+
/**
|
|
1089
|
+
* Define o index da aba selecionada.
|
|
1090
|
+
*/
|
|
1091
|
+
"selectedIndex"?: number;
|
|
1092
|
+
/**
|
|
1093
|
+
* Define a aba selecionada.
|
|
1094
|
+
*/
|
|
1095
|
+
"selectedTab"?: string;
|
|
1096
|
+
/**
|
|
1097
|
+
* Define o nome das abas do componente, separadas por vírgulas ",".
|
|
1098
|
+
*/
|
|
1099
|
+
"tabs"?: string;
|
|
1100
|
+
}
|
|
1101
|
+
interface SnkTaskbar {
|
|
1102
|
+
/**
|
|
1103
|
+
* Lista de ações que devem ser usadas no botão "Mais opções"
|
|
1104
|
+
*/
|
|
1105
|
+
"actionsList"?: Array<Action>;
|
|
1106
|
+
/**
|
|
1107
|
+
* Lista separada por virgula, contendo todos os elementos a serem criados
|
|
1108
|
+
*/
|
|
1109
|
+
"buttons"?: string;
|
|
1110
|
+
/**
|
|
1111
|
+
* Nome usado para guardar/recuperar as configurações do formulário
|
|
1112
|
+
*/
|
|
1113
|
+
"configName"?: string;
|
|
1114
|
+
/**
|
|
1115
|
+
* Mapa com definição de botões personalizados. A chave do mapa deve ser passada na lista "buttons" no lugar onde o botão irá aparecer.
|
|
1116
|
+
*/
|
|
1117
|
+
"customButtons"?: Map<string, CustomButton>;
|
|
1118
|
+
/**
|
|
1119
|
+
* Instância do DataUnit
|
|
1120
|
+
*/
|
|
1121
|
+
"dataUnit"?: DataUnit;
|
|
1122
|
+
/**
|
|
1123
|
+
* Array contendo todos os botões a serem desabilitados
|
|
1124
|
+
*/
|
|
1125
|
+
"disabledButtons"?: Array<string>;
|
|
1126
|
+
/**
|
|
1127
|
+
* Emitido sempre que houver alteração em algum elemento aberto pelo botão de ação
|
|
1128
|
+
*/
|
|
1129
|
+
"onActionChange"?: (event: SnkTaskbarCustomEvent<any>) => void;
|
|
1130
|
+
/**
|
|
1131
|
+
* Emitido sempre que houver click de botão ou ação
|
|
1132
|
+
*/
|
|
1133
|
+
"onActionClick"?: (event: SnkTaskbarCustomEvent<string>) => void;
|
|
1134
|
+
/**
|
|
1135
|
+
* Qual botão deve ter aparência primária
|
|
1136
|
+
*/
|
|
1137
|
+
"primaryButton"?: string;
|
|
1138
|
+
}
|
|
97
1139
|
interface TestePesquisa {
|
|
98
1140
|
}
|
|
99
1141
|
interface IntrinsicElements {
|
|
100
1142
|
"snk-application": SnkApplication;
|
|
1143
|
+
"snk-config-modal": SnkConfigModal;
|
|
1144
|
+
"snk-config-options": SnkConfigOptions;
|
|
1145
|
+
"snk-configurator": SnkConfigurator;
|
|
1146
|
+
"snk-crud": SnkCrud;
|
|
1147
|
+
"snk-data-unit": SnkDataUnit;
|
|
1148
|
+
"snk-field-config": SnkFieldConfig;
|
|
1149
|
+
"snk-filter-bar": SnkFilterBar;
|
|
1150
|
+
"snk-filter-binary-select": SnkFilterBinarySelect;
|
|
1151
|
+
"snk-filter-detail": SnkFilterDetail;
|
|
1152
|
+
"snk-filter-item": SnkFilterItem;
|
|
1153
|
+
"snk-filter-list": SnkFilterList;
|
|
1154
|
+
"snk-filter-modal": SnkFilterModal;
|
|
1155
|
+
"snk-filter-multi-select": SnkFilterMultiSelect;
|
|
1156
|
+
"snk-filter-number": SnkFilterNumber;
|
|
1157
|
+
"snk-filter-period": SnkFilterPeriod;
|
|
1158
|
+
"snk-filter-personalized": SnkFilterPersonalized;
|
|
1159
|
+
"snk-filter-search": SnkFilterSearch;
|
|
1160
|
+
"snk-filter-text": SnkFilterText;
|
|
1161
|
+
"snk-form": SnkForm;
|
|
1162
|
+
"snk-form-config": SnkFormConfig;
|
|
1163
|
+
"snk-grid": SnkGrid;
|
|
101
1164
|
"snk-pesquisa": SnkPesquisa;
|
|
1165
|
+
"snk-tab-config": SnkTabConfig;
|
|
1166
|
+
"snk-taskbar": SnkTaskbar;
|
|
102
1167
|
"teste-pesquisa": TestePesquisa;
|
|
103
1168
|
}
|
|
104
1169
|
}
|
|
@@ -107,7 +1172,30 @@ declare module "@stencil/core" {
|
|
|
107
1172
|
export namespace JSX {
|
|
108
1173
|
interface IntrinsicElements {
|
|
109
1174
|
"snk-application": LocalJSX.SnkApplication & JSXBase.HTMLAttributes<HTMLSnkApplicationElement>;
|
|
1175
|
+
"snk-config-modal": LocalJSX.SnkConfigModal & JSXBase.HTMLAttributes<HTMLSnkConfigModalElement>;
|
|
1176
|
+
"snk-config-options": LocalJSX.SnkConfigOptions & JSXBase.HTMLAttributes<HTMLSnkConfigOptionsElement>;
|
|
1177
|
+
"snk-configurator": LocalJSX.SnkConfigurator & JSXBase.HTMLAttributes<HTMLSnkConfiguratorElement>;
|
|
1178
|
+
"snk-crud": LocalJSX.SnkCrud & JSXBase.HTMLAttributes<HTMLSnkCrudElement>;
|
|
1179
|
+
"snk-data-unit": LocalJSX.SnkDataUnit & JSXBase.HTMLAttributes<HTMLSnkDataUnitElement>;
|
|
1180
|
+
"snk-field-config": LocalJSX.SnkFieldConfig & JSXBase.HTMLAttributes<HTMLSnkFieldConfigElement>;
|
|
1181
|
+
"snk-filter-bar": LocalJSX.SnkFilterBar & JSXBase.HTMLAttributes<HTMLSnkFilterBarElement>;
|
|
1182
|
+
"snk-filter-binary-select": LocalJSX.SnkFilterBinarySelect & JSXBase.HTMLAttributes<HTMLSnkFilterBinarySelectElement>;
|
|
1183
|
+
"snk-filter-detail": LocalJSX.SnkFilterDetail & JSXBase.HTMLAttributes<HTMLSnkFilterDetailElement>;
|
|
1184
|
+
"snk-filter-item": LocalJSX.SnkFilterItem & JSXBase.HTMLAttributes<HTMLSnkFilterItemElement>;
|
|
1185
|
+
"snk-filter-list": LocalJSX.SnkFilterList & JSXBase.HTMLAttributes<HTMLSnkFilterListElement>;
|
|
1186
|
+
"snk-filter-modal": LocalJSX.SnkFilterModal & JSXBase.HTMLAttributes<HTMLSnkFilterModalElement>;
|
|
1187
|
+
"snk-filter-multi-select": LocalJSX.SnkFilterMultiSelect & JSXBase.HTMLAttributes<HTMLSnkFilterMultiSelectElement>;
|
|
1188
|
+
"snk-filter-number": LocalJSX.SnkFilterNumber & JSXBase.HTMLAttributes<HTMLSnkFilterNumberElement>;
|
|
1189
|
+
"snk-filter-period": LocalJSX.SnkFilterPeriod & JSXBase.HTMLAttributes<HTMLSnkFilterPeriodElement>;
|
|
1190
|
+
"snk-filter-personalized": LocalJSX.SnkFilterPersonalized & JSXBase.HTMLAttributes<HTMLSnkFilterPersonalizedElement>;
|
|
1191
|
+
"snk-filter-search": LocalJSX.SnkFilterSearch & JSXBase.HTMLAttributes<HTMLSnkFilterSearchElement>;
|
|
1192
|
+
"snk-filter-text": LocalJSX.SnkFilterText & JSXBase.HTMLAttributes<HTMLSnkFilterTextElement>;
|
|
1193
|
+
"snk-form": LocalJSX.SnkForm & JSXBase.HTMLAttributes<HTMLSnkFormElement>;
|
|
1194
|
+
"snk-form-config": LocalJSX.SnkFormConfig & JSXBase.HTMLAttributes<HTMLSnkFormConfigElement>;
|
|
1195
|
+
"snk-grid": LocalJSX.SnkGrid & JSXBase.HTMLAttributes<HTMLSnkGridElement>;
|
|
110
1196
|
"snk-pesquisa": LocalJSX.SnkPesquisa & JSXBase.HTMLAttributes<HTMLSnkPesquisaElement>;
|
|
1197
|
+
"snk-tab-config": LocalJSX.SnkTabConfig & JSXBase.HTMLAttributes<HTMLSnkTabConfigElement>;
|
|
1198
|
+
"snk-taskbar": LocalJSX.SnkTaskbar & JSXBase.HTMLAttributes<HTMLSnkTaskbarElement>;
|
|
111
1199
|
"teste-pesquisa": LocalJSX.TestePesquisa & JSXBase.HTMLAttributes<HTMLTestePesquisaElement>;
|
|
112
1200
|
}
|
|
113
1201
|
}
|