MCPcopy Index your code
hub / github.com/tinyplex/tinybase / AddCell

Function AddCell

src/ui-solid-inspector/index.tsx:432–449  ·  view source on GitHub ↗
(props: OnDoneProp & RowProps)

Source from the content-addressed store, hash-verified

430 });
431
432const AddCell = (props: OnDoneProp & RowProps) => {
433 const store = useStoreOrStoreById(props.store)();
434 const has = (cellId: Id) =>
435 store?.hasCell(props.tableId, props.rowId, cellId) ?? false;
436 return NewId({
437 onDone: props.onDone,
438 suggestedId: getNewIdFromSuggestedId('cell', has),
439 has,
440 set: useSetCellCallback(
441 props.tableId,
442 props.rowId,
443 (newId: Id) => newId,
444 () => '',
445 store,
446 ),
447 prompt: 'Add cell',
448 });
449};
450
451const CloneRow = (props: OnDoneProp & RowProps) => {
452 const store = useStoreOrStoreById(props.store)();

Callers

nothing calls this directly

Calls 4

useStoreOrStoreByIdFunction · 0.90
getNewIdFromSuggestedIdFunction · 0.90
useSetCellCallbackFunction · 0.90
NewIdFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…