import { _objectSpread2 } from "../../../../../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectSpread2.js";
import { formatProducts } from "../../../service2/utils.js";
import { Context } from "../../../model.js";
import useSelectPet from "../../../service2/hooks/useSelectPet.js";
import React, { useContext } from "react";
import { ProductCard } from "@pisell/materials";
//#region src/components/booking/info/service/editService/BookingList/index.tsx
const BookingList = ({ items }) => {
	const { state, dispatch } = useContext(Context);
	const { holderLists } = useSelectPet(state);
	const productParams = {
		hideAddBtn: state.isTerminalDayBookingPage,
		isShowNote: false,
		isShowPackageNote: false,
		holders: holderLists,
		isEdit: false,
		disabledEdit: true
	};
	return /* @__PURE__ */ React.createElement("div", { style: {
		display: "flex",
		flexWrap: "wrap",
		gap: 16
	} }, formatProducts(items, state, false).map((item, index) => {
		return /* @__PURE__ */ React.createElement("div", { style: { width: "100%" } }, /* @__PURE__ */ React.createElement(ProductCard, _objectSpread2({
			key: item._id,
			dataSource: item
		}, productParams)));
	}));
};
//#endregion
export { BookingList as default };
