Plugins
Covers Engine Plugin SDK 2.0.0 · Interface Plugin SDK 0.2.0
IfElseBlock
Edit conditional branch configuration with the host component.
Import
import { IfElseBlock } from "@dartwic/interface-sdk/ui";Declaration
export const IfElseBlock: HostComponent<IfElseBlockProps>;IfElseBlockProps
Edits a conditional configuration block.
export interface IfElseBlockProps extends HostComponentProps {
initialData: Record<string, unknown>;
onDataChange: (data: Record<string, unknown>) => void;
compact?: boolean;
}| Prop | Type | Requirement | Description |
|---|---|---|---|
initialData | Record<string, unknown> | Required | |
onDataChange | (data: Record<string, unknown>) => void | Required | |
compact | boolean | Optional | |
className | string | Optional | Additional Tailwind or host CSS classes. |
children | HostNode | Optional | Child content rendered by the host component. |
id | string | Optional | Optional DOM identifier. |
style | Record<string, unknown> | Optional | Inline style values passed to the host component. |