"use strict";
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
const reactUtils = require("@contember/react-utils");
const react = require("react");
const SingleKindFileHandler = require("./SingleKindFileHandler.cjs");
const useSingleKindFileHandler = (props, kindFactory) => {
  const stableProps = reactUtils.useObjectMemo(props);
  return react.useMemo(
    () => new SingleKindFileHandler.SingleKindFileHandler(
      kindFactory(stableProps),
      SingleKindFileHandler.isEmptyByUrlField(stableProps.urlField)
    ),
    [kindFactory, stableProps]
  );
};
exports.useSingleKindFileHandler = useSingleKindFileHandler;
//# sourceMappingURL=useSingleKindFileHandler.cjs.map
