ngx-tethys 19.1.0-next.1 → 19.1.0-next.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.
Files changed (143) hide show
  1. package/CHANGELOG.md +105 -0
  2. package/arrow-switcher/arrow-switcher.component.d.ts +5 -1
  3. package/badge/badge.component.d.ts +1 -1
  4. package/color-picker/coordinates.directive.d.ts +1 -2
  5. package/date-picker/abstract-picker.component.d.ts +50 -52
  6. package/date-picker/abstract-picker.directive.d.ts +15 -40
  7. package/date-picker/base-picker.component.d.ts +12 -40
  8. package/date-picker/date-picker.config.d.ts +3 -0
  9. package/date-picker/lib/calendar/calendar-footer.component.d.ts +24 -19
  10. package/date-picker/lib/calendar/calendar-header.component.d.ts +15 -15
  11. package/date-picker/lib/calendar/calendar-table.component.d.ts +15 -16
  12. package/date-picker/lib/date/date-table-cell.component.d.ts +6 -3
  13. package/date-picker/lib/date/date-table.component.d.ts +2 -3
  14. package/date-picker/lib/date-carousel/date-carousel.component.d.ts +2 -3
  15. package/date-picker/lib/decade/decade-header.component.d.ts +2 -5
  16. package/date-picker/lib/decade/decade-table.component.d.ts +3 -5
  17. package/date-picker/lib/month/month-table.component.d.ts +1 -2
  18. package/date-picker/lib/popups/date-popup.component.d.ts +33 -34
  19. package/date-picker/lib/popups/inner-popup.component.d.ts +22 -29
  20. package/date-picker/lib/quarter/quarter-table.component.d.ts +1 -4
  21. package/date-picker/lib/year/year-header.component.d.ts +2 -4
  22. package/date-picker/lib/year/year-table.component.d.ts +2 -4
  23. package/date-picker/month-picker.component.d.ts +2 -2
  24. package/date-picker/picker.component.d.ts +31 -36
  25. package/date-picker/picker.pipes.d.ts +4 -5
  26. package/date-picker/picker.util.d.ts +5 -5
  27. package/date-picker/picker.validators.d.ts +4 -8
  28. package/date-picker/quarter-picker.component.d.ts +2 -3
  29. package/date-picker/styles/range-picker.scss +1 -0
  30. package/date-picker/week-picker.component.d.ts +0 -1
  31. package/date-picker/year-picker.component.d.ts +2 -3
  32. package/dropdown/dropdown-menu.component.d.ts +1 -1
  33. package/dropdown/dropdown.directive.d.ts +4 -3
  34. package/empty/empty.component.d.ts +2 -1
  35. package/fesm2022/ngx-tethys-arrow-switcher.mjs +15 -3
  36. package/fesm2022/ngx-tethys-arrow-switcher.mjs.map +1 -1
  37. package/fesm2022/ngx-tethys-autocomplete.mjs +4 -4
  38. package/fesm2022/ngx-tethys-autocomplete.mjs.map +1 -1
  39. package/fesm2022/ngx-tethys-badge.mjs.map +1 -1
  40. package/fesm2022/ngx-tethys-cascader.mjs +1 -1
  41. package/fesm2022/ngx-tethys-cascader.mjs.map +1 -1
  42. package/fesm2022/ngx-tethys-checkbox.mjs +2 -2
  43. package/fesm2022/ngx-tethys-checkbox.mjs.map +1 -1
  44. package/fesm2022/ngx-tethys-color-picker.mjs +4 -6
  45. package/fesm2022/ngx-tethys-color-picker.mjs.map +1 -1
  46. package/fesm2022/ngx-tethys-copy.mjs +2 -2
  47. package/fesm2022/ngx-tethys-copy.mjs.map +1 -1
  48. package/fesm2022/ngx-tethys-date-picker.mjs +855 -1072
  49. package/fesm2022/ngx-tethys-date-picker.mjs.map +1 -1
  50. package/fesm2022/ngx-tethys-divider.mjs +5 -5
  51. package/fesm2022/ngx-tethys-divider.mjs.map +1 -1
  52. package/fesm2022/ngx-tethys-dropdown.mjs +9 -11
  53. package/fesm2022/ngx-tethys-dropdown.mjs.map +1 -1
  54. package/fesm2022/ngx-tethys-empty.mjs +5 -2
  55. package/fesm2022/ngx-tethys-empty.mjs.map +1 -1
  56. package/fesm2022/ngx-tethys-flexible-text.mjs +4 -5
  57. package/fesm2022/ngx-tethys-flexible-text.mjs.map +1 -1
  58. package/fesm2022/ngx-tethys-i18n.mjs +26 -6
  59. package/fesm2022/ngx-tethys-i18n.mjs.map +1 -1
  60. package/fesm2022/ngx-tethys-image.mjs +5 -7
  61. package/fesm2022/ngx-tethys-image.mjs.map +1 -1
  62. package/fesm2022/ngx-tethys-layout.mjs +291 -334
  63. package/fesm2022/ngx-tethys-layout.mjs.map +1 -1
  64. package/fesm2022/ngx-tethys-list.mjs +183 -217
  65. package/fesm2022/ngx-tethys-list.mjs.map +1 -1
  66. package/fesm2022/ngx-tethys-message.mjs +29 -36
  67. package/fesm2022/ngx-tethys-message.mjs.map +1 -1
  68. package/fesm2022/ngx-tethys-notify.mjs +33 -41
  69. package/fesm2022/ngx-tethys-notify.mjs.map +1 -1
  70. package/fesm2022/ngx-tethys-radio.mjs +4 -4
  71. package/fesm2022/ngx-tethys-radio.mjs.map +1 -1
  72. package/fesm2022/ngx-tethys-resizable.mjs +20 -17
  73. package/fesm2022/ngx-tethys-resizable.mjs.map +1 -1
  74. package/fesm2022/ngx-tethys-select.mjs +164 -228
  75. package/fesm2022/ngx-tethys-select.mjs.map +1 -1
  76. package/fesm2022/ngx-tethys-shared.mjs +423 -587
  77. package/fesm2022/ngx-tethys-shared.mjs.map +1 -1
  78. package/fesm2022/ngx-tethys-skeleton.mjs +1 -2
  79. package/fesm2022/ngx-tethys-skeleton.mjs.map +1 -1
  80. package/fesm2022/ngx-tethys-stepper.mjs.map +1 -1
  81. package/fesm2022/ngx-tethys-table.mjs +1 -2
  82. package/fesm2022/ngx-tethys-table.mjs.map +1 -1
  83. package/fesm2022/ngx-tethys-time-picker.mjs +244 -271
  84. package/fesm2022/ngx-tethys-time-picker.mjs.map +1 -1
  85. package/fesm2022/ngx-tethys-tooltip.mjs +109 -93
  86. package/fesm2022/ngx-tethys-tooltip.mjs.map +1 -1
  87. package/fesm2022/ngx-tethys-tree-select.mjs +215 -281
  88. package/fesm2022/ngx-tethys-tree-select.mjs.map +1 -1
  89. package/fesm2022/ngx-tethys-upload.mjs +2 -2
  90. package/fesm2022/ngx-tethys-upload.mjs.map +1 -1
  91. package/fesm2022/ngx-tethys.mjs +1 -1
  92. package/fesm2022/ngx-tethys.mjs.map +1 -1
  93. package/i18n/i18n.d.ts +7 -2
  94. package/i18n/locales/de-de.d.ts +5 -1
  95. package/i18n/locales/en-us.d.ts +5 -1
  96. package/i18n/locales/ja-jp.d.ts +5 -1
  97. package/i18n/locales/zh-hans.d.ts +5 -1
  98. package/i18n/locales/zh-hant.d.ts +5 -1
  99. package/image/preview/image-preview.component.d.ts +2 -2
  100. package/layout/header.component.d.ts +15 -19
  101. package/layout/layout.component.d.ts +3 -2
  102. package/layout/sidebar-header.component.d.ts +7 -8
  103. package/layout/sidebar.component.d.ts +32 -62
  104. package/list/list-item-meta.component.d.ts +7 -9
  105. package/list/list-item.component.d.ts +0 -2
  106. package/list/list.component.d.ts +2 -8
  107. package/list/selection/selection-list.d.ts +33 -46
  108. package/message/abstract/abstract-message.component.d.ts +2 -3
  109. package/message/message-container.component.d.ts +0 -1
  110. package/message/message.component.d.ts +1 -3
  111. package/notify/notify-container.component.d.ts +0 -1
  112. package/notify/notify.component.d.ts +7 -12
  113. package/package.json +1 -1
  114. package/resizable/resizable.directive.d.ts +2 -1
  115. package/schematics/version.d.ts +1 -1
  116. package/schematics/version.js +1 -1
  117. package/select/custom-select/custom-select.component.d.ts +33 -56
  118. package/select/native-select/native-select.component.d.ts +7 -13
  119. package/shared/base-form-check.component.d.ts +6 -8
  120. package/shared/directives/string-or-template-outlet.directive.d.ts +5 -6
  121. package/shared/directives/thy-autofocus.directive.d.ts +4 -6
  122. package/shared/directives/thy-contextmenu.directive.d.ts +2 -2
  123. package/shared/directives/thy-ctrl-enter.directive.d.ts +2 -2
  124. package/shared/directives/thy-enter.directive.d.ts +2 -2
  125. package/shared/directives/thy-scroll.directive.d.ts +5 -8
  126. package/shared/directives/thy-show.d.ts +5 -6
  127. package/shared/directives/thy-stop-propagation.directive.d.ts +4 -4
  128. package/shared/directives/view-outlet.directive.d.ts +6 -7
  129. package/shared/ng-transclude.directive.d.ts +2 -3
  130. package/shared/option/group/option-group.component.d.ts +5 -9
  131. package/shared/option/list-option/list-option.component.d.ts +9 -13
  132. package/shared/option/option.component.d.ts +10 -17
  133. package/shared/option/option.token.d.ts +4 -3
  134. package/shared/option/options-container.component.d.ts +1 -1
  135. package/shared/select/select-control/select-control.component.d.ts +38 -53
  136. package/stepper/stepper.component.d.ts +1 -1
  137. package/table/table-column.component.d.ts +15 -5
  138. package/time-picker/inner/inner-time-picker.class.d.ts +15 -13
  139. package/time-picker/inner/inner-time-picker.component.d.ts +26 -26
  140. package/time-picker/time-picker-panel.component.d.ts +18 -20
  141. package/time-picker/time-picker.component.d.ts +22 -30
  142. package/tooltip/tooltip.directive.d.ts +20 -22
  143. package/tree-select/tree-select.component.d.ts +53 -70
