"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var i=require("../../../_virtual/jsx-runtime.js"),f=require("react"),d=require("../styles.js"),a=require("../../../utils/index.js");function j({id:t,name:o,label:e,value:u,onChange:c=a.noop,disabled:p=!1,hasError:R=!1,checked:x,...r},l){!t&&e&&(t=a.slugify(e));const s=a.getId(r["data-testid"]),n=a.getId(r["data-testid"]);return i.jsxRuntimeExports.jsxs(d.CheckRadioWrapper,{children:[i.jsxRuntimeExports.jsx(d.CheckRadioInput,{ref:l,type:"radio",id:t,name:o,value:u,disabled:p,hasError:R,onChange:c,"data-testid":s("input"),"data-trackid":n("input"),"aria-label":r["aria-label"]||e,checked:x}),e&&i.jsxRuntimeExports.jsx(d.CheckRadioLabel,{htmlFor:t,"data-testid":s("label"),"data-trackid":n("label"),children:e})]})}const h=f.forwardRef(j);exports.Radio=h;
