import { DeferredSubTrees } from "@contember/binding";
import { useCallback } from "react";
import { jsxDEV, Fragment } from "react/jsx-dev-runtime";
var _jsxFileName = "/__w/interface/interface/packages/admin/src/components/bindingFacade/upload/internalComponents/selection/SingleKindSelectFileDialog.tsx";
const SingleKindSelectFileDialog = ({
  selectedEntityIds,
  onToggleSelectConnector,
  connectorFactory,
  innerComponent: Component,
  innerProps
}) => {
  const onToggleSelect = useCallback((entity) => {
    onToggleSelectConnector(connectorFactory(entity));
  }, [connectorFactory, onToggleSelectConnector]);
  return /* @__PURE__ */ jsxDEV(Fragment, {
    children: /* @__PURE__ */ jsxDEV(DeferredSubTrees, {
      fallback: /* @__PURE__ */ jsxDEV(Fragment, {
        children: "Loading..."
      }, void 0, false),
      children: /* @__PURE__ */ jsxDEV(Component, {
        ...innerProps,
        onToggleSelect,
        selectedEntityIds
      }, void 0, false, {
        fileName: _jsxFileName,
        lineNumber: 32,
        columnNumber: 4
      }, void 0)
    }, void 0, false, {
      fileName: _jsxFileName,
      lineNumber: 31,
      columnNumber: 3
    }, void 0)
  }, void 0, false);
};
export {
  SingleKindSelectFileDialog
};
//# sourceMappingURL=SingleKindSelectFileDialog.js.map