@@ -1,48 +1,44 @@
1
1
  import { ThyPlacement } from 'ngx-tethys/core';
2
2
  import { TinyDate } from 'ngx-tethys/util';
3
3
  import { CdkConnectedOverlay, CdkOverlayOrigin, ConnectedOverlayPositionChange, ConnectionPositionPair } from '@angular/cdk/overlay';
4
- import { AfterViewInit, ElementRef, EventEmitter, OnChanges, SimpleChanges } from '@angular/core';
4
+ import { AfterViewInit, ElementRef } from '@angular/core';
5
5
  import { CompatibleValue, RangePartType } from './inner-types';
6
6
  import { ThyDateGranularity } from './standard-types';
7
7
  import * as i0 from "@angular/core";
8
- import * as i1 from "ngx-tethys/util";
9
8
  /**
10
9
  * @private
11
10
  */
12
- export declare class ThyPicker implements OnChanges, AfterViewInit {
11
+ export declare class ThyPicker implements AfterViewInit {
13
12
  private changeDetector;
14
13
  private dateHelper;
15
14
  private i18n;
16
- isRange: boolean;
17
- open: boolean | undefined;
18
- disabled: boolean;
19
- placeholder: string | string[];
20
- readonly: boolean;
21
- allowClear: boolean;
22
- autoFocus: boolean;
23
- className: string;
24
- size: 'sm' | 'xs' | 'lg' | 'md' | 'default';
25
- suffixIcon: string;
26
- placement: ThyPlacement;
27
- flexible: boolean;
28
- mode: string;
29
- hasBackdrop: boolean;
30
- separator: string;
31
- timeZone: string;
32
- blur: EventEmitter<Event>;
33
- readonly valueChange: EventEmitter<TinyDate | TinyDate[]>;
34
- readonly openChange: EventEmitter<boolean>;
35
- readonly inputChange: EventEmitter<string>;
36
- origin: CdkOverlayOrigin;
37
- cdkConnectedOverlay: CdkConnectedOverlay;
38
- pickerInput: ElementRef;
39
- overlayContainer: ElementRef<HTMLElement>;
40
- get format(): string;
41
- set format(value: string);
42
- get flexibleDateGranularity(): ThyDateGranularity;
43
- set flexibleDateGranularity(granularity: ThyDateGranularity);
44
- get value(): TinyDate | TinyDate[] | null;
45
- set value(value: TinyDate | TinyDate[] | null);
15
+ readonly isRange: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
16
+ readonly opened: import("@angular/core").InputSignal<boolean>;
17
+ readonly disabled: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
18
+ readonly placeholder: import("@angular/core").InputSignal<string | string[]>;
19
+ readonly readonly: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
20
+ readonly allowClear: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
21
+ readonly autoFocus: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
22
+ readonly className: import("@angular/core").InputSignal<string>;
23
+ readonly size: import("@angular/core").InputSignal<"default" | "sm" | "lg" | "xs" | "md">;
24
+ readonly suffixIcon: import("@angular/core").InputSignal<string>;
25
+ readonly placement: import("@angular/core").InputSignal<ThyPlacement>;
26
+ readonly flexible: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
27
+ readonly mode: import("@angular/core").InputSignal<string>;
28
+ readonly hasBackdrop: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
29
+ readonly separator: import("@angular/core").InputSignal<string>;
30
+ readonly timeZone: import("@angular/core").InputSignal<string>;
31
+ readonly blur: import("@angular/core").OutputEmitterRef<Event>;
32
+ readonly valueChange: import("@angular/core").OutputEmitterRef<TinyDate | TinyDate[]>;
33
+ readonly openChange: import("@angular/core").OutputEmitterRef<boolean>;
34
+ readonly inputChange: import("@angular/core").OutputEmitterRef<string>;
35
+ readonly origin: import("@angular/core").Signal<CdkOverlayOrigin>;
36
+ readonly cdkConnectedOverlay: import("@angular/core").Signal<CdkConnectedOverlay>;
37
+ readonly pickerInput: import("@angular/core").Signal<ElementRef<any>>;
38
+ readonly overlayContainer: import("@angular/core").Signal<ElementRef<HTMLElement>>;
39
+ readonly format: import("@angular/core").InputSignal<string>;
40
+ readonly flexibleDateGranularity: import("@angular/core").InputSignal<ThyDateGranularity>;
41
+ readonly value: import("@angular/core").InputSignal<TinyDate | TinyDate[]>;
46
42
  private innerflexibleDateGranularity;
47
43
  private innerFormat;
48
44
  private innerValue;
@@ -53,7 +49,7 @@ export declare class ThyPicker implements OnChanges, AfterViewInit {
53
49
  overlayPositions: ConnectionPositionPair[];
54
50
  get realOpenState(): boolean;
55
51
  get readonlyState(): boolean;
56
- ngOnChanges(changes: SimpleChanges): void;
52
+ constructor();
57
53
  ngAfterViewInit(): void;
58
54
  focus(): void;
59
55
  onBlur(event: FocusEvent): void;
@@ -76,6 +72,5 @@ export declare class ThyPicker implements OnChanges, AfterViewInit {
76
72
  getPlaceholder(): string;
77
73
  private updateReadableDate;
78
74
  static ɵfac: i0.ɵɵFactoryDeclaration<ThyPicker, never>;
79
- static ɵcmp: i0.ɵɵComponentDeclaration<ThyPicker, "thy-picker", ["thyPicker"], { "isRange": { "alias": "isRange"; "required": false; }; "open": { "alias": "open"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; "allowClear": { "alias": "allowClear"; "required": false; }; "autoFocus": { "alias": "autoFocus"; "required": false; }; "className": { "alias": "className"; "required": false; }; "size": { "alias": "size"; "required": false; }; "suffixIcon": { "alias": "suffixIcon"; "required": false; }; "placement": { "alias": "placement"; "required": false; }; "flexible": { "alias": "flexible"; "required": false; }; "mode": { "alias": "mode"; "required": false; }; "hasBackdrop": { "alias": "hasBackdrop"; "required": false; }; "separator": { "alias": "separator"; "required": false; }; "timeZone": { "alias": "timeZone"; "required": false; }; "format": { "alias": "format"; "required": false; }; "flexibleDateGranularity": { "alias": "flexibleDateGranularity"; "required": false; }; "value": { "alias": "value"; "required": false; }; }, { "blur": "blur"; "valueChange": "valueChange"; "openChange": "openChange"; "inputChange": "inputChange"; }, never, ["*"], true, never>;
80
- static ngAcceptInputType_hasBackdrop: i1.ThyBooleanInput;
75
+ static ɵcmp: i0.ɵɵComponentDeclaration<ThyPicker, "thy-picker", ["thyPicker"], { "isRange": { "alias": "isRange"; "required": false; "isSignal": true; }; "opened": { "alias": "opened"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "readonly": { "alias": "readonly"; "required": false; "isSignal": true; }; "allowClear": { "alias": "allowClear"; "required": false; "isSignal": true; }; "autoFocus": { "alias": "autoFocus"; "required": false; "isSignal": true; }; "className": { "alias": "className"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "suffixIcon": { "alias": "suffixIcon"; "required": false; "isSignal": true; }; "placement": { "alias": "placement"; "required": false; "isSignal": true; }; "flexible": { "alias": "flexible"; "required": false; "isSignal": true; }; "mode": { "alias": "mode"; "required": false; "isSignal": true; }; "hasBackdrop": { "alias": "hasBackdrop"; "required": false; "isSignal": true; }; "separator": { "alias": "separator"; "required": false; "isSignal": true; }; "timeZone": { "alias": "timeZone"; "required": false; "isSignal": true; }; "format": { "alias": "format"; "required": false; "isSignal": true; }; "flexibleDateGranularity": { "alias": "flexibleDateGranularity"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; }, { "blur": "blur"; "valueChange": "valueChange"; "openChange": "openChange"; "inputChange": "inputChange"; }, never, ["*"], true, never>;
81
76
  }
@@ -1,7 +1,7 @@
1
1
  import { PipeTransform } from '@angular/core';
2
2
  import { ThyDatePickerConfigService } from './date-picker.service';
3
3
  import { AdvancedSelectableCell } from './inner-types';
4
- import { CompatibleDate, DateEntry, ThyDateGranularity, ThyDateRangeEntry } from './standard-types';
4
+ import { ThyCompatibleDate, DateEntry, ThyDateGranularity, ThyDateRangeEntry } from './standard-types';
5
5
  import * as i0 from "@angular/core";
6
6
  /**
7
7
  * @private
@@ -10,14 +10,14 @@ export declare class ThyDatePickerFormatPipe implements PipeTransform {
10
10
  private dateHelper;
11
11
  private datePickerConfigService;
12
12
  private i18n;
13
- transform(originalValue: CompatibleDate | DateEntry | ThyDateRangeEntry, formatStr?: string, separator?: string): string;
13
+ transform(originalValue: ThyCompatibleDate | DateEntry | ThyDateRangeEntry, formatStr?: string, separator?: string): string;
14
14
  static ɵfac: i0.ɵɵFactoryDeclaration<ThyDatePickerFormatPipe, never>;
15
15
  static ɵpipe: i0.ɵɵPipeDeclaration<ThyDatePickerFormatPipe, "thyDatePickerFormat", true>;
16
16
  }
17
17
  export declare class ThyQuarterPickerFormatPipe implements PipeTransform {
18
18
  private datePickerConfigService;
19
19
  constructor(datePickerConfigService: ThyDatePickerConfigService);
20
- transform(originalValue: CompatibleDate | DateEntry | ThyDateRangeEntry, formatStr?: string, separator?: string): string;
20
+ transform(originalValue: ThyCompatibleDate | DateEntry | ThyDateRangeEntry, formatStr?: string, separator?: string): string;
21
21
  static ɵfac: i0.ɵɵFactoryDeclaration<ThyQuarterPickerFormatPipe, never>;
22
22
  static ɵpipe: i0.ɵɵPipeDeclaration<ThyQuarterPickerFormatPipe, "thyQuarterPickerFormat", true>;
23
23
  }
@@ -25,8 +25,7 @@ export declare class ThyQuarterPickerFormatPipe implements PipeTransform {
25
25
  * @private
26
26
  */
27
27
  export declare class ThyDatePickerFormatStringPipe implements PipeTransform {
28
- private dateHelper;
29
- transform(originalValue: CompatibleDate | DateEntry | ThyDateRangeEntry): string;
28
+ transform(originalValue: ThyCompatibleDate | DateEntry | ThyDateRangeEntry): string;
30
29
  static ɵfac: i0.ɵɵFactoryDeclaration<ThyDatePickerFormatStringPipe, never>;
31
30
  static ɵpipe: i0.ɵɵPipeDeclaration<ThyDatePickerFormatStringPipe, "thyDatePickerFormatString", true>;
32
31
  }
@@ -3,16 +3,16 @@ import { ThyI18nLocale } from 'ngx-tethys/i18n';
3
3
  import { SafeAny } from 'ngx-tethys/types';
4
4
  import { TinyDate } from 'ngx-tethys/util';
5
5
  import { CompatibleValue, RangeAdvancedValue } from './inner-types';
6
- import { CompatibleDate, DateEntry, ThyDateGranularity, ThyDateRangeEntry, ThyPanelMode, ThyShortcutValue } from './standard-types';
7
- export declare function transformDateValue(value: CompatibleDate | CompatibleValue | number | DateEntry | ThyDateRangeEntry | RangeAdvancedValue): {
8
- value: CompatibleDate;
6
+ import { ThyCompatibleDate, DateEntry, ThyDateGranularity, ThyDateRangeEntry, ThyPanelMode, ThyShortcutValue } from './standard-types';
7
+ export declare function transformDateValue(value: ThyCompatibleDate | CompatibleValue | number | DateEntry | ThyDateRangeEntry | RangeAdvancedValue): {
8
+ value: ThyCompatibleDate;
9
9
  withTime?: boolean;
10
10
  flexibleDateGranularity?: ThyDateGranularity;
11
11
  };
12
12
  export declare function getFlexibleAdvancedReadableValue(tinyDates: TinyDate[], flexibleDateGranularity: ThyDateGranularity, separator: string, locale: Signal<ThyI18nLocale>): string;
13
13
  export declare function convertDate(date: Date | number | TinyDate): Date;
14
14
  export declare function hasValue(value: CompatibleValue): boolean;
15
- export declare function makeValue(value: CompatibleDate | null, isRange?: boolean, timeZone?: string): CompatibleValue;
15
+ export declare function makeValue(value: ThyCompatibleDate | null, isRange?: boolean, timeZone?: string): CompatibleValue;
16
16
  export declare function dateAddAmount(value: TinyDate, amount: number, mode: ThyPanelMode): TinyDate;
17
17
  export declare function isAfterMoreThanOneMonth(rightDate: TinyDate, leftDate: TinyDate): boolean;
18
18
  export declare function isAfterMoreThanLessOneYear(rightDate: TinyDate, leftDate: TinyDate): boolean;
@@ -27,4 +27,4 @@ export declare function getShortcutValue(value: ThyShortcutValue): number | Date
27
27
  export declare function isValidStringDate(dateStr: string, timeZone?: string): boolean;
28
28
  export declare function parseStringDate(dateStr: string, timeZone?: string): TinyDate;
29
29
  export declare function hasTimeInStringDate(dateStr: string, timeZone?: string): boolean;
30
- export declare function setValueByTimestampPrecision(date: CompatibleDate | number | Date | DateEntry | ThyDateRangeEntry | SafeAny, isRange: boolean, timestampPrecision: 'seconds' | 'milliseconds', timeZone?: string): number | number[];
30
+ export declare function setValueByTimestampPrecision(date: ThyCompatibleDate | number | Date | DateEntry | ThyDateRangeEntry | SafeAny, isRange: boolean, timestampPrecision: 'seconds' | 'milliseconds', timeZone?: string): number | number[];
@@ -4,23 +4,19 @@ import * as i0 from "@angular/core";
4
4
  * @private
5
5
  */
6
6
  export declare class DatePickerRequiredValidator implements Validator {
7
- private _required;
8
- get required(): boolean | string;
9
- set required(value: boolean | string);
7
+ readonly required: import("@angular/core").InputSignalWithTransform<boolean, string | boolean>;
10
8
  validate(control: AbstractControl): ValidationErrors | null;
11
9
  private validateRequired;
12
10
  static ɵfac: i0.ɵɵFactoryDeclaration<DatePickerRequiredValidator, never>;
13
- static ɵdir: i0.ɵɵDirectiveDeclaration<DatePickerRequiredValidator, "[thyDatePicker][required][formControlName],[thyDatePicker][required][formControl],[thyDatePicker][required][ngModel],thy-date-picker[required][formControlName],thy-date-picker[required][formControl],thy-date-picker[required][ngModel]", never, { "required": { "alias": "required"; "required": false; }; }, {}, never, never, true, never>;
11
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DatePickerRequiredValidator, "[thyDatePicker][required][formControlName],[thyDatePicker][required][formControl],[thyDatePicker][required][ngModel],thy-date-picker[required][formControlName],thy-date-picker[required][formControl],thy-date-picker[required][ngModel]", never, { "required": { "alias": "required"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
14
12
  }
15
13
  /**
16
14
  * @private
17
15
  */
18
16
  export declare class RangePickerRequiredValidator implements Validator {
19
- private _required;
20
- get required(): boolean | string;
21
- set required(value: boolean | string);
17
+ readonly required: import("@angular/core").InputSignalWithTransform<boolean, string | boolean>;
22
18
  validate(control: AbstractControl): ValidationErrors | null;
23
19
  private validateRequired;
24
20
  static ɵfac: i0.ɵɵFactoryDeclaration<RangePickerRequiredValidator, never>;
25
- static ɵdir: i0.ɵɵDirectiveDeclaration<RangePickerRequiredValidator, "[thyRangePicker][required][formControlName],[thyRangePicker][required][formControl],[thyRangePicker][required][ngModel],thy-range-picker[required][formControlName],thy-range-picker[required][formControl],thy-range-picker[required][ngModel]", never, { "required": { "alias": "required"; "required": false; }; }, {}, never, never, true, never>;
21
+ static ɵdir: i0.ɵɵDirectiveDeclaration<RangePickerRequiredValidator, "[thyRangePicker][required][formControlName],[thyRangePicker][required][formControl],[thyRangePicker][required][ngModel],thy-range-picker[required][formControlName],thy-range-picker[required][formControl],thy-range-picker[required][ngModel]", never, { "required": { "alias": "required"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
26
22
  }
@@ -11,13 +11,12 @@ export declare class ThyQuarterPicker extends BasePicker {
11
11
  protected elementRef: ElementRef;
12
12
  /**
13
13
  * 展示的季度格式
14
- * @type string
15
14
  */
16
- thyFormat: string;
15
+ readonly thyFormat: import("@angular/core").ModelSignal<string>;
17
16
  isRange: boolean;
18
17
  endPanelMode: ThyPanelMode;
19
18
  private hostRenderer;
20
19
  constructor();
21
20
  static ɵfac: i0.ɵɵFactoryDeclaration<ThyQuarterPicker, never>;
22
- static ɵcmp: i0.ɵɵComponentDeclaration<ThyQuarterPicker, "thy-quarter-picker", ["thyQuarterPicker"], { "thyFormat": { "alias": "thyFormat"; "required": false; }; }, {}, never, never, true, never>;
21
+ static ɵcmp: i0.ɵɵComponentDeclaration<ThyQuarterPicker, "thy-quarter-picker", ["thyQuarterPicker"], { "thyFormat": { "alias": "thyFormat"; "required": false; "isSignal": true; }; }, { "thyFormat": "thyFormatChange"; }, never, never, true, never>;
23
22
  }
@@ -40,6 +40,7 @@ $input-box-height: 34px;
40
40
  }
41
41
 
42
42
  &-flexible {
43
+ width: 338px;
43
44
  .#{style.$calendar-prefix-cls}-picker-inner-popup {
44
45
  width: 338px;
45
46
  .thy-calendar-body {
@@ -8,7 +8,6 @@ import * as i0 from "@angular/core";
8
8
  */
9
9
  export declare class ThyWeekPicker extends BasePicker {
10
10
  protected elementRef: ElementRef;
11
- showWeek: boolean;
12
11
  private hostRenderer;
13
12
  constructor();
14
13
  static ɵfac: i0.ɵɵFactoryDeclaration<ThyWeekPicker, never>;
@@ -11,13 +11,12 @@ export declare class ThyYearPicker extends BasePicker {
11
11
  protected elementRef: ElementRef;
12
12
  /**
13
13
  * 展示的年份格式
14
- * @type string
15
14
  */
16
- thyFormat: string;
15
+ readonly thyFormat: import("@angular/core").ModelSignal<string>;
17
16
  isRange: boolean;
18
17
  endPanelMode: ThyPanelMode;
19
18
  private hostRenderer;
20
19
  constructor();
21
20
  static ɵfac: i0.ɵɵFactoryDeclaration<ThyYearPicker, never>;
22
- static ɵcmp: i0.ɵɵComponentDeclaration<ThyYearPicker, "thy-year-picker", ["thyYearPicker"], { "thyFormat": { "alias": "thyFormat"; "required": false; }; }, {}, never, never, true, never>;
21
+ static ɵcmp: i0.ɵɵComponentDeclaration<ThyYearPicker, "thy-year-picker", ["thyYearPicker"], { "thyFormat": { "alias": "thyFormat"; "required": false; "isSignal": true; }; }, { "thyFormat": "thyFormatChange"; }, never, never, true, never>;
23
22
  }
@@ -20,7 +20,7 @@ export declare class ThyDropdownMenuComponent {
20
20
  /**
21
21
  * 设置菜单宽度
22
22
  */
23
- readonly thyWidth: import("@angular/core").InputSignalWithTransform<string, any>;
23
+ readonly thyWidth: import("@angular/core").InputSignalWithTransform<string, string | number>;
24
24
  /**
25
25
  * 是否直接渲染 dropdown-menu 中的元素
26
26
  */
@@ -1,5 +1,5 @@
1
1
  import { ComponentType, OverlayRef } from '@angular/cdk/overlay';
2
- import { EventEmitter, OnInit, Signal, TemplateRef } from '@angular/core';
2
+ import { OnInit, Signal, TemplateRef } from '@angular/core';
3
3
  import { ThyOverlayDirectiveBase, ThyPlacement } from 'ngx-tethys/core';
4
4
  import { ThyPopoverConfig } from 'ngx-tethys/popover';
5
5
  import { SafeAny } from 'ngx-tethys/types';
@@ -50,8 +50,9 @@ export declare class ThyDropdownDirective extends ThyOverlayDirectiveBase implem
50
50
  readonly thyPopoverOptions: import("@angular/core").InputSignal<Pick<ThyPopoverConfig<unknown>, "height" | "minWidth" | "placement" | "insideClosable" | "outsideClosable">>;
51
51
  /**
52
52
  * 弹出框的显示位置,会覆盖 thyPopoverOptions 中的 placement,`top` | `topLeft` | `topRight` | `bottom` | `bottomLeft` | `bottomRight` | `left` | `leftTop` | `leftBottom` | `right` | `rightTop` | `rightBottom`
53
+ * @default bottomLeft
53
54
  */
54
- readonly thyPlacement: import("@angular/core").InputSignalWithTransform<ThyPlacement, ThyPlacement>;
55
+ readonly thyPlacement: import("@angular/core").InputSignal<ThyPlacement>;
55
56
  /**
56
57
  * 点击 dropdown-menu 内部是否关闭弹出框,会覆盖 thyPopoverOptions 中的 insideClosable
57
58
  */
@@ -64,7 +65,7 @@ export declare class ThyDropdownDirective extends ThyOverlayDirectiveBase implem
64
65
  /**
65
66
  * 菜单 Active 事件,打开菜单返回 true,关闭返回 false
66
67
  */
67
- thyActiveChange: EventEmitter<boolean>;
68
+ readonly thyActiveChange: import("@angular/core").OutputEmitterRef<boolean>;
68
69
  constructor();
69
70
  ngOnInit(): void;
70
71
  createOverlay(): OverlayRef;
@@ -81,7 +81,8 @@ export declare class ThyEmpty implements AfterViewInit {
81
81
  */
82
82
  readonly extraTemplateRef: Signal<TemplateRef<any>>;
83
83
  protected readonly presetSvg: Signal<import("@angular/platform-browser").SafeHtml>;
84
- protected readonly displayText: Signal<any>;
84
+ protected readonly displayText: import("@angular/core").WritableSignal<any>;
85
+ setMessage(text: string): void;
85
86
  constructor();
86
87
  private _calculatePosition;
87
88
  updateClass(): void;
@@ -1,6 +1,6 @@
1
1
  import { ThyTooltipDirective, ThyTooltipModule } from 'ngx-tethys/tooltip';
2
2
  import * as i0 from '@angular/core';
3
- import { inject, ChangeDetectorRef, signal, output, input, numberAttribute, computed, forwardRef, ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
3
+ import { inject, ChangeDetectorRef, signal, output, input, numberAttribute, computed, linkedSignal, forwardRef, ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
4
4
  import { CommonModule } from '@angular/common';
5
5
  import { ThyButtonIcon, ThyButtonModule } from 'ngx-tethys/button';
6
6
  import { NG_VALUE_ACCESSOR } from '@angular/forms';
@@ -55,6 +55,18 @@ class ThyArrowSwitcher {
55
55
  this.nextDisabled = computed(() => {
56
56
  return this.index() >= this.thyTotal() - 1 || this.disabled();
57
57
  });
58
+ this.previousTooltip = linkedSignal(() => {
59
+ return this.thyPreviousTooltip();
60
+ });
61
+ this.nextTooltip = linkedSignal(() => {
62
+ return this.thyNextTooltip();
63
+ });
64
+ }
65
+ setPreviousTooltip(value) {
66
+ this.previousTooltip.set(value);
67
+ }
68
+ setNextTooltip(value) {
69
+ this.nextTooltip.set(value);
58
70
  }
59
71
  writeValue(value) {
60
72
  if (value >= 0) {
@@ -88,7 +100,7 @@ class ThyArrowSwitcher {
88
100
  useExisting: forwardRef(() => ThyArrowSwitcher),
89
101
  multi: true
90
102
  }
91
- ], ngImport: i0, template: "@if (thyTheme() === 'lite') {\n <div class=\"switcher-wrapper\">\n <a\n thyAction\n [thyTooltip]=\"thyPreviousTooltip()\"\n href=\"javascript:;\"\n [thyDisabled]=\"previousDisabled()\"\n class=\"mr-2\"\n (click)=\"onPreviousClick($event)\"\n ><thy-icon thyIconName=\"angle-up\"></thy-icon\n ></a>\n <a thyAction [thyTooltip]=\"thyNextTooltip()\" href=\"javascript:;\" [thyDisabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"\n ><thy-icon thyIconName=\"angle-down\"></thy-icon\n ></a>\n </div>\n} @else {\n <div class=\"switcher-wrapper\">\n <button\n thyButtonIcon=\"angle-left\"\n [thyTooltip]=\"thyPreviousTooltip()\"\n [disabled]=\"previousDisabled()\"\n (click)=\"onPreviousClick($event)\"></button>\n <span>{{ index() + 1 }} / {{ thyTotal() }}</span>\n <button thyButtonIcon=\"angle-right\" [thyTooltip]=\"thyNextTooltip()\" [disabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"></button>\n </div>\n}\n", dependencies: [{ kind: "component", type: ThyAction, selector: "thy-action, [thyAction]", inputs: ["thyType", "thyIcon", "thyActionIcon", "thyActive", "thyActionActive", "thyTheme", "thyHoverIcon", "thyDisabled"] }, { kind: "directive", type: ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { kind: "component", type: ThyIcon, selector: "thy-icon, [thy-icon]", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { kind: "component", type: ThyButtonIcon, selector: "thy-button-icon,[thy-button-icon],[thyButtonIcon]", inputs: ["thySize", "thyIcon", "thyButtonIcon", "thyShape", "thyLight", "thyActive", "thyTheme", "thyColor"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
103
+ ], ngImport: i0, template: "@if (thyTheme() === 'lite') {\n <div class=\"switcher-wrapper\">\n <a\n thyAction\n [thyTooltip]=\"previousTooltip()\"\n href=\"javascript:;\"\n [thyDisabled]=\"previousDisabled()\"\n class=\"mr-2\"\n (click)=\"onPreviousClick($event)\"\n ><thy-icon thyIconName=\"angle-up\"></thy-icon\n ></a>\n <a thyAction [thyTooltip]=\"nextTooltip()\" href=\"javascript:;\" [thyDisabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"\n ><thy-icon thyIconName=\"angle-down\"></thy-icon\n ></a>\n </div>\n} @else {\n <div class=\"switcher-wrapper\">\n <button\n thyButtonIcon=\"angle-left\"\n [thyTooltip]=\"previousTooltip()\"\n [disabled]=\"previousDisabled()\"\n (click)=\"onPreviousClick($event)\"></button>\n <span>{{ index() + 1 }} / {{ thyTotal() }}</span>\n <button thyButtonIcon=\"angle-right\" [thyTooltip]=\"nextTooltip()\" [disabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"></button>\n </div>\n}\n", dependencies: [{ kind: "component", type: ThyAction, selector: "thy-action, [thyAction]", inputs: ["thyType", "thyIcon", "thyActionIcon", "thyActive", "thyActionActive", "thyTheme", "thyHoverIcon", "thyDisabled"] }, { kind: "directive", type: ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { kind: "component", type: ThyIcon, selector: "thy-icon, [thy-icon]", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { kind: "component", type: ThyButtonIcon, selector: "thy-button-icon,[thy-button-icon],[thyButtonIcon]", inputs: ["thySize", "thyIcon", "thyButtonIcon", "thyShape", "thyLight", "thyActive", "thyTheme", "thyColor"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
92
104
  }
93
105
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: ThyArrowSwitcher, decorators: [{
94
106
  type: Component,
@@ -101,7 +113,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImpor
101
113
  useExisting: forwardRef(() => ThyArrowSwitcher),
102
114
  multi: true
103
115
  }
104
- ], imports: [ThyAction, ThyTooltipDirective, ThyIcon, ThyButtonIcon], template: "@if (thyTheme() === 'lite') {\n <div class=\"switcher-wrapper\">\n <a\n thyAction\n [thyTooltip]=\"thyPreviousTooltip()\"\n href=\"javascript:;\"\n [thyDisabled]=\"previousDisabled()\"\n class=\"mr-2\"\n (click)=\"onPreviousClick($event)\"\n ><thy-icon thyIconName=\"angle-up\"></thy-icon\n ></a>\n <a thyAction [thyTooltip]=\"thyNextTooltip()\" href=\"javascript:;\" [thyDisabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"\n ><thy-icon thyIconName=\"angle-down\"></thy-icon\n ></a>\n </div>\n} @else {\n <div class=\"switcher-wrapper\">\n <button\n thyButtonIcon=\"angle-left\"\n [thyTooltip]=\"thyPreviousTooltip()\"\n [disabled]=\"previousDisabled()\"\n (click)=\"onPreviousClick($event)\"></button>\n <span>{{ index() + 1 }} / {{ thyTotal() }}</span>\n <button thyButtonIcon=\"angle-right\" [thyTooltip]=\"thyNextTooltip()\" [disabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"></button>\n </div>\n}\n" }]
116
+ ], imports: [ThyAction, ThyTooltipDirective, ThyIcon, ThyButtonIcon], template: "@if (thyTheme() === 'lite') {\n <div class=\"switcher-wrapper\">\n <a\n thyAction\n [thyTooltip]=\"previousTooltip()\"\n href=\"javascript:;\"\n [thyDisabled]=\"previousDisabled()\"\n class=\"mr-2\"\n (click)=\"onPreviousClick($event)\"\n ><thy-icon thyIconName=\"angle-up\"></thy-icon\n ></a>\n <a thyAction [thyTooltip]=\"nextTooltip()\" href=\"javascript:;\" [thyDisabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"\n ><thy-icon thyIconName=\"angle-down\"></thy-icon\n ></a>\n </div>\n} @else {\n <div class=\"switcher-wrapper\">\n <button\n thyButtonIcon=\"angle-left\"\n [thyTooltip]=\"previousTooltip()\"\n [disabled]=\"previousDisabled()\"\n (click)=\"onPreviousClick($event)\"></button>\n <span>{{ index() + 1 }} / {{ thyTotal() }}</span>\n <button thyButtonIcon=\"angle-right\" [thyTooltip]=\"nextTooltip()\" [disabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"></button>\n </div>\n}\n" }]
105
117
  }] });
106
118
 
107
119
  class ThyArrowSwitcherModule {
@@ -1 +1 @@
1
- {"version":3,"file":"ngx-tethys-arrow-switcher.mjs","sources":["../../../src/arrow-switcher/arrow-switcher.component.ts","../../../src/arrow-switcher/arrow-switcher.component.html","../../../src/arrow-switcher/module.ts","../../../src/arrow-switcher/ngx-tethys-arrow-switcher.ts"],"sourcesContent":["import {\n Component,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n forwardRef,\n numberAttribute,\n inject,\n input,\n output,\n computed,\n Signal,\n WritableSignal,\n signal\n} from '@angular/core';\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { ThyButtonIcon } from 'ngx-tethys/button';\nimport { ThyIcon } from 'ngx-tethys/icon';\nimport { ThyTooltipDirective } from 'ngx-tethys/tooltip';\nimport { ThyAction } from 'ngx-tethys/action';\n\nexport type ThyArrowSwitcherTheme = 'default' | 'lite';\nexport interface ThyArrowSwitcherEvent {\n index: number;\n event: Event;\n}\n\n/**\n * 上下条切换组件\n * @name thy-arrow-switcher\n * @order 10\n */\n@Component({\n selector: 'thy-arrow-switcher',\n templateUrl: './arrow-switcher.component.html',\n host: {\n class: 'thy-arrow-switcher',\n '[class.thy-arrow-switcher-small]': 'isSmallSize()'\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => ThyArrowSwitcher),\n multi: true\n }\n ],\n imports: [ThyAction, ThyTooltipDirective, ThyIcon, ThyButtonIcon]\n})\nexport class ThyArrowSwitcher implements ControlValueAccessor {\n private cd = inject(ChangeDetectorRef);\n\n private disabled: WritableSignal<boolean> = signal(false);\n\n /**\n * 点击上一条事件\n */\n readonly thyPrevious = output<ThyArrowSwitcherEvent>();\n\n /**\n * 点击下一条事件\n */\n readonly thyNext = output<ThyArrowSwitcherEvent>();\n\n /**\n * 设置上一条 Hover Tooltip 提示\n */\n readonly thyPreviousTooltip = input<string>();\n\n /**\n * 设置下一条 Hover Tooltip 提示\n */\n readonly thyNextTooltip = input<string>();\n\n /**\n * 展示主题\n * @type default | lite\n */\n readonly thyTheme = input<ThyArrowSwitcherTheme>('default');\n\n /**\n * 总条数\n */\n readonly thyTotal = input<number, unknown>(undefined, { transform: numberAttribute });\n\n /**\n * 尺寸大小,默认尺寸为大号,取值为`sm`时展示小号\n */\n readonly thySize = input<string>();\n\n readonly isSmallSize: Signal<boolean> = computed(() => {\n return this.thySize() === 'sm';\n });\n\n index: WritableSignal<number> = signal(0);\n\n readonly previousDisabled = computed(() => {\n return this.index() <= 0 || this.disabled();\n });\n\n readonly nextDisabled = computed(() => {\n return this.index() >= this.thyTotal() - 1 || this.disabled();\n });\n\n private onModelChange: (value: number) => void;\n\n private onModelTouched: () => void;\n\n writeValue(value: number): void {\n if (value >= 0) {\n this.index.set(value);\n }\n this.cd.markForCheck();\n }\n\n registerOnChange(fn: () => void) {\n this.onModelChange = fn;\n }\n\n registerOnTouched(fn: () => void) {\n this.onModelTouched = fn;\n }\n\n setDisabledState(isDisable: boolean) {\n this.disabled.set(isDisable);\n }\n\n onPreviousClick(event: Event) {\n this.index.set(this.index() - 1);\n this.onModelChange(this.index());\n\n this.thyPrevious.emit({ index: this.index(), event });\n }\n\n onNextClick(event: Event) {\n this.index.set(this.index() + 1);\n this.onModelChange(this.index());\n\n this.thyNext.emit({ index: this.index(), event });\n }\n}\n","@if (thyTheme() === 'lite') {\n <div class=\"switcher-wrapper\">\n <a\n thyAction\n [thyTooltip]=\"thyPreviousTooltip()\"\n href=\"javascript:;\"\n [thyDisabled]=\"previousDisabled()\"\n class=\"mr-2\"\n (click)=\"onPreviousClick($event)\"\n ><thy-icon thyIconName=\"angle-up\"></thy-icon\n ></a>\n <a thyAction [thyTooltip]=\"thyNextTooltip()\" href=\"javascript:;\" [thyDisabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"\n ><thy-icon thyIconName=\"angle-down\"></thy-icon\n ></a>\n </div>\n} @else {\n <div class=\"switcher-wrapper\">\n <button\n thyButtonIcon=\"angle-left\"\n [thyTooltip]=\"thyPreviousTooltip()\"\n [disabled]=\"previousDisabled()\"\n (click)=\"onPreviousClick($event)\"></button>\n <span>{{ index() + 1 }} / {{ thyTotal() }}</span>\n <button thyButtonIcon=\"angle-right\" [thyTooltip]=\"thyNextTooltip()\" [disabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"></button>\n </div>\n}\n","import { ThyTooltipModule } from 'ngx-tethys/tooltip';\nimport { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ThyButtonModule } from 'ngx-tethys/button';\nimport { ThyArrowSwitcher } from './arrow-switcher.component';\nimport { ThyIconModule } from 'ngx-tethys/icon';\nimport { ThyActionModule } from 'ngx-tethys/action';\n\n@NgModule({\n imports: [CommonModule, ThyButtonModule, ThyIconModule, ThyActionModule, ThyTooltipModule, ThyArrowSwitcher],\n exports: [ThyArrowSwitcher]\n})\nexport class ThyArrowSwitcherModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;AA0BA;;;;AAIG;MAkBU,gBAAgB,CAAA;AAjB7B,IAAA,WAAA,GAAA;AAkBY,QAAA,IAAA,CAAA,EAAE,GAAG,MAAM,CAAC,iBAAiB,CAAC;AAE9B,QAAA,IAAA,CAAA,QAAQ,GAA4B,MAAM,CAAC,KAAK,CAAC;AAEzD;;AAEG;QACM,IAAW,CAAA,WAAA,GAAG,MAAM,EAAyB;AAEtD;;AAEG;QACM,IAAO,CAAA,OAAA,GAAG,MAAM,EAAyB;AAElD;;AAEG;QACM,IAAkB,CAAA,kBAAA,GAAG,KAAK,EAAU;AAE7C;;AAEG;QACM,IAAc,CAAA,cAAA,GAAG,KAAK,EAAU;AAEzC;;;AAGG;AACM,QAAA,IAAA,CAAA,QAAQ,GAAG,KAAK,CAAwB,SAAS,CAAC;AAE3D;;AAEG;QACM,IAAQ,CAAA,QAAA,GAAG,KAAK,CAAkB,SAAS,EAAE,EAAE,SAAS,EAAE,eAAe,EAAE,CAAC;AAErF;;AAEG;QACM,IAAO,C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A,EAAA,CAAA;kBAJlC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,eAAe,EAAE,aAAa,EAAE,eAAe,EAAE,gBAAgB,EAAE,gBAAgB,CAAC;oBAC5G,OAAO,EAAE,CAAC,gBAAgB;AAC7B,iBAAA;;;ACXD;;AAEG;;;;"}
1
+ {"version":3,"file":"ngx-tethys-arrow-switcher.mjs","sources":["../../../src/arrow-switcher/arrow-switcher.component.ts","../../../src/arrow-switcher/arrow-switcher.component.html","../../../src/arrow-switcher/module.ts","../../../src/arrow-switcher/ngx-tethys-arrow-switcher.ts"],"sourcesContent":["import {\n Component,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n forwardRef,\n numberAttribute,\n inject,\n input,\n output,\n computed,\n Signal,\n WritableSignal,\n signal,\n linkedSignal\n} from '@angular/core';\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { ThyButtonIcon } from 'ngx-tethys/button';\nimport { ThyIcon } from 'ngx-tethys/icon';\nimport { ThyTooltipDirective } from 'ngx-tethys/tooltip';\nimport { ThyAction } from 'ngx-tethys/action';\n\nexport type ThyArrowSwitcherTheme = 'default' | 'lite';\nexport interface ThyArrowSwitcherEvent {\n index: number;\n event: Event;\n}\n\n/**\n * 上下条切换组件\n * @name thy-arrow-switcher\n * @order 10\n */\n@Component({\n selector: 'thy-arrow-switcher',\n templateUrl: './arrow-switcher.component.html',\n host: {\n class: 'thy-arrow-switcher',\n '[class.thy-arrow-switcher-small]': 'isSmallSize()'\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => ThyArrowSwitcher),\n multi: true\n }\n ],\n imports: [ThyAction, ThyTooltipDirective, ThyIcon, ThyButtonIcon]\n})\nexport class ThyArrowSwitcher implements ControlValueAccessor {\n private cd = inject(ChangeDetectorRef);\n\n private disabled: WritableSignal<boolean> = signal(false);\n\n /**\n * 点击上一条事件\n */\n readonly thyPrevious = output<ThyArrowSwitcherEvent>();\n\n /**\n * 点击下一条事件\n */\n readonly thyNext = output<ThyArrowSwitcherEvent>();\n\n /**\n * 设置上一条 Hover Tooltip 提示\n */\n readonly thyPreviousTooltip = input<string>();\n\n /**\n * 设置下一条 Hover Tooltip 提示\n */\n readonly thyNextTooltip = input<string>();\n\n /**\n * 展示主题\n * @type default | lite\n */\n readonly thyTheme = input<ThyArrowSwitcherTheme>('default');\n\n /**\n * 总条数\n */\n readonly thyTotal = input<number, unknown>(undefined, { transform: numberAttribute });\n\n /**\n * 尺寸大小,默认尺寸为大号,取值为`sm`时展示小号\n */\n readonly thySize = input<string>();\n\n readonly isSmallSize: Signal<boolean> = computed(() => {\n return this.thySize() === 'sm';\n });\n\n protected readonly index: WritableSignal<number> = signal(0);\n\n readonly previousDisabled = computed(() => {\n return this.index() <= 0 || this.disabled();\n });\n\n readonly nextDisabled = computed(() => {\n return this.index() >= this.thyTotal() - 1 || this.disabled();\n });\n\n private onModelChange: (value: number) => void;\n\n private onModelTouched: () => void;\n\n protected readonly previousTooltip = linkedSignal(() => {\n return this.thyPreviousTooltip();\n });\n\n protected readonly nextTooltip = linkedSignal(() => {\n return this.thyNextTooltip();\n });\n\n public setPreviousTooltip(value: string) {\n this.previousTooltip.set(value);\n }\n\n public setNextTooltip(value: string) {\n this.nextTooltip.set(value);\n }\n\n writeValue(value: number): void {\n if (value >= 0) {\n this.index.set(value);\n }\n this.cd.markForCheck();\n }\n\n registerOnChange(fn: () => void) {\n this.onModelChange = fn;\n }\n\n registerOnTouched(fn: () => void) {\n this.onModelTouched = fn;\n }\n\n setDisabledState(isDisable: boolean) {\n this.disabled.set(isDisable);\n }\n\n onPreviousClick(event: Event) {\n this.index.set(this.index() - 1);\n this.onModelChange(this.index());\n\n this.thyPrevious.emit({ index: this.index(), event });\n }\n\n onNextClick(event: Event) {\n this.index.set(this.index() + 1);\n this.onModelChange(this.index());\n\n this.thyNext.emit({ index: this.index(), event });\n }\n}\n","@if (thyTheme() === 'lite') {\n <div class=\"switcher-wrapper\">\n <a\n thyAction\n [thyTooltip]=\"previousTooltip()\"\n href=\"javascript:;\"\n [thyDisabled]=\"previousDisabled()\"\n class=\"mr-2\"\n (click)=\"onPreviousClick($event)\"\n ><thy-icon thyIconName=\"angle-up\"></thy-icon\n ></a>\n <a thyAction [thyTooltip]=\"nextTooltip()\" href=\"javascript:;\" [thyDisabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"\n ><thy-icon thyIconName=\"angle-down\"></thy-icon\n ></a>\n </div>\n} @else {\n <div class=\"switcher-wrapper\">\n <button\n thyButtonIcon=\"angle-left\"\n [thyTooltip]=\"previousTooltip()\"\n [disabled]=\"previousDisabled()\"\n (click)=\"onPreviousClick($event)\"></button>\n <span>{{ index() + 1 }} / {{ thyTotal() }}</span>\n <button thyButtonIcon=\"angle-right\" [thyTooltip]=\"nextTooltip()\" [disabled]=\"nextDisabled()\" (click)=\"onNextClick($event)\"></button>\n </div>\n}\n","import { ThyTooltipModule } from 'ngx-tethys/tooltip';\nimport { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ThyButtonModule } from 'ngx-tethys/button';\nimport { ThyArrowSwitcher } from './arrow-switcher.component';\nimport { ThyIconModule } from 'ngx-tethys/icon';\nimport { ThyActionModule } from 'ngx-tethys/action';\n\n@NgModule({\n imports: [CommonModule, ThyButtonModule, ThyIconModule, ThyActionModule, ThyTooltipModule, ThyArrowSwitcher],\n exports: [ThyArrowSwitcher]\n})\nexport class ThyArrowSwitcherModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;AA2BA;;;;AAIG;MAkBU,gBAAgB,CAAA;AAjB7B,IAAA,WAAA,GAAA;AAkBY,QAAA,IAAA,CAAA,EAAE,GAAG,MAAM,CAAC,iBAAiB,CAAC;AAE9B,QAAA,IAAA,CAAA,QAAQ,GAA4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, ThyOption, THY_OPTION_PARENT_COMPONENT, ThyOptionModule, ThySharedModule } from 'ngx-tethys/shared';
12
12
  import { Subject, defer, merge, timer, of, fromEvent } from 'rxjs';
13
13
  import { take, switchMap, startWith, takeUntil, filter, map, delay } from 'rxjs/operators';
14
+ import { outputToObservable } from '@angular/core/rxjs-interop';
14
15
  import { SelectionModel } from '@angular/cdk/collections';
15
16
  import { ActiveDescendantKeyManager } from '@angular/cdk/a11y';
16
17
  import { coerceBooleanProperty, ESCAPE, ENTER, UP_ARROW, DOWN_ARROW, TAB } from 'ngx-tethys/util';
@@ -21,7 +22,6 @@ import { coerceElement, coerceArray } from '@angular/cdk/coercion';
21
22
  import { Platform } from '@angular/cdk/platform';
22
23
  import { ViewportRuler } from '@angular/cdk/scrolling';
23
24
  import { state, style, trigger } from '@angular/animations';
24
- import { outputToObservable } from '@angular/core/rxjs-interop';
25
25
 
26
26
  /**
27
27
  * 自动完成组件
@@ -43,7 +43,7 @@ class ThyAutocomplete {
43
43
  this.optionsContainer = viewChild('panel');
44
44
  this.optionSelectionChanges = defer(() => {
45
45
  if (this.options) {
46
- return merge(...this.options.map(option => option.selectionChange));
46
+ return merge(...this.options.map(option => outputToObservable(option.selectionChange)));
47
47
  }
48
48
  return this.ngZone.onStable.asObservable().pipe(take(1), switchMap(() => this.optionSelectionChanges));
49
49
  });
@@ -127,8 +127,8 @@ class ThyAutocomplete {
127
127
  this.selectionModel.clear();
128
128
  }
129
129
  else {
130
- if (wasSelected !== option.selected) {
131
- option.selected ? this.selectionModel.select(option) : this.selectionModel.deselect(option);
130
+ if (wasSelected !== option.selected()) {
131
+ option.selected() ? this.selectionModel.select(option) : this.selectionModel.deselect(option);
132
132
  }
133
133
  if (isUserInput) {
134
134
  this.keyManager.setActiveItem(option);