@revisium/schema-toolkit-ui 0.5.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/README.md CHANGED
@@ -154,7 +154,7 @@ import type { ITableDataSource } from '@revisium/schema-toolkit-ui';
154
154
 
155
155
  const dataSource: ITableDataSource = {
156
156
  async fetchMetadata() {
157
- // Return { schema, columns, viewState, readonly }
157
+ // Return { schema, columns, viewState, readonly, refSchemas? }
158
158
  },
159
159
  async fetchRows(query) {
160
160
  // query: { where, orderBy, search, first, after }
@@ -168,7 +168,7 @@ const dataSource: ITableDataSource = {
168
168
  // Return { ok, error? }
169
169
  },
170
170
  async saveView(viewState) {
171
- // Persist column/filter/sort/search settings
171
+ // Persist column order, widths, pins, and sort settings
172
172
  // Return { ok, error? }
173
173
  },
174
174
  };
@@ -241,6 +241,7 @@ All callbacks are optional and passed via `TableEditorOptions.callbacks`:
241
241
  | `onUploadFile` | `(params: { rowId: string; fileId: string; file: File }) => Promise<Record<string, unknown> \| null>` | Upload a file for a file field |
242
242
  | `onOpenFile` | `(url: string) => void` | Open/preview a file URL |
243
243
  | `onCopyPath` | `(path: string) => void` | Copy JSON path to clipboard |
244
+ | `onReadonlyEditAttempt` | `() => void` | Called when the user tries to edit a read-only cell (double-click, Enter, typing). Use this to show a toast/notification. Throttled internally (2 s). |
244
245
 
245
246
  In read-only mode (`fetchMetadata` returns `readonly: true`), delete and duplicate actions are hidden automatically. Open row still works.
246
247