@alauda/ui 8.0.1-beta.0 → 8.0.1-beta.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/anchor/anchor.directive.d.ts +2 -2
- package/button/button.types.d.ts +3 -0
- package/date-picker/calendar/panel/picker-panel.d.ts +1 -1
- package/date-picker/calendar/range-picker-panel/component.d.ts +1 -1
- package/dialog/dialog-container.component.d.ts +7 -0
- package/dialog/dialog-ref.d.ts +2 -4
- package/dialog/dialog.service.d.ts +3 -5
- package/fesm2022/alauda-ui.mjs +1092 -738
- package/fesm2022/alauda-ui.mjs.map +1 -1
- package/form/common-form.d.ts +5 -1
- package/icon/icons.d.ts +1 -1
- package/input/autosize.directive.d.ts +4 -1
- package/internal/types/index.d.ts +3 -0
- package/message/message.config.d.ts +20 -0
- package/notification/notification.component.d.ts +4 -0
- package/package.json +2 -9
- package/paginator/paginator-intl.d.ts +9 -0
- package/radio/base-radio.d.ts +1 -1
- package/select/base-select.d.ts +3 -0
- package/select/validators.d.ts +1 -1
- package/sort/sort-errors.d.ts +4 -0
- package/table/table-cell-def.directive.d.ts +4 -0
- package/table/table-cell.directive.d.ts +1 -0
- package/table/table-column-def.directive.d.ts +4 -0
- package/table/table-header-cell-def.directive.d.ts +4 -0
- package/table/table-header-cell.directive.d.ts +1 -0
- package/table/table-header-row-def.directive.d.ts +4 -0
- package/table/table-header-row.component.d.ts +1 -0
- package/table/table-row-def.directive.d.ts +5 -0
- package/table/table-row.component.d.ts +1 -0
- package/table/table-scroll.directive.d.ts +1 -1
- package/tabs/tab-body.component.d.ts +16 -0
- package/tabs/tab-context.service.d.ts +3 -0
- package/tabs/tab-group.component.d.ts +28 -0
- package/tabs/tab-header-active-indicator.component.d.ts +9 -0
- package/tabs/tab-header.component.d.ts +79 -0
- package/tabs/tab.component.d.ts +18 -0
- package/tabs/tabs.types.d.ts +3 -0
- package/theme/style.css +10 -9
- package/tooltip/tooltip-intl.d.ts +3 -0
- package/tsconfig.lib.tsbuildinfo +1 -1
- package/esm2022/accordion/accordion-item/accordion-item.component.mjs +0 -73
- package/esm2022/accordion/accordion.component.mjs +0 -27
- package/esm2022/accordion/accordion.module.mjs +0 -54
- package/esm2022/accordion/index.mjs +0 -4
- package/esm2022/alauda-ui.mjs +0 -2
- package/esm2022/anchor/anchor.component.mjs +0 -137
- package/esm2022/anchor/anchor.directive.mjs +0 -184
- package/esm2022/anchor/anchor.module.mjs +0 -42
- package/esm2022/anchor/index.mjs +0 -6
- package/esm2022/anchor/types.mjs +0 -2
- package/esm2022/anchor/utils.mjs +0 -26
- package/esm2022/autocomplete/autocomplete-placeholder.component.mjs +0 -18
- package/esm2022/autocomplete/autocomplete.component.mjs +0 -52
- package/esm2022/autocomplete/autocomplete.directive.mjs +0 -282
- package/esm2022/autocomplete/autocomplete.module.mjs +0 -69
- package/esm2022/autocomplete/autocomplete.types.mjs +0 -2
- package/esm2022/autocomplete/helper-directives.mjs +0 -18
- package/esm2022/autocomplete/index.mjs +0 -9
- package/esm2022/autocomplete/suggestion/suggestion.component.mjs +0 -74
- package/esm2022/autocomplete/suggestion-group/suggestion-group.component.mjs +0 -23
- package/esm2022/back-top/back-top.component.mjs +0 -84
- package/esm2022/back-top/back-top.module.mjs +0 -19
- package/esm2022/back-top/index.mjs +0 -3
- package/esm2022/breadcrumb/breadcrumb-item.component.mjs +0 -32
- package/esm2022/breadcrumb/breadcrumb.component.mjs +0 -57
- package/esm2022/breadcrumb/breadcrumb.module.mjs +0 -32
- package/esm2022/breadcrumb/index.mjs +0 -4
- package/esm2022/button/button-group/button-group.component.mjs +0 -11
- package/esm2022/button/button.component.mjs +0 -121
- package/esm2022/button/button.module.mjs +0 -19
- package/esm2022/button/button.types.mjs +0 -11
- package/esm2022/button/index.mjs +0 -5
- package/esm2022/card/card.component.mjs +0 -16
- package/esm2022/card/card.module.mjs +0 -48
- package/esm2022/card/helper-directives.mjs +0 -45
- package/esm2022/card/index.mjs +0 -5
- package/esm2022/card/section.component.mjs +0 -11
- package/esm2022/checkbox/checkbox-group/checkbox-group.component.mjs +0 -61
- package/esm2022/checkbox/checkbox.component.mjs +0 -112
- package/esm2022/checkbox/checkbox.module.mjs +0 -32
- package/esm2022/checkbox/index.mjs +0 -4
- package/esm2022/color-picker/color-picker.component.mjs +0 -28
- package/esm2022/color-picker/color-picker.module.mjs +0 -18
- package/esm2022/color-picker/index.mjs +0 -3
- package/esm2022/core/animation/animation-consts.mjs +0 -12
- package/esm2022/date-picker/calendar/constant.mjs +0 -31
- package/esm2022/date-picker/calendar/date-picker-panel/component.mjs +0 -173
- package/esm2022/date-picker/calendar/footer/component.mjs +0 -29
- package/esm2022/date-picker/calendar/header/component.mjs +0 -136
- package/esm2022/date-picker/calendar/panel/picker-panel.mjs +0 -154
- package/esm2022/date-picker/calendar/range-picker-panel/component.mjs +0 -218
- package/esm2022/date-picker/calendar/util.mjs +0 -145
- package/esm2022/date-picker/date-picker/date-picker.component.mjs +0 -100
- package/esm2022/date-picker/date-picker.module.mjs +0 -85
- package/esm2022/date-picker/date-picker.type.mjs +0 -12
- package/esm2022/date-picker/index.mjs +0 -12
- package/esm2022/date-picker/range-picker/range-picker.component.mjs +0 -90
- package/esm2022/date-picker/trigger/trigger.component.mjs +0 -122
- package/esm2022/dialog/confirm-dialog/confirm-dialog-config.mjs +0 -12
- package/esm2022/dialog/confirm-dialog/confirm-dialog.component.mjs +0 -95
- package/esm2022/dialog/dialog-animations.mjs +0 -57
- package/esm2022/dialog/dialog-config.mjs +0 -15
- package/esm2022/dialog/dialog-content/dialog-close.directive.mjs +0 -39
- package/esm2022/dialog/dialog-content/dialog-content.component.mjs +0 -19
- package/esm2022/dialog/dialog-content/dialog-footer.component.mjs +0 -15
- package/esm2022/dialog/dialog-content/dialog-header.component.mjs +0 -39
- package/esm2022/dialog/dialog-ref.mjs +0 -48
- package/esm2022/dialog/dialog.component.mjs +0 -154
- package/esm2022/dialog/dialog.module.mjs +0 -72
- package/esm2022/dialog/dialog.service.mjs +0 -120
- package/esm2022/dialog/dialog.types.mjs +0 -17
- package/esm2022/dialog/index.mjs +0 -12
- package/esm2022/dialog/utils/errors.mjs +0 -4
- package/esm2022/dialog/utils/index.mjs +0 -11
- package/esm2022/drawer/component/drawer.component.mjs +0 -88
- package/esm2022/drawer/component/internal/internal.component.mjs +0 -184
- package/esm2022/drawer/drawer-ref.mjs +0 -28
- package/esm2022/drawer/drawer.module.mjs +0 -41
- package/esm2022/drawer/drawer.service.mjs +0 -114
- package/esm2022/drawer/helper-directives.mjs +0 -36
- package/esm2022/drawer/index.mjs +0 -7
- package/esm2022/drawer/types.mjs +0 -6
- package/esm2022/dropdown/dropdown-active.directive.mjs +0 -22
- package/esm2022/dropdown/dropdown-button/dropdown-button.component.mjs +0 -47
- package/esm2022/dropdown/dropdown.directive.mjs +0 -53
- package/esm2022/dropdown/dropdown.module.mjs +0 -80
- package/esm2022/dropdown/dropdown.types.mjs +0 -8
- package/esm2022/dropdown/helper-directives.mjs +0 -18
- package/esm2022/dropdown/index.mjs +0 -11
- package/esm2022/dropdown/menu/menu.component.mjs +0 -19
- package/esm2022/dropdown/menu-group/menu-group.component.mjs +0 -11
- package/esm2022/dropdown/menu-item/menu-item.component.mjs +0 -37
- package/esm2022/dropdown/submenu/submenu.component.mjs +0 -45
- package/esm2022/form/common-form.mjs +0 -87
- package/esm2022/form/form-item/form-item.component.mjs +0 -108
- package/esm2022/form/form.directive.mjs +0 -70
- package/esm2022/form/form.module.mjs +0 -58
- package/esm2022/form/form.types.mjs +0 -11
- package/esm2022/form/helper-directives.mjs +0 -77
- package/esm2022/form/index.mjs +0 -7
- package/esm2022/i18n/i18n.module.mjs +0 -16
- package/esm2022/i18n/i18n.pipe.mjs +0 -22
- package/esm2022/i18n/i18n.service.mjs +0 -40
- package/esm2022/i18n/i18n.type.mjs +0 -6
- package/esm2022/i18n/index.mjs +0 -7
- package/esm2022/i18n/language/en.mjs +0 -25
- package/esm2022/i18n/language/zh.mjs +0 -25
- package/esm2022/icon/icon-register.service.mjs +0 -63
- package/esm2022/icon/icon.component.mjs +0 -65
- package/esm2022/icon/icon.module.mjs +0 -18
- package/esm2022/icon/icons.mjs +0 -2
- package/esm2022/icon/index.mjs +0 -4
- package/esm2022/icon/utils.mjs +0 -7
- package/esm2022/index.mjs +0 -39
- package/esm2022/inline-alert/helper-directives.mjs +0 -15
- package/esm2022/inline-alert/index.mjs +0 -5
- package/esm2022/inline-alert/inline-alert.component.mjs +0 -57
- package/esm2022/inline-alert/inline-alert.module.mjs +0 -32
- package/esm2022/inline-alert/inline-alert.types.mjs +0 -9
- package/esm2022/input/autosize.directive.mjs +0 -55
- package/esm2022/input/helper-directives.mjs +0 -47
- package/esm2022/input/index.mjs +0 -9
- package/esm2022/input/input-group/input-group.component.mjs +0 -46
- package/esm2022/input/input.component.mjs +0 -57
- package/esm2022/input/input.module.mjs +0 -85
- package/esm2022/input/number-input/number-input.component.mjs +0 -130
- package/esm2022/input/search/search.component.mjs +0 -89
- package/esm2022/input/tags-input/tags-input.component.mjs +0 -255
- package/esm2022/input/tags-input/with-max-row-count.mjs +0 -50
- package/esm2022/input/utils/index.mjs +0 -67
- package/esm2022/internal/types/index.mjs +0 -8
- package/esm2022/internal/utils/animations.mjs +0 -2
- package/esm2022/internal/utils/async.mjs +0 -6
- package/esm2022/internal/utils/bem.mjs +0 -43
- package/esm2022/internal/utils/coercion.mjs +0 -5
- package/esm2022/internal/utils/fn.mjs +0 -16
- package/esm2022/internal/utils/index.mjs +0 -10
- package/esm2022/internal/utils/observe-dom.mjs +0 -23
- package/esm2022/internal/utils/operators.mjs +0 -15
- package/esm2022/internal/utils/scroll-into-view.mjs +0 -17
- package/esm2022/internal/utils/styles-renderer.mjs +0 -40
- package/esm2022/internal/utils/watch-content-exist.mjs +0 -6
- package/esm2022/message/base-message.mjs +0 -90
- package/esm2022/message/index.mjs +0 -4
- package/esm2022/message/message-animations.mjs +0 -32
- package/esm2022/message/message-wrapper.component.mjs +0 -14
- package/esm2022/message/message.component.mjs +0 -70
- package/esm2022/message/message.config.mjs +0 -16
- package/esm2022/message/message.module.mjs +0 -31
- package/esm2022/message/message.service.mjs +0 -29
- package/esm2022/notification/index.mjs +0 -5
- package/esm2022/notification/notification-wrapper.component.mjs +0 -16
- package/esm2022/notification/notification.component.mjs +0 -103
- package/esm2022/notification/notification.config.mjs +0 -7
- package/esm2022/notification/notification.module.mjs +0 -36
- package/esm2022/notification/notification.service.mjs +0 -29
- package/esm2022/paginator/index.mjs +0 -4
- package/esm2022/paginator/paginator-intl.mjs +0 -21
- package/esm2022/paginator/paginator.component.mjs +0 -134
- package/esm2022/paginator/paginator.module.mjs +0 -37
- package/esm2022/radio/base-radio.mjs +0 -67
- package/esm2022/radio/index.mjs +0 -6
- package/esm2022/radio/radio-button/radio-button.component.mjs +0 -41
- package/esm2022/radio/radio-group/radio-group.component.mjs +0 -68
- package/esm2022/radio/radio.component.mjs +0 -23
- package/esm2022/radio/radio.module.mjs +0 -36
- package/esm2022/radio/radio.types.mjs +0 -6
- package/esm2022/scrolling/fixed-size-table-virtual-scroll-strategy.mjs +0 -81
- package/esm2022/scrolling/fixed-size-table-virtual-scroll.directive.mjs +0 -120
- package/esm2022/scrolling/fixed-size-virtual-scroll.directive.mjs +0 -28
- package/esm2022/scrolling/index.mjs +0 -7
- package/esm2022/scrolling/scrolling.module.mjs +0 -30
- package/esm2022/scrolling/virtual-for-of.directive.mjs +0 -35
- package/esm2022/scrolling/virtual-scroll-viewport.component.mjs +0 -26
- package/esm2022/select/base-select.mjs +0 -327
- package/esm2022/select/helper-directives.mjs +0 -67
- package/esm2022/select/index.mjs +0 -10
- package/esm2022/select/multi-select/multi-select.component.mjs +0 -313
- package/esm2022/select/option/option.component.mjs +0 -113
- package/esm2022/select/option-group/option-group.component.mjs +0 -23
- package/esm2022/select/option-placeholder.component.mjs +0 -18
- package/esm2022/select/select.component.mjs +0 -116
- package/esm2022/select/select.module.mjs +0 -87
- package/esm2022/select/select.types.mjs +0 -7
- package/esm2022/select/validators.mjs +0 -79
- package/esm2022/shared/click-outside.directive.mjs +0 -29
- package/esm2022/shared/shared.module.mjs +0 -16
- package/esm2022/sort/index.mjs +0 -6
- package/esm2022/sort/sort-errors.mjs +0 -13
- package/esm2022/sort/sort-header.component.mjs +0 -68
- package/esm2022/sort/sort.directive.mjs +0 -75
- package/esm2022/sort/sort.module.mjs +0 -19
- package/esm2022/sort/sort.types.mjs +0 -2
- package/esm2022/status-bar/index.mjs +0 -4
- package/esm2022/status-bar/status-bar.component.mjs +0 -29
- package/esm2022/status-bar/status-bar.module.mjs +0 -18
- package/esm2022/status-bar/status-bar.types.mjs +0 -13
- package/esm2022/steps/index.mjs +0 -4
- package/esm2022/steps/steps.component.mjs +0 -173
- package/esm2022/steps/steps.module.mjs +0 -18
- package/esm2022/steps/types.mjs +0 -7
- package/esm2022/switch/index.mjs +0 -3
- package/esm2022/switch/switch.component.mjs +0 -46
- package/esm2022/switch/switch.module.mjs +0 -17
- package/esm2022/table/index.mjs +0 -16
- package/esm2022/table/table-cell-def.directive.mjs +0 -26
- package/esm2022/table/table-cell.component.mjs +0 -125
- package/esm2022/table/table-cell.directive.mjs +0 -29
- package/esm2022/table/table-column-def.directive.mjs +0 -32
- package/esm2022/table/table-column-resizable.directive.mjs +0 -150
- package/esm2022/table/table-header-cell-def.directive.mjs +0 -26
- package/esm2022/table/table-header-cell.directive.mjs +0 -25
- package/esm2022/table/table-header-row-def.directive.mjs +0 -42
- package/esm2022/table/table-header-row.component.mjs +0 -26
- package/esm2022/table/table-placeholder.directive.mjs +0 -32
- package/esm2022/table/table-row-def.directive.mjs +0 -38
- package/esm2022/table/table-row.component.mjs +0 -44
- package/esm2022/table/table-scroll.directive.mjs +0 -131
- package/esm2022/table/table.component.mjs +0 -83
- package/esm2022/table/table.module.mjs +0 -82
- package/esm2022/table-of-contents/index.mjs +0 -5
- package/esm2022/table-of-contents/table-of-contents.module.mjs +0 -32
- package/esm2022/table-of-contents/toc-container.directive.mjs +0 -110
- package/esm2022/table-of-contents/toc-content.directive.mjs +0 -36
- package/esm2022/table-of-contents/toc-link.directive.mjs +0 -45
- package/esm2022/tabs/index.mjs +0 -9
- package/esm2022/tabs/tab-body.component.mjs +0 -148
- package/esm2022/tabs/tab-context.service.mjs +0 -28
- package/esm2022/tabs/tab-group.component.mjs +0 -258
- package/esm2022/tabs/tab-header-active-indicator.component.mjs +0 -39
- package/esm2022/tabs/tab-header.component.mjs +0 -264
- package/esm2022/tabs/tab.component.mjs +0 -65
- package/esm2022/tabs/tabs.module.mjs +0 -97
- package/esm2022/tabs/tabs.types.mjs +0 -10
- package/esm2022/tag/check-tag/check-tag.component.mjs +0 -33
- package/esm2022/tag/index.mjs +0 -5
- package/esm2022/tag/tag.component.mjs +0 -65
- package/esm2022/tag/tag.module.mjs +0 -19
- package/esm2022/tag/tag.types.mjs +0 -8
- package/esm2022/theme/index.mjs +0 -6
- package/esm2022/theme/theme.module.mjs +0 -27
- package/esm2022/theme/theme.pipe.mjs +0 -85
- package/esm2022/theme/theme.service.mjs +0 -56
- package/esm2022/theme/theme.types.mjs +0 -2
- package/esm2022/theme/utils.mjs +0 -10
- package/esm2022/time-picker/component.mjs +0 -190
- package/esm2022/time-picker/constant.mjs +0 -5
- package/esm2022/time-picker/index.mjs +0 -6
- package/esm2022/time-picker/panel/panel.component.mjs +0 -236
- package/esm2022/time-picker/time-picker.module.mjs +0 -64
- package/esm2022/time-picker/time-picker.type.mjs +0 -13
- package/esm2022/tooltip/animations.mjs +0 -57
- package/esm2022/tooltip/base-tooltip.mjs +0 -325
- package/esm2022/tooltip/index.mjs +0 -9
- package/esm2022/tooltip/tooltip-active.directive.mjs +0 -50
- package/esm2022/tooltip/tooltip-copy.directive.mjs +0 -79
- package/esm2022/tooltip/tooltip-intl.mjs +0 -18
- package/esm2022/tooltip/tooltip.component.mjs +0 -75
- package/esm2022/tooltip/tooltip.directive.mjs +0 -48
- package/esm2022/tooltip/tooltip.module.mjs +0 -39
- package/esm2022/tooltip/tooltip.types.mjs +0 -19
- package/esm2022/tooltip/utils/index.mjs +0 -58
- package/esm2022/tree-select/index.mjs +0 -5
- package/esm2022/tree-select/tree-node-placeholder.component.mjs +0 -18
- package/esm2022/tree-select/tree-select.component.mjs +0 -324
- package/esm2022/tree-select/tree-select.module.mjs +0 -44
- package/esm2022/tree-select/tree-select.types.mjs +0 -2
|
@@ -6,8 +6,11 @@ import { TabHeaderComponent } from './tab-header.component';
|
|
|
6
6
|
import { TabComponent } from './tab.component';
|
|
7
7
|
import { TabSize, TabType } from './tabs.types';
|
|
8
8
|
import * as i0 from "@angular/core";
|
|
9
|
+
/** A simple change event emitted on focus or selection changes. */
|
|
9
10
|
export declare class TabChangeEvent {
|
|
11
|
+
/** Index of the currently-selected tab. */
|
|
10
12
|
index: number;
|
|
13
|
+
/** Reference to the currently-selected tab. */
|
|
11
14
|
tab: TabComponent;
|
|
12
15
|
}
|
|
13
16
|
export declare class TabGroupComponent implements OnChanges, AfterContentChecked, AfterContentInit, OnDestroy {
|
|
@@ -17,17 +20,24 @@ export declare class TabGroupComponent implements OnChanges, AfterContentChecked
|
|
|
17
20
|
_headerAddon: TabHeaderAddonDirective;
|
|
18
21
|
_tabHeader: TabHeaderComponent;
|
|
19
22
|
_tabTitle: TabTitleDirective;
|
|
23
|
+
/** The tab index that should be selected after the content has been checked. */
|
|
20
24
|
private _indexToSelect;
|
|
25
|
+
/** Subscription to tabs being added/removed. */
|
|
21
26
|
private _tabsSubscription;
|
|
27
|
+
/** Subscription to changes in the tab labels. */
|
|
22
28
|
private _tabLabelSubscription;
|
|
23
29
|
private _selectedIndex;
|
|
24
30
|
private _tab;
|
|
25
31
|
private _type;
|
|
26
32
|
private _size;
|
|
33
|
+
/** true lazy mode for template ref children */
|
|
27
34
|
private _lazy;
|
|
28
35
|
private _previousHeaderAddon;
|
|
36
|
+
/** Emits whenever the type changes */
|
|
29
37
|
readonly _typeChange: Subject<void>;
|
|
38
|
+
/** Emits whenever the size changes */
|
|
30
39
|
readonly _sizeChange: Subject<void>;
|
|
40
|
+
/** The index of the active tab. */
|
|
31
41
|
get selectedIndex(): number;
|
|
32
42
|
set selectedIndex(value: number);
|
|
33
43
|
get tab(): string;
|
|
@@ -39,25 +49,43 @@ export declare class TabGroupComponent implements OnChanges, AfterContentChecked
|
|
|
39
49
|
set size(val: TabSize);
|
|
40
50
|
get lazy(): boolean;
|
|
41
51
|
set lazy(lazy: boolean);
|
|
52
|
+
/** Output to enable support for two-way binding on `[(selectedIndex)]` */
|
|
42
53
|
readonly selectedIndexChange: EventEmitter<number>;
|
|
43
54
|
readonly tabChange: EventEmitter<string>;
|
|
55
|
+
/** Event emitted when the tab selection has changed. */
|
|
44
56
|
readonly selectedTabChange: EventEmitter<TabChangeEvent>;
|
|
57
|
+
/** Event emitted when focus has changed within a tab group. */
|
|
45
58
|
readonly focusChange: EventEmitter<TabChangeEvent>;
|
|
46
59
|
constructor(_changeDetectorRef: ChangeDetectorRef);
|
|
47
60
|
activatedTabs: TabComponent[];
|
|
48
61
|
get activeTab(): TabComponent;
|
|
49
62
|
ngOnChanges(changes: SimpleChanges): void;
|
|
63
|
+
/**
|
|
64
|
+
* After the content is checked, this component knows what tabs have been defined
|
|
65
|
+
* and what the selected index should be. This is where we can know exactly what position
|
|
66
|
+
* each tab should be in according to the new selected index.
|
|
67
|
+
*/
|
|
50
68
|
ngAfterContentChecked(): void;
|
|
51
69
|
ngAfterContentInit(): void;
|
|
52
70
|
ngOnDestroy(): void;
|
|
71
|
+
/** Handle click events, setting new selected index if appropriate. */
|
|
53
72
|
_handleClick(tab: TabComponent, idx: number): void;
|
|
54
73
|
_focusChanged(index: number): void;
|
|
74
|
+
/** Re-aligns the ink bar to the selected tab element. */
|
|
55
75
|
realignActiveIndicator(): void;
|
|
56
76
|
private _changeActivatedTabs;
|
|
77
|
+
/** Clamps the given index to the bounds of 0 and the tabs length. */
|
|
57
78
|
private _clampTabIndex;
|
|
58
79
|
private _findIndexByTab;
|
|
59
80
|
private _createChangeEvent;
|
|
81
|
+
/**
|
|
82
|
+
* Subscribes to changes in the tab labels. This is needed, because the @Input for the label is
|
|
83
|
+
* on the Tab component, whereas the data binding is inside the TabGroup. In order for the
|
|
84
|
+
* binding to be updated, we need to subscribe to changes in it and trigger change detection
|
|
85
|
+
* manually.
|
|
86
|
+
*/
|
|
60
87
|
private _subscribeToTabLabels;
|
|
88
|
+
/** Retrieves the tabindex for the tab. */
|
|
61
89
|
_getTabIndex(tab: TabComponent, idx: number): number | null;
|
|
62
90
|
static ɵfac: i0.ɵɵFactoryDeclaration<TabGroupComponent, never>;
|
|
63
91
|
static ɵcmp: i0.ɵɵComponentDeclaration<TabGroupComponent, "aui-tab-group", ["auiTabGroup"], { "selectedIndex": { "alias": "selectedIndex"; "required": false; }; "tab": { "alias": "tab"; "required": false; }; "type": { "alias": "type"; "required": false; }; "title": { "alias": "title"; "required": false; }; "size": { "alias": "size"; "required": false; }; "lazy": { "alias": "lazy"; "required": false; }; }, { "selectedIndexChange": "selectedIndexChange"; "tabChange": "tabChange"; "selectedTabChange": "selectedTabChange"; "focusChange": "focusChange"; }, ["_headerAddon", "_tabTitle", "_tabs"], never, true, never>;
|
|
@@ -8,7 +8,16 @@ export declare class TabHeaderActiveIndicatorComponent {
|
|
|
8
8
|
type: TabType;
|
|
9
9
|
bem: Bem;
|
|
10
10
|
constructor(_elementRef: ElementRef<HTMLElement>, _ngZone: NgZone);
|
|
11
|
+
/**
|
|
12
|
+
* Calculates the styles from the provided element in order to align the indicator to that element.
|
|
13
|
+
* Shows the indicator if previously set as hidden.
|
|
14
|
+
* @param element
|
|
15
|
+
*/
|
|
11
16
|
alignToElement(element: HTMLElement): void;
|
|
17
|
+
/**
|
|
18
|
+
* Sets the proper styles to the element.
|
|
19
|
+
* @param element
|
|
20
|
+
*/
|
|
12
21
|
private _setStyles;
|
|
13
22
|
private _getElementPosition;
|
|
14
23
|
static ɵfac: i0.ɵɵFactoryDeclaration<TabHeaderActiveIndicatorComponent, never>;
|
|
@@ -4,28 +4,47 @@ import { TabHeaderAddonDirective, TabLabelWrapperDirective, TabTitleDirective }
|
|
|
4
4
|
import { TabHeaderActiveIndicatorComponent } from './tab-header-active-indicator.component';
|
|
5
5
|
import { TabSize, TabType } from './tabs.types';
|
|
6
6
|
import * as i0 from "@angular/core";
|
|
7
|
+
/**
|
|
8
|
+
* The directions that scrolling can go in when the header's tabs exceed the header width. 'After'
|
|
9
|
+
* will scroll the header towards the end of the tabs list and 'before' will scroll towards the
|
|
10
|
+
* beginning of the list.
|
|
11
|
+
*/
|
|
7
12
|
export type ScrollDirection = 'after' | 'before';
|
|
8
13
|
export declare class TabHeaderComponent implements OnDestroy, AfterContentChecked, AfterContentInit {
|
|
9
14
|
private readonly _changeDetectorRef;
|
|
10
15
|
bem: Bem;
|
|
11
16
|
_showAddon: boolean;
|
|
17
|
+
/** Whether the controls for pagination should be displayed */
|
|
12
18
|
_showPaginationControls: boolean;
|
|
19
|
+
/** Whether the tab list can be scrolled more towards the end of the tab label list. */
|
|
13
20
|
_disableScrollAfter: boolean;
|
|
21
|
+
/** Whether the tab list can be scrolled more towards the beginning of the tab label list. */
|
|
14
22
|
_disableScrollBefore: boolean;
|
|
23
|
+
/** Whether the scroll distance has changed and should be applied after the view is checked. */
|
|
15
24
|
private _scrollDistanceChanged;
|
|
25
|
+
/** Whether the header should scroll to the selected index after the view has been checked. */
|
|
16
26
|
private _selectedIndexChanged;
|
|
27
|
+
/** The distance in pixels that the tab labels should be translated to the left. */
|
|
17
28
|
private _scrollDistance;
|
|
18
29
|
private _selectedIndex;
|
|
30
|
+
/** Emits when the component is destroyed. */
|
|
19
31
|
private readonly _destroyed;
|
|
32
|
+
/** Used to manage focus between the tabs. */
|
|
20
33
|
private _keyManager;
|
|
21
34
|
type: TabType;
|
|
22
35
|
size: TabSize;
|
|
36
|
+
/** The index of the active tab. */
|
|
23
37
|
get selectedIndex(): number;
|
|
24
38
|
set selectedIndex(value: number);
|
|
39
|
+
/** Event emitted when the option is selected. */
|
|
25
40
|
readonly selectFocusedIndex: EventEmitter<number>;
|
|
41
|
+
/** Event emitted when a label is focused. */
|
|
26
42
|
readonly indexFocused: EventEmitter<number>;
|
|
27
43
|
_headerAddon: TabHeaderAddonDirective;
|
|
28
44
|
_title: TabTitleDirective;
|
|
45
|
+
/**
|
|
46
|
+
* workaround for @link https://github.com/microsoft/TypeScript/pull/42425
|
|
47
|
+
*/
|
|
29
48
|
_labelWrappers: QueryList<TabLabelWrapperDirective & {
|
|
30
49
|
disabled?: boolean;
|
|
31
50
|
}>;
|
|
@@ -35,22 +54,82 @@ export declare class TabHeaderComponent implements OnDestroy, AfterContentChecke
|
|
|
35
54
|
_activeIndicator: TabHeaderActiveIndicatorComponent;
|
|
36
55
|
ngOnDestroy(): void;
|
|
37
56
|
ngAfterContentChecked(): void;
|
|
57
|
+
/**
|
|
58
|
+
* Aligns the ink bar to the selected tab on load.
|
|
59
|
+
*/
|
|
38
60
|
ngAfterContentInit(): void;
|
|
61
|
+
/** Sets the distance in pixels that the tab header should be transformed in the X-axis. */
|
|
39
62
|
get scrollDistance(): number;
|
|
40
63
|
set scrollDistance(v: number);
|
|
64
|
+
/** Tracks which element has focus; used for keyboard navigation */
|
|
41
65
|
get focusIndex(): number;
|
|
66
|
+
/** When the focus index is set, we must manually send focus to the correct label */
|
|
42
67
|
set focusIndex(value: number);
|
|
68
|
+
/**
|
|
69
|
+
* Determines if an index is valid. If the tabs are not ready yet, we assume that the user is
|
|
70
|
+
* providing a valid index and return true.
|
|
71
|
+
*/
|
|
43
72
|
_isValidIndex(index: number): boolean;
|
|
44
73
|
_handleKeydown(event: KeyboardEvent): void;
|
|
74
|
+
/**
|
|
75
|
+
* Sets focus on the HTML element for the label wrapper and scrolls it into the view if
|
|
76
|
+
* scrolling is enabled.
|
|
77
|
+
*/
|
|
45
78
|
_setTabFocus(tabIndex: number): void;
|
|
79
|
+
/**
|
|
80
|
+
* Moves the tab list such that the desired tab label (marked by index) is moved into view.
|
|
81
|
+
*
|
|
82
|
+
* This is an expensive call that forces a layout reflow to compute box and scroll metrics and
|
|
83
|
+
* should be called sparingly.
|
|
84
|
+
*/
|
|
46
85
|
_scrollToLabel(labelIndex: number): void;
|
|
86
|
+
/**
|
|
87
|
+
* Moves the tab list in the 'before' or 'after' direction (towards the beginning of the list or
|
|
88
|
+
* the end of the list, respectively). The distance to scroll is computed to be a third of the
|
|
89
|
+
* length of the tab list view window.
|
|
90
|
+
*
|
|
91
|
+
* This is an expensive call that forces a layout reflow to compute box and scroll metrics and
|
|
92
|
+
* should be called sparingly.
|
|
93
|
+
*/
|
|
47
94
|
_scrollHeader(scrollDir: ScrollDirection): void;
|
|
95
|
+
/**
|
|
96
|
+
* Callback for when the MutationObserver detects that the content has changed.
|
|
97
|
+
*/
|
|
48
98
|
_onContentChanges(): void;
|
|
99
|
+
/**
|
|
100
|
+
* Updating the view whether pagination should be enabled or not
|
|
101
|
+
*/
|
|
49
102
|
_updatePagination(): void;
|
|
103
|
+
/**
|
|
104
|
+
* Evaluate whether the pagination controls should be displayed. If the scroll width of the
|
|
105
|
+
* tab list is wider than the size of the header container, then the pagination controls should
|
|
106
|
+
* be shown.
|
|
107
|
+
*
|
|
108
|
+
* This is an expensive call that forces a layout reflow to compute box and scroll metrics and
|
|
109
|
+
* should be called sparingly.
|
|
110
|
+
*/
|
|
50
111
|
_checkPaginationEnabled(): void;
|
|
112
|
+
/**
|
|
113
|
+
* Evaluate whether the before and after controls should be enabled or disabled.
|
|
114
|
+
* If the header is at the beginning of the list (scroll distance is equal to 0) then disable the
|
|
115
|
+
* before button. If the header is at the end of the list (scroll distance is equal to the
|
|
116
|
+
* maximum distance we can scroll), then disable the after button.
|
|
117
|
+
*
|
|
118
|
+
* This is an expensive call that forces a layout reflow to compute box and scroll metrics and
|
|
119
|
+
* should be called sparingly.
|
|
120
|
+
*/
|
|
51
121
|
_checkScrollingControls(): void;
|
|
122
|
+
/**
|
|
123
|
+
* Determines what is the maximum length in pixels that can be set for the scroll distance. This
|
|
124
|
+
* is equal to the difference in width between the tab list container and tab header container.
|
|
125
|
+
*
|
|
126
|
+
* This is an expensive call that forces a layout reflow to compute box and scroll metrics and
|
|
127
|
+
* should be called sparingly.
|
|
128
|
+
*/
|
|
52
129
|
_getMaxScrollDistance(): number;
|
|
130
|
+
/** Performs the CSS transformation on the tab list that will cause the list to scroll. */
|
|
53
131
|
_updateTabScrollPosition(): void;
|
|
132
|
+
/** Tells the active indicator to align itself to the current label wrapper */
|
|
54
133
|
_alignActiveIndicatorToSelectedTab(): void;
|
|
55
134
|
constructor(_changeDetectorRef: ChangeDetectorRef);
|
|
56
135
|
static ɵfac: i0.ɵɵFactoryDeclaration<TabHeaderComponent, never>;
|
package/tabs/tab.component.d.ts
CHANGED
|
@@ -8,17 +8,35 @@ export declare class TabComponent implements AfterContentInit, OnDestroy, OnChan
|
|
|
8
8
|
private readonly _viewContainerRef;
|
|
9
9
|
readonly tabContext: TabContextService;
|
|
10
10
|
name: string;
|
|
11
|
+
/** Plain text label for the tab, used when there is no template label. */
|
|
11
12
|
textLabel: string;
|
|
13
|
+
/** Whether or not to show the close button in the header */
|
|
12
14
|
closeable: boolean;
|
|
15
|
+
/** Whether or not the tab is disabled */
|
|
13
16
|
disabled: boolean;
|
|
14
17
|
close: EventEmitter<void>;
|
|
18
|
+
/** Content for the tab label given by `<ng-template [auiTabLabel]>`. */
|
|
15
19
|
templateLabel: TabLabelDirective;
|
|
20
|
+
/**
|
|
21
|
+
* Template provided in the tab content that will be used if present, used to enable lazy-loading
|
|
22
|
+
*/
|
|
16
23
|
_explicitContent: TemplateRef<any>;
|
|
24
|
+
/** Template inside the AuiTab view that contains an `<ng-content>`. */
|
|
17
25
|
_implicitContent: TemplateRef<any>;
|
|
18
26
|
get content(): TemplatePortal | null;
|
|
27
|
+
/**
|
|
28
|
+
* The relatively indexed position where 0 represents the center, negative is left, and positive
|
|
29
|
+
* represents the right.
|
|
30
|
+
*/
|
|
19
31
|
position: number | null;
|
|
32
|
+
/**
|
|
33
|
+
* The initial relatively index origin of the tab if it was created and selected after there
|
|
34
|
+
* was already a selected tab. Provides context of what position the tab should originate from.
|
|
35
|
+
*/
|
|
20
36
|
origin: number | null;
|
|
37
|
+
/** Emits whenever the internal state of the tab changes. */
|
|
21
38
|
readonly _stateChanges: Subject<void>;
|
|
39
|
+
/** Portal that will be the hosted content of the tab */
|
|
22
40
|
private _contentPortal;
|
|
23
41
|
constructor(_viewContainerRef: ViewContainerRef, tabContext: TabContextService);
|
|
24
42
|
ngAfterContentInit(): void;
|
package/tabs/tabs.types.d.ts
CHANGED
package/theme/style.css
CHANGED
|
@@ -25,10 +25,10 @@
|
|
|
25
25
|
position: absolute;
|
|
26
26
|
pointer-events: auto;
|
|
27
27
|
box-sizing: border-box;
|
|
28
|
-
z-index: 1000;
|
|
29
28
|
display: flex;
|
|
30
29
|
max-width: 100%;
|
|
31
30
|
max-height: 100%;
|
|
31
|
+
z-index: 1000;
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
.cdk-overlay-backdrop {
|
|
@@ -37,21 +37,22 @@
|
|
|
37
37
|
bottom: 0;
|
|
38
38
|
left: 0;
|
|
39
39
|
right: 0;
|
|
40
|
-
z-index: 1000;
|
|
41
40
|
pointer-events: auto;
|
|
42
41
|
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
|
|
43
|
-
transition: opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1);
|
|
44
42
|
opacity: 0;
|
|
43
|
+
z-index: 1000;
|
|
44
|
+
transition: opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1);
|
|
45
45
|
}
|
|
46
46
|
|
|
47
|
-
.cdk-overlay-backdrop
|
|
47
|
+
.cdk-overlay-backdrop-showing {
|
|
48
48
|
opacity: 1;
|
|
49
49
|
}
|
|
50
50
|
|
|
51
|
-
|
|
52
|
-
|
|
51
|
+
@media (forced-colors: active) {
|
|
52
|
+
.cdk-overlay-backdrop-showing {
|
|
53
|
+
opacity: 0.6;
|
|
54
|
+
}
|
|
53
55
|
}
|
|
54
|
-
|
|
55
56
|
.cdk-overlay-dark-backdrop {
|
|
56
57
|
background: rgba(0, 0, 0, 0.32);
|
|
57
58
|
}
|
|
@@ -62,7 +63,7 @@
|
|
|
62
63
|
opacity: 1;
|
|
63
64
|
}
|
|
64
65
|
|
|
65
|
-
.cdk-overlay-transparent-backdrop.cdk-overlay-backdrop-showing {
|
|
66
|
+
.cdk-overlay-transparent-backdrop.cdk-overlay-backdrop-showing, .cdk-high-contrast-active .cdk-overlay-transparent-backdrop {
|
|
66
67
|
opacity: 0;
|
|
67
68
|
visibility: visible;
|
|
68
69
|
}
|
|
@@ -73,11 +74,11 @@
|
|
|
73
74
|
|
|
74
75
|
.cdk-overlay-connected-position-bounding-box {
|
|
75
76
|
position: absolute;
|
|
76
|
-
z-index: 1000;
|
|
77
77
|
display: flex;
|
|
78
78
|
flex-direction: column;
|
|
79
79
|
min-width: 1px;
|
|
80
80
|
min-height: 1px;
|
|
81
|
+
z-index: 1000;
|
|
81
82
|
}
|
|
82
83
|
|
|
83
84
|
.cdk-global-scrollblock {
|