@taiga-ui/core 4.2.0 → 4.4.0-canary.6e6e993

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 (84) hide show
  1. package/components/data-list/data-list.component.d.ts +0 -1
  2. package/components/icon/icon.component.d.ts +5 -2
  3. package/components/scrollbar/scrollbar.component.d.ts +2 -1
  4. package/components/scrollbar/scrollbar.directive.d.ts +4 -4
  5. package/components/textfield/textfield.component.d.ts +1 -0
  6. package/directives/dropdown/dropdown-context.directive.d.ts +1 -1
  7. package/directives/dropdown/dropdown-open.directive.d.ts +1 -1
  8. package/esm2022/components/calendar/calendar-sheet.component.mjs +6 -7
  9. package/esm2022/components/calendar/calendar-year.component.mjs +6 -7
  10. package/esm2022/components/data-list/data-list.component.mjs +12 -31
  11. package/esm2022/components/dialog/dialog.component.mjs +8 -16
  12. package/esm2022/components/error/error.component.mjs +6 -9
  13. package/esm2022/components/expand/expand.component.mjs +10 -24
  14. package/esm2022/components/icon/icon.component.mjs +18 -10
  15. package/esm2022/components/loader/loader.component.mjs +8 -11
  16. package/esm2022/components/notification/notification.directive.mjs +6 -6
  17. package/esm2022/components/notification/notification.options.mjs +2 -2
  18. package/esm2022/components/root/root.component.mjs +1 -1
  19. package/esm2022/components/scrollbar/scroll-controls.component.mjs +3 -3
  20. package/esm2022/components/scrollbar/scrollbar.component.mjs +17 -18
  21. package/esm2022/components/scrollbar/scrollbar.directive.mjs +31 -22
  22. package/esm2022/components/spin-button/spin-button.component.mjs +4 -8
  23. package/esm2022/components/textfield/select.directive.mjs +4 -4
  24. package/esm2022/components/textfield/textfield.component.mjs +6 -3
  25. package/esm2022/directives/dropdown/dropdown-context.directive.mjs +17 -41
  26. package/esm2022/directives/dropdown/dropdown-hover.directive.mjs +5 -5
  27. package/esm2022/directives/dropdown/dropdown-open.directive.mjs +15 -23
  28. package/esm2022/directives/hint/hint-pointer.directive.mjs +6 -6
  29. package/esm2022/directives/hint/hint.component.mjs +4 -6
  30. package/esm2022/directives/icons/icons.directive.mjs +2 -2
  31. package/esm2022/pipes/month/month.pipe.mjs +2 -2
  32. package/esm2022/services/breakpoint.service.mjs +2 -2
  33. package/esm2022/services/dark-theme.service.mjs +4 -1
  34. package/esm2022/tokens/dark-mode.mjs +40 -0
  35. package/esm2022/tokens/icon-resolver.mjs +12 -10
  36. package/esm2022/tokens/icons.mjs +8 -4
  37. package/esm2022/tokens/index.mjs +2 -1
  38. package/esm2022/utils/format/number-to-string-without-exp.mjs +2 -2
  39. package/fesm2022/taiga-ui-core-components-calendar.mjs +9 -11
  40. package/fesm2022/taiga-ui-core-components-calendar.mjs.map +1 -1
  41. package/fesm2022/taiga-ui-core-components-data-list.mjs +11 -30
  42. package/fesm2022/taiga-ui-core-components-data-list.mjs.map +1 -1
  43. package/fesm2022/taiga-ui-core-components-dialog.mjs +7 -15
  44. package/fesm2022/taiga-ui-core-components-dialog.mjs.map +1 -1
  45. package/fesm2022/taiga-ui-core-components-error.mjs +5 -8
  46. package/fesm2022/taiga-ui-core-components-error.mjs.map +1 -1
  47. package/fesm2022/taiga-ui-core-components-expand.mjs +9 -23
  48. package/fesm2022/taiga-ui-core-components-expand.mjs.map +1 -1
  49. package/fesm2022/taiga-ui-core-components-icon.mjs +17 -9
  50. package/fesm2022/taiga-ui-core-components-icon.mjs.map +1 -1
  51. package/fesm2022/taiga-ui-core-components-loader.mjs +7 -10
  52. package/fesm2022/taiga-ui-core-components-loader.mjs.map +1 -1
  53. package/fesm2022/taiga-ui-core-components-notification.mjs +6 -6
  54. package/fesm2022/taiga-ui-core-components-notification.mjs.map +1 -1
  55. package/fesm2022/taiga-ui-core-components-root.mjs +1 -1
  56. package/fesm2022/taiga-ui-core-components-scrollbar.mjs +48 -40
  57. package/fesm2022/taiga-ui-core-components-scrollbar.mjs.map +1 -1
  58. package/fesm2022/taiga-ui-core-components-spin-button.mjs +3 -7
  59. package/fesm2022/taiga-ui-core-components-spin-button.mjs.map +1 -1
  60. package/fesm2022/taiga-ui-core-components-textfield.mjs +8 -5
  61. package/fesm2022/taiga-ui-core-components-textfield.mjs.map +1 -1
  62. package/fesm2022/taiga-ui-core-directives-dropdown.mjs +32 -64
  63. package/fesm2022/taiga-ui-core-directives-dropdown.mjs.map +1 -1
  64. package/fesm2022/taiga-ui-core-directives-hint.mjs +7 -9
  65. package/fesm2022/taiga-ui-core-directives-hint.mjs.map +1 -1
  66. package/fesm2022/taiga-ui-core-directives-icons.mjs +2 -2
  67. package/fesm2022/taiga-ui-core-directives-icons.mjs.map +1 -1
  68. package/fesm2022/taiga-ui-core-pipes-month.mjs +1 -1
  69. package/fesm2022/taiga-ui-core-pipes-month.mjs.map +1 -1
  70. package/fesm2022/taiga-ui-core-services.mjs +4 -1
  71. package/fesm2022/taiga-ui-core-services.mjs.map +1 -1
  72. package/fesm2022/taiga-ui-core-tokens.mjs +57 -15
  73. package/fesm2022/taiga-ui-core-tokens.mjs.map +1 -1
  74. package/fesm2022/taiga-ui-core-utils-format.mjs +1 -1
  75. package/fesm2022/taiga-ui-core-utils-format.mjs.map +1 -1
  76. package/package.json +324 -324
  77. package/services/dark-theme.service.d.ts +3 -0
  78. package/styles/components/icon.less +1 -1
  79. package/styles/components/icons.less +1 -0
  80. package/styles/components/textfield.less +9 -11
  81. package/tokens/dark-mode.d.ts +6 -0
  82. package/tokens/icon-resolver.d.ts +4 -0
  83. package/tokens/icons.d.ts +4 -0
  84. package/tokens/index.d.ts +1 -0
