@ultimat3/admin
Advanced tools
+1
-0
@@ -37,2 +37,3 @@ # @ultimat3/admin — boundary | ||
| - Colours only via `ThemeTokenRef` (`--x-*`). Raw hex does not typecheck. | ||
| - **One owner of `globalThis.React`, and it is `@ultimat3/ui`'s.** `inert-jsx.ts` keeps the walkers (`nodesOf`, `shallowNodesOf`, `renderNodes`, `renderHtml`) and delegates install/restore to `probe`/`unprobe` from `@ultimat3/ui/jsx-probe` — tier 5 → tier 4, downward, no declared edge needed. It kept its own `depth`/`saved` pair until 2026-08-22 and two counters over one property restore in the wrong order: admin installs (saving the real binding), ui installs (saving ADMIN's factory), admin restores, ui restores admin's factory back over the top. `bun test` seats both packages in one process, so the interleave is reachable; `inert-jsx.test.ts` drives it in both orders. | ||
| - Views are pure functions of props — no `createSignal`, no local state; the route owns it. | ||
@@ -39,0 +40,0 @@ |
+16
-16
| { | ||
| "name": "@ultimat3/admin", | ||
| "version": "7.0.0", | ||
| "version": "8.0.0", | ||
| "description": "Two dashboards: the /_x framework dev panels and the generated, AI-first app admin", | ||
@@ -35,18 +35,18 @@ "license": "MIT", | ||
| "dependencies": { | ||
| "@ultimat3/action": "7.0.0", | ||
| "@ultimat3/ai": "7.0.0", | ||
| "@ultimat3/cache": "7.0.0", | ||
| "@ultimat3/core": "7.0.0", | ||
| "@ultimat3/db": "7.0.0", | ||
| "@ultimat3/entity": "7.0.0", | ||
| "@ultimat3/i18n": "7.0.0", | ||
| "@ultimat3/jobs": "7.0.0", | ||
| "@ultimat3/mcp": "7.0.0", | ||
| "@ultimat3/money": "7.0.0", | ||
| "@ultimat3/policy": "7.0.0", | ||
| "@ultimat3/query": "7.0.0", | ||
| "@ultimat3/render": "7.0.0", | ||
| "@ultimat3/schema": "7.0.0", | ||
| "@ultimat3/ui": "7.0.0" | ||
| "@ultimat3/action": "8.0.0", | ||
| "@ultimat3/ai": "8.0.0", | ||
| "@ultimat3/cache": "8.0.0", | ||
| "@ultimat3/core": "8.0.0", | ||
| "@ultimat3/db": "8.0.0", | ||
| "@ultimat3/entity": "8.0.0", | ||
| "@ultimat3/i18n": "8.0.0", | ||
| "@ultimat3/jobs": "8.0.0", | ||
| "@ultimat3/mcp": "8.0.0", | ||
| "@ultimat3/money": "8.0.0", | ||
| "@ultimat3/policy": "8.0.0", | ||
| "@ultimat3/query": "8.0.0", | ||
| "@ultimat3/render": "8.0.0", | ||
| "@ultimat3/schema": "8.0.0", | ||
| "@ultimat3/ui": "8.0.0" | ||
| } | ||
| } |
+21
-26
@@ -11,2 +11,6 @@ // TEST-ONLY. Calls an admin `.tsx` view as the plain function it is and walks what came back, so | ||
| // The subpath, never the barrel: this is a test harness and the design system's `index.ts` is its | ||
| // semver'd contract (`packages/ui/CLAUDE.md`). It is imported for `globalThis.React`'s ONE counter. | ||
| import { probe, unprobe } from '@ultimat3/ui/jsx-probe'; | ||
| /** `@ultimat3/render`'s node brand, read off the GLOBAL symbol registry rather than imported. */ | ||
@@ -27,3 +31,7 @@ const RENDER_NODE: symbol = Symbol.for('ultimate.render.jsx'); | ||
| /** The classic factory these `.tsx` files fall back to under `jsx: 'preserve'`. */ | ||
| /** | ||
| * Build a node by hand, the shape the installed factory builds. NOT the installed factory — that is | ||
| * `@ultimat3/ui`'s, so there is one owner of `globalThis.React` (see `installFactory` below). This | ||
| * is what a test uses to construct a tree it did not render. | ||
| */ | ||
| export function h( | ||
@@ -40,23 +48,15 @@ type: string | InertComponent, | ||
| /** | ||
| * How many installs are live, and what `globalThis.React` was before the first one. A harness that | ||
| * DELETED the property on the way out destroys a binding it did not create, and a nested install | ||
| * would tear the factory out from under the suite still using it — the counter is what makes the | ||
| * last restore the only one that acts. | ||
| * Install the classic-factory global, through `@ultimat3/ui`'s ONE counter over `globalThis.React`. | ||
| * | ||
| * This package kept its own `depth`/`saved` pair until 2026-08-22, and two counters over one | ||
| * property restore in the wrong order: admin installs (saving the real binding), ui installs | ||
| * (saving ADMIN's factory), admin restores (its counter hits 0 → the real binding is back), ui | ||
| * restores (its counter hits 0 → admin's factory goes back over it). `bun test` is one process and | ||
| * `packages/ui` and `packages/admin` are one run, so the interleave is reachable, and the global | ||
| * was left holding a harness the run had already torn down. `admin` is tier 5 and `ui` is tier 4, | ||
| * so importing down is the fix; the two factories build the same `{ inert, type, props }` shape, | ||
| * which is what `isInertNode` recognises. | ||
| */ | ||
| let depth = 0; | ||
| let saved: PropertyDescriptor | undefined; | ||
| export function installFactory(): void { | ||
| if (depth === 0) { | ||
| // The descriptor, not the value: the property may be a getter or non-writable, and `assign` | ||
| // onto either throws or silently loses. | ||
| saved = Object.getOwnPropertyDescriptor(globalThis, 'React'); | ||
| Object.defineProperty(globalThis, 'React', { | ||
| value: { createElement: h }, | ||
| configurable: true, | ||
| writable: true, | ||
| enumerable: true, | ||
| }); | ||
| } | ||
| depth += 1; | ||
| probe(); | ||
| } | ||
@@ -66,8 +66,3 @@ | ||
| export function restoreFactory(): void { | ||
| if (depth === 0) return; | ||
| depth -= 1; | ||
| if (depth > 0) return; | ||
| if (saved === undefined) Reflect.deleteProperty(globalThis, 'React'); | ||
| else Object.defineProperty(globalThis, 'React', saved); | ||
| saved = undefined; | ||
| unprobe(); | ||
| } | ||
@@ -74,0 +69,0 @@ |
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
297952
0.32%6354
-0.08%+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated
Updated