import { bn as pe, bt as ge, bu as fe, bv as be, bw as ye, bx as me, al as ve, aa as Ie, aD as he, by as Se, am as Ce, bz as Ze, bA as We, r as le, bB as Q, bC as Oe, J as Ge, m as H, u as Be, j as z, W as Re, l as xe, O as Ee, T as Pe, P as Te, X as Ve } from "./index-CsBCemCF.js";
import M, { memo as we, useContext as _e, useCallback as q } from "react";
import { u as Le } from "./useBasicWidgetState-KOlq_goV.js";
import { T as Ae } from "./timepicker-Buj3NwSV.js";
var $e = pe.Consumer;
const Ne = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
  __proto__: null,
  ThemeConsumer: $e,
  ThemeProvider: ge,
  createThemedStyled: fe,
  createThemedUseStyletron: be,
  createThemedWithStyle: ye,
  expandBorderStyles: me,
  hexToRgb: ve,
  styled: Ie,
  useStyletron: he,
  withStyle: Se,
  withWrapper: Ce
}, Symbol.toStringTag, { value: "Module" }));
var C = {};
const U = /* @__PURE__ */ Ze(Ne);
var E = {}, K;
function ze() {
  if (K) return E;
  K = 1, Object.defineProperty(E, "__esModule", {
    value: !0
  }), E.STATE_CHANGE_TYPE = E.SIZE = E.ENHANCER_POSITION = E.CUSTOM_INPUT_TYPE = E.ADJOINED = void 0;
  var g = {
    change: "change"
  };
  E.STATE_CHANGE_TYPE = g;
  var s = {
    textarea: "textarea"
  };
  E.CUSTOM_INPUT_TYPE = s;
  var I = {
    none: "none",
    left: "left",
    right: "right",
    both: "both"
  };
  E.ADJOINED = I;
  var y = {
    mini: "mini",
    default: "default",
    compact: "compact",
    large: "large"
  };
  E.SIZE = y;
  var v = {
    start: "start",
    end: "end"
  };
  return E.ENHANCER_POSITION = v, E;
}
var D = {}, V = {}, j = {}, ee;
function Fe() {
  if (ee) return j;
  ee = 1, Object.defineProperty(j, "__esModule", {
    value: !0
  }), j.default = s;
  function g(y) {
    "@babel/helpers - typeof";
    return g = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(v) {
      return typeof v;
    } : function(v) {
      return v && typeof Symbol == "function" && v.constructor === Symbol && v !== Symbol.prototype ? "symbol" : typeof v;
    }, g(y);
  }
  function s(y) {
    y = y || {};
    for (var v = arguments.length <= 1 ? 0 : arguments.length - 1, m, b, h = 0; h < v; h++) {
      m = (h + 1 < 1 || arguments.length <= h + 1 ? void 0 : arguments[h + 1]) || {};
      for (var f in m)
        g(m[f]) !== void 0 && (b = m[f], I(b) ? y[f] = s(
          /* eslint-disable-next-line no-mixed-operators */
          y[f] || Array.isArray(b) && [] || {},
          b
        ) : y[f] = b);
    }
    return y;
  }
  function I(y) {
    return Array.isArray(y) || {}.toString.call(y) == "[object Object]";
  }
  return j;
}
var te;
function ue() {
  if (te) return V;
  te = 1, Object.defineProperty(V, "__esModule", {
    value: !0
  }), V.getOverride = R, V.getOverrideProps = G, V.getOverrides = $, V.mergeConfigurationOverrides = A, V.mergeOverride = T, V.mergeOverrides = L, V.toObjectOverride = P, V.useOverrides = N;
  var g = m(M), s = We(), I = y(/* @__PURE__ */ Fe());
  function y(o) {
    return o && o.__esModule ? o : { default: o };
  }
  function v(o) {
    if (typeof WeakMap != "function") return null;
    var t = /* @__PURE__ */ new WeakMap(), u = /* @__PURE__ */ new WeakMap();
    return (v = function(r) {
      return r ? u : t;
    })(o);
  }
  function m(o, t) {
    if (o && o.__esModule)
      return o;
    if (o === null || W(o) !== "object" && typeof o != "function")
      return { default: o };
    var u = v(t);
    if (u && u.has(o))
      return u.get(o);
    var c = {}, r = Object.defineProperty && Object.getOwnPropertyDescriptor;
    for (var a in o)
      if (a !== "default" && Object.prototype.hasOwnProperty.call(o, a)) {
        var l = r ? Object.getOwnPropertyDescriptor(o, a) : null;
        l && (l.get || l.set) ? Object.defineProperty(c, a, l) : c[a] = o[a];
      }
    return c.default = o, u && u.set(o, c), c;
  }
  function b() {
    return b = Object.assign ? Object.assign.bind() : function(o) {
      for (var t = 1; t < arguments.length; t++) {
        var u = arguments[t];
        for (var c in u)
          Object.prototype.hasOwnProperty.call(u, c) && (o[c] = u[c]);
      }
      return o;
    }, b.apply(this, arguments);
  }
  function h(o, t) {
    var u = Object.keys(o);
    if (Object.getOwnPropertySymbols) {
      var c = Object.getOwnPropertySymbols(o);
      t && (c = c.filter(function(r) {
        return Object.getOwnPropertyDescriptor(o, r).enumerable;
      })), u.push.apply(u, c);
    }
    return u;
  }
  function f(o) {
    for (var t = 1; t < arguments.length; t++) {
      var u = arguments[t] != null ? arguments[t] : {};
      t % 2 ? h(Object(u), !0).forEach(function(c) {
        O(o, c, u[c]);
      }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(u)) : h(Object(u)).forEach(function(c) {
        Object.defineProperty(o, c, Object.getOwnPropertyDescriptor(u, c));
      });
    }
    return o;
  }
  function O(o, t, u) {
    return t in o ? Object.defineProperty(o, t, { value: u, enumerable: !0, configurable: !0, writable: !0 }) : o[t] = u, o;
  }
  function W(o) {
    "@babel/helpers - typeof";
    return W = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
      return typeof t;
    } : function(t) {
      return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
    }, W(o);
  }
  function R(o) {
    return (0, s.isValidElementType)(o) ? o : o && W(o) === "object" ? o.component : o;
  }
  function G(o) {
    return o && W(o) === "object" ? W(o.props) === "object" ? f(f({}, o.props), {}, {
      $style: o.style
    }) : {
      $style: o.style
    } : {};
  }
  function P(o) {
    return (0, s.isValidElementType)(o) ? {
      // eslint-disable-next-line @typescript-eslint/no-explicit-any
      component: o
    } : o || {};
  }
  function $(o, t) {
    var u = R(o) || t;
    if (o && W(o) === "object" && typeof o.props == "function") {
      process.env.NODE_ENV !== "production" && console.warn("baseui:Overrides Props as a function will be removed in the next major version. Override the whole component instead. See https://baseweb.design/guides/understanding-overrides/#override-the-entire-subcomponent");
      var c = /* @__PURE__ */ g.forwardRef(function(a, l) {
        var n = o.props(a), e = G(f(f({}, o), {}, {
          props: n
        }));
        return /* @__PURE__ */ g.createElement(u, b({
          ref: l
        }, e));
      });
      return c.displayName = u.displayName, [c, {}];
    }
    var r = G(o);
    return [u, r];
  }
  function L() {
    var o = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, u = Object.assign({}, o, t), c = Object.keys(u);
    return c.reduce(function(r, a) {
      return r[a] = T(P(o[a]), P(t[a])), r;
    }, {});
  }
  function T(o, t) {
    var u = f(f({}, o), t);
    return o.props && t.props && (u.props = A(o.props, t.props)), o.style && t.style && (u.style = A(o.style, t.style)), u;
  }
  function A(o, t) {
    return W(o) === "object" && W(t) === "object" ? (0, I.default)({}, o, t) : function() {
      return (0, I.default)({}, typeof o == "function" ? o.apply(void 0, arguments) : o, typeof t == "function" ? t.apply(void 0, arguments) : t);
    };
  }
  function N(o) {
    var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
    return g.useMemo(function() {
      return Object.keys(o).reduce(function(u, c) {
        return u[c] = $(t[c], o[c]), u;
      }, {});
    }, [t]);
  }
  return V;
}
var X = {}, F = {}, re;
function De() {
  if (re) return F;
  re = 1, Object.defineProperty(F, "__esModule", {
    value: !0
  }), F.Svg = void 0, F.getSvgStyles = s;
  var g = U;
  function s(y) {
    var v = y.$theme, m = y.$size, b = y.$color, h = v.sizing.scale600;
    m && (v.sizing[m] ? h = v.sizing[m] : typeof m == "number" ? h = "".concat(m, "px") : h = m);
    var f = "currentColor";
    return b && (v.colors[b] ? f = v.colors[b] : f = b), {
      display: "inline-block",
      fill: f,
      color: f,
      height: h,
      width: h
    };
  }
  var I = (0, g.styled)("svg", s);
  return F.Svg = I, I.displayName = "Svg", I.displayName = "Svg", F;
}
var J = {}, ne;
function Xe() {
  if (ne) return J;
  ne = 1, Object.defineProperty(J, "__esModule", {
    value: !0
  }), J.default = g;
  function g(s) {
    var I = {};
    for (var y in s)
      y[0] !== "$" && (I[y] = s[y]);
    return I;
  }
  return J;
}
var ie;
function je() {
  if (ie) return X;
  ie = 1;
  function g(r) {
    "@babel/helpers - typeof";
    return g = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(a) {
      return typeof a;
    } : function(a) {
      return a && typeof Symbol == "function" && a.constructor === Symbol && a !== Symbol.prototype ? "symbol" : typeof a;
    }, g(r);
  }
  Object.defineProperty(X, "__esModule", {
    value: !0
  }), X.default = void 0;
  var s = f(M), I = /* @__PURE__ */ ue(), y = /* @__PURE__ */ De(), v = b(/* @__PURE__ */ Xe()), m = ["children", "title", "size", "color", "overrides"];
  function b(r) {
    return r && r.__esModule ? r : { default: r };
  }
  function h(r) {
    if (typeof WeakMap != "function") return null;
    var a = /* @__PURE__ */ new WeakMap(), l = /* @__PURE__ */ new WeakMap();
    return (h = function(e) {
      return e ? l : a;
    })(r);
  }
  function f(r, a) {
    if (r && r.__esModule)
      return r;
    if (r === null || g(r) !== "object" && typeof r != "function")
      return { default: r };
    var l = h(a);
    if (l && l.has(r))
      return l.get(r);
    var n = {}, e = Object.defineProperty && Object.getOwnPropertyDescriptor;
    for (var i in r)
      if (i !== "default" && Object.prototype.hasOwnProperty.call(r, i)) {
        var p = e ? Object.getOwnPropertyDescriptor(r, i) : null;
        p && (p.get || p.set) ? Object.defineProperty(n, i, p) : n[i] = r[i];
      }
    return n.default = r, l && l.set(r, n), n;
  }
  function O() {
    return O = Object.assign ? Object.assign.bind() : function(r) {
      for (var a = 1; a < arguments.length; a++) {
        var l = arguments[a];
        for (var n in l)
          Object.prototype.hasOwnProperty.call(l, n) && (r[n] = l[n]);
      }
      return r;
    }, O.apply(this, arguments);
  }
  function W(r, a) {
    var l = Object.keys(r);
    if (Object.getOwnPropertySymbols) {
      var n = Object.getOwnPropertySymbols(r);
      a && (n = n.filter(function(e) {
        return Object.getOwnPropertyDescriptor(r, e).enumerable;
      })), l.push.apply(l, n);
    }
    return l;
  }
  function R(r) {
    for (var a = 1; a < arguments.length; a++) {
      var l = arguments[a] != null ? arguments[a] : {};
      a % 2 ? W(Object(l), !0).forEach(function(n) {
        G(r, n, l[n]);
      }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(r, Object.getOwnPropertyDescriptors(l)) : W(Object(l)).forEach(function(n) {
        Object.defineProperty(r, n, Object.getOwnPropertyDescriptor(l, n));
      });
    }
    return r;
  }
  function G(r, a, l) {
    return a in r ? Object.defineProperty(r, a, { value: l, enumerable: !0, configurable: !0, writable: !0 }) : r[a] = l, r;
  }
  function P(r, a) {
    return N(r) || A(r, a) || L(r, a) || $();
  }
  function $() {
    throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
  }
  function L(r, a) {
    if (r) {
      if (typeof r == "string") return T(r, a);
      var l = Object.prototype.toString.call(r).slice(8, -1);
      if (l === "Object" && r.constructor && (l = r.constructor.name), l === "Map" || l === "Set") return Array.from(r);
      if (l === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(l)) return T(r, a);
    }
  }
  function T(r, a) {
    (a == null || a > r.length) && (a = r.length);
    for (var l = 0, n = new Array(a); l < a; l++)
      n[l] = r[l];
    return n;
  }
  function A(r, a) {
    var l = r == null ? null : typeof Symbol < "u" && r[Symbol.iterator] || r["@@iterator"];
    if (l != null) {
      var n = [], e = !0, i = !1, p, d;
      try {
        for (l = l.call(r); !(e = (p = l.next()).done) && (n.push(p.value), !(a && n.length === a)); e = !0)
          ;
      } catch (S) {
        i = !0, d = S;
      } finally {
        try {
          !e && l.return != null && l.return();
        } finally {
          if (i) throw d;
        }
      }
      return n;
    }
  }
  function N(r) {
    if (Array.isArray(r)) return r;
  }
  function o(r, a) {
    if (r == null) return {};
    var l = t(r, a), n, e;
    if (Object.getOwnPropertySymbols) {
      var i = Object.getOwnPropertySymbols(r);
      for (e = 0; e < i.length; e++)
        n = i[e], !(a.indexOf(n) >= 0) && Object.prototype.propertyIsEnumerable.call(r, n) && (l[n] = r[n]);
    }
    return l;
  }
  function t(r, a) {
    if (r == null) return {};
    var l = {}, n = Object.keys(r), e, i;
    for (i = 0; i < n.length; i++)
      e = n[i], !(a.indexOf(e) >= 0) && (l[e] = r[e]);
    return l;
  }
  var u = function(a, l) {
    var n = a.children, e = a.title, i = a.size, p = a.color, d = a.overrides, S = d === void 0 ? {} : d, Z = o(a, m), x = (0, I.getOverrides)(S.Svg, y.Svg), w = P(x, 2), B = w[0], _ = w[1], Y = B.__STYLETRON__ ? R(R({
      title: e,
      $color: p,
      $size: i
    }, Z), _) : R(R({
      title: e,
      color: p,
      size: i
    }, (0, v.default)(Z)), (0, v.default)(_));
    return /* @__PURE__ */ s.createElement(B, O({
      "data-baseweb": "icon",
      ref: l
    }, Y), e ? /* @__PURE__ */ s.createElement("title", null, e) : null, n);
  }, c = /* @__PURE__ */ s.forwardRef(u);
  return X.default = c, X;
}
var oe;
function Je() {
  if (oe) return D;
  oe = 1;
  function g(t) {
    "@babel/helpers - typeof";
    return g = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(u) {
      return typeof u;
    } : function(u) {
      return u && typeof Symbol == "function" && u.constructor === Symbol && u !== Symbol.prototype ? "symbol" : typeof u;
    }, g(t);
  }
  Object.defineProperty(D, "__esModule", {
    value: !0
  }), D.default = void 0;
  var s = f(M), I = U, y = /* @__PURE__ */ ue(), v = b(/* @__PURE__ */ je()), m = ["title", "size", "color", "overrides"];
  function b(t) {
    return t && t.__esModule ? t : { default: t };
  }
  function h(t) {
    if (typeof WeakMap != "function") return null;
    var u = /* @__PURE__ */ new WeakMap(), c = /* @__PURE__ */ new WeakMap();
    return (h = function(a) {
      return a ? c : u;
    })(t);
  }
  function f(t, u) {
    if (t && t.__esModule)
      return t;
    if (t === null || g(t) !== "object" && typeof t != "function")
      return { default: t };
    var c = h(u);
    if (c && c.has(t))
      return c.get(t);
    var r = {}, a = Object.defineProperty && Object.getOwnPropertyDescriptor;
    for (var l in t)
      if (l !== "default" && Object.prototype.hasOwnProperty.call(t, l)) {
        var n = a ? Object.getOwnPropertyDescriptor(t, l) : null;
        n && (n.get || n.set) ? Object.defineProperty(r, l, n) : r[l] = t[l];
      }
    return r.default = t, c && c.set(t, r), r;
  }
  function O() {
    return O = Object.assign ? Object.assign.bind() : function(t) {
      for (var u = 1; u < arguments.length; u++) {
        var c = arguments[u];
        for (var r in c)
          Object.prototype.hasOwnProperty.call(c, r) && (t[r] = c[r]);
      }
      return t;
    }, O.apply(this, arguments);
  }
  function W(t, u) {
    if (t == null) return {};
    var c = R(t, u), r, a;
    if (Object.getOwnPropertySymbols) {
      var l = Object.getOwnPropertySymbols(t);
      for (a = 0; a < l.length; a++)
        r = l[a], !(u.indexOf(r) >= 0) && Object.prototype.propertyIsEnumerable.call(t, r) && (c[r] = t[r]);
    }
    return c;
  }
  function R(t, u) {
    if (t == null) return {};
    var c = {}, r = Object.keys(t), a, l;
    for (l = 0; l < r.length; l++)
      a = r[l], !(u.indexOf(a) >= 0) && (c[a] = t[a]);
    return c;
  }
  function G(t, u) {
    return A(t) || T(t, u) || $(t, u) || P();
  }
  function P() {
    throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
  }
  function $(t, u) {
    if (t) {
      if (typeof t == "string") return L(t, u);
      var c = Object.prototype.toString.call(t).slice(8, -1);
      if (c === "Object" && t.constructor && (c = t.constructor.name), c === "Map" || c === "Set") return Array.from(t);
      if (c === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(c)) return L(t, u);
    }
  }
  function L(t, u) {
    (u == null || u > t.length) && (u = t.length);
    for (var c = 0, r = new Array(u); c < u; c++)
      r[c] = t[c];
    return r;
  }
  function T(t, u) {
    var c = t == null ? null : typeof Symbol < "u" && t[Symbol.iterator] || t["@@iterator"];
    if (c != null) {
      var r = [], a = !0, l = !1, n, e;
      try {
        for (c = c.call(t); !(a = (n = c.next()).done) && (r.push(n.value), !(u && r.length === u)); a = !0)
          ;
      } catch (i) {
        l = !0, e = i;
      } finally {
        try {
          !a && c.return != null && c.return();
        } finally {
          if (l) throw e;
        }
      }
      return r;
    }
  }
  function A(t) {
    if (Array.isArray(t)) return t;
  }
  function N(t, u) {
    var c = (0, I.useStyletron)(), r = G(c, 2), a = r[1], l = t.title, n = l === void 0 ? "Delete Alt" : l, e = t.size, i = t.color, p = t.overrides, d = p === void 0 ? {} : p, S = W(t, m), Z = (0, y.mergeOverride)(
      // Icons from the theme target the SVG override in the underlying Icon component
      {
        component: a.icons && a.icons.DeleteAlt ? a.icons.DeleteAlt : null
      },
      d && d.Svg ? (0, y.toObjectOverride)(d.Svg) : {}
    );
    return /* @__PURE__ */ s.createElement(v.default, O({
      viewBox: "0 0 24 24",
      ref: u,
      title: n,
      size: e,
      color: i,
      overrides: {
        Svg: Z
      }
    }, S), /* @__PURE__ */ s.createElement("path", {
      fillRule: "evenodd",
      clipRule: "evenodd",
      d: "M12 20C16.4183 20 20 16.4183 20 12C20 7.58173 16.4183 4 12 4C7.58173 4 4 7.58173 4 12C4 16.4183 7.58173 20 12 20ZM10.0303 8.96967C9.73743 8.67679 9.26257 8.67679 8.96967 8.96967C8.67676 9.26257 8.67676 9.73743 8.96967 10.0303L10.9393 12L8.96967 13.9697C8.67676 14.2626 8.67676 14.7374 8.96967 15.0303C9.26257 15.3232 9.73743 15.3232 10.0303 15.0303L12 13.0607L13.9697 15.0303C14.2626 15.3232 14.7374 15.3232 15.0303 15.0303C15.3232 14.7374 15.3232 14.2626 15.0303 13.9697L13.0607 12L15.0303 10.0303C15.3232 9.73743 15.3232 9.26257 15.0303 8.96967C14.7374 8.67679 14.2626 8.67679 13.9697 8.96967L12 10.9393L10.0303 8.96967Z"
    }));
  }
  var o = /* @__PURE__ */ s.forwardRef(N);
  return D.default = o, D;
}
var ae;
function Ye() {
  if (ae) return C;
  ae = 1, Object.defineProperty(C, "__esModule", {
    value: !0
  }), C.getRootStyles = C.getInputStyles = C.getInputContainerStyles = C.StyledMaskToggleButton = C.StyledClearIconContainer = C.StyledClearIcon = C.Root = C.InputEnhancer = C.InputContainer = C.Input = void 0;
  var g = U, s = /* @__PURE__ */ ze(), I = y(/* @__PURE__ */ Je());
  function y(n) {
    return n && n.__esModule ? n : { default: n };
  }
  function v(n, e) {
    var i = Object.keys(n);
    if (Object.getOwnPropertySymbols) {
      var p = Object.getOwnPropertySymbols(n);
      e && (p = p.filter(function(d) {
        return Object.getOwnPropertyDescriptor(n, d).enumerable;
      })), i.push.apply(i, p);
    }
    return i;
  }
  function m(n) {
    for (var e = 1; e < arguments.length; e++) {
      var i = arguments[e] != null ? arguments[e] : {};
      e % 2 ? v(Object(i), !0).forEach(function(p) {
        b(n, p, i[p]);
      }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(i)) : v(Object(i)).forEach(function(p) {
        Object.defineProperty(n, p, Object.getOwnPropertyDescriptor(i, p));
      });
    }
    return n;
  }
  function b(n, e, i) {
    return e in n ? Object.defineProperty(n, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : n[e] = i, n;
  }
  var h = (0, g.styled)("button", function(n) {
    var e, i = n.$theme, p = n.$size, d = n.$isFocusVisible, S = (e = {}, b(e, s.SIZE.mini, i.sizing.scale400), b(e, s.SIZE.compact, i.sizing.scale400), b(e, s.SIZE.default, i.sizing.scale300), b(e, s.SIZE.large, i.sizing.scale200), e)[p];
    return {
      display: "flex",
      alignItems: "center",
      borderTopStyle: "none",
      borderBottomStyle: "none",
      borderLeftStyle: "none",
      borderRightStyle: "none",
      background: "none",
      paddingLeft: S,
      paddingRight: S,
      outline: d ? "solid 3px ".concat(i.colors.accent) : "none",
      color: i.colors.contentPrimary
    };
  });
  C.StyledMaskToggleButton = h, h.displayName = "StyledMaskToggleButton", h.displayName = "StyledMaskToggleButton";
  var f = (0, g.styled)("div", function(n) {
    var e, i = n.$alignTop, p = i === void 0 ? !1 : i, d = n.$size, S = n.$theme, Z = (e = {}, b(e, s.SIZE.mini, S.sizing.scale200), b(e, s.SIZE.compact, S.sizing.scale200), b(e, s.SIZE.default, S.sizing.scale100), b(e, s.SIZE.large, S.sizing.scale0), e)[d];
    return {
      display: "flex",
      alignItems: p ? "flex-start" : "center",
      paddingLeft: Z,
      paddingRight: Z,
      paddingTop: p ? S.sizing.scale500 : "0px",
      color: S.colors.contentPrimary
    };
  });
  C.StyledClearIconContainer = f, f.displayName = "StyledClearIconContainer", f.displayName = "StyledClearIconContainer";
  var O = (0, g.styled)(I.default, function(n) {
    var e = n.$theme, i = n.$isFocusVisible;
    return {
      cursor: "pointer",
      outline: i ? "solid 3px ".concat(e.colors.accent) : "none"
    };
  });
  C.StyledClearIcon = O, O.displayName = "StyledClearIcon", O.displayName = "StyledClearIcon";
  function W(n, e) {
    var i;
    return (i = {}, b(i, s.SIZE.mini, {
      paddingTop: e.scale100,
      paddingBottom: e.scale100,
      paddingLeft: e.scale550,
      paddingRight: e.scale550
    }), b(i, s.SIZE.compact, {
      paddingTop: e.scale200,
      paddingBottom: e.scale200,
      paddingLeft: e.scale550,
      paddingRight: e.scale550
    }), b(i, s.SIZE.default, {
      paddingTop: e.scale400,
      paddingBottom: e.scale400,
      paddingLeft: e.scale550,
      paddingRight: e.scale550
    }), b(i, s.SIZE.large, {
      paddingTop: e.scale550,
      paddingBottom: e.scale550,
      paddingLeft: e.scale550,
      paddingRight: e.scale550
    }), i)[n];
  }
  function R(n, e, i, p, d) {
    var S = n === s.ADJOINED.both || n === s.ADJOINED.left && p !== "rtl" || n === s.ADJOINED.right && p === "rtl" || d && p === "rtl", Z = n === s.ADJOINED.both || n === s.ADJOINED.right && p !== "rtl" || n === s.ADJOINED.left && p === "rtl" || d && p !== "rtl";
    return {
      paddingLeft: S ? i.scale550 : "0px",
      paddingRight: Z ? i.scale550 : "0px"
    };
  }
  function G(n, e) {
    var i;
    return (i = {}, b(i, s.SIZE.mini, e.font100), b(i, s.SIZE.compact, e.font200), b(i, s.SIZE.default, e.font300), b(i, s.SIZE.large, e.font400), i)[n];
  }
  function P(n, e, i) {
    var p = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : !1, d = arguments.length > 4 ? arguments[4] : void 0;
    return n ? {
      borderLeftColor: d.inputFillDisabled,
      borderRightColor: d.inputFillDisabled,
      borderTopColor: d.inputFillDisabled,
      borderBottomColor: d.inputFillDisabled,
      backgroundColor: d.inputFillDisabled
    } : e ? {
      borderLeftColor: d.borderSelected,
      borderRightColor: d.borderSelected,
      borderTopColor: d.borderSelected,
      borderBottomColor: d.borderSelected,
      backgroundColor: d.inputFillActive
    } : i ? {
      borderLeftColor: d.inputBorderError,
      borderRightColor: d.inputBorderError,
      borderTopColor: d.inputBorderError,
      borderBottomColor: d.inputBorderError,
      backgroundColor: d.inputFillError
    } : p ? {
      borderLeftColor: d.inputBorderPositive,
      borderRightColor: d.inputBorderPositive,
      borderTopColor: d.inputBorderPositive,
      borderBottomColor: d.inputBorderPositive,
      backgroundColor: d.inputFillPositive
    } : {
      borderLeftColor: d.inputBorder,
      borderRightColor: d.inputBorder,
      borderTopColor: d.inputBorder,
      borderBottomColor: d.inputBorder,
      backgroundColor: d.inputFill
    };
  }
  function $(n, e) {
    var i = e.inputBorderRadius;
    return n === s.SIZE.mini && (i = e.inputBorderRadiusMini), {
      borderTopLeftRadius: i,
      borderBottomLeftRadius: i,
      borderTopRightRadius: i,
      borderBottomRightRadius: i
    };
  }
  var L = function(e) {
    var i = e.$isFocused, p = e.$adjoined, d = e.$error, S = e.$disabled, Z = e.$positive, x = e.$size, w = e.$theme, B = e.$theme, _ = B.borders, Y = B.colors, ce = B.sizing, de = B.typography, k = B.animation, se = e.$hasIconTrailing;
    return m(m(m(m({
      boxSizing: "border-box",
      display: "flex",
      overflow: "hidden",
      width: "100%",
      borderLeftWidth: "2px",
      borderRightWidth: "2px",
      borderTopWidth: "2px",
      borderBottomWidth: "2px",
      borderLeftStyle: "solid",
      borderRightStyle: "solid",
      borderTopStyle: "solid",
      borderBottomStyle: "solid",
      transitionProperty: "border",
      transitionDuration: k.timing200,
      transitionTimingFunction: k.easeOutCurve
    }, $(x, _)), G(x, de)), P(S, i, d, Z, Y)), R(p, x, ce, w.direction, se));
  };
  C.getRootStyles = L;
  var T = (0, g.styled)("div", L);
  C.Root = T, T.displayName = "Root", T.displayName = "Root";
  function A(n, e) {
    var i;
    return (i = {}, b(i, s.SIZE.mini, {
      paddingRight: e.scale400,
      paddingLeft: e.scale400
    }), b(i, s.SIZE.compact, {
      paddingRight: e.scale400,
      paddingLeft: e.scale400
    }), b(i, s.SIZE.default, {
      paddingRight: e.scale300,
      paddingLeft: e.scale300
    }), b(i, s.SIZE.large, {
      paddingRight: e.scale200,
      paddingLeft: e.scale200
    }), i)[n];
  }
  function N(n, e, i, p, d) {
    return n ? {
      color: d.inputEnhancerTextDisabled,
      backgroundColor: d.inputFillDisabled
    } : e ? {
      color: d.contentPrimary,
      backgroundColor: d.inputFillActive
    } : i ? {
      color: d.contentPrimary,
      backgroundColor: d.inputFillError
    } : p ? {
      color: d.contentPrimary,
      backgroundColor: d.inputFillPositive
    } : {
      color: d.contentPrimary,
      backgroundColor: d.inputFill
    };
  }
  var o = (0, g.styled)("div", function(n) {
    var e = n.$size, i = n.$disabled, p = n.$isFocused, d = n.$error, S = n.$positive, Z = n.$theme, x = Z.colors, w = Z.sizing, B = Z.typography, _ = Z.animation;
    return m(m(m({
      display: "flex",
      alignItems: "center",
      justifyContent: "center",
      transitionProperty: "color, background-color",
      transitionDuration: _.timing200,
      transitionTimingFunction: _.easeOutCurve
    }, G(e, B)), A(e, w)), N(i, p, d, S, x));
  });
  C.InputEnhancer = o, o.displayName = "InputEnhancer", o.displayName = "InputEnhancer";
  function t(n, e, i, p, d) {
    return n ? {
      color: d.inputTextDisabled,
      backgroundColor: d.inputFillDisabled
    } : e ? {
      color: d.contentPrimary,
      backgroundColor: d.inputFillActive
    } : i ? {
      color: d.contentPrimary,
      backgroundColor: d.inputFillError
    } : p ? {
      color: d.contentPrimary,
      backgroundColor: d.inputFillPositive
    } : {
      color: d.contentPrimary,
      backgroundColor: d.inputFill
    };
  }
  var u = function(e) {
    var i = e.$isFocused, p = e.$error, d = e.$disabled, S = e.$positive, Z = e.$size, x = e.$theme, w = x.colors, B = x.typography, _ = x.animation;
    return m(m({
      display: "flex",
      width: "100%",
      transitionProperty: "background-color",
      transitionDuration: _.timing200,
      transitionTimingFunction: _.easeOutCurve
    }, G(Z, B)), t(d, i, p, S, w));
  };
  C.getInputContainerStyles = u;
  var c = (0, g.styled)("div", u);
  C.InputContainer = c, c.displayName = "InputContainer", c.displayName = "InputContainer";
  function r(n, e, i, p) {
    return n ? {
      color: p.inputTextDisabled,
      "-webkit-text-fill-color": p.inputTextDisabled,
      caretColor: p.contentPrimary,
      "::placeholder": {
        color: p.inputPlaceholderDisabled
      }
    } : {
      color: p.contentPrimary,
      caretColor: p.contentPrimary,
      "::placeholder": {
        color: p.inputPlaceholder
      }
    };
  }
  var a = function(e) {
    var i = e.$disabled, p = e.$isFocused, d = e.$error, S = e.$size, Z = e.$theme, x = Z.colors, w = Z.sizing, B = Z.typography;
    return m(m(m({
      boxSizing: "border-box",
      backgroundColor: "transparent",
      borderLeftWidth: 0,
      borderRightWidth: 0,
      borderTopWidth: 0,
      borderBottomWidth: 0,
      borderLeftStyle: "none",
      borderRightStyle: "none",
      borderTopStyle: "none",
      borderBottomStyle: "none",
      outline: "none",
      width: "100%",
      // See https://stackoverflow.com/a/33811151
      minWidth: 0,
      maxWidth: "100%",
      cursor: i ? "not-allowed" : "text",
      margin: "0",
      paddingTop: "0",
      paddingBottom: "0",
      paddingLeft: "0",
      paddingRight: "0"
    }, G(S, B)), W(S, w)), r(i, p, d, x));
  };
  C.getInputStyles = a;
  var l = (0, g.styled)("input", a);
  return C.Input = l, l.displayName = "Input", l.displayName = "Input", C;
}
var He = /* @__PURE__ */ Ye();
function Me() {
  return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop).";
}
const Ue = /* @__PURE__ */ le("div", process.env.NODE_ENV === "production" ? {
  target: "e1ipygm11"
} : {
  target: "e1ipygm11",
  label: "StyledClearIconContainer"
})(process.env.NODE_ENV === "production" ? {
  name: "1ucqwki",
  styles: "position:absolute;top:50%;right:2.05em"
} : {
  name: "1ucqwki",
  styles: "position:absolute;top:50%;right:2.05em/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi9ob21lL3J1bm5lci93b3JrL3N0bGl0ZS9zdGxpdGUvc3RyZWFtbGl0L2Zyb250ZW5kL2xpYi9zcmMvY29tcG9uZW50cy93aWRnZXRzL1RpbWVJbnB1dC9zdHlsZWQtY29tcG9uZW50cy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFvQndDIiwiZmlsZSI6Ii9ob21lL3J1bm5lci93b3JrL3N0bGl0ZS9zdGxpdGUvc3RyZWFtbGl0L2Zyb250ZW5kL2xpYi9zcmMvY29tcG9uZW50cy93aWRnZXRzL1RpbWVJbnB1dC9zdHlsZWQtY29tcG9uZW50cy50cyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogQ29weXJpZ2h0IChjKSBTdHJlYW1saXQgSW5jLiAoMjAxOC0yMDIyKSBTbm93Zmxha2UgSW5jLiAoMjAyMi0yMDI1KVxuICpcbiAqIExpY2Vuc2VkIHVuZGVyIHRoZSBBcGFjaGUgTGljZW5zZSwgVmVyc2lvbiAyLjAgKHRoZSBcIkxpY2Vuc2VcIik7XG4gKiB5b3UgbWF5IG5vdCB1c2UgdGhpcyBmaWxlIGV4Y2VwdCBpbiBjb21wbGlhbmNlIHdpdGggdGhlIExpY2Vuc2UuXG4gKiBZb3UgbWF5IG9idGFpbiBhIGNvcHkgb2YgdGhlIExpY2Vuc2UgYXRcbiAqXG4gKiAgICAgaHR0cDovL3d3dy5hcGFjaGUub3JnL2xpY2Vuc2VzL0xJQ0VOU0UtMi4wXG4gKlxuICogVW5sZXNzIHJlcXVpcmVkIGJ5IGFwcGxpY2FibGUgbGF3IG9yIGFncmVlZCB0byBpbiB3cml0aW5nLCBzb2Z0d2FyZVxuICogZGlzdHJpYnV0ZWQgdW5kZXIgdGhlIExpY2Vuc2UgaXMgZGlzdHJpYnV0ZWQgb24gYW4gXCJBUyBJU1wiIEJBU0lTLFxuICogV0lUSE9VVCBXQVJSQU5USUVTIE9SIENPTkRJVElPTlMgT0YgQU5ZIEtJTkQsIGVpdGhlciBleHByZXNzIG9yIGltcGxpZWQuXG4gKiBTZWUgdGhlIExpY2Vuc2UgZm9yIHRoZSBzcGVjaWZpYyBsYW5ndWFnZSBnb3Zlcm5pbmcgcGVybWlzc2lvbnMgYW5kXG4gKiBsaW1pdGF0aW9ucyB1bmRlciB0aGUgTGljZW5zZS5cbiAqL1xuXG5pbXBvcnQgaXNQcm9wVmFsaWQgZnJvbSBcIkBlbW90aW9uL2lzLXByb3AtdmFsaWRcIlxuaW1wb3J0IHN0eWxlZCBmcm9tIFwiQGVtb3Rpb24vc3R5bGVkXCJcbmltcG9ydCB7IFN0eWxlZERyb3Bkb3duTGlzdEl0ZW0gfSBmcm9tIFwiYmFzZXVpL3NlbGVjdFwiXG5cbmV4cG9ydCBjb25zdCBTdHlsZWRDbGVhckljb25Db250YWluZXIgPSBzdHlsZWQuZGl2KHtcbiAgcG9zaXRpb246IFwiYWJzb2x1dGVcIixcbiAgdG9wOiBcIjUwJVwiLFxuICByaWdodDogXCIyLjA1ZW1cIixcbn0pXG5cbmV4cG9ydCBjb25zdCBTdHlsZWRUaW1lRHJvcGRvd25MaXN0SXRlbSA9IHN0eWxlZChTdHlsZWREcm9wZG93bkxpc3RJdGVtLCB7XG4gIHNob3VsZEZvcndhcmRQcm9wOiBpc1Byb3BWYWxpZCxcbn0pKCh7IHRoZW1lLCAkaXNIaWdobGlnaHRlZCB9KSA9PiB7XG4gIHJldHVybiB7XG4gICAgcGFkZGluZ1JpZ2h0OiB0aGVtZS5zcGFjaW5nLmxnLFxuICAgIHBhZGRpbmdMZWZ0OiB0aGVtZS5zcGFjaW5nLmxnLFxuICAgIHBhZGRpbmdUb3A6IHRoZW1lLnNwYWNpbmcuc20sXG4gICAgcGFkZGluZ0JvdHRvbTogdGhlbWUuc3BhY2luZy5zbSxcbiAgICBiYWNrZ3JvdW5kOiAkaXNIaWdobGlnaHRlZCA/IHRoZW1lLmNvbG9ycy5kYXJrZW5lZEJnTWl4MTUgOiB1bmRlZmluZWQsXG5cbiAgICBcIiY6aG92ZXIsICY6YWN0aXZlLCAmOmZvY3VzLXZpc2libGVcIjoge1xuICAgICAgYmFja2dyb3VuZDogdGhlbWUuY29sb3JzLmRhcmtlbmVkQmdNaXgxNSxcbiAgICB9LFxuICB9XG59KVxuIl19 */",
  toString: Me
}), ke = /* @__PURE__ */ le(Oe, process.env.NODE_ENV === "production" ? {
  shouldForwardProp: Q,
  target: "e1ipygm10"
} : {
  shouldForwardProp: Q,
  target: "e1ipygm10",
  label: "StyledTimeDropdownListItem"
})(({
  theme: g,
  $isHighlighted: s
}) => ({
  paddingRight: g.spacing.lg,
  paddingLeft: g.spacing.lg,
  paddingTop: g.spacing.sm,
  paddingBottom: g.spacing.sm,
  background: s ? g.colors.darkenedBgMix15 : void 0,
  "&:hover, &:active, &:focus-visible": {
    background: g.colors.darkenedBgMix15
  }
}), process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi9ob21lL3J1bm5lci93b3JrL3N0bGl0ZS9zdGxpdGUvc3RyZWFtbGl0L2Zyb250ZW5kL2xpYi9zcmMvY29tcG9uZW50cy93aWRnZXRzL1RpbWVJbnB1dC9zdHlsZWQtY29tcG9uZW50cy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUEwQjBDIiwiZmlsZSI6Ii9ob21lL3J1bm5lci93b3JrL3N0bGl0ZS9zdGxpdGUvc3RyZWFtbGl0L2Zyb250ZW5kL2xpYi9zcmMvY29tcG9uZW50cy93aWRnZXRzL1RpbWVJbnB1dC9zdHlsZWQtY29tcG9uZW50cy50cyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogQ29weXJpZ2h0IChjKSBTdHJlYW1saXQgSW5jLiAoMjAxOC0yMDIyKSBTbm93Zmxha2UgSW5jLiAoMjAyMi0yMDI1KVxuICpcbiAqIExpY2Vuc2VkIHVuZGVyIHRoZSBBcGFjaGUgTGljZW5zZSwgVmVyc2lvbiAyLjAgKHRoZSBcIkxpY2Vuc2VcIik7XG4gKiB5b3UgbWF5IG5vdCB1c2UgdGhpcyBmaWxlIGV4Y2VwdCBpbiBjb21wbGlhbmNlIHdpdGggdGhlIExpY2Vuc2UuXG4gKiBZb3UgbWF5IG9idGFpbiBhIGNvcHkgb2YgdGhlIExpY2Vuc2UgYXRcbiAqXG4gKiAgICAgaHR0cDovL3d3dy5hcGFjaGUub3JnL2xpY2Vuc2VzL0xJQ0VOU0UtMi4wXG4gKlxuICogVW5sZXNzIHJlcXVpcmVkIGJ5IGFwcGxpY2FibGUgbGF3IG9yIGFncmVlZCB0byBpbiB3cml0aW5nLCBzb2Z0d2FyZVxuICogZGlzdHJpYnV0ZWQgdW5kZXIgdGhlIExpY2Vuc2UgaXMgZGlzdHJpYnV0ZWQgb24gYW4gXCJBUyBJU1wiIEJBU0lTLFxuICogV0lUSE9VVCBXQVJSQU5USUVTIE9SIENPTkRJVElPTlMgT0YgQU5ZIEtJTkQsIGVpdGhlciBleHByZXNzIG9yIGltcGxpZWQuXG4gKiBTZWUgdGhlIExpY2Vuc2UgZm9yIHRoZSBzcGVjaWZpYyBsYW5ndWFnZSBnb3Zlcm5pbmcgcGVybWlzc2lvbnMgYW5kXG4gKiBsaW1pdGF0aW9ucyB1bmRlciB0aGUgTGljZW5zZS5cbiAqL1xuXG5pbXBvcnQgaXNQcm9wVmFsaWQgZnJvbSBcIkBlbW90aW9uL2lzLXByb3AtdmFsaWRcIlxuaW1wb3J0IHN0eWxlZCBmcm9tIFwiQGVtb3Rpb24vc3R5bGVkXCJcbmltcG9ydCB7IFN0eWxlZERyb3Bkb3duTGlzdEl0ZW0gfSBmcm9tIFwiYmFzZXVpL3NlbGVjdFwiXG5cbmV4cG9ydCBjb25zdCBTdHlsZWRDbGVhckljb25Db250YWluZXIgPSBzdHlsZWQuZGl2KHtcbiAgcG9zaXRpb246IFwiYWJzb2x1dGVcIixcbiAgdG9wOiBcIjUwJVwiLFxuICByaWdodDogXCIyLjA1ZW1cIixcbn0pXG5cbmV4cG9ydCBjb25zdCBTdHlsZWRUaW1lRHJvcGRvd25MaXN0SXRlbSA9IHN0eWxlZChTdHlsZWREcm9wZG93bkxpc3RJdGVtLCB7XG4gIHNob3VsZEZvcndhcmRQcm9wOiBpc1Byb3BWYWxpZCxcbn0pKCh7IHRoZW1lLCAkaXNIaWdobGlnaHRlZCB9KSA9PiB7XG4gIHJldHVybiB7XG4gICAgcGFkZGluZ1JpZ2h0OiB0aGVtZS5zcGFjaW5nLmxnLFxuICAgIHBhZGRpbmdMZWZ0OiB0aGVtZS5zcGFjaW5nLmxnLFxuICAgIHBhZGRpbmdUb3A6IHRoZW1lLnNwYWNpbmcuc20sXG4gICAgcGFkZGluZ0JvdHRvbTogdGhlbWUuc3BhY2luZy5zbSxcbiAgICBiYWNrZ3JvdW5kOiAkaXNIaWdobGlnaHRlZCA/IHRoZW1lLmNvbG9ycy5kYXJrZW5lZEJnTWl4MTUgOiB1bmRlZmluZWQsXG5cbiAgICBcIiY6aG92ZXIsICY6YWN0aXZlLCAmOmZvY3VzLXZpc2libGVcIjoge1xuICAgICAgYmFja2dyb3VuZDogdGhlbWUuY29sb3JzLmRhcmtlbmVkQmdNaXgxNSxcbiAgICB9LFxuICB9XG59KVxuIl19 */");
function Qe({
  disabled: g,
  element: s,
  widgetMgr: I,
  fragmentId: y
}) {
  const [v, m] = Le({
    getStateFromWidgetMgr: qe,
    getDefaultStateFromProto: Ke,
    getCurrStateFromProto: et,
    updateWidgetMgrState: tt,
    element: s,
    widgetMgr: I,
    fragmentId: y
  }), b = _e(Ge), h = H(s.default) && !g, f = Be(), O = {
    Select: {
      props: {
        disabled: g,
        overrides: {
          ControlContainer: {
            style: {
              height: f.sizes.minElementHeight,
              // Baseweb requires long-hand props, short-hand leads to weird bugs & warnings.
              borderLeftWidth: f.sizes.borderWidth,
              borderRightWidth: f.sizes.borderWidth,
              borderTopWidth: f.sizes.borderWidth,
              borderBottomWidth: f.sizes.borderWidth
            }
          },
          IconsContainer: {
            style: () => ({
              paddingRight: f.spacing.sm
            })
          },
          ValueContainer: {
            style: () => ({
              lineHeight: f.lineHeights.inputWidget,
              // Baseweb requires long-hand props, short-hand leads to weird bugs & warnings.
              paddingRight: f.spacing.sm,
              paddingLeft: f.spacing.md,
              paddingBottom: f.spacing.sm,
              paddingTop: f.spacing.sm
            })
          },
          SingleValue: {
            style: {
              fontWeight: f.fontWeights.normal
            },
            props: {
              "data-testid": "stTimeInputTimeDisplay"
            }
          },
          Dropdown: {
            style: () => ({
              paddingTop: f.spacing.none,
              paddingBottom: f.spacing.none,
              // Somehow this adds an additional shadow, even though we already have
              // one on the popover, so we need to remove it here.
              boxShadow: "none",
              maxHeight: f.sizes.maxDropdownHeight
            })
          },
          DropdownListItem: {
            component: ke
          },
          // Nudge the dropdown menu by 1px so the focus state doesn't get cut off
          Popover: {
            props: {
              ignoreBoundary: b,
              overrides: {
                Body: {
                  style: () => ({
                    marginTop: f.spacing.px
                  })
                }
              }
            }
          },
          Placeholder: {
            style: () => ({
              color: f.colors.fadedText60
            })
          },
          SelectArrow: {
            component: Ve,
            props: {
              overrides: {
                Svg: {
                  style: () => ({
                    width: f.iconSizes.xl,
                    height: f.iconSizes.xl
                  })
                }
              }
            }
          }
        }
      }
    }
  }, W = q((G) => {
    const P = G === null ? null : rt(G);
    m({
      value: P,
      fromUi: !0
    });
  }, [m]), R = q(() => {
    W(null);
  }, [W]);
  return /* @__PURE__ */ z.jsxs("div", { className: "stTimeInput", "data-testid": "stTimeInput", children: [
    /* @__PURE__ */ z.jsx(Re, { label: s.label, disabled: g, labelVisibility: xe(s.labelVisibility?.value), children: s.help && /* @__PURE__ */ z.jsx(Ee, { children: /* @__PURE__ */ z.jsx(Pe, { content: s.help, placement: Te.TOP_RIGHT }) }) }),
    /* @__PURE__ */ z.jsx(
      Ae,
      {
        format: "24",
        step: s.step ? Number(s.step) : 900,
        value: H(v) ? void 0 : nt(v),
        onChange: W,
        overrides: O,
        nullable: h,
        creatable: !0,
        "aria-label": s.label
      }
    ),
    h && !H(v) && // The time picker doesn't have a built-in clearable functionality.
    // Therefore, we are adding the clear button here.
    /* @__PURE__ */ z.jsx(Ue, { onClick: R, "data-testid": "stTimeInputClearButton", children: /* @__PURE__ */ z.jsx(He.StyledClearIcon, { overrides: {
      Svg: {
        style: {
          color: f.colors.grayTextColor,
          // setting this width and height makes the clear-icon align with dropdown arrows of other input fields
          padding: f.spacing.threeXS,
          height: f.sizes.clearIconSize,
          width: f.sizes.clearIconSize,
          ":hover": {
            fill: f.colors.bodyText
          }
        }
      }
    }, $isFocusVisible: !1 }) })
  ] });
}
function qe(g, s) {
  return g.getStringValue(s) ?? null;
}
function Ke(g) {
  return g.default ?? null;
}
function et(g) {
  return g.value ?? null;
}
function tt(g, s, I, y) {
  s.setStringValue(g, I.value, {
    fromUi: I.fromUi
  }, y);
}
function rt(g) {
  const s = g.getHours().toString().padStart(2, "0"), I = g.getMinutes().toString().padStart(2, "0");
  return `${s}:${I}`;
}
function nt(g) {
  if (g === null)
    return null;
  const [s, I] = g.split(":").map(Number), y = /* @__PURE__ */ new Date();
  return y.setHours(s), y.setMinutes(I), y;
}
const ut = we(Qe);
export {
  ut as default
};
//# sourceMappingURL=index-CceKGChf.js.map
