require("./StatusLight.css");
var $e991cbcdf82ced71$exports = require("./CenterBaseline.cjs");
var $6367bc87eb7d24ad$exports = require("./Content.cjs");
var $5eb75e0c130e0669$exports = require("../icons/Skeleton.cjs");
var $ac757a4c2bd72aee$exports = require("../icons/useSpectrumContextProps.cjs");
var $lz5dj$reactjsxruntime = require("react/jsx-runtime");
var $lz5dj$react = require("react");
var $lz5dj$reactariautils = require("@react-aria/utils");
var $lz5dj$reactspectrumutils = require("@react-spectrum/utils");


function $parcel$export(e, n, v, s) {
  Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
}

$parcel$export(module.exports, "StatusLightContext", () => $dad358896b5630fa$export$d8f8c0b091d8cb9b);
$parcel$export(module.exports, "StatusLight", () => $dad358896b5630fa$export$5f84c37a31c6e41c);
/*
 * Copyright 2024 Adobe. All rights reserved.
 * This file is licensed to you under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License. You may obtain a copy
 * of the License at http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software distributed under
 * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
 * OF ANY KIND, either express or implied. See the License for the specific language
 * governing permissions and limitations under the License.
 */ 







const $dad358896b5630fa$export$d8f8c0b091d8cb9b = /*#__PURE__*/ (0, $lz5dj$react.createContext)(null);
const $dad358896b5630fa$var$wrapper = function anonymous(props, overrides) {
    let rules = " ";
    let width = false;
    let matches = (overrides || '').matchAll(/(?:^|\s)(J|G|I|H|_u|_v|_s|__A|_d|_J|z|y|B|A|_P|_9|W|_l|_A|_z|_6|Z|N|L)[^\s]+/g);
    for (let p of matches){
        if (p[1] === "Z") width = true;
        rules += p[0];
    }
    rules += ' sd12';
    rules += ' Uc12';
    rules += ' Usd12';
    rules += ' qc12';
    rules += ' qsd12';
    rules += ' ea12';
    if (!width) rules += ' ZJ12';
    if (props.size === "XL") {
        rules += ' uk12';
        rules += ' ucJ9TBTb12';
        rules += ' ud3Euai12';
        rules += ' uea12';
        rules += ' ugb12';
        rules += ' uhd12';
        rules += ' uje12';
        rules += ' u2NhKxcl12';
        rules += ' uic12';
    } else if (props.size === "L") {
        rules += ' uk12';
        rules += ' ucJ9TBTb12';
        rules += ' ud3Euai12';
        rules += ' uea12';
        rules += ' ugb12';
        rules += ' uhd12';
        rules += ' uje12';
        rules += ' u2NhKxcl12';
        rules += ' uic12';
    } else if (props.size === "S") {
        rules += ' uk12';
        rules += ' ucJ9TBTb12';
        rules += ' ud3Euai12';
        rules += ' uea12';
        rules += ' ugb12';
        rules += ' uhd12';
        rules += ' uje12';
        rules += ' u2NhKxcl12';
        rules += ' uic12';
    } else if (props.size === "XS") {
        rules += ' uk12';
        rules += ' ucJ9TBTb12';
        rules += ' ud3Euai12';
        rules += ' uea12';
        rules += ' ugb12';
        rules += ' uhd12';
        rules += ' uje12';
        rules += ' u2NhKxcl12';
        rules += ' uic12';
    } else {
        rules += ' uk12';
        rules += ' ucJ9TBTb12';
        rules += ' ud3Euai12';
        rules += ' uea12';
        rules += ' ugb12';
        rules += ' uhd12';
        rules += ' uje12';
        rules += ' u2NhKxcl12';
        rules += ' uic12';
    }
    if (props.size === "XL") {
        rules += ' -_6BNtrc-e12';
        rules += ' vx12';
    } else if (props.size === "L") {
        rules += ' -_6BNtrc-d12';
        rules += ' vx12';
    } else if (props.size === "S") {
        rules += ' -_6BNtrc-b12';
        rules += ' vx12';
    } else if (props.size === "XS") {
        rules += ' -_6BNtrc-a12';
        rules += ' vx12';
    } else {
        rules += ' -_6BNtrc-c12';
        rules += ' vx12';
    }
    if (props.size === "XL") {
        rules += ' xb12';
        rules += ' _xa12';
    } else if (props.size === "L") {
        rules += ' xb12';
        rules += ' _xa12';
    } else if (props.size === "S") {
        rules += ' xb12';
        rules += ' _xa12';
    } else if (props.size === "XS") {
        rules += ' xb12';
        rules += ' _xa12';
    } else {
        rules += ' xb12';
        rules += ' _xa12';
    }
    if (props.size === "XL") {
        rules += ' _Fd12';
        rules += ' _FnuYUweb12';
    } else if (props.size === "L") {
        rules += ' _Fd12';
        rules += ' _FnuYUweb12';
    } else if (props.size === "S") {
        rules += ' _Fd12';
        rules += ' _FnuYUweb12';
    } else if (props.size === "XS") {
        rules += ' _Fd12';
        rules += ' _FnuYUweb12';
    } else {
        rules += ' _Fd12';
        rules += ' _FnuYUweb12';
    }
    if (props.variant === "neutral") rules += ' pn12';
    else rules += ' pt12';
    rules += ' __ca12';
    return rules;
};
const $dad358896b5630fa$var$light = function anonymous(props) {
    let rules = " ";
    if (props.size === "XL") rules += ' Zk12';
    else if (props.size === "L") rules += ' Zj12';
    else if (props.size === "M") rules += ' Zi12';
    else if (props.size === "S") rules += ' Zh12';
    if (props.size === "XL") rules += ' Fl12';
    else if (props.size === "L") rules += ' Fk12';
    else if (props.size === "M") rules += ' Fj12';
    else if (props.size === "S") rules += ' Fi12';
    if (props.isSkeleton) rules += ' tn12';
    else if (props.variant === "silver") rules += ' te12';
    else if (props.variant === "brown") rules += ' th12';
    else if (props.variant === "cinnamon") rules += ' tj12';
    else if (props.variant === "turquoise") rules += ' tb12';
    else if (props.variant === "pink") rules += ' to12';
    else if (props.variant === "yellow") rules += ' tl12';
    else if (props.variant === "seafoam") rules += ' tc12';
    else if (props.variant === "indigo") rules += ' td12';
    else if (props.variant === "magenta") rules += ' tp12';
    else if (props.variant === "purple") rules += ' ti12';
    else if (props.variant === "fuchsia") rules += ' tk12';
    else if (props.variant === "cyan") rules += ' ts12';
    else if (props.variant === "chartreuse") rules += ' tg12';
    else if (props.variant === "celery") rules += ' tv12';
    else if (props.variant === "negative") rules += ' tq12';
    else if (props.variant === "notice") rules += ' tm12';
    else if (props.variant === "positive") rules += ' tt12';
    else if (props.variant === "neutral") rules += ' tf12';
    else if (props.variant === "informative") rules += ' tu12';
    rules += ' _Ne12';
    rules += ' Pe12';
    return rules;
};
const $dad358896b5630fa$export$5f84c37a31c6e41c = /*#__PURE__*/ (0, $lz5dj$react.forwardRef)(function StatusLight(props, ref) {
    [props, ref] = (0, $ac757a4c2bd72aee$exports.useSpectrumContextProps)(props, ref, $dad358896b5630fa$export$d8f8c0b091d8cb9b);
    let { children: children, size: size = 'M', variant: variant, role: role, UNSAFE_className: UNSAFE_className = '', UNSAFE_style: UNSAFE_style, styles: styles } = props;
    let domRef = (0, $lz5dj$reactspectrumutils.useDOMRef)(ref);
    let isSkeleton = (0, $5eb75e0c130e0669$exports.useIsSkeleton)();
    if (!children && !props['aria-label'] && process.env.NODE_ENV !== 'production') console.warn('If no children are provided, an aria-label must be specified');
    if (!role && (props['aria-label'] || props['aria-labelledby']) && process.env.NODE_ENV !== 'production') console.warn('A labelled StatusLight must have a role.');
    return /*#__PURE__*/ (0, $lz5dj$reactjsxruntime.jsxs)("div", {
        ...(0, $lz5dj$reactariautils.filterDOMProps)(props, {
            labelable: !!role
        }),
        ref: domRef,
        role: role,
        style: UNSAFE_style,
        className: UNSAFE_className + $dad358896b5630fa$var$wrapper({
            size: size,
            variant: variant
        }, styles),
        children: [
            /*#__PURE__*/ (0, $lz5dj$reactjsxruntime.jsx)((0, $e991cbcdf82ced71$exports.CenterBaseline), {
                children: /*#__PURE__*/ (0, $lz5dj$reactjsxruntime.jsx)("svg", {
                    className: $dad358896b5630fa$var$light({
                        size: size,
                        variant: variant,
                        isSkeleton: isSkeleton
                    }),
                    "aria-hidden": "true",
                    children: /*#__PURE__*/ (0, $lz5dj$reactjsxruntime.jsx)("circle", {
                        r: "50%",
                        cx: "50%",
                        cy: "50%"
                    })
                })
            }),
            /*#__PURE__*/ (0, $lz5dj$reactjsxruntime.jsx)((0, $6367bc87eb7d24ad$exports.Text), {
                children: children
            })
        ]
    });
});


//# sourceMappingURL=StatusLight.cjs.map
