@taiga-ui/core 5.0.0-rc.0 → 5.0.0-rc.2

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 (81) hide show
  1. package/components/data-list/index.d.ts +1 -0
  2. package/components/data-list/option-content.directive.d.ts +1 -1
  3. package/components/data-list/option-with-content.directive.d.ts +9 -0
  4. package/components/data-list/option-with-value.directive.d.ts +2 -1
  5. package/components/data-list/option.directive.d.ts +0 -4
  6. package/components/textfield/textfield-multi/textfield-item.component.d.ts +1 -0
  7. package/components/textfield/textfield-multi/textfield-multi.component.d.ts +2 -0
  8. package/fesm2022/taiga-ui-core-classes.mjs +3 -3
  9. package/fesm2022/taiga-ui-core-components-button.mjs +8 -7
  10. package/fesm2022/taiga-ui-core-components-button.mjs.map +1 -1
  11. package/fesm2022/taiga-ui-core-components-calendar.mjs +23 -33
  12. package/fesm2022/taiga-ui-core-components-calendar.mjs.map +1 -1
  13. package/fesm2022/taiga-ui-core-components-cell.mjs +7 -7
  14. package/fesm2022/taiga-ui-core-components-cell.mjs.map +1 -1
  15. package/fesm2022/taiga-ui-core-components-data-list.mjs +43 -34
  16. package/fesm2022/taiga-ui-core-components-data-list.mjs.map +1 -1
  17. package/fesm2022/taiga-ui-core-components-error.mjs +10 -12
  18. package/fesm2022/taiga-ui-core-components-error.mjs.map +1 -1
  19. package/fesm2022/taiga-ui-core-components-expand.mjs +3 -3
  20. package/fesm2022/taiga-ui-core-components-icon.mjs +8 -12
  21. package/fesm2022/taiga-ui-core-components-icon.mjs.map +1 -1
  22. package/fesm2022/taiga-ui-core-components-input.mjs +6 -6
  23. package/fesm2022/taiga-ui-core-components-label.mjs +9 -7
  24. package/fesm2022/taiga-ui-core-components-label.mjs.map +1 -1
  25. package/fesm2022/taiga-ui-core-components-link.mjs +8 -7
  26. package/fesm2022/taiga-ui-core-components-link.mjs.map +1 -1
  27. package/fesm2022/taiga-ui-core-components-loader.mjs +3 -3
  28. package/fesm2022/taiga-ui-core-components-notification.mjs +18 -19
  29. package/fesm2022/taiga-ui-core-components-notification.mjs.map +1 -1
  30. package/fesm2022/taiga-ui-core-components-root.mjs +3 -3
  31. package/fesm2022/taiga-ui-core-components-scrollbar.mjs +24 -30
  32. package/fesm2022/taiga-ui-core-components-scrollbar.mjs.map +1 -1
  33. package/fesm2022/taiga-ui-core-components-spin-button.mjs +3 -3
  34. package/fesm2022/taiga-ui-core-components-textfield.mjs +39 -29
  35. package/fesm2022/taiga-ui-core-components-textfield.mjs.map +1 -1
  36. package/fesm2022/taiga-ui-core-components-title.mjs +9 -7
  37. package/fesm2022/taiga-ui-core-components-title.mjs.map +1 -1
  38. package/fesm2022/taiga-ui-core-directives-appearance.mjs +14 -16
  39. package/fesm2022/taiga-ui-core-directives-appearance.mjs.map +1 -1
  40. package/fesm2022/taiga-ui-core-directives-button-x.mjs +3 -3
  41. package/fesm2022/taiga-ui-core-directives-date-format.mjs +3 -3
  42. package/fesm2022/taiga-ui-core-directives-group.mjs +9 -7
  43. package/fesm2022/taiga-ui-core-directives-group.mjs.map +1 -1
  44. package/fesm2022/taiga-ui-core-directives-icons.mjs +12 -10
  45. package/fesm2022/taiga-ui-core-directives-icons.mjs.map +1 -1
  46. package/fesm2022/taiga-ui-core-directives-items-handlers.mjs +12 -18
  47. package/fesm2022/taiga-ui-core-directives-items-handlers.mjs.map +1 -1
  48. package/fesm2022/taiga-ui-core-directives-number-format.mjs +3 -3
  49. package/fesm2022/taiga-ui-core-pipes-format-number.mjs +3 -3
  50. package/fesm2022/taiga-ui-core-portals-alert.mjs +9 -9
  51. package/fesm2022/taiga-ui-core-portals-dialog.mjs +13 -15
  52. package/fesm2022/taiga-ui-core-portals-dialog.mjs.map +1 -1
  53. package/fesm2022/taiga-ui-core-portals-dropdown.mjs +57 -69
  54. package/fesm2022/taiga-ui-core-portals-dropdown.mjs.map +1 -1
  55. package/fesm2022/taiga-ui-core-portals-hint.mjs +40 -48
  56. package/fesm2022/taiga-ui-core-portals-hint.mjs.map +1 -1
  57. package/fesm2022/taiga-ui-core-portals-modal.mjs +6 -6
  58. package/fesm2022/taiga-ui-core-portals-popup.mjs +11 -15
  59. package/fesm2022/taiga-ui-core-portals-popup.mjs.map +1 -1
  60. package/fesm2022/taiga-ui-core-services.mjs +7 -9
  61. package/fesm2022/taiga-ui-core-services.mjs.map +1 -1
  62. package/fesm2022/taiga-ui-core-tokens.mjs +16 -32
  63. package/fesm2022/taiga-ui-core-tokens.mjs.map +1 -1
  64. package/package.json +6 -6
  65. package/styles/components/appearance.less +2 -1
  66. package/styles/components/button.less +3 -3
  67. package/styles/components/group.less +1 -1
  68. package/styles/components/icon.less +1 -1
  69. package/styles/components/icons.less +1 -1
  70. package/styles/components/label.less +1 -1
  71. package/styles/components/link.less +2 -1
  72. package/styles/components/notification.less +2 -2
  73. package/styles/components/textfield.less +1 -1
  74. package/styles/components/title.less +6 -6
  75. package/styles/mixins/slider.less +12 -15
  76. package/styles/mixins/slider.scss +12 -17
  77. package/styles/theme/appearance/action.less +0 -14
  78. package/styles/theme/appearance/floating.less +5 -0
  79. package/tokens/i18n.d.ts +4 -0
  80. package/tokens/index.d.ts +0 -1
  81. package/tokens/theme.d.ts +0 -2
@@ -1,5 +1,6 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { InjectionToken, ChangeDetectionStrategy, ViewEncapsulation, Component, inject, computed, input, Directive, Injectable } from '@angular/core';
3
+ import '@taiga-ui/cdk/constants';
3
4
  import { tuiWithStyles, tuiIsString } from '@taiga-ui/cdk/utils/miscellaneous';
4
5
  import { tuiButtonOptionsProvider, TuiButton } from '@taiga-ui/core/components/button';
5
6
  import { tuiLinkOptionsProvider } from '@taiga-ui/core/components/link';
@@ -43,12 +44,12 @@ const [TUI_NOTIFICATION_OPTIONS, tuiNotificationOptionsProvider] = tuiCreateOpti
43
44
  const TUI_NOTIFICATION_CONCURRENCY = new InjectionToken(ngDevMode ? 'TUI_NOTIFICATION_CONCURRENCY' : '', { factory: () => 5 });
44
45
 
45
46
  class Styles {
46
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: Styles, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
47
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.17", type: Styles, isStandalone: true, selector: "ng-component", host: { classAttribute: "tui-notification" }, ngImport: i0, template: '', isInline: true, styles: ["[tuiNotification]{-webkit-appearance:none;appearance:none;padding:0;border:0;background:none;font:inherit;line-height:inherit;position:relative;display:block;max-block-size:100%;color:var(--tui-text-primary);padding:1rem;font:var(--tui-font-body-m);line-height:1.5rem;border-radius:var(--tui-radius-l);box-sizing:border-box;text-align:start;text-decoration:none;border-inline-start:var(--t-start) solid transparent;border-inline-end:var(--t-end) solid transparent;--t-start: 0;--t-end: 0}[tuiNotification]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled){cursor:pointer}[tuiNotification][data-icon-start]{--t-start: 2rem}[tuiNotification][data-icon-end]{--t-end: 1.5rem}[tuiNotification]:before{position:absolute;inset-inline-start:-1rem}[tuiNotification]:after{position:absolute;top:50%;transform:translateY(-50%);inset-inline-end:-.5rem;font-size:1rem;margin:0;margin-inline-end:-.25rem;margin-inline-start:auto;color:var(--tui-text-tertiary)!important}[tuiNotification][data-size=s]{padding:.375rem .625rem;font:var(--tui-font-body-s);line-height:1.25rem;border-radius:var(--tui-radius-m)}[tuiNotification][data-size=s][data-icon-start]{--t-start: 1.5rem}[tuiNotification][data-size=s]:before{inset-block-start:.5rem;inset-inline-start:-.875rem;font-size:1rem}[tuiNotification][data-size=s]:after{inset-inline-end:-.875rem}[tuiNotification][data-size=s] tui-icon{font-size:1rem}[tuiNotification][data-size=s] [tuiTitle]{font:var(--tui-font-body-s);font-weight:700}[tuiNotification][data-size=s] [tuiSubtitle]{font:var(--tui-font-body-s)}[tuiNotification][data-size=s] [tuiSubtitle]+*{gap:1rem;margin:.375rem 0 .25rem}[tuiNotification][data-size=s]>[tuiIconButton]{inset-block-start:0;inset-inline-end:0}[tuiNotification][data-size=m]{padding:.75rem;font:var(--tui-font-body-s);line-height:1.25rem;border-radius:var(--tui-radius-m)}[tuiNotification][data-size=m][data-icon-start]{--t-start: 1.625rem}[tuiNotification][data-size=m]:before{inset-inline-start:-.875rem;font-size:1.25rem}[tuiNotification][data-size=m]:after{inset-inline-end:-.75rem}[tuiNotification][data-size=m] tui-icon{font-size:1.25rem}[tuiNotification][data-size=m] [tuiTitle]{font:var(--tui-font-ui-m);font-weight:700}[tuiNotification][data-size=m] [tuiSubtitle]{font:var(--tui-font-body-s)}[tuiNotification][data-size=m] [tuiSubtitle]+*{gap:1rem;margin:.625rem 0 .25rem}[tuiNotification][data-size=m]>[tuiIconButton]{inset-block-start:.375rem;inset-inline-end:.5rem}[tuiNotification] [tuiTitle]{gap:.125rem;font:var(--tui-font-ui-l);font-weight:700}[tuiNotification] [tuiSubtitle]{font:var(--tui-font-body-m)}[tuiNotification] [tuiSubtitle]+*{display:flex;align-items:center;gap:1.25rem;margin-block-start:.625rem;font:var(--tui-font-body-s)}[tuiNotification]>[tuiIconButton]{position:absolute;inset-block-start:.75rem;inset-inline-end:.75rem;box-shadow:none!important;background:transparent!important}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
47
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: Styles, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
48
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.18", type: Styles, isStandalone: true, selector: "ng-component", host: { classAttribute: "tui-notification" }, ngImport: i0, template: '', isInline: true, styles: ["[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]){-webkit-appearance:none;appearance:none;padding:0;border:0;background:none;font:inherit;line-height:inherit;position:relative;display:flow-root;max-block-size:100%;color:var(--tui-text-primary);padding:1rem;font:var(--tui-font-body-m);line-height:1.5rem;border-radius:var(--tui-radius-l);box-sizing:border-box;text-align:start;text-decoration:none;border-inline-start:var(--t-start) solid transparent;border-inline-end:var(--t-end) solid transparent;--t-start: 0;--t-end: 0}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]):is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled){cursor:pointer}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-icon-start]{--t-start: 2rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-icon-end]{--t-end: 1.5rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]):before{position:absolute;inset-inline-start:-1rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]):after{position:absolute;top:50%;transform:translateY(-50%);inset-inline-end:-.5rem;font-size:1rem;margin:0;margin-inline-end:-.25rem;margin-inline-start:auto;color:var(--tui-text-tertiary)!important}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s]{padding:.375rem .625rem;font:var(--tui-font-body-s);line-height:1.25rem;border-radius:var(--tui-radius-m)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s][data-icon-start]{--t-start: 1.5rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s]:before{inset-block-start:.5rem;inset-inline-start:-.875rem;font-size:1rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s]:after{inset-inline-end:-.875rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s] tui-icon{font-size:1rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s] [tuiTitle]{font:var(--tui-font-body-s);font-weight:700}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s] [tuiSubtitle]{font:var(--tui-font-body-s)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s] [tuiSubtitle]+*{gap:1rem;margin:.375rem 0 .25rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s]>[tuiIconButton]{inset-block-start:0;inset-inline-end:0}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m]{padding:.75rem;font:var(--tui-font-body-s);line-height:1.25rem;border-radius:var(--tui-radius-m)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m][data-icon-start]{--t-start: 1.625rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m]:before{inset-inline-start:-.875rem;font-size:1.25rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m]:after{inset-inline-end:-.75rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m] tui-icon{font-size:1.25rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m] [tuiTitle]{font:var(--tui-font-ui-m);font-weight:700}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m] [tuiSubtitle]{font:var(--tui-font-body-s)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m] [tuiSubtitle]+*{gap:1rem;margin:.625rem 0 .25rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m]>[tuiIconButton]{inset-block-start:.375rem;inset-inline-end:.5rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]) [tuiTitle]{gap:.125rem;font:var(--tui-font-ui-l);font-weight:700}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]) [tuiSubtitle]{font:var(--tui-font-body-m)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]) [tuiSubtitle]+*{display:flex;align-items:center;gap:1.25rem;margin-block-start:.625rem;font:var(--tui-font-body-s)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])>[tuiIconButton]{position:absolute;inset-block-start:.75rem;inset-inline-end:.75rem;box-shadow:none!important;background:transparent!important}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
48
49
  }
