@vc-shell/framework 1.0.70 → 1.0.72

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 (182) hide show
  1. package/CHANGELOG.md +51 -1
  2. package/core/composables/useNotifications/index.ts +1 -1
  3. package/core/composables/usePermissions/index.ts +21 -8
  4. package/core/composables/useUser/index.ts +180 -13
  5. package/core/plugins/modularity/index.ts +17 -2
  6. package/core/utilities/index.ts +1 -0
  7. package/core/utilities/kebabToCamel.ts +7 -0
  8. package/dist/core/composables/useNotifications/index.d.ts +1 -1
  9. package/dist/core/composables/useNotifications/index.d.ts.map +1 -1
  10. package/dist/core/composables/usePermissions/index.d.ts +1 -2
  11. package/dist/core/composables/usePermissions/index.d.ts.map +1 -1
  12. package/dist/core/composables/useUser/index.d.ts +18 -1
  13. package/dist/core/composables/useUser/index.d.ts.map +1 -1
  14. package/dist/core/plugins/modularity/index.d.ts +4 -1
  15. package/dist/core/plugins/modularity/index.d.ts.map +1 -1
  16. package/dist/core/utilities/index.d.ts +1 -0
  17. package/dist/core/utilities/index.d.ts.map +1 -1
  18. package/dist/core/utilities/kebabToCamel.d.ts +2 -0
  19. package/dist/core/utilities/kebabToCamel.d.ts.map +1 -0
  20. package/dist/framework.mjs +18205 -16332
  21. package/dist/index.css +1 -1
  22. package/dist/index.d.ts +2 -1
  23. package/dist/index.d.ts.map +1 -1
  24. package/dist/shared/components/app-switcher/composables/useAppSwitcher/index.d.ts +1 -1
  25. package/dist/shared/components/app-switcher/composables/useAppSwitcher/index.d.ts.map +1 -1
  26. package/dist/shared/components/blade-navigation/components/vc-blade-navigation/index.d.ts +5 -7
  27. package/dist/shared/components/blade-navigation/components/vc-blade-navigation/index.d.ts.map +1 -1
  28. package/dist/shared/components/blade-navigation/components/vc-blade-navigation/vc-blade-navigation.vue.d.ts +5 -5
  29. package/dist/shared/components/blade-navigation/components/vc-blade-navigation/vc-blade-navigation.vue.d.ts.map +1 -1
  30. package/dist/shared/components/blade-navigation/composables/useBladeNavigation/index.d.ts +21 -5
  31. package/dist/shared/components/blade-navigation/composables/useBladeNavigation/index.d.ts.map +1 -1
  32. package/dist/shared/components/blade-navigation/types/index.d.ts +1 -1
  33. package/dist/shared/components/blade-navigation/types/index.d.ts.map +1 -1
  34. package/dist/shared/components/change-password/change-password.vue.d.ts +7 -0
  35. package/dist/shared/components/change-password/change-password.vue.d.ts.map +1 -0
  36. package/dist/shared/components/change-password/index.d.ts +11 -0
  37. package/dist/shared/components/change-password/index.d.ts.map +1 -0
  38. package/dist/shared/components/index.d.ts +9 -0
  39. package/dist/shared/components/index.d.ts.map +1 -0
  40. package/dist/shared/components/language-selector/index.d.ts +55 -0
  41. package/dist/shared/components/language-selector/index.d.ts.map +1 -0
  42. package/dist/shared/components/language-selector/language-selector.vue.d.ts +45 -0
  43. package/dist/shared/components/language-selector/language-selector.vue.d.ts.map +1 -0
  44. package/dist/shared/components/notifications/core/notification.d.ts.map +1 -1
  45. package/dist/shared/components/notifications/types/index.d.ts +3 -1
  46. package/dist/shared/components/notifications/types/index.d.ts.map +1 -1
  47. package/dist/shared/components/user-dropdown-button/index.d.ts +43 -0
  48. package/dist/shared/components/user-dropdown-button/index.d.ts.map +1 -0
  49. package/dist/shared/components/user-dropdown-button/user-dropdown-button.vue.d.ts +33 -0
  50. package/dist/shared/components/user-dropdown-button/user-dropdown-button.vue.d.ts.map +1 -0
  51. package/dist/shared/index.d.ts +3 -7
  52. package/dist/shared/index.d.ts.map +1 -1
  53. package/dist/shared/locales/index.d.ts +3 -0
  54. package/dist/shared/locales/index.d.ts.map +1 -0
  55. package/dist/shared/modules/assets/components/assets-details/assets-details.vue.d.ts +2 -9
  56. package/dist/shared/modules/assets/components/assets-details/assets-details.vue.d.ts.map +1 -1
  57. package/dist/shared/modules/assets/components/assets-details/index.d.ts +23 -157
  58. package/dist/shared/modules/assets/components/assets-details/index.d.ts.map +1 -1
  59. package/dist/shared/modules/assets-manager/components/assets-manager/assets-manager.vue.d.ts +2 -9
  60. package/dist/shared/modules/assets-manager/components/assets-manager/assets-manager.vue.d.ts.map +1 -1
  61. package/dist/shared/modules/assets-manager/components/assets-manager/index.d.ts +27 -172
  62. package/dist/shared/modules/assets-manager/components/assets-manager/index.d.ts.map +1 -1
  63. package/dist/shared/modules/index.d.ts +3 -0
  64. package/dist/shared/modules/index.d.ts.map +1 -0
  65. package/dist/shared/pages/InvitePage/components/index.d.ts +2 -0
  66. package/dist/shared/pages/InvitePage/components/index.d.ts.map +1 -0
  67. package/dist/shared/pages/InvitePage/components/invite/Invite.vue.d.ts +33 -0
  68. package/dist/shared/pages/InvitePage/components/invite/Invite.vue.d.ts.map +1 -0
  69. package/dist/shared/pages/InvitePage/components/invite/index.d.ts +32 -0
  70. package/dist/shared/pages/InvitePage/components/invite/index.d.ts.map +1 -0
  71. package/dist/shared/pages/InvitePage/index.d.ts +5 -0
  72. package/dist/shared/pages/InvitePage/index.d.ts.map +1 -0
  73. package/dist/shared/pages/InvitePage/locales/index.d.ts +3 -0
  74. package/dist/shared/pages/InvitePage/locales/index.d.ts.map +1 -0
  75. package/dist/shared/pages/LoginPage/components/index.d.ts +2 -0
  76. package/dist/shared/pages/LoginPage/components/index.d.ts.map +1 -0
  77. package/dist/shared/pages/LoginPage/components/login/Login.vue.d.ts +17 -0
  78. package/dist/shared/pages/LoginPage/components/login/Login.vue.d.ts.map +1 -0
  79. package/dist/shared/pages/LoginPage/components/login/index.d.ts +28 -0
  80. package/dist/shared/pages/LoginPage/components/login/index.d.ts.map +1 -0
  81. package/dist/shared/pages/LoginPage/index.d.ts +3 -0
  82. package/dist/shared/pages/LoginPage/index.d.ts.map +1 -0
  83. package/dist/shared/pages/LoginPage/locales/index.d.ts +3 -0
  84. package/dist/shared/pages/LoginPage/locales/index.d.ts.map +1 -0
  85. package/dist/shared/pages/LoginPage/plugin.d.ts +6 -0
  86. package/dist/shared/pages/LoginPage/plugin.d.ts.map +1 -0
  87. package/dist/shared/pages/ResetPasswordPage/components/index.d.ts +2 -0
  88. package/dist/shared/pages/ResetPasswordPage/components/index.d.ts.map +1 -0
  89. package/dist/shared/pages/ResetPasswordPage/components/reset-password/ResetPassword.vue.d.ts +33 -0
  90. package/dist/shared/pages/ResetPasswordPage/components/reset-password/ResetPassword.vue.d.ts.map +1 -0
  91. package/dist/shared/pages/ResetPasswordPage/components/reset-password/index.d.ts +32 -0
  92. package/dist/shared/pages/ResetPasswordPage/components/reset-password/index.d.ts.map +1 -0
  93. package/dist/shared/pages/ResetPasswordPage/index.d.ts +5 -0
  94. package/dist/shared/pages/ResetPasswordPage/index.d.ts.map +1 -0
  95. package/dist/shared/pages/ResetPasswordPage/locales/index.d.ts +3 -0
  96. package/dist/shared/pages/ResetPasswordPage/locales/index.d.ts.map +1 -0
  97. package/dist/shared/pages/index.d.ts +10 -0
  98. package/dist/shared/pages/index.d.ts.map +1 -0
  99. package/dist/tsconfig.tsbuildinfo +1 -1
  100. package/dist/typings/index.d.ts +8 -0
  101. package/dist/typings/index.d.ts.map +1 -0
  102. package/dist/ui/components/atoms/vc-button/index.d.ts +36 -6
  103. package/dist/ui/components/atoms/vc-button/index.d.ts.map +1 -1
  104. package/dist/ui/components/atoms/vc-button/vc-button.vue.d.ts +10 -7
  105. package/dist/ui/components/atoms/vc-button/vc-button.vue.d.ts.map +1 -1
  106. package/dist/ui/components/atoms/vc-link/vc-link.stories.d.ts.map +1 -1
  107. package/dist/ui/components/atoms/vc-status/index.d.ts +6 -6
  108. package/dist/ui/components/atoms/vc-status/vc-status.vue.d.ts +1 -1
  109. package/dist/ui/components/molecules/vc-select/vc-select.vue.d.ts.map +1 -1
  110. package/dist/ui/components/organisms/vc-app/_internal/vc-app-bar/vc-app-bar.vue.d.ts.map +1 -1
  111. package/dist/ui/components/organisms/vc-app/_internal/vc-app-menu/_internal/vc-app-menu-item/vc-app-menu-item.vue.d.ts +1 -1
  112. package/dist/ui/components/organisms/vc-app/_internal/vc-app-menu/_internal/vc-app-menu-item/vc-app-menu-item.vue.d.ts.map +1 -1
  113. package/dist/ui/components/organisms/vc-app/vc-app.vue.d.ts +2 -2
  114. package/dist/ui/components/organisms/vc-app/vc-app.vue.d.ts.map +1 -1
  115. package/dist/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/_internal/vc-blade-toolbar-button/vc-blade-toolbar-button.vue.d.ts.map +1 -1
  116. package/dist/ui/components/organisms/vc-blade/index.d.ts +1 -31
  117. package/dist/ui/components/organisms/vc-blade/index.d.ts.map +1 -1
  118. package/dist/ui/components/organisms/vc-blade/vc-blade.vue.d.ts +1 -6
  119. package/dist/ui/components/organisms/vc-blade/vc-blade.vue.d.ts.map +1 -1
  120. package/dist/ui/components/organisms/vc-popup/index.d.ts +6 -6
  121. package/dist/ui/components/organisms/vc-popup/vc-popup.vue.d.ts +1 -1
  122. package/dist/ui/components/organisms/vc-popup/vc-popup.vue.d.ts.map +1 -1
  123. package/dist/ui/components/organisms/vc-table/_internal/vc-table-filter/vc-table-filter.vue.d.ts +2 -1
  124. package/dist/ui/components/organisms/vc-table/_internal/vc-table-filter/vc-table-filter.vue.d.ts.map +1 -1
  125. package/dist/ui/components/organisms/vc-table/index.d.ts +7 -7
  126. package/dist/ui/components/organisms/vc-table/vc-table.vue.d.ts +7 -7
  127. package/dist/ui/components/organisms/vc-table/vc-table.vue.d.ts.map +1 -1
  128. package/package.json +11 -8
  129. package/shared/components/app-switcher/composables/useAppSwitcher/index.ts +1 -1
  130. package/shared/components/blade-navigation/components/vc-blade-navigation/vc-blade-navigation.vue +10 -21
  131. package/shared/components/blade-navigation/composables/useBladeNavigation/index.ts +150 -67
  132. package/shared/components/blade-navigation/types/index.ts +1 -1
  133. package/shared/components/change-password/change-password.vue +167 -0
  134. package/shared/components/change-password/index.ts +10 -0
  135. package/shared/components/index.ts +8 -0
  136. package/shared/components/language-selector/index.ts +10 -0
  137. package/shared/components/language-selector/language-selector.vue +60 -0
  138. package/shared/components/notifications/core/notification.ts +3 -3
  139. package/shared/components/notifications/types/index.ts +4 -1
  140. package/shared/components/user-dropdown-button/index.ts +10 -0
  141. package/shared/components/user-dropdown-button/user-dropdown-button.vue +124 -0
  142. package/shared/index.ts +12 -8
  143. package/shared/locales/en.json +35 -0
  144. package/shared/locales/index.ts +2 -0
  145. package/shared/modules/assets/components/assets-details/assets-details.vue +1 -7
  146. package/shared/modules/assets-manager/components/assets-manager/assets-manager.vue +0 -6
  147. package/shared/modules/index.ts +2 -0
  148. package/shared/pages/InvitePage/components/index.ts +1 -0
  149. package/shared/pages/InvitePage/components/invite/Invite.vue +172 -0
  150. package/shared/pages/InvitePage/components/invite/index.ts +3 -0
  151. package/shared/pages/InvitePage/index.ts +7 -0
  152. package/shared/pages/InvitePage/locales/en.json +31 -0
  153. package/shared/pages/InvitePage/locales/index.ts +2 -0
  154. package/shared/pages/LoginPage/components/index.ts +1 -0
  155. package/shared/pages/LoginPage/components/login/Login.vue +283 -0
  156. package/shared/pages/LoginPage/components/login/index.ts +3 -0
  157. package/shared/pages/LoginPage/index.ts +2 -0
  158. package/shared/pages/LoginPage/locales/en.json +36 -0
  159. package/shared/pages/LoginPage/locales/index.ts +2 -0
  160. package/shared/pages/LoginPage/plugin.ts +17 -0
  161. package/shared/pages/ResetPasswordPage/components/index.ts +1 -0
  162. package/shared/pages/ResetPasswordPage/components/reset-password/ResetPassword.vue +166 -0
  163. package/shared/pages/ResetPasswordPage/components/reset-password/index.ts +3 -0
  164. package/shared/pages/ResetPasswordPage/index.ts +7 -0
  165. package/shared/pages/ResetPasswordPage/locales/en.json +28 -0
  166. package/shared/pages/ResetPasswordPage/locales/index.ts +2 -0
  167. package/shared/pages/index.ts +12 -0
  168. package/ui/components/atoms/vc-button/vc-button.vue +109 -143
  169. package/ui/components/atoms/vc-link/vc-link.stories.ts +0 -1
  170. package/ui/components/atoms/vc-link/vc-link.vue +2 -2
  171. package/ui/components/molecules/vc-select/vc-select.vue +3 -3
  172. package/ui/components/organisms/vc-app/_internal/vc-app-bar/vc-app-bar.vue +2 -1
  173. package/ui/components/organisms/vc-app/_internal/vc-app-menu/_internal/vc-app-menu-item/vc-app-menu-item.vue +3 -4
  174. package/ui/components/organisms/vc-app/vc-app.vue +12 -12
  175. package/ui/components/organisms/vc-blade/_internal/vc-blade-toolbar/_internal/vc-blade-toolbar-button/vc-blade-toolbar-button.vue +5 -8
  176. package/ui/components/organisms/vc-blade/vc-blade.vue +14 -22
  177. package/ui/components/organisms/vc-login-form/vc-login-form.stories.ts +1 -1
  178. package/ui/components/organisms/vc-popup/_internal/vc-popup-warning/vc-popup-warning.vue +1 -1
  179. package/ui/components/organisms/vc-popup/vc-popup.vue +1 -1
  180. package/ui/components/organisms/vc-table/_internal/vc-table-filter/vc-table-filter.vue +5 -8
  181. package/ui/components/organisms/vc-table/vc-table.vue +25 -18
  182. package/ui/locales/en.json +3 -3
