@ts-core/angular 15.0.1 → 15.0.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 (48) hide show
  1. package/bottomSheet/BottomSheetImpl.d.ts +0 -11
  2. package/bottomSheet/component/BottomSheetBaseComponent.d.ts +0 -5
  3. package/component/tab-group/tab-group.component.d.ts +4 -2
  4. package/directive/ResizeDirective.d.ts +2 -2
  5. package/directive/SelectOnFocusDirective.d.ts +1 -1
  6. package/esm2020/bottomSheet/BottomSheetImpl.mjs +2 -47
  7. package/esm2020/bottomSheet/BottomSheetService.mjs +2 -2
  8. package/esm2020/bottomSheet/component/BottomSheetBaseComponent.mjs +1 -16
  9. package/esm2020/component/tab-group/tab-group.component.mjs +15 -4
  10. package/esm2020/directive/AutoScrollBottomDirective.mjs +2 -2
  11. package/esm2020/directive/MenuTriggerForDirective.mjs +5 -3
  12. package/esm2020/directive/ResizeDirective.mjs +5 -5
  13. package/esm2020/directive/SelectOnFocusDirective.mjs +2 -2
  14. package/esm2020/language/LanguageMatPaginatorIntl.mjs +5 -7
  15. package/esm2020/manager/ResizeManager.mjs +3 -11
  16. package/esm2020/notification/NotificationService.mjs +2 -2
  17. package/esm2020/theme/ThemeStyleDirective.mjs +2 -2
  18. package/esm2020/util/ViewUtil.mjs +1 -1
  19. package/esm2020/window/IWindow.mjs +2 -1
  20. package/esm2020/window/WindowImpl.mjs +10 -17
  21. package/esm2020/window/WindowService.mjs +2 -2
  22. package/fesm2015/ts-core-angular.mjs +867 -931
  23. package/fesm2015/ts-core-angular.mjs.map +1 -1
  24. package/fesm2020/ts-core-angular.mjs +867 -931
  25. package/fesm2020/ts-core-angular.mjs.map +1 -1
  26. package/htdocs/common.js +3 -3
  27. package/manager/ResizeManager.d.ts +1 -1
  28. package/package.json +1 -2
  29. package/style/_filter.scss +14 -0
  30. package/style/_mouse.scss +27 -0
  31. package/style/_scroll.scss +20 -0
  32. package/style/_text.scss +12 -0
  33. package/style/mat/_core.scss +317 -0
  34. package/style/mat/_index.scss +169 -0
  35. package/style/mat/_variables.scss +1 -0
  36. package/style/mat/bootstrap/_background.scss +22 -4
  37. package/style/mat/bootstrap/_border.scss +67 -72
  38. package/style/mat/bootstrap/_index.scss +27 -0
  39. package/style/mat/bootstrap/_text.scss +28 -24
  40. package/style/mat/helper/_theme.scss +96 -0
  41. package/style/mat/helper/_typography.scss +15 -0
  42. package/window/IWindow.d.ts +1 -0
  43. package/window/WindowImpl.d.ts +1 -2
  44. package/style/mat/bootstrap/_variables.scss +0 -8
  45. package/style/mat/vi-mat-bootstrap.scss +0 -50
  46. package/style/mat/vi-mat.scss +0 -570
  47. package/style/mixin.scss +0 -69
  48. package/style/mouse.scss +0 -47
