@taiga-ui/kit 3.27.0-dev.main-35534c1 → 3.27.0-dev.main-7aaa5b6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/taiga-ui-kit-components-input-date.umd.js +39 -30
- package/bundles/taiga-ui-kit-components-input-date.umd.js.map +1 -1
- package/bundles/taiga-ui-kit-components-input-phone-international.umd.js +25 -265
- package/bundles/taiga-ui-kit-components-input-phone-international.umd.js.map +1 -1
- package/bundles/taiga-ui-kit-components-input-time.umd.js +35 -29
- package/bundles/taiga-ui-kit-components-input-time.umd.js.map +1 -1
- package/bundles/taiga-ui-kit-constants.umd.js +10 -0
- package/bundles/taiga-ui-kit-constants.umd.js.map +1 -1
- package/bundles/taiga-ui-kit-pipes-iso-to-country-code.umd.js +76 -0
- package/bundles/taiga-ui-kit-pipes-iso-to-country-code.umd.js.map +1 -0
- package/bundles/taiga-ui-kit-pipes-to-country-code.umd.js +98 -0
- package/bundles/taiga-ui-kit-pipes-to-country-code.umd.js.map +1 -0
- package/bundles/taiga-ui-kit-pipes.umd.js +16 -4
- package/bundles/taiga-ui-kit-pipes.umd.js.map +1 -1
- package/bundles/taiga-ui-kit-tokens.umd.js +224 -0
- package/bundles/taiga-ui-kit-tokens.umd.js.map +1 -1
- package/bundles/taiga-ui-kit-utils-mask.umd.js +13 -0
- package/bundles/taiga-ui-kit-utils-mask.umd.js.map +1 -1
- package/bundles/taiga-ui-kit-utils-phone.umd.js +31 -0
- package/bundles/taiga-ui-kit-utils-phone.umd.js.map +1 -0
- package/bundles/taiga-ui-kit-utils.umd.js +10 -4
- package/bundles/taiga-ui-kit-utils.umd.js.map +1 -1
- package/components/input-date/input-date.component.d.ts +4 -3
- package/components/input-date/input-date.module.d.ts +3 -2
- package/components/input-phone-international/index.d.ts +0 -3
- package/components/input-phone-international/input-phone-international.component.d.ts +8 -4
- package/components/input-time/input-time.component.d.ts +3 -2
- package/components/input-time/input-time.module.d.ts +4 -3
- package/constants/date-mode-maskito-adapter.d.ts +3 -0
- package/constants/index.d.ts +2 -0
- package/esm2015/components/input-date/input-date.component.js +29 -19
- package/esm2015/components/input-date/input-date.module.js +6 -5
- package/esm2015/components/input-phone-international/index.js +1 -4
- package/esm2015/components/input-phone-international/input-phone-international.component.js +24 -31
- package/esm2015/components/input-time/input-time.component.js +21 -15
- package/esm2015/components/input-time/input-time.module.js +6 -5
- package/esm2015/constants/date-mode-maskito-adapter.js +6 -0
- package/esm2015/constants/index.js +3 -1
- package/esm2015/constants/mask-after-code-regexp.js +2 -0
- package/esm2015/pipes/index.js +3 -1
- package/esm2015/pipes/iso-to-country-code/index.js +3 -0
- package/esm2015/pipes/iso-to-country-code/iso-to-country-code.module.js +16 -0
- package/esm2015/pipes/iso-to-country-code/iso-to-country-code.pipe.js +24 -0
- package/esm2015/pipes/iso-to-country-code/taiga-ui-kit-pipes-iso-to-country-code.js +5 -0
- package/esm2015/pipes/to-country-code/index.js +3 -0
- package/esm2015/pipes/to-country-code/taiga-ui-kit-pipes-to-country-code.js +5 -0
- package/esm2015/pipes/to-country-code/to-country-code.module.js +16 -0
- package/esm2015/pipes/to-country-code/to-country-code.pipe.js +47 -0
- package/esm2015/tokens/countries-masks.js +222 -0
- package/esm2015/tokens/index.js +2 -1
- package/esm2015/utils/index.js +2 -1
- package/esm2015/utils/mask/create-auto-corrected-date-pipe.js +7 -1
- package/esm2015/utils/mask/create-auto-corrected-time-pipe.js +2 -1
- package/esm2015/utils/mask/create-date-mask.js +4 -1
- package/esm2015/utils/mask/create-time-mask.js +4 -1
- package/esm2015/utils/phone/get-max-allowed-phone-length.js +4 -0
- package/esm2015/utils/phone/index.js +4 -0
- package/esm2015/utils/phone/iso-to-country-code.js +5 -0
- package/esm2015/utils/phone/not-kz-region.js +5 -0
- package/esm2015/utils/phone/taiga-ui-kit-utils-phone.js +5 -0
- package/fesm2015/taiga-ui-kit-components-input-date.js +32 -21
- package/fesm2015/taiga-ui-kit-components-input-date.js.map +1 -1
- package/fesm2015/taiga-ui-kit-components-input-phone-international.js +24 -255
- package/fesm2015/taiga-ui-kit-components-input-phone-international.js.map +1 -1
- package/fesm2015/taiga-ui-kit-components-input-time.js +26 -19
- package/fesm2015/taiga-ui-kit-components-input-time.js.map +1 -1
- package/fesm2015/taiga-ui-kit-constants.js +9 -1
- package/fesm2015/taiga-ui-kit-constants.js.map +1 -1
- package/fesm2015/taiga-ui-kit-pipes-iso-to-country-code.js +44 -0
- package/fesm2015/taiga-ui-kit-pipes-iso-to-country-code.js.map +1 -0
- package/fesm2015/taiga-ui-kit-pipes-to-country-code.js +67 -0
- package/fesm2015/taiga-ui-kit-pipes-to-country-code.js.map +1 -0
- package/fesm2015/taiga-ui-kit-pipes.js +2 -0
- package/fesm2015/taiga-ui-kit-pipes.js.map +1 -1
- package/fesm2015/taiga-ui-kit-tokens.js +222 -2
- package/fesm2015/taiga-ui-kit-tokens.js.map +1 -1
- package/fesm2015/taiga-ui-kit-utils-mask.js +13 -0
- package/fesm2015/taiga-ui-kit-utils-mask.js.map +1 -1
- package/fesm2015/taiga-ui-kit-utils-phone.js +21 -0
- package/fesm2015/taiga-ui-kit-utils-phone.js.map +1 -0
- package/fesm2015/taiga-ui-kit-utils.js +1 -0
- package/fesm2015/taiga-ui-kit-utils.js.map +1 -1
- package/package.json +1 -1
- package/pipes/index.d.ts +2 -0
- package/pipes/iso-to-country-code/index.d.ts +2 -0
- package/pipes/iso-to-country-code/iso-to-country-code.module.d.ts +7 -0
- package/pipes/iso-to-country-code/iso-to-country-code.pipe.d.ts +10 -0
- package/pipes/iso-to-country-code/package.json +10 -0
- package/pipes/iso-to-country-code/taiga-ui-kit-pipes-iso-to-country-code.d.ts +5 -0
- package/pipes/to-country-code/index.d.ts +2 -0
- package/pipes/to-country-code/package.json +10 -0
- package/pipes/to-country-code/taiga-ui-kit-pipes-to-country-code.d.ts +5 -0
- package/pipes/to-country-code/to-country-code.module.d.ts +7 -0
- package/pipes/to-country-code/to-country-code.pipe.d.ts +10 -0
- package/tokens/index.d.ts +1 -0
- package/utils/index.d.ts +1 -0
- package/utils/mask/create-auto-corrected-date-pipe.d.ts +9 -0
- package/utils/mask/create-auto-corrected-time-pipe.d.ts +1 -0
- package/utils/mask/create-date-mask.d.ts +3 -0
- package/utils/mask/create-time-mask.d.ts +3 -0
- package/utils/phone/get-max-allowed-phone-length.d.ts +2 -0
- package/utils/phone/index.d.ts +3 -0
- package/utils/phone/iso-to-country-code.d.ts +2 -0
- package/utils/phone/package.json +10 -0
- package/utils/phone/taiga-ui-kit-utils-phone.d.ts +5 -0
- package/esm2015/components/input-phone-international/const/mask-after-code-regexp.js +0 -2
- package/esm2015/components/input-phone-international/tokens/countries-masks.js +0 -222
- package/esm2015/components/input-phone-international/utils/not-kz-region.js +0 -5
- /package/{components/input-phone-international/const → constants}/mask-after-code-regexp.d.ts +0 -0
- /package/{components/input-phone-international/tokens → tokens}/countries-masks.d.ts +0 -0
- /package/{components/input-phone-international/utils → utils/phone}/not-kz-region.d.ts +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
(function (global, factory) {
|
|
2
|
-
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/forms'), require('@taiga-ui/cdk'), require('@taiga-ui/core'), require('@taiga-ui/i18n'), require('@taiga-ui/kit/components/arrow'), require('@taiga-ui/kit/components/input-phone'), require('@taiga-ui/kit/providers'), require('@taiga-ui/kit/tokens'), require('@angular/common'), require('@tinkoff/ng-polymorpheus'), require('rxjs')) :
|
|
3
|
-
typeof define === 'function' && define.amd ? define('@taiga-ui/kit/components/input-phone-international', ['exports', '@angular/core', '@angular/forms', '@taiga-ui/cdk', '@taiga-ui/core', '@taiga-ui/i18n', '@taiga-ui/kit/components/arrow', '@taiga-ui/kit/components/input-phone', '@taiga-ui/kit/providers', '@taiga-ui/kit/tokens', '@angular/common', '@tinkoff/ng-polymorpheus', 'rxjs'], factory) :
|
|
4
|
-
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global["taiga-ui"] = global["taiga-ui"] || {}, global["taiga-ui"].kit = global["taiga-ui"].kit || {}, global["taiga-ui"].kit.components = global["taiga-ui"].kit.components || {}, global["taiga-ui"].kit.components["input-phone-international"] = {}), global.ng.core, global.ng.forms, global.i4, global.i1, global.i18n, global["taiga-ui"].kit.components.arrow, global["taiga-ui"].kit.components["input-phone"], global["taiga-ui"].kit.providers, global["taiga-ui"].kit.tokens, global.ng.common, global.i6, global.rxjs));
|
|
5
|
-
})(this, (function (exports, i0, i5, i4, i1, i18n, arrow, i2, providers, tokens, i3, i6, i7) { 'use strict';
|
|
2
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/forms'), require('@taiga-ui/cdk'), require('@taiga-ui/core'), require('@taiga-ui/i18n'), require('@taiga-ui/kit/components/arrow'), require('@taiga-ui/kit/components/input-phone'), require('@taiga-ui/kit/pipes'), require('@taiga-ui/kit/providers'), require('@taiga-ui/kit/tokens'), require('@taiga-ui/kit/utils'), require('@angular/common'), require('@tinkoff/ng-polymorpheus'), require('rxjs')) :
|
|
3
|
+
typeof define === 'function' && define.amd ? define('@taiga-ui/kit/components/input-phone-international', ['exports', '@angular/core', '@angular/forms', '@taiga-ui/cdk', '@taiga-ui/core', '@taiga-ui/i18n', '@taiga-ui/kit/components/arrow', '@taiga-ui/kit/components/input-phone', '@taiga-ui/kit/pipes', '@taiga-ui/kit/providers', '@taiga-ui/kit/tokens', '@taiga-ui/kit/utils', '@angular/common', '@tinkoff/ng-polymorpheus', 'rxjs'], factory) :
|
|
4
|
+
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global["taiga-ui"] = global["taiga-ui"] || {}, global["taiga-ui"].kit = global["taiga-ui"].kit || {}, global["taiga-ui"].kit.components = global["taiga-ui"].kit.components || {}, global["taiga-ui"].kit.components["input-phone-international"] = {}), global.ng.core, global.ng.forms, global.i4, global.i1, global.i18n, global["taiga-ui"].kit.components.arrow, global["taiga-ui"].kit.components["input-phone"], global["taiga-ui"].kit.pipes, global["taiga-ui"].kit.providers, global["taiga-ui"].kit.tokens, global["taiga-ui"].kit.utils, global.ng.common, global.i6, global.rxjs));
|
|
5
|
+
})(this, (function (exports, i0, i5, i4, i1, i18n, arrow, i2, i8, providers, tokens, utils, i3, i6, i7) { 'use strict';
|
|
6
6
|
|
|
7
7
|
function _interopNamespace(e) {
|
|
8
8
|
if (e && e.__esModule) return e;
|
|
@@ -27,12 +27,11 @@
|
|
|
27
27
|
var i4__namespace = /*#__PURE__*/_interopNamespace(i4);
|
|
28
28
|
var i1__namespace = /*#__PURE__*/_interopNamespace(i1);
|
|
29
29
|
var i2__namespace = /*#__PURE__*/_interopNamespace(i2);
|
|
30
|
+
var i8__namespace = /*#__PURE__*/_interopNamespace(i8);
|
|
30
31
|
var i3__namespace = /*#__PURE__*/_interopNamespace(i3);
|
|
31
32
|
var i6__namespace = /*#__PURE__*/_interopNamespace(i6);
|
|
32
33
|
var i7__namespace = /*#__PURE__*/_interopNamespace(i7);
|
|
33
34
|
|
|
34
|
-
var MASK_AFTER_CODE_REGEXP = /\([#]+\)|[#\- ]/g;
|
|
35
|
-
|
|
36
35
|
/*! *****************************************************************************
|
|
37
36
|
Copyright (c) Microsoft Corporation.
|
|
38
37
|
|
|
@@ -366,229 +365,6 @@
|
|
|
366
365
|
useValue: Object.assign(Object.assign({}, TUI_INPUT_PHONE_INTERNATIONAL_DEFAULT_OPTIONS), options),
|
|
367
366
|
}); };
|
|
368
367
|
|
|
369
|
-
var TUI_COUNTRIES_MASKS = new i0.InjectionToken("[TUI_COUNTRIES_MASKS]", {
|
|
370
|
-
factory: function () {
|
|
371
|
-
var _a;
|
|
372
|
-
return (_a = {},
|
|
373
|
-
_a[i18n.TuiCountryIsoCode.AD] = "+376###-###",
|
|
374
|
-
_a[i18n.TuiCountryIsoCode.AE] = "+971-##-###-####",
|
|
375
|
-
_a[i18n.TuiCountryIsoCode.AF] = "+93##-###-####",
|
|
376
|
-
_a[i18n.TuiCountryIsoCode.AG] = "+1(268) ###-####",
|
|
377
|
-
_a[i18n.TuiCountryIsoCode.AI] = "+1(264) ###-####",
|
|
378
|
-
_a[i18n.TuiCountryIsoCode.AL] = "+355(###) ###-###",
|
|
379
|
-
_a[i18n.TuiCountryIsoCode.AM] = "+374##-###-###",
|
|
380
|
-
_a[i18n.TuiCountryIsoCode.AO] = "+244(###) ###-###",
|
|
381
|
-
_a[i18n.TuiCountryIsoCode.AR] = "+54(###) ###-####",
|
|
382
|
-
_a[i18n.TuiCountryIsoCode.AT] = "+43(###) ###-####",
|
|
383
|
-
_a[i18n.TuiCountryIsoCode.AU] = "+61#-####-####",
|
|
384
|
-
_a[i18n.TuiCountryIsoCode.AW] = "+297###-####",
|
|
385
|
-
_a[i18n.TuiCountryIsoCode.AZ] = "+994##-###-##-##",
|
|
386
|
-
_a[i18n.TuiCountryIsoCode.BA] = "+387 ###-####-##",
|
|
387
|
-
_a[i18n.TuiCountryIsoCode.BB] = "+1(246) ###-####",
|
|
388
|
-
_a[i18n.TuiCountryIsoCode.BD] = "+880##-###-###",
|
|
389
|
-
_a[i18n.TuiCountryIsoCode.BE] = "+32(###) ###-###",
|
|
390
|
-
_a[i18n.TuiCountryIsoCode.BF] = "+226##-##-####",
|
|
391
|
-
_a[i18n.TuiCountryIsoCode.BG] = "+359(###) ###-###",
|
|
392
|
-
_a[i18n.TuiCountryIsoCode.BH] = "+973####-####",
|
|
393
|
-
_a[i18n.TuiCountryIsoCode.BI] = "+257##-##-####",
|
|
394
|
-
_a[i18n.TuiCountryIsoCode.BJ] = "+229##-##-####",
|
|
395
|
-
_a[i18n.TuiCountryIsoCode.BL] = "+590 ## ## ## ## ##",
|
|
396
|
-
_a[i18n.TuiCountryIsoCode.BM] = "+1(441) ###-####",
|
|
397
|
-
_a[i18n.TuiCountryIsoCode.BN] = "+673###-####",
|
|
398
|
-
_a[i18n.TuiCountryIsoCode.BO] = "+591#-###-####",
|
|
399
|
-
_a[i18n.TuiCountryIsoCode.BQ] = "+599-###-####",
|
|
400
|
-
_a[i18n.TuiCountryIsoCode.BR] = "+55(##) ####-####",
|
|
401
|
-
_a[i18n.TuiCountryIsoCode.BS] = "+1(242) ###-####",
|
|
402
|
-
_a[i18n.TuiCountryIsoCode.BT] = "+975#-###-###",
|
|
403
|
-
_a[i18n.TuiCountryIsoCode.BW] = "+267##-###-###",
|
|
404
|
-
_a[i18n.TuiCountryIsoCode.BY] = "+375(##) ###-##-##",
|
|
405
|
-
_a[i18n.TuiCountryIsoCode.BZ] = "+501###-####",
|
|
406
|
-
_a[i18n.TuiCountryIsoCode.CA] = "+1(###) ###-####",
|
|
407
|
-
_a[i18n.TuiCountryIsoCode.CD] = "+243(###) ###-###",
|
|
408
|
-
_a[i18n.TuiCountryIsoCode.CF] = "+236-##-##-####",
|
|
409
|
-
_a[i18n.TuiCountryIsoCode.CG] = "+242##-###-####",
|
|
410
|
-
_a[i18n.TuiCountryIsoCode.CH] = "+41##-###-####",
|
|
411
|
-
_a[i18n.TuiCountryIsoCode.CI] = "+225##-##-###-###",
|
|
412
|
-
_a[i18n.TuiCountryIsoCode.CL] = "+56#-####-####",
|
|
413
|
-
_a[i18n.TuiCountryIsoCode.CM] = "+237#####-####",
|
|
414
|
-
_a[i18n.TuiCountryIsoCode.CN] = "+86(###) ####-####",
|
|
415
|
-
_a[i18n.TuiCountryIsoCode.CO] = "+57(###) ###-####",
|
|
416
|
-
_a[i18n.TuiCountryIsoCode.CR] = "+506####-####",
|
|
417
|
-
_a[i18n.TuiCountryIsoCode.CU] = "+53#-###-####",
|
|
418
|
-
_a[i18n.TuiCountryIsoCode.CV] = "+238(###) ##-##",
|
|
419
|
-
_a[i18n.TuiCountryIsoCode.CW] = "+5999-###-####",
|
|
420
|
-
_a[i18n.TuiCountryIsoCode.CY] = "+357##-###-###",
|
|
421
|
-
_a[i18n.TuiCountryIsoCode.CZ] = "+420(###) ###-###",
|
|
422
|
-
_a[i18n.TuiCountryIsoCode.DE] = "+49(###) ###-###-##",
|
|
423
|
-
_a[i18n.TuiCountryIsoCode.DJ] = "+253##-##-##-##",
|
|
424
|
-
_a[i18n.TuiCountryIsoCode.DK] = "+45##-##-##-##",
|
|
425
|
-
_a[i18n.TuiCountryIsoCode.DM] = "+1(767) ###-####",
|
|
426
|
-
_a[i18n.TuiCountryIsoCode.DO] = "+1(###) ###-####",
|
|
427
|
-
_a[i18n.TuiCountryIsoCode.DZ] = "+213##-###-####",
|
|
428
|
-
_a[i18n.TuiCountryIsoCode.EC] = "+593##-###-####",
|
|
429
|
-
_a[i18n.TuiCountryIsoCode.EE] = "+372####-####",
|
|
430
|
-
_a[i18n.TuiCountryIsoCode.EG] = "+20(###) ###-####",
|
|
431
|
-
_a[i18n.TuiCountryIsoCode.ER] = "+291#-###-###",
|
|
432
|
-
_a[i18n.TuiCountryIsoCode.ES] = "+34(###) ###-###",
|
|
433
|
-
_a[i18n.TuiCountryIsoCode.ET] = "+251##-###-####",
|
|
434
|
-
_a[i18n.TuiCountryIsoCode.FI] = "+358(###) ###-##-##",
|
|
435
|
-
_a[i18n.TuiCountryIsoCode.FJ] = "+679##-#####",
|
|
436
|
-
_a[i18n.TuiCountryIsoCode.FK] = "+500#####",
|
|
437
|
-
_a[i18n.TuiCountryIsoCode.FM] = "+691###-####",
|
|
438
|
-
_a[i18n.TuiCountryIsoCode.FR] = "+33 ## ## ## ## ##",
|
|
439
|
-
_a[i18n.TuiCountryIsoCode.GA] = "+241##-##-##-##",
|
|
440
|
-
_a[i18n.TuiCountryIsoCode.GB] = "+44##-####-####",
|
|
441
|
-
_a[i18n.TuiCountryIsoCode.GD] = "+1(473) ###-####",
|
|
442
|
-
_a[i18n.TuiCountryIsoCode.GE] = "+995(###) ###-###",
|
|
443
|
-
_a[i18n.TuiCountryIsoCode.GF] = "+594 ## ## ## ## ##",
|
|
444
|
-
_a[i18n.TuiCountryIsoCode.GH] = "+233(###) ###-###",
|
|
445
|
-
_a[i18n.TuiCountryIsoCode.GI] = "+350###-#####",
|
|
446
|
-
_a[i18n.TuiCountryIsoCode.GL] = "+299##-##-##",
|
|
447
|
-
_a[i18n.TuiCountryIsoCode.GM] = "+220(###) ##-##",
|
|
448
|
-
_a[i18n.TuiCountryIsoCode.GN] = "+224##-###-###",
|
|
449
|
-
_a[i18n.TuiCountryIsoCode.GP] = "+590 ## ## ## ## ##",
|
|
450
|
-
_a[i18n.TuiCountryIsoCode.GQ] = "+240##-###-####",
|
|
451
|
-
_a[i18n.TuiCountryIsoCode.GR] = "+30(###) ###-####",
|
|
452
|
-
_a[i18n.TuiCountryIsoCode.GT] = "+502#-###-####",
|
|
453
|
-
_a[i18n.TuiCountryIsoCode.GW] = "+245#-######",
|
|
454
|
-
_a[i18n.TuiCountryIsoCode.GY] = "+592###-####",
|
|
455
|
-
_a[i18n.TuiCountryIsoCode.HK] = "+852####-####",
|
|
456
|
-
_a[i18n.TuiCountryIsoCode.HN] = "+504####-####",
|
|
457
|
-
_a[i18n.TuiCountryIsoCode.HR] = "+385##-###-####",
|
|
458
|
-
_a[i18n.TuiCountryIsoCode.HT] = "+509##-##-####",
|
|
459
|
-
_a[i18n.TuiCountryIsoCode.HU] = "+36(###) ###-###",
|
|
460
|
-
_a[i18n.TuiCountryIsoCode.ID] = "+62(###) ###-##-###",
|
|
461
|
-
_a[i18n.TuiCountryIsoCode.IE] = "+353(###) ###-###",
|
|
462
|
-
_a[i18n.TuiCountryIsoCode.IL] = "+972##-###-####",
|
|
463
|
-
_a[i18n.TuiCountryIsoCode.IN] = "+91(####) ###-###",
|
|
464
|
-
_a[i18n.TuiCountryIsoCode.IQ] = "+964(###) ###-####",
|
|
465
|
-
_a[i18n.TuiCountryIsoCode.IR] = "+98(###) ###-####",
|
|
466
|
-
_a[i18n.TuiCountryIsoCode.IS] = "+354###-####",
|
|
467
|
-
_a[i18n.TuiCountryIsoCode.IT] = "+39(###) ####-###",
|
|
468
|
-
_a[i18n.TuiCountryIsoCode.JM] = "+1(876) ###-####",
|
|
469
|
-
_a[i18n.TuiCountryIsoCode.JO] = "+962#-####-####",
|
|
470
|
-
_a[i18n.TuiCountryIsoCode.JP] = "+81-##-####-####",
|
|
471
|
-
_a[i18n.TuiCountryIsoCode.KE] = "+254###-######",
|
|
472
|
-
_a[i18n.TuiCountryIsoCode.KG] = "+996(###) ###-###",
|
|
473
|
-
_a[i18n.TuiCountryIsoCode.KH] = "+855##-###-###",
|
|
474
|
-
_a[i18n.TuiCountryIsoCode.KM] = "+269##-#####",
|
|
475
|
-
_a[i18n.TuiCountryIsoCode.KN] = "+1(869) ###-####",
|
|
476
|
-
_a[i18n.TuiCountryIsoCode.KP] = "+850####-#############",
|
|
477
|
-
_a[i18n.TuiCountryIsoCode.KR] = "+82##-###-####",
|
|
478
|
-
_a[i18n.TuiCountryIsoCode.KW] = "+965####-####",
|
|
479
|
-
_a[i18n.TuiCountryIsoCode.KY] = "+1(345) ###-####",
|
|
480
|
-
_a[i18n.TuiCountryIsoCode.KZ] = "+7(###) ###-##-##",
|
|
481
|
-
_a[i18n.TuiCountryIsoCode.LA] = "+856##-##-###-###",
|
|
482
|
-
_a[i18n.TuiCountryIsoCode.LB] = "+961##-###-###",
|
|
483
|
-
_a[i18n.TuiCountryIsoCode.LC] = "+1(758) ###-####",
|
|
484
|
-
_a[i18n.TuiCountryIsoCode.LI] = "+423(###) ###-####",
|
|
485
|
-
_a[i18n.TuiCountryIsoCode.LK] = "+94##-###-####",
|
|
486
|
-
_a[i18n.TuiCountryIsoCode.LR] = "+231##-###-###",
|
|
487
|
-
_a[i18n.TuiCountryIsoCode.LS] = "+266#-###-####",
|
|
488
|
-
_a[i18n.TuiCountryIsoCode.LT] = "+370(###) ##-###",
|
|
489
|
-
_a[i18n.TuiCountryIsoCode.LU] = "+352(###) ###-###",
|
|
490
|
-
_a[i18n.TuiCountryIsoCode.LV] = "+371##-###-###",
|
|
491
|
-
_a[i18n.TuiCountryIsoCode.LY] = "+218##-###-####",
|
|
492
|
-
_a[i18n.TuiCountryIsoCode.MA] = "+212##-####-###",
|
|
493
|
-
_a[i18n.TuiCountryIsoCode.MC] = "+377###-###-###",
|
|
494
|
-
_a[i18n.TuiCountryIsoCode.MD] = "+373####-####",
|
|
495
|
-
_a[i18n.TuiCountryIsoCode.ME] = "+382##-###-###",
|
|
496
|
-
_a[i18n.TuiCountryIsoCode.MF] = "+590 ## ## ## ## ##",
|
|
497
|
-
_a[i18n.TuiCountryIsoCode.MG] = "+261##-##-#####",
|
|
498
|
-
_a[i18n.TuiCountryIsoCode.MK] = "+389##-###-###",
|
|
499
|
-
_a[i18n.TuiCountryIsoCode.ML] = "+223##-##-####",
|
|
500
|
-
_a[i18n.TuiCountryIsoCode.MM] = "+95##-###-###",
|
|
501
|
-
_a[i18n.TuiCountryIsoCode.MN] = "+976##-##-####",
|
|
502
|
-
_a[i18n.TuiCountryIsoCode.MO] = "+853####-####",
|
|
503
|
-
_a[i18n.TuiCountryIsoCode.MQ] = "+596 ## ## ## ## ##",
|
|
504
|
-
_a[i18n.TuiCountryIsoCode.MR] = "+222##-##-####",
|
|
505
|
-
_a[i18n.TuiCountryIsoCode.MS] = "+1(664) ###-####",
|
|
506
|
-
_a[i18n.TuiCountryIsoCode.MT] = "+356####-####",
|
|
507
|
-
_a[i18n.TuiCountryIsoCode.MU] = "+230####-####",
|
|
508
|
-
_a[i18n.TuiCountryIsoCode.MV] = "+960###-####",
|
|
509
|
-
_a[i18n.TuiCountryIsoCode.MW] = "+265#-####-####",
|
|
510
|
-
_a[i18n.TuiCountryIsoCode.MX] = "+52(###) ###-####",
|
|
511
|
-
_a[i18n.TuiCountryIsoCode.MY] = "+60(###) ###-###",
|
|
512
|
-
_a[i18n.TuiCountryIsoCode.MZ] = "+258##-###-###",
|
|
513
|
-
_a[i18n.TuiCountryIsoCode.NA] = "+264##-###-####",
|
|
514
|
-
_a[i18n.TuiCountryIsoCode.NC] = "+687 ### ###",
|
|
515
|
-
_a[i18n.TuiCountryIsoCode.NE] = "+227##-##-####",
|
|
516
|
-
_a[i18n.TuiCountryIsoCode.NG] = "+234(###) ###-####",
|
|
517
|
-
_a[i18n.TuiCountryIsoCode.NI] = "+505####-####",
|
|
518
|
-
_a[i18n.TuiCountryIsoCode.NL] = "+31##-###-####",
|
|
519
|
-
_a[i18n.TuiCountryIsoCode.NO] = "+47(###) ##-###",
|
|
520
|
-
_a[i18n.TuiCountryIsoCode.NP] = "+977##-###-###",
|
|
521
|
-
_a[i18n.TuiCountryIsoCode.NZ] = "+64(###) ###-####",
|
|
522
|
-
_a[i18n.TuiCountryIsoCode.OM] = "+968##-###-###",
|
|
523
|
-
_a[i18n.TuiCountryIsoCode.PA] = "+507###-####",
|
|
524
|
-
_a[i18n.TuiCountryIsoCode.PE] = "+51(###) ###-###",
|
|
525
|
-
_a[i18n.TuiCountryIsoCode.PF] = "+689 ## ## ## ##",
|
|
526
|
-
_a[i18n.TuiCountryIsoCode.PG] = "+675(###) ##-###",
|
|
527
|
-
_a[i18n.TuiCountryIsoCode.PH] = "+63(###) ###-####",
|
|
528
|
-
_a[i18n.TuiCountryIsoCode.PK] = "+92(###) ###-####",
|
|
529
|
-
_a[i18n.TuiCountryIsoCode.PL] = "+48(###) ###-###",
|
|
530
|
-
_a[i18n.TuiCountryIsoCode.PT] = "+351##-###-####",
|
|
531
|
-
_a[i18n.TuiCountryIsoCode.PW] = "+680###-####",
|
|
532
|
-
_a[i18n.TuiCountryIsoCode.PY] = "+595(###) ###-###",
|
|
533
|
-
_a[i18n.TuiCountryIsoCode.QA] = "+974####-####",
|
|
534
|
-
_a[i18n.TuiCountryIsoCode.RE] = "+262 ## ## ## ## ##",
|
|
535
|
-
_a[i18n.TuiCountryIsoCode.RO] = "+40##-###-####",
|
|
536
|
-
_a[i18n.TuiCountryIsoCode.RS] = "+381##-###-####",
|
|
537
|
-
_a[i18n.TuiCountryIsoCode.RU] = "+7### ###-##-##",
|
|
538
|
-
_a[i18n.TuiCountryIsoCode.RW] = "+250(###) ###-###",
|
|
539
|
-
_a[i18n.TuiCountryIsoCode.SA] = "+966#-####-####",
|
|
540
|
-
_a[i18n.TuiCountryIsoCode.SB] = "+677###-####",
|
|
541
|
-
_a[i18n.TuiCountryIsoCode.SC] = "+248#-###-###",
|
|
542
|
-
_a[i18n.TuiCountryIsoCode.SD] = "+249##-###-####",
|
|
543
|
-
_a[i18n.TuiCountryIsoCode.SE] = "+46##-###-####",
|
|
544
|
-
_a[i18n.TuiCountryIsoCode.SG] = "+65####-####",
|
|
545
|
-
_a[i18n.TuiCountryIsoCode.SH] = "+290####",
|
|
546
|
-
_a[i18n.TuiCountryIsoCode.SI] = "+386##-###-###",
|
|
547
|
-
_a[i18n.TuiCountryIsoCode.SK] = "+421(###) ###-###",
|
|
548
|
-
_a[i18n.TuiCountryIsoCode.SL] = "+232##-######",
|
|
549
|
-
_a[i18n.TuiCountryIsoCode.SM] = "+378####-######",
|
|
550
|
-
_a[i18n.TuiCountryIsoCode.SN] = "+221##-###-####",
|
|
551
|
-
_a[i18n.TuiCountryIsoCode.SO] = "+252##-###-###",
|
|
552
|
-
_a[i18n.TuiCountryIsoCode.SR] = "+597###-####",
|
|
553
|
-
_a[i18n.TuiCountryIsoCode.ST] = "+239##-#####",
|
|
554
|
-
_a[i18n.TuiCountryIsoCode.SV] = "+503##-##-####",
|
|
555
|
-
_a[i18n.TuiCountryIsoCode.SX] = "+1(721) ###-####",
|
|
556
|
-
_a[i18n.TuiCountryIsoCode.SY] = "+963##-####-###",
|
|
557
|
-
_a[i18n.TuiCountryIsoCode.SZ] = "+268##-##-####",
|
|
558
|
-
_a[i18n.TuiCountryIsoCode.TC] = "+1(649) ###-####",
|
|
559
|
-
_a[i18n.TuiCountryIsoCode.TD] = "+235##-##-##-##",
|
|
560
|
-
_a[i18n.TuiCountryIsoCode.TG] = "+228##-###-###",
|
|
561
|
-
_a[i18n.TuiCountryIsoCode.TH] = "+66##-###-####",
|
|
562
|
-
_a[i18n.TuiCountryIsoCode.TJ] = "+992##-###-####",
|
|
563
|
-
_a[i18n.TuiCountryIsoCode.TL] = "+670###-#####",
|
|
564
|
-
_a[i18n.TuiCountryIsoCode.TM] = "+993#-###-####",
|
|
565
|
-
_a[i18n.TuiCountryIsoCode.TN] = "+216##-###-###",
|
|
566
|
-
_a[i18n.TuiCountryIsoCode.TO] = "+676#####",
|
|
567
|
-
_a[i18n.TuiCountryIsoCode.TR] = "+90(###) ###-####",
|
|
568
|
-
_a[i18n.TuiCountryIsoCode.TT] = "+1(868) ###-####",
|
|
569
|
-
_a[i18n.TuiCountryIsoCode.TW] = "+886#-####-####",
|
|
570
|
-
_a[i18n.TuiCountryIsoCode.TZ] = "+255##-###-####",
|
|
571
|
-
_a[i18n.TuiCountryIsoCode.UA] = "+380(##) ###-##-##",
|
|
572
|
-
_a[i18n.TuiCountryIsoCode.UG] = "+256(###) ###-###",
|
|
573
|
-
_a[i18n.TuiCountryIsoCode.US] = "+1(###) ###-####",
|
|
574
|
-
_a[i18n.TuiCountryIsoCode.UY] = "+598#-###-##-##",
|
|
575
|
-
_a[i18n.TuiCountryIsoCode.UZ] = "+998##-###-####",
|
|
576
|
-
_a[i18n.TuiCountryIsoCode.VC] = "+1(784) ###-####",
|
|
577
|
-
_a[i18n.TuiCountryIsoCode.VE] = "+58(###) ###-####",
|
|
578
|
-
_a[i18n.TuiCountryIsoCode.VG] = "+1(284)###-####",
|
|
579
|
-
_a[i18n.TuiCountryIsoCode.VN] = "+84(###) ####-###",
|
|
580
|
-
_a[i18n.TuiCountryIsoCode.VU] = "+678##-#####",
|
|
581
|
-
_a[i18n.TuiCountryIsoCode.WS] = "+685##-####",
|
|
582
|
-
_a[i18n.TuiCountryIsoCode.XK] = "+383##-###-###",
|
|
583
|
-
_a[i18n.TuiCountryIsoCode.YE] = "+967###-###-###",
|
|
584
|
-
_a[i18n.TuiCountryIsoCode.YT] = "+262 ## ## ## ## ##",
|
|
585
|
-
_a[i18n.TuiCountryIsoCode.ZA] = "+27##-###-####",
|
|
586
|
-
_a[i18n.TuiCountryIsoCode.ZM] = "+260##-###-####",
|
|
587
|
-
_a[i18n.TuiCountryIsoCode.ZW] = "+263#-######",
|
|
588
|
-
_a);
|
|
589
|
-
},
|
|
590
|
-
});
|
|
591
|
-
|
|
592
368
|
function tuiExtractValueFromEvent(event) {
|
|
593
369
|
var _a;
|
|
594
370
|
return "dataTransfer" in event
|
|
@@ -596,25 +372,21 @@
|
|
|
596
372
|
: i4.tuiGetClipboardDataText(event);
|
|
597
373
|
}
|
|
598
374
|
|
|
599
|
-
function tuiNotKzRegion(value) {
|
|
600
|
-
var region = Number(value.slice(1, 4));
|
|
601
|
-
return region < 600 || region > 799;
|
|
602
|
-
}
|
|
603
|
-
|
|
604
375
|
var TuiInputPhoneInternationalComponent = /** @class */ (function (_super) {
|
|
605
376
|
__extends(TuiInputPhoneInternationalComponent, _super);
|
|
606
|
-
function TuiInputPhoneInternationalComponent(control, cdr, countriesNames$, countriesMasks, options, flagPipe) {
|
|
377
|
+
function TuiInputPhoneInternationalComponent(control, cdr, countriesNames$, countriesMasks, options, flagPipe, extractCountryCodePipe) {
|
|
607
378
|
var _this = _super.call(this, control, cdr) || this;
|
|
608
379
|
_this.countriesNames$ = countriesNames$;
|
|
609
380
|
_this.countriesMasks = countriesMasks;
|
|
610
381
|
_this.options = options;
|
|
611
382
|
_this.flagPipe = flagPipe;
|
|
383
|
+
_this.extractCountryCodePipe = extractCountryCodePipe;
|
|
612
384
|
_this.countries = _this.options.countries;
|
|
613
385
|
_this.countryIsoCodeChange = new i0.EventEmitter();
|
|
614
386
|
_this.countryIsoCode = _this.options.countryIsoCode;
|
|
615
387
|
_this.open = false;
|
|
616
388
|
_this.arrow = arrow.TUI_ARROW;
|
|
617
|
-
_this.isoToCountryCodeMapper = function (item) { return _this.
|
|
389
|
+
_this.isoToCountryCodeMapper = function (item) { return utils.tuiIsoToCountryCode(_this.countriesMasks, item); };
|
|
618
390
|
return _this;
|
|
619
391
|
}
|
|
620
392
|
Object.defineProperty(TuiInputPhoneInternationalComponent.prototype, "isoCode", {
|
|
@@ -648,14 +420,14 @@
|
|
|
648
420
|
});
|
|
649
421
|
Object.defineProperty(TuiInputPhoneInternationalComponent.prototype, "inputPhoneCountryCode", {
|
|
650
422
|
get: function () {
|
|
651
|
-
return
|
|
423
|
+
return utils.tuiIsoToCountryCode(this.countriesMasks, this.countryIsoCode);
|
|
652
424
|
},
|
|
653
425
|
enumerable: false,
|
|
654
426
|
configurable: true
|
|
655
427
|
});
|
|
656
428
|
Object.defineProperty(TuiInputPhoneInternationalComponent.prototype, "phoneMaskAfterCountryCode", {
|
|
657
429
|
get: function () {
|
|
658
|
-
var countryCode = this.
|
|
430
|
+
var countryCode = this.inputPhoneCountryCode;
|
|
659
431
|
return this.calculateMaskAfterCountryCode(this.countriesMasks[this.countryIsoCode], countryCode);
|
|
660
432
|
},
|
|
661
433
|
enumerable: false,
|
|
@@ -674,11 +446,11 @@
|
|
|
674
446
|
});
|
|
675
447
|
TuiInputPhoneInternationalComponent.prototype.onPaste = function (event) {
|
|
676
448
|
var value = tuiExtractValueFromEvent(event).replace(i1.TUI_NON_DIGITS_REGEXP, '');
|
|
677
|
-
var countryIsoCode = this.
|
|
449
|
+
var countryIsoCode = this.extractCountryCodePipe.transform(value, this.countries);
|
|
678
450
|
if (!countryIsoCode) {
|
|
679
451
|
this.value = ("" + this.inputPhoneCountryCode + value)
|
|
680
452
|
.replace(i1.TUI_MASK_SYMBOLS_REGEXP, '')
|
|
681
|
-
.slice(0,
|
|
453
|
+
.slice(0, utils.tuiGetMaxAllowedPhoneLength(this.countriesMasks, this.countryIsoCode));
|
|
682
454
|
return;
|
|
683
455
|
}
|
|
684
456
|
if (countryIsoCode === i18n.TuiCountryIsoCode.RU) {
|
|
@@ -699,7 +471,7 @@
|
|
|
699
471
|
this.updateCountryIsoCode(isoCode);
|
|
700
472
|
// recalculates mask inside inputPhone to prevent isoCode conflict
|
|
701
473
|
this.cdr.detectChanges();
|
|
702
|
-
var maxLength = this.
|
|
474
|
+
var maxLength = utils.tuiGetMaxAllowedPhoneLength(this.countriesMasks, isoCode);
|
|
703
475
|
if (this.value.length > maxLength) {
|
|
704
476
|
this.value = this.value.slice(0, maxLength);
|
|
705
477
|
}
|
|
@@ -711,8 +483,12 @@
|
|
|
711
483
|
_super.prototype.setDisabledState.call(this);
|
|
712
484
|
this.close();
|
|
713
485
|
};
|
|
486
|
+
/**
|
|
487
|
+
* @deprecated use `{{ countryIsoCode | tuiIsoToCountryCode }}`
|
|
488
|
+
* TODO drop in v4.0
|
|
489
|
+
*/
|
|
714
490
|
TuiInputPhoneInternationalComponent.prototype.isoToCountryCode = function (isoCode) {
|
|
715
|
-
return this.countriesMasks
|
|
491
|
+
return utils.tuiIsoToCountryCode(this.countriesMasks, isoCode);
|
|
716
492
|
};
|
|
717
493
|
/** @deprecated use 'value' setter */
|
|
718
494
|
TuiInputPhoneInternationalComponent.prototype.onModelChange = function (value) {
|
|
@@ -730,36 +506,19 @@
|
|
|
730
506
|
TuiInputPhoneInternationalComponent.prototype.close = function () {
|
|
731
507
|
this.open = false;
|
|
732
508
|
};
|
|
733
|
-
TuiInputPhoneInternationalComponent.prototype.getMaxAllowedLength = function (isoCode) {
|
|
734
|
-
return this.countriesMasks[isoCode].replace(/[()\- ]/g, '').length;
|
|
735
|
-
};
|
|
736
509
|
TuiInputPhoneInternationalComponent.prototype.updateCountryIsoCode = function (code) {
|
|
737
510
|
this.countryIsoCode = code;
|
|
738
511
|
this.countryIsoCodeChange.emit(code);
|
|
739
512
|
};
|
|
740
|
-
TuiInputPhoneInternationalComponent.prototype.extractCountryCode = function (value) {
|
|
741
|
-
var _this = this;
|
|
742
|
-
return this.countries.find(function (countryIsoCode) {
|
|
743
|
-
var ruCodeTest = countryIsoCode === i18n.TuiCountryIsoCode.RU &&
|
|
744
|
-
/^[7 | 8]/.test(value) &&
|
|
745
|
-
/^(?!880[1-9 ])/.test(value) &&
|
|
746
|
-
value.length + 1 === _this.getMaxAllowedLength(i18n.TuiCountryIsoCode.RU);
|
|
747
|
-
var matched = ruCodeTest ||
|
|
748
|
-
(value.startsWith(_this.isoToCountryCode(countryIsoCode).replace(i4.CHAR_PLUS, '')) &&
|
|
749
|
-
value.length + 1 === _this.getMaxAllowedLength(countryIsoCode));
|
|
750
|
-
return matched && countryIsoCode === i18n.TuiCountryIsoCode.RU
|
|
751
|
-
? tuiNotKzRegion(value)
|
|
752
|
-
: matched;
|
|
753
|
-
});
|
|
754
|
-
};
|
|
755
513
|
return TuiInputPhoneInternationalComponent;
|
|
756
514
|
}(i4.AbstractTuiControl));
|
|
757
|
-
TuiInputPhoneInternationalComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: TuiInputPhoneInternationalComponent, deps: [{ token: i5.NgControl, optional: true, self: true }, { token: i0.ChangeDetectorRef }, { token: tokens.TUI_COUNTRIES }, { token: TUI_COUNTRIES_MASKS }, { token: TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS }, { token: i1.TuiFlagPipe }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
515
|
+
TuiInputPhoneInternationalComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: TuiInputPhoneInternationalComponent, deps: [{ token: i5.NgControl, optional: true, self: true }, { token: i0.ChangeDetectorRef }, { token: tokens.TUI_COUNTRIES }, { token: tokens.TUI_COUNTRIES_MASKS }, { token: TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS }, { token: i1.TuiFlagPipe }, { token: i8.TuiToCountryCodePipe }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
758
516
|
TuiInputPhoneInternationalComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: TuiInputPhoneInternationalComponent, selector: "tui-input-phone-international", inputs: { isoCode: ["countryIsoCode", "isoCode"], countries: "countries" }, outputs: { countryIsoCodeChange: "countryIsoCodeChange" }, host: { listeners: { "paste.capture.prevent.stop": "onPaste($event)", "drop.capture.prevent.stop": "onPaste($event)" } }, providers: [
|
|
759
517
|
i4.tuiAsFocusableItemAccessor(TuiInputPhoneInternationalComponent),
|
|
760
518
|
i4.tuiAsControl(TuiInputPhoneInternationalComponent),
|
|
761
519
|
// TODO: for backward compatibility only. Drop in v4.0
|
|
762
520
|
i1.TuiFlagPipe,
|
|
521
|
+
i8.TuiToCountryCodePipe,
|
|
763
522
|
], viewQueries: [{ propertyName: "inputPhoneComponent", first: true, predicate: i2.TuiInputPhoneComponent, descendants: true }, { propertyName: "primitiveTextfield", first: true, predicate: i1.TuiPrimitiveTextfieldComponent, descendants: true }], usesInheritance: true, ngImport: i0__namespace, template: "<tui-hosted-dropdown\n *ngIf=\"countriesNames$ | async as countriesNames\"\n class=\"t-hosted-dropdown\"\n [content]=\"dropdown\"\n [canOpen]=\"!readOnly\"\n [(open)]=\"open\"\n (tuiActiveZoneChange)=\"onActiveZone($event)\"\n>\n <div tuiGroup>\n <tui-primitive-textfield\n tuiHintContent=\"\"\n tuiTextfieldPrefix=\"\"\n tuiTextfieldPostfix=\"\"\n class=\"t-country-select tui-group__auto-width-item\"\n [tuiTextfieldCustomContent]=\"countryValueContent\"\n [tuiTextfieldLabelOutside]=\"true\"\n [tuiTextfieldIcon]=\"icon\"\n [disabled]=\"disabled\"\n [focusable]=\"focusable\"\n [editable]=\"false\"\n [pseudoFocus]=\"open || null\"\n [readOnly]=\"readOnly\"\n ></tui-primitive-textfield>\n <tui-input-phone\n class=\"t-input-phone tui-group__auto-width-item\"\n [disabled]=\"disabled\"\n [focusable]=\"focusable\"\n [countryCode]=\"inputPhoneCountryCode\"\n [phoneMaskAfterCountryCode]=\"phoneMaskAfterCountryCode\"\n [readOnly]=\"readOnly\"\n [pseudoInvalid]=\"computedInvalid\"\n [pseudoFocus]=\"pseudoFocus\"\n [pseudoHover]=\"pseudoHover\"\n [(ngModel)]=\"value\"\n >\n <ng-content></ng-content>\n <input\n tuiTextfield\n autocomplete=\"new-password\"\n />\n </tui-input-phone>\n </div>\n\n <ng-template #dropdown>\n <tui-data-list>\n <button\n *ngFor=\"let item of countries\"\n tuiOption\n (click)=\"onItemClick(item)\"\n >\n <img\n alt=\"\"\n class=\"t-country-item-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 | tuiMapper : isoToCountryCodeMapper }}\n </span>\n </button>\n </tui-data-list>\n </ng-template>\n\n <ng-template #countryValueContent>\n <!-- eslint-disable @html-eslint/require-img-alt -->\n <img\n class=\"t-flag\"\n [alt]=\"countriesNames[countryIsoCode]\"\n [src]=\"countryIsoCode | tuiFlag\"\n />\n </ng-template>\n\n <ng-template #icon>\n <div\n tuiWrapper\n appearance=\"icon\"\n >\n <ng-container *polymorpheusOutlet=\"arrow\"></ng-container>\n </div>\n </ng-template>\n</tui-hosted-dropdown>\n", styles: [":host{display:block}:host._disabled{pointer-events:none}.t-hosted-dropdown{display:block}.t-country-select{width: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]{width:5.5rem}.t-country-select[data-size=s]{width:2rem}.t-country-select[data-size=s] .t-flag{margin-left:-1rem}.t-arrow-icon{position:relative;display:flex;width:1.5rem;height:1.5rem;margin:0 0 0 .25rem;-webkit-margin-start:.25rem;margin-inline-start:.25rem;-webkit-margin-end:0;margin-inline-end:0;align-items:center;justify-content:center;box-sizing:border-box;cursor:pointer}:host._readonly .t-arrow-icon,:host._disabled .t-arrow-icon{pointer-events:none}.t-arrow-icon_open{transform:rotate(180deg)}.t-input-phone{flex:1}.t-flag{width:1.75rem;height:1.25rem;margin-left:-.5rem}.t-country-item-flag{width:1.75rem;height:1.25rem}.t-country-item-name{margin-left:.75rem;margin-right:auto}.t-country-item-code{color:var(--tui-text-02);margin-right:.25rem}\n"], components: [{ type: i1__namespace.TuiHostedDropdownComponent, selector: "tui-hosted-dropdown", inputs: ["content", "sided", "canOpen", "open"], outputs: ["openChange", "focusedChange"] }, { type: i1__namespace.TuiPrimitiveTextfieldComponent, selector: "tui-primitive-textfield", inputs: ["editable", "filler", "iconCleaner", "readOnly", "invalid", "disabled", "prefix", "postfix", "value"], outputs: ["valueChange"] }, { type: i2__namespace.TuiInputPhoneComponent, selector: "tui-input-phone", inputs: ["countryCode", "phoneMaskAfterCountryCode", "allowText", "search"], outputs: ["searchChange"] }, { type: i1__namespace.TuiTextfieldComponent, selector: "input[tuiTextfield], textarea[tuiTextfield]" }, { type: i1__namespace.TuiDataListComponent, selector: "tui-data-list", inputs: ["role", "emptyContent", "size"] }, { type: i1__namespace.TuiOptionComponent, selector: "button[tuiOption], a[tuiOption]", inputs: ["size", "role", "disabled", "value"] }], directives: [{ type: i3__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4__namespace.TuiActiveZoneDirective, selector: "[tuiActiveZone]:not(ng-container), [tuiActiveZoneChange]:not(ng-container), [tuiActiveZoneParent]:not(ng-container)", inputs: ["tuiActiveZoneParent"], outputs: ["tuiActiveZoneChange"], exportAs: ["tuiActiveZone"] }, { type: i1__namespace.TuiGroupDirective, selector: "[tuiGroup]:not(ng-container)", inputs: ["orientation", "adaptive", "collapsed", "rounded", "size"] }, { type: i1__namespace.TuiPrimitiveTextfieldDirective, selector: "tui-primitive-textfield" }, { type: i1__namespace.TuiHintOptionsDirective, selector: "[tuiHintContent]", inputs: ["tuiHintContent", "tuiHintDirection", "tuiHintAppearance", "tuiHintShowDelay", "tuiHintHideDelay"] }, { type: i1__namespace.TuiTextfieldPrefixDirective, selector: "[tuiTextfieldPrefix]", inputs: ["tuiTextfieldPrefix"] }, { type: i1__namespace.TuiTextfieldPostfixDirective, selector: "[tuiTextfieldPostfix]", inputs: ["tuiTextfieldPostfix"] }, { type: i1__namespace.TuiTextfieldCustomContentDirective, selector: "[tuiTextfieldCustomContent]", inputs: ["tuiTextfieldCustomContent"] }, { type: i1__namespace.TuiTextfieldLabelOutsideDirective, selector: "[tuiTextfieldLabelOutside]", inputs: ["tuiTextfieldLabelOutside"] }, { type: i1__namespace.TuiTextfieldIconDirective, selector: "[tuiTextfieldIcon]", inputs: ["tuiTextfieldIcon"] }, { type: i2__namespace.TuiInputPhoneDirective, selector: "tui-input-phone" }, { type: i5__namespace.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5__namespace.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i3__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i1__namespace.TuiWrapperDirective, selector: "[tuiWrapper]", inputs: ["disabled", "readOnly", "hover", "active", "focus", "invalid", "appearance"] }, { type: i6__namespace.PolymorpheusOutletDirective, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }], pipes: { "async": i3__namespace.AsyncPipe, "tuiFlag": i1__namespace.TuiFlagPipe, "tuiMapper": i4__namespace.TuiMapperPipe }, viewProviders: [providers.FIXED_DROPDOWN_CONTROLLER_PROVIDER], changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
764
523
|
__decorate([
|
|
765
524
|
i4.tuiDefaultProp()
|
|
@@ -779,6 +538,7 @@
|
|
|
779
538
|
i4.tuiAsControl(TuiInputPhoneInternationalComponent),
|
|
780
539
|
// TODO: for backward compatibility only. Drop in v4.0
|
|
781
540
|
i1.TuiFlagPipe,
|
|
541
|
+
i8.TuiToCountryCodePipe,
|
|
782
542
|
],
|
|
783
543
|
viewProviders: [providers.FIXED_DROPDOWN_CONTROLLER_PROVIDER],
|
|
784
544
|
}]
|
|
@@ -798,13 +558,16 @@
|
|
|
798
558
|
args: [tokens.TUI_COUNTRIES]
|
|
799
559
|
}] }, { type: undefined, decorators: [{
|
|
800
560
|
type: i0.Inject,
|
|
801
|
-
args: [TUI_COUNTRIES_MASKS]
|
|
561
|
+
args: [tokens.TUI_COUNTRIES_MASKS]
|
|
802
562
|
}] }, { type: undefined, decorators: [{
|
|
803
563
|
type: i0.Inject,
|
|
804
564
|
args: [TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS]
|
|
805
565
|
}] }, { type: i1__namespace.TuiFlagPipe, decorators: [{
|
|
806
566
|
type: i0.Inject,
|
|
807
567
|
args: [i1.TuiFlagPipe]
|
|
568
|
+
}] }, { type: i8__namespace.TuiToCountryCodePipe, decorators: [{
|
|
569
|
+
type: i0.Inject,
|
|
570
|
+
args: [i8.TuiToCountryCodePipe]
|
|
808
571
|
}] }];
|
|
809
572
|
}, propDecorators: { inputPhoneComponent: [{
|
|
810
573
|
type: i0.ViewChild,
|
|
@@ -900,15 +663,12 @@
|
|
|
900
663
|
* Generated bundle index. Do not edit.
|
|
901
664
|
*/
|
|
902
665
|
|
|
903
|
-
exports.MASK_AFTER_CODE_REGEXP = MASK_AFTER_CODE_REGEXP;
|
|
904
|
-
exports.TUI_COUNTRIES_MASKS = TUI_COUNTRIES_MASKS;
|
|
905
666
|
exports.TUI_INPUT_PHONE_INTERNATIONAL_DEFAULT_OPTIONS = TUI_INPUT_PHONE_INTERNATIONAL_DEFAULT_OPTIONS;
|
|
906
667
|
exports.TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS = TUI_INPUT_PHONE_INTERNATIONAL_OPTIONS;
|
|
907
668
|
exports.TuiInputPhoneInternationalComponent = TuiInputPhoneInternationalComponent;
|
|
908
669
|
exports.TuiInputPhoneInternationalModule = TuiInputPhoneInternationalModule;
|
|
909
670
|
exports.tuiExtractValueFromEvent = tuiExtractValueFromEvent;
|
|
910
671
|
exports.tuiInputPhoneInternationalOptionsProvider = tuiInputPhoneInternationalOptionsProvider;
|
|
911
|
-
exports.tuiNotKzRegion = tuiNotKzRegion;
|
|
912
672
|
|
|
913
673
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
914
674
|
|