"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = Page;
var _clsx = _interopRequireDefault(require("clsx"));
var _editor = require("@wordpress/editor");
var _header = _interopRequireDefault(require("./header"));
var _lockUnlock = require("../../lock-unlock");
var _jsxRuntime = require("react/jsx-runtime");
/**
 * External dependencies
 */

/**
 * WordPress dependencies
 */

/**
 * Internal dependencies
 */

const {
  NavigableRegion
} = (0, _lockUnlock.unlock)(_editor.privateApis);
function Page({
  title,
  subTitle,
  actions,
  children,
  className,
  hideTitleFromUI = false
}) {
  const classes = (0, _clsx.default)('edit-site-page', className);
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(NavigableRegion, {
    className: classes,
    ariaLabel: title,
    children: /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
      className: "edit-site-page-content",
      children: [!hideTitleFromUI && title && /*#__PURE__*/(0, _jsxRuntime.jsx)(_header.default, {
        title: title,
        subTitle: subTitle,
        actions: actions
      }), children]
    })
  });
}
//# sourceMappingURL=index.js.map