@@ -1,26 +1,60 @@
1
- @mixin vi-mat-theme-bootstrap-border($theme, $text-primary-default, $text-accent-default) {
2
- $warn: map-get($theme, warn);
3
- $accent: map-get($theme, accent);
4
- $primary: map-get($theme, primary);
5
- $is-dark: map-get($theme, is-dark);
6
- $foreground: map-get($theme, foreground);
1
+ @use 'sass:map';
2
+ @use '@angular/material' as mat;
3
+ @use '../variables' as var;
7
4
 
8
- $border-color: map-get($foreground, divider);
9
- $text-base-color: map-get($foreground, base);
5
+ @import 'bootstrap/scss/functions';
6
+ @import 'bootstrap/scss/variables';
7
+ @import 'bootstrap/scss/mixins/breakpoints';
10
8
 
11
- $warn-color: mat-color($warn);
12
- $accent-color: mat-color($accent, $text-accent-default);
13
- $primary-color: mat-color($primary, $text-primary-default);
14
-
15
- @if $is-dark {
16
- $accent-color: mat-color($accent);
17
- $primary-color: mat-color($primary);
9
+ @mixin core() {
10
+ $border-radius: var.$border-radius;
11
+ // Rounded
12
+ .rounded {
13
+ border-radius: $border-radius !important;
14
+ }
15
+ .rounded-top {
16
+ border-top-left-radius: $border-radius !important;
17
+ border-top-right-radius: $border-radius !important;
18
+ }
19
+ .rounded-right {
20
+ border-top-right-radius: $border-radius !important;
21
+ border-bottom-right-radius: $border-radius !important;
22
+ }
23
+ .rounded-bottom {
24
+ border-bottom-right-radius: $border-radius !important;
25
+ border-bottom-left-radius: $border-radius !important;
26
+ }
27
+ .rounded-left {
28
+ border-top-left-radius: $border-radius !important;
29
+ border-bottom-left-radius: $border-radius !important;
18
30
  }
31
+ .rounded-circle {
32
+ border-radius: 50% !important;
33
+ }
34
+ }
35
+
36
+ @mixin color($theme) {
37
+ $warn: map.get($theme, 'warn');
38
+ $accent: map.get($theme, 'accent');
39
+ $primary: map.get($theme, 'primary');
40
+ $is-dark: map.get($theme, 'is-dark');
41
+ $foreground: map.get($theme, 'foreground');
42
+
43
+ $base-color: map.get($foreground, 'base');
44
+ $base-color-invert: map.get($foreground, 'base-invert');
45
+
46
+ $border-color: map.get($foreground, 'divider');
47
+
48
+ $warn-color: mat.get-color-from-palette($warn);
49
+ $accent-color: mat.get-color-from-palette($accent);
50
+ $primary-color: mat.get-color-from-palette($primary);
51
+
52
+ $border-width: 1px;
19
53
 
20
54
  @each $breakpoint in map-keys($grid-breakpoints) {
21
55
  @include media-breakpoint-up($breakpoint) {
22
56
  $infix: breakpoint-infix($breakpoint, $grid-breakpoints);
23
- @include vi-mat-theme-bootstrap-border-mixin($infix, $border-width, $border-color);
57
+ @include border-mixin($infix, $border-width, $border-color);
24
58
  }
25
59
  }
26
60
 
@@ -50,55 +84,24 @@
50
84
  }
51
85
  }
52
86
  .border-base {
53
- border-color: $text-base-color !important;
87
+ border-color: $base-color !important;
54
88
  }
55
89
  .border-base-hover {
56
90
  &:hover {
57
- border-color: $text-base-color !important;
91
+ border-color: $base-color !important;
58
92
  }
59
93
  }
60
94
  .border-base-invert {
61
- border-color: $text-base-color !important;
62
- @include filter-invert(1);
95
+ border-color: $base-color-invert !important;
63
96
  }
64
97
  .border-base-invert-hover {
65
98
  &:hover {
66
- border-color: $text-base-color !important;
67
- @include filter-invert(1);
99
+ border-color: $base-color-invert !important;
68
100
  }
69
101
  }
70
-
71
- // Rounded
72
- .rounded {
73
- border-radius: $border-radius !important;
74
- }
75
-
76
- .rounded-top {
77
- border-top-left-radius: $border-radius !important;
78
- border-top-right-radius: $border-radius !important;
79
- }
80
-
81
- .rounded-right {
82
- border-top-right-radius: $border-radius !important;
83
- border-bottom-right-radius: $border-radius !important;
84
- }
85
-
86
- .rounded-bottom {
87
- border-bottom-right-radius: $border-radius !important;
88
- border-bottom-left-radius: $border-radius !important;
89
- }
90
-
91
- .rounded-left {
92
- border-top-left-radius: $border-radius !important;
93
- border-bottom-left-radius: $border-radius !important;
94
- }
95
-
96
- .rounded-circle {
97
- border-radius: 50% !important;
98
- }
99
102
  }
100
103
 
