"use strict";
/*---------------------------------------------------------------------------------------------
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
* See LICENSE.md in the project root for license terms and full copyright notice.
*--------------------------------------------------------------------------------------------*/
/** @packageDocumentation
 * @module Zone
 */
Object.defineProperty(exports, "__esModule", { value: true });
exports.ZoneTargets = void 0;
const React = require("react");
const appui_layout_react_1 = require("@itwin/appui-layout-react");
/** Zone Targets React component.
 * @internal
 */
class ZoneTargets extends React.Component {
    render() {
        switch (this.props.dropTarget) {
            case appui_layout_react_1.ZoneTargetType.Merge: // eslint-disable-line deprecation/deprecation
                return (React.createElement(appui_layout_react_1.MergeTarget, { className: this.props.className, 
                    // eslint-disable-next-line deprecation/deprecation
                    onTargetChanged: (isTargeted) => this.props.targetChangeHandler.handleTargetChanged(this.props.zoneId, appui_layout_react_1.ZoneTargetType.Merge, isTargeted), style: this.props.style }));
            case appui_layout_react_1.ZoneTargetType.Back: // eslint-disable-line deprecation/deprecation
                return (React.createElement(appui_layout_react_1.BackTarget, { className: this.props.className, 
                    // eslint-disable-next-line deprecation/deprecation
                    onTargetChanged: (isTargeted) => this.props.targetChangeHandler.handleTargetChanged(this.props.zoneId, appui_layout_react_1.ZoneTargetType.Back, isTargeted), style: this.props.style, zoneIndex: this.props.zoneId }));
            default:
                return null;
        }
    }
}
exports.ZoneTargets = ZoneTargets;
//# sourceMappingURL=ZoneTargets.js.map