Skip to content
This repository was archived by the owner on Nov 4, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions packages/types/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -76,9 +76,6 @@
"url": "https://github.com/objectstack-ai/objectui.git",
"directory": "packages/types"
},
"dependencies": {
"@objectstack/spec": "^0.1.1"
},
"devDependencies": {
"typescript": "^5.9.3"
}
Expand Down
26 changes: 14 additions & 12 deletions packages/types/src/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,9 @@
* @packageDocumentation
*/

import type { UIComponent } from '@objectstack/spec';

/**
* Base schema interface that all component schemas extend.
*
* This extends UIComponent from @objectstack/spec (the "highest law")
* and adds ObjectUI-specific rendering extensions like visibleOn, hiddenOn, etc.
*
* Inheritance Chain:
* UIComponent (@objectstack/spec) → BaseSchema → Specific Schemas (ChartSchema, etc.)
* This is the fundamental building block of the Object UI protocol.
*
* @example
* ```typescript
Expand All @@ -37,7 +30,19 @@ import type { UIComponent } from '@objectstack/spec';
* }
* ```
*/
export interface BaseSchema extends UIComponent {
export interface BaseSchema {
/**
* Component type identifier. Determines which renderer to use.
* @example 'input', 'button', 'form', 'grid'
*/
type: string;

/**
* Unique identifier for the component instance.
* Used for state management, event handling, and React keys.
*/
id?: string;

/**
* Human-readable name for the component.
* Used for form field names, labels, and debugging.
Expand Down Expand Up @@ -157,9 +162,6 @@ export interface BaseSchema extends UIComponent {
* A schema node can be a full schema object or a primitive value.
* This union type supports both structured components and simple content.
*
* Note: This uses BaseSchema (instead of UIComponent from spec) to provide
* ObjectUI-specific type narrowing and to include ObjectUI extensions in the type system.
*
* @example
* ```typescript
* const nodes: SchemaNode[] = [
Expand Down
10 changes: 0 additions & 10 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.