e-virt-table 1.2.0 → 1.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.es.js CHANGED
@@ -149,7 +149,7 @@ function Ae(a) {
149
149
  t.push.apply(t, a[e] || []);
150
150
  }), t;
151
151
  }
152
- var Ft = /* @__PURE__ */ function(a) {
152
+ var Bt = /* @__PURE__ */ function(a) {
153
153
  Re(t, a);
154
154
  function t(e, i) {
155
155
  var s;
@@ -161,7 +161,7 @@ function Te(a, t, e, i, s) {
161
161
  if (t.first) {
162
162
  var r = new Promise(function(x, g) {
163
163
  var p = function(y) {
164
- return i(y), y.length ? g(new Ft(y, bt(y))) : x(s);
164
+ return i(y), y.length ? g(new Bt(y, bt(y))) : x(s);
165
165
  }, u = Ae(a);
166
166
  Xt(u, e, p);
167
167
  });
@@ -172,7 +172,7 @@ function Te(a, t, e, i, s) {
172
172
  var o = t.firstFields === !0 ? Object.keys(a) : t.firstFields || [], n = Object.keys(a), h = n.length, c = 0, d = [], f = new Promise(function(x, g) {
173
173
  var p = function(w) {
174
174
  if (d.push.apply(d, w), c++, c === h)
175
- return i(d), d.length ? g(new Ft(d, bt(d))) : x(s);
175
+ return i(d), d.length ? g(new Bt(d, bt(d))) : x(s);
176
176
  };
177
177
  n.length || (i(d), x(s)), n.forEach(function(u) {
178
178
  var w = a[u];
@@ -194,7 +194,7 @@ function He(a, t) {
194
194
  }
195
195
  return e;
196
196
  }
197
- function Bt(a, t) {
197
+ function Ft(a, t) {
198
198
  return function(e) {
199
199
  var i;
200
200
  return a.fullFields ? i = He(t, a.fullFields) : i = t[e.field || a.fullField], Me(e) ? (e.field = e.field || a.fullField, e.fieldValue = i, e) : {
@@ -299,12 +299,12 @@ var Zt = function(t, e, i, s, r, o) {
299
299
  }
300
300
  var o = ["integer", "float", "array", "regexp", "object", "method", "email", "number", "date", "url", "hex"], n = t.type;
301
301
  o.indexOf(n) > -1 ? et[n](e) || s.push(D(r.messages.types[n], t.fullField, t.type)) : n && typeof e !== t.type && s.push(D(r.messages.types[n], t.fullField, t.type));
302
- }, Fe = function(t, e, i, s, r) {
302
+ }, Be = function(t, e, i, s, r) {
303
303
  var o = typeof t.len == "number", n = typeof t.min == "number", h = typeof t.max == "number", c = /[\uD800-\uDBFF][\uDC00-\uDFFF]/g, d = e, f = null, x = typeof e == "number", g = typeof e == "string", p = Array.isArray(e);
304
304
  if (x ? f = "number" : g ? f = "string" : p && (f = "array"), !f)
305
305
  return !1;
306
306
  p && (d = e.length), g && (d = e.replace(c, "_").length), o ? d !== t.len && s.push(D(r.messages[f].len, t.fullField, t.len)) : n && !h && d < t.min ? s.push(D(r.messages[f].min, t.fullField, t.min)) : h && !n && d > t.max ? s.push(D(r.messages[f].max, t.fullField, t.max)) : n && h && (d < t.min || d > t.max) && s.push(D(r.messages[f].range, t.fullField, t.min, t.max));
307
- }, j = "enum", Be = function(t, e, i, s, r) {
307
+ }, j = "enum", Fe = function(t, e, i, s, r) {
308
308
  t[j] = Array.isArray(t[j]) ? t[j] : [], t[j].indexOf(e) === -1 && s.push(D(r.messages[j], t.fullField, t[j].join(", ")));
309
309
  }, ke = function(t, e, i, s, r) {
310
310
  if (t.pattern) {
@@ -319,8 +319,8 @@ var Zt = function(t, e, i, s, r, o) {
319
319
  required: Zt,
320
320
  whitespace: De,
321
321
  type: Xe,
322
- range: Fe,
323
- enum: Be,
322
+ range: Be,
323
+ enum: Fe,
324
324
  pattern: ke
325
325
  }, Ke = function(t, e, i, s, r) {
326
326
  var o = [], n = t.required || !t.required && s.hasOwnProperty(t.field);
@@ -583,14 +583,14 @@ var Rt = vt(), nt = /* @__PURE__ */ function() {
583
583
  v === void 0 && (v = []);
584
584
  var O = Array.isArray(v) ? v : [v];
585
585
  !h.suppressWarning && O.length && a.warning("async-validator:", O), O.length && y.message !== void 0 && (O = [].concat(y.message));
586
- var S = O.map(Bt(y, n));
586
+ var S = O.map(Ft(y, n));
587
587
  if (h.first && S.length)
588
588
  return p[y.field] = 1, w(S);
589
589
  if (!E)
590
590
  w(S);
591
591
  else {
592
592
  if (y.required && !u.value)
593
- return y.message !== void 0 ? S = [].concat(y.message).map(Bt(y, n)) : h.error && (S = [h.error(y, D(h.messages.required, y.field))]), w(S);
593
+ return y.message !== void 0 ? S = [].concat(y.message).map(Ft(y, n)) : h.error && (S = [h.error(y, D(h.messages.required, y.field))]), w(S);
594
594
  var I = {};
595
595
  y.defaultField && Object.keys(u.value).map(function(L) {
596
596
  I[L] = y.defaultField;
@@ -2175,8 +2175,8 @@ class ai {
2175
2175
  }, "");
2176
2176
  for (let R = e - 1; R >= 0; R--) {
2177
2177
  const A = this.rowIndexRowKeyMap.get(R) || "", L = h.reduce((M, T) => {
2178
- const B = this.getItemValue(A, T) ?? "";
2179
- return `${M}${B}`;
2178
+ const F = this.getItemValue(A, T) ?? "";
2179
+ return `${M}${F}`;
2180
2180
  }, "");
2181
2181
  if (I === L)
2182
2182
  w = R;
@@ -2185,8 +2185,8 @@ class ai {
2185
2185
  }
2186
2186
  for (let R = e; R <= this.ctx.maxRowIndex; R++) {
2187
2187
  const A = this.rowIndexRowKeyMap.get(R) || "", L = h.reduce((M, T) => {
2188
- const B = this.getItemValue(A, T) ?? "";
2189
- return `${M}${B}`;
2188
+ const F = this.getItemValue(A, T) ?? "";
2189
+ return `${M}${F}`;
2190
2190
  }, "");
2191
2191
  if (I === L)
2192
2192
  y = R;
@@ -2372,7 +2372,7 @@ class hi {
2372
2372
  this.ctx = t, this.init();
2373
2373
  }
2374
2374
  init() {
2375
- this.bind(window, "resize", this.handleResize.bind(this)), this.bind(window, "mouseup", this.handleMouseUp.bind(this)), this.bind(window, "mousemove", this.handleMousemove.bind(this)), this.bind(window, "blur", this.handleOutsideMousedown.bind(this)), this.bind(window, "mousedown", this.handleOutsideMousedown.bind(this)), this.bind(this.ctx.stageElement, "click", this.handleClick.bind(this)), this.bind(window, "keydown", this.handleKeydown.bind(this)), this.bind(this.ctx.stageElement, "wheel", this.handleWheel.bind(this)), this.bind(this.ctx.stageElement, "touchstart", this.handleTouchstart.bind(this)), this.bind(this.ctx.stageElement, "touchend", this.handleTouchend.bind(this)), this.bind(this.ctx.stageElement, "touchmove", this.handleTouchmove.bind(this)), this.bind(this.ctx.stageElement, "contextmenu", this.handleContextMenu.bind(this)), this.bind(this.ctx.stageElement, "mousedown", this.handleMouseDown.bind(this)), this.bind(this.ctx.stageElement, "dblclick", this.handleDblclick.bind(this)), this.bind(this.ctx.stageElement, "mouseover", this.handleMouseover.bind(this)), this.bind(this.ctx.stageElement, "mouseout", this.handleMouseout.bind(this));
2375
+ this.bind(window, "resize", this.handleResize.bind(this)), this.bind(window, "mouseup", this.handleMouseUp.bind(this)), this.bind(window, "mousemove", this.handleMousemove.bind(this)), this.bind(window, "blur", this.handleOutsideMousedown.bind(this)), this.bind(window, "mousedown", this.handleOutsideMousedown.bind(this)), this.bind(this.ctx.stageElement, "click", this.handleClick.bind(this)), this.bind(window, "keydown", this.handleKeydown.bind(this)), this.bind(this.ctx.stageElement, "wheel", this.handleWheel.bind(this), { passive: !1 }), this.bind(this.ctx.stageElement, "touchstart", this.handleTouchstart.bind(this), { passive: !1 }), this.bind(this.ctx.stageElement, "touchend", this.handleTouchend.bind(this)), this.bind(this.ctx.stageElement, "touchmove", this.handleTouchmove.bind(this), { passive: !1 }), this.bind(this.ctx.stageElement, "contextmenu", this.handleContextMenu.bind(this)), this.bind(this.ctx.stageElement, "mousedown", this.handleMouseDown.bind(this)), this.bind(this.ctx.stageElement, "dblclick", this.handleDblclick.bind(this)), this.bind(this.ctx.stageElement, "mouseover", this.handleMouseover.bind(this)), this.bind(this.ctx.stageElement, "mouseout", this.handleMouseout.bind(this));
2376
2376
  }
2377
2377
  destroy() {
2378
2378
  this.eventTasks.forEach((t, e) => {
@@ -2854,24 +2854,30 @@ class fi {
2854
2854
  for (let e = 0; e < this.ctx.config.ICONS.length; e++) {
2855
2855
  const i = this.ctx.config.ICONS[e];
2856
2856
  let s = i.color;
2857
- const r = this.createImageFromSVG(i.svg, s).then((o) => {
2857
+ const r = this.createImageFromSVG(i.svg, s, i.isBlob).then((o) => {
2858
2858
  this.icons.set(i.name, o);
2859
2859
  });
2860
2860
  t.push(r);
2861
2861
  }
2862
2862
  await Promise.all(t), this.ctx.emit("draw");
2863
2863
  }
2864
- async createImageFromSVG(t, e) {
2865
- const r = new DOMParser().parseFromString(t, "image/svg+xml").documentElement;
2866
- e && r.querySelectorAll("*").forEach((c) => {
2864
+ async createImageFromSVG(t, e, i = !1) {
2865
+ const o = new DOMParser().parseFromString(t, "image/svg+xml").documentElement;
2866
+ e && o.querySelectorAll("*").forEach((c) => {
2867
2867
  c.setAttribute("fill", e);
2868
2868
  });
2869
- const o = new Image(), n = new Blob([new XMLSerializer().serializeToString(r)], {
2870
- type: "image/svg+xml"
2871
- }), h = URL.createObjectURL(n);
2872
- return o.src = h, new Promise((c, d) => {
2873
- o.onerror = () => d(new Error("Failed to load image")), o.onload = () => {
2874
- c(o);
2869
+ const n = new Image();
2870
+ let h = "";
2871
+ if (i) {
2872
+ const c = new Blob([new XMLSerializer().serializeToString(o)], {
2873
+ type: "image/svg+xml"
2874
+ });
2875
+ h = URL.createObjectURL(c);
2876
+ } else
2877
+ h = "data:image/svg+xml;charset=utf-8," + encodeURIComponent(new XMLSerializer().serializeToString(o));
2878
+ return n.src = h, new Promise((c, d) => {
2879
+ n.onerror = () => d(new Error("Failed to load image")), n.onload = () => {
2880
+ c(n);
2875
2881
  };
2876
2882
  });
2877
2883
  }
@@ -3927,32 +3933,32 @@ class pi {
3927
3933
  this.height = p, this.data = g, this.width = e.width, this.visibleWidth = this.ctx.stageWidth - o;
3928
3934
  const u = this.ctx.footer.height;
3929
3935
  !this.data.length && !n ? this.height = h : !this.data.length && n && (this.height = n - e.height - u - o);
3930
- const w = this.data.length ? "not-empty" : "empty";
3936
+ let w = this.height + e.height + o;
3937
+ w += u;
3938
+ let y = w;
3939
+ const E = window.innerHeight, { top: m } = this.containerRect || this.ctx.containerElement.getBoundingClientRect();
3940
+ if (E > m && d && !n) {
3941
+ const R = E - m - f;
3942
+ R > e.height + o ? y = R : w > c && (y = c);
3943
+ } else this.data.length && n ? y = n : this.data.length && c && w > c && (y = c);
3944
+ y > 0 && (this.ctx.stageHeight = Math.floor(y), this.ctx.stageElement.style.height = `${this.ctx.stageHeight - 0.5}px`);
3945
+ let C = this.ctx.stageHeight - e.height - o;
3946
+ r ? this.visibleHeight = C - u : this.visibleHeight = C, this.data.length || (this.height = this.visibleHeight), this.ctx.body.x = this.x, this.ctx.body.y = this.y, this.ctx.body.width = this.width, this.ctx.body.height = this.height, this.ctx.body.visibleWidth = this.visibleWidth, this.ctx.body.visibleHeight = this.visibleHeight, this.ctx.body.data = g;
3947
+ const b = window.devicePixelRatio || 1, v = this.ctx.stageWidth * b, O = this.ctx.stageHeight * b;
3948
+ t.width = Math.floor(v), t.height = Math.floor(O);
3949
+ const S = this.data.length ? "not-empty" : "empty";
3931
3950
  this.ctx.emit("emptyChange", {
3932
- isEmpty: w,
3933
- type: w,
3951
+ isEmpty: S,
3952
+ type: S,
3934
3953
  headerHeight: e.height,
3935
3954
  bodyHeight: this.height,
3936
3955
  footerHeight: u,
3937
3956
  width: this.width,
3938
3957
  height: this.data.length ? 0 : h + u
3939
- });
3940
- let y = this.height + e.height + o;
3941
- y += u;
3942
- let E = y;
3943
- const m = window.innerHeight, { top: C } = this.containerRect || this.ctx.containerElement.getBoundingClientRect();
3944
- if (this.data.length && m > C && d && !n) {
3945
- const R = m - C - f;
3946
- R > e.height + o ? E = R : y > c && (E = c);
3947
- } else this.data.length && n ? E = n : this.data.length && c && y > c && (E = c);
3948
- E > 0 && (this.ctx.stageHeight = Math.floor(E), this.ctx.stageElement.style.height = `${this.ctx.stageHeight - 0.5}px`);
3949
- let b = this.ctx.stageHeight - e.height - o;
3950
- r ? this.visibleHeight = b - u : this.visibleHeight = b, this.ctx.body.x = this.x, this.ctx.body.y = this.y, this.ctx.body.width = this.width, this.ctx.body.height = this.height, this.ctx.body.visibleWidth = this.visibleWidth, this.ctx.body.visibleHeight = this.visibleHeight, this.ctx.body.data = g;
3951
- const v = window.devicePixelRatio || 1, O = this.ctx.stageWidth * v, S = this.ctx.stageHeight * v;
3952
- t.width = Math.floor(O), t.height = Math.floor(S), this.ctx.canvasElement.setAttribute(
3958
+ }), this.ctx.canvasElement.setAttribute(
3953
3959
  "style",
3954
3960
  ` height:${this.ctx.stageHeight}px;width:${this.ctx.stageWidth}px;`
3955
- ), this.ctx.paint.scale(v);
3961
+ ), this.ctx.paint.scale(b);
3956
3962
  }
3957
3963
  // 调整行的高度
3958
3964
  initResizeRow() {
@@ -5121,12 +5127,12 @@ const Li = (a) => ({
5121
5127
  }, g = Ht(s), p = Mt(g), u = await o.getDimensions(c), w = g === "y", y = w ? "top" : "left", E = w ? "bottom" : "right", m = w ? "clientHeight" : "clientWidth", C = r.reference[p] + r.reference[g] - x[g] - r.floating[p], b = x[g] - r.reference[g], v = await (o.getOffsetParent == null ? void 0 : o.getOffsetParent(c));
5122
5128
  let O = v ? v[m] : 0;
5123
5129
  (!O || !await (o.isElement == null ? void 0 : o.isElement(v))) && (O = n.floating[m] || r.floating[p]);
5124
- const S = C / 2 - b / 2, I = O / 2 - u[p] / 2 - 1, R = rt(f[y], I), A = rt(f[E], I), L = R, M = O - u[p] - A, T = O / 2 - u[p] / 2 + S, B = _t(L, T, M), Y = !h.arrow && lt(s) != null && T !== B && r.reference[p] / 2 - (T < L ? R : A) - u[p] / 2 < 0, k = Y ? T < L ? T - L : T - M : 0;
5130
+ const S = C / 2 - b / 2, I = O / 2 - u[p] / 2 - 1, R = rt(f[y], I), A = rt(f[E], I), L = R, M = O - u[p] - A, T = O / 2 - u[p] / 2 + S, F = _t(L, T, M), Y = !h.arrow && lt(s) != null && T !== F && r.reference[p] / 2 - (T < L ? R : A) - u[p] / 2 < 0, k = Y ? T < L ? T - L : T - M : 0;
5125
5131
  return {
5126
5132
  [g]: x[g] + k,
5127
5133
  data: {
5128
- [g]: B,
5129
- centerOffset: T - B - k,
5134
+ [g]: F,
5135
+ centerOffset: T - F - k,
5130
5136
  ...Y && {
5131
5137
  alignmentOffset: k
5132
5138
  }
@@ -5171,15 +5177,15 @@ const Li = (a) => ({
5171
5177
  overflows: I
5172
5178
  }], !I.every((T) => T <= 0)) {
5173
5179
  var A, L;
5174
- const T = (((A = r.flip) == null ? void 0 : A.index) || 0) + 1, B = O[T];
5175
- if (B)
5180
+ const T = (((A = r.flip) == null ? void 0 : A.index) || 0) + 1, F = O[T];
5181
+ if (F)
5176
5182
  return {
5177
5183
  data: {
5178
5184
  index: T,
5179
5185
  overflows: R
5180
5186
  },
5181
5187
  reset: {
5182
- placement: B
5188
+ placement: F
5183
5189
  }
5184
5190
  };
5185
5191
  let Y = (L = R.filter((k) => k.overflows[0] <= 0).sort((k, W) => k.overflows[1] - W.overflows[1])[0]) == null ? void 0 : L.placement;
@@ -5352,7 +5358,7 @@ function ht(a) {
5352
5358
  overflowX: e,
5353
5359
  overflowY: i,
5354
5360
  display: s
5355
- } = F(a);
5361
+ } = B(a);
5356
5362
  return /auto|scroll|overlay|hidden|clip/.test(t + i + e) && !["inline", "contents"].includes(s);
5357
5363
  }
5358
5364
  function Di(a) {
@@ -5368,7 +5374,7 @@ function wt(a) {
5368
5374
  });
5369
5375
  }
5370
5376
  function Dt(a) {
5371
- const t = Nt(), e = X(a) ? F(a) : a;
5377
+ const t = Nt(), e = X(a) ? B(a) : a;
5372
5378
  return e.transform !== "none" || e.perspective !== "none" || (e.containerType ? e.containerType !== "normal" : !1) || !t && (e.backdropFilter ? e.backdropFilter !== "none" : !1) || !t && (e.filter ? e.filter !== "none" : !1) || ["transform", "perspective", "filter"].some((i) => (e.willChange || "").includes(i)) || ["paint", "layout", "strict", "content"].some((i) => (e.contain || "").includes(i));
5373
5379
  }
5374
5380
  function Ni(a) {
@@ -5388,7 +5394,7 @@ function Nt() {
5388
5394
  function Q(a) {
5389
5395
  return ["html", "body", "#document"].includes(tt(a));
5390
5396
  }
5391
- function F(a) {
5397
+ function B(a) {
5392
5398
  return N(a).getComputedStyle(a);
5393
5399
  }
5394
5400
  function pt(a) {
@@ -5430,7 +5436,7 @@ function Lt(a) {
5430
5436
  return a.parent && Object.getPrototypeOf(a.parent) ? a.frameElement : null;
5431
5437
  }
5432
5438
  function fe(a) {
5433
- const t = F(a);
5439
+ const t = B(a);
5434
5440
  let e = parseFloat(t.width) || 0, i = parseFloat(t.height) || 0;
5435
5441
  const s = K(a), r = s ? a.offsetWidth : e, o = s ? a.offsetHeight : i, n = ft(e) !== r || ft(i) !== o;
5436
5442
  return n && (e = r, i = o), {
@@ -5465,7 +5471,7 @@ function ue(a) {
5465
5471
  y: t.visualViewport.offsetTop
5466
5472
  };
5467
5473
  }
5468
- function Fi(a, t, e) {
5474
+ function Bi(a, t, e) {
5469
5475
  return t === void 0 && (t = !1), !e || t && e !== N(a) ? !1 : t;
5470
5476
  }
5471
5477
  function ot(a, t, e, i) {
@@ -5473,13 +5479,13 @@ function ot(a, t, e, i) {
5473
5479
  const s = a.getBoundingClientRect(), r = xe(a);
5474
5480
  let o = z(1);
5475
5481
  t && (i ? X(i) && (o = Z(i)) : o = Z(a));
5476
- const n = Fi(r, e, i) ? ue(r) : z(0);
5482
+ const n = Bi(r, e, i) ? ue(r) : z(0);
5477
5483
  let h = (s.left + n.x) / o.x, c = (s.top + n.y) / o.y, d = s.width / o.x, f = s.height / o.y;
5478
5484
  if (r) {
5479
5485
  const x = N(r), g = i && X(i) ? N(i) : i;
5480
5486
  let p = x, u = Lt(p);
5481
5487
  for (; u && i && g !== p; ) {
5482
- const w = Z(u), y = u.getBoundingClientRect(), E = F(u), m = y.left + (u.clientLeft + parseFloat(E.paddingLeft)) * w.x, C = y.top + (u.clientTop + parseFloat(E.paddingTop)) * w.y;
5488
+ const w = Z(u), y = u.getBoundingClientRect(), E = B(u), m = y.left + (u.clientLeft + parseFloat(E.paddingLeft)) * w.x, C = y.top + (u.clientTop + parseFloat(E.paddingTop)) * w.y;
5483
5489
  h *= w.x, c *= w.y, d *= w.x, f *= w.y, h += m, c += C, p = N(u), u = Lt(p);
5484
5490
  }
5485
5491
  }
@@ -5490,7 +5496,7 @@ function ot(a, t, e, i) {
5490
5496
  y: c
5491
5497
  });
5492
5498
  }
5493
- function Bi(a) {
5499
+ function Fi(a) {
5494
5500
  let {
5495
5501
  elements: t,
5496
5502
  rect: e,
@@ -5527,7 +5533,7 @@ function Ki(a) {
5527
5533
  const t = V(a), e = pt(a), i = a.ownerDocument.body, s = U(t.scrollWidth, t.clientWidth, i.scrollWidth, i.clientWidth), r = U(t.scrollHeight, t.clientHeight, i.scrollHeight, i.clientHeight);
5528
5534
  let o = -e.scrollLeft + At(a);
5529
5535
  const n = -e.scrollTop;
5530
- return F(i).direction === "rtl" && (o += U(t.clientWidth, i.clientWidth) - s), {
5536
+ return B(i).direction === "rtl" && (o += U(t.clientWidth, i.clientWidth) - s), {
5531
5537
  width: s,
5532
5538
  height: r,
5533
5539
  x: o,
@@ -5578,17 +5584,17 @@ function Gt(a, t, e) {
5578
5584
  }
5579
5585
  function ge(a, t) {
5580
5586
  const e = $(a);
5581
- return e === t || !X(e) || Q(e) ? !1 : F(e).position === "fixed" || ge(e, t);
5587
+ return e === t || !X(e) || Q(e) ? !1 : B(e).position === "fixed" || ge(e, t);
5582
5588
  }
5583
5589
  function Wi(a, t) {
5584
5590
  const e = t.get(a);
5585
5591
  if (e)
5586
5592
  return e;
5587
5593
  let i = St(a, [], !1).filter((n) => X(n) && tt(n) !== "body"), s = null;
5588
- const r = F(a).position === "fixed";
5594
+ const r = B(a).position === "fixed";
5589
5595
  let o = r ? $(a) : a;
5590
5596
  for (; X(o) && !Q(o); ) {
5591
- const n = F(o), h = Dt(o);
5597
+ const n = B(o), h = Dt(o);
5592
5598
  !h && n.position === "fixed" && (s = null), (r ? !h && !s : !h && n.position === "static" && !!s && ["absolute", "fixed"].includes(s.position) || ht(o) && !h && ge(a, o)) ? i = i.filter((d) => d !== o) : s = n, o = $(o);
5593
5599
  }
5594
5600
  return t.set(a, i), i;
@@ -5648,10 +5654,10 @@ function $i(a, t, e) {
5648
5654
  };
5649
5655
  }
5650
5656
  function mt(a) {
5651
- return F(a).position === "static";
5657
+ return B(a).position === "static";
5652
5658
  }
5653
5659
  function jt(a, t) {
5654
- if (!K(a) || F(a).position === "fixed")
5660
+ if (!K(a) || B(a).position === "fixed")
5655
5661
  return null;
5656
5662
  if (t)
5657
5663
  return t(a);
@@ -5689,10 +5695,10 @@ const qi = async function(a) {
5689
5695
  };
5690
5696
  };
5691
5697
  function Gi(a) {
5692
- return F(a).direction === "rtl";
5698
+ return B(a).direction === "rtl";
5693
5699
  }
5694
5700
  const ji = {
5695
- convertOffsetParentRelativeRectToViewportRelativeRect: Bi,
5701
+ convertOffsetParentRelativeRectToViewportRelativeRect: Fi,
5696
5702
  getDocumentElement: V,
5697
5703
  getClippingRect: Pi,
5698
5704
  getOffsetParent: we,
@@ -6399,7 +6405,7 @@ class rs {
6399
6405
  this.ctx.off(t, e);
6400
6406
  }
6401
6407
  filterMethod(t) {
6402
- this.ctx.setScrollY(0), this.ctx.setScrollX(0), this.ctx.database.init(), this.header.init(), this.ctx.database.setFilterMethod(t), this.ctx.emit("draw");
6408
+ this.scrollTo(0, 0), this.ctx.database.setFilterMethod(t), this.ctx.database.init(), this.ctx.emit("draw");
6403
6409
  }
6404
6410
  editCell(t, e) {
6405
6411
  this.editor.editCell(t, e);