@acorex/components 6.5.28 → 6.5.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/acorex-components.d.ts +5 -0
- package/esm2020/acorex-components.mjs +5 -0
- package/esm2020/lib/accordion/accordion.component.mjs +44 -0
- package/esm2020/lib/accordion/accordion.module.mjs +20 -0
- package/esm2020/lib/base/base-page.class.mjs +94 -0
- package/esm2020/lib/base/components.class.mjs +17 -0
- package/esm2020/lib/base/element.class.mjs +294 -0
- package/esm2020/lib/base/events.class.mjs +11 -0
- package/esm2020/lib/button/button.component.mjs +71 -0
- package/esm2020/lib/button/button.module.mjs +21 -0
- package/esm2020/lib/calendar/calendar-box/calendar-box.component.mjs +413 -0
- package/esm2020/lib/calendar/calendar-box/calendar-box.module.mjs +22 -0
- package/esm2020/lib/calendar/scheduler/scheduler-views.property.mjs +54 -0
- package/esm2020/lib/calendar/scheduler/scheduler.class.mjs +18 -0
- package/esm2020/lib/calendar/scheduler/scheduler.component.mjs +213 -0
- package/esm2020/lib/calendar/scheduler/scheduler.module.mjs +68 -0
- package/esm2020/lib/calendar/scheduler/toolbars/scheduler-toolbar-navigator.mjs +132 -0
- package/esm2020/lib/calendar/scheduler/toolbars/scheduler-toolbar-views.mjs +37 -0
- package/esm2020/lib/calendar/scheduler/views/agenda/scheduler-agenda-view.component.mjs +47 -0
- package/esm2020/lib/calendar/scheduler/views/daytime/scheduler-daytime-view.component.mjs +95 -0
- package/esm2020/lib/calendar/scheduler/views/month/scheduler-month-view.component.mjs +204 -0
- package/esm2020/lib/calendar/scheduler/views/scheduler-view.component.mjs +99 -0
- package/esm2020/lib/calendar/scheduler/views/timeline/scheduler-timeline-view.component.mjs +77 -0
- package/esm2020/lib/checkbox/checkbox.component.mjs +98 -0
- package/esm2020/lib/checkbox/checkbox.module.mjs +20 -0
- package/esm2020/lib/color-picker/color-box/color-box.component.mjs +422 -0
- package/esm2020/lib/color-picker/color-picker.component.mjs +82 -0
- package/esm2020/lib/color-picker/color-picker.module.mjs +24 -0
- package/esm2020/lib/context-menu/context-menu.component.mjs +65 -0
- package/esm2020/lib/context-menu/context-menu.directive.mjs +135 -0
- package/esm2020/lib/context-menu/context-menu.module.mjs +20 -0
- package/esm2020/lib/data-filter/columns/filter-column-date.component.mjs +138 -0
- package/esm2020/lib/data-filter/columns/filter-column-number.component.mjs +117 -0
- package/esm2020/lib/data-filter/columns/filter-column-selection.component.mjs +74 -0
- package/esm2020/lib/data-filter/columns/filter-column-string.component.mjs +117 -0
- package/esm2020/lib/data-filter/filter-panel/filter-panel.component.mjs +258 -0
- package/esm2020/lib/data-filter/filter.class.mjs +44 -0
- package/esm2020/lib/data-filter/filter.module.mjs +90 -0
- package/esm2020/lib/data-filter/toolbar/filter-toolbar.component.mjs +166 -0
- package/esm2020/lib/data-list/core/data-list.component.mjs +40 -0
- package/esm2020/lib/data-list/list/list.component.mjs +124 -0
- package/esm2020/lib/data-list/list/list.module.mjs +22 -0
- package/esm2020/lib/data-list/list/toolbar-list-view.component.mjs +85 -0
- package/esm2020/lib/data-source/datasource.component.mjs +47 -0
- package/esm2020/lib/data-source/datasource.module.mjs +18 -0
- package/esm2020/lib/data-source/read-param.mjs +5 -0
- package/esm2020/lib/date-picker/date-picker.component.mjs +702 -0
- package/esm2020/lib/date-picker/date-picker.module.mjs +25 -0
- package/esm2020/lib/dialog/dialog.component.mjs +24 -0
- package/esm2020/lib/dialog/dialog.module.mjs +21 -0
- package/esm2020/lib/dialog/dialog.service.mjs +150 -0
- package/esm2020/lib/drawer/content.component.mjs +18 -0
- package/esm2020/lib/drawer/drawer-container.component.mjs +36 -0
- package/esm2020/lib/drawer/drawer.component.mjs +142 -0
- package/esm2020/lib/drawer/drawer.module.mjs +23 -0
- package/esm2020/lib/dropdown/dropdown.component.mjs +176 -0
- package/esm2020/lib/dropdown/dropdown.module.mjs +26 -0
- package/esm2020/lib/fieldset/fieldset.component.mjs +59 -0
- package/esm2020/lib/fieldset/fieldset.module.mjs +19 -0
- package/esm2020/lib/form-group/form-group.component.mjs +34 -0
- package/esm2020/lib/form-group/form-group.module.mjs +21 -0
- package/esm2020/lib/label/label.component.mjs +19 -0
- package/esm2020/lib/label/label.module.mjs +21 -0
- package/esm2020/lib/loading/loading-indicator.component.mjs +17 -0
- package/esm2020/lib/loading/loading-panel.component.mjs +44 -0
- package/esm2020/lib/loading/loading.module.mjs +21 -0
- package/esm2020/lib/loading/loading.service.mjs +45 -0
- package/esm2020/lib/menu/menu-item.component.mjs +47 -0
- package/esm2020/lib/menu/menu.component.mjs +86 -0
- package/esm2020/lib/menu/menu.module.mjs +22 -0
- package/esm2020/lib/menu/menu2.component.mjs +96 -0
- package/esm2020/lib/number-box/number-box.component.mjs +622 -0
- package/esm2020/lib/number-box/number-box.module.mjs +21 -0
- package/esm2020/lib/page/content.component.mjs +32 -0
- package/esm2020/lib/page/footer.component.mjs +19 -0
- package/esm2020/lib/page/page.component.mjs +53 -0
- package/esm2020/lib/page/page.module.mjs +22 -0
- package/esm2020/lib/panel-box/panel-box.component.mjs +88 -0
- package/esm2020/lib/panel-box/panel-box.module.mjs +19 -0
- package/esm2020/lib/password-box/password-box.component.mjs +31 -0
- package/esm2020/lib/password-box/password-box.module.mjs +23 -0
- package/esm2020/lib/popover/custom-cdk-overlay.service.mjs +48 -0
- package/esm2020/lib/popover/overlay.service.mjs +90 -0
- package/esm2020/lib/popover/popover.component.mjs +127 -0
- package/esm2020/lib/popover/popover.module.mjs +19 -0
- package/esm2020/lib/popup/popup.component.mjs +147 -0
- package/esm2020/lib/popup/popup.module.mjs +25 -0
- package/esm2020/lib/popup/popup.service.mjs +93 -0
- package/esm2020/lib/progress-bar/progress-bar.component.mjs +19 -0
- package/esm2020/lib/progress-bar/progress-bar.module.mjs +19 -0
- package/esm2020/lib/property-editor/editors/check-editor/check-editor.mjs +61 -0
- package/esm2020/lib/property-editor/editors/check-editor/check.module.mjs +22 -0
- package/esm2020/lib/property-editor/editors/color-editor/color.editor.mjs +38 -0
- package/esm2020/lib/property-editor/editors/color-editor/color.module.mjs +24 -0
- package/esm2020/lib/property-editor/editors/column-editor/column.editor.mjs +115 -0
- package/esm2020/lib/property-editor/editors/column-editor/column.module.mjs +32 -0
- package/esm2020/lib/property-editor/editors/conditional-color-editor/conditional-color.editor.mjs +211 -0
- package/esm2020/lib/property-editor/editors/conditional-color-editor/conditional-color.module.mjs +78 -0
- package/esm2020/lib/property-editor/editors/date-editor/date.editor.mjs +51 -0
- package/esm2020/lib/property-editor/editors/date-editor/date.module.mjs +24 -0
- package/esm2020/lib/property-editor/editors/number-editor/number.editor.mjs +63 -0
- package/esm2020/lib/property-editor/editors/number-editor/number.module.mjs +24 -0
- package/esm2020/lib/property-editor/editors/range-editor/range.editor.mjs +140 -0
- package/esm2020/lib/property-editor/editors/range-editor/range.module.mjs +61 -0
- package/esm2020/lib/property-editor/editors/searchbar-selectbox-editor/searchbar-selectbox-editor.mjs +72 -0
- package/esm2020/lib/property-editor/editors/selectbox-editor/selectbox.editor.mjs +71 -0
- package/esm2020/lib/property-editor/editors/selectbox-editor/selectbox.module.mjs +25 -0
- package/esm2020/lib/property-editor/editors/selection-editor/selection-editor.mjs +69 -0
- package/esm2020/lib/property-editor/editors/selection-editor/selection.module.mjs +22 -0
- package/esm2020/lib/property-editor/editors/switch-editor/number.editor.mjs +29 -0
- package/esm2020/lib/property-editor/editors/switch-editor/number.module.mjs +25 -0
- package/esm2020/lib/property-editor/editors/text-editor/text.editor.mjs +32 -0
- package/esm2020/lib/property-editor/editors/text-editor/text.module.mjs +24 -0
- package/esm2020/lib/property-editor/editors/textarea-editor/textarea.editor.mjs +32 -0
- package/esm2020/lib/property-editor/editors/textarea-editor/textarea.module.mjs +24 -0
- package/esm2020/lib/property-editor/editors/time-editor/time.editor.mjs +43 -0
- package/esm2020/lib/property-editor/editors/time-editor/time.module.mjs +24 -0
- package/esm2020/lib/property-editor/property-editor-renderer.directive.mjs +154 -0
- package/esm2020/lib/property-editor/property-editor.class.mjs +101 -0
- package/esm2020/lib/property-editor/property-editor.module.mjs +196 -0
- package/esm2020/lib/query-builder/query-builder-group.component.mjs +124 -0
- package/esm2020/lib/query-builder/query-builder-popup/query-builder-popup.component.mjs +171 -0
- package/esm2020/lib/query-builder/query-builder-rule.component.mjs +395 -0
- package/esm2020/lib/query-builder/query-builder.class.mjs +20 -0
- package/esm2020/lib/query-builder/query-builder.component.mjs +82 -0
- package/esm2020/lib/query-builder/query-builder.module.mjs +62 -0
- package/esm2020/lib/query-builder/query-builder.service.mjs +197 -0
- package/esm2020/lib/search-bar/search-bar.component.mjs +283 -0
- package/esm2020/lib/search-bar/search-bar.module.mjs +63 -0
- package/esm2020/lib/searchbox/searchbox.component.mjs +79 -0
- package/esm2020/lib/searchbox/searchbox.module.mjs +24 -0
- package/esm2020/lib/selectbox/selectbox.component.mjs +961 -0
- package/esm2020/lib/selectbox/selectbox.module.mjs +44 -0
- package/esm2020/lib/selectbox/selectbox2.component.mjs +574 -0
- package/esm2020/lib/selection-list/selection-list.component.mjs +108 -0
- package/esm2020/lib/selection-list/selection-list.module.mjs +21 -0
- package/esm2020/lib/switch/switch.component.mjs +51 -0
- package/esm2020/lib/switch/switch.module.mjs +20 -0
- package/esm2020/lib/tab-page/tab-page-Renderer.component.mjs +71 -0
- package/esm2020/lib/tab-page/tab-page-host.component.mjs +116 -0
- package/esm2020/lib/tab-page/tab-page.module.mjs +21 -0
- package/esm2020/lib/tab-page/tab-page.service.mjs +156 -0
- package/esm2020/lib/tab-strip/tab-strip.component.mjs +36 -0
- package/esm2020/lib/tab-strip/tab-strip.module.mjs +19 -0
- package/esm2020/lib/tab-view/dynamic-tabs.directive.mjs +24 -0
- package/esm2020/lib/tab-view/tab-view.component.mjs +105 -0
- package/esm2020/lib/tab-view/tab-view.module.mjs +21 -0
- package/esm2020/lib/tab-view/tab.component.mjs +30 -0
- package/esm2020/lib/textarea/textarea.component.mjs +26 -0
- package/esm2020/lib/textarea/textarea.module.mjs +21 -0
- package/esm2020/lib/textbox/textbox.component.mjs +39 -0
- package/esm2020/lib/textbox/textbox.module.mjs +24 -0
- package/esm2020/lib/time-picker/time-picker.component.mjs +943 -0
- package/esm2020/lib/time-picker/time-picker.module.mjs +22 -0
- package/esm2020/lib/toast/toast-message/toast-message.component.mjs +74 -0
- package/esm2020/lib/toast/toast-wrapper/toast-wrapper.component.mjs +13 -0
- package/esm2020/lib/toast/toast.module.mjs +21 -0
- package/esm2020/lib/toast/toast.service.mjs +44 -0
- package/esm2020/lib/toolbar/group-button/toolbar-group-button.component.mjs +78 -0
- package/esm2020/lib/toolbar/menu/toolbar-menu.component.mjs +57 -0
- package/esm2020/lib/toolbar/search/toolbar-search.component.mjs +54 -0
- package/esm2020/lib/toolbar/title/toolbar-title.component.mjs +47 -0
- package/esm2020/lib/toolbar/toolbar-item.mjs +6 -0
- package/esm2020/lib/toolbar/toolbar.component.mjs +13 -0
- package/esm2020/lib/toolbar/toolbar.module.mjs +40 -0
- package/esm2020/lib/tooltip/tooltip.directive.mjs +100 -0
- package/esm2020/lib/tooltip/tooltip.module.mjs +19 -0
- package/esm2020/lib/tree-side-menu/tree-side-menu.component.mjs +646 -0
- package/esm2020/lib/tree-side-menu/tree-side-menu.module.mjs +35 -0
- package/esm2020/lib/tree-view/tree-view.component.mjs +775 -0
- package/esm2020/lib/tree-view/tree-view.module.mjs +22 -0
- package/esm2020/lib/upload-file/upload-file.component.mjs +208 -0
- package/esm2020/lib/upload-file/upload-file.events.mjs +2 -0
- package/esm2020/lib/upload-file/upload-file.module.mjs +24 -0
- package/esm2020/lib/validation/validation-form.component.mjs +65 -0
- package/esm2020/lib/validation/validation-rule.widget.mjs +111 -0
- package/esm2020/lib/validation/validation.class.mjs +2 -0
- package/esm2020/lib/validation/validation.component.mjs +89 -0
- package/esm2020/lib/validation/validation.module.mjs +34 -0
- package/esm2020/public-api.mjs +158 -0
- package/fesm2015/acorex-components.mjs +15988 -0
- package/fesm2015/acorex-components.mjs.map +1 -0
- package/fesm2020/acorex-components.mjs +15923 -0
- package/fesm2020/acorex-components.mjs.map +1 -0
- package/lib/accordion/accordion.component.d.ts +13 -0
- package/lib/accordion/accordion.module.d.ts +9 -0
- package/lib/base/base-page.class.d.ts +46 -0
- package/lib/base/components.class.d.ts +10 -0
- package/lib/base/element.class.d.ts +106 -0
- package/lib/base/events.class.d.ts +18 -0
- package/lib/button/button.component.d.ts +21 -0
- package/lib/button/button.module.d.ts +8 -0
- package/lib/calendar/calendar-box/calendar-box.component.d.ts +81 -0
- package/lib/calendar/calendar-box/calendar-box.module.d.ts +11 -0
- package/lib/calendar/scheduler/scheduler-views.property.d.ts +19 -0
- package/{src/lib/calendar/scheduler/scheduler.class.ts → lib/calendar/scheduler/scheduler.class.d.ts} +36 -50
- package/lib/calendar/scheduler/scheduler.component.d.ts +39 -0
- package/lib/calendar/scheduler/scheduler.module.d.ts +21 -0
- package/lib/calendar/scheduler/toolbars/scheduler-toolbar-navigator.d.ts +25 -0
- package/lib/calendar/scheduler/toolbars/scheduler-toolbar-views.d.ts +14 -0
- package/lib/calendar/scheduler/views/agenda/scheduler-agenda-view.component.d.ts +16 -0
- package/lib/calendar/scheduler/views/daytime/scheduler-daytime-view.component.d.ts +26 -0
- package/lib/calendar/scheduler/views/month/scheduler-month-view.component.d.ts +37 -0
- package/lib/calendar/scheduler/views/scheduler-view.component.d.ts +28 -0
- package/lib/calendar/scheduler/views/timeline/scheduler-timeline-view.component.d.ts +24 -0
- package/lib/checkbox/checkbox.component.d.ts +30 -0
- package/lib/checkbox/checkbox.module.d.ts +9 -0
- package/lib/color-picker/color-box/color-box.component.d.ts +25 -0
- package/lib/color-picker/color-picker.component.d.ts +30 -0
- package/lib/color-picker/color-picker.module.d.ts +13 -0
- package/lib/context-menu/context-menu.component.d.ts +22 -0
- package/lib/context-menu/context-menu.directive.d.ts +38 -0
- package/lib/context-menu/context-menu.module.d.ts +9 -0
- package/lib/data-filter/columns/filter-column-date.component.d.ts +22 -0
- package/lib/data-filter/columns/filter-column-number.component.d.ts +15 -0
- package/lib/data-filter/columns/filter-column-selection.component.d.ts +18 -0
- package/lib/data-filter/columns/filter-column-string.component.d.ts +15 -0
- package/lib/data-filter/filter-panel/filter-panel.component.d.ts +45 -0
- package/lib/data-filter/filter.class.d.ts +40 -0
- package/lib/data-filter/filter.module.d.ts +24 -0
- package/lib/data-filter/toolbar/filter-toolbar.component.d.ts +25 -0
- package/lib/data-list/core/data-list.component.d.ts +15 -0
- package/lib/data-list/list/list.component.d.ts +40 -0
- package/lib/data-list/list/list.module.d.ts +11 -0
- package/lib/data-list/list/toolbar-list-view.component.d.ts +17 -0
- package/lib/data-source/datasource.component.d.ts +16 -0
- package/lib/data-source/datasource.module.d.ts +7 -0
- package/{src/lib/data-source/read-param.ts → lib/data-source/read-param.d.ts} +40 -50
- package/lib/date-picker/date-picker.component.d.ts +81 -0
- package/lib/date-picker/date-picker.module.d.ts +14 -0
- package/lib/dialog/dialog.component.d.ts +14 -0
- package/lib/dialog/dialog.module.d.ts +10 -0
- package/lib/dialog/dialog.service.d.ts +36 -0
- package/lib/drawer/content.component.d.ts +7 -0
- package/lib/drawer/drawer-container.component.d.ts +10 -0
- package/lib/drawer/drawer.component.d.ts +34 -0
- package/lib/drawer/drawer.module.d.ts +10 -0
- package/lib/dropdown/dropdown.component.d.ts +38 -0
- package/lib/dropdown/dropdown.module.d.ts +13 -0
- package/lib/fieldset/fieldset.component.d.ts +11 -0
- package/lib/fieldset/fieldset.module.d.ts +8 -0
- package/lib/form-group/form-group.component.d.ts +14 -0
- package/lib/form-group/form-group.module.d.ts +8 -0
- package/lib/label/label.component.d.ts +9 -0
- package/lib/label/label.module.d.ts +8 -0
- package/lib/loading/loading-indicator.component.d.ts +9 -0
- package/lib/loading/loading-panel.component.d.ts +13 -0
- package/lib/loading/loading.module.d.ts +10 -0
- package/lib/loading/loading.service.d.ts +13 -0
- package/lib/menu/menu-item.component.d.ts +18 -0
- package/lib/menu/menu.component.d.ts +35 -0
- package/lib/menu/menu.module.d.ts +11 -0
- package/lib/menu/menu2.component.d.ts +21 -0
- package/lib/number-box/number-box.component.d.ts +52 -0
- package/lib/number-box/number-box.module.d.ts +10 -0
- package/lib/page/content.component.d.ts +8 -0
- package/lib/page/footer.component.d.ts +5 -0
- package/lib/page/page.component.d.ts +16 -0
- package/lib/page/page.module.d.ts +11 -0
- package/lib/panel-box/panel-box.component.d.ts +19 -0
- package/lib/panel-box/panel-box.module.d.ts +8 -0
- package/lib/password-box/password-box.component.d.ts +12 -0
- package/lib/password-box/password-box.module.d.ts +10 -0
- package/lib/popover/custom-cdk-overlay.service.d.ts +19 -0
- package/lib/popover/overlay.service.d.ts +31 -0
- package/lib/popover/popover.component.d.ts +34 -0
- package/lib/popover/popover.module.d.ts +8 -0
- package/lib/popup/popup.component.d.ts +40 -0
- package/lib/popup/popup.module.d.ts +13 -0
- package/lib/popup/popup.service.d.ts +22 -0
- package/lib/progress-bar/progress-bar.component.d.ts +7 -0
- package/lib/progress-bar/progress-bar.module.d.ts +8 -0
- package/lib/property-editor/editors/check-editor/check-editor.d.ts +19 -0
- package/lib/property-editor/editors/check-editor/check.module.d.ts +11 -0
- package/lib/property-editor/editors/color-editor/color.editor.d.ts +13 -0
- package/lib/property-editor/editors/color-editor/color.module.d.ts +12 -0
- package/lib/property-editor/editors/column-editor/column.editor.d.ts +34 -0
- package/lib/property-editor/editors/column-editor/column.module.d.ts +20 -0
- package/lib/property-editor/editors/conditional-color-editor/conditional-color.editor.d.ts +44 -0
- package/lib/property-editor/editors/conditional-color-editor/conditional-color.module.d.ts +19 -0
- package/lib/property-editor/editors/date-editor/date.editor.d.ts +28 -0
- package/lib/property-editor/editors/date-editor/date.module.d.ts +12 -0
- package/lib/property-editor/editors/number-editor/number.editor.d.ts +20 -0
- package/lib/property-editor/editors/number-editor/number.module.d.ts +12 -0
- package/lib/property-editor/editors/range-editor/range.editor.d.ts +29 -0
- package/lib/property-editor/editors/range-editor/range.module.d.ts +18 -0
- package/lib/property-editor/editors/searchbar-selectbox-editor/searchbar-selectbox-editor.d.ts +29 -0
- package/lib/property-editor/editors/selectbox-editor/selectbox.editor.d.ts +28 -0
- package/lib/property-editor/editors/selectbox-editor/selectbox.module.d.ts +14 -0
- package/lib/property-editor/editors/selection-editor/selection-editor.d.ts +25 -0
- package/lib/property-editor/editors/selection-editor/selection.module.d.ts +11 -0
- package/lib/property-editor/editors/switch-editor/number.editor.d.ts +11 -0
- package/lib/property-editor/editors/switch-editor/number.module.d.ts +13 -0
- package/lib/property-editor/editors/text-editor/text.editor.d.ts +18 -0
- package/lib/property-editor/editors/text-editor/text.module.d.ts +12 -0
- package/lib/property-editor/editors/textarea-editor/textarea.editor.d.ts +17 -0
- package/lib/property-editor/editors/textarea-editor/textarea.module.d.ts +12 -0
- package/lib/property-editor/editors/time-editor/time.editor.d.ts +17 -0
- package/lib/property-editor/editors/time-editor/time.module.d.ts +12 -0
- package/lib/property-editor/property-editor-renderer.directive.d.ts +30 -0
- package/lib/property-editor/property-editor.class.d.ts +92 -0
- package/lib/property-editor/property-editor.module.d.ts +21 -0
- package/lib/query-builder/query-builder-group.component.d.ts +33 -0
- package/lib/query-builder/query-builder-popup/query-builder-popup.component.d.ts +35 -0
- package/lib/query-builder/query-builder-rule.component.d.ts +45 -0
- package/lib/query-builder/query-builder.class.d.ts +45 -0
- package/lib/query-builder/query-builder.component.d.ts +27 -0
- package/lib/query-builder/query-builder.module.d.ts +23 -0
- package/lib/query-builder/query-builder.service.d.ts +18 -0
- package/lib/search-bar/search-bar.component.d.ts +61 -0
- package/lib/search-bar/search-bar.module.d.ts +18 -0
- package/lib/searchbox/searchbox.component.d.ts +22 -0
- package/lib/searchbox/searchbox.module.d.ts +13 -0
- package/lib/selectbox/selectbox.component.d.ts +118 -0
- package/lib/selectbox/selectbox.module.d.ts +15 -0
- package/lib/selectbox/selectbox2.component.d.ts +103 -0
- package/lib/selection-list/selection-list.component.d.ts +32 -0
- package/lib/selection-list/selection-list.module.d.ts +10 -0
- package/lib/switch/switch.component.d.ts +20 -0
- package/lib/switch/switch.module.d.ts +9 -0
- package/lib/tab-page/tab-page-Renderer.component.d.ts +16 -0
- package/lib/tab-page/tab-page-host.component.d.ts +25 -0
- package/lib/tab-page/tab-page.module.d.ts +10 -0
- package/lib/tab-page/tab-page.service.d.ts +30 -0
- package/lib/tab-strip/tab-strip.component.d.ts +28 -0
- package/lib/tab-strip/tab-strip.module.d.ts +8 -0
- package/lib/tab-view/dynamic-tabs.directive.d.ts +16 -0
- package/lib/tab-view/tab-view.component.d.ts +26 -0
- package/lib/tab-view/tab-view.module.d.ts +10 -0
- package/lib/tab-view/tab.component.d.ts +12 -0
- package/lib/textarea/textarea.component.d.ts +12 -0
- package/lib/textarea/textarea.module.d.ts +8 -0
- package/lib/textbox/textbox.component.d.ts +16 -0
- package/lib/textbox/textbox.module.d.ts +11 -0
- package/lib/time-picker/time-picker.component.d.ts +52 -0
- package/lib/time-picker/time-picker.module.d.ts +11 -0
- package/lib/toast/toast-message/toast-message.component.d.ts +18 -0
- package/lib/toast/toast-wrapper/toast-wrapper.component.d.ts +8 -0
- package/lib/toast/toast.module.d.ts +9 -0
- package/lib/toast/toast.service.d.ts +18 -0
- package/lib/toolbar/group-button/toolbar-group-button.component.d.ts +12 -0
- package/lib/toolbar/menu/toolbar-menu.component.d.ts +24 -0
- package/lib/toolbar/search/toolbar-search.component.d.ts +16 -0
- package/lib/toolbar/title/toolbar-title.component.d.ts +9 -0
- package/lib/toolbar/toolbar-item.d.ts +3 -0
- package/lib/toolbar/toolbar.component.d.ts +8 -0
- package/lib/toolbar/toolbar.module.d.ts +14 -0
- package/lib/tooltip/tooltip.directive.d.ts +21 -0
- package/lib/tooltip/tooltip.module.d.ts +8 -0
- package/lib/tree-side-menu/tree-side-menu.component.d.ts +111 -0
- package/lib/tree-side-menu/tree-side-menu.module.d.ts +11 -0
- package/lib/tree-view/tree-view.component.d.ts +121 -0
- package/lib/tree-view/tree-view.module.d.ts +11 -0
- package/lib/upload-file/upload-file.component.d.ts +42 -0
- package/lib/upload-file/upload-file.events.d.ts +10 -0
- package/lib/upload-file/upload-file.module.d.ts +13 -0
- package/lib/validation/validation-form.component.d.ts +19 -0
- package/lib/validation/validation-rule.widget.d.ts +23 -0
- package/lib/validation/validation.class.d.ts +16 -0
- package/lib/validation/validation.component.d.ts +25 -0
- package/lib/validation/validation.module.d.ts +11 -0
- package/package.json +33 -13
- package/{src/public-api.ts → public-api.d.ts} +155 -214
- package/karma.conf.js +0 -32
- package/ng-package.json +0 -10
- package/src/lib/accordion/accordion.component.ts +0 -43
- package/src/lib/accordion/accordion.module.ts +0 -11
- package/src/lib/accordion/api.ts +0 -2
- package/src/lib/base/base-page.class.ts +0 -116
- package/src/lib/base/components.class.ts +0 -9
- package/src/lib/base/element.class.ts +0 -344
- package/src/lib/base/events.class.ts +0 -32
- package/src/lib/button/button.component.html +0 -17
- package/src/lib/button/button.component.ts +0 -72
- package/src/lib/button/button.module.ts +0 -14
- package/src/lib/calendar/calendar-box/calendar-box.component.html +0 -68
- package/src/lib/calendar/calendar-box/calendar-box.component.ts +0 -461
- package/src/lib/calendar/calendar-box/calendar-box.module.ts +0 -16
- package/src/lib/calendar/scheduler/scheduler-views.property.ts +0 -38
- package/src/lib/calendar/scheduler/scheduler.component.html +0 -9
- package/src/lib/calendar/scheduler/scheduler.component.scss +0 -181
- package/src/lib/calendar/scheduler/scheduler.component.ts +0 -249
- package/src/lib/calendar/scheduler/scheduler.module.ts +0 -45
- package/src/lib/calendar/scheduler/toolbars/scheduler-toolbar-navigator.ts +0 -133
- package/src/lib/calendar/scheduler/toolbars/scheduler-toolbar-views.ts +0 -33
- package/src/lib/calendar/scheduler/views/agenda/scheduler-agenda-view.component.html +0 -43
- package/src/lib/calendar/scheduler/views/agenda/scheduler-agenda-view.component.scss +0 -66
- package/src/lib/calendar/scheduler/views/agenda/scheduler-agenda-view.component.ts +0 -50
- package/src/lib/calendar/scheduler/views/daytime/scheduler-daytime-view.component.html +0 -45
- package/src/lib/calendar/scheduler/views/daytime/scheduler-daytime-view.component.scss +0 -19
- package/src/lib/calendar/scheduler/views/daytime/scheduler-daytime-view.component.ts +0 -103
- package/src/lib/calendar/scheduler/views/month/scheduler-month-view.component.html +0 -39
- package/src/lib/calendar/scheduler/views/month/scheduler-month-view.component.scss +0 -55
- package/src/lib/calendar/scheduler/views/month/scheduler-month-view.component.ts +0 -233
- package/src/lib/calendar/scheduler/views/scheduler-view.component.ts +0 -124
- package/src/lib/calendar/scheduler/views/timeline/scheduler-timeline-view.component.html +0 -50
- package/src/lib/calendar/scheduler/views/timeline/scheduler-timeline-view.component.scss +0 -4
- package/src/lib/calendar/scheduler/views/timeline/scheduler-timeline-view.component.ts +0 -92
- package/src/lib/checkbox/checkbox.component.html +0 -22
- package/src/lib/checkbox/checkbox.component.ts +0 -107
- package/src/lib/checkbox/checkbox.module.ts +0 -11
- package/src/lib/color-picker/color-box/color-box.component.html +0 -37
- package/src/lib/color-picker/color-box/color-box.component.scss +0 -60
- package/src/lib/color-picker/color-box/color-box.component.ts +0 -438
- package/src/lib/color-picker/color-picker.component.html +0 -31
- package/src/lib/color-picker/color-picker.component.ts +0 -87
- package/src/lib/color-picker/color-picker.module.ts +0 -16
- package/src/lib/context-menu/context-menu.component.html +0 -42
- package/src/lib/context-menu/context-menu.component.ts +0 -78
- package/src/lib/context-menu/context-menu.directive.ts +0 -159
- package/src/lib/context-menu/context-menu.module.ts +0 -15
- package/src/lib/data-filter/columns/filter-column-date.component.ts +0 -123
- package/src/lib/data-filter/columns/filter-column-number.component.ts +0 -100
- package/src/lib/data-filter/columns/filter-column-selection.component.ts +0 -69
- package/src/lib/data-filter/columns/filter-column-string.component.ts +0 -100
- package/src/lib/data-filter/filter-panel/filter-panel.component.html +0 -120
- package/src/lib/data-filter/filter-panel/filter-panel.component.scss +0 -143
- package/src/lib/data-filter/filter-panel/filter-panel.component.ts +0 -266
- package/src/lib/data-filter/filter.class.ts +0 -73
- package/src/lib/data-filter/filter.module.ts +0 -52
- package/src/lib/data-filter/toolbar/filter-toolbar.component.html +0 -5
- package/src/lib/data-filter/toolbar/filter-toolbar.component.scss +0 -17
- package/src/lib/data-filter/toolbar/filter-toolbar.component.ts +0 -179
- package/src/lib/data-list/core/data-list.component.ts +0 -62
- package/src/lib/data-list/list/list.component.html +0 -32
- package/src/lib/data-list/list/list.component.scss +0 -64
- package/src/lib/data-list/list/list.component.ts +0 -149
- package/src/lib/data-list/list/list.module.ts +0 -14
- package/src/lib/data-list/list/toolbar-list-view.component.ts +0 -63
- package/src/lib/data-source/datasource.component.ts +0 -50
- package/src/lib/data-source/datasource.module.ts +0 -11
- package/src/lib/date-picker/date-picker.component.html +0 -30
- package/src/lib/date-picker/date-picker.component.scss +0 -5
- package/src/lib/date-picker/date-picker.component.ts +0 -720
- package/src/lib/date-picker/date-picker.module.ts +0 -17
- package/src/lib/dialog/dialog.component.html +0 -5
- package/src/lib/dialog/dialog.component.scss +0 -32
- package/src/lib/dialog/dialog.component.ts +0 -32
- package/src/lib/dialog/dialog.module.ts +0 -13
- package/src/lib/dialog/dialog.service.ts +0 -178
- package/src/lib/drawer/content.component.ts +0 -18
- package/src/lib/drawer/drawer-container.component.ts +0 -37
- package/src/lib/drawer/drawer.component.ts +0 -151
- package/src/lib/drawer/drawer.module.ts +0 -16
- package/src/lib/dropdown/dropdown.component.html +0 -26
- package/src/lib/dropdown/dropdown.component.scss +0 -8
- package/src/lib/dropdown/dropdown.component.ts +0 -197
- package/src/lib/dropdown/dropdown.module.ts +0 -19
- package/src/lib/fieldset/fieldset.component.html +0 -6
- package/src/lib/fieldset/fieldset.component.ts +0 -49
- package/src/lib/fieldset/fieldset.module.ts +0 -11
- package/src/lib/form-group/form-group.component.html +0 -15
- package/src/lib/form-group/form-group.component.ts +0 -39
- package/src/lib/form-group/form-group.module.ts +0 -14
- package/src/lib/label/label.component.html +0 -5
- package/src/lib/label/label.component.ts +0 -18
- package/src/lib/label/label.module.ts +0 -14
- package/src/lib/loading/loading-indicator.component.html +0 -27
- package/src/lib/loading/loading-indicator.component.ts +0 -16
- package/src/lib/loading/loading-panel.component.ts +0 -37
- package/src/lib/loading/loading.module.ts +0 -13
- package/src/lib/loading/loading.service.ts +0 -44
- package/src/lib/menu/menu-item.component.ts +0 -41
- package/src/lib/menu/menu.component.html +0 -74
- package/src/lib/menu/menu.component.ts +0 -111
- package/src/lib/menu/menu.module.ts +0 -13
- package/src/lib/menu/menu2.component.scss +0 -59
- package/src/lib/menu/menu2.component.ts +0 -98
- package/src/lib/number-box/number-box.component.html +0 -32
- package/src/lib/number-box/number-box.component.ts +0 -641
- package/src/lib/number-box/number-box.module.ts +0 -13
- package/src/lib/page/content.component.ts +0 -18
- package/src/lib/page/footer.component.ts +0 -13
- package/src/lib/page/page.component.ts +0 -43
- package/src/lib/page/page.module.ts +0 -14
- package/src/lib/panel-box/panel-box.component.html +0 -19
- package/src/lib/panel-box/panel-box.component.scss +0 -25
- package/src/lib/panel-box/panel-box.component.ts +0 -87
- package/src/lib/panel-box/panel-box.module.ts +0 -10
- package/src/lib/password-box/password-box.component.html +0 -22
- package/src/lib/password-box/password-box.component.ts +0 -30
- package/src/lib/password-box/password-box.module.ts +0 -16
- package/src/lib/popover/custom-cdk-overlay.service.ts +0 -82
- package/src/lib/popover/overlay.service.ts +0 -102
- package/src/lib/popover/popover.component.html +0 -5
- package/src/lib/popover/popover.component.scss +0 -9
- package/src/lib/popover/popover.component.ts +0 -130
- package/src/lib/popover/popover.module.ts +0 -11
- package/src/lib/popup/popup.component.html +0 -33
- package/src/lib/popup/popup.component.scss +0 -167
- package/src/lib/popup/popup.component.ts +0 -184
- package/src/lib/popup/popup.module.ts +0 -16
- package/src/lib/popup/popup.service.ts +0 -103
- package/src/lib/progress-bar/progress-bar.component.html +0 -5
- package/src/lib/progress-bar/progress-bar.component.ts +0 -10
- package/src/lib/progress-bar/progress-bar.module.ts +0 -11
- package/src/lib/property-editor/editors/check-editor/check-editor.ts +0 -44
- package/src/lib/property-editor/editors/check-editor/check.module.ts +0 -14
- package/src/lib/property-editor/editors/color-editor/color.editor.ts +0 -30
- package/src/lib/property-editor/editors/color-editor/color.module.ts +0 -20
- package/src/lib/property-editor/editors/column-editor/column.editor.html +0 -75
- package/src/lib/property-editor/editors/column-editor/column.editor.scss +0 -193
- package/src/lib/property-editor/editors/column-editor/column.editor.ts +0 -124
- package/src/lib/property-editor/editors/column-editor/column.module.ts +0 -28
- package/src/lib/property-editor/editors/conditional-color-editor/conditional-color.editor.html +0 -80
- package/src/lib/property-editor/editors/conditional-color-editor/conditional-color.editor.scss +0 -71
- package/src/lib/property-editor/editors/conditional-color-editor/conditional-color.editor.ts +0 -232
- package/src/lib/property-editor/editors/conditional-color-editor/conditional-color.module.ts +0 -52
- package/src/lib/property-editor/editors/date-editor/date.editor.ts +0 -49
- package/src/lib/property-editor/editors/date-editor/date.module.ts +0 -20
- package/src/lib/property-editor/editors/number-editor/number.editor.ts +0 -46
- package/src/lib/property-editor/editors/number-editor/number.module.ts +0 -20
- package/src/lib/property-editor/editors/range-editor/range.editor.html +0 -67
- package/src/lib/property-editor/editors/range-editor/range.editor.scss +0 -68
- package/src/lib/property-editor/editors/range-editor/range.editor.ts +0 -153
- package/src/lib/property-editor/editors/range-editor/range.module.ts +0 -37
- package/src/lib/property-editor/editors/searchbar-selectbox-editor/searchbar-selectbox-editor.html +0 -8
- package/src/lib/property-editor/editors/searchbar-selectbox-editor/searchbar-selectbox-editor.ts +0 -70
- package/src/lib/property-editor/editors/selectbox-editor/selectbox.editor.html +0 -8
- package/src/lib/property-editor/editors/selectbox-editor/selectbox.editor.ts +0 -77
- package/src/lib/property-editor/editors/selectbox-editor/selectbox.module.ts +0 -18
- package/src/lib/property-editor/editors/selection-editor/selection-editor.ts +0 -52
- package/src/lib/property-editor/editors/selection-editor/selection.module.ts +0 -14
- package/src/lib/property-editor/editors/switch-editor/number.editor.ts +0 -26
- package/src/lib/property-editor/editors/switch-editor/number.module.ts +0 -21
- package/src/lib/property-editor/editors/text-editor/text.editor.html +0 -5
- package/src/lib/property-editor/editors/text-editor/text.editor.ts +0 -31
- package/src/lib/property-editor/editors/text-editor/text.module.ts +0 -20
- package/src/lib/property-editor/editors/textarea-editor/textarea.editor.html +0 -9
- package/src/lib/property-editor/editors/textarea-editor/textarea.editor.ts +0 -37
- package/src/lib/property-editor/editors/textarea-editor/textarea.module.ts +0 -20
- package/src/lib/property-editor/editors/time-editor/time.editor.ts +0 -38
- package/src/lib/property-editor/editors/time-editor/time.module.ts +0 -20
- package/src/lib/property-editor/property-editor-renderer.directive.ts +0 -165
- package/src/lib/property-editor/property-editor.class.ts +0 -178
- package/src/lib/property-editor/property-editor.module.ts +0 -115
- package/src/lib/query-builder/query-builder-group.component.html +0 -68
- package/src/lib/query-builder/query-builder-group.component.ts +0 -122
- package/src/lib/query-builder/query-builder-popup/query-builder-popup.component.html +0 -82
- package/src/lib/query-builder/query-builder-popup/query-builder-popup.component.ts +0 -178
- package/src/lib/query-builder/query-builder-rule.component.html +0 -135
- package/src/lib/query-builder/query-builder-rule.component.ts +0 -390
- package/src/lib/query-builder/query-builder.class.ts +0 -53
- package/src/lib/query-builder/query-builder.component.html +0 -3
- package/src/lib/query-builder/query-builder.component.scss +0 -286
- package/src/lib/query-builder/query-builder.component.ts +0 -220
- package/src/lib/query-builder/query-builder.module.ts +0 -44
- package/src/lib/query-builder/query-builder.service.ts +0 -188
- package/src/lib/search-bar/search-bar.component.html +0 -30
- package/src/lib/search-bar/search-bar.component.scss +0 -114
- package/src/lib/search-bar/search-bar.component.ts +0 -287
- package/src/lib/search-bar/search-bar.module.ts +0 -33
- package/src/lib/searchbox/searchbox.component.html +0 -25
- package/src/lib/searchbox/searchbox.component.ts +0 -85
- package/src/lib/searchbox/searchbox.module.ts +0 -17
- package/src/lib/selectbox/selectbox.component.html +0 -100
- package/src/lib/selectbox/selectbox.component.ts +0 -984
- package/src/lib/selectbox/selectbox.module.ts +0 -31
- package/src/lib/selectbox/selectbox2.component.html +0 -78
- package/src/lib/selectbox/selectbox2.component.ts +0 -603
- package/src/lib/selection-list/selection-list.component.html +0 -21
- package/src/lib/selection-list/selection-list.component.ts +0 -115
- package/src/lib/selection-list/selection-list.module.ts +0 -13
- package/src/lib/switch/switch.component.html +0 -4
- package/src/lib/switch/switch.component.scss +0 -65
- package/src/lib/switch/switch.component.ts +0 -57
- package/src/lib/switch/switch.module.ts +0 -14
- package/src/lib/tab-page/tab-page-Renderer.component.ts +0 -70
- package/src/lib/tab-page/tab-page-host.component.ts +0 -110
- package/src/lib/tab-page/tab-page.module.ts +0 -13
- package/src/lib/tab-page/tab-page.service.ts +0 -176
- package/src/lib/tab-strip/tab-strip.component.html +0 -6
- package/src/lib/tab-strip/tab-strip.component.ts +0 -47
- package/src/lib/tab-strip/tab-strip.module.ts +0 -11
- package/src/lib/tab-view/dynamic-tabs.directive.ts +0 -17
- package/src/lib/tab-view/tab-view.component.html +0 -33
- package/src/lib/tab-view/tab-view.component.scss +0 -0
- package/src/lib/tab-view/tab-view.component.ts +0 -129
- package/src/lib/tab-view/tab-view.module.ts +0 -12
- package/src/lib/tab-view/tab.component.html +0 -8
- package/src/lib/tab-view/tab.component.ts +0 -15
- package/src/lib/textarea/textarea.component.html +0 -13
- package/src/lib/textarea/textarea.component.ts +0 -24
- package/src/lib/textarea/textarea.module.ts +0 -14
- package/src/lib/textbox/textbox.component.html +0 -22
- package/src/lib/textbox/textbox.component.ts +0 -38
- package/src/lib/textbox/textbox.module.ts +0 -16
- package/src/lib/time-picker/time-picker.component.html +0 -21
- package/src/lib/time-picker/time-picker.component.ts +0 -1003
- package/src/lib/time-picker/time-picker.module.ts +0 -15
- package/src/lib/toast/toast-message/toast-message.component.html +0 -17
- package/src/lib/toast/toast-message/toast-message.component.scss +0 -75
- package/src/lib/toast/toast-message/toast-message.component.ts +0 -64
- package/src/lib/toast/toast-wrapper/toast-wrapper.component.scss +0 -15
- package/src/lib/toast/toast-wrapper/toast-wrapper.component.ts +0 -13
- package/src/lib/toast/toast.module.ts +0 -12
- package/src/lib/toast/toast.service.ts +0 -64
- package/src/lib/toolbar/group-button/toolbar-group-button.component.ts +0 -54
- package/src/lib/toolbar/menu/toolbar-menu.component.html +0 -4
- package/src/lib/toolbar/menu/toolbar-menu.component.ts +0 -81
- package/src/lib/toolbar/search/toolbar-search.component.html +0 -4
- package/src/lib/toolbar/search/toolbar-search.component.scss +0 -24
- package/src/lib/toolbar/search/toolbar-search.component.ts +0 -61
- package/src/lib/toolbar/title/toolbar-title.component.ts +0 -35
- package/src/lib/toolbar/toolbar-item.ts +0 -4
- package/src/lib/toolbar/toolbar.component.html +0 -4
- package/src/lib/toolbar/toolbar.component.scss +0 -9
- package/src/lib/toolbar/toolbar.component.ts +0 -16
- package/src/lib/toolbar/toolbar.module.ts +0 -25
- package/src/lib/tooltip/tooltip.directive.ts +0 -101
- package/src/lib/tooltip/tooltip.module.ts +0 -11
- package/src/lib/tree-side-menu/tree-side-menu.component.html +0 -43
- package/src/lib/tree-side-menu/tree-side-menu.component.ts +0 -698
- package/src/lib/tree-side-menu/tree-side-menu.module.ts +0 -19
- package/src/lib/tree-view/tree-view.component.html +0 -46
- package/src/lib/tree-view/tree-view.component.ts +0 -835
- package/src/lib/tree-view/tree-view.module.ts +0 -16
- package/src/lib/upload-file/upload-file.component.html +0 -16
- package/src/lib/upload-file/upload-file.component.ts +0 -230
- package/src/lib/upload-file/upload-file.events.ts +0 -11
- package/src/lib/upload-file/upload-file.module.ts +0 -16
- package/src/lib/validation/validation-form.component.ts +0 -78
- package/src/lib/validation/validation-rule.widget.ts +0 -112
- package/src/lib/validation/validation.class.ts +0 -22
- package/src/lib/validation/validation.component.ts +0 -92
- package/src/lib/validation/validation.module.ts +0 -28
- package/src/test.ts +0 -28
- package/tsconfig.lib.json +0 -25
- package/tsconfig.lib.prod.json +0 -6
- package/tsconfig.spec.json +0 -17
- package/tslint.json +0 -17
@@ -1,984 +0,0 @@
|
|
1
|
-
import {
|
2
|
-
Component,
|
3
|
-
ViewEncapsulation,
|
4
|
-
ChangeDetectionStrategy,
|
5
|
-
Input,
|
6
|
-
EventEmitter,
|
7
|
-
Output,
|
8
|
-
ViewChild,
|
9
|
-
ChangeDetectorRef,
|
10
|
-
ElementRef,
|
11
|
-
ContentChild,
|
12
|
-
NgZone,
|
13
|
-
QueryList,
|
14
|
-
ContentChildren,
|
15
|
-
TemplateRef
|
16
|
-
} from '@angular/core';
|
17
|
-
import { Observable } from 'rxjs';
|
18
|
-
import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
|
19
|
-
import { AXTextBoxComponent } from '../textbox/textbox.component';
|
20
|
-
import { AXDropdownComponent } from '../dropdown/dropdown.component';
|
21
|
-
import { AXBaseSizableComponent, AXBaseInputComponent, AXElementSize, AXValidatableComponent } from '../base/element.class';
|
22
|
-
import { AXDataSourceComponent } from '../data-source/datasource.component';
|
23
|
-
import { AXValidation } from '../validation/validation.component';
|
24
|
-
import { AXDataSourceReadParams } from '../data-source/read-param';
|
25
|
-
import { AXBaseEvent } from '../base/events.class';
|
26
|
-
import { AXSearchBoxComponent } from '../searchbox/searchbox.component';
|
27
|
-
import { AXConfig } from '@acorex/core';
|
28
|
-
import { differenceBy } from 'lodash';
|
29
|
-
export class AXSelectBoxSelectionChangedEvent extends AXBaseEvent {
|
30
|
-
constructor(component: any, public selectedItems: any[], public selectedValues: any[] | any) {
|
31
|
-
super();
|
32
|
-
this.component = component;
|
33
|
-
}
|
34
|
-
}
|
35
|
-
|
36
|
-
@Component({
|
37
|
-
selector: 'ax-select-box',
|
38
|
-
templateUrl: './selectbox.component.html',
|
39
|
-
encapsulation: ViewEncapsulation.None,
|
40
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
41
|
-
host: { style: 'width: 100%' },
|
42
|
-
providers: [{ provide: AXValidatableComponent, useExisting: AXSelectBoxComponent }]
|
43
|
-
})
|
44
|
-
export class AXSelectBoxComponent extends AXValidatableComponent implements AXBaseSizableComponent, AXBaseInputComponent {
|
45
|
-
@Input() showDropDownButton: boolean = true;
|
46
|
-
|
47
|
-
@ContentChild(TemplateRef, { static: true })
|
48
|
-
rowTemplate: TemplateRef<any>;
|
49
|
-
|
50
|
-
@Input()
|
51
|
-
rowInputTemplate: TemplateRef<any>;
|
52
|
-
@ViewChild(AXTextBoxComponent, { static: true })
|
53
|
-
span: ElementRef<HTMLElement>;
|
54
|
-
|
55
|
-
@ViewChild(AXTextBoxComponent, { static: true })
|
56
|
-
textbox: AXTextBoxComponent;
|
57
|
-
|
58
|
-
@ViewChild('listContainer', { static: true })
|
59
|
-
listContainer: ElementRef<HTMLDivElement>;
|
60
|
-
|
61
|
-
@ViewChild('serchBox', { static: false })
|
62
|
-
serchBox: AXSearchBoxComponent;
|
63
|
-
|
64
|
-
@ViewChild('textBoxSelectBox', { static: true })
|
65
|
-
textBoxSelectBox: AXTextBoxComponent;
|
66
|
-
|
67
|
-
@Input() showCheckBox: boolean = true;
|
68
|
-
|
69
|
-
@Input() readonly: boolean = false;
|
70
|
-
|
71
|
-
@Input() rtl: boolean = AXConfig.get('layout.rtl');
|
72
|
-
|
73
|
-
@Input() disabled: boolean = false;
|
74
|
-
|
75
|
-
@Input() placeholder: string;
|
76
|
-
|
77
|
-
@Input() size: AXElementSize = 'md';
|
78
|
-
|
79
|
-
@Input() allowNull: boolean = true;
|
80
|
-
|
81
|
-
@Input() textAlign: 'right' | 'left' | null = null;
|
82
|
-
|
83
|
-
@Input() bufferSize: number = 20;
|
84
|
-
|
85
|
-
@Input() remoteOperation: boolean = false;
|
86
|
-
|
87
|
-
@Input() fitParent: boolean = true;
|
88
|
-
|
89
|
-
@Input() dropdownWidth: string = '300px'
|
90
|
-
|
91
|
-
@Output()
|
92
|
-
dropdownToggle: EventEmitter<any> = new EventEmitter<any>();
|
93
|
-
// this input is Private and only use in LOV
|
94
|
-
|
95
|
-
currentfocusedIndex: number = -1;
|
96
|
-
showLoading: boolean = false;
|
97
|
-
|
98
|
-
skip: number = -1;
|
99
|
-
searchText: string = '';
|
100
|
-
// @Input()
|
101
|
-
// chipsWidth: string = '';
|
102
|
-
|
103
|
-
text: string = '';
|
104
|
-
totalCount: number = 0;
|
105
|
-
|
106
|
-
@ContentChild(AXDataSourceComponent, { static: true })
|
107
|
-
private _contentDataSource: AXDataSourceComponent;
|
108
|
-
|
109
|
-
private _dataSource: AXDataSourceComponent;
|
110
|
-
|
111
|
-
@Input()
|
112
|
-
public get dataSource(): AXDataSourceComponent {
|
113
|
-
return this._dataSource ? this._dataSource : this._contentDataSource;
|
114
|
-
}
|
115
|
-
|
116
|
-
public set dataSource(v: AXDataSourceComponent) {
|
117
|
-
this._dataSource = v;
|
118
|
-
}
|
119
|
-
|
120
|
-
@ContentChild(AXValidation, { static: true })
|
121
|
-
private _contentValidation: AXValidation;
|
122
|
-
|
123
|
-
private _validation: AXValidation;
|
124
|
-
|
125
|
-
@Input()
|
126
|
-
public get validation(): AXValidation {
|
127
|
-
return this._validation ? this._validation : this._contentValidation;
|
128
|
-
}
|
129
|
-
|
130
|
-
public set validation(v: AXValidation) {
|
131
|
-
this._validation = v;
|
132
|
-
}
|
133
|
-
|
134
|
-
constructor(private cdr: ChangeDetectorRef, private ref: ElementRef, private zone: NgZone) {
|
135
|
-
super();
|
136
|
-
}
|
137
|
-
|
138
|
-
@ViewChild('d', { static: true })
|
139
|
-
dropdown: AXDropdownComponent;
|
140
|
-
|
141
|
-
@Input() disabledCallback: (e: { item: any; index: number }) => boolean;
|
142
|
-
|
143
|
-
@Input() allowSearch: boolean = true;
|
144
|
-
@Input() textField: string = 'text';
|
145
|
-
@Input() valueField: string = 'value';
|
146
|
-
@Input() disabledField: string = 'disabled';
|
147
|
-
@Input() mode: 'single' | 'multiple' = 'single';
|
148
|
-
itemRemove: boolean = false;
|
149
|
-
@Output() itemsChange: EventEmitter<any[]> = new EventEmitter<any[]>();
|
150
|
-
|
151
|
-
@Output() onBlur: EventEmitter<any> = new EventEmitter<any>();
|
152
|
-
|
153
|
-
@Output() onFocus: EventEmitter<any> = new EventEmitter<any>();
|
154
|
-
|
155
|
-
private _items: any[] = [];
|
156
|
-
@Input()
|
157
|
-
public get items(): any[] {
|
158
|
-
return this._items;
|
159
|
-
}
|
160
|
-
public set items(v: any[]) {
|
161
|
-
this._items = v;
|
162
|
-
if (this.itemsChange) {
|
163
|
-
this.itemsChange.emit(v);
|
164
|
-
}
|
165
|
-
if (this.itemsStatusObserver) {
|
166
|
-
this.itemsStatusObserver.next(this.items.length);
|
167
|
-
}
|
168
|
-
}
|
169
|
-
|
170
|
-
hasSelectedValue: boolean = false;
|
171
|
-
itemsFiltered: any[] = [];
|
172
|
-
|
173
|
-
// #endregion
|
174
|
-
|
175
|
-
dropDownDisabled: boolean = false;
|
176
|
-
|
177
|
-
@Output()
|
178
|
-
selectionChanged: EventEmitter<AXSelectBoxSelectionChangedEvent> = new EventEmitter<AXSelectBoxSelectionChangedEvent>();
|
179
|
-
|
180
|
-
@Output()
|
181
|
-
selectedItemsChange: EventEmitter<any[]> = new EventEmitter<any[]>();
|
182
|
-
|
183
|
-
private _selectedItems: any[] = [];
|
184
|
-
@Input()
|
185
|
-
public get selectedItems(): any[] {
|
186
|
-
return this._selectedItems || [];
|
187
|
-
}
|
188
|
-
public set selectedItems(v: any[]) {
|
189
|
-
this.setSelectedItemsChange(v);
|
190
|
-
// if (!v) {
|
191
|
-
// v = [];
|
192
|
-
// }
|
193
|
-
|
194
|
-
// const old = this.selectedItems;
|
195
|
-
// if (JSON.stringify(old) !== JSON.stringify(v)) {
|
196
|
-
// this._selectedItems = this.mode == 'single' ? v.slice(0, 1) : [...new Set(v)]; //[...new Set(v[0])] : [...new Set(v)];
|
197
|
-
// this._selectedItems.forEach((c) => (c.selected = true));
|
198
|
-
// this.selectedItemsChange.emit(this._selectedItems);
|
199
|
-
// this.selectedValuesChange.emit(this.selectedValues);
|
200
|
-
// this.clearValidationStyle(this.ref.nativeElement);
|
201
|
-
// this.waitForData(() => {
|
202
|
-
// if (this._selectedItems) {
|
203
|
-
// this.items.forEach((c) => (c.selected = this._selectedItems.some((i) => i[this.valueField] == c[this.valueField])));
|
204
|
-
// }
|
205
|
-
// });
|
206
|
-
// }
|
207
|
-
}
|
208
|
-
|
209
|
-
setSelectedItemsChange(v: any[], old: any[] = this.selectedItems) {
|
210
|
-
if (!v) {
|
211
|
-
v = [];
|
212
|
-
}
|
213
|
-
// const old = this.selectedItems;
|
214
|
-
var f = differenceBy(old, v, this.valueField);
|
215
|
-
var s = differenceBy(v, old, this.valueField);
|
216
|
-
// if (JSON.stringify(old) !== JSON.stringify(v)) {
|
217
|
-
if (f.length != 0 || s.length != 0) {
|
218
|
-
this._selectedItems = this.mode == 'single' ? v.slice(0, 1) : [...new Set(v)]; //[...new Set(v[0])] : [...new Set(v)];
|
219
|
-
this._selectedItems.forEach((c) => (c.selected = true));
|
220
|
-
this.selectedItemsChange.emit(this._selectedItems);
|
221
|
-
this.selectedValuesChange.emit(this.selectedValues);
|
222
|
-
this.clearValidationStyle(this.ref.nativeElement);
|
223
|
-
this.waitForData(() => {
|
224
|
-
if (this._selectedItems) {
|
225
|
-
this.items.forEach((c) => (c.selected = this._selectedItems.some((i) => i[this.valueField] == c[this.valueField])));
|
226
|
-
}
|
227
|
-
});
|
228
|
-
}
|
229
|
-
}
|
230
|
-
|
231
|
-
ngOnInit() {
|
232
|
-
if (this.rowTemplate === undefined && this.rowInputTemplate != undefined) {
|
233
|
-
this.rowTemplate = this.rowInputTemplate;
|
234
|
-
}
|
235
|
-
if (this.rtl == null) {
|
236
|
-
this.rtl = window.getComputedStyle(this.ref.nativeElement, null).getPropertyValue('direction') === 'rtl';
|
237
|
-
}
|
238
|
-
}
|
239
|
-
|
240
|
-
scrolled(e) {
|
241
|
-
if (
|
242
|
-
this.remoteOperation &&
|
243
|
-
this.totalCount > this.items.length &&
|
244
|
-
this.listContainer.nativeElement.scrollHeight != 0 &&
|
245
|
-
this.listContainer.nativeElement.scrollHeight - this.listContainer.nativeElement.scrollTop - 300 < 50
|
246
|
-
) {
|
247
|
-
if (this.skip !== this.items.length) {
|
248
|
-
this.showLoading = true;
|
249
|
-
this.skip = this.items.length;
|
250
|
-
const params: AXDataSourceReadParams = {};
|
251
|
-
params.skip = this.items.length;
|
252
|
-
params.take = this.bufferSize; //* (Math.floor(this.items.length / this.bufferSize) + 1);
|
253
|
-
if (this.textbox) {
|
254
|
-
params.searchText = this.text;
|
255
|
-
} else {
|
256
|
-
params.searchText = null;
|
257
|
-
}
|
258
|
-
this.fetch(params);
|
259
|
-
}
|
260
|
-
}
|
261
|
-
}
|
262
|
-
private setSelectedItems(v: any[], isUserInput: boolean) {
|
263
|
-
let changed = false;
|
264
|
-
if (isUserInput) {
|
265
|
-
changed = JSON.stringify(v) !== JSON.stringify(this.selectedItems);
|
266
|
-
}
|
267
|
-
this.selectedItems = v;
|
268
|
-
this.setSelectedIndex();
|
269
|
-
if (isUserInput && changed) {
|
270
|
-
this.emitSelectionChangedEvent();
|
271
|
-
}
|
272
|
-
}
|
273
|
-
|
274
|
-
private searchChangeObserver: any;
|
275
|
-
|
276
|
-
delay: number = 500;
|
277
|
-
|
278
|
-
textChanged(e) {
|
279
|
-
if ((e.value === null || e.value === undefined || e.value === '') && (e.oldValue === null || e.oldValue === undefined || e.oldValue === '')) {
|
280
|
-
} else {
|
281
|
-
this.currentfocusedIndex = -1;
|
282
|
-
if (this.remoteOperation) {
|
283
|
-
this.searchText = this.text;
|
284
|
-
// this.searchText = e.value;
|
285
|
-
// this.text = e.value;
|
286
|
-
// this.items = [];
|
287
|
-
if (this.items) {
|
288
|
-
let t = this.items.length;
|
289
|
-
for (let i = 0; i < t; i++) {
|
290
|
-
this.items.pop();
|
291
|
-
}
|
292
|
-
}
|
293
|
-
|
294
|
-
// this.items.forEach((element) => {
|
295
|
-
// this.items.pop();
|
296
|
-
// });
|
297
|
-
const params: AXDataSourceReadParams = {};
|
298
|
-
params.searchText = this.text;
|
299
|
-
// params.searchText = e.value;
|
300
|
-
params.skip = 0;
|
301
|
-
params.take = this.bufferSize;
|
302
|
-
this.fetch(params);
|
303
|
-
}
|
304
|
-
}
|
305
|
-
}
|
306
|
-
|
307
|
-
isItemDisabled(item: any): boolean {
|
308
|
-
if (item[this.disabledField] == true) {
|
309
|
-
return true;
|
310
|
-
} else if (this.disabledCallback) {
|
311
|
-
return this.disabledCallback({ item, index: -1 });
|
312
|
-
} else {
|
313
|
-
return false;
|
314
|
-
}
|
315
|
-
}
|
316
|
-
|
317
|
-
onButtonClick(e) {
|
318
|
-
}
|
319
|
-
|
320
|
-
private setSelectedIndex(sign: -1 | 1 | null = null): void {
|
321
|
-
if (sign == null) {
|
322
|
-
if (!this.remoteOperation && this.text && this.text !== '') {
|
323
|
-
this.currentfocusedIndex = this.items
|
324
|
-
.filter((c) => (c[this.textField] as string).toLowerCase().includes(this.text.toLowerCase()))
|
325
|
-
.indexOf(this.selectedItems[this.selectedItems.length - 1]);
|
326
|
-
} else {
|
327
|
-
this.currentfocusedIndex = this.items.indexOf(this.selectedItems[this.selectedItems.length - 1]);
|
328
|
-
}
|
329
|
-
} else {
|
330
|
-
sign === -1 ? this.currentfocusedIndex-- : this.currentfocusedIndex++;
|
331
|
-
}
|
332
|
-
|
333
|
-
if (this.remoteOperation) {
|
334
|
-
this.itemsFiltered = this.items;
|
335
|
-
} else {
|
336
|
-
this.itemsFiltered = this.text
|
337
|
-
? this.items.filter((c) => (c[this.textField] as string).toLowerCase().includes(this.text.toLowerCase()))
|
338
|
-
: this.items;
|
339
|
-
}
|
340
|
-
|
341
|
-
this.currentfocusedIndex =
|
342
|
-
this.currentfocusedIndex < 0
|
343
|
-
? 0
|
344
|
-
: this.currentfocusedIndex >= this.itemsFiltered.length
|
345
|
-
? this.itemsFiltered.length - 1
|
346
|
-
: this.currentfocusedIndex;
|
347
|
-
//
|
348
|
-
// set scroll
|
349
|
-
if (this.listContainer) {
|
350
|
-
this.zone.runOutsideAngular(() => {
|
351
|
-
const itemDiv = this.listContainer.nativeElement.querySelector(`.list-item:nth-child(${this.currentfocusedIndex})`);
|
352
|
-
if (itemDiv) {
|
353
|
-
itemDiv.scrollIntoView({ behavior: 'smooth' });
|
354
|
-
}
|
355
|
-
});
|
356
|
-
}
|
357
|
-
}
|
358
|
-
|
359
|
-
@Output()
|
360
|
-
selectedValuesChange: EventEmitter<any[] | any> = new EventEmitter<any[] | any>();
|
361
|
-
|
362
|
-
@Input()
|
363
|
-
public get selectedValues(): any[] | any {
|
364
|
-
if (this.mode === 'single') {
|
365
|
-
return this._selectedItems.map((c) => c[this.valueField])[0];
|
366
|
-
} else {
|
367
|
-
return this._selectedItems.map((c) => c[this.valueField]) || [];
|
368
|
-
}
|
369
|
-
}
|
370
|
-
|
371
|
-
public set selectedValues(v: any[] | any) {
|
372
|
-
if (this.compareSelectedValues(v)) {
|
373
|
-
return;
|
374
|
-
}
|
375
|
-
if (v == null) {
|
376
|
-
this.selectedItems = [];
|
377
|
-
} else {
|
378
|
-
if (v !== undefined) {
|
379
|
-
if (v != [] && v != '' && v != null) {
|
380
|
-
this.hasSelectedValue = true;
|
381
|
-
}
|
382
|
-
|
383
|
-
this.waitForData(() => {
|
384
|
-
if (this.mode === 'single') {
|
385
|
-
if (this.items.filter((c) => v == c[this.valueField])) {
|
386
|
-
this.selectedItems = this.items.filter((c) => v == c[this.valueField]);
|
387
|
-
} else {
|
388
|
-
this.selectedItems = [];
|
389
|
-
}
|
390
|
-
} else {
|
391
|
-
if (Array.isArray(v)) {
|
392
|
-
if (this.selectedItems.length > v.length) {
|
393
|
-
this.selectedItems = this.selectedItems.filter((c) => v.includes(c[this.valueField]));
|
394
|
-
} else {
|
395
|
-
let addId = [];
|
396
|
-
v.forEach((vId) => {
|
397
|
-
addId.push({
|
398
|
-
[this.valueField]: vId
|
399
|
-
});
|
400
|
-
});
|
401
|
-
|
402
|
-
let newId = differenceBy(addId, this.selectedItems, this.valueField);
|
403
|
-
let vv = [];
|
404
|
-
newId.forEach((rc) => {
|
405
|
-
vv.push(rc[this.valueField]);
|
406
|
-
});
|
407
|
-
this.items
|
408
|
-
.filter((c) => vv.includes(c[this.valueField]))
|
409
|
-
.forEach((res) => {
|
410
|
-
this.selectedItems.push(res);
|
411
|
-
});
|
412
|
-
// this.selectedItems.push(this.items.filter((c) => vv.includes(c[this.valueField])));
|
413
|
-
this.setSelectedItemsChange(this.selectedItems, vv.length > 0 ? [1] : this.selectedItems);
|
414
|
-
}
|
415
|
-
|
416
|
-
// this.selectedItems = this.items.filter((c) => v.includes(c[this.valueField]));
|
417
|
-
} else if (v) {
|
418
|
-
this.selectedItems = this.items.filter((c) => v === c[this.valueField]);
|
419
|
-
} else {
|
420
|
-
this.selectedItems = [];
|
421
|
-
}
|
422
|
-
}
|
423
|
-
this.selectedValuesChange.emit(this.selectedValues);
|
424
|
-
this.cdr.markForCheck();
|
425
|
-
this.cdr.detectChanges();
|
426
|
-
});
|
427
|
-
}
|
428
|
-
}
|
429
|
-
}
|
430
|
-
|
431
|
-
private compareSelectedValues(newValue: any[] | any) {
|
432
|
-
const currentValue = this.selectedValues;
|
433
|
-
return (currentValue == null && newValue == null) || JSON.stringify(currentValue) === JSON.stringify(newValue);
|
434
|
-
}
|
435
|
-
|
436
|
-
private setSelectedValues(v: any[] | any, isUserInput: boolean) {
|
437
|
-
const changed = isUserInput ? !this.compareSelectedValues(v) : false;
|
438
|
-
this.selectedValues = v;
|
439
|
-
if (isUserInput && changed) {
|
440
|
-
this.emitSelectionChangedEvent();
|
441
|
-
}
|
442
|
-
}
|
443
|
-
|
444
|
-
private emitSelectionChangedEvent() {
|
445
|
-
this.selectedValuesChange.emit(this.selectedValues);
|
446
|
-
this.selectionChanged.emit(new AXSelectBoxSelectionChangedEvent(this, this.selectedItems, this.selectedValues));
|
447
|
-
}
|
448
|
-
|
449
|
-
ngAfterViewInit(): void {
|
450
|
-
if (this.bufferSize < 10) {
|
451
|
-
this.bufferSize = 10;
|
452
|
-
}
|
453
|
-
if (this.mode == 'single') {
|
454
|
-
this.showCheckBox = false;
|
455
|
-
} else {
|
456
|
-
this.showCheckBox = true;
|
457
|
-
}
|
458
|
-
if (!this.remoteOperation || (this.remoteOperation && this.hasSelectedValue)) {
|
459
|
-
this.refresh();
|
460
|
-
}
|
461
|
-
}
|
462
|
-
dropdownToggleSelecBox(e) {
|
463
|
-
this.text = '';
|
464
|
-
if (this.dropdown.isOpen) {
|
465
|
-
this.refresh();
|
466
|
-
setTimeout(() => {
|
467
|
-
if (this.serchBox) {
|
468
|
-
this.serchBox.focus();
|
469
|
-
}
|
470
|
-
}, 1);
|
471
|
-
} else {
|
472
|
-
// this.refresh();
|
473
|
-
}
|
474
|
-
this.dropdownToggle.emit(e);
|
475
|
-
}
|
476
|
-
|
477
|
-
ngAfterContentInit() {
|
478
|
-
// if (!this.allowSearch) {
|
479
|
-
// if (this.readonly == false) {
|
480
|
-
// this.itemRemove = true;
|
481
|
-
// this.readonly = true;
|
482
|
-
// }
|
483
|
-
// }
|
484
|
-
this.initValidation(this.ref, 'selectedItems', this.validation);
|
485
|
-
if (this.dataSource) {
|
486
|
-
// if (this.allowSearch == false) {
|
487
|
-
// this.fetch();
|
488
|
-
// }
|
489
|
-
this.dataSource.onDataReceived.subscribe((c) => {
|
490
|
-
this.showLoading = false;
|
491
|
-
this.dataReceived(c.data.result);
|
492
|
-
});
|
493
|
-
}
|
494
|
-
this.cdr.markForCheck();
|
495
|
-
this.cdr.detectChanges();
|
496
|
-
}
|
497
|
-
|
498
|
-
private dataReceived(data: any) {
|
499
|
-
if (this.remoteOperation) {
|
500
|
-
if (this.searchText && this.searchText != null && this.searchText !== '') {
|
501
|
-
if (data.totalCount) {
|
502
|
-
if (this.items.length == 0) {
|
503
|
-
//this.items = data.items;
|
504
|
-
data.items.forEach((item) => {
|
505
|
-
this.items.push(item);
|
506
|
-
});
|
507
|
-
} else {
|
508
|
-
data.items.forEach((item) => {
|
509
|
-
this.items.push(item);
|
510
|
-
});
|
511
|
-
// if (this.itemsStatusObserver) {
|
512
|
-
// this.itemsStatusObserver.next(this.items.length);
|
513
|
-
// }
|
514
|
-
}
|
515
|
-
|
516
|
-
this.totalCount = data.totalCount;
|
517
|
-
} else {
|
518
|
-
if (this.items.length == 0) {
|
519
|
-
this.items = data.items;
|
520
|
-
} else {
|
521
|
-
data.items.forEach((item) => {
|
522
|
-
this.items.push(item);
|
523
|
-
});
|
524
|
-
// if (this.itemsStatusObserver) {
|
525
|
-
// this.itemsStatusObserver.next(this.items.length);
|
526
|
-
// }
|
527
|
-
}
|
528
|
-
this.totalCount = data.items == undefined ? 0 : data.items.length;
|
529
|
-
}
|
530
|
-
} else if (data.items && data.items.length === data.totalCount) {
|
531
|
-
this.items = data.items;
|
532
|
-
this.totalCount = data.items.length;
|
533
|
-
} else if (data.totalCount) {
|
534
|
-
data.items.forEach((elm) => {
|
535
|
-
this.items.push(elm);
|
536
|
-
});
|
537
|
-
// if (this.itemsStatusObserver) {
|
538
|
-
// this.itemsStatusObserver.next(this.items.length);
|
539
|
-
// }
|
540
|
-
this.totalCount = data.totalCount;
|
541
|
-
} else {
|
542
|
-
data.forEach((elm) => {
|
543
|
-
this.items.push(elm);
|
544
|
-
// if (this.itemsStatusObserver) {
|
545
|
-
// this.itemsStatusObserver.next(this.items.length);
|
546
|
-
// }
|
547
|
-
});
|
548
|
-
this.totalCount = data.length;
|
549
|
-
}
|
550
|
-
} else {
|
551
|
-
this.items = data;
|
552
|
-
}
|
553
|
-
|
554
|
-
this.cdr.markForCheck();
|
555
|
-
this.cdr.detectChanges();
|
556
|
-
|
557
|
-
this.dropdown.updatePosition();
|
558
|
-
}
|
559
|
-
|
560
|
-
// private params: AXDataSourceReadParams = {};
|
561
|
-
|
562
|
-
fetch(params: AXDataSourceReadParams = {}) {
|
563
|
-
// this.params = params;
|
564
|
-
if (this.dataSource) {
|
565
|
-
this.showLoading = true;
|
566
|
-
this.dataSource.fetch(params);
|
567
|
-
}
|
568
|
-
}
|
569
|
-
|
570
|
-
refresh() {
|
571
|
-
const params: AXDataSourceReadParams = {};
|
572
|
-
if (this.remoteOperation) {
|
573
|
-
params.skip = 0;
|
574
|
-
this.skip = 0;
|
575
|
-
params.take = this.bufferSize;
|
576
|
-
}
|
577
|
-
if (this.dataSource != undefined) {
|
578
|
-
// this.items = [];
|
579
|
-
// this.items.forEach((element) => {
|
580
|
-
// this.items.pop();
|
581
|
-
// });
|
582
|
-
|
583
|
-
if (this.items) {
|
584
|
-
let t = this.items.length;
|
585
|
-
for (let i = 0; i < t; i++) {
|
586
|
-
this.items.pop();
|
587
|
-
}
|
588
|
-
}
|
589
|
-
|
590
|
-
this.fetch(params);
|
591
|
-
}
|
592
|
-
}
|
593
|
-
|
594
|
-
handleItemRemoveClick(item) {
|
595
|
-
if (this.mode === 'single') {
|
596
|
-
// this.selectedItems = null;
|
597
|
-
this.setSelectedValues(null, true);
|
598
|
-
// this.selectedItemsChange.emit(this._selectedItems);
|
599
|
-
// this.clearValidationStyle(this.ref.nativeElement);
|
600
|
-
} else {
|
601
|
-
// this.selectedItems = this.selectedItems.filter((c) => c !== item);
|
602
|
-
this.setSelectedItems(
|
603
|
-
this.selectedItems.filter((c) => c[this.valueField] !== item[this.valueField]),
|
604
|
-
true
|
605
|
-
);
|
606
|
-
// this._selectedItems = this._selectedItems.filter(c => c !== item);
|
607
|
-
// this.selectedItemsChange.emit(this._selectedItems);
|
608
|
-
// this.clearValidationStyle(this.ref.nativeElement);
|
609
|
-
}
|
610
|
-
// this.text = '';
|
611
|
-
this.validate();
|
612
|
-
this.cdr.markForCheck();
|
613
|
-
}
|
614
|
-
|
615
|
-
onFocusTextBox(e) { }
|
616
|
-
|
617
|
-
onTextBoxClick(e) {
|
618
|
-
if (this.disabled == false && this.readonly == false) {
|
619
|
-
this.dropdown.open();
|
620
|
-
}
|
621
|
-
}
|
622
|
-
|
623
|
-
handleItemClick(e: MouseEvent, item: any) {
|
624
|
-
if (this.isItemDisabled(item) == false) {
|
625
|
-
const value = item[this.valueField];
|
626
|
-
|
627
|
-
if (this.mode === 'single') {
|
628
|
-
// this.selectedValues = value;
|
629
|
-
this.setSelectedValues(value, true);
|
630
|
-
} else {
|
631
|
-
const exists = this.selectedValues.slice(0);
|
632
|
-
if (exists.includes(value)) {
|
633
|
-
if (this.allowNull == true || (this.allowNull == false && this.selectedItems.length > 1)) {
|
634
|
-
this.handleItemRemoveClick(item);
|
635
|
-
}
|
636
|
-
} else {
|
637
|
-
exists.push(value);
|
638
|
-
// this.selectedValues = exists;
|
639
|
-
this.setSelectedValues(exists, true);
|
640
|
-
}
|
641
|
-
}
|
642
|
-
|
643
|
-
if (this.mode == 'single') {
|
644
|
-
this.text = '';
|
645
|
-
this.dropdown.close();
|
646
|
-
this.cdr.markForCheck();
|
647
|
-
}
|
648
|
-
// if (e.stopPropagation() == undefined) {
|
649
|
-
// e.stopPropagation();
|
650
|
-
// }
|
651
|
-
setTimeout(() => {
|
652
|
-
if (this.serchBox) {
|
653
|
-
this.serchBox.focus();
|
654
|
-
}
|
655
|
-
}, 0);
|
656
|
-
}
|
657
|
-
|
658
|
-
e.stopPropagation();
|
659
|
-
}
|
660
|
-
|
661
|
-
handleKeyEventSearch(e: KeyboardEvent) {
|
662
|
-
if (this.disabled || this.readonly) {
|
663
|
-
this.dropdown.close();
|
664
|
-
setTimeout(() => {
|
665
|
-
this.textBoxSelectBox.focus();
|
666
|
-
}, 0);
|
667
|
-
return false;
|
668
|
-
}
|
669
|
-
if (e.key === 'Escape') {
|
670
|
-
this.text = null;
|
671
|
-
setTimeout(() => {
|
672
|
-
this.textBoxSelectBox.focus();
|
673
|
-
}, 0);
|
674
|
-
}
|
675
|
-
if ((e.key === 'ArrowDown' || e.key === 'ArrowUp') && this.getItems().length > 0 && e.type === 'keydown') {
|
676
|
-
if (this.mode === 'single') {
|
677
|
-
this.currentfocusedIndex = this.currentfocusedIndex + (e.key === 'ArrowDown' ? 1 : -1);
|
678
|
-
this.selectedItemByIndex(this.currentfocusedIndex);
|
679
|
-
} else {
|
680
|
-
if (this.dropdown.isOpen) {
|
681
|
-
this.setSelectedIndex(e.key === 'ArrowDown' ? 1 : -1);
|
682
|
-
} else {
|
683
|
-
this.dropdown.open();
|
684
|
-
setTimeout(() => {
|
685
|
-
if (this.serchBox) {
|
686
|
-
this.serchBox.focus();
|
687
|
-
}
|
688
|
-
}, 0);
|
689
|
-
}
|
690
|
-
}
|
691
|
-
}
|
692
|
-
// if (e.key == 'Enter' && this.dropdown.isOpen && this.mode == 'single') {
|
693
|
-
// this.dropdown.close();
|
694
|
-
// setTimeout(() => {
|
695
|
-
// this.dropdown.focus();
|
696
|
-
// }, 0);
|
697
|
-
// }
|
698
|
-
//e.stopPropagation();
|
699
|
-
//e.preventDefault();
|
700
|
-
e.stopImmediatePropagation();
|
701
|
-
if (e.type === 'keydown' && e.key == 'Enter' && this.dropdown.isOpen) {
|
702
|
-
if (!this.remoteOperation && this.text && this.text !== '') {
|
703
|
-
this.itemsFiltered = this.items.filter((c) => (c[this.textField] as string).toLowerCase().includes(this.text.toLowerCase()));
|
704
|
-
if (this.itemsFiltered.length === 1) {
|
705
|
-
this.currentfocusedIndex = 0;
|
706
|
-
}
|
707
|
-
} else {
|
708
|
-
this.itemsFiltered = this.items;
|
709
|
-
}
|
710
|
-
|
711
|
-
if (
|
712
|
-
this.selectedItems.filter((c) => c[this.valueField] === this.itemsFiltered[this.currentfocusedIndex][this.valueField]).length > 0 &&
|
713
|
-
this.mode == 'multiple'
|
714
|
-
) {
|
715
|
-
if (this.allowNull == true || (this.allowNull == false && this.selectedItems.length > 1)) {
|
716
|
-
if (!this.remoteOperation && this.text && this.text !== '') {
|
717
|
-
this.selectedItems = this.selectedItems.filter(
|
718
|
-
(c) =>
|
719
|
-
c !==
|
720
|
-
this.items.filter((c) => (c[this.textField] as string).toLowerCase().includes(this.text.toLowerCase()))[this.currentfocusedIndex]
|
721
|
-
);
|
722
|
-
} else {
|
723
|
-
this.selectedItems = this.selectedItems.filter((c) => c[this.valueField] !== this.items[this.currentfocusedIndex][this.valueField]);
|
724
|
-
}
|
725
|
-
this.emitSelectionChangedEvent();
|
726
|
-
}
|
727
|
-
} else {
|
728
|
-
if (this.mode == 'multiple') {
|
729
|
-
if (this.currentfocusedIndex != -1) {
|
730
|
-
if (!this.remoteOperation && this.text && this.text !== '') {
|
731
|
-
if (this.itemsFiltered.length === 1) {
|
732
|
-
this.selectedItems.push(this.itemsFiltered[0]);
|
733
|
-
} else {
|
734
|
-
this.selectedItems.push(this.itemsFiltered[this.currentfocusedIndex]);
|
735
|
-
}
|
736
|
-
} else {
|
737
|
-
this.selectedItems.push(this.items[this.currentfocusedIndex]);
|
738
|
-
}
|
739
|
-
this.emitSelectionChangedEvent();
|
740
|
-
}
|
741
|
-
} else {
|
742
|
-
if (this.text && this.itemsFiltered?.length === 1) {
|
743
|
-
this.setSelectedItems(this.itemsFiltered, true);
|
744
|
-
}
|
745
|
-
if (this.mode == 'single') {
|
746
|
-
this.dropdown.close();
|
747
|
-
setTimeout(() => {
|
748
|
-
this.textBoxSelectBox.focus();
|
749
|
-
}, 0);
|
750
|
-
}
|
751
|
-
}
|
752
|
-
}
|
753
|
-
e.stopPropagation();
|
754
|
-
e.preventDefault();
|
755
|
-
e.stopImmediatePropagation();
|
756
|
-
}
|
757
|
-
this.cdr.markForCheck();
|
758
|
-
}
|
759
|
-
|
760
|
-
isChar(str: string) {
|
761
|
-
if (
|
762
|
-
str.includes('Shift') ||
|
763
|
-
str.includes('Tab') ||
|
764
|
-
str.includes('Control') ||
|
765
|
-
str.includes('Alt') ||
|
766
|
-
str.includes('CapsLock') ||
|
767
|
-
str.includes('Meta') ||
|
768
|
-
str.includes('ContextMenu') ||
|
769
|
-
str.includes('Enter') ||
|
770
|
-
str.includes('Backspace') ||
|
771
|
-
str.includes('PrintScreen') ||
|
772
|
-
str.includes('ScrollLock') ||
|
773
|
-
str.includes('Pause') ||
|
774
|
-
str.includes('Home') ||
|
775
|
-
str.includes('End') ||
|
776
|
-
str.includes('Insert') ||
|
777
|
-
str.includes('PageUp') ||
|
778
|
-
str.includes('Delete') ||
|
779
|
-
str.includes('PageDown') ||
|
780
|
-
str.includes('NumLock') ||
|
781
|
-
str.includes('Escape') ||
|
782
|
-
str.includes('Arrow') ||
|
783
|
-
str.includes('ّF1') ||
|
784
|
-
str.includes('F2') ||
|
785
|
-
str.includes('F3') ||
|
786
|
-
str.includes('F4') ||
|
787
|
-
str.includes('F5') ||
|
788
|
-
str.includes('F6') ||
|
789
|
-
str.includes('F7') ||
|
790
|
-
str.includes('F8') ||
|
791
|
-
str.includes('F9') ||
|
792
|
-
str.includes('F10') ||
|
793
|
-
str.includes('F11') ||
|
794
|
-
str.includes('F12')
|
795
|
-
) {
|
796
|
-
return false;
|
797
|
-
} else {
|
798
|
-
return true;
|
799
|
-
}
|
800
|
-
}
|
801
|
-
|
802
|
-
handleKeyEvent(e: any) {
|
803
|
-
// const NumberMinusPattern = /[a-zA-Z0-9\-]/g;
|
804
|
-
// const Farsi = /[پچجحخهعغفقثصضشسیبلاتنمکگوئدذرزطظژؤإأءًٌٍَُِّ\s]+$/;
|
805
|
-
// const inputChar = String.fromCharCode(e.charCode);
|
806
|
-
// const patternEn = /^[a-zA-Z0-9]*$/;
|
807
|
-
// const pattern = /^[\u0600-\u06FF\s]+$/;
|
808
|
-
const inputChar = e.key;
|
809
|
-
if (
|
810
|
-
(inputChar != 'Backspace' &&
|
811
|
-
inputChar != 'Backspace' &&
|
812
|
-
inputChar != 'Tab' &&
|
813
|
-
inputChar != 'Enter' &&
|
814
|
-
inputChar != 'Escape' &&
|
815
|
-
inputChar != 'ArrowDown' &&
|
816
|
-
inputChar != 'ArrowUp') ||
|
817
|
-
e.code === 'Space' ||
|
818
|
-
e.ctrlKey == true
|
819
|
-
) {
|
820
|
-
e.preventDefault();
|
821
|
-
}
|
822
|
-
if (
|
823
|
-
e.key === 'Backspace' &&
|
824
|
-
e.type === 'keydown' &&
|
825
|
-
((this.allowNull === true && this.selectedItems.length > 0) || (this.allowNull === false && this.selectedItems.length > 1))
|
826
|
-
) {
|
827
|
-
this.selectedItems.pop();
|
828
|
-
this.emitSelectionChangedEvent();
|
829
|
-
}
|
830
|
-
if (this.disabled || this.readonly) {
|
831
|
-
this.dropdown.close();
|
832
|
-
setTimeout(() => {
|
833
|
-
this.textBoxSelectBox.focus();
|
834
|
-
}, 0);
|
835
|
-
return false;
|
836
|
-
}
|
837
|
-
const INPUT = String.fromCharCode(e.keyCode);
|
838
|
-
if (this.isChar(e.key) && this.allowSearch && e.ctrlKey == false) {
|
839
|
-
this.dropdown.open();
|
840
|
-
setTimeout(() => {
|
841
|
-
if (this.serchBox) {
|
842
|
-
this.serchBox.focus();
|
843
|
-
}
|
844
|
-
}, 0);
|
845
|
-
this.text = e.key;
|
846
|
-
}
|
847
|
-
|
848
|
-
if (e.key === 'Escape') {
|
849
|
-
this.text = null;
|
850
|
-
this.dropdown.close();
|
851
|
-
setTimeout(() => {
|
852
|
-
this.textBoxSelectBox.focus();
|
853
|
-
}, 0);
|
854
|
-
}
|
855
|
-
if ((e.key === 'ArrowDown' || e.key === 'ArrowUp') && this.getItems().length > 0 && e.type === 'keydown') {
|
856
|
-
if (this.mode === 'single') {
|
857
|
-
this.selectedItemByIndex(this.currentfocusedIndex + (e.key === 'ArrowDown' ? 1 : -1));
|
858
|
-
} else {
|
859
|
-
if (this.dropdown.isOpen) {
|
860
|
-
// this.setSelectedIndex((e.key === 'ArrowDown' ? 1 : -1));
|
861
|
-
if (this.allowSearch == false) {
|
862
|
-
this.setSelectedIndex(e.key === 'ArrowDown' ? 1 : -1);
|
863
|
-
} else {
|
864
|
-
setTimeout(() => {
|
865
|
-
if (this.serchBox) {
|
866
|
-
this.serchBox.focus();
|
867
|
-
}
|
868
|
-
}, 0);
|
869
|
-
}
|
870
|
-
} else {
|
871
|
-
this.dropdown.open();
|
872
|
-
if (this.allowSearch == true) {
|
873
|
-
setTimeout(() => {
|
874
|
-
if (this.serchBox) {
|
875
|
-
this.serchBox.focus();
|
876
|
-
}
|
877
|
-
}, 0);
|
878
|
-
}
|
879
|
-
}
|
880
|
-
}
|
881
|
-
}
|
882
|
-
|
883
|
-
if (this.allowSearch === false) {
|
884
|
-
if (e.type === 'keydown' && e.key == 'Enter' && this.dropdown.isOpen) {
|
885
|
-
e.stopImmediatePropagation();
|
886
|
-
if (
|
887
|
-
this.selectedItems.filter((c) => c[this.valueField] === this.itemsFiltered[this.currentfocusedIndex][this.valueField]).length > 0 &&
|
888
|
-
this.mode == 'multiple'
|
889
|
-
) {
|
890
|
-
if (this.allowNull == true || (this.allowNull == false && this.selectedItems.length > 1)) {
|
891
|
-
if (!this.remoteOperation && this.text && this.text !== '') {
|
892
|
-
this.selectedItems = this.selectedItems.filter(
|
893
|
-
(c) =>
|
894
|
-
c !==
|
895
|
-
this.items.filter((c) => (c[this.textField] as string).toLowerCase().includes(this.text.toLowerCase()))[this.currentfocusedIndex]
|
896
|
-
);
|
897
|
-
} else {
|
898
|
-
this.selectedItems = this.selectedItems.filter((c) => c[this.valueField] !== this.items[this.currentfocusedIndex][this.valueField]);
|
899
|
-
}
|
900
|
-
this.emitSelectionChangedEvent();
|
901
|
-
}
|
902
|
-
} else {
|
903
|
-
if (this.mode == 'multiple') {
|
904
|
-
if (this.currentfocusedIndex != -1) {
|
905
|
-
if (!this.remoteOperation && this.text && this.text !== '') {
|
906
|
-
if (this.itemsFiltered.length === 1) {
|
907
|
-
this.selectedItems.push(this.itemsFiltered[0]);
|
908
|
-
} else {
|
909
|
-
this.selectedItems.push(this.itemsFiltered[this.currentfocusedIndex]);
|
910
|
-
}
|
911
|
-
} else {
|
912
|
-
this.selectedItems.push(this.items[this.currentfocusedIndex]);
|
913
|
-
}
|
914
|
-
this.emitSelectionChangedEvent();
|
915
|
-
}
|
916
|
-
} else {
|
917
|
-
if (this.text && this.itemsFiltered.length === 1) {
|
918
|
-
this.setSelectedItems(this.itemsFiltered, true);
|
919
|
-
}
|
920
|
-
if (this.mode == 'single') {
|
921
|
-
this.dropdown.close();
|
922
|
-
setTimeout(() => {
|
923
|
-
this.textBoxSelectBox.focus();
|
924
|
-
}, 0);
|
925
|
-
}
|
926
|
-
}
|
927
|
-
}
|
928
|
-
}
|
929
|
-
}
|
930
|
-
|
931
|
-
this.cdr.markForCheck();
|
932
|
-
}
|
933
|
-
|
934
|
-
focus(): void {
|
935
|
-
this.textbox.focus();
|
936
|
-
}
|
937
|
-
|
938
|
-
selectedItemByIndex(index: number) {
|
939
|
-
let item = [];
|
940
|
-
if (!this.remoteOperation && this.text && this.text !== '') {
|
941
|
-
this.itemsFiltered = this.items.filter((c) => (c[this.textField] as string).toLowerCase().includes(this.text.toLowerCase()));
|
942
|
-
|
943
|
-
item = this.itemsFiltered[index];
|
944
|
-
} else {
|
945
|
-
item = this.items[index];
|
946
|
-
}
|
947
|
-
//
|
948
|
-
// const item = this.text ? this.items.filter((c) => (c[this.textField] as string).toLowerCase().includes(this.text.toLowerCase()))[index] : this.items[index];
|
949
|
-
if (item) {
|
950
|
-
this.setSelectedItems([item], true);
|
951
|
-
}
|
952
|
-
|
953
|
-
this.setSelectedIndex();
|
954
|
-
}
|
955
|
-
|
956
|
-
getItems(): any[] {
|
957
|
-
if (this.items == null) {
|
958
|
-
return [];
|
959
|
-
}
|
960
|
-
return !this.remoteOperation && this.text && this.text !== ''
|
961
|
-
? this.items.filter((c) => (c[this.textField] as string).toLowerCase().includes(this.text.toLowerCase()))
|
962
|
-
: this.items;
|
963
|
-
}
|
964
|
-
|
965
|
-
isItemSelected(item: any): boolean {
|
966
|
-
return this.selectedItems && this.selectedItems.filter((c) => c[this.valueField] === item[this.valueField]).length > 0;
|
967
|
-
}
|
968
|
-
|
969
|
-
private itemsStatusObserver: any;
|
970
|
-
private waitForData(callbackfn: () => void) {
|
971
|
-
if (this.items && this.items.length) {
|
972
|
-
callbackfn();
|
973
|
-
} else if (!this.itemsStatusObserver) {
|
974
|
-
Observable.create((observer) => {
|
975
|
-
this.itemsStatusObserver = observer;
|
976
|
-
})
|
977
|
-
.pipe(debounceTime(100))
|
978
|
-
.pipe(distinctUntilChanged())
|
979
|
-
.subscribe((c) => {
|
980
|
-
callbackfn();
|
981
|
-
});
|
982
|
-
}
|
983
|
-
}
|
984
|
-
}
|