@taiga-ui/core 3.17.0 → 3.18.0

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 (99) hide show
  1. package/bundles/taiga-ui-core-abstract.umd.js +1 -0
  2. package/bundles/taiga-ui-core-abstract.umd.js.map +1 -1
  3. package/bundles/taiga-ui-core-components-dialog.umd.js +189 -167
  4. package/bundles/taiga-ui-core-components-dialog.umd.js.map +1 -1
  5. package/bundles/taiga-ui-core-components-notification.umd.js +2 -2
  6. package/bundles/taiga-ui-core-components-notification.umd.js.map +1 -1
  7. package/bundles/taiga-ui-core-components-primitive-textfield.umd.js +1 -1
  8. package/bundles/taiga-ui-core-components-primitive-textfield.umd.js.map +1 -1
  9. package/bundles/taiga-ui-core-components-root.umd.js +1 -1
  10. package/bundles/taiga-ui-core-components-svg.umd.js +100 -20
  11. package/bundles/taiga-ui-core-components-svg.umd.js.map +1 -1
  12. package/bundles/taiga-ui-core-components-tooltip.umd.js +31 -13
  13. package/bundles/taiga-ui-core-components-tooltip.umd.js.map +1 -1
  14. package/bundles/taiga-ui-core-directives-dropdown.umd.js +45 -25
  15. package/bundles/taiga-ui-core-directives-dropdown.umd.js.map +1 -1
  16. package/bundles/taiga-ui-core-directives-hint.umd.js +67 -63
  17. package/bundles/taiga-ui-core-directives-hint.umd.js.map +1 -1
  18. package/bundles/taiga-ui-core-tokens.umd.js +39 -1
  19. package/bundles/taiga-ui-core-tokens.umd.js.map +1 -1
  20. package/components/dialog/dialog-close.service.d.ts +15 -0
  21. package/components/dialog/dialog.component.d.ts +5 -4
  22. package/components/dialog/dialog.tokens.d.ts +2 -0
  23. package/components/dialog/index.d.ts +1 -1
  24. package/components/notification/notification.component.d.ts +2 -2
  25. package/components/svg/deprecated-icons.d.ts +1 -0
  26. package/components/svg/index.d.ts +2 -0
  27. package/components/svg/svg-options.d.ts +14 -0
  28. package/components/svg/svg.component.d.ts +5 -7
  29. package/components/tooltip/tooltip.component.d.ts +2 -2
  30. package/components/tooltip/tooltip.module.d.ts +5 -4
  31. package/directives/dropdown/dropdown-hover-options.directive.d.ts +9 -0
  32. package/directives/dropdown/dropdown-hover.directive.d.ts +3 -1
  33. package/directives/dropdown/dropdown-position-sided.directive.d.ts +2 -2
  34. package/directives/dropdown/dropdown-position.directive.d.ts +2 -2
  35. package/directives/dropdown/index.d.ts +1 -0
  36. package/directives/hint/hint-hover.directive.d.ts +4 -2
  37. package/directives/hint/hint-position.directive.d.ts +2 -2
  38. package/esm2015/abstract/rect-accessor.js +2 -1
  39. package/esm2015/components/dialog/dialog-close.service.js +51 -0
  40. package/esm2015/components/dialog/dialog.component.js +26 -10
  41. package/esm2015/components/dialog/dialog.tokens.js +5 -1
  42. package/esm2015/components/dialog/index.js +2 -2
  43. package/esm2015/components/notification/notification.component.js +3 -3
  44. package/esm2015/components/primitive-textfield/primitive-textfield.component.js +2 -2
  45. package/esm2015/components/root/root.component.js +1 -1
  46. package/esm2015/components/svg/deprecated-icons.js +59 -0
  47. package/esm2015/components/svg/index.js +3 -1
  48. package/esm2015/components/svg/svg-options.js +29 -0
  49. package/esm2015/components/svg/svg.component.js +13 -18
  50. package/esm2015/components/tooltip/tooltip.component.js +13 -13
  51. package/esm2015/components/tooltip/tooltip.module.js +21 -4
  52. package/esm2015/directives/dropdown/dropdown-hover-options.directive.js +14 -0
  53. package/esm2015/directives/dropdown/dropdown-hover.directive.js +10 -5
  54. package/esm2015/directives/dropdown/dropdown-position-sided.directive.js +12 -12
  55. package/esm2015/directives/dropdown/dropdown-position.directive.js +11 -11
  56. package/esm2015/directives/dropdown/index.js +2 -1
  57. package/esm2015/directives/hint/hint-hover.directive.js +13 -10
  58. package/esm2015/directives/hint/hint-options.directive.js +2 -2
  59. package/esm2015/directives/hint/hint-position.directive.js +12 -11
  60. package/esm2015/directives/hint/hint.component.js +3 -2
  61. package/esm2015/interfaces/dialog-options.js +1 -1
  62. package/esm2015/tokens/icon-place.js +5 -2
  63. package/esm2015/tokens/icons-path.js +4 -1
  64. package/esm2015/tokens/index.js +2 -1
  65. package/esm2015/tokens/svg-content-processor.js +4 -1
  66. package/esm2015/tokens/svg-src-processor.js +4 -1
  67. package/esm2015/tokens/viewport.js +26 -0
  68. package/fesm2015/taiga-ui-core-abstract.js +1 -0
  69. package/fesm2015/taiga-ui-core-abstract.js.map +1 -1
  70. package/fesm2015/taiga-ui-core-components-dialog.js +85 -69
  71. package/fesm2015/taiga-ui-core-components-dialog.js.map +1 -1
  72. package/fesm2015/taiga-ui-core-components-notification.js +2 -2
  73. package/fesm2015/taiga-ui-core-components-notification.js.map +1 -1
  74. package/fesm2015/taiga-ui-core-components-primitive-textfield.js +1 -1
  75. package/fesm2015/taiga-ui-core-components-primitive-textfield.js.map +1 -1
  76. package/fesm2015/taiga-ui-core-components-root.js +1 -1
  77. package/fesm2015/taiga-ui-core-components-svg.js +98 -21
  78. package/fesm2015/taiga-ui-core-components-svg.js.map +1 -1
  79. package/fesm2015/taiga-ui-core-components-tooltip.js +32 -15
  80. package/fesm2015/taiga-ui-core-components-tooltip.js.map +1 -1
  81. package/fesm2015/taiga-ui-core-directives-dropdown.js +42 -25
  82. package/fesm2015/taiga-ui-core-directives-dropdown.js.map +1 -1
  83. package/fesm2015/taiga-ui-core-directives-hint.js +30 -27
  84. package/fesm2015/taiga-ui-core-directives-hint.js.map +1 -1
  85. package/fesm2015/taiga-ui-core-tokens.js +38 -2
  86. package/fesm2015/taiga-ui-core-tokens.js.map +1 -1
  87. package/interfaces/dialog-options.d.ts +4 -3
  88. package/package.json +4 -4
  89. package/styles/mixins/textfield.less +4 -22
  90. package/styles/mixins/textfield.scss +3 -22
  91. package/styles/theme/wrapper/icon.less +17 -27
  92. package/tokens/icon-place.d.ts +3 -0
  93. package/tokens/icons-path.d.ts +3 -0
  94. package/tokens/index.d.ts +1 -0
  95. package/tokens/svg-content-processor.d.ts +3 -0
  96. package/tokens/svg-src-processor.d.ts +3 -0
  97. package/tokens/viewport.d.ts +4 -0
  98. package/components/dialog/dialog.providers.d.ts +0 -5
  99. package/esm2015/components/dialog/dialog.providers.js +0 -51
