Skip to main content

@dialstack/sdk-dev / react/src/dial-plan / DialPlanProps

Interface: DialPlanProps

Defined in: sdk/react/src/react/DialPlan.tsx:73

Properties​

className?​

TypeScript
optional className?: string;

Defined in: sdk/react/src/react/DialPlan.tsx:97

Optional CSS class name for the container


dialPlanId?​

TypeScript
optional dialPlanId?: string;

Defined in: sdk/react/src/react/DialPlan.tsx:75

The ID of the dial plan to fetch and display


locale?​

TypeScript
optional locale?: DialPlanLocale;

Defined in: sdk/react/src/react/DialPlan.tsx:79

Locale strings for node labels and exits


mode?​

TypeScript
optional mode?: DialPlanMode;

Defined in: sdk/react/src/react/DialPlan.tsx:77

Display mode: 'view' (default), 'edit', or 'preview' (static thumbnail)


onCreateResource?​

TypeScript
optional onCreateResource?: (type, options?) => Promise<
| {
extension_number?: string;
id: string;
name: string;
}
| undefined>;

Defined in: sdk/react/src/react/DialPlan.tsx:106

Optional callback to create a new resource from a config panel select. Provided by the host app. options carries per-type hints (currently notifyEligible for voice apps) so the create dialog can skip choices incompatible with the current edit context.

Parameters​

type​

ResourceType

options?​

ListResourcesOptions

Returns​

Promise< | { extension_number?: string; id: string; name: string; } | undefined>


onDirtyChange?​

TypeScript
optional onDirtyChange?: (isDirty) => void;

Defined in: sdk/react/src/react/DialPlan.tsx:91

Callback fired when dirty state changes (edit mode)

Parameters​

isDirty​

boolean

Returns​

void


onError?​

TypeScript
optional onError?: (error) => void;

Defined in: sdk/react/src/react/DialPlan.tsx:93

Alias for onLoadError, used in edit mode

Parameters​

error​

Error

Returns​

void


onLoaderEnd?​

TypeScript
optional onLoaderEnd?: (dialPlan) => void;

Defined in: sdk/react/src/react/DialPlan.tsx:85

Callback fired when the dial plan finishes loading

Parameters​

dialPlan​

DialPlan

Returns​

void


onLoadError?​

TypeScript
optional onLoadError?: (error) => void;

Defined in: sdk/react/src/react/DialPlan.tsx:87

Callback fired when there's an error

Parameters​

error​

Error

Returns​

void


onLoaderStart?​

TypeScript
optional onLoaderStart?: () => void;

Defined in: sdk/react/src/react/DialPlan.tsx:83

Callback fired when the dial plan starts loading

Returns​

void


onNodeClick?​

TypeScript
optional onNodeClick?: (nodeId, node) => void;

Defined in: sdk/react/src/react/DialPlan.tsx:81

Callback fired when a node is clicked (view mode)

Parameters​

nodeId​

string

node​

DialPlanNode

Returns​

void


onOpenResource?​

TypeScript
optional onOpenResource?: (resourceId) => void;

Defined in: sdk/react/src/react/DialPlan.tsx:111

Optional callback to open a resource in a new tab. Provided by the host app.

Parameters​

resourceId​

string

Returns​

void


onSave?​

TypeScript
optional onSave?: (dialPlan) => void;

Defined in: sdk/react/src/react/DialPlan.tsx:89

Callback fired when the dial plan is saved (edit mode)

Parameters​

dialPlan​

DialPlan

Returns​

void


style?​

TypeScript
optional style?: CSSProperties;

Defined in: sdk/react/src/react/DialPlan.tsx:99

Optional inline styles for the container


theme?​

TypeScript
optional theme?: "light" | "dark";

Defined in: sdk/react/src/react/DialPlan.tsx:95

Color theme: 'light' (default) or 'dark'