Skip to content

The complete open source platform to run your entire marketplace. Storefront, vendor panel, admin console, and integrations in one enterprise-grade platform you own.

811 B
Raw Blame
import { Children, ReactNode } from "react";

import { SingleColumnPage } from "@components/layout/pages";
import { WidgetZone } from "@mercurjs/dashboard-shared";

import {
  ShippingProfileListTable,
  ShippingProfileListDataTable,
  ShippingProfileListHeader,
  ShippingProfileListTitle,
} from "./_components";

const Root = ({ children }: { children?: ReactNode }) => {
  return (
    <SingleColumnPage>
      <WidgetZone id="shipping-profiles.list">
        {Children.count(children) > 0 ? children : <ShippingProfileListTable />}
      </WidgetZone>
    </SingleColumnPage>
  );
};

export const ShippingProfileListPage = Object.assign(Root, {
  Table: ShippingProfileListTable,
  Header: ShippingProfileListHeader,
  HeaderTitle: ShippingProfileListTitle,
  DataTable: ShippingProfileListDataTable,
});