@@ -1,8 +1,8 @@
1
1
  (function (global, factory) {
2
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@taiga-ui/cdk'), require('@taiga-ui/core/abstract'), require('@taiga-ui/core/animations'), require('@taiga-ui/core/directives/mode'), require('@taiga-ui/core/services'), require('@taiga-ui/core/tokens'), require('@tinkoff/ng-polymorpheus'), require('rxjs/operators'), require('rxjs'), require('@taiga-ui/core/utils'), require('@angular/common'), require('@ng-web-apis/common'), require('@taiga-ui/core/constants')) :
3
- typeof define === 'function' && define.amd ? define('@taiga-ui/core/directives/hint', ['exports', '@angular/core', '@taiga-ui/cdk', '@taiga-ui/core/abstract', '@taiga-ui/core/animations', '@taiga-ui/core/directives/mode', '@taiga-ui/core/services', '@taiga-ui/core/tokens', '@tinkoff/ng-polymorpheus', 'rxjs/operators', 'rxjs', '@taiga-ui/core/utils', '@angular/common', '@ng-web-apis/common', '@taiga-ui/core/constants'], factory) :
4
- (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global["taiga-ui"] = global["taiga-ui"] || {}, global["taiga-ui"].core = global["taiga-ui"].core || {}, global["taiga-ui"].core.directives = global["taiga-ui"].core.directives || {}, global["taiga-ui"].core.directives.hint = {}), global.ng.core, global.i3, global["taiga-ui"].core.abstract, global["taiga-ui"].core.animations, global["taiga-ui"].core.directives.mode, global["taiga-ui"].core.services, global["taiga-ui"].core.tokens, global.i1, global.rxjs.operators, global.rxjs, global["taiga-ui"].core.utils, global.ng.common, global.common$1, global["taiga-ui"].core.constants));
5
- })(this, (function (exports, i0, i3, i3$1, animations, i5, i2$1, tokens, i1, operators, i2, utils, common, common$1, constants) { 'use strict';
2
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@taiga-ui/cdk'), require('@taiga-ui/core/abstract'), require('@taiga-ui/core/animations'), require('@taiga-ui/core/directives/mode'), require('@taiga-ui/core/services'), require('@taiga-ui/core/tokens'), require('@tinkoff/ng-polymorpheus'), require('rxjs/operators'), require('rxjs'), require('@taiga-ui/core/utils'), require('@angular/common'), require('@taiga-ui/core/constants')) :
3
+ typeof define === 'function' && define.amd ? define('@taiga-ui/core/directives/hint', ['exports', '@angular/core', '@taiga-ui/cdk', '@taiga-ui/core/abstract', '@taiga-ui/core/animations', '@taiga-ui/core/directives/mode', '@taiga-ui/core/services', '@taiga-ui/core/tokens', '@tinkoff/ng-polymorpheus', 'rxjs/operators', 'rxjs', '@taiga-ui/core/utils', '@angular/common', '@taiga-ui/core/constants'], factory) :
4
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global["taiga-ui"] = global["taiga-ui"] || {}, global["taiga-ui"].core = global["taiga-ui"].core || {}, global["taiga-ui"].core.directives = global["taiga-ui"].core.directives || {}, global["taiga-ui"].core.directives.hint = {}), global.ng.core, global.i3, global["taiga-ui"].core.abstract, global["taiga-ui"].core.animations, global["taiga-ui"].core.directives.mode, global["taiga-ui"].core.services, global["taiga-ui"].core.tokens, global.i1$1, global.rxjs.operators, global.rxjs, global["taiga-ui"].core.utils, global.ng.common, global["taiga-ui"].core.constants));
5
+ })(this, (function (exports, i0, i3, i1, animations, i5, i2$1, tokens, i1$1, operators, i2, utils, common, constants) { 'use strict';
6
6
 
7
7
  function _interopNamespace(e) {
8
8
  if (e && e.__esModule) return e;
@@ -23,11 +23,11 @@
23
23
  }
24
24
 
25
25
  var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
26
- var i3__namespace$1 = /*#__PURE__*/_interopNamespace(i3);
27
- var i3__namespace = /*#__PURE__*/_interopNamespace(i3$1);
26
+ var i3__namespace = /*#__PURE__*/_interopNamespace(i3);
27
+ var i1__namespace$1 = /*#__PURE__*/_interopNamespace(i1);
28
28
  var i5__namespace = /*#__PURE__*/_interopNamespace(i5);
29
29
  var i2__namespace$1 = /*#__PURE__*/_interopNamespace(i2$1);
30
- var i1__namespace = /*#__PURE__*/_interopNamespace(i1);
30
+ var i1__namespace = /*#__PURE__*/_interopNamespace(i1$1);
31
31
  var i2__namespace = /*#__PURE__*/_interopNamespace(i2);
32
32
 
33
33
  /******************************************************************************
@@ -363,7 +363,7 @@
363
363
  showDelay: 500,
364
364
  hideDelay: 200,
365
365
  appearance: '',
366
- icon: 'tuiIconTooltipLarge',
366
+ icon: 'tuiIconHelpCircle',
367
367
  };
368
368
  var TUI_HINT_OPTIONS = new i0.InjectionToken('[TUI_HINT_OPTIONS] Default parameters for hint directive', {
369
369
  factory: function () { return TUI_HINT_DEFAULT_OPTIONS; },
@@ -450,12 +450,13 @@
450
450
 
451
451
  var TuiHintHoverDirective = /** @class */ (function (_super) {
452
452
  __extends(TuiHintHoverDirective, _super);
453
- function TuiHintHoverDirective(hovered$, options) {
453
+ function TuiHintHoverDirective(hovered$, options, elementRef) {
454
454
  var _this = _super.call(this, function (subscriber) { return _this.stream$.subscribe(subscriber); }) || this;
455
455
  _this.hovered$ = hovered$;
456
456
  _this.options = options;
457
+ _this.elementRef = elementRef;
457
458
  _this.toggle$ = new i2.Subject();
458
- _this.stream$ = i2.merge(_this.toggle$, _this.hovered$).pipe(operators.switchMap(function (visible) { return i2.of(visible).pipe(operators.delay(visible ? _this.showDelay : _this.hideDelay)); }));
459
+ _this.stream$ = i2.merge(_this.toggle$.pipe(operators.switchMap(function (visible) { return i2.of(visible).pipe(operators.delay(visible ? 0 : _this.hideDelay)); }), operators.takeUntil(_this.hovered$), operators.repeat()), _this.hovered$.pipe(operators.switchMap(function (visible) { return i2.of(visible).pipe(operators.delay(visible ? _this.showDelay : _this.hideDelay)); }), operators.takeUntil(_this.toggle$), operators.repeat()));
459
460
  _this.showDelay = _this.options.showDelay;
460
461
  _this.hideDelay = _this.options.hideDelay;
461
462
  return _this;
@@ -464,9 +465,9 @@
464
465
  this.toggle$.next(visible);
465
466
  };
466
467
  return TuiHintHoverDirective;
467
- }(i3$1.TuiDriver));
468
- TuiHintHoverDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintHoverDirective, deps: [{ token: i3.TuiHoveredService }, { token: TUI_HINT_OPTIONS }], target: i0__namespace.ɵɵFactoryTarget.Directive });
469
- TuiHintHoverDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintHoverDirective, selector: "[tuiHint]:not(ng-container)", inputs: { showDelay: ["tuiHintShowDelay", "showDelay"], hideDelay: ["tuiHintHideDelay", "hideDelay"] }, host: { listeners: { "click": "toggle(true)" } }, providers: [i3$1.tuiAsDriver(TuiHintHoverDirective), i3.TuiHoveredService], usesInheritance: true, ngImport: i0__namespace });
468
+ }(i1.TuiDriver));
469
+ TuiHintHoverDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintHoverDirective, deps: [{ token: i3.TuiHoveredService }, { token: TUI_HINT_OPTIONS }, { token: i0.ElementRef }], target: i0__namespace.ɵɵFactoryTarget.Directive });
470
+ TuiHintHoverDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintHoverDirective, selector: "[tuiHint]:not(ng-container)", inputs: { showDelay: ["tuiHintShowDelay", "showDelay"], hideDelay: ["tuiHintHideDelay", "hideDelay"] }, providers: [i1.tuiAsDriver(TuiHintHoverDirective), i3.TuiHoveredService], exportAs: ["tuiHintHover"], usesInheritance: true, ngImport: i0__namespace });
470
471
  __decorate([
471
472
  i3.tuiDefaultProp()
472
473
  ], TuiHintHoverDirective.prototype, "showDelay", void 0);
