import { jsxs as _jsxs } from "react/jsx-runtime";
import { forwardRef } from "react";
import { switchBall, switchTrack } from "./switchStyles.js";
/**
 * Used to create the switch track styles
 * @internal
 */ export const SwitchTrack = /*#__PURE__*/ forwardRef(function SwitchTrack(props, ref) {
    const { style, className, ballAddon, ballProps, ballStyle, ballClassName, active, children, disabled = false, ...remaining } = props;
    return /*#__PURE__*/ _jsxs("div", {
        ...remaining,
        ref: ref,
        style: style,
        className: switchTrack({
            disabled,
            className
        }),
        children: [
            children,
            /*#__PURE__*/ _jsxs("span", {
                style: ballStyle,
                ...ballProps,
                className: switchBall({
                    className: ballClassName,
                    active
                }),
                children: [
                    ballAddon,
                    ballProps?.children
                ]
            })
        ]
    });
});

//# sourceMappingURL=SwitchTrack.js.map