import { jsx, jsxs } from "react/jsx-runtime";
import { privateApis as componentsPrivateApis } from "@wordpress/components";
import { __, _x } from "@wordpress/i18n";
import { useSelect } from "@wordpress/data";
import { forwardRef } from "@wordpress/element";
import { store as editorStore } from "../../store";
import { unlock } from "../../lock-unlock";
import { sidebars } from "./constants";
const { Tabs } = unlock(componentsPrivateApis);
const SidebarHeader = (_, ref) => {
  const { documentLabel } = useSelect((select) => {
    const { getPostTypeLabel } = select(editorStore);
    return {
      documentLabel: (
        // translators: Default label for the Document sidebar tab, not selected.
        getPostTypeLabel() || _x("Document", "noun, panel")
      )
    };
  }, []);
  return /* @__PURE__ */ jsxs(Tabs.TabList, { ref, children: [
    /* @__PURE__ */ jsx(
      Tabs.Tab,
      {
        tabId: sidebars.document,
        "data-tab-id": sidebars.document,
        children: documentLabel
      }
    ),
    /* @__PURE__ */ jsx(
      Tabs.Tab,
      {
        tabId: sidebars.block,
        "data-tab-id": sidebars.block,
        children: __("Block")
      }
    )
  ] });
};
var header_default = forwardRef(SidebarHeader);
export {
  header_default as default
};
//# sourceMappingURL=header.js.map