@@ -477,7 +478,8 @@
477
478
  type: i0.Directive,
478
479
  args: [{
479
480
  selector: '[tuiHint]:not(ng-container)',
480
- providers: [i3$1.tuiAsDriver(TuiHintHoverDirective), i3.TuiHoveredService],
481
+ exportAs: 'tuiHintHover',
482
+ providers: [i1.tuiAsDriver(TuiHintHoverDirective), i3.TuiHoveredService],
481
483
  }]
482
484
  }], ctorParameters: function () {
483
485
  return [{ type: i2__namespace.Observable, decorators: [{
@@ -486,6 +488,9 @@
486
488
  }] }, { type: undefined, decorators: [{
487
489
  type: i0.Inject,
488
490
  args: [TUI_HINT_OPTIONS]
491
+ }] }, { type: i0__namespace.ElementRef, decorators: [{
492
+ type: i0.Inject,
493
+ args: [i0.ElementRef]
489
494
  }] }];
490
495
  }, propDecorators: { showDelay: [{
491
496
  type: i0.Input,
@@ -493,9 +498,6 @@
493
498
  }], hideDelay: [{
494
499
  type: i0.Input,
495
500
  args: ['tuiHintHideDelay']
496
- }], toggle: [{
497
- type: i0.HostListener,
498
- args: ['click', ['true']]
499
501
  }] } });
