@sankhyalabs/sankhyablocks 10.1.0-dev.6 → 10.1.0-dev.60
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/LICENSE +4 -1
- package/dist/cjs/{ConfigStorage-72f34bd4.js → ConfigStorage-156bfcac.js} +19 -2
- package/dist/cjs/ContinuousInsertUtils-1ae0c6ac.js +41 -0
- package/dist/cjs/{DataFetcher-991b0349.js → DataFetcher-d13b4637.js} +121 -69
- package/dist/cjs/{FormConfigHelper-e253a418.js → FormConfigHelper-28fe4668.js} +3 -1
- package/dist/cjs/FormConfigHelper-c5f5473a.js +342 -0
- package/dist/cjs/{ISave-ebf6b4ed.js → ISave-55d9dcc3.js} +1 -1
- package/dist/cjs/ImageUtils-d6139911.js +144 -0
- package/dist/cjs/{PersonalizedFilterUtils-7259cf65.js → PersonalizedFilterUtils-263e4d24.js} +65 -5
- package/dist/cjs/{SnkFormConfigManager-cdbb29d4.js → SnkFormConfigManager-5cb9a39c.js} +5 -5
- package/dist/cjs/{SnkMultiSelectionListDataSource-011bec79.js → SnkMultiSelectionListDataSource-5c5badfc.js} +146 -74
- package/dist/cjs/{auth-fetcher-c3cac878.js → auth-fetcher-d1715459.js} +1 -1
- package/dist/cjs/config-header.cjs.entry.js +1 -1
- package/dist/cjs/configs-button.cjs.entry.js +1 -1
- package/dist/cjs/css-shim-a27d231b.js +6 -0
- package/dist/cjs/{dataunit-fetcher-8bf469e7.js → dataunit-fetcher-fae710c5.js} +91 -110
- package/dist/cjs/dom-ff96a4bc.js +75 -0
- package/dist/cjs/field-config_2.cjs.entry.js +3 -3
- package/dist/cjs/fields-layout.cjs.entry.js +6 -6
- package/dist/cjs/fields-selector.cjs.entry.js +3 -3
- package/dist/cjs/{filter-type.enum-2bb46d2a.js → filter-type.enum-b3b388af.js} +7 -0
- package/dist/cjs/{form-config-fetcher-c7af90d8.js → form-config-fetcher-bbebdcb8.js} +41 -5
- package/dist/cjs/guides-configurator.cjs.entry.js +3 -3
- package/dist/cjs/{index-1cf293c1.js → index-1894343a.js} +1547 -207
- package/dist/cjs/{index-e3e39724.js → index-bc950921.js} +6 -0
- package/dist/cjs/{index-13d05f03.js → index-f0fe7e6e.js} +90 -21
- package/dist/cjs/loader.cjs.js +16 -2
- package/dist/cjs/pesquisa-grid_2.cjs.entry.js +6 -6
- package/dist/cjs/sankhyablocks.cjs.js +132 -4
- package/dist/cjs/shadow-css-7e3e0ab1.js +389 -0
- package/dist/cjs/snk-actions-button_9.cjs.entry.js +169 -120
- package/dist/cjs/snk-actions-form.cjs.entry.js +1 -1
- package/dist/cjs/snk-application.cjs.entry.js +28 -9
- package/dist/cjs/snk-attach_11.cjs.entry.js +2952 -0
- package/dist/cjs/snk-client-confirm.cjs.entry.js +1 -1
- package/dist/cjs/snk-configurator.cjs.entry.js +3 -1
- package/dist/cjs/snk-crud.cjs.entry.js +149 -102
- package/dist/cjs/snk-custom-slot-elements.cjs.entry.js +1 -1
- package/dist/cjs/snk-custom-slot-guide.cjs.entry.js +40 -0
- package/dist/cjs/snk-data-exporter.cjs.entry.js +62 -16
- package/dist/cjs/{snk-data-unit-7d587ad5.js → snk-data-unit-32237a2d.js} +12 -3
- package/dist/cjs/snk-data-unit.cjs.entry.js +4 -4
- package/dist/cjs/snk-detail-view.cjs.entry.js +32 -20
- package/dist/cjs/snk-dynaform-config-header_5.cjs.entry.js +739 -0
- package/dist/cjs/snk-dynaform-detail-view_2.cjs.entry.js +961 -0
- package/dist/cjs/snk-dynaform-field-config_2.cjs.entry.js +327 -0
- package/dist/cjs/snk-dynaform-guides-view-2c7c6ce4.js +1094 -0
- package/dist/cjs/snk-dynaform-guides-view.cjs.entry.js +23 -0
- package/dist/cjs/snk-dynaform.cjs.entry.js +679 -0
- package/dist/cjs/snk-entity-list.cjs.entry.js +1 -1
- package/dist/cjs/snk-entity-search.cjs.entry.js +211 -0
- package/dist/cjs/snk-exporter-email-sender.cjs.entry.js +2 -2
- package/dist/cjs/{snk-expression-group_2.cjs.entry.js → snk-expression-group_4.cjs.entry.js} +422 -19
- package/dist/cjs/snk-filter-bar_4.cjs.entry.js +170 -120
- package/dist/cjs/snk-filter-binary-select.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-checkbox-list.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-multi-select.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-number.cjs.entry.js +11 -7
- package/dist/cjs/snk-filter-period.cjs.entry.js +14 -7
- package/dist/cjs/snk-filter-search.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-text.cjs.entry.js +2 -2
- package/dist/cjs/snk-form-summary.cjs.entry.js +1 -1
- package/dist/cjs/snk-form-view.cjs.entry.js +70 -8
- package/dist/cjs/snk-form_2.cjs.entry.js +21 -11
- package/dist/cjs/snk-grid.cjs.entry.js +91 -36
- package/dist/cjs/{snk-guides-viewer-366d5c32.js → snk-guides-viewer-67b9cca9.js} +78 -214
- package/dist/cjs/snk-guides-viewer.cjs.entry.js +10 -18
- package/dist/cjs/snk-layout-form-config.cjs.entry.js +71 -0
- package/dist/cjs/snk-personalized-filter-editor.cjs.entry.js +1 -1
- package/dist/cjs/snk-pesquisa.cjs.entry.js +6 -7
- package/dist/cjs/snk-print-selector.cjs.entry.js +1 -1
- package/dist/cjs/snk-taskbar.cjs.entry.js +184 -127
- package/dist/cjs/{sortable.esm-9a110bb7.js → sortable.esm-b87669ab.js} +76 -90
- package/dist/cjs/taskbar-elements-25f800b3.js +152 -0
- package/dist/cjs/taskbarUtils-99aaa01f.js +236 -0
- package/dist/cjs/teste-pesquisa.cjs.entry.js +1 -1
- package/dist/collection/collection-manifest.json +26 -0
- package/dist/collection/components/snk-actions-button/actions/executor/launch-screen.executor.js +6 -3
- package/dist/collection/components/snk-actions-button/snk-actions-button.js +30 -6
- package/dist/collection/components/snk-application/errorhandler/snk-error-handler.js +1 -0
- package/dist/collection/components/snk-application/snk-application.js +20 -2
- package/dist/collection/components/snk-attach/snk-attach.css +29 -7
- package/dist/collection/components/snk-attach/snk-attach.js +93 -18
- package/dist/collection/components/snk-configurator/snk-configurator.js +2 -0
- package/dist/collection/components/snk-crud/snk-crud.css +55 -0
- package/dist/collection/components/snk-crud/snk-crud.js +169 -98
- package/dist/collection/components/snk-crud/subcomponents/GuideBuilder.js +1 -1
- package/dist/collection/components/snk-crud/subcomponents/snk-detail-view/snk-detail-view.css +4 -1
- package/dist/collection/components/snk-crud/subcomponents/snk-detail-view/snk-detail-view.js +21 -7
- package/dist/collection/components/snk-crud/subcomponents/snk-entity-search.css +17 -0
- package/dist/collection/components/snk-crud/subcomponents/snk-entity-search.js +330 -0
- package/dist/collection/components/snk-crud/subcomponents/snk-form-view.js +90 -8
- package/dist/collection/components/snk-crud/subcomponents/snk-guides-viewer.css +22 -8
- package/dist/collection/components/snk-crud/subcomponents/snk-guides-viewer.js +89 -204
- package/dist/collection/components/snk-crud/utils/taskbarUtils.js +163 -0
- package/dist/collection/components/snk-custom-slot-guide/snk-custom-slot-guide.css +3 -0
- package/dist/collection/components/snk-custom-slot-guide/snk-custom-slot-guide.js +95 -0
- package/dist/collection/components/snk-data-exporter/exporter-email-sender/snk-exporter-email-sender.js +1 -1
- package/dist/collection/components/snk-data-exporter/exporter-strategy/ClientSideExporterStrategy.js +2 -2
- package/dist/collection/components/snk-data-exporter/interfaces/IExporterProvider.js +78 -23
- package/dist/collection/components/snk-data-exporter/snk-data-exporter.js +28 -5
- package/dist/collection/components/snk-data-exporter/structure/ItemBuilder.js +43 -2
- package/dist/collection/components/snk-data-unit/snk-data-unit.js +9 -0
- package/dist/collection/components/snk-dynaform/interfaces/PropsCustomEditor.js +1 -0
- package/dist/collection/components/snk-dynaform/interfaces/PropsCustomRender.js +1 -0
- package/dist/collection/components/snk-dynaform/snk-dynaform.css +69 -0
- package/dist/collection/components/snk-dynaform/snk-dynaform.js +1661 -0
- package/dist/collection/components/snk-dynaform/subcomponents/CardFormResizeObserver.js +26 -0
- package/dist/collection/components/snk-dynaform/subcomponents/GuideBuilder.js +51 -0
- package/dist/collection/components/snk-dynaform/subcomponents/snk-dynaform-detail-view/snk-dynaform-detail-view.css +182 -0
- package/dist/collection/components/snk-dynaform/subcomponents/snk-dynaform-detail-view/snk-dynaform-detail-view.js +1015 -0
- package/dist/collection/components/snk-dynaform/subcomponents/snk-dynaform-form-view/snk-dynaform-form-view.css +98 -0
- package/dist/collection/components/snk-dynaform/subcomponents/snk-dynaform-form-view/snk-dynaform-form-view.js +590 -0
- package/dist/collection/components/snk-dynaform/subcomponents/snk-dynaform-guides-view/snk-dynaform-guides-view.css +321 -0
- package/dist/collection/components/snk-dynaform/subcomponents/snk-dynaform-guides-view/snk-dynaform-guides-view.js +1587 -0
- package/dist/collection/components/snk-dynaform-form-config/FormConfigHelper.js +325 -0
- package/dist/collection/components/snk-dynaform-form-config/SnkFormConfigManager.js +219 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-config-header/snk-dynaform-config-header.css +17 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-config-header/snk-dynaform-config-header.js +236 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-config-header/snk-dynaform-configs-button/snk-dynaform-configs-button.css +41 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-config-header/snk-dynaform-configs-button/snk-dynaform-configs-button.js +170 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-field-item/snk-dynaform-field-config/snk-dynaform-field-config.css +22 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-field-item/snk-dynaform-field-config/snk-dynaform-field-config.js +408 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-field-item/snk-dynaform-field-item.css +88 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-field-item/snk-dynaform-field-item.js +209 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-fields-layout/snk-dynaform-fields-layout.css +167 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-fields-layout/snk-dynaform-fields-layout.js +655 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-fields-selector/snk-dynaform-fields-selector.css +42 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-fields-selector/snk-dynaform-fields-selector.js +171 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-form-config.css +66 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-form-config.js +557 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-guides-configurator/snk-dynaform-guides-configurator.css +80 -0
- package/dist/collection/components/snk-dynaform-form-config/snk-dynaform-guides-configurator/snk-dynaform-guides-configurator.js +326 -0
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-number.js +12 -8
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-period.js +14 -7
- package/dist/collection/components/snk-filter-bar/filter-item/editors/snk-filter-text.js +1 -1
- package/dist/collection/components/snk-filter-bar/filter-item/snk-filter-detail.js +1 -1
- package/dist/collection/components/snk-filter-bar/filter-item/snk-filter-item.css +5 -1
- package/dist/collection/components/snk-filter-bar/filter-item/snk-filter-item.js +28 -2
- package/dist/collection/components/snk-filter-bar/filter-modal/snk-filter-modal.css +7 -1
- package/dist/collection/components/snk-filter-bar/filter-modal/snk-filter-modal.js +22 -8
- package/dist/collection/components/snk-filter-bar/snk-filter-bar.css +1 -6
- package/dist/collection/components/snk-filter-bar/snk-filter-bar.js +166 -78
- package/dist/collection/components/snk-form-config/FormConfigHelper.js +3 -1
- package/dist/collection/components/snk-form-config/SnkFormConfigManager.js +3 -3
- package/dist/collection/components/snk-form-config/field-item/field-config/field-config.css +1 -0
- package/dist/collection/components/snk-form-config/fields-layout/fields-layout.css +16 -0
- package/dist/collection/components/snk-form-config/fields-layout/fields-layout.js +4 -4
- package/dist/collection/components/snk-form-config/guides-configurator/guides-configurator.css +3 -4
- package/dist/collection/components/snk-form-config/guides-configurator/guides-configurator.js +2 -2
- package/dist/collection/components/snk-form-config/snk-form-config.js +15 -5
- package/dist/collection/components/snk-grid/snk-grid.css +33 -5
- package/dist/collection/components/snk-grid/snk-grid.js +199 -24
- package/dist/collection/components/snk-grid-config/snk-grid-config.js +153 -51
- package/dist/collection/components/snk-image-input/snk-image-input.css +3 -0
- package/dist/collection/components/snk-image-input/snk-image-input.js +338 -0
- package/dist/collection/components/snk-image-input/utils/ImageUtils.js +135 -0
- package/dist/collection/components/snk-layout-form-config/snk-layout-form-config.js +1 -1
- package/dist/collection/components/snk-layout-form-config/snk-view-representation/snk-view-representation.js +1 -1
- package/dist/collection/components/snk-personalized-filter/snk-personalized-filter.js +1 -1
- package/dist/collection/components/snk-personalized-filter/subcomponents/snk-filter-param-config/utils/PersonalizedFilterUtils.js +13 -0
- package/dist/collection/components/snk-pesquisa/snk-pesquisa.js +0 -4
- package/dist/collection/components/snk-simple-crud/snk-simple-crud.js +34 -22
- package/dist/collection/components/snk-taskbar/elements/taskbar-actions-button/taskbar-actions-button.css +8 -0
- package/dist/collection/components/snk-taskbar/elements/taskbar-actions-button/taskbar-actions-button.js +38 -2
- package/dist/collection/components/snk-taskbar/elements/taskbar-elements.js +54 -37
- package/dist/collection/components/snk-taskbar/elements/taskbar-split-button/taskbar-split-button.js +27 -1
- package/dist/collection/components/snk-taskbar/processor/simple-taskbar-processor.js +55 -0
- package/dist/collection/components/snk-taskbar/snk-taskbar.css +44 -1
- package/dist/collection/components/snk-taskbar/snk-taskbar.js +248 -132
- package/dist/collection/components/snk-taskbar/subcomponents/snk-taskbar-skeleton.css +12 -0
- package/dist/collection/components/snk-taskbar/subcomponents/snk-taskbar-skeleton.js +19 -0
- package/dist/collection/lib/@types/index.js +6 -0
- package/dist/collection/lib/configs/ConfigStorage.js +5 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/data-unit/DataUnitDataLoader.js +1 -1
- package/dist/collection/lib/http/data-fetcher/fetchers/data-unit/cache/PreloadManager.js +51 -4
- package/dist/collection/lib/http/data-fetcher/fetchers/data-unit/dataunit-fetcher.js +24 -2
- package/dist/collection/lib/http/data-fetcher/fetchers/data-unit/helpers/DataUnitDataLoaderHelper.js +15 -104
- package/dist/collection/lib/http/data-fetcher/fetchers/form-config-fetcher.js +22 -4
- package/dist/collection/lib/http/data-fetcher/fetchers/grid-config-fetcher.js +12 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/resource-fetcher.js +18 -0
- package/dist/collection/lib/message/SnkMessageBuilder.js +11 -2
- package/dist/collection/lib/message/messageResourceEnUSUtils.js +2 -0
- package/dist/collection/lib/message/messageResourceEsESUtils.js +2 -0
- package/dist/collection/lib/message/messageResourcePtBRUtils.js +2 -0
- package/dist/collection/lib/message/resources/en-us/dataUnitDataLoaderHelper.msg.js +0 -13
- package/dist/collection/lib/message/resources/en-us/snk-crud.msg.js +13 -1
- package/dist/collection/lib/message/resources/en-us/snk-form.msg.js +1 -0
- package/dist/collection/lib/message/resources/en-us/snk-image-input.msg.js +11 -0
- package/dist/collection/lib/message/resources/en-us/snk-layout-form-config.msg.js +10 -2
- package/dist/collection/lib/message/resources/es-es/dataUnitDataLoaderHelper.msg.js +0 -13
- package/dist/collection/lib/message/resources/es-es/snk-crud.msg.js +13 -1
- package/dist/collection/lib/message/resources/es-es/snk-form.msg.js +1 -0
- package/dist/collection/lib/message/resources/es-es/snk-image-input.msg.js +11 -0
- package/dist/collection/lib/message/resources/es-es/snk-layout-form-config.msg.js +8 -0
- package/dist/collection/lib/message/resources/pt-br/dataUnitDataLoaderHelper.msg.js +0 -13
- package/dist/collection/lib/message/resources/pt-br/snk-configurator.msg.js +1 -1
- package/dist/collection/lib/message/resources/pt-br/snk-crud.msg.js +13 -1
- package/dist/collection/lib/message/resources/pt-br/snk-form.msg.js +1 -0
- package/dist/collection/lib/message/resources/pt-br/snk-image-input.msg.js +11 -0
- package/dist/collection/lib/message/resources/pt-br/snk-layout-form-config.msg.js +10 -2
- package/dist/collection/lib/utils/CrudUtils.js +7 -4
- package/dist/components/ConfigStorage.js +17 -0
- package/dist/components/ContinuousInsertUtils.js +86 -28
- package/dist/components/DataFetcher.js +3 -2731
- package/dist/components/ISave.js +6 -0
- package/dist/components/PersonalizedFilterUtils.js +13 -0
- package/dist/components/SnkFormConfigManager.js +3 -3
- package/dist/components/SnkMessageBuilder.js +2804 -0
- package/dist/components/dataunit-fetcher.js +91 -110
- package/dist/components/field-config2.js +4 -2
- package/dist/components/fields-layout2.js +4 -4
- package/dist/components/form-config-fetcher.js +40 -4
- package/dist/components/guides-configurator2.js +2 -2
- package/dist/components/index.d.ts +16 -0
- package/dist/components/index.js +16 -0
- package/dist/components/index2.js +90 -21
- package/dist/components/snk-actions-button2.js +15 -9
- package/dist/components/snk-application2.js +22 -2
- package/dist/components/snk-attach2.js +69 -27
- package/dist/components/snk-configurator2.js +2 -0
- package/dist/components/snk-crud.js +240 -176
- package/dist/components/snk-custom-slot-guide.d.ts +11 -0
- package/dist/components/snk-custom-slot-guide.js +55 -0
- package/dist/components/snk-data-exporter2.js +56 -9
- package/dist/components/snk-data-unit2.js +10 -1
- package/dist/components/snk-detail-view2.js +227 -318
- package/dist/components/snk-dynaform-config-header.d.ts +11 -0
- package/dist/components/snk-dynaform-config-header.js +6 -0
- package/dist/components/snk-dynaform-config-header2.js +103 -0
- package/dist/components/snk-dynaform-configs-button.d.ts +11 -0
- package/dist/components/snk-dynaform-configs-button.js +6 -0
- package/dist/components/snk-dynaform-configs-button2.js +76 -0
- package/dist/components/snk-dynaform-detail-view.d.ts +11 -0
- package/dist/components/snk-dynaform-detail-view.js +6 -0
- package/dist/components/snk-dynaform-detail-view2.js +2213 -0
- package/dist/components/snk-dynaform-field-config.d.ts +11 -0
- package/dist/components/snk-dynaform-field-config.js +6 -0
- package/dist/components/snk-dynaform-field-config2.js +605 -0
- package/dist/components/snk-dynaform-field-item.d.ts +11 -0
- package/dist/components/snk-dynaform-field-item.js +6 -0
- package/dist/components/snk-dynaform-field-item2.js +96 -0
- package/dist/components/snk-dynaform-fields-layout.d.ts +11 -0
- package/dist/components/snk-dynaform-fields-layout.js +6 -0
- package/dist/components/snk-dynaform-fields-layout2.js +428 -0
- package/dist/components/snk-dynaform-fields-selector.d.ts +11 -0
- package/dist/components/snk-dynaform-fields-selector.js +6 -0
- package/dist/components/snk-dynaform-fields-selector2.js +104 -0
- package/dist/components/snk-dynaform-form-config.d.ts +11 -0
- package/dist/components/snk-dynaform-form-config.js +6 -0
- package/dist/components/snk-dynaform-form-config2.js +430 -0
- package/dist/components/snk-dynaform-form-view.d.ts +11 -0
- package/dist/components/snk-dynaform-form-view.js +6 -0
- package/dist/components/snk-dynaform-form-view2.js +272 -0
- package/dist/components/snk-dynaform-guides-configurator.d.ts +11 -0
- package/dist/components/snk-dynaform-guides-configurator.js +6 -0
- package/dist/components/snk-dynaform-guides-configurator2.js +173 -0
- package/dist/components/snk-dynaform-guides-view.d.ts +11 -0
- package/dist/components/snk-dynaform-guides-view.js +6 -0
- package/dist/components/snk-dynaform.d.ts +11 -0
- package/dist/components/snk-dynaform.js +1007 -0
- package/dist/components/snk-entity-search.d.ts +11 -0
- package/dist/components/snk-entity-search.js +6 -0
- package/dist/components/snk-entity-search2.js +231 -0
- package/dist/components/snk-exporter-email-sender2.js +1 -1
- package/dist/components/snk-filter-bar2.js +116 -80
- package/dist/components/snk-filter-detail2.js +1 -1
- package/dist/components/snk-filter-item2.js +9 -3
- package/dist/components/snk-filter-modal2.js +22 -9
- package/dist/components/snk-filter-number.js +11 -7
- package/dist/components/snk-filter-period.js +13 -6
- package/dist/components/snk-filter-text.js +1 -1
- package/dist/components/snk-form-config2.js +15 -5
- package/dist/components/snk-form-view2.js +79 -10
- package/dist/components/snk-grid-config2.js +109 -50
- package/dist/components/snk-grid2.js +132 -65
- package/dist/components/snk-image-input.d.ts +11 -0
- package/dist/components/snk-image-input.js +6 -0
- package/dist/components/snk-image-input2.js +316 -0
- package/dist/components/snk-layout-form-config2.js +1 -1
- package/dist/components/snk-personalized-filter2.js +1 -1
- package/dist/components/snk-pesquisa2.js +0 -1
- package/dist/components/snk-simple-crud2.js +46 -45
- package/dist/components/snk-taskbar-skeleton.d.ts +11 -0
- package/dist/components/snk-taskbar-skeleton.js +6 -0
- package/dist/components/snk-taskbar-skeleton2.js +29 -0
- package/dist/components/snk-taskbar2.js +256 -176
- package/dist/components/snk-view-representation2.js +1 -1
- package/dist/components/sortable.esm.js +76 -90
- package/dist/components/taskbar-actions-button2.js +21 -2
- package/dist/components/taskbar-split-button2.js +10 -1
- package/dist/components/taskbarUtils.js +229 -0
- package/dist/esm/{ConfigStorage-22324b6b.js → ConfigStorage-0d1c0695.js} +19 -2
- package/dist/esm/ContinuousInsertUtils-bce77dc1.js +39 -0
- package/dist/esm/{DataFetcher-450828a0.js → DataFetcher-70de9419.js} +121 -49
- package/dist/esm/{FormConfigHelper-e89ca25c.js → FormConfigHelper-d09669f3.js} +3 -1
- package/dist/esm/FormConfigHelper-efc29480.js +328 -0
- package/dist/esm/{ISave-61153166.js → ISave-f5704813.js} +1 -1
- package/dist/esm/ImageUtils-efbea0e4.js +138 -0
- package/dist/esm/{PersonalizedFilterUtils-2db38ff2.js → PersonalizedFilterUtils-45b5803c.js} +62 -2
- package/dist/esm/{SnkFormConfigManager-b5a92e12.js → SnkFormConfigManager-e7f05f79.js} +5 -5
- package/dist/esm/{SnkMultiSelectionListDataSource-d7ce2e54.js → SnkMultiSelectionListDataSource-6ac291a9.js} +141 -69
- package/dist/esm/{auth-fetcher-eef9d01e.js → auth-fetcher-e34880e5.js} +1 -1
- package/dist/esm/config-header.entry.js +1 -1
- package/dist/esm/configs-button.entry.js +1 -1
- package/dist/esm/css-shim-9f2d321e.js +4 -0
- package/dist/esm/{dataunit-fetcher-da9596f6.js → dataunit-fetcher-d26e4a08.js} +91 -110
- package/dist/esm/dom-64053c71.js +73 -0
- package/dist/esm/field-config_2.entry.js +3 -3
- package/dist/esm/fields-layout.entry.js +6 -6
- package/dist/esm/fields-selector.entry.js +3 -3
- package/dist/esm/{filter-type.enum-f6a8fe23.js → filter-type.enum-62b7fe88.js} +8 -1
- package/dist/esm/{form-config-fetcher-8d0a5e1c.js → form-config-fetcher-98c42169.js} +41 -5
- package/dist/esm/guides-configurator.entry.js +3 -3
- package/dist/esm/{index-479e1293.js → index-04f73a26.js} +1539 -207
- package/dist/esm/{index-b40568ff.js → index-c6721886.js} +6 -0
- package/dist/esm/{index-446f9341.js → index-ea250be6.js} +90 -21
- package/dist/esm/loader.js +17 -3
- package/dist/esm/pesquisa-grid_2.entry.js +6 -6
- package/dist/esm/sankhyablocks.js +133 -5
- package/dist/esm/shadow-css-98135883.js +387 -0
- package/dist/esm/snk-actions-button_9.entry.js +170 -121
- package/dist/esm/snk-actions-form.entry.js +1 -1
- package/dist/esm/snk-application.entry.js +28 -9
- package/dist/esm/snk-attach_11.entry.js +2938 -0
- package/dist/esm/snk-client-confirm.entry.js +1 -1
- package/dist/esm/snk-configurator.entry.js +3 -1
- package/dist/esm/snk-crud.entry.js +149 -102
- package/dist/esm/snk-custom-slot-elements.entry.js +1 -1
- package/dist/esm/snk-custom-slot-guide.entry.js +36 -0
- package/dist/esm/snk-data-exporter.entry.js +62 -16
- package/dist/esm/{snk-data-unit-99616a07.js → snk-data-unit-ff57ac90.js} +12 -3
- package/dist/esm/snk-data-unit.entry.js +4 -4
- package/dist/esm/snk-detail-view.entry.js +32 -20
- package/dist/esm/snk-dynaform-config-header_5.entry.js +731 -0
- package/dist/esm/snk-dynaform-detail-view_2.entry.js +956 -0
- package/dist/esm/snk-dynaform-field-config_2.entry.js +322 -0
- package/dist/esm/snk-dynaform-guides-view-0dfbefc1.js +1091 -0
- package/dist/esm/snk-dynaform-guides-view.entry.js +15 -0
- package/dist/esm/snk-dynaform.entry.js +675 -0
- package/dist/esm/snk-entity-list.entry.js +1 -1
- package/dist/esm/snk-entity-search.entry.js +207 -0
- package/dist/esm/snk-exporter-email-sender.entry.js +2 -2
- package/dist/esm/{snk-expression-group_2.entry.js → snk-expression-group_4.entry.js} +407 -6
- package/dist/esm/snk-filter-bar_4.entry.js +148 -98
- package/dist/esm/snk-filter-binary-select.entry.js +1 -1
- package/dist/esm/snk-filter-checkbox-list.entry.js +1 -1
- package/dist/esm/snk-filter-multi-select.entry.js +1 -1
- package/dist/esm/snk-filter-number.entry.js +11 -7
- package/dist/esm/snk-filter-period.entry.js +14 -7
- package/dist/esm/snk-filter-search.entry.js +1 -1
- package/dist/esm/snk-filter-text.entry.js +2 -2
- package/dist/esm/snk-form-summary.entry.js +1 -1
- package/dist/esm/snk-form-view.entry.js +71 -9
- package/dist/esm/snk-form_2.entry.js +21 -11
- package/dist/esm/snk-grid.entry.js +89 -34
- package/dist/esm/{snk-guides-viewer-240de636.js → snk-guides-viewer-31a0a23d.js} +79 -215
- package/dist/esm/snk-guides-viewer.entry.js +10 -18
- package/dist/esm/snk-layout-form-config.entry.js +67 -0
- package/dist/esm/snk-personalized-filter-editor.entry.js +1 -1
- package/dist/esm/snk-pesquisa.entry.js +6 -7
- package/dist/esm/snk-print-selector.entry.js +1 -1
- package/dist/esm/snk-taskbar.entry.js +185 -128
- package/dist/esm/{sortable.esm-842f85a3.js → sortable.esm-bc277c12.js} +76 -90
- package/dist/esm/taskbar-elements-ba9d6889.js +149 -0
- package/dist/esm/taskbarUtils-cb9db0d9.js +230 -0
- package/dist/esm/teste-pesquisa.entry.js +1 -1
- package/dist/sankhyablocks/{p-840fb68c.js → p-097d75b3.js} +2 -2
- package/dist/sankhyablocks/{p-7f7fe6c4.entry.js → p-0a160fb5.entry.js} +1 -1
- package/dist/sankhyablocks/p-0dbd53d9.js +1 -0
- package/dist/sankhyablocks/p-12579574.entry.js +1 -0
- package/dist/sankhyablocks/p-129a4906.entry.js +1 -0
- package/dist/sankhyablocks/{p-162bddae.entry.js → p-175c9576.entry.js} +1 -1
- package/dist/sankhyablocks/p-1d31aec3.entry.js +1 -0
- package/dist/sankhyablocks/p-24b059ee.entry.js +1 -0
- package/dist/sankhyablocks/{p-f5e942b7.entry.js → p-250b273e.entry.js} +1 -1
- package/dist/sankhyablocks/p-26f1919e.entry.js +1 -0
- package/dist/sankhyablocks/p-2a83f20e.entry.js +1 -0
- package/dist/sankhyablocks/p-2c4f7fdd.entry.js +1 -0
- package/dist/sankhyablocks/p-2c9d0870.js +2 -0
- package/dist/sankhyablocks/{p-cb4343c4.entry.js → p-2cc2526e.entry.js} +1 -1
- package/dist/sankhyablocks/{p-75af335e.entry.js → p-2ebda226.entry.js} +1 -1
- package/dist/sankhyablocks/p-2ec98523.js +1 -0
- package/dist/sankhyablocks/p-3a35917e.entry.js +1 -0
- package/dist/sankhyablocks/p-449dfe55.entry.js +1 -0
- package/dist/sankhyablocks/p-46d7e2de.js +1 -0
- package/dist/sankhyablocks/p-4dd574d6.js +1 -0
- package/dist/sankhyablocks/p-541c72ec.entry.js +1 -0
- package/dist/sankhyablocks/p-58709cf9.js +1 -0
- package/dist/sankhyablocks/{p-27482793.entry.js → p-5aae5c74.entry.js} +1 -1
- package/dist/sankhyablocks/p-5aeae67f.js +1 -0
- package/dist/sankhyablocks/p-5d50f59a.entry.js +1 -0
- package/dist/sankhyablocks/p-5ef0e9a8.entry.js +1 -0
- package/dist/sankhyablocks/p-6f60df43.js +1 -0
- package/dist/sankhyablocks/{p-825098c1.entry.js → p-752c57f4.entry.js} +1 -1
- package/dist/sankhyablocks/{p-e258de96.entry.js → p-76729994.entry.js} +1 -1
- package/dist/sankhyablocks/{p-62e9b9b8.entry.js → p-846d8f79.entry.js} +1 -1
- package/dist/sankhyablocks/p-855ccf64.entry.js +1 -0
- package/dist/sankhyablocks/p-885262ce.entry.js +1 -0
- package/dist/sankhyablocks/{p-118c221e.js → p-8b4d6719.js} +1 -1
- package/dist/sankhyablocks/p-8d1ef77a.js +60 -0
- package/dist/sankhyablocks/{p-7d6f1285.js → p-8d81c8d3.js} +2 -2
- package/dist/sankhyablocks/{p-3d41f5a8.entry.js → p-8d946600.entry.js} +1 -1
- package/dist/sankhyablocks/p-8f5dd87d.entry.js +1 -0
- package/dist/sankhyablocks/p-90037547.js +1 -0
- package/dist/sankhyablocks/{p-96d45943.entry.js → p-90ae6c2e.entry.js} +1 -1
- package/dist/sankhyablocks/{p-0b9a42ad.entry.js → p-9742ea0e.entry.js} +1 -1
- package/dist/sankhyablocks/p-9e02a785.js +1 -0
- package/dist/sankhyablocks/{p-2fdac5e6.entry.js → p-9e109f5e.entry.js} +1 -1
- package/dist/sankhyablocks/p-9e7dc97d.entry.js +1 -0
- package/dist/sankhyablocks/p-a25ab2ff.entry.js +1 -0
- package/dist/sankhyablocks/p-a2a9f520.entry.js +1 -0
- package/dist/sankhyablocks/p-a46ac091.js +1 -0
- package/dist/sankhyablocks/p-a696bbcd.entry.js +1 -0
- package/dist/sankhyablocks/p-a73b6b00.js +1 -0
- package/dist/sankhyablocks/p-a9012341.entry.js +11 -0
- package/dist/sankhyablocks/p-abcb646d.js +1 -0
- package/dist/sankhyablocks/{p-180716b2.entry.js → p-ae326d06.entry.js} +1 -1
- package/dist/sankhyablocks/p-af673291.js +1 -0
- package/dist/sankhyablocks/p-b555ce38.entry.js +1 -0
- package/dist/sankhyablocks/p-bd2a845c.js +1 -0
- package/dist/sankhyablocks/p-bfce617e.entry.js +1 -0
- package/dist/sankhyablocks/p-c3ec6642.js +19 -0
- package/dist/sankhyablocks/p-c4b34e2b.entry.js +1 -0
- package/dist/sankhyablocks/{p-92cfc028.js → p-c9440c8a.js} +1 -1
- package/dist/sankhyablocks/p-ca3728c0.entry.js +1 -0
- package/dist/sankhyablocks/p-cbb8e351.js +7 -0
- package/dist/sankhyablocks/p-cd153f71.entry.js +1 -0
- package/dist/sankhyablocks/p-ce8ccd72.entry.js +1 -0
- package/dist/sankhyablocks/{p-4c763b10.entry.js → p-d657f71f.entry.js} +1 -1
- package/dist/sankhyablocks/p-da455c82.js +12 -0
- package/dist/sankhyablocks/p-e5a3711f.js +1 -0
- package/dist/sankhyablocks/{p-9a63f3f7.entry.js → p-e737fd5a.entry.js} +1 -1
- package/dist/sankhyablocks/p-eac48627.js +1 -0
- package/dist/sankhyablocks/p-ec7c87bb.js +28 -0
- package/dist/sankhyablocks/p-ee56dda6.entry.js +1 -0
- package/dist/sankhyablocks/{p-667cab42.entry.js → p-f152ef98.entry.js} +1 -1
- package/dist/sankhyablocks/{p-7e250432.entry.js → p-f7170e10.entry.js} +1 -1
- package/dist/sankhyablocks/{p-7345782c.entry.js → p-f921270b.entry.js} +1 -1
- package/dist/sankhyablocks/p-fb6e3c65.entry.js +1 -0
- package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
- package/dist/types/components/snk-actions-button/snk-actions-button.d.ts +4 -0
- package/dist/types/components/snk-application/snk-application.d.ts +1 -1
- package/dist/types/components/snk-attach/snk-attach.d.ts +22 -4
- package/dist/types/components/snk-crud/snk-crud.d.ts +33 -11
- package/dist/types/components/snk-crud/subcomponents/snk-detail-view/snk-detail-view.d.ts +3 -2
- package/dist/types/components/snk-crud/subcomponents/snk-entity-search.d.ts +62 -0
- package/dist/types/components/snk-crud/subcomponents/snk-form-view.d.ts +12 -0
- package/dist/types/components/snk-crud/subcomponents/snk-guides-viewer.d.ts +13 -25
- package/dist/types/components/snk-crud/utils/taskbarUtils.d.ts +13 -0
- package/dist/types/components/snk-custom-slot-guide/snk-custom-slot-guide.d.ts +16 -0
- package/dist/types/components/snk-data-exporter/interfaces/IExporterProvider.d.ts +8 -0
- package/dist/types/components/snk-data-exporter/snk-data-exporter.d.ts +4 -0
- package/dist/types/components/snk-data-exporter/structure/ItemBuilder.d.ts +16 -0
- package/dist/types/components/snk-data-unit/snk-data-unit.d.ts +1 -0
- package/dist/types/components/snk-dynaform/interfaces/PropsCustomEditor.d.ts +4 -0
- package/dist/types/components/snk-dynaform/interfaces/PropsCustomRender.d.ts +4 -0
- package/dist/types/components/snk-dynaform/subcomponents/CardFormResizeObserver.d.ts +1 -0
- package/dist/types/components/snk-dynaform/subcomponents/GuideBuilder.d.ts +14 -0
- package/dist/types/components/snk-dynaform/subcomponents/snk-dynaform-detail-view/snk-dynaform-detail-view.d.ts +169 -0
- package/dist/types/components/snk-dynaform/subcomponents/snk-dynaform-form-view/snk-dynaform-form-view.d.ts +108 -0
- package/dist/types/components/snk-dynaform-form-config/FormConfigHelper.d.ts +36 -0
- package/dist/types/components/snk-dynaform-form-config/SnkFormConfigManager.d.ts +35 -0
- package/dist/types/components/snk-dynaform-form-config/snk-dynaform-config-header/snk-dynaform-config-header.d.ts +23 -0
- package/dist/types/components/snk-dynaform-form-config/snk-dynaform-config-header/snk-dynaform-configs-button/snk-dynaform-configs-button.d.ts +19 -0
- package/dist/types/components/snk-dynaform-form-config/snk-dynaform-field-item/snk-dynaform-field-config/snk-dynaform-field-config.d.ts +56 -0
- package/dist/types/components/snk-dynaform-form-config/snk-dynaform-fields-layout/snk-dynaform-fields-layout.d.ts +74 -0
- package/dist/types/components/snk-dynaform-form-config/snk-dynaform-fields-selector/snk-dynaform-fields-selector.d.ts +21 -0
- package/dist/types/components/snk-dynaform-form-config/snk-dynaform-form-config.d.ts +95 -0
- package/dist/types/components/snk-dynaform-form-config/snk-dynaform-guides-configurator/snk-dynaform-guides-configurator.d.ts +35 -0
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-number.d.ts +1 -1
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-period.d.ts +1 -0
- package/dist/types/components/snk-filter-bar/filter-item/snk-filter-item.d.ts +5 -1
- package/dist/types/components/snk-filter-bar/filter-modal/snk-filter-modal.d.ts +2 -1
- package/dist/types/components/snk-filter-bar/snk-filter-bar.d.ts +33 -16
- package/dist/types/components/snk-form-config/FormConfigHelper.d.ts +1 -1
- package/dist/types/components/snk-form-config/fields-layout/fields-layout.d.ts +2 -2
- package/dist/types/components/snk-form-config/guides-configurator/guides-configurator.d.ts +1 -1
- package/dist/types/components/snk-form-config/snk-form-config.d.ts +2 -1
- package/dist/types/components/snk-grid/snk-grid.d.ts +37 -1
- package/dist/types/components/snk-grid-config/snk-grid-config.d.ts +11 -0
- package/dist/types/components/snk-image-input/snk-image-input.d.ts +57 -0
- package/dist/types/components/snk-image-input/utils/ImageUtils.d.ts +15 -0
- package/dist/types/components/snk-personalized-filter/interfaces/IParameter.d.ts +1 -0
- package/dist/types/components/snk-pesquisa/snk-pesquisa.d.ts +0 -1
- package/dist/types/components/snk-simple-crud/snk-simple-crud.d.ts +4 -1
- package/dist/types/components/snk-taskbar/elements/taskbar-actions-button/taskbar-actions-button.d.ts +6 -0
- package/dist/types/components/snk-taskbar/elements/taskbar-elements.d.ts +29 -2
- package/dist/types/components/snk-taskbar/elements/taskbar-split-button/taskbar-split-button.d.ts +5 -0
- package/dist/types/components/snk-taskbar/processor/simple-taskbar-processor.d.ts +31 -0
- package/dist/types/components/snk-taskbar/snk-taskbar.d.ts +32 -21
- package/dist/types/components/snk-taskbar/subcomponents/snk-taskbar-skeleton.d.ts +3 -0
- package/dist/types/components.d.ts +2638 -1183
- package/dist/types/lib/@types/index.d.ts +6 -0
- package/dist/types/lib/configs/ConfigStorage.d.ts +1 -0
- package/dist/types/lib/http/data-fetcher/fetchers/data-unit/cache/PreloadManager.d.ts +1 -0
- package/dist/types/lib/http/data-fetcher/fetchers/data-unit/dataunit-fetcher.d.ts +2 -1
- package/dist/types/lib/http/data-fetcher/fetchers/data-unit/helpers/DataUnitDataLoaderHelper.d.ts +3 -1
- package/dist/types/lib/http/data-fetcher/fetchers/fetchDataExporter/interfaces/IFetchDataExporterParams.d.ts +2 -0
- package/dist/types/lib/http/data-fetcher/fetchers/form-config-fetcher.d.ts +1 -0
- package/dist/types/lib/http/data-fetcher/fetchers/grid-config-fetcher.d.ts +1 -0
- package/dist/types/lib/http/data-fetcher/fetchers/resource-fetcher.d.ts +1 -0
- package/dist/types/lib/message/resources/en-us/snk-image-input.msg.d.ts +1 -0
- package/dist/types/lib/message/resources/es-es/snk-image-input.msg.d.ts +1 -0
- package/dist/types/lib/message/resources/pt-br/snk-image-input.msg.d.ts +1 -0
- package/package.json +11 -8
- package/react/components.d.ts +16 -0
- package/react/components.js +16 -0
- package/react/components.js.map +1 -1
- package/dist/cjs/default-filters-a09bf82b.js +0 -8
- package/dist/cjs/index-62760a9c.js +0 -49
- package/dist/cjs/index-8d94b7e0.js +0 -7
- package/dist/cjs/snk-attach.cjs.entry.js +0 -910
- package/dist/cjs/snk-default-filter.cjs.entry.js +0 -77
- package/dist/cjs/snk-filter-advanced-mode_2.cjs.entry.js +0 -61
- package/dist/cjs/snk-filter-detail.cjs.entry.js +0 -198
- package/dist/cjs/snk-filter-field-search_2.cjs.entry.js +0 -408
- package/dist/cjs/snk-filter-modal-item.cjs.entry.js +0 -108
- package/dist/cjs/snk-personalized-filter.cjs.entry.js +0 -357
- package/dist/cjs/snk-simple-bar.cjs.entry.js +0 -45
- package/dist/cjs/snk-simple-crud.cjs.entry.js +0 -870
- package/dist/cjs/taskbar-elements-fb5d1e08.js +0 -132
- package/dist/cjs/taskbar-processor-2fba34a8.js +0 -53
- package/dist/esm/default-filters-50105e43.js +0 -8
- package/dist/esm/index-620ac460.js +0 -7
- package/dist/esm/index-8acbae97.js +0 -49
- package/dist/esm/snk-attach.entry.js +0 -906
- package/dist/esm/snk-default-filter.entry.js +0 -73
- package/dist/esm/snk-filter-advanced-mode_2.entry.js +0 -56
- package/dist/esm/snk-filter-detail.entry.js +0 -194
- package/dist/esm/snk-filter-field-search_2.entry.js +0 -403
- package/dist/esm/snk-filter-modal-item.entry.js +0 -104
- package/dist/esm/snk-personalized-filter.entry.js +0 -353
- package/dist/esm/snk-simple-bar.entry.js +0 -41
- package/dist/esm/snk-simple-crud.entry.js +0 -866
- package/dist/esm/taskbar-elements-faaf5d8f.js +0 -129
- package/dist/esm/taskbar-processor-3436124c.js +0 -51
- package/dist/sankhyablocks/p-002d4d2b.js +0 -1
- package/dist/sankhyablocks/p-093f58fa.entry.js +0 -1
- package/dist/sankhyablocks/p-0948dc0a.entry.js +0 -11
- package/dist/sankhyablocks/p-0f3698af.js +0 -1
- package/dist/sankhyablocks/p-1a0caadb.js +0 -1
- package/dist/sankhyablocks/p-1a9c5684.entry.js +0 -1
- package/dist/sankhyablocks/p-1d589380.entry.js +0 -1
- package/dist/sankhyablocks/p-21107f0d.entry.js +0 -1
- package/dist/sankhyablocks/p-28f50632.js +0 -1
- package/dist/sankhyablocks/p-39be771c.js +0 -1
- package/dist/sankhyablocks/p-3ed04f0d.entry.js +0 -1
- package/dist/sankhyablocks/p-471b34f4.entry.js +0 -1
- package/dist/sankhyablocks/p-4963dd2a.entry.js +0 -1
- package/dist/sankhyablocks/p-49ddc27a.entry.js +0 -1
- package/dist/sankhyablocks/p-51833248.js +0 -7
- package/dist/sankhyablocks/p-55798617.js +0 -1
- package/dist/sankhyablocks/p-55f6fef2.entry.js +0 -1
- package/dist/sankhyablocks/p-56f16390.entry.js +0 -1
- package/dist/sankhyablocks/p-58683e28.js +0 -60
- package/dist/sankhyablocks/p-5ea893c5.entry.js +0 -1
- package/dist/sankhyablocks/p-60dd1d27.entry.js +0 -1
- package/dist/sankhyablocks/p-62aef37a.js +0 -1
- package/dist/sankhyablocks/p-669bb869.entry.js +0 -1
- package/dist/sankhyablocks/p-6a4b21dd.js +0 -1
- package/dist/sankhyablocks/p-6ee2ca7a.entry.js +0 -1
- package/dist/sankhyablocks/p-7cac3870.entry.js +0 -1
- package/dist/sankhyablocks/p-84345e7a.js +0 -1
- package/dist/sankhyablocks/p-86e54841.entry.js +0 -1
- package/dist/sankhyablocks/p-88b337fe.entry.js +0 -1
- package/dist/sankhyablocks/p-91005a00.entry.js +0 -1
- package/dist/sankhyablocks/p-91a9abb6.entry.js +0 -1
- package/dist/sankhyablocks/p-988afe78.js +0 -1
- package/dist/sankhyablocks/p-ada013c0.entry.js +0 -1
- package/dist/sankhyablocks/p-b568c1d4.js +0 -1
- package/dist/sankhyablocks/p-b7e891cc.entry.js +0 -1
- package/dist/sankhyablocks/p-b987e15d.js +0 -1
- package/dist/sankhyablocks/p-c35fc941.js +0 -26
- package/dist/sankhyablocks/p-c3dbf441.entry.js +0 -1
- package/dist/sankhyablocks/p-c4fcf1fb.entry.js +0 -1
- package/dist/sankhyablocks/p-c98c79c3.entry.js +0 -1
- package/dist/sankhyablocks/p-cadf4846.entry.js +0 -1
- package/dist/sankhyablocks/p-d8d8169b.js +0 -2
- package/dist/sankhyablocks/p-e91c3c57.entry.js +0 -1
- package/dist/sankhyablocks/p-ea729922.entry.js +0 -1
- package/dist/sankhyablocks/p-ec5fbad8.js +0 -1
- package/dist/sankhyablocks/p-f4184ce7.js +0 -1
|
@@ -0,0 +1,961 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-1894343a.js');
|
|
6
|
+
const core = require('@sankhyalabs/core');
|
|
7
|
+
const snkDynaformGuidesView = require('./snk-dynaform-guides-view-2c7c6ce4.js');
|
|
8
|
+
const form = require('@sankhyalabs/ezui/dist/collection/utils/form');
|
|
9
|
+
const DataFetcher = require('./DataFetcher-d13b4637.js');
|
|
10
|
+
require('./ISave-55d9dcc3.js');
|
|
11
|
+
const index$1 = require('./index-bc950921.js');
|
|
12
|
+
require('@sankhyalabs/ezui/dist/collection/utils/constants');
|
|
13
|
+
require('@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata');
|
|
14
|
+
require('./dataunit-fetcher-fae710c5.js');
|
|
15
|
+
require('./filter-item-type.enum-a7ffdaa6.js');
|
|
16
|
+
const formConfigFetcher = require('./form-config-fetcher-bbebdcb8.js');
|
|
17
|
+
const constants = require('./constants-6d82e405.js');
|
|
18
|
+
const taskbarElements = require('./taskbar-elements-25f800b3.js');
|
|
19
|
+
const utils = require('@sankhyalabs/ezui/dist/collection/utils');
|
|
20
|
+
const taskbarUtils = require('./taskbarUtils-99aaa01f.js');
|
|
21
|
+
const FormConfigHelper = require('./FormConfigHelper-c5f5473a.js');
|
|
22
|
+
require('./ConfigStorage-156bfcac.js');
|
|
23
|
+
require('./PrintUtils-bcaeb82f.js');
|
|
24
|
+
require('@sankhyalabs/ezui/dist/collection/components/ez-grid/utils');
|
|
25
|
+
require('@sankhyalabs/core/dist/utils/SortingUtils');
|
|
26
|
+
require('./ResourceIDUtils-5ff86aa7.js');
|
|
27
|
+
require('./index-f0fe7e6e.js');
|
|
28
|
+
|
|
29
|
+
const snkDynaformDetailViewCss = ".sc-snk-dynaform-detail-view-h{display:flex;row-gap:24px;flex-direction:column;width:100%;height:100%;overflow-x:hidden;overflow-y:auto;padding:var(--space--4, 4px);scrollbar-width:auto;scrollbar-color:var(--color--strokes, #E1E2E5) transparent}.sc-snk-dynaform-detail-view-h::-webkit-scrollbar{width:var(--space--14, 14px);height:var(--space--14, 14px)}.sc-snk-dynaform-detail-view-h::-webkit-scrollbar-track{background:transparent}.sc-snk-dynaform-detail-view-h::-webkit-scrollbar-thumb{background-color:var(--color--strokes, #E1E2E5);border-radius:var(--border--radius-100, 100px);border:2px solid transparent;background-clip:padding-box}.sc-snk-dynaform-detail-view-h::-webkit-scrollbar-thumb:hover{background-color:var(--color--petroleum-100, #C8CCD3);background-clip:padding-box}.sc-snk-dynaform-detail-view-h::-webkit-scrollbar-corner{background:transparent}.level-path.sc-snk-dynaform-detail-view{color:var(--color--title-primary, #2B3A54);font-weight:var(--text-weight--medium, 400);padding-right:3px}.grid-container.sc-snk-dynaform-detail-view{min-height:100px;height:100%;width:100%;display:flex;flex-wrap:wrap;text-decoration:none;border-radius:var(--border--radius-medium);background-color:var(--color--gray-70, #FFFFFF);border:1px solid var(--color--petroleum-100, #C8CCD3)}.detail-header.sc-snk-dynaform-detail-view{padding-bottom:0}snk-data-unit.sc-snk-dynaform-detail-view{flex:1;min-height:0;gap:var(--space--12, 12px);display:flex;flex-direction:column}snk-data-unit.sc-snk-dynaform-detail-view ez-view-stack.sc-snk-dynaform-detail-view{flex:1;min-height:0}snk-grid.sc-snk-dynaform-detail-view{height:100%;--snk-grid-margin:0px;--snk-grid-box-shadow:none;--snk-grid-min-height:135px}.form-and-detail-container.sc-snk-dynaform-detail-view>ez-tabselector.sc-snk-dynaform-detail-view{flex-shrink:0}.form-and-detail-container.sc-snk-dynaform-detail-view{display:flex;flex-direction:column;height:100%;width:100%;overflow:auto;padding:var(--space--12, 12px);scrollbar-width:auto;scrollbar-color:var(--color--strokes, #E1E2E5) transparent}.form-and-detail-container.sc-snk-dynaform-detail-view::-webkit-scrollbar{width:var(--space--14, 14px);height:var(--space--14, 14px)}.form-and-detail-container.sc-snk-dynaform-detail-view::-webkit-scrollbar-track{background:transparent}.form-and-detail-container.sc-snk-dynaform-detail-view::-webkit-scrollbar-thumb{background-color:var(--color--strokes, #E1E2E5);border-radius:var(--border--radius-100, 100px);border:2px solid transparent;background-clip:padding-box}.form-and-detail-container.sc-snk-dynaform-detail-view::-webkit-scrollbar-thumb:hover{background-color:var(--color--petroleum-100, #C8CCD3);background-clip:padding-box}.form-and-detail-container.sc-snk-dynaform-detail-view::-webkit-scrollbar-corner{background:transparent}.ez-tabselector-internal.sc-snk-dynaform-detail-view{margin:var(--space--8, 8px) 0}.selected-record-header.sc-snk-dynaform-detail-view{display:flex;align-items:center;flex-wrap:wrap;gap:var(--space--8, 8px) var(--space--12, 12px);padding:var(--space--12, 12px) var(--space--16, 16px);margin-bottom:var(--space--12, 12px);background:var(--color--gray-80, #F9F9F9);border-radius:var(--border--radius-12, 12px);font-family:var(--font--pattern);border:1px solid var(--color--petroleum-100, #C8CCD3);border-left:4px solid var(--color--ocean-green-500, #00B07E)}.selected-record-header--message.sc-snk-dynaform-detail-view{border-left-color:var(--color--primary, #007EFF)}.selected-record-header__message.sc-snk-dynaform-detail-view{font-size:var(--font-size--default, 14px);font-weight:var(--font-weight--medium, 500);color:var(--color--title-primary, #2B3A54)}.selected-record-header__chip.sc-snk-dynaform-detail-view{display:inline-flex;flex-direction:row;align-items:center;gap:var(--space--4, 4px);min-width:0}.selected-record-header__label.sc-snk-dynaform-detail-view{font-size:var(--font-size--xs, 11px);font-weight:var(--font-weight--medium, 500);text-transform:uppercase;letter-spacing:0.04em;color:var(--color--text-secondary, #6E7A8A)}.selected-record-header__value.sc-snk-dynaform-detail-view{font-size:var(--font-size--md, 15px);font-weight:var(--font-weight--semibold, 600);color:var(--color--ocean-green-1000, #00281D);line-height:1.2;word-break:break-word}.selected-record-header__separator.sc-snk-dynaform-detail-view{display:inline-block;align-self:stretch;width:1px;background:var(--color--petroleum-100, #C8CCD3);margin:0 var(--space--4, 4px)}";
|
|
30
|
+
|
|
31
|
+
const SnkDynaformDetailView = class {
|
|
32
|
+
constructor(hostRef) {
|
|
33
|
+
index.registerInstance(this, hostRef);
|
|
34
|
+
this._taskbarProcessor = new taskbarUtils.SimpleTaskbarProcessor(taskbarUtils.DEFAULT_TASKBAR_BUTTONS);
|
|
35
|
+
/** Evita repetir a carga inicial da grade no mesmo mount da aba. */
|
|
36
|
+
this._didInitialLoad = false;
|
|
37
|
+
this._currentView = 0;
|
|
38
|
+
this.attachmentRegisterKey = undefined;
|
|
39
|
+
this._fieldToGetFocus = undefined;
|
|
40
|
+
this._hasToCreateFieldSearch = true;
|
|
41
|
+
this._selectedSheet = undefined;
|
|
42
|
+
this._internalErrorTabs = new Set();
|
|
43
|
+
this._selectedRecordPKDisplay = undefined;
|
|
44
|
+
this.formConfigManager = undefined;
|
|
45
|
+
this.dataUnitName = undefined;
|
|
46
|
+
this.resourceID = undefined;
|
|
47
|
+
this.entityName = undefined;
|
|
48
|
+
this.label = undefined;
|
|
49
|
+
this.dataUnit = undefined;
|
|
50
|
+
this.selectedForm = undefined;
|
|
51
|
+
this.dataState = undefined;
|
|
52
|
+
this.messagesBuilder = undefined;
|
|
53
|
+
this.canEdit = true;
|
|
54
|
+
this.taskbarCustomContainerId = undefined;
|
|
55
|
+
this.customEditors = undefined;
|
|
56
|
+
this.customRenders = undefined;
|
|
57
|
+
this.presentationMode = index$1.PresentationMode.SECONDARY;
|
|
58
|
+
}
|
|
59
|
+
observeDataUnit(newDataUnit, oldDataUnit) {
|
|
60
|
+
newDataUnit === null || newDataUnit === void 0 ? void 0 : newDataUnit.subscribe(this.dataUnitActionHandler.bind(this));
|
|
61
|
+
oldDataUnit === null || oldDataUnit === void 0 ? void 0 : oldDataUnit.unsubscribe(this.dataUnitActionHandler);
|
|
62
|
+
}
|
|
63
|
+
observerDataState(newValue, oldValue) {
|
|
64
|
+
const openInsertion = !(oldValue === null || oldValue === void 0 ? void 0 : oldValue.insertionMode) && (newValue === null || newValue === void 0 ? void 0 : newValue.insertionMode);
|
|
65
|
+
const closeInsertion = (oldValue === null || oldValue === void 0 ? void 0 : oldValue.insertionMode) && !(newValue === null || newValue === void 0 ? void 0 : newValue.insertionMode);
|
|
66
|
+
if (openInsertion || closeInsertion) {
|
|
67
|
+
this.loadMetadata();
|
|
68
|
+
}
|
|
69
|
+
if (this._formMetadata == undefined) {
|
|
70
|
+
return;
|
|
71
|
+
}
|
|
72
|
+
if (!this.selectedSheetIsDetail()) {
|
|
73
|
+
if (openInsertion) {
|
|
74
|
+
setTimeout(() => {
|
|
75
|
+
this.changeViewMode(constants.VIEW_MODE.FORM);
|
|
76
|
+
}, 0);
|
|
77
|
+
}
|
|
78
|
+
if (closeInsertion) {
|
|
79
|
+
this.changeViewMode(constants.VIEW_MODE.GRID);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Muda o modo de visualização do componente entre VIEW_MODE.GRID e VIEW_MODE.FORM
|
|
85
|
+
* @param mode - Novo modo que o componente deve ser apresentado.
|
|
86
|
+
*/
|
|
87
|
+
async changeViewMode(mode) {
|
|
88
|
+
if (!this._viewStack) {
|
|
89
|
+
return;
|
|
90
|
+
}
|
|
91
|
+
this._viewStack.show(mode);
|
|
92
|
+
this._currentView = mode;
|
|
93
|
+
}
|
|
94
|
+
/**
|
|
95
|
+
* Abre o configurador de grid.
|
|
96
|
+
*/
|
|
97
|
+
async configGrid() {
|
|
98
|
+
if (this._snkGrid) {
|
|
99
|
+
this._snkGrid.showConfig();
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
async showUp() {
|
|
103
|
+
if (this._snkFormView) {
|
|
104
|
+
this._snkFormView.showUp();
|
|
105
|
+
}
|
|
106
|
+
if (this._snkGrid) {
|
|
107
|
+
this._snkGrid.scrollIntoView({ behavior: "smooth", block: "start" });
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
/**
|
|
111
|
+
* Registra um editor customizado para campos da grade e formulário.
|
|
112
|
+
*/
|
|
113
|
+
async addCustomEditor(fieldName, customEditor) {
|
|
114
|
+
var _a, _b;
|
|
115
|
+
const detailContext = this.normalizeDataUnitName();
|
|
116
|
+
(_a = this._snkGrid) === null || _a === void 0 ? void 0 : _a.addCustomEditor(fieldName, customEditor, detailContext);
|
|
117
|
+
(_b = this._snkFormView) === null || _b === void 0 ? void 0 : _b.addCustomEditor(fieldName, customEditor, detailContext);
|
|
118
|
+
}
|
|
119
|
+
async observerPropsCustomEditor(newValue) {
|
|
120
|
+
for (const fieldName in newValue) {
|
|
121
|
+
await this.addCustomEditor(fieldName, newValue[fieldName]);
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* Registra um render customizado para colunas da grid.
|
|
126
|
+
*/
|
|
127
|
+
async addGridCustomRender(fieldName, customRender) {
|
|
128
|
+
var _a;
|
|
129
|
+
const detailContext = this.normalizeDataUnitName();
|
|
130
|
+
await ((_a = this._snkGrid) === null || _a === void 0 ? void 0 : _a.addGridCustomRender(fieldName, customRender, detailContext));
|
|
131
|
+
}
|
|
132
|
+
onContentCardChanged(evt) {
|
|
133
|
+
snkDynaformGuidesView.SnkDynaformGuidesViewer.updateContentCard(evt.detail.formName, evt.detail.cardConfig, evt.detail.propertyChanged, this.formConfigManager).then(() => index.forceUpdate(this));
|
|
134
|
+
evt.stopPropagation();
|
|
135
|
+
}
|
|
136
|
+
async observeCustomRenders(newValue) {
|
|
137
|
+
for (const field in newValue) {
|
|
138
|
+
const customRender = newValue[field];
|
|
139
|
+
await this.addGridCustomRender(field, customRender);
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
loadMetadata() {
|
|
143
|
+
if (!this.dataUnit || !this.formConfigManager) {
|
|
144
|
+
return;
|
|
145
|
+
}
|
|
146
|
+
if (!this.formConfigManager.isLoaded) {
|
|
147
|
+
return;
|
|
148
|
+
}
|
|
149
|
+
const formConfig = this.formConfigManager.getConfig(this.dataUnit);
|
|
150
|
+
this._formMetadata = form.buildFormMetadata(formConfig == undefined || formConfig.fields.length === 0 ? undefined : formConfig, this.dataUnit, true);
|
|
151
|
+
this.initSelectedSheet();
|
|
152
|
+
}
|
|
153
|
+
initSelectedSheet() {
|
|
154
|
+
if (!this._formMetadata) {
|
|
155
|
+
this._selectedSheet = undefined;
|
|
156
|
+
return;
|
|
157
|
+
}
|
|
158
|
+
const sheets = this._formMetadata.getAllSheets();
|
|
159
|
+
if (!sheets || sheets.size === 0) {
|
|
160
|
+
this._selectedSheet = undefined;
|
|
161
|
+
return;
|
|
162
|
+
}
|
|
163
|
+
// Mantém a aba atual caso ela ainda exista e não seja a área principal.
|
|
164
|
+
if (this._selectedSheet && this._selectedSheet.name !== SnkDynaformDetailView.MAIN_TAB) {
|
|
165
|
+
const current = sheets.get(this._selectedSheet.name);
|
|
166
|
+
if (current) {
|
|
167
|
+
this._selectedSheet = current;
|
|
168
|
+
return;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
// Caso contrário, seleciona o primeiro sheet que não seja a área principal (primeira aba).
|
|
172
|
+
this._selectedSheet = this.getFirstNonMainSheet(sheets);
|
|
173
|
+
}
|
|
174
|
+
getFirstNonMainSheet(sheets) {
|
|
175
|
+
for (const [name, sheet] of sheets) {
|
|
176
|
+
if (name !== SnkDynaformDetailView.MAIN_TAB) {
|
|
177
|
+
return sheet;
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
return undefined;
|
|
181
|
+
}
|
|
182
|
+
dataUnitReadyHandler(evt) {
|
|
183
|
+
this.dataUnit = evt.detail;
|
|
184
|
+
this.loadMetadata();
|
|
185
|
+
this.ensureInitialLoad();
|
|
186
|
+
}
|
|
187
|
+
/**
|
|
188
|
+
* Dispara a carga inicial da grade quando a aba é montada com o master já
|
|
189
|
+
* selecionado. A carga do filho normalmente é disparada pelo evento de troca
|
|
190
|
+
* de seleção do master; uma aba montada tardiamente (aberta depois que o
|
|
191
|
+
* registro master já estava selecionado) não recebe esse evento e ficaria
|
|
192
|
+
* vazia até um refresh manual. Navegações seguintes do master continuam
|
|
193
|
+
* recarregando pela assinatura existente do DataUnit.
|
|
194
|
+
*/
|
|
195
|
+
ensureInitialLoad() {
|
|
196
|
+
var _a, _b, _c, _d, _e;
|
|
197
|
+
if (this._didInitialLoad) {
|
|
198
|
+
return;
|
|
199
|
+
}
|
|
200
|
+
const dataUnit = this.dataUnit;
|
|
201
|
+
const parentDataUnit = (_a = dataUnit === null || dataUnit === void 0 ? void 0 : dataUnit.getParentDataUnit) === null || _a === void 0 ? void 0 : _a.call(dataUnit);
|
|
202
|
+
if (((_b = parentDataUnit === null || parentDataUnit === void 0 ? void 0 : parentDataUnit.getSelectedRecord) === null || _b === void 0 ? void 0 : _b.call(parentDataUnit)) && ((_d = (_c = dataUnit === null || dataUnit === void 0 ? void 0 : dataUnit.records) === null || _c === void 0 ? void 0 : _c.length) !== null && _d !== void 0 ? _d : 0) === 0) {
|
|
203
|
+
this._didInitialLoad = true;
|
|
204
|
+
(_e = dataUnit === null || dataUnit === void 0 ? void 0 : dataUnit.loadData) === null || _e === void 0 ? void 0 : _e.call(dataUnit);
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
getFormFields() {
|
|
208
|
+
var _a, _b, _c;
|
|
209
|
+
const mainSheet = (_b = (_a = this._formMetadata) === null || _a === void 0 ? void 0 : _a.getAllSheets()) === null || _b === void 0 ? void 0 : _b.get(SnkDynaformDetailView.MAIN_TAB);
|
|
210
|
+
return (_c = mainSheet === null || mainSheet === void 0 ? void 0 : mainSheet.fields) !== null && _c !== void 0 ? _c : [];
|
|
211
|
+
}
|
|
212
|
+
hasNonMainSheets() {
|
|
213
|
+
if (!this._formMetadata) {
|
|
214
|
+
return false;
|
|
215
|
+
}
|
|
216
|
+
for (const name of this._formMetadata.getAllSheets().keys()) {
|
|
217
|
+
if (name !== SnkDynaformDetailView.MAIN_TAB) {
|
|
218
|
+
return true;
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
return false;
|
|
222
|
+
}
|
|
223
|
+
selectedSheetIsDetail() {
|
|
224
|
+
return !!this._selectedSheet && form.FormMetadata.getDetailName(this._selectedSheet.name) != undefined;
|
|
225
|
+
}
|
|
226
|
+
isSheetDisabled(sheet) {
|
|
227
|
+
var _a;
|
|
228
|
+
if (form.FormMetadata.getDetailName(sheet.name) == undefined) {
|
|
229
|
+
return false;
|
|
230
|
+
}
|
|
231
|
+
const currentRecord = (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getSelectedRecord();
|
|
232
|
+
if (!currentRecord || !this.dataUnit) {
|
|
233
|
+
return true;
|
|
234
|
+
}
|
|
235
|
+
return this.dataUnit.isNewRecord(currentRecord.__record__id__) || this.dataUnit.isMultipleEdition;
|
|
236
|
+
}
|
|
237
|
+
buildInternalTabItems() {
|
|
238
|
+
if (!this._formMetadata) {
|
|
239
|
+
return [];
|
|
240
|
+
}
|
|
241
|
+
const sheets = Array.from(this._formMetadata.getAllSheets().values());
|
|
242
|
+
const nonMainSheets = sheets.filter((sheet) => sheet.name !== SnkDynaformDetailView.MAIN_TAB);
|
|
243
|
+
return nonMainSheets.map((sheet, index) => ({
|
|
244
|
+
tabKey: sheet.name,
|
|
245
|
+
label: sheet.label,
|
|
246
|
+
index,
|
|
247
|
+
disabled: this.isSheetDisabled(sheet),
|
|
248
|
+
rightIcon: this._internalErrorTabs.has(sheet.name) ? 'alert-circle-inverted' : undefined,
|
|
249
|
+
}));
|
|
250
|
+
}
|
|
251
|
+
onInternalTabChange(tab) {
|
|
252
|
+
var _a, _b;
|
|
253
|
+
// A área principal (__main) é sempre visível e não é uma aba selecionável.
|
|
254
|
+
if (tab.tabKey === SnkDynaformDetailView.MAIN_TAB) {
|
|
255
|
+
return;
|
|
256
|
+
}
|
|
257
|
+
const matchedSheet = (_b = (_a = this._formMetadata) === null || _a === void 0 ? void 0 : _a.getAllSheets()) === null || _b === void 0 ? void 0 : _b.get(tab.tabKey);
|
|
258
|
+
if (!matchedSheet || this.isSheetDisabled(matchedSheet)) {
|
|
259
|
+
return;
|
|
260
|
+
}
|
|
261
|
+
this._selectedSheet = matchedSheet;
|
|
262
|
+
}
|
|
263
|
+
executeActionHandler(evt) {
|
|
264
|
+
var _a;
|
|
265
|
+
if (evt.detail === taskbarElements.TaskbarElement.GRID_MODE) {
|
|
266
|
+
this.changeViewMode(constants.VIEW_MODE.GRID);
|
|
267
|
+
evt.stopPropagation();
|
|
268
|
+
}
|
|
269
|
+
if (evt.detail === taskbarElements.TaskbarElement.UPDATE_MULTIPLE && this.dataUnit) {
|
|
270
|
+
this.dataUnit.isMultipleEdition = true;
|
|
271
|
+
this.changeViewMode(constants.VIEW_MODE.FORM);
|
|
272
|
+
evt.stopPropagation();
|
|
273
|
+
}
|
|
274
|
+
if (evt.detail === taskbarElements.TaskbarElement.FORM_MODE || evt.detail === taskbarElements.TaskbarElement.UPDATE || evt.detail === taskbarElements.TaskbarElement.INSERT) {
|
|
275
|
+
this.changeViewMode(constants.VIEW_MODE.FORM);
|
|
276
|
+
evt.stopPropagation();
|
|
277
|
+
}
|
|
278
|
+
if (evt.detail === taskbarElements.TaskbarElement.ATTACH) {
|
|
279
|
+
(_a = this._snkAttach) === null || _a === void 0 ? void 0 : _a.open();
|
|
280
|
+
evt.stopPropagation();
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
async getAttachmentRegisterKey() {
|
|
284
|
+
if (!this._snkDataUnit) {
|
|
285
|
+
return;
|
|
286
|
+
}
|
|
287
|
+
const recordCriteria = await this._snkDataUnit.getSelectedRecordsIDsInfo();
|
|
288
|
+
const joinedPrimaryKeys = recordCriteria.map(({ value }) => value).join('_');
|
|
289
|
+
return joinedPrimaryKeys;
|
|
290
|
+
}
|
|
291
|
+
async handleDataStateChange({ detail: dataState }) {
|
|
292
|
+
var _a;
|
|
293
|
+
this.dataState = dataState;
|
|
294
|
+
if (dataState.selectedRecord !== undefined && this._snkDataUnit) {
|
|
295
|
+
this.attachmentRegisterKey = (_a = await this.getAttachmentRegisterKey()) !== null && _a !== void 0 ? _a : undefined;
|
|
296
|
+
}
|
|
297
|
+
this._selectedRecordPKDisplay = this.buildSelectedRecordPKDisplay();
|
|
298
|
+
}
|
|
299
|
+
buildSelectedRecordPKDisplay() {
|
|
300
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
301
|
+
if (!this.dataUnit) {
|
|
302
|
+
return undefined;
|
|
303
|
+
}
|
|
304
|
+
if ((_a = this.dataState) === null || _a === void 0 ? void 0 : _a.insertionMode) {
|
|
305
|
+
const message = (_b = this.messagesBuilder) === null || _b === void 0 ? void 0 : _b.getMessage("snkCrud.newRecord");
|
|
306
|
+
return message ? { message } : undefined;
|
|
307
|
+
}
|
|
308
|
+
const selectedRecord = this.dataUnit.getSelectedRecord();
|
|
309
|
+
if (!selectedRecord) {
|
|
310
|
+
return undefined;
|
|
311
|
+
}
|
|
312
|
+
const items = [];
|
|
313
|
+
const fields = (_d = (_c = this.dataUnit.metadata) === null || _c === void 0 ? void 0 : _c.fields) !== null && _d !== void 0 ? _d : [];
|
|
314
|
+
for (const field of fields) {
|
|
315
|
+
if (((_e = field.properties) === null || _e === void 0 ? void 0 : _e.isPrimaryKey) !== "true") {
|
|
316
|
+
continue;
|
|
317
|
+
}
|
|
318
|
+
const rawValue = selectedRecord[field.name];
|
|
319
|
+
const value = (_f = rawValue === null || rawValue === void 0 ? void 0 : rawValue.value) !== null && _f !== void 0 ? _f : rawValue;
|
|
320
|
+
if (value === undefined || value === null || value === "") {
|
|
321
|
+
continue;
|
|
322
|
+
}
|
|
323
|
+
items.push({ label: (_g = field.label) !== null && _g !== void 0 ? _g : field.name, value: String(value) });
|
|
324
|
+
}
|
|
325
|
+
return items.length ? { items } : undefined;
|
|
326
|
+
}
|
|
327
|
+
renderSelectedRecordHeader() {
|
|
328
|
+
var _a;
|
|
329
|
+
if (!this.label && !this._selectedRecordPKDisplay) {
|
|
330
|
+
return undefined;
|
|
331
|
+
}
|
|
332
|
+
const display = this._selectedRecordPKDisplay;
|
|
333
|
+
if (!display) {
|
|
334
|
+
return undefined;
|
|
335
|
+
}
|
|
336
|
+
if (display.message) {
|
|
337
|
+
return (index.h("div", { class: "selected-record-header selected-record-header--message" }, index.h("span", { class: "selected-record-header__message" }, display.message)));
|
|
338
|
+
}
|
|
339
|
+
if (!((_a = display.items) === null || _a === void 0 ? void 0 : _a.length)) {
|
|
340
|
+
return undefined;
|
|
341
|
+
}
|
|
342
|
+
return (index.h("div", { class: "selected-record-header", role: "group" }, display.items.map((item, index$1) => [
|
|
343
|
+
index$1 > 0 && index.h("span", { class: "selected-record-header__separator", "aria-hidden": "true" }),
|
|
344
|
+
index.h("div", { class: "selected-record-header__chip" }, index.h("span", { class: "selected-record-header__label" }, item.label, ":"), index.h("span", { class: "selected-record-header__value" }, item.value))
|
|
345
|
+
])));
|
|
346
|
+
}
|
|
347
|
+
componentWillLoad() {
|
|
348
|
+
var _a;
|
|
349
|
+
this._configName = `dynaform.${this.entityName}`;
|
|
350
|
+
this.formConfigManager = new snkDynaformGuidesView.SnkFormConfigManager(this._configName, (_a = this.resourceID) !== null && _a !== void 0 ? _a : '', () => this.loadMetadata(), this.dataUnit);
|
|
351
|
+
this.formConfigManager.loadConfig();
|
|
352
|
+
if (this.messagesBuilder == undefined) {
|
|
353
|
+
this.messagesBuilder = new DataFetcher.SnkMessageBuilder(this.entityName);
|
|
354
|
+
}
|
|
355
|
+
}
|
|
356
|
+
componentWillRender() {
|
|
357
|
+
this.initializeTaskbarProcessor();
|
|
358
|
+
}
|
|
359
|
+
initializeTaskbarProcessor() {
|
|
360
|
+
if (!this.dataState) {
|
|
361
|
+
return;
|
|
362
|
+
}
|
|
363
|
+
const detailTaskbarManager = this.buildDetailTaskbarManager();
|
|
364
|
+
const topTaskbarId = taskbarUtils.getTopTaskBarId(this.dataState, this.presentationMode);
|
|
365
|
+
this._taskbarProcessor.process(topTaskbarId, detailTaskbarManager, this.dataState, [], []);
|
|
366
|
+
}
|
|
367
|
+
buildDetailTaskbarManager() {
|
|
368
|
+
const EDITION_MODE_BUTTONS = [
|
|
369
|
+
taskbarElements.TaskbarElement.CANCEL,
|
|
370
|
+
taskbarElements.TaskbarElement.SAVE,
|
|
371
|
+
];
|
|
372
|
+
const currentView = this._currentView;
|
|
373
|
+
return {
|
|
374
|
+
getButtons: (taskbarID, dataState, defaultButtons) => {
|
|
375
|
+
var _a, _b, _c;
|
|
376
|
+
if (!taskbarID) {
|
|
377
|
+
return [];
|
|
378
|
+
}
|
|
379
|
+
const isInEditionMode = (dataState === null || dataState === void 0 ? void 0 : dataState.insertionMode) || (dataState === null || dataState === void 0 ? void 0 : dataState.isDirty);
|
|
380
|
+
if (isInEditionMode) {
|
|
381
|
+
return EDITION_MODE_BUTTONS;
|
|
382
|
+
}
|
|
383
|
+
let buttons = [...defaultButtons];
|
|
384
|
+
if (currentView === constants.VIEW_MODE.FORM) {
|
|
385
|
+
const indexFormMode = buttons.indexOf(taskbarElements.TaskbarElement.FORM_MODE);
|
|
386
|
+
if (indexFormMode > -1) {
|
|
387
|
+
buttons = [
|
|
388
|
+
...buttons.slice(0, indexFormMode),
|
|
389
|
+
taskbarElements.TaskbarElement.GRID_MODE,
|
|
390
|
+
...buttons.slice(indexFormMode + 1),
|
|
391
|
+
];
|
|
392
|
+
}
|
|
393
|
+
}
|
|
394
|
+
if (((_c = (_b = (_a = dataState === null || dataState === void 0 ? void 0 : dataState.selectionInfo) === null || _a === void 0 ? void 0 : _a.records) === null || _b === void 0 ? void 0 : _b.length) !== null && _c !== void 0 ? _c : 0) > 1) {
|
|
395
|
+
const indexUpdate = buttons.indexOf(taskbarElements.TaskbarElement.UPDATE);
|
|
396
|
+
if (indexUpdate > -1) {
|
|
397
|
+
buttons = [
|
|
398
|
+
...buttons.slice(0, indexUpdate),
|
|
399
|
+
taskbarElements.TaskbarElement.UPDATE_MULTIPLE,
|
|
400
|
+
...buttons.slice(indexUpdate + 1),
|
|
401
|
+
];
|
|
402
|
+
}
|
|
403
|
+
}
|
|
404
|
+
return buttons;
|
|
405
|
+
},
|
|
406
|
+
isEnabled: (_, dataState, buttonName, originalValue) => {
|
|
407
|
+
if (!dataState) {
|
|
408
|
+
return originalValue;
|
|
409
|
+
}
|
|
410
|
+
const hasSelectedRecord = dataState.selectedRecord !== undefined;
|
|
411
|
+
const buttonsRequiringSelection = [
|
|
412
|
+
taskbarElements.TaskbarElement.UPDATE,
|
|
413
|
+
taskbarElements.TaskbarElement.REMOVE,
|
|
414
|
+
taskbarElements.TaskbarElement.ATTACH,
|
|
415
|
+
taskbarElements.TaskbarElement.CLONE,
|
|
416
|
+
];
|
|
417
|
+
if (!hasSelectedRecord && buttonsRequiringSelection.includes(buttonName)) {
|
|
418
|
+
return false;
|
|
419
|
+
}
|
|
420
|
+
if (buttonName === taskbarElements.TaskbarElement.PREVIOUS && !dataState.hasPrevious) {
|
|
421
|
+
return false;
|
|
422
|
+
}
|
|
423
|
+
if (buttonName === taskbarElements.TaskbarElement.NEXT && !dataState.hasNext) {
|
|
424
|
+
return false;
|
|
425
|
+
}
|
|
426
|
+
if (buttonName === taskbarElements.TaskbarElement.INSERT && dataState.insertionMode) {
|
|
427
|
+
return false;
|
|
428
|
+
}
|
|
429
|
+
return originalValue;
|
|
430
|
+
},
|
|
431
|
+
};
|
|
432
|
+
}
|
|
433
|
+
async componentDidLoad() {
|
|
434
|
+
if (this.customEditors) {
|
|
435
|
+
await this.observerPropsCustomEditor(this.customEditors);
|
|
436
|
+
}
|
|
437
|
+
if (this.customRenders) {
|
|
438
|
+
await this.observeCustomRenders(this.customRenders);
|
|
439
|
+
}
|
|
440
|
+
this.initKeyboardManager();
|
|
441
|
+
}
|
|
442
|
+
disconnectedCallback() {
|
|
443
|
+
var _a;
|
|
444
|
+
(_a = this._keyboardManager) === null || _a === void 0 ? void 0 : _a.unbindAllShortcutKeys();
|
|
445
|
+
}
|
|
446
|
+
async dataUnitActionHandler(action) {
|
|
447
|
+
var _a;
|
|
448
|
+
if (action.type === core.Action.FIELD_INVALIDATED) {
|
|
449
|
+
const sheetName = this.findSheetOfField((_a = action.payload) === null || _a === void 0 ? void 0 : _a.fieldName);
|
|
450
|
+
if (sheetName) {
|
|
451
|
+
this._internalErrorTabs = new Set([...this._internalErrorTabs, sheetName]);
|
|
452
|
+
}
|
|
453
|
+
}
|
|
454
|
+
}
|
|
455
|
+
findSheetOfField(fieldName) {
|
|
456
|
+
var _a;
|
|
457
|
+
if (!fieldName || !this._formMetadata) {
|
|
458
|
+
return undefined;
|
|
459
|
+
}
|
|
460
|
+
const sheets = this._formMetadata.getAllSheets();
|
|
461
|
+
for (const [sheetName, sheet] of sheets) {
|
|
462
|
+
if ((_a = sheet.fields) === null || _a === void 0 ? void 0 : _a.some((f) => f.name === fieldName)) {
|
|
463
|
+
return sheetName;
|
|
464
|
+
}
|
|
465
|
+
}
|
|
466
|
+
return undefined;
|
|
467
|
+
}
|
|
468
|
+
normalizeDataUnitName() {
|
|
469
|
+
var _a, _b;
|
|
470
|
+
return (_b = (_a = this.dataUnitName) === null || _a === void 0 ? void 0 : _a.replace(/\//g, '>')) !== null && _b !== void 0 ? _b : '';
|
|
471
|
+
}
|
|
472
|
+
getSettingsListForm() {
|
|
473
|
+
var _a, _b;
|
|
474
|
+
const hardList = [{
|
|
475
|
+
value: core.StringUtils.generateUUID(),
|
|
476
|
+
label: (_b = (_a = this.messagesBuilder) === null || _a === void 0 ? void 0 : _a.getMessage("snkCrud.findColumn", undefined)) !== null && _b !== void 0 ? _b : "",
|
|
477
|
+
disableCloseOnSelect: true,
|
|
478
|
+
eagerInitialize: true,
|
|
479
|
+
itemBuilder: (_, item) => this.getFieldsSearch(item)
|
|
480
|
+
}];
|
|
481
|
+
return hardList;
|
|
482
|
+
}
|
|
483
|
+
getFieldsSearch(item) {
|
|
484
|
+
var _a;
|
|
485
|
+
if (this._fieldSearch === undefined || this._hasToCreateFieldSearch) {
|
|
486
|
+
this._hasToCreateFieldSearch = false;
|
|
487
|
+
this._fieldSearch = utils.buildFieldSearch(item, ({ argument }) => this.fieldsOptionLoader(argument), (option) => this.onSelectField(option));
|
|
488
|
+
}
|
|
489
|
+
return (_a = this._fieldSearch) !== null && _a !== void 0 ? _a : document.createElement('div');
|
|
490
|
+
}
|
|
491
|
+
fieldsOptionLoader(argument) {
|
|
492
|
+
const searchTerm = argument === null || argument === void 0 ? void 0 : argument.toLowerCase();
|
|
493
|
+
const allFields = this.getFormFields().map(field => { var _a; return (_a = this.dataUnit) === null || _a === void 0 ? void 0 : _a.getField(field.name); });
|
|
494
|
+
const filteredFields = allFields.filter(field => {
|
|
495
|
+
var _a, _b;
|
|
496
|
+
if (!field) {
|
|
497
|
+
return;
|
|
498
|
+
}
|
|
499
|
+
return ((_a = field.name) === null || _a === void 0 ? void 0 : _a.toLowerCase().includes(searchTerm)) ||
|
|
500
|
+
((_b = field.label) === null || _b === void 0 ? void 0 : _b.toLowerCase().includes(searchTerm));
|
|
501
|
+
});
|
|
502
|
+
const options = filteredFields.map((field) => {
|
|
503
|
+
if (!field) {
|
|
504
|
+
return;
|
|
505
|
+
}
|
|
506
|
+
return ({ value: field.name, label: field.label });
|
|
507
|
+
});
|
|
508
|
+
return Promise.resolve(options);
|
|
509
|
+
}
|
|
510
|
+
onSelectField(option) {
|
|
511
|
+
if (option == undefined) {
|
|
512
|
+
return;
|
|
513
|
+
}
|
|
514
|
+
this._fieldToGetFocus = option.value;
|
|
515
|
+
}
|
|
516
|
+
clearFieldToFocusHandler() {
|
|
517
|
+
this._fieldToGetFocus = undefined;
|
|
518
|
+
}
|
|
519
|
+
getColumnSearch(item) {
|
|
520
|
+
var _a;
|
|
521
|
+
if (this._columnSearch !== undefined) {
|
|
522
|
+
return this._columnSearch;
|
|
523
|
+
}
|
|
524
|
+
this._columnSearch = utils.buildFieldSearch(item, ({ argument }) => new Promise(accept => {
|
|
525
|
+
var _a;
|
|
526
|
+
(_a = this._snkGrid) === null || _a === void 0 ? void 0 : _a.filterColumns(argument).then((columns) => {
|
|
527
|
+
accept(columns
|
|
528
|
+
.filter(column => !column.hidden)
|
|
529
|
+
.map(column => ({ label: column.label, value: column.name })));
|
|
530
|
+
});
|
|
531
|
+
}), (option) => {
|
|
532
|
+
var _a;
|
|
533
|
+
if (option != undefined) {
|
|
534
|
+
(_a = this._snkGrid) === null || _a === void 0 ? void 0 : _a.locateColumn(option.value);
|
|
535
|
+
}
|
|
536
|
+
});
|
|
537
|
+
return (_a = this._columnSearch) !== null && _a !== void 0 ? _a : document.createElement('div');
|
|
538
|
+
}
|
|
539
|
+
buildTaskbarCustomActionsList() {
|
|
540
|
+
return [this.buildSearchColumnTaskbarAction()];
|
|
541
|
+
}
|
|
542
|
+
buildSearchColumnTaskbarAction() {
|
|
543
|
+
var _a, _b;
|
|
544
|
+
return {
|
|
545
|
+
value: core.StringUtils.generateUUID(),
|
|
546
|
+
label: (_b = (_a = this.messagesBuilder) === null || _a === void 0 ? void 0 : _a.getMessage('snkGrid.findColumn', {})) !== null && _b !== void 0 ? _b : "",
|
|
547
|
+
disableCloseOnSelect: true,
|
|
548
|
+
eagerInitialize: true,
|
|
549
|
+
itemBuilder: (_, item) => { var _a; return (_a = this.getColumnSearch(item)) !== null && _a !== void 0 ? _a : document.createElement('div'); },
|
|
550
|
+
};
|
|
551
|
+
}
|
|
552
|
+
async initKeyboardManager() {
|
|
553
|
+
var _a;
|
|
554
|
+
this._keyboardManager = new core.KeyboardManager({ propagate: false, element: this._element });
|
|
555
|
+
this._keyboardManager.bind(utils.SHORTCUT_SEARCH_FIELD, async () => {
|
|
556
|
+
var _a;
|
|
557
|
+
await ((_a = this._snkFormView) === null || _a === void 0 ? void 0 : _a.showSearchField());
|
|
558
|
+
}, { description: (_a = this.messagesBuilder) === null || _a === void 0 ? void 0 : _a.getMessage("snkSimpleCrud.findFields"), element: this._element });
|
|
559
|
+
}
|
|
560
|
+
renderTabSelector() {
|
|
561
|
+
if (!this.hasNonMainSheets()) {
|
|
562
|
+
return undefined;
|
|
563
|
+
}
|
|
564
|
+
const selectedKey = this._selectedSheet && this._selectedSheet.name !== SnkDynaformDetailView.MAIN_TAB
|
|
565
|
+
? this._selectedSheet.name
|
|
566
|
+
: undefined;
|
|
567
|
+
return (index.h("ez-tabselector", { class: "ez-tabselector-internal", tabs: this.buildInternalTabItems(), selectedTab: selectedKey, onEzChange: (evt) => this.onInternalTabChange(evt.detail) }));
|
|
568
|
+
}
|
|
569
|
+
/**
|
|
570
|
+
* Renderiza o conteúdo da aba selecionada, seguindo as mesmas regras do
|
|
571
|
+
* formulário master (snk-dynaform-guides-view.getContent):
|
|
572
|
+
* - Sheet de detalhe (child[...]) → snk-dynaform-detail-view aninhado.
|
|
573
|
+
* - Sheet de formulário (ex.: "Geral") → snk-dynaform-form-view com os campos do sheet.
|
|
574
|
+
*/
|
|
575
|
+
renderSelectedSheetContent() {
|
|
576
|
+
if (!this._selectedSheet || this._selectedSheet.name === SnkDynaformDetailView.MAIN_TAB) {
|
|
577
|
+
return undefined;
|
|
578
|
+
}
|
|
579
|
+
const childEntityName = form.FormMetadata.getDetailName(this._selectedSheet.name);
|
|
580
|
+
if (childEntityName) {
|
|
581
|
+
return (index.h("snk-dynaform-detail-view", { key: `sub_${this.dataUnitName}_${this._selectedSheet.name}`, dataUnitName: `${this.dataUnitName}/${childEntityName}`, entityName: childEntityName, label: this._selectedSheet.label, resourceID: this.resourceID, canEdit: this.canEdit, messagesBuilder: this.messagesBuilder, customEditors: this.customEditors, customRenders: this.customRenders, presentationMode: this.presentationMode, taskbarCustomContainerId: this.taskbarCustomContainerId }));
|
|
582
|
+
}
|
|
583
|
+
return (index.h("snk-dynaform-form-view", { key: `sheet_${this._selectedSheet.name}`, name: this._selectedSheet.name, formMetadata: this._formMetadata, dataUnit: this.dataUnit, fields: this._selectedSheet.fields, fieldToFocus: this._fieldToGetFocus, label: this._selectedSheet.label, onSnkRequestClearFieldToFocus: this.clearFieldToFocusHandler.bind(this), fieldSearch: this._fieldSearch }));
|
|
584
|
+
}
|
|
585
|
+
renderViewStack() {
|
|
586
|
+
var _a, _b;
|
|
587
|
+
return (index.h("ez-view-stack", { ref: (ref) => this._viewStack = ref }, index.h("stack-item", { class: "ez-size-width--full ez-size-height--full" }, index.h("snk-grid", { class: "ez-size-width--full ez-size-height--full", ref: (ref) => {
|
|
588
|
+
if (ref)
|
|
589
|
+
this._snkGrid = ref;
|
|
590
|
+
}, configName: this._configName, messagesBuilder: this.messagesBuilder, onGridDoubleClick: () => this.changeViewMode(constants.VIEW_MODE.FORM), onActionClick: (evt) => this.executeActionHandler(evt), presentationMode: this.presentationMode, canEdit: this.canEdit, isDetail: true, taskbarCustomContainerId: this.taskbarCustomContainerId, gridHeaderCustomSlotId: "DETAIL_GRID_HEADER_CUSTOM_ELEMENTS", topTaskbarCustomSlotId: "DETAIL_GRID_TASKBAR_CUSTOM_ELEMENTS", outlineMode: true, enableGridInsert: true, autoLoad: true, multipleEditionEnabled: true, multipleSelection: true, hideHeader: true, hideGridTaskbar: true })), index.h("stack-item", { class: "ez-size-width--full ez-size-height--full grid-container" }, index.h("div", { class: "form-and-detail-container" }, index.h("snk-dynaform-form-view", { ref: (ref) => {
|
|
591
|
+
if (ref)
|
|
592
|
+
this._snkFormView = ref;
|
|
593
|
+
}, name: SnkDynaformDetailView.MAIN_TAB, formMetadata: this._formMetadata, dataUnit: this.dataUnit, fields: this.getFormFields(), fieldToFocus: this._fieldToGetFocus, label: this.label, onSnkRequestClearFieldToFocus: this.clearFieldToFocusHandler.bind(this), fieldSearch: this._fieldSearch }, this.renderSelectedRecordHeader()), this.renderTabSelector(), this.renderSelectedSheetContent())), index.h("snk-attach", { ref: (ref) => this._snkAttach = ref, registerKey: (_a = this.attachmentRegisterKey) !== null && _a !== void 0 ? _a : '', messagesBuilder: this.messagesBuilder, entityName: (_b = this.entityName) !== null && _b !== void 0 ? _b : '' })));
|
|
594
|
+
}
|
|
595
|
+
render() {
|
|
596
|
+
return (index.h(index.Host, null, index.h("snk-data-unit", { ref: (el) => {
|
|
597
|
+
if (el)
|
|
598
|
+
this._snkDataUnit = el;
|
|
599
|
+
}, dataUnitName: `${this.dataUnitName}`, onDataUnitReady: evt => this.dataUnitReadyHandler(evt), entityName: this.entityName, onDataStateChange: this.handleDataStateChange.bind(this), ignoreSaveMessage: this._currentView === constants.VIEW_MODE.GRID, messagesBuilder: this.messagesBuilder, configName: this._configName }, index.h("snk-taskbar", { key: "detailViewTaskbar", class: "form-taskbar", "data-element-id": "detail_top", configName: this._configName, messagesBuilder: this.messagesBuilder, buttons: this._taskbarProcessor.buttons, disabledButtons: this._taskbarProcessor.disabledButtons, customButtons: this._taskbarProcessor.customButtons, primaryButton: "INSERT", overflowStrategy: "hiddenItems", alignRigth: true, sizeButtons: 'small', presentationMode: this.presentationMode, onActionClick: evt => this.executeActionHandler(evt), dataUnit: this.dataUnit, resourceID: this.resourceID, customContainerId: this.taskbarCustomContainerId, customSlotId: "DETAIL_TASKBAR_CUSTOM_ELEMENTS", actionsSettingsList: this.getSettingsListForm(), customActionsList: this.buildTaskbarCustomActionsList() }, index.h("slot", { name: "DETAIL_TASKBAR_CUSTOM_ELEMENTS" })), this.renderViewStack())));
|
|
600
|
+
}
|
|
601
|
+
get _element() { return index.getElement(this); }
|
|
602
|
+
static get watchers() { return {
|
|
603
|
+
"dataUnit": ["observeDataUnit"],
|
|
604
|
+
"dataState": ["observerDataState"],
|
|
605
|
+
"customEditors": ["observerPropsCustomEditor"],
|
|
606
|
+
"customRenders": ["observeCustomRenders"]
|
|
607
|
+
}; }
|
|
608
|
+
};
|
|
609
|
+
SnkDynaformDetailView.MAIN_TAB = "__main";
|
|
610
|
+
SnkDynaformDetailView.style = snkDynaformDetailViewCss;
|
|
611
|
+
|
|
612
|
+
const snkDynaformFormConfigCss = ".sc-snk-dynaform-form-config-h{display:flex;flex-direction:column;height:100vh;width:100%;font-family:var(--font-pattern, \"Roboto\");background:white;color:#2b3a54;--snk-form-config-container-height:calc(100vh - 95px);outline:none}.form-config-body.sc-snk-dynaform-form-config{height:var(--snk-form-config-container-height);overflow:hidden;padding-top:var(--space--12, 12px)}.form-config-layout.sc-snk-dynaform-form-config{display:flex;flex-direction:row;height:100%;gap:20px;align-items:stretch}.main-editing-area.sc-snk-dynaform-form-config{display:flex;flex-direction:column;flex:1;min-width:0;height:100%;overflow:hidden;gap:12px}.main-editing-area.sc-snk-dynaform-form-config>snk-dynaform-fields-layout.sc-snk-dynaform-form-config{flex:1 1 auto;min-height:0;overflow:auto;flex-direction:row}.main-editing-area.sc-snk-dynaform-form-config>snk-dynaform-guides-configurator.sc-snk-dynaform-form-config{flex:0 0 auto}.main-fields-section.sc-snk-dynaform-form-config{flex:0 0 40vh;display:flex;flex-direction:column;min-height:0;overflow:hidden}.guide-header.sc-snk-dynaform-form-config{display:flex;width:100%;padding-bottom:12px;border-bottom:1px solid #dce0e8;height:30px;font-weight:500;font-size:16px}";
|
|
613
|
+
|
|
614
|
+
const SnkDynaformFormConfig = class {
|
|
615
|
+
constructor(hostRef) {
|
|
616
|
+
index.registerInstance(this, hostRef);
|
|
617
|
+
this.configClose = index.createEvent(this, "configClose", 7);
|
|
618
|
+
this.configChange = index.createEvent(this, "configChange", 7);
|
|
619
|
+
this.guidesMap = new Map();
|
|
620
|
+
this.availableFields = [];
|
|
621
|
+
this.guidesList = [];
|
|
622
|
+
this.groupsList = [];
|
|
623
|
+
this.mainGuide = undefined;
|
|
624
|
+
this.mainGroupsList = [];
|
|
625
|
+
this.selectedGuide = undefined;
|
|
626
|
+
this._formConfig = {};
|
|
627
|
+
this.configOptions = [];
|
|
628
|
+
this.originalConfigSelected = undefined;
|
|
629
|
+
this.configSelected = undefined;
|
|
630
|
+
this.hasChanges = false;
|
|
631
|
+
this.optionConfigChanged = false;
|
|
632
|
+
this.dataUnit = undefined;
|
|
633
|
+
this.configManager = undefined;
|
|
634
|
+
this.ignoreReadOnlyFormFields = undefined;
|
|
635
|
+
this.messagesBuilder = undefined;
|
|
636
|
+
this.customGuidesConfig = [];
|
|
637
|
+
}
|
|
638
|
+
handleFieldConfigChanged() {
|
|
639
|
+
this.hasChanges = true;
|
|
640
|
+
}
|
|
641
|
+
async handleFormConfigOptionSelected({ detail }) {
|
|
642
|
+
this.configSelected = detail;
|
|
643
|
+
this.selectedGuide = undefined;
|
|
644
|
+
await this.loadConfigByUser();
|
|
645
|
+
this.optionConfigChanged = !core.ObjectUtils.equals(this.configSelected, this.originalConfigSelected);
|
|
646
|
+
if (this.configSelected.origin === formConfigFetcher.UserConfigType.DEFAULT) {
|
|
647
|
+
this.hasChanges = false;
|
|
648
|
+
}
|
|
649
|
+
}
|
|
650
|
+
async handleAddFieldToGuide({ detail: fieldItem }) {
|
|
651
|
+
var _a, _b;
|
|
652
|
+
const hasValidSecondaryGuide = this.selectedGuide
|
|
653
|
+
&& !this.selectedGuide.isCustom
|
|
654
|
+
&& !this.selectedGuide.isDetail;
|
|
655
|
+
if (!hasValidSecondaryGuide && this.selectedGuide && (this.selectedGuide.isCustom || this.selectedGuide.isDetail)) {
|
|
656
|
+
this.showCanNotAddFieldToGuideDialog();
|
|
657
|
+
return;
|
|
658
|
+
}
|
|
659
|
+
if (!hasValidSecondaryGuide && !this.mainGuide) {
|
|
660
|
+
this.showNoGuideSelectedDialog();
|
|
661
|
+
return;
|
|
662
|
+
}
|
|
663
|
+
this.availableFields = [...this.availableFields.filter(f => f.name !== fieldItem.name)];
|
|
664
|
+
if (hasValidSecondaryGuide) {
|
|
665
|
+
await ((_a = this.refFieldsLayout) === null || _a === void 0 ? void 0 : _a.addFieldToLayout(fieldItem));
|
|
666
|
+
}
|
|
667
|
+
else {
|
|
668
|
+
await ((_b = this.refMainFieldsLayout) === null || _b === void 0 ? void 0 : _b.addFieldToLayout(fieldItem));
|
|
669
|
+
}
|
|
670
|
+
}
|
|
671
|
+
async handleSetFieldAsAvailable({ detail }) {
|
|
672
|
+
const hasField = this.availableFields.some(f => f.name === detail.name);
|
|
673
|
+
if (hasField)
|
|
674
|
+
return;
|
|
675
|
+
this.availableFields = [...this.availableFields, detail];
|
|
676
|
+
}
|
|
677
|
+
async handleRemoveFieldFromAvailable({ detail }) {
|
|
678
|
+
this.availableFields = this.availableFields.filter(f => f.name !== detail.name);
|
|
679
|
+
}
|
|
680
|
+
observeSelectedGuide(guide) {
|
|
681
|
+
var _a, _b;
|
|
682
|
+
if ((guide === null || guide === void 0 ? void 0 : guide.name) && ((_a = this.mainGuide) === null || _a === void 0 ? void 0 : _a.name) && guide.name === this.mainGuide.name) {
|
|
683
|
+
this.selectedGuide = undefined;
|
|
684
|
+
return;
|
|
685
|
+
}
|
|
686
|
+
const guideGroups = (_b = this.guidesMap.get(guide === null || guide === void 0 ? void 0 : guide.name)) !== null && _b !== void 0 ? _b : [];
|
|
687
|
+
this.groupsList = [...guideGroups];
|
|
688
|
+
}
|
|
689
|
+
observeConfigManager() {
|
|
690
|
+
this.loadFormConfig();
|
|
691
|
+
}
|
|
692
|
+
showNoGuideSelectedDialog() {
|
|
693
|
+
const title = this.getMessage('snkFormConfig.noGuideSelected.title');
|
|
694
|
+
const message = this.getMessage('snkFormConfig.noGuideSelected.message');
|
|
695
|
+
utils.ApplicationUtils.alert(title, message);
|
|
696
|
+
}
|
|
697
|
+
showCanNotAddFieldToGuideDialog() {
|
|
698
|
+
const title = this.getMessage('snkFormConfig.canNotAddFieldToGuide.title');
|
|
699
|
+
const message = this.getMessage('snkFormConfig.canNotAddFieldToGuide.message');
|
|
700
|
+
utils.ApplicationUtils.alert(title, message);
|
|
701
|
+
}
|
|
702
|
+
/**
|
|
703
|
+
* Conforme mecanismo de mensagens, é possível customizar as mensagens dos blocos de construção
|
|
704
|
+
* através de um pequeno modulo na estrutura da aplicação:
|
|
705
|
+
* - Criar um arquivo no seguinte caminho: /messages/appmessages.msg.js.
|
|
706
|
+
* Para conhecer os detalhes do módulo, vide o arquivo neste projeto "/src/lib/message/resources/snk-form.msg.ts"
|
|
707
|
+
*/
|
|
708
|
+
getMessage(key, params) {
|
|
709
|
+
return this.messagesBuilder.getMessage(key, params);
|
|
710
|
+
}
|
|
711
|
+
async initializeUserConfig() {
|
|
712
|
+
if (this.configManager == undefined)
|
|
713
|
+
return;
|
|
714
|
+
try {
|
|
715
|
+
const userConfig = await this.configManager.fetchUserAvailableConfigs();
|
|
716
|
+
this.configOptions = userConfig;
|
|
717
|
+
const isDefault = this._formConfig != undefined ? this._formConfig.defaultConfiguration : true;
|
|
718
|
+
const origin = (isDefault ? formConfigFetcher.UserConfigType.DEFAULT : formConfigFetcher.UserConfigType.USER);
|
|
719
|
+
this.configSelected = userConfig === null || userConfig === void 0 ? void 0 : userConfig.find((config) => config.origin === origin);
|
|
720
|
+
this.originalConfigSelected = userConfig === null || userConfig === void 0 ? void 0 : userConfig.find((config) => config.origin === origin);
|
|
721
|
+
}
|
|
722
|
+
catch (error) {
|
|
723
|
+
console.error(this.getMessage('snkFormConfig.errors.failFetchUserConfig'));
|
|
724
|
+
console.error(error);
|
|
725
|
+
}
|
|
726
|
+
}
|
|
727
|
+
async loadConfigByUser() {
|
|
728
|
+
if (!this.configManager || !this.configSelected)
|
|
729
|
+
return;
|
|
730
|
+
if (this.isConfigDefaultSelected()) {
|
|
731
|
+
await this.handleLoadDefaultConfig();
|
|
732
|
+
}
|
|
733
|
+
else {
|
|
734
|
+
this.loadFormConfig();
|
|
735
|
+
}
|
|
736
|
+
}
|
|
737
|
+
async handleLoadDefaultConfig() {
|
|
738
|
+
const defaultConfig = await this.configManager.fetchDefaultConfig();
|
|
739
|
+
if (defaultConfig) {
|
|
740
|
+
this.loadFormConfig(defaultConfig);
|
|
741
|
+
return;
|
|
742
|
+
}
|
|
743
|
+
const emptyConfig = this.configManager.getEmptyConfig();
|
|
744
|
+
if (emptyConfig) {
|
|
745
|
+
this.loadFormConfig(emptyConfig);
|
|
746
|
+
}
|
|
747
|
+
}
|
|
748
|
+
isConfigDefaultSelected() {
|
|
749
|
+
return this.configSelected.origin === formConfigFetcher.UserConfigType.DEFAULT;
|
|
750
|
+
}
|
|
751
|
+
loadFormConfig(config) {
|
|
752
|
+
this._formConfig = config ? config : this.getConfig();
|
|
753
|
+
this.loadGuides();
|
|
754
|
+
this.initializeAvailableFields();
|
|
755
|
+
}
|
|
756
|
+
initializeAvailableFields() {
|
|
757
|
+
var _a;
|
|
758
|
+
if (((_a = this._formConfig) === null || _a === void 0 ? void 0 : _a.fields) == undefined)
|
|
759
|
+
return;
|
|
760
|
+
const fieldsFormConfig = [...this._formConfig.fields];
|
|
761
|
+
const fieldsMetadata = this.dataUnit.metadata.fields;
|
|
762
|
+
this.availableFields = fieldsMetadata.filter(({ name: fieldName, visible: fieldVisible, properties }) => {
|
|
763
|
+
const hasCfg = fieldsFormConfig.some(({ name: fieldFormName }) => fieldFormName === fieldName);
|
|
764
|
+
/**
|
|
765
|
+
* Quando a visibilidade de um campo é alterada pelo dataunit, mas o desenvolvedor deseja que o mesmo continue
|
|
766
|
+
* sendo apresentado no configurador, precisamos fazer essa tratativa, verificando se o campo não tem configuração
|
|
767
|
+
*/
|
|
768
|
+
if (!hasCfg && properties.visibleOnConfig === true && !fieldVisible)
|
|
769
|
+
return properties.visibleOnConfig;
|
|
770
|
+
return fieldVisible === true && hasCfg === false;
|
|
771
|
+
});
|
|
772
|
+
}
|
|
773
|
+
getInitialOrder(guidesList) {
|
|
774
|
+
var _a, _b;
|
|
775
|
+
if (Array.isArray((_a = this._formConfig) === null || _a === void 0 ? void 0 : _a.tabs)) {
|
|
776
|
+
return (_b = this._formConfig.tabs) === null || _b === void 0 ? void 0 : _b.length;
|
|
777
|
+
}
|
|
778
|
+
if (guidesList.length > 0) {
|
|
779
|
+
return Math.max(...guidesList.map(g => g.order));
|
|
780
|
+
}
|
|
781
|
+
return 0;
|
|
782
|
+
}
|
|
783
|
+
loadGuides() {
|
|
784
|
+
var _a, _b, _c, _d;
|
|
785
|
+
this.guidesList = [];
|
|
786
|
+
this.guidesList.push(...FormConfigHelper.buildGuides(this._formConfig, this.getMessage('snkFormConfig.form.mainArea'), this.dataUnit, constants.TAB_NAMES.general));
|
|
787
|
+
this.guidesList.push(...FormConfigHelper.buildChildrenGuides(this.dataUnit, this.getInitialOrder(this.guidesList), this.guidesList));
|
|
788
|
+
this.guidesList.push(...FormConfigHelper.buildCustomGuides(this.customGuidesConfig, this.guidesList));
|
|
789
|
+
this.guidesMap = FormConfigHelper.buildGuidesMap((_a = this._formConfig) === null || _a === void 0 ? void 0 : _a.fields, this.guidesList, this.dataUnit, constants.TAB_NAMES.general);
|
|
790
|
+
this.mainGuide = this.guidesList.find(g => g.name === constants.TAB_NAMES.main);
|
|
791
|
+
this.mainGroupsList = ((_b = this.mainGuide) === null || _b === void 0 ? void 0 : _b.name)
|
|
792
|
+
? [...((_d = (_c = this.guidesMap) === null || _c === void 0 ? void 0 : _c.get(this.mainGuide.name)) !== null && _d !== void 0 ? _d : [])]
|
|
793
|
+
: [];
|
|
794
|
+
this.ensureSelectedGuide();
|
|
795
|
+
}
|
|
796
|
+
ensureSelectedGuide() {
|
|
797
|
+
const stillValid = this.selectedGuide
|
|
798
|
+
&& this.guidesList.some(g => g.name === this.selectedGuide.name);
|
|
799
|
+
if (stillValid)
|
|
800
|
+
return;
|
|
801
|
+
const firstSelectable = this.guidesList
|
|
802
|
+
.filter(g => { var _a; return g.visible && g.name !== ((_a = this.mainGuide) === null || _a === void 0 ? void 0 : _a.name); })
|
|
803
|
+
.sort((a, b) => { var _a, _b; return ((_a = a.order) !== null && _a !== void 0 ? _a : Number.MAX_VALUE) - ((_b = b.order) !== null && _b !== void 0 ? _b : Number.MAX_VALUE); })[0];
|
|
804
|
+
this.selectedGuide = firstSelectable;
|
|
805
|
+
}
|
|
806
|
+
getConfig() {
|
|
807
|
+
let config = this.configManager.getConfig(this.dataUnit, false);
|
|
808
|
+
if (config.fields && config.fields.length === 0) {
|
|
809
|
+
config = undefined;
|
|
810
|
+
}
|
|
811
|
+
if (config == undefined) {
|
|
812
|
+
config = form.buildFormConfigFromDataUnit(this.dataUnit);
|
|
813
|
+
}
|
|
814
|
+
return core.ObjectUtils.copy(config);
|
|
815
|
+
}
|
|
816
|
+
handleSelectGuide({ detail: selectedGuide }) {
|
|
817
|
+
this.selectedGuide = selectedGuide;
|
|
818
|
+
}
|
|
819
|
+
handleLayoutChanged({ detail: newGroupList }) {
|
|
820
|
+
if (!this.selectedGuide)
|
|
821
|
+
return;
|
|
822
|
+
this.hasChanges = true;
|
|
823
|
+
this.groupsList = [...newGroupList];
|
|
824
|
+
this.guidesMap.set(this.selectedGuide.name, [...newGroupList]);
|
|
825
|
+
}
|
|
826
|
+
handleMainLayoutChanged({ detail: newGroupList }) {
|
|
827
|
+
var _a;
|
|
828
|
+
if (!((_a = this.mainGuide) === null || _a === void 0 ? void 0 : _a.name))
|
|
829
|
+
return;
|
|
830
|
+
this.hasChanges = true;
|
|
831
|
+
this.mainGroupsList = [...newGroupList];
|
|
832
|
+
this.guidesMap.set(this.mainGuide.name, [...newGroupList]);
|
|
833
|
+
}
|
|
834
|
+
getIsDefaultConfig() {
|
|
835
|
+
var _a;
|
|
836
|
+
const optionSelected = (_a = this.configSelected) === null || _a === void 0 ? void 0 : _a.origin;
|
|
837
|
+
return optionSelected === formConfigFetcher.UserConfigType.DEFAULT
|
|
838
|
+
&& this.optionConfigChanged === true
|
|
839
|
+
&& this.hasChanges === false;
|
|
840
|
+
}
|
|
841
|
+
getTabsToSave() {
|
|
842
|
+
return this.guidesList.map(tab => {
|
|
843
|
+
return {
|
|
844
|
+
name: tab.name,
|
|
845
|
+
label: tab.name === constants.TAB_NAMES.main ? tab.name : tab.label,
|
|
846
|
+
order: tab.name === constants.TAB_NAMES.main ? 0 : tab.order,
|
|
847
|
+
visible: tab.visible,
|
|
848
|
+
};
|
|
849
|
+
});
|
|
850
|
+
}
|
|
851
|
+
async handleSaveConfig() {
|
|
852
|
+
var _a;
|
|
853
|
+
const savedConfig = await this.configManager.saveConfig(this.buildConfigToSave());
|
|
854
|
+
this.configSelected = (_a = this.configOptions) === null || _a === void 0 ? void 0 : _a.find((config) => {
|
|
855
|
+
return config.origin === (this.hasChanges ? formConfigFetcher.UserConfigType.USER : formConfigFetcher.UserConfigType.DEFAULT);
|
|
856
|
+
});
|
|
857
|
+
this.originalConfigSelected = this.configSelected;
|
|
858
|
+
this.hasChanges = false;
|
|
859
|
+
this.optionConfigChanged = false;
|
|
860
|
+
utils.ApplicationUtils.info(this.getMessage('snkFormConfig.info.successfullyConfigSaved'), { iconName: 'check' });
|
|
861
|
+
this.configChange.emit(savedConfig);
|
|
862
|
+
}
|
|
863
|
+
buildConfigToSave() {
|
|
864
|
+
const formConfig = core.ObjectUtils.copy(this._formConfig);
|
|
865
|
+
formConfig.tabs = this.getTabsToSave();
|
|
866
|
+
formConfig.fields = FormConfigHelper.getFieldsToSave(this.guidesMap);
|
|
867
|
+
formConfig.defaultConfiguration = this.getIsDefaultConfig();
|
|
868
|
+
return formConfig;
|
|
869
|
+
}
|
|
870
|
+
handleAvailableFieldListChanged({ detail: updatedList }) {
|
|
871
|
+
this.availableFields = [...updatedList];
|
|
872
|
+
}
|
|
873
|
+
handleSetFieldListAsAvailable({ detail: updatedList }) {
|
|
874
|
+
this.availableFields = [...this.availableFields, ...updatedList];
|
|
875
|
+
}
|
|
876
|
+
handleGuideDeleted({ detail: guide }) {
|
|
877
|
+
var _a, _b;
|
|
878
|
+
const guideName = guide.name;
|
|
879
|
+
const guideGroups = (_a = this.guidesMap.get(guideName)) !== null && _a !== void 0 ? _a : [];
|
|
880
|
+
const fieldsToAvailable = [];
|
|
881
|
+
guideGroups.forEach(group => fieldsToAvailable.push(...group.fields));
|
|
882
|
+
this.availableFields = [...this.availableFields, ...fieldsToAvailable];
|
|
883
|
+
this.guidesList = [...this.guidesList.filter(g => g.name !== guideName)];
|
|
884
|
+
this.guidesMap.delete(guideName);
|
|
885
|
+
if (((_b = this.selectedGuide) === null || _b === void 0 ? void 0 : _b.name) === guideName) {
|
|
886
|
+
this.selectedGuide = undefined;
|
|
887
|
+
this.ensureSelectedGuide();
|
|
888
|
+
}
|
|
889
|
+
this.hasChanges = true;
|
|
890
|
+
}
|
|
891
|
+
handleGuideListChanged({ detail: updatedList }) {
|
|
892
|
+
this.hasChanges = true;
|
|
893
|
+
this.guidesList = [...updatedList];
|
|
894
|
+
}
|
|
895
|
+
handleGuideRenamed({ detail: updatedName }) {
|
|
896
|
+
var _a;
|
|
897
|
+
const previousGuide = this.selectedGuide;
|
|
898
|
+
if (!(previousGuide === null || previousGuide === void 0 ? void 0 : previousGuide.name))
|
|
899
|
+
return;
|
|
900
|
+
const previousName = previousGuide.name;
|
|
901
|
+
const guideGroups = (_a = this.guidesMap.get(previousName)) !== null && _a !== void 0 ? _a : [];
|
|
902
|
+
const updatedGroups = FormConfigHelper.updateTabInFieldsFromGroupList(guideGroups, updatedName);
|
|
903
|
+
this.guidesMap.delete(previousName);
|
|
904
|
+
this.guidesMap.set(updatedName, updatedGroups);
|
|
905
|
+
const updatedGuide = {
|
|
906
|
+
name: updatedName,
|
|
907
|
+
label: updatedName,
|
|
908
|
+
visible: previousGuide.visible,
|
|
909
|
+
order: previousGuide.order,
|
|
910
|
+
};
|
|
911
|
+
this.guidesList = [...this.guidesList.map(guide => (guide.name === previousName) ? updatedGuide : guide)];
|
|
912
|
+
this.groupsList = [...updatedGroups];
|
|
913
|
+
this.selectedGuide = updatedGuide;
|
|
914
|
+
this.hasChanges = true;
|
|
915
|
+
}
|
|
916
|
+
handleCreateNewGuide() {
|
|
917
|
+
const newGuideName = FormConfigHelper.buildNewGuideName(this.guidesList, this.getMessage.bind(this));
|
|
918
|
+
const newGuide = {
|
|
919
|
+
name: newGuideName,
|
|
920
|
+
label: newGuideName,
|
|
921
|
+
visible: true,
|
|
922
|
+
order: this.guidesList.length + 1,
|
|
923
|
+
};
|
|
924
|
+
const newGuideFixedGroup = {
|
|
925
|
+
name: constants.GROUP_NAMES.noGroup,
|
|
926
|
+
fields: [],
|
|
927
|
+
};
|
|
928
|
+
this.guidesList = [...this.guidesList, newGuide];
|
|
929
|
+
this.guidesMap.set(newGuideName, [newGuideFixedGroup]);
|
|
930
|
+
this.selectedGuide = newGuide;
|
|
931
|
+
this.hasChanges = true;
|
|
932
|
+
}
|
|
933
|
+
getGuideNames() {
|
|
934
|
+
return [
|
|
935
|
+
...this.guidesList.map(g => g.name.toLowerCase()),
|
|
936
|
+
this.getMessage('snkFormConfig.form.mainArea').toLowerCase(),
|
|
937
|
+
];
|
|
938
|
+
}
|
|
939
|
+
async componentWillRender() {
|
|
940
|
+
if (this.messagesBuilder == undefined) {
|
|
941
|
+
const application = core.ApplicationContext.getContextValue('__SNK__APPLICATION__');
|
|
942
|
+
this.messagesBuilder = application.messagesBuilder;
|
|
943
|
+
}
|
|
944
|
+
}
|
|
945
|
+
async componentWillLoad() {
|
|
946
|
+
this.loadFormConfig();
|
|
947
|
+
await this.initializeUserConfig();
|
|
948
|
+
}
|
|
949
|
+
render() {
|
|
950
|
+
var _a;
|
|
951
|
+
return (index.h(index.Host, null, index.h("snk-dynaform-config-header", { configOptions: this.configOptions, selectedConfig: this.configSelected, messagesBuilder: this.messagesBuilder, hasChanges: this.hasChanges, optionConfigChanged: this.optionConfigChanged, onConfigClose: () => this.configClose.emit(), onSaveConfig: async () => await this.handleSaveConfig() }), index.h("div", { class: "form-config-body" }, index.h("div", { class: "form-config-layout" }, index.h("snk-dynaform-fields-selector", { dataUnit: this.dataUnit, availableFields: this.availableFields, onFieldListChanged: this.handleAvailableFieldListChanged.bind(this), messagesBuilder: this.messagesBuilder }), index.h("div", { class: "main-editing-area" }, this.mainGuide && (index.h("div", { class: "main-fields-section" }, index.h("snk-dynaform-fields-layout", { ref: ref => this.refMainFieldsLayout = ref, selectedGuide: this.mainGuide, guideNames: this.getGuideNames(), groupsList: this.mainGroupsList, messagesBuilder: this.messagesBuilder, dataUnit: this.dataUnit, isMainSection: true, onLayoutChanged: this.handleMainLayoutChanged.bind(this), onSetFieldListAsAvailable: this.handleSetFieldListAsAvailable.bind(this) }))), index.h("snk-dynaform-guides-configurator", { messagesBuilder: this.messagesBuilder, guidesList: this.guidesList, selectedGuide: this.selectedGuide, mainGuideName: (_a = this.mainGuide) === null || _a === void 0 ? void 0 : _a.name, onGuideSelected: this.handleSelectGuide.bind(this), onGuideListChanged: this.handleGuideListChanged.bind(this), onCreateNewGuide: this.handleCreateNewGuide.bind(this), onGuideDeleted: this.handleGuideDeleted.bind(this) }), index.h("snk-dynaform-fields-layout", { ref: ref => this.refFieldsLayout = ref, selectedGuide: this.selectedGuide, guideNames: this.getGuideNames(), groupsList: this.groupsList, messagesBuilder: this.messagesBuilder, dataUnit: this.dataUnit, onGuideRenamed: this.handleGuideRenamed.bind(this), onLayoutChanged: this.handleLayoutChanged.bind(this), onSetFieldListAsAvailable: this.handleSetFieldListAsAvailable.bind(this) }))))));
|
|
952
|
+
}
|
|
953
|
+
static get watchers() { return {
|
|
954
|
+
"selectedGuide": ["observeSelectedGuide"],
|
|
955
|
+
"configManager": ["observeConfigManager"]
|
|
956
|
+
}; }
|
|
957
|
+
};
|
|
958
|
+
SnkDynaformFormConfig.style = snkDynaformFormConfigCss;
|
|
959
|
+
|
|
960
|
+
exports.snk_dynaform_detail_view = SnkDynaformDetailView;
|
|
961
|
+
exports.snk_dynaform_form_config = SnkDynaformFormConfig;
|