@taiga-ui/legacy 4.52.0-canary.65c65f9 → 4.52.0-canary.692273c

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 (160) hide show
  1. package/components/combo-box/combo-box.module.d.ts +1 -1
  2. package/components/dialog/dialog.component.d.ts +20 -0
  3. package/components/dialog/dialog.directive.d.ts +7 -0
  4. package/components/dialog/dialog.factory.d.ts +16 -0
  5. package/components/dialog/dialog.interfaces.d.ts +31 -0
  6. package/components/dialog/dialog.service.d.ts +7 -0
  7. package/components/dialog/dialog.tokens.d.ts +8 -0
  8. package/components/dialog/index.d.ts +6 -0
  9. package/components/index.d.ts +1 -11
  10. package/components/input/input.module.d.ts +1 -1
  11. package/components/input-date-range/input-date-range.module.d.ts +1 -1
  12. package/components/input-date-time/input-date-time.module.d.ts +1 -1
  13. package/components/input-month-range/input-month-range.module.d.ts +1 -1
  14. package/components/input-range/input-range.component.d.ts +1 -1
  15. package/components/input-tag/input-tag.module.d.ts +1 -1
  16. package/components/multi-select/multi-select.module.d.ts +1 -1
  17. package/components/select/select.module.d.ts +1 -1
  18. package/fesm2022/taiga-ui-legacy-components-combo-box.mjs +4 -5
  19. package/fesm2022/taiga-ui-legacy-components-combo-box.mjs.map +1 -1
  20. package/fesm2022/taiga-ui-legacy-components-dialog.mjs +130 -0
  21. package/fesm2022/taiga-ui-legacy-components-dialog.mjs.map +1 -0
  22. package/fesm2022/taiga-ui-legacy-components-input-date-range.mjs +2 -2
  23. package/fesm2022/taiga-ui-legacy-components-input-date-range.mjs.map +1 -1
  24. package/fesm2022/taiga-ui-legacy-components-input-date-time.mjs +2 -2
  25. package/fesm2022/taiga-ui-legacy-components-input-date-time.mjs.map +1 -1
  26. package/fesm2022/taiga-ui-legacy-components-input-month-range.mjs +2 -2
  27. package/fesm2022/taiga-ui-legacy-components-input-month-range.mjs.map +1 -1
  28. package/fesm2022/taiga-ui-legacy-components-input-number.mjs +2 -2
  29. package/fesm2022/taiga-ui-legacy-components-input-number.mjs.map +1 -1
  30. package/fesm2022/taiga-ui-legacy-components-input-range.mjs +7 -7
  31. package/fesm2022/taiga-ui-legacy-components-input-range.mjs.map +1 -1
  32. package/fesm2022/taiga-ui-legacy-components-input-slider.mjs +3 -3
  33. package/fesm2022/taiga-ui-legacy-components-input-slider.mjs.map +1 -1
  34. package/fesm2022/taiga-ui-legacy-components-input-tag.mjs +3 -3
  35. package/fesm2022/taiga-ui-legacy-components-input-tag.mjs.map +1 -1
  36. package/fesm2022/taiga-ui-legacy-components-input.mjs +4 -5
  37. package/fesm2022/taiga-ui-legacy-components-input.mjs.map +1 -1
  38. package/fesm2022/taiga-ui-legacy-components-multi-select-option.mjs +1 -1
  39. package/fesm2022/taiga-ui-legacy-components-multi-select-option.mjs.map +1 -1
  40. package/fesm2022/taiga-ui-legacy-components-multi-select.mjs +4 -4
  41. package/fesm2022/taiga-ui-legacy-components-multi-select.mjs.map +1 -1
  42. package/fesm2022/taiga-ui-legacy-components-primitive-textfield.mjs +2 -2
  43. package/fesm2022/taiga-ui-legacy-components-primitive-textfield.mjs.map +1 -1
  44. package/fesm2022/taiga-ui-legacy-components-select.mjs +4 -5
  45. package/fesm2022/taiga-ui-legacy-components-select.mjs.map +1 -1
  46. package/fesm2022/taiga-ui-legacy-components-textarea.mjs +2 -2
  47. package/fesm2022/taiga-ui-legacy-components-textarea.mjs.map +1 -1
  48. package/fesm2022/taiga-ui-legacy-components.mjs +1 -11
  49. package/fesm2022/taiga-ui-legacy-components.mjs.map +1 -1
  50. package/fesm2022/taiga-ui-legacy.mjs +0 -2
  51. package/fesm2022/taiga-ui-legacy.mjs.map +1 -1
  52. package/index.d.ts +0 -2
  53. package/package.json +5 -65
  54. package/utils/icons-path-factory.d.ts +1 -1
  55. package/components/color-selector/color-edit/color-edit.component.d.ts +0 -18
  56. package/components/color-selector/color-edit/color-edit.module.d.ts +0 -21
  57. package/components/color-selector/color-picker/color-picker.component.d.ts +0 -22
  58. package/components/color-selector/color-picker/color-picker.module.d.ts +0 -14
  59. package/components/color-selector/color-selector.component.d.ts +0 -47
  60. package/components/color-selector/color-selector.module.d.ts +0 -23
  61. package/components/color-selector/color-selector.options.d.ts +0 -25
  62. package/components/color-selector/flat-picker/flat-picker.component.d.ts +0 -12
  63. package/components/color-selector/flat-picker/flat-picker.module.d.ts +0 -12
  64. package/components/color-selector/index.d.ts +0 -16
  65. package/components/color-selector/linear-multi-picker/linear-multi-picker.component.d.ts +0 -17
  66. package/components/color-selector/linear-multi-picker/linear-multi-picker.module.d.ts +0 -12
  67. package/components/color-selector/linear-picker/linear-picker.component.d.ts +0 -10
  68. package/components/color-selector/linear-picker/linear-picker.module.d.ts +0 -12
  69. package/components/color-selector/palette/palette.component.d.ts +0 -10
  70. package/components/color-selector/palette/palette.module.d.ts +0 -13
  71. package/components/color-selector/services/picker.service.d.ts +0 -15
  72. package/components/input-color/index.d.ts +0 -2
  73. package/components/input-color/input-color.component.d.ts +0 -30
  74. package/components/input-color/input-color.module.d.ts +0 -17
  75. package/components/input-copy/index.d.ts +0 -4
  76. package/components/input-copy/input-copy.component.d.ts +0 -33
  77. package/components/input-copy/input-copy.directive.d.ts +0 -11
  78. package/components/input-copy/input-copy.module.d.ts +0 -18
  79. package/components/input-copy/input-copy.options.d.ts +0 -26
  80. package/components/input-date/index.d.ts +0 -3
  81. package/components/input-date/input-date.component.d.ts +0 -62
  82. package/components/input-date/input-date.directive.d.ts +0 -19
  83. package/components/input-date/input-date.module.d.ts +0 -24
  84. package/components/input-date/native-date/native-date.component.d.ts +0 -15
  85. package/components/input-date-multi/index.d.ts +0 -2
  86. package/components/input-date-multi/input-date-multi.component.d.ts +0 -66
  87. package/components/input-date-multi/input-date-multi.module.d.ts +0 -20
  88. package/components/input-month/index.d.ts +0 -3
  89. package/components/input-month/input-month.component.d.ts +0 -44
  90. package/components/input-month/input-month.directive.d.ts +0 -19
  91. package/components/input-month/input-month.module.d.ts +0 -19
  92. package/components/input-phone/index.d.ts +0 -4
  93. package/components/input-phone/input-phone.component.d.ts +0 -52
  94. package/components/input-phone/input-phone.directive.d.ts +0 -16
  95. package/components/input-phone/input-phone.module.d.ts +0 -15
  96. package/components/input-phone/input-phone.options.d.ts +0 -22
  97. package/components/input-phone/utils/complete-phone-insertion-preprocessor.d.ts +0 -9
  98. package/components/input-phone/utils/create-phone-mask-expression.d.ts +0 -7
  99. package/components/input-phone/utils/index.d.ts +0 -2
  100. package/components/input-phone-international/index.d.ts +0 -3
  101. package/components/input-phone-international/input-phone-international.component.d.ts +0 -43
  102. package/components/input-phone-international/input-phone-international.options.d.ts +0 -25
  103. package/components/input-phone-international/utils/extract-value-from-event.d.ts +0 -4
  104. package/components/input-time/index.d.ts +0 -4
  105. package/components/input-time/input-time.component.d.ts +0 -62
  106. package/components/input-time/input-time.directive.d.ts +0 -17
  107. package/components/input-time/input-time.module.d.ts +0 -23
  108. package/components/input-time/input-time.options.d.ts +0 -42
  109. package/components/input-time/native-time/native-time.component.d.ts +0 -12
  110. package/components/input-year/index.d.ts +0 -3
  111. package/components/input-year/input-year.component.d.ts +0 -36
  112. package/components/input-year/input-year.directive.d.ts +0 -14
  113. package/components/input-year/input-year.module.d.ts +0 -18
  114. package/components/svg/content-processor.d.ts +0 -19
  115. package/components/svg/deprecated-icons.d.ts +0 -5
  116. package/components/svg/index.d.ts +0 -5
  117. package/components/svg/svg-options.d.ts +0 -50
  118. package/components/svg/svg.component.d.ts +0 -50
  119. package/components/svg/svg.service.d.ts +0 -21
  120. package/fesm2022/taiga-ui-legacy-components-color-selector.mjs +0 -726
  121. package/fesm2022/taiga-ui-legacy-components-color-selector.mjs.map +0 -1
  122. package/fesm2022/taiga-ui-legacy-components-input-color.mjs +0 -127
  123. package/fesm2022/taiga-ui-legacy-components-input-color.mjs.map +0 -1
  124. package/fesm2022/taiga-ui-legacy-components-input-copy.mjs +0 -197
  125. package/fesm2022/taiga-ui-legacy-components-input-copy.mjs.map +0 -1
  126. package/fesm2022/taiga-ui-legacy-components-input-date-multi.mjs +0 -272
  127. package/fesm2022/taiga-ui-legacy-components-input-date-multi.mjs.map +0 -1
  128. package/fesm2022/taiga-ui-legacy-components-input-date.mjs +0 -372
  129. package/fesm2022/taiga-ui-legacy-components-input-date.mjs.map +0 -1
  130. package/fesm2022/taiga-ui-legacy-components-input-month.mjs +0 -231
  131. package/fesm2022/taiga-ui-legacy-components-input-month.mjs.map +0 -1
  132. package/fesm2022/taiga-ui-legacy-components-input-phone-international.mjs +0 -215
  133. package/fesm2022/taiga-ui-legacy-components-input-phone-international.mjs.map +0 -1
  134. package/fesm2022/taiga-ui-legacy-components-input-phone.mjs +0 -373
  135. package/fesm2022/taiga-ui-legacy-components-input-phone.mjs.map +0 -1
  136. package/fesm2022/taiga-ui-legacy-components-input-time.mjs +0 -430
  137. package/fesm2022/taiga-ui-legacy-components-input-time.mjs.map +0 -1
  138. package/fesm2022/taiga-ui-legacy-components-input-year.mjs +0 -188
  139. package/fesm2022/taiga-ui-legacy-components-input-year.mjs.map +0 -1
  140. package/fesm2022/taiga-ui-legacy-components-svg.mjs +0 -387
  141. package/fesm2022/taiga-ui-legacy-components-svg.mjs.map +0 -1
  142. package/fesm2022/taiga-ui-legacy-pipes-format-phone.mjs +0 -59
  143. package/fesm2022/taiga-ui-legacy-pipes-format-phone.mjs.map +0 -1
  144. package/fesm2022/taiga-ui-legacy-pipes-iso-to-country-code.mjs +0 -50
  145. package/fesm2022/taiga-ui-legacy-pipes-iso-to-country-code.mjs.map +0 -1
  146. package/fesm2022/taiga-ui-legacy-pipes-to-country-code.mjs +0 -80
  147. package/fesm2022/taiga-ui-legacy-pipes-to-country-code.mjs.map +0 -1
  148. package/fesm2022/taiga-ui-legacy-pipes.mjs +0 -8
  149. package/fesm2022/taiga-ui-legacy-pipes.mjs.map +0 -1
  150. package/fesm2022/taiga-ui-legacy-services.mjs +0 -42
  151. package/fesm2022/taiga-ui-legacy-services.mjs.map +0 -1
  152. package/pipes/format-phone/format-phone.pipe.d.ts +0 -37
  153. package/pipes/format-phone/index.d.ts +0 -1
  154. package/pipes/index.d.ts +0 -3
  155. package/pipes/iso-to-country-code/index.d.ts +0 -1
  156. package/pipes/iso-to-country-code/iso-to-country-code.pipe.d.ts +0 -30
  157. package/pipes/to-country-code/index.d.ts +0 -1
  158. package/pipes/to-country-code/to-country-code.pipe.d.ts +0 -38
  159. package/services/index.d.ts +0 -1
  160. package/services/static-request.service.d.ts +0 -11