package/CHANGELOG.md CHANGED
@@ -1,3 +1,45 @@
1
+ ## [1.0.72](https://github.com/VirtoCommerce/vc-shell/compare/v1.0.71...v1.0.72) (2023-06-07)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * authData length check ([bd04284](https://github.com/VirtoCommerce/vc-shell/commit/bd04284fd91887a41ba99f52bd37d844a13c2e8a))
7
+ * vc-app-bar mobile styles ([75955d4](https://github.com/VirtoCommerce/vc-shell/commit/75955d4cb9692a3430395f8dbf5943b5c2eb8f36))
8
+ * vc-select dropdown closing ([ecde06f](https://github.com/VirtoCommerce/vc-shell/commit/ecde06ffd679d06f7d8f75304437510f4e46063c))
9
+
10
+
11
+ ### Features
12
+
13
+ * blade nav last state, permissions ([d98144a](https://github.com/VirtoCommerce/vc-shell/commit/d98144a2e5f2b4241543f7624fc7d811aa3f951f))
14
+
15
+
16
+
17
+ ## [1.0.71](https://github.com/VirtoCommerce/vc-shell/compare/v1.0.70...v1.0.71) (2023-06-02)
18
+
19
+
20
+ ### Bug Fixes
21
+
22
+ * *ui* vc-button text style ([58545cc](https://github.com/VirtoCommerce/vc-shell/commit/58545cc7955549a877e48cb8451e751490c564b3))
23
+ * *ui* vc-popup condition fix ([f0a3866](https://github.com/VirtoCommerce/vc-shell/commit/f0a3866325b12bf4fbc7d68eb83d1692d4cb7cca))
24
+ * navigation prevention fix ([fd94904](https://github.com/VirtoCommerce/vc-shell/commit/fd94904dc94d076dd690c41c18417e5e80dd2cc5))
25
+ * required blade in IBladeEvent interface ([b5197b2](https://github.com/VirtoCommerce/vc-shell/commit/b5197b26994291cb3cb8955626e7fff5154e2e73))
26
+
27
+
28
+ ### Features
29
+
30
+ * azure active directory signin ([46cee05](https://github.com/VirtoCommerce/vc-shell/commit/46cee052064434bdd143d744ca7557f5c0fd7e84))
31
+ * common pages moved to shell ([fca5967](https://github.com/VirtoCommerce/vc-shell/commit/fca5967bfa8fdfee09c043dfc565e8aa2534ada1))
32
+ * error slot removed from blades ([9135daa](https://github.com/VirtoCommerce/vc-shell/commit/9135daa186236c6ee9b95ebe786b4fc532828bfb))
33
+ * refactored vc-button ([b66d081](https://github.com/VirtoCommerce/vc-shell/commit/b66d081b79c32fd9a726bf686ec94070debd7f63))
34
+ * select-all ([3e30fef](https://github.com/VirtoCommerce/vc-shell/commit/3e30fefb71f0e5319724f0487c4c01f049ae19ff))
35
+
36
+
37
+ ### Reverts
38
+
39
+ * required blade in IBladeEvent ([61b1223](https://github.com/VirtoCommerce/vc-shell/commit/61b1223a3b4ce8a131a0ac58ec6c65ca18a053e8))
40
+
41
+
42
+
1
43
  ## [1.0.70](https://github.com/VirtoCommerce/vc-shell/compare/v1.0.69...v1.0.70) (2023-05-18)
2
44
 
3
45
 
@@ -21,7 +63,6 @@
21
63
  * notifications template ([1af7c34](https://github.com/VirtoCommerce/vc-shell/commit/1af7c34e228a8c7f8f0cdffd4edce4ff00b5882c))
22
64
  * popup handler/updated variant templates ([eae6366](https://github.com/VirtoCommerce/vc-shell/commit/eae6366839a2ab2e0c0dccfc14cf7c6bab5731f6))
23
65
  * refactored notifications ([84fda40](https://github.com/VirtoCommerce/vc-shell/commit/84fda4097a3afc7bb8e4a9f99da574885b872d7c))
24
- * transition to yarn berry monorepo ([73a4da7](https://github.com/VirtoCommerce/vc-shell/commit/73a4da7905fffa030501175d76aeaa0f4caae99a))
25
66
  * updated boilerplate ([9f686cc](https://github.com/VirtoCommerce/vc-shell/commit/9f686cca9361a1070b09d4763f6c5b3ace1a47ce))
26
67
  * v-click-outside changed to vueUse directive ([26d764f](https://github.com/VirtoCommerce/vc-shell/commit/26d764f83c9b53e667a85684b424a91de8e06a29))
27
68
  * vc-select generic component ([c71c8da](https://github.com/VirtoCommerce/vc-shell/commit/c71c8daead1ba5c5ece2a0eb4e15a52d01b1666e))
@@ -36,6 +77,15 @@
36
77
 
37
78
 
38
79
 
80
+ ## [1.0.69](https://github.com/VirtoCommerce/vc-shell/compare/v1.0.68...v1.0.69) (2023-04-26)
81
+
82
+
83
+ ### Features
84
+
85
+ * transition to yarn berry monorepo ([73a4da7](https://github.com/VirtoCommerce/vc-shell/commit/73a4da7905fffa030501175d76aeaa0f4caae99a))
86
+
87
+
88
+
39
89
  ## [1.0.68](https://github.com/VirtoCommerce/vc-shell/compare/v1.0.67...v1.0.68) (2023-04-24)
40
90
 
41
91
 
@@ -8,7 +8,7 @@ const notificationsClient = new PushNotificationClient();
8
8
  interface INotifications {
9
9
  readonly notifications: ComputedRef<PushNotification[]>;
10
10
  readonly moduleNotifications: ComputedRef<PushNotification[]>;
11
- loadFromHistory(take?: number): void;
11
+ loadFromHistory(take?: number): Promise<void>;
12
12
  addNotification(message: PushNotification): void;
13
13
  markAsRead(message: PushNotification): void;
14
14
  markAllAsRead(): void;
@@ -1,32 +1,45 @@
1
+ import { Ref, ref } from "vue";
1
2
  import { useUser } from "./../useUser";
2
- import { computed, ComputedRef } from "vue";
3
3
 
4
4
  interface IUsePermissions {
5
- readonly userPermissions: ComputedRef<string[]>;
6
5
  checkPermission(permissions: string | string[]): boolean;
6
+ fetchUserPermissions(): Promise<void>;
7
7
  }
8
-
8
+ const userPermissions: Ref<string[]> = ref([]);
9
9
  export function usePermissions(): IUsePermissions {
10
- const { user } = useUser();
10
+ const { user, loadUser } = useUser();
11
+
12
+ async function fetchUserPermissions() {
13
+ if (user.value?.permissions) {
14
+ userPermissions.value = user.value?.permissions;
15
+ } else {
16
+ try {
17
+ const userData = await loadUser();
18
+ userPermissions.value = userData.permissions;
19
+ } catch (e) {
20
+ throw new Error("Unable to load user permissions");
21
+ }
22
+ }
23
+ }
11
24
 
12
25
  function checkPermission(permissions: string | string[] | undefined) {
13
26
  if (!permissions) {
14
27
  return true;
15
28
  } else if (permissions || (permissions && permissions instanceof Array)) {
16
29
  if (typeof permissions === "string") {
17
- return user.value?.permissions.includes(permissions);
30
+ return userPermissions.value?.includes(permissions);
18
31
  } else if (permissions.length > 0) {
19
- return user.value?.permissions.some((role) => {
32
+ return userPermissions.value?.some((role) => {
20
33
  return permissions.includes(role);
21
34
  });
22
35
  }
23
36
  } else {
24
- console.error("Permissions must be a string or strings array");
37
+ throw new Error("Permissions must be a string or strings array");
25
38
  }
26
39
  }
27
40
 
28
41
  return {
29
- userPermissions: computed(() => user.value?.permissions),
30
42
  checkPermission,
43
+ fetchUserPermissions,
31
44
  };
32
45
  }
@@ -1,4 +1,4 @@
1
- import { computed, Ref, ref, ComputedRef } from "vue";
1
+ import { computed, Ref, ref, ComputedRef, onUnmounted, getCurrentInstance } from "vue";
2
2
  import ClientOAuth2 from "client-oauth2";
3
3
  import {
4
4
  UserDetail,
@@ -9,6 +9,8 @@ import {
9
9
  IdentityResult,
10
10
  } from "./../../api";
11
11
  import { AuthData, RequestPasswordResult, SignInResults } from "./../../types";
12
+ import * as _ from "lodash-es";
13
+ import fetchIntercept from "fetch-intercept";
12
14
  //The Platform Manager uses the same key to store authorization data in the
13
15
  //local storage, so we can exchange authorization data between the Platform Manager
14
16
  //and the user application that is hosted in the same domain as the sub application.
@@ -21,11 +23,25 @@ const authClient = new ClientOAuth2({
21
23
  accessTokenUri: `/connect/token`,
22
24
  scopes: ["offline_access"],
23
25
  });
26
+ const isExternalSignedIn = ref(false);
27
+ const activeAuthenticationType = ref();
24
28
  const securityClient = new SecurityClient();
25
29
 
30
+ export interface LoginTypes {
31
+ enabled?: boolean;
32
+ hasLoginForm?: boolean;
33
+ authenticationType?: string;
34
+ priority?: number;
35
+ }
36
+ export interface LoginProviders {
37
+ authenticationType?: string;
38
+ displayName?: string;
39
+ }
40
+
26
41
  interface IUseUser {
27
42
  user: ComputedRef<UserDetail | null>;
28
43
  loading: ComputedRef<boolean>;
44
+ isExternalSignedIn: Ref<boolean>;
29
45
  getAccessToken: () => Promise<string | null>;
30
46
  loadUser: () => Promise<UserDetail>;
31
47
  signIn: (username: string, password: string) => Promise<SignInResults>;
@@ -35,9 +51,23 @@ interface IUseUser {
35
51
  resetPasswordByToken: (userId: string, password: string, token: string) => Promise<SecurityResult>;
36
52
  requestPasswordReset: (loginOrEmail: string) => Promise<RequestPasswordResult>;
37
53
  changeUserPassword: (oldPassword: string, newPassword: string) => Promise<SecurityResult>;
54
+ getExternalLoginProviders: () => Promise<LoginProviders[]>;
55
+ externalSignIn: (authenticationType?: string | undefined, returnUrl?: string | undefined) => void;
56
+ externalSignOut: (authenticationType?: string | undefined) => void;
57
+ getLoginTypes: () => Promise<LoginTypes[]>;
58
+ isAzureAdAuthAvailable: () => Promise<boolean>;
59
+ getAzureAdAuthCaption: () => Promise<string>;
38
60
  }
39
61
 
40
62
  export function useUser(): IUseUser {
63
+ // const instance = getCurrentInstance();
64
+ // if (instance) {
65
+ // onUnmounted(() => {
66
+ // console.error("UNREGISTET");
67
+ // unregister();
68
+ // });
69
+ // }
70
+
41
71
  async function validateToken(userId: string, token: string): Promise<boolean> {
42
72
  let result = false;
43
73
  try {
@@ -84,7 +114,7 @@ export function useUser(): IUseUser {
84
114
  expiresAt: addOffsetToCurrentDate(Number(token.data["expires_in"])),
85
115
  userName: username,
86
116
  };
87
- console.log("[userUsers]: an access token has been obtained successfully", authData.value);
117
+ console.log("[useUser]: an access token has been obtained successfully", authData.value);
88
118
 
89
119
  storeAuthData(authData.value);
90
120
  await loadUser();
@@ -94,10 +124,15 @@ export function useUser(): IUseUser {
94
124
 
95
125
  async function signOut(): Promise<void> {
96
126
  console.debug(`[@vc-shell/framework#useUser:signOut] - Entry point`);
97
- user.value = undefined;
98
- authData.value = undefined;
99
- storeAuthData({});
100
- //todo
127
+
128
+ if (!isExternalSignedIn.value) {
129
+ user.value = undefined;
130
+ authData.value = undefined;
131
+ storeAuthData({});
132
+ } else {
133
+ externalSignOut(activeAuthenticationType.value);
134
+ activeAuthenticationType.value = undefined;
135
+ }
101
136
  }
102
137
 
103
138
  async function loadUser(): Promise<UserDetail> {
@@ -108,7 +143,7 @@ export function useUser(): IUseUser {
108
143
  try {
109
144
  loading.value = true;
110
145
  user.value = await securityClient.getCurrentUser();
111
- console.log("[userUsers]: an user details has been loaded", user.value);
146
+ console.log("[useUser]: an user details has been loaded", user.value);
112
147
  } catch (e) {
113
148
  console.dir(e);
114
149
  throw e;
@@ -121,8 +156,8 @@ export function useUser(): IUseUser {
121
156
 
122
157
  async function getAccessToken(): Promise<string | null> {
123
158
  console.debug(`[@vc-shell/framework#useUser:getAccessToken] - Entry point`);
124
- if (!authData.value) {
125
- authData.value = readAuthData();
159
+ if (!authData.value || Object.keys(authData.value).length === 0) {
160
+ authData.value = await readAuthData();
126
161
  }
127
162
 
128
163
  if (authData.value && Date.now() >= (authData.value.expiresAt ?? 0)) {
@@ -131,7 +166,8 @@ export function useUser(): IUseUser {
131
166
  authData.value.refreshToken ?? "",
132
167
  {}
133
168
  );
134
- console.log("[userUsers]: an access token is expired, using refresh token to receive a new");
169
+
170
+ console.log("[useUser]: an access token is expired, using refresh token to receive a new");
135
171
  try {
136
172
  const newToken = await token.refresh();
137
173
  if (newToken) {
@@ -145,7 +181,7 @@ export function useUser(): IUseUser {
145
181
  storeAuthData(authData.value);
146
182
  }
147
183
  } catch (e) {
148
- console.log("[userUsers]: getAccessToken() returns error", e);
184
+ console.log("[useUser]: getAccessToken() returns error", e);
149
185
  }
150
186
  }
151
187
 
@@ -155,8 +191,8 @@ export function useUser(): IUseUser {
155
191
  function storeAuthData(authData: AuthData) {
156
192
  localStorage.setItem(VC_AUTH_DATA_KEY, JSON.stringify({ ...(authData || {}) }));
157
193
  }
158
- function readAuthData(): AuthData {
159
- return JSON.parse(localStorage.getItem(VC_AUTH_DATA_KEY) || "{}") as AuthData;
194
+ async function readAuthData(): Promise<AuthData> {
195
+ return (await JSON.parse(localStorage.getItem(VC_AUTH_DATA_KEY) || "{}")) as AuthData;
160
196
  }
161
197
 
162
198
  function addOffsetToCurrentDate(offsetInSeconds: number): number {
@@ -211,9 +247,134 @@ export function useUser(): IUseUser {
211
247
  return result as SecurityResult;
212
248
  }
213
249
 
250
+ async function getLoginTypes(): Promise<LoginTypes[]> {
251
+ let result = null as LoginTypes[];
252
+ try {
253
+ const fetchResult = await fetch("/api/platform/security/logintypes", {
254
+ method: "GET",
255
+ headers: {},
256
+ });
257
+
258
+ const response = await fetchResult.text();
259
+ if (response && response.trim()) {
260
+ result = JSON.parse(response) as LoginTypes[];
261
+ }
262
+ } catch (e) {
263
+ console.error(e);
264
+
265
+ throw e;
266
+ }
267
+
268
+ return result;
269
+ }
270
+
271
+ async function getExternalLoginProviders(): Promise<LoginProviders[]> {
272
+ let result = null as LoginProviders[];
273
+ try {
274
+ const fetchResult = await fetch(import.meta.env.APP_PLATFORM_URL + "externalsignin/providers", {
275
+ method: "GET",
276
+ mode: "no-cors",
277
+ });
278
+
279
+ const response = await fetchResult.text();
280
+ if (response && response.trim()) {
281
+ result = JSON.parse(response) as LoginProviders[];
282
+ }
283
+ } catch (e) {
284
+ console.error(e);
285
+
286
+ throw e;
287
+ }
288
+
289
+ return result;
290
+ }
291
+
292
+ async function externalSignIn(authenticationType?: string | undefined, returnUrl?: string | undefined) {
293
+ activeAuthenticationType.value = authenticationType;
294
+ try {
295
+ let url_ = import.meta.env.APP_PLATFORM_URL + "externalsignin?";
296
+ if (authenticationType === null) throw new Error("The parameter 'authenticationType' cannot be null.");
297
+ else {
298
+ if (authenticationType !== undefined)
299
+ url_ += "authenticationType=" + encodeURIComponent("" + authenticationType) + "&";
300
+ if (returnUrl !== undefined) url_ += "returnUrl=" + encodeURIComponent("" + returnUrl) + "&";
301
+ }
302
+ url_ = url_.replace(/[?&]$/, "");
303
+ isExternalSignedIn.value = true;
304
+ initInterceptor();
305
+
306
+ window.location.href = url_;
307
+ } catch (e) {
308
+ isExternalSignedIn.value = false;
309
+ console.error(e);
310
+
311
+ throw e;
312
+ }
313
+ }
314
+
315
+ async function externalSignOut(authenticationType?: string | undefined): Promise<void> {
316
+ try {
317
+ let url_ = import.meta.env.APP_PLATFORM_URL + "externalsignin/signout?";
318
+ if (authenticationType === null) throw new Error("The parameter 'authenticationType' cannot be null.");
319
+ else {
320
+ if (authenticationType !== undefined)
321
+ url_ += "authenticationType=" + encodeURIComponent("" + authenticationType) + "&";
322
+ }
323
+ url_ = url_.replace(/[?&]$/, "");
324
+
325
+ await fetch(url_, {
326
+ method: "GET",
327
+ mode: "no-cors",
328
+ headers: {},
329
+ });
330
+
331
+ fetchIntercept.clear();
332
+ } catch (e) {
333
+ console.error(e);
334
+
335
+ throw e;
336
+ }
337
+ isExternalSignedIn.value = false;
338
+ }
339
+
340
+ async function isAzureAdAuthAvailable(): Promise<boolean> {
341
+ const loginTypes = await getLoginTypes();
342
+ if (loginTypes) {
343
+ return (
344
+ loginTypes.filter((x) => x.authenticationType === "AzureAD").length > 0 &&
345
+ loginTypes.find((x) => x.authenticationType === "AzureAD").enabled
346
+ );
347
+ }
348
+ return false;
349
+ }
350
+
351
+ async function getAzureAdAuthCaption(): Promise<string> {
352
+ const loginProviders = await getExternalLoginProviders();
353
+ if (loginProviders) {
354
+ return loginProviders.find((x) => x.authenticationType === "AzureAD").displayName;
355
+ }
356
+ return null;
357
+ }
358
+
359
+ /* Intercepting requests to explicitly remove auth token when we use AzureAd authentication */
360
+ function initInterceptor() {
361
+ console.log("[@vc-shell/framework#useUser:initInterceptor]: Entry point");
362
+ return fetchIntercept.register({
363
+ request: function (_url, config) {
364
+ if (isExternalSignedIn.value) {
365
+ const edited = _.omit(config.headers, "authorization");
366
+ config.headers = edited;
367
+ }
368
+
369
+ return [_url, config];
370
+ },
371
+ });
372
+ }
373
+
214
374
  return {
215
375
  user: computed(() => user.value),
216
376
  loading: computed(() => loading.value),
377
+ isExternalSignedIn,
217
378
  getAccessToken,
218
379
  loadUser,
219
380
  signIn,
@@ -223,5 +384,11 @@ export function useUser(): IUseUser {
223
384
  resetPasswordByToken,
224
385
  requestPasswordReset,
225
386
  changeUserPassword,
387
+ getExternalLoginProviders,
388
+ externalSignIn,
389
+ externalSignOut,
390
+ getLoginTypes,
391
+ isAzureAdAuthAvailable,
392
+ getAzureAdAuthCaption,
226
393
  };
227
394
  }
@@ -1,5 +1,8 @@
1
1
  import { App } from "vue";
2
2
  import { i18n } from "./../i18n";
3
+ import { Router } from "vue-router";
4
+ import { BladeConstructor } from "./../../../shared/components/blade-navigation/types";
5
+ import { kebabToPascal } from "./../../utilities";
3
6
 
4
7
  export const createModule = (components: unknown, locales?: unknown) => ({
5
8
  install(app: App): void {
@@ -21,10 +24,22 @@ export const createAppModule = (pages: unknown, locales?: unknown, notificationT
21
24
  const module = createModule(pages, locales);
22
25
 
23
26
  return {
24
- install(app: App): void {
27
+ install(app: App, options: { router: Router }): void {
28
+ const { router } = options;
25
29
  // Register pages
26
- Object.entries(pages).forEach(([, page]) => {
30
+ Object.entries(pages).forEach(([, page]: [string, BladeConstructor]) => {
27
31
  app.config.globalProperties.pages?.push(page);
32
+
33
+ // Dynamically add pages to vue router
34
+ if (page.url) {
35
+ const mainRouteName = router.getRoutes().find((r) => r.meta?.root)?.name;
36
+
37
+ router.addRoute(mainRouteName, {
38
+ name: kebabToPascal(page.url.substring(1)),
39
+ path: page.url.substring(1),
40
+ component: page,
41
+ });
42
+ }
28
43
  });
29
44
 
30
45
  if (notificationTemplates) {
@@ -1 +1,2 @@
1
1
  export * from "./camelToSnake";
2
+ export * from "./kebabToCamel";
@@ -0,0 +1,7 @@
1
+ const kebabToCamel = (str: string) => str.replace(/-./g, (x) => x[1].toUpperCase());
2
+
3
+ export function kebabToPascal(str: string) {
4
+ const camelCase = kebabToCamel(str);
5
+ const pascalCase = camelCase[0].toUpperCase() + camelCase.substr(1);
6
+ return pascalCase;
7
+ }
@@ -3,7 +3,7 @@ import { ComputedRef } from "vue";
3
3
  interface INotifications {
4
4
  readonly notifications: ComputedRef<PushNotification[]>;
5
5
  readonly moduleNotifications: ComputedRef<PushNotification[]>;
6
- loadFromHistory(take?: number): void;
6
+ loadFromHistory(take?: number): Promise<void>;
7
7
  addNotification(message: PushNotification): void;
8
8
  markAsRead(message: PushNotification): void;
9
9
  markAllAsRead(): void;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../core/composables/useNotifications/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAA0B,MAAM,aAAa,CAAC;AAEvE,OAAO,EAAY,WAAW,EAAO,MAAM,KAAK,CAAC;AAKjD,UAAU,cAAc;IACtB,QAAQ,CAAC,aAAa,EAAE,WAAW,CAAC,gBAAgB,EAAE,CAAC,CAAC;IACxD,QAAQ,CAAC,mBAAmB,EAAE,WAAW,CAAC,gBAAgB,EAAE,CAAC,CAAC;IAC9D,eAAe,CAAC,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACrC,eAAe,CAAC,OAAO,EAAE,gBAAgB,GAAG,IAAI,CAAC;IACjD,UAAU,CAAC,OAAO,EAAE,gBAAgB,GAAG,IAAI,CAAC;IAC5C,aAAa,IAAI,IAAI,CAAC;CACvB;AAKD,wBAAgB,gBAAgB,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,cAAc,CA6F/E"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../core/composables/useNotifications/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAA0B,MAAM,aAAa,CAAC;AAEvE,OAAO,EAAY,WAAW,EAAO,MAAM,KAAK,CAAC;AAKjD,UAAU,cAAc;IACtB,QAAQ,CAAC,aAAa,EAAE,WAAW,CAAC,gBAAgB,EAAE,CAAC,CAAC;IACxD,QAAQ,CAAC,mBAAmB,EAAE,WAAW,CAAC,gBAAgB,EAAE,CAAC,CAAC;IAC9D,eAAe,CAAC,IAAI,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC9C,eAAe,CAAC,OAAO,EAAE,gBAAgB,GAAG,IAAI,CAAC;IACjD,UAAU,CAAC,OAAO,EAAE,gBAAgB,GAAG,IAAI,CAAC;IAC5C,aAAa,IAAI,IAAI,CAAC;CACvB;AAKD,wBAAgB,gBAAgB,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,cAAc,CA6F/E"}
@@ -1,7 +1,6 @@
1
- import { ComputedRef } from "vue";
2
1
  interface IUsePermissions {
3
- readonly userPermissions: ComputedRef<string[]>;
4
2
  checkPermission(permissions: string | string[]): boolean;
3
+ fetchUserPermissions(): Promise<void>;
5
4
  }
6
5
  export declare function usePermissions(): IUsePermissions;
7
6
  export {};
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../core/composables/usePermissions/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAY,WAAW,EAAE,MAAM,KAAK,CAAC;AAE5C,UAAU,eAAe;IACvB,QAAQ,CAAC,eAAe,EAAE,WAAW,CAAC,MAAM,EAAE,CAAC,CAAC;IAChD,eAAe,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,OAAO,CAAC;CAC1D;AAED,wBAAgB,cAAc,IAAI,eAAe,CAuBhD"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../core/composables/usePermissions/index.ts"],"names":[],"mappings":"AAGA,UAAU,eAAe;IACvB,eAAe,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,OAAO,CAAC;IACzD,oBAAoB,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;CACvC;AAED,wBAAgB,cAAc,IAAI,eAAe,CAoChD"}
@@ -1,9 +1,20 @@
1
- import { ComputedRef } from "vue";
1
+ import { Ref, ComputedRef } from "vue";
2
2
  import { UserDetail, SecurityResult, IdentityResult } from "./../../api";
3
3
  import { RequestPasswordResult, SignInResults } from "./../../types";
4
+ export interface LoginTypes {
5
+ enabled?: boolean;
6
+ hasLoginForm?: boolean;
7
+ authenticationType?: string;
8
+ priority?: number;
9
+ }
10
+ export interface LoginProviders {
11
+ authenticationType?: string;
12
+ displayName?: string;
13
+ }
4
14
  interface IUseUser {
5
15
  user: ComputedRef<UserDetail | null>;
6
16
  loading: ComputedRef<boolean>;
17
+ isExternalSignedIn: Ref<boolean>;
7
18
  getAccessToken: () => Promise<string | null>;
8
19
  loadUser: () => Promise<UserDetail>;
9
20
  signIn: (username: string, password: string) => Promise<SignInResults>;
@@ -13,6 +24,12 @@ interface IUseUser {
13
24
  resetPasswordByToken: (userId: string, password: string, token: string) => Promise<SecurityResult>;
14
25
  requestPasswordReset: (loginOrEmail: string) => Promise<RequestPasswordResult>;
15
26
  changeUserPassword: (oldPassword: string, newPassword: string) => Promise<SecurityResult>;
27
+ getExternalLoginProviders: () => Promise<LoginProviders[]>;
28
+ externalSignIn: (authenticationType?: string | undefined, returnUrl?: string | undefined) => void;
29
+ externalSignOut: (authenticationType?: string | undefined) => void;
30
+ getLoginTypes: () => Promise<LoginTypes[]>;
31
+ isAzureAdAuthAvailable: () => Promise<boolean>;
32
+ getAzureAdAuthCaption: () => Promise<string>;
16
33
  }
17
34
  export declare function useUser(): IUseUser;
18
35
  export {};
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../core/composables/useUser/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAsB,WAAW,EAAE,MAAM,KAAK,CAAC;AAEtD,OAAO,EACL,UAAU,EAGV,cAAc,EAEd,cAAc,EACf,MAAM,aAAa,CAAC;AACrB,OAAO,EAAY,qBAAqB,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAe/E,UAAU,QAAQ;IAChB,IAAI,EAAE,WAAW,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;IACrC,OAAO,EAAE,WAAW,CAAC,OAAO,CAAC,CAAC;IAC9B,cAAc,EAAE,MAAM,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IAC7C,QAAQ,EAAE,MAAM,OAAO,CAAC,UAAU,CAAC,CAAC;IACpC,MAAM,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,aAAa,CAAC,CAAC;IACvE,OAAO,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAC7B,aAAa,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;IACnE,gBAAgB,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,cAAc,CAAC,CAAC;IAChE,oBAAoB,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,cAAc,CAAC,CAAC;IACnG,oBAAoB,EAAE,CAAC,YAAY,EAAE,MAAM,KAAK,OAAO,CAAC,qBAAqB,CAAC,CAAC;IAC/E,kBAAkB,EAAE,CAAC,WAAW,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,KAAK,OAAO,CAAC,cAAc,CAAC,CAAC;CAC3F;AAED,wBAAgB,OAAO,IAAI,QAAQ,CA2LlC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../core/composables/useUser/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,GAAG,EAAO,WAAW,EAAmC,MAAM,KAAK,CAAC;AAEvF,OAAO,EACL,UAAU,EAGV,cAAc,EAEd,cAAc,EACf,MAAM,aAAa,CAAC;AACrB,OAAO,EAAY,qBAAqB,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAmB/E,MAAM,WAAW,UAAU;IACzB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AACD,MAAM,WAAW,cAAc;IAC7B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,UAAU,QAAQ;IAChB,IAAI,EAAE,WAAW,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;IACrC,OAAO,EAAE,WAAW,CAAC,OAAO,CAAC,CAAC;IAC9B,kBAAkB,EAAE,GAAG,CAAC,OAAO,CAAC,CAAC;IACjC,cAAc,EAAE,MAAM,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IAC7C,QAAQ,EAAE,MAAM,OAAO,CAAC,UAAU,CAAC,CAAC;IACpC,MAAM,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,aAAa,CAAC,CAAC;IACvE,OAAO,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAC7B,aAAa,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;IACnE,gBAAgB,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,cAAc,CAAC,CAAC;IAChE,oBAAoB,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,cAAc,CAAC,CAAC;IACnG,oBAAoB,EAAE,CAAC,YAAY,EAAE,MAAM,KAAK,OAAO,CAAC,qBAAqB,CAAC,CAAC;IAC/E,kBAAkB,EAAE,CAAC,WAAW,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,KAAK,OAAO,CAAC,cAAc,CAAC,CAAC;IAC1F,yBAAyB,EAAE,MAAM,OAAO,CAAC,cAAc,EAAE,CAAC,CAAC;IAC3D,cAAc,EAAE,CAAC,kBAAkB,CAAC,EAAE,MAAM,GAAG,SAAS,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,KAAK,IAAI,CAAC;IAClG,eAAe,EAAE,CAAC,kBAAkB,CAAC,EAAE,MAAM,GAAG,SAAS,KAAK,IAAI,CAAC;IACnE,aAAa,EAAE,MAAM,OAAO,CAAC,UAAU,EAAE,CAAC,CAAC;IAC3C,sBAAsB,EAAE,MAAM,OAAO,CAAC,OAAO,CAAC,CAAC;IAC/C,qBAAqB,EAAE,MAAM,OAAO,CAAC,MAAM,CAAC,CAAC;CAC9C;AAED,wBAAgB,OAAO,IAAI,QAAQ,CA4UlC"}
@@ -1,8 +1,11 @@
1
1
  import { App } from "vue";
2
+ import { Router } from "vue-router";
2
3
  export declare const createModule: (components: unknown, locales?: unknown) => {
3
4
  install(app: App): void;
4
5
  };
5
6
  export declare const createAppModule: (pages: unknown, locales?: unknown, notificationTemplates?: unknown) => {
6
- install(app: App): void;
7
+ install(app: App, options: {
8
+ router: Router;
9
+ }): void;
7
10
  };
8
11
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../core/plugins/modularity/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAG1B,eAAO,MAAM,YAAY,eAAgB,OAAO,YAAY,OAAO;iBACpD,GAAG,GAAG,IAAI;CAavB,CAAC;AAEH,eAAO,MAAM,eAAe,UAAW,OAAO,YAAY,OAAO,0BAA0B,OAAO;iBAIjF,GAAG,GAAG,IAAI;CAe1B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../core/plugins/modularity/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B,OAAO,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAIpC,eAAO,MAAM,YAAY,eAAgB,OAAO,YAAY,OAAO;iBACpD,GAAG,GAAG,IAAI;CAavB,CAAC;AAEH,eAAO,MAAM,eAAe,UAAW,OAAO,YAAY,OAAO,0BAA0B,OAAO;iBAIjF,GAAG,WAAW;QAAE,MAAM,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI;CA2BvD,CAAC"}
@@ -1,2 +1,3 @@
1
1
  export * from "./camelToSnake";
2
+ export * from "./kebabToCamel";
2
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../core/utilities/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../core/utilities/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare function kebabToPascal(str: string): string;
2
+ //# sourceMappingURL=kebabToCamel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"kebabToCamel.d.ts","sourceRoot":"","sources":["../../../core/utilities/kebabToCamel.ts"],"names":[],"mappings":"AAEA,wBAAgB,aAAa,CAAC,GAAG,EAAE,MAAM,UAIxC"}