"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.IconButton = void 0;
const tslib_1 = require("tslib");
const components_1 = require("@bluebase/components");
const IconButton_1 = tslib_1.__importDefault(require("@material-ui/core/IconButton"));
const react_1 = tslib_1.__importDefault(require("react"));
const react_native_1 = require("react-native");
const core_1 = require("@bluebase/core");
exports.IconButton = (props) => {
    const { disabled, name, size, color, style, onPress } = props;
    const { theme } = core_1.useTheme();
    return (react_1.default.createElement(IconButton_1.default, { disabled: disabled, onClick: onPress },
        react_1.default.createElement(components_1.Icon, { name: name, size: size, color: color !== null && color !== void 0 ? color : theme.palette.text.secondary, style: react_native_1.StyleSheet.flatten(style) })));
};
exports.IconButton.defaultProps = components_1.IconButtonDefaultProps;
