@lifi/widget
Version:
LI.FI Widget for cross-chain bridging and swapping. It will drive your multi-chain strategy and attract new users from everywhere.
16 lines (15 loc) • 946 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.CloseDrawerButton = void 0;
const jsx_runtime_1 = require("react/jsx-runtime");
const CloseRounded_1 = require("@mui/icons-material/CloseRounded");
const material_1 = require("@mui/material");
const IconButton_1 = require("@mui/material/IconButton");
const react_i18next_1 = require("react-i18next");
const AppDrawerContext_1 = require("../../AppDrawerContext");
const CloseDrawerButton = (props) => {
const { t } = (0, react_i18next_1.useTranslation)();
const { closeDrawer } = (0, AppDrawerContext_1.useDrawer)();
return ((0, jsx_runtime_1.jsx)(material_1.Tooltip, { title: t('button.close'), enterDelay: 400, arrow: true, children: (0, jsx_runtime_1.jsx)(IconButton_1.default, { size: "medium", onClick: closeDrawer, ...props, children: (0, jsx_runtime_1.jsx)(CloseRounded_1.default, {}) }) }));
};
exports.CloseDrawerButton = CloseDrawerButton;