/** @packageDocumentation * @module Zone */ import * as React from "react"; import { CommonProps, RectangleProps } from "@bentley/ui-core"; import { DisabledResizeHandles, DraggedWidgetManagerProps, ToolSettingsWidgetManagerProps, WidgetManagerProps, WidgetZoneId, ZoneManagerProps, ZoneTargetType } from "@bentley/ui-ninezone"; import { TargetChangeHandler, WidgetChangeHandler, ZoneDefProvider } from "../frontstage/FrontstageComposer"; import { WidgetProps } from "../widgets/WidgetProps"; import { WidgetTabs } from "../widgets/WidgetStack"; import { ZoneDef, ZoneState } from "./ZoneDef"; /** Enum for [[Zone]] Location. * @public */ export declare enum ZoneLocation { TopLeft = 1, TopCenter = 2, TopRight = 3, CenterLeft = 4, CenterRight = 6, BottomLeft = 7, BottomCenter = 8, BottomRight = 9 } /** Properties of a [[Zone]] component * @public */ export interface ZoneProps extends CommonProps { /** Default Zone state. Controls how the Zone is initially displayed. Defaults to ZoneState.Open. */ defaultState?: ZoneState; /** Indicates if other Zones may be merged with this Zone. Defaults to false. */ allowsMerging?: boolean; /** Any application data to attach to this Zone. */ applicationData?: any; /** Indicates with which other zone to merge. */ mergeWithZone?: ZoneLocation; /** Describes preferred initial width of the zone. */ initialWidth?: number; /** Properties for the Widgets in this Zone. * @note Stable `WidgetProps["id"]` is generated if id is not provided to correctly save and restore App layout. * [[Frontstage]] version must be increased when Widget location is changed or new widgets are added/removed. */ widgets?: Array>; /** @internal */ runtimeProps?: ZoneRuntimeProps; } /** Runtime Properties for the [[Zone]] component. * @internal */ export interface ZoneRuntimeProps { activeTabIndex: number; disabledResizeHandles: DisabledResizeHandles | undefined; draggedWidget: DraggedWidgetManagerProps | undefined; dropTarget: ZoneTargetType | undefined; getWidgetContentRef: (id: WidgetZoneId) => React.Ref; ghostOutline: RectangleProps | undefined; isHidden: boolean; isInFooterMode: boolean; openWidgetId: WidgetZoneId | undefined; targetChangeHandler: TargetChangeHandler; widget: WidgetManagerProps | undefined; widgetTabs: WidgetTabs; widgetChangeHandler: WidgetChangeHandler; zoneDefProvider: ZoneDefProvider; zoneDef: ZoneDef; zone: ZoneManagerProps; } /** @internal */ export declare function getStableWidgetProps(widgetProps: WidgetProps, stableId: string): WidgetProps; /** Zone React component. * A Zone is a standard area on the screen for users to read and interact with data applicable to the current task. Each Zone has a defined purpose. * @public */ export declare class Zone extends React.Component { constructor(props: ZoneProps); static initializeZoneDef(zoneDef: ZoneDef, props: ZoneProps): void; componentDidMount(): void; componentWillUnmount(): void; render(): React.ReactNode; private _handleWidgetStateChangedEvent; private getWidgetIdForDef; } /** @internal */ export declare const isToolSettingsWidgetManagerProps: (props: WidgetManagerProps | undefined) => props is ToolSettingsWidgetManagerProps; //# sourceMappingURL=Zone.d.ts.map