@venizia/ardor-admin 0.4.8-6 → 0.4.8-8
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/dist/common/types.d.ts
CHANGED
|
@@ -99,8 +99,8 @@ export interface IApplication extends Omit<CoreAdminProps, 'children'> {
|
|
|
99
99
|
* (IGNIS's, so a provider registered with `LoggerFactory.use` is the one behind it).
|
|
100
100
|
*/
|
|
101
101
|
logger?: ILogger;
|
|
102
|
-
/** The store the Redux provider of the shell serves. */
|
|
103
|
-
reduxStore
|
|
102
|
+
/** The store the Redux provider of the shell serves. Absent, the shell mounts no Redux provider. */
|
|
103
|
+
reduxStore?: Store;
|
|
104
104
|
/** Rendered as the `Suspense` fallback and while feature messages for the locale load. */
|
|
105
105
|
suspense: ReactNode;
|
|
106
106
|
/** The application's own resources; each feature's are mounted after them. */
|
|
@@ -3,9 +3,10 @@ import type { IApplication } from '../common/types.js';
|
|
|
3
3
|
/**
|
|
4
4
|
* The application shell. It resolves the data, auth and i18n providers from `container`, mounts the
|
|
5
5
|
* `resources` and `routes` of the application and of each feature inside react-admin, and wraps it
|
|
6
|
-
* all in `ApplicationContext.Provider` (`container`, `logger`), the Redux provider
|
|
7
|
-
* While a feature's lazy messages for the current locale
|
|
8
|
-
* react-admin; a failed load is thrown from render. Remaining
|
|
6
|
+
* all in `ApplicationContext.Provider` (`container`, `logger`), the Redux provider (only when
|
|
7
|
+
* `reduxStore` is passed) and `Suspense`. While a feature's lazy messages for the current locale
|
|
8
|
+
* load, it renders `suspense` instead of react-admin; a failed load is thrown from render. Remaining
|
|
9
|
+
* props go to react-admin's `CoreAdmin`.
|
|
9
10
|
*/
|
|
10
11
|
export declare const ArdorApplication: React.FC<IApplication>;
|
|
11
12
|
//# sourceMappingURL=application.d.ts.map
|
|
@@ -14,7 +14,8 @@ const Wrapper = ({ applicationName = 'ArdorApplication', container, reduxStore,
|
|
|
14
14
|
const applicationLogger = React.useMemo(() => {
|
|
15
15
|
return logger ?? LoggerFactory.getLogger([applicationName]);
|
|
16
16
|
}, [logger, applicationName]);
|
|
17
|
-
|
|
17
|
+
const content = _jsx(React.Suspense, { fallback: suspense, children: children });
|
|
18
|
+
return (_jsx(ApplicationContext.Provider, { value: { container, logger: applicationLogger }, children: reduxStore ? _jsx(ReduxProvider, { store: reduxStore, children: content }) : content }));
|
|
18
19
|
};
|
|
19
20
|
/**
|
|
20
21
|
* The i18n provider is built with the initial locale's eager messages only; when a feature loads
|
|
@@ -54,9 +55,10 @@ const useFeatureMessagesReady = (opts) => {
|
|
|
54
55
|
/**
|
|
55
56
|
* The application shell. It resolves the data, auth and i18n providers from `container`, mounts the
|
|
56
57
|
* `resources` and `routes` of the application and of each feature inside react-admin, and wraps it
|
|
57
|
-
* all in `ApplicationContext.Provider` (`container`, `logger`), the Redux provider
|
|
58
|
-
* While a feature's lazy messages for the current locale
|
|
59
|
-
* react-admin; a failed load is thrown from render. Remaining
|
|
58
|
+
* all in `ApplicationContext.Provider` (`container`, `logger`), the Redux provider (only when
|
|
59
|
+
* `reduxStore` is passed) and `Suspense`. While a feature's lazy messages for the current locale
|
|
60
|
+
* load, it renders `suspense` instead of react-admin; a failed load is thrown from render. Remaining
|
|
61
|
+
* props go to react-admin's `CoreAdmin`.
|
|
60
62
|
*/
|
|
61
63
|
export const ArdorApplication = (props) => {
|
|
62
64
|
const { container, reduxStore, suspense, logger, resources, routes, features: selected, ...reactAdminProps } = props;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@venizia/ardor-admin",
|
|
3
|
-
"version": "0.4.8-
|
|
3
|
+
"version": "0.4.8-8",
|
|
4
4
|
"description": "ARDOR react-admin adapter - the REST data provider, auth provider and i18n provider wired through IGNIS inversion, the ArdorApplication root component, the translate and notify hooks, and the English and Vietnamese message bundles.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"admin",
|
|
@@ -61,8 +61,8 @@
|
|
|
61
61
|
"prepublishOnly": "make rebuild"
|
|
62
62
|
},
|
|
63
63
|
"dependencies": {
|
|
64
|
-
"@venizia/ardor-kernel": "0.4.8-
|
|
65
|
-
"@venizia/ardor-react": "0.4.8-
|
|
64
|
+
"@venizia/ardor-kernel": "0.4.8-8",
|
|
65
|
+
"@venizia/ardor-react": "0.4.8-8"
|
|
66
66
|
},
|
|
67
67
|
"devDependencies": {
|
|
68
68
|
"@happy-dom/global-registrator": "^21.0.4",
|
|
@@ -72,11 +72,11 @@
|
|
|
72
72
|
"@testing-library/react": "^16.3.3",
|
|
73
73
|
"@types/bun": "^1.4.3",
|
|
74
74
|
"@types/react": "^19",
|
|
75
|
-
"@venizia/dev-configs": "^0.4.8-
|
|
76
|
-
"@venizia/ignis-filter": "^0.4.7-
|
|
77
|
-
"@venizia/ignis-helpers": "^0.4.8-
|
|
78
|
-
"@venizia/ignis-inversion": "^0.4.7-
|
|
79
|
-
"@venizia/ignis-kernel": "^0.4.8-
|
|
75
|
+
"@venizia/dev-configs": "^0.4.8-4",
|
|
76
|
+
"@venizia/ignis-filter": "^0.4.7-4",
|
|
77
|
+
"@venizia/ignis-helpers": "^0.4.8-7",
|
|
78
|
+
"@venizia/ignis-inversion": "^0.4.7-3",
|
|
79
|
+
"@venizia/ignis-kernel": "^0.4.8-7",
|
|
80
80
|
"eslint": "^10.13.0",
|
|
81
81
|
"oxlint": "1.89.0",
|
|
82
82
|
"oxlint-tsgolint": "7.0.2004",
|
|
@@ -94,10 +94,10 @@
|
|
|
94
94
|
"peerDependencies": {
|
|
95
95
|
"@reduxjs/toolkit": ">=2.13.0",
|
|
96
96
|
"@tanstack/react-query": ">=5.104.5",
|
|
97
|
-
"@venizia/ignis-filter": "^0.4.7-
|
|
98
|
-
"@venizia/ignis-helpers": "^0.4.8-
|
|
99
|
-
"@venizia/ignis-inversion": "^0.4.7-
|
|
100
|
-
"@venizia/ignis-kernel": "^0.4.8-
|
|
97
|
+
"@venizia/ignis-filter": "^0.4.7-4",
|
|
98
|
+
"@venizia/ignis-helpers": "^0.4.8-7",
|
|
99
|
+
"@venizia/ignis-inversion": "^0.4.7-3",
|
|
100
|
+
"@venizia/ignis-kernel": "^0.4.8-7",
|
|
101
101
|
"ra-core": ">=5.15.5",
|
|
102
102
|
"ra-i18n-polyglot": ">=5.15.5",
|
|
103
103
|
"react": ">=19.3.1",
|