UNPKG

@lonli-lokli/react-mosaic-component

Version:
34 lines (33 loc) 1.67 kB
// libs/react-mosaic-component/src/lib/buttons/defaultToolbarControls.tsx import React from "react"; import { ExpandButton } from "./ExpandButton.mjs"; import { RemoveButton } from "./RemoveButton.mjs"; import { ReplaceButton } from "./ReplaceButton.mjs"; import { SplitButton } from "./SplitButton.mjs"; import { AddTabButton } from "./AddTabButton.mjs"; import { TabSplitButton } from "./TabSplitButton.mjs"; import { TabRemoveButton } from "./TabRemoveButton.mjs"; var DEFAULT_PANEL_CONTROLS_IN_TABS = React.Children.toArray([ /* @__PURE__ */ React.createElement(RemoveButton, null) ]); var createDefaultTabsControls = (path) => React.Children.toArray([ /* @__PURE__ */ React.createElement(TabSplitButton, { path, key: "tab-split-btn" }), /* @__PURE__ */ React.createElement(TabRemoveButton, { path, key: "tab-remove-btn" }) ]); var DEFAULT_PANEL_CONTROLS_WITH_CREATION = React.Children.toArray([ /* @__PURE__ */ React.createElement(ReplaceButton, { key: "replace-btn" }), /* @__PURE__ */ React.createElement(SplitButton, { key: "split-btn" }), /* @__PURE__ */ React.createElement(AddTabButton, { key: "add-tab-btn" }), /* @__PURE__ */ React.createElement(ExpandButton, { key: "expand-btn" }), /* @__PURE__ */ React.createElement(RemoveButton, { key: "remove-btn" }) ]); var DEFAULT_PANEL_CONTROLS_WITHOUT_CREATION = React.Children.toArray([ /* @__PURE__ */ React.createElement(ExpandButton, { key: "expand-btn" }), /* @__PURE__ */ React.createElement(RemoveButton, { key: "remove-btn" }) ]); export { DEFAULT_PANEL_CONTROLS_IN_TABS, DEFAULT_PANEL_CONTROLS_WITHOUT_CREATION, DEFAULT_PANEL_CONTROLS_WITH_CREATION, createDefaultTabsControls };