"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }"use client";
var _chunkZJDXJT76cjs = require('./chunk-ZJDXJT76.cjs');var _chunk5KRCPBZRcjs = require('./chunk-5KRCPBZR.cjs');var _chunk3CNSKST2cjs = require('./chunk-3CNSKST2.cjs');var _chunk5NXYDZPPcjs = require('./chunk-5NXYDZPP.cjs');var _react = require('react');var _clsx = require('clsx'); var _clsx2 = _interopRequireDefault(_clsx);var w=_chunk3CNSKST2cjs.a.call(void 0, "EulToggle",["checked","disabled","focusVisible","input","readOnly","root"]),d=o=>_chunk5KRCPBZRcjs.e.call(void 0, "EulToggle",{input:["input"],root:["root",o.checked&&"checked",o.disabled&&"disabled",o.focusVisible&&"focusVisible",o.readOnly&&"readOnly"],thumb:["thumb"]}),e= exports.a =w;var u=_chunk3CNSKST2cjs.m.call(void 0, "input")`
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  margin: 0;
  cursor: inherit;
  opacity: 0;
`,g=_chunk3CNSKST2cjs.m.call(void 0, "div")(({theme:o})=>_chunk5NXYDZPPcjs.p`
    position: relative;
    display: inline-block;
    width: ${o.spacing(8)};
    height: ${o.spacing(5)};
    font-size: 0;
    background-color: ${o.palette.background[200]};
    border-radius: 100px;
    cursor: pointer;
    transition: ${o.transitions.create(["background-color"])};

    &.${e.checked} {
      background-color: ${o.palette.tealOpaque[300]};
    }

    &:hover {
      background-color: ${o.palette.background[100]};

      &.${e.checked} {
        background-color: ${o.palette.tealOpaque[400]};
      }
    }

    &.${e.focusVisible} {
      outline: ${o.spacing(.5)} solid ${o.palette.yellow[600]};
      outline-offset: ${o.spacing(.5)};
    }

    &.${e.disabled}, &.${e.disabled}:hover {
      background-color: transparent;
      outline: 1px solid ${o.palette.background[600]};
      cursor: not-allowed;
    }
  `),b=_chunk3CNSKST2cjs.m.call(void 0, "span")(({theme:o})=>_chunk5NXYDZPPcjs.p`
    position: relative;
    top: 2px;
    left: 2px;
    display: block;
    width: ${o.spacing(4)};
    height: ${o.spacing(4)};
    background-color: ${o.palette.background[700]};
    border-radius: ${o.spacing(4)};
    transition: ${o.transitions.create(["left","background-color"])};

    .${e.checked} & {
      top: 2px;
      left: 14px;
      background-color: ${o.palette.teal[700]};
    }

    .${e.root}:hover & {
      background-color: ${o.palette.background[800]};
    }

    .${e.checked}:hover & {
      background-color: ${o.palette.teal[800]};
    }

    .${e.disabled} &,
    .${e.disabled}:hover & {
      background-color: ${o.palette.background[600]};
    }
  `);var _jsxruntime = require('react/jsx-runtime');var $=_react.forwardRef.call(void 0, ({className:o,name:k,value:m,...a},T)=>{let{checked:x,disabled:y,focusVisible:h,getInputProps:C,readOnly:S}=_chunkZJDXJT76cjs.a.call(void 0, a),v=_chunk5KRCPBZRcjs.d.call(void 0, a),t=d({checked:x,disabled:y,focusVisible:h,readOnly:S});return _jsxruntime.jsxs.call(void 0, g,{className:_clsx2.default.call(void 0, o,t.root),children:[_jsxruntime.jsx.call(void 0, b,{className:_clsx2.default.call(void 0, t.thumb)}),_jsxruntime.jsx.call(void 0, u,{className:_clsx2.default.call(void 0, t.input),name:k,value:m,...C(),...v,ref:T})]})});$.displayName="Toggle";var V=$;exports.a = e; exports.b = V;
