"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ToolPanelSettingsPanel = void 0;
const tslib_1 = require("tslib");
const React = tslib_1.__importStar(require("react"));
const icons_1 = require("../../../components/icons");
const Panel_1 = tslib_1.__importDefault(require("../../../components/Panel"));
//We cannot destructure this.props using the react way in typescript which is a real pain as you
//need to transfer props individually as a consequence
//let { buttonContent, ...other } = this.props
class ToolPanelSettingsPanel extends React.Component {
    render() {
        let header = (React.createElement("span", { style: { verticalAlign: 'middle' } },
            ' ',
            React.createElement(icons_1.Icon, { name: 'spanner' }),
            " ",
            React.createElement("span", null, "Settings"),
            this.props.button &&
                React.cloneElement(this.props.button, {
                    style: {
                        float: 'right',
                        border: '0px',
                        background: 'none',
                        borderRadius: '0px',
                        boxShadow: 'none',
                    },
                })));
        return (React.createElement(Panel_1.default, { header: header, style: { margin: '0px', padding: '0px' } }, this.props.children));
    }
}
exports.ToolPanelSettingsPanel = ToolPanelSettingsPanel;