500
502
 
501
503
  var TuiHintPointerDirective = /** @class */ (function (_super) {
@@ -516,16 +518,16 @@
516
518
  }(TuiHintHoverDirective));
517
519
  TuiHintPointerDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintPointerDirective, deps: null, target: i0__namespace.ɵɵFactoryTarget.Directive });
518
520
  TuiHintPointerDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintPointerDirective, selector: "[tuiHint][tuiHintPointer]", host: { listeners: { "mousemove.silent": "onMove($event)" } }, providers: [
519
- i3$1.tuiAsRectAccessor(TuiHintPointerDirective),
520
- i3$1.tuiAsDriver(TuiHintPointerDirective),
521
+ i1.tuiAsRectAccessor(TuiHintPointerDirective),
522
+ i1.tuiAsDriver(TuiHintPointerDirective),
521
523
  ], usesInheritance: true, ngImport: i0__namespace });
522
524
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintPointerDirective, decorators: [{
523
525
  type: i0.Directive,
524
526
  args: [{
525
527
  selector: '[tuiHint][tuiHintPointer]',
526
528
  providers: [
527
- i3$1.tuiAsRectAccessor(TuiHintPointerDirective),
528
- i3$1.tuiAsDriver(TuiHintPointerDirective),
529
+ i1.tuiAsRectAccessor(TuiHintPointerDirective),
530
+ i1.tuiAsDriver(TuiHintPointerDirective),
529
531
  ],
530
532
  }]
531
533
  }], propDecorators: { onMove: [{
@@ -568,7 +570,8 @@
568
570
  configurable: true
569
571
  });
570
572
  TuiHintComponent.prototype.onClick = function (target) {
571
- if (!this.elementRef.nativeElement.contains(target)) {
573
+ if (!this.elementRef.nativeElement.contains(target) &&
574
+ !this.hover.elementRef.nativeElement.contains(target)) {
572
575
  this.hover.toggle(false);
573
576
  }
574
577
  };
@@ -587,7 +590,7 @@
587
590
  };
588
591
  return TuiHintComponent;
589
592
  }());
