"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.ReactSelectLoadMoreButton = void 0;
var react_1 = __importDefault(require("react"));
var Button_1 = __importDefault(require("@mui/material/Button"));
var CircularProgress_1 = __importDefault(require("@mui/material/CircularProgress"));
var ui_i18n_1 = __importDefault(require("ui-i18n"));
var styles_1 = require("./styles");
var ReactSelectLoadMoreButton = function (_a) {
    var loading = _a.loading, onClick = _a.onClick, onMouseDown = _a.onMouseDown;
    var styles = (0, styles_1.useStyles)();
    return (react_1.default.createElement("div", { className: styles.loadMoreContainer }, loading ? (react_1.default.createElement(CircularProgress_1.default, { className: styles.loadingSpinner, size: 24 })) : (react_1.default.createElement(Button_1.default, { color: "primary", onClick: onClick, onMouseDown: onMouseDown, className: styles.moreButton },
        react_1.default.createElement("div", { className: styles.buttonLabel }, ui_i18n_1.default.text('Load more'))))));
};
exports.ReactSelectLoadMoreButton = ReactSelectLoadMoreButton;
