import { A as p, B as v, C as b, E as w, M as P, V as N, k as A, p as E, w as I, z as M } from "./isArrayLikeObject.js";
import { C as B, E as F, M as m, S as _, f as o, j as S, k as T, m as $, u as y, w as O, x as C } from "./_baseUniq.js";
var G = /\s/;
function H(n) {
  for (var r = n.length; r-- && G.test(n.charAt(r)); ) ;
  return r;
}
var L = /^\s+/;
function R(n) {
  return n && n.slice(0, H(n) + 1).replace(L, "");
}
var x = NaN, c = /^[-+]0x[0-9a-f]+$/i, q = /^0b[01]+$/i, K = /^0o[0-7]+$/i, W = parseInt;
function X(n) {
  if (typeof n == "number") return n;
  if (m(n)) return x;
  if (v(n)) {
    var r = typeof n.valueOf == "function" ? n.valueOf() : n;
    n = v(r) ? r + "" : r;
  }
  if (typeof n != "string") return n === 0 ? n : +n;
  n = R(n);
  var t = q.test(n);
  return t || K.test(n) ? W(n.slice(2), t ? 2 : 8) : c.test(n) ? x : +n;
}
var g = 1 / 0, Y = 17976931348623157e292;
function z(n) {
  return n ? (n = X(n), n === g || n === -g ? (n < 0 ? -1 : 1) * Y : n === n ? n : 0) : n === 0 ? n : 0;
}
function D(n) {
  var r = z(n), t = r % 1;
  return r === r ? t ? r - t : r : 0;
}
function en(n) {
  return n != null && n.length ? C(n, 1) : [];
}
var l = Object.prototype, J = l.hasOwnProperty, fn = w(function(n, r) {
  n = Object(n);
  var t = -1, s = r.length, i = s > 2 ? r[2] : void 0;
  for (i && b(r[0], r[1], i) && (s = 1); ++t < s; )
    for (var f = r[t], a = E(f), e = -1, d = a.length; ++e < d; ) {
      var h = a[e], u = n[h];
      (u === void 0 || p(u, l[h]) && !J.call(n, h)) && (n[h] = f[h]);
    }
  return n;
});
function dn(n) {
  var r = n == null ? 0 : n.length;
  return r ? n[r - 1] : void 0;
}
function Q(n) {
  return function(r, t, s) {
    var i = Object(r);
    if (!I(r)) {
      var f = o(t, 3);
      r = F(r), t = function(e) {
        return f(i[e], e, i);
      };
    }
    var a = n(r, t, s);
    return a > -1 ? i[f ? r[a] : a] : void 0;
  };
}
var U = Math.max;
function Z(n, r, t) {
  var s = n == null ? 0 : n.length;
  if (!s) return -1;
  var i = t == null ? 0 : D(t);
  return i < 0 && (i = U(s + i, 0)), T(n, o(r, 3), i);
}
var hn = Q(Z);
function V(n, r) {
  var t = -1, s = I(n) ? Array(n.length) : [];
  return y(n, function(i, f, a) {
    s[++t] = r(i, f, a);
  }), s;
}
function un(n, r) {
  return (N(n) ? S : V)(n, o(r, 3));
}
var k = Object.prototype.hasOwnProperty;
function j(n, r) {
  return n != null && k.call(n, r);
}
function vn(n, r) {
  return n != null && $(n, r, j);
}
function nn(n, r) {
  return n < r;
}
function rn(n, r, t) {
  for (var s = -1, i = n.length; ++s < i; ) {
    var f = n[s], a = r(f);
    if (a != null && (e === void 0 ? a === a && !m(a) : t(a, e))) var e = a, d = f;
  }
  return d;
}
function on(n) {
  return n && n.length ? rn(n, M, nn) : void 0;
}
function tn(n, r, t, s) {
  if (!v(n)) return n;
  r = O(r, n);
  for (var i = -1, f = r.length, a = f - 1, e = n; e != null && ++i < f; ) {
    var d = B(r[i]), h = t;
    if (d === "__proto__" || d === "constructor" || d === "prototype") return n;
    if (i != a) {
      var u = e[d];
      h = s ? s(u, d, e) : void 0, h === void 0 && (h = v(u) ? u : P(r[i + 1]) ? [] : {});
    }
    A(e, d, h), e = e[d];
  }
  return n;
}
function xn(n, r, t) {
  for (var s = -1, i = r.length, f = {}; ++s < i; ) {
    var a = r[s], e = _(n, a);
    t(e, a) && tn(f, O(a, n), e);
  }
  return f;
}
export {
  vn as a,
  hn as c,
  en as d,
  D as f,
  nn as i,
  dn as l,
  on as n,
  un as o,
  z as p,
  rn as r,
  V as s,
  xn as t,
  fn as u
};

//# sourceMappingURL=_basePickBy.js.map