import { j as r } from "../../../../_virtual/jsx-runtime.js";
import m from "../../../../icons/ChevronDown.js";
import c from "../../../../icons/ChevronUp.js";
import { SelectInput as a } from "../../../Field/dropdown/styles.js";
import { Border as s } from "../../../Field/styles.js";
import { Wrapper as u, LeadingIconWrapper as x, IconWrapper as j } from "./styles.js";
function W({
  hasError: t,
  disabled: e,
  handleClick: p,
  placeholder: n,
  visible: i,
  leadingIcon: o
}) {
  return /* @__PURE__ */ r.jsx(u, { children: /* @__PURE__ */ r.jsx(s, { hasError: t, disabled: e, children: /* @__PURE__ */ r.jsxs(
    a,
    {
      role: "button",
      "aria-haspopup": "true",
      onClick: p,
      variant: "medium",
      disabled: e,
      hasText: !0,
      children: [
        o && /* @__PURE__ */ r.jsx(x, { disabled: e, children: o }),
        n,
        /* @__PURE__ */ r.jsx("input", { name: "date-picker-select-input", "aria-autocomplete": "none" }),
        /* @__PURE__ */ r.jsx(j, { disabled: e, children: i ? /* @__PURE__ */ r.jsx(c, {}) : /* @__PURE__ */ r.jsx(m, {}) })
      ]
    }
  ) }) });
}
export {
  W as DatePickerSelect
};