101
- @mixin vi-mat-theme-bootstrap-border-mixin($infix, $width, $color) {
104
+ @mixin border-mixin($infix, $width, $color) {
102
105
  // Transparent
103
106
  .border-transparent {
104
107
  border-width: $width;
@@ -110,9 +113,6 @@
110
113
  border-top-width: $width;
111
114
  border-top-color: $color !important;
112
115
  border-top-style: solid !important;
113
- &.dashed {
114
- border-top-style: dashed !important;
115
- }
116
116
  }
117
117
  .border#{$infix}-top-0 {
118
118
  border-top-style: none !important;
@@ -122,9 +122,6 @@
122
122
  border-right-width: $width;
123
123
  border-right-color: $color !important;
124
124
  border-right-style: solid !important;
125
- &.dashed {
126
- border-right-style: dashed !important;
127
- }
128
125
  }
129
126
  .border#{$infix}-right-0 {
130
127
  border-right-style: none !important;
@@ -134,9 +131,6 @@
134
131
  border-bottom-width: $width;
135
132
  border-bottom-color: $color !important;
136
133
  border-bottom-style: solid !important;
137
- &.dashed {
138
- border-bottom-style: dashed !important;
139
- }
140
134
  }
141
135
  .border#{$infix}-bottom-0 {
142
136
  border-bottom-style: none !important;
@@ -146,9 +140,6 @@
146
140
  border-left-width: $width;
147
141
  border-left-color: $color !important;
148
142
  border-left-style: solid !important;
149
- &.dashed {
150
- border-left-style: dashed !important;
151
- }
152
143
  }
153
144
  .border#{$infix}-left-0 {
154
145
  border-left-style: none !important;
@@ -163,10 +154,6 @@
163
154
  border-right-width: $width;
164
155
  border-right-color: $color !important;
165
156
  border-right-style: solid !important;
166
- &.dashed {
167
- border-left-style: dashed !important;
168
- border-right-style: dashed !important;
169
- }
170
157
  }
171
158
  .border#{$infix}-x-0 {
172
159
  border-left-style: none !important;
@@ -195,13 +182,21 @@
195
182
  border-bottom-width: $width;
196
183
  border-bottom-color: $color;
197
184
  border-bottom-style: solid !important;
198
- &.dashed {
199
- border-top-style: dashed !important;
200
- border-bottom-style: dashed !important;
201
- }
202
185
  }
203
186
  .border#{$infix}-x-0 {
204
187
  border-top-style: none !important;
205
188
  border-bottom-style: none !important;
206
189
  }
207
190
  }