49
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: Styles, decorators: [{
50
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: Styles, decorators: [{
50
51
  type: Component,
51
- args: [{ template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'tui-notification' }, styles: ["[tuiNotification]{-webkit-appearance:none;appearance:none;padding:0;border:0;background:none;font:inherit;line-height:inherit;position:relative;display:block;max-block-size:100%;color:var(--tui-text-primary);padding:1rem;font:var(--tui-font-body-m);line-height:1.5rem;border-radius:var(--tui-radius-l);box-sizing:border-box;text-align:start;text-decoration:none;border-inline-start:var(--t-start) solid transparent;border-inline-end:var(--t-end) solid transparent;--t-start: 0;--t-end: 0}[tuiNotification]:is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled){cursor:pointer}[tuiNotification][data-icon-start]{--t-start: 2rem}[tuiNotification][data-icon-end]{--t-end: 1.5rem}[tuiNotification]:before{position:absolute;inset-inline-start:-1rem}[tuiNotification]:after{position:absolute;top:50%;transform:translateY(-50%);inset-inline-end:-.5rem;font-size:1rem;margin:0;margin-inline-end:-.25rem;margin-inline-start:auto;color:var(--tui-text-tertiary)!important}[tuiNotification][data-size=s]{padding:.375rem .625rem;font:var(--tui-font-body-s);line-height:1.25rem;border-radius:var(--tui-radius-m)}[tuiNotification][data-size=s][data-icon-start]{--t-start: 1.5rem}[tuiNotification][data-size=s]:before{inset-block-start:.5rem;inset-inline-start:-.875rem;font-size:1rem}[tuiNotification][data-size=s]:after{inset-inline-end:-.875rem}[tuiNotification][data-size=s] tui-icon{font-size:1rem}[tuiNotification][data-size=s] [tuiTitle]{font:var(--tui-font-body-s);font-weight:700}[tuiNotification][data-size=s] [tuiSubtitle]{font:var(--tui-font-body-s)}[tuiNotification][data-size=s] [tuiSubtitle]+*{gap:1rem;margin:.375rem 0 .25rem}[tuiNotification][data-size=s]>[tuiIconButton]{inset-block-start:0;inset-inline-end:0}[tuiNotification][data-size=m]{padding:.75rem;font:var(--tui-font-body-s);line-height:1.25rem;border-radius:var(--tui-radius-m)}[tuiNotification][data-size=m][data-icon-start]{--t-start: 1.625rem}[tuiNotification][data-size=m]:before{inset-inline-start:-.875rem;font-size:1.25rem}[tuiNotification][data-size=m]:after{inset-inline-end:-.75rem}[tuiNotification][data-size=m] tui-icon{font-size:1.25rem}[tuiNotification][data-size=m] [tuiTitle]{font:var(--tui-font-ui-m);font-weight:700}[tuiNotification][data-size=m] [tuiSubtitle]{font:var(--tui-font-body-s)}[tuiNotification][data-size=m] [tuiSubtitle]+*{gap:1rem;margin:.625rem 0 .25rem}[tuiNotification][data-size=m]>[tuiIconButton]{inset-block-start:.375rem;inset-inline-end:.5rem}[tuiNotification] [tuiTitle]{gap:.125rem;font:var(--tui-font-ui-l);font-weight:700}[tuiNotification] [tuiSubtitle]{font:var(--tui-font-body-m)}[tuiNotification] [tuiSubtitle]+*{display:flex;align-items:center;gap:1.25rem;margin-block-start:.625rem;font:var(--tui-font-body-s)}[tuiNotification]>[tuiIconButton]{position:absolute;inset-block-start:.75rem;inset-inline-end:.75rem;box-shadow:none!important;background:transparent!important}\n"] }]
52
+ args: [{ template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'tui-notification' }, styles: ["[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]){-webkit-appearance:none;appearance:none;padding:0;border:0;background:none;font:inherit;line-height:inherit;position:relative;display:flow-root;max-block-size:100%;color:var(--tui-text-primary);padding:1rem;font:var(--tui-font-body-m);line-height:1.5rem;border-radius:var(--tui-radius-l);box-sizing:border-box;text-align:start;text-decoration:none;border-inline-start:var(--t-start) solid transparent;border-inline-end:var(--t-end) solid transparent;--t-start: 0;--t-end: 0}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]):is(a,button,select,textarea,input,label,.tui-interactive):not(:disabled){cursor:pointer}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-icon-start]{--t-start: 2rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-icon-end]{--t-end: 1.5rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]):before{position:absolute;inset-inline-start:-1rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]):after{position:absolute;top:50%;transform:translateY(-50%);inset-inline-end:-.5rem;font-size:1rem;margin:0;margin-inline-end:-.25rem;margin-inline-start:auto;color:var(--tui-text-tertiary)!important}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s]{padding:.375rem .625rem;font:var(--tui-font-body-s);line-height:1.25rem;border-radius:var(--tui-radius-m)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s][data-icon-start]{--t-start: 1.5rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s]:before{inset-block-start:.5rem;inset-inline-start:-.875rem;font-size:1rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s]:after{inset-inline-end:-.875rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s] tui-icon{font-size:1rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s] [tuiTitle]{font:var(--tui-font-body-s);font-weight:700}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s] [tuiSubtitle]{font:var(--tui-font-body-s)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s] [tuiSubtitle]+*{gap:1rem;margin:.375rem 0 .25rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=s]>[tuiIconButton]{inset-block-start:0;inset-inline-end:0}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m]{padding:.75rem;font:var(--tui-font-body-s);line-height:1.25rem;border-radius:var(--tui-radius-m)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m][data-icon-start]{--t-start: 1.625rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m]:before{inset-inline-start:-.875rem;font-size:1.25rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m]:after{inset-inline-end:-.75rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m] tui-icon{font-size:1.25rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m] [tuiTitle]{font:var(--tui-font-ui-m);font-weight:700}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m] [tuiSubtitle]{font:var(--tui-font-body-s)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m] [tuiSubtitle]+*{gap:1rem;margin:.625rem 0 .25rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])[data-size=m]>[tuiIconButton]{inset-block-start:.375rem;inset-inline-end:.5rem}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]) [tuiTitle]{gap:.125rem;font:var(--tui-font-ui-l);font-weight:700}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]) [tuiSubtitle]{font:var(--tui-font-body-m)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"]) [tuiSubtitle]+*{display:flex;align-items:center;gap:1.25rem;margin-block-start:.625rem;font:var(--tui-font-body-s)}[tuiNotification]:where(*[data-tui-version=\"5.0.0-rc.2\"])>[tuiIconButton]{position:absolute;inset-block-start:.75rem;inset-inline-end:.75rem;box-shadow:none!important;background:transparent!important}\n"] }]
52
53
  }] });
53
54
  class TuiNotificationDirective {
54
55
  constructor() {
@@ -59,14 +60,14 @@ class TuiNotificationDirective {
59
60
  this.size = input(this.options.size);
60
61
  this.icon = input(this.options.icon);
61
62
  }
62
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiNotificationDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
63
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.17", type: TuiNotificationDirective, isStandalone: true, selector: "[tuiNotification]:not(ng-template)", inputs: { appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.data-size": "size()" } }, providers: [
63
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiNotificationDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
64
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.18", type: TuiNotificationDirective, isStandalone: true, selector: "[tuiNotification]:not(ng-template)", inputs: { appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.data-size": "size()" } }, providers: [
64
65
  tuiAppearanceOptionsProvider(TUI_NOTIFICATION_OPTIONS),
65
66
  tuiLinkOptionsProvider({ appearance: '' }),
66
67
  tuiButtonOptionsProvider({ appearance: 'outline-grayscale', size: 's' }),
67
68
  ], hostDirectives: [{ directive: i1.TuiWithIcons }, { directive: i2.TuiWithAppearance }], ngImport: i0 }); }
68
69
  }
69
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiNotificationDirective, decorators: [{
70
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiNotificationDirective, decorators: [{
70
71
  type: Directive,
71
72
  args: [{
72
73
  selector: '[tuiNotification]:not(ng-template)',
@@ -92,10 +93,10 @@ class TuiNotificationComponent {
92
93
  .pipe(switchMap((autoClose) => (autoClose ? timer(autoClose) : EMPTY)), takeUntil(fromEvent(this.el, 'mouseenter')), repeat({ delay: () => fromEvent(this.el, 'mouseleave') }), takeUntilDestroyed())
93
94
  .subscribe(() => this.item.$implicit.complete());
94
95
  }
95
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiNotificationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
96
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: TuiNotificationComponent, isStandalone: true, selector: "tui-notification-alert", host: { attributes: { "role": "alert" } }, hostDirectives: [{ directive: i1$1.TuiAnimated }, { directive: i2$1.TuiAlertDirective }], ngImport: i0, template: "<div class=\"t-wrapper\">\n <div\n size=\"m\"\n tuiNotification\n [appearance]=\"item.appearance\"\n [class.t-closable]=\"item.closable\"\n [icon]=\"item.icon\"\n >\n <span tuiTitle>\n <ng-container *polymorpheusOutlet=\"item.label as text; context: item\">\n {{ text }}\n </ng-container>\n <span tuiSubtitle>\n <span\n *polymorpheusOutlet=\"item.content as text; context: item\"\n [innerHTML]=\"text\"\n ></span>\n </span>\n </span>\n @if (item.closable) {\n <button\n tuiIconButton\n type=\"button\"\n [iconStart]=\"icons.close\"\n (click)=\"item.$implicit.complete()\"\n >\n {{ close() }}\n </button>\n }\n </div>\n</div>\n", styles: [":host{inline-size:18rem;margin:1.625rem 3rem;word-break:break-word;transform:translateZ(0);filter:drop-shadow(0 .375rem 1rem rgba(0,0,0,.12))}:host :host-context(tui-root._mobile){margin:.625rem 1rem}.t-wrapper{background:var(--tui-background-base);clip-path:inset(.375rem 0 round var(--tui-radius-m))}.t-closable{padding-inline-end:2.5rem}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }, { kind: "directive", type: TuiNotificationDirective, selector: "[tuiNotification]:not(ng-template)", inputs: ["appearance", "size", "icon"] }, { kind: "directive", type: TuiTitle, selector: "[tuiTitle]", inputs: ["tuiTitle"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
96
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiNotificationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
97
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TuiNotificationComponent, isStandalone: true, selector: "tui-notification-alert", host: { attributes: { "role": "alert" } }, hostDirectives: [{ directive: i1$1.TuiAnimated }, { directive: i2$1.TuiAlertDirective }], ngImport: i0, template: "<div class=\"t-wrapper\">\n <div\n size=\"m\"\n tuiNotification\n [appearance]=\"item.appearance\"\n [class.t-closable]=\"item.closable\"\n [icon]=\"item.icon\"\n >\n <span tuiTitle>\n <ng-container *polymorpheusOutlet=\"item.label as text; context: item\">\n {{ text }}\n </ng-container>\n <span tuiSubtitle>\n <span\n *polymorpheusOutlet=\"item.content as text; context: item\"\n [innerHTML]=\"text\"\n ></span>\n </span>\n </span>\n @if (item.closable) {\n <button\n tuiIconButton\n type=\"button\"\n [iconStart]=\"icons.close\"\n (click)=\"item.$implicit.complete()\"\n >\n {{ close() }}\n </button>\n }\n </div>\n</div>\n", styles: [":host{inline-size:18rem;margin:1.625rem 3rem;word-break:break-word;transform:translateZ(0);filter:drop-shadow(0 .375rem 1rem rgba(0,0,0,.12))}:host :host-context(tui-root._mobile){margin:.625rem 1rem}.t-wrapper{background:var(--tui-background-base);clip-path:inset(.375rem 0 round var(--tui-radius-m))}.t-closable{padding-inline-end:2.5rem}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }, { kind: "directive", type: TuiNotificationDirective, selector: "[tuiNotification]:not(ng-template)", inputs: ["appearance", "size", "icon"] }, { kind: "directive", type: TuiTitle, selector: "[tuiTitle]", inputs: ["tuiTitle"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
97
98
  }
98
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiNotificationComponent, decorators: [{
99
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiNotificationComponent, decorators: [{
99
100
  type: Component,
100
101
  args: [{ selector: 'tui-notification-alert', imports: [PolymorpheusOutlet, TuiButton, TuiNotificationDirective, TuiTitle], changeDetection: ChangeDetectionStrategy.OnPush, hostDirectives: [TuiAnimated, TuiAlertDirective], host: { role: 'alert' }, template: "<div class=\"t-wrapper\">\n <div\n size=\"m\"\n tuiNotification\n [appearance]=\"item.appearance\"\n [class.t-closable]=\"item.closable\"\n [icon]=\"item.icon\"\n >\n <span tuiTitle>\n <ng-container *polymorpheusOutlet=\"item.label as text; context: item\">\n {{ text }}\n </ng-container>\n <span tuiSubtitle>\n <span\n *polymorpheusOutlet=\"item.content as text; context: item\"\n [innerHTML]=\"text\"\n ></span>\n </span>\n </span>\n @if (item.closable) {\n <button\n tuiIconButton\n type=\"button\"\n [iconStart]=\"icons.close\"\n (click)=\"item.$implicit.complete()\"\n >\n {{ close() }}\n </button>\n }\n </div>\n</div>\n", styles: [":host{inline-size:18rem;margin:1.625rem 3rem;word-break:break-word;transform:translateZ(0);filter:drop-shadow(0 .375rem 1rem rgba(0,0,0,.12))}:host :host-context(tui-root._mobile){margin:.625rem 1rem}.t-wrapper{background:var(--tui-background-base);clip-path:inset(.375rem 0 round var(--tui-radius-m))}.t-closable{padding-inline-end:2.5rem}\n"] }]
101
102
  }] });
@@ -106,23 +107,21 @@ class TuiNotificationService extends TuiAlertService {
106
107
  this.options = inject(TUI_NOTIFICATION_OPTIONS);
107
108
  this.component = TuiNotificationComponent;
108
109
  }
109
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiNotificationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
110
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiNotificationService, providedIn: 'root' }); }
110
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiNotificationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
111
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiNotificationService, providedIn: 'root' }); }
111
112
  }