590
- TuiHintComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintComponent, deps: [{ token: i3.TuiHoveredService }, { token: i2$1.TuiPositionService }, { token: i3.TuiDestroyService, self: true }, { token: i3$1.TuiRectAccessor }, { token: i0.ElementRef }, { token: tokens.TUI_ANIMATION_OPTIONS }, { token: i1.POLYMORPHEUS_CONTEXT }, { token: TuiHintHoverDirective }, { token: TuiHintPointerDirective, optional: true }, { token: i5.TuiModeDirective, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Component });
593
+ TuiHintComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintComponent, deps: [{ token: i3.TuiHoveredService }, { token: i2$1.TuiPositionService }, { token: i3.TuiDestroyService, self: true }, { token: i1.TuiRectAccessor }, { token: i0.ElementRef }, { token: tokens.TUI_ANIMATION_OPTIONS }, { token: i1$1.POLYMORPHEUS_CONTEXT }, { token: TuiHintHoverDirective }, { token: TuiHintPointerDirective, optional: true }, { token: i5.TuiModeDirective, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Component });
591
594
  TuiHintComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintComponent, selector: "tui-hint", host: { listeners: { "document:click": "onClick($event.target)" }, properties: { "@tuiFadeIn": "this.animation", "attr.data-appearance": "this.appearance", "class._untouchable": "this.untouchable" } }, providers: [i3.TuiDestroyService, i2$1.TuiPositionService, i3.TuiHoveredService], ngImport: i0__namespace, template: "\n <ng-container *polymorpheusOutlet=\"content as text; context: context\">\n {{ text }}\n </ng-container>\n ", isInline: true, styles: [":host{position:absolute;max-width:18rem;min-height:var(--tui-height-m);padding:.75rem 1rem;background:var(--tui-primary);border-radius:var(--tui-radius-l);color:var(--tui-primary-text);box-sizing:border-box;font:var(--tui-font-text-s);white-space:pre-line;word-wrap:break-word}:host:before{content:\"\";position:absolute;top:var(--top);left:var(--left);width:.5rem;height:.5rem;border-radius:.125rem;box-sizing:border-box;background:inherit;transform:translate(-50%,-50%) rotate(45deg)}:host[data-appearance=error]{background:var(--tui-error-fill)}:host[data-appearance=onDark]{background:var(--tui-elevation-01);color:var(--tui-text-01);filter:drop-shadow(0 0 .125rem rgba(0,0,0,.16)) drop-shadow(0 1.5rem 1rem rgba(0,0,0,.03)) drop-shadow(0 .75rem .75rem rgba(0,0,0,.04)) drop-shadow(0 .25rem .375rem rgba(0,0,0,.05))}:host:not([style*=\"top\"]){visibility:hidden}:host._untouchable{pointer-events:none}\n"], directives: [{ type: i1__namespace.PolymorpheusOutletDirective, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }], animations: [animations.tuiFadeIn], changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
592
595
  __decorate([
593
596
  i3.tuiPure
@@ -614,9 +617,9 @@
614
617
  }, {
615
618
  type: i0.Inject,
616
619
  args: [i3.TuiDestroyService]
617
- }] }, { type: i3__namespace.TuiRectAccessor, decorators: [{
620
+ }] }, { type: i1__namespace$1.TuiRectAccessor, decorators: [{
618
621
  type: i0.Inject,
619
- args: [i3$1.TuiRectAccessor]
622
+ args: [i1.TuiRectAccessor]
620
623
  }] }, { type: i0__namespace.ElementRef, decorators: [{
621
624
  type: i0.Inject,
622
625
  args: [i0.ElementRef]
@@ -625,7 +628,7 @@
625
628
  args: [tokens.TUI_ANIMATION_OPTIONS]
626
629
  }] }, { type: undefined, decorators: [{
627
630
  type: i0.Inject,
628
- args: [i1.POLYMORPHEUS_CONTEXT]
631
+ args: [i1$1.POLYMORPHEUS_CONTEXT]
629
632
  }] }, { type: TuiHintHoverDirective, decorators: [{
630
633
  type: i0.Inject,
631
634
  args: [TuiHintHoverDirective]
@@ -697,14 +700,14 @@
697
700
  };
698
701
  return TuiHintDirective;
699
702
  }());
