"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.AdaptableIconSelector = void 0;
const tslib_1 = require("tslib");
const React = tslib_1.__importStar(require("react"));
const IconSelector_1 = require("../../../components/IconSelector");
const AdaptableContext_1 = require("../../AdaptableContext");
/**
 * This component connects to adaptable to retrieve custom icons
 */
const AdaptableIconSelector = (props) => {
    var _a, _b;
    const adaptable = (0, AdaptableContext_1.useAdaptable)();
    const userInterfaceOptions = (_a = adaptable.api.optionsApi.getAdaptableOptions()) === null || _a === void 0 ? void 0 : _a.userInterfaceOptions;
    const customDefinedIcons = (_b = userInterfaceOptions.customIcons) !== null && _b !== void 0 ? _b : [];
    return React.createElement(IconSelector_1.IconSelector, Object.assign({ customIcons: customDefinedIcons }, props));
};
exports.AdaptableIconSelector = AdaptableIconSelector;
