@acorex/components 7.2.6 → 7.2.8
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/alert/lib/alert.component.d.ts +2 -1
- package/breadcrumbs/lib/breadcrumbs-item.component.d.ts +5 -69
- package/button/lib/button-group.component.d.ts +6 -6
- package/button/lib/button-item.component.d.ts +6 -6
- package/calendar/lib/calendar.component.d.ts +1 -0
- package/checkbox/lib/checkbox.component.d.ts +15 -9
- package/chips/lib/chips.component.d.ts +5 -64
- package/collapse/lib/collapse-group.component.d.ts +22 -10
- package/collapse/lib/collapse.component.d.ts +13 -7
- package/color-palette/lib/color-palette-input.component.d.ts +11 -10
- package/color-palette/lib/color-palette-picker.component.d.ts +12 -10
- package/color-palette/lib/color-palette-preview.component.d.ts +11 -7
- package/color-palette/lib/color-palette-swatches.component.d.ts +13 -11
- package/color-palette/lib/color-palette.class.d.ts +12 -6
- package/color-palette/lib/color-palette.component.d.ts +4 -10
- package/color-palette/lib/color-palette.module.d.ts +9 -8
- package/color-picker/lib/color-picker.component.d.ts +21 -18
- package/common/index.d.ts +1 -0
- package/common/lib/classes/components.class.d.ts +2 -1
- package/common/lib/components/base-component.class.d.ts +11 -9
- package/common/lib/components/input-base-value-component.class.d.ts +26 -0
- package/common/lib/components/interactive-component.class.d.ts +7 -0
- package/common/lib/components/value-component.class.d.ts +15 -7
- package/decorators/index.d.ts +1 -0
- package/decorators/lib/divider.component.d.ts +5 -0
- package/drawer/lib/drawer.component.d.ts +1 -1
- package/esm2022/acorex-components.mjs +1 -1
- package/esm2022/action-sheet/lib/action-sheet.component.mjs +3 -3
- package/esm2022/action-sheet/lib/action-sheet.module.mjs +4 -4
- package/esm2022/action-sheet/lib/action-sheet.service.mjs +3 -3
- package/esm2022/alert/lib/alert.component.mjs +13 -11
- package/esm2022/alert/lib/alert.module.mjs +4 -4
- package/esm2022/avatar/lib/avatar-group.component.mjs +3 -3
- package/esm2022/avatar/lib/avatar.component.mjs +3 -3
- package/esm2022/avatar/lib/avatar.module.mjs +4 -4
- package/esm2022/badge/lib/badge.component.mjs +5 -5
- package/esm2022/badge/lib/badge.module.mjs +4 -4
- package/esm2022/breadcrumbs/lib/breadcrumbs-item.component.mjs +11 -20
- package/esm2022/breadcrumbs/lib/breadcrumbs.component.mjs +4 -4
- package/esm2022/breadcrumbs/lib/breadcrumbs.module.mjs +4 -4
- package/esm2022/button/lib/button-group.component.mjs +3 -3
- package/esm2022/button/lib/button-item.component.mjs +3 -3
- package/esm2022/button/lib/button.component.mjs +3 -3
- package/esm2022/button/lib/button.module.mjs +4 -4
- package/esm2022/calendar/lib/calendar-range.component.mjs +3 -3
- package/esm2022/calendar/lib/calendar.class.mjs +6 -5
- package/esm2022/calendar/lib/calendar.component.mjs +15 -14
- package/esm2022/calendar/lib/calendar.module.mjs +4 -4
- package/esm2022/checkbox/lib/checkbox.component.mjs +44 -20
- package/esm2022/checkbox/lib/checkbox.module.mjs +4 -4
- package/esm2022/chips/lib/chips.component.mjs +9 -11
- package/esm2022/chips/lib/chips.module.mjs +4 -4
- package/esm2022/collapse/lib/collapse-group.component.mjs +81 -25
- package/esm2022/collapse/lib/collapse.component.mjs +29 -16
- package/esm2022/collapse/lib/collapse.module.mjs +4 -4
- package/esm2022/color-palette/lib/color-palette-input.component.mjs +59 -74
- package/esm2022/color-palette/lib/color-palette-picker.component.mjs +78 -69
- package/esm2022/color-palette/lib/color-palette-preview.component.mjs +33 -27
- package/esm2022/color-palette/lib/color-palette-swatches.component.mjs +37 -251
- package/esm2022/color-palette/lib/color-palette.class.mjs +229 -8
- package/esm2022/color-palette/lib/color-palette.component.mjs +32 -58
- package/esm2022/color-palette/lib/color-palette.module.mjs +9 -6
- package/esm2022/color-picker/lib/color-picker.component.mjs +5 -8
- package/esm2022/color-picker/lib/color-picker.module.mjs +4 -4
- package/esm2022/common/index.mjs +2 -1
- package/esm2022/common/lib/classes/components.class.mjs +19 -19
- package/esm2022/common/lib/common.module.mjs +4 -4
- package/esm2022/common/lib/components/base-component.class.mjs +12 -8
- package/esm2022/common/lib/components/input-base-value-component.class.mjs +47 -0
- package/esm2022/common/lib/components/interactive-component.class.mjs +31 -4
- package/esm2022/common/lib/components/value-component.class.mjs +60 -38
- package/esm2022/common/lib/directives/auto-focus.directive.mjs +3 -3
- package/esm2022/common/lib/directives/debounce-time.directive.mjs +3 -3
- package/esm2022/common/lib/directives/hotkey.directive.mjs +3 -3
- package/esm2022/common/lib/directives/infinite-scroll.directive.mjs +3 -3
- package/esm2022/common/lib/directives/responsive.directive.mjs +3 -3
- package/esm2022/common/lib/services/custom-cdk-overlay.service.mjs +6 -6
- package/esm2022/common/lib/services/hotkey.service.mjs +3 -3
- package/esm2022/common/lib/services/overlay.service.mjs +3 -3
- package/esm2022/context-menu/lib/context-menu.component.mjs +3 -3
- package/esm2022/context-menu/lib/context-menu.module.mjs +4 -4
- package/esm2022/data-pager/lib/data-pager-base.component.mjs +6 -6
- package/esm2022/data-pager/lib/data-pager-info.component.mjs +3 -3
- package/esm2022/data-pager/lib/data-pager-input-selector.component.mjs +3 -3
- package/esm2022/data-pager/lib/data-pager-next-buttons.components.mjs +3 -3
- package/esm2022/data-pager/lib/data-pager-numeric-selector.component.mjs +3 -3
- package/esm2022/data-pager/lib/data-pager-pagesize-dropdown.component.mjs +3 -3
- package/esm2022/data-pager/lib/data-pager-prev-buttons.component.mjs +3 -3
- package/esm2022/data-pager/lib/data-pager.component.mjs +3 -3
- package/esm2022/data-pager/lib/data-pager.module.mjs +4 -4
- package/esm2022/data-table/lib/data-column-cell-template.directive.mjs +3 -3
- package/esm2022/data-table/lib/data-column.directive.mjs +3 -3
- package/esm2022/data-table/lib/data-table.component.mjs +3 -3
- package/esm2022/data-table/lib/data-table.module.mjs +4 -4
- package/esm2022/date-picker/lib/datepicker.component.mjs +3 -3
- package/esm2022/date-picker/lib/datepicker.module.mjs +4 -4
- package/esm2022/decorators/index.mjs +2 -1
- package/esm2022/decorators/lib/close-button.component.mjs +3 -3
- package/esm2022/decorators/lib/content.component.mjs +3 -3
- package/esm2022/decorators/lib/decorators.module.mjs +4 -4
- package/esm2022/decorators/lib/divider.component.mjs +17 -0
- package/esm2022/decorators/lib/footer.component.mjs +3 -3
- package/esm2022/decorators/lib/form-hint.component.mjs +6 -6
- package/esm2022/decorators/lib/header.component.mjs +3 -3
- package/esm2022/decorators/lib/icon.component.mjs +3 -3
- package/esm2022/decorators/lib/overlay.component.mjs +3 -3
- package/esm2022/decorators/lib/placeholder.component.mjs +3 -3
- package/esm2022/decorators/lib/prefix.component.mjs +3 -3
- package/esm2022/decorators/lib/sub-title.component.mjs +3 -3
- package/esm2022/decorators/lib/suffix.component.mjs +4 -4
- package/esm2022/decorators/lib/text.component.mjs +3 -3
- package/esm2022/decorators/lib/title.component.mjs +3 -3
- package/esm2022/dialog/lib/dialog.component.mjs +3 -3
- package/esm2022/dialog/lib/dialog.module.mjs +4 -4
- package/esm2022/dialog/lib/dialog.service.mjs +3 -3
- package/esm2022/drawer/lib/drawer-container.component.mjs +3 -3
- package/esm2022/drawer/lib/drawer.component.mjs +6 -5
- package/esm2022/drawer/lib/drawer.module.mjs +4 -4
- package/esm2022/dropdown/lib/dropdown-panel.component.mjs +3 -3
- package/esm2022/dropdown/lib/dropdown.module.mjs +4 -4
- package/esm2022/form/lib/form-field.component.mjs +4 -4
- package/esm2022/form/lib/form.component.mjs +4 -6
- package/esm2022/form/lib/form.module.mjs +4 -4
- package/esm2022/form/lib/validation-rule.widget.mjs +3 -3
- package/esm2022/form/lib/validation-summary.component.mjs +3 -3
- package/esm2022/image/lib/image.component.mjs +3 -3
- package/esm2022/image/lib/image.module.mjs +4 -4
- package/esm2022/index.mjs +1 -1
- package/esm2022/label/lib/label.component.mjs +4 -4
- package/esm2022/label/lib/label.module.mjs +4 -4
- package/esm2022/loading/lib/loading-spinner.component.mjs +3 -3
- package/esm2022/loading/lib/loading.component.mjs +3 -3
- package/esm2022/loading/lib/loading.directive.mjs +3 -3
- package/esm2022/loading/lib/loading.module.mjs +4 -4
- package/esm2022/loading/lib/loading.service.mjs +3 -3
- package/esm2022/menu/lib/menu.component.mjs +3 -3
- package/esm2022/menu/lib/menu.module.mjs +4 -4
- package/esm2022/mixin/lib/base-components.class.mjs +3 -3
- package/esm2022/mixin/lib/base-menu-mixin.class.mjs +3 -3
- package/esm2022/mixin/lib/value-mixin.class.mjs +4 -1
- package/esm2022/notification/lib/notification.component.mjs +3 -3
- package/esm2022/notification/lib/notification.module.mjs +4 -4
- package/esm2022/notification/lib/notification.service.mjs +3 -3
- package/esm2022/number-box/lib/number-box.component.mjs +3 -3
- package/esm2022/number-box/lib/number-box.module.mjs +4 -4
- package/esm2022/otp/lib/otp.component.mjs +3 -3
- package/esm2022/otp/lib/otp.module.mjs +4 -4
- package/esm2022/page/lib/base-page.class.mjs +3 -3
- package/esm2022/page/lib/page.component.mjs +3 -3
- package/esm2022/page/lib/page.module.mjs +4 -4
- package/esm2022/password-box/lib/password-box.component.mjs +3 -3
- package/esm2022/password-box/lib/password-box.module.mjs +4 -4
- package/esm2022/popover/lib/dropdown-component.class.mjs +3 -3
- package/esm2022/popover/lib/popover.component.mjs +3 -3
- package/esm2022/popover/lib/popover.module.mjs +4 -4
- package/esm2022/popup/lib/popup.component.mjs +3 -3
- package/esm2022/popup/lib/popup.module.mjs +4 -4
- package/esm2022/popup/lib/popup.service.mjs +3 -3
- package/esm2022/progress-bar/lib/progress-bar.component.mjs +3 -3
- package/esm2022/progress-bar/lib/progress-bar.module.mjs +4 -4
- package/esm2022/radio/lib/radio.component.mjs +3 -3
- package/esm2022/radio/lib/radio.module.mjs +4 -4
- package/esm2022/range-slider/lib/range-slider.component.mjs +36 -23
- package/esm2022/range-slider/lib/range-slider.module.mjs +7 -6
- package/esm2022/result/lib/result.component.mjs +3 -3
- package/esm2022/result/lib/result.module.mjs +4 -4
- package/esm2022/search-box/lib/search-box.component.mjs +3 -3
- package/esm2022/search-box/lib/search-box.module.mjs +4 -4
- package/esm2022/select-box/lib/select-box.component.mjs +3 -3
- package/esm2022/select-box/lib/select-box.module.mjs +4 -4
- package/esm2022/selection-list/lib/selection-list.component.mjs +3 -3
- package/esm2022/selection-list/lib/selection-list.module.mjs +4 -4
- package/esm2022/switch/lib/switch-content.component.mjs +3 -3
- package/esm2022/switch/lib/switch.component.mjs +27 -25
- package/esm2022/switch/lib/switch.module.mjs +4 -4
- package/esm2022/tabs/lib/tab-content.directive.mjs +3 -3
- package/esm2022/tabs/lib/tab-item.component.mjs +3 -3
- package/esm2022/tabs/lib/tabs.component.mjs +3 -3
- package/esm2022/tabs/lib/tabs.module.mjs +4 -4
- package/esm2022/tag/lib/tag.component.mjs +3 -3
- package/esm2022/tag/lib/tag.module.mjs +4 -4
- package/esm2022/textarea/lib/textarea.component.mjs +3 -3
- package/esm2022/textarea/lib/textarea.module.mjs +4 -4
- package/esm2022/textbox/lib/mask-options.directive.mjs +3 -3
- package/esm2022/textbox/lib/textbox.component.mjs +39 -21
- package/esm2022/textbox/lib/textbox.module.mjs +4 -4
- package/esm2022/time-box/lib/time-box.component.mjs +4 -6
- package/esm2022/time-box/lib/time-box.module.mjs +4 -4
- package/esm2022/toast/lib/toast.component.mjs +3 -3
- package/esm2022/toast/lib/toast.module.mjs +4 -4
- package/esm2022/toast/lib/toast.service.mjs +3 -3
- package/esm2022/tooltip/lib/tooltip.component.mjs +3 -3
- package/esm2022/tooltip/lib/tooltip.directive.mjs +3 -3
- package/esm2022/tooltip/lib/tooltip.module.mjs +4 -4
- package/esm2022/uploader/lib/uploader.component.mjs +3 -3
- package/esm2022/uploader/lib/uploader.module.mjs +4 -4
- package/fesm2022/acorex-components-action-sheet.mjs +10 -10
- package/fesm2022/acorex-components-alert.mjs +16 -14
- package/fesm2022/acorex-components-alert.mjs.map +1 -1
- package/fesm2022/acorex-components-avatar.mjs +10 -10
- package/fesm2022/acorex-components-badge.mjs +8 -8
- package/fesm2022/acorex-components-badge.mjs.map +1 -1
- package/fesm2022/acorex-components-breadcrumbs.mjs +18 -28
- package/fesm2022/acorex-components-breadcrumbs.mjs.map +1 -1
- package/fesm2022/acorex-components-button.mjs +13 -13
- package/fesm2022/acorex-components-calendar.mjs +26 -24
- package/fesm2022/acorex-components-calendar.mjs.map +1 -1
- package/fesm2022/acorex-components-checkbox.mjs +47 -24
- package/fesm2022/acorex-components-checkbox.mjs.map +1 -1
- package/fesm2022/acorex-components-chips.mjs +13 -15
- package/fesm2022/acorex-components-chips.mjs.map +1 -1
- package/fesm2022/acorex-components-collapse.mjs +110 -41
- package/fesm2022/acorex-components-collapse.mjs.map +1 -1
- package/fesm2022/acorex-components-color-palette.mjs +445 -461
- package/fesm2022/acorex-components-color-palette.mjs.map +1 -1
- package/fesm2022/acorex-components-color-picker.mjs +8 -11
- package/fesm2022/acorex-components-color-picker.mjs.map +1 -1
- package/fesm2022/acorex-components-common.mjs +192 -97
- package/fesm2022/acorex-components-common.mjs.map +1 -1
- package/fesm2022/acorex-components-context-menu.mjs +7 -7
- package/fesm2022/acorex-components-data-pager.mjs +31 -31
- package/fesm2022/acorex-components-data-table.mjs +13 -13
- package/fesm2022/acorex-components-date-picker.mjs +7 -7
- package/fesm2022/acorex-components-decorators.mjs +60 -45
- package/fesm2022/acorex-components-decorators.mjs.map +1 -1
- package/fesm2022/acorex-components-dialog.mjs +10 -10
- package/fesm2022/acorex-components-drawer.mjs +11 -10
- package/fesm2022/acorex-components-drawer.mjs.map +1 -1
- package/fesm2022/acorex-components-dropdown.mjs +7 -7
- package/fesm2022/acorex-components-form.mjs +17 -19
- package/fesm2022/acorex-components-form.mjs.map +1 -1
- package/fesm2022/acorex-components-image.mjs +7 -7
- package/fesm2022/acorex-components-label.mjs +8 -8
- package/fesm2022/acorex-components-label.mjs.map +1 -1
- package/fesm2022/acorex-components-loading.mjs +16 -16
- package/fesm2022/acorex-components-menu.mjs +7 -7
- package/fesm2022/acorex-components-mixin.mjs +7 -5
- package/fesm2022/acorex-components-mixin.mjs.map +1 -1
- package/fesm2022/acorex-components-notification.mjs +10 -10
- package/fesm2022/acorex-components-number-box.mjs +7 -7
- package/fesm2022/acorex-components-otp.mjs +7 -7
- package/fesm2022/acorex-components-page.mjs +10 -10
- package/fesm2022/acorex-components-password-box.mjs +7 -7
- package/fesm2022/acorex-components-popover.mjs +10 -10
- package/fesm2022/acorex-components-popup.mjs +10 -10
- package/fesm2022/acorex-components-progress-bar.mjs +7 -7
- package/fesm2022/acorex-components-radio.mjs +7 -7
- package/fesm2022/acorex-components-range-slider.mjs +40 -28
- package/fesm2022/acorex-components-range-slider.mjs.map +1 -1
- package/fesm2022/acorex-components-result.mjs +7 -7
- package/fesm2022/acorex-components-search-box.mjs +7 -7
- package/fesm2022/acorex-components-search-box.mjs.map +1 -1
- package/fesm2022/acorex-components-select-box.mjs +7 -7
- package/fesm2022/acorex-components-selection-list.mjs +7 -7
- package/fesm2022/acorex-components-switch.mjs +33 -32
- package/fesm2022/acorex-components-switch.mjs.map +1 -1
- package/fesm2022/acorex-components-tabs.mjs +13 -13
- package/fesm2022/acorex-components-tag.mjs +7 -7
- package/fesm2022/acorex-components-textarea.mjs +7 -7
- package/fesm2022/acorex-components-textbox.mjs +45 -28
- package/fesm2022/acorex-components-textbox.mjs.map +1 -1
- package/fesm2022/acorex-components-time-box.mjs +7 -9
- package/fesm2022/acorex-components-time-box.mjs.map +1 -1
- package/fesm2022/acorex-components-toast.mjs +10 -10
- package/fesm2022/acorex-components-tooltip.mjs +10 -10
- package/fesm2022/acorex-components-uploader.mjs +7 -7
- package/fesm2022/acorex-components.mjs.map +1 -1
- package/mixin/lib/base-components.class.d.ts +2 -2
- package/mixin/lib/base-menu-mixin.class.d.ts +5 -5
- package/mixin/lib/button-mixin.class.d.ts +2 -2
- package/mixin/lib/clickable-mixin.class.d.ts +2 -2
- package/mixin/lib/color-look-mixing.class.d.ts +2 -2
- package/mixin/lib/datalist-component.class.d.ts +10 -10
- package/mixin/lib/dropdown-mixin.class.d.ts +2 -2
- package/mixin/lib/interactive-mixin.class.d.ts +4 -4
- package/mixin/lib/loading-mixin.class.d.ts +2 -2
- package/mixin/lib/mixin.class.d.ts +62 -61
- package/mixin/lib/page-component.class.d.ts +2 -2
- package/mixin/lib/selection-component.class.d.ts +2 -2
- package/mixin/lib/sizable-mixin.class.d.ts +2 -2
- package/mixin/lib/textbox-mixin.class.d.ts +2 -2
- package/mixin/lib/value-mixin.class.d.ts +9 -8
- package/package.json +25 -25
- package/range-slider/lib/range-slider.component.d.ts +8 -9
- package/range-slider/lib/range-slider.module.d.ts +3 -2
- package/switch/lib/switch.component.d.ts +10 -8
- package/tabs/lib/tab-item.component.d.ts +2 -2
- package/textbox/lib/textbox.component.d.ts +8 -8
- package/time-box/lib/time-box.component.d.ts +1 -1
@@ -1,7 +1,7 @@
|
|
1
1
|
import * as i0 from '@angular/core';
|
2
2
|
import { Injectable, Directive, Host, Self, Optional, Input, EventEmitter, Output, Inject, NgModule, inject, ChangeDetectorRef, ElementRef, ViewContainerRef, TemplateRef } from '@angular/core';
|
3
3
|
import * as i1 from '@angular/forms';
|
4
|
-
import { skip, distinctUntilChanged, debounceTime, fromEvent, merge } from 'rxjs';
|
4
|
+
import { skip, distinctUntilChanged, debounceTime, fromEvent, noop, merge } from 'rxjs';
|
5
5
|
import * as i3 from '@angular/common';
|
6
6
|
import { DOCUMENT } from '@angular/common';
|
7
7
|
import * as i1$1 from '@angular/platform-browser';
|
@@ -9,7 +9,7 @@ import { Observable } from 'rxjs/internal/Observable';
|
|
9
9
|
import { map, pairwise, filter, startWith, exhaustMap } from 'rxjs/operators';
|
10
10
|
import { classes } from 'polytype';
|
11
11
|
import { AXHtmlUtil, AXObjectUtil } from '@acorex/core/utils';
|
12
|
-
import {
|
12
|
+
import { coerceBooleanProperty, coerceNumberProperty } from '@angular/cdk/coercion';
|
13
13
|
import * as i1$2 from '@angular/cdk/overlay';
|
14
14
|
import { OverlayContainer, Overlay } from '@angular/cdk/overlay';
|
15
15
|
import * as i2 from '@angular/cdk/bidi';
|
@@ -118,45 +118,45 @@ class AXComponentClosedPromise extends Promise {
|
|
118
118
|
}
|
119
119
|
}
|
120
120
|
class AXComponent {
|
121
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
122
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.
|
121
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXComponent, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
122
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXComponent }); }
|
123
123
|
}
|
124
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
124
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXComponent, decorators: [{
|
125
125
|
type: Injectable
|
126
126
|
}] });
|
127
127
|
class AXClosbaleComponent extends AXComponent {
|
128
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
129
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.
|
128
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXClosbaleComponent, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
|
129
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXClosbaleComponent }); }
|
130
130
|
}
|
131
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
131
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXClosbaleComponent, decorators: [{
|
132
132
|
type: Injectable
|
133
133
|
}] });
|
134
134
|
class AXSearchableComponent extends AXComponent {
|
135
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
136
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.
|
135
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXSearchableComponent, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
|
136
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXSearchableComponent }); }
|
137
137
|
}
|
138
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
138
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXSearchableComponent, decorators: [{
|
139
139
|
type: Injectable
|
140
140
|
}] });
|
141
141
|
class AXValuableComponent extends AXComponent {
|
142
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
143
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.
|
142
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXValuableComponent, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
|
143
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXValuableComponent }); }
|
144
144
|
}
|
145
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
145
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXValuableComponent, decorators: [{
|
146
146
|
type: Injectable
|
147
147
|
}] });
|
148
148
|
class AXFocusableComponent extends AXComponent {
|
149
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
150
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.
|
149
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXFocusableComponent, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
|
150
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXFocusableComponent }); }
|
151
151
|
}
|
152
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
152
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXFocusableComponent, decorators: [{
|
153
153
|
type: Injectable
|
154
154
|
}] });
|
155
155
|
class AXPagedComponent extends AXComponent {
|
156
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
157
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.
|
156
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXPagedComponent, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
|
157
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXPagedComponent }); }
|
158
158
|
}
|
159
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
159
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXPagedComponent, decorators: [{
|
160
160
|
type: Injectable
|
161
161
|
}] });
|
162
162
|
|
@@ -194,10 +194,10 @@ class AXAutoFocusDirective {
|
|
194
194
|
}, 100);
|
195
195
|
}
|
196
196
|
}
|
197
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
198
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.
|
197
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXAutoFocusDirective, deps: [{ token: i0.ElementRef }, { token: AXFocusableComponent, host: true, optional: true, self: true }], target: i0.ɵɵFactoryTarget.Directive }); }
|
198
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.6", type: AXAutoFocusDirective, selector: "[axAutoFocus]", inputs: { autoFocus: ["axAutoFocus", "autoFocus"], time: ["focus-time", "time"] }, ngImport: i0 }); }
|
199
199
|
}
|
200
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
200
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXAutoFocusDirective, decorators: [{
|
201
201
|
type: Directive,
|
202
202
|
args: [{
|
203
203
|
selector: '[axAutoFocus]',
|
@@ -243,10 +243,10 @@ class AXNgModelChangeDebouncedDirective {
|
|
243
243
|
this.subscription = this.ngModel.control.valueChanges.pipe(skip(1), // skip initial value
|
244
244
|
distinctUntilChanged(), debounceTime(this.ngModelChangeDebounceTime)).subscribe((value) => this.ngModelChangeDebounced.emit(value));
|
245
245
|
}
|
246
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
247
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.
|
246
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXNgModelChangeDebouncedDirective, deps: [{ token: i1.NgModel }], target: i0.ɵɵFactoryTarget.Directive }); }
|
247
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.6", type: AXNgModelChangeDebouncedDirective, selector: "[ngModelChangeDebounced]", inputs: { ngModelChangeDebounceTime: "ngModelChangeDebounceTime" }, outputs: { ngModelChangeDebounced: "ngModelChangeDebounced", ngModelChangeDebounceTimeChange: "ngModelChangeDebounceTimeChange" }, ngImport: i0 }); }
|
248
248
|
}
|
249
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
249
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXNgModelChangeDebouncedDirective, decorators: [{
|
250
250
|
type: Directive,
|
251
251
|
args: [{
|
252
252
|
selector: '[ngModelChangeDebounced]',
|
@@ -288,10 +288,10 @@ class AXHotkeysService {
|
|
288
288
|
}
|
289
289
|
});
|
290
290
|
}
|
291
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
292
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.
|
291
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXHotkeysService, deps: [{ token: i1$1.EventManager }, { token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
292
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXHotkeysService, providedIn: 'root' }); }
|
293
293
|
}
|
294
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
294
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXHotkeysService, decorators: [{
|
295
295
|
type: Injectable,
|
296
296
|
args: [{ providedIn: 'root' }]
|
297
297
|
}], ctorParameters: function () { return [{ type: i1$1.EventManager }, { type: Document, decorators: [{
|
@@ -355,10 +355,10 @@ class AXHotkeyDirective {
|
|
355
355
|
s.unsubscribe();
|
356
356
|
});
|
357
357
|
}
|
358
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
359
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.
|
358
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXHotkeyDirective, deps: [{ token: i0.ElementRef }, { token: AXComponent, host: true, optional: true, self: true }, { token: AXHotkeysService }], target: i0.ɵɵFactoryTarget.Directive }); }
|
359
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.6", type: AXHotkeyDirective, selector: "[hotkey]", inputs: { hotkey: "hotkey" }, ngImport: i0 }); }
|
360
360
|
}
|
361
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
361
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXHotkeyDirective, decorators: [{
|
362
362
|
type: Directive,
|
363
363
|
args: [{
|
364
364
|
selector: '[hotkey]',
|
@@ -417,10 +417,10 @@ class AXInfiniteScrollerDirective {
|
|
417
417
|
}));
|
418
418
|
//.subscribe((data) => { console.log(data) }, (err) => console.log(err));
|
419
419
|
}
|
420
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
421
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.
|
420
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXInfiniteScrollerDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
421
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.6", type: AXInfiniteScrollerDirective, selector: "[axInfiniteScroller]", inputs: { scrollCallback: "scrollCallback", immediateCallback: "immediateCallback", scrollPercent: "scrollPercent" }, ngImport: i0 }); }
|
422
422
|
}
|
423
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
423
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXInfiniteScrollerDirective, decorators: [{
|
424
424
|
type: Directive,
|
425
425
|
args: [{
|
426
426
|
selector: '[axInfiniteScroller]'
|
@@ -460,17 +460,17 @@ class AXResponsiveDirective {
|
|
460
460
|
this._observer?.disconnect();
|
461
461
|
this._observer?.unobserve(this._elementRef.nativeElement);
|
462
462
|
}
|
463
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
464
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.
|
463
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXResponsiveDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
464
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.6", type: AXResponsiveDirective, selector: "[ax-responsive]", ngImport: i0 }); }
|
465
465
|
}
|
466
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
466
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXResponsiveDirective, decorators: [{
|
467
467
|
type: Directive,
|
468
468
|
args: [{ selector: '[ax-responsive]' }]
|
469
469
|
}], ctorParameters: function () { return [{ type: i0.ElementRef }]; } });
|
470
470
|
|
471
471
|
class AXCommonModule {
|
472
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
473
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.
|
472
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXCommonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
473
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.6", ngImport: i0, type: AXCommonModule, declarations: [AXResponsiveDirective,
|
474
474
|
AXInfiniteScrollerDirective,
|
475
475
|
AXNgModelChangeDebouncedDirective,
|
476
476
|
AXAutoFocusDirective,
|
@@ -479,9 +479,9 @@ class AXCommonModule {
|
|
479
479
|
AXAutoFocusDirective,
|
480
480
|
AXNgModelChangeDebouncedDirective,
|
481
481
|
AXHotkeyDirective] }); }
|
482
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.
|
482
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXCommonModule }); }
|
483
483
|
}
|
484
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
484
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXCommonModule, decorators: [{
|
485
485
|
type: NgModule,
|
486
486
|
args: [{
|
487
487
|
imports: [],
|
@@ -519,21 +519,24 @@ class MXBaseComponent {
|
|
519
519
|
getViewContainer() {
|
520
520
|
return this._viewRef;
|
521
521
|
}
|
522
|
-
|
522
|
+
internalOptionChanging(option) {
|
523
523
|
return option?.value;
|
524
524
|
}
|
525
|
+
internalOptionChanged(option) {
|
526
|
+
}
|
525
527
|
init() {
|
526
528
|
this.getHostElement().__axContext__ = this;
|
527
529
|
}
|
528
530
|
setOption(option) {
|
529
531
|
const oldValue = this[option.name];
|
530
|
-
|
532
|
+
let newValue = this.internalOptionChanging({
|
531
533
|
name: option.name,
|
532
534
|
value: option.value,
|
533
535
|
});
|
534
536
|
//TODO : check real changes
|
535
|
-
if (option.beforeCallback)
|
536
|
-
option.beforeCallback(oldValue, newValue);
|
537
|
+
if (option.beforeCallback) {
|
538
|
+
newValue = option.beforeCallback(oldValue, newValue);
|
539
|
+
}
|
537
540
|
if (oldValue != newValue) {
|
538
541
|
this[`_${option.name}`] = option.value;
|
539
542
|
this.onOptionChanged.emit({
|
@@ -544,6 +547,7 @@ class MXBaseComponent {
|
|
544
547
|
});
|
545
548
|
const emitter = this[`${option.name}Change`];
|
546
549
|
emitter?.emit(newValue);
|
550
|
+
this.internalOptionChanged({ name: option.name, value: newValue });
|
547
551
|
}
|
548
552
|
if (option.afterCallback)
|
549
553
|
option.afterCallback(oldValue, newValue);
|
@@ -558,10 +562,10 @@ class MXBaseComponent {
|
|
558
562
|
set rtl(value) {
|
559
563
|
this.setOption({ name: 'rtl', value });
|
560
564
|
}
|
561
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
562
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.
|
565
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: MXBaseComponent, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
566
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: MXBaseComponent }); }
|
563
567
|
}
|
564
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
568
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: MXBaseComponent, decorators: [{
|
565
569
|
type: Injectable
|
566
570
|
}] });
|
567
571
|
const BASE_INPUTS = ['rtl'];
|
@@ -626,6 +630,18 @@ const COLOR_LOOK_INPUTS = [...COLOR_INPUTS, ...LOOK_INPUTS];
|
|
626
630
|
const COLOR_LOOK_OUTPUT = [...COLOR_OUTPUT, ...LOOK_OUTPUT];
|
627
631
|
|
628
632
|
class MXInteractiveComponent extends MXBaseComponent {
|
633
|
+
registerOnTouched(fn) {
|
634
|
+
this.onTouchedCallback = fn;
|
635
|
+
}
|
636
|
+
get touched() {
|
637
|
+
return this._touched;
|
638
|
+
}
|
639
|
+
markAsTouched() {
|
640
|
+
if (!this.touched) {
|
641
|
+
this.onTouchedCallback();
|
642
|
+
this._touched = true;
|
643
|
+
}
|
644
|
+
}
|
629
645
|
/**
|
630
646
|
* If set to true, it disables the component.
|
631
647
|
*/
|
@@ -633,7 +649,17 @@ class MXInteractiveComponent extends MXBaseComponent {
|
|
633
649
|
return this._disabled;
|
634
650
|
}
|
635
651
|
set disabled(value) {
|
636
|
-
|
652
|
+
value = coerceBooleanProperty(value);
|
653
|
+
this.setOption({
|
654
|
+
name: 'disabled',
|
655
|
+
value,
|
656
|
+
afterCallback: () => {
|
657
|
+
this.cdr.markForCheck();
|
658
|
+
},
|
659
|
+
});
|
660
|
+
}
|
661
|
+
setDisabledState(isDisabled) {
|
662
|
+
this.disabled = isDisabled;
|
637
663
|
}
|
638
664
|
/**
|
639
665
|
* Specifies the tabindex of the component.
|
@@ -652,6 +678,7 @@ class MXInteractiveComponent extends MXBaseComponent {
|
|
652
678
|
});
|
653
679
|
}
|
654
680
|
emitOnBlurEvent(e) {
|
681
|
+
this.markAsTouched();
|
655
682
|
this.onBlur.emit({
|
656
683
|
component: this,
|
657
684
|
htmlElement: this.getHostElement(),
|
@@ -660,6 +687,9 @@ class MXInteractiveComponent extends MXBaseComponent {
|
|
660
687
|
}
|
661
688
|
constructor() {
|
662
689
|
super();
|
690
|
+
this.onTouchedCallback = noop;
|
691
|
+
this._touched = false;
|
692
|
+
this.disabledChange = new EventEmitter();
|
663
693
|
this._tabIndex = 0;
|
664
694
|
/**
|
665
695
|
* Fires each time the component gets focused.
|
@@ -683,7 +713,7 @@ class MXInteractiveComponent extends MXBaseComponent {
|
|
683
713
|
}
|
684
714
|
}
|
685
715
|
const INTERACTIVE_INPUTS = ['disabled', 'tabIndex', ...BASE_INPUTS];
|
686
|
-
const INTERACTIVE_OUTPUT = ['onFocus', 'onBlur', ...BASE_OUTPUT];
|
716
|
+
const INTERACTIVE_OUTPUT = ['onFocus', 'onBlur', 'disabledChange', ...BASE_OUTPUT];
|
687
717
|
|
688
718
|
class MXButtonBaseComponent extends classes(MXInteractiveComponent, MXColorLookComponent) {
|
689
719
|
/**
|
@@ -761,7 +791,7 @@ const BUTTON_OUTPUT = [
|
|
761
791
|
COLOR_LOOK_OUTPUT,
|
762
792
|
];
|
763
793
|
|
764
|
-
class MXValueComponent extends
|
794
|
+
class MXValueComponent extends MXInteractiveComponent {
|
765
795
|
constructor() {
|
766
796
|
super(...arguments);
|
767
797
|
/**
|
@@ -771,9 +801,12 @@ class MXValueComponent extends MXBaseComponent {
|
|
771
801
|
this.onValueChanged = new EventEmitter();
|
772
802
|
this.valueChange = new EventEmitter();
|
773
803
|
this.stateChange = new EventEmitter();
|
804
|
+
this.readonlyChange = new EventEmitter();
|
774
805
|
this._readonly = false;
|
806
|
+
this._dirty = false;
|
775
807
|
this._isUserInteraction = false;
|
776
808
|
this._state = 'clear';
|
809
|
+
this.onChangeCallback = noop;
|
777
810
|
}
|
778
811
|
/**
|
779
812
|
* If set to true, user cannot change the value of component.
|
@@ -782,7 +815,14 @@ class MXValueComponent extends MXBaseComponent {
|
|
782
815
|
return this._readonly;
|
783
816
|
}
|
784
817
|
set readonly(value) {
|
785
|
-
|
818
|
+
value = coerceBooleanProperty(value);
|
819
|
+
this.setOption({
|
820
|
+
name: 'readonly',
|
821
|
+
value,
|
822
|
+
afterCallback: () => {
|
823
|
+
this.cdr.markForCheck();
|
824
|
+
},
|
825
|
+
});
|
786
826
|
}
|
787
827
|
get name() {
|
788
828
|
return this._name;
|
@@ -790,35 +830,27 @@ class MXValueComponent extends MXBaseComponent {
|
|
790
830
|
set name(value) {
|
791
831
|
this._name = value;
|
792
832
|
}
|
793
|
-
get
|
794
|
-
return this.
|
833
|
+
get dirty() {
|
834
|
+
return this._dirty;
|
795
835
|
}
|
796
|
-
|
797
|
-
this.
|
836
|
+
markAsDirty() {
|
837
|
+
this._dirty = true;
|
798
838
|
}
|
799
839
|
get value() {
|
800
|
-
return this.
|
840
|
+
return this.internalGetValue(this._value) ?? this.defaultValue;
|
801
841
|
}
|
802
842
|
set value(v) {
|
803
|
-
v = this.
|
804
|
-
//if (!this._isInited ) {
|
843
|
+
v = this.internalSetValue(v);
|
805
844
|
const old = AXObjectUtil.deepJSONClone(this.value);
|
806
845
|
// TODO: check real equality
|
807
846
|
if (v != old) {
|
808
847
|
this._value = v;
|
809
848
|
this.emitOnValueChangedEvent(old, this.value);
|
810
|
-
this.cdr.markForCheck();
|
811
849
|
if (v == null || v == undefined || v == '' || (Array.isArray(v) && v.length == 0)) {
|
812
850
|
this.setState('clear');
|
813
851
|
}
|
814
|
-
|
815
|
-
// if (this._isInited) {
|
816
|
-
// this.validate();
|
817
|
-
// }
|
818
|
-
// }
|
852
|
+
this.internalValueChanged(this.value);
|
819
853
|
}
|
820
|
-
this._isUserInteraction = false;
|
821
|
-
//}
|
822
854
|
}
|
823
855
|
get state() {
|
824
856
|
return this._state;
|
@@ -834,16 +866,21 @@ class MXValueComponent extends MXBaseComponent {
|
|
834
866
|
value: newValue,
|
835
867
|
oldValue: oldValue,
|
836
868
|
name: this.name,
|
837
|
-
isUserInteraction: this.
|
869
|
+
isUserInteraction: this._isUserInteraction,
|
838
870
|
});
|
871
|
+
this.onChangeCallback(newValue);
|
872
|
+
this.cdr.markForCheck();
|
839
873
|
this._isUserInteraction = false;
|
840
874
|
}
|
841
|
-
|
875
|
+
internalSetValue(value) {
|
842
876
|
return value;
|
843
877
|
}
|
844
|
-
|
878
|
+
internalGetValue(value) {
|
845
879
|
return value;
|
846
880
|
}
|
881
|
+
internalValueChanged(value) {
|
882
|
+
}
|
883
|
+
;
|
847
884
|
ngOnInit() {
|
848
885
|
super.init();
|
849
886
|
this.getHostElement().setAttribute('ax-form-input', 'true');
|
@@ -855,14 +892,13 @@ class MXValueComponent extends MXBaseComponent {
|
|
855
892
|
this.onValueChanged?.unsubscribe();
|
856
893
|
this.onOptionChanged?.unsubscribe();
|
857
894
|
}
|
858
|
-
clear() {
|
859
|
-
this.value = null;
|
860
|
-
}
|
861
895
|
_checkRequired() {
|
862
|
-
const isRequired = Array.from(this.getHostElement().querySelectorAll('ax-validation-rule')).some(c => c.__axContext__.enabled && c.__axContext__.rule == 'required');
|
896
|
+
const isRequired = Array.from(this.getHostElement().querySelectorAll('ax-validation-rule')).some((c) => c.__axContext__.enabled && c.__axContext__.rule == 'required');
|
863
897
|
//
|
864
898
|
if (isRequired) {
|
865
|
-
const container = this.getHostElement().classList.contains('ax-editor-container')
|
899
|
+
const container = this.getHostElement().classList.contains('ax-editor-container')
|
900
|
+
? this.getHostElement()
|
901
|
+
: this.getHostElement().querySelector('.ax-editor-container');
|
866
902
|
const formField = container?.closest('.ax-form-field');
|
867
903
|
const label = formField?.querySelector('ax-label')?.__axContext__;
|
868
904
|
if (label)
|
@@ -870,8 +906,7 @@ class MXValueComponent extends MXBaseComponent {
|
|
870
906
|
}
|
871
907
|
}
|
872
908
|
validate() {
|
873
|
-
|
874
|
-
const rules = Array.from(this.getHostElement().querySelectorAll('ax-validation-rule')).filter(c => c.__axContext__.enabled);
|
909
|
+
const rules = Array.from(this.getHostElement().querySelectorAll('ax-validation-rule')).filter((c) => c.__axContext__.enabled);
|
875
910
|
//
|
876
911
|
if (!rules || rules.length === 0) {
|
877
912
|
this.setState('clear');
|
@@ -882,13 +917,13 @@ class MXValueComponent extends MXBaseComponent {
|
|
882
917
|
id: this.id,
|
883
918
|
});
|
884
919
|
}
|
885
|
-
return new Promise(resolve => {
|
920
|
+
return new Promise((resolve) => {
|
886
921
|
Promise.all(rules
|
887
|
-
.filter(c => typeof c?.validate === 'function')
|
888
|
-
.map(c => {
|
922
|
+
.filter((c) => typeof c?.validate === 'function')
|
923
|
+
.map((c) => {
|
889
924
|
return c.validate(this.value);
|
890
|
-
})).then(d => {
|
891
|
-
const error = d.find(c => c.result === false);
|
925
|
+
})).then((d) => {
|
926
|
+
const error = d.find((c) => c.result === false);
|
892
927
|
if (error) {
|
893
928
|
this.setState('error', error.message);
|
894
929
|
resolve({
|
@@ -912,7 +947,9 @@ class MXValueComponent extends MXBaseComponent {
|
|
912
947
|
});
|
913
948
|
}
|
914
949
|
setState(state, ...args) {
|
915
|
-
const container = this.getHostElement().classList.contains('ax-editor-container')
|
950
|
+
const container = this.getHostElement().classList.contains('ax-editor-container')
|
951
|
+
? this.getHostElement()
|
952
|
+
: this.getHostElement().querySelector('.ax-editor-container');
|
916
953
|
const formField = container?.closest('.ax-form-field');
|
917
954
|
const label = formField?.querySelector('ax-label') || formField?.querySelector('label');
|
918
955
|
let target = container || this.getHostElement().firstElementChild;
|
@@ -951,10 +988,68 @@ class MXValueComponent extends MXBaseComponent {
|
|
951
988
|
}
|
952
989
|
this.cdr.markForCheck();
|
953
990
|
}
|
954
|
-
|
955
|
-
|
991
|
+
registerOnChange(fn) {
|
992
|
+
this.onChangeCallback = fn;
|
993
|
+
}
|
994
|
+
writeValue(value) {
|
995
|
+
this.value = value;
|
996
|
+
}
|
997
|
+
commitValue(value, u = false) {
|
998
|
+
if (u) {
|
999
|
+
this.markAsTouched();
|
1000
|
+
this.markAsDirty();
|
1001
|
+
this._isUserInteraction = true;
|
1002
|
+
}
|
1003
|
+
this.writeValue(value);
|
1004
|
+
}
|
1005
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: MXValueComponent, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
|
1006
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: MXValueComponent }); }
|
1007
|
+
}
|
1008
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: MXValueComponent, decorators: [{
|
1009
|
+
type: Injectable
|
1010
|
+
}] });
|
1011
|
+
|
1012
|
+
class MXInputBaseValueComponent extends MXValueComponent {
|
1013
|
+
constructor() {
|
1014
|
+
super(...arguments);
|
1015
|
+
/**
|
1016
|
+
* Fires each time the user press a key.
|
1017
|
+
* @event
|
1018
|
+
*/
|
1019
|
+
this.onKeyDown = new EventEmitter();
|
1020
|
+
/**
|
1021
|
+
* Fires each time the user press a key.
|
1022
|
+
* @event
|
1023
|
+
*/
|
1024
|
+
this.onKeyUp = new EventEmitter();
|
1025
|
+
/**
|
1026
|
+
* Fires each time the user press a key.
|
1027
|
+
* @event
|
1028
|
+
*/
|
1029
|
+
this.onKeyPress = new EventEmitter();
|
1030
|
+
}
|
1031
|
+
emitOnKeydownEvent(e) {
|
1032
|
+
this.onKeyDown.emit({
|
1033
|
+
component: this,
|
1034
|
+
nativeEvent: e
|
1035
|
+
});
|
1036
|
+
}
|
1037
|
+
emitOnKeyupEvent(e) {
|
1038
|
+
this.onKeyUp.emit({
|
1039
|
+
component: this,
|
1040
|
+
nativeEvent: e
|
1041
|
+
});
|
1042
|
+
}
|
1043
|
+
emitOnKeypressEvent(e) {
|
1044
|
+
this.onKeyPress.emit({
|
1045
|
+
component: this,
|
1046
|
+
nativeEvent: e
|
1047
|
+
});
|
1048
|
+
}
|
1049
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: MXInputBaseValueComponent, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
|
1050
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: MXInputBaseValueComponent }); }
|
956
1051
|
}
|
957
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
1052
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: MXInputBaseValueComponent, decorators: [{
|
958
1053
|
type: Injectable
|
959
1054
|
}] });
|
960
1055
|
|
@@ -1037,10 +1132,10 @@ class DynamicOverlayContainer extends OverlayContainer {
|
|
1037
1132
|
setContainerElement(containerElement) {
|
1038
1133
|
this._containerElement = containerElement;
|
1039
1134
|
}
|
1040
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
1041
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.
|
1135
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DynamicOverlayContainer, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
|
1136
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DynamicOverlayContainer, providedIn: 'root' }); }
|
1042
1137
|
}
|
1043
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
1138
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DynamicOverlayContainer, decorators: [{
|
1044
1139
|
type: Injectable,
|
1045
1140
|
args: [{
|
1046
1141
|
providedIn: 'root',
|
@@ -1060,10 +1155,10 @@ class DynamicOverlay extends Overlay {
|
|
1060
1155
|
this.setContainerElement(containerElement);
|
1061
1156
|
return super.create(config);
|
1062
1157
|
}
|
1063
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
1064
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.
|
1158
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DynamicOverlay, deps: [{ token: i1$2.ScrollStrategyOptions }, { token: DynamicOverlayContainer }, { token: i0.ComponentFactoryResolver }, { token: i1$2.OverlayPositionBuilder }, { token: i1$2.OverlayKeyboardDispatcher }, { token: i0.Injector }, { token: i0.NgZone }, { token: DOCUMENT }, { token: i2.Directionality }, { token: i0.RendererFactory2 }, { token: i3.Location }, { token: i1$2.OverlayOutsideClickDispatcher }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
1159
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DynamicOverlay, providedIn: 'root' }); }
|
1065
1160
|
}
|
1066
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
1161
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DynamicOverlay, decorators: [{
|
1067
1162
|
type: Injectable,
|
1068
1163
|
args: [{
|
1069
1164
|
providedIn: 'root',
|
@@ -1170,10 +1265,10 @@ class AXOverlayService {
|
|
1170
1265
|
},
|
1171
1266
|
};
|
1172
1267
|
}
|
1173
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.
|
1174
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.
|
1268
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXOverlayService, deps: [{ token: DynamicOverlay }, { token: i1$2.Overlay }, { token: i0.ApplicationRef }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
1269
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXOverlayService, providedIn: 'root' }); }
|
1175
1270
|
}
|
1176
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.
|
1271
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: AXOverlayService, decorators: [{
|
1177
1272
|
type: Injectable,
|
1178
1273
|
args: [{ providedIn: 'root' }]
|
1179
1274
|
}], ctorParameters: function () { return [{ type: DynamicOverlay }, { type: i1$2.Overlay }, { type: i0.ApplicationRef }]; } });
|
@@ -1182,5 +1277,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImpor
|
|
1182
1277
|
* Generated bundle index. Do not edit.
|
1183
1278
|
*/
|
1184
1279
|
|
1185
|
-
export { AXAutoFocusDirective, AXButtonClickEvent, AXClickEvent, AXClosbaleComponent, AXCommonModule, AXComponent, AXComponentCloseEvent, AXComponentClosedPromise, AXComponentClosing, AXComponentResult, AXEvent, AXFocusEvent, AXFocusableComponent, AXHotkeyDirective, AXHotkeysService, AXHtmlEvent, AXInfiniteScrollerDirective, AXItemClickEvent, AXNgModelChangeDebouncedDirective, AXOptionChangedEvent, AXOverlayService, AXPagedComponent, AXPositions, AXRangeChangedEvent, AXResponsiveDirective, AXSearchableComponent, AXSelectionValueChangedEvent, AXValuableComponent, AXValueChangedEvent, AX_DIRECTIONS, AX_LOCATIONS, AX_STYLE_COLOR_TYPES, BASE_INPUTS, BASE_OUTPUT, BUTTON_INPUTS, BUTTON_OUTPUT, COLOR_INPUTS, COLOR_LOOK_INPUTS, COLOR_LOOK_OUTPUT, COLOR_OUTPUT, DynamicOverlay, DynamicOverlayContainer, INTERACTIVE_INPUTS, INTERACTIVE_OUTPUT, LOOK_INPUTS, LOOK_OUTPUT, MXBaseComponent, MXButtonBaseComponent, MXColorComponent, MXColorLookComponent, MXInteractiveComponent, MXLookComponent, MXValueComponent, TAB_META_KEY };
|
1280
|
+
export { AXAutoFocusDirective, AXButtonClickEvent, AXClickEvent, AXClosbaleComponent, AXCommonModule, AXComponent, AXComponentCloseEvent, AXComponentClosedPromise, AXComponentClosing, AXComponentResult, AXEvent, AXFocusEvent, AXFocusableComponent, AXHotkeyDirective, AXHotkeysService, AXHtmlEvent, AXInfiniteScrollerDirective, AXItemClickEvent, AXNgModelChangeDebouncedDirective, AXOptionChangedEvent, AXOverlayService, AXPagedComponent, AXPositions, AXRangeChangedEvent, AXResponsiveDirective, AXSearchableComponent, AXSelectionValueChangedEvent, AXValuableComponent, AXValueChangedEvent, AX_DIRECTIONS, AX_LOCATIONS, AX_STYLE_COLOR_TYPES, BASE_INPUTS, BASE_OUTPUT, BUTTON_INPUTS, BUTTON_OUTPUT, COLOR_INPUTS, COLOR_LOOK_INPUTS, COLOR_LOOK_OUTPUT, COLOR_OUTPUT, DynamicOverlay, DynamicOverlayContainer, INTERACTIVE_INPUTS, INTERACTIVE_OUTPUT, LOOK_INPUTS, LOOK_OUTPUT, MXBaseComponent, MXButtonBaseComponent, MXColorComponent, MXColorLookComponent, MXInputBaseValueComponent, MXInteractiveComponent, MXLookComponent, MXValueComponent, TAB_META_KEY };
|
1186
1281
|
//# sourceMappingURL=acorex-components-common.mjs.map
|