191
+
192
+ @mixin typography($typography) {
193
+ }
194
+ @mixin theme($theme, $typography) {
195
+ $color: mat.get-color-config($theme);
196
+ @if $color != null {
197
+ @include color($theme);
198
+ }
199
+ @if $typography != null {
200
+ @include typography($typography);
201
+ }
202
+ }
@@ -0,0 +1,27 @@
1
+ @use 'text' as text;
2
+ @use 'border' as border;
3
+ @use 'background' as background;
4
+ @use '../helper/typography' as typography;
5
+
6
+ @mixin core() {
7
+ @include border.core();
8
+ }
9
+ @mixin color($theme) {
10
+ @include text.color($theme);
11
+ @include border.color($theme);
12
+ @include background.color($theme);
13
+ }
14
+ @mixin typography($typography) {
15
+ @include text.typography($typography);
16
+ @include border.typography($typography);
17
+ @include background.typography($typography);
18
+ }
19
+ @mixin theme($theme, $typography) {
20
+ $color: mat.get-color-config($theme);
21
+ @if $color != null {
22
+ @include color($theme);
23
+ }
24
+ @if $typography != null {
25
+ @include typography($typography);
26
+ }
27
+ }
@@ -1,43 +1,47 @@
1
- @mixin vi-mat-theme-bootstrap-text($theme, $text-primary-default, $text-accent-default) {
2
- $warn: map-get($theme, warn);
3
- $accent: map-get($theme, accent);
4
- $primary: map-get($theme, primary);
5
- $is-dark: map-get($theme, is-dark);
6
- $foreground: map-get($theme, foreground);
1
+ @use 'sass:map';
2
+ @use '@angular/material' as mat;
7
3
 
8
- $text-color: map-get($foreground, text);
9
- $text-base-color: map-get($foreground, base);
10
- $text-accent-color: mat-color($accent, $text-accent-default);
11
- $text-primary-color: mat-color($primary, $text-primary-default);
12
-
13
- @if $is-dark {
14
- $text-accent-color: mat-color($accent);
15
- $text-primary-color: mat-color($primary);
16
- }
4
+ @mixin color($theme, $text-primary-default: 700, $text-accent-default: 500) {
5
+ $warn: map.get($theme, 'warn');
6
+ $accent: map.get($theme, 'accent');
7
+ $primary: map.get($theme, 'primary');
8
+ $is-dark: map.get($theme, 'is-dark');
9
+ $foreground: map.get($theme, 'foreground');
17
10
 
18
11
  .text-base {
19
- color: $text-base-color !important;
12
+ color: map.get($foreground, 'base') !important;
20
13
  }
21
14
  .text-base-invert {
22
- color: $text-base-color !important;
23
- @include filter-invert(1);
15
+ color: map.get($foreground, 'base-invert') !important;
24
16
  }
25
17
  .text-accent {
26
- color: $text-accent-color !important;
18
+ color: mat.get-color-from-palette($accent, $text-accent-default) !important;
27
19
  }
28
20
  .text-primary {
29
- color: $text-primary-color !important;
21
+ color: mat.get-color-from-palette($primary, $text-primary-default) !important;
30
22
  }
31
23
  .text-danger {
32
- color: mat-color($warn) !important;
24
+ color: mat.get-color-from-palette($warn) !important;
33
25
  }
34
26
  .text-warning {
35
- color: map-get($foreground, warning-text) !important;
27
+ color: map.get($foreground, 'warning-text') !important;
36
28
  }
37
29
  .text-success {
38
- color: map-get($foreground, success-text) !important;
30
+ color: map.get($foreground, 'success-text') !important;
39
31
  }
40
32
  .text-secondary {
41
- color: map-get($foreground, secondary-text) !important;
33
+ color: map.get($foreground, 'secondary-text') !important;
42
34
  }
43
35
  }
36
+
37
+ @mixin typography($typography) {
38
+ }
39
+ @mixin theme($theme, $typography) {
40
+ $color: mat.get-color-config($theme);
41
+ @if $color != null {
42
+ @include color($theme);
43
+ }
44
+ @if $typography != null {
45
+ @include typography($typography);
46
+ }
47
+ }
@@ -0,0 +1,96 @@
1
+ @use 'sass:map';
2
+
3
+ @function background-change($theme, $name, $value) {
4
+ $modified-theme: $theme;
5
+ $theme-color: map.get($theme, 'color');
6
+ $color-palette: map.get($theme-color, 'background');
7
+ @if $color-palette {
8
+ $color-palette: map.merge(
9
+ $color-palette,
10
+ (
11
+ $name: $value,
12
+ )
13
+ );
14
+ }
15
+ @if $color-palette {
16
+ $modified-theme: map.merge(
17
+ $modified-theme,
18
+ (
19
+ color:
20
+ map.merge(
21
+ $theme-color,
22
+ (
23
+ background: $color-palette,
24
+ )
25
+ ),
26
+ )
27
+ );
28
+ }
29
+
30
+ $palette: map.get($theme, 'background');
31
+ @if $palette{
32
+ $palette: map.merge(
33
+ $palette,
34
+ (
35
+ $name: $value,
36
+ )
37
+ );
38
+ }
39
+ @if $palette {
40
+ $modified-theme: map.merge(
41
+ $modified-theme,
42
+ (
43
+ background: $palette,
44
+ )
45
+ );
46
+ }
47
+ @return $modified-theme;
48
+ }
49
+
50
+ @function foreground-change($theme, $name, $value) {
51
+ $modified-theme: $theme;
52
+ $theme-color: map.get($theme, color);
53
+ $color-palette: map.get($theme-color, 'foreground');
54
+ @if $color-palette {
55
+ $color-palette: map.merge(
56
+ $color-palette,
57
+ (
58
+ $name: $value,
59
+ )
60
+ );
61
+ }
62
+ @if $color-palette {
63
+ $modified-theme: map.merge(
64
+ $modified-theme,
65
+ (
66
+ color:
67
+ map.merge(
68
+ $theme-color,
69
+ (
70
+ foreground: $color-palette,
71
+ )
72
+ ),
73
+ )
74
+ );
75
+ }
76
+
77
+ $palette: map.get($theme, 'foreground');
78
+ @if $palette{
79
+ $palette: map.merge(
80
+ $palette,
81
+ (
82
+ $name: $value,
83
+ )
84
+ );
85
+ }
86
+ @if $palette {
87
+ $modified-theme: map.merge(
88
+ $modified-theme,
89
+ (
90
+ foreground: $palette,
91
+ )
92
+ );
93
+ }
94
+ @return $modified-theme;
95
+ }
96
+
@@ -0,0 +1,15 @@
1
+ @use 'sass:map';
2
+ @use '@angular/material' as mat;
3
+
4
+ @mixin level($typography, $name, $isImportant: true) {
5
+ @if $isImportant {
6
+ font-size: mat.font-size($typography, $name) !important;
7
+ font-family: mat.font-family($typography, $name) !important;
8
+ font-weight: mat.font-weight($typography, $name) !important;
9
+ line-height: mat.line-height($typography, $name) !important;
10
+ letter-spacing: mat.letter-spacing($typography, $name) !important;
11
+ }
12
+ @else {
13
+ @include mat.typography-level($typography, $name);
14
+ }
15
+ }
@@ -36,6 +36,7 @@ export declare enum WindowEvent {
36
36
  RESIZED = "RESIZED",
37
37
  DISABLED_CHANGED = "DISABLED_CHANGED",
38
38
  MINIMIZED_CHANGED = "MINIMIZED_CHANGED",
39
+ IS_ON_TOP_CHANGED = "IS_ON_TOP_CHANGED",
39
40
  EXPAND = "EXPAND",
40
41
  SET_ON_TOP = "SET_ON_TOP"
41
42
  }
@@ -12,7 +12,6 @@ export declare class WindowImpl<T = any> extends WindowBase<T> implements IWindo
12
12
  static SHAKE_DELAY: number;
13
13
  static RESIZE_DELAY: number;
14
14
  private _isBlink;
15
- private blinkTimer;
16
15
  private _isShaking;
17
16
  private shakeTimer;
18
17
  private resizeTimer;
@@ -43,12 +42,12 @@ export declare class WindowImpl<T = any> extends WindowBase<T> implements IWindo
43
42
  protected commitIsBlinkProperties(): void;
44
43
  protected commitIsShakingProperties(): void;
45
44
  protected commitIsDisabledProperties(): void;
45
+ protected commitIsOnTopProperties(): void;
46
46
  protected commitIsMinimizedProperties(): void;
47
47
  protected getConfig(): WindowConfig;
48
48
  protected getContainer(): HTMLElement;
49
49
  protected getReference(): MatDialogRef<IWindowContent<T>>;
50
50
  protected isNeedClickStopPropagation(event: MouseEvent): boolean;
51
- private stopBlinkIfNeed;
52
51
  protected resizeHandler: () => void;
53
52
  protected mouseDownHandler(event: MouseEvent): void;
54
53
  protected mouseClickHandler(event: MouseEvent): void;
@@ -1,8 +0,0 @@
1
- /*--------------------------------------------------------------------------
2
- //
3
- // Properties
4
- //
5
- //-------------------------------------------------------------------------*/
6
-
7
- $border-width: 1px !default;
8
- $border-radius: 4px !default;
@@ -1,50 +0,0 @@
1
- @import '@angular/material/theming';
2
- @import 'bootstrap/variables';
3
- @import 'bootstrap/background';
4
- @import 'bootstrap/border';
5
- @import 'bootstrap/text';
6
-
7
- /*--------------------------------------------------------------------------
8
- //
9
- // Methods
10
- //
11
- //-------------------------------------------------------------------------*/
12
-
13
- @mixin vi-mat-core-bootstrap($typography) {
14
- body {
15
- @include mat-typography-level-to-styles($typography, body-1);
16
- }
17
- }
18
-
19
- @mixin vi-mat-theme-bootstrap($theme, $text-primary-default, $text-accent-default) {
20
- $warn: map-get($theme, warn);
21
- $accent: map-get($theme, accent);
22
- $primary: map-get($theme, primary);
23
- $is-dark: map-get($theme, is-dark);
24
- $background: map-get($theme, background);
25
- $foreground: map-get($theme, foreground);
26
-
27
- $text-color: map-get($foreground, text);
28
- $text-accent-color: mat-color($accent, $text-accent-default);
29
- $text-primary-color: mat-color($primary, $text-primary-default);
30
-
31
- $divider-color: map-get($foreground, divider);
32
-
33
- @if $is-dark {
34
- $text-accent-color: mat-color($accent);
35
- $text-primary-color: mat-color($primary);
36
- }
37
-
38
- color: $text-color;
39
- background-color: map-get($background, body) !important;
40
-
41
- .form-control {
42
- background: transparent;
43
- color: $text-color;
44
- border-color: $divider-color;
45
- }
46
-
47
- @include vi-mat-theme-bootstrap-text($theme, $text-primary-default, $text-accent-default);
48
- @include vi-mat-theme-bootstrap-border($theme, $text-primary-default, $text-accent-default);
49
- @include vi-mat-theme-bootstrap-background($theme, $text-primary-default, $text-accent-default);
50
- }