@@ -1,231 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { inject, Input, ViewChild, ChangeDetectionStrategy, Component, Directive, NgModule } from '@angular/core';
3
- import { TUI_FALSE_HANDLER } from '@taiga-ui/cdk/constants';
4
- import { TuiDay, tuiDateClamp, TuiMonth } from '@taiga-ui/cdk/date-time';
5
- import { TUI_IS_MOBILE } from '@taiga-ui/cdk/tokens';
6
- import { TuiMonthPipe } from '@taiga-ui/core/pipes/month';
7
- import { TUI_INPUT_DATE_OPTIONS } from '@taiga-ui/kit/tokens';
8
- import { AbstractTuiNullableControl, tuiAsControl, AbstractTuiTextfieldHost } from '@taiga-ui/legacy/classes';
9
- import * as i2 from '@taiga-ui/legacy/components/primitive-textfield';
10
- import { TuiPrimitiveTextfieldComponent, TuiTextfieldComponent, TuiPrimitiveTextfieldModule } from '@taiga-ui/legacy/components/primitive-textfield';
11
- import * as i3 from '@taiga-ui/legacy/directives';
12
- import { TUI_TEXTFIELD_SIZE, TuiTextfieldControllerModule, TuiLegacyDropdownOpenMonitorDirective } from '@taiga-ui/legacy/directives';
13
- import { TUI_MONTH_FORMATTER, tuiAsFocusableItemAccessor, TUI_MONTH_FORMATTER_PROVIDER, tuiAsTextfieldHost } from '@taiga-ui/legacy/tokens';
14
- import * as i1 from '@taiga-ui/kit/components/calendar-month';
15
- import { TuiCalendarMonth } from '@taiga-ui/kit/components/calendar-month';
16
- import * as i4 from '@angular/forms';
17
- import { FormsModule } from '@angular/forms';
18
- import * as i1$1 from '@taiga-ui/core/directives/dropdown';
19
- import { TuiDropdown } from '@taiga-ui/core/directives/dropdown';
20
- import * as i6 from '@angular/common';
21
- import { CommonModule } from '@angular/common';
22
- import * as i7 from '@taiga-ui/cdk/pipes/mapper';
23
- import { TuiMapperPipe } from '@taiga-ui/cdk/pipes/mapper';
24
- import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
25
- import { Subject, distinctUntilChanged, switchMap } from 'rxjs';
26
-
27
- /**
28
- * TODO(v5): delete it
29
- * @deprecated use new version of {@link https://taiga-ui.dev/components/input-month TuiInputMonth} (from @taiga-ui/kit) instead
30
- */
31
- class TuiInputMonthComponent extends AbstractTuiNullableControl {
32
- constructor() {
33
- super(...arguments);
34
- this.isMobile = inject(TUI_IS_MOBILE);
35
- this.options = inject(TUI_INPUT_DATE_OPTIONS);
36
- this.textfieldSize = inject(TUI_TEXTFIELD_SIZE);
37
- this.formatter = inject(TUI_MONTH_FORMATTER);
38
- this.min = this.options.min;
39
- this.max = this.options.max;
40
- this.disabledItemHandler = TUI_FALSE_HANDLER;
41
- this.defaultActiveYear = TuiDay.currentLocal();
42
- this.open = false;
43
- }
44
- get nativeFocusableElement() {
45
- return this.textfield?.nativeFocusableElement || null;
46
- }
47
- get focused() {
48
- return !!this.textfield?.focused;
49
- }
50
- onValueChange(value) {
51
- if (value) {
52
- return;
53
- }
54
- this.value = null;
55
- this.onOpenChange(!this.nativePicker);
56
- }
57
- onMonthClick(month) {
58
- this.value = month;
59
- this.close();
60
- }
61
- setDisabledState() {
62
- super.setDisabledState();
63
- this.close();
64
- }
65
- get size() {
66
- return this.textfieldSize.size;
67
- }
68
- get computedMin() {
69
- return this.min ?? this.options.min;
70
- }
71
- get computedMax() {
72
- return this.max ?? this.options.max;
73
- }
74
- get computedDefaultActiveYear() {
75
- return (this.activeYear ||
76
- this.value ||
77
- tuiDateClamp(this.defaultActiveYear, this.computedMin, this.computedMax));
78
- }
79
- get calendarIcon() {
80
- return this.options.icon;
81
- }
82
- get nativePicker() {
83
- return this.isMobile && this.options.nativePicker;
84
- }
85
- get nativePickerMin() {
86
- return this.computedMin.toJSON();
87
- }
88
- get nativePickerMax() {
89
- return this.computedMax.toJSON();
90
- }
91
- get nativeValue() {
92
- return this.value?.toJSON() || '';
93
- }
94
- onNativeChange(value) {
95
- const [year = 0, month = 0] = value.split('-').map(Number);
96
- this.value = value
97
- ? tuiDateClamp(new TuiMonth(year, month - 1), this.computedMin, this.computedMax)
98
- : null;
99
- }
100
- onFocused(focused) {
101
- this.updateFocused(focused);
102
- }
103
- onOpenChange(open) {
104
- if (open && this.value) {
105
- this.activeYear = this.value;
106
- }
107
- this.open = open;
108
- }
109
- close() {
110
- this.open = false;
111
- }
112
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiInputMonthComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
113
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiInputMonthComponent, isStandalone: false, selector: "tui-input-month", inputs: { min: "min", max: "max", disabledItemHandler: "disabledItemHandler", defaultActiveYear: "defaultActiveYear" }, host: { properties: { "attr.data-size": "size" } }, providers: [
114
- tuiAsFocusableItemAccessor(TuiInputMonthComponent),
115
- tuiAsControl(TuiInputMonthComponent),
116
- TUI_MONTH_FORMATTER_PROVIDER,
117
- TuiMonthPipe,
118
- ], viewQueries: [{ propertyName: "textfield", first: true, predicate: TuiPrimitiveTextfieldComponent, descendants: true }], usesInheritance: true, ngImport: i0, template: "<div\n tuiDropdownOpenMonitor\n class=\"t-hosted\"\n [tuiDropdown]=\"dropdown\"\n [tuiDropdownEnabled]=\"interactive && !nativePicker\"\n [tuiDropdownOpen]=\"open && interactive\"\n (tuiDropdownOpenChange)=\"onOpenChange($event)\"\n>\n <tui-primitive-textfield\n class=\"t-textfield\"\n [disabled]=\"computedDisabled\"\n [editable]=\"false\"\n [invalid]=\"computedInvalid\"\n [nativeId]=\"nativeId\"\n [pseudoFocus]=\"pseudoFocus\"\n [pseudoHover]=\"pseudoHover\"\n [readOnly]=\"readOnly\"\n [tuiTextfieldIcon]=\"calendarIcon\"\n [value]=\"(value | tuiMapper: formatter | async) || ''\"\n (focusedChange)=\"onFocused($event)\"\n (valueChange)=\"onValueChange($event)\"\n >\n <ng-content />\n <ng-content\n ngProjectAs=\"input\"\n select=\"input\"\n />\n @if (nativePicker) {\n <input\n type=\"month\"\n class=\"t-mobile\"\n [max]=\"nativePickerMax\"\n [min]=\"nativePickerMin\"\n [ngModel]=\"nativeValue\"\n [ngModelOptions]=\"{standalone: true}\"\n (click.stop.zoneless)=\"(0)\"\n (mousedown.stop.zoneless)=\"(0)\"\n (ngModelChange)=\"onNativeChange($event)\"\n />\n }\n </tui-primitive-textfield>\n\n <ng-template #dropdown>\n <tui-calendar-month\n [disabledItemHandler]=\"disabledItemHandler\"\n [max]=\"computedMax\"\n [min]=\"computedMin\"\n [value]=\"value\"\n [year]=\"computedDefaultActiveYear\"\n (monthClick)=\"onMonthClick($event)\"\n (mousedown.prevent.zoneless)=\"(0)\"\n (yearChange)=\"activeYear = $event\"\n />\n </ng-template>\n</div>\n", styles: [":host{display:block;border-radius:var(--tui-radius-m);text-align:start}:host :host-context(*:disabled){pointer-events:none}.t-hosted{display:block;border-radius:inherit}.t-textfield{border-radius:inherit;text-align:inherit}.t-mobile{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;opacity:0;border:0}\n"], dependencies: [{ kind: "component", type: i1.TuiCalendarMonth, selector: "tui-calendar-month", inputs: ["year", "disabledItemHandler", "minLength", "maxLength", "min", "max", "value"], outputs: ["monthClick", "hoveredItemChange", "yearChange"] }, { kind: "component", type: i2.TuiPrimitiveTextfieldComponent, selector: "tui-primitive-textfield", inputs: ["editable", "iconCleaner", "readOnly", "invalid", "disabled", "value"], outputs: ["valueChange"] }, { kind: "directive", type: i2.TuiPrimitiveTextfieldDirective, selector: "tui-primitive-textfield" }, { kind: "directive", type: i3.TuiTextfieldIconDirective, selector: "[tuiTextfieldIcon]", inputs: ["tuiTextfieldIcon"] }, { kind: "directive", type: i4.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i3.TuiLegacyDropdownOpenMonitorDirective, selector: "[tuiDropdownOpenMonitor]" }, { kind: "directive", type: i1$1.TuiDropdownDirective, selector: "[tuiDropdown]:not(ng-container):not(ng-template)", inputs: ["tuiDropdown"], exportAs: ["tuiDropdown"] }, { kind: "directive", type: i1$1.TuiDropdownOpen, selector: "[tuiDropdown][tuiDropdownOpen],[tuiDropdown][tuiDropdownOpenChange]", inputs: ["tuiDropdownEnabled", "tuiDropdownOpen"], outputs: ["tuiDropdownOpenChange"] }, { kind: "pipe", type: i6.AsyncPipe, name: "async" }, { kind: "pipe", type: i7.TuiMapperPipe, name: "tuiMapper" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
119
- }
120
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiInputMonthComponent, decorators: [{
121
- type: Component,
122
- args: [{ standalone: false, selector: 'tui-input-month', changeDetection: ChangeDetectionStrategy.OnPush, providers: [
123
- tuiAsFocusableItemAccessor(TuiInputMonthComponent),
124
- tuiAsControl(TuiInputMonthComponent),
125
- TUI_MONTH_FORMATTER_PROVIDER,
126
- TuiMonthPipe,
127
- ], host: {
128
- '[attr.data-size]': 'size',
129
- }, template: "<div\n tuiDropdownOpenMonitor\n class=\"t-hosted\"\n [tuiDropdown]=\"dropdown\"\n [tuiDropdownEnabled]=\"interactive && !nativePicker\"\n [tuiDropdownOpen]=\"open && interactive\"\n (tuiDropdownOpenChange)=\"onOpenChange($event)\"\n>\n <tui-primitive-textfield\n class=\"t-textfield\"\n [disabled]=\"computedDisabled\"\n [editable]=\"false\"\n [invalid]=\"computedInvalid\"\n [nativeId]=\"nativeId\"\n [pseudoFocus]=\"pseudoFocus\"\n [pseudoHover]=\"pseudoHover\"\n [readOnly]=\"readOnly\"\n [tuiTextfieldIcon]=\"calendarIcon\"\n [value]=\"(value | tuiMapper: formatter | async) || ''\"\n (focusedChange)=\"onFocused($event)\"\n (valueChange)=\"onValueChange($event)\"\n >\n <ng-content />\n <ng-content\n ngProjectAs=\"input\"\n select=\"input\"\n />\n @if (nativePicker) {\n <input\n type=\"month\"\n class=\"t-mobile\"\n [max]=\"nativePickerMax\"\n [min]=\"nativePickerMin\"\n [ngModel]=\"nativeValue\"\n [ngModelOptions]=\"{standalone: true}\"\n (click.stop.zoneless)=\"(0)\"\n (mousedown.stop.zoneless)=\"(0)\"\n (ngModelChange)=\"onNativeChange($event)\"\n />\n }\n </tui-primitive-textfield>\n\n <ng-template #dropdown>\n <tui-calendar-month\n [disabledItemHandler]=\"disabledItemHandler\"\n [max]=\"computedMax\"\n [min]=\"computedMin\"\n [value]=\"value\"\n [year]=\"computedDefaultActiveYear\"\n (monthClick)=\"onMonthClick($event)\"\n (mousedown.prevent.zoneless)=\"(0)\"\n (yearChange)=\"activeYear = $event\"\n />\n </ng-template>\n</div>\n", styles: [":host{display:block;border-radius:var(--tui-radius-m);text-align:start}:host :host-context(*:disabled){pointer-events:none}.t-hosted{display:block;border-radius:inherit}.t-textfield{border-radius:inherit;text-align:inherit}.t-mobile{position:absolute;top:0;left:0;inline-size:100%;block-size:100%;opacity:0;border:0}\n"] }]
130
- }], propDecorators: { textfield: [{
131
- type: ViewChild,
132
- args: [TuiPrimitiveTextfieldComponent]
133
- }], min: [{
134
- type: Input
135
- }], max: [{
136
- type: Input
137
- }], disabledItemHandler: [{
138
- type: Input
139
- }], defaultActiveYear: [{
140
- type: Input
141
- }] } });
142
-
143
- /**
144
- * TODO(v5): delete it
145
- * @deprecated use new version of {@link https://taiga-ui.dev/components/input-month TuiInputMonth} (from @taiga-ui/kit) instead
146
- */
147
- class TuiInputMonthDirective extends AbstractTuiTextfieldHost {
148
- constructor() {
149
- super(...arguments);
150
- this.value$ = new Subject();
151
- this.localizedValue = '';
152
- this.$ = this.value$
153
- .pipe(distinctUntilChanged(), switchMap(inject(TUI_MONTH_FORMATTER)), takeUntilDestroyed())
154
- .subscribe((localizedValue) => {
155
- this.localizedValue = localizedValue;
156
- });
157
- }
158
- get readOnly() {
159
- return true;
160
- }
161
- get value() {
162
- return this.localizedValue;
163
- }
164
- ngDoCheck() {
165
- this.value$.next(this.host.value);
166
- }
167
- onValueChange(value) {
168
- this.host.onValueChange(value);
169
- }
170
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiInputMonthDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
171
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.15", type: TuiInputMonthDirective, isStandalone: false, selector: "tui-input-month", providers: [tuiAsTextfieldHost(TuiInputMonthDirective)], usesInheritance: true, ngImport: i0 }); }
172
- }
173
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiInputMonthDirective, decorators: [{
174
- type: Directive,
175
- args: [{
176
- standalone: false,
177
- selector: 'tui-input-month',
178
- providers: [tuiAsTextfieldHost(TuiInputMonthDirective)],
179
- }]
180
- }] });
181
-
182
- /**
183
- * TODO(v5): delete it
184
- * @deprecated use new version of {@link https://taiga-ui.dev/components/input-month TuiInputMonth} (from @taiga-ui/kit) instead
185
- */
186
- class TuiInputMonthModule {
187
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiInputMonthModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
188
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.15", ngImport: i0, type: TuiInputMonthModule, declarations: [TuiInputMonthComponent, TuiInputMonthDirective], imports: [CommonModule,
189
- TuiCalendarMonth,
190
- TuiPrimitiveTextfieldModule,
191
- TuiMapperPipe,
192
- TuiTextfieldControllerModule,
193
- FormsModule,
194
- TuiLegacyDropdownOpenMonitorDirective, i1$1.TuiDropdownOptionsDirective, i1$1.TuiDropdownDriverDirective, i1$1.TuiDropdownDirective, i1$1.TuiDropdownComponent, i1$1.TuiDropdownOpen, i1$1.TuiDropdownOpenLegacy, i1$1.TuiDropdownPortal, i1$1.TuiDropdownManual, i1$1.TuiDropdownHover, i1$1.TuiDropdownContext, i1$1.TuiDropdownPosition, i1$1.TuiDropdownPositionSided, i1$1.TuiDropdownSelection], exports: [TuiInputMonthComponent,
195
- TuiInputMonthDirective,
196
- TuiTextfieldComponent, i1$1.TuiDropdownOptionsDirective, i1$1.TuiDropdownDriverDirective, i1$1.TuiDropdownDirective, i1$1.TuiDropdownComponent, i1$1.TuiDropdownOpen, i1$1.TuiDropdownOpenLegacy, i1$1.TuiDropdownPortal, i1$1.TuiDropdownManual, i1$1.TuiDropdownHover, i1$1.TuiDropdownContext, i1$1.TuiDropdownPosition, i1$1.TuiDropdownPositionSided, i1$1.TuiDropdownSelection] }); }
197
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiInputMonthModule, imports: [CommonModule,
198
- TuiCalendarMonth,
199
- TuiPrimitiveTextfieldModule,
200
- TuiTextfieldControllerModule,
201
- FormsModule, i1$1.TuiDropdownComponent] }); }
202
- }
203
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiInputMonthModule, decorators: [{
204
- type: NgModule,
205
- args: [{
206
- imports: [
207
- CommonModule,
208
- TuiCalendarMonth,
209
- TuiPrimitiveTextfieldModule,
210
- TuiMapperPipe,
211
- TuiTextfieldControllerModule,
212
- FormsModule,
213
- TuiLegacyDropdownOpenMonitorDirective,
214
- ...TuiDropdown,
215
- ],
216
- declarations: [TuiInputMonthComponent, TuiInputMonthDirective],
217
- exports: [
218
- TuiInputMonthComponent,
219
- TuiInputMonthDirective,
220
- TuiTextfieldComponent,
221
- ...TuiDropdown,
222
- ],
223
- }]
224
- }] });
225
-
226
- /**
227
- * Generated bundle index. Do not edit.
228
- */
229
-
230
- export { TuiInputMonthComponent, TuiInputMonthDirective, TuiInputMonthModule };
231
- //# sourceMappingURL=taiga-ui-legacy-components-input-month.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"taiga-ui-legacy-components-input-month.mjs","sources":["../../../projects/legacy/components/input-month/input-month.component.ts","../../../projects/legacy/components/input-month/input-month.template.html","../../../projects/legacy/components/input-month/input-month.directive.ts","../../../projects/legacy/components/input-month/input-month.module.ts","../../../projects/legacy/components/input-month/taiga-ui-legacy-components-input-month.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n inject,\n Input,\n ViewChild,\n} from '@angular/core';\nimport {TUI_FALSE_HANDLER} from '@taiga-ui/cdk/constants';\nimport {tuiDateClamp, TuiDay, TuiMonth, type TuiYear} from '@taiga-ui/cdk/date-time';\nimport {TUI_IS_MOBILE} from '@taiga-ui/cdk/tokens';\nimport {type TuiBooleanHandler} from '@taiga-ui/cdk/types';\nimport {TuiMonthPipe} from '@taiga-ui/core/pipes/month';\nimport {type TuiSizeL, type TuiSizeS} from '@taiga-ui/core/types';\nimport {TUI_INPUT_DATE_OPTIONS, type TuiInputDateOptions} from '@taiga-ui/kit/tokens';\nimport {AbstractTuiNullableControl, tuiAsControl} from '@taiga-ui/legacy/classes';\nimport {TuiPrimitiveTextfieldComponent} from '@taiga-ui/legacy/components/primitive-textfield';\nimport {TUI_TEXTFIELD_SIZE} from '@taiga-ui/legacy/directives';\nimport {\n TUI_MONTH_FORMATTER,\n TUI_MONTH_FORMATTER_PROVIDER,\n tuiAsFocusableItemAccessor,\n type TuiFocusableElementAccessor,\n} from '@taiga-ui/legacy/tokens';\n\n/**\n * TODO(v5): delete it\n * @deprecated use new version of {@link https://taiga-ui.dev/components/input-month TuiInputMonth} (from @taiga-ui/kit) instead\n */\n@Component({\n standalone: false,\n selector: 'tui-input-month',\n templateUrl: './input-month.template.html',\n styleUrls: ['./input-month.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n tuiAsFocusableItemAccessor(TuiInputMonthComponent),\n tuiAsControl(TuiInputMonthComponent),\n TUI_MONTH_FORMATTER_PROVIDER,\n TuiMonthPipe,\n ],\n host: {\n '[attr.data-size]': 'size',\n },\n})\nexport class TuiInputMonthComponent\n extends AbstractTuiNullableControl<TuiMonth>\n implements TuiFocusableElementAccessor\n{\n @ViewChild(TuiPrimitiveTextfieldComponent)\n private readonly textfield?: TuiPrimitiveTextfieldComponent;\n\n private readonly isMobile = inject(TUI_IS_MOBILE);\n private readonly options = inject(TUI_INPUT_DATE_OPTIONS);\n private readonly textfieldSize = inject(TUI_TEXTFIELD_SIZE);\n\n protected readonly formatter = inject(TUI_MONTH_FORMATTER);\n protected activeYear?: TuiYear;\n\n @Input()\n public min: TuiMonth | null = this.options.min;\n\n @Input()\n public max: TuiMonth | null = this.options.max;\n\n @Input()\n public disabledItemHandler: TuiBooleanHandler<TuiMonth> = TUI_FALSE_HANDLER;\n\n @Input()\n public defaultActiveYear: TuiYear = TuiDay.currentLocal();\n\n public open = false;\n\n public get nativeFocusableElement(): HTMLInputElement | null {\n return this.textfield?.nativeFocusableElement || null;\n }\n\n public get focused(): boolean {\n return !!this.textfield?.focused;\n }\n\n public onValueChange(value: string): void {\n if (value) {\n return;\n }\n\n this.value = null;\n this.onOpenChange(!this.nativePicker);\n }\n\n public onMonthClick(month: TuiMonth): void {\n this.value = month;\n this.close();\n }\n\n public override setDisabledState(): void {\n super.setDisabledState();\n this.close();\n }\n\n protected get size(): TuiSizeL | TuiSizeS {\n return this.textfieldSize.size;\n }\n\n protected get computedMin(): TuiMonth {\n return this.min ?? this.options.min;\n }\n\n protected get computedMax(): TuiMonth {\n return this.max ?? this.options.max;\n }\n\n protected get computedDefaultActiveYear(): TuiYear {\n return (\n this.activeYear ||\n this.value ||\n tuiDateClamp(this.defaultActiveYear, this.computedMin, this.computedMax)\n );\n }\n\n protected get calendarIcon(): TuiInputDateOptions['icon'] {\n return this.options.icon;\n }\n\n protected get nativePicker(): boolean {\n return this.isMobile && this.options.nativePicker;\n }\n\n protected get nativePickerMin(): string {\n return this.computedMin.toJSON();\n }\n\n protected get nativePickerMax(): string {\n return this.computedMax.toJSON();\n }\n\n protected get nativeValue(): string {\n return this.value?.toJSON() || '';\n }\n\n protected onNativeChange(value: string): void {\n const [year = 0, month = 0] = value.split('-').map(Number);\n\n this.value = value\n ? tuiDateClamp(\n new TuiMonth(year, month - 1),\n this.computedMin,\n this.computedMax,\n )\n : null;\n }\n\n protected onFocused(focused: boolean): void {\n this.updateFocused(focused);\n }\n\n protected onOpenChange(open: boolean): void {\n if (open && this.value) {\n this.activeYear = this.value;\n }\n\n this.open = open;\n }\n\n private close(): void {\n this.open = false;\n }\n}\n","<div\n tuiDropdownOpenMonitor\n class=\"t-hosted\"\n [tuiDropdown]=\"dropdown\"\n [tuiDropdownEnabled]=\"interactive && !nativePicker\"\n [tuiDropdownOpen]=\"open && interactive\"\n (tuiDropdownOpenChange)=\"onOpenChange($event)\"\n>\n <tui-primitive-textfield\n class=\"t-textfield\"\n [disabled]=\"computedDisabled\"\n [editable]=\"false\"\n [invalid]=\"computedInvalid\"\n [nativeId]=\"nativeId\"\n [pseudoFocus]=\"pseudoFocus\"\n [pseudoHover]=\"pseudoHover\"\n [readOnly]=\"readOnly\"\n [tuiTextfieldIcon]=\"calendarIcon\"\n [value]=\"(value | tuiMapper: formatter | async) || ''\"\n (focusedChange)=\"onFocused($event)\"\n (valueChange)=\"onValueChange($event)\"\n >\n <ng-content />\n <ng-content\n ngProjectAs=\"input\"\n select=\"input\"\n />\n @if (nativePicker) {\n <input\n type=\"month\"\n class=\"t-mobile\"\n [max]=\"nativePickerMax\"\n [min]=\"nativePickerMin\"\n [ngModel]=\"nativeValue\"\n [ngModelOptions]=\"{standalone: true}\"\n (click.stop.zoneless)=\"(0)\"\n (mousedown.stop.zoneless)=\"(0)\"\n (ngModelChange)=\"onNativeChange($event)\"\n />\n }\n </tui-primitive-textfield>\n\n <ng-template #dropdown>\n <tui-calendar-month\n [disabledItemHandler]=\"disabledItemHandler\"\n [max]=\"computedMax\"\n [min]=\"computedMin\"\n [value]=\"value\"\n [year]=\"computedDefaultActiveYear\"\n (monthClick)=\"onMonthClick($event)\"\n (mousedown.prevent.zoneless)=\"(0)\"\n (yearChange)=\"activeYear = $event\"\n />\n </ng-template>\n</div>\n","import {Directive, type DoCheck, inject} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {type TuiMonth} from '@taiga-ui/cdk/date-time';\nimport {AbstractTuiTextfieldHost} from '@taiga-ui/legacy/classes';\nimport {TUI_MONTH_FORMATTER, tuiAsTextfieldHost} from '@taiga-ui/legacy/tokens';\nimport {distinctUntilChanged, Subject, switchMap} from 'rxjs';\n\nimport {type TuiInputMonthComponent} from './input-month.component';\n\n/**\n * TODO(v5): delete it\n * @deprecated use new version of {@link https://taiga-ui.dev/components/input-month TuiInputMonth} (from @taiga-ui/kit) instead\n */\n@Directive({\n standalone: false,\n selector: 'tui-input-month',\n providers: [tuiAsTextfieldHost(TuiInputMonthDirective)],\n})\nexport class TuiInputMonthDirective\n extends AbstractTuiTextfieldHost<TuiInputMonthComponent>\n implements DoCheck\n{\n private readonly value$ = new Subject<TuiMonth | null>();\n\n private localizedValue = '';\n\n protected readonly $ = this.value$\n .pipe(\n distinctUntilChanged(),\n switchMap(inject(TUI_MONTH_FORMATTER)),\n takeUntilDestroyed(),\n )\n .subscribe((localizedValue) => {\n this.localizedValue = localizedValue;\n });\n\n public override get readOnly(): boolean {\n return true;\n }\n\n public override get value(): string {\n return this.localizedValue;\n }\n\n public ngDoCheck(): void {\n this.value$.next(this.host.value);\n }\n\n public onValueChange(value: string): void {\n this.host.onValueChange(value);\n }\n}\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {FormsModule} from '@angular/forms';\nimport {TuiMapperPipe} from '@taiga-ui/cdk/pipes/mapper';\nimport {TuiDropdown} from '@taiga-ui/core/directives/dropdown';\nimport {TuiCalendarMonth} from '@taiga-ui/kit/components/calendar-month';\nimport {\n TuiPrimitiveTextfieldModule,\n TuiTextfieldComponent,\n} from '@taiga-ui/legacy/components/primitive-textfield';\nimport {\n TuiLegacyDropdownOpenMonitorDirective,\n TuiTextfieldControllerModule,\n} from '@taiga-ui/legacy/directives';\n\nimport {TuiInputMonthComponent} from './input-month.component';\nimport {TuiInputMonthDirective} from './input-month.directive';\n\n/**\n * TODO(v5): delete it\n * @deprecated use new version of {@link https://taiga-ui.dev/components/input-month TuiInputMonth} (from @taiga-ui/kit) instead\n */\n@NgModule({\n imports: [\n CommonModule,\n TuiCalendarMonth,\n TuiPrimitiveTextfieldModule,\n TuiMapperPipe,\n TuiTextfieldControllerModule,\n FormsModule,\n TuiLegacyDropdownOpenMonitorDirective,\n ...TuiDropdown,\n ],\n declarations: [TuiInputMonthComponent, TuiInputMonthDirective],\n exports: [\n TuiInputMonthComponent,\n TuiInputMonthDirective,\n TuiTextfieldComponent,\n ...TuiDropdown,\n ],\n})\nexport class TuiInputMonthModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i5","i1"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAwBA;;;AAGG;AAiBG,MAAO,sBACT,SAAQ,0BAAoC,CAAA;AAjBhD,IAAA,WAAA,GAAA;;AAuBqB,QAAA,IAAA,CAAA,QAAQ,GAAG,MAAM,CAAC,aAAa,CAAC;AAChC,QAAA,IAAA,C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,WAAW;wBACX,qCAAqC;AACrC,wBAAA,GAAG,WAAW;AACjB,qBAAA;AACD,oBAAA,YAAY,EAAE,CAAC,sBAAsB,EAAE,sBAAsB,CAAC;AAC9D,oBAAA,OAAO,EAAE;wBACL,sBAAsB;wBACtB,sBAAsB;wBACtB,qBAAqB;AACrB,wBAAA,GAAG,WAAW;AACjB,qBAAA;AACJ,iBAAA;;;ACxCD;;AAEG;;;;"}
@@ -1,215 +0,0 @@
1
- import { __decorate } from 'tslib';
2
- import * as i2 from '@angular/common';
3
- import { CommonModule } from '@angular/common';
4
- import * as i0 from '@angular/core';
5
- import { InjectionToken, inject, EventEmitter, Input, Output, ViewChild, ChangeDetectionStrategy, Component } from '@angular/core';
6
- import * as i3 from '@angular/forms';
7
- import { FormsModule } from '@angular/forms';
8
- import { TUI_NON_DIGITS_REGEXP, CHAR_PLUS } from '@taiga-ui/cdk/constants';
9
- import { tuiProvideOptions, tuiPure } from '@taiga-ui/cdk/utils/miscellaneous';
10
- import * as i4 from '@taiga-ui/core/components/data-list';
11
- import { TuiDataList } from '@taiga-ui/core/components/data-list';
12
- import { TuiAppearance } from '@taiga-ui/core/directives/appearance';
13
- import * as i1 from '@taiga-ui/core/directives/dropdown';
14
- import { TuiDropdownFixed, TuiDropdown } from '@taiga-ui/core/directives/dropdown';
15
- import { TuiGroup } from '@taiga-ui/core/directives/group';
16
- import * as i5 from '@taiga-ui/core/directives/hint';
17
- import { TuiHint } from '@taiga-ui/core/directives/hint';
18
- import { TuiFlagPipe } from '@taiga-ui/core/pipes/flag';
19
- import { TUI_COUNTRIES } from '@taiga-ui/kit/tokens';
20
- import { AbstractTuiControl, tuiAsControl } from '@taiga-ui/legacy/classes';
21
- import { TUI_ARROW } from '@taiga-ui/legacy/components/arrow';
22
- import * as i6 from '@taiga-ui/legacy/components/input-phone';
23
- import { TuiInputPhoneModule, TuiInputPhoneComponent } from '@taiga-ui/legacy/components/input-phone';
24
- import * as i7 from '@taiga-ui/legacy/components/primitive-textfield';
25
- import { TuiPrimitiveTextfieldModule, TuiPrimitiveTextfieldComponent } from '@taiga-ui/legacy/components/primitive-textfield';
26
- import * as i8 from '@taiga-ui/legacy/directives';
27
- import { TUI_TEXTFIELD_SIZE, TuiLegacyDropdownOpenMonitorDirective, TuiTextfieldControllerModule } from '@taiga-ui/legacy/directives';
28
- import { TuiToCountryCodePipe, TuiIsoToCountryCodePipe } from '@taiga-ui/legacy/pipes';
29
- import { TUI_COUNTRIES_MASKS, tuiAsFocusableItemAccessor } from '@taiga-ui/legacy/tokens';
30
- import { tuiIsoToCountryCode, tuiGetMaxAllowedPhoneLength } from '@taiga-ui/legacy/utils';
31
- import { PolymorpheusOutlet } from '@taiga-ui/polymorpheus';
32
- import { tuiGetClipboardDataText } from '@taiga-ui/cdk/utils/dom';
33
-
34
- /**
35
- * @deprecated: drop in v5.0 use {@link TuiInputPhoneInternational}
36
- * https://taiga-ui.dev/components/input-phone-international
37
- */
38
- const TUI_INPUT_PHONE_INTERNATIONAL_DEFAULT_OPTIONS = {
39
- countries: [],
40
- countryIsoCode: 'RU',
41
- };
42
- /**
43
- * @deprecated: drop in v5.0 use {@link TuiInputPhoneInternational}
44
- * https://taiga-ui.dev/components/input-phone-international
45
- */
46
- const TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS = new InjectionToken(ngDevMode ? 'TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS' : '', {
47
- factory: () => TUI_INPUT_PHONE_INTERNATIONAL_DEFAULT_OPTIONS,
48
- });
49
- /**
50
- * @deprecated: drop in v5.0 use {@link TuiInputPhoneInternational}
51
- * https://taiga-ui.dev/components/input-phone-international
52
- */
53
- function tuiInputPhoneInternationalOptionsProvider(options) {
54
- return tuiProvideOptions(TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS, options, TUI_INPUT_PHONE_INTERNATIONAL_DEFAULT_OPTIONS);
55
- }
56
-
57
- /**
58
- * @deprecated: drop in v5.0
59
- */
60
- function tuiExtractValueFromEvent(event) {
61
- return 'dataTransfer' in event
62
- ? event.dataTransfer?.getData('text/plain') || ''
63
- : tuiGetClipboardDataText(event);
64
- }
65
-
66
- const MASK_SYMBOLS = /[ \-_()]/g;
67
- /**
68
- * @deprecated: drop in v5.0 use {@link TuiInputPhoneInternational}
69
- * https://taiga-ui.dev/components/input-phone-international
70
- */
71
- class TuiInputPhoneInternationalComponent extends AbstractTuiControl {
72
- constructor() {
73
- super(...arguments);
74
- this.options = inject(TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS);
75
- this.extractCountryCodePipe = inject(TuiToCountryCodePipe);
76
- this.textfieldSize = inject(TUI_TEXTFIELD_SIZE);
77
- this.open = false;
78
- this.countriesNames$ = inject(TUI_COUNTRIES);
79
- this.countriesMasks = inject(TUI_COUNTRIES_MASKS);
80
- this.arrow = TUI_ARROW;
81
- this.countries = this.options.countries;
82
- this.countryIsoCodeChange = new EventEmitter();
83
- this.countryIsoCode = this.options.countryIsoCode;
84
- }
85
- set isoCode(code) {
86
- if (this.countryIsoCode === code) {
87
- return;
88
- }
89
- this.inputPhoneComponent?.writeValue(this.value);
90
- this.countryIsoCode = code;
91
- }
92
- get nativeFocusableElement() {
93
- return this.inputPhoneComponent && !this.computedDisabled
94
- ? this.inputPhoneComponent.nativeFocusableElement
95
- : null;
96
- }
97
- get focused() {
98
- return ((!!this.primitiveTextfield && this.primitiveTextfield.focused) ||
99
- (!!this.inputPhoneComponent && this.inputPhoneComponent.focused));
100
- }
101
- get inputPhoneCountryCode() {
102
- return tuiIsoToCountryCode(this.countriesMasks, this.countryIsoCode);
103
- }
104
- get phoneMaskAfterCountryCode() {
105
- const countryCode = this.inputPhoneCountryCode;
106
- return this.calculateMaskAfterCountryCode(this.countriesMasks[this.countryIsoCode], countryCode);
107
- }
108
- onPaste(event) {
109
- let value = tuiExtractValueFromEvent(event).replace(TUI_NON_DIGITS_REGEXP, '');
110
- const countryIsoCode = this.extractCountryCodePipe.transform(value, this.countries);
111
- if (!countryIsoCode) {
112
- this.value = `${this.inputPhoneCountryCode}${value}`
113
- .replaceAll(MASK_SYMBOLS, '')
114
- .slice(0, tuiGetMaxAllowedPhoneLength(this.countriesMasks, this.countryIsoCode));
115
- return;
116
- }
117
- if (countryIsoCode === 'RU') {
118
- value = value.replace(/^8/, '7');
119
- }
120
- this.updateCountryIsoCode(countryIsoCode);
121
- this.value = `${CHAR_PLUS}${value}`;
122
- }
123
- onItemClick(isoCode) {
124
- this.open = false;
125
- this.updateCountryIsoCode(isoCode);
126
- // recalculates mask inside inputPhone to prevent isoCode conflict
127
- this.cdr.detectChanges();
128
- const maxLength = tuiGetMaxAllowedPhoneLength(this.countriesMasks, isoCode);
129
- if (this.value.length > maxLength) {
130
- this.value = this.value.slice(0, maxLength);
131
- }
132
- if (this.nativeFocusableElement) {
133
- this.nativeFocusableElement.focus();
134
- }
135
- }
136
- setDisabledState() {
137
- super.setDisabledState();
138
- this.close();
139
- }
140
- get size() {
141
- return this.textfieldSize.size;
142
- }
143
- onActiveZone(active) {
144
- this.updateFocused(active);
145
- }
146
- getFallbackValue() {
147
- return '';
148
- }
149
- calculateMaskAfterCountryCode(mask, countryCode) {
150
- return mask.replace(countryCode, '').trim();
151
- }
152
- close() {
153
- this.open = false;
154
- }
155
- updateCountryIsoCode(code) {
156
- this.countryIsoCode = code;
157
- this.countryIsoCodeChange.emit(code);
158
- }
159
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiInputPhoneInternationalComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
160
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiInputPhoneInternationalComponent, isStandalone: true, selector: "tui-input-phone-international", inputs: { countries: "countries", isoCode: ["countryIsoCode", "isoCode"] }, outputs: { countryIsoCodeChange: "countryIsoCodeChange" }, host: { listeners: { "paste.capture.prevent.stop": "onPaste($event)", "drop.capture.prevent.stop": "onPaste($event)" }, properties: { "attr.data-size": "size" } }, providers: [
161
- tuiAsFocusableItemAccessor(TuiInputPhoneInternationalComponent),
162
- tuiAsControl(TuiInputPhoneInternationalComponent),
163
- TuiToCountryCodePipe,
164
- ], viewQueries: [{ propertyName: "inputPhoneComponent", first: true, predicate: TuiInputPhoneComponent, descendants: true }, { propertyName: "primitiveTextfield", first: true, predicate: TuiPrimitiveTextfieldComponent, descendants: true }], usesInheritance: true, hostDirectives: [{ directive: i1.TuiDropdownFixed }], ngImport: i0, template: "@if (countriesNames$ | async; as countriesNames) {\n <div\n tuiDropdownOpenMonitor\n [tuiDropdown]=\"dropdown\"\n [tuiDropdownEnabled]=\"!readOnly\"\n [(tuiDropdownOpen)]=\"open\"\n (tuiActiveZoneChange)=\"onActiveZone($event)\"\n >\n <div tuiGroup>\n <tui-primitive-textfield\n tuiHintContent=\"\"\n tuiTextfieldPostfix=\"\"\n tuiTextfieldPrefix=\"\"\n class=\"t-country-select\"\n [disabled]=\"disabled\"\n [editable]=\"false\"\n [focusable]=\"focusable\"\n [pseudoFocus]=\"open || null\"\n [readOnly]=\"readOnly\"\n [style.flex]=\"'0 0 auto'\"\n [tuiTextfieldCustomContent]=\"countryValueContent\"\n [tuiTextfieldIcon]=\"icon\"\n [tuiTextfieldLabelOutside]=\"true\"\n />\n <tui-input-phone\n class=\"t-input-phone\"\n [countryCode]=\"inputPhoneCountryCode\"\n [disabled]=\"disabled\"\n [focusable]=\"focusable\"\n [ngModelOptions]=\"{standalone: true}\"\n [phoneMaskAfterCountryCode]=\"phoneMaskAfterCountryCode\"\n [pseudoFocus]=\"pseudoFocus\"\n [pseudoHover]=\"pseudoHover\"\n [pseudoInvalid]=\"computedInvalid\"\n [readOnly]=\"readOnly\"\n [style.flex]=\"'0 0 auto'\"\n [(ngModel)]=\"value\"\n >\n <ng-content />\n <input\n autocomplete=\"new-password\"\n tuiTextfieldLegacy\n />\n </tui-input-phone>\n </div>\n <ng-template #dropdown>\n <tui-data-list>\n @for (item of countries; track item) {\n <button\n tuiOption\n type=\"button\"\n (click)=\"onItemClick(item)\"\n >\n <img\n alt=\"\"\n class=\"t-flag\"\n [src]=\"item | tuiFlag\"\n />\n <span class=\"t-country-item-name\">\n {{ countriesNames[item] }}\n </span>\n <span class=\"t-country-item-code\">\n {{ item | tuiIsoToCountryCode }}\n </span>\n </button>\n }\n </tui-data-list>\n </ng-template>\n <ng-template #countryValueContent>\n <img\n class=\"t-flag t-flag_select\"\n [alt]=\"countriesNames[countryIsoCode]\"\n [src]=\"countryIsoCode | tuiFlag\"\n />\n </ng-template>\n <ng-template #icon>\n <div tuiAppearance=\"icon\">\n <ng-container *polymorpheusOutlet=\"arrow\" />\n </div>\n </ng-template>\n </div>\n}\n", styles: [":host{display:block}:host._disabled,:host :host-context(*:disabled){pointer-events:none}.t-country-select{inline-size:5.625rem}.t-country-select:not(._readonly) ::ng-deep input:not(:disabled){cursor:pointer}.t-country-select._readonly ::ng-deep input{cursor:default}.t-country-select[data-size=m]{inline-size:5.5rem}.t-country-select[data-size=s]{inline-size:2rem}.t-country-select[data-size=s] .t-flag{margin-inline-start:-1rem}.t-input-phone{flex:1}.t-flag{inline-size:1.75rem;block-size:1.75rem;border-radius:50%}.t-flag_select{margin-inline-start:-.5rem}.t-country-item-name{margin-inline-start:.75rem;margin-inline-end:auto}.t-country-item-code{color:var(--tui-text-secondary);margin-inline-end:.25rem}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiAppearance, selector: "[tuiAppearance]", inputs: ["tuiAppearance", "tuiAppearanceState", "tuiAppearanceFocus", "tuiAppearanceMode"] }, { kind: "component", type: i4.TuiDataListComponent, selector: "tui-data-list", inputs: ["emptyContent", "size"] }, { kind: "component", type: i4.TuiOption, selector: "button[tuiOption]:not([new]), a[tuiOption]:not([new]), label[tuiOption]:not([new])", inputs: ["disabled", "value"] }, { kind: "directive", type: i1.TuiDropdownDirective, selector: "[tuiDropdown]:not(ng-container):not(ng-template)", inputs: ["tuiDropdown"], exportAs: ["tuiDropdown"] }, { kind: "directive", type: i1.TuiDropdownOpen, selector: "[tuiDropdown][tuiDropdownOpen],[tuiDropdown][tuiDropdownOpenChange]", inputs: ["tuiDropdownEnabled", "tuiDropdownOpen"], outputs: ["tuiDropdownOpenChange"] }, { kind: "pipe", type: TuiFlagPipe, name: "tuiFlag" }, { kind: "directive", type: TuiGroup, selector: "[tuiGroup]:not(ng-container)", inputs: ["orientation", "collapsed", "rounded", "size"] }, { kind: "directive", type: i5.TuiHintOptionsDirective, selector: "[tuiHintContent]", inputs: ["tuiHintContent", "tuiHintDirection", "tuiHintAppearance", "tuiHintShowDelay", "tuiHintHideDelay"] }, { kind: "ngmodule", type: TuiInputPhoneModule }, { kind: "component", type: i6.TuiInputPhoneComponent, selector: "tui-input-phone", inputs: ["phoneMaskAfterCountryCode", "allowText", "search", "countryCode"], outputs: ["searchChange"] }, { kind: "directive", type: i6.TuiInputPhoneDirective, selector: "tui-input-phone" }, { kind: "component", type: i7.TuiTextfieldComponent, selector: "input[tuiTextfieldLegacy], textarea[tuiTextfieldLegacy]" }, { kind: "pipe", type: TuiIsoToCountryCodePipe, name: "tuiIsoToCountryCode" }, { kind: "directive", type: TuiLegacyDropdownOpenMonitorDirective, selector: "[tuiDropdownOpenMonitor]" }, { kind: "ngmodule", type: TuiPrimitiveTextfieldModule }, { kind: "component", type: i7.TuiPrimitiveTextfieldComponent, selector: "tui-primitive-textfield", inputs: ["editable", "iconCleaner", "readOnly", "invalid", "disabled", "value"], outputs: ["valueChange"] }, { kind: "directive", type: i7.TuiPrimitiveTextfieldDirective, selector: "tui-primitive-textfield" }, { kind: "ngmodule", type: TuiTextfieldControllerModule }, { kind: "directive", type: i8.TuiTextfieldCustomContentDirective, selector: "[tuiTextfieldCustomContent]", inputs: ["tuiTextfieldCustomContent"] }, { kind: "directive", type: i8.TuiTextfieldLabelOutsideDirective, selector: "[tuiTextfieldLabelOutside]", inputs: ["tuiTextfieldLabelOutside"] }, { kind: "directive", type: i8.TuiTextfieldIconDirective, selector: "[tuiTextfieldIcon]", inputs: ["tuiTextfieldIcon"] }, { kind: "directive", type: i8.TuiTextfieldPrefixDirective, selector: "[tuiTextfieldPrefix]", inputs: ["tuiTextfieldPrefix"] }, { kind: "directive", type: i8.TuiTextfieldPostfixDirective, selector: "[tuiTextfieldPostfix]", inputs: ["tuiTextfieldPostfix"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
165
- }
166
- __decorate([
167
- tuiPure
168
- ], TuiInputPhoneInternationalComponent.prototype, "calculateMaskAfterCountryCode", null);
169
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiInputPhoneInternationalComponent, decorators: [{
170
- type: Component,
171
- args: [{ selector: 'tui-input-phone-international', imports: [
172
- CommonModule,
173
- FormsModule,
174
- PolymorpheusOutlet,
175
- TuiAppearance,
176
- TuiDataList,
177
- TuiDropdown,
178
- TuiFlagPipe,
179
- TuiGroup,
180
- TuiHint,
181
- TuiInputPhoneModule,
182
- TuiIsoToCountryCodePipe,
183
- TuiLegacyDropdownOpenMonitorDirective,
184
- TuiPrimitiveTextfieldModule,
185
- TuiTextfieldControllerModule,
186
- ], changeDetection: ChangeDetectionStrategy.OnPush, providers: [
187
- tuiAsFocusableItemAccessor(TuiInputPhoneInternationalComponent),
188
- tuiAsControl(TuiInputPhoneInternationalComponent),
189
- TuiToCountryCodePipe,
190
- ], hostDirectives: [TuiDropdownFixed], host: {
191
- '[attr.data-size]': 'size',
192
- '(paste.capture.prevent.stop)': 'onPaste($event)',
193
- '(drop.capture.prevent.stop)': 'onPaste($event)',
194
- }, template: "@if (countriesNames$ | async; as countriesNames) {\n <div\n tuiDropdownOpenMonitor\n [tuiDropdown]=\"dropdown\"\n [tuiDropdownEnabled]=\"!readOnly\"\n [(tuiDropdownOpen)]=\"open\"\n (tuiActiveZoneChange)=\"onActiveZone($event)\"\n >\n <div tuiGroup>\n <tui-primitive-textfield\n tuiHintContent=\"\"\n tuiTextfieldPostfix=\"\"\n tuiTextfieldPrefix=\"\"\n class=\"t-country-select\"\n [disabled]=\"disabled\"\n [editable]=\"false\"\n [focusable]=\"focusable\"\n [pseudoFocus]=\"open || null\"\n [readOnly]=\"readOnly\"\n [style.flex]=\"'0 0 auto'\"\n [tuiTextfieldCustomContent]=\"countryValueContent\"\n [tuiTextfieldIcon]=\"icon\"\n [tuiTextfieldLabelOutside]=\"true\"\n />\n <tui-input-phone\n class=\"t-input-phone\"\n [countryCode]=\"inputPhoneCountryCode\"\n [disabled]=\"disabled\"\n [focusable]=\"focusable\"\n [ngModelOptions]=\"{standalone: true}\"\n [phoneMaskAfterCountryCode]=\"phoneMaskAfterCountryCode\"\n [pseudoFocus]=\"pseudoFocus\"\n [pseudoHover]=\"pseudoHover\"\n [pseudoInvalid]=\"computedInvalid\"\n [readOnly]=\"readOnly\"\n [style.flex]=\"'0 0 auto'\"\n [(ngModel)]=\"value\"\n >\n <ng-content />\n <input\n autocomplete=\"new-password\"\n tuiTextfieldLegacy\n />\n </tui-input-phone>\n </div>\n <ng-template #dropdown>\n <tui-data-list>\n @for (item of countries; track item) {\n <button\n tuiOption\n type=\"button\"\n (click)=\"onItemClick(item)\"\n >\n <img\n alt=\"\"\n class=\"t-flag\"\n [src]=\"item | tuiFlag\"\n />\n <span class=\"t-country-item-name\">\n {{ countriesNames[item] }}\n </span>\n <span class=\"t-country-item-code\">\n {{ item | tuiIsoToCountryCode }}\n </span>\n </button>\n }\n </tui-data-list>\n </ng-template>\n <ng-template #countryValueContent>\n <img\n class=\"t-flag t-flag_select\"\n [alt]=\"countriesNames[countryIsoCode]\"\n [src]=\"countryIsoCode | tuiFlag\"\n />\n </ng-template>\n <ng-template #icon>\n <div tuiAppearance=\"icon\">\n <ng-container *polymorpheusOutlet=\"arrow\" />\n </div>\n </ng-template>\n </div>\n}\n", styles: [":host{display:block}:host._disabled,:host :host-context(*:disabled){pointer-events:none}.t-country-select{inline-size:5.625rem}.t-country-select:not(._readonly) ::ng-deep input:not(:disabled){cursor:pointer}.t-country-select._readonly ::ng-deep input{cursor:default}.t-country-select[data-size=m]{inline-size:5.5rem}.t-country-select[data-size=s]{inline-size:2rem}.t-country-select[data-size=s] .t-flag{margin-inline-start:-1rem}.t-input-phone{flex:1}.t-flag{inline-size:1.75rem;block-size:1.75rem;border-radius:50%}.t-flag_select{margin-inline-start:-.5rem}.t-country-item-name{margin-inline-start:.75rem;margin-inline-end:auto}.t-country-item-code{color:var(--tui-text-secondary);margin-inline-end:.25rem}\n"] }]
195
- }], propDecorators: { inputPhoneComponent: [{
196
- type: ViewChild,
197
- args: [TuiInputPhoneComponent]
198
- }], primitiveTextfield: [{
199
- type: ViewChild,
200
- args: [TuiPrimitiveTextfieldComponent]
201
- }], countries: [{
202
- type: Input
203
- }], countryIsoCodeChange: [{
204
- type: Output
205
- }], isoCode: [{
206
- type: Input,
207
- args: ['countryIsoCode']
208
- }], calculateMaskAfterCountryCode: [] } });
209
-
210
- /**
211
- * Generated bundle index. Do not edit.
212
- */
213
-
214
- export { TUI_INPUT_PHONE_INTERNATIONAL_DEFAULT_OPTIONS, TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS, TuiInputPhoneInternationalComponent, tuiExtractValueFromEvent, tuiInputPhoneInternationalOptionsProvider };
215
- //# sourceMappingURL=taiga-ui-legacy-components-input-phone-international.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"taiga-ui-legacy-components-input-phone-international.mjs","sources":["../../../projects/legacy/components/input-phone-international/input-phone-international.options.ts","../../../projects/legacy/components/input-phone-international/utils/extract-value-from-event.ts","../../../projects/legacy/components/input-phone-international/input-phone-international.component.ts","../../../projects/legacy/components/input-phone-international/input-phone-international.template.html","../../../projects/legacy/components/input-phone-international/taiga-ui-legacy-components-input-phone-international.ts"],"sourcesContent":["import {InjectionToken, type Provider} from '@angular/core';\nimport {tuiProvideOptions} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {type TuiCountryIsoCode} from '@taiga-ui/i18n/types';\n\n/**\n * @deprecated: drop in v5.0 use {@link TuiInputPhoneInternational}\n * https://taiga-ui.dev/components/input-phone-international\n */\nexport interface TuiInputPhoneInternationalOptions {\n readonly countries: readonly TuiCountryIsoCode[];\n readonly countryIsoCode: TuiCountryIsoCode;\n}\n\n/**\n * @deprecated: drop in v5.0 use {@link TuiInputPhoneInternational}\n * https://taiga-ui.dev/components/input-phone-international\n */\nexport const TUI_INPUT_PHONE_INTERNATIONAL_DEFAULT_OPTIONS: TuiInputPhoneInternationalOptions =\n {\n countries: [],\n countryIsoCode: 'RU',\n };\n\n/**\n * @deprecated: drop in v5.0 use {@link TuiInputPhoneInternational}\n * https://taiga-ui.dev/components/input-phone-international\n */\nexport const TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS = new InjectionToken(\n ngDevMode ? 'TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS' : '',\n {\n factory: () => TUI_INPUT_PHONE_INTERNATIONAL_DEFAULT_OPTIONS,\n },\n);\n\n/**\n * @deprecated: drop in v5.0 use {@link TuiInputPhoneInternational}\n * https://taiga-ui.dev/components/input-phone-international\n */\nexport function tuiInputPhoneInternationalOptionsProvider(\n options: Partial<TuiInputPhoneInternationalOptions>,\n): Provider {\n return tuiProvideOptions(\n TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS,\n options,\n TUI_INPUT_PHONE_INTERNATIONAL_DEFAULT_OPTIONS,\n );\n}\n","import {tuiGetClipboardDataText} from '@taiga-ui/cdk/utils/dom';\n\n/**\n * @deprecated: drop in v5.0\n */\nexport function tuiExtractValueFromEvent(event: ClipboardEvent | DragEvent): string {\n return 'dataTransfer' in event\n ? event.dataTransfer?.getData('text/plain') || ''\n : tuiGetClipboardDataText(event);\n}\n","import {CommonModule} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n inject,\n Input,\n Output,\n ViewChild,\n} from '@angular/core';\nimport {FormsModule} from '@angular/forms';\nimport {CHAR_PLUS, TUI_NON_DIGITS_REGEXP} from '@taiga-ui/cdk/constants';\nimport {type TuiContext} from '@taiga-ui/cdk/types';\nimport {tuiPure} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TuiDataList} from '@taiga-ui/core/components/data-list';\nimport {TuiAppearance} from '@taiga-ui/core/directives/appearance';\nimport {TuiDropdown, TuiDropdownFixed} from '@taiga-ui/core/directives/dropdown';\nimport {TuiGroup} from '@taiga-ui/core/directives/group';\nimport {TuiHint} from '@taiga-ui/core/directives/hint';\nimport {TuiFlagPipe} from '@taiga-ui/core/pipes/flag';\nimport {type TuiSizeL, type TuiSizeM, type TuiSizeS} from '@taiga-ui/core/types';\nimport {type TuiCountryIsoCode} from '@taiga-ui/i18n/types';\nimport {TUI_COUNTRIES} from '@taiga-ui/kit/tokens';\nimport {AbstractTuiControl, tuiAsControl} from '@taiga-ui/legacy/classes';\nimport {TUI_ARROW} from '@taiga-ui/legacy/components/arrow';\nimport {\n TuiInputPhoneComponent,\n TuiInputPhoneModule,\n} from '@taiga-ui/legacy/components/input-phone';\nimport {\n TuiPrimitiveTextfieldComponent,\n TuiPrimitiveTextfieldModule,\n} from '@taiga-ui/legacy/components/primitive-textfield';\nimport {\n TUI_TEXTFIELD_SIZE,\n TuiLegacyDropdownOpenMonitorDirective,\n TuiTextfieldControllerModule,\n} from '@taiga-ui/legacy/directives';\nimport {TuiIsoToCountryCodePipe, TuiToCountryCodePipe} from '@taiga-ui/legacy/pipes';\nimport {\n TUI_COUNTRIES_MASKS,\n tuiAsFocusableItemAccessor,\n type TuiFocusableElementAccessor,\n} from '@taiga-ui/legacy/tokens';\nimport {tuiGetMaxAllowedPhoneLength, tuiIsoToCountryCode} from '@taiga-ui/legacy/utils';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nimport {TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS} from './input-phone-international.options';\nimport {tuiExtractValueFromEvent} from './utils/extract-value-from-event';\n\nconst MASK_SYMBOLS = /[ \\-_()]/g;\n\n/**\n * @deprecated: drop in v5.0 use {@link TuiInputPhoneInternational}\n * https://taiga-ui.dev/components/input-phone-international\n */\n@Component({\n selector: 'tui-input-phone-international',\n imports: [\n CommonModule,\n FormsModule,\n PolymorpheusOutlet,\n TuiAppearance,\n TuiDataList,\n TuiDropdown,\n TuiFlagPipe,\n TuiGroup,\n TuiHint,\n TuiInputPhoneModule,\n TuiIsoToCountryCodePipe,\n TuiLegacyDropdownOpenMonitorDirective,\n TuiPrimitiveTextfieldModule,\n TuiTextfieldControllerModule,\n ],\n templateUrl: './input-phone-international.template.html',\n styleUrls: ['./input-phone-international.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n tuiAsFocusableItemAccessor(TuiInputPhoneInternationalComponent),\n tuiAsControl(TuiInputPhoneInternationalComponent),\n TuiToCountryCodePipe,\n ],\n hostDirectives: [TuiDropdownFixed],\n host: {\n '[attr.data-size]': 'size',\n '(paste.capture.prevent.stop)': 'onPaste($event)',\n '(drop.capture.prevent.stop)': 'onPaste($event)',\n },\n})\nexport class TuiInputPhoneInternationalComponent\n extends AbstractTuiControl<string>\n implements TuiFocusableElementAccessor\n{\n @ViewChild(TuiInputPhoneComponent)\n private readonly inputPhoneComponent?: TuiInputPhoneComponent;\n\n @ViewChild(TuiPrimitiveTextfieldComponent)\n private readonly primitiveTextfield?: TuiPrimitiveTextfieldComponent;\n\n private readonly options = inject(TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS);\n private readonly extractCountryCodePipe = inject(TuiToCountryCodePipe);\n private readonly textfieldSize = inject(TUI_TEXTFIELD_SIZE);\n\n protected open = false;\n protected readonly countriesNames$ = inject(TUI_COUNTRIES);\n protected readonly countriesMasks = inject(TUI_COUNTRIES_MASKS);\n protected readonly arrow: PolymorpheusContent<\n TuiContext<TuiSizeL | TuiSizeM | TuiSizeS>\n > = TUI_ARROW;\n\n @Input()\n public countries = this.options.countries;\n\n @Output()\n public readonly countryIsoCodeChange = new EventEmitter<TuiCountryIsoCode>();\n\n public countryIsoCode = this.options.countryIsoCode;\n\n @Input('countryIsoCode')\n public set isoCode(code: TuiCountryIsoCode) {\n if (this.countryIsoCode === code) {\n return;\n }\n\n this.inputPhoneComponent?.writeValue(this.value);\n this.countryIsoCode = code;\n }\n\n public get nativeFocusableElement(): HTMLElement | null {\n return this.inputPhoneComponent && !this.computedDisabled\n ? this.inputPhoneComponent.nativeFocusableElement\n : null;\n }\n\n public get focused(): boolean {\n return (\n (!!this.primitiveTextfield && this.primitiveTextfield.focused) ||\n (!!this.inputPhoneComponent && this.inputPhoneComponent.focused)\n );\n }\n\n public get inputPhoneCountryCode(): string {\n return tuiIsoToCountryCode(this.countriesMasks, this.countryIsoCode);\n }\n\n public get phoneMaskAfterCountryCode(): string {\n const countryCode = this.inputPhoneCountryCode;\n\n return this.calculateMaskAfterCountryCode(\n this.countriesMasks[this.countryIsoCode],\n countryCode,\n );\n }\n\n public onPaste(event: ClipboardEvent | DragEvent): void {\n let value = tuiExtractValueFromEvent(event).replace(TUI_NON_DIGITS_REGEXP, '');\n const countryIsoCode = this.extractCountryCodePipe.transform(\n value,\n this.countries,\n );\n\n if (!countryIsoCode) {\n this.value = `${this.inputPhoneCountryCode}${value}`\n .replaceAll(MASK_SYMBOLS, '')\n .slice(\n 0,\n tuiGetMaxAllowedPhoneLength(this.countriesMasks, this.countryIsoCode),\n );\n\n return;\n }\n\n if (countryIsoCode === 'RU') {\n value = value.replace(/^8/, '7');\n }\n\n this.updateCountryIsoCode(countryIsoCode);\n this.value = `${CHAR_PLUS}${value}`;\n }\n\n public onItemClick(isoCode: TuiCountryIsoCode): void {\n this.open = false;\n this.updateCountryIsoCode(isoCode);\n // recalculates mask inside inputPhone to prevent isoCode conflict\n this.cdr.detectChanges();\n\n const maxLength = tuiGetMaxAllowedPhoneLength(this.countriesMasks, isoCode);\n\n if (this.value.length > maxLength) {\n this.value = this.value.slice(0, maxLength);\n }\n\n if (this.nativeFocusableElement) {\n this.nativeFocusableElement.focus();\n }\n }\n\n public override setDisabledState(): void {\n super.setDisabledState();\n this.close();\n }\n\n protected get size(): TuiSizeL | TuiSizeS {\n return this.textfieldSize.size;\n }\n\n protected onActiveZone(active: boolean): void {\n this.updateFocused(active);\n }\n\n protected getFallbackValue(): string {\n return '';\n }\n\n @tuiPure\n private calculateMaskAfterCountryCode(mask: string, countryCode: string): string {\n return mask.replace(countryCode, '').trim();\n }\n\n private close(): void {\n this.open = false;\n }\n\n private updateCountryIsoCode(code: TuiCountryIsoCode): void {\n this.countryIsoCode = code;\n this.countryIsoCodeChange.emit(code);\n }\n}\n","@if (countriesNames$ | async; as countriesNames) {\n <div\n tuiDropdownOpenMonitor\n [tuiDropdown]=\"dropdown\"\n [tuiDropdownEnabled]=\"!readOnly\"\n [(tuiDropdownOpen)]=\"open\"\n (tuiActiveZoneChange)=\"onActiveZone($event)\"\n >\n <div tuiGroup>\n <tui-primitive-textfield\n tuiHintContent=\"\"\n tuiTextfieldPostfix=\"\"\n tuiTextfieldPrefix=\"\"\n class=\"t-country-select\"\n [disabled]=\"disabled\"\n [editable]=\"false\"\n [focusable]=\"focusable\"\n [pseudoFocus]=\"open || null\"\n [readOnly]=\"readOnly\"\n [style.flex]=\"'0 0 auto'\"\n [tuiTextfieldCustomContent]=\"countryValueContent\"\n [tuiTextfieldIcon]=\"icon\"\n [tuiTextfieldLabelOutside]=\"true\"\n />\n <tui-input-phone\n class=\"t-input-phone\"\n [countryCode]=\"inputPhoneCountryCode\"\n [disabled]=\"disabled\"\n [focusable]=\"focusable\"\n [ngModelOptions]=\"{standalone: true}\"\n [phoneMaskAfterCountryCode]=\"phoneMaskAfterCountryCode\"\n [pseudoFocus]=\"pseudoFocus\"\n [pseudoHover]=\"pseudoHover\"\n [pseudoInvalid]=\"computedInvalid\"\n [readOnly]=\"readOnly\"\n [style.flex]=\"'0 0 auto'\"\n [(ngModel)]=\"value\"\n >\n <ng-content />\n <input\n autocomplete=\"new-password\"\n tuiTextfieldLegacy\n />\n </tui-input-phone>\n </div>\n <ng-template #dropdown>\n <tui-data-list>\n @for (item of countries; track item) {\n <button\n tuiOption\n type=\"button\"\n (click)=\"onItemClick(item)\"\n >\n <img\n alt=\"\"\n class=\"t-flag\"\n [src]=\"item | tuiFlag\"\n />\n <span class=\"t-country-item-name\">\n {{ countriesNames[item] }}\n </span>\n <span class=\"t-country-item-code\">\n {{ item | tuiIsoToCountryCode }}\n </span>\n </button>\n }\n </tui-data-list>\n </ng-template>\n <ng-template #countryValueContent>\n <img\n class=\"t-flag t-flag_select\"\n [alt]=\"countriesNames[countryIsoCode]\"\n [src]=\"countryIsoCode | tuiFlag\"\n />\n </ng-template>\n <ng-template #icon>\n <div tuiAppearance=\"icon\">\n <ng-container *polymorpheusOutlet=\"arrow\" />\n </div>\n </ng-template>\n </div>\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAaA;;;AAGG;AACU,MAAA,6CAA6C,GACtD;AACI,IAAA,SAAS,EAAE,EAAE;AACb,IAAA,cAAc,EAAE,IAAI;;AAG5B;;;AAGG;AACU,MAAA,qCAAqC,GAAG,IAAI,cAAc,CACnE,SAAS,GAAG,uCAAuC,GAAG,EAAE,EACxD;AACI,IAAA,OAAO,EAAE,MAAM,6CAA6C;AAC/D,CAAA;AAGL;;;AAGG;AACG,SAAU,yCAAyC,CACrD,OAAmD,EAAA;IAEnD,OAA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