import { e_ as d, e$ as a, av as c, X as n, Z as i, f0 as s, bS as t, cP as g, d8 as l, cR as p, d9 as u, bV as $ } from "./603b75d9.js";
import "react";
import "react-dom";
function b(o) {
  const r = d(o.background), e = a(o.background);
  return c`
    &&& {
      border-radius: ${o.radius};
      margin: ${o.margin};
      padding: ${o.padding};
      &:not(:disabled) {
        // click animation color
        --antd-wave-shadow-color: ${o.border};
        border-color: ${o.border};
        color: ${o.text};
        background: ${o.background};
        border-radius: ${o.radius};
        margin: ${o.margin};
        padding: ${o.padding};

        &:hover,
        &:focus {
          color: ${o.text};
          background-color: ${r};
          border-color: ${o.border === o.background ? r : o.border};
        }

        &:active {
          color: ${o.text};
          background-color: ${e};
          border-color: ${o.border === o.background ? e : o.border};
        }
      }
    }
  `;
}
const C = n($)`
  ${(o) => o.$buttonStyle && b(o.$buttonStyle)}
  width: 100%;
  height: auto;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  span {
    overflow: hidden;
    text-overflow: ellipsis;
  }
  gap: 6px;
`, w = n.div`
  // The button component is disabled but can respond to drag & select events
  ${(o) => o.disabled && `
    cursor: not-allowed;
    button:disabled {
      pointer-events: none;
    }
  `};
`;
function h(o) {
  return o && (o.hasOwnProperty("backgroundColor") || o.hasOwnProperty("borderColor") || o.hasOwnProperty("color")) ? {
    background: o.backgroundColor,
    border: o.borderColor,
    text: o.color
  } : o;
}
const f = i(s), x = t(f, h), B = g([l, p, u]);
export {
  C as Button100,
  w as ButtonCompWrapper,
  x as ButtonStyleControl,
  B as buttonRefMethods,
  b as getButtonStyle
};