@@ -1,5 +1,8 @@
1
1
  import { Observable } from 'rxjs';
2
2
  import * as i0 from "@angular/core";
3
+ /**
4
+ * @deprecated use {@link TUI_DARK_MODE} instead
5
+ */
3
6
  export declare class TuiDarkThemeService extends Observable<boolean> {
4
7
  constructor();
5
8
  static ɵfac: i0.ɵɵFactoryDeclaration<TuiDarkThemeService, never>;
@@ -34,7 +34,7 @@ tui-icon {
34
34
 
35
35
  content: '';
36
36
  display: block;
37
- mask: var(--t-icon) no-repeat center/contain;
37
+ mask: var(--t-icon) no-repeat center/contain intersect;
38
38
  background: currentColor;
39
39
  }
40
40
  }
@@ -25,6 +25,7 @@
25
25
  display: var(--t-icon-start);
26
26
  width: 1em;
27
27
  height: 1em;
28
+ line-height: 1em;
28
29
  font-size: 1.5rem;
29
30
  flex-shrink: 0;
30
31
  background: currentColor;
@@ -15,6 +15,7 @@ tui-textfield {
15
15
  padding: 0 var(--tui-padding-l);
16
16
  border-radius: var(--tui-radius-l);
17
17
  font: var(--tui-font-text-m);
18
+ box-sizing: border-box;
18
19
 
19
20
  &[style*='--t-icon-start:'] {
20
21
  --t-left: 2.25rem;
@@ -53,14 +54,12 @@ tui-textfield {
53
54
  }
54
55
 
55
56
  &::before {
56
- margin-inline-start: -0.25rem;
57
- margin-inline-end: 0.5rem;
57
+ margin: 0 0.5rem 0 -0.125rem;
58
58
  font-size: 1rem;
59
59
  }
60
60
 
61
61
  &::after {
62
- margin-inline-end: -0.175rem;
63
- margin-inline-start: 0.25rem;
62
+ margin: 0 -0.175rem 0 0.25rem;
64
63
  font-size: 1rem;
65
64
  }
66
65
 
@@ -90,13 +89,11 @@ tui-textfield {
90
89
  }
91
90
 
92
91
  &::before {
93
- margin-inline-start: -0.125rem;
94
- margin-inline-end: 0.375rem;
92
+ margin: 0 0.375rem 0 -0.125rem;
95
93
  }
96
94
 
97
95
  &::after {
98
- margin-inline-start: 0.375rem;
99
- margin-inline-end: -0.125rem;
96
+ margin: 0 -0.125rem 0 0.375rem;
100
97
  }
101
98
 
102
99
  input,
@@ -220,7 +217,7 @@ tui-textfield {
220
217
  }
221
218
  }
222
219
 
223
- label:defined {
220
+ label:not([data-orientation='vertical']) {
224
221
  .transition(all);
225
222
  .text-overflow();
226
223
 
@@ -231,8 +228,8 @@ tui-textfield {
231
228
  }
232
229
 
233
230
  label:defined,
234
- input::placeholder,
235
- select._empty {
231
+ input:defined::placeholder,
232
+ select:defined._empty {
236
233
  color: var(--tui-text-secondary);
237
234
  }
238
235
 
@@ -260,6 +257,7 @@ tui-textfield {
260
257
  align-items: center;
261
258
  gap: 0.25rem;
262
259
  margin-inline-start: auto;
260
+ isolation: isolate;
263
261
  }
264
262
 
265
263
  .t-clear {
@@ -0,0 +1,6 @@
1
+ import { InjectionToken, type WritableSignal } from '@angular/core';
2
+ export declare const TUI_DARK_MODE_DEFAULT_KEY = "tuiDark";
3
+ export declare const TUI_DARK_MODE_KEY: InjectionToken<string>;
4
+ export declare const TUI_DARK_MODE: InjectionToken<WritableSignal<boolean> & {
5
+ reset(): void;
6
+ }>;
@@ -1,5 +1,9 @@
1
1
  import type { Provider } from '@angular/core';
2
2
  import type { TuiStringHandler } from '@taiga-ui/cdk/types';
3
+ export declare const TUI_ICON_RESOLVER: import("@angular/core").InjectionToken<TuiStringHandler<string>>;
4
+ /**
5
+ * @deprecated use {@link TUI_ICON_RESOLVER}
6
+ */
3
7
  export declare const TUI_ICON_START_RESOLVER: import("@angular/core").InjectionToken<TuiStringHandler<string>>;
4
8
  export declare function tuiInjectIconResolver(): TuiStringHandler<string>;
5
9
  export declare function tuiIconResolverProvider(useValue: TuiStringHandler<string>): Provider;
package/tokens/icons.d.ts CHANGED
@@ -1,3 +1,7 @@
1
1
  import type { FactoryProvider } from '@angular/core';
2
+ export declare const TUI_ICON_REGISTRY: import("@angular/core").InjectionToken<Record<string, string>>;
3
+ /**
4
+ * @deprecated: use {@link TUI_ICON_REGISTRY}
5
+ */
2
6
  export declare const TUI_ICON_STARTS: import("@angular/core").InjectionToken<Record<string, string>>;
3
7
  export declare function tuiIconsProvider(icons: Record<string, string>): FactoryProvider;
package/tokens/index.d.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  export * from './animations-speed';
2
2
  export * from './assets-path';
3
3
  export * from './common-icons';
4
+ export * from './dark-mode';
4
5
  export * from './date-format';
5
6
  export * from './day-type-handler';
6
7
  export * from './first-day-of-week';