aril 0.0.24 → 0.0.26

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 (172) hide show
  1. package/boot/host/src/bootstrap.d.ts +2 -1
  2. package/boot/mfe/src/bootstrap.d.ts +2 -1
  3. package/esm2022/boot/host/index.mjs +1 -1
  4. package/esm2022/boot/host/src/app.component.mjs +1 -1
  5. package/esm2022/boot/host/src/bootstrap.mjs +14 -6
  6. package/esm2022/boot/host/src/services/custom-manifest.mjs +1 -1
  7. package/esm2022/boot/host/src/services/microFrontEnd.service.mjs +1 -1
  8. package/esm2022/boot/host/src/services/plugin-init.token.mjs +1 -1
  9. package/esm2022/boot/host/src/services/showdowDOMWrapper.mjs +1 -1
  10. package/esm2022/boot/index.mjs +1 -1
  11. package/esm2022/boot/mfe/index.mjs +1 -1
  12. package/esm2022/boot/mfe/src/app.component.mjs +13 -13
  13. package/esm2022/boot/mfe/src/bootstrap.mjs +13 -5
  14. package/esm2022/http/lib/enums.mjs +2 -1
  15. package/esm2022/http/lib/interfaces.mjs +1 -2
  16. package/esm2022/http/src/httpClient.mjs +1 -1
  17. package/esm2022/http/src/serviceBase.mjs +8 -5
  18. package/esm2022/http/src/serviceStateMethods.mjs +1 -2
  19. package/esm2022/i18n/src/file-url-token.mjs +1 -1
  20. package/esm2022/i18n/src/i18n.module.mjs +1 -1
  21. package/esm2022/i18n/src/loader.mjs +2 -2
  22. package/esm2022/i18n/src/provideI18n.mjs +1 -1
  23. package/esm2022/i18n/src/provideScope.mjs +1 -1
  24. package/esm2022/keycloak/aril-keycloak.mjs +5 -0
  25. package/esm2022/keycloak/index.mjs +3 -0
  26. package/esm2022/keycloak/src/auth.interceptor.mjs +13 -0
  27. package/esm2022/keycloak/src/keycloak.manager.mjs +59 -0
  28. package/esm2022/public-api.mjs +1 -1
  29. package/esm2022/theme/index.mjs +1 -1
  30. package/esm2022/theme/layout/app/config/app.config.component.mjs +4 -4
  31. package/esm2022/theme/layout/app/layout/app.layout.component.mjs +5 -5
  32. package/esm2022/theme/layout/app/layout/mfe.layout.component.mjs +21 -21
  33. package/esm2022/theme/layout/app/menu/app.menu.component.mjs +4 -4
  34. package/esm2022/theme/layout/app/profileSidebar/app.profilesidebar.component.mjs +2 -2
  35. package/esm2022/theme/layout/app/sidebar/app.sidebar.component.mjs +2 -2
  36. package/esm2022/theme/layout/app/topbar/app.topbar.component.mjs +12 -9
  37. package/esm2022/theme/layout/service/app.layout.service.mjs +1 -1
  38. package/esm2022/theme/layout/service/app.menu.service.mjs +1 -1
  39. package/esm2022/ui/button/src/button.component.mjs +2 -2
  40. package/esm2022/ui/calendar/src/calendar.component.mjs +4 -4
  41. package/esm2022/ui/field/src/field.component.mjs +5 -5
  42. package/esm2022/ui/fileUpload/src/file-upload.component.mjs +3 -3
  43. package/esm2022/ui/form/index.mjs +2 -2
  44. package/esm2022/ui/form/src/form-submit-button.component.mjs +2 -2
  45. package/esm2022/ui/form/src/form.component.mjs +1 -1
  46. package/esm2022/ui/index.mjs +1 -1
  47. package/esm2022/ui/lib/src/form/form-error-message.directive.mjs +1 -1
  48. package/esm2022/ui/lib/src/form/form-field-builder.mjs +1 -1
  49. package/esm2022/ui/lib/src/grid/flex-grid.directive.mjs +1 -1
  50. package/esm2022/ui/lib/src/input/dx-input-error-message.pipe.mjs +1 -1
  51. package/esm2022/ui/lib/src/input/input-error-message.pipe.mjs +1 -1
  52. package/esm2022/ui/lib/src/input/value-accessor.directive.mjs +1 -1
  53. package/esm2022/ui/mask/src/mask.component.mjs +2 -2
  54. package/esm2022/ui/number/src/number.component.mjs +2 -2
  55. package/esm2022/ui/overlayPanel/src/overlay-panel.component.mjs +2 -2
  56. package/esm2022/ui/password/src/password.component.mjs +2 -2
  57. package/esm2022/ui/radioButton/src/radio-button.component.mjs +1 -1
  58. package/esm2022/ui/selectBox/src/select-box.component.mjs +4 -4
  59. package/esm2022/ui/switch/src/switch.component.mjs +2 -2
  60. package/esm2022/ui/table/index.mjs +3 -3
  61. package/esm2022/ui/table/src/table-column.component.mjs +1 -1
  62. package/esm2022/ui/table/src/table.component.mjs +2 -2
  63. package/esm2022/ui/tagBox/src/tag-box.component.mjs +1 -1
  64. package/esm2022/ui/text/src/text.component.mjs +2 -2
  65. package/esm2022/ui/textArea/src/text-area.component.mjs +3 -3
  66. package/esm2022/ui/tree/src/tree.component.mjs +5 -5
  67. package/esm2022/ui/treeTable/src/tree-table.component.mjs +4 -4
  68. package/esm2022/util/custom_pages/index.mjs +1 -1
  69. package/esm2022/util/custom_pages/src/notFound.component.mjs +109 -109
  70. package/esm2022/util/index.mjs +1 -1
  71. package/esm2022/util/lib/src/module-router.mjs +1 -1
  72. package/esm2022/util/lib/src/types.mjs +1 -4
  73. package/esm2022/util/loaders/index.mjs +1 -1
  74. package/esm2022/util/loaders/script/script.loader.service.mjs +1 -1
  75. package/esm2022/util/loaders/style/style.loader.service.mjs +1 -1
  76. package/esm2022/util/primitive-extensions/src/date.extensions.mjs +1 -1
  77. package/esm2022/util/pub-sub/src/pub-sub.service.mjs +1 -1
  78. package/fesm2022/{aril-app.component-tFlRp3qI.mjs → aril-app.component-sZDpvJDM.mjs} +16 -14
  79. package/fesm2022/aril-app.component-sZDpvJDM.mjs.map +1 -0
  80. package/fesm2022/{aril-aril--3c18nTH.mjs → aril-aril-D__IXMsf.mjs} +24 -10
  81. package/fesm2022/aril-aril-D__IXMsf.mjs.map +1 -0
  82. package/fesm2022/aril-boot-host.mjs +13 -5
  83. package/fesm2022/aril-boot-host.mjs.map +1 -1
  84. package/fesm2022/{aril-boot-mfe-app.component-wYzFs1Za.mjs → aril-boot-mfe-app.component-zro0FnKY.mjs} +15 -13
  85. package/fesm2022/aril-boot-mfe-app.component-zro0FnKY.mjs.map +1 -0
  86. package/fesm2022/aril-boot-mfe.mjs +13 -5
  87. package/fesm2022/aril-boot-mfe.mjs.map +1 -1
  88. package/fesm2022/aril-boot.mjs.map +1 -1
  89. package/fesm2022/aril-http.mjs +6 -4
  90. package/fesm2022/aril-http.mjs.map +1 -1
  91. package/fesm2022/aril-i18n.mjs +1 -1
  92. package/fesm2022/aril-i18n.mjs.map +1 -1
  93. package/fesm2022/aril-keycloak.mjs +77 -0
  94. package/fesm2022/aril-keycloak.mjs.map +1 -0
  95. package/fesm2022/aril-theme-layout.mjs +266 -264
  96. package/fesm2022/aril-theme-layout.mjs.map +1 -1
  97. package/fesm2022/aril-theme.mjs.map +1 -1
  98. package/fesm2022/aril-ui-button.mjs.map +1 -1
  99. package/fesm2022/aril-ui-calendar.mjs +3 -3
  100. package/fesm2022/aril-ui-calendar.mjs.map +1 -1
  101. package/fesm2022/aril-ui-field.mjs +3 -3
  102. package/fesm2022/aril-ui-field.mjs.map +1 -1
  103. package/fesm2022/aril-ui-fileUpload.mjs +2 -2
  104. package/fesm2022/aril-ui-fileUpload.mjs.map +1 -1
  105. package/fesm2022/aril-ui-form.mjs +28 -28
  106. package/fesm2022/aril-ui-form.mjs.map +1 -1
  107. package/fesm2022/aril-ui-lib.mjs.map +1 -1
  108. package/fesm2022/aril-ui-mask.mjs +1 -1
  109. package/fesm2022/aril-ui-mask.mjs.map +1 -1
  110. package/fesm2022/aril-ui-number.mjs +2 -2
  111. package/fesm2022/aril-ui-number.mjs.map +1 -1
  112. package/fesm2022/aril-ui-overlayPanel.mjs.map +1 -1
  113. package/fesm2022/aril-ui-password.mjs +2 -2
  114. package/fesm2022/aril-ui-password.mjs.map +1 -1
  115. package/fesm2022/aril-ui-radioButton.mjs.map +1 -1
  116. package/fesm2022/aril-ui-selectBox.mjs +2 -2
  117. package/fesm2022/aril-ui-selectBox.mjs.map +1 -1
  118. package/fesm2022/aril-ui-switch.mjs +2 -2
  119. package/fesm2022/aril-ui-switch.mjs.map +1 -1
  120. package/fesm2022/aril-ui-table.mjs +23 -23
  121. package/fesm2022/aril-ui-table.mjs.map +1 -1
  122. package/fesm2022/aril-ui-tagBox.mjs.map +1 -1
  123. package/fesm2022/aril-ui-text.mjs +1 -1
  124. package/fesm2022/aril-ui-text.mjs.map +1 -1
  125. package/fesm2022/aril-ui-textArea.mjs +2 -2
  126. package/fesm2022/aril-ui-textArea.mjs.map +1 -1
  127. package/fesm2022/aril-ui-tree.mjs +4 -4
  128. package/fesm2022/aril-ui-tree.mjs.map +1 -1
  129. package/fesm2022/aril-ui-treeTable.mjs +2 -2
  130. package/fesm2022/aril-ui-treeTable.mjs.map +1 -1
  131. package/fesm2022/aril-ui.mjs.map +1 -1
  132. package/fesm2022/aril-util-custom_pages.mjs +108 -108
  133. package/fesm2022/aril-util-custom_pages.mjs.map +1 -1
  134. package/fesm2022/aril-util-lib.mjs +0 -3
  135. package/fesm2022/aril-util-lib.mjs.map +1 -1
  136. package/fesm2022/aril-util-loaders.mjs.map +1 -1
  137. package/fesm2022/aril-util-primitive-extensions.mjs.map +1 -1
  138. package/fesm2022/aril-util-pub-sub.mjs.map +1 -1
  139. package/fesm2022/aril-util.mjs.map +1 -1
  140. package/fesm2022/aril.mjs +3 -1
  141. package/fesm2022/aril.mjs.map +1 -1
  142. package/http/lib/enums.d.ts +1 -0
  143. package/keycloak/index.d.ts +2 -0
  144. package/keycloak/src/auth.interceptor.d.ts +2 -0
  145. package/keycloak/src/keycloak.manager.d.ts +24 -0
  146. package/package.json +10 -2
  147. package/styles/ui/ui.common.scss +24 -24
  148. package/theme/index.ts +1 -1
  149. package/theme/layout/app/config/app.config.component.d.ts +1 -1
  150. package/theme/layout/app/config/app.config.component.ts +4 -4
  151. package/theme/layout/app/layout/app.layout.component.d.ts +1 -1
  152. package/theme/layout/app/layout/app.layout.component.ts +6 -6
  153. package/theme/layout/app/layout/mfe.layout.component.ts +49 -49
  154. package/theme/layout/app/menu/app.menu.component.d.ts +2 -2
  155. package/theme/layout/app/menu/app.menu.component.ts +2 -2
  156. package/theme/layout/app/menu/app.sub.menu.component.html +13 -13
  157. package/theme/layout/app/profileSidebar/app.profilesidebar.component.ts +1 -1
  158. package/theme/layout/app/sidebar/app.sidebar.component.ts +1 -1
  159. package/theme/layout/app/topbar/app.topbar.component.d.ts +3 -2
  160. package/theme/layout/app/topbar/app.topbar.component.html +45 -37
  161. package/theme/layout/app/topbar/app.topbar.component.ts +32 -28
  162. package/theme/layout/service/app.layout.service.ts +178 -178
  163. package/theme/layout/service/app.menu.service.ts +59 -57
  164. package/theme/ng-package.json +6 -6
  165. package/theme/styles/theme/base/components/data/_paginator.scss +92 -92
  166. package/theme/styles/theme/dark/_variables.scss +918 -918
  167. package/theme/styles/theme/light/_variables.scss +911 -911
  168. package/ui/selectBox/src/select-box.component.d.ts +1 -1
  169. package/ui/table/src/table.component.d.ts +1 -1
  170. package/fesm2022/aril-app.component-tFlRp3qI.mjs.map +0 -1
  171. package/fesm2022/aril-aril--3c18nTH.mjs.map +0 -1
  172. package/fesm2022/aril-boot-mfe-app.component-wYzFs1Za.mjs.map +0 -1
@@ -1,178 +1,178 @@
1
- import { Injectable, effect, signal } from '@angular/core';
2
-
3
- import { Subject } from 'rxjs';
4
-
5
- export type MenuMode = 'static' | 'overlay' | 'horizontal' | 'slim' | 'slim-plus' | 'reveal' | 'drawer';
6
-
7
- export type ColorScheme = 'light' | 'dark' | 'dim';
8
-
9
- export type MenuColorScheme = 'colorScheme' | 'primaryColor' | 'transparent';
10
-
11
- export interface AppConfig {
12
- inputStyle: string;
13
- colorScheme: ColorScheme;
14
- theme: string;
15
- ripple: boolean;
16
- menuMode: MenuMode;
17
- scale: number;
18
- menuTheme: MenuColorScheme;
19
- }
20
-
21
- interface LayoutState {
22
- staticMenuDesktopInactive: boolean;
23
- overlayMenuActive: boolean;
24
- profileSidebarVisible: boolean;
25
- configSidebarVisible: boolean;
26
- staticMenuMobileActive: boolean;
27
- menuHoverActive: boolean;
28
- sidebarActive: boolean;
29
- anchored: boolean;
30
- }
31
-
32
- @Injectable({
33
- providedIn: 'root'
34
- })
35
- export class LayoutService {
36
- _config: AppConfig = {
37
- ripple: false,
38
- inputStyle: 'outlined',
39
- menuMode: 'horizontal',
40
- colorScheme: 'light',
41
- theme: 'indigo',
42
- scale: 12,
43
- menuTheme: 'colorScheme'
44
- };
45
-
46
- // TODO: Set User Config
47
- config = signal<AppConfig>(this._config);
48
-
49
- state: LayoutState = {
50
- staticMenuDesktopInactive: false,
51
- overlayMenuActive: false,
52
- profileSidebarVisible: false,
53
- configSidebarVisible: false,
54
- staticMenuMobileActive: false,
55
- menuHoverActive: false,
56
- sidebarActive: false,
57
- anchored: false
58
- };
59
-
60
- private configUpdate = new Subject<AppConfig>();
61
-
62
- private overlayOpen = new Subject<any>();
63
-
64
- configUpdate$ = this.configUpdate.asObservable();
65
-
66
- overlayOpen$ = this.overlayOpen.asObservable();
67
-
68
- constructor() {
69
- effect(() => {
70
- const config = this.config();
71
- if (this.updateStyle(config)) {
72
- this.changeTheme();
73
- }
74
- this.changeScale(config.scale);
75
- this.onConfigUpdate();
76
- });
77
- }
78
-
79
- updateStyle(config: AppConfig) {
80
- return config.theme !== this._config.theme || config.colorScheme !== this._config.colorScheme;
81
- }
82
-
83
- onMenuToggle() {
84
- if (this.isOverlay()) {
85
- this.state.overlayMenuActive = !this.state.overlayMenuActive;
86
-
87
- if (this.state.overlayMenuActive) {
88
- this.overlayOpen.next(null);
89
- }
90
- }
91
-
92
- if (this.isDesktop()) {
93
- this.state.staticMenuDesktopInactive = !this.state.staticMenuDesktopInactive;
94
- } else {
95
- this.state.staticMenuMobileActive = !this.state.staticMenuMobileActive;
96
-
97
- if (this.state.staticMenuMobileActive) {
98
- this.overlayOpen.next(null);
99
- }
100
- }
101
- }
102
-
103
- onOverlaySubmenuOpen() {
104
- this.overlayOpen.next(null);
105
- }
106
-
107
- showProfileSidebar() {
108
- this.state.profileSidebarVisible = true;
109
- }
110
-
111
- showConfigSidebar() {
112
- this.state.configSidebarVisible = true;
113
- }
114
-
115
- isOverlay() {
116
- return this.config().menuMode === 'overlay';
117
- }
118
-
119
- isDesktop() {
120
- return window.innerWidth > 991;
121
- }
122
-
123
- isSlim() {
124
- return this.config().menuMode === 'slim';
125
- }
126
-
127
- isSlimPlus() {
128
- return this.config().menuMode === 'slim-plus';
129
- }
130
-
131
- isHorizontal() {
132
- return this.config().menuMode === 'horizontal';
133
- }
134
-
135
- isMobile() {
136
- return !this.isDesktop();
137
- }
138
-
139
- onConfigUpdate() {
140
- this._config = { ...this.config() };
141
- this.configUpdate.next(this.config());
142
- }
143
-
144
- changeTheme() {
145
- const config = this.config();
146
- const themeLink = <HTMLLinkElement>document.getElementById('theme-link');
147
- const themeLinkHref = themeLink.getAttribute('href')!;
148
- const newHref = themeLinkHref
149
- .split('/')
150
- .map((el) =>
151
- el == this._config.theme ? (el = config.theme)
152
- : el == `theme-${this._config.colorScheme}` ? (el = `theme-${config.colorScheme}`)
153
- : el
154
- )
155
- .join('/');
156
-
157
- this.replaceThemeLink(newHref);
158
- }
159
-
160
- replaceThemeLink(href: string) {
161
- const id = 'theme-link';
162
- let themeLink = <HTMLLinkElement>document.getElementById(id);
163
- const cloneLinkElement = <HTMLLinkElement>themeLink.cloneNode(true);
164
-
165
- cloneLinkElement.setAttribute('href', href);
166
- cloneLinkElement.setAttribute('id', id + '-clone');
167
-
168
- themeLink.parentNode!.insertBefore(cloneLinkElement, themeLink.nextSibling);
169
- cloneLinkElement.addEventListener('load', () => {
170
- themeLink.remove();
171
- cloneLinkElement.setAttribute('id', id);
172
- });
173
- }
174
-
175
- changeScale(value: number) {
176
- document.documentElement.style.fontSize = `${value}px`;
177
- }
178
- }
1
+ import { Injectable, effect, signal } from '@angular/core';
2
+
3
+ import { Subject } from 'rxjs';
4
+
5
+ export type MenuMode = 'static' | 'overlay' | 'horizontal' | 'slim' | 'slim-plus' | 'reveal' | 'drawer';
6
+
7
+ export type ColorScheme = 'light' | 'dark' | 'dim';
8
+
9
+ export type MenuColorScheme = 'colorScheme' | 'primaryColor' | 'transparent';
10
+
11
+ export interface AppConfig {
12
+ inputStyle: string;
13
+ colorScheme: ColorScheme;
14
+ theme: string;
15
+ ripple: boolean;
16
+ menuMode: MenuMode;
17
+ scale: number;
18
+ menuTheme: MenuColorScheme;
19
+ }
20
+
21
+ interface LayoutState {
22
+ staticMenuDesktopInactive: boolean;
23
+ overlayMenuActive: boolean;
24
+ profileSidebarVisible: boolean;
25
+ configSidebarVisible: boolean;
26
+ staticMenuMobileActive: boolean;
27
+ menuHoverActive: boolean;
28
+ sidebarActive: boolean;
29
+ anchored: boolean;
30
+ }
31
+
32
+ @Injectable({
33
+ providedIn: 'root'
34
+ })
35
+ export class LayoutService {
36
+ _config: AppConfig = {
37
+ ripple: false,
38
+ inputStyle: 'outlined',
39
+ menuMode: 'horizontal',
40
+ colorScheme: 'light',
41
+ theme: 'indigo',
42
+ scale: 12,
43
+ menuTheme: 'colorScheme'
44
+ };
45
+
46
+ // TODO: Set User Config
47
+ config = signal<AppConfig>(this._config);
48
+
49
+ state: LayoutState = {
50
+ staticMenuDesktopInactive: false,
51
+ overlayMenuActive: false,
52
+ profileSidebarVisible: false,
53
+ configSidebarVisible: false,
54
+ staticMenuMobileActive: false,
55
+ menuHoverActive: false,
56
+ sidebarActive: false,
57
+ anchored: false
58
+ };
59
+
60
+ private configUpdate = new Subject<AppConfig>();
61
+
62
+ private overlayOpen = new Subject<any>();
63
+
64
+ configUpdate$ = this.configUpdate.asObservable();
65
+
66
+ overlayOpen$ = this.overlayOpen.asObservable();
67
+
68
+ constructor() {
69
+ effect(() => {
70
+ const config = this.config();
71
+ if (this.updateStyle(config)) {
72
+ this.changeTheme();
73
+ }
74
+ this.changeScale(config.scale);
75
+ this.onConfigUpdate();
76
+ });
77
+ }
78
+
79
+ updateStyle(config: AppConfig) {
80
+ return config.theme !== this._config.theme || config.colorScheme !== this._config.colorScheme;
81
+ }
82
+
83
+ onMenuToggle() {
84
+ if (this.isOverlay()) {
85
+ this.state.overlayMenuActive = !this.state.overlayMenuActive;
86
+
87
+ if (this.state.overlayMenuActive) {
88
+ this.overlayOpen.next(null);
89
+ }
90
+ }
91
+
92
+ if (this.isDesktop()) {
93
+ this.state.staticMenuDesktopInactive = !this.state.staticMenuDesktopInactive;
94
+ } else {
95
+ this.state.staticMenuMobileActive = !this.state.staticMenuMobileActive;
96
+
97
+ if (this.state.staticMenuMobileActive) {
98
+ this.overlayOpen.next(null);
99
+ }
100
+ }
101
+ }
102
+
103
+ onOverlaySubmenuOpen() {
104
+ this.overlayOpen.next(null);
105
+ }
106
+
107
+ showProfileSidebar() {
108
+ this.state.profileSidebarVisible = true;
109
+ }
110
+
111
+ showConfigSidebar() {
112
+ this.state.configSidebarVisible = true;
113
+ }
114
+
115
+ isOverlay() {
116
+ return this.config().menuMode === 'overlay';
117
+ }
118
+
119
+ isDesktop() {
120
+ return window.innerWidth > 991;
121
+ }
122
+
123
+ isSlim() {
124
+ return this.config().menuMode === 'slim';
125
+ }
126
+
127
+ isSlimPlus() {
128
+ return this.config().menuMode === 'slim-plus';
129
+ }
130
+
131
+ isHorizontal() {
132
+ return this.config().menuMode === 'horizontal';
133
+ }
134
+
135
+ isMobile() {
136
+ return !this.isDesktop();
137
+ }
138
+
139
+ onConfigUpdate() {
140
+ this._config = { ...this.config() };
141
+ this.configUpdate.next(this.config());
142
+ }
143
+
144
+ changeTheme() {
145
+ const config = this.config();
146
+ const themeLink = <HTMLLinkElement>document.getElementById('theme-link');
147
+ const themeLinkHref = themeLink.getAttribute('href')!;
148
+ const newHref = themeLinkHref
149
+ .split('/')
150
+ .map((el) =>
151
+ el == this._config.theme ? (el = config.theme)
152
+ : el == `theme-${this._config.colorScheme}` ? (el = `theme-${config.colorScheme}`)
153
+ : el
154
+ )
155
+ .join('/');
156
+
157
+ this.replaceThemeLink(newHref);
158
+ }
159
+
160
+ replaceThemeLink(href: string) {
161
+ const id = 'theme-link';
162
+ let themeLink = <HTMLLinkElement>document.getElementById(id);
163
+ const cloneLinkElement = <HTMLLinkElement>themeLink.cloneNode(true);
164
+
165
+ cloneLinkElement.setAttribute('href', href);
166
+ cloneLinkElement.setAttribute('id', id + '-clone');
167
+
168
+ themeLink.parentNode!.insertBefore(cloneLinkElement, themeLink.nextSibling);
169
+ cloneLinkElement.addEventListener('load', () => {
170
+ themeLink.remove();
171
+ cloneLinkElement.setAttribute('id', id);
172
+ });
173
+ }
174
+
175
+ changeScale(value: number) {
176
+ document.documentElement.style.fontSize = `${value}px`;
177
+ }
178
+ }
@@ -1,57 +1,59 @@
1
- import { Injectable, computed, signal } from '@angular/core';
2
-
3
- import { Subject } from 'rxjs';
4
- import { MenuItem } from 'primeng/api';
5
-
6
- import { APIs } from 'aril/http';
7
- import { MenuChangeEvent } from './menuchangeevent';
8
-
9
- interface MenuConfig {
10
- items: MenuItem[];
11
- prefix?: APIs;
12
- }
13
-
14
- @Injectable({
15
- providedIn: 'root'
16
- })
17
- export class AppMenuService {
18
- private menuSource = new Subject<MenuChangeEvent>();
19
- private resetSource = new Subject();
20
-
21
- public menuConfig = signal<MenuConfig>({ items: [], prefix: undefined });
22
- public subMenuConfig = signal<MenuConfig>({ items: [], prefix: undefined });
23
-
24
- public menuItems = computed(() => {
25
- const config = this.menuConfig();
26
-
27
- if (config.prefix) return config.items.map((item) => this.addPrefix(item, config.prefix));
28
- else return config.items;
29
- });
30
-
31
- public subMenuItems = computed(() => {
32
- const config = this.subMenuConfig();
33
-
34
- if (config.prefix) return config.items.map((item) => this.addPrefix(item, config.prefix));
35
- else return config.items;
36
- });
37
-
38
- menuSource$ = this.menuSource.asObservable();
39
- resetSource$ = this.resetSource.asObservable();
40
-
41
- addPrefix(menuItem: MenuItem, appPrefix: APIs | undefined) {
42
- if (menuItem.items) {
43
- menuItem.items = menuItem.items.map((item) => this.addPrefix(item, appPrefix));
44
- } else {
45
- menuItem.routerLink = `/${appPrefix}/${menuItem.routerLink}`;
46
- }
47
- return menuItem;
48
- }
49
-
50
- onMenuStateChange(event: MenuChangeEvent) {
51
- this.menuSource.next(event);
52
- }
53
-
54
- reset() {
55
- this.resetSource.next(true);
56
- }
57
- }
1
+ import { Injectable, computed, signal } from '@angular/core';
2
+
3
+ import { MenuItem } from 'primeng/api';
4
+
5
+ import { Subject } from 'rxjs';
6
+
7
+ import { APIs } from 'aril/http';
8
+
9
+ import { MenuChangeEvent } from './menuchangeevent';
10
+
11
+ interface MenuConfig {
12
+ items: MenuItem[];
13
+ prefix?: APIs;
14
+ }
15
+
16
+ @Injectable({
17
+ providedIn: 'root'
18
+ })
19
+ export class AppMenuService {
20
+ private menuSource = new Subject<MenuChangeEvent>();
21
+ private resetSource = new Subject();
22
+
23
+ public menuConfig = signal<MenuConfig>({ items: [], prefix: undefined });
24
+ public subMenuConfig = signal<MenuConfig>({ items: [], prefix: undefined });
25
+
26
+ public menuItems = computed(() => {
27
+ const config = this.menuConfig();
28
+
29
+ if (config.prefix) return config.items.map((item) => this.addPrefix(item, config.prefix));
30
+ else return config.items;
31
+ });
32
+
33
+ public subMenuItems = computed(() => {
34
+ const config = this.subMenuConfig();
35
+
36
+ if (config.prefix) return config.items.map((item) => this.addPrefix(item, config.prefix));
37
+ else return config.items;
38
+ });
39
+
40
+ menuSource$ = this.menuSource.asObservable();
41
+ resetSource$ = this.resetSource.asObservable();
42
+
43
+ addPrefix(menuItem: MenuItem, appPrefix: APIs | undefined) {
44
+ if (menuItem.items) {
45
+ menuItem.items = menuItem.items.map((item) => this.addPrefix(item, appPrefix));
46
+ } else {
47
+ menuItem.routerLink = `/${appPrefix}/${menuItem.routerLink}`;
48
+ }
49
+ return menuItem;
50
+ }
51
+
52
+ onMenuStateChange(event: MenuChangeEvent) {
53
+ this.menuSource.next(event);
54
+ }
55
+
56
+ reset() {
57
+ this.resetSource.next(true);
58
+ }
59
+ }
@@ -1,6 +1,6 @@
1
- {
2
- "$schema": "../../../node_modules/ng-packagr/ng-package.schema.json",
3
- "lib": {
4
- "entryFile": "./index.ts"
5
- }
6
- }
1
+ {
2
+ "$schema": "../../../node_modules/ng-packagr/ng-package.schema.json",
3
+ "lib": {
4
+ "entryFile": "./index.ts"
5
+ }
6
+ }
@@ -1,92 +1,92 @@
1
- .p-paginator {
2
- background: $paginatorBg;
3
- color: $paginatorTextColor;
4
- border: $paginatorBorder;
5
- border-width: $paginatorBorderWidth;
6
- padding: $paginatorPadding;
7
- border-radius: $borderRadius;
8
-
9
- .p-paginator-first,
10
- .p-paginator-prev,
11
- .p-paginator-next,
12
- .p-paginator-last {
13
- background-color: $paginatorElementBg;
14
- border: $paginatorElementBorder;
15
- color: $paginatorElementIconColor;
16
- min-width: $paginatorElementWidth;
17
- height: $paginatorElementHeight;
18
- margin: $paginatorElementMargin;
19
- transition: $listItemTransition;
20
- border-radius: $paginatorElementBorderRadius;
21
-
22
- &:not(.p-disabled):not(.p-highlight):hover {
23
- background: $paginatorElementHoverBg;
24
- border-color: $paginatorElementHoverBorderColor;
25
- color: $paginatorElementIconHoverColor;
26
- }
27
- }
28
-
29
- .p-paginator-first {
30
- border-top-left-radius: $paginatorElementBorderRadius;
31
- border-bottom-left-radius: $paginatorElementBorderRadius;
32
- }
33
-
34
- .p-paginator-last {
35
- border-top-right-radius: $paginatorElementBorderRadius;
36
- border-bottom-right-radius: $paginatorElementBorderRadius;
37
- }
38
-
39
- .p-dropdown {
40
- margin-left: $inlineSpacing;
41
- margin-right: $inlineSpacing;
42
- height: $paginatorElementHeight;
43
-
44
- .p-dropdown-label {
45
- padding-right: 0;
46
- }
47
- }
48
-
49
- .p-paginator-page-input {
50
- margin-left: $inlineSpacing;
51
- margin-right: $inlineSpacing;
52
-
53
- .p-inputtext {
54
- max-width: $paginatorElementWidth;
55
- }
56
- }
57
-
58
- .p-paginator-current {
59
- background-color: $paginatorElementBg;
60
- border: $paginatorElementBorder;
61
- color: $paginatorElementIconColor;
62
- min-width: $paginatorElementWidth;
63
- height: $paginatorElementHeight;
64
- margin: $paginatorElementMargin;
65
- padding: 0 $inlineSpacing;
66
- }
67
-
68
- .p-paginator-pages {
69
- .p-paginator-page {
70
- background-color: $paginatorElementBg;
71
- border: $paginatorElementBorder;
72
- color: $paginatorElementIconColor;
73
- min-width: 2rem;
74
- height: 2rem;
75
- margin: $paginatorElementMargin;
76
- transition: $listItemTransition;
77
- border-radius: $paginatorElementBorderRadius;
78
-
79
- &.p-highlight {
80
- background: $highlightBg;
81
- border-color: $highlightBg;
82
- color: $highlightTextColor;
83
- }
84
-
85
- &:not(.p-highlight):hover {
86
- background: $paginatorElementHoverBg;
87
- border-color: $paginatorElementHoverBorderColor;
88
- color: $paginatorElementIconHoverColor;
89
- }
90
- }
91
- }
92
- }
1
+ .p-paginator {
2
+ background: $paginatorBg;
3
+ color: $paginatorTextColor;
4
+ border: $paginatorBorder;
5
+ border-width: $paginatorBorderWidth;
6
+ padding: $paginatorPadding;
7
+ border-radius: $borderRadius;
8
+
9
+ .p-paginator-first,
10
+ .p-paginator-prev,
11
+ .p-paginator-next,
12
+ .p-paginator-last {
13
+ background-color: $paginatorElementBg;
14
+ border: $paginatorElementBorder;
15
+ color: $paginatorElementIconColor;
16
+ min-width: $paginatorElementWidth;
17
+ height: $paginatorElementHeight;
18
+ margin: $paginatorElementMargin;
19
+ transition: $listItemTransition;
20
+ border-radius: $paginatorElementBorderRadius;
21
+
22
+ &:not(.p-disabled):not(.p-highlight):hover {
23
+ background: $paginatorElementHoverBg;
24
+ border-color: $paginatorElementHoverBorderColor;
25
+ color: $paginatorElementIconHoverColor;
26
+ }
27
+ }
28
+
29
+ .p-paginator-first {
30
+ border-top-left-radius: $paginatorElementBorderRadius;
31
+ border-bottom-left-radius: $paginatorElementBorderRadius;
32
+ }
33
+
34
+ .p-paginator-last {
35
+ border-top-right-radius: $paginatorElementBorderRadius;
36
+ border-bottom-right-radius: $paginatorElementBorderRadius;
37
+ }
38
+
39
+ .p-dropdown {
40
+ margin-left: $inlineSpacing;
41
+ margin-right: $inlineSpacing;
42
+ height: $paginatorElementHeight;
43
+
44
+ .p-dropdown-label {
45
+ padding-right: 0;
46
+ }
47
+ }
48
+
49
+ .p-paginator-page-input {
50
+ margin-left: $inlineSpacing;
51
+ margin-right: $inlineSpacing;
52
+
53
+ .p-inputtext {
54
+ max-width: $paginatorElementWidth;
55
+ }
56
+ }
57
+
58
+ .p-paginator-current {
59
+ background-color: $paginatorElementBg;
60
+ border: $paginatorElementBorder;
61
+ color: $paginatorElementIconColor;
62
+ min-width: $paginatorElementWidth;
63
+ height: $paginatorElementHeight;
64
+ margin: $paginatorElementMargin;
65
+ padding: 0 $inlineSpacing;
66
+ }
67
+
68
+ .p-paginator-pages {
69
+ .p-paginator-page {
70
+ background-color: $paginatorElementBg;
71
+ border: $paginatorElementBorder;
72
+ color: $paginatorElementIconColor;
73
+ min-width: 2rem;
74
+ height: 2rem;
75
+ margin: $paginatorElementMargin;
76
+ transition: $listItemTransition;
77
+ border-radius: $paginatorElementBorderRadius;
78
+
79
+ &.p-highlight {
80
+ background: $highlightBg;
81
+ border-color: $highlightBg;
82
+ color: $highlightTextColor;
83
+ }
84
+
85
+ &:not(.p-highlight):hover {
86
+ background: $paginatorElementHoverBg;
87
+ border-color: $paginatorElementHoverBorderColor;
88
+ color: $paginatorElementIconHoverColor;
89
+ }
90
+ }
91
+ }
92
+ }