New workspace package that owns built-in node bundles, one folder per kind. Today the plugin is empty — no behavior change. Future commits will add column/, shelf/, wall/, etc. and append each definition to builtinPlugin.nodes. The package depends on core (registry types) at v1; viewer, editor, react, three are declared as peer deps so future node bundles can use them without bumping their own version on every monorepo bump. External plugins land as separate packages with the exact same shape — this package is the dogfooded reference. Tests: builtinPlugin shape + loadPlugin succeeds with zero kinds. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
19 lines
655 B
TypeScript
19 lines
655 B
TypeScript
import type { Plugin } from '@pascal-app/core'
|
|
|
|
/**
|
|
* Built-in plugin bundling every node kind shipped with the Pascal editor.
|
|
*
|
|
* Apps load this once at bootstrap (`loadPlugin(builtinPlugin)`) before
|
|
* mounting the viewer. New built-in nodes are added by creating a folder
|
|
* here under `src/<kind>/` and appending its `NodeDefinition` to `nodes`.
|
|
*
|
|
* External plugins follow the exact same shape — same `Plugin` type, same
|
|
* `loadPlugin` call path. This is intentional: the API is stress-tested
|
|
* by built-ins before any third-party plugin lands.
|
|
*/
|
|
export const builtinPlugin: Plugin = {
|
|
id: 'pascal:core',
|
|
apiVersion: 1,
|
|
nodes: [],
|
|
}
|