112
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiNotificationService, decorators: [{
113
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiNotificationService, decorators: [{
113
114
  type: Injectable,
114
- args: [{
115
- providedIn: 'root',
116
- }]
115
+ args: [{ providedIn: 'root' }]
117
116
  }], ctorParameters: () => [] });
118
117
  class TuiNotificationTemplate {
119
118
  constructor() {
120
119
  this.tuiNotificationOptions = input({});
121
120
  }
122
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiNotificationTemplate, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
123
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.17", type: TuiNotificationTemplate, isStandalone: true, selector: "ng-template[tuiNotification]", inputs: { tuiNotificationOptions: { classPropertyName: "tuiNotificationOptions", publicName: "tuiNotificationOptions", isSignal: true, isRequired: false, transformFunction: null } }, providers: [tuiAsPortal(TuiNotificationService)], hostDirectives: [{ directive: i1$2.TuiPortalDirective, inputs: ["options", "tuiNotificationOptions", "open", "tuiNotification"], outputs: ["openChange", "tuiNotificationChange"] }], ngImport: i0 }); }
121
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiNotificationTemplate, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
122
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.18", type: TuiNotificationTemplate, isStandalone: true, selector: "ng-template[tuiNotification]", inputs: { tuiNotificationOptions: { classPropertyName: "tuiNotificationOptions", publicName: "tuiNotificationOptions", isSignal: true, isRequired: false, transformFunction: null } }, providers: [tuiAsPortal(TuiNotificationService)], hostDirectives: [{ directive: i1$2.TuiPortalDirective, inputs: ["options", "tuiNotificationOptions", "open", "tuiNotification"], outputs: ["openChange", "tuiNotificationChange"] }], ngImport: i0 }); }
124
123
  }