700
- TuiHintDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintDirective, deps: [{ token: i0.ElementRef }, { token: i1.PolymorpheusComponent }, { token: i2$1.TuiHintService }, { token: TUI_HINT_OPTIONS }, { token: i3.TuiActiveZoneDirective, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Directive });
703
+ TuiHintDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintDirective, deps: [{ token: i0.ElementRef }, { token: i1$1.PolymorpheusComponent }, { token: i2$1.TuiHintService }, { token: TUI_HINT_OPTIONS }, { token: i3.TuiActiveZoneDirective, optional: true }], target: i0__namespace.ɵɵFactoryTarget.Directive });
701
704
  TuiHintDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintDirective, selector: "[tuiHint]:not(ng-container)", inputs: { content: ["tuiHint", "content"], context: ["tuiHintContext", "context"], tuiHintAppearance: "tuiHintAppearance" }, providers: [
702
- i3$1.tuiAsRectAccessor(TuiHintDirective),
703
- i3$1.tuiAsVehicle(TuiHintDirective),
705
+ i1.tuiAsRectAccessor(TuiHintDirective),
706
+ i1.tuiAsVehicle(TuiHintDirective),
704
707
  {
705
- provide: i1.PolymorpheusComponent,
708
+ provide: i1$1.PolymorpheusComponent,
706
709
  deps: [TUI_HINT_COMPONENT, i0.INJECTOR],
707
- useClass: i1.PolymorpheusComponent,
710
+ useClass: i1$1.PolymorpheusComponent,
708
711
  },
709
712
  ], usesOnChanges: true, ngImport: i0__namespace });
710
713
  __decorate([
@@ -718,12 +721,12 @@
718
721
  args: [{
719
722
  selector: '[tuiHint]:not(ng-container)',
720
723
  providers: [
721
- i3$1.tuiAsRectAccessor(TuiHintDirective),
722
- i3$1.tuiAsVehicle(TuiHintDirective),
724
+ i1.tuiAsRectAccessor(TuiHintDirective),
725
+ i1.tuiAsVehicle(TuiHintDirective),
723
726
  {
724
- provide: i1.PolymorpheusComponent,
727
+ provide: i1$1.PolymorpheusComponent,
725
728
  deps: [TUI_HINT_COMPONENT, i0.INJECTOR],
726
- useClass: i1.PolymorpheusComponent,
729
+ useClass: i1$1.PolymorpheusComponent,
727
730
  },
728
731
  ],
729
732
  }]
@@ -733,14 +736,14 @@
733
736
  args: [i0.ElementRef]
734
737
  }] }, { type: i1__namespace.PolymorpheusComponent, decorators: [{
735
738
  type: i0.Inject,
736
- args: [i1.PolymorpheusComponent]
739
+ args: [i1$1.PolymorpheusComponent]
737
740
  }] }, { type: i2__namespace$1.TuiHintService, decorators: [{
738
741
  type: i0.Inject,
739
742
  args: [i2$1.TuiHintService]
740
743
  }] }, { type: undefined, decorators: [{
741
744
  type: i0.Inject,
742
745
  args: [TUI_HINT_OPTIONS]
743
- }] }, { type: i3__namespace$1.TuiActiveZoneDirective, decorators: [{
746
+ }] }, { type: i3__namespace.TuiActiveZoneDirective, decorators: [{
744
747
  type: i0.Optional
745
748
  }, {
746
749
  type: i0.Inject,
@@ -789,9 +792,9 @@
789
792
  configurable: true
790
793
  });
791
794
  return TuiHintDescribeDirective;
792
- }(i3$1.TuiDriver));
795
+ }(i1.TuiDriver));
793
796
  TuiHintDescribeDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintDescribeDirective, deps: [{ token: i0.NgZone }, { token: TuiHintHoverDirective }, { token: common.DOCUMENT }, { token: i0.ElementRef }], target: i0__namespace.ɵɵFactoryTarget.Directive });
794
- TuiHintDescribeDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintDescribeDirective, selector: "[tuiHintDescribe]", inputs: { tuiHintDescribe: "tuiHintDescribe" }, providers: [i3$1.tuiAsDriver(TuiHintDescribeDirective)], usesInheritance: true, ngImport: i0__namespace });
797
+ TuiHintDescribeDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintDescribeDirective, selector: "[tuiHintDescribe]", inputs: { tuiHintDescribe: "tuiHintDescribe" }, providers: [i1.tuiAsDriver(TuiHintDescribeDirective)], usesInheritance: true, ngImport: i0__namespace });
795
798
  __decorate([
796
799
  i3.tuiPure
797
800
  ], TuiHintDescribeDirective.prototype, "element", null);
@@ -799,7 +802,7 @@
799
802
  type: i0.Directive,
800
803
  args: [{
801
804
  selector: '[tuiHintDescribe]',
802
- providers: [i3$1.tuiAsDriver(TuiHintDescribeDirective)],
805
+ providers: [i1.tuiAsDriver(TuiHintDescribeDirective)],
803
806
  }]
804
807
  }], ctorParameters: function () {
805
808
  return [{ type: i0__namespace.NgZone, decorators: [{
@@ -825,7 +828,7 @@
825
828
  return _super !== null && _super.apply(this, arguments) || this;
826
829
  }
827
830
  return TuiHintDriverDirective;
828
- }(i3$1.AbstractTuiDriverDirective));
831
+ }(i1.AbstractTuiDriverDirective));
829
832
  TuiHintDriverDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintDriverDirective, deps: null, target: i0__namespace.ɵɵFactoryTarget.Directive });
830
833
  TuiHintDriverDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintDriverDirective, selector: "[tuiHint]", providers: [i3.TuiDestroyService], usesInheritance: true, ngImport: i0__namespace });
831
834
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintDriverDirective, decorators: [{
@@ -846,14 +849,14 @@
846
849
  return ((_a = this.tuiHintHost) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect()) || i3.EMPTY_CLIENT_RECT;
847
850
  };
848
851
  return TuiHintHostDirective;
849
- }(i3$1.TuiRectAccessor));
852
+ }(i1.TuiRectAccessor));
850
853
  TuiHintHostDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintHostDirective, deps: null, target: i0__namespace.ɵɵFactoryTarget.Directive });
851
- TuiHintHostDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintHostDirective, selector: "[tuiHint][tuiHintHost]", inputs: { tuiHintHost: "tuiHintHost" }, providers: [i3$1.tuiAsRectAccessor(TuiHintHostDirective)], usesInheritance: true, ngImport: i0__namespace });
854
+ TuiHintHostDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintHostDirective, selector: "[tuiHint][tuiHintHost]", inputs: { tuiHintHost: "tuiHintHost" }, providers: [i1.tuiAsRectAccessor(TuiHintHostDirective)], usesInheritance: true, ngImport: i0__namespace });
852
855
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintHostDirective, decorators: [{
853
856
  type: i0.Directive,
854
857
  args: [{
855
858
  selector: '[tuiHint][tuiHintHost]',
856
- providers: [i3$1.tuiAsRectAccessor(TuiHintHostDirective)],
859
+ providers: [i1.tuiAsRectAccessor(TuiHintHostDirective)],
857
860
  }]
858
861
  }], propDecorators: { tuiHintHost: [{
859
862
  type: i0.Input
@@ -871,14 +874,14 @@
871
874
  this.stream$.next(this.tuiHintManual);
872
875
  };
873
876
  return TuiHintManualDirective;
874
- }(i3$1.TuiDriver));
877
+ }(i1.TuiDriver));
875
878
  TuiHintManualDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintManualDirective, deps: [], target: i0__namespace.ɵɵFactoryTarget.Directive });
876
- TuiHintManualDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintManualDirective, selector: "[tuiHint][tuiHintManual]", inputs: { tuiHintManual: "tuiHintManual" }, providers: [i3$1.tuiAsDriver(TuiHintManualDirective)], usesInheritance: true, usesOnChanges: true, ngImport: i0__namespace });
879
+ TuiHintManualDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintManualDirective, selector: "[tuiHint][tuiHintManual]", inputs: { tuiHintManual: "tuiHintManual" }, providers: [i1.tuiAsDriver(TuiHintManualDirective)], usesInheritance: true, usesOnChanges: true, ngImport: i0__namespace });
877
880
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintManualDirective, decorators: [{
878
881
  type: i0.Directive,
879
882
  args: [{
880
883
  selector: '[tuiHint][tuiHintManual]',
881
- providers: [i3$1.tuiAsDriver(TuiHintManualDirective)],
884
+ providers: [i1.tuiAsDriver(TuiHintManualDirective)],
882
885
  }]
883
886
  }], ctorParameters: function () { return []; }, propDecorators: { tuiHintManual: [{
884
887
  type: i0.Input
@@ -889,9 +892,9 @@
889
892
  var TOP = 0;
890
893
  var LEFT = 1;
891
894
  var TuiHintPositionDirective = /** @class */ (function () {
892
- function TuiHintPositionDirective(options, windowRef, accessor) {
895
+ function TuiHintPositionDirective(options, viewport, accessor) {
893
896
  this.options = options;
894
- this.windowRef = windowRef;
897
+ this.viewport = viewport;
895
898
  this.accessor = accessor;
896
899
  this.points = constants.TUI_HINT_DIRECTIONS.reduce(function (acc, direction) {
897
900
  var _a;
@@ -938,7 +941,8 @@
938
941
  };
939
942
  Object.defineProperty(TuiHintPositionDirective.prototype, "fallback", {
940
943
  get: function () {
941
- return this.points.top[TOP] > this.windowRef.innerHeight - this.points.bottom[TOP]
944
+ return this.points.top[TOP] >
945
+ this.viewport.getClientRect().bottom - this.points.bottom[TOP]
942
946
  ? 'top'
943
947
  : 'bottom';
944
948
  },
@@ -947,16 +951,16 @@
947
951
  });
948
952
  TuiHintPositionDirective.prototype.checkPosition = function (_a, width, height) {
949
953
  var _b = __read(_a, 2), top = _b[0], left = _b[1];
950
- var _c = this.windowRef, innerHeight = _c.innerHeight, innerWidth = _c.innerWidth;
954
+ var viewport = this.viewport.getClientRect();
951
955
  return (top > OFFSET &&
952
956
  left > OFFSET &&
953
- top + height < innerHeight - OFFSET &&
954
- left + width < innerWidth - OFFSET);
957
+ top + height < viewport.bottom - OFFSET &&
958
+ left + width < viewport.right - OFFSET);
955
959
  };
956
960
  return TuiHintPositionDirective;
957
961
  }());
958
- TuiHintPositionDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintPositionDirective, deps: [{ token: TUI_HINT_OPTIONS }, { token: common$1.WINDOW }, { token: i3$1.TuiRectAccessor }], target: i0__namespace.ɵɵFactoryTarget.Directive });
959
- TuiHintPositionDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintPositionDirective, selector: "[tuiHint]:not([tuiHintCustomPosition])", inputs: { direction: ["tuiHintDirection", "direction"] }, providers: [i3$1.tuiAsPositionAccessor(TuiHintPositionDirective)], ngImport: i0__namespace });
962
+ TuiHintPositionDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintPositionDirective, deps: [{ token: TUI_HINT_OPTIONS }, { token: tokens.TUI_VIEWPORT }, { token: i1.TuiRectAccessor }], target: i0__namespace.ɵɵFactoryTarget.Directive });
963
+ TuiHintPositionDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TuiHintPositionDirective, selector: "[tuiHint]:not([tuiHintCustomPosition])", inputs: { direction: ["tuiHintDirection", "direction"] }, providers: [i1.tuiAsPositionAccessor(TuiHintPositionDirective)], ngImport: i0__namespace });
960
964
  __decorate([
961
965
  i3.tuiDefaultProp()
962
966
  ], TuiHintPositionDirective.prototype, "direction", void 0);
@@ -964,18 +968,18 @@
964
968
  type: i0.Directive,
965
969
  args: [{
966
970
  selector: '[tuiHint]:not([tuiHintCustomPosition])',
967
- providers: [i3$1.tuiAsPositionAccessor(TuiHintPositionDirective)],
971
+ providers: [i1.tuiAsPositionAccessor(TuiHintPositionDirective)],
968
972
  }]
969
973
  }], ctorParameters: function () {
970
974
  return [{ type: undefined, decorators: [{
971
975
  type: i0.Inject,
972
976
  args: [TUI_HINT_OPTIONS]
973
- }] }, { type: Window, decorators: [{
977
+ }] }, { type: i1__namespace$1.TuiRectAccessor, decorators: [{
974
978
  type: i0.Inject,
975
- args: [common$1.WINDOW]
976
- }] }, { type: i3__namespace.TuiRectAccessor, decorators: [{
979
+ args: [tokens.TUI_VIEWPORT]
980
+ }] }, { type: i1__namespace$1.TuiRectAccessor, decorators: [{
977
981
  type: i0.Inject,
978
- args: [i3$1.TuiRectAccessor]
982
+ args: [i1.TuiRectAccessor]
979
983
  }] }];
980
984
  }, propDecorators: { direction: [{
981
985
  type: i0.Input,
@@ -997,7 +1001,7 @@
997
1001
  TuiHintPointerDirective,
998
1002
  TuiHintDescribeDirective,
999
1003
  TuiHintPositionDirective,
1000
- TuiHintOptionsDirective], imports: [common.CommonModule, i1.PolymorpheusModule], exports: [TuiHintComponent,
1004
+ TuiHintOptionsDirective], imports: [common.CommonModule, i1$1.PolymorpheusModule], exports: [TuiHintComponent,
1001
1005
  TuiHintDirective,
1002
1006
  TuiHintDriverDirective,
1003
1007
  TuiHintHostDirective,
@@ -1007,11 +1011,11 @@
1007
1011
  TuiHintDescribeDirective,
1008
1012
  TuiHintPositionDirective,
1009
1013
  TuiHintOptionsDirective] });
1010
- TuiHintModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintModule, imports: [[common.CommonModule, i1.PolymorpheusModule]] });
1014
+ TuiHintModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintModule, imports: [[common.CommonModule, i1$1.PolymorpheusModule]] });
1011
1015
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TuiHintModule, decorators: [{
1012
1016
  type: i0.NgModule,
1013
1017
  args: [{
1014
- imports: [common.CommonModule, i1.PolymorpheusModule],
1018
+ imports: [common.CommonModule, i1$1.PolymorpheusModule],
1015
1019
  declarations: [
1016
1020
  TuiHintComponent,
1017
1021
  TuiHintDirective,