/*---------------------------------------------------------------------------------------------
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
* See LICENSE.md in the project root for license terms and full copyright notice.
*--------------------------------------------------------------------------------------------*/
/** @packageDocumentation
 * @module StatusBar
 */
import * as React from "react";
import { Zone } from "@itwin/appui-layout-react";
import { SafeAreaContext } from "../safearea/SafeAreaContext";
import { StatusBar } from "../statusbar/StatusBar";
import { getFloatingZoneBounds } from "./FrameworkZone";
import { Outline } from "./Outline";
import { ZoneTargets } from "../dragdrop/ZoneTargets";
/** Status Bar Zone React component.
 * @internal
 */
export class StatusBarZone extends React.PureComponent {
    render() {
        const bounds = getFloatingZoneBounds(this.props.zoneProps);
        return (React.createElement(SafeAreaContext.Consumer, null, (safeAreaInsets) => (React.createElement(React.Fragment, null,
            React.createElement(Zone, { bounds: this.props.isInFooterMode ? undefined : bounds, className: this.props.className, id: this.props.zoneProps.id, isHidden: this.props.isHidden, isInFooterMode: this.props.isInFooterMode, safeAreaInsets: safeAreaInsets }, this.props.widgetControl &&
                React.createElement(StatusBar, { isInFooterMode: this.props.isInFooterMode, widgetControl: this.props.widgetControl })),
            React.createElement(Zone, { bounds: this.props.zoneProps.bounds, id: this.props.zoneProps.id, isInFooterMode: this.props.isInFooterMode, safeAreaInsets: safeAreaInsets },
                React.createElement(ZoneTargets, { zoneId: this.props.zoneProps.id, dropTarget: this.props.dropTarget, targetChangeHandler: this.props.targetChangeHandler })),
            React.createElement(Outline, { bounds: this.props.targetedBounds })))));
    }
}
//# sourceMappingURL=StatusBarZone.js.map