import { nativeTypesConfig as o } from "./nativeTypesConfig.es.js";
import { NativeDragSource as a } from "./NativeDragSource.es.js";
function f(t, n) {
  const r = o[t];
  if (!r)
    throw new Error(`native type ${t} has no configuration`);
  const e = new a(r);
  return e.loadDataTransfer(n), e;
}
function u(t) {
  if (!t)
    return null;
  const n = Array.prototype.slice.call(t.types || []);
  return Object.keys(o).filter((r) => {
    const e = o[r];
    return e != null && e.matchesTypes ? e.matchesTypes.some(
      (i) => n.indexOf(i) > -1
    ) : !1;
  })[0] || null;
}
export {
  f as createNativeDragSource,
  u as matchNativeItemType
};
//# sourceMappingURL=index.es.js.map
