import { jsxDEV } from "react/jsx-dev-runtime";
import { DataBindingProvider, EntitySubTree } from "@contember/react-binding";
import { useOnPersistSuccess } from "../useOnPersistSuccess.js";
import { NotFoundBoundary } from "./NotFoundBoundary.js";
import { scopeComponent } from "./scopeComponent.js";
import { FeedbackRenderer } from "../../bindingFacade/renderers/FeedbackRenderer.js";
const EditScope = scopeComponent(
  ({
    children,
    onPersistSuccess,
    redirectOnSuccess,
    refreshDataBindingOnPersist,
    skipBindingStateUpdateAfterPersist,
    stateComponent,
    stateProps,
    ...entityProps
  }) => /* @__PURE__ */ jsxDEV(
    DataBindingProvider,
    {
      refreshOnPersist: refreshDataBindingOnPersist ?? true,
      stateComponent: stateComponent ?? FeedbackRenderer,
      stateProps,
      skipStateUpdateAfterPersist: skipBindingStateUpdateAfterPersist,
      children: /* @__PURE__ */ jsxDEV(EntitySubTree, { ...entityProps, onPersistSuccess: useOnPersistSuccess({ redirectOnSuccess, onPersistSuccess }), children: /* @__PURE__ */ jsxDEV(NotFoundBoundary, { children }, void 0, false, {
        fileName: "/__w/interface/interface/packages/admin/src/components/pageRouting/Scopes/EditScope.tsx",
        lineNumber: 41,
        columnNumber: 5
      }, void 0) }, void 0, false, {
        fileName: "/__w/interface/interface/packages/admin/src/components/pageRouting/Scopes/EditScope.tsx",
        lineNumber: 40,
        columnNumber: 4
      }, void 0)
    },
    void 0,
    false,
    {
      fileName: "/__w/interface/interface/packages/admin/src/components/pageRouting/Scopes/EditScope.tsx",
      lineNumber: 34,
      columnNumber: 3
    },
    void 0
  ),
  "EditScope"
);
export {
  EditScope
};
//# sourceMappingURL=EditScope.js.map
