UNPKG

@mantine/code-highlight

Version:

Code highlight with Mantine theme

18 lines (17 loc) 999 B
"use client"; const require_CodeHighlightControl = require("../CodeHighlightControl/CodeHighlightControl.cjs"); const require_ExpandIcon = require("./ExpandIcon.cjs"); let react_jsx_runtime = require("react/jsx-runtime"); //#region packages/@mantine/code-highlight/src/CodeHighlight/ExpandCodeButton/ExpandCodeButton.tsx function ExpandCodeButton({ expanded, onExpand, expandCodeLabel = "Expand code", collapseCodeLabel = "Collapse code" }) { return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_CodeHighlightControl.CodeHighlightControl, { onClick: () => onExpand(!expanded), tooltipLabel: expanded ? collapseCodeLabel : expandCodeLabel, "aria-label": expanded ? collapseCodeLabel : expandCodeLabel, children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_ExpandIcon.ExpandIcon, { expanded }) }); } ExpandCodeButton.displayName = "@mantine/code-highlight/ExpandCodeButton"; //#endregion exports.ExpandCodeButton = ExpandCodeButton; //# sourceMappingURL=ExpandCodeButton.cjs.map