Skip to content
Sheetwrite

Sheetwrite / Documentation

SheetwriteGridProps@sheetwrite/svelte

Advanced Svelte adapter props with inferred host row identity.

Advanced Svelte adapter props with inferred host row identity.

Members 39

workbook Live workbook schema adopted by the Grid.
workbook: GridOptions["workbook"];
data Eager values for the active sheet.
data?: GridOptions["data"];
rowBridge Optional canonical-to-host row projection.
rowBridge?: RowBridge<Id>;
datasource Lazy visible-row provider.
datasource?: GridOptions["datasource"];
datasourceStorage Datasource storage policy.
datasourceStorage?: GridOptions["datasourceStorage"];
renderer Canvas or worker paint backend.
renderer?: GridOptions["renderer"];
workerUrl Browser-fetchable worker module URL.
workerUrl?: GridOptions["workerUrl"];
presentation Positional spreadsheet or semantic data-grid headers.
presentation?: GridOptions["presentation"];
theme Live resolved-theme overrides.
theme?: GridOptions["theme"];
readOnly Disables mutations, not navigation.
readOnly?: GridOptions["readOnly"];
protectionResolver Client protected-range check.
protectionResolver?: GridOptions["protectionResolver"];
mutationPolicy Atomic or partial denial policy.
mutationPolicy?: GridOptions["mutationPolicy"];
transactionResourceLimits Overrides inclusive operation-count and encoded-byte ceilings for every atomic mutation.
transactionResourceLimits?: GridOptions["transactionResourceLimits"];
renderers Named custom cell renderers.
renderers?: GridOptions["renderers"];
editors Named custom cell editors.
editors?: GridOptions["editors"];
overscan Extra rows painted around the viewport.
overscan?: GridOptions["overscan"];
minColumns Minimum column count with padding.
minColumns?: GridOptions["minColumns"];
config Built-in UI control configuration.
config?: GridOptions["config"];
height Host height as pixels or a CSS length.
height?: number | string;
fill Fills the parent's available size.
fill?: true;
fallback Content shown until initialization succeeds.
fallback?: Snippet;
grid Bindable live Grid, cleared on reset or unmount.
grid?: Grid;
onGridChange Receives every committed Grid change, including its applied transaction.
onGridChange?: (event: ChangeEvent) => void;
onRowDelta Receives projected host-row effects when a row bridge is attached.
onRowDelta?: RowBridgeHandler<Id>;
onSelectionChange Receives the current selection, or null after it is cleared.
onSelectionChange?: (selection: Selection | null) => void;
onViewportChange Receives visible row bounds and vertical scroll offset after scrolling.
onViewportChange?: (event: GridEvents["scroll"]) => void;
onEditBegin Fires when cell editing begins.
onEditBegin?: (event: GridEvents["edit-begin"]) => void;
onEditCommit Fires after an edit commits its parsed cell value.
onEditCommit?: (event: GridEvents["edit-commit"]) => void;
onActiveSheetChange Fires after the visible sheet changes.
onActiveSheetChange?: (event: GridEvents["active-sheet"]) => void;
onCommandStateChange Receives observable undo/redo and formatting command state.
onCommandStateChange?: (event: GridEvents["command-state-change"]) => void;
onMutationRejected Receives structured issues when a Grid mutation is rejected.
onMutationRejected?: (event: GridEvents["mutation-rejected"]) => void;
onRendererFallback Fires when worker rendering falls back to the main-thread canvas renderer.
onRendererFallback?: (event: GridEvents["renderer-fallback"]) => void;
onDatasourceError Receives failed datasource requests and their errors.
onDatasourceError?: (event: GridEvents["datasource-error"]) => void;
onExportError Receives failures from built-in XLSX export actions.
onExportError?: (event: GridEvents["export-error"]) => void;
onReady Fires after the adapter publishes a ready Grid generation.
onReady?: (event: GridReadyEvent) => void;
onInitializationError Receives a WASM initialization failure while the adapter remains mounted.
onInitializationError?: (error: SheetwriteError) => void;
wasmSource Explicit source passed to process-wide WASM initialization; concurrent initialization is first-source-wins.
wasmSource?: BufferSource | URL | string | Request | WebAssembly.Module;

Declaration

View full TypeScript declaration
export interface SheetwriteGridProps<
Id extends RowBridgeId = RowBridgeId,
> extends Omit<
HTMLAttributes<HTMLDivElement>,
keyof GridAdapterEventHandlers<Id> | "children"
> {
workbook: GridOptions["workbook"];
data?: GridOptions["data"];
rowBridge?: RowBridge<Id>;
datasource?: GridOptions["datasource"];
datasourceStorage?: GridOptions["datasourceStorage"];
renderer?: GridOptions["renderer"];
workerUrl?: GridOptions["workerUrl"];
presentation?: GridOptions["presentation"];
theme?: GridOptions["theme"];
readOnly?: GridOptions["readOnly"];
protectionResolver?: GridOptions["protectionResolver"];
mutationPolicy?: GridOptions["mutationPolicy"];
transactionResourceLimits?: GridOptions["transactionResourceLimits"];
hyperlinkActivation?: GridOptions["hyperlinkActivation"];
renderers?: GridOptions["renderers"];
editors?: GridOptions["editors"];
overscan?: GridOptions["overscan"];
minColumns?: GridOptions["minColumns"];
config?: GridOptions["config"];
height?: number | string;
fill?: true;
fallback?: Snippet;
grid?: Grid;
onGridChange?: (event: ChangeEvent) => void;
onRowDelta?: RowBridgeHandler<Id>;
onSelectionChange?: (selection: Selection | null) => void;
onViewportChange?: (event: GridEvents["scroll"]) => void;
onEditBegin?: (event: GridEvents["edit-begin"]) => void;
onEditCommit?: (event: GridEvents["edit-commit"]) => void;
onSearch?: (result: GridEvents["search"]) => void;
onActiveSheetChange?: (event: GridEvents["active-sheet"]) => void;
onCommandStateChange?: (event: GridEvents["command-state-change"]) => void;
onMutationRejected?: (event: GridEvents["mutation-rejected"]) => void;
onRendererFallback?: (event: GridEvents["renderer-fallback"]) => void;
onDatasourceError?: (event: GridEvents["datasource-error"]) => void;
onExportError?: (event: GridEvents["export-error"]) => void;
onReady?: (event: GridReadyEvent) => void;
onInitializationError?: (error: SheetwriteError) => void;
wasmSource?: BufferSource | URL | string | Request | WebAssembly.Module;
}