@asteby/metacore-app-providers 0.3.0 → 0.6.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/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/metacore-app-shell.d.ts +40 -0
- package/dist/metacore-app-shell.d.ts.map +1 -0
- package/dist/metacore-app-shell.js +110 -0
- package/dist/metacore-app-shell.js.map +1 -0
- package/package.json +20 -3
package/dist/index.d.ts
CHANGED
|
@@ -4,4 +4,5 @@ export { LayoutProvider, useLayout, type Collapsible, type Variant, } from './la
|
|
|
4
4
|
export { SearchProvider, useSearch, type SearchProviderProps } from './search-provider';
|
|
5
5
|
export { getCookie, setCookie, removeCookie } from './cookies';
|
|
6
6
|
export { PlatformConfigProvider, usePlatformConfig, applyBranding, applyCachedBranding, FALLBACK_BRANDING, type PlatformBranding, type BrandingFetcher, type PlatformConfigProviderProps, } from './platform-config-provider';
|
|
7
|
+
export { MetacoreAppShell, type MetacoreAppShellProps, } from './metacore-app-shell';
|
|
7
8
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,YAAY,EAAE,KAAK,SAAS,EAAE,MAAM,sBAAsB,CAAA;AACtF,OAAO,EAAE,YAAY,EAAE,OAAO,EAAE,KAAK,iBAAiB,EAAE,MAAM,iBAAiB,CAAA;AAC/E,OAAO,EACL,cAAc,EACd,SAAS,EACT,KAAK,WAAW,EAChB,KAAK,OAAO,GACb,MAAM,mBAAmB,CAAA;AAC1B,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,KAAK,mBAAmB,EAAE,MAAM,mBAAmB,CAAA;AACvF,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAC9D,OAAO,EACL,sBAAsB,EACtB,iBAAiB,EACjB,aAAa,EACb,mBAAmB,EACnB,iBAAiB,EACjB,KAAK,gBAAgB,EACrB,KAAK,eAAe,EACpB,KAAK,2BAA2B,GACjC,MAAM,4BAA4B,CAAA"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,YAAY,EAAE,KAAK,SAAS,EAAE,MAAM,sBAAsB,CAAA;AACtF,OAAO,EAAE,YAAY,EAAE,OAAO,EAAE,KAAK,iBAAiB,EAAE,MAAM,iBAAiB,CAAA;AAC/E,OAAO,EACL,cAAc,EACd,SAAS,EACT,KAAK,WAAW,EAChB,KAAK,OAAO,GACb,MAAM,mBAAmB,CAAA;AAC1B,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,KAAK,mBAAmB,EAAE,MAAM,mBAAmB,CAAA;AACvF,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAC9D,OAAO,EACL,sBAAsB,EACtB,iBAAiB,EACjB,aAAa,EACb,mBAAmB,EACnB,iBAAiB,EACjB,KAAK,gBAAgB,EACrB,KAAK,eAAe,EACpB,KAAK,2BAA2B,GACjC,MAAM,4BAA4B,CAAA;AACnC,OAAO,EACL,gBAAgB,EAChB,KAAK,qBAAqB,GAC3B,MAAM,sBAAsB,CAAA"}
|
package/dist/index.js
CHANGED
|
@@ -4,4 +4,5 @@ export { LayoutProvider, useLayout, } from './layout-provider';
|
|
|
4
4
|
export { SearchProvider, useSearch } from './search-provider';
|
|
5
5
|
export { getCookie, setCookie, removeCookie } from './cookies';
|
|
6
6
|
export { PlatformConfigProvider, usePlatformConfig, applyBranding, applyCachedBranding, FALLBACK_BRANDING, } from './platform-config-provider';
|
|
7
|
+
export { MetacoreAppShell, } from './metacore-app-shell';
|
|
7
8
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,YAAY,EAAkB,MAAM,sBAAsB,CAAA;AACtF,OAAO,EAAE,YAAY,EAAE,OAAO,EAA0B,MAAM,iBAAiB,CAAA;AAC/E,OAAO,EACL,cAAc,EACd,SAAS,GAGV,MAAM,mBAAmB,CAAA;AAC1B,OAAO,EAAE,cAAc,EAAE,SAAS,EAA4B,MAAM,mBAAmB,CAAA;AACvF,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAC9D,OAAO,EACL,sBAAsB,EACtB,iBAAiB,EACjB,aAAa,EACb,mBAAmB,EACnB,iBAAiB,GAIlB,MAAM,4BAA4B,CAAA"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,YAAY,EAAkB,MAAM,sBAAsB,CAAA;AACtF,OAAO,EAAE,YAAY,EAAE,OAAO,EAA0B,MAAM,iBAAiB,CAAA;AAC/E,OAAO,EACL,cAAc,EACd,SAAS,GAGV,MAAM,mBAAmB,CAAA;AAC1B,OAAO,EAAE,cAAc,EAAE,SAAS,EAA4B,MAAM,mBAAmB,CAAA;AACvF,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAC9D,OAAO,EACL,sBAAsB,EACtB,iBAAiB,EACjB,aAAa,EACb,mBAAmB,EACnB,iBAAiB,GAIlB,MAAM,4BAA4B,CAAA;AACnC,OAAO,EACL,gBAAgB,GAEjB,MAAM,sBAAsB,CAAA"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export interface MetacoreInstallRequest {
|
|
3
|
+
addonKey: string;
|
|
4
|
+
version?: string;
|
|
5
|
+
bundleURL?: string;
|
|
6
|
+
}
|
|
7
|
+
export interface MetacoreAppShellProps {
|
|
8
|
+
/** Axios-compatible API client used by ApiProvider + PWAProvider. */
|
|
9
|
+
api: any;
|
|
10
|
+
/** TanStack QueryClient instance. Optional — skipped if not supplied. */
|
|
11
|
+
queryClient?: any;
|
|
12
|
+
/** Hide the bundled <Toaster /> (e.g. when the app already mounts one). */
|
|
13
|
+
hideToaster?: boolean;
|
|
14
|
+
/** Hide the PWA install prompt button. */
|
|
15
|
+
hidePWAInstall?: boolean;
|
|
16
|
+
/** Hide the PWA update prompt button (banner that opens on a new SW). */
|
|
17
|
+
hidePWAUpdate?: boolean;
|
|
18
|
+
/** Hide the offline indicator. */
|
|
19
|
+
hideOfflineIndicator?: boolean;
|
|
20
|
+
/** Disable the metadata-cache invalidation that fires on SW updates. */
|
|
21
|
+
disableMetadataInvalidate?: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* Handle the `metacore:install` postMessage from an embedded Hub iframe.
|
|
24
|
+
* Receives the addon key + version + bundle URL; the host runs its own
|
|
25
|
+
* install pipeline (POST `/api/marketplace/install/<key>`, etc) and is
|
|
26
|
+
* responsible for messaging back to the iframe with `metacore:installed`
|
|
27
|
+
* once done. The MessageEventSource argument is the iframe's window —
|
|
28
|
+
* call `source.postMessage({type:'metacore:installed', addonKey})` to
|
|
29
|
+
* confirm.
|
|
30
|
+
*
|
|
31
|
+
* Default: POSTs `/marketplace/install` on the bundled API client and
|
|
32
|
+
* replies on success. Set to `null` to disable the listener entirely.
|
|
33
|
+
*/
|
|
34
|
+
onAddonInstall?: ((req: MetacoreInstallRequest, source: MessageEventSource | null) => void | Promise<void>) | null;
|
|
35
|
+
/** Toaster position; passed straight to sonner. */
|
|
36
|
+
toasterPosition?: 'top-left' | 'top-right' | 'top-center' | 'bottom-left' | 'bottom-right' | 'bottom-center';
|
|
37
|
+
children: React.ReactNode;
|
|
38
|
+
}
|
|
39
|
+
export declare function MetacoreAppShell({ api, queryClient, hideToaster, hidePWAInstall, hidePWAUpdate, hideOfflineIndicator, disableMetadataInvalidate, onAddonInstall, toasterPosition, children, }: MetacoreAppShellProps): import("react/jsx-runtime").JSX.Element;
|
|
40
|
+
//# sourceMappingURL=metacore-app-shell.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"metacore-app-shell.d.ts","sourceRoot":"","sources":["../src/metacore-app-shell.tsx"],"names":[],"mappings":"AAmBA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAY9B,MAAM,WAAW,sBAAsB;IACrC,QAAQ,EAAE,MAAM,CAAA;IAChB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,MAAM,WAAW,qBAAqB;IACpC,qEAAqE;IACrE,GAAG,EAAE,GAAG,CAAA;IACR,yEAAyE;IACzE,WAAW,CAAC,EAAE,GAAG,CAAA;IACjB,2EAA2E;IAC3E,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,0CAA0C;IAC1C,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,yEAAyE;IACzE,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,kCAAkC;IAClC,oBAAoB,CAAC,EAAE,OAAO,CAAA;IAC9B,wEAAwE;IACxE,yBAAyB,CAAC,EAAE,OAAO,CAAA;IACnC;;;;;;;;;;;OAWG;IACH,cAAc,CAAC,EACX,CAAC,CAAC,GAAG,EAAE,sBAAsB,EAAE,MAAM,EAAE,kBAAkB,GAAG,IAAI,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,GAC1F,IAAI,CAAA;IACR,mDAAmD;IACnD,eAAe,CAAC,EACZ,UAAU,GACV,WAAW,GACX,YAAY,GACZ,aAAa,GACb,cAAc,GACd,eAAe,CAAA;IACnB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;CAC1B;AAoFD,wBAAgB,gBAAgB,CAAC,EAC/B,GAAG,EACH,WAAW,EACX,WAAW,EACX,cAAc,EACd,aAAa,EACb,oBAAoB,EACpB,yBAAyB,EACzB,cAAc,EACd,eAA6B,EAC7B,QAAQ,GACT,EAAE,qBAAqB,2CAqBvB"}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
// MetacoreAppShell — single-line wiring of every provider an app needs to
|
|
3
|
+
// run on the metacore platform: API context, query client, PWA install +
|
|
4
|
+
// update prompts, offline indicator, toasts, and stale-while-revalidate
|
|
5
|
+
// metadata cache invalidation when a service-worker update is applied.
|
|
6
|
+
//
|
|
7
|
+
// Apps mount it once and forget about the wedding-cake of providers:
|
|
8
|
+
//
|
|
9
|
+
// import { MetacoreAppShell } from '@asteby/metacore-app-providers'
|
|
10
|
+
// import { api } from './lib/api'
|
|
11
|
+
//
|
|
12
|
+
// ReactDOM.createRoot(...).render(
|
|
13
|
+
// <MetacoreAppShell api={api} queryClient={queryClient}>
|
|
14
|
+
// <RouterProvider router={router} />
|
|
15
|
+
// </MetacoreAppShell>
|
|
16
|
+
// )
|
|
17
|
+
//
|
|
18
|
+
// Peer deps (`@asteby/metacore-pwa`, `@asteby/metacore-runtime-react`,
|
|
19
|
+
// `@asteby/metacore-ui`) are required — the shell is the full kit. Apps that
|
|
20
|
+
// want a subset wire providers directly and skip the shell.
|
|
21
|
+
import * as React from 'react';
|
|
22
|
+
import { QueryClientProvider } from '@tanstack/react-query';
|
|
23
|
+
import { ApiProvider, useMetadataCache } from '@asteby/metacore-runtime-react';
|
|
24
|
+
import { PWAProvider, PWAInstallPrompt, PWAUpdatePrompt, OfflineIndicator, usePWAContext, } from '@asteby/metacore-pwa';
|
|
25
|
+
import { Toaster } from '@asteby/metacore-ui/primitives';
|
|
26
|
+
/**
|
|
27
|
+
* Drops every cached table/modal metadata entry the moment the PWA layer
|
|
28
|
+
* tells us a new service worker has finished installing. The next mount of
|
|
29
|
+
* <DynamicTable> hits the network instead of replaying yesterday's
|
|
30
|
+
* column / filter / actions definitions.
|
|
31
|
+
*/
|
|
32
|
+
/**
|
|
33
|
+
* Listens for the `metacore:install` postMessage from an embedded Hub
|
|
34
|
+
* iframe and forwards to the supplied handler (or the default backend
|
|
35
|
+
* call). Confirms back to the iframe with `metacore:installed` so the
|
|
36
|
+
* Hub UI flips to the success state.
|
|
37
|
+
*/
|
|
38
|
+
function AddonInstallListener({ api, onAddonInstall, }) {
|
|
39
|
+
React.useEffect(() => {
|
|
40
|
+
if (onAddonInstall === null)
|
|
41
|
+
return;
|
|
42
|
+
const handler = async (e) => {
|
|
43
|
+
const data = e.data;
|
|
44
|
+
if (!data || data.type !== 'metacore:install' || !data.addonKey)
|
|
45
|
+
return;
|
|
46
|
+
const req = {
|
|
47
|
+
addonKey: data.addonKey,
|
|
48
|
+
version: data.version,
|
|
49
|
+
bundleURL: data.bundleURL,
|
|
50
|
+
};
|
|
51
|
+
try {
|
|
52
|
+
if (onAddonInstall) {
|
|
53
|
+
await onAddonInstall(req, e.source);
|
|
54
|
+
}
|
|
55
|
+
else {
|
|
56
|
+
// Default pipeline: POST to the host's marketplace install
|
|
57
|
+
// endpoint. Apps that don't ship that endpoint should pass an
|
|
58
|
+
// explicit `onAddonInstall` handler.
|
|
59
|
+
await api.post('/marketplace/install', req);
|
|
60
|
+
}
|
|
61
|
+
e.source?.postMessage({ type: 'metacore:installed', addonKey: req.addonKey }, { targetOrigin: '*' });
|
|
62
|
+
}
|
|
63
|
+
catch (err) {
|
|
64
|
+
e.source?.postMessage({
|
|
65
|
+
type: 'metacore:install-failed',
|
|
66
|
+
addonKey: req.addonKey,
|
|
67
|
+
error: err instanceof Error ? err.message : String(err),
|
|
68
|
+
}, { targetOrigin: '*' });
|
|
69
|
+
}
|
|
70
|
+
};
|
|
71
|
+
window.addEventListener('message', handler);
|
|
72
|
+
return () => window.removeEventListener('message', handler);
|
|
73
|
+
}, [api, onAddonInstall]);
|
|
74
|
+
return null;
|
|
75
|
+
}
|
|
76
|
+
function MetadataInvalidator({ disabled }) {
|
|
77
|
+
const { needRefresh } = usePWAContext();
|
|
78
|
+
React.useEffect(() => {
|
|
79
|
+
if (disabled)
|
|
80
|
+
return;
|
|
81
|
+
if (!needRefresh)
|
|
82
|
+
return;
|
|
83
|
+
try {
|
|
84
|
+
const state = useMetadataCache.getState();
|
|
85
|
+
if (state?.cache) {
|
|
86
|
+
for (const key of Object.keys(state.cache))
|
|
87
|
+
delete state.cache[key];
|
|
88
|
+
}
|
|
89
|
+
if (state?.modalCache) {
|
|
90
|
+
for (const key of Object.keys(state.modalCache))
|
|
91
|
+
delete state.modalCache[key];
|
|
92
|
+
}
|
|
93
|
+
if (typeof state?.set === 'function') {
|
|
94
|
+
state.set({ prefetched: false });
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
catch {
|
|
98
|
+
/* best-effort */
|
|
99
|
+
}
|
|
100
|
+
}, [disabled, needRefresh]);
|
|
101
|
+
return null;
|
|
102
|
+
}
|
|
103
|
+
export function MetacoreAppShell({ api, queryClient, hideToaster, hidePWAInstall, hidePWAUpdate, hideOfflineIndicator, disableMetadataInvalidate, onAddonInstall, toasterPosition = 'top-right', children, }) {
|
|
104
|
+
const inner = (_jsxs(ApiProvider, { client: api, children: [_jsxs(PWAProvider, { api: api, children: [children, _jsx(MetadataInvalidator, { disabled: !!disableMetadataInvalidate }), _jsx(AddonInstallListener, { api: api, onAddonInstall: onAddonInstall }), !hidePWAInstall && _jsx(PWAInstallPrompt, {}), !hidePWAUpdate && _jsx(PWAUpdatePrompt, {}), !hideOfflineIndicator && _jsx(OfflineIndicator, {})] }), !hideToaster && (_jsx(Toaster, { position: toasterPosition, richColors: true, theme: 'light' }))] }));
|
|
105
|
+
if (queryClient) {
|
|
106
|
+
return _jsx(QueryClientProvider, { client: queryClient, children: inner });
|
|
107
|
+
}
|
|
108
|
+
return inner;
|
|
109
|
+
}
|
|
110
|
+
//# sourceMappingURL=metacore-app-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ACvC,CAAC,aAAa,IAAI,KAAC,eAAe,KAAG,EACrC,CAAC,oBAAoB,IAAI,KAAC,gBAAgB,KAAG,IAClC,EACb,CAAC,WAAW,IAAI,CACf,KAAC,OAAO,IAAC,QAAQ,EAAE,eAAe,EAAE,UAAU,QAAC,KAAK,EAAC,OAAO,GAAG,CAChE,IACW,CACf,CAAA;IAED,IAAI,WAAW,EAAE,CAAC;QAChB,OAAO,KAAC,mBAAmB,IAAC,MAAM,EAAE,WAAW,YAAG,KAAK,GAAuB,CAAA;IAChF,CAAC;IACD,OAAO,KAAK,CAAA;AACd,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@asteby/metacore-app-providers",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"description": "Providers genéricos reutilizables para apps metacore (direction, font, layout, search, platform-config)",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -25,7 +25,21 @@
|
|
|
25
25
|
"@radix-ui/react-direction": "^1.1.0",
|
|
26
26
|
"@tanstack/react-query": ">=5",
|
|
27
27
|
"react": ">=18",
|
|
28
|
-
"react-dom": ">=18"
|
|
28
|
+
"react-dom": ">=18",
|
|
29
|
+
"@asteby/metacore-pwa": ">=0.3.1",
|
|
30
|
+
"@asteby/metacore-runtime-react": ">=7.1.5",
|
|
31
|
+
"@asteby/metacore-ui": ">=0.7"
|
|
32
|
+
},
|
|
33
|
+
"peerDependenciesMeta": {
|
|
34
|
+
"@asteby/metacore-pwa": {
|
|
35
|
+
"optional": true
|
|
36
|
+
},
|
|
37
|
+
"@asteby/metacore-runtime-react": {
|
|
38
|
+
"optional": true
|
|
39
|
+
},
|
|
40
|
+
"@asteby/metacore-ui": {
|
|
41
|
+
"optional": true
|
|
42
|
+
}
|
|
29
43
|
},
|
|
30
44
|
"devDependencies": {
|
|
31
45
|
"@radix-ui/react-direction": "^1.1.1",
|
|
@@ -34,7 +48,10 @@
|
|
|
34
48
|
"@types/react-dom": "^19.0.0",
|
|
35
49
|
"react": "^19.2.4",
|
|
36
50
|
"react-dom": "^19.2.4",
|
|
37
|
-
"typescript": "^5.6.0"
|
|
51
|
+
"typescript": "^5.6.0",
|
|
52
|
+
"@asteby/metacore-runtime-react": "7.1.5",
|
|
53
|
+
"@asteby/metacore-ui": "0.7.0",
|
|
54
|
+
"@asteby/metacore-pwa": "0.3.1"
|
|
38
55
|
},
|
|
39
56
|
"publishConfig": {
|
|
40
57
|
"access": "public"
|