@squide/firefly 9.0.0 → 9.1.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.
- package/CHANGELOG.md +116 -0
- package/README.md +1 -1
- package/dist/{chunk-H6F7HDB3.js → chunk-GXSW4CZS.js} +2 -2
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/useNavigationItems.d.ts +4 -2
- package/dist/useNavigationItems.js +1 -1
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,121 @@
|
|
|
1
1
|
# @squide/firefly
|
|
2
2
|
|
|
3
|
+
## 9.1.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#195](https://github.com/gsoft-inc/wl-squide/pull/195) [`98e4839`](https://github.com/gsoft-inc/wl-squide/commit/98e48393fda27ebb2974ecc1e2f71b09f4e84953) Thanks [@patricklafrance](https://github.com/patricklafrance)! - Replaced the `ManagedRoutes` placeholder by the `PublicRoutes` and `ProtectedRoutes` placeholder.
|
|
8
|
+
|
|
9
|
+
Before:
|
|
10
|
+
|
|
11
|
+
```tsx
|
|
12
|
+
import {
|
|
13
|
+
ManagedRoutes,
|
|
14
|
+
type ModuleRegisterFunction,
|
|
15
|
+
type FireflyRuntime,
|
|
16
|
+
} from "@squide/firefly";
|
|
17
|
+
import { RootLayout } from "./RootLayout.tsx";
|
|
18
|
+
|
|
19
|
+
export const registerHost: ModuleRegisterFunction<FireflyRuntime> = (
|
|
20
|
+
runtime
|
|
21
|
+
) => {
|
|
22
|
+
runtime.registerRoute(
|
|
23
|
+
{
|
|
24
|
+
element: <RootLayout />,
|
|
25
|
+
children: [ManagedRoutes],
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
hoist: true,
|
|
29
|
+
}
|
|
30
|
+
);
|
|
31
|
+
};
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
Now:
|
|
35
|
+
|
|
36
|
+
```tsx
|
|
37
|
+
import {
|
|
38
|
+
PublicRoutes,
|
|
39
|
+
ProtectedRoutes,
|
|
40
|
+
type ModuleRegisterFunction,
|
|
41
|
+
type FireflyRuntime,
|
|
42
|
+
} from "@squide/firefly";
|
|
43
|
+
import { RootLayout } from "./RootLayout.tsx";
|
|
44
|
+
|
|
45
|
+
export const registerHost: ModuleRegisterFunction<FireflyRuntime> = (
|
|
46
|
+
runtime
|
|
47
|
+
) => {
|
|
48
|
+
runtime.registerRoute(
|
|
49
|
+
{
|
|
50
|
+
element: <RootLayout />,
|
|
51
|
+
children: [PublicRoutes, ProtectedRoutes],
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
hoist: true,
|
|
55
|
+
}
|
|
56
|
+
);
|
|
57
|
+
};
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
Or:
|
|
61
|
+
|
|
62
|
+
```tsx
|
|
63
|
+
import {
|
|
64
|
+
PublicRoutes,
|
|
65
|
+
ProtectedRoutes,
|
|
66
|
+
type ModuleRegisterFunction,
|
|
67
|
+
type FireflyRuntime,
|
|
68
|
+
} from "@squide/firefly";
|
|
69
|
+
import { RootLayout } from "./RootLayout.tsx";
|
|
70
|
+
|
|
71
|
+
export const registerHost: ModuleRegisterFunction<FireflyRuntime> = (
|
|
72
|
+
runtime
|
|
73
|
+
) => {
|
|
74
|
+
runtime.registerRoute(
|
|
75
|
+
{
|
|
76
|
+
element: <RootLayout />,
|
|
77
|
+
children: [
|
|
78
|
+
PublicRoutes,
|
|
79
|
+
{
|
|
80
|
+
element: <AuthenticationBoundary />,
|
|
81
|
+
children: [
|
|
82
|
+
{
|
|
83
|
+
element: <AuthenticatedLayout />,
|
|
84
|
+
children: [ProtectedRoutes],
|
|
85
|
+
},
|
|
86
|
+
],
|
|
87
|
+
},
|
|
88
|
+
],
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
hoist: true,
|
|
92
|
+
}
|
|
93
|
+
);
|
|
94
|
+
};
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
This release also includes a new `runtime.registerPublicRoute()` function.
|
|
98
|
+
|
|
99
|
+
### Patch Changes
|
|
100
|
+
|
|
101
|
+
- Updated dependencies [[`98e4839`](https://github.com/gsoft-inc/wl-squide/commit/98e48393fda27ebb2974ecc1e2f71b09f4e84953)]:
|
|
102
|
+
- @squide/react-router@6.1.0
|
|
103
|
+
- @squide/core@5.1.0
|
|
104
|
+
- @squide/module-federation@6.0.2
|
|
105
|
+
- @squide/msw@3.0.2
|
|
106
|
+
|
|
107
|
+
## 9.0.1
|
|
108
|
+
|
|
109
|
+
### Patch Changes
|
|
110
|
+
|
|
111
|
+
- [#191](https://github.com/gsoft-inc/wl-squide/pull/191) [`2b62c53`](https://github.com/gsoft-inc/wl-squide/commit/2b62c539b0f3123cb47475566181e0b446ea6b40) Thanks [@patricklafrance](https://github.com/patricklafrance)! - `useNavigationItems` now accepts `useRuntimeNavigationItems` options.
|
|
112
|
+
|
|
113
|
+
- Updated dependencies [[`2b62c53`](https://github.com/gsoft-inc/wl-squide/commit/2b62c539b0f3123cb47475566181e0b446ea6b40)]:
|
|
114
|
+
- @squide/react-router@6.0.1
|
|
115
|
+
- @squide/core@5.0.1
|
|
116
|
+
- @squide/module-federation@6.0.1
|
|
117
|
+
- @squide/msw@3.0.1
|
|
118
|
+
|
|
3
119
|
## 9.0.0
|
|
4
120
|
|
|
5
121
|
### Major Changes
|
package/README.md
CHANGED
|
@@ -10,4 +10,4 @@ View the [contributor's documentation](../../CONTRIBUTING.md).
|
|
|
10
10
|
|
|
11
11
|
## License
|
|
12
12
|
|
|
13
|
-
Copyright ©
|
|
13
|
+
Copyright © 2024, Workleap. This code is licensed under the Apache License, Version 2.0. You may obtain a copy of this license at https://github.com/gsoft-inc/workleap-license/blob/master/LICENSE.
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { useAppRouterState } from './chunk-G32YX2KR.js';
|
|
2
2
|
import { useRuntimeNavigationItems } from '@squide/react-router';
|
|
3
3
|
|
|
4
|
-
function useNavigationItems() {
|
|
4
|
+
function useNavigationItems(options) {
|
|
5
5
|
useAppRouterState();
|
|
6
|
-
return useRuntimeNavigationItems();
|
|
6
|
+
return useRuntimeNavigationItems(options);
|
|
7
7
|
}
|
|
8
8
|
|
|
9
9
|
export { useNavigationItems };
|
package/dist/index.d.ts
CHANGED
|
@@ -14,7 +14,7 @@ export { useCanUpdateDeferredRegistrations } from './useCanUpdateDeferredRegistr
|
|
|
14
14
|
export { DeferredRegistrationsErrorCallback, DeferredRegistrationsErrorsObject, UseDeferredRegistrationsOptions, useDeferredRegistrations } from './useDeferredRegistrations.js';
|
|
15
15
|
export { useIsActiveRouteProtected } from './useIsActiveRouteProtected.js';
|
|
16
16
|
export { useIsBootstrapping } from './useIsBootstrapping.js';
|
|
17
|
-
export { useNavigationItems } from './useNavigationItems.js';
|
|
17
|
+
export { UseNavigationItemsOptions, useNavigationItems } from './useNavigationItems.js';
|
|
18
18
|
export { IsUnauthorizedErrorCallback, useProtectedDataQueries } from './useProtectedDataQueries.js';
|
|
19
19
|
export { usePublicDataQueries } from './usePublicDataQueries.js';
|
|
20
20
|
export { useRegisterDeferredRegistrations } from './useRegisterDeferredRegistrations.js';
|
package/dist/index.js
CHANGED
|
@@ -6,7 +6,7 @@ export { useUpdateDeferredRegistrations } from './chunk-N2GOIQ5E.js';
|
|
|
6
6
|
export { useCanRegisterDeferredRegistrations } from './chunk-PU7MASPN.js';
|
|
7
7
|
export { useCanUpdateDeferredRegistrations } from './chunk-WVRMJZV6.js';
|
|
8
8
|
export { useIsBootstrapping } from './chunk-I6L3AYOB.js';
|
|
9
|
-
export { useNavigationItems } from './chunk-
|
|
9
|
+
export { useNavigationItems } from './chunk-GXSW4CZS.js';
|
|
10
10
|
export { useProtectedDataQueries } from './chunk-RG5N56BQ.js';
|
|
11
11
|
export { AppRouter } from './chunk-36U4TTNR.js';
|
|
12
12
|
export { useStrictRegistrationMode } from './chunk-WOPD33CM.js';
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import * as _squide_react_router from '@squide/react-router';
|
|
2
|
+
import { UseRuntimeNavigationItemsOptions } from '@squide/react-router';
|
|
2
3
|
|
|
3
|
-
|
|
4
|
+
type UseNavigationItemsOptions = UseRuntimeNavigationItemsOptions;
|
|
5
|
+
declare function useNavigationItems(options?: UseNavigationItemsOptions): _squide_react_router.RootNavigationItem[];
|
|
4
6
|
|
|
5
|
-
export { useNavigationItems };
|
|
7
|
+
export { type UseNavigationItemsOptions, useNavigationItems };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { useNavigationItems } from './chunk-
|
|
1
|
+
export { useNavigationItems } from './chunk-GXSW4CZS.js';
|
|
2
2
|
import './chunk-G32YX2KR.js';
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@squide/firefly",
|
|
3
3
|
"author": "Workleap",
|
|
4
|
-
"version": "9.
|
|
4
|
+
"version": "9.1.0",
|
|
5
5
|
"description": "Helpers to facilitate the creation of an application with the Squide firefly technology stack.",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"repository": {
|
|
@@ -57,10 +57,10 @@
|
|
|
57
57
|
"typescript": "5.5.3"
|
|
58
58
|
},
|
|
59
59
|
"dependencies": {
|
|
60
|
-
"@squide/
|
|
61
|
-
"@squide/
|
|
62
|
-
"@squide/msw": "3.0.
|
|
63
|
-
"@squide/react-router": "6.
|
|
60
|
+
"@squide/module-federation": "6.0.2",
|
|
61
|
+
"@squide/core": "5.1.0",
|
|
62
|
+
"@squide/msw": "3.0.2",
|
|
63
|
+
"@squide/react-router": "6.1.0"
|
|
64
64
|
},
|
|
65
65
|
"sideEffects": false,
|
|
66
66
|
"engines": {
|