import '@das-fed/ui/packages/components/tree/style.css';
import { defineComponent as nr, createBlock as Wt, openBlock as C, unref as i, createElementBlock as w, createElementVNode as Fe, renderSlot as M, createTextVNode as we, toDisplayString as be, ref as U, computed as ee, watch as pt, nextTick as Pe, onMounted as $a, onBeforeUnmount as _n, useAttrs as mn, normalizeClass as Xe, normalizeStyle as Tr, createCommentVNode as O, withDirectives as ye, createVNode as Se, mergeProps as Cr, isRef as Tn, createSlots as mt, withCtx as Ae, withModifiers as Ye, Fragment as me, vShow as Cn, renderList as ut } from "vue";
import { withInstall as _a } from "@das-fed/utils/with-install/index";
import { setThemeRule as wn } from "@das-fed/web/packages/theme/index";
import { t as $e, setI18nRule as jn } from "@das-fed/web/packages/i18n/index";
import { DasAutoRegisterIcon as kn, DasIcon as ft } from "@das-fed/ui/packages/components/icon/index";
import { DasInput as On } from "@das-fed/ui/packages/components/input/index";
import { vOverlay as zt } from "@das-fed/ui/packages/components/overlay/index";
import { vDasTooltip as Ie } from "@das-fed/ui/packages/components/text-tooltip/index";
import { vDasLoading as Sn } from "@das-fed/ui/packages/components/loading/index";
import { ElLoading as wr, ElTree as An, ElPopover as In } from "element-plus";
import "element-plus/es/components/popover/style/css";
import "element-plus/es/components/tree/style/css";
import { DasIconCaretRight as xn } from "@das-fed/ui/packages/icons/caret-right/index";
import { arrUnique as ma } from "@das-fed/utils/common-tools";
import "element-plus/es/components/loading/style/css";
const Pn = /* @__PURE__ */ nr({
  __name: "expand-icon",
  setup(e) {
    return (t, r) => (C(), Wt(i(xn), {
      class: "das-tree__expand-icon",
      size: "medium"
    }));
  }
}), Ta = (e, t) => {
  const r = e.__vccOpts || e;
  for (const [a, l] of t)
    r[a] = l;
  return r;
}, En = /* @__PURE__ */ Ta(Pn, [["__scopeId", "data-v-d51f7d20"]]), Ln = { class: "tree-empty-block" }, Kn = { class: "tree-empty-text" }, Nn = /* @__PURE__ */ nr({
  __name: "empty",
  props: {
    emptyText: {}
  },
  setup(e) {
    return (t, r) => (C(), w("div", Ln, [
      Fe("div", Kn, [
        M(t.$slots, "default", {}, () => [
          we(
            be(t.emptyText),
            1
            /* TEXT */
          )
        ], !0)
      ])
    ]));
  }
}), Ct = /* @__PURE__ */ Ta(Nn, [["__scopeId", "data-v-04eb8a79"]]), Dn = (e) => /^[+-]?\d+(\.\d+)?(px|em|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|%)$/.test(e), Mn = (e) => typeof e == "string" && Dn(e) ? e : e + "px", qt = (e, t = "children") => Array.isArray(e) && e.length ? e.reduce((r, a) => {
  let l = a[t], d = { ...a };
  return delete d[t], l && l.length ? r.concat(d, qt(l, t)) : r.concat(d);
}, []) : [];
function Fn() {
  this.__data__ = [], this.size = 0;
}
function Ca(e, t) {
  return e === t || e !== e && t !== t;
}
function At(e, t) {
  for (var r = e.length; r--; )
    if (Ca(e[r][0], t))
      return r;
  return -1;
}
var Bn = Array.prototype, Un = Bn.splice;
function zn(e) {
  var t = this.__data__, r = At(t, e);
  if (r < 0)
    return !1;
  var a = t.length - 1;
  return r == a ? t.pop() : Un.call(t, r, 1), --this.size, !0;
}
function Gn(e) {
  var t = this.__data__, r = At(t, e);
  return r < 0 ? void 0 : t[r][1];
}
function Rn(e) {
  return At(this.__data__, e) > -1;
}
function Vn(e, t) {
  var r = this.__data__, a = At(r, e);
  return a < 0 ? (++this.size, r.push([e, t])) : r[a][1] = t, this;
}
function Ee(e) {
  var t = -1, r = e == null ? 0 : e.length;
  for (this.clear(); ++t < r; ) {
    var a = e[t];
    this.set(a[0], a[1]);
  }
}
Ee.prototype.clear = Fn;
Ee.prototype.delete = zn;
Ee.prototype.get = Gn;
Ee.prototype.has = Rn;
Ee.prototype.set = Vn;
function Hn() {
  this.__data__ = new Ee(), this.size = 0;
}
function Wn(e) {
  var t = this.__data__, r = t.delete(e);
  return this.size = t.size, r;
}
function qn(e) {
  return this.__data__.get(e);
}
function Jn(e) {
  return this.__data__.has(e);
}
var wa = typeof global == "object" && global && global.Object === Object && global, Xn = typeof self == "object" && self && self.Object === Object && self, Te = wa || Xn || Function("return this")(), Ze = Te.Symbol, ja = Object.prototype, Yn = ja.hasOwnProperty, Zn = ja.toString, dt = Ze ? Ze.toStringTag : void 0;
function Qn(e) {
  var t = Yn.call(e, dt), r = e[dt];
  try {
    e[dt] = void 0;
    var a = !0;
  } catch {
  }
  var l = Zn.call(e);
  return a && (t ? e[dt] = r : delete e[dt]), l;
}
var eo = Object.prototype, to = eo.toString;
function ro(e) {
  return to.call(e);
}
var ao = "[object Null]", no = "[object Undefined]", jr = Ze ? Ze.toStringTag : void 0;
function et(e) {
  return e == null ? e === void 0 ? no : ao : jr && jr in Object(e) ? Qn(e) : ro(e);
}
function ze(e) {
  var t = typeof e;
  return e != null && (t == "object" || t == "function");
}
var oo = "[object AsyncFunction]", so = "[object Function]", io = "[object GeneratorFunction]", lo = "[object Proxy]";
function ka(e) {
  if (!ze(e))
    return !1;
  var t = et(e);
  return t == so || t == io || t == oo || t == lo;
}
var Gt = Te["__core-js_shared__"], kr = function() {
  var e = /[^.]+$/.exec(Gt && Gt.keys && Gt.keys.IE_PROTO || "");
  return e ? "Symbol(src)_1." + e : "";
}();
function co(e) {
  return !!kr && kr in e;
}
var uo = Function.prototype, fo = uo.toString;
function Re(e) {
  if (e != null) {
    try {
      return fo.call(e);
    } catch {
    }
    try {
      return e + "";
    } catch {
    }
  }
  return "";
}
var vo = /[\\^$.*+?()[\]{}|]/g, ho = /^\[object .+?Constructor\]$/, yo = Function.prototype, po = Object.prototype, go = yo.toString, bo = po.hasOwnProperty, $o = RegExp(
  "^" + go.call(bo).replace(vo, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
);
function _o(e) {
  if (!ze(e) || co(e))
    return !1;
  var t = ka(e) ? $o : ho;
  return t.test(Re(e));
}
function mo(e, t) {
  return e == null ? void 0 : e[t];
}
function Ve(e, t) {
  var r = mo(e, t);
  return _o(r) ? r : void 0;
}
var gt = Ve(Te, "Map"), bt = Ve(Object, "create");
function To() {
  this.__data__ = bt ? bt(null) : {}, this.size = 0;
}
function Co(e) {
  var t = this.has(e) && delete this.__data__[e];
  return this.size -= t ? 1 : 0, t;
}
var wo = "__lodash_hash_undefined__", jo = Object.prototype, ko = jo.hasOwnProperty;
function Oo(e) {
  var t = this.__data__;
  if (bt) {
    var r = t[e];
    return r === wo ? void 0 : r;
  }
  return ko.call(t, e) ? t[e] : void 0;
}
var So = Object.prototype, Ao = So.hasOwnProperty;
function Io(e) {
  var t = this.__data__;
  return bt ? t[e] !== void 0 : Ao.call(t, e);
}
var xo = "__lodash_hash_undefined__";
function Po(e, t) {
  var r = this.__data__;
  return this.size += this.has(e) ? 0 : 1, r[e] = bt && t === void 0 ? xo : t, this;
}
function Ge(e) {
  var t = -1, r = e == null ? 0 : e.length;
  for (this.clear(); ++t < r; ) {
    var a = e[t];
    this.set(a[0], a[1]);
  }
}
Ge.prototype.clear = To;
Ge.prototype.delete = Co;
Ge.prototype.get = Oo;
Ge.prototype.has = Io;
Ge.prototype.set = Po;
function Eo() {
  this.size = 0, this.__data__ = {
    hash: new Ge(),
    map: new (gt || Ee)(),
    string: new Ge()
  };
}
function Lo(e) {
  var t = typeof e;
  return t == "string" || t == "number" || t == "symbol" || t == "boolean" ? e !== "__proto__" : e === null;
}
function It(e, t) {
  var r = e.__data__;
  return Lo(t) ? r[typeof t == "string" ? "string" : "hash"] : r.map;
}
function Ko(e) {
  var t = It(this, e).delete(e);
  return this.size -= t ? 1 : 0, t;
}
function No(e) {
  return It(this, e).get(e);
}
function Do(e) {
  return It(this, e).has(e);
}
function Mo(e, t) {
  var r = It(this, e), a = r.size;
  return r.set(e, t), this.size += r.size == a ? 0 : 1, this;
}
function tt(e) {
  var t = -1, r = e == null ? 0 : e.length;
  for (this.clear(); ++t < r; ) {
    var a = e[t];
    this.set(a[0], a[1]);
  }
}
tt.prototype.clear = Eo;
tt.prototype.delete = Ko;
tt.prototype.get = No;
tt.prototype.has = Do;
tt.prototype.set = Mo;
var Fo = 200;
function Bo(e, t) {
  var r = this.__data__;
  if (r instanceof Ee) {
    var a = r.__data__;
    if (!gt || a.length < Fo - 1)
      return a.push([e, t]), this.size = ++r.size, this;
    r = this.__data__ = new tt(a);
  }
  return r.set(e, t), this.size = r.size, this;
}
function rt(e) {
  var t = this.__data__ = new Ee(e);
  this.size = t.size;
}
rt.prototype.clear = Hn;
rt.prototype.delete = Wn;
rt.prototype.get = qn;
rt.prototype.has = Jn;
rt.prototype.set = Bo;
function Uo(e, t) {
  for (var r = -1, a = e == null ? 0 : e.length; ++r < a && t(e[r], r, e) !== !1; )
    ;
  return e;
}
var Or = function() {
  try {
    var e = Ve(Object, "defineProperty");
    return e({}, "", {}), e;
  } catch {
  }
}();
function zo(e, t, r) {
  t == "__proto__" && Or ? Or(e, t, {
    configurable: !0,
    enumerable: !0,
    value: r,
    writable: !0
  }) : e[t] = r;
}
var Go = Object.prototype, Ro = Go.hasOwnProperty;
function Vo(e, t, r) {
  var a = e[t];
  (!(Ro.call(e, t) && Ca(a, r)) || r === void 0 && !(t in e)) && zo(e, t, r);
}
function Ho(e, t) {
  for (var r = -1, a = Array(e); ++r < e; )
    a[r] = t(r);
  return a;
}
function at(e) {
  return e != null && typeof e == "object";
}
var Wo = "[object Arguments]";
function Sr(e) {
  return at(e) && et(e) == Wo;
}
var Oa = Object.prototype, qo = Oa.hasOwnProperty, Jo = Oa.propertyIsEnumerable, Xo = Sr(/* @__PURE__ */ function() {
  return arguments;
}()) ? Sr : function(e) {
  return at(e) && qo.call(e, "callee") && !Jo.call(e, "callee");
}, or = Array.isArray;
function Yo() {
  return !1;
}
var Sa = typeof exports == "object" && exports && !exports.nodeType && exports, Ar = Sa && typeof module == "object" && module && !module.nodeType && module, Zo = Ar && Ar.exports === Sa, Ir = Zo ? Te.Buffer : void 0, Qo = Ir ? Ir.isBuffer : void 0, Aa = Qo || Yo, es = 9007199254740991, ts = /^(?:0|[1-9]\d*)$/;
function rs(e, t) {
  var r = typeof e;
  return t = t ?? es, !!t && (r == "number" || r != "symbol" && ts.test(e)) && e > -1 && e % 1 == 0 && e < t;
}
var as = 9007199254740991;
function Ia(e) {
  return typeof e == "number" && e > -1 && e % 1 == 0 && e <= as;
}
var ns = "[object Arguments]", os = "[object Array]", ss = "[object Boolean]", is = "[object Date]", ls = "[object Error]", cs = "[object Function]", us = "[object Map]", fs = "[object Number]", ds = "[object Object]", vs = "[object RegExp]", hs = "[object Set]", ys = "[object String]", ps = "[object WeakMap]", gs = "[object ArrayBuffer]", bs = "[object DataView]", $s = "[object Float32Array]", _s = "[object Float64Array]", ms = "[object Int8Array]", Ts = "[object Int16Array]", Cs = "[object Int32Array]", ws = "[object Uint8Array]", js = "[object Uint8ClampedArray]", ks = "[object Uint16Array]", Os = "[object Uint32Array]", G = {};
G[$s] = G[_s] = G[ms] = G[Ts] = G[Cs] = G[ws] = G[js] = G[ks] = G[Os] = !0;
G[ns] = G[os] = G[gs] = G[ss] = G[bs] = G[is] = G[ls] = G[cs] = G[us] = G[fs] = G[ds] = G[vs] = G[hs] = G[ys] = G[ps] = !1;
function Ss(e) {
  return at(e) && Ia(e.length) && !!G[et(e)];
}
function sr(e) {
  return function(t) {
    return e(t);
  };
}
var xa = typeof exports == "object" && exports && !exports.nodeType && exports, yt = xa && typeof module == "object" && module && !module.nodeType && module, As = yt && yt.exports === xa, Rt = As && wa.process, Qe = function() {
  try {
    var e = yt && yt.require && yt.require("util").types;
    return e || Rt && Rt.binding && Rt.binding("util");
  } catch {
  }
}(), xr = Qe && Qe.isTypedArray, Is = xr ? sr(xr) : Ss, xs = Object.prototype, Ps = xs.hasOwnProperty;
function Es(e, t) {
  var r = or(e), a = !r && Xo(e), l = !r && !a && Aa(e), d = !r && !a && !l && Is(e), s = r || a || l || d, g = s ? Ho(e.length, String) : [], p = g.length;
  for (var v in e)
    Ps.call(e, v) && !(s && // Safari 9 has enumerable `arguments.length` in strict mode.
    (v == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
    l && (v == "offset" || v == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
    d && (v == "buffer" || v == "byteLength" || v == "byteOffset") || // Skip index properties.
    rs(v, p))) && g.push(v);
  return g;
}
var Ls = Object.prototype;
function Pa(e) {
  var t = e && e.constructor, r = typeof t == "function" && t.prototype || Ls;
  return e === r;
}
function Ea(e, t) {
  return function(r) {
    return e(t(r));
  };
}
var Ks = Ea(Object.keys, Object), Ns = Object.prototype, Ds = Ns.hasOwnProperty;
function Ms(e) {
  if (!Pa(e))
    return Ks(e);
  var t = [];
  for (var r in Object(e))
    Ds.call(e, r) && r != "constructor" && t.push(r);
  return t;
}
function Fs(e) {
  return e != null && Ia(e.length) && !ka(e);
}
function Bs(e) {
  return Fs(e) ? Es(e) : Ms(e);
}
var La = typeof exports == "object" && exports && !exports.nodeType && exports, Pr = La && typeof module == "object" && module && !module.nodeType && module, Us = Pr && Pr.exports === La, Er = Us ? Te.Buffer : void 0;
Er && Er.allocUnsafe;
function zs(e, t) {
  return e.slice();
}
function Gs(e, t) {
  for (var r = -1, a = e == null ? 0 : e.length, l = 0, d = []; ++r < a; ) {
    var s = e[r];
    t(s, r, e) && (d[l++] = s);
  }
  return d;
}
function Rs() {
  return [];
}
var Vs = Object.prototype, Hs = Vs.propertyIsEnumerable, Lr = Object.getOwnPropertySymbols, Ws = Lr ? function(e) {
  return e == null ? [] : (e = Object(e), Gs(Lr(e), function(t) {
    return Hs.call(e, t);
  }));
} : Rs;
function qs(e, t) {
  for (var r = -1, a = t.length, l = e.length; ++r < a; )
    e[l + r] = t[r];
  return e;
}
var Js = Ea(Object.getPrototypeOf, Object);
function Xs(e, t, r) {
  var a = t(e);
  return or(e) ? a : qs(a, r(e));
}
function Ys(e) {
  return Xs(e, Bs, Ws);
}
var Jt = Ve(Te, "DataView"), Xt = Ve(Te, "Promise"), Yt = Ve(Te, "Set"), Zt = Ve(Te, "WeakMap"), Kr = "[object Map]", Zs = "[object Object]", Nr = "[object Promise]", Dr = "[object Set]", Mr = "[object WeakMap]", Fr = "[object DataView]", Qs = Re(Jt), ei = Re(gt), ti = Re(Xt), ri = Re(Yt), ai = Re(Zt), xe = et;
(Jt && xe(new Jt(new ArrayBuffer(1))) != Fr || gt && xe(new gt()) != Kr || Xt && xe(Xt.resolve()) != Nr || Yt && xe(new Yt()) != Dr || Zt && xe(new Zt()) != Mr) && (xe = function(e) {
  var t = et(e), r = t == Zs ? e.constructor : void 0, a = r ? Re(r) : "";
  if (a)
    switch (a) {
      case Qs:
        return Fr;
      case ei:
        return Kr;
      case ti:
        return Nr;
      case ri:
        return Dr;
      case ai:
        return Mr;
    }
  return t;
});
var ni = Object.prototype, oi = ni.hasOwnProperty;
function si(e) {
  var t = e.length, r = new e.constructor(t);
  return t && typeof e[0] == "string" && oi.call(e, "index") && (r.index = e.index, r.input = e.input), r;
}
var Br = Te.Uint8Array;
function ir(e) {
  var t = new e.constructor(e.byteLength);
  return new Br(t).set(new Br(e)), t;
}
function ii(e, t) {
  var r = ir(e.buffer);
  return new e.constructor(r, e.byteOffset, e.byteLength);
}
var li = /\w*$/;
function ci(e) {
  var t = new e.constructor(e.source, li.exec(e));
  return t.lastIndex = e.lastIndex, t;
}
var Ur = Ze ? Ze.prototype : void 0, zr = Ur ? Ur.valueOf : void 0;
function ui(e) {
  return zr ? Object(zr.call(e)) : {};
}
function fi(e, t) {
  var r = ir(e.buffer);
  return new e.constructor(r, e.byteOffset, e.length);
}
var di = "[object Boolean]", vi = "[object Date]", hi = "[object Map]", yi = "[object Number]", pi = "[object RegExp]", gi = "[object Set]", bi = "[object String]", $i = "[object Symbol]", _i = "[object ArrayBuffer]", mi = "[object DataView]", Ti = "[object Float32Array]", Ci = "[object Float64Array]", wi = "[object Int8Array]", ji = "[object Int16Array]", ki = "[object Int32Array]", Oi = "[object Uint8Array]", Si = "[object Uint8ClampedArray]", Ai = "[object Uint16Array]", Ii = "[object Uint32Array]";
function xi(e, t, r) {
  var a = e.constructor;
  switch (t) {
    case _i:
      return ir(e);
    case di:
    case vi:
      return new a(+e);
    case mi:
      return ii(e);
    case Ti:
    case Ci:
    case wi:
    case ji:
    case ki:
    case Oi:
    case Si:
    case Ai:
    case Ii:
      return fi(e);
    case hi:
      return new a();
    case yi:
    case bi:
      return new a(e);
    case pi:
      return ci(e);
    case gi:
      return new a();
    case $i:
      return ui(e);
  }
}
var Gr = Object.create, Pi = /* @__PURE__ */ function() {
  function e() {
  }
  return function(t) {
    if (!ze(t))
      return {};
    if (Gr)
      return Gr(t);
    e.prototype = t;
    var r = new e();
    return e.prototype = void 0, r;
  };
}();
function Ei(e) {
  return typeof e.constructor == "function" && !Pa(e) ? Pi(Js(e)) : {};
}
var Li = "[object Map]";
function Ki(e) {
  return at(e) && xe(e) == Li;
}
var Rr = Qe && Qe.isMap, Ni = Rr ? sr(Rr) : Ki, Di = "[object Set]";
function Mi(e) {
  return at(e) && xe(e) == Di;
}
var Vr = Qe && Qe.isSet, Fi = Vr ? sr(Vr) : Mi, Ka = "[object Arguments]", Bi = "[object Array]", Ui = "[object Boolean]", zi = "[object Date]", Gi = "[object Error]", Na = "[object Function]", Ri = "[object GeneratorFunction]", Vi = "[object Map]", Hi = "[object Number]", Da = "[object Object]", Wi = "[object RegExp]", qi = "[object Set]", Ji = "[object String]", Xi = "[object Symbol]", Yi = "[object WeakMap]", Zi = "[object ArrayBuffer]", Qi = "[object DataView]", el = "[object Float32Array]", tl = "[object Float64Array]", rl = "[object Int8Array]", al = "[object Int16Array]", nl = "[object Int32Array]", ol = "[object Uint8Array]", sl = "[object Uint8ClampedArray]", il = "[object Uint16Array]", ll = "[object Uint32Array]", F = {};
F[Ka] = F[Bi] = F[Zi] = F[Qi] = F[Ui] = F[zi] = F[el] = F[tl] = F[rl] = F[al] = F[nl] = F[Vi] = F[Hi] = F[Da] = F[Wi] = F[qi] = F[Ji] = F[Xi] = F[ol] = F[sl] = F[il] = F[ll] = !0;
F[Gi] = F[Na] = F[Yi] = !1;
function wt(e, t, r, a, l, d) {
  var s;
  if (s !== void 0)
    return s;
  if (!ze(e))
    return e;
  var g = or(e);
  if (g)
    s = si(e);
  else {
    var p = xe(e), v = p == Na || p == Ri;
    if (Aa(e))
      return zs(e);
    if (p == Da || p == Ka || v && !l)
      s = v ? {} : Ei(e);
    else {
      if (!F[p])
        return l ? e : {};
      s = xi(e, p);
    }
  }
  d || (d = new rt());
  var x = d.get(e);
  if (x)
    return x;
  d.set(e, s), Fi(e) ? e.forEach(function(z) {
    s.add(wt(z, t, r, z, e, d));
  }) : Ni(e) && e.forEach(function(z, W) {
    s.set(W, wt(z, t, r, W, e, d));
  });
  var j = Ys, _ = g ? void 0 : j(e);
  return Uo(_ || e, function(z, W) {
    _ && (W = z, z = e[W]), Vo(s, W, wt(z, t, r, W, e, d));
  }), s;
}
var cl = 1, ul = 4;
function Be(e) {
  return wt(e, cl | ul);
}
var Vt = function() {
  return Te.Date.now();
}, fl = /\s/;
function dl(e) {
  for (var t = e.length; t-- && fl.test(e.charAt(t)); )
    ;
  return t;
}
var vl = /^\s+/;
function hl(e) {
  return e && e.slice(0, dl(e) + 1).replace(vl, "");
}
var yl = "[object Symbol]";
function pl(e) {
  return typeof e == "symbol" || at(e) && et(e) == yl;
}
var Hr = NaN, gl = /^[-+]0x[0-9a-f]+$/i, bl = /^0b[01]+$/i, $l = /^0o[0-7]+$/i, _l = parseInt;
function Wr(e) {
  if (typeof e == "number")
    return e;
  if (pl(e))
    return Hr;
  if (ze(e)) {
    var t = typeof e.valueOf == "function" ? e.valueOf() : e;
    e = ze(t) ? t + "" : t;
  }
  if (typeof e != "string")
    return e === 0 ? e : +e;
  e = hl(e);
  var r = bl.test(e);
  return r || $l.test(e) ? _l(e.slice(2), r ? 2 : 8) : gl.test(e) ? Hr : +e;
}
var ml = "Expected a function", Tl = Math.max, Cl = Math.min;
function wl(e, t, r) {
  var a, l, d, s, g, p, v = 0, x = !1, j = !1, _ = !0;
  if (typeof e != "function")
    throw new TypeError(ml);
  t = Wr(t) || 0, ze(r) && (x = !!r.leading, j = "maxWait" in r, d = j ? Tl(Wr(r.maxWait) || 0, t) : d, _ = "trailing" in r ? !!r.trailing : _);
  function z(I) {
    var le = a, Q = l;
    return a = l = void 0, v = I, s = e.apply(Q, le), s;
  }
  function W(I) {
    return v = I, g = setTimeout(q, t), x ? z(I) : s;
  }
  function S(I) {
    var le = I - p, Q = I - v, ae = t - le;
    return j ? Cl(ae, d - Q) : ae;
  }
  function Z(I) {
    var le = I - p, Q = I - v;
    return p === void 0 || le >= t || le < 0 || j && Q >= d;
  }
  function q() {
    var I = Vt();
    if (Z(I))
      return ke(I);
    g = setTimeout(q, S(I));
  }
  function ke(I) {
    return g = void 0, _ && a ? z(I) : (a = l = void 0, s);
  }
  function ue() {
    g !== void 0 && clearTimeout(g), v = 0, a = p = l = g = void 0;
  }
  function fe() {
    return g === void 0 ? s : ke(Vt());
  }
  function ie() {
    var I = Vt(), le = Z(I);
    if (a = arguments, l = this, p = I, le) {
      if (g === void 0)
        return W(p);
      if (j)
        return clearTimeout(g), g = setTimeout(q, t), z(p);
    }
    return g === void 0 && (g = setTimeout(q, t)), s;
  }
  return ie.cancel = ue, ie.flush = fe, ie;
}
const jl = (e, t, r, a, l, d, s, g, p) => {
  const v = U(null), x = U([]), j = U(!1), _ = ee(() => ({
    label: "name",
    children: "children",
    parentId: "parentId",
    pathName: "pathName",
    disabled: "disabled",
    isLeaf: "leaf",
    allowUnSelect: "allowUnSelect",
    ...e.props
  })), z = ee(() => {
    let o = "100%";
    return e.height && (o = Mn(e.height)), o;
  }), W = (o, u, c) => {
    if (!e.operationsLabel) return;
    const $ = e.operationsLabel[o];
    if ($)
      return typeof $ == "function" ? $(u, c) : $;
  }, S = U({}), Z = (o, u) => {
    o && (S.value[u] = o);
  }, q = U(null), ke = U(null), ue = U({ node: null, data: null }), fe = (o, u) => {
    ke.value = S.value[u[e.nodeKey]], ue.value = {
      node: o,
      data: u
    };
  }, ie = () => {
    var o;
    (o = q.value) == null || o.hide();
  }, I = U(""), le = (o) => {
    I.value = o ? ue.value.data[e.nodeKey] : "";
  }, Q = (o, u) => {
    var m, L, k, Y;
    let c = {};
    const $ = "bottom";
    return e.showOperations && ((m = e.mergeOprations) != null && m.list ? typeof e.mergeOprations.list != "function" ? (L = e.mergeOprations) != null && L.list && e.mergeOprations.list.length && (c.list = e.mergeOprations.list) : c.list = e.mergeOprations.list(o, u) : c.list = [], (k = c.list) != null && k.length && (c.list = c.list.filter((Ne) => !Ne.hidden)), (Y = e.mergeOprations) != null && Y.position ? (typeof e.mergeOprations.position != "function" ? c.position = e.mergeOprations.position : c.position = e.mergeOprations.position(o, u), c.position === "left" && (c.position = "top"), c.position === "right" && (c.position = "bottom")) : c.position = $), c;
  }, ae = (o, u) => {
    let c = [], $ = [];
    if (e.showOperations && (!e.operations || !e.operations.length ? $ = [
      {
        value: "add",
        label: W("add", o, u) ?? $e("新增同级"),
        icon: "add"
      },
      {
        value: "addItem",
        label: W("addItem", o, u) ?? $e("新增子级"),
        icon: "addItem"
      },
      {
        value: "edit",
        label: W("edit", o, u) ?? $e("编辑"),
        icon: "edit"
      },
      {
        value: "delete",
        label: W("delete", o, u) ?? $e("删除"),
        icon: "delete"
      }
    ] : typeof e.operations == "function" ? $ = e.operations(o, u) : $ = e.operations), !$ || !$.length) return [];
    if (e.operations)
      c = $;
    else {
      let m = [];
      e.operationsLayout && (typeof e.operationsLayout == "string" ? m = e.operationsLayout.split(",") : typeof e.operationsLayout(o, u) == "string" ? m = e.operationsLayout(o, u).split(",") : m = ["add", "addItem", "edit", "delete"]), $ != null && $.length && (m != null && m.length) && m.forEach((L) => {
        const k = $.find((Y) => Y.value === L);
        k && c.push(k);
      });
    }
    return o.level === Number(e.maxNodeLevel) && (c = c.filter((m) => m.icon !== "addItem" && m.name !== $e("新增子级"))), c.length && (c = c.filter((m) => !m.hidden)), c;
  }, pe = (o, u, c) => {
    o.disabled || (ie(), I.value = "", setTimeout(() => t("handleOperation", o, u, c), 0));
  }, We = (o, u) => u[_.value.label].toLowerCase().includes(o.toLowerCase()), ne = ee(() => (e == null ? void 0 : e.filterNodeMethod) ?? We), oe = ee({
    get: () => e.filterValue,
    set: (o) => {
      t("update:filterValue", o);
    }
  }), de = () => {
    const o = oe.value, u = _.value.children;
    o && e.data ? x.value = qt(e.data, u).filter((c) => ne.value(o, c)) : e.data && (x.value = qt(e.data, u)), x.value.length || x.value.push({ [_.value.label]: $e("暂无数据"), id: "nodata" });
  }, De = () => {
    x.value = [];
  }, ct = (o, u) => {
    var c;
    return o ? u[(c = _.value) == null ? void 0 : c.label].includes(o) : !0;
  }, _e = (o, u) => {
    let c = !1;
    return typeof _.value.disabled == "string" ? c = o[_.value.disabled] ?? !1 : typeof _.value.disabled == "function" && (c = _.value.disabled(o, u) ?? !1), c;
  }, ge = (o, u = "parentId") => {
    var k;
    const c = o[u], $ = (k = r.value) == null ? void 0 : k.store.nodesMap, m = ($ == null ? void 0 : $[c]) ?? null;
    if (!m) return [null, null];
    if (!_e(m.data, m)) return [m.data, m];
    const L = ge(m.data, u);
    if (L) return L;
  }, qe = (o, u) => {
    let c = !1;
    return typeof _.value.isLeaf == "string" ? c = o[_.value.isLeaf] ?? !1 : typeof _.value.isLeaf == "function" && (c = _.value.isLeaf(o, u) ?? !1), c;
  }, Me = (o) => {
    let u = !1;
    return typeof _.value.allowUnSelect == "string" ? u = o[_.value.allowUnSelect] ?? !1 : typeof _.value.allowUnSelect == "function" && (u = _.value.allowUnSelect(o) ?? !1), u;
  }, ve = (o) => e.draggable ? e.allowDrag ? e.allowDrag(o) : !0 : !1, Le = (o, u) => {
    if (typeof e.filterItemClass == "string")
      return e.filterItemClass;
    if (typeof e.filterItemClass == "function")
      return e.filterItemClass(o, u);
  };
  let b = 0;
  const N = async (o, u) => {
    var $;
    if (($ = v.value) == null || $.click(), _e(o, u)) return;
    let c = !0;
    e.changeNodeConfirm && (c = await e.changeNodeConfirm(o)), c && (b++, E(o, u));
  }, E = wl((...o) => {
    const [u, c] = o;
    b > 1 ? he(u, c) : P(u, c), b = 0;
  }, 500), he = (o, u) => {
    e.showCheckbox ? t("check-node-db-click", o, u) : t("node-db-click", o, u);
  }, P = (o, u) => {
    var c;
    e.showCheckbox ? t("check-node-click", o, u) : (j.value = !0, l.value = o[e.nodeKey], (c = r.value) == null || c.setCurrentKey(l.value), o.path && (a.value = o.path), t("change", o[e.nodeKey], o), t("node-click", o, u), t("node-change", o));
  }, Ke = async (o, u) => {
    await Pe(), !(d.value && !e.showCheckbox && l.value && o[e.nodeKey] !== l.value) && t("current-change", o, u);
  }, ce = (o, u = !1) => {
    let c = !1;
    return e != null && e.nodeKey && (e.showCheckbox ? u && (c = !!l.value.includes(o[e.nodeKey])) : c = l.value === o[e.nodeKey]), c;
  }, Oe = async (o) => {
    var u, c, $;
    if (!_e(o, null)) {
      if (!e.showCheckbox)
        N(o);
      else {
        const m = (u = e.data) == null ? void 0 : u.find((L) => L[e.nodeKey] === o[e.nodeKey]);
        if (!ce(o, !0) || !(e.hideRootCheckbox && m)) {
          const L = l.value || [];
          if (e != null && e.nodeKey && !L.includes(o[e.nodeKey])) {
            const k = L.concat(o[e.nodeKey]) || [];
            e.showCheckbox && ((c = r.value) == null || c.setCheckedKeys(k)), g(o, { checkedKeys: [...k] }, !0);
          }
        }
        ($ = r.value) == null || $.setCurrentKey(o[e.nodeKey]);
      }
      x.value = [], oe.value = "", t("filter-node-click", o);
    }
  }, Ce = (o, u) => {
    let c = "", $ = "";
    return _.value.class && (typeof _.value.class == "string" ? $ = _.value.class : $ = _.value.class(o, u)), $ && (c = `${c} ${$}`), ce(o) && (c = `${c} is-active`), ve(u) && (c = `${c} show-draggable-icon`), c;
  }, J = async () => {
    var o;
    return await Pe(), j.value ? j.value = !1 : (e.showCheckbox || (o = r.value) == null || o.setCurrentKey(l.value, !0), !0);
  };
  return pt(
    () => e.data,
    (o, u) => {
      if (!d.value) {
        if (!e.showOperations)
          if (o && o.length) {
            const c = o.find(
              ($) => $[_.value.children] && $[_.value.children].length
            );
            p.value = !c;
          } else
            p.value = !1;
        if (JSON.stringify(o) !== JSON.stringify(u)) {
          if (o && o.length && e.defaultExpandRoot) {
            const c = o.map(($) => $[e.nodeKey]);
            s.value = Be(c);
          }
          J();
        }
      }
    },
    { immediate: !0, deep: !0 }
  ), {
    realHeight: z,
    dasTree: v,
    treeRef: r,
    oprationVisibleChange: le,
    getOperations: ae,
    handleOperation: pe,
    filterInnerValue: oe,
    filterMethod: ct,
    filterList: x,
    selectItem: Oe,
    nodeClass: Ce,
    innerValue: l,
    nodeClick: N,
    defaultProps: _,
    filterSeach: de,
    filterNodeMethodFn: ne,
    filterClear: De,
    isActive: ce,
    expandParent: J,
    disabledFlag: _e,
    currentOprationKey: I,
    getMergeOperations: Q,
    setOprationsMoreBtnRefs: Z,
    oprationsPopoverRef: q,
    currentMoreBtnRef: ke,
    moreBtnEnter: fe,
    currentOprationItem: ue,
    isLeafFlag: qe,
    filterCustomClass: Le,
    allowUnSelectFlag: Me,
    findSelectableParentNode: ge,
    currentChange: Ke
  };
};
var Tt = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
function kl(e) {
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
}
function Ol() {
  this.__data__ = [], this.size = 0;
}
var Sl = Ol;
function Al(e, t) {
  return e === t || e !== e && t !== t;
}
var Ma = Al, Il = Ma;
function xl(e, t) {
  for (var r = e.length; r--; )
    if (Il(e[r][0], t))
      return r;
  return -1;
}
var xt = xl, Pl = xt, El = Array.prototype, Ll = El.splice;
function Kl(e) {
  var t = this.__data__, r = Pl(t, e);
  if (r < 0)
    return !1;
  var a = t.length - 1;
  return r == a ? t.pop() : Ll.call(t, r, 1), --this.size, !0;
}
var Nl = Kl, Dl = xt;
function Ml(e) {
  var t = this.__data__, r = Dl(t, e);
  return r < 0 ? void 0 : t[r][1];
}
var Fl = Ml, Bl = xt;
function Ul(e) {
  return Bl(this.__data__, e) > -1;
}
var zl = Ul, Gl = xt;
function Rl(e, t) {
  var r = this.__data__, a = Gl(r, e);
  return a < 0 ? (++this.size, r.push([e, t])) : r[a][1] = t, this;
}
var Vl = Rl, Hl = Sl, Wl = Nl, ql = Fl, Jl = zl, Xl = Vl;
function nt(e) {
  var t = -1, r = e == null ? 0 : e.length;
  for (this.clear(); ++t < r; ) {
    var a = e[t];
    this.set(a[0], a[1]);
  }
}
nt.prototype.clear = Hl;
nt.prototype.delete = Wl;
nt.prototype.get = ql;
nt.prototype.has = Jl;
nt.prototype.set = Xl;
var Pt = nt, Yl = Pt;
function Zl() {
  this.__data__ = new Yl(), this.size = 0;
}
var Ql = Zl;
function ec(e) {
  var t = this.__data__, r = t.delete(e);
  return this.size = t.size, r;
}
var tc = ec;
function rc(e) {
  return this.__data__.get(e);
}
var ac = rc;
function nc(e) {
  return this.__data__.has(e);
}
var oc = nc, sc = typeof Tt == "object" && Tt && Tt.Object === Object && Tt, Fa = sc, ic = Fa, lc = typeof self == "object" && self && self.Object === Object && self, cc = ic || lc || Function("return this")(), je = cc, uc = je, fc = uc.Symbol, lr = fc, qr = lr, Ba = Object.prototype, dc = Ba.hasOwnProperty, vc = Ba.toString, vt = qr ? qr.toStringTag : void 0;
function hc(e) {
  var t = dc.call(e, vt), r = e[vt];
  try {
    e[vt] = void 0;
    var a = !0;
  } catch {
  }
  var l = vc.call(e);
  return a && (t ? e[vt] = r : delete e[vt]), l;
}
var yc = hc, pc = Object.prototype, gc = pc.toString;
function bc(e) {
  return gc.call(e);
}
var $c = bc, Jr = lr, _c = yc, mc = $c, Tc = "[object Null]", Cc = "[object Undefined]", Xr = Jr ? Jr.toStringTag : void 0;
function wc(e) {
  return e == null ? e === void 0 ? Cc : Tc : Xr && Xr in Object(e) ? _c(e) : mc(e);
}
var Et = wc;
function jc(e) {
  var t = typeof e;
  return e != null && (t == "object" || t == "function");
}
var $t = jc, kc = Et, Oc = $t, Sc = "[object AsyncFunction]", Ac = "[object Function]", Ic = "[object GeneratorFunction]", xc = "[object Proxy]";
function Pc(e) {
  if (!Oc(e))
    return !1;
  var t = kc(e);
  return t == Ac || t == Ic || t == Sc || t == xc;
}
var Ua = Pc, Ec = je, Lc = Ec["__core-js_shared__"], Kc = Lc, Ht = Kc, Yr = function() {
  var e = /[^.]+$/.exec(Ht && Ht.keys && Ht.keys.IE_PROTO || "");
  return e ? "Symbol(src)_1." + e : "";
}();
function Nc(e) {
  return !!Yr && Yr in e;
}
var Dc = Nc, Mc = Function.prototype, Fc = Mc.toString;
function Bc(e) {
  if (e != null) {
    try {
      return Fc.call(e);
    } catch {
    }
    try {
      return e + "";
    } catch {
    }
  }
  return "";
}
var za = Bc, Uc = Ua, zc = Dc, Gc = $t, Rc = za, Vc = /[\\^$.*+?()[\]{}|]/g, Hc = /^\[object .+?Constructor\]$/, Wc = Function.prototype, qc = Object.prototype, Jc = Wc.toString, Xc = qc.hasOwnProperty, Yc = RegExp(
  "^" + Jc.call(Xc).replace(Vc, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
);
function Zc(e) {
  if (!Gc(e) || zc(e))
    return !1;
  var t = Uc(e) ? Yc : Hc;
  return t.test(Rc(e));
}
var Qc = Zc;
function eu(e, t) {
  return e == null ? void 0 : e[t];
}
var tu = eu, ru = Qc, au = tu;
function nu(e, t) {
  var r = au(e, t);
  return ru(r) ? r : void 0;
}
var He = nu, ou = He, su = je, iu = ou(su, "Map"), cr = iu, lu = He, cu = lu(Object, "create"), Lt = cu, Zr = Lt;
function uu() {
  this.__data__ = Zr ? Zr(null) : {}, this.size = 0;
}
var fu = uu;
function du(e) {
  var t = this.has(e) && delete this.__data__[e];
  return this.size -= t ? 1 : 0, t;
}
var vu = du, hu = Lt, yu = "__lodash_hash_undefined__", pu = Object.prototype, gu = pu.hasOwnProperty;
function bu(e) {
  var t = this.__data__;
  if (hu) {
    var r = t[e];
    return r === yu ? void 0 : r;
  }
  return gu.call(t, e) ? t[e] : void 0;
}
var $u = bu, _u = Lt, mu = Object.prototype, Tu = mu.hasOwnProperty;
function Cu(e) {
  var t = this.__data__;
  return _u ? t[e] !== void 0 : Tu.call(t, e);
}
var wu = Cu, ju = Lt, ku = "__lodash_hash_undefined__";
function Ou(e, t) {
  var r = this.__data__;
  return this.size += this.has(e) ? 0 : 1, r[e] = ju && t === void 0 ? ku : t, this;
}
var Su = Ou, Au = fu, Iu = vu, xu = $u, Pu = wu, Eu = Su;
function ot(e) {
  var t = -1, r = e == null ? 0 : e.length;
  for (this.clear(); ++t < r; ) {
    var a = e[t];
    this.set(a[0], a[1]);
  }
}
ot.prototype.clear = Au;
ot.prototype.delete = Iu;
ot.prototype.get = xu;
ot.prototype.has = Pu;
ot.prototype.set = Eu;
var Lu = ot, Qr = Lu, Ku = Pt, Nu = cr;
function Du() {
  this.size = 0, this.__data__ = {
    hash: new Qr(),
    map: new (Nu || Ku)(),
    string: new Qr()
  };
}
var Mu = Du;
function Fu(e) {
  var t = typeof e;
  return t == "string" || t == "number" || t == "symbol" || t == "boolean" ? e !== "__proto__" : e === null;
}
var Bu = Fu, Uu = Bu;
function zu(e, t) {
  var r = e.__data__;
  return Uu(t) ? r[typeof t == "string" ? "string" : "hash"] : r.map;
}
var Kt = zu, Gu = Kt;
function Ru(e) {
  var t = Gu(this, e).delete(e);
  return this.size -= t ? 1 : 0, t;
}
var Vu = Ru, Hu = Kt;
function Wu(e) {
  return Hu(this, e).get(e);
}
var qu = Wu, Ju = Kt;
function Xu(e) {
  return Ju(this, e).has(e);
}
var Yu = Xu, Zu = Kt;
function Qu(e, t) {
  var r = Zu(this, e), a = r.size;
  return r.set(e, t), this.size += r.size == a ? 0 : 1, this;
}
var ef = Qu, tf = Mu, rf = Vu, af = qu, nf = Yu, of = ef;
function st(e) {
  var t = -1, r = e == null ? 0 : e.length;
  for (this.clear(); ++t < r; ) {
    var a = e[t];
    this.set(a[0], a[1]);
  }
}
st.prototype.clear = tf;
st.prototype.delete = rf;
st.prototype.get = af;
st.prototype.has = nf;
st.prototype.set = of;
var sf = st, lf = Pt, cf = cr, uf = sf, ff = 200;
function df(e, t) {
  var r = this.__data__;
  if (r instanceof lf) {
    var a = r.__data__;
    if (!cf || a.length < ff - 1)
      return a.push([e, t]), this.size = ++r.size, this;
    r = this.__data__ = new uf(a);
  }
  return r.set(e, t), this.size = r.size, this;
}
var vf = df, hf = Pt, yf = Ql, pf = tc, gf = ac, bf = oc, $f = vf;
function it(e) {
  var t = this.__data__ = new hf(e);
  this.size = t.size;
}
it.prototype.clear = yf;
it.prototype.delete = pf;
it.prototype.get = gf;
it.prototype.has = bf;
it.prototype.set = $f;
var _f = it;
function mf(e, t) {
  for (var r = -1, a = e == null ? 0 : e.length; ++r < a && t(e[r], r, e) !== !1; )
    ;
  return e;
}
var Tf = mf, Cf = He, wf = function() {
  try {
    var e = Cf(Object, "defineProperty");
    return e({}, "", {}), e;
  } catch {
  }
}(), jf = wf, ea = jf;
function kf(e, t, r) {
  t == "__proto__" && ea ? ea(e, t, {
    configurable: !0,
    enumerable: !0,
    value: r,
    writable: !0
  }) : e[t] = r;
}
var Ga = kf, Of = Ga, Sf = Ma, Af = Object.prototype, If = Af.hasOwnProperty;
function xf(e, t, r) {
  var a = e[t];
  (!(If.call(e, t) && Sf(a, r)) || r === void 0 && !(t in e)) && Of(e, t, r);
}
var Ra = xf, Pf = Ra, Ef = Ga;
function Lf(e, t, r, a) {
  var l = !r;
  r || (r = {});
  for (var d = -1, s = t.length; ++d < s; ) {
    var g = t[d], p = a ? a(r[g], e[g], g, r, e) : void 0;
    p === void 0 && (p = e[g]), l ? Ef(r, g, p) : Pf(r, g, p);
  }
  return r;
}
var Nt = Lf;
function Kf(e, t) {
  for (var r = -1, a = Array(e); ++r < e; )
    a[r] = t(r);
  return a;
}
var Nf = Kf;
function Df(e) {
  return e != null && typeof e == "object";
}
var _t = Df, Mf = Et, Ff = _t, Bf = "[object Arguments]";
function Uf(e) {
  return Ff(e) && Mf(e) == Bf;
}
var zf = Uf, ta = zf, Gf = _t, Va = Object.prototype, Rf = Va.hasOwnProperty, Vf = Va.propertyIsEnumerable, Hf = ta(/* @__PURE__ */ function() {
  return arguments;
}()) ? ta : function(e) {
  return Gf(e) && Rf.call(e, "callee") && !Vf.call(e, "callee");
}, Wf = Hf, qf = Array.isArray, ur = qf, kt = { exports: {} };
function Jf() {
  return !1;
}
var Xf = Jf;
kt.exports;
(function(e, t) {
  var r = je, a = Xf, l = t && !t.nodeType && t, d = l && !0 && e && !e.nodeType && e, s = d && d.exports === l, g = s ? r.Buffer : void 0, p = g ? g.isBuffer : void 0, v = p || a;
  e.exports = v;
})(kt, kt.exports);
var Ha = kt.exports, Yf = 9007199254740991, Zf = /^(?:0|[1-9]\d*)$/;
function Qf(e, t) {
  var r = typeof e;
  return t = t ?? Yf, !!t && (r == "number" || r != "symbol" && Zf.test(e)) && e > -1 && e % 1 == 0 && e < t;
}
var ed = Qf, td = 9007199254740991;
function rd(e) {
  return typeof e == "number" && e > -1 && e % 1 == 0 && e <= td;
}
var Wa = rd, ad = Et, nd = Wa, od = _t, sd = "[object Arguments]", id = "[object Array]", ld = "[object Boolean]", cd = "[object Date]", ud = "[object Error]", fd = "[object Function]", dd = "[object Map]", vd = "[object Number]", hd = "[object Object]", yd = "[object RegExp]", pd = "[object Set]", gd = "[object String]", bd = "[object WeakMap]", $d = "[object ArrayBuffer]", _d = "[object DataView]", md = "[object Float32Array]", Td = "[object Float64Array]", Cd = "[object Int8Array]", wd = "[object Int16Array]", jd = "[object Int32Array]", kd = "[object Uint8Array]", Od = "[object Uint8ClampedArray]", Sd = "[object Uint16Array]", Ad = "[object Uint32Array]", R = {};
R[md] = R[Td] = R[Cd] = R[wd] = R[jd] = R[kd] = R[Od] = R[Sd] = R[Ad] = !0;
R[sd] = R[id] = R[$d] = R[ld] = R[_d] = R[cd] = R[ud] = R[fd] = R[dd] = R[vd] = R[hd] = R[yd] = R[pd] = R[gd] = R[bd] = !1;
function Id(e) {
  return od(e) && nd(e.length) && !!R[ad(e)];
}
var xd = Id;
function Pd(e) {
  return function(t) {
    return e(t);
  };
}
var fr = Pd, Ot = { exports: {} };
Ot.exports;
(function(e, t) {
  var r = Fa, a = t && !t.nodeType && t, l = a && !0 && e && !e.nodeType && e, d = l && l.exports === a, s = d && r.process, g = function() {
    try {
      var p = l && l.require && l.require("util").types;
      return p || s && s.binding && s.binding("util");
    } catch {
    }
  }();
  e.exports = g;
})(Ot, Ot.exports);
var dr = Ot.exports, Ed = xd, Ld = fr, ra = dr, aa = ra && ra.isTypedArray, Kd = aa ? Ld(aa) : Ed, Nd = Kd, Dd = Nf, Md = Wf, Fd = ur, Bd = Ha, Ud = ed, zd = Nd, Gd = Object.prototype, Rd = Gd.hasOwnProperty;
function Vd(e, t) {
  var r = Fd(e), a = !r && Md(e), l = !r && !a && Bd(e), d = !r && !a && !l && zd(e), s = r || a || l || d, g = s ? Dd(e.length, String) : [], p = g.length;
  for (var v in e)
    (t || Rd.call(e, v)) && !(s && // Safari 9 has enumerable `arguments.length` in strict mode.
    (v == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
    l && (v == "offset" || v == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
    d && (v == "buffer" || v == "byteLength" || v == "byteOffset") || // Skip index properties.
    Ud(v, p))) && g.push(v);
  return g;
}
var qa = Vd, Hd = Object.prototype;
function Wd(e) {
  var t = e && e.constructor, r = typeof t == "function" && t.prototype || Hd;
  return e === r;
}
var vr = Wd;
function qd(e, t) {
  return function(r) {
    return e(t(r));
  };
}
var Ja = qd, Jd = Ja, Xd = Jd(Object.keys, Object), Yd = Xd, Zd = vr, Qd = Yd, ev = Object.prototype, tv = ev.hasOwnProperty;
function rv(e) {
  if (!Zd(e))
    return Qd(e);
  var t = [];
  for (var r in Object(e))
    tv.call(e, r) && r != "constructor" && t.push(r);
  return t;
}
var av = rv, nv = Ua, ov = Wa;
function sv(e) {
  return e != null && ov(e.length) && !nv(e);
}
var Xa = sv, iv = qa, lv = av, cv = Xa;
function uv(e) {
  return cv(e) ? iv(e) : lv(e);
}
var hr = uv, fv = Nt, dv = hr;
function vv(e, t) {
  return e && fv(t, dv(t), e);
}
var hv = vv;
function yv(e) {
  var t = [];
  if (e != null)
    for (var r in Object(e))
      t.push(r);
  return t;
}
var pv = yv, gv = $t, bv = vr, $v = pv, _v = Object.prototype, mv = _v.hasOwnProperty;
function Tv(e) {
  if (!gv(e))
    return $v(e);
  var t = bv(e), r = [];
  for (var a in e)
    a == "constructor" && (t || !mv.call(e, a)) || r.push(a);
  return r;
}
var Cv = Tv, wv = qa, jv = Cv, kv = Xa;
function Ov(e) {
  return kv(e) ? wv(e, !0) : jv(e);
}
var yr = Ov, Sv = Nt, Av = yr;
function Iv(e, t) {
  return e && Sv(t, Av(t), e);
}
var xv = Iv, St = { exports: {} };
St.exports;
(function(e, t) {
  var r = je, a = t && !t.nodeType && t, l = a && !0 && e && !e.nodeType && e, d = l && l.exports === a, s = d ? r.Buffer : void 0, g = s ? s.allocUnsafe : void 0;
  function p(v, x) {
    if (x)
      return v.slice();
    var j = v.length, _ = g ? g(j) : new v.constructor(j);
    return v.copy(_), _;
  }
  e.exports = p;
})(St, St.exports);
var Pv = St.exports;
function Ev(e, t) {
  var r = -1, a = e.length;
  for (t || (t = Array(a)); ++r < a; )
    t[r] = e[r];
  return t;
}
var Lv = Ev;
function Kv(e, t) {
  for (var r = -1, a = e == null ? 0 : e.length, l = 0, d = []; ++r < a; ) {
    var s = e[r];
    t(s, r, e) && (d[l++] = s);
  }
  return d;
}
var Nv = Kv;
function Dv() {
  return [];
}
var Ya = Dv, Mv = Nv, Fv = Ya, Bv = Object.prototype, Uv = Bv.propertyIsEnumerable, na = Object.getOwnPropertySymbols, zv = na ? function(e) {
  return e == null ? [] : (e = Object(e), Mv(na(e), function(t) {
    return Uv.call(e, t);
  }));
} : Fv, pr = zv, Gv = Nt, Rv = pr;
function Vv(e, t) {
  return Gv(e, Rv(e), t);
}
var Hv = Vv;
function Wv(e, t) {
  for (var r = -1, a = t.length, l = e.length; ++r < a; )
    e[l + r] = t[r];
  return e;
}
var Za = Wv, qv = Ja, Jv = qv(Object.getPrototypeOf, Object), Qa = Jv, Xv = Za, Yv = Qa, Zv = pr, Qv = Ya, eh = Object.getOwnPropertySymbols, th = eh ? function(e) {
  for (var t = []; e; )
    Xv(t, Zv(e)), e = Yv(e);
  return t;
} : Qv, en = th, rh = Nt, ah = en;
function nh(e, t) {
  return rh(e, ah(e), t);
}
var oh = nh, sh = Za, ih = ur;
function lh(e, t, r) {
  var a = t(e);
  return ih(e) ? a : sh(a, r(e));
}
var tn = lh, ch = tn, uh = pr, fh = hr;
function dh(e) {
  return ch(e, fh, uh);
}
var vh = dh, hh = tn, yh = en, ph = yr;
function gh(e) {
  return hh(e, ph, yh);
}
var bh = gh, $h = He, _h = je, mh = $h(_h, "DataView"), Th = mh, Ch = He, wh = je, jh = Ch(wh, "Promise"), kh = jh, Oh = He, Sh = je, Ah = Oh(Sh, "Set"), Ih = Ah, xh = He, Ph = je, Eh = xh(Ph, "WeakMap"), Lh = Eh, Qt = Th, er = cr, tr = kh, rr = Ih, ar = Lh, rn = Et, lt = za, oa = "[object Map]", Kh = "[object Object]", sa = "[object Promise]", ia = "[object Set]", la = "[object WeakMap]", ca = "[object DataView]", Nh = lt(Qt), Dh = lt(er), Mh = lt(tr), Fh = lt(rr), Bh = lt(ar), Ue = rn;
(Qt && Ue(new Qt(new ArrayBuffer(1))) != ca || er && Ue(new er()) != oa || tr && Ue(tr.resolve()) != sa || rr && Ue(new rr()) != ia || ar && Ue(new ar()) != la) && (Ue = function(e) {
  var t = rn(e), r = t == Kh ? e.constructor : void 0, a = r ? lt(r) : "";
  if (a)
    switch (a) {
      case Nh:
        return ca;
      case Dh:
        return oa;
      case Mh:
        return sa;
      case Fh:
        return ia;
      case Bh:
        return la;
    }
  return t;
});
var gr = Ue, Uh = Object.prototype, zh = Uh.hasOwnProperty;
function Gh(e) {
  var t = e.length, r = new e.constructor(t);
  return t && typeof e[0] == "string" && zh.call(e, "index") && (r.index = e.index, r.input = e.input), r;
}
var Rh = Gh, Vh = je, Hh = Vh.Uint8Array, Wh = Hh, ua = Wh;
function qh(e) {
  var t = new e.constructor(e.byteLength);
  return new ua(t).set(new ua(e)), t;
}
var br = qh, Jh = br;
function Xh(e, t) {
  var r = t ? Jh(e.buffer) : e.buffer;
  return new e.constructor(r, e.byteOffset, e.byteLength);
}
var Yh = Xh, Zh = /\w*$/;
function Qh(e) {
  var t = new e.constructor(e.source, Zh.exec(e));
  return t.lastIndex = e.lastIndex, t;
}
var ey = Qh, fa = lr, da = fa ? fa.prototype : void 0, va = da ? da.valueOf : void 0;
function ty(e) {
  return va ? Object(va.call(e)) : {};
}
var ry = ty, ay = br;
function ny(e, t) {
  var r = t ? ay(e.buffer) : e.buffer;
  return new e.constructor(r, e.byteOffset, e.length);
}
var oy = ny, sy = br, iy = Yh, ly = ey, cy = ry, uy = oy, fy = "[object Boolean]", dy = "[object Date]", vy = "[object Map]", hy = "[object Number]", yy = "[object RegExp]", py = "[object Set]", gy = "[object String]", by = "[object Symbol]", $y = "[object ArrayBuffer]", _y = "[object DataView]", my = "[object Float32Array]", Ty = "[object Float64Array]", Cy = "[object Int8Array]", wy = "[object Int16Array]", jy = "[object Int32Array]", ky = "[object Uint8Array]", Oy = "[object Uint8ClampedArray]", Sy = "[object Uint16Array]", Ay = "[object Uint32Array]";
function Iy(e, t, r) {
  var a = e.constructor;
  switch (t) {
    case $y:
      return sy(e);
    case fy:
    case dy:
      return new a(+e);
    case _y:
      return iy(e, r);
    case my:
    case Ty:
    case Cy:
    case wy:
    case jy:
    case ky:
    case Oy:
    case Sy:
    case Ay:
      return uy(e, r);
    case vy:
      return new a();
    case hy:
    case gy:
      return new a(e);
    case yy:
      return ly(e);
    case py:
      return new a();
    case by:
      return cy(e);
  }
}
var xy = Iy, Py = $t, ha = Object.create, Ey = /* @__PURE__ */ function() {
  function e() {
  }
  return function(t) {
    if (!Py(t))
      return {};
    if (ha)
      return ha(t);
    e.prototype = t;
    var r = new e();
    return e.prototype = void 0, r;
  };
}(), Ly = Ey, Ky = Ly, Ny = Qa, Dy = vr;
function My(e) {
  return typeof e.constructor == "function" && !Dy(e) ? Ky(Ny(e)) : {};
}
var Fy = My, By = gr, Uy = _t, zy = "[object Map]";
function Gy(e) {
  return Uy(e) && By(e) == zy;
}
var Ry = Gy, Vy = Ry, Hy = fr, ya = dr, pa = ya && ya.isMap, Wy = pa ? Hy(pa) : Vy, qy = Wy, Jy = gr, Xy = _t, Yy = "[object Set]";
function Zy(e) {
  return Xy(e) && Jy(e) == Yy;
}
var Qy = Zy, ep = Qy, tp = fr, ga = dr, ba = ga && ga.isSet, rp = ba ? tp(ba) : ep, ap = rp, np = _f, op = Tf, sp = Ra, ip = hv, lp = xv, cp = Pv, up = Lv, fp = Hv, dp = oh, vp = vh, hp = bh, yp = gr, pp = Rh, gp = xy, bp = Fy, $p = ur, _p = Ha, mp = qy, Tp = $t, Cp = ap, wp = hr, jp = yr, kp = 1, Op = 2, Sp = 4, an = "[object Arguments]", Ap = "[object Array]", Ip = "[object Boolean]", xp = "[object Date]", Pp = "[object Error]", nn = "[object Function]", Ep = "[object GeneratorFunction]", Lp = "[object Map]", Kp = "[object Number]", on = "[object Object]", Np = "[object RegExp]", Dp = "[object Set]", Mp = "[object String]", Fp = "[object Symbol]", Bp = "[object WeakMap]", Up = "[object ArrayBuffer]", zp = "[object DataView]", Gp = "[object Float32Array]", Rp = "[object Float64Array]", Vp = "[object Int8Array]", Hp = "[object Int16Array]", Wp = "[object Int32Array]", qp = "[object Uint8Array]", Jp = "[object Uint8ClampedArray]", Xp = "[object Uint16Array]", Yp = "[object Uint32Array]", B = {};
B[an] = B[Ap] = B[Up] = B[zp] = B[Ip] = B[xp] = B[Gp] = B[Rp] = B[Vp] = B[Hp] = B[Wp] = B[Lp] = B[Kp] = B[on] = B[Np] = B[Dp] = B[Mp] = B[Fp] = B[qp] = B[Jp] = B[Xp] = B[Yp] = !0;
B[Pp] = B[nn] = B[Bp] = !1;
function jt(e, t, r, a, l, d) {
  var s, g = t & kp, p = t & Op, v = t & Sp;
  if (r && (s = l ? r(e, a, l, d) : r(e)), s !== void 0)
    return s;
  if (!Tp(e))
    return e;
  var x = $p(e);
  if (x) {
    if (s = pp(e), !g)
      return up(e, s);
  } else {
    var j = yp(e), _ = j == nn || j == Ep;
    if (_p(e))
      return cp(e, g);
    if (j == on || j == an || _ && !l) {
      if (s = p || _ ? {} : bp(e), !g)
        return p ? dp(e, lp(s, e)) : fp(e, ip(s, e));
    } else {
      if (!B[j])
        return l ? e : {};
      s = gp(e, j, g);
    }
  }
  d || (d = new np());
  var z = d.get(e);
  if (z)
    return z;
  d.set(e, s), Cp(e) ? e.forEach(function(Z) {
    s.add(jt(Z, t, r, Z, e, d));
  }) : mp(e) && e.forEach(function(Z, q) {
    s.set(q, jt(Z, t, r, q, e, d));
  });
  var W = v ? p ? hp : vp : p ? jp : wp, S = x ? void 0 : W(e);
  return op(S || e, function(Z, q) {
    S && (q = Z, Z = e[q]), sp(s, q, jt(Z, t, r, q, e, d));
  }), s;
}
var Zp = jt, Qp = Zp, eg = 1, tg = 4;
function rg(e) {
  return Qp(e, eg | tg);
}
var ag = rg;
const ht = /* @__PURE__ */ kl(ag), ng = (e, t, r, a, l, d, s, g, p, v, x, j, _, z, W, S, Z, q, ke) => {
  const ue = U([]), fe = U(!1), ie = U(null), I = U(null);
  pt(
    () => fe.value,
    (b) => {
      if (!b) {
        I.value && I.value.close();
        return;
      }
      I.value = a.value && wr.service({
        target: a.value
      });
    }
  );
  const le = async (b, N) => {
    if (e.load)
      return await e.load(b, N);
  }, Q = async () => {
    if (e.search)
      return await e.search(d.value);
  }, ae = U([]), pe = U([]), We = U([]), ne = U(!1), oe = async (b, N, E = !1) => {
    var Oe, Ce;
    await Pe(), !ie.value && a.value && (ne.value = !0, ie.value = wr.service({
      target: a.value
    }));
    let he = {};
    z(b.data, b) ? he = { data: [] } : he = await le(b.data, b.level), ie.value && (ie.value.close(), ne.value = !1);
    let { data: P } = he;
    P || (P = []);
    let Ke = [];
    const ce = ((Oe = b == null ? void 0 : b.childNodes) == null ? void 0 : Oe.map((J) => J.data)) || [];
    if (ce && P && ce.length && P.length && ce.length === P.length) {
      const J = Object.keys(P[0]), o = ce.map(($) => {
        let m = {};
        return J.forEach((L) => m[L] = $[L]), m;
      }), u = P.map(($) => {
        let m = {};
        return J.forEach((L) => m[L] = $[L]), m;
      });
      if (JSON.stringify(o) === JSON.stringify(u))
        return b.loaded = !0, b.loading = !1, [];
    }
    if (b.level === 0) {
      if (ae.value = P, e.parentLinkChildrenStrictly)
        for (const J of ae.value) {
          const o = await q(J);
          Ke = [...Ke, ...o];
        }
      if (e.defaultExpandRoot) {
        const J = (Ce = ae.value) == null ? void 0 : Ce.map((o) => o[e.nodeKey]);
        Z.value = ht(J);
      }
      E || (pe.value.push(b), We.value.push(N));
    }
    return W.value = ma([...W.value, ...P, ...Ke], e.nodeKey), N && N(P), P;
  }, de = U(!1), De = async () => {
    if (d.value === "" || d.value === void 0 || d.value === null) {
      ue.value = [], de.value = !1;
      return;
    }
    de.value = !0;
    const b = await Q() || [];
    (!b || !(b != null && b.length)) && b.push({ [g.value.label]: $e("暂无数据"), id: "nodata" }), ue.value = b, de.value = !1;
  }, ct = () => {
    ue.value = [];
  }, _e = async (b, N = !1) => {
    var ce, Oe, Ce, J, o, u, c;
    let E = b ?? {};
    if (ue.value = [], d.value = "", fe.value || N && j(E, null) || (E.path || (E.path = E[e.nodeKey] ?? ""), !E.path)) return;
    const he = E.path.split(/[\/,]/);
    he[0] !== e.rootNodeId && he.unshift(e.rootNodeId + "");
    const P = (ce = r.value) == null ? void 0 : ce.store.nodesMap;
    if (E[e.nodeKey] ? P[E[e.nodeKey]] : null) {
      if (!e.showCheckbox)
        v(E);
      else if (N) {
        const $ = (o = ae.value) == null ? void 0 : o.find((m) => m[e.nodeKey] === E[e.nodeKey]);
        if (!(e.hideRootCheckbox && $)) {
          const m = s.value.includes(E[e.nodeKey]) ? ht(s.value) : ht([...s.value, E[e.nodeKey]]);
          (u = r.value) == null || u.setCheckedKeys(m), S(E, { checkedKeys: [...m] }, N);
        }
        E[e.nodeKey] && ((c = r.value) == null || c.setCurrentKey(E[e.nodeKey]));
      }
      t("filter-node-click", E);
    } else {
      let $ = "", m = {};
      fe.value = !0;
      for (const L of he) {
        await Pe();
        const k = (Oe = r.value) == null ? void 0 : Oe.store.nodesMap, Y = k == null ? void 0 : k[L];
        if (!Y) continue;
        if (Y.loaded) {
          $ = L;
          continue;
        }
        Y.loading = !0, Y.childNodes = [], Y.shouldLoadData();
        const Ne = await oe(Y);
        Ne && Ne.length && Y.doCreateChildren(Ne), Y.loaded = !0, Y.loading = !1, Y.expand(), await Pe(), $ = L, m = Y.data;
      }
      if (N && m) {
        if (!e.showCheckbox)
          v(m);
        else {
          const L = s.value.includes($) ? ht(s.value) : ht([...s.value, $]);
          (Ce = r.value) == null || Ce.setCheckedKeys(L), S(m, { checkedKeys: [...L] }, N), m[e.nodeKey] && ((J = r.value) == null || J.setCurrentKey(m[e.nodeKey]));
        }
        t("filter-node-click", m);
      }
    }
    return fe.value = !1, !0;
  }, ge = async () => {
    let b = e.defaultExpandedPaths || [];
    if (e.showCheckbox ? p.value && p.value.length && (b = [...b, ...p.value]) : p.value && (b = b == null ? void 0 : b.concat(p.value)), b.length) {
      b = Array.from(new Set(b));
      for (const N of b)
        await _e({ path: N });
    }
    return !0;
  }, qe = () => new Promise((b) => {
    const N = () => {
      if (ae.value && ae.value.length) return b(!0);
      setTimeout(() => N(), 50);
    };
    N();
  }), Me = async () => {
    await qe();
    const b = ae.value.find((N) => !z(N));
    ke.value = !b;
  }, ve = async () => {
    await x(), await ge(), e.showOperations || await Me();
  }, Le = async () => {
    var b, N;
    if ((N = (b = r.value) == null ? void 0 : b.store) != null && N.nodesMap && (r.value.store.nodesMap = {}), pe.value.length) {
      for (let E = 0; E < pe.value.length; E++)
        pe.value[E].childNodes = [], await oe(pe.value[E], We.value[E], !0);
      return await ve(), !0;
    }
  };
  return pt(
    () => e.renderDom,
    (b) => {
      b && Le();
    }
  ), $a(async () => {
    l.value && await ve();
  }), {
    rootLevelData: ae,
    searchLoading: de,
    searchData: ue,
    firstLoading: ne,
    lazyLoad: oe,
    search: Q,
    handleSearch: De,
    handleSearchClear: ct,
    handleSearchResultItemClick: _e,
    resetLazyLoad: Le
  };
}, og = (e, t, r) => {
  let a = 0, l = "";
  const d = (p = "visible", v) => {
    var _;
    if (!r.isEllipsis) return;
    const x = (_ = t.value) == null ? void 0 : _.$el.querySelectorAll(".el-tree-node__children"), j = (x == null ? void 0 : x.length) ?? 0;
    !v && l === p && a === j || (a = j, l = p, x && x.length && x.forEach((z) => {
      z.classList.remove(l === "visible" ? "overflow-hide" : "overflow-visible"), z.classList.add(l === "visible" ? "overflow-visible" : "overflow-hide");
    }));
  }, s = new AbortController(), { signal: g } = s;
  return $a(() => {
    var v;
    if (!r.isEllipsis) return;
    const p = (v = e.value) == null ? void 0 : v.querySelector(".das-tree-container");
    p && p.addEventListener("mousemove", () => d("visible"), { signal: g });
  }), _n(() => {
    r.isEllipsis && s.abort();
  }), { setTreeNodeChildrenOverflow: d };
}, sg = { class: "das-tree-box" }, ig = { class: "das-tree-container das-ce-scrollbar" }, lg = {
  ref: "treeParentRef",
  class: "tree-parent-container"
}, cg = {
  key: 0,
  class: "tree-oprations-node"
}, ug = {
  key: 0,
  class: "tree-oprations-label"
}, fg = {
  key: 1,
  class: "tree-oprations-label"
}, dg = ["onMouseenter"], vg = {
  key: 0,
  class: "tree-normal-node"
}, hg = {
  key: 1,
  class: "tree-normal-node"
}, yg = {
  key: 0,
  class: "empty-box"
}, pg = {
  key: 0,
  class: "search-result-container das-ce-scrollbar"
}, gg = ["onMousedown"], bg = { class: "name" }, $g = {
  key: 0,
  class: "path-name"
}, _g = {
  key: 1,
  class: "search-result-container"
}, mg = {
  key: 0,
  class: "search-result-container das-ce-scrollbar"
}, Tg = ["onMousedown"], Cg = { class: "name" }, wg = {
  key: 0,
  class: "path-name"
}, jg = {
  key: 1,
  class: "search-result-container"
}, kg = {
  key: 0,
  class: "opration-list"
}, Og = ["disabled", "onClick"], Sg = { class: "icon" }, Ag = { class: "label" }, Ig = ["disabled", "onClick"], xg = { class: "icon" }, Pg = { class: "label" }, Eg = ["disabled", "onClick"], Lg = { class: "icon" }, Kg = { class: "label" }, Ng = {
  name: "DasTree",
  inheritAttrs: !1
}, Dg = /* @__PURE__ */ nr({
  ...Ng,
  props: {
    data: { default: () => [] },
    loading: { type: Boolean },
    nodeKey: { default: "id" },
    modelValue: { default: "" },
    path: {},
    height: {},
    isEllipsis: { type: Boolean },
    draggable: { type: Boolean },
    allowDrag: {},
    currentNodeKey: { default: "" },
    defaultCheckedKeys: {},
    defaultExpandedKeys: { default: () => [] },
    defaultExpandedPaths: { default: () => [] },
    defaultExpandRoot: { type: Boolean, default: !0 },
    expandOnClickNode: { type: Boolean, default: void 0 },
    checkStrictly: { type: Boolean, default: void 0 },
    parentLinkChildrenStrictly: { type: Boolean },
    dataLinkView: { type: Boolean, default: !0 },
    getGrandChildren: {},
    childLinkParentStrictly: { type: Boolean },
    props: { default: () => ({}) },
    showCheckbox: { type: Boolean },
    hideRootCheckbox: { type: Boolean },
    showOperations: { type: Boolean },
    operations: {},
    mergeOprations: {},
    operationsLayout: { type: [String, Function], default: "add,addItem,edit,delete,preview,view" },
    operationsLabel: {},
    maxNodeLevel: { default: 12 },
    showFilterInput: { type: Boolean, default: !0 },
    isFilter: { type: Boolean },
    filterNodeMethod: {},
    filterValue: {},
    filterItemClass: {},
    inputOptions: { default: () => ({}) },
    emptyText: { default: "" },
    searchEmptyText: { default: "" },
    rootNodeId: { default: "-1" },
    load: {},
    search: {},
    renderDom: { type: Boolean, default: !0 },
    overlayZIndex: { default: "1" },
    keepSelected: { type: Boolean },
    notAutoresetLazyLoad: { type: Boolean },
    changeNodeConfirm: {}
  },
  emits: ["update:filterValue", "update:modelValue", "update:path", "change", "handleOperation", "filter-value-change", "filter-node-click", "node-change", "check-node-change", "node-click", "check-node-click", "node-db-click", "check-node-db-click", "current-change"],
  setup(e, { expose: t, emit: r }) {
    const a = e, l = r;
    kn({
      gengduocaozuo: import("@das-fed/ui/packages/icons/gengduocaozuo"),
      search: import("@das-fed/ui/packages/icons/search"),
      add: import("@das-fed/ui/packages/icons/add"),
      addItem: import("@das-fed/ui/packages/icons/add-item"),
      edit: import("@das-fed/ui/packages/icons/edit"),
      delete: import("@das-fed/ui/packages/icons/delete"),
      preview: import("@das-fed/ui/packages/icons/preview"),
      view: import("@das-fed/ui/packages/icons/view")
    });
    const d = mn(), s = U(), g = ee(() => a.emptyText || $e("暂无数据")), p = ee(() => a.searchEmptyText || $e("noDataTryAnotherKeyword")), v = ee(() => d.lazy ?? !!x.value), x = ee(() => a.load ?? void 0), j = U([]), _ = ee(() => a.search ?? void 0), z = ee(() => a.showCheckbox ? S.value : []), W = ee(() => a.showCheckbox ? a.currentNodeKey : S.value), S = ee({
      get() {
        return a.showCheckbox && !a.modelValue ? [] : a.modelValue;
      },
      set(n) {
        l("update:modelValue", n);
      }
    }), Z = ee({
      get: () => a.path,
      set: (n) => {
        l("update:path", n);
      }
    }), q = U([]), ke = ee(() => {
      let n = [...q.value, ...a.defaultExpandedKeys];
      return Array.from(new Set(n));
    }), ue = () => new Promise((n) => {
      const f = () => {
        var A, h, y, K;
        if ((h = (A = s.value) == null ? void 0 : A.store) != null && h.nodesMap && ((K = Object.keys((y = s.value) == null ? void 0 : y.store.nodesMap)) == null ? void 0 : K.length) > 0)
          return n(!0);
        setTimeout(() => f(), 50);
      };
      f();
    }), fe = (n) => new Promise((f) => {
      let A = 0;
      const h = () => {
        if (!(!j.value || !j.value.length)) {
          if (Array.isArray(n)) {
            const y = j.value.filter((K) => n.includes(K[a.nodeKey]));
            if (y.length === n.length) return f(y);
          } else {
            const y = j.value.find((K) => K[a.nodeKey] === n);
            if (y) return f(y);
          }
          if (setTimeout(() => {
            h(), A += 50;
          }, 50), A >= 6e3)
            return Array.isArray(n) ? f([]) : f({});
        }
      };
      h();
    }), ie = async (n) => a.getGrandChildren ? await a.getGrandChildren(n) : [], I = (n, f) => {
      var h;
      let A = n.childNodes.length;
      if (A > 0)
        for (let y = 0; y < A; y++) {
          const K = f, X = n.childNodes[y];
          if (J(X.data, X)) {
            I({ ...X }, f);
            continue;
          }
          X.checked !== K && (X.checked = K), I(X, f);
        }
      s.value && (S.value = (h = s.value) == null ? void 0 : h.getCheckedKeys());
    }, le = async (n, f) => {
      var K, X, te;
      if (Y(n, null)) {
        if (f)
          S.value.includes(n[a.nodeKey]) || S.value.push(n[a.nodeKey]);
        else {
          const re = S.value.findIndex((V) => V === n[a.nodeKey]);
          re > -1 && S.value.splice(re, 1);
        }
        return (K = s.value) == null || K.setCheckedKeys(S.value), oe.value = !0, [];
      }
      let A = await ie(n);
      j.value = ma([...j.value, ...A], a.nodeKey);
      const h = A.concat(n), y = Array.from(new Set(h.map((re) => re[a.nodeKey])));
      if (f) {
        const re = S.value ?? [], V = Be([...re, ...y]);
        S.value = Array.from(new Set(V)), (X = s.value) == null || X.setCheckedKeys(V);
      } else {
        const V = (S.value ?? []).filter((H) => !y.includes(H));
        S.value = Array.from(new Set(V)), (te = s.value) == null || te.setCheckedKeys(V);
      }
      return A;
    }, Q = U([]), ae = async (n, f) => {
      var h;
      if (v.value) {
        const y = await le(n, f);
        return l("check-node-change", S.value, n, f), Q.value = y.map((K) => K[a.nodeKey]), y;
      }
      await Pe();
      const A = (h = s.value) == null ? void 0 : h.getNode(n[a.nodeKey]);
      return I(A, f), [];
    }, pe = (n, f) => {
      const A = n == null ? void 0 : n.parent;
      if (!A) return;
      const h = f;
      if (J(A.data, A)) {
        pe({ ...A }, f);
        return;
      }
      A.checked !== h && (A.checked = h), pe(A, f);
    }, We = async (n, f) => {
      var h, y;
      await Pe();
      const A = (h = s.value) == null ? void 0 : h.getNode(n[a.nodeKey]);
      return pe(A, f), s.value && (S.value = (y = s.value) == null ? void 0 : y.getCheckedKeys()), !0;
    }, ne = U(!1), oe = U(!1), de = async (n, f, A = !1) => {
      var V, H;
      oe.value = !0;
      const { checkedKeys: h } = f, y = h.includes(n[a.nodeKey]), K = S.value.includes(n[a.nodeKey]), X = a.keepSelected && !sn(n) && K && !y;
      await Pe();
      let te = ((V = s.value) == null ? void 0 : V.getCheckedKeys()) || [];
      if (X && (te = Be([...te, n[a.nodeKey]]), a.showCheckbox && ((H = s.value) == null || H.setCheckedKeys(te))), a.parentLinkChildrenStrictly || (S.value = te), y && a.childLinkParentStrictly && !ne.value) {
        const D = S.value ?? [];
        await We(n, y), S.value = Array.from(/* @__PURE__ */ new Set([...D, ...S.value]));
      }
      let re = [];
      a.parentLinkChildrenStrictly && !ne.value && (re = await ae(n, y)), a.parentLinkChildrenStrictly && v.value || (await Pe(), l("check-node-change", S.value, n, y)), A && l("change", S.value, n, y, re);
    }, De = U(!1), {
      realHeight: ct,
      dasTree: _e,
      getMergeOperations: ge,
      getOperations: qe,
      handleOperation: Me,
      filterInnerValue: ve,
      filterList: Le,
      selectItem: b,
      nodeClass: N,
      nodeClick: E,
      isActive: he,
      defaultProps: P,
      filterNodeMethodFn: Ke,
      filterSeach: ce,
      filterClear: Oe,
      expandParent: Ce,
      disabledFlag: J,
      currentOprationKey: o,
      oprationVisibleChange: u,
      setOprationsMoreBtnRefs: c,
      oprationsPopoverRef: $,
      moreBtnEnter: m,
      currentMoreBtnRef: L,
      currentOprationItem: k,
      isLeafFlag: Y,
      filterCustomClass: Ne,
      allowUnSelectFlag: sn,
      findSelectableParentNode: ln,
      currentChange: cn
    } = jl(a, l, s, Z, S, v, q, de, De), {
      rootLevelData: un,
      searchLoading: Dt,
      searchData: Mt,
      lazyLoad: fn,
      firstLoading: dn,
      handleSearch: $r,
      handleSearchClear: vn,
      handleSearchResultItemClick: hn,
      resetLazyLoad: Ft
    } = ng(
      a,
      l,
      s,
      _e,
      v,
      ve,
      S,
      P,
      Z,
      E,
      ue,
      J,
      he,
      Y,
      j,
      de,
      q,
      ie,
      De
    ), yn = () => {
      _.value ? $r() : ce();
    };
    pt(
      () => ve.value,
      (n) => {
        l("filter-value-change", n), yn();
      }
    );
    const Je = U(null);
    pt(
      () => S.value,
      (n) => {
        var h, y, K, X, te, re;
        const f = a.showCheckbox ? n ?? [] : n ?? void 0, A = a.showCheckbox ? Je.value ?? [] : Je.value ?? void 0;
        if (JSON.stringify(f) !== JSON.stringify(A)) {
          if (a.showCheckbox) {
            if (f.length === 0) {
              (y = s.value) == null || y.setCheckedKeys([]), Je.value = Be(f);
              return;
            }
          } else if (!f) {
            (h = s.value) == null || h.setCurrentKey(), Je.value = Be(f);
            return;
          }
          if (oe.value) {
            oe.value = !1, Je.value = Be(f);
            return;
          }
          if (!v.value)
            a.showCheckbox ? (K = s.value) == null || K.setCheckedKeys(f) : Ce();
          else if (a.showCheckbox)
            if (!a.parentLinkChildrenStrictly || !a.dataLinkView) {
              const V = j.value.map((D) => D[a.nodeKey]), H = f.filter((D) => !V.includes(D));
              H && H.length ? Ft().then(() => {
                var D;
                s.value && ((D = s.value) == null || D.setCheckedKeys(f));
              }) : s.value && ((te = s.value) == null || te.setCheckedKeys(f));
            } else {
              if (s.value && ((re = s.value) == null || re.setCheckedKeys([])), f.length && A.length === 0)
                for (let V of f) {
                  const H = Q.value.findIndex((D) => D === V);
                  H !== -1 && Q.value.splice(H, 1), fe(V).then((D) => {
                    D && (ne.value = !0, de(D, { checkedKeys: [...f] }).then(() => {
                      oe.value = !1, ne.value = !1;
                    }));
                  });
                }
              if (f.length && A.length) {
                const V = A.filter((D) => !f.includes(D)), H = f.filter((D) => !A.includes(D));
                if (V && V.length)
                  for (let D of V) {
                    const T = Q.value.findIndex((se) => se === D);
                    T !== -1 && Q.value.splice(T, 1), fe(D).then(async (se) => {
                      se && (ne.value = !0, de(se, { checkedKeys: [...f] }).then(() => {
                        oe.value = !1, ne.value = !1;
                      }));
                    });
                  }
                if (H && H.length)
                  for (let D of H) {
                    const T = Q.value.findIndex((se) => se === D);
                    T !== -1 && Q.value.splice(T, 1), fe(D).then((se) => {
                      se && (ne.value = !0, de(se, { checkedKeys: [...f] }).then(() => {
                        oe.value = !1, ne.value = !1;
                      }));
                    });
                  }
              }
            }
          else if (j.value.find((H) => H[a.nodeKey] === f))
            (X = s.value) == null || X.setCurrentKey(f);
          else {
            if (a.notAutoresetLazyLoad) return;
            Ft().then(() => {
              var H;
              (H = s.value) == null || H.setCurrentKey(f);
            });
          }
          Je.value = Be(f);
        }
      },
      { immediate: !0, deep: !0 }
    );
    const Bt = () => {
      _.value ? vn() : Oe();
    }, pn = ee(() => a.parentLinkChildrenStrictly || a.childLinkParentStrictly ? !0 : !!(a.checkStrictly ?? v.value)), gn = ee(() => v.value ? !!dn.value : a.loading), Ut = ee(() => {
      var n, f;
      return v.value ? !((n = un.value) != null && n.length) : !((f = a.data) != null && f.length);
    }), _r = ee(() => {
      var n;
      if (_.value)
        return !Dt.value && ((n = Mt.value) == null ? void 0 : n.length) === 1 && Mt.value[0][P.value.label] === $e("暂无数据");
      if (a.isFilter)
        return Le.value.length === 1 && Le.value[0][P.value.label] === $e("暂无数据");
    }), { setTreeNodeChildrenOverflow: bn } = og(_e, s, a), $n = () => {
      a.isEllipsis && bn("hidden");
    };
    return t({
      /** el-tree实例 */
      treeRef: s,
      /** 数据是否为空 */
      treeIsEmpty: Ut,
      /** 获取可选的父级节点，递归往上查找 */
      findSelectableParentNode: ln,
      /** 非懒加载：子级联动父级 */
      childLinkParent: pe,
      /** 非懒加载：父级联动子级 */
      parentLinkChild: I,
      /** 清空搜索框并重新加载整棵树方法(用于懒加载重新请求整颗树的数据) */
      resetLazyLoad: async () => ((_.value || a.isFilter) && (ve.value = "", Bt()), await Ft(), !0),
      /** 自动展开父节点方法 */
      autoExpand: Ce,
      /** 清空搜索值，回到tree面板 */
      searchClear: Bt,
      /** 懒加载获取到的所有平铺数据 */
      lazyData: j,
      /** 判断懒加载指定节点、节点集合是否全部加载完成 */
      lazyDataNextTick: fe,
      /** 非懒加载模式触发搜索 */
      filterSeach: ce,
      /** 懒加载模式触发搜索 */
      handleSearch: $r,
      /** 根据父级获取所有子孙节点(提供给tree-select组件使用) */
      getGrandChildrenFn: ie
    }), (n, f) => {
      var A;
      return C(), w(
        "div",
        {
          ref_key: "dasTree",
          ref: _e,
          style: Tr({ height: i(ct) }),
          class: Xe({
            "das-ui-tree": !0,
            "is-checkbox": n.showCheckbox,
            "is-ellipsis": n.isEllipsis,
            "is-operations": n.showOperations,
            "is-draggable": n.draggable,
            "root-checkbox_hide": n.hideRootCheckbox
          })
        },
        [
          (n.isFilter || _.value) && n.showFilterInput ? (C(), Wt(i(On), Cr({
            key: 0,
            class: "das-tree-filter-input",
            modelValue: i(ve),
            "onUpdate:modelValue": f[0] || (f[0] = (h) => Tn(ve) ? ve.value = h : null),
            borderType: "bordered",
            size: "table"
          }, n.inputOptions, {
            placeholder: (A = n.inputOptions) != null && A.placeholder ? n.inputOptions.placeholder : i($e)("请搜索"),
            onClear: Bt,
            clearable: "",
            filterSpace: !1
          }), mt({
            prefix: Ae(() => [
              M(n.$slots, "prefix", {}, () => [
                Se(i(ft), {
                  icon: "search",
                  customSize: 19,
                  iconColor: "#999999",
                  style: { cursor: "pointer" }
                })
              ])
            ]),
            _: 2
            /* DYNAMIC */
          }, [
            n.$slots.suffix ? {
              name: "suffix",
              fn: Ae(() => [
                M(n.$slots, "suffix")
              ]),
              key: "0"
            } : void 0,
            n.$slots.prepend ? {
              name: "prepend",
              fn: Ae(() => [
                M(n.$slots, "prepend")
              ]),
              key: "1"
            } : void 0,
            n.$slots.append ? {
              name: "append",
              fn: Ae(() => [
                M(n.$slots, "append")
              ]),
              key: "2"
            } : void 0
          ]), 1040, ["modelValue", "placeholder"])) : O("v-if", !0),
          n.$slots["container-top"] ? M(n.$slots, "container-top", { key: 1 }) : O("v-if", !0),
          ye((C(), w("div", sg, [
            O(" das-ce-scrollbar开头的样式不要删除  web componets引用了该组件，有用的！！！ "),
            ye((C(), w("div", ig, [
              n.$slots.top ? M(n.$slots, "top", { key: 0 }) : O("v-if", !0),
              Fe(
                "div",
                lg,
                [
                  (C(), Wt(i(An), Cr({
                    ref_key: "treeRef",
                    ref: s,
                    key: n.renderDom,
                    class: { "is-root-all-left": De.value },
                    icon: En,
                    data: n.renderDom ? n.data : [],
                    lazy: v.value,
                    load: x.value ? i(fn) : void 0,
                    "check-strictly": v.value ? !0 : pn.value,
                    "node-key": n.nodeKey,
                    "current-node-key": W.value,
                    "default-checked-keys": z.value,
                    "default-expanded-keys": ke.value,
                    props: { ...i(P), class: i(N) },
                    "show-checkbox": n.showCheckbox,
                    "expand-on-click-node": n.expandOnClickNode ?? n.showCheckbox,
                    "filter-node-method": i(Ke),
                    draggable: n.draggable,
                    "allow-drag": n.allowDrag
                  }, { ...i(d), onCurrentChange: void 0 }, {
                    onCurrentChange: i(cn),
                    onNodeClick: i(E),
                    onCheck: f[2] || (f[2] = (h, y) => {
                      de(h, y, !0);
                    }),
                    onNodeCollapse: $n
                  }), {
                    default: Ae(({ node: h, data: y }) => [
                      M(n.$slots, "default", {
                        node: h,
                        data: y
                      }, () => {
                        var K, X;
                        return [
                          f[5] || (f[5] = Fe(
                            "div",
                            null,
                            null,
                            -1
                            /* CACHED */
                          )),
                          O(" 有操作项 "),
                          n.showOperations ? (C(), w("div", cg, [
                            M(n.$slots, "oprations-label", {
                              node: h,
                              data: y
                            }, () => [
                              n.isEllipsis ? ye((C(), w("div", ug, [
                                we(
                                  be(y[i(P).label]),
                                  1
                                  /* TEXT */
                                )
                              ])), [
                                [i(Ie)]
                              ]) : O("v-if", !0),
                              n.isEllipsis ? O("v-if", !0) : (C(), w(
                                "div",
                                fg,
                                be(y[i(P).label]),
                                1
                                /* TEXT */
                              ))
                            ]),
                            !i(J)(y, h) && ((X = (K = i(ge)(h, y)) == null ? void 0 : K.list) != null && X.length || i(qe)(h, y).length) ? (C(), w("div", {
                              key: 0,
                              class: "oprations-box",
                              onMouseenter: (te) => i(m)(h, y)
                            }, [
                              Fe(
                                "div",
                                {
                                  class: "more-icon",
                                  ref: (te) => i(c)(te, y[n.nodeKey]),
                                  style: Tr(i(o) === y[n.nodeKey] ? "opacity: 1" : ""),
                                  onClick: f[1] || (f[1] = Ye(() => {
                                  }, ["stop"]))
                                },
                                [
                                  Se(i(ft), {
                                    icon: "gengduocaozuo",
                                    iconColor: "#666666",
                                    size: "medium"
                                  })
                                ],
                                4
                                /* STYLE */
                              )
                            ], 40, dg)) : O("v-if", !0)
                          ])) : O("v-if", !0),
                          O(" 无操作项 "),
                          n.showOperations ? O("v-if", !0) : (C(), w(
                            me,
                            { key: 1 },
                            [
                              n.isEllipsis ? ye((C(), w("div", vg, [
                                we(
                                  be(y[i(P).label]),
                                  1
                                  /* TEXT */
                                )
                              ])), [
                                [i(Ie)]
                              ]) : (C(), w(
                                "div",
                                hg,
                                be(y[i(P).label]),
                                1
                                /* TEXT */
                              ))
                            ],
                            64
                            /* STABLE_FRAGMENT */
                          ))
                        ];
                      })
                    ]),
                    _: 3
                    /* FORWARDED */
                  }, 16, ["class", "data", "lazy", "load", "check-strictly", "node-key", "current-node-key", "default-checked-keys", "default-expanded-keys", "props", "show-checkbox", "expand-on-click-node", "filter-node-method", "draggable", "allow-drag", "onCurrentChange", "onNodeClick"]))
                ],
                512
                /* NEED_PATCH */
              ),
              n.$slots.bottom ? M(n.$slots, "bottom", { key: 1 }) : O("v-if", !0)
            ])), [
              [i(zt)],
              [Cn, !Ut.value]
            ]),
            O(" 空状态 "),
            Ut.value && !gn.value ? (C(), w("div", yg, [
              n.$slots.top ? M(n.$slots, "top", { key: 0 }) : O("v-if", !0),
              Se(Ct, { "empty-text": g.value }, mt({
                _: 2
                /* DYNAMIC */
              }, [
                n.$slots["empty-text"] ? {
                  name: "default",
                  fn: Ae(() => [
                    M(n.$slots, "empty-text")
                  ]),
                  key: "0"
                } : void 0
              ]), 1032, ["empty-text"]),
              n.$slots.bottom ? M(n.$slots, "bottom", { key: 1 }) : O("v-if", !0)
            ])) : O("v-if", !0),
            O(" 懒加载：搜索节点 "),
            i(ve) && !i(Dt) && _.value ? (C(), w(
              me,
              { key: 1 },
              [
                _r.value ? (C(), w("div", _g, [
                  n.$slots.top ? M(n.$slots, "top", { key: 0 }) : O("v-if", !0),
                  Se(Ct, { "empty-text": p.value }, mt({
                    _: 2
                    /* DYNAMIC */
                  }, [
                    n.$slots["search-empty-text"] ? {
                      name: "default",
                      fn: Ae(() => [
                        M(n.$slots, "search-empty-text")
                      ]),
                      key: "0"
                    } : void 0
                  ]), 1032, ["empty-text"]),
                  n.$slots.bottom ? M(n.$slots, "bottom", { key: 1 }) : O("v-if", !0)
                ])) : ye((C(), w("ul", pg, [
                  n.$slots.top ? M(n.$slots, "top", { key: 0 }) : O("v-if", !0),
                  (C(!0), w(
                    me,
                    null,
                    ut(i(Mt), (h, y) => (C(), w("li", {
                      key: h[n.nodeKey],
                      class: Xe([
                        "search-result-item",
                        i(he)(h, !0) ? "is-active" : "",
                        i(J)(h, null) ? "is-disabled" : "",
                        i(Ne)(h, y)
                      ]),
                      onMousedown: Ye((K) => i(hn)(h, !0), ["stop"])
                    }, [
                      M(n.$slots, "search-result-item", {
                        item: h,
                        index: y
                      }, () => [
                        ye((C(), w("div", bg, [
                          we(
                            be(h[i(P).label]),
                            1
                            /* TEXT */
                          )
                        ])), [
                          [i(Ie)]
                        ]),
                        h[i(P).pathName] ? ye((C(), w("div", $g, [
                          we(
                            be(h[i(P).pathName]),
                            1
                            /* TEXT */
                          )
                        ])), [
                          [i(Ie)]
                        ]) : O("v-if", !0)
                      ])
                    ], 42, gg))),
                    128
                    /* KEYED_FRAGMENT */
                  )),
                  n.$slots.bottom ? M(n.$slots, "bottom", { key: 1 }) : O("v-if", !0)
                ])), [
                  [i(zt)]
                ])
              ],
              64
              /* STABLE_FRAGMENT */
            )) : i(ve) && n.isFilter ? (C(), w(
              me,
              { key: 2 },
              [
                O(" 非懒加载：搜索节点 "),
                _r.value ? (C(), w("div", jg, [
                  n.$slots.top ? M(n.$slots, "top", { key: 0 }) : O("v-if", !0),
                  Se(Ct, { "empty-text": p.value }, mt({
                    _: 2
                    /* DYNAMIC */
                  }, [
                    n.$slots["search-empty-text"] ? {
                      name: "default",
                      fn: Ae(() => [
                        M(n.$slots, "search-empty-text")
                      ]),
                      key: "0"
                    } : void 0
                  ]), 1032, ["empty-text"]),
                  n.$slots.bottom ? M(n.$slots, "bottom", { key: 1 }) : O("v-if", !0)
                ])) : ye((C(), w("ul", mg, [
                  n.$slots.top ? M(n.$slots, "top", { key: 0 }) : O("v-if", !0),
                  (C(!0), w(
                    me,
                    null,
                    ut(i(Le), (h, y) => (C(), w("li", {
                      key: h[n.nodeKey],
                      class: Xe([
                        "search-result-item",
                        i(he)(h, !0) ? "is-active" : "",
                        i(J)(h, null) ? "is-disabled" : "",
                        i(Ne)(h, y)
                      ]),
                      onMousedown: Ye((K) => i(b)(h), ["stop"])
                    }, [
                      M(n.$slots, "search-result-item", {
                        item: h,
                        index: y
                      }, () => [
                        ye((C(), w("div", Cg, [
                          we(
                            be(h[i(P).label]),
                            1
                            /* TEXT */
                          )
                        ])), [
                          [i(Ie)]
                        ]),
                        h[i(P).pathName] ? ye((C(), w("div", wg, [
                          we(
                            be(h[i(P).pathName]),
                            1
                            /* TEXT */
                          )
                        ])), [
                          [i(Ie)]
                        ]) : O("v-if", !0)
                      ])
                    ], 42, Tg))),
                    128
                    /* KEYED_FRAGMENT */
                  )),
                  n.$slots.bottom ? M(n.$slots, "bottom", { key: 1 }) : O("v-if", !0)
                ])), [
                  [i(zt)]
                ])
              ],
              64
              /* STABLE_FRAGMENT */
            )) : O("v-if", !0)
          ])), [
            [i(Sn), v.value && i(Dt)]
          ]),
          n.$slots["container-bottom"] ? M(n.$slots, "container-bottom", { key: 2 }) : O("v-if", !0),
          O(" 操作项（单例，解决dom渲染性能问题） "),
          Se(i(In), {
            "popper-class": "das-tree-operation-dropdown",
            ref_key: "oprationsPopoverRef",
            ref: $,
            "virtual-ref": i(L),
            placement: "bottom-start",
            "show-arrow": !1,
            trigger: "hover",
            "virtual-triggering": "",
            onShow: f[3] || (f[3] = (h) => i(u)(!0)),
            onHide: f[4] || (f[4] = (h) => i(u)(!1))
          }, {
            default: Ae(() => {
              var h, y, K, X, te, re, V, H, D;
              return [
                (h = i(k)) != null && h.node ? (C(), w("ul", kg, [
                  (K = (y = i(ge)(i(k).node, i(k).data)) == null ? void 0 : y.list) != null && K.length && ((X = i(ge)(i(k).node, i(k).data)) == null ? void 0 : X.position) === "top" ? (C(!0), w(
                    me,
                    { key: 0 },
                    ut((te = i(ge)(i(k).node, i(k).data)) == null ? void 0 : te.list, (T, se) => (C(), w(
                      me,
                      {
                        key: T.value
                      },
                      [
                        T.hidden ? O("v-if", !0) : (C(), w("li", {
                          class: Xe(["opration-item", T.disabled ? "is-disabled" : ""]),
                          key: T.value || se,
                          disabled: T.disabled,
                          onClick: Ye((mr) => i(Me)(T, i(k).node, i(k).data), ["stop"])
                        }, [
                          Fe("div", Sg, [
                            Se(i(ft), {
                              icon: T.icon,
                              size: "small",
                              iconColor: T.disabled ? "#b2b2b2" : T.iconColor ? T.iconColor : "#666666"
                            }, null, 8, ["icon", "iconColor"])
                          ]),
                          ye((C(), w("div", Ag, [
                            we(
                              be(T.label || T.value),
                              1
                              /* TEXT */
                            )
                          ])), [
                            [i(Ie)]
                          ])
                        ], 10, Og))
                      ],
                      64
                      /* STABLE_FRAGMENT */
                    ))),
                    128
                    /* KEYED_FRAGMENT */
                  )) : O("v-if", !0),
                  (C(!0), w(
                    me,
                    null,
                    ut(i(qe)(i(k).node, i(k).data), (T, se) => (C(), w(
                      me,
                      {
                        key: T.value
                      },
                      [
                        T.hidden ? O("v-if", !0) : (C(), w("li", {
                          class: Xe(["opration-item", T.disabled ? "is-disabled" : ""]),
                          key: T.value || se,
                          disabled: T.disabled,
                          onClick: Ye((mr) => i(Me)(T, i(k).node, i(k).data), ["stop"])
                        }, [
                          Fe("div", xg, [
                            Se(i(ft), {
                              icon: T.icon,
                              size: "small",
                              iconColor: T.disabled ? "#b2b2b2" : T.iconColor ? T.iconColor : "#666666"
                            }, null, 8, ["icon", "iconColor"])
                          ]),
                          ye((C(), w("div", Pg, [
                            we(
                              be(T.label || T.value),
                              1
                              /* TEXT */
                            )
                          ])), [
                            [i(Ie)]
                          ])
                        ], 10, Ig))
                      ],
                      64
                      /* STABLE_FRAGMENT */
                    ))),
                    128
                    /* KEYED_FRAGMENT */
                  )),
                  (V = (re = i(ge)(i(k).node, i(k).data)) == null ? void 0 : re.list) != null && V.length && ((H = i(ge)(i(k).node, i(k).data)) == null ? void 0 : H.position) === "bottom" ? (C(!0), w(
                    me,
                    { key: 1 },
                    ut((D = i(ge)(i(k).node, i(k).data)) == null ? void 0 : D.list, (T, se) => (C(), w(
                      me,
                      {
                        key: T.value
                      },
                      [
                        T.hidden ? O("v-if", !0) : (C(), w("li", {
                          class: Xe(["opration-item", T.disabled ? "is-disabled" : ""]),
                          key: T.value || se,
                          disabled: T.disabled,
                          onClick: Ye((mr) => i(Me)(T, i(k).node, i(k).data), ["stop"])
                        }, [
                          Fe("div", Lg, [
                            Se(i(ft), {
                              icon: T.icon,
                              size: "small",
                              iconColor: T.disabled ? "#b2b2b2" : T.iconColor ? T.iconColor : "#666666"
                            }, null, 8, ["icon", "iconColor"])
                          ]),
                          ye((C(), w("div", Kg, [
                            we(
                              be(T.label || T.value),
                              1
                              /* TEXT */
                            )
                          ])), [
                            [i(Ie)]
                          ])
                        ], 10, Eg))
                      ],
                      64
                      /* STABLE_FRAGMENT */
                    ))),
                    128
                    /* KEYED_FRAGMENT */
                  )) : O("v-if", !0)
                ])) : O("v-if", !0)
              ];
            }),
            _: 1
            /* STABLE */
          }, 8, ["virtual-ref"])
        ],
        6
        /* CLASS, STYLE */
      );
    };
  }
}), Mg = {
  "--das-ui-tree-node-disabled-bg-color": "#B2B2B2",
  "--das-ui-tree-node-hover-bg-color": "#F5F5F5",
  "--das-ui-tree-node-active-bg-color": "#E3EBFF",
  "--das-ui-tree-node-active-font-color": "#5582F3",
  "--das-ui-tree-node-checkbox-border-color": "#D9D9D9",
  "--das-ui-tree-node-checkbox-checked-bg-color": "#5582F3",
  "--das-ui-tree-node-checkbox-disabled-checked-bg-color": "#D9D9D9",
  "--das-ui-tree-node-checkbox-disabled-checked-icon-color": "#b4b4b4",
  "--das-ui-tree-node-drop-color": "#333333",
  "--das-ui-tree-node-drop-bg-color": "#E3EBFF",
  "--das-ui-tree-node-drop-border-color": "#5582F3",
  "--das-ui-tree-node-drop-indicator-color": "#276FF5",
  "--das-ui-tree-empty-text": "#999999"
}, Fg = {
  请搜索: { "zh-CN": "请搜索", en: "Please search", _appCode: "framework" },
  "搜索中...": { "zh-CN": "搜索中...", en: "Search...", _appCode: "framework" },
  新增同级: { "zh-CN": "新增同级", en: "Add Sibling", _appCode: "framework" },
  新增子级: { "zh-CN": "新增子级", en: "Add Child", _appCode: "framework" },
  编辑: { "zh-CN": "编辑", en: "Edit", _appCode: "framework" },
  删除: { "zh-CN": "删除", en: "Delete", _appCode: "framework" },
  请选择: { "zh-CN": "请选择", en: "Please Select", _appCode: "framework" },
  暂无数据: { "zh-CN": "暂无数据", en: "No Data", _appCode: "framework" },
  noDataTryAnotherKeyword: {
    "zh-CN": "未查询到相关数据，换个关键词试试吧！",
    en: "No relevant data found, try a different keyword!",
    _appCode: "framework"
  }
};
jn(Fg);
wn(Mg);
const tb = _a(Dg), rb = _a(Ct), ab = () => U(null), nb = { name: "Tree 树" };
export {
  tb as DasTree,
  rb as DasTreeEmpty,
  ab as DasTreeRef,
  nb as default
};
