ngx-mat-tui-calendar 0.0.12 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (25) hide show
  1. package/bundles/ngx-mat-tui-calendar.umd.js +1169 -12
  2. package/bundles/ngx-mat-tui-calendar.umd.js.map +1 -1
  3. package/esm2015/lib/calendar-editor-options.js +2 -0
  4. package/esm2015/lib/calendar-options.js +2 -0
  5. package/esm2015/lib/local-date.js +102 -0
  6. package/esm2015/lib/ngx-mat-tui-calendar-editor-dialog/ngx-mat-tui-calendar-editor-dialog.component.js +147 -0
  7. package/esm2015/lib/ngx-mat-tui-calendar-wrapper/ngx-mat-tui-calendar-wrapper.component.js +19 -0
  8. package/esm2015/lib/ngx-mat-tui-calendar.component.js +495 -7
  9. package/esm2015/lib/ngx-mat-tui-calendar.module.js +109 -4
  10. package/esm2015/public-api.js +4 -1
  11. package/fesm2015/ngx-mat-tui-calendar.js +851 -10
  12. package/fesm2015/ngx-mat-tui-calendar.js.map +1 -1
  13. package/lib/calendar-editor-options.d.ts +6 -0
  14. package/lib/calendar-options.d.ts +6 -0
  15. package/lib/local-date.d.ts +43 -0
  16. package/lib/ngx-mat-tui-calendar-editor-dialog/ngx-mat-tui-calendar-editor-dialog.component.d.ts +35 -0
  17. package/lib/ngx-mat-tui-calendar-wrapper/ngx-mat-tui-calendar-wrapper.component.d.ts +8 -0
  18. package/lib/ngx-mat-tui-calendar.component.d.ts +71 -4
  19. package/lib/ngx-mat-tui-calendar.module.d.ts +24 -1
  20. package/ngx-mat-tui-calendar.theme.scss +9 -0
  21. package/package.json +34 -9
  22. package/public-api.d.ts +3 -0
  23. package/src/lib/ngx-mat-tui-calendar-editor-dialog/ngx-mat-tui-calendar-editor-dialog.component.theme.scss +75 -0
  24. package/src/lib/ngx-mat-tui-calendar-wrapper/ngx-mat-tui-calendar-wrapper.component.theme.scss +38 -0
  25. package/src/lib/ngx-mat-tui-calendar.component.theme.scss +112 -0
@@ -0,0 +1,112 @@
1
+ @use 'sass:map';
2
+ @use '~@angular/material' as mat;
3
+ @use 'ngx-mat-tui-calendar-editor-dialog/ngx-mat-tui-calendar-editor-dialog.component.theme.scss' as tui-calendar-popup;
4
+ @use 'ngx-mat-tui-calendar-wrapper/ngx-mat-tui-calendar-wrapper.component.theme.scss' as tui-calendar-wrapper;
5
+
6
+
7
+
8
+ @function rgba-to-rgb($rgba, $background: #fff) {
9
+ @return mix(rgb(red($rgba), green($rgba), blue($rgba)), $background, alpha($rgba) * 100%);
10
+ }
11
+
12
+ @mixin color($theme) {
13
+ // Get the color config from the theme.
14
+ $color-config: mat.get-color-config($theme);
15
+
16
+ // Get the primary color palette from the color-config.
17
+ $primary-palette: map.get($color-config, 'primary');
18
+ $accent-palette: map.get($color-config, 'accent');
19
+ $warn-palette: map.get($color-config, 'warn');
20
+ $darkMode: map.get($color-config, 'is-dark');
21
+ $foreground-palette: map.get($color-config, foreground);
22
+ $background-palette: map.get($color-config, background);
23
+ $background-color: mat.get-color-from-palette($background-palette, dialog);
24
+ $divider-color: rgba-to-rgb(mat.get-color-from-palette($foreground-palette, divider), $background-color);
25
+
26
+ #theme-primary {
27
+ color: mat.get-color-from-palette($primary-palette);
28
+ }
29
+ #theme-highlight {
30
+ @if($darkMode) {
31
+ color: mat.get-color-from-palette($accent-palette);
32
+ } @else {
33
+ color: mat.get-color-from-palette($primary-palette);
34
+ }
35
+ }
36
+ #theme-primary-shaded {
37
+ @if($darkMode) {
38
+ color: rgba(mat.get-color-from-palette($primary-palette), 0.5);
39
+ } @else {
40
+ color: rgba(mat.get-color-from-palette($primary-palette), 0.05);
41
+ }
42
+ }
43
+ #theme-accent {
44
+ color: mat.get-color-from-palette($accent-palette);
45
+ }
46
+ #theme-warn {
47
+ color: mat.get-color-from-palette($warn-palette);
48
+ }
49
+ #theme-foreground {
50
+ color: mat.get-color-from-palette($foreground-palette, text);
51
+ }
52
+ #theme-divider {
53
+ color: $divider-color;
54
+ }
55
+ #theme-background {
56
+ color: $background-color;
57
+ }
58
+
59
+ .mat-button.navigation-button:hover {
60
+ background-color: mat.get-color-from-palette($primary-palette, 900);
61
+ }
62
+
63
+ .mat-button.navigation-button:active {
64
+ color: mat.get-color-from-palette($accent-palette);
65
+ }
66
+
67
+ .mat-button-toggle.view-button {
68
+ color: mat.get-color-from-palette($primary-palette, '700-contrast');
69
+ background-color: mat.get-color-from-palette($primary-palette, 700);
70
+ }
71
+
72
+ .mat-button-toggle.view-button:hover {
73
+ background-color: mat.get-color-from-palette($primary-palette, 900);
74
+ }
75
+
76
+ .mat-button-toggle-checked.view-button {
77
+ color: mat.get-color-from-palette($accent-palette, '700-contrast');
78
+ background-color: mat.get-color-from-palette($accent-palette, 700);
79
+ }
80
+
81
+ .mat-button-toggle-checked.view-button:hover {
82
+ color: mat.get-color-from-palette($accent-palette, '700-contrast');
83
+ background-color: mat.get-color-from-palette($accent-palette, 900);
84
+ }
85
+
86
+
87
+ }
88
+
89
+ @mixin typography($theme) {
90
+ // Get the typography config from the theme.
91
+ $typography-config: mat.get-typography-config($theme);
92
+
93
+ .event-calendar-title {
94
+ font-family: mat.font-family($typography-config);
95
+ }
96
+ }
97
+
98
+ @mixin theme($theme) {
99
+ $color-config: mat.get-color-config($theme);
100
+ @if $color-config != null {
101
+ @include color($theme);
102
+ }
103
+
104
+ $typography-config: mat.get-typography-config($theme);
105
+ @if $typography-config != null {
106
+ @include typography($theme);
107
+ }
108
+
109
+ @include tui-calendar-popup.theme($theme);
110
+ @include tui-calendar-wrapper.theme($theme);
111
+
112
+ }