ngx-axis-appforge 0.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.editorconfig +17 -0
- package/README.md +111 -0
- package/angular.json +40 -0
- package/axis-components/badge/badge.css +3 -0
- package/axis-components/badge/badge.html +20 -0
- package/axis-components/badge/badge.options.ts +23 -0
- package/axis-components/badge/badge.ts +17 -0
- package/axis-components/badge/design/config.ts +52 -0
- package/axis-components/badge/design/ng-package.json +5 -0
- package/axis-components/badge/design/setting/setting.css +0 -0
- package/axis-components/badge/design/setting/setting.html +181 -0
- package/axis-components/badge/design/setting/setting.ts +126 -0
- package/axis-components/badge/ng-package.json +5 -0
- package/axis-components/button/button.css +3 -0
- package/axis-components/button/button.html +13 -0
- package/axis-components/button/button.options.ts +17 -0
- package/axis-components/button/button.ts +56 -0
- package/axis-components/button/design/config.ts +30 -0
- package/axis-components/button/design/ng-package.json +5 -0
- package/axis-components/button/design/setting/setting.css +0 -0
- package/axis-components/button/design/setting/setting.html +151 -0
- package/axis-components/button/design/setting/setting.ts +76 -0
- package/axis-components/button/ng-package.json +5 -0
- package/axis-components/cmp-map.ts +52 -0
- package/axis-components/cmplib.ts +9 -0
- package/axis-components/desc/desc.css +8 -0
- package/axis-components/desc/desc.html +19 -0
- package/axis-components/desc/desc.options.ts +24 -0
- package/axis-components/desc/desc.ts +29 -0
- package/axis-components/desc/design/config.ts +113 -0
- package/axis-components/desc/design/desc-item-setting/desc-item-setting.css +0 -0
- package/axis-components/desc/design/desc-item-setting/desc-item-setting.html +47 -0
- package/axis-components/desc/design/desc-item-setting/desc-item-setting.ts +40 -0
- package/axis-components/desc/design/desc-items-menu/desc-items-menu.css +0 -0
- package/axis-components/desc/design/desc-items-menu/desc-items-menu.html +9 -0
- package/axis-components/desc/design/desc-items-menu/desc-items-menu.ts +23 -0
- package/axis-components/desc/design/desc-setting/desc-setting.css +0 -0
- package/axis-components/desc/design/desc-setting/desc-setting.html +76 -0
- package/axis-components/desc/design/desc-setting/desc-setting.ts +51 -0
- package/axis-components/desc/design/ng-package.json +5 -0
- package/axis-components/desc/ng-package.json +5 -0
- package/axis-components/design/cmplib/cmplib.css +5 -0
- package/axis-components/design/cmplib/cmplib.html +52 -0
- package/axis-components/design/cmplib/cmplib.ts +96 -0
- package/axis-components/design/design/config.ts +29 -0
- package/axis-components/design/design/ng-package.json +5 -0
- package/axis-components/design/design/setting/setting.css +0 -0
- package/axis-components/design/design/setting/setting.html +33 -0
- package/axis-components/design/design/setting/setting.ts +33 -0
- package/axis-components/design/design.css +15 -0
- package/axis-components/design/design.html +51 -0
- package/axis-components/design/design.options.ts +9 -0
- package/axis-components/design/design.ts +509 -0
- package/axis-components/design/ng-package.json +5 -0
- package/axis-components/design/preview/drag.service.ts +148 -0
- package/axis-components/design/preview/drop-handler.ts +56 -0
- package/axis-components/design/preview/preview.css +3 -0
- package/axis-components/design/preview/preview.html +1 -0
- package/axis-components/design/preview/preview.ts +250 -0
- package/axis-components/design/preview/select.service.ts +140 -0
- package/axis-components/design/shortcut-key.ts +160 -0
- package/axis-components/design/toolbar/toolbar.css +24 -0
- package/axis-components/design/toolbar/toolbar.html +96 -0
- package/axis-components/design/toolbar/toolbar.ts +65 -0
- package/axis-components/design/tree/drag-drop.ts +125 -0
- package/axis-components/design/tree/tree.css +30 -0
- package/axis-components/design/tree/tree.html +49 -0
- package/axis-components/design/tree/tree.ts +292 -0
- package/axis-components/dynamic-container/design/config.ts +30 -0
- package/axis-components/dynamic-container/design/ng-package.json +5 -0
- package/axis-components/dynamic-container/design/setting/setting.css +0 -0
- package/axis-components/dynamic-container/design/setting/setting.html +20 -0
- package/axis-components/dynamic-container/design/setting/setting.ts +30 -0
- package/axis-components/dynamic-container/dynamic-container.css +3 -0
- package/axis-components/dynamic-container/dynamic-container.html +2 -0
- package/axis-components/dynamic-container/dynamic-container.options.ts +6 -0
- package/axis-components/dynamic-container/dynamic-container.ts +17 -0
- package/axis-components/dynamic-container/ng-package.json +5 -0
- package/axis-components/editor/editor.css +47 -0
- package/axis-components/editor/editor.html +10 -0
- package/axis-components/editor/editor.options.ts +10 -0
- package/axis-components/editor/editor.ts +86 -0
- package/axis-components/editor/ng-package.json +5 -0
- package/axis-components/examples/examples/badge.ts +17 -0
- package/axis-components/examples/examples/button.ts +38 -0
- package/axis-components/examples/examples/desc.ts +31 -0
- package/axis-components/examples/examples/design.ts +15 -0
- package/axis-components/examples/examples/dynamic-container.ts +21 -0
- package/axis-components/examples/examples/flex.ts +18 -0
- package/axis-components/examples/examples/form-item.ts +39 -0
- package/axis-components/examples/examples/form.ts +315 -0
- package/axis-components/examples/examples/icon.ts +16 -0
- package/axis-components/examples/examples/image.ts +15 -0
- package/axis-components/examples/examples/input-component.ts +15 -0
- package/axis-components/examples/examples/input-icon.ts +15 -0
- package/axis-components/examples/examples/input-json.ts +15 -0
- package/axis-components/examples/examples/input-number.ts +15 -0
- package/axis-components/examples/examples/input.ts +15 -0
- package/axis-components/examples/examples/modal.ts +15 -0
- package/axis-components/examples/examples/scope.ts +17 -0
- package/axis-components/examples/examples/single-selector.ts +25 -0
- package/axis-components/examples/examples/splitter.ts +36 -0
- package/axis-components/examples/examples/table.ts +126 -0
- package/axis-components/examples/examples/text.ts +15 -0
- package/axis-components/examples/examples/textarea.ts +15 -0
- package/axis-components/examples/examples/tree-selector.ts +35 -0
- package/axis-components/examples/examples/upload.ts +15 -0
- package/axis-components/examples/examples.ts +73 -0
- package/axis-components/flex/design/config.ts +49 -0
- package/axis-components/flex/design/ng-package.json +5 -0
- package/axis-components/flex/design/setting/setting.css +0 -0
- package/axis-components/flex/design/setting/setting.html +72 -0
- package/axis-components/flex/design/setting/setting.ts +43 -0
- package/axis-components/flex/flex.css +5 -0
- package/axis-components/flex/flex.html +6 -0
- package/axis-components/flex/flex.options.ts +12 -0
- package/axis-components/flex/flex.ts +15 -0
- package/axis-components/flex/ng-package.json +5 -0
- package/axis-components/form/design/config.ts +71 -0
- package/axis-components/form/design/ng-package.json +5 -0
- package/axis-components/form/design/setting/setting.css +0 -0
- package/axis-components/form/design/setting/setting.html +21 -0
- package/axis-components/form/design/setting/setting.ts +31 -0
- package/axis-components/form/form.css +3 -0
- package/axis-components/form/form.html +3 -0
- package/axis-components/form/form.options.ts +9 -0
- package/axis-components/form/form.ts +121 -0
- package/axis-components/form/ng-package.json +5 -0
- package/axis-components/form-item/design/config.ts +43 -0
- package/axis-components/form-item/design/ng-package.json +5 -0
- package/axis-components/form-item/design/setting/input-validator/input-validator.css +8 -0
- package/axis-components/form-item/design/setting/input-validator/input-validator.html +140 -0
- package/axis-components/form-item/design/setting/input-validator/input-validator.ts +158 -0
- package/axis-components/form-item/design/setting/setting.css +0 -0
- package/axis-components/form-item/design/setting/setting.html +39 -0
- package/axis-components/form-item/design/setting/setting.ts +40 -0
- package/axis-components/form-item/form-item.css +4 -0
- package/axis-components/form-item/form-item.html +16 -0
- package/axis-components/form-item/form-item.options.ts +12 -0
- package/axis-components/form-item/form-item.ts +128 -0
- package/axis-components/form-item/ng-package.json +5 -0
- package/axis-components/icon/design/config.ts +29 -0
- package/axis-components/icon/design/ng-package.json +5 -0
- package/axis-components/icon/design/setting/setting.css +0 -0
- package/axis-components/icon/design/setting/setting.html +67 -0
- package/axis-components/icon/design/setting/setting.ts +48 -0
- package/axis-components/icon/icon.css +0 -0
- package/axis-components/icon/icon.html +7 -0
- package/axis-components/icon/icon.options.ts +10 -0
- package/axis-components/icon/icon.ts +17 -0
- package/axis-components/icon/ng-package.json +5 -0
- package/axis-components/image/design/config.ts +30 -0
- package/axis-components/image/design/ng-package.json +5 -0
- package/axis-components/image/design/setting/setting.css +0 -0
- package/axis-components/image/design/setting/setting.html +42 -0
- package/axis-components/image/design/setting/setting.ts +37 -0
- package/axis-components/image/image.css +58 -0
- package/axis-components/image/image.html +14 -0
- package/axis-components/image/image.options.ts +8 -0
- package/axis-components/image/image.ts +29 -0
- package/axis-components/image/ng-package.json +5 -0
- package/axis-components/input/design/config.ts +80 -0
- package/axis-components/input/design/ng-package.json +5 -0
- package/axis-components/input/design/setting/setting.css +0 -0
- package/axis-components/input/design/setting/setting.html +79 -0
- package/axis-components/input/design/setting/setting.ts +51 -0
- package/axis-components/input/input.css +4 -0
- package/axis-components/input/input.html +32 -0
- package/axis-components/input/input.options.ts +14 -0
- package/axis-components/input/input.ts +53 -0
- package/axis-components/input/ng-package.json +5 -0
- package/axis-components/input-component/design/config.ts +30 -0
- package/axis-components/input-component/design/ng-package.json +5 -0
- package/axis-components/input-component/design/setting/setting.css +0 -0
- package/axis-components/input-component/design/setting/setting.html +33 -0
- package/axis-components/input-component/design/setting/setting.ts +33 -0
- package/axis-components/input-component/input-component.css +4 -0
- package/axis-components/input-component/input-component.html +25 -0
- package/axis-components/input-component/input-component.options.ts +7 -0
- package/axis-components/input-component/input-component.ts +50 -0
- package/axis-components/input-component/ng-package.json +5 -0
- package/axis-components/input-icon/design/config.ts +30 -0
- package/axis-components/input-icon/design/ng-package.json +5 -0
- package/axis-components/input-icon/design/setting/setting.css +0 -0
- package/axis-components/input-icon/design/setting/setting.html +29 -0
- package/axis-components/input-icon/design/setting/setting.ts +33 -0
- package/axis-components/input-icon/input-icon.css +4 -0
- package/axis-components/input-icon/input-icon.html +70 -0
- package/axis-components/input-icon/input-icon.options.ts +7 -0
- package/axis-components/input-icon/input-icon.ts +51 -0
- package/axis-components/input-icon/ng-package.json +5 -0
- package/axis-components/input-json/design/config.ts +29 -0
- package/axis-components/input-json/design/ng-package.json +5 -0
- package/axis-components/input-json/design/setting/setting.css +0 -0
- package/axis-components/input-json/design/setting/setting.html +7 -0
- package/axis-components/input-json/design/setting/setting.ts +26 -0
- package/axis-components/input-json/input-json.css +4 -0
- package/axis-components/input-json/input-json.html +19 -0
- package/axis-components/input-json/input-json.ts +67 -0
- package/axis-components/input-json/ng-package.json +5 -0
- package/axis-components/input-number/design/config.ts +30 -0
- package/axis-components/input-number/design/ng-package.json +5 -0
- package/axis-components/input-number/design/setting/setting.css +0 -0
- package/axis-components/input-number/design/setting/setting.html +118 -0
- package/axis-components/input-number/design/setting/setting.ts +66 -0
- package/axis-components/input-number/input-number.css +22 -0
- package/axis-components/input-number/input-number.html +11 -0
- package/axis-components/input-number/input-number.options.ts +17 -0
- package/axis-components/input-number/input-number.ts +30 -0
- package/axis-components/input-number/ng-package.json +5 -0
- package/axis-components/modal/design/config.ts +50 -0
- package/axis-components/modal/design/ng-package.json +5 -0
- package/axis-components/modal/design/set-modal-visible-handler/set-modal-visible-handler.css +0 -0
- package/axis-components/modal/design/set-modal-visible-handler/set-modal-visible-handler.html +15 -0
- package/axis-components/modal/design/set-modal-visible-handler/set-modal-visible-handler.ts +34 -0
- package/axis-components/modal/design/setting/setting.css +0 -0
- package/axis-components/modal/design/setting/setting.html +139 -0
- package/axis-components/modal/design/setting/setting.ts +92 -0
- package/axis-components/modal/modal.css +0 -0
- package/axis-components/modal/modal.html +7 -0
- package/axis-components/modal/modal.options.ts +20 -0
- package/axis-components/modal/modal.ts +57 -0
- package/axis-components/modal/ng-package.json +5 -0
- package/axis-components/ng-package.json +5 -0
- package/axis-components/scope/design/config.ts +59 -0
- package/axis-components/scope/design/ng-package.json +5 -0
- package/axis-components/scope/design/setting/datasource-editor/datasource-editor.css +28 -0
- package/axis-components/scope/design/setting/datasource-editor/datasource-editor.html +188 -0
- package/axis-components/scope/design/setting/datasource-editor/datasource-editor.ts +245 -0
- package/axis-components/scope/design/setting/setting.css +0 -0
- package/axis-components/scope/design/setting/setting.html +19 -0
- package/axis-components/scope/design/setting/setting.ts +30 -0
- package/axis-components/scope/ng-package.json +5 -0
- package/axis-components/scope/scope.css +6 -0
- package/axis-components/scope/scope.html +4 -0
- package/axis-components/scope/scope.options.ts +8 -0
- package/axis-components/scope/scope.ts +48 -0
- package/axis-components/single-selector/design/config.ts +30 -0
- package/axis-components/single-selector/design/ng-package.json +5 -0
- package/axis-components/single-selector/design/setting/setting.css +0 -0
- package/axis-components/single-selector/design/setting/setting.html +164 -0
- package/axis-components/single-selector/design/setting/setting.ts +80 -0
- package/axis-components/single-selector/ng-package.json +5 -0
- package/axis-components/single-selector/single-selector.css +8 -0
- package/axis-components/single-selector/single-selector.html +51 -0
- package/axis-components/single-selector/single-selector.options.ts +22 -0
- package/axis-components/single-selector/single-selector.ts +80 -0
- package/axis-components/splitter/design/config.ts +84 -0
- package/axis-components/splitter/design/ng-package.json +5 -0
- package/axis-components/splitter/design/splitter-menu/splitter-menu.css +0 -0
- package/axis-components/splitter/design/splitter-menu/splitter-menu.html +10 -0
- package/axis-components/splitter/design/splitter-menu/splitter-menu.ts +22 -0
- package/axis-components/splitter/design/splitter-panel-setting/splitter-panel-setting.css +0 -0
- package/axis-components/splitter/design/splitter-panel-setting/splitter-panel-setting.html +66 -0
- package/axis-components/splitter/design/splitter-panel-setting/splitter-panel-setting.ts +47 -0
- package/axis-components/splitter/design/splitter-setting/splitter-setting.css +0 -0
- package/axis-components/splitter/design/splitter-setting/splitter-setting.html +28 -0
- package/axis-components/splitter/design/splitter-setting/splitter-setting.ts +30 -0
- package/axis-components/splitter/ng-package.json +5 -0
- package/axis-components/splitter/splitter.css +7 -0
- package/axis-components/splitter/splitter.html +12 -0
- package/axis-components/splitter/splitter.options.ts +18 -0
- package/axis-components/splitter/splitter.ts +29 -0
- package/axis-components/table/design/config.ts +147 -0
- package/axis-components/table/design/ng-package.json +5 -0
- package/axis-components/table/design/table-field-setting/table-field-setting.css +0 -0
- package/axis-components/table/design/table-field-setting/table-field-setting.html +259 -0
- package/axis-components/table/design/table-field-setting/table-field-setting.ts +105 -0
- package/axis-components/table/design/table-fields-menu/table-fields-menu.css +0 -0
- package/axis-components/table/design/table-fields-menu/table-fields-menu.html +9 -0
- package/axis-components/table/design/table-fields-menu/table-fields-menu.ts +24 -0
- package/axis-components/table/design/table-setting/table-setting.css +0 -0
- package/axis-components/table/design/table-setting/table-setting.html +417 -0
- package/axis-components/table/design/table-setting/table-setting.ts +173 -0
- package/axis-components/table/expand.ts +12 -0
- package/axis-components/table/ng-package.json +5 -0
- package/axis-components/table/select.ts +66 -0
- package/axis-components/table/table-setter/table-setter.css +55 -0
- package/axis-components/table/table-setter/table-setter.html +38 -0
- package/axis-components/table/table-setter/table-setter.ts +121 -0
- package/axis-components/table/table.css +5 -0
- package/axis-components/table/table.html +191 -0
- package/axis-components/table/table.options.ts +72 -0
- package/axis-components/table/table.ts +204 -0
- package/axis-components/text/design/config.ts +30 -0
- package/axis-components/text/design/ng-package.json +5 -0
- package/axis-components/text/design/setting/setting.css +0 -0
- package/axis-components/text/design/setting/setting.html +84 -0
- package/axis-components/text/design/setting/setting.ts +54 -0
- package/axis-components/text/ng-package.json +5 -0
- package/axis-components/text/text.css +3 -0
- package/axis-components/text/text.html +17 -0
- package/axis-components/text/text.options.ts +10 -0
- package/axis-components/text/text.ts +54 -0
- package/axis-components/textarea/design/config.ts +30 -0
- package/axis-components/textarea/design/ng-package.json +5 -0
- package/axis-components/textarea/design/setting/setting.css +0 -0
- package/axis-components/textarea/design/setting/setting.html +76 -0
- package/axis-components/textarea/design/setting/setting.ts +55 -0
- package/axis-components/textarea/ng-package.json +5 -0
- package/axis-components/textarea/textarea.css +4 -0
- package/axis-components/textarea/textarea.html +11 -0
- package/axis-components/textarea/textarea.options.ts +13 -0
- package/axis-components/textarea/textarea.ts +49 -0
- package/axis-components/tree-selector/design/config.ts +55 -0
- package/axis-components/tree-selector/design/ng-package.json +5 -0
- package/axis-components/tree-selector/design/tree-selector-menu/tree-selector-menu.css +0 -0
- package/axis-components/tree-selector/design/tree-selector-menu/tree-selector-menu.html +9 -0
- package/axis-components/tree-selector/design/tree-selector-menu/tree-selector-menu.ts +26 -0
- package/axis-components/tree-selector/design/tree-selector-menu-setting/tree-selector-menu-setting.css +0 -0
- package/axis-components/tree-selector/design/tree-selector-menu-setting/tree-selector-menu-setting.html +80 -0
- package/axis-components/tree-selector/design/tree-selector-menu-setting/tree-selector-menu-setting.ts +58 -0
- package/axis-components/tree-selector/design/tree-selector-setting/tree-selector-setting.css +0 -0
- package/axis-components/tree-selector/design/tree-selector-setting/tree-selector-setting.html +235 -0
- package/axis-components/tree-selector/design/tree-selector-setting/tree-selector-setting.ts +87 -0
- package/axis-components/tree-selector/ng-package.json +5 -0
- package/axis-components/tree-selector/tree-selector.css +43 -0
- package/axis-components/tree-selector/tree-selector.html +65 -0
- package/axis-components/tree-selector/tree-selector.options.ts +50 -0
- package/axis-components/tree-selector/tree-selector.ts +252 -0
- package/axis-components/upload/design/config.ts +37 -0
- package/axis-components/upload/design/ng-package.json +5 -0
- package/axis-components/upload/design/setting/setting.css +0 -0
- package/axis-components/upload/design/setting/setting.html +288 -0
- package/axis-components/upload/design/setting/setting.ts +96 -0
- package/axis-components/upload/ng-package.json +5 -0
- package/axis-components/upload/upload.css +3 -0
- package/axis-components/upload/upload.html +36 -0
- package/axis-components/upload/upload.options.ts +29 -0
- package/axis-components/upload/upload.ts +130 -0
- package/axis-components-covers/badge.svg +1 -0
- package/axis-components-covers/button.svg +14 -0
- package/axis-components-covers/desc.svg +39 -0
- package/axis-components-covers/design.jpg +0 -0
- package/axis-components-covers/dynamic-container.svg +9 -0
- package/axis-components-covers/flex.svg +33 -0
- package/axis-components-covers/form-item.svg +22 -0
- package/axis-components-covers/form.svg +38 -0
- package/axis-components-covers/icon.svg +22 -0
- package/axis-components-covers/image.svg +13 -0
- package/axis-components-covers/input-component.svg +27 -0
- package/axis-components-covers/input-icon.svg +29 -0
- package/axis-components-covers/input-json.svg +29 -0
- package/axis-components-covers/input-number.svg +35 -0
- package/axis-components-covers/input.svg +21 -0
- package/axis-components-covers/modal.svg +23 -0
- package/axis-components-covers/scope.svg +9 -0
- package/axis-components-covers/single-selector.svg +20 -0
- package/axis-components-covers/splitter.svg +8 -0
- package/axis-components-covers/table.svg +27 -0
- package/axis-components-covers/text.svg +22 -0
- package/axis-components-covers/textarea.svg +9 -0
- package/axis-components-covers/tree-selector.svg +77 -0
- package/axis-components-covers/upload.svg +26 -0
- package/core/base/base-menu.ts +22 -0
- package/core/base/base.ts +143 -0
- package/core/base/design-builder.ts +8 -0
- package/core/base/funfield-base.ts +106 -0
- package/core/base/funfield-value-base.ts +53 -0
- package/core/base/value-access.ts +70 -0
- package/core/directives/dynamic.ts +216 -0
- package/core/directives/scope.ts +432 -0
- package/core/models/api.options.ts +5 -0
- package/core/models/base.options.ts +11 -0
- package/core/models/cmplib.ts +7 -0
- package/core/models/data-source.options.ts +11 -0
- package/core/models/data.options.ts +6 -0
- package/core/models/design-build.ts +26 -0
- package/core/models/design-config.ts +14 -0
- package/core/models/design-tree-node.ts +16 -0
- package/core/models/event-desc.ts +28 -0
- package/core/models/event-handler.ts +6 -0
- package/core/models/event.options.ts +14 -0
- package/core/models/examples.ts +21 -0
- package/core/models/form-registe.options.ts +12 -0
- package/core/models/fun-field.options.ts +6 -0
- package/core/models/initobs.ts +8 -0
- package/core/models/options-node.ts +149 -0
- package/core/models/static-data-source.options.ts +4 -0
- package/core/models/trigge-events.options.ts +3 -0
- package/core/models/value-access.options.ts +10 -0
- package/core/ng-package.json +5 -0
- package/core/pipes/how-long.pipe.ts +69 -0
- package/core/public-api.ts +39 -0
- package/core/share/api-handler/api-handler.css +0 -0
- package/core/share/api-handler/api-handler.html +38 -0
- package/core/share/api-handler/api-handler.ts +51 -0
- package/core/share/array-filter-handler/array-filter-handler.css +0 -0
- package/core/share/array-filter-handler/array-filter-handler.html +26 -0
- package/core/share/array-filter-handler/array-filter-handler.ts +65 -0
- package/core/share/array-filter-handler/input-filter-options/filter-options.css +19 -0
- package/core/share/array-filter-handler/input-filter-options/filter-options.html +57 -0
- package/core/share/array-filter-handler/input-filter-options/filter-options.ts +100 -0
- package/core/share/base-design-setting/base-design-setting.css +0 -0
- package/core/share/base-design-setting/base-design-setting.html +50 -0
- package/core/share/base-design-setting/base-design-setting.ts +55 -0
- package/core/share/base-event-handler-descs.ts +100 -0
- package/core/share/common-menu/common-menu.css +0 -0
- package/core/share/common-menu/common-menu.html +21 -0
- package/core/share/common-menu/common-menu.ts +73 -0
- package/core/share/data-handler/data-handler.css +0 -0
- package/core/share/data-handler/data-handler.html +13 -0
- package/core/share/data-handler/data-handler.ts +39 -0
- package/core/share/events-handler.service.ts +185 -0
- package/core/share/fun-field/fun-field.css +55 -0
- package/core/share/fun-field/fun-field.html +175 -0
- package/core/share/fun-field/fun-field.ts +363 -0
- package/core/share/input-trigger/input-trigger.css +16 -0
- package/core/share/input-trigger/input-trigger.html +114 -0
- package/core/share/input-trigger/input-trigger.ts +394 -0
- package/core/share/msg-tip-handler/msg-tip-handler.css +0 -0
- package/core/share/msg-tip-handler/msg-tip-handler.html +40 -0
- package/core/share/msg-tip-handler/msg-tip-handler.ts +46 -0
- package/core/share/refresh-data-source-handler/refresh-data-source-handler.css +0 -0
- package/core/share/refresh-data-source-handler/refresh-data-source-handler.html +29 -0
- package/core/share/refresh-data-source-handler/refresh-data-source-handler.ts +55 -0
- package/core/share/route-handler/route-handler.css +0 -0
- package/core/share/route-handler/route-handler.html +49 -0
- package/core/share/route-handler/route-handler.ts +51 -0
- package/core/share/set-data-source-handler/set-data-source-handler.css +0 -0
- package/core/share/set-data-source-handler/set-data-source-handler.html +23 -0
- package/core/share/set-data-source-handler/set-data-source-handler.ts +44 -0
- package/core/share/simple-menu/simple-menu.css +0 -0
- package/core/share/simple-menu/simple-menu.html +5 -0
- package/core/share/simple-menu/simple-menu.ts +17 -0
- package/core/share/tokens.ts +29 -0
- package/core/share/value-design-setting/value-design-setting.css +0 -0
- package/core/share/value-design-setting/value-design-setting.html +48 -0
- package/core/share/value-design-setting/value-design-setting.ts +54 -0
- package/core/utils/code-name.utils.ts +19 -0
- package/core/utils/components-loader.ts +29 -0
- package/core/utils/declaration.utils.ts +38 -0
- package/core/utils/dynamic.util.ts +57 -0
- package/core/utils/form-validators.ts +160 -0
- package/core/utils/form.util.ts +25 -0
- package/core/utils/http.utils.ts +8 -0
- package/core/utils/object.utils.ts +182 -0
- package/core/utils/scripts-loader.ts +25 -0
- package/ng-package.json +13 -0
- package/package.json +37 -0
- package/providers/ng-package.json +5 -0
- package/providers/providers.ts +44 -0
- package/providers/public-api.ts +1 -0
- package/public-api.ts +1 -0
- package/tsconfig.json +38 -0
- package/tsconfig.lib.json +19 -0
- package/tsconfig.lib.prod.json +11 -0
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
@if (options.readonly()) {
|
|
2
|
+
<span>
|
|
3
|
+
{{value()}}
|
|
4
|
+
</span>
|
|
5
|
+
}@else {
|
|
6
|
+
@if (options.variant()=="outlined") {
|
|
7
|
+
<nz-input-group [nzSuffix]="suffixTemplate" [nzPrefix]="prefixTemplate">
|
|
8
|
+
<input (keydown.enter)="onEnter()" [type]="options.type()" nz-input [disabled]="options.disabled()"
|
|
9
|
+
[(ngModel)]="inputValue" (ngModelChange)="inputSubject.next($event)" [placeholder]="options.placeholder()"
|
|
10
|
+
[maxLength]="options.maxlength()||9999999" [autofocus]="options.autofocus()" />
|
|
11
|
+
</nz-input-group>
|
|
12
|
+
<ng-template #prefixTemplate>
|
|
13
|
+
<div class="prefix-container">
|
|
14
|
+
@if (options.prefix()) {
|
|
15
|
+
<ng-container [axisDynamic]="options.prefix()"></ng-container>
|
|
16
|
+
}
|
|
17
|
+
</div>
|
|
18
|
+
</ng-template>
|
|
19
|
+
<ng-template #suffixTemplate>
|
|
20
|
+
<div class="suffix-container">
|
|
21
|
+
@if (options.suffix()) {
|
|
22
|
+
<ng-container [axisDynamic]="options.suffix()"></ng-container>
|
|
23
|
+
}
|
|
24
|
+
</div>
|
|
25
|
+
</ng-template>
|
|
26
|
+
}@else {
|
|
27
|
+
<input (keydown.enter)="onEnter()" [type]="options.type()" nz-input [nzVariant]="options.variant()"
|
|
28
|
+
[disabled]="options.disabled()" [(ngModel)]="inputValue" (ngModelChange)="inputSubject.next($event)"
|
|
29
|
+
[placeholder]="options.placeholder()" [maxLength]="options.maxlength()||9999999"
|
|
30
|
+
[autofocus]="options.autofocus()" />
|
|
31
|
+
}
|
|
32
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { signal } from "@angular/core";
|
|
2
|
+
import { ValueAccessOptions } from "ngx-axis-appforge/core";
|
|
3
|
+
|
|
4
|
+
export class InputOptions extends ValueAccessOptions {
|
|
5
|
+
|
|
6
|
+
readonly placeholder = signal("");
|
|
7
|
+
readonly maxlength = signal<number | null>(null);
|
|
8
|
+
readonly debounceTime = signal<number | null>(null);
|
|
9
|
+
readonly autofocus = signal<boolean>(false);
|
|
10
|
+
readonly type = signal<"text" | "password">("text");
|
|
11
|
+
readonly prefix = signal<any>(undefined);
|
|
12
|
+
readonly suffix = signal<any>(undefined);
|
|
13
|
+
readonly variant = signal<'outlined' | 'borderless' | 'filled' | 'underlined'>("outlined");
|
|
14
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component, effect, model } from '@angular/core';
|
|
2
|
+
import { InputOptions } from './input.options';
|
|
3
|
+
import { FormsModule } from '@angular/forms';
|
|
4
|
+
import { NzInputModule } from 'ng-zorro-antd/input';
|
|
5
|
+
import { DynamicDirective, ValueAccess } from 'ngx-axis-appforge/core';
|
|
6
|
+
import { debounceTime, Subject } from 'rxjs';
|
|
7
|
+
|
|
8
|
+
@Component({
|
|
9
|
+
selector: 'axis-input',
|
|
10
|
+
imports: [NzInputModule, FormsModule, DynamicDirective],
|
|
11
|
+
templateUrl: './input.html',
|
|
12
|
+
styleUrl: './input.css',
|
|
13
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
14
|
+
})
|
|
15
|
+
export class Input extends ValueAccess<InputOptions> {
|
|
16
|
+
constructor() {
|
|
17
|
+
super();
|
|
18
|
+
effect(() => {
|
|
19
|
+
this.unsubscribe(["change"]);
|
|
20
|
+
if (this.options.debounceTime() ?? 0 > 0) {
|
|
21
|
+
this.addSubscribe(this.inputSubject.pipe(debounceTime(this.options.debounceTime()!)).subscribe(value => {
|
|
22
|
+
this.value.set(value);
|
|
23
|
+
this.onChange?.(value);
|
|
24
|
+
}), "change");
|
|
25
|
+
} else {
|
|
26
|
+
this.addSubscribe(this.inputSubject.subscribe(value => {
|
|
27
|
+
this.value.set(value);
|
|
28
|
+
this.onChange?.(value);
|
|
29
|
+
}), "change");
|
|
30
|
+
}
|
|
31
|
+
});
|
|
32
|
+
effect(() => {
|
|
33
|
+
if (this.options.initValue() !== undefined) {
|
|
34
|
+
this.inputValue.set(this.options.initValue());
|
|
35
|
+
}
|
|
36
|
+
})
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
override options: InputOptions = new InputOptions();
|
|
40
|
+
|
|
41
|
+
readonly inputValue = model<string>();
|
|
42
|
+
readonly inputSubject = new Subject();
|
|
43
|
+
|
|
44
|
+
override writeValue(value: any): void {
|
|
45
|
+
super.writeValue(value);
|
|
46
|
+
this.inputValue.set(value);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
onEnter() {
|
|
50
|
+
this.triggeEvents("enterKeydown").subscribe();
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { NextInfo, DesignBuildResult, DesignBindElementsResult, DesignConfig, OptionsNode, SimpleMenu } from "ngx-axis-appforge/core";
|
|
2
|
+
import { Setting } from "./setting/setting";
|
|
3
|
+
|
|
4
|
+
export const Config: DesignConfig = {
|
|
5
|
+
|
|
6
|
+
componentName: "组件输入框",
|
|
7
|
+
buildOptionsNodes(nextInfo: NextInfo): DesignBuildResult {
|
|
8
|
+
return {
|
|
9
|
+
treeNode: new OptionsNode({
|
|
10
|
+
parentId: nextInfo.parentId,
|
|
11
|
+
scopeId: nextInfo.scopeId,
|
|
12
|
+
name: "组件输入框",
|
|
13
|
+
canSetting: true,
|
|
14
|
+
canDrag: true,
|
|
15
|
+
dragType: "component",
|
|
16
|
+
parentObj: nextInfo.parentObject,
|
|
17
|
+
indexOfParentObj: nextInfo.indexOfParent,
|
|
18
|
+
rootOptions: nextInfo.currentObject,
|
|
19
|
+
settingType: Setting,
|
|
20
|
+
contextMenu: SimpleMenu,
|
|
21
|
+
icon: "build"
|
|
22
|
+
})
|
|
23
|
+
};
|
|
24
|
+
},
|
|
25
|
+
bindElementsOptionsNode(element: HTMLElement, options: any): DesignBindElementsResult {
|
|
26
|
+
return {
|
|
27
|
+
[options.id]: { element }
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
};
|
|
File without changes
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
<form [formGroup]="fg" nz-form>
|
|
2
|
+
<nz-collapse [nzBordered]="false">
|
|
3
|
+
<nz-collapse-panel nzHeader="基本设置" nzActive>
|
|
4
|
+
<nz-form-item>
|
|
5
|
+
<nz-form-label nzSpan="8" nzTooltipTitle="注入的数据对象,格式:{数据名:数据}">
|
|
6
|
+
数据注入
|
|
7
|
+
</nz-form-label>
|
|
8
|
+
<nz-form-control nzSpan="16">
|
|
9
|
+
<axis-fun-field formControlName="injectData">
|
|
10
|
+
<ng-container ngModel [ngModelOptions]="{standalone:true}"
|
|
11
|
+
[axisDynamic]="{component:'axis-components/input-json',inuse:true}"
|
|
12
|
+
[standalone]="true"></ng-container>
|
|
13
|
+
</axis-fun-field>
|
|
14
|
+
</nz-form-control>
|
|
15
|
+
</nz-form-item>
|
|
16
|
+
<nz-form-item>
|
|
17
|
+
<nz-form-label nzSpan="8" nzTooltipTitle="可以选择的权限列表,格式:{权限编码:权限名字}">
|
|
18
|
+
权限列表
|
|
19
|
+
</nz-form-label>
|
|
20
|
+
<nz-form-control nzSpan="16">
|
|
21
|
+
<axis-fun-field formControlName="allPermissions">
|
|
22
|
+
<ng-container ngModel [ngModelOptions]="{standalone:true}"
|
|
23
|
+
[axisDynamic]="{component:'axis-components/input-json',inuse:true}"
|
|
24
|
+
[standalone]="true"></ng-container>
|
|
25
|
+
</axis-fun-field>
|
|
26
|
+
</nz-form-control>
|
|
27
|
+
</nz-form-item>
|
|
28
|
+
</nz-collapse-panel>
|
|
29
|
+
<axis-value-design-setting [fg]="fg"></axis-value-design-setting>
|
|
30
|
+
<axis-base-design-setting [fg]="fg"></axis-base-design-setting>
|
|
31
|
+
<axis-input-trigger formControlName="triggeEvents" [internalTriggers]="['valueChange']"></axis-input-trigger>
|
|
32
|
+
</nz-collapse>
|
|
33
|
+
</form>
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component } from '@angular/core';
|
|
2
|
+
import { FormsModule, ReactiveFormsModule, UntypedFormGroup } from '@angular/forms';
|
|
3
|
+
import { NzFormModule } from 'ng-zorro-antd/form';
|
|
4
|
+
import { NzInputModule } from 'ng-zorro-antd/input';
|
|
5
|
+
import { BaseDesignSetting, baseFbConfig, baseFunField, DynamicDirective, FunField, FunFieldOptions, FunFieldValueBase, InputTrigger, ValueDesignSetting, valueFbConfig, valueFunField } from 'ngx-axis-appforge/core';
|
|
6
|
+
import { NzCollapseModule } from 'ng-zorro-antd/collapse';
|
|
7
|
+
|
|
8
|
+
@Component({
|
|
9
|
+
selector: 'axis-design-input-icon-setting',
|
|
10
|
+
imports: [FormsModule, NzFormModule, ReactiveFormsModule, NzCollapseModule, NzInputModule, BaseDesignSetting, InputTrigger, ValueDesignSetting, DynamicDirective, FunField],
|
|
11
|
+
templateUrl: './setting.html',
|
|
12
|
+
styleUrl: './setting.css',
|
|
13
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
14
|
+
})
|
|
15
|
+
export class Setting extends FunFieldValueBase {
|
|
16
|
+
override fg: UntypedFormGroup = this.fb.group(({
|
|
17
|
+
...baseFbConfig,
|
|
18
|
+
...valueFbConfig,
|
|
19
|
+
injectData: [],
|
|
20
|
+
allPermissions: []
|
|
21
|
+
}));
|
|
22
|
+
|
|
23
|
+
protected override funFields: FunFieldOptions = {
|
|
24
|
+
...baseFunField,
|
|
25
|
+
...valueFunField,
|
|
26
|
+
injectData: {
|
|
27
|
+
defaultValue: {}
|
|
28
|
+
},
|
|
29
|
+
allPermissions: {
|
|
30
|
+
defaultValue: {}
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
<nz-input-group (click)="isVisible.set(!options.disabled())" [nzPrefix]="prefix" [nzSuffix]="suffix">
|
|
2
|
+
<input nz-input [disabled]="options.disabled()" [placeholder]="options.readonly()?'查看组件':'配置组件'" readonly />
|
|
3
|
+
</nz-input-group>
|
|
4
|
+
<ng-template #prefix>
|
|
5
|
+
<i nz-icon nzType="build"></i>
|
|
6
|
+
</ng-template>
|
|
7
|
+
<ng-template #suffix>
|
|
8
|
+
<i nz-icon [nzType]="options.readonly()?'eye':'edit'"></i>
|
|
9
|
+
</ng-template>
|
|
10
|
+
<nz-modal [(nzVisible)]="isVisible" (nzOnOk)="onOk()" (nzOnCancel)="isVisible.set(false)" nzWidth="800"
|
|
11
|
+
[nzBodyStyle]="{padding:'0',height:'70vh',overflow:'hidden',position:'relative'}" (nzAfterOpen)="afterOpen()">
|
|
12
|
+
<ng-container *nzModalTitle>
|
|
13
|
+
<div tabindex="-1" autofocus="true" (keydown.escape)="isVisible.set(false)">
|
|
14
|
+
<i nz-icon nzType="build"></i> {{options.readonly()?'查看组件':'配置组件'}}
|
|
15
|
+
</div>
|
|
16
|
+
</ng-container>
|
|
17
|
+
<div *nzModalContent #content style="height: 100%;" tabindex="-1" autofocus="true"
|
|
18
|
+
(keydown.escape)="isVisible.set(false)">
|
|
19
|
+
@if (!options.readonly()) {
|
|
20
|
+
<ng-container [axisDynamic]="designOptions()" [standalone]="true" [(ngModel)]="designValue"></ng-container>
|
|
21
|
+
}@else {
|
|
22
|
+
<ng-container [axisDynamic]="value()" [standalone]="true"></ng-container>
|
|
23
|
+
}
|
|
24
|
+
</div>
|
|
25
|
+
</nz-modal>
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { signal } from "@angular/core";
|
|
2
|
+
import { ValueAccessOptions } from "ngx-axis-appforge/core";
|
|
3
|
+
|
|
4
|
+
export class InputComponentOptions extends ValueAccessOptions {
|
|
5
|
+
readonly injectData = signal<any>({});
|
|
6
|
+
readonly allPermissions = signal<{ [permission: string]: string }>({});
|
|
7
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component, computed, ElementRef, model, ViewChild } from '@angular/core';
|
|
2
|
+
import { NzFormModule } from 'ng-zorro-antd/form';
|
|
3
|
+
import { NzInputModule } from 'ng-zorro-antd/input';
|
|
4
|
+
import { InputComponentOptions } from './input-component.options';
|
|
5
|
+
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
6
|
+
import { DynamicDirective, ValueAccess } from 'ngx-axis-appforge/core';
|
|
7
|
+
import { NzModalModule } from 'ng-zorro-antd/modal';
|
|
8
|
+
import { NzIconModule } from 'ng-zorro-antd/icon';
|
|
9
|
+
|
|
10
|
+
@Component({
|
|
11
|
+
selector: 'axis-input-component',
|
|
12
|
+
imports: [NzFormModule, NzInputModule, NzFormModule, DynamicDirective, NzModalModule, ReactiveFormsModule, NzIconModule, FormsModule],
|
|
13
|
+
templateUrl: './input-component.html',
|
|
14
|
+
styleUrl: './input-component.css',
|
|
15
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
16
|
+
})
|
|
17
|
+
export class InputComponent extends ValueAccess<InputComponentOptions> {
|
|
18
|
+
protected override options: InputComponentOptions = new InputComponentOptions();
|
|
19
|
+
|
|
20
|
+
readonly isVisible = model(false);
|
|
21
|
+
readonly designValue = model<any>();
|
|
22
|
+
readonly designOptions = computed(() => ({ component: 'axis-components/design', inuse: true, injectData: this.options.injectData(), allPermissions: this.options.allPermissions() }));
|
|
23
|
+
|
|
24
|
+
@ViewChild("content")
|
|
25
|
+
content?: ElementRef<HTMLElement>;
|
|
26
|
+
|
|
27
|
+
override writeValue(value: any): void {
|
|
28
|
+
super.writeValue(value);
|
|
29
|
+
this.designValue.set(this.value());
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
override setInitValue(value: any): void {
|
|
33
|
+
super.setInitValue(value);
|
|
34
|
+
if (this.value() !== undefined) {
|
|
35
|
+
this.designValue.set(this.value());
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
afterOpen() {
|
|
40
|
+
setTimeout(() => {
|
|
41
|
+
this.content?.nativeElement.focus();
|
|
42
|
+
}, 100);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
onOk() {
|
|
46
|
+
this.value.set({ ...this.designValue() });
|
|
47
|
+
this.onChange?.(this.value())
|
|
48
|
+
this.isVisible.set(false);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { NextInfo, DesignBuildResult, DesignBindElementsResult, DesignConfig, OptionsNode, SimpleMenu } from "ngx-axis-appforge/core";
|
|
2
|
+
import { Setting } from "./setting/setting";
|
|
3
|
+
|
|
4
|
+
export const Config: DesignConfig = {
|
|
5
|
+
|
|
6
|
+
componentName: "图标输入框",
|
|
7
|
+
buildOptionsNodes(nextInfo: NextInfo): DesignBuildResult {
|
|
8
|
+
return {
|
|
9
|
+
treeNode: new OptionsNode({
|
|
10
|
+
parentId: nextInfo.parentId,
|
|
11
|
+
scopeId: nextInfo.scopeId,
|
|
12
|
+
name: "图标输入框",
|
|
13
|
+
canSetting: true,
|
|
14
|
+
canDrag: true,
|
|
15
|
+
dragType: "component",
|
|
16
|
+
parentObj: nextInfo.parentObject,
|
|
17
|
+
indexOfParentObj: nextInfo.indexOfParent,
|
|
18
|
+
rootOptions: nextInfo.currentObject,
|
|
19
|
+
settingType: Setting,
|
|
20
|
+
contextMenu: SimpleMenu,
|
|
21
|
+
icon: "highlight"
|
|
22
|
+
})
|
|
23
|
+
};
|
|
24
|
+
},
|
|
25
|
+
bindElementsOptionsNode(element: HTMLElement, options: any): DesignBindElementsResult {
|
|
26
|
+
return {
|
|
27
|
+
[options.id]: { element }
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
};
|
|
File without changes
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
<form [formGroup]="fg" nz-form>
|
|
2
|
+
<nz-collapse [nzBordered]="false">
|
|
3
|
+
<nz-collapse-panel nzHeader="基本设置" nzActive>
|
|
4
|
+
<nz-form-item>
|
|
5
|
+
<nz-form-label nzSpan="8" nzRequired>
|
|
6
|
+
提示文本
|
|
7
|
+
</nz-form-label>
|
|
8
|
+
<nz-form-control nzSpan="16">
|
|
9
|
+
<axis-fun-field formControlName="placeholder">
|
|
10
|
+
<input nz-input ngModel [ngModelOptions]="{standalone:true}" />
|
|
11
|
+
</axis-fun-field>
|
|
12
|
+
</nz-form-control>
|
|
13
|
+
</nz-form-item>
|
|
14
|
+
<nz-form-item>
|
|
15
|
+
<nz-form-label nzSpan="8" nzRequired>
|
|
16
|
+
弹窗标题
|
|
17
|
+
</nz-form-label>
|
|
18
|
+
<nz-form-control nzSpan="16">
|
|
19
|
+
<axis-fun-field formControlName="modalTitle">
|
|
20
|
+
<input nz-input ngModel [ngModelOptions]="{standalone:true}" />
|
|
21
|
+
</axis-fun-field>
|
|
22
|
+
</nz-form-control>
|
|
23
|
+
</nz-form-item>
|
|
24
|
+
</nz-collapse-panel>
|
|
25
|
+
<axis-value-design-setting [fg]="fg"></axis-value-design-setting>
|
|
26
|
+
<axis-base-design-setting [fg]="fg"></axis-base-design-setting>
|
|
27
|
+
<axis-input-trigger formControlName="triggeEvents" [internalTriggers]="['valueChange']"></axis-input-trigger>
|
|
28
|
+
</nz-collapse>
|
|
29
|
+
</form>
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component } from '@angular/core';
|
|
2
|
+
import { FormsModule, ReactiveFormsModule, UntypedFormGroup } from '@angular/forms';
|
|
3
|
+
import { NzFormModule } from 'ng-zorro-antd/form';
|
|
4
|
+
import { NzInputModule } from 'ng-zorro-antd/input';
|
|
5
|
+
import { BaseDesignSetting, baseFbConfig, baseFunField, FunField, FunFieldOptions, FunFieldValueBase, InputTrigger, ValueDesignSetting, valueFbConfig, valueFunField } from 'ngx-axis-appforge/core';
|
|
6
|
+
import { NzCollapseModule } from 'ng-zorro-antd/collapse';
|
|
7
|
+
|
|
8
|
+
@Component({
|
|
9
|
+
selector: 'axis-design-input-icon-setting',
|
|
10
|
+
imports: [FormsModule, NzFormModule, ReactiveFormsModule, NzCollapseModule, NzInputModule, BaseDesignSetting, FunField, InputTrigger, ValueDesignSetting],
|
|
11
|
+
templateUrl: './setting.html',
|
|
12
|
+
styleUrl: './setting.css',
|
|
13
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
14
|
+
})
|
|
15
|
+
export class Setting extends FunFieldValueBase {
|
|
16
|
+
override fg: UntypedFormGroup = this.fb.group(({
|
|
17
|
+
...baseFbConfig,
|
|
18
|
+
...valueFbConfig,
|
|
19
|
+
placeholder: [],
|
|
20
|
+
modalTitle: [],
|
|
21
|
+
}));
|
|
22
|
+
|
|
23
|
+
protected override funFields: FunFieldOptions = {
|
|
24
|
+
...baseFunField,
|
|
25
|
+
...valueFunField,
|
|
26
|
+
placeholder: {
|
|
27
|
+
defaultValue: "设置图标"
|
|
28
|
+
},
|
|
29
|
+
modalTitle: {
|
|
30
|
+
defaultValue: "设置图标"
|
|
31
|
+
},
|
|
32
|
+
};
|
|
33
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
@if (!options.readonly()) {
|
|
2
|
+
<nz-input-group (click)="isVisible.set(!options.disabled())" [nzPrefix]="value()?.component? iconInp:undefined"
|
|
3
|
+
[nzSuffix]="iconSuffix">
|
|
4
|
+
<input nz-input [disabled]="options.disabled()" [placeholder]="options.placeholder()" readonly />
|
|
5
|
+
</nz-input-group>
|
|
6
|
+
<ng-template #iconInp>
|
|
7
|
+
<ng-container [axisDynamic]="value()" [standalone]="true"></ng-container>
|
|
8
|
+
</ng-template>
|
|
9
|
+
<ng-template #iconSuffix>
|
|
10
|
+
<i nz-icon nzType="right" style="color:rgba(0, 0, 0, 0.25)" nzTheme="outline"></i>
|
|
11
|
+
</ng-template>
|
|
12
|
+
<nz-modal [(nzVisible)]="isVisible" [nzTitle]="options.modalTitle()" (nzOnOk)="onOk()"
|
|
13
|
+
(nzOnCancel)="isVisible.set(false)" (nzAfterClose)="resetForm()">
|
|
14
|
+
<ng-container *nzModalContent>
|
|
15
|
+
<form [formGroup]="fg">
|
|
16
|
+
<nz-form-item>
|
|
17
|
+
<nz-form-label nzSpan="6" nzRequired>图标库</nz-form-label>
|
|
18
|
+
<nz-form-control nzSpan="18">
|
|
19
|
+
<nz-radio-group formControlName="lib">
|
|
20
|
+
<label nz-radio-button nzValue="antdesign">antdesign</label>
|
|
21
|
+
<label nz-radio-button nzValue="iconfont">iconfont</label>
|
|
22
|
+
</nz-radio-group>
|
|
23
|
+
</nz-form-control>
|
|
24
|
+
</nz-form-item>
|
|
25
|
+
@if (formValue() == undefined || formValue()?.lib == 'antdesign') {
|
|
26
|
+
<nz-form-item>
|
|
27
|
+
<nz-form-label nzSpan="6" nzRequired>图标主题</nz-form-label>
|
|
28
|
+
<nz-form-control nzSpan="18">
|
|
29
|
+
<nz-radio-group formControlName="theme">
|
|
30
|
+
<label nz-radio-button nzValue="outline">outline</label>
|
|
31
|
+
<label nz-radio-button nzValue="fill">fill</label>
|
|
32
|
+
<label nz-radio-button nzValue="twotone">twotone</label>
|
|
33
|
+
</nz-radio-group>
|
|
34
|
+
</nz-form-control>
|
|
35
|
+
</nz-form-item>
|
|
36
|
+
}
|
|
37
|
+
<nz-form-item>
|
|
38
|
+
<nz-form-label nzSpan="6" nzRequired>图标</nz-form-label>
|
|
39
|
+
<nz-form-control nzSpan="18">
|
|
40
|
+
<nz-input-group style="max-width: 200px;" [nzSuffix]="iconPreview">
|
|
41
|
+
<input autofocus placeholder="输入图标类型,如 edit" nz-input formControlName="icon" />
|
|
42
|
+
</nz-input-group>
|
|
43
|
+
<ng-template #iconPreview>
|
|
44
|
+
<ng-container [axisDynamic]="preview()" [standalone]="true"></ng-container>
|
|
45
|
+
</ng-template>
|
|
46
|
+
</nz-form-control>
|
|
47
|
+
</nz-form-item>
|
|
48
|
+
<nz-form-item>
|
|
49
|
+
<nz-form-label nzSpan="6">
|
|
50
|
+
antdesign 图标库
|
|
51
|
+
</nz-form-label>
|
|
52
|
+
<nz-form-control nzSpan="18">
|
|
53
|
+
<a target="_blank"
|
|
54
|
+
href="https://ng.ant.design/components/icon/zh">https://ng.ant.design/components/icon/zh</a>
|
|
55
|
+
</nz-form-control>
|
|
56
|
+
</nz-form-item>
|
|
57
|
+
<nz-form-item>
|
|
58
|
+
<nz-form-label nzSpan="6">
|
|
59
|
+
iconfont 图标库
|
|
60
|
+
</nz-form-label>
|
|
61
|
+
<nz-form-control nzSpan="18">
|
|
62
|
+
<a target="_blank" href="https://www.iconfont.cn/">https://www.iconfont.cn/</a>
|
|
63
|
+
</nz-form-control>
|
|
64
|
+
</nz-form-item>
|
|
65
|
+
</form>
|
|
66
|
+
</ng-container>
|
|
67
|
+
</nz-modal>
|
|
68
|
+
}@else if(value()?.comonent){
|
|
69
|
+
<ng-container [axisDynamic]="value()" [standalone]="true"></ng-container>
|
|
70
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component, computed, inject, model } from '@angular/core';
|
|
2
|
+
import { NzFormModule } from 'ng-zorro-antd/form';
|
|
3
|
+
import { NzInputModule } from 'ng-zorro-antd/input';
|
|
4
|
+
import { InputIconOptions } from './input-icon.options';
|
|
5
|
+
import { FormsModule, ReactiveFormsModule, UntypedFormBuilder } from '@angular/forms';
|
|
6
|
+
import { DynamicDirective, FormValidators, ValueAccess } from 'ngx-axis-appforge/core';
|
|
7
|
+
import { NzModalModule } from 'ng-zorro-antd/modal';
|
|
8
|
+
import { NzIconModule } from 'ng-zorro-antd/icon';
|
|
9
|
+
import { NzRadioModule } from 'ng-zorro-antd/radio';
|
|
10
|
+
import { toSignal } from '@angular/core/rxjs-interop';
|
|
11
|
+
|
|
12
|
+
@Component({
|
|
13
|
+
selector: 'axis-input-icon',
|
|
14
|
+
imports: [NzFormModule, NzInputModule, NzFormModule, DynamicDirective, NzModalModule, ReactiveFormsModule, NzIconModule, NzRadioModule, FormsModule],
|
|
15
|
+
templateUrl: './input-icon.html',
|
|
16
|
+
styleUrl: './input-icon.css',
|
|
17
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
18
|
+
})
|
|
19
|
+
export class InputIcon extends ValueAccess<InputIconOptions> {
|
|
20
|
+
protected override options: InputIconOptions = new InputIconOptions();
|
|
21
|
+
|
|
22
|
+
private readonly fb = inject(UntypedFormBuilder);
|
|
23
|
+
readonly fg = this.fb.group({
|
|
24
|
+
lib: ["antdesign", FormValidators.required],
|
|
25
|
+
theme: ["outline", FormValidators.required],
|
|
26
|
+
icon: [undefined, FormValidators.required]
|
|
27
|
+
});
|
|
28
|
+
readonly formValue = toSignal(this.fg.valueChanges);
|
|
29
|
+
readonly preview = computed(() => ({ component: "axis-components/icon", inuse: true, ...this.formValue() }))
|
|
30
|
+
|
|
31
|
+
isVisible = model(false);
|
|
32
|
+
|
|
33
|
+
override writeValue(value: any): void {
|
|
34
|
+
super.writeValue(value);
|
|
35
|
+
this.fg.reset(value);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
resetForm() {
|
|
39
|
+
this.fg.reset({
|
|
40
|
+
lib: "antdesign",
|
|
41
|
+
theme: "outline",
|
|
42
|
+
icon: undefined,
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
onOk() {
|
|
47
|
+
this.value.set(this.preview());
|
|
48
|
+
this.onChange?.(this.value())
|
|
49
|
+
this.isVisible.set(false);
|
|
50
|
+
}
|
|
51
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { NextInfo, DesignBuildResult, DesignBindElementsResult, DesignConfig, OptionsNode } from "ngx-axis-appforge/core";
|
|
2
|
+
import { Setting } from "./setting/setting";
|
|
3
|
+
|
|
4
|
+
export const Config: DesignConfig = {
|
|
5
|
+
|
|
6
|
+
componentName: "JSON输入框",
|
|
7
|
+
buildOptionsNodes(nextInfo: NextInfo): DesignBuildResult {
|
|
8
|
+
return {
|
|
9
|
+
treeNode: new OptionsNode({
|
|
10
|
+
parentId: nextInfo.parentId,
|
|
11
|
+
scopeId: nextInfo.scopeId,
|
|
12
|
+
name: "JSON输入框",
|
|
13
|
+
canSetting: true,
|
|
14
|
+
canDrag: true,
|
|
15
|
+
dragType: "component",
|
|
16
|
+
parentObj: nextInfo.parentObject,
|
|
17
|
+
indexOfParentObj: nextInfo.indexOfParent,
|
|
18
|
+
rootOptions: nextInfo.currentObject,
|
|
19
|
+
settingType: Setting,
|
|
20
|
+
icon: "file"
|
|
21
|
+
})
|
|
22
|
+
};
|
|
23
|
+
},
|
|
24
|
+
bindElementsOptionsNode(element: HTMLElement, options: any): DesignBindElementsResult {
|
|
25
|
+
return {
|
|
26
|
+
[options.id]: { element }
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
};
|
|
File without changes
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
<form [formGroup]="fg" nz-form>
|
|
2
|
+
<nz-collapse [nzBordered]="false">
|
|
3
|
+
<axis-value-design-setting [fg]="fg"></axis-value-design-setting>
|
|
4
|
+
<axis-base-design-setting [fg]="fg"></axis-base-design-setting>
|
|
5
|
+
<axis-input-trigger formControlName="triggeEvents" [internalTriggers]="['valueChange']"></axis-input-trigger>
|
|
6
|
+
</nz-collapse>
|
|
7
|
+
</form>
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component } from '@angular/core';
|
|
2
|
+
import { FormsModule, ReactiveFormsModule, UntypedFormGroup } from '@angular/forms';
|
|
3
|
+
import { NzFormModule } from 'ng-zorro-antd/form';
|
|
4
|
+
import { NzGridModule } from 'ng-zorro-antd/grid';
|
|
5
|
+
import { BaseDesignSetting, baseFbConfig, baseFunField, FunFieldOptions, FunFieldValueBase, InputTrigger, ValueDesignSetting, valueFbConfig, valueFunField } from 'ngx-axis-appforge/core';
|
|
6
|
+
import { NzCollapseModule } from 'ng-zorro-antd/collapse';
|
|
7
|
+
|
|
8
|
+
@Component({
|
|
9
|
+
selector: 'axis-design-input-json-setting',
|
|
10
|
+
imports: [NzFormModule, FormsModule, ReactiveFormsModule, NzGridModule, NzCollapseModule, ValueDesignSetting, BaseDesignSetting, InputTrigger],
|
|
11
|
+
templateUrl: './setting.html',
|
|
12
|
+
styleUrl: './setting.css',
|
|
13
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
14
|
+
})
|
|
15
|
+
export class Setting extends FunFieldValueBase {
|
|
16
|
+
override fg: UntypedFormGroup = this.fb.group(({
|
|
17
|
+
...baseFbConfig,
|
|
18
|
+
...valueFbConfig,
|
|
19
|
+
}));
|
|
20
|
+
|
|
21
|
+
protected override funFields: FunFieldOptions = {
|
|
22
|
+
...baseFunField,
|
|
23
|
+
...valueFunField,
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
}
|