dpot-ui 0.1.11 → 0.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
@@ -55,16 +55,16 @@ const U = function() {
55
55
  };
56
56
  function o(t, i, a) {
57
57
  this._reference = t.jquery ? t[0] : t, this.state = {};
58
- var s = typeof i > "u" || i === null, p = i && Object.prototype.toString.call(i) === "[object Object]";
59
- return s || p ? this._popper = this.parse(p ? i : {}) : this._popper = i.jquery ? i[0] : i, this._options = Object.assign({}, r, a), this._options.modifiers = this._options.modifiers.map(
60
- function(d) {
61
- if (this._options.modifiersIgnored.indexOf(d) === -1)
62
- return d === "applyStyle" && this._popper.setAttribute(
58
+ var n = typeof i > "u" || i === null, d = i && Object.prototype.toString.call(i) === "[object Object]";
59
+ return n || d ? this._popper = this.parse(d ? i : {}) : this._popper = i.jquery ? i[0] : i, this._options = Object.assign({}, r, a), this._options.modifiers = this._options.modifiers.map(
60
+ function(p) {
61
+ if (this._options.modifiersIgnored.indexOf(p) === -1)
62
+ return p === "applyStyle" && this._popper.setAttribute(
63
63
  "x-placement",
64
64
  this._options.placement
65
- ), this.modifiers[d] || d;
65
+ ), this.modifiers[p] || p;
66
66
  }.bind(this)
67
- ), this.state.position = this._getPosition(this._popper, this._reference), $(this._popper, { position: this.state.position, top: 0 }), this.update(), this._setupEventListeners(), this;
67
+ ), this.state.position = this._getPosition(this._popper, this._reference), x(this._popper, { position: this.state.position, top: 0 }), this.update(), this._setupEventListeners(), this;
68
68
  }
69
69
  o.prototype.destroy = function() {
70
70
  return this._popper.removeAttribute("x-placement"), this._popper.style.left = "", this._popper.style.position = "", this._popper.style.top = "", this._popper.style[F("transform")] = "", this._removeEventListeners(), this._options.removeOnDestroy && this._popper.remove(), this;
@@ -96,24 +96,24 @@ const U = function() {
96
96
  arrowAttributes: ["x-arrow"]
97
97
  };
98
98
  t = Object.assign({}, i, t);
99
- var a = e.document, s = a.createElement(t.tagName);
100
- if (u(s, t.classNames), v(s, t.attributes), t.contentType === "node" ? s.appendChild(
99
+ var a = e.document, n = a.createElement(t.tagName);
100
+ if (u(n, t.classNames), v(n, t.attributes), t.contentType === "node" ? n.appendChild(
101
101
  t.content.jquery ? t.content[0] : t.content
102
- ) : t.contentType === "html" ? s.innerHTML = t.content : s.textContent = t.content, t.arrowTagName) {
103
- var p = a.createElement(t.arrowTagName);
104
- u(p, t.arrowClassNames), v(p, t.arrowAttributes), s.appendChild(p);
102
+ ) : t.contentType === "html" ? n.innerHTML = t.content : n.textContent = t.content, t.arrowTagName) {
103
+ var d = a.createElement(t.arrowTagName);
104
+ u(d, t.arrowClassNames), v(d, t.arrowAttributes), n.appendChild(d);
105
105
  }
106
- var d = t.parent.jquery ? t.parent[0] : t.parent;
107
- if (typeof d == "string") {
108
- if (d = a.querySelectorAll(t.parent), d.length > 1 && console.warn(
106
+ var p = t.parent.jquery ? t.parent[0] : t.parent;
107
+ if (typeof p == "string") {
108
+ if (p = a.querySelectorAll(t.parent), p.length > 1 && console.warn(
109
109
  "WARNING: the given `parent` query(" + t.parent + ") matched more than one element, the first one will be used"
110
- ), d.length === 0)
110
+ ), p.length === 0)
111
111
  throw "ERROR: the given `parent` doesn't exists!";
112
- d = d[0];
112
+ p = p[0];
113
113
  }
114
- return d.length > 1 && !(d instanceof Element) && (console.warn(
114
+ return p.length > 1 && !(p instanceof Element) && (console.warn(
115
115
  "WARNING: you have passed as parent a list of elements, the first one will be used"
116
- ), d = d[0]), d.appendChild(s), s;
116
+ ), p = p[0]), p.appendChild(n), n;
117
117
  function u(g, m) {
118
118
  m.forEach(function(w) {
119
119
  g.classList.add(w);
@@ -134,16 +134,16 @@ const U = function() {
134
134
  return a ? "fixed" : "absolute";
135
135
  }, o.prototype._getOffsets = function(t, i, a) {
136
136
  a = a.split("-")[0];
137
- var s = {};
138
- s.position = this.state.position;
139
- var p = s.position === "fixed", d = K(
137
+ var n = {};
138
+ n.position = this.state.position;
139
+ var d = n.position === "fixed", p = K(
140
140
  i,
141
141
  _(t),
142
- p
143
- ), u = n(t);
144
- return ["right", "left"].indexOf(a) !== -1 ? (s.top = d.top + d.height / 2 - u.height / 2, a === "left" ? s.left = d.left - u.width : s.left = d.right) : (s.left = d.left + d.width / 2 - u.width / 2, a === "top" ? s.top = d.top - u.height : s.top = d.bottom), s.width = u.width, s.height = u.height, {
145
- popper: s,
146
- reference: d
142
+ d
143
+ ), u = s(t);
144
+ return ["right", "left"].indexOf(a) !== -1 ? (n.top = p.top + p.height / 2 - u.height / 2, a === "left" ? n.left = p.left - u.width : n.left = p.right) : (n.left = p.left + p.width / 2 - u.width / 2, a === "top" ? n.top = p.top - u.height : n.top = p.bottom), n.width = u.width, n.height = u.height, {
145
+ popper: n,
146
+ reference: p
147
147
  };
148
148
  }, o.prototype._setupEventListeners = function() {
149
149
  if (this.state.updateBound = this.update.bind(this), e.addEventListener("resize", this.state.updateBound), this._options.boundariesElement !== "window") {
@@ -156,25 +156,25 @@ const U = function() {
156
156
  this.state.updateBound
157
157
  ), this.state.scrollTarget = null), this.state.updateBound = null;
158
158
  }, o.prototype._getBoundaries = function(t, i, a) {
159
- var s = {}, p, d;
159
+ var n = {}, d, p;
160
160
  if (a === "window") {
161
161
  var u = e.document.body, v = e.document.documentElement;
162
- d = Math.max(
162
+ p = Math.max(
163
163
  u.scrollHeight,
164
164
  u.offsetHeight,
165
165
  v.clientHeight,
166
166
  v.scrollHeight,
167
167
  v.offsetHeight
168
- ), p = Math.max(
168
+ ), d = Math.max(
169
169
  u.scrollWidth,
170
170
  u.offsetWidth,
171
171
  v.clientWidth,
172
172
  v.scrollWidth,
173
173
  v.offsetWidth
174
- ), s = {
174
+ ), n = {
175
175
  top: 0,
176
- right: p,
177
- bottom: d,
176
+ right: d,
177
+ bottom: p,
178
178
  left: 0
179
179
  };
180
180
  } else if (a === "viewport") {
@@ -183,103 +183,103 @@ const U = function() {
183
183
  document.documentElement.scrollTop,
184
184
  document.body.scrollTop
185
185
  ) : E.scrollTop;
186
- }, x = function(E) {
186
+ }, $ = function(E) {
187
187
  return E == document.body ? Math.max(
188
188
  document.documentElement.scrollLeft,
189
189
  document.body.scrollLeft
190
190
  ) : E.scrollLeft;
191
- }, j = t.offsets.popper.position === "fixed" ? 0 : S(m), I = t.offsets.popper.position === "fixed" ? 0 : x(m);
192
- s = {
193
- top: 0 - (w.top - j),
191
+ }, T = t.offsets.popper.position === "fixed" ? 0 : S(m), I = t.offsets.popper.position === "fixed" ? 0 : $(m);
192
+ n = {
193
+ top: 0 - (w.top - T),
194
194
  right: e.document.documentElement.clientWidth - (w.left - I),
195
- bottom: e.document.documentElement.clientHeight - (w.top - j),
195
+ bottom: e.document.documentElement.clientHeight - (w.top - T),
196
196
  left: 0 - (w.left - I)
197
197
  };
198
198
  } else
199
- _(this._popper) === a ? s = {
199
+ _(this._popper) === a ? n = {
200
200
  top: 0,
201
201
  left: 0,
202
202
  right: a.clientWidth,
203
203
  bottom: a.clientHeight
204
- } : s = M(a);
205
- return s.left += i, s.right -= i, s.top = s.top + i, s.bottom = s.bottom - i, s;
204
+ } : n = M(a);
205
+ return n.left += i, n.right -= i, n.top = n.top + i, n.bottom = n.bottom - i, n;
206
206
  }, o.prototype.runModifiers = function(t, i, a) {
207
- var s = i.slice();
208
- return a !== void 0 && (s = this._options.modifiers.slice(
207
+ var n = i.slice();
208
+ return a !== void 0 && (n = this._options.modifiers.slice(
209
209
  0,
210
- h(this._options.modifiers, a)
211
- )), s.forEach(
212
- function(p) {
213
- y(p) && (t = p.call(this, t));
210
+ c(this._options.modifiers, a)
211
+ )), n.forEach(
212
+ function(d) {
213
+ y(d) && (t = d.call(this, t));
214
214
  }.bind(this)
215
215
  ), t;
216
216
  }, o.prototype.isModifierRequired = function(t, i) {
217
- var a = h(this._options.modifiers, t);
218
- return !!this._options.modifiers.slice(0, a).filter(function(s) {
219
- return s === i;
217
+ var a = c(this._options.modifiers, t);
218
+ return !!this._options.modifiers.slice(0, a).filter(function(n) {
219
+ return n === i;
220
220
  }).length;
221
221
  }, o.prototype.modifiers = {}, o.prototype.modifiers.applyStyle = function(t) {
222
222
  var i = {
223
223
  position: t.offsets.popper.position
224
- }, a = Math.round(t.offsets.popper.left), s = Math.round(t.offsets.popper.top), p;
225
- return this._options.gpuAcceleration && (p = F("transform")) ? (i[p] = "translate3d(" + a + "px, " + s + "px, 0)", i.top = 0, i.left = 0) : (i.left = a, i.top = s), Object.assign(i, t.styles), $(this._popper, i), this._popper.setAttribute("x-placement", t.placement), this.isModifierRequired(
224
+ }, a = Math.round(t.offsets.popper.left), n = Math.round(t.offsets.popper.top), d;
225
+ return this._options.gpuAcceleration && (d = F("transform")) ? (i[d] = "translate3d(" + a + "px, " + n + "px, 0)", i.top = 0, i.left = 0) : (i.left = a, i.top = n), Object.assign(i, t.styles), x(this._popper, i), this._popper.setAttribute("x-placement", t.placement), this.isModifierRequired(
226
226
  this.modifiers.applyStyle,
227
227
  this.modifiers.arrow
228
- ) && t.offsets.arrow && $(t.arrowElement, t.offsets.arrow), t;
228
+ ) && t.offsets.arrow && x(t.arrowElement, t.offsets.arrow), t;
229
229
  }, o.prototype.modifiers.shift = function(t) {
230
- var i = t.placement, a = i.split("-")[0], s = i.split("-")[1];
231
- if (s) {
232
- var p = t.offsets.reference, d = f(t.offsets.popper), u = {
230
+ var i = t.placement, a = i.split("-")[0], n = i.split("-")[1];
231
+ if (n) {
232
+ var d = t.offsets.reference, p = f(t.offsets.popper), u = {
233
233
  y: {
234
- start: { top: p.top },
234
+ start: { top: d.top },
235
235
  end: {
236
- top: p.top + p.height - d.height
236
+ top: d.top + d.height - p.height
237
237
  }
238
238
  },
239
239
  x: {
240
- start: { left: p.left },
240
+ start: { left: d.left },
241
241
  end: {
242
- left: p.left + p.width - d.width
242
+ left: d.left + d.width - p.width
243
243
  }
244
244
  }
245
245
  }, v = ["bottom", "top"].indexOf(a) !== -1 ? "x" : "y";
246
246
  t.offsets.popper = Object.assign(
247
- d,
248
- u[v][s]
247
+ p,
248
+ u[v][n]
249
249
  );
250
250
  }
251
251
  return t;
252
252
  }, o.prototype.modifiers.preventOverflow = function(t) {
253
- var i = this._options.preventOverflowOrder, a = f(t.offsets.popper), s = {
253
+ var i = this._options.preventOverflowOrder, a = f(t.offsets.popper), n = {
254
254
  left: function() {
255
- var p = a.left;
256
- return a.left < t.boundaries.left && (p = Math.max(a.left, t.boundaries.left)), { left: p };
255
+ var d = a.left;
256
+ return a.left < t.boundaries.left && (d = Math.max(a.left, t.boundaries.left)), { left: d };
257
257
  },
258
258
  right: function() {
259
- var p = a.left;
260
- return a.right > t.boundaries.right && (p = Math.min(
259
+ var d = a.left;
260
+ return a.right > t.boundaries.right && (d = Math.min(
261
261
  a.left,
262
262
  t.boundaries.right - a.width
263
- )), { left: p };
263
+ )), { left: d };
264
264
  },
265
265
  top: function() {
266
- var p = a.top;
267
- return a.top < t.boundaries.top && (p = Math.max(a.top, t.boundaries.top)), { top: p };
266
+ var d = a.top;
267
+ return a.top < t.boundaries.top && (d = Math.max(a.top, t.boundaries.top)), { top: d };
268
268
  },
269
269
  bottom: function() {
270
- var p = a.top;
271
- return a.bottom > t.boundaries.bottom && (p = Math.min(
270
+ var d = a.top;
271
+ return a.bottom > t.boundaries.bottom && (d = Math.min(
272
272
  a.top,
273
273
  t.boundaries.bottom - a.height
274
- )), { top: p };
274
+ )), { top: d };
275
275
  }
276
276
  };
277
- return i.forEach(function(p) {
278
- t.offsets.popper = Object.assign(a, s[p]());
277
+ return i.forEach(function(d) {
278
+ t.offsets.popper = Object.assign(a, n[d]());
279
279
  }), t;
280
280
  }, o.prototype.modifiers.keepTogether = function(t) {
281
- var i = f(t.offsets.popper), a = t.offsets.reference, s = Math.floor;
282
- return i.right < s(a.left) && (t.offsets.popper.left = s(a.left) - i.width), i.left > s(a.right) && (t.offsets.popper.left = s(a.right)), i.bottom < s(a.top) && (t.offsets.popper.top = s(a.top) - i.height), i.top > s(a.bottom) && (t.offsets.popper.top = s(a.bottom)), t;
281
+ var i = f(t.offsets.popper), a = t.offsets.reference, n = Math.floor;
282
+ return i.right < n(a.left) && (t.offsets.popper.left = n(a.left) - i.width), i.left > n(a.right) && (t.offsets.popper.left = n(a.right)), i.bottom < n(a.top) && (t.offsets.popper.top = n(a.top) - i.height), i.top > n(a.bottom) && (t.offsets.popper.top = n(a.bottom)), t;
283
283
  }, o.prototype.modifiers.flip = function(t) {
284
284
  if (!this.isModifierRequired(
285
285
  this.modifiers.flip,
@@ -290,13 +290,13 @@ const U = function() {
290
290
  ), t;
291
291
  if (t.flipped && t.placement === t._originalPlacement)
292
292
  return t;
293
- var i = t.placement.split("-")[0], a = l(i), s = t.placement.split("-")[1] || "", p = [];
294
- return this._options.flipBehavior === "flip" ? p = [i, a] : p = this._options.flipBehavior, p.forEach(
295
- function(d, u) {
296
- if (!(i !== d || p.length === u + 1)) {
293
+ var i = t.placement.split("-")[0], a = l(i), n = t.placement.split("-")[1] || "", d = [];
294
+ return this._options.flipBehavior === "flip" ? d = [i, a] : d = this._options.flipBehavior, d.forEach(
295
+ function(p, u) {
296
+ if (!(i !== p || d.length === u + 1)) {
297
297
  i = t.placement.split("-")[0], a = l(i);
298
298
  var v = f(t.offsets.popper), g = ["right", "bottom"].indexOf(i) !== -1;
299
- (g && Math.floor(t.offsets.reference[i]) > Math.floor(v[a]) || !g && Math.floor(t.offsets.reference[i]) < Math.floor(v[a])) && (t.flipped = !0, t.placement = p[u + 1], s && (t.placement += "-" + s), t.offsets.popper = this._getOffsets(
299
+ (g && Math.floor(t.offsets.reference[i]) > Math.floor(v[a]) || !g && Math.floor(t.offsets.reference[i]) < Math.floor(v[a])) && (t.flipped = !0, t.placement = d[u + 1], n && (t.placement += "-" + n), t.offsets.popper = this._getOffsets(
300
300
  this._popper,
301
301
  this._reference,
302
302
  t.placement
@@ -326,20 +326,20 @@ const U = function() {
326
326
  return console.warn(
327
327
  "WARNING: keepTogether modifier is required by arrow modifier in order to work, be sure to include it before arrow!"
328
328
  ), t;
329
- var s = {}, p = t.placement.split("-")[0], d = f(t.offsets.popper), u = t.offsets.reference, v = ["left", "right"].indexOf(p) !== -1, g = v ? "height" : "width", m = v ? "top" : "left", w = v ? "left" : "top", S = v ? "bottom" : "right", x = n(i)[g];
330
- u[S] - x < d[m] && (t.offsets.popper[m] -= d[m] - (u[S] - x)), u[m] + x > d[S] && (t.offsets.popper[m] += u[m] + x - d[S]);
331
- var j = u[m] + (a || u[g] / 2 - x / 2), I = j - d[m];
329
+ var n = {}, d = t.placement.split("-")[0], p = f(t.offsets.popper), u = t.offsets.reference, v = ["left", "right"].indexOf(d) !== -1, g = v ? "height" : "width", m = v ? "top" : "left", w = v ? "left" : "top", S = v ? "bottom" : "right", $ = s(i)[g];
330
+ u[S] - $ < p[m] && (t.offsets.popper[m] -= p[m] - (u[S] - $)), u[m] + $ > p[S] && (t.offsets.popper[m] += u[m] + $ - p[S]);
331
+ var T = u[m] + (a || u[g] / 2 - $ / 2), I = T - p[m];
332
332
  return I = Math.max(
333
- Math.min(d[g] - x - 10, I),
333
+ Math.min(p[g] - $ - 10, I),
334
334
  8
335
- ), s[m] = I, s[w] = "", t.offsets.arrow = s, t.arrowElement = i, t;
335
+ ), n[m] = I, n[w] = "", t.offsets.arrow = n, t.arrowElement = i, t;
336
336
  };
337
- function n(t) {
337
+ function s(t) {
338
338
  var i = t.style.display, a = t.style.visibility;
339
339
  t.style.display = "block", t.style.visibility = "hidden", t.offsetWidth;
340
- var s = e.getComputedStyle(t), p = parseFloat(s.marginTop) + parseFloat(s.marginBottom), d = parseFloat(s.marginLeft) + parseFloat(s.marginRight), u = {
341
- width: t.offsetWidth + d,
342
- height: t.offsetHeight + p
340
+ var n = e.getComputedStyle(t), d = parseFloat(n.marginTop) + parseFloat(n.marginBottom), p = parseFloat(n.marginLeft) + parseFloat(n.marginRight), u = {
341
+ width: t.offsetWidth + p,
342
+ height: t.offsetHeight + d
343
343
  };
344
344
  return t.style.display = i, t.style.visibility = a, u;
345
345
  }
@@ -358,16 +358,16 @@ const U = function() {
358
358
  var i = Object.assign({}, t);
359
359
  return i.right = i.left + i.width, i.bottom = i.top + i.height, i;
360
360
  }
361
- function h(t, i) {
362
- var a = 0, s;
363
- for (s in t) {
364
- if (t[s] === i)
361
+ function c(t, i) {
362
+ var a = 0, n;
363
+ for (n in t) {
364
+ if (t[n] === i)
365
365
  return a;
366
366
  a++;
367
367
  }
368
368
  return null;
369
369
  }
370
- function c(t, i) {
370
+ function h(t, i) {
371
371
  var a = e.getComputedStyle(t, null);
372
372
  return a[i];
373
373
  }
@@ -378,25 +378,25 @@ const U = function() {
378
378
  function b(t) {
379
379
  var i = t.parentNode;
380
380
  return i ? i === e.document ? e.document.body.scrollTop || e.document.body.scrollLeft ? e.document.body : e.document.documentElement : ["scroll", "auto"].indexOf(
381
- c(i, "overflow")
381
+ h(i, "overflow")
382
382
  ) !== -1 || ["scroll", "auto"].indexOf(
383
- c(i, "overflow-x")
383
+ h(i, "overflow-x")
384
384
  ) !== -1 || ["scroll", "auto"].indexOf(
385
- c(i, "overflow-y")
385
+ h(i, "overflow-y")
386
386
  ) !== -1 ? i : b(t.parentNode) : t;
387
387
  }
388
388
  function k(t) {
389
- return t === e.document.body ? !1 : c(t, "position") === "fixed" ? !0 : t.parentNode ? k(t.parentNode) : t;
389
+ return t === e.document.body ? !1 : h(t, "position") === "fixed" ? !0 : t.parentNode ? k(t.parentNode) : t;
390
390
  }
391
- function $(t, i) {
392
- function a(s) {
393
- return s !== "" && !isNaN(parseFloat(s)) && isFinite(s);
391
+ function x(t, i) {
392
+ function a(n) {
393
+ return n !== "" && !isNaN(parseFloat(n)) && isFinite(n);
394
394
  }
395
- Object.keys(i).forEach(function(s) {
396
- var p = "";
395
+ Object.keys(i).forEach(function(n) {
396
+ var d = "";
397
397
  ["width", "height", "top", "right", "bottom", "left"].indexOf(
398
- s
399
- ) !== -1 && a(i[s]) && (p = "px"), t.style[s] = i[s] + p;
398
+ n
399
+ ) !== -1 && a(i[n]) && (d = "px"), t.style[n] = i[n] + d;
400
400
  });
401
401
  }
402
402
  function y(t) {
@@ -413,37 +413,37 @@ const U = function() {
413
413
  return i.right = i.left + i.width, i.bottom = i.top + i.height, i;
414
414
  }
415
415
  function O(t) {
416
- var i = t.getBoundingClientRect(), a = navigator.userAgent.indexOf("MSIE") != -1, s = a && t.tagName === "HTML" ? -t.scrollTop : i.top;
416
+ var i = t.getBoundingClientRect(), a = navigator.userAgent.indexOf("MSIE") != -1, n = a && t.tagName === "HTML" ? -t.scrollTop : i.top;
417
417
  return {
418
418
  left: i.left,
419
- top: s,
419
+ top: n,
420
420
  right: i.right,
421
421
  bottom: i.bottom,
422
422
  width: i.right - i.left,
423
- height: i.bottom - s
423
+ height: i.bottom - n
424
424
  };
425
425
  }
426
426
  function K(t, i, a) {
427
- var s = O(t), p = O(i);
427
+ var n = O(t), d = O(i);
428
428
  if (a) {
429
- var d = b(i);
430
- p.top += d.scrollTop, p.bottom += d.scrollTop, p.left += d.scrollLeft, p.right += d.scrollLeft;
429
+ var p = b(i);
430
+ d.top += p.scrollTop, d.bottom += p.scrollTop, d.left += p.scrollLeft, d.right += p.scrollLeft;
431
431
  }
432
432
  var u = {
433
- top: s.top - p.top,
434
- left: s.left - p.left,
435
- bottom: s.top - p.top + s.height,
436
- right: s.left - p.left + s.width,
437
- width: s.width,
438
- height: s.height
433
+ top: n.top - d.top,
434
+ left: n.left - d.left,
435
+ bottom: n.top - d.top + n.height,
436
+ right: n.left - d.left + n.width,
437
+ width: n.width,
438
+ height: n.height
439
439
  };
440
440
  return u;
441
441
  }
442
442
  function F(t) {
443
443
  for (var i = ["", "ms", "webkit", "moz", "o"], a = 0; a < i.length; a++) {
444
- var s = i[a] ? i[a] + t.charAt(0).toUpperCase() + t.slice(1) : t;
445
- if (typeof e.document.body.style[s] < "u")
446
- return s;
444
+ var n = i[a] ? i[a] + t.charAt(0).toUpperCase() + t.slice(1) : t;
445
+ if (typeof e.document.body.style[n] < "u")
446
+ return n;
447
447
  }
448
448
  return null;
449
449
  }
@@ -457,15 +457,15 @@ const U = function() {
457
457
  "Cannot convert first argument to object"
458
458
  );
459
459
  for (var i = Object(t), a = 1; a < arguments.length; a++) {
460
- var s = arguments[a];
461
- if (s != null) {
462
- s = Object(s);
463
- for (var p = Object.keys(s), d = 0, u = p.length; d < u; d++) {
464
- var v = p[d], g = Object.getOwnPropertyDescriptor(
465
- s,
460
+ var n = arguments[a];
461
+ if (n != null) {
462
+ n = Object(n);
463
+ for (var d = Object.keys(n), p = 0, u = d.length; p < u; p++) {
464
+ var v = d[p], g = Object.getOwnPropertyDescriptor(
465
+ n,
466
466
  v
467
467
  );
468
- g !== void 0 && g.enumerable && (i[v] = s[v]);
468
+ g !== void 0 && g.enumerable && (i[v] = n[v]);
469
469
  }
470
470
  }
471
471
  }
@@ -530,7 +530,7 @@ const U = function() {
530
530
  return;
531
531
  const e = this.popperOptions, r = this.popperElm = this.popperElm || this.popper || this.$refs.popover;
532
532
  let o = this.referenceElm = this.referenceElm || this.reference || this.$refs.reference;
533
- !o && this.$slots.reference && this.$slots.reference[0] && (o = this.referenceElm = this.$slots.reference[0].elm), !(!r || !o) && (this.visibleArrow && this.appendArrow(r), this.appendToBody && document.body.appendChild(this.popperElm), this.popperJS && this.popperJS.destroy && this.popperJS.destroy(), e.placement = this.currentPlacement, e.offset = this.offset, e.arrowOffset = this.arrowOffset, this.popperJS = new U(o, r, e), this.popperJS.onCreate((n) => {
533
+ !o && this.$slots.reference && this.$slots.reference[0] && (o = this.referenceElm = this.$slots.reference[0].elm), !(!r || !o) && (this.visibleArrow && this.appendArrow(r), this.appendToBody && document.body.appendChild(this.popperElm), this.popperJS && this.popperJS.destroy && this.popperJS.destroy(), e.placement = this.currentPlacement, e.offset = this.offset, e.arrowOffset = this.arrowOffset, this.popperJS = new U(o, r, e), this.popperJS.onCreate((s) => {
534
534
  this.$emit("created", this), this.$nextTick(this.updatePopper);
535
535
  }), typeof e.onUpdate == "function" && this.popperJS.onUpdate(e.onUpdate), this.popperJS._popper.style.zIndex = 1e3, this.popperElm.addEventListener("click", L));
536
536
  },
@@ -546,9 +546,9 @@ const U = function() {
546
546
  if (this.appended)
547
547
  return;
548
548
  this.appended = !0;
549
- for (let n in e.attributes)
550
- if (/^_v-/.test(e.attributes[n].name)) {
551
- r = e.attributes[n].name;
549
+ for (let s in e.attributes)
550
+ if (/^_v-/.test(e.attributes[s].name)) {
551
+ r = e.attributes[s].name;
552
552
  break;
553
553
  }
554
554
  const o = document.createElement("div");
@@ -586,15 +586,15 @@ var Z = function() {
586
586
  }
587
587
  }, [e._t("reference")], 2)]);
588
588
  }, X = [];
589
- function C(e, r, o, n, l, f, h, c) {
589
+ function C(e, r, o, s, l, f, c, h) {
590
590
  var _ = typeof e == "function" ? e.options : e;
591
- r && (_.render = r, _.staticRenderFns = o, _._compiled = !0), n && (_.functional = !0), f && (_._scopeId = "data-v-" + f);
591
+ r && (_.render = r, _.staticRenderFns = o, _._compiled = !0), s && (_.functional = !0), f && (_._scopeId = "data-v-" + f);
592
592
  var b;
593
- if (h ? (b = function(y) {
593
+ if (c ? (b = function(y) {
594
594
  y = y || // cached call
595
595
  this.$vnode && this.$vnode.ssrContext || // stateful
596
- this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext, !y && typeof __VUE_SSR_CONTEXT__ < "u" && (y = __VUE_SSR_CONTEXT__), l && l.call(this, y), y && y._registeredComponents && y._registeredComponents.add(h);
597
- }, _._ssrRegister = b) : l && (b = c ? function() {
596
+ this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext, !y && typeof __VUE_SSR_CONTEXT__ < "u" && (y = __VUE_SSR_CONTEXT__), l && l.call(this, y), y && y._registeredComponents && y._registeredComponents.add(c);
597
+ }, _._ssrRegister = b) : l && (b = h ? function() {
598
598
  l.call(
599
599
  this,
600
600
  (_.functional ? this.parent : this).$root.$options.shadowRoot
@@ -607,8 +607,8 @@ function C(e, r, o, n, l, f, h, c) {
607
607
  return b.call(O), k(M, O);
608
608
  };
609
609
  } else {
610
- var $ = _.beforeCreate;
611
- _.beforeCreate = $ ? [].concat($, b) : [b];
610
+ var x = _.beforeCreate;
611
+ _.beforeCreate = x ? [].concat(x, b) : [b];
612
612
  }
613
613
  return {
614
614
  exports: e,
@@ -705,8 +705,8 @@ var oe = function() {
705
705
  disabled: e.disabled
706
706
  },
707
707
  on: {
708
- click: function(n) {
709
- return n.stopPropagation(), e.handleChange.apply(null, arguments);
708
+ click: function(s) {
709
+ return s.stopPropagation(), e.handleChange.apply(null, arguments);
710
710
  }
711
711
  }
712
712
  }, [o("span", {
@@ -737,22 +737,22 @@ const ie = {
737
737
  }
738
738
  }
739
739
  }, P = {};
740
- var ne = /* @__PURE__ */ C(
740
+ var se = /* @__PURE__ */ C(
741
741
  ie,
742
742
  oe,
743
743
  re,
744
744
  !1,
745
- se,
745
+ ne,
746
746
  "1bea0315",
747
747
  null,
748
748
  null
749
749
  );
750
- function se(e) {
750
+ function ne(e) {
751
751
  for (let r in P)
752
752
  this[r] = P[r];
753
753
  }
754
754
  const ae = /* @__PURE__ */ function() {
755
- return ne.exports;
755
+ return se.exports;
756
756
  }();
757
757
  var le = function() {
758
758
  var e = this, r = e.$createElement, o = e._self._c || r;
@@ -762,8 +762,8 @@ var le = function() {
762
762
  disabled: e.disabled
763
763
  },
764
764
  on: {
765
- click: function(n) {
766
- return n.stopPropagation(), e.handleChange.apply(null, arguments);
765
+ click: function(s) {
766
+ return s.stopPropagation(), e.handleChange.apply(null, arguments);
767
767
  }
768
768
  }
769
769
  }, [o("span", {
@@ -771,8 +771,8 @@ var le = function() {
771
771
  }), o("span", {
772
772
  staticClass: "dp-radio_name_"
773
773
  }, [e._v(e._s(e.data.name))])]);
774
- }, pe = [];
775
- const de = {
774
+ }, de = [];
775
+ const pe = {
776
776
  name: "dp-radio",
777
777
  props: {
778
778
  data: {
@@ -793,22 +793,22 @@ const de = {
793
793
  }
794
794
  }
795
795
  }, R = {};
796
- var ce = /* @__PURE__ */ C(
797
- de,
798
- le,
796
+ var he = /* @__PURE__ */ C(
799
797
  pe,
798
+ le,
799
+ de,
800
800
  !1,
801
- he,
801
+ ce,
802
802
  "1d357f3a",
803
803
  null,
804
804
  null
805
805
  );
806
- function he(e) {
806
+ function ce(e) {
807
807
  for (let r in R)
808
808
  this[r] = R[r];
809
809
  }
810
810
  const fe = /* @__PURE__ */ function() {
811
- return ce.exports;
811
+ return he.exports;
812
812
  }();
813
813
  var ue = function() {
814
814
  var e = this, r = e.$createElement, o = e._self._c || r;
@@ -827,11 +827,11 @@ var ue = function() {
827
827
  class: [e.value.length && "dp-checkfilter_title_checked_"]
828
828
  }, [e._v(e._s(e.title))]), o("span", {
829
829
  staticClass: "dp-checkfilter_arrow_"
830
- })]), o("div", [e.type === "check" ? e._l(e.option, function(n) {
830
+ })]), o("div", [e.type === "check" ? e._l(e.option, function(s) {
831
831
  return o("dp-check", {
832
- key: n.code,
832
+ key: s.code,
833
833
  attrs: {
834
- data: Object.assign({}, n, {
834
+ data: Object.assign({}, s, {
835
835
  key: e.code
836
836
  }),
837
837
  value: e.value
@@ -840,11 +840,11 @@ var ue = function() {
840
840
  change: e.handleChange
841
841
  }
842
842
  });
843
- }) : e.type === "radio" ? e._l(e.option, function(n) {
843
+ }) : e.type === "radio" ? e._l(e.option, function(s) {
844
844
  return o("dp-radio", {
845
- key: n.code,
845
+ key: s.code,
846
846
  attrs: {
847
- data: Object.assign({}, n, {
847
+ data: Object.assign({}, s, {
848
848
  key: e.code
849
849
  }),
850
850
  value: e.value[0]
@@ -918,8 +918,8 @@ var ye = function() {
918
918
  justifyContent: e.align
919
919
  }, e.item.style, e.item.privateStyle),
920
920
  on: {
921
- click: function(n) {
922
- return n.stopPropagation(), e.handleItemClick(e.item, e.fullCode);
921
+ click: function(s) {
922
+ return s.stopPropagation(), e.handleItemClick(e.item, e.fullCode);
923
923
  }
924
924
  }
925
925
  }, [e._t(e.item.slot || e.item.code, function() {
@@ -927,20 +927,23 @@ var ye = function() {
927
927
  staticClass: "dp-table_header_item_border_ dp-table_header_item_group_title_ dp-table_header_item_height_",
928
928
  style: {
929
929
  borderColor: e.borderColor,
930
- justifyContent: e.align
930
+ textAlign: e.align
931
+ },
932
+ attrs: {
933
+ title: e.item.name
931
934
  }
932
935
  }, [e._v(e._s(e.item.name))]), e.item.children ? o("ul", {
933
936
  staticClass: "dp-table_header_item_child_",
934
937
  style: {
935
938
  borderColor: e.borderColor
936
939
  }
937
- }, e._l(e.item.children, function(n) {
940
+ }, e._l(e.item.children, function(s) {
938
941
  return o("dp-table-header-item", {
939
- key: n.code,
942
+ key: s.code,
940
943
  attrs: {
941
944
  align: e.align,
942
- fullCode: [].concat(e.fullCode, [n.code]),
943
- item: n,
945
+ fullCode: [].concat(e.fullCode, [s.code]),
946
+ item: s,
944
947
  borderColor: e.borderColor,
945
948
  sortInfo: e.sortInfo,
946
949
  filterInfo: e.filterInfo
@@ -975,7 +978,11 @@ var ye = function() {
975
978
  on: {
976
979
  change: e.handleChangeFilter
977
980
  }
978
- })] : [e._v(" " + e._s(e.item.name) + " "), e.item.sortKey ? o("span", {
981
+ })] : [o("span", {
982
+ attrs: {
983
+ title: e.item.name
984
+ }
985
+ }, [e._v(e._s(e.item.name))]), e.item.sortKey ? o("span", {
979
986
  class: ["dp-table_header_item_sort_", e.sortInfo.target.join("_") === e.fullCode.join("_") && e.sortInfo.value === "up" && "dp-table_header_item_sort_up_", e.sortInfo.target.join("_") === e.fullCode.join("_") && e.sortInfo.value === "down" && "dp-table_header_item_sort_down_"]
980
987
  }) : e._e()]];
981
988
  })], 2);
@@ -1005,6 +1012,17 @@ const Ce = {
1005
1012
  type: Array
1006
1013
  }
1007
1014
  },
1015
+ watch: {
1016
+ item: {
1017
+ handler() {
1018
+ this.item && this.item.children && this.$nextTick(() => {
1019
+ const e = this.$el.children[1].offsetWidth;
1020
+ this.$el.style.maxWidth = `${e}px`;
1021
+ });
1022
+ },
1023
+ immediate: !0
1024
+ }
1025
+ },
1008
1026
  data() {
1009
1027
  return {
1010
1028
  resizer: null,
@@ -1031,32 +1049,32 @@ const Ce = {
1031
1049
  beforeUnMounted() {
1032
1050
  this.resizer && this.resizer.unobserve(this.$el);
1033
1051
  }
1034
- }, A = {};
1035
- var xe = /* @__PURE__ */ C(
1052
+ }, B = {};
1053
+ var $e = /* @__PURE__ */ C(
1036
1054
  Ce,
1037
1055
  ye,
1038
1056
  we,
1039
1057
  !1,
1040
- $e,
1041
- "5cf7a766",
1058
+ xe,
1059
+ "60018e50",
1042
1060
  null,
1043
1061
  null
1044
1062
  );
1045
- function $e(e) {
1046
- for (let r in A)
1047
- this[r] = A[r];
1063
+ function xe(e) {
1064
+ for (let r in B)
1065
+ this[r] = B[r];
1048
1066
  }
1049
1067
  const Se = /* @__PURE__ */ function() {
1050
- return xe.exports;
1068
+ return $e.exports;
1051
1069
  }(), D = (e, r, o) => {
1052
- const n = e[o];
1053
- if (!n.isFixed || !r[n.code])
1070
+ const s = e[o];
1071
+ if (!s.isFixed || !r[s.code])
1054
1072
  return {};
1055
- const l = (h) => typeof h == "number" ? [h] : Object.values(h).map((c) => l(c)).flat();
1056
- return { position: "sticky", left: `${e.filter((h, c) => c < o && h.isFixed).map((h) => l(r[h.code])).reduce((h, c) => parseFloat(h) + parseFloat(c), 0)}px` };
1057
- }, T = (e, r, o) => {
1058
- const n = e[r[0]];
1059
- return r.length > 1 ? T(n, r.slice(1)) : e[o] || n;
1073
+ const l = (c) => typeof c == "number" ? [c] : Object.values(c).map((h) => l(h)).flat();
1074
+ return { position: "sticky", left: `${e.filter((c, h) => h < o && c.isFixed).map((c) => l(r[c.code])).reduce((c, h) => parseFloat(c) + parseFloat(h), 0)}px` };
1075
+ }, j = (e, r, o) => {
1076
+ const s = e[r[0]];
1077
+ return r.length > 1 ? j(s, r.slice(1), o) : e[o] === void 0 ? s : e[o];
1060
1078
  };
1061
1079
  var Ie = function() {
1062
1080
  var e = this, r = e.$createElement, o = e._self._c || r;
@@ -1064,17 +1082,18 @@ var Ie = function() {
1064
1082
  staticClass: "dp-table_header_view_",
1065
1083
  style: {
1066
1084
  borderColor: e.borderColor,
1067
- backgroundColor: e.bgColor
1085
+ backgroundColor: e.bgColor,
1086
+ minWidth: e.isBlock ? "100%" : ""
1068
1087
  }
1069
- }, e._l(e.data, function(n, l) {
1088
+ }, e._l(e.data, function(s, l) {
1070
1089
  return o("dp-item", {
1071
- key: n.code,
1072
- class: [n.isFixed && "dp-table_fixed_bg_", e.isLeftScroll && "dp-table_fixed_shadow_"],
1090
+ key: s.code,
1091
+ class: [s.isFixed && "dp-table_fixed_bg_", e.isLeftScroll && "dp-table_fixed_shadow_"],
1073
1092
  style: Object.assign({}, e.fixedStyle[l]),
1074
1093
  attrs: {
1075
- item: n,
1094
+ item: s,
1076
1095
  align: e.align,
1077
- fullCode: [n.code],
1096
+ fullCode: [s.code],
1078
1097
  borderColor: e.borderColor,
1079
1098
  sortInfo: e.sortInfo,
1080
1099
  filterInfo: e.filterInfo
@@ -1084,11 +1103,11 @@ var Ie = function() {
1084
1103
  changeSort: e.handleChangeSort,
1085
1104
  changeFilter: e.handleChangeFilter
1086
1105
  },
1087
- scopedSlots: e._u([e._l(e.$slots, function(f, h) {
1106
+ scopedSlots: e._u([e._l(e.$slots, function(f, c) {
1088
1107
  return {
1089
- key: h,
1108
+ key: c,
1090
1109
  fn: function() {
1091
- return [e._t(h)];
1110
+ return [e._t(c)];
1092
1111
  },
1093
1112
  proxy: !0
1094
1113
  };
@@ -1136,21 +1155,27 @@ const Ee = {
1136
1155
  return this.data.map((e, r) => ({ ...D(this.data, this.widthInfo, r), backgroundColor: this.bgColor }));
1137
1156
  }
1138
1157
  },
1158
+ watch: {
1159
+ data() {
1160
+ this.widthInfo = {};
1161
+ }
1162
+ },
1139
1163
  data() {
1140
1164
  return {
1141
1165
  widthInfo: {},
1142
- timer: null
1166
+ timer: null,
1167
+ isBlock: !0
1143
1168
  };
1144
1169
  },
1145
1170
  methods: {
1146
1171
  computFixedStyle: D,
1147
1172
  handleChangeWidthInfo(e) {
1148
1173
  this.widthInfo = { ...this.widthInfo, ...e }, clearTimeout(this.timer), this.timer = setTimeout(() => {
1149
- this.$emit("changeWidth", this.widthInfo);
1174
+ this.$emit("changeWidth", this.widthInfo), this.isBlock = Object.values(this.widthInfo).reduce((r, o) => r + o, 0) > this.$el.offsetWidth - 2, this.$emit("changeBlock", this.isBlock);
1150
1175
  }, 300);
1151
1176
  },
1152
1177
  handleChangeSort(e, r) {
1153
- console.log(e, r), this.$emit("changeSort", e, r);
1178
+ this.$emit("changeSort", e, r);
1154
1179
  },
1155
1180
  handleChangeFilter(e) {
1156
1181
  this.$emit("changeFilter", e);
@@ -1163,7 +1188,7 @@ var ke = /* @__PURE__ */ C(
1163
1188
  Oe,
1164
1189
  !1,
1165
1190
  Me,
1166
- "2293b374",
1191
+ "5d3820ae",
1167
1192
  null,
1168
1193
  null
1169
1194
  );
@@ -1171,17 +1196,18 @@ function Me(e) {
1171
1196
  for (let r in W)
1172
1197
  this[r] = W[r];
1173
1198
  }
1174
- const je = /* @__PURE__ */ function() {
1199
+ const Te = /* @__PURE__ */ function() {
1175
1200
  return ke.exports;
1176
1201
  }();
1177
- var Te = function() {
1202
+ var je = function() {
1178
1203
  var e = this, r = e.$createElement, o = e._self._c || r;
1179
1204
  return o("div", {
1180
1205
  staticClass: "dp-table_view_box_"
1181
1206
  }, [o("div", {
1182
1207
  staticClass: "dp-table_view_border_",
1183
1208
  style: {
1184
- borderColor: e.borderColor
1209
+ borderColor: e.borderColor,
1210
+ minWidth: e.isBlock ? "100%" : ""
1185
1211
  }
1186
1212
  }, [o("div", {
1187
1213
  ref: "table",
@@ -1202,10 +1228,11 @@ var Te = function() {
1202
1228
  },
1203
1229
  on: {
1204
1230
  changeWidth: e.handleSetWidthInfo,
1231
+ changeBlock: e.handleSetBlock,
1205
1232
  changeSort: e.handleChangeSort,
1206
1233
  changeFilter: e.handleChangeFilter
1207
1234
  },
1208
- scopedSlots: e._u([e._l(e.$slots, function(n, l) {
1235
+ scopedSlots: e._u([e._l(e.$slots, function(s, l) {
1209
1236
  return {
1210
1237
  key: l,
1211
1238
  fn: function() {
@@ -1220,12 +1247,12 @@ var Te = function() {
1220
1247
  height: `${e.fullHeight}px`,
1221
1248
  paddingTop: e.beforeHeight + "px"
1222
1249
  }
1223
- }, e._l(e.resultData, function(n) {
1250
+ }, e._l(e.resultData, function(s) {
1224
1251
  return o("li", {
1225
- key: n.__key,
1226
- class: ["dp-table_body_item_", n.__isTotalData && "dp-table_total_view_"],
1227
- style: Object.assign({}, n.style, e.hoverStyle, e.computEvenColor(n.__sub), {
1228
- height: `${e.fullHeightInfo[n.__key]}px`
1252
+ key: s.__key,
1253
+ class: ["dp-table_body_item_", s.__isTotalData && "dp-table_total_view_"],
1254
+ style: Object.assign({}, s.style, e.hoverStyle, e.computEvenColor(s.__sub), {
1255
+ height: `${e.fullHeightInfo[s.__key]}px`
1229
1256
  }),
1230
1257
  on: {
1231
1258
  mouseenter: function(l) {
@@ -1236,72 +1263,78 @@ var Te = function() {
1236
1263
  }
1237
1264
  }
1238
1265
  }, [e._l(e.deepHeadData, function(l, f) {
1239
- return [n[l.code] instanceof Object ? [n[l.code].slot ? o("div", {
1266
+ return [s[l.code] instanceof Object ? [s[l.code].slot ? o("div", {
1240
1267
  class: ["dp-table_body_item_group_col_", l.isFixed && "dp-table_fixed_bg_", !!e.scrollLeft && "dp-table_fixed_shadow_"],
1241
1268
  style: Object.assign({
1242
1269
  borderColor: e.borderColor
1243
- }, l.style, l.colStyle, e.computEvenColor(n.__sub), e.fixedStyle[f], e.computWidth(n[l.code]))
1244
- }, e._l([n[l.code].slot].flat(), function(h, c) {
1270
+ }, l.style, l.colStyle, e.computEvenColor(s.__sub), e.fixedStyle[f], e.computWidth(s[l.code]))
1271
+ }, e._l([s[l.code].slot].flat(), function(c, h) {
1245
1272
  return o("div", {
1246
- key: h,
1273
+ key: c,
1247
1274
  staticClass: "dp-table_body_item_child_",
1248
1275
  style: Object.assign({
1249
1276
  borderColor: e.borderColor,
1250
1277
  padding: e.itemPadding,
1251
1278
  justifyContent: e.dir
1252
- }, l.style, l.colStyle, n[l.code].style, {
1279
+ }, l.style, l.colStyle, s[l.code].style, {
1253
1280
  width: "100%"
1254
1281
  })
1255
- }, [e._t(h, null, {
1256
- item: n,
1257
- index: c
1282
+ }, [e._t(c, null, {
1283
+ item: s,
1284
+ index: h
1258
1285
  })], 2);
1259
- }), 0) : n[l.code].raw ? o("div", {
1286
+ }), 0) : s[l.code].raw ? o("div", {
1260
1287
  class: ["dp-table_body_item_group_col_", l.isFixed && "dp-table_fixed_bg_", !!e.scrollLeft && "dp-table_fixed_shadow_"],
1261
1288
  style: Object.assign({
1262
1289
  borderColor: e.borderColor
1263
- }, l.style, l.colStyle, e.computEvenColor(n.__sub), e.fixedStyle[f], e.computWidth(n[l.code]))
1264
- }, e._l([n[l.code].raw].flat(), function(h, c) {
1290
+ }, l.style, l.colStyle, e.computEvenColor(s.__sub), e.fixedStyle[f], e.computWidth(s[l.code]))
1291
+ }, e._l([s[l.code].raw].flat(), function(c, h) {
1265
1292
  return o("div", {
1266
- key: c,
1293
+ key: h,
1267
1294
  staticClass: "dp-table_body_item_child_",
1268
1295
  style: Object.assign({
1269
1296
  borderColor: e.borderColor,
1270
1297
  padding: e.itemPadding,
1271
1298
  justifyContent: e.dir
1272
- }, l.style, l.colStyle, n[l.code].style, {
1299
+ }, l.style, l.colStyle, s[l.code].style, {
1273
1300
  width: "100%"
1274
1301
  }),
1275
1302
  domProps: {
1276
- innerHTML: e._s(h)
1303
+ innerHTML: e._s(c)
1277
1304
  }
1278
1305
  });
1279
- }), 0) : n[l.code].value ? o("div", {
1306
+ }), 0) : s[l.code].value ? o("div", {
1280
1307
  class: ["dp-table_body_item_group_col_", l.isFixed && "dp-table_fixed_bg_", !!e.scrollLeft && "dp-table_fixed_shadow_"],
1281
1308
  style: Object.assign({
1282
1309
  borderColor: e.borderColor
1283
- }, l.style, l.colStyle, e.computEvenColor(n.__sub), e.fixedStyle[f], e.computWidth(n[l.code]))
1284
- }, e._l([n[l.code].value].flat(), function(h, c) {
1310
+ }, l.style, l.colStyle, e.computEvenColor(s.__sub), e.fixedStyle[f], e.computWidth(s[l.code]))
1311
+ }, e._l([s[l.code].value].flat(), function(c, h) {
1285
1312
  return o("div", {
1286
- key: c,
1313
+ key: h,
1287
1314
  staticClass: "dp-table_body_item_child_",
1288
1315
  style: Object.assign({
1289
1316
  borderColor: e.borderColor,
1290
1317
  padding: e.itemPadding,
1291
1318
  justifyContent: e.dir
1292
- }, l.style, l.colStyle, n[l.code].style, {
1319
+ }, l.style, l.colStyle, s[l.code].style, {
1293
1320
  width: "100%"
1294
- })
1295
- }, [e._v(e._s(h))]);
1321
+ }),
1322
+ attrs: {
1323
+ title: l.isShowTitle ? c : ""
1324
+ }
1325
+ }, [e._v(e._s(c))]);
1296
1326
  }), 0) : e._e()] : o("div", {
1297
1327
  class: ["dp-table_body_item_child_", l.isFixed && "dp-table_fixed_bg_", !!e.scrollLeft && "dp-table_fixed_shadow_"],
1298
1328
  style: Object.assign({
1299
1329
  borderColor: e.borderColor,
1300
1330
  padding: e.itemPadding,
1301
1331
  justifyContent: e.dir
1302
- }, l.style, l.colStyle, e.computEvenColor(n.__sub), e.fixedStyle[f])
1303
- }, [e._v(e._s(n[l.code]))])];
1304
- }), n.__isTotalData ? o("span", {
1332
+ }, l.style, l.colStyle, e.computEvenColor(s.__sub), e.fixedStyle[f]),
1333
+ attrs: {
1334
+ title: l.isShowTitle ? s[l.code] : ""
1335
+ }
1336
+ }, [e._v(e._s(s[l.code]))])];
1337
+ }), s.__isTotalData ? o("span", {
1305
1338
  staticClass: "dp-table_total_border_",
1306
1339
  style: {
1307
1340
  borderColor: e.borderColor
@@ -1322,7 +1355,7 @@ var Te = function() {
1322
1355
  const Fe = {
1323
1356
  name: "dp-table",
1324
1357
  components: {
1325
- DpHeader: je
1358
+ DpHeader: Te
1326
1359
  },
1327
1360
  props: {
1328
1361
  // 边框颜色
@@ -1405,7 +1438,7 @@ const Fe = {
1405
1438
  // 平铺表头
1406
1439
  deepHeadData() {
1407
1440
  const e = [], r = (o) => {
1408
- o.children ? o.children.forEach((n) => r({ ...n, code: `${o.code}_${n.code}` })) : e.push(o);
1441
+ o.children ? o.children.forEach((s) => r({ ...s, code: `${o.code}_${s.code}` })) : e.push(o);
1409
1442
  };
1410
1443
  return this.resultHeadData.forEach((o) => r(o)), e;
1411
1444
  },
@@ -1414,8 +1447,8 @@ const Fe = {
1414
1447
  const e = Object.values(this.filterInfo).filter((r) => r.value.length);
1415
1448
  return e.length ? [...this.bodyData].filter((r) => {
1416
1449
  let o = !0;
1417
- return e.some((n) => {
1418
- if (!n.value.includes(T(r, n.target, n.filterKey)))
1450
+ return e.some((s) => {
1451
+ if (!s.value.includes(j(r, s.target, s.filterKey)))
1419
1452
  return o = !1, !0;
1420
1453
  }), o;
1421
1454
  }) : this.bodyData;
@@ -1427,22 +1460,22 @@ const Fe = {
1427
1460
  // 表体渲染数据
1428
1461
  resultData() {
1429
1462
  return Object.keys(this.widthInfo).length < this.headData.length || !this.headData.length ? [] : (this.sortInfo.value ? [...this.filterBodyData].sort((r, o) => {
1430
- const n = T(r, this.sortInfo.target, this.sortInfo.sortKey), l = T(o, this.sortInfo.target, this.sortInfo.sortKey);
1431
- return this.sortInfo.value === "up" ? n - l : l - n;
1463
+ const s = j(r, this.sortInfo.target, this.sortInfo.sortKey), l = j(o, this.sortInfo.target, this.sortInfo.sortKey);
1464
+ return this.sortInfo.value === "up" ? s - l : l - s;
1432
1465
  }) : this.filterBodyData).slice(this.beforeIndex, this.currentIndex).concat(this.totalData ? [{ ...this.totalData, __sub: "", __isTotalData: !0 }] : []).map((r, o) => {
1433
- const n = this.handleComputItem(r);
1434
- return Object.keys(n).forEach((l) => {
1435
- if (n[l] instanceof Object && (n[l].merge || 0) > 1) {
1436
- const f = this.deepHeadData.findIndex((c) => c.code === l), h = this.deepHeadData.slice(f, f + n[l].merge);
1437
- h.forEach((c) => {
1438
- const _ = n[c.code];
1439
- _ instanceof Object || (n[c.code] = { value: _ }), n[c.code] = { ...n[c.code], isMergeIgnored: !0 };
1440
- }), n[l].isMerge = !0, n[l].width = h.map((c) => this.widthInfo[c.code]).reduce((c, _) => c + _, 0);
1466
+ const s = this.handleComputItem(r);
1467
+ return Object.keys(s).forEach((l) => {
1468
+ if (s[l] instanceof Object && (s[l].merge || 0) > 1) {
1469
+ const f = this.deepHeadData.findIndex((h) => h.code === l), c = this.deepHeadData.slice(f, f + s[l].merge);
1470
+ c.forEach((h) => {
1471
+ const _ = s[h.code];
1472
+ _ instanceof Object || (s[h.code] = { value: _ }), s[h.code] = { ...s[h.code], isMergeIgnored: !0 };
1473
+ }), s[l].isMerge = !0, s[l].width = c.map((h) => this.widthInfo[h.code]).reduce((h, _) => h + _, 0);
1441
1474
  }
1442
1475
  }), {
1443
1476
  __sub: o + parseInt(this.basicSub) + this.beforeIndex,
1444
1477
  ...r,
1445
- ...n,
1478
+ ...s,
1446
1479
  __key: o + this.beforeIndex
1447
1480
  };
1448
1481
  });
@@ -1481,7 +1514,8 @@ const Fe = {
1481
1514
  target: [],
1482
1515
  value: null
1483
1516
  },
1484
- filterInfo: {}
1517
+ filterInfo: {},
1518
+ isBlock: !0
1485
1519
  };
1486
1520
  },
1487
1521
  mounted() {
@@ -1503,7 +1537,7 @@ const Fe = {
1503
1537
  if (this.rowHeight)
1504
1538
  o = this.rowHeight;
1505
1539
  else if (this.rowItemHeight) {
1506
- const n = this.handleComputItem(e, !0), l = this.deepHeadData.map((h) => n[h.code] instanceof Object ? n[h.code].slot ? [n[h.code].slot].flat().length : n[h.code].raw ? [n[h.code].raw].flat().length : n[h.code].value ? [n[h.code].value].flat().length : 1 : 1);
1540
+ const s = this.handleComputItem(e, !0), l = this.deepHeadData.map((c) => s[c.code] instanceof Object ? s[c.code].slot ? [s[c.code].slot].flat().length : s[c.code].raw ? [s[c.code].raw].flat().length : s[c.code].value ? [s[c.code].value].flat().length : 1 : 1);
1507
1541
  o = Math.max(...l) * this.rowItemHeight;
1508
1542
  }
1509
1543
  return o;
@@ -1513,13 +1547,17 @@ const Fe = {
1513
1547
  handleSetWidthInfo(e) {
1514
1548
  this.widthInfo = e;
1515
1549
  },
1550
+ // 设置表格块模式
1551
+ handleSetBlock(e) {
1552
+ this.isBlock = e;
1553
+ },
1516
1554
  // 递归铺开数据
1517
1555
  handleComputItem(e, r) {
1518
1556
  let o = {};
1519
- const n = (l, f) => {
1520
- f.children ? f.children.forEach((h) => n((l || {})[h.code], { ...h, code: `${f.code}_${h.code}` })) : o[f.code] = l;
1557
+ const s = (l, f) => {
1558
+ f.children ? f.children.forEach((c) => s((l || {})[c.code], { ...c, code: `${f.code}_${c.code}` })) : o[f.code] = l;
1521
1559
  };
1522
- return this.headData.filter((l) => r || l.children).forEach((l) => n(e[l.code], l)), o;
1560
+ return this.headData.filter((l) => r || l.children).forEach((l) => s(e[l.code], l)), o;
1523
1561
  },
1524
1562
  // 滚动事件
1525
1563
  handleScroll(e) {
@@ -1529,9 +1567,9 @@ const Fe = {
1529
1567
  this.beforeIndex = Math.max(Math.floor(r / this.rowHeight), 0), this.currentIndex = Math.max(this.beforeIndex + Math.ceil(this.$el.offsetHeight / this.rowHeight) * 3, 50);
1530
1568
  else {
1531
1569
  let o = 0;
1532
- this.beforeIndex = this.fullHeightInfo.findIndex((n) => {
1533
- const l = o + n >= r;
1534
- return l || (o += n), l;
1570
+ this.beforeIndex = this.fullHeightInfo.findIndex((s) => {
1571
+ const l = o + s >= r;
1572
+ return l || (o += s), l;
1535
1573
  }), this.currentIndex = Math.min(this.beforeIndex + 50, this.filterBodyData.length);
1536
1574
  }
1537
1575
  }, 10);
@@ -1544,7 +1582,7 @@ const Fe = {
1544
1582
  handleChangeSort(e, r) {
1545
1583
  if (this.sortInfo.target.join("_") === r.join("_")) {
1546
1584
  const o = ["up", "down", null];
1547
- this.sortInfo.value = o[(o.findIndex((n) => n === (this.sortInfo.value || null)) + 1) % o.length];
1585
+ this.sortInfo.value = o[(o.findIndex((s) => s === (this.sortInfo.value || null)) + 1) % o.length];
1548
1586
  } else
1549
1587
  this.sortInfo = { target: r, value: "up", sortKey: e.sortKey, sortFn: e.sortFn || null };
1550
1588
  this.$emit("changeSort", { key: e.sortKey, value: this.sortInfo.value });
@@ -1554,20 +1592,20 @@ const Fe = {
1554
1592
  this.filterInfo = { ...this.filterInfo, ...e }, this.beforeIndex = 0, this.currentIndex = 50, this.$refs.table.scrollTop = 0, this.$emit("changeFilter", Object.values(this.filterInfo).map((r) => ({ key: r.key, value: r.value })));
1555
1593
  }
1556
1594
  }
1557
- }, B = {};
1595
+ }, A = {};
1558
1596
  var Le = /* @__PURE__ */ C(
1559
1597
  Fe,
1560
- Te,
1598
+ je,
1561
1599
  De,
1562
1600
  !1,
1563
1601
  He,
1564
- "42fb40b0",
1602
+ "2f0f128a",
1565
1603
  null,
1566
1604
  null
1567
1605
  );
1568
1606
  function He(e) {
1569
- for (let r in B)
1570
- this[r] = B[r];
1607
+ for (let r in A)
1608
+ this[r] = A[r];
1571
1609
  }
1572
1610
  const Pe = /* @__PURE__ */ function() {
1573
1611
  return Le.exports;
@@ -1581,7 +1619,7 @@ var Re = function() {
1581
1619
  }
1582
1620
  });
1583
1621
  }, Ne = [];
1584
- const Ae = {
1622
+ const Be = {
1585
1623
  name: "dp-raw",
1586
1624
  props: {
1587
1625
  data: String
@@ -1593,13 +1631,13 @@ const Ae = {
1593
1631
  computSvgDom() {
1594
1632
  const e = ["width", "height"];
1595
1633
  [...this.$el.querySelectorAll("img")].filter((o) => /.svg$/i.test(o.src)).forEach(async (o) => {
1596
- const n = await fetch(o.src).then(async (l) => await l.text());
1597
- if (n) {
1634
+ const s = await fetch(o.src).then(async (l) => await l.text());
1635
+ if (s) {
1598
1636
  const l = document.createElement("span");
1599
1637
  o.replaceWith(l);
1600
1638
  const f = document.createElement("span");
1601
- f.innerHTML = n, [...o.attributes].filter((c) => c.value && c.name !== "src").forEach((c) => {
1602
- e.includes(c.name) ? f.style[c.name] = c.value : f[c.name] = c.value;
1639
+ f.innerHTML = s, [...o.attributes].filter((h) => h.value && h.name !== "src").forEach((h) => {
1640
+ e.includes(h.name) ? f.style[h.name] = h.value : f[h.name] = h.value;
1603
1641
  }), f.style.display = "inline-block", f.style.fontSize = "0", f.setAttribute("part", "__svg_view__"), l.attachShadow({ mode: "open" }).append(f);
1604
1642
  }
1605
1643
  });
@@ -1607,16 +1645,16 @@ const Ae = {
1607
1645
  }
1608
1646
  }, z = {};
1609
1647
  var We = /* @__PURE__ */ C(
1610
- Ae,
1648
+ Be,
1611
1649
  Re,
1612
1650
  Ne,
1613
1651
  !1,
1614
- Be,
1652
+ Ae,
1615
1653
  "65587794",
1616
1654
  null,
1617
1655
  null
1618
1656
  );
1619
- function Be(e) {
1657
+ function Ae(e) {
1620
1658
  for (let r in z)
1621
1659
  this[r] = z[r];
1622
1660
  }
@@ -1624,8 +1662,8 @@ const ze = /* @__PURE__ */ function() {
1624
1662
  return We.exports;
1625
1663
  }();
1626
1664
  var qe = { choice: 'span.__MC41aTVhZDc3NDdnMzM2__[data-t="MC4wNHY2eGVwODFmMXg"]', decide: 'span.__MC5jY2ZpMWU5NzYyamo__[data-t="MC5hMDFjMGM5NGNmZmFl"]', fill: 'span.__MC50aXB0OGc2Y2tqbw__[data-t="MC5mM2VtbTVkcDJm"]', scoreline: 'span.__MC5sOG52dGVycnI5Zw__[data-t="MC42NG83Z2Y1Y2w3bw"]' }, Je = (e) => {
1627
- let { el: r, isShow: o, type: n } = e, l = Object.keys(qe), f = o ? l.filter((c) => !(n || l).includes(c)) : n || l, h = l.filter((c) => !f.includes(c));
1628
- r.classList.add(...f.map((c) => `__toggleraw_${c}_hidden`)), r.classList.remove(...h.map((c) => `__toggleraw_${c}_hidden`));
1665
+ let { el: r, isShow: o, type: s } = e, l = Object.keys(qe), f = o ? l.filter((h) => !(s || l).includes(h)) : s || l, c = l.filter((h) => !f.includes(h));
1666
+ r.classList.add(...f.map((h) => `__toggleraw_${h}_hidden`)), r.classList.remove(...c.map((h) => `__toggleraw_${h}_hidden`));
1629
1667
  }, Ve = Je, Ge = { ToggleRaw: Ve }, Ke = function() {
1630
1668
  var e = this, r = e.$createElement, o = e._self._c || r;
1631
1669
  return o("svg", {
@@ -1684,7 +1722,7 @@ var et = function() {
1684
1722
  left: `${e.index * e.itemW}%`,
1685
1723
  background: e.activeColor
1686
1724
  }
1687
- }), e._l(e.option, function(n, l) {
1725
+ }), e._l(e.option, function(s, l) {
1688
1726
  return o("div", {
1689
1727
  staticClass: "dp-capsule_view_item_",
1690
1728
  style: {
@@ -1693,10 +1731,10 @@ var et = function() {
1693
1731
  },
1694
1732
  on: {
1695
1733
  click: function(f) {
1696
- return e.handleChange(n.code);
1734
+ return e.handleChange(s.code);
1697
1735
  }
1698
1736
  }
1699
- }, [e._v(e._s(n.name))]);
1737
+ }, [e._v(e._s(s.name))]);
1700
1738
  })], 2);
1701
1739
  }, tt = [];
1702
1740
  const ot = {
@@ -1756,10 +1794,10 @@ function it(e) {
1756
1794
  for (let r in J)
1757
1795
  this[r] = J[r];
1758
1796
  }
1759
- const nt = /* @__PURE__ */ function() {
1797
+ const st = /* @__PURE__ */ function() {
1760
1798
  return rt.exports;
1761
1799
  }();
1762
- var st = function() {
1800
+ var nt = function() {
1763
1801
  var e = this, r = e.$createElement, o = e._self._c || r;
1764
1802
  return o("dp-popover", {
1765
1803
  attrs: {
@@ -1772,7 +1810,7 @@ var st = function() {
1772
1810
  name: "set"
1773
1811
  },
1774
1812
  nativeOn: {
1775
- click: function(n) {
1813
+ click: function(s) {
1776
1814
  return e.handleChange(e.isShow);
1777
1815
  }
1778
1816
  },
@@ -1794,7 +1832,7 @@ const lt = {
1794
1832
  components: {
1795
1833
  DpIcon: Qe,
1796
1834
  DpPopover: G,
1797
- DpCapsule: nt
1835
+ DpCapsule: st
1798
1836
  },
1799
1837
  props: {
1800
1838
  initVal: {
@@ -1825,34 +1863,34 @@ const lt = {
1825
1863
  }
1826
1864
  }
1827
1865
  }, V = {};
1828
- var pt = /* @__PURE__ */ C(
1866
+ var dt = /* @__PURE__ */ C(
1829
1867
  lt,
1830
- st,
1868
+ nt,
1831
1869
  at,
1832
1870
  !1,
1833
- dt,
1871
+ pt,
1834
1872
  "41c0d3a5",
1835
1873
  null,
1836
1874
  null
1837
1875
  );
1838
- function dt(e) {
1876
+ function pt(e) {
1839
1877
  for (let r in V)
1840
1878
  this[r] = V[r];
1841
1879
  }
1842
- const ct = /* @__PURE__ */ function() {
1843
- return pt.exports;
1844
- }(), ht = [
1880
+ const ht = /* @__PURE__ */ function() {
1881
+ return dt.exports;
1882
+ }(), ct = [
1845
1883
  Pe,
1846
1884
  ze,
1847
- ct
1885
+ ht
1848
1886
  ], ft = {
1849
1887
  install: (e) => {
1850
- ht.forEach((r) => e.component(r.name, r));
1888
+ ct.forEach((r) => e.component(r.name, r));
1851
1889
  }
1852
1890
  };
1853
1891
  export {
1854
1892
  ze as Raw,
1855
1893
  Pe as Table,
1856
- ct as ToggleRaw,
1894
+ ht as ToggleRaw,
1857
1895
  ft as default
1858
1896
  };