function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
import React from 'react';
import { PisellReservationCore } from "./PisellReservation";
import { PISELL_RESERVATION_BODY_VIEW_STORAGE_KEY } from "./reservationConstants";
import { useReservationResponsiveVariant } from "./hooks/useReservationResponsiveVariant";
/**
 * 预约页面：双视图可切换、子视图持久化，行为对齐原 PisellReservation 页面。
 *
 * `variant` 解析策略（与 responsive skill 的 props 优先级一致）：
 * 1. 调用方显式传入的 `props.variant` 最高优先；
 * 2. 否则按视口宽度（≤ 768px）自适应到 `'phone'` / `'desktop'`，随窗口/横竖屏变化实时切换。
 */
export var PisellReservationBookingPage = function PisellReservationBookingPage(props) {
  var _props$bodyViewStorag;
  var variant = useReservationResponsiveVariant(props.variant);
  return /*#__PURE__*/React.createElement(PisellReservationCore, _extends({}, props, {
    bodyViewStorageKey: (_props$bodyViewStorag = props.bodyViewStorageKey) !== null && _props$bodyViewStorag !== void 0 ? _props$bodyViewStorag : PISELL_RESERVATION_BODY_VIEW_STORAGE_KEY,
    variant: variant
  }));
};

/**
 * 与 {@link PisellReservationBookingPage} 相同实现。
 * 低代码存量页面仍使用 `componentName: PisellReservation` 时由物料包导出此名以解析组件。
 */
export var PisellReservation = PisellReservationBookingPage;
export default PisellReservationBookingPage;