125
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiNotificationTemplate, decorators: [{
124
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiNotificationTemplate, decorators: [{
126
125
  type: Directive,
127
126
  args: [{
128
127
  selector: 'ng-template[tuiNotification]',
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-core-components-notification.mjs","sources":["../../../projects/core/components/notification/notification.options.ts","../../../projects/core/components/notification/notification.directive.ts","../../../projects/core/components/notification/notification.component.ts","../../../projects/core/components/notification/notification.template.html","../../../projects/core/components/notification/notification.service.ts","../../../projects/core/components/notification/notification.ts","../../../projects/core/components/notification/taiga-ui-core-components-notification.ts"],"sourcesContent":["import {InjectionToken} from '@angular/core';\nimport {type TuiNumberHandler, type TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiCreateOptions} from '@taiga-ui/cdk/utils/di';\nimport {type TuiAppearanceOptions} from '@taiga-ui/core/directives/appearance';\nimport {type TuiPositionOptions} from '@taiga-ui/core/portals/alert';\nimport {type TuiSizeL, type TuiSizeS} from '@taiga-ui/core/types';\n\nexport interface TuiNotificationOptions<I = undefined>\n extends TuiAppearanceOptions, TuiPositionOptions {\n readonly icon: TuiStringHandler<string> | string;\n readonly size: TuiSizeL | TuiSizeS;\n readonly autoClose: TuiNumberHandler<string> | number;\n readonly closable: boolean;\n readonly label: string;\n readonly data: I;\n}\n\nconst ICONS: Record<string, string> = {\n info: '@tui.info',\n positive: '@tui.circle-check',\n negative: '@tui.circle-x',\n warning: '@tui.circle-alert',\n neutral: '@tui.info',\n};\n\nexport const TUI_NOTIFICATION_DEFAULT_OPTIONS: TuiNotificationOptions = {\n appearance: 'info',\n icon: (appearance) => ICONS[appearance] ?? '',\n size: 'l',\n data: undefined,\n autoClose: 3000,\n label: '',\n closable: true,\n block: 'start',\n inline: 'end',\n};\n\nexport const [TUI_NOTIFICATION_OPTIONS, tuiNotificationOptionsProvider] =\n tuiCreateOptions(TUI_NOTIFICATION_DEFAULT_OPTIONS);\n\nexport const TUI_NOTIFICATION_CONCURRENCY = new InjectionToken(\n ngDevMode ? 'TUI_NOTIFICATION_CONCURRENCY' : '',\n {factory: () => 5},\n);\n","import {\n ChangeDetectionStrategy,\n Component,\n computed,\n Directive,\n inject,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport {type TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiIsString, tuiWithStyles} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {tuiButtonOptionsProvider} from '@taiga-ui/core/components/button';\nimport {tuiLinkOptionsProvider} from '@taiga-ui/core/components/link';\nimport {\n tuiAppearanceOptionsProvider,\n TuiWithAppearance,\n} from '@taiga-ui/core/directives/appearance';\nimport {tuiIconStart, TuiWithIcons} from '@taiga-ui/core/directives/icons';\n\nimport {TUI_NOTIFICATION_OPTIONS} from './notification.options';\n\n@Component({\n template: '',\n styles: '@import \"@taiga-ui/core/styles/components/notification.less\";',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {class: 'tui-notification'},\n})\nclass Styles {}\n\n@Directive({\n selector: '[tuiNotification]:not(ng-template)',\n providers: [\n tuiAppearanceOptionsProvider(TUI_NOTIFICATION_OPTIONS),\n tuiLinkOptionsProvider({appearance: ''}),\n tuiButtonOptionsProvider({appearance: 'outline-grayscale', size: 's'}),\n ],\n hostDirectives: [TuiWithIcons, TuiWithAppearance],\n host: {'[attr.data-size]': 'size()'},\n})\nexport class TuiNotificationDirective {\n private readonly options = inject(TUI_NOTIFICATION_OPTIONS);\n\n protected readonly nothing = tuiWithStyles(Styles);\n protected readonly icons = tuiIconStart(\n computed((icon = this.icon()) =>\n tuiIsString(icon) ? icon : icon(this.appearance()),\n ),\n );\n\n public readonly appearance = input(this.options.appearance);\n public readonly size = input(this.options.size);\n public readonly icon = input<TuiStringHandler<string> | string>(this.options.icon);\n}\n","import {ChangeDetectionStrategy, Component, inject} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {type TuiPortalContext} from '@taiga-ui/cdk/portals';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TuiTitle} from '@taiga-ui/core/components/title';\nimport {TuiAlertDirective} from '@taiga-ui/core/portals/alert';\nimport {TUI_CLOSE_WORD, TUI_COMMON_ICONS} from '@taiga-ui/core/tokens';\nimport {injectContext, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\nimport {EMPTY, fromEvent, of, repeat, switchMap, takeUntil, timer} from 'rxjs';\n\nimport {TuiNotificationDirective} from './notification.directive';\nimport {type TuiNotificationOptions} from './notification.options';\n\n@Component({\n selector: 'tui-notification-alert',\n imports: [PolymorpheusOutlet, TuiButton, TuiNotificationDirective, TuiTitle],\n templateUrl: './notification.template.html',\n styleUrl: './notification.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [TuiAnimated, TuiAlertDirective],\n host: {role: 'alert'},\n})\nexport class TuiNotificationComponent<O, I> {\n private readonly el = tuiInjectElement();\n\n protected readonly icons = inject(TUI_COMMON_ICONS);\n protected readonly close = inject(TUI_CLOSE_WORD);\n protected readonly item =\n injectContext<TuiPortalContext<TuiNotificationOptions<I>, O>>();\n\n protected readonly sub = of(\n typeof this.item.autoClose === 'function'\n ? this.item.autoClose(this.item.appearance)\n : this.item.autoClose,\n )\n .pipe(\n switchMap((autoClose) => (autoClose ? timer(autoClose) : EMPTY)),\n takeUntil(fromEvent(this.el, 'mouseenter')),\n repeat({delay: () => fromEvent(this.el, 'mouseleave')}),\n takeUntilDestroyed(),\n )\n .subscribe(() => this.item.$implicit.complete());\n}\n","<div class=\"t-wrapper\">\n <div\n size=\"m\"\n tuiNotification\n [appearance]=\"item.appearance\"\n [class.t-closable]=\"item.closable\"\n [icon]=\"item.icon\"\n >\n <span tuiTitle>\n <ng-container *polymorpheusOutlet=\"item.label as text; context: item\">\n {{ text }}\n </ng-container>\n <span tuiSubtitle>\n <span\n *polymorpheusOutlet=\"item.content as text; context: item\"\n [innerHTML]=\"text\"\n ></span>\n </span>\n </span>\n @if (item.closable) {\n <button\n tuiIconButton\n type=\"button\"\n [iconStart]=\"icons.close\"\n (click)=\"item.$implicit.complete()\"\n >\n {{ close() }}\n </button>\n }\n </div>\n</div>\n","import {Directive, inject, Injectable, input} from '@angular/core';\nimport {tuiAsPortal, TuiPortalDirective} from '@taiga-ui/cdk/portals';\nimport {TuiAlertService} from '@taiga-ui/core/portals/alert';\n\nimport {TuiNotificationComponent} from './notification.component';\nimport {\n TUI_NOTIFICATION_CONCURRENCY,\n TUI_NOTIFICATION_OPTIONS,\n type TuiNotificationOptions,\n} from './notification.options';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class TuiNotificationService extends TuiAlertService<TuiNotificationOptions<any>> {\n protected override readonly options = inject(TUI_NOTIFICATION_OPTIONS);\n protected override readonly component = TuiNotificationComponent;\n\n constructor() {\n super(inject(TUI_NOTIFICATION_CONCURRENCY));\n }\n}\n\n@Directive({\n selector: 'ng-template[tuiNotification]',\n providers: [tuiAsPortal(TuiNotificationService)],\n hostDirectives: [\n {\n directive: TuiPortalDirective,\n inputs: ['options: tuiNotificationOptions', 'open: tuiNotification'],\n outputs: ['openChange: tuiNotificationChange'],\n },\n ],\n})\nexport class TuiNotificationTemplate<T> {\n public readonly tuiNotificationOptions = input<Partial<TuiNotificationOptions<T>>>(\n {},\n );\n}\n","import {TuiNotificationDirective} from './notification.directive';\nimport {TuiNotificationTemplate} from './notification.service';\n\nexport const TuiNotification = [\n TuiNotificationDirective,\n TuiNotificationTemplate,\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1","i2"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAiBA,MAAM,KAAK,GAA2B;AAClC,IAAA,IAAI,EAAE,WAAW;AACjB,IAAA,QAAQ,EAAE,mBAAmB;AAC7B,IAAA,QAAQ,EAAE,eAAe;AACzB,IAAA,OAAO,EAAE,mBAAmB;AAC5B,IAAA,OAAO,EAAE,WAAW;CACvB;AAEY,MAAA,gCAAgC,GAA2B;AACpE,IAAA,UAAU,EAAE,MAAM;IAClB,IAAI,EAAE,CAAC,UAAU,KAAK,KAAK,CAAC,UAAU,CAAC,IAAI,EAAE;AAC7C,IAAA,IAAI,EAAE,GAAG;AACT,IAAA,IAA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ga-ui-core-components-notification.mjs","sources":["../../../projects/core/components/notification/notification.options.ts","../../../projects/core/components/notification/notification.directive.ts","../../../projects/core/components/notification/notification.component.ts","../../../projects/core/components/notification/notification.template.html","../../../projects/core/components/notification/notification.service.ts","../../../projects/core/components/notification/notification.ts","../../../projects/core/components/notification/taiga-ui-core-components-notification.ts"],"sourcesContent":["import {InjectionToken} from '@angular/core';\nimport {type TuiNumberHandler, type TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiCreateOptions} from '@taiga-ui/cdk/utils/di';\nimport {type TuiAppearanceOptions} from '@taiga-ui/core/directives/appearance';\nimport {type TuiPositionOptions} from '@taiga-ui/core/portals/alert';\nimport {type TuiSizeL, type TuiSizeS} from '@taiga-ui/core/types';\n\nexport interface TuiNotificationOptions<I = undefined>\n extends TuiAppearanceOptions, TuiPositionOptions {\n readonly icon: TuiStringHandler<string> | string;\n readonly size: TuiSizeL | TuiSizeS;\n readonly autoClose: TuiNumberHandler<string> | number;\n readonly closable: boolean;\n readonly label: string;\n readonly data: I;\n}\n\nconst ICONS: Record<string, string> = {\n info: '@tui.info',\n positive: '@tui.circle-check',\n negative: '@tui.circle-x',\n warning: '@tui.circle-alert',\n neutral: '@tui.info',\n};\n\nexport const TUI_NOTIFICATION_DEFAULT_OPTIONS: TuiNotificationOptions = {\n appearance: 'info',\n icon: (appearance) => ICONS[appearance] ?? '',\n size: 'l',\n data: undefined,\n autoClose: 3000,\n label: '',\n closable: true,\n block: 'start',\n inline: 'end',\n};\n\nexport const [TUI_NOTIFICATION_OPTIONS, tuiNotificationOptionsProvider] =\n tuiCreateOptions(TUI_NOTIFICATION_DEFAULT_OPTIONS);\n\nexport const TUI_NOTIFICATION_CONCURRENCY = new InjectionToken(\n ngDevMode ? 'TUI_NOTIFICATION_CONCURRENCY' : '',\n {factory: () => 5},\n);\n","import {\n ChangeDetectionStrategy,\n Component,\n computed,\n Directive,\n inject,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport {TUI_VERSION} from '@taiga-ui/cdk/constants';\nimport {type TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiIsString, tuiWithStyles} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {tuiButtonOptionsProvider} from '@taiga-ui/core/components/button';\nimport {tuiLinkOptionsProvider} from '@taiga-ui/core/components/link';\nimport {\n tuiAppearanceOptionsProvider,\n TuiWithAppearance,\n} from '@taiga-ui/core/directives/appearance';\nimport {tuiIconStart, TuiWithIcons} from '@taiga-ui/core/directives/icons';\n\nimport {TUI_NOTIFICATION_OPTIONS} from './notification.options';\n\n@Component({\n template: '',\n styles: `\n [data-tui-version='${TUI_VERSION}'] {\n @import '@taiga-ui/core/styles/components/notification.less';\n }\n `,\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {class: 'tui-notification'},\n})\nclass Styles {}\n\n@Directive({\n selector: '[tuiNotification]:not(ng-template)',\n providers: [\n tuiAppearanceOptionsProvider(TUI_NOTIFICATION_OPTIONS),\n tuiLinkOptionsProvider({appearance: ''}),\n tuiButtonOptionsProvider({appearance: 'outline-grayscale', size: 's'}),\n ],\n hostDirectives: [TuiWithIcons, TuiWithAppearance],\n host: {'[attr.data-size]': 'size()'},\n})\nexport class TuiNotificationDirective {\n private readonly options = inject(TUI_NOTIFICATION_OPTIONS);\n\n protected readonly nothing = tuiWithStyles(Styles);\n protected readonly icons = tuiIconStart(\n computed((icon = this.icon()) =>\n tuiIsString(icon) ? icon : icon(this.appearance()),\n ),\n );\n\n public readonly appearance = input(this.options.appearance);\n public readonly size = input(this.options.size);\n public readonly icon = input<TuiStringHandler<string> | string>(this.options.icon);\n}\n","import {ChangeDetectionStrategy, Component, inject} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {type TuiPortalContext} from '@taiga-ui/cdk/portals';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TuiTitle} from '@taiga-ui/core/components/title';\nimport {TuiAlertDirective} from '@taiga-ui/core/portals/alert';\nimport {TUI_CLOSE_WORD, TUI_COMMON_ICONS} from '@taiga-ui/core/tokens';\nimport {injectContext, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\nimport {EMPTY, fromEvent, of, repeat, switchMap, takeUntil, timer} from 'rxjs';\n\nimport {TuiNotificationDirective} from './notification.directive';\nimport {type TuiNotificationOptions} from './notification.options';\n\n@Component({\n selector: 'tui-notification-alert',\n imports: [PolymorpheusOutlet, TuiButton, TuiNotificationDirective, TuiTitle],\n templateUrl: './notification.template.html',\n styleUrl: './notification.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [TuiAnimated, TuiAlertDirective],\n host: {role: 'alert'},\n})\nexport class TuiNotificationComponent<O, I> {\n private readonly el = tuiInjectElement();\n\n protected readonly icons = inject(TUI_COMMON_ICONS);\n protected readonly close = inject(TUI_CLOSE_WORD);\n protected readonly item =\n injectContext<TuiPortalContext<TuiNotificationOptions<I>, O>>();\n\n protected readonly sub = of(\n typeof this.item.autoClose === 'function'\n ? this.item.autoClose(this.item.appearance)\n : this.item.autoClose,\n )\n .pipe(\n switchMap((autoClose) => (autoClose ? timer(autoClose) : EMPTY)),\n takeUntil(fromEvent(this.el, 'mouseenter')),\n repeat({delay: () => fromEvent(this.el, 'mouseleave')}),\n takeUntilDestroyed(),\n )\n .subscribe(() => this.item.$implicit.complete());\n}\n","<div class=\"t-wrapper\">\n <div\n size=\"m\"\n tuiNotification\n [appearance]=\"item.appearance\"\n [class.t-closable]=\"item.closable\"\n [icon]=\"item.icon\"\n >\n <span tuiTitle>\n <ng-container *polymorpheusOutlet=\"item.label as text; context: item\">\n {{ text }}\n </ng-container>\n <span tuiSubtitle>\n <span\n *polymorpheusOutlet=\"item.content as text; context: item\"\n [innerHTML]=\"text\"\n ></span>\n </span>\n </span>\n @if (item.closable) {\n <button\n tuiIconButton\n type=\"button\"\n [iconStart]=\"icons.close\"\n (click)=\"item.$implicit.complete()\"\n >\n {{ close() }}\n </button>\n }\n </div>\n</div>\n","import {Directive, inject, Injectable, input} from '@angular/core';\nimport {tuiAsPortal, TuiPortalDirective} from '@taiga-ui/cdk/portals';\nimport {TuiAlertService} from '@taiga-ui/core/portals/alert';\n\nimport {TuiNotificationComponent} from './notification.component';\nimport {\n TUI_NOTIFICATION_CONCURRENCY,\n TUI_NOTIFICATION_OPTIONS,\n type TuiNotificationOptions,\n} from './notification.options';\n\n@Injectable({providedIn: 'root'})\nexport class TuiNotificationService extends TuiAlertService<TuiNotificationOptions<any>> {\n protected override readonly options = inject(TUI_NOTIFICATION_OPTIONS);\n protected override readonly component = TuiNotificationComponent;\n\n constructor() {\n super(inject(TUI_NOTIFICATION_CONCURRENCY));\n }\n}\n\n@Directive({\n selector: 'ng-template[tuiNotification]',\n providers: [tuiAsPortal(TuiNotificationService)],\n hostDirectives: [\n {\n directive: TuiPortalDirective,\n inputs: ['options: tuiNotificationOptions', 'open: tuiNotification'],\n outputs: ['openChange: tuiNotificationChange'],\n },\n ],\n})\nexport class TuiNotificationTemplate<T> {\n public readonly tuiNotificationOptions = input<Partial<TuiNotificationOptions<T>>>(\n {},\n );\n}\n","import {TuiNotificationDirective} from './notification.directive';\nimport {TuiNotificationTemplate} from './notification.service';\n\nexport const TuiNotification = [\n TuiNotificationDirective,\n TuiNotificationTemplate,\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1","i2"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAiBA,MAAM,KAAK,GAA2B;AAClC,IAAA,IAAI,EAAE,WAAW;AACjB,IAAA,QAAQ,EAAE,mBAAmB;AAC7B,IAAA,QAAQ,EAAE,eAAe;AACzB,IAAA,OAAO,EAAE,mBAAmB;AAC5B,IAAA,OAAO,EAAE,WAAW;CACvB;AAEY,MAAA,gCAAgC,GAA2B;AACpE,IAAA,UA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;AC5BY,MAAA,eAAe,GAAG;IAC3B,wBAAwB;IACxB,uBAAuB;;;ACL3B;;AAEG;;;;"}
@@ -32,10 +32,10 @@ class TuiRoot {
32
32
  get parent() {
33
33
  return this.doc.fullscreenElement === this.el || !this.child;
34
34
  }
35
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiRoot, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
36
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: TuiRoot, isStandalone: true, selector: "tui-root", host: { attributes: { "data-tui-version": "5.0.0-rc.0" }, listeners: { "touchstart.passive.zoneless": "0", "document:fullscreenchange": "top.set(parent)" }, properties: { "style.--tui-duration.ms": "duration", "style.--tui-scroll-behavior": "reducedMotion ? \"auto\" : \"smooth\"", "class._mobile": "breakpoint() === \"mobile\"" } }, hostDirectives: [{ directive: i1.TuiPlatform }, { directive: i2.TuiVisualViewport }, { directive: i3.TuiFontSize }], ngImport: i0, template: "<div class=\"t-root-content\">\n <ng-content />\n</div>\n@if (top()) {\n @if (scrollbars) {\n <tui-scroll-controls class=\"t-root-scrollbar\" />\n }\n <tui-popups>\n <ng-content select=\"tuiOverContent\" />\n </tui-popups>\n}\n", styles: ["@keyframes tuiPresent{to{opacity:.99999}}@keyframes tuiFade{0%{opacity:0}}@keyframes tuiSlide{0%{transform:var(--tui-from, translateY(100%))}}@keyframes tuiScale{0%{transform:scale(var(--tui-scale, 0))}}@keyframes tuiCollapse{0%{grid-template-rows:0fr}to{grid-template-rows:1fr}}.tui-enter,.tui-leave{animation-duration:var(--tui-duration);animation-timing-function:ease-in-out;pointer-events:none}.tui-leave{animation-direction:reverse}\n", ".tui-zero-scrollbar{scrollbar-width:none;-ms-overflow-style:none}.tui-zero-scrollbar::-webkit-scrollbar,.tui-zero-scrollbar::-webkit-scrollbar-thumb{display:none}body,input{margin:0}tui-root{position:relative;display:block;font:var(--tui-font-body-s);color:var(--tui-text-primary);flex:1;border-image:conic-gradient(var(--tui-background-base) 0 0) fill 0/0/0 0 100vh 0;-webkit-tap-highlight-color:transparent}:root{--tui-inline-start: left;--tui-inline-end: right;--tui-inline: 1}[dir=rtl]{--tui-inline-start: right;--tui-inline-end: left;--tui-inline: -1}tui-root>.t-root-scrollbar{position:fixed;z-index:0;inset:0}.t-root-content{position:relative;top:var(--t-root-top);block-size:100%;isolation:isolate}.t-root-content>*{--t-root-top: 0}[tuiDropdownButton][tuiDropdownButton]{display:none}\n"], dependencies: [{ kind: "component", type: TuiPopups, selector: "tui-popups" }, { kind: "component", type: TuiScrollControls, selector: "tui-scroll-controls" }], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None }); }
35
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiRoot, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
36
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TuiRoot, isStandalone: true, selector: "tui-root", host: { attributes: { "data-tui-version": "5.0.0-rc.2" }, listeners: { "touchstart.passive.zoneless": "0", "document:fullscreenchange": "top.set(parent)" }, properties: { "style.--tui-duration.ms": "duration", "style.--tui-scroll-behavior": "reducedMotion ? \"auto\" : \"smooth\"", "class._mobile": "breakpoint() === \"mobile\"" } }, hostDirectives: [{ directive: i1.TuiPlatform }, { directive: i2.TuiVisualViewport }, { directive: i3.TuiFontSize }], ngImport: i0, template: "<div class=\"t-root-content\">\n <ng-content />\n</div>\n@if (top()) {\n @if (scrollbars) {\n <tui-scroll-controls class=\"t-root-scrollbar\" />\n }\n <tui-popups>\n <ng-content select=\"tuiOverContent\" />\n </tui-popups>\n}\n", styles: ["@keyframes tuiPresent{to{opacity:.99999}}@keyframes tuiFade{0%{opacity:0}}@keyframes tuiSlide{0%{transform:var(--tui-from, translateY(100%))}}@keyframes tuiScale{0%{transform:scale(var(--tui-scale, 0))}}@keyframes tuiCollapse{0%{grid-template-rows:0fr}to{grid-template-rows:1fr}}.tui-enter,.tui-leave{animation-duration:var(--tui-duration);animation-timing-function:ease-in-out;pointer-events:none}.tui-leave{animation-direction:reverse}\n", ".tui-zero-scrollbar{scrollbar-width:none;-ms-overflow-style:none}.tui-zero-scrollbar::-webkit-scrollbar,.tui-zero-scrollbar::-webkit-scrollbar-thumb{display:none}body,input{margin:0}tui-root{position:relative;display:block;font:var(--tui-font-body-s);color:var(--tui-text-primary);flex:1;border-image:conic-gradient(var(--tui-background-base) 0 0) fill 0/0/0 0 100vh 0;-webkit-tap-highlight-color:transparent}:root{--tui-inline-start: left;--tui-inline-end: right;--tui-inline: 1}[dir=rtl]{--tui-inline-start: right;--tui-inline-end: left;--tui-inline: -1}tui-root>.t-root-scrollbar{position:fixed;z-index:0;inset:0}.t-root-content{position:relative;top:var(--t-root-top);block-size:100%;isolation:isolate}.t-root-content>*{--t-root-top: 0}[tuiDropdownButton][tuiDropdownButton]{display:none}\n"], dependencies: [{ kind: "component", type: TuiPopups, selector: "tui-popups" }, { kind: "component", type: TuiScrollControls, selector: "tui-scroll-controls" }], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None }); }
37
37
  }
38
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiRoot, decorators: [{
38
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiRoot, decorators: [{
39
39
  type: Component,
40
40
  args: [{ selector: 'tui-root', imports: [TuiPopups, TuiScrollControls], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.Default, hostDirectives: [TuiPlatform, TuiVisualViewport, TuiFontSize], host: {
41
41
  'data-tui-version': TUI_VERSION,
@@ -15,10 +15,10 @@ const TUI_SCROLL_REF = new InjectionToken(ngDevMode ? 'TUI_SCROLL_REF' : '', {
15
15
  factory: () => new ElementRef(inject(DOCUMENT).documentElement),
16
16
  });
17
17
  class TuiScrollRef {
18
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollRef, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
19
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.17", type: TuiScrollRef, isStandalone: true, selector: "[tuiScrollRef]", providers: [tuiProvide(TUI_SCROLL_REF, ElementRef)], ngImport: i0 }); }
18
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollRef, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
19
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.18", type: TuiScrollRef, isStandalone: true, selector: "[tuiScrollRef]", providers: [tuiProvide(TUI_SCROLL_REF, ElementRef)], ngImport: i0 }); }
20
20
  }
21
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollRef, decorators: [{
21
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollRef, decorators: [{
22
22
  type: Directive,
23
23
  args: [{
24
24
  selector: '[tuiScrollRef]',
@@ -52,10 +52,10 @@ class TuiScrollbarService extends Observable {
52
52
  (width - offsetWidth);
53
53
  return [maxTop * scrolledTop, maxLeft * scrolledLeft];
54
54
  }
55
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollbarService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
56
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollbarService }); }
55
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollbarService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
56
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollbarService }); }
57
57
  }
58
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollbarService, decorators: [{
58
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollbarService, decorators: [{
59
59
  type: Injectable
60
60
  }], ctorParameters: () => [] });
61
61
  function getOffsetVertical({ clientY }, { top, height }) {
@@ -134,10 +134,10 @@ class TuiScrollbarDirective {
134
134
  ? Math.ceil((dimension.clientHeight / dimension.scrollHeight) * 100) / 100
135
135
  : Math.ceil((dimension.clientWidth / dimension.scrollWidth) * 100) / 100;
136
136
  }
137
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollbarDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
138
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.17", type: TuiScrollbarDirective, isStandalone: true, selector: "[tuiScrollbar]", inputs: { tuiScrollbar: { classPropertyName: "tuiScrollbar", publicName: "tuiScrollbar", isSignal: true, isRequired: false, transformFunction: null } }, providers: [TuiScrollbarService], ngImport: i0 }); }
137
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollbarDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
138
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.18", type: TuiScrollbarDirective, isStandalone: true, selector: "[tuiScrollbar]", inputs: { tuiScrollbar: { classPropertyName: "tuiScrollbar", publicName: "tuiScrollbar", isSignal: true, isRequired: false, transformFunction: null } }, providers: [TuiScrollbarService], ngImport: i0 }); }
139
139
  }
140
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollbarDirective, decorators: [{
140
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollbarDirective, decorators: [{
141
141
  type: Directive,
142
142
  args: [{
143
143
  selector: '[tuiScrollbar]',
@@ -145,9 +145,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImpo
145
145
  }]
146
146
  }] });
147
147
 
148
- const TUI_DEFAULT_SCROLLBAR_OPTIONS = {
149
- mode: 'always',
150
- };
148
+ const TUI_DEFAULT_SCROLLBAR_OPTIONS = { mode: 'always' };
151
149
  const [TUI_SCROLLBAR_OPTIONS, tuiScrollbarOptionsProvider] = tuiCreateOptions(TUI_DEFAULT_SCROLLBAR_OPTIONS);
152
150
 
153
151
  class TuiScrollControls {
@@ -163,10 +161,10 @@ class TuiScrollControls {
163
161
  Math.ceil((clientWidth / scrollWidth) * 100) < 100,
164
162
  ];
165
163
  }
166
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollControls, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
167
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: TuiScrollControls, isStandalone: true, selector: "tui-scroll-controls", ngImport: i0, template: "@if (nativeScrollbar) {\n} @else {\n @if (refresh$ | async; as bars) {\n @if (bars[0]) {\n <div\n tuiAnimated\n class=\"t-bar t-bar_vertical\"\n [class.t-bar_has-horizontal]=\"bars[1]\"\n (mousedown.capture.prevent)=\"(0)\"\n >\n <div\n tuiScrollbar=\"vertical\"\n class=\"t-thumb\"\n ></div>\n </div>\n }\n @if (bars[1]) {\n <div\n tuiAnimated\n class=\"t-bar t-bar_horizontal\"\n [class.t-bar_has-vertical]=\"bars[0]\"\n (mousedown.capture.prevent)=\"(0)\"\n >\n <div\n tuiScrollbar=\"horizontal\"\n class=\"t-thumb\"\n ></div>\n </div>\n }\n }\n}\n", styles: [":host{position:sticky;top:0;left:0;z-index:1;inset-inline-start:0;min-inline-size:calc(100% - 1px);min-block-size:calc(100% - 1px);max-inline-size:calc(100% - 1px);max-block-size:calc(100% - 1px);margin-inline-end:calc(-100% + 1px);pointer-events:none;overflow:hidden;color:var(--tui-text-primary)}::ng-deep [tuiScrollable]{scrollbar-width:none;-ms-overflow-style:none}::ng-deep [tuiScrollable]::-webkit-scrollbar,::ng-deep [tuiScrollable]::-webkit-scrollbar-thumb{display:none}.t-bar{position:absolute;inset-inline-end:0;pointer-events:auto}.t-bar.tui-enter,.t-bar.tui-leave{animation-name:tuiFade}.t-bar_vertical{inset-block:.25rem;inline-size:.875rem}.t-bar_horizontal{inset-block-end:0;inset-inline-start:0;block-size:.875rem}.t-bar_has-horizontal{inset-block-end:.5rem}.t-bar_has-vertical{inset-inline-end:.5rem}.t-thumb{transition-property:all;transition-duration:.15s;transition-timing-function:ease-in-out;position:absolute;border-radius:6.25rem;border:.25rem solid transparent;cursor:pointer;pointer-events:auto;-webkit-user-select:none;user-select:none;background:currentColor;background-clip:content-box;box-sizing:border-box;transition-property:width,height,opacity;opacity:.2}.t-thumb:hover{opacity:.24}.t-thumb:active{opacity:.48}.t-bar_vertical .t-thumb{inset-inline-end:0;inline-size:.75rem;min-block-size:1.25rem}.t-bar_vertical:hover .t-thumb,.t-bar_vertical .t-thumb:active{inline-size:.875rem}.t-bar_horizontal .t-thumb{inset-block-end:0;block-size:.75rem;min-inline-size:1.25rem}.t-bar_horizontal:hover .t-thumb,.t-bar_horizontal .t-thumb:active{block-size:.875rem}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "directive", type: TuiAnimated, selector: "[tuiAnimated]" }, { kind: "directive", type: TuiScrollbarDirective, selector: "[tuiScrollbar]", inputs: ["tuiScrollbar"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
164
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollControls, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
165
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TuiScrollControls, isStandalone: true, selector: "tui-scroll-controls", ngImport: i0, template: "@if (nativeScrollbar) {\n} @else {\n @if (refresh$ | async; as bars) {\n @if (bars[0]) {\n <div\n tuiAnimated\n class=\"t-bar t-bar_vertical\"\n [class.t-bar_has-horizontal]=\"bars[1]\"\n (mousedown.capture.prevent)=\"(0)\"\n >\n <div\n tuiScrollbar=\"vertical\"\n class=\"t-thumb\"\n ></div>\n </div>\n }\n @if (bars[1]) {\n <div\n tuiAnimated\n class=\"t-bar t-bar_horizontal\"\n [class.t-bar_has-vertical]=\"bars[0]\"\n (mousedown.capture.prevent)=\"(0)\"\n >\n <div\n tuiScrollbar=\"horizontal\"\n class=\"t-thumb\"\n ></div>\n </div>\n }\n }\n}\n", styles: [":host{position:sticky;top:0;left:0;z-index:1;inset-inline-start:0;min-inline-size:calc(100% - 1px);min-block-size:calc(100% - 1px);max-inline-size:calc(100% - 1px);max-block-size:calc(100% - 1px);margin-inline-end:calc(-100% + 1px);pointer-events:none;overflow:hidden;color:var(--tui-text-primary)}::ng-deep [tuiScrollable]{scrollbar-width:none;-ms-overflow-style:none}::ng-deep [tuiScrollable]::-webkit-scrollbar,::ng-deep [tuiScrollable]::-webkit-scrollbar-thumb{display:none}.t-bar{position:absolute;inset-inline-end:0;pointer-events:auto}.t-bar.tui-enter,.t-bar.tui-leave{animation-name:tuiFade}.t-bar_vertical{inset-block:.25rem;inline-size:.875rem}.t-bar_horizontal{inset-block-end:0;inset-inline-start:0;block-size:.875rem}.t-bar_has-horizontal{inset-block-end:.5rem}.t-bar_has-vertical{inset-inline-end:.5rem}.t-thumb{transition-property:all;transition-duration:.15s;transition-timing-function:ease-in-out;position:absolute;border-radius:6.25rem;border:.25rem solid transparent;cursor:pointer;pointer-events:auto;-webkit-user-select:none;user-select:none;background:currentColor;background-clip:content-box;box-sizing:border-box;transition-property:width,height,opacity;opacity:.2}.t-thumb:hover{opacity:.24}.t-thumb:active{opacity:.48}.t-bar_vertical .t-thumb{inset-inline-end:0;inline-size:.75rem;min-block-size:1.25rem}.t-bar_vertical:hover .t-thumb,.t-bar_vertical .t-thumb:active{inline-size:.875rem}.t-bar_horizontal .t-thumb{inset-block-end:0;block-size:.75rem;min-inline-size:1.25rem}.t-bar_horizontal:hover .t-thumb,.t-bar_horizontal .t-thumb:active{block-size:.875rem}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "directive", type: TuiAnimated, selector: "[tuiAnimated]" }, { kind: "directive", type: TuiScrollbarDirective, selector: "[tuiScrollbar]", inputs: ["tuiScrollbar"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
168
166
  }
169
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollControls, decorators: [{
167
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollControls, decorators: [{
170
168
  type: Component,
171
169
  args: [{ selector: 'tui-scroll-controls', imports: [AsyncPipe, TuiAnimated, TuiScrollbarDirective], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (nativeScrollbar) {\n} @else {\n @if (refresh$ | async; as bars) {\n @if (bars[0]) {\n <div\n tuiAnimated\n class=\"t-bar t-bar_vertical\"\n [class.t-bar_has-horizontal]=\"bars[1]\"\n (mousedown.capture.prevent)=\"(0)\"\n >\n <div\n tuiScrollbar=\"vertical\"\n class=\"t-thumb\"\n ></div>\n </div>\n }\n @if (bars[1]) {\n <div\n tuiAnimated\n class=\"t-bar t-bar_horizontal\"\n [class.t-bar_has-vertical]=\"bars[0]\"\n (mousedown.capture.prevent)=\"(0)\"\n >\n <div\n tuiScrollbar=\"horizontal\"\n class=\"t-thumb\"\n ></div>\n </div>\n }\n }\n}\n", styles: [":host{position:sticky;top:0;left:0;z-index:1;inset-inline-start:0;min-inline-size:calc(100% - 1px);min-block-size:calc(100% - 1px);max-inline-size:calc(100% - 1px);max-block-size:calc(100% - 1px);margin-inline-end:calc(-100% + 1px);pointer-events:none;overflow:hidden;color:var(--tui-text-primary)}::ng-deep [tuiScrollable]{scrollbar-width:none;-ms-overflow-style:none}::ng-deep [tuiScrollable]::-webkit-scrollbar,::ng-deep [tuiScrollable]::-webkit-scrollbar-thumb{display:none}.t-bar{position:absolute;inset-inline-end:0;pointer-events:auto}.t-bar.tui-enter,.t-bar.tui-leave{animation-name:tuiFade}.t-bar_vertical{inset-block:.25rem;inline-size:.875rem}.t-bar_horizontal{inset-block-end:0;inset-inline-start:0;block-size:.875rem}.t-bar_has-horizontal{inset-block-end:.5rem}.t-bar_has-vertical{inset-inline-end:.5rem}.t-thumb{transition-property:all;transition-duration:.15s;transition-timing-function:ease-in-out;position:absolute;border-radius:6.25rem;border:.25rem solid transparent;cursor:pointer;pointer-events:auto;-webkit-user-select:none;user-select:none;background:currentColor;background-clip:content-box;box-sizing:border-box;transition-property:width,height,opacity;opacity:.2}.t-thumb:hover{opacity:.24}.t-thumb:active{opacity:.48}.t-bar_vertical .t-thumb{inset-inline-end:0;inline-size:.75rem;min-block-size:1.25rem}.t-bar_vertical:hover .t-thumb,.t-bar_vertical .t-thumb:active{inline-size:.875rem}.t-bar_horizontal .t-thumb{inset-block-end:0;block-size:.75rem;min-inline-size:1.25rem}.t-bar_horizontal:hover .t-thumb,.t-bar_horizontal .t-thumb:active{block-size:.875rem}\n"] }]
172
170
  }] });
@@ -206,15 +204,15 @@ class TuiScrollbar {
206
204
  const scrollLeft = offsetLeft + offsetWidth / 2 - this.scrollRef.clientWidth / 2;
207
205
  this.scrollRef.scrollTo?.(scrollLeft, scrollTop);
208
206
  }
209
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollbar, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
210
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: TuiScrollbar, isStandalone: true, selector: "tui-scrollbar", host: { listeners: { "tui-scrollable.stop": "scrollRef = $event.detail", "tui-scroll-into-view.stop": "scrollIntoView($event.detail)" }, properties: { "class._native-hidden": "options.mode !== \"native\" && (!isIOS || options.mode === \"hidden\")" } }, providers: [
207
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollbar, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
208
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TuiScrollbar, isStandalone: true, selector: "tui-scrollbar", host: { listeners: { "tui-scrollable.stop": "scrollRef = $event.detail", "tui-scroll-into-view.stop": "scrollIntoView($event.detail)" }, properties: { "class._native-hidden": "options.mode !== \"native\" && (!isIOS || options.mode === \"hidden\")" } }, providers: [
211
209
  {
212
210
  provide: TUI_SCROLL_REF,
213
211
  useFactory: () => inject(TuiScrollbar).browserScrollRef,
214
212
  },
215
213
  ], ngImport: i0, template: "@if (!isIOS && options.mode !== 'native' && options.mode !== 'hidden') {\n <tui-scroll-controls\n class=\"t-bars\"\n [class.t-hover-mode]=\"options.mode === 'hover'\"\n />\n}\n<div\n class=\"t-content\"\n [class.t-content_delegated]=\"delegated\"\n>\n <ng-content />\n</div>\n", styles: [":host{position:relative;display:flex;max-block-size:100%;isolation:isolate;overflow:auto}:host._native-hidden{scrollbar-width:none;-ms-overflow-style:none}:host._native-hidden::-webkit-scrollbar,:host._native-hidden::-webkit-scrollbar-thumb{display:none}:host .t-hover-mode:not(:active){transition-property:opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;opacity:0}:host:hover .t-hover-mode{transition-property:opacity;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;opacity:1}.t-content{isolation:isolate;flex:1;flex-basis:auto;inline-size:100%;block-size:max-content}.t-content_delegated{block-size:100%}.t-bars{color:var(--tui-text-primary)}\n"], dependencies: [{ kind: "component", type: TuiScrollControls, selector: "tui-scroll-controls" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
216
214
  }
217
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollbar, decorators: [{
215
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollbar, decorators: [{
218
216
  type: Component,
219
217
  args: [{ selector: 'tui-scrollbar', imports: [TuiScrollControls], changeDetection: ChangeDetectionStrategy.OnPush, providers: [
220
218
  {
@@ -253,14 +251,12 @@ class TuiScrollIntoView {
253
251
  });
254
252
  });
255
253
  }
256
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollIntoView, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
257
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.17", type: TuiScrollIntoView, isStandalone: true, selector: "[tuiScrollIntoView]", inputs: { tuiScrollIntoView: { classPropertyName: "tuiScrollIntoView", publicName: "tuiScrollIntoView", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 }); }
254
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollIntoView, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
255
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.18", type: TuiScrollIntoView, isStandalone: true, selector: "[tuiScrollIntoView]", inputs: { tuiScrollIntoView: { classPropertyName: "tuiScrollIntoView", publicName: "tuiScrollIntoView", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 }); }
258
256
  }
259
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollIntoView, decorators: [{
257
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollIntoView, decorators: [{
260
258
  type: Directive,
261
- args: [{
262
- selector: '[tuiScrollIntoView]',
263
- }]
259
+ args: [{ selector: '[tuiScrollIntoView]' }]
264
260
  }] });
265
261
 
266
262
  class TuiScrollable {
@@ -270,14 +266,12 @@ class TuiScrollable {
270
266
  ngOnInit() {
271
267
  this.el.dispatchEvent(new CustomEvent(TUI_SCROLLABLE, { bubbles: true, detail: this.el }));
272
268
  }
273
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollable, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
274
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.17", type: TuiScrollable, isStandalone: true, selector: "[tuiScrollable]", ngImport: i0 }); }
269
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollable, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
270
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.18", type: TuiScrollable, isStandalone: true, selector: "[tuiScrollable]", ngImport: i0 }); }
275
271
  }
276
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiScrollable, decorators: [{
272
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiScrollable, decorators: [{
277
273
  type: Directive,
278
- args: [{
279
- selector: '[tuiScrollable]',
280
- }]
274
+ args: [{ selector: '[tuiScrollable]' }]
281
275
  }] });
282
276
 
283
277
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"taiga-ui-core-components-scrollbar.mjs","sources":["../../../projects/core/components/scrollbar/scroll-ref.directive.ts","../../../projects/core/components/scrollbar/scrollbar.service.ts","../../../projects/core/components/scrollbar/scrollbar.directive.ts","../../../projects/core/components/scrollbar/scrollbar.options.ts","../../../projects/core/components/scrollbar/scroll-controls.component.ts","../../../projects/core/components/scrollbar/scroll-controls.template.html","../../../projects/core/components/scrollbar/scrollbar.component.ts","../../../projects/core/components/scrollbar/scrollbar.template.html","../../../projects/core/components/scrollbar/scroll-into-view.directive.ts","../../../projects/core/components/scrollbar/scrollable.directive.ts","../../../projects/core/components/scrollbar/taiga-ui-core-components-scrollbar.ts"],"sourcesContent":["import {DOCUMENT} from '@angular/common';\nimport {Directive, ElementRef, inject, InjectionToken} from '@angular/core';\nimport {tuiProvide} from '@taiga-ui/cdk/utils/di';\n\nexport const SCROLL_REF_SELECTOR = '[tuiScrollRef]';\nexport const TUI_SCROLL_REF = new InjectionToken(ngDevMode ? 'TUI_SCROLL_REF' : '', {\n factory: () => new ElementRef(inject(DOCUMENT).documentElement),\n});\n\n@Directive({\n selector: '[tuiScrollRef]',\n providers: [tuiProvide(TUI_SCROLL_REF, ElementRef)],\n})\nexport class TuiScrollRef {}\n","import {inject, Injectable} from '@angular/core';\nimport {tuiTypedFromEvent, tuiZonefree} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {filter, map, merge, Observable, switchMap, takeUntil} from 'rxjs';\n\nimport {TUI_SCROLL_REF} from './scroll-ref.directive';\n\n@Injectable()\nexport class TuiScrollbarService extends Observable<[number, number]> {\n private readonly el = tuiInjectElement();\n private readonly element = inject(TUI_SCROLL_REF).nativeElement;\n private readonly scroll$ = merge(\n tuiTypedFromEvent(this.el.parentElement!, 'mousedown').pipe(\n filter(({target}) => target !== this.el),\n map((event) => this.getScrolled(event, 0.5, 0.5)),\n ),\n tuiTypedFromEvent(this.el, 'mousedown').pipe(\n tuiZonefree(),\n switchMap((event) => {\n const {ownerDocument} = this.el;\n const rect = this.el.getBoundingClientRect();\n const vertical = getOffsetVertical(event, rect);\n const horizontal = getOffsetHorizontal(event, rect);\n\n return tuiTypedFromEvent(ownerDocument, 'mousemove').pipe(\n map((event) => this.getScrolled(event, vertical, horizontal)),\n takeUntil(tuiTypedFromEvent(ownerDocument, 'mouseup')),\n );\n }),\n ),\n );\n\n constructor() {\n super((subscriber) => this.scroll$.subscribe(subscriber));\n }\n\n private getScrolled(\n {clientY, clientX}: MouseEvent,\n offsetY: number,\n offsetX: number,\n ): [number, number] {\n const {offsetHeight, offsetWidth} = this.el;\n const {top, left, right, width, height} =\n this.el.parentElement!.getBoundingClientRect();\n const rtl = this.el.matches('[dir=\"rtl\"] :scope');\n const inline = rtl ? right : left;\n const multiplier = rtl ? -1 : 1;\n const maxTop = this.element.scrollHeight - height;\n const maxLeft = this.element.scrollWidth - width;\n const scrolledTop =\n (clientY - top - offsetHeight * offsetY) / (height - offsetHeight);\n const scrolledLeft =\n (clientX - inline - offsetWidth * offsetX * multiplier) /\n (width - offsetWidth);\n\n return [maxTop * scrolledTop, maxLeft * scrolledLeft];\n }\n}\n\nfunction getOffsetVertical({clientY}: MouseEvent, {top, height}: DOMRect): number {\n return (clientY - top) / height;\n}\n\nfunction getOffsetHorizontal({clientX}: MouseEvent, {left, width}: DOMRect): number {\n return (clientX - left) / width;\n}\n","import {Directive, inject, input} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {WA_ANIMATION_FRAME} from '@ng-web-apis/common';\nimport {\n tuiScrollFrom,\n tuiZonefree,\n tuiZonefreeScheduler,\n} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {merge, throttleTime} from 'rxjs';\n\nimport {TUI_SCROLL_REF} from './scroll-ref.directive';\nimport {TuiScrollbarService} from './scrollbar.service';\n\nconst MIN_WIDTH = 24;\n\ninterface ComputedDimension {\n scrollTop: number;\n scrollHeight: number;\n clientHeight: number;\n scrollLeft: number;\n scrollWidth: number;\n clientWidth: number;\n}\n\n@Directive({\n selector: '[tuiScrollbar]',\n providers: [TuiScrollbarService],\n})\nexport class TuiScrollbarDirective {\n private readonly el = inject(TUI_SCROLL_REF).nativeElement;\n private readonly style = tuiInjectElement().style;\n\n protected readonly scrollSub = inject(TuiScrollbarService)\n .pipe(takeUntilDestroyed())\n .subscribe(([top, left]) => {\n this.el.style.scrollBehavior = 'auto';\n\n if (this.tuiScrollbar() === 'horizontal') {\n this.el.scrollLeft = left;\n } else {\n this.el.scrollTop = top;\n }\n\n this.el.style.scrollBehavior = '';\n });\n\n protected readonly styleSub = merge(\n inject(WA_ANIMATION_FRAME).pipe(throttleTime(100, tuiZonefreeScheduler())),\n tuiScrollFrom(this.el),\n )\n .pipe(tuiZonefree(), takeUntilDestroyed())\n .subscribe(() => {\n const dimension: ComputedDimension = {\n scrollTop: this.el.scrollTop,\n scrollHeight: this.el.scrollHeight,\n clientHeight: this.el.clientHeight,\n scrollLeft: this.el.scrollLeft,\n scrollWidth: this.el.scrollWidth,\n clientWidth: this.el.clientWidth,\n };\n\n const thumb = `${this.getThumb(dimension) * 100}%`;\n const view = `${this.getView(dimension) * 100}%`;\n\n if (this.tuiScrollbar() === 'vertical') {\n this.style.top = thumb;\n this.style.height = view;\n } else {\n this.style.left = thumb;\n this.style.insetInlineStart = thumb;\n this.style.width = view;\n }\n });\n\n public readonly tuiScrollbar = input<'horizontal' | 'vertical'>('vertical');\n\n private getScrolled(dimension: ComputedDimension): number {\n return this.tuiScrollbar() === 'vertical'\n ? dimension.scrollTop / (dimension.scrollHeight - dimension.clientHeight)\n : dimension.scrollLeft / (dimension.scrollWidth - dimension.clientWidth);\n }\n\n private getCompensation(dimension: ComputedDimension): number {\n if (\n ((dimension.clientHeight * dimension.clientHeight) / dimension.scrollHeight >\n MIN_WIDTH &&\n this.tuiScrollbar() === 'vertical') ||\n ((dimension.clientWidth * dimension.clientWidth) / dimension.scrollWidth >\n MIN_WIDTH &&\n this.tuiScrollbar() === 'horizontal')\n ) {\n return 0;\n }\n\n return this.tuiScrollbar() === 'vertical'\n ? MIN_WIDTH / dimension.clientHeight\n : MIN_WIDTH / dimension.clientWidth;\n }\n\n private getThumb(dimension: ComputedDimension): number {\n const compensation = this.getCompensation(dimension) || this.getView(dimension);\n\n return Math.abs(this.getScrolled(dimension) * (1 - compensation));\n }\n\n private getView(dimension: ComputedDimension): number {\n return this.tuiScrollbar() === 'vertical'\n ? Math.ceil((dimension.clientHeight / dimension.scrollHeight) * 100) / 100\n : Math.ceil((dimension.clientWidth / dimension.scrollWidth) * 100) / 100;\n }\n}\n","import {tuiCreateOptions} from '@taiga-ui/cdk/utils/di';\n\nexport interface TuiScrollbarOptions {\n mode: 'always' | 'hidden' | 'hover' | 'native';\n}\n\nexport const TUI_DEFAULT_SCROLLBAR_OPTIONS: TuiScrollbarOptions = {\n mode: 'always',\n};\n\nexport const [TUI_SCROLLBAR_OPTIONS, tuiScrollbarOptionsProvider] =\n tuiCreateOptions<TuiScrollbarOptions>(TUI_DEFAULT_SCROLLBAR_OPTIONS);\n","import {AsyncPipe} from '@angular/common';\nimport {ChangeDetectionStrategy, Component, inject} from '@angular/core';\nimport {WA_ANIMATION_FRAME} from '@ng-web-apis/common';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {tuiZonefreeScheduler, tuiZoneOptimized} from '@taiga-ui/cdk/observables';\nimport {distinctUntilChanged, map, startWith, throttleTime} from 'rxjs';\n\nimport {TUI_SCROLL_REF} from './scroll-ref.directive';\nimport {TuiScrollbarDirective} from './scrollbar.directive';\nimport {TUI_SCROLLBAR_OPTIONS} from './scrollbar.options';\n\n@Component({\n selector: 'tui-scroll-controls',\n imports: [AsyncPipe, TuiAnimated, TuiScrollbarDirective],\n templateUrl: './scroll-controls.template.html',\n styleUrl: './scroll-controls.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiScrollControls {\n private readonly scrollRef = inject(TUI_SCROLL_REF).nativeElement;\n\n protected readonly nativeScrollbar = inject(TUI_SCROLLBAR_OPTIONS).mode === 'native';\n protected readonly refresh$ = inject(WA_ANIMATION_FRAME).pipe(\n throttleTime(300, tuiZonefreeScheduler()),\n map(() => this.scrollbars),\n startWith([false, false]),\n distinctUntilChanged((a, b) => a[0] === b[0] && a[1] === b[1]),\n tuiZoneOptimized(),\n );\n\n private get scrollbars(): [boolean, boolean] {\n const {clientHeight, scrollHeight, clientWidth, scrollWidth} = this.scrollRef;\n\n return [\n Math.ceil((clientHeight / scrollHeight) * 100) < 100,\n Math.ceil((clientWidth / scrollWidth) * 100) < 100,\n ];\n }\n}\n","@if (nativeScrollbar) {\n} @else {\n @if (refresh$ | async; as bars) {\n @if (bars[0]) {\n <div\n tuiAnimated\n class=\"t-bar t-bar_vertical\"\n [class.t-bar_has-horizontal]=\"bars[1]\"\n (mousedown.capture.prevent)=\"(0)\"\n >\n <div\n tuiScrollbar=\"vertical\"\n class=\"t-thumb\"\n ></div>\n </div>\n }\n @if (bars[1]) {\n <div\n tuiAnimated\n class=\"t-bar t-bar_horizontal\"\n [class.t-bar_has-vertical]=\"bars[0]\"\n (mousedown.capture.prevent)=\"(0)\"\n >\n <div\n tuiScrollbar=\"horizontal\"\n class=\"t-thumb\"\n ></div>\n </div>\n }\n }\n}\n","import {ChangeDetectionStrategy, Component, ElementRef, inject} from '@angular/core';\nimport {WA_IS_IOS} from '@ng-web-apis/platform';\nimport {tuiGetElementOffset, tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\n\nimport {TuiScrollControls} from './scroll-controls.component';\nimport {TUI_SCROLL_REF} from './scroll-ref.directive';\nimport {TUI_SCROLLBAR_OPTIONS} from './scrollbar.options';\n\n/**\n * An event for scrolling an element into view within {@link TuiScrollbar}.\n */\nexport const TUI_SCROLL_INTO_VIEW = 'tui-scroll-into-view';\n\n/**\n * An event to notify {@link TuiScrollbar} that\n * it should control a nested element.\n */\nexport const TUI_SCROLLABLE = 'tui-scrollable';\n\n@Component({\n selector: 'tui-scrollbar',\n imports: [TuiScrollControls],\n templateUrl: './scrollbar.template.html',\n styleUrl: './scrollbar.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n {\n provide: TUI_SCROLL_REF,\n useFactory: () => inject(TuiScrollbar).browserScrollRef,\n },\n ],\n host: {\n '[class._native-hidden]':\n 'options.mode !== \"native\" && (!isIOS || options.mode === \"hidden\")',\n [`(${TUI_SCROLLABLE}.stop)`]: 'scrollRef = $event.detail',\n [`(${TUI_SCROLL_INTO_VIEW}.stop)`]: 'scrollIntoView($event.detail)',\n },\n})\nexport class TuiScrollbar {\n private readonly el = tuiInjectElement();\n\n protected readonly options = inject(TUI_SCROLLBAR_OPTIONS);\n protected readonly isIOS = inject(WA_IS_IOS);\n protected readonly browserScrollRef = new ElementRef(this.el);\n\n protected get delegated(): boolean {\n return this.scrollRef !== this.el || this.options.mode === 'native';\n }\n\n protected get scrollRef(): HTMLElement {\n return this.browserScrollRef.nativeElement;\n }\n\n protected set scrollRef(element: HTMLElement) {\n this.browserScrollRef.nativeElement = element;\n }\n\n protected scrollIntoView(detail: HTMLElement): void {\n if (this.delegated) {\n return;\n }\n\n const {offsetHeight, offsetWidth} = detail;\n const {offsetTop, offsetLeft} = tuiGetElementOffset(this.scrollRef, detail);\n const scrollTop = offsetTop + offsetHeight / 2 - this.scrollRef.clientHeight / 2;\n const scrollLeft = offsetLeft + offsetWidth / 2 - this.scrollRef.clientWidth / 2;\n\n this.scrollRef.scrollTo?.(scrollLeft, scrollTop);\n }\n}\n","@if (!isIOS && options.mode !== 'native' && options.mode !== 'hidden') {\n <tui-scroll-controls\n class=\"t-bars\"\n [class.t-hover-mode]=\"options.mode === 'hover'\"\n />\n}\n<div\n class=\"t-content\"\n [class.t-content_delegated]=\"delegated\"\n>\n <ng-content />\n</div>\n","import {DestroyRef, Directive, effect, inject, input} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {timer} from 'rxjs';\n\nimport {TUI_SCROLL_INTO_VIEW} from './scrollbar.component';\n\n/**\n * Directive scrolls element into view inside tui-scrollbar\n */\n@Directive({\n selector: '[tuiScrollIntoView]',\n})\nexport class TuiScrollIntoView {\n private readonly el = tuiInjectElement();\n private readonly destroyRef = inject(DestroyRef);\n\n public readonly tuiScrollIntoView = input<boolean>();\n\n protected readonly dispatchEvent = effect(() => {\n const scroll = this.tuiScrollIntoView();\n\n if (!scroll) {\n return;\n }\n\n // Timeout is necessary in order to give element render cycle to get into its final spot\n // (for example if it is inside dropdown box which has to be positioned first)\n timer(0)\n .pipe(takeUntilDestroyed(this.destroyRef))\n .subscribe(() => {\n this.el.dispatchEvent(\n new CustomEvent<Element>(TUI_SCROLL_INTO_VIEW, {\n bubbles: true,\n detail: this.el,\n }),\n );\n });\n });\n}\n","import {Directive, type OnInit} from '@angular/core';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\n\nimport {TUI_SCROLLABLE} from './scrollbar.component';\n\n@Directive({\n selector: '[tuiScrollable]',\n})\nexport class TuiScrollable implements OnInit {\n private readonly el = tuiInjectElement();\n\n public ngOnInit(): void {\n this.el.dispatchEvent(\n new CustomEvent(TUI_SCROLLABLE, {bubbles: true, detail: this.el}),\n );\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;AAIO,MAAM,mBAAmB,GAAG;AACtB,MAAA,cAAc,GAAG,IAAI,cAAc,CAAC,SAAS,GAAG,gBAAgB,GAAG,EAAE,EAAE;AAChF,IAAA,OAAO,EAAE,MAAM,IAAI,UAAU,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,eAAe,CAAC;AAClE,CAAA;MAMY,YAAY,CAAA;+GAAZ,YAAY,EAAA,IAAA,EAAA,E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AAA,CAAA,CAAA;mGAAjB,iBAAiB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,qBAAA,EAAA,MAAA,EAAA,EAAA,iBAAA,EAAA,EAAA,iBAAA,EAAA,mBAAA,EAAA,UAAA,EAAA,mBAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAH7B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,qBAAqB;AAClC,iBAAA;;;MCJY,aAAa,CAAA;AAH1B,IAAA,WAAA,GAAA;QAIqB,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAE;AAO3C;IALU,QAAQ,GAAA;QACX,IAAI,CAAC,EAAE,CAAC,aAAa,CACjB,IAAI,WAAW,CAAC,cAAc,EAAE,EAAC,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,EAAC,CAAC,CACpE;;+GANI,aAAa,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;mGAAb,aAAa,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,iBAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAAb,aAAa,EAAA,UAAA,EAAA,CAAA;kBAHzB,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,iBAAiB;AAC9B,iBAAA;;;ACPD;;AAEG;;;;"}
1
+ {"version":3,"file":"taiga-ui-core-components-scrollbar.mjs","sources":["../../../projects/core/components/scrollbar/scroll-ref.directive.ts","../../../projects/core/components/scrollbar/scrollbar.service.ts","../../../projects/core/components/scrollbar/scrollbar.directive.ts","../../../projects/core/components/scrollbar/scrollbar.options.ts","../../../projects/core/components/scrollbar/scroll-controls.component.ts","../../../projects/core/components/scrollbar/scroll-controls.template.html","../../../projects/core/components/scrollbar/scrollbar.component.ts","../../../projects/core/components/scrollbar/scrollbar.template.html","../../../projects/core/components/scrollbar/scroll-into-view.directive.ts","../../../projects/core/components/scrollbar/scrollable.directive.ts","../../../projects/core/components/scrollbar/taiga-ui-core-components-scrollbar.ts"],"sourcesContent":["import {DOCUMENT} from '@angular/common';\nimport {Directive, ElementRef, inject, InjectionToken} from '@angular/core';\nimport {tuiProvide} from '@taiga-ui/cdk/utils/di';\n\nexport const SCROLL_REF_SELECTOR = '[tuiScrollRef]';\nexport const TUI_SCROLL_REF = new InjectionToken(ngDevMode ? 'TUI_SCROLL_REF' : '', {\n factory: () => new ElementRef(inject(DOCUMENT).documentElement),\n});\n\n@Directive({\n selector: '[tuiScrollRef]',\n providers: [tuiProvide(TUI_SCROLL_REF, ElementRef)],\n})\nexport class TuiScrollRef {}\n","import {inject, Injectable} from '@angular/core';\nimport {tuiTypedFromEvent, tuiZonefree} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {filter, map, merge, Observable, switchMap, takeUntil} from 'rxjs';\n\nimport {TUI_SCROLL_REF} from './scroll-ref.directive';\n\n@Injectable()\nexport class TuiScrollbarService extends Observable<[number, number]> {\n private readonly el = tuiInjectElement();\n private readonly element = inject(TUI_SCROLL_REF).nativeElement;\n private readonly scroll$ = merge(\n tuiTypedFromEvent(this.el.parentElement!, 'mousedown').pipe(\n filter(({target}) => target !== this.el),\n map((event) => this.getScrolled(event, 0.5, 0.5)),\n ),\n tuiTypedFromEvent(this.el, 'mousedown').pipe(\n tuiZonefree(),\n switchMap((event) => {\n const {ownerDocument} = this.el;\n const rect = this.el.getBoundingClientRect();\n const vertical = getOffsetVertical(event, rect);\n const horizontal = getOffsetHorizontal(event, rect);\n\n return tuiTypedFromEvent(ownerDocument, 'mousemove').pipe(\n map((event) => this.getScrolled(event, vertical, horizontal)),\n takeUntil(tuiTypedFromEvent(ownerDocument, 'mouseup')),\n );\n }),\n ),\n );\n\n constructor() {\n super((subscriber) => this.scroll$.subscribe(subscriber));\n }\n\n private getScrolled(\n {clientY, clientX}: MouseEvent,\n offsetY: number,\n offsetX: number,\n ): [number, number] {\n const {offsetHeight, offsetWidth} = this.el;\n const {top, left, right, width, height} =\n this.el.parentElement!.getBoundingClientRect();\n const rtl = this.el.matches('[dir=\"rtl\"] :scope');\n const inline = rtl ? right : left;\n const multiplier = rtl ? -1 : 1;\n const maxTop = this.element.scrollHeight - height;\n const maxLeft = this.element.scrollWidth - width;\n const scrolledTop =\n (clientY - top - offsetHeight * offsetY) / (height - offsetHeight);\n const scrolledLeft =\n (clientX - inline - offsetWidth * offsetX * multiplier) /\n (width - offsetWidth);\n\n return [maxTop * scrolledTop, maxLeft * scrolledLeft];\n }\n}\n\nfunction getOffsetVertical({clientY}: MouseEvent, {top, height}: DOMRect): number {\n return (clientY - top) / height;\n}\n\nfunction getOffsetHorizontal({clientX}: MouseEvent, {left, width}: DOMRect): number {\n return (clientX - left) / width;\n}\n","import {Directive, inject, input} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {WA_ANIMATION_FRAME} from '@ng-web-apis/common';\nimport {\n tuiScrollFrom,\n tuiZonefree,\n tuiZonefreeScheduler,\n} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {merge, throttleTime} from 'rxjs';\n\nimport {TUI_SCROLL_REF} from './scroll-ref.directive';\nimport {TuiScrollbarService} from './scrollbar.service';\n\nconst MIN_WIDTH = 24;\n\ninterface ComputedDimension {\n scrollTop: number;\n scrollHeight: number;\n clientHeight: number;\n scrollLeft: number;\n scrollWidth: number;\n clientWidth: number;\n}\n\n@Directive({\n selector: '[tuiScrollbar]',\n providers: [TuiScrollbarService],\n})\nexport class TuiScrollbarDirective {\n private readonly el = inject(TUI_SCROLL_REF).nativeElement;\n private readonly style = tuiInjectElement().style;\n\n protected readonly scrollSub = inject(TuiScrollbarService)\n .pipe(takeUntilDestroyed())\n .subscribe(([top, left]) => {\n this.el.style.scrollBehavior = 'auto';\n\n if (this.tuiScrollbar() === 'horizontal') {\n this.el.scrollLeft = left;\n } else {\n this.el.scrollTop = top;\n }\n\n this.el.style.scrollBehavior = '';\n });\n\n protected readonly styleSub = merge(\n inject(WA_ANIMATION_FRAME).pipe(throttleTime(100, tuiZonefreeScheduler())),\n tuiScrollFrom(this.el),\n )\n .pipe(tuiZonefree(), takeUntilDestroyed())\n .subscribe(() => {\n const dimension: ComputedDimension = {\n scrollTop: this.el.scrollTop,\n scrollHeight: this.el.scrollHeight,\n clientHeight: this.el.clientHeight,\n scrollLeft: this.el.scrollLeft,\n scrollWidth: this.el.scrollWidth,\n clientWidth: this.el.clientWidth,\n };\n\n const thumb = `${this.getThumb(dimension) * 100}%`;\n const view = `${this.getView(dimension) * 100}%`;\n\n if (this.tuiScrollbar() === 'vertical') {\n this.style.top = thumb;\n this.style.height = view;\n } else {\n this.style.left = thumb;\n this.style.insetInlineStart = thumb;\n this.style.width = view;\n }\n });\n\n public readonly tuiScrollbar = input<'horizontal' | 'vertical'>('vertical');\n\n private getScrolled(dimension: ComputedDimension): number {\n return this.tuiScrollbar() === 'vertical'\n ? dimension.scrollTop / (dimension.scrollHeight - dimension.clientHeight)\n : dimension.scrollLeft / (dimension.scrollWidth - dimension.clientWidth);\n }\n\n private getCompensation(dimension: ComputedDimension): number {\n if (\n ((dimension.clientHeight * dimension.clientHeight) / dimension.scrollHeight >\n MIN_WIDTH &&\n this.tuiScrollbar() === 'vertical') ||\n ((dimension.clientWidth * dimension.clientWidth) / dimension.scrollWidth >\n MIN_WIDTH &&\n this.tuiScrollbar() === 'horizontal')\n ) {\n return 0;\n }\n\n return this.tuiScrollbar() === 'vertical'\n ? MIN_WIDTH / dimension.clientHeight\n : MIN_WIDTH / dimension.clientWidth;\n }\n\n private getThumb(dimension: ComputedDimension): number {\n const compensation = this.getCompensation(dimension) || this.getView(dimension);\n\n return Math.abs(this.getScrolled(dimension) * (1 - compensation));\n }\n\n private getView(dimension: ComputedDimension): number {\n return this.tuiScrollbar() === 'vertical'\n ? Math.ceil((dimension.clientHeight / dimension.scrollHeight) * 100) / 100\n : Math.ceil((dimension.clientWidth / dimension.scrollWidth) * 100) / 100;\n }\n}\n","import {tuiCreateOptions} from '@taiga-ui/cdk/utils/di';\n\nexport interface TuiScrollbarOptions {\n mode: 'always' | 'hidden' | 'hover' | 'native';\n}\n\nexport const TUI_DEFAULT_SCROLLBAR_OPTIONS: TuiScrollbarOptions = {mode: 'always'};\n\nexport const [TUI_SCROLLBAR_OPTIONS, tuiScrollbarOptionsProvider] =\n tuiCreateOptions<TuiScrollbarOptions>(TUI_DEFAULT_SCROLLBAR_OPTIONS);\n","import {AsyncPipe} from '@angular/common';\nimport {ChangeDetectionStrategy, Component, inject} from '@angular/core';\nimport {WA_ANIMATION_FRAME} from '@ng-web-apis/common';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {tuiZonefreeScheduler, tuiZoneOptimized} from '@taiga-ui/cdk/observables';\nimport {distinctUntilChanged, map, startWith, throttleTime} from 'rxjs';\n\nimport {TUI_SCROLL_REF} from './scroll-ref.directive';\nimport {TuiScrollbarDirective} from './scrollbar.directive';\nimport {TUI_SCROLLBAR_OPTIONS} from './scrollbar.options';\n\n@Component({\n selector: 'tui-scroll-controls',\n imports: [AsyncPipe, TuiAnimated, TuiScrollbarDirective],\n templateUrl: './scroll-controls.template.html',\n styleUrl: './scroll-controls.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiScrollControls {\n private readonly scrollRef = inject(TUI_SCROLL_REF).nativeElement;\n\n protected readonly nativeScrollbar = inject(TUI_SCROLLBAR_OPTIONS).mode === 'native';\n protected readonly refresh$ = inject(WA_ANIMATION_FRAME).pipe(\n throttleTime(300, tuiZonefreeScheduler()),\n map(() => this.scrollbars),\n startWith([false, false]),\n distinctUntilChanged((a, b) => a[0] === b[0] && a[1] === b[1]),\n tuiZoneOptimized(),\n );\n\n private get scrollbars(): [boolean, boolean] {\n const {clientHeight, scrollHeight, clientWidth, scrollWidth} = this.scrollRef;\n\n return [\n Math.ceil((clientHeight / scrollHeight) * 100) < 100,\n Math.ceil((clientWidth / scrollWidth) * 100) < 100,\n ];\n }\n}\n","@if (nativeScrollbar) {\n} @else {\n @if (refresh$ | async; as bars) {\n @if (bars[0]) {\n <div\n tuiAnimated\n class=\"t-bar t-bar_vertical\"\n [class.t-bar_has-horizontal]=\"bars[1]\"\n (mousedown.capture.prevent)=\"(0)\"\n >\n <div\n tuiScrollbar=\"vertical\"\n class=\"t-thumb\"\n ></div>\n </div>\n }\n @if (bars[1]) {\n <div\n tuiAnimated\n class=\"t-bar t-bar_horizontal\"\n [class.t-bar_has-vertical]=\"bars[0]\"\n (mousedown.capture.prevent)=\"(0)\"\n >\n <div\n tuiScrollbar=\"horizontal\"\n class=\"t-thumb\"\n ></div>\n </div>\n }\n }\n}\n","import {ChangeDetectionStrategy, Component, ElementRef, inject} from '@angular/core';\nimport {WA_IS_IOS} from '@ng-web-apis/platform';\nimport {tuiGetElementOffset, tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\n\nimport {TuiScrollControls} from './scroll-controls.component';\nimport {TUI_SCROLL_REF} from './scroll-ref.directive';\nimport {TUI_SCROLLBAR_OPTIONS} from './scrollbar.options';\n\n/**\n * An event for scrolling an element into view within {@link TuiScrollbar}.\n */\nexport const TUI_SCROLL_INTO_VIEW = 'tui-scroll-into-view';\n\n/**\n * An event to notify {@link TuiScrollbar} that\n * it should control a nested element.\n */\nexport const TUI_SCROLLABLE = 'tui-scrollable';\n\n@Component({\n selector: 'tui-scrollbar',\n imports: [TuiScrollControls],\n templateUrl: './scrollbar.template.html',\n styleUrl: './scrollbar.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n {\n provide: TUI_SCROLL_REF,\n useFactory: () => inject(TuiScrollbar).browserScrollRef,\n },\n ],\n host: {\n '[class._native-hidden]':\n 'options.mode !== \"native\" && (!isIOS || options.mode === \"hidden\")',\n [`(${TUI_SCROLLABLE}.stop)`]: 'scrollRef = $event.detail',\n [`(${TUI_SCROLL_INTO_VIEW}.stop)`]: 'scrollIntoView($event.detail)',\n },\n})\nexport class TuiScrollbar {\n private readonly el = tuiInjectElement();\n\n protected readonly options = inject(TUI_SCROLLBAR_OPTIONS);\n protected readonly isIOS = inject(WA_IS_IOS);\n protected readonly browserScrollRef = new ElementRef(this.el);\n\n protected get delegated(): boolean {\n return this.scrollRef !== this.el || this.options.mode === 'native';\n }\n\n protected get scrollRef(): HTMLElement {\n return this.browserScrollRef.nativeElement;\n }\n\n protected set scrollRef(element: HTMLElement) {\n this.browserScrollRef.nativeElement = element;\n }\n\n protected scrollIntoView(detail: HTMLElement): void {\n if (this.delegated) {\n return;\n }\n\n const {offsetHeight, offsetWidth} = detail;\n const {offsetTop, offsetLeft} = tuiGetElementOffset(this.scrollRef, detail);\n const scrollTop = offsetTop + offsetHeight / 2 - this.scrollRef.clientHeight / 2;\n const scrollLeft = offsetLeft + offsetWidth / 2 - this.scrollRef.clientWidth / 2;\n\n this.scrollRef.scrollTo?.(scrollLeft, scrollTop);\n }\n}\n","@if (!isIOS && options.mode !== 'native' && options.mode !== 'hidden') {\n <tui-scroll-controls\n class=\"t-bars\"\n [class.t-hover-mode]=\"options.mode === 'hover'\"\n />\n}\n<div\n class=\"t-content\"\n [class.t-content_delegated]=\"delegated\"\n>\n <ng-content />\n</div>\n","import {DestroyRef, Directive, effect, inject, input} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {timer} from 'rxjs';\n\nimport {TUI_SCROLL_INTO_VIEW} from './scrollbar.component';\n\n/**\n * Directive scrolls element into view inside tui-scrollbar\n */\n@Directive({selector: '[tuiScrollIntoView]'})\nexport class TuiScrollIntoView {\n private readonly el = tuiInjectElement();\n private readonly destroyRef = inject(DestroyRef);\n\n public readonly tuiScrollIntoView = input<boolean>();\n\n protected readonly dispatchEvent = effect(() => {\n const scroll = this.tuiScrollIntoView();\n\n if (!scroll) {\n return;\n }\n\n // Timeout is necessary in order to give element render cycle to get into its final spot\n // (for example if it is inside dropdown box which has to be positioned first)\n timer(0)\n .pipe(takeUntilDestroyed(this.destroyRef))\n .subscribe(() => {\n this.el.dispatchEvent(\n new CustomEvent<Element>(TUI_SCROLL_INTO_VIEW, {\n bubbles: true,\n detail: this.el,\n }),\n );\n });\n });\n}\n","import {Directive, type OnInit} from '@angular/core';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\n\nimport {TUI_SCROLLABLE} from './scrollbar.component';\n\n@Directive({selector: '[tuiScrollable]'})\nexport class TuiScrollable implements OnInit {\n private readonly el = tuiInjectElement();\n\n public ngOnInit(): void {\n this.el.dispatchEvent(\n new CustomEvent(TUI_SCROLLABLE, {bubbles: true, detail: this.el}),\n );\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;AAIO,MAAM,mBAAmB,GAAG;AACtB,MAAA,cAAc,GAAG,IAAI,cAAc,CAAC,SAAS,GAAG,gBAAgB,GAAG,EAAE,EAAE;AAChF,IAAA,OAAO,EAAE,MAAM,IAAI,UAAU,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,eAAe,CAAC;AAClE,CAAA;MAMY,YAAY,CAAA;+GAAZ,YAAY,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;mGAAZ,YAAY,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,gBAAA,EAAA,SAAA,EAFV,CAAC,UAAU,CAAC,cAAc,EAAE,UAAU,CAAC,CAAC,EAAA,QAAA,EAAA,EAAA,EAA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AA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAD7B,SAAS;mBAAC,EAAC,QAAQ,EAAE,qBAAqB,EAAC;;;MCJ/B,aAAa,CAAA;AAD1B,IAAA,WAAA,GAAA;QAEqB,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAE;AAO3C;IALU,QAAQ,GAAA;QACX,IAAI,CAAC,EAAE,CAAC,aAAa,CACjB,IAAI,WAAW,CAAC,cAAc,EAAE,EAAC,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,EAAC,CAAC,CACpE;;+GANI,aAAa,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;mGAAb,aAAa,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,iBAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAAb,aAAa,EAAA,UAAA,EAAA,CAAA;kBADzB,SAAS;mBAAC,EAAC,QAAQ,EAAE,iBAAiB,EAAC;;;ACLxC;;AAEG;;;;"}
@@ -24,10 +24,10 @@ class TuiSpinButton {
24
24
  this.rightClick.emit();
25
25
  }
26
26
  }
27
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiSpinButton, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
28
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: TuiSpinButton, isStandalone: true, selector: "tui-spin-button", inputs: { focusable: { classPropertyName: "focusable", publicName: "focusable", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, leftDisabled: { classPropertyName: "leftDisabled", publicName: "leftDisabled", isSignal: true, isRequired: false, transformFunction: null }, rightDisabled: { classPropertyName: "rightDisabled", publicName: "rightDisabled", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { leftClick: "leftClick", rightClick: "rightClick" }, host: { listeners: { "mousedown.zoneless.prevent": "(0)", "keydown.arrowLeft.prevent": "onLeftClick()", "keydown.arrowRight.prevent": "onRightClick()" } }, ngImport: i0, template: "@if (spinTexts(); as texts) {\n <button\n appearance=\"flat\"\n automation-id=\"tui-spin-button__left\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [class.t-button_hidden]=\"disabled() || leftDisabled()\"\n [iconStart]=\"icons.decrement\"\n [tabIndex]=\"focusable() ? 0 : -1\"\n (click)=\"onLeftClick()\"\n >\n {{ texts[0] }}\n </button>\n <span class=\"t-content t-calendar-title\">\n <ng-content />\n </span>\n <button\n appearance=\"flat\"\n automation-id=\"tui-spin-button__right\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [class.t-button_hidden]=\"disabled() || rightDisabled()\"\n [iconStart]=\"icons.increment\"\n [tabIndex]=\"focusable() ? 0 : -1\"\n (click)=\"onRightClick()\"\n >\n {{ texts[1] }}\n </button>\n}\n", styles: [":host{display:flex;align-items:center;justify-content:space-between;font:var(--tui-font-body-l);text-align:center;font-weight:700}.t-button{transform:scaleX(var(--tui-inline))}.t-button_hidden{visibility:hidden}.t-content{padding:0 .5rem}\n"], dependencies: [{ kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
27
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiSpinButton, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
28
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.18", type: TuiSpinButton, isStandalone: true, selector: "tui-spin-button", inputs: { focusable: { classPropertyName: "focusable", publicName: "focusable", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, leftDisabled: { classPropertyName: "leftDisabled", publicName: "leftDisabled", isSignal: true, isRequired: false, transformFunction: null }, rightDisabled: { classPropertyName: "rightDisabled", publicName: "rightDisabled", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { leftClick: "leftClick", rightClick: "rightClick" }, host: { listeners: { "mousedown.zoneless.prevent": "(0)", "keydown.arrowLeft.prevent": "onLeftClick()", "keydown.arrowRight.prevent": "onRightClick()" } }, ngImport: i0, template: "@if (spinTexts(); as texts) {\n <button\n appearance=\"flat\"\n automation-id=\"tui-spin-button__left\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [class.t-button_hidden]=\"disabled() || leftDisabled()\"\n [iconStart]=\"icons.decrement\"\n [tabIndex]=\"focusable() ? 0 : -1\"\n (click)=\"onLeftClick()\"\n >\n {{ texts[0] }}\n </button>\n <span class=\"t-content t-calendar-title\">\n <ng-content />\n </span>\n <button\n appearance=\"flat\"\n automation-id=\"tui-spin-button__right\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [class.t-button_hidden]=\"disabled() || rightDisabled()\"\n [iconStart]=\"icons.increment\"\n [tabIndex]=\"focusable() ? 0 : -1\"\n (click)=\"onRightClick()\"\n >\n {{ texts[1] }}\n </button>\n}\n", styles: [":host{display:flex;align-items:center;justify-content:space-between;font:var(--tui-font-body-l);text-align:center;font-weight:700}.t-button{transform:scaleX(var(--tui-inline))}.t-button_hidden{visibility:hidden}.t-content{padding:0 .5rem}\n"], dependencies: [{ kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
29
29
  }
30
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiSpinButton, decorators: [{
30
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: TuiSpinButton, decorators: [{
31
31
  type: Component,
32
32
  args: [{ selector: 'tui-spin-button', imports: [TuiButton], changeDetection: ChangeDetectionStrategy.OnPush, host: {
33
33
  '(mousedown.zoneless.prevent)': '(0)',