@asteby/metacore-app-providers 0.6.4 → 2.0.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/README.md
CHANGED
|
@@ -1,14 +1,50 @@
|
|
|
1
1
|
# @asteby/metacore-app-providers
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Generic, reusable React providers for metacore host applications. One
|
|
4
|
+
package wires the cross-cutting concerns every metacore app shares —
|
|
5
|
+
direction, font, layout, search, platform branding — plus the optional
|
|
6
|
+
"full kit" `<MetacoreAppShell>` that bundles API + PWA + toaster in a
|
|
7
|
+
single tag.
|
|
4
8
|
|
|
5
|
-
##
|
|
9
|
+
## Stability
|
|
10
|
+
|
|
11
|
+
Stable as of v1.0. The exports below follow semver. Persistence keys
|
|
12
|
+
(cookie names, localStorage keys) and provider context shapes will not
|
|
13
|
+
change inside the major. Optional peer integrations (`@asteby/metacore-pwa`,
|
|
14
|
+
`@asteby/metacore-runtime-react`, `@asteby/metacore-ui`, `sonner`) move
|
|
15
|
+
on their own cadence — the shell tolerates compatible versions via the
|
|
16
|
+
peer ranges declared in `package.json`.
|
|
17
|
+
|
|
18
|
+
## Install
|
|
6
19
|
|
|
7
20
|
```bash
|
|
8
21
|
pnpm add @asteby/metacore-app-providers @radix-ui/react-direction
|
|
22
|
+
# transports / kits used by MetacoreAppShell + PlatformConfigProvider
|
|
23
|
+
pnpm add @tanstack/react-query sonner
|
|
24
|
+
# optional, only if you mount MetacoreAppShell:
|
|
25
|
+
pnpm add @asteby/metacore-pwa @asteby/metacore-runtime-react @asteby/metacore-ui
|
|
9
26
|
```
|
|
10
27
|
|
|
11
|
-
##
|
|
28
|
+
## Exports at a glance
|
|
29
|
+
|
|
30
|
+
| Export | Purpose |
|
|
31
|
+
|---|---|
|
|
32
|
+
| `DirectionProvider`, `useDirection` | LTR/RTL with cookie persistence (`dir`). |
|
|
33
|
+
| `FontProvider`, `useFont` | Font class on `<html>`, cookie-persisted (`font`). Requires `fonts` prop. |
|
|
34
|
+
| `LayoutProvider`, `useLayout` | Sidebar variant + collapsible mode. Cookies: `layout_variant`, `layout_collapsible`. |
|
|
35
|
+
| `SearchProvider`, `useSearch` | Cmd/Ctrl+K hotkey + `open`/`setOpen` for command palettes. |
|
|
36
|
+
| `PlatformConfigProvider`, `usePlatformConfig` | Tenant branding (name, logo, primary/accent color, support URLs) — transport-agnostic. |
|
|
37
|
+
| `applyBranding`, `applyCachedBranding` | Imperative helpers for pre-React paint and SW updates. |
|
|
38
|
+
| `FALLBACK_BRANDING` | Empty defaults consumers can spread over. |
|
|
39
|
+
| `MetacoreAppShell` | Full kit: ApiProvider + QueryClient + PWA + Toaster + addon-install bridge. |
|
|
40
|
+
| `getCookie`, `setCookie`, `removeCookie` | Tiny cookie helpers shared by the providers. |
|
|
41
|
+
|
|
42
|
+
Types: `Direction`, `Collapsible`, `Variant`, `FontProviderProps`,
|
|
43
|
+
`SearchProviderProps`, `PlatformBranding`, `BrandingFetcher`,
|
|
44
|
+
`PlatformConfigProviderProps`, `MetacoreAppShellProps`,
|
|
45
|
+
`MetacoreInstallRequest`.
|
|
46
|
+
|
|
47
|
+
## Basic providers
|
|
12
48
|
|
|
13
49
|
```tsx
|
|
14
50
|
import {
|
|
@@ -17,8 +53,7 @@ import {
|
|
|
17
53
|
LayoutProvider,
|
|
18
54
|
SearchProvider,
|
|
19
55
|
} from '@asteby/metacore-app-providers'
|
|
20
|
-
|
|
21
|
-
const fonts = ['inter', 'manrope', 'system'] as const
|
|
56
|
+
import { fonts } from '@asteby/metacore-starter-config/fonts'
|
|
22
57
|
|
|
23
58
|
<DirectionProvider>
|
|
24
59
|
<FontProvider fonts={fonts}>
|
|
@@ -31,11 +66,141 @@ const fonts = ['inter', 'manrope', 'system'] as const
|
|
|
31
66
|
</DirectionProvider>
|
|
32
67
|
```
|
|
33
68
|
|
|
34
|
-
|
|
69
|
+
- `FontProvider` requires `fonts` (the first entry is the default).
|
|
70
|
+
- `SearchProvider` accepts `hotkey` (default `'k'`, with Cmd/Ctrl). The
|
|
71
|
+
consumer renders the command menu using `useSearch().open` /
|
|
72
|
+
`setOpen()`.
|
|
73
|
+
- All four persist state in cookies so SSR/edge runtimes can restore the
|
|
74
|
+
initial frame.
|
|
75
|
+
|
|
76
|
+
## PlatformConfigProvider — tenant branding
|
|
77
|
+
|
|
78
|
+
Centralised branding for any metacore app. Apps fetch their tenant's
|
|
79
|
+
branding (name, logo, primary color, support URLs) from a backend
|
|
80
|
+
endpoint they own; this provider caches it, applies CSS variables
|
|
81
|
+
(`--primary`, `--background`, `--sidebar-*`, ...) to `<html>`, persists
|
|
82
|
+
the payload in `localStorage` so subsequent loads paint the right brand
|
|
83
|
+
**before** React mounts, and re-applies on dark/light toggles.
|
|
84
|
+
|
|
85
|
+
The provider is transport-agnostic: callers pass an async `fetcher`. No
|
|
86
|
+
HTTP client is hard-wired — any of axios / fetch / ofetch / hand-rolled
|
|
87
|
+
works.
|
|
88
|
+
|
|
89
|
+
```tsx
|
|
90
|
+
import {
|
|
91
|
+
PlatformConfigProvider,
|
|
92
|
+
applyCachedBranding,
|
|
93
|
+
type PlatformBranding,
|
|
94
|
+
} from '@asteby/metacore-app-providers'
|
|
95
|
+
import { api } from './lib/api'
|
|
96
|
+
|
|
97
|
+
// Paint the cached brand BEFORE React mounts.
|
|
98
|
+
applyCachedBranding()
|
|
99
|
+
|
|
100
|
+
const defaults: PlatformBranding = {
|
|
101
|
+
platform_name: 'Acme Hub',
|
|
102
|
+
platform_logo: '/logo.svg',
|
|
103
|
+
primary_color: '#84cc16',
|
|
104
|
+
accent_color: '#22d3ee',
|
|
105
|
+
favicon_url: '/favicon.ico',
|
|
106
|
+
support_email: 'support@acme.test',
|
|
107
|
+
support_url: 'https://acme.test/support',
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
<PlatformConfigProvider
|
|
111
|
+
fetcher={async () => (await api.get('/platform/branding')).data}
|
|
112
|
+
defaults={defaults}
|
|
113
|
+
>
|
|
114
|
+
<App />
|
|
115
|
+
</PlatformConfigProvider>
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
Inside the tree:
|
|
119
|
+
|
|
120
|
+
```tsx
|
|
121
|
+
const { platform_name, primary_color, refetch } = usePlatformConfig()
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
`refetch()` invalidates the query if the host knows the branding just
|
|
125
|
+
changed (e.g. after a settings save).
|
|
126
|
+
|
|
127
|
+
### Contract
|
|
128
|
+
|
|
129
|
+
- `fetcher` resolves to a `Partial<PlatformBranding>`. The provider merges
|
|
130
|
+
it over `defaults`, so missing fields fall back instead of blanking the
|
|
131
|
+
UI.
|
|
132
|
+
- Hex colors (`#rrggbb`) are converted to `oklch()` and pushed onto the
|
|
133
|
+
`<html>` element as CSS variables. The dark/light variant is derived
|
|
134
|
+
by reading `document.documentElement.classList`; the provider observes
|
|
135
|
+
class changes and re-applies on toggle.
|
|
136
|
+
- Persistence key is `platform-branding` in `localStorage`. Override via
|
|
137
|
+
`storageKey`. `applyCachedBranding(storageKey?)` is exported for hosts
|
|
138
|
+
that need a non-default key in their pre-React boot script.
|
|
139
|
+
- `staleTime` defaults to 5 minutes (TanStack Query). The provider keeps
|
|
140
|
+
one query per `storageKey`.
|
|
141
|
+
|
|
142
|
+
## MetacoreAppShell — the full kit
|
|
143
|
+
|
|
144
|
+
`<MetacoreAppShell>` wires every provider an app needs to run on the
|
|
145
|
+
metacore platform: API context, QueryClient, PWA install + update
|
|
146
|
+
prompts, offline indicator, sonner toaster, addon-install bridge for
|
|
147
|
+
embedded Hub iframes, and stale-while-revalidate metadata-cache
|
|
148
|
+
invalidation when a service-worker update is applied.
|
|
149
|
+
|
|
150
|
+
```tsx
|
|
151
|
+
import { MetacoreAppShell } from '@asteby/metacore-app-providers'
|
|
152
|
+
import { QueryClient } from '@tanstack/react-query'
|
|
153
|
+
import { api } from './lib/api'
|
|
154
|
+
|
|
155
|
+
const queryClient = new QueryClient()
|
|
156
|
+
|
|
157
|
+
<MetacoreAppShell api={api} queryClient={queryClient}>
|
|
158
|
+
<RouterProvider router={router} />
|
|
159
|
+
</MetacoreAppShell>
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
Optional flags (all default to enabled):
|
|
163
|
+
|
|
164
|
+
| Prop | Effect |
|
|
165
|
+
|---|---|
|
|
166
|
+
| `hideToaster` | Skip the bundled `<Toaster />`. |
|
|
167
|
+
| `hidePWAInstall` | Skip `<PWAInstallPrompt />`. |
|
|
168
|
+
| `hidePWAUpdate` | Skip `<PWAUpdatePrompt />`. |
|
|
169
|
+
| `hideOfflineIndicator` | Skip `<OfflineIndicator />`. |
|
|
170
|
+
| `disableMetadataInvalidate`| Don't drop the runtime metadata cache on SW update. |
|
|
171
|
+
| `onAddonInstall` | Custom handler for the `metacore:install` postMessage from an embedded Hub iframe. Set to `null` to disable the listener. |
|
|
172
|
+
| `toasterPosition` | `'top-right'` by default; passed through to sonner. |
|
|
173
|
+
|
|
174
|
+
The shell pulls peers (`@asteby/metacore-pwa`,
|
|
175
|
+
`@asteby/metacore-runtime-react`, `@asteby/metacore-ui`, `sonner`) when
|
|
176
|
+
mounted. Apps that only want a subset wire the individual providers and
|
|
177
|
+
skip the shell.
|
|
178
|
+
|
|
179
|
+
### Addon install bridge
|
|
180
|
+
|
|
181
|
+
When mounted inside (or alongside) the metacore Hub, the shell listens
|
|
182
|
+
for `window.postMessage({ type: 'metacore:install', addonKey, ... })`
|
|
183
|
+
events and either:
|
|
184
|
+
|
|
185
|
+
1. invokes `onAddonInstall(req, source)` if you supplied one, OR
|
|
186
|
+
2. POSTs `req` to `/marketplace/install` on the bundled API client.
|
|
187
|
+
|
|
188
|
+
On success it shows a sonner toast, drops the runtime metadata cache,
|
|
189
|
+
dispatches a `metacore:metadata-changed` `CustomEvent` on `window` (so
|
|
190
|
+
sidebars and command menus refetch without a reload), and replies to
|
|
191
|
+
the iframe with `metacore:installed`. On failure it replies with
|
|
192
|
+
`metacore:install-failed` and surfaces the error.
|
|
193
|
+
|
|
194
|
+
## Persistence summary
|
|
35
195
|
|
|
36
|
-
|
|
37
|
-
|
|
196
|
+
| Cookie / key | Owner |
|
|
197
|
+
|---|---|
|
|
198
|
+
| `dir` | `DirectionProvider` |
|
|
199
|
+
| `font` | `FontProvider` |
|
|
200
|
+
| `layout_variant` | `LayoutProvider` |
|
|
201
|
+
| `layout_collapsible` | `LayoutProvider` |
|
|
202
|
+
| `platform-branding` | `PlatformConfigProvider` (localStorage) |
|
|
38
203
|
|
|
39
|
-
##
|
|
204
|
+
## License
|
|
40
205
|
|
|
41
|
-
|
|
206
|
+
Apache-2.0
|
|
@@ -3,6 +3,10 @@ export interface MetacoreInstallRequest {
|
|
|
3
3
|
addonKey: string;
|
|
4
4
|
version?: string;
|
|
5
5
|
bundleURL?: string;
|
|
6
|
+
/** Display name already localised by the Hub at click time. */
|
|
7
|
+
name?: string;
|
|
8
|
+
/** Hub-supplied category bucket. */
|
|
9
|
+
category?: string;
|
|
6
10
|
}
|
|
7
11
|
export interface MetacoreAppShellProps {
|
|
8
12
|
/** Axios-compatible API client used by ApiProvider + PWAProvider. */
|
|
@@ -1 +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;AAa9B,MAAM,WAAW,sBAAsB;IACrC,QAAQ,EAAE,MAAM,CAAA;IAChB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,SAAS,CAAC,EAAE,MAAM,CAAA;
|
|
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;AAa9B,MAAM,WAAW,sBAAsB;IACrC,QAAQ,EAAE,MAAM,CAAA;IAChB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,+DAA+D;IAC/D,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,oCAAoC;IACpC,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB;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;AA4HD,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"}
|
|
@@ -48,6 +48,8 @@ function AddonInstallListener({ api, onAddonInstall, }) {
|
|
|
48
48
|
addonKey: data.addonKey,
|
|
49
49
|
version: data.version,
|
|
50
50
|
bundleURL: data.bundleURL,
|
|
51
|
+
name: data.name,
|
|
52
|
+
category: data.category,
|
|
51
53
|
};
|
|
52
54
|
// Surface the install in the host's toaster too so the user knows
|
|
53
55
|
// the click was heard even if the iframe loses focus.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"metacore-app-shell.js","sourceRoot":"","sources":["../src/metacore-app-shell.tsx"],"names":[],"mappings":";AAAA,0EAA0E;AAC1E,yEAAyE;AACzE,wEAAwE;AACxE,uEAAuE;AACvE,EAAE;AACF,qEAAqE;AACrE,EAAE;AACF,sEAAsE;AACtE,oCAAoC;AACpC,EAAE;AACF,qCAAqC;AACrC,6DAA6D;AAC7D,2CAA2C;AAC3C,0BAA0B;AAC1B,MAAM;AACN,EAAE;AACF,uEAAuE;AACvE,6EAA6E;AAC7E,4DAA4D;AAC5D,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAC3D,OAAO,EAAE,WAAW,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAA;AAC9E,OAAO,EACL,WAAW,EACX,gBAAgB,EAChB,eAAe,EACf,gBAAgB,EAChB,aAAa,GACd,MAAM,sBAAsB,CAAA;AAC7B,OAAO,EAAE,OAAO,EAAE,MAAM,gCAAgC,CAAA;AACxD,OAAO,EAAE,KAAK,EAAE,MAAM,QAAQ,CAAA;
|
|
1
|
+
{"version":3,"file":"metacore-app-shell.js","sourceRoot":"","sources":["../src/metacore-app-shell.tsx"],"names":[],"mappings":";AAAA,0EAA0E;AAC1E,yEAAyE;AACzE,wEAAwE;AACxE,uEAAuE;AACvE,EAAE;AACF,qEAAqE;AACrE,EAAE;AACF,sEAAsE;AACtE,oCAAoC;AACpC,EAAE;AACF,qCAAqC;AACrC,6DAA6D;AAC7D,2CAA2C;AAC3C,0BAA0B;AAC1B,MAAM;AACN,EAAE;AACF,uEAAuE;AACvE,6EAA6E;AAC7E,4DAA4D;AAC5D,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,C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,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": "2.0.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": {
|
|
@@ -27,8 +27,8 @@
|
|
|
27
27
|
"react": ">=18",
|
|
28
28
|
"react-dom": ">=18",
|
|
29
29
|
"@asteby/metacore-pwa": ">=0.3.1",
|
|
30
|
-
"@asteby/metacore-runtime-react": ">=
|
|
31
|
-
"@asteby/metacore-ui": ">=0.
|
|
30
|
+
"@asteby/metacore-runtime-react": ">=8.0.0",
|
|
31
|
+
"@asteby/metacore-ui": ">=2.0.0",
|
|
32
32
|
"sonner": ">=1.7"
|
|
33
33
|
},
|
|
34
34
|
"peerDependenciesMeta": {
|
|
@@ -52,8 +52,8 @@
|
|
|
52
52
|
"sonner": "^2.0.0",
|
|
53
53
|
"typescript": "^5.6.0",
|
|
54
54
|
"@asteby/metacore-pwa": "0.3.1",
|
|
55
|
-
"@asteby/metacore-
|
|
56
|
-
"@asteby/metacore-
|
|
55
|
+
"@asteby/metacore-runtime-react": "8.0.0",
|
|
56
|
+
"@asteby/metacore-ui": "2.0.0"
|
|
57
57
|
},
|
|
58
58
|
"publishConfig": {
|
|
59
59
|
"access": "public"
|