import { jsxs as m, jsx as c } from "react/jsx-runtime";
import { a as h } from "./index.CfQlFjZU.js";
import { useMemo as l } from "react";
const C = "creator_radioContainer_KWfnB", u = "creator_input_ow6sr", d = { radioContainer: C, input: u }, f = ({
  label: t,
  name: n,
  value: o,
  disabled: e,
  selected: s,
  onChecked: r
}) => {
  const i = l(() => `radio-${n}-${o}`, [n, o]), a = () => {
    r?.();
  };
  return {
    containerClassName: d.radioContainer,
    className: d.input,
    label: t,
    name: n,
    value: o,
    id: i,
    disabled: e,
    checked: s === o,
    onChecked: a
  };
}, R = ({
  containerClassName: t,
  className: n,
  label: o,
  name: e,
  value: s,
  id: r,
  disabled: i,
  checked: a,
  onChecked: p
}) => /* @__PURE__ */ m("span", { className: t, children: [
  /* @__PURE__ */ c(
    "input",
    {
      type: "radio",
      id: r,
      className: n,
      name: e,
      value: s,
      disabled: i,
      checked: a,
      onChange: p
    }
  ),
  /* @__PURE__ */ c("label", { htmlFor: r, children: o })
] }), N = h(R, f);
export {
  N as R
};
