"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.pageItemRoute = void 0;
var _i18n = require("@wordpress/i18n");
var _editor = _interopRequireDefault(require("../editor"));
var _sidebarDataviews = _interopRequireDefault(require("../sidebar-dataviews"));
var _sidebarNavigationScreen = _interopRequireDefault(require("../sidebar-navigation-screen"));
var _sidebarNavigationScreenUnsupported = _interopRequireDefault(require("../sidebar-navigation-screen-unsupported"));
var _jsxRuntime = require("react/jsx-runtime");
/**
 * WordPress dependencies
 */

/**
 * Internal dependencies
 */

const pageItemRoute = exports.pageItemRoute = {
  name: 'page-item',
  path: '/page/:postId',
  areas: {
    sidebar({
      siteData
    }) {
      const isBlockTheme = siteData.currentTheme?.is_block_theme;
      return isBlockTheme ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_sidebarNavigationScreen.default, {
        title: (0, _i18n.__)('Pages'),
        backPath: "/",
        content: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sidebarDataviews.default, {
          postType: "page"
        })
      }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_sidebarNavigationScreenUnsupported.default, {});
    },
    mobile({
      siteData
    }) {
      const isBlockTheme = siteData.currentTheme?.is_block_theme;
      return isBlockTheme ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_editor.default, {}) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_sidebarNavigationScreenUnsupported.default, {});
    },
    preview({
      siteData
    }) {
      const isBlockTheme = siteData.currentTheme?.is_block_theme;
      return isBlockTheme ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_editor.default, {}) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_sidebarNavigationScreenUnsupported.default, {});
    }
  }
};
//# sourceMappingURL=page-item.js.map