import { createRendererMotionComponent } from "../../motion/index.js";
import { createUseRender } from "../dom/use-render.js";
import { isSVGComponent } from "../dom/utils/is-svg-component.js";
import { htmlMotionConfig } from "../html/config-motion.js";
import { svgMotionConfig } from "../svg/config-motion.js";
function createMotionComponentFactory(preloadedFeatures, createVisualElement) {
  return function createMotionComponent(Component, { forwardMotionProps } = { forwardMotionProps: false }) {
    const baseConfig = isSVGComponent(Component) ? svgMotionConfig : htmlMotionConfig;
    const config = {
      ...baseConfig,
      preloadedFeatures,
      useRender: createUseRender(forwardMotionProps),
      createVisualElement,
      Component
    };
    return createRendererMotionComponent(config);
  };
}
export {
  createMotionComponentFactory
};
//# sourceMappingURL=create-factory.js.map
