From 2683737c859cddce4e02560dad833741e626e350 Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Wed, 22 Apr 2020 22:31:07 -0700 Subject: [PATCH 01/13] updated to popper 2.3.3 --- src/BlazorTable/wwwroot/BlazorTable.min.js | 40 ++++++++++------------ 1 file changed, 19 insertions(+), 21 deletions(-) diff --git a/src/BlazorTable/wwwroot/BlazorTable.min.js b/src/BlazorTable/wwwroot/BlazorTable.min.js index 3d11ad46..54b3c4d2 100644 --- a/src/BlazorTable/wwwroot/BlazorTable.min.js +++ b/src/BlazorTable/wwwroot/BlazorTable.min.js @@ -1,29 +1,27 @@ -/* - Copyright (C) Federico Zivolo 2019 v1.16.0 - Distributed under the MIT License (license terms are at http://opensource.org/licenses/MIT). - */(function (e, t) { 'object' == typeof exports && 'undefined' != typeof module ? module.exports = t() : 'function' == typeof define && define.amd ? define(t) : e.Popper = t() })(this, function () { 'use strict'; function e(e) { return e && '[object Function]' === {}.toString.call(e) } function t(e, t) { if (1 !== e.nodeType) return []; var o = e.ownerDocument.defaultView, n = o.getComputedStyle(e, null); return t ? n[t] : n } function o(e) { return 'HTML' === e.nodeName ? e : e.parentNode || e.host } function n(e) { if (!e) return document.body; switch (e.nodeName) { case 'HTML': case 'BODY': return e.ownerDocument.body; case '#document': return e.body; }var i = t(e), r = i.overflow, p = i.overflowX, s = i.overflowY; return /(auto|scroll|overlay)/.test(r + s + p) ? e : n(o(e)) } function i(e) { return e && e.referenceNode ? e.referenceNode : e } function r(e) { return 11 === e ? re : 10 === e ? pe : re || pe } function p(e) { if (!e) return document.documentElement; for (var o = r(10) ? document.body : null, n = e.offsetParent || null; n === o && e.nextElementSibling;)n = (e = e.nextElementSibling).offsetParent; var i = n && n.nodeName; return i && 'BODY' !== i && 'HTML' !== i ? -1 !== ['TH', 'TD', 'TABLE'].indexOf(n.nodeName) && 'static' === t(n, 'position') ? p(n) : n : e ? e.ownerDocument.documentElement : document.documentElement } function s(e) { var t = e.nodeName; return 'BODY' !== t && ('HTML' === t || p(e.firstElementChild) === e) } function d(e) { return null === e.parentNode ? e : d(e.parentNode) } function a(e, t) { if (!e || !e.nodeType || !t || !t.nodeType) return document.documentElement; var o = e.compareDocumentPosition(t) & Node.DOCUMENT_POSITION_FOLLOWING, n = o ? e : t, i = o ? t : e, r = document.createRange(); r.setStart(n, 0), r.setEnd(i, 0); var l = r.commonAncestorContainer; if (e !== l && t !== l || n.contains(i)) return s(l) ? l : p(l); var f = d(e); return f.host ? a(f.host, t) : a(e, d(t).host) } function l(e) { var t = 1 < arguments.length && void 0 !== arguments[1] ? arguments[1] : 'top', o = 'top' === t ? 'scrollTop' : 'scrollLeft', n = e.nodeName; if ('BODY' === n || 'HTML' === n) { var i = e.ownerDocument.documentElement, r = e.ownerDocument.scrollingElement || i; return r[o] } return e[o] } function f(e, t) { var o = 2 < arguments.length && void 0 !== arguments[2] && arguments[2], n = l(t, 'top'), i = l(t, 'left'), r = o ? -1 : 1; return e.top += n * r, e.bottom += n * r, e.left += i * r, e.right += i * r, e } function m(e, t) { var o = 'x' === t ? 'Left' : 'Top', n = 'Left' == o ? 'Right' : 'Bottom'; return parseFloat(e['border' + o + 'Width'], 10) + parseFloat(e['border' + n + 'Width'], 10) } function h(e, t, o, n) { return ee(t['offset' + e], t['scroll' + e], o['client' + e], o['offset' + e], o['scroll' + e], r(10) ? parseInt(o['offset' + e]) + parseInt(n['margin' + ('Height' === e ? 'Top' : 'Left')]) + parseInt(n['margin' + ('Height' === e ? 'Bottom' : 'Right')]) : 0) } function c(e) { var t = e.body, o = e.documentElement, n = r(10) && getComputedStyle(o); return { height: h('Height', t, o, n), width: h('Width', t, o, n) } } function g(e) { return le({}, e, { right: e.left + e.width, bottom: e.top + e.height }) } function u(e) { var o = {}; try { if (r(10)) { o = e.getBoundingClientRect(); var n = l(e, 'top'), i = l(e, 'left'); o.top += n, o.left += i, o.bottom += n, o.right += i } else o = e.getBoundingClientRect() } catch (t) { } var p = { left: o.left, top: o.top, width: o.right - o.left, height: o.bottom - o.top }, s = 'HTML' === e.nodeName ? c(e.ownerDocument) : {}, d = s.width || e.clientWidth || p.width, a = s.height || e.clientHeight || p.height, f = e.offsetWidth - d, h = e.offsetHeight - a; if (f || h) { var u = t(e); f -= m(u, 'x'), h -= m(u, 'y'), p.width -= f, p.height -= h } return g(p) } function b(e, o) { var i = 2 < arguments.length && void 0 !== arguments[2] && arguments[2], p = r(10), s = 'HTML' === o.nodeName, d = u(e), a = u(o), l = n(e), m = t(o), h = parseFloat(m.borderTopWidth, 10), c = parseFloat(m.borderLeftWidth, 10); i && s && (a.top = ee(a.top, 0), a.left = ee(a.left, 0)); var b = g({ top: d.top - a.top - h, left: d.left - a.left - c, width: d.width, height: d.height }); if (b.marginTop = 0, b.marginLeft = 0, !p && s) { var w = parseFloat(m.marginTop, 10), y = parseFloat(m.marginLeft, 10); b.top -= h - w, b.bottom -= h - w, b.left -= c - y, b.right -= c - y, b.marginTop = w, b.marginLeft = y } return (p && !i ? o.contains(l) : o === l && 'BODY' !== l.nodeName) && (b = f(b, o)), b } function w(e) { var t = 1 < arguments.length && void 0 !== arguments[1] && arguments[1], o = e.ownerDocument.documentElement, n = b(e, o), i = ee(o.clientWidth, window.innerWidth || 0), r = ee(o.clientHeight, window.innerHeight || 0), p = t ? 0 : l(o), s = t ? 0 : l(o, 'left'), d = { top: p - n.top + n.marginTop, left: s - n.left + n.marginLeft, width: i, height: r }; return g(d) } function y(e) { var n = e.nodeName; if ('BODY' === n || 'HTML' === n) return !1; if ('fixed' === t(e, 'position')) return !0; var i = o(e); return !!i && y(i) } function E(e) { if (!e || !e.parentElement || r()) return document.documentElement; for (var o = e.parentElement; o && 'none' === t(o, 'transform');)o = o.parentElement; return o || document.documentElement } function v(e, t, r, p) { var s = 4 < arguments.length && void 0 !== arguments[4] && arguments[4], d = { top: 0, left: 0 }, l = s ? E(e) : a(e, i(t)); if ('viewport' === p) d = w(l, s); else { var f; 'scrollParent' === p ? (f = n(o(t)), 'BODY' === f.nodeName && (f = e.ownerDocument.documentElement)) : 'window' === p ? f = e.ownerDocument.documentElement : f = p; var m = b(f, l, s); if ('HTML' === f.nodeName && !y(l)) { var h = c(e.ownerDocument), g = h.height, u = h.width; d.top += m.top - m.marginTop, d.bottom = g + m.top, d.left += m.left - m.marginLeft, d.right = u + m.left } else d = m } r = r || 0; var v = 'number' == typeof r; return d.left += v ? r : r.left || 0, d.top += v ? r : r.top || 0, d.right -= v ? r : r.right || 0, d.bottom -= v ? r : r.bottom || 0, d } function x(e) { var t = e.width, o = e.height; return t * o } function O(e, t, o, n, i) { var r = 5 < arguments.length && void 0 !== arguments[5] ? arguments[5] : 0; if (-1 === e.indexOf('auto')) return e; var p = v(o, n, r, i), s = { top: { width: p.width, height: t.top - p.top }, right: { width: p.right - t.right, height: p.height }, bottom: { width: p.width, height: p.bottom - t.bottom }, left: { width: t.left - p.left, height: p.height } }, d = Object.keys(s).map(function (e) { return le({ key: e }, s[e], { area: x(s[e]) }) }).sort(function (e, t) { return t.area - e.area }), a = d.filter(function (e) { var t = e.width, n = e.height; return t >= o.clientWidth && n >= o.clientHeight }), l = 0 < a.length ? a[0].key : d[0].key, f = e.split('-')[1]; return l + (f ? '-' + f : '') } function L(e, t, o) { var n = 3 < arguments.length && void 0 !== arguments[3] ? arguments[3] : null, r = n ? E(t) : a(t, i(o)); return b(o, r, n) } function S(e) { var t = e.ownerDocument.defaultView, o = t.getComputedStyle(e), n = parseFloat(o.marginTop || 0) + parseFloat(o.marginBottom || 0), i = parseFloat(o.marginLeft || 0) + parseFloat(o.marginRight || 0), r = { width: e.offsetWidth + i, height: e.offsetHeight + n }; return r } function T(e) { var t = { left: 'right', right: 'left', bottom: 'top', top: 'bottom' }; return e.replace(/left|right|bottom|top/g, function (e) { return t[e] }) } function C(e, t, o) { o = o.split('-')[0]; var n = S(e), i = { width: n.width, height: n.height }, r = -1 !== ['right', 'left'].indexOf(o), p = r ? 'top' : 'left', s = r ? 'left' : 'top', d = r ? 'height' : 'width', a = r ? 'width' : 'height'; return i[p] = t[p] + t[d] / 2 - n[d] / 2, i[s] = o === s ? t[s] - n[a] : t[T(s)], i } function D(e, t) { return Array.prototype.find ? e.find(t) : e.filter(t)[0] } function N(e, t, o) { if (Array.prototype.findIndex) return e.findIndex(function (e) { return e[t] === o }); var n = D(e, function (e) { return e[t] === o }); return e.indexOf(n) } function P(t, o, n) { var i = void 0 === n ? t : t.slice(0, N(t, 'name', n)); return i.forEach(function (t) { t['function'] && console.warn('`modifier.function` is deprecated, use `modifier.fn`!'); var n = t['function'] || t.fn; t.enabled && e(n) && (o.offsets.popper = g(o.offsets.popper), o.offsets.reference = g(o.offsets.reference), o = n(o, t)) }), o } function k() { if (!this.state.isDestroyed) { var e = { instance: this, styles: {}, arrowStyles: {}, attributes: {}, flipped: !1, offsets: {} }; e.offsets.reference = L(this.state, this.popper, this.reference, this.options.positionFixed), e.placement = O(this.options.placement, e.offsets.reference, this.popper, this.reference, this.options.modifiers.flip.boundariesElement, this.options.modifiers.flip.padding), e.originalPlacement = e.placement, e.positionFixed = this.options.positionFixed, e.offsets.popper = C(this.popper, e.offsets.reference, e.placement), e.offsets.popper.position = this.options.positionFixed ? 'fixed' : 'absolute', e = P(this.modifiers, e), this.state.isCreated ? this.options.onUpdate(e) : (this.state.isCreated = !0, this.options.onCreate(e)) } } function W(e, t) { return e.some(function (e) { var o = e.name, n = e.enabled; return n && o === t }) } function B(e) { for (var t = [!1, 'ms', 'Webkit', 'Moz', 'O'], o = e.charAt(0).toUpperCase() + e.slice(1), n = 0; n < t.length; n++) { var i = t[n], r = i ? '' + i + o : e; if ('undefined' != typeof document.body.style[r]) return r } return null } function H() { return this.state.isDestroyed = !0, W(this.modifiers, 'applyStyle') && (this.popper.removeAttribute('x-placement'), this.popper.style.position = '', this.popper.style.top = '', this.popper.style.left = '', this.popper.style.right = '', this.popper.style.bottom = '', this.popper.style.willChange = '', this.popper.style[B('transform')] = ''), this.disableEventListeners(), this.options.removeOnDestroy && this.popper.parentNode.removeChild(this.popper), this } function A(e) { var t = e.ownerDocument; return t ? t.defaultView : window } function M(e, t, o, i) { var r = 'BODY' === e.nodeName, p = r ? e.ownerDocument.defaultView : e; p.addEventListener(t, o, { passive: !0 }), r || M(n(p.parentNode), t, o, i), i.push(p) } function F(e, t, o, i) { o.updateBound = i, A(e).addEventListener('resize', o.updateBound, { passive: !0 }); var r = n(e); return M(r, 'scroll', o.updateBound, o.scrollParents), o.scrollElement = r, o.eventsEnabled = !0, o } function I() { this.state.eventsEnabled || (this.state = F(this.reference, this.options, this.state, this.scheduleUpdate)) } function R(e, t) { return A(e).removeEventListener('resize', t.updateBound), t.scrollParents.forEach(function (e) { e.removeEventListener('scroll', t.updateBound) }), t.updateBound = null, t.scrollParents = [], t.scrollElement = null, t.eventsEnabled = !1, t } function U() { this.state.eventsEnabled && (cancelAnimationFrame(this.scheduleUpdate), this.state = R(this.reference, this.state)) } function Y(e) { return '' !== e && !isNaN(parseFloat(e)) && isFinite(e) } function V(e, t) { Object.keys(t).forEach(function (o) { var n = ''; -1 !== ['width', 'height', 'top', 'right', 'bottom', 'left'].indexOf(o) && Y(t[o]) && (n = 'px'), e.style[o] = t[o] + n }) } function j(e, t) { Object.keys(t).forEach(function (o) { var n = t[o]; !1 === n ? e.removeAttribute(o) : e.setAttribute(o, t[o]) }) } function q(e, t) { var o = e.offsets, n = o.popper, i = o.reference, r = $, p = function (e) { return e }, s = r(i.width), d = r(n.width), a = -1 !== ['left', 'right'].indexOf(e.placement), l = -1 !== e.placement.indexOf('-'), f = t ? a || l || s % 2 == d % 2 ? r : Z : p, m = t ? r : p; return { left: f(1 == s % 2 && 1 == d % 2 && !l && t ? n.left - 1 : n.left), top: m(n.top), bottom: m(n.bottom), right: f(n.right) } } function K(e, t, o) { var n = D(e, function (e) { var o = e.name; return o === t }), i = !!n && e.some(function (e) { return e.name === o && e.enabled && e.order < n.order }); if (!i) { var r = '`' + t + '`'; console.warn('`' + o + '`' + ' modifier is required by ' + r + ' modifier in order to work, be sure to include it before ' + r + '!') } return i } function z(e) { return 'end' === e ? 'start' : 'start' === e ? 'end' : e } function G(e) { var t = 1 < arguments.length && void 0 !== arguments[1] && arguments[1], o = he.indexOf(e), n = he.slice(o + 1).concat(he.slice(0, o)); return t ? n.reverse() : n } function _(e, t, o, n) { var i = e.match(/((?:\-|\+)?\d*\.?\d*)(.*)/), r = +i[1], p = i[2]; if (!r) return e; if (0 === p.indexOf('%')) { var s; switch (p) { case '%p': s = o; break; case '%': case '%r': default: s = n; }var d = g(s); return d[t] / 100 * r } if ('vh' === p || 'vw' === p) { var a; return a = 'vh' === p ? ee(document.documentElement.clientHeight, window.innerHeight || 0) : ee(document.documentElement.clientWidth, window.innerWidth || 0), a / 100 * r } return r } function X(e, t, o, n) { var i = [0, 0], r = -1 !== ['right', 'left'].indexOf(n), p = e.split(/(\+|\-)/).map(function (e) { return e.trim() }), s = p.indexOf(D(p, function (e) { return -1 !== e.search(/,|\s/) })); p[s] && -1 === p[s].indexOf(',') && console.warn('Offsets separated by white space(s) are deprecated, use a comma (,) instead.'); var d = /\s*,\s*|\s+/, a = -1 === s ? [p] : [p.slice(0, s).concat([p[s].split(d)[0]]), [p[s].split(d)[1]].concat(p.slice(s + 1))]; return a = a.map(function (e, n) { var i = (1 === n ? !r : r) ? 'height' : 'width', p = !1; return e.reduce(function (e, t) { return '' === e[e.length - 1] && -1 !== ['+', '-'].indexOf(t) ? (e[e.length - 1] = t, p = !0, e) : p ? (e[e.length - 1] += t, p = !1, e) : e.concat(t) }, []).map(function (e) { return _(e, i, t, o) }) }), a.forEach(function (e, t) { e.forEach(function (o, n) { Y(o) && (i[t] += o * ('-' === e[n - 1] ? -1 : 1)) }) }), i } function J(e, t) { var o, n = t.offset, i = e.placement, r = e.offsets, p = r.popper, s = r.reference, d = i.split('-')[0]; return o = Y(+n) ? [+n, 0] : X(n, p, s, d), 'left' === d ? (p.top += o[0], p.left -= o[1]) : 'right' === d ? (p.top += o[0], p.left += o[1]) : 'top' === d ? (p.left += o[0], p.top -= o[1]) : 'bottom' === d && (p.left += o[0], p.top += o[1]), e.popper = p, e } var Q = Math.min, Z = Math.floor, $ = Math.round, ee = Math.max, te = 'undefined' != typeof window && 'undefined' != typeof document && 'undefined' != typeof navigator, oe = function () { for (var e = ['Edge', 'Trident', 'Firefox'], t = 0; t < e.length; t += 1)if (te && 0 <= navigator.userAgent.indexOf(e[t])) return 1; return 0 }(), ne = te && window.Promise, ie = ne ? function (e) { var t = !1; return function () { t || (t = !0, window.Promise.resolve().then(function () { t = !1, e() })) } } : function (e) { var t = !1; return function () { t || (t = !0, setTimeout(function () { t = !1, e() }, oe)) } }, re = te && !!(window.MSInputMethodContext && document.documentMode), pe = te && /MSIE 10/.test(navigator.userAgent), se = function (e, t) { if (!(e instanceof t)) throw new TypeError('Cannot call a class as a function') }, de = function () { function e(e, t) { for (var o, n = 0; n < t.length; n++)o = t[n], o.enumerable = o.enumerable || !1, o.configurable = !0, 'value' in o && (o.writable = !0), Object.defineProperty(e, o.key, o) } return function (t, o, n) { return o && e(t.prototype, o), n && e(t, n), t } }(), ae = function (e, t, o) { return t in e ? Object.defineProperty(e, t, { value: o, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = o, e }, le = Object.assign || function (e) { for (var t, o = 1; o < arguments.length; o++)for (var n in t = arguments[o], t) Object.prototype.hasOwnProperty.call(t, n) && (e[n] = t[n]); return e }, fe = te && /Firefox/i.test(navigator.userAgent), me = ['auto-start', 'auto', 'auto-end', 'top-start', 'top', 'top-end', 'right-start', 'right', 'right-end', 'bottom-end', 'bottom', 'bottom-start', 'left-end', 'left', 'left-start'], he = me.slice(3), ce = { FLIP: 'flip', CLOCKWISE: 'clockwise', COUNTERCLOCKWISE: 'counterclockwise' }, ge = function () { function t(o, n) { var i = this, r = 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : {}; se(this, t), this.scheduleUpdate = function () { return requestAnimationFrame(i.update) }, this.update = ie(this.update.bind(this)), this.options = le({}, t.Defaults, r), this.state = { isDestroyed: !1, isCreated: !1, scrollParents: [] }, this.reference = o && o.jquery ? o[0] : o, this.popper = n && n.jquery ? n[0] : n, this.options.modifiers = {}, Object.keys(le({}, t.Defaults.modifiers, r.modifiers)).forEach(function (e) { i.options.modifiers[e] = le({}, t.Defaults.modifiers[e] || {}, r.modifiers ? r.modifiers[e] : {}) }), this.modifiers = Object.keys(this.options.modifiers).map(function (e) { return le({ name: e }, i.options.modifiers[e]) }).sort(function (e, t) { return e.order - t.order }), this.modifiers.forEach(function (t) { t.enabled && e(t.onLoad) && t.onLoad(i.reference, i.popper, i.options, t, i.state) }), this.update(); var p = this.options.eventsEnabled; p && this.enableEventListeners(), this.state.eventsEnabled = p } return de(t, [{ key: 'update', value: function () { return k.call(this) } }, { key: 'destroy', value: function () { return H.call(this) } }, { key: 'enableEventListeners', value: function () { return I.call(this) } }, { key: 'disableEventListeners', value: function () { return U.call(this) } }]), t }(); return ge.Utils = ('undefined' == typeof window ? global : window).PopperUtils, ge.placements = me, ge.Defaults = { placement: 'bottom', positionFixed: !1, eventsEnabled: !0, removeOnDestroy: !1, onCreate: function () { }, onUpdate: function () { }, modifiers: { shift: { order: 100, enabled: !0, fn: function (e) { var t = e.placement, o = t.split('-')[0], n = t.split('-')[1]; if (n) { var i = e.offsets, r = i.reference, p = i.popper, s = -1 !== ['bottom', 'top'].indexOf(o), d = s ? 'left' : 'top', a = s ? 'width' : 'height', l = { start: ae({}, d, r[d]), end: ae({}, d, r[d] + r[a] - p[a]) }; e.offsets.popper = le({}, p, l[n]) } return e } }, offset: { order: 200, enabled: !0, fn: J, offset: 0 }, preventOverflow: { order: 300, enabled: !0, fn: function (e, t) { var o = t.boundariesElement || p(e.instance.popper); e.instance.reference === o && (o = p(o)); var n = B('transform'), i = e.instance.popper.style, r = i.top, s = i.left, d = i[n]; i.top = '', i.left = '', i[n] = ''; var a = v(e.instance.popper, e.instance.reference, t.padding, o, e.positionFixed); i.top = r, i.left = s, i[n] = d, t.boundaries = a; var l = t.priority, f = e.offsets.popper, m = { primary: function (e) { var o = f[e]; return f[e] < a[e] && !t.escapeWithReference && (o = ee(f[e], a[e])), ae({}, e, o) }, secondary: function (e) { var o = 'right' === e ? 'left' : 'top', n = f[o]; return f[e] > a[e] && !t.escapeWithReference && (n = Q(f[o], a[e] - ('right' === e ? f.width : f.height))), ae({}, o, n) } }; return l.forEach(function (e) { var t = -1 === ['left', 'top'].indexOf(e) ? 'secondary' : 'primary'; f = le({}, f, m[t](e)) }), e.offsets.popper = f, e }, priority: ['left', 'right', 'top', 'bottom'], padding: 5, boundariesElement: 'scrollParent' }, keepTogether: { order: 400, enabled: !0, fn: function (e) { var t = e.offsets, o = t.popper, n = t.reference, i = e.placement.split('-')[0], r = Z, p = -1 !== ['top', 'bottom'].indexOf(i), s = p ? 'right' : 'bottom', d = p ? 'left' : 'top', a = p ? 'width' : 'height'; return o[s] < r(n[d]) && (e.offsets.popper[d] = r(n[d]) - o[a]), o[d] > r(n[s]) && (e.offsets.popper[d] = r(n[s])), e } }, arrow: { order: 500, enabled: !0, fn: function (e, o) { var n; if (!K(e.instance.modifiers, 'arrow', 'keepTogether')) return e; var i = o.element; if ('string' == typeof i) { if (i = e.instance.popper.querySelector(i), !i) return e; } else if (!e.instance.popper.contains(i)) return console.warn('WARNING: `arrow.element` must be child of its popper element!'), e; var r = e.placement.split('-')[0], p = e.offsets, s = p.popper, d = p.reference, a = -1 !== ['left', 'right'].indexOf(r), l = a ? 'height' : 'width', f = a ? 'Top' : 'Left', m = f.toLowerCase(), h = a ? 'left' : 'top', c = a ? 'bottom' : 'right', u = S(i)[l]; d[c] - u < s[m] && (e.offsets.popper[m] -= s[m] - (d[c] - u)), d[m] + u > s[c] && (e.offsets.popper[m] += d[m] + u - s[c]), e.offsets.popper = g(e.offsets.popper); var b = d[m] + d[l] / 2 - u / 2, w = t(e.instance.popper), y = parseFloat(w['margin' + f], 10), E = parseFloat(w['border' + f + 'Width'], 10), v = b - e.offsets.popper[m] - y - E; return v = ee(Q(s[l] - u, v), 0), e.arrowElement = i, e.offsets.arrow = (n = {}, ae(n, m, $(v)), ae(n, h, ''), n), e }, element: '[x-arrow]' }, flip: { order: 600, enabled: !0, fn: function (e, t) { if (W(e.instance.modifiers, 'inner')) return e; if (e.flipped && e.placement === e.originalPlacement) return e; var o = v(e.instance.popper, e.instance.reference, t.padding, t.boundariesElement, e.positionFixed), n = e.placement.split('-')[0], i = T(n), r = e.placement.split('-')[1] || '', p = []; switch (t.behavior) { case ce.FLIP: p = [n, i]; break; case ce.CLOCKWISE: p = G(n); break; case ce.COUNTERCLOCKWISE: p = G(n, !0); break; default: p = t.behavior; }return p.forEach(function (s, d) { if (n !== s || p.length === d + 1) return e; n = e.placement.split('-')[0], i = T(n); var a = e.offsets.popper, l = e.offsets.reference, f = Z, m = 'left' === n && f(a.right) > f(l.left) || 'right' === n && f(a.left) < f(l.right) || 'top' === n && f(a.bottom) > f(l.top) || 'bottom' === n && f(a.top) < f(l.bottom), h = f(a.left) < f(o.left), c = f(a.right) > f(o.right), g = f(a.top) < f(o.top), u = f(a.bottom) > f(o.bottom), b = 'left' === n && h || 'right' === n && c || 'top' === n && g || 'bottom' === n && u, w = -1 !== ['top', 'bottom'].indexOf(n), y = !!t.flipVariations && (w && 'start' === r && h || w && 'end' === r && c || !w && 'start' === r && g || !w && 'end' === r && u), E = !!t.flipVariationsByContent && (w && 'start' === r && c || w && 'end' === r && h || !w && 'start' === r && u || !w && 'end' === r && g), v = y || E; (m || b || v) && (e.flipped = !0, (m || b) && (n = p[d + 1]), v && (r = z(r)), e.placement = n + (r ? '-' + r : ''), e.offsets.popper = le({}, e.offsets.popper, C(e.instance.popper, e.offsets.reference, e.placement)), e = P(e.instance.modifiers, e, 'flip')) }), e }, behavior: 'flip', padding: 5, boundariesElement: 'viewport', flipVariations: !1, flipVariationsByContent: !1 }, inner: { order: 700, enabled: !1, fn: function (e) { var t = e.placement, o = t.split('-')[0], n = e.offsets, i = n.popper, r = n.reference, p = -1 !== ['left', 'right'].indexOf(o), s = -1 === ['top', 'left'].indexOf(o); return i[p ? 'left' : 'top'] = r[o] - (s ? i[p ? 'width' : 'height'] : 0), e.placement = T(t), e.offsets.popper = g(i), e } }, hide: { order: 800, enabled: !0, fn: function (e) { if (!K(e.instance.modifiers, 'hide', 'preventOverflow')) return e; var t = e.offsets.reference, o = D(e.instance.modifiers, function (e) { return 'preventOverflow' === e.name }).boundaries; if (t.bottom < o.top || t.left > o.right || t.top > o.bottom || t.right < o.left) { if (!0 === e.hide) return e; e.hide = !0, e.attributes['x-out-of-boundaries'] = '' } else { if (!1 === e.hide) return e; e.hide = !1, e.attributes['x-out-of-boundaries'] = !1 } return e } }, computeStyle: { order: 850, enabled: !0, fn: function (e, t) { var o = t.x, n = t.y, i = e.offsets.popper, r = D(e.instance.modifiers, function (e) { return 'applyStyle' === e.name }).gpuAcceleration; void 0 !== r && console.warn('WARNING: `gpuAcceleration` option moved to `computeStyle` modifier and will not be supported in future versions of Popper.js!'); var s, d, a = void 0 === r ? t.gpuAcceleration : r, l = p(e.instance.popper), f = u(l), m = { position: i.position }, h = q(e, 2 > window.devicePixelRatio || !fe), c = 'bottom' === o ? 'top' : 'bottom', g = 'right' === n ? 'left' : 'right', b = B('transform'); if (d = 'bottom' == c ? 'HTML' === l.nodeName ? -l.clientHeight + h.bottom : -f.height + h.bottom : h.top, s = 'right' == g ? 'HTML' === l.nodeName ? -l.clientWidth + h.right : -f.width + h.right : h.left, a && b) m[b] = 'translate3d(' + s + 'px, ' + d + 'px, 0)', m[c] = 0, m[g] = 0, m.willChange = 'transform'; else { var w = 'bottom' == c ? -1 : 1, y = 'right' == g ? -1 : 1; m[c] = d * w, m[g] = s * y, m.willChange = c + ', ' + g } var E = { "x-placement": e.placement }; return e.attributes = le({}, E, e.attributes), e.styles = le({}, m, e.styles), e.arrowStyles = le({}, e.offsets.arrow, e.arrowStyles), e }, gpuAcceleration: !0, x: 'bottom', y: 'right' }, applyStyle: { order: 900, enabled: !0, fn: function (e) { return V(e.instance.popper, e.styles), j(e.instance.popper, e.attributes), e.arrowElement && Object.keys(e.arrowStyles).length && V(e.arrowElement, e.arrowStyles), e }, onLoad: function (e, t, o, n, i) { var r = L(i, t, e, o.positionFixed), p = O(o.placement, r, t, e, o.modifiers.flip.boundariesElement, o.modifiers.flip.padding); return t.setAttribute('x-placement', p), V(t, { position: o.positionFixed ? 'fixed' : 'absolute' }), o }, gpuAcceleration: void 0 } } }, ge }); +/** + * @popperjs/core v2.3.3 - MIT License + */ + +"use strict"; !function (e, t) { "object" == typeof exports && "undefined" != typeof module ? t(exports) : "function" == typeof define && define.amd ? define(["exports"], t) : t((e = e || self).Popper = {}) }(this, (function (e) { function t(e) { return { width: (e = e.getBoundingClientRect()).width, height: e.height, top: e.top, right: e.right, bottom: e.bottom, left: e.left, x: e.left, y: e.top } } function r(e) { return "[object Window]" !== e.toString() ? (e = e.ownerDocument) ? e.defaultView : window : e } function n(e) { return { scrollLeft: (e = r(e)).pageXOffset, scrollTop: e.pageYOffset } } function o(e) { return e instanceof r(e).Element || e instanceof Element } function i(e) { return e instanceof r(e).HTMLElement || e instanceof HTMLElement } function a(e) { return e ? (e.nodeName || "").toLowerCase() : null } function s(e) { return (o(e) ? e.ownerDocument : e.document).documentElement } function f(e) { return t(s(e)).left + n(e).scrollLeft } function p(e, o, p) { void 0 === p && (p = !1), e = t(e); var c = { scrollLeft: 0, scrollTop: 0 }, u = { x: 0, y: 0 }; return p || ("body" !== a(o) && (c = o !== r(o) && i(o) ? { scrollLeft: o.scrollLeft, scrollTop: o.scrollTop } : n(o)), i(o) ? ((u = t(o)).x += o.clientLeft, u.y += o.clientTop) : (o = s(o)) && (u.x = f(o))), { x: e.left + c.scrollLeft - u.x, y: e.top + c.scrollTop - u.y, width: e.width, height: e.height } } function c(e) { return { x: e.offsetLeft, y: e.offsetTop, width: e.offsetWidth, height: e.offsetHeight } } function u(e) { return "html" === a(e) ? e : e.assignedSlot || e.parentNode || e.host || s(e) } function l(e) { return r(e).getComputedStyle(e) } function d(e, t) { void 0 === t && (t = []); var n = function e(t) { if (0 <= ["html", "body", "#document"].indexOf(a(t))) return t.ownerDocument.body; if (i(t)) { var r = l(t); if (/auto|scroll|overlay|hidden/.test(r.overflow + r.overflowY + r.overflowX)) return t } return e(u(t)) }(e); e = "body" === a(n); var o = r(n); return n = e ? [o].concat(o.visualViewport || []) : n, t = t.concat(n), e ? t : t.concat(d(u(n))) } function m(e) { return i(e) && "fixed" !== l(e).position ? e.offsetParent : null } function h(e) { var t = r(e); for (e = m(e); e && 0 <= ["table", "td", "th"].indexOf(a(e));)e = m(e); return e && "body" === a(e) && "static" === l(e).position ? t : e || t } function v(e) { var t = new Map, r = new Set, n = []; return e.forEach((function (e) { t.set(e.name, e) })), e.forEach((function (e) { r.has(e.name) || function e(o) { r.add(o.name), [].concat(o.requires || [], o.requiresIfExists || []).forEach((function (n) { r.has(n) || (n = t.get(n)) && e(n) })), n.push(o) }(e) })), n } function g(e) { var t; return function () { return t || (t = new Promise((function (r) { Promise.resolve().then((function () { t = void 0, r(e()) })) }))), t } } function b(e) { return e.split("-")[0] } function y() { for (var e = arguments.length, t = Array(e), r = 0; r < e; r++)t[r] = arguments[r]; return !t.some((function (e) { return !(e && "function" == typeof e.getBoundingClientRect) })) } function w(e) { void 0 === e && (e = {}); var t = e.defaultModifiers, r = void 0 === t ? [] : t, n = void 0 === (e = e.defaultOptions) ? F : e; return function (e, t, i) { function a() { f.forEach((function (e) { return e() })), f = [] } void 0 === i && (i = n); var s = { placement: "bottom", orderedModifiers: [], options: Object.assign({}, F, {}, n), modifiersData: {}, elements: { reference: e, popper: t }, attributes: {}, styles: {} }, f = [], u = !1, l = { state: s, setOptions: function (i) { return a(), s.options = Object.assign({}, n, {}, s.options, {}, i), s.scrollParents = { reference: o(e) ? d(e) : e.contextElement ? d(e.contextElement) : [], popper: d(t) }, i = function (e) { var t = v(e); return C.reduce((function (e, r) { return e.concat(t.filter((function (e) { return e.phase === r }))) }), []) }(function (e) { var t = e.reduce((function (e, t) { var r = e[t.name]; return e[t.name] = r ? Object.assign({}, r, {}, t, { options: Object.assign({}, r.options, {}, t.options), data: Object.assign({}, r.data, {}, t.data) }) : t, e }), {}); return Object.keys(t).map((function (e) { return t[e] })) }([].concat(r, s.options.modifiers))), s.orderedModifiers = i.filter((function (e) { return e.enabled })), s.orderedModifiers.forEach((function (e) { var t = e.name, r = e.options; r = void 0 === r ? {} : r, "function" == typeof (e = e.effect) && (t = e({ state: s, name: t, instance: l, options: r }), f.push(t || function () { })) })), l.update() }, forceUpdate: function () { if (!u) { var e = s.elements, t = e.reference; if (y(t, e = e.popper)) for (s.rects = { reference: p(t, h(e), "fixed" === s.options.strategy), popper: c(e) }, s.reset = !1, s.placement = s.options.placement, s.orderedModifiers.forEach((function (e) { return s.modifiersData[e.name] = Object.assign({}, e.data) })), t = 0; t < s.orderedModifiers.length; t++)if (!0 === s.reset) s.reset = !1, t = -1; else { var r = s.orderedModifiers[t]; e = r.fn; var n = r.options; n = void 0 === n ? {} : n, r = r.name, "function" == typeof e && (s = e({ state: s, options: n, name: r, instance: l }) || s) } } }, update: g((function () { return new Promise((function (e) { l.forceUpdate(), e(s) })) })), destroy: function () { a(), u = !0 } }; return y(e, t) ? (l.setOptions(i).then((function (e) { !u && i.onFirstUpdate && i.onFirstUpdate(e) })), l) : l } } function x(e) { return 0 <= ["top", "bottom"].indexOf(e) ? "x" : "y" } function O(e) { var t = e.reference, r = e.element, n = (e = e.placement) ? b(e) : null; e = e ? e.split("-")[1] : null; var o = t.x + t.width / 2 - r.width / 2, i = t.y + t.height / 2 - r.height / 2; switch (n) { case "top": o = { x: o, y: t.y - r.height }; break; case "bottom": o = { x: o, y: t.y + t.height }; break; case "right": o = { x: t.x + t.width, y: i }; break; case "left": o = { x: t.x - r.width, y: i }; break; default: o = { x: t.x, y: t.y } }if (null != (n = n ? x(n) : null)) switch (i = "y" === n ? "height" : "width", e) { case "start": o[n] = Math.floor(o[n]) - Math.floor(t[i] / 2 - r[i] / 2); break; case "end": o[n] = Math.floor(o[n]) + Math.ceil(t[i] / 2 - r[i] / 2) }return o } function M(e) { var t, n = e.popper, o = e.popperRect, i = e.placement, a = e.offsets, f = e.position, p = e.gpuAcceleration, c = e.adaptive, u = window.devicePixelRatio || 1; e = Math.round(a.x * u) / u || 0, u = Math.round(a.y * u) / u || 0; var l = a.hasOwnProperty("x"); a = a.hasOwnProperty("y"); var d, m = "left", v = "top", g = window; if (c) { var b = h(n); b === r(n) && (b = s(n)), "top" === i && (v = "bottom", u -= b.clientHeight - o.height, u *= p ? 1 : -1), "left" === i && (m = "right", e -= b.clientWidth - o.width, e *= p ? 1 : -1) } return n = Object.assign({ position: f }, c && V), p ? Object.assign({}, n, ((d = {})[v] = a ? "0" : "", d[m] = l ? "0" : "", d.transform = 2 > (g.devicePixelRatio || 1) ? "translate(" + e + "px, " + u + "px)" : "translate3d(" + e + "px, " + u + "px, 0)", d)) : Object.assign({}, n, ((t = {})[v] = a ? u + "px" : "", t[m] = l ? e + "px" : "", t.transform = "", t)) } function j(e) { return e.replace(/left|right|bottom|top/g, (function (e) { return I[e] })) } function E(e) { return e.replace(/start|end/g, (function (e) { return _[e] })) } function D(e, t) { var r = !(!t.getRootNode || !t.getRootNode().host); if (e.contains(t)) return !0; if (r) do { if (t && e.isSameNode(t)) return !0; t = t.parentNode || t.host } while (t); return !1 } function P(e) { return Object.assign({}, e, { left: e.x, top: e.y, right: e.x + e.width, bottom: e.y + e.height }) } function L(e, o) { if ("viewport" === o) { var a = r(e); e = a.visualViewport, o = a.innerWidth, a = a.innerHeight, e && /iPhone|iPod|iPad/.test(navigator.platform) && (o = e.width, a = e.height), e = P({ width: o, height: a, x: 0, y: 0 }) } else i(o) ? e = t(o) : (e = r(a = s(e)), o = n(a), (a = p(s(a), e)).height = Math.max(a.height, e.innerHeight), a.width = Math.max(a.width, e.innerWidth), a.x = -o.scrollLeft, a.y = -o.scrollTop, e = P(a)); return e } function k(e, t, n) { return t = "clippingParents" === t ? function (e) { var t = d(e), r = 0 <= ["absolute", "fixed"].indexOf(l(e).position) && i(e) ? h(e) : e; return o(r) ? t.filter((function (e) { return o(e) && D(e, r) })) : [] }(e) : [].concat(t), (n = (n = [].concat(t, [n])).reduce((function (t, n) { var o = L(e, n), p = r(n = i(n) ? n : s(e)), c = i(n) ? l(n) : {}; parseFloat(c.borderTopWidth); var u = parseFloat(c.borderRightWidth) || 0, d = parseFloat(c.borderBottomWidth) || 0, m = parseFloat(c.borderLeftWidth) || 0; c = "html" === a(n); var h = f(n), v = n.clientWidth + u, g = n.clientHeight + d; return c && 50 < p.innerHeight - n.clientHeight && (g = p.innerHeight - d), d = c ? 0 : n.clientTop, u = n.clientLeft > m ? u : c ? p.innerWidth - v - h : n.offsetWidth - v, p = c ? p.innerHeight - g : n.offsetHeight - g, n = c ? h : n.clientLeft, t.top = Math.max(o.top + d, t.top), t.right = Math.min(o.right - u, t.right), t.bottom = Math.min(o.bottom - p, t.bottom), t.left = Math.max(o.left + n, t.left), t }), L(e, n[0]))).width = n.right - n.left, n.height = n.bottom - n.top, n.x = n.left, n.y = n.top, n } function B(e) { return Object.assign({}, { top: 0, right: 0, bottom: 0, left: 0 }, {}, e) } function W(e, t) { return t.reduce((function (t, r) { return t[r] = e, t }), {}) } function H(e, r) { void 0 === r && (r = {}); var n = r; r = void 0 === (r = n.placement) ? e.placement : r; var i = n.boundary, a = void 0 === i ? "clippingParents" : i, f = void 0 === (i = n.rootBoundary) ? "viewport" : i; i = void 0 === (i = n.elementContext) ? "popper" : i; var p = n.altBoundary, c = void 0 !== p && p; n = B("number" != typeof (n = void 0 === (n = n.padding) ? 0 : n) ? n : W(n, R)); var u = e.elements.reference; p = e.rects.popper, a = k(o(c = e.elements[c ? "popper" === i ? "reference" : "popper" : i]) ? c : c.contextElement || s(e.elements.popper), a, f), c = O({ reference: f = t(u), element: p, strategy: "absolute", placement: r }), p = P(Object.assign({}, p, {}, c)), f = "popper" === i ? p : f; var l = { top: a.top - f.top + n.top, bottom: f.bottom - a.bottom + n.bottom, left: a.left - f.left + n.left, right: f.right - a.right + n.right }; if (e = e.modifiersData.offset, "popper" === i && e) { var d = e[r]; Object.keys(l).forEach((function (e) { var t = 0 <= ["right", "bottom"].indexOf(e) ? 1 : -1, r = 0 <= ["top", "bottom"].indexOf(e) ? "y" : "x"; l[e] += d[r] * t })) } return l } function T(e, t, r) { return void 0 === r && (r = { x: 0, y: 0 }), { top: e.top - t.height - r.y, right: e.right - t.width + r.x, bottom: e.bottom - t.height + r.y, left: e.left - t.width - r.x } } function A(e) { return ["top", "right", "bottom", "left"].some((function (t) { return 0 <= e[t] })) } var R = ["top", "bottom", "right", "left"], q = R.reduce((function (e, t) { return e.concat([t + "-start", t + "-end"]) }), []), S = [].concat(R, ["auto"]).reduce((function (e, t) { return e.concat([t, t + "-start", t + "-end"]) }), []), C = "beforeRead read afterRead beforeMain main afterMain beforeWrite write afterWrite".split(" "), F = { placement: "bottom", modifiers: [], strategy: "absolute" }, N = { passive: !0 }, V = { top: "auto", right: "auto", bottom: "auto", left: "auto" }, I = { left: "right", right: "left", bottom: "top", top: "bottom" }, _ = { start: "end", end: "start" }, U = [{ name: "eventListeners", enabled: !0, phase: "write", fn: function () { }, effect: function (e) { var t = e.state, n = e.instance, o = (e = e.options).scroll, i = void 0 === o || o, a = void 0 === (e = e.resize) || e, s = r(t.elements.popper), f = [].concat(t.scrollParents.reference, t.scrollParents.popper); return i && f.forEach((function (e) { e.addEventListener("scroll", n.update, N) })), a && s.addEventListener("resize", n.update, N), function () { i && f.forEach((function (e) { e.removeEventListener("scroll", n.update, N) })), a && s.removeEventListener("resize", n.update, N) } }, data: {} }, { name: "popperOffsets", enabled: !0, phase: "read", fn: function (e) { var t = e.state; t.modifiersData[e.name] = O({ reference: t.rects.reference, element: t.rects.popper, strategy: "absolute", placement: t.placement }) }, data: {} }, { name: "computeStyles", enabled: !0, phase: "beforeWrite", fn: function (e) { var t = e.state, r = e.options; e = void 0 === (e = r.gpuAcceleration) || e, r = void 0 === (r = r.adaptive) || r, e = { placement: b(t.placement), popper: t.elements.popper, popperRect: t.rects.popper, gpuAcceleration: e }, null != t.modifiersData.popperOffsets && (t.styles.popper = Object.assign({}, t.styles.popper, {}, M(Object.assign({}, e, { offsets: t.modifiersData.popperOffsets, position: t.options.strategy, adaptive: r })))), null != t.modifiersData.arrow && (t.styles.arrow = Object.assign({}, t.styles.arrow, {}, M(Object.assign({}, e, { offsets: t.modifiersData.arrow, position: "absolute", adaptive: !1 })))), t.attributes.popper = Object.assign({}, t.attributes.popper, { "data-popper-placement": t.placement }) }, data: {} }, { name: "applyStyles", enabled: !0, phase: "write", fn: function (e) { var t = e.state; Object.keys(t.elements).forEach((function (e) { var r = t.styles[e] || {}, n = t.attributes[e] || {}, o = t.elements[e]; i(o) && a(o) && (Object.assign(o.style, r), Object.keys(n).forEach((function (e) { var t = n[e]; !1 === t ? o.removeAttribute(e) : o.setAttribute(e, !0 === t ? "" : t) }))) })) }, effect: function (e) { var t = e.state, r = { popper: { position: t.options.strategy, left: "0", top: "0", margin: "0" }, arrow: { position: "absolute" }, reference: {} }; return Object.assign(t.elements.popper.style, r.popper), t.elements.arrow && Object.assign(t.elements.arrow.style, r.arrow), function () { Object.keys(t.elements).forEach((function (e) { var n = t.elements[e], o = t.attributes[e] || {}; e = Object.keys(t.styles.hasOwnProperty(e) ? t.styles[e] : r[e]).reduce((function (e, t) { return e[t] = "", e }), {}), i(n) && a(n) && (Object.assign(n.style, e), Object.keys(o).forEach((function (e) { n.removeAttribute(e) }))) })) } }, requires: ["computeStyles"] }, { name: "offset", enabled: !0, phase: "main", requires: ["popperOffsets"], fn: function (e) { var t = e.state, r = e.name, n = void 0 === (e = e.options.offset) ? [0, 0] : e, o = (e = S.reduce((function (e, r) { var o = t.rects, i = b(r), a = 0 <= ["left", "top"].indexOf(i) ? -1 : 1, s = "function" == typeof n ? n(Object.assign({}, o, { placement: r })) : n; return o = (o = s[0]) || 0, s = ((s = s[1]) || 0) * a, i = 0 <= ["left", "right"].indexOf(i) ? { x: s, y: o } : { x: o, y: s }, e[r] = i, e }), {}))[t.placement], i = o.x; o = o.y, null != t.modifiersData.popperOffsets && (t.modifiersData.popperOffsets.x += i, t.modifiersData.popperOffsets.y += o), t.modifiersData[r] = e } }, { name: "flip", enabled: !0, phase: "main", fn: function (e) { var t = e.state, r = e.options; if (e = e.name, !t.modifiersData[e]._skip) { var n = r.fallbackPlacements, o = r.padding, i = r.boundary, a = r.rootBoundary, s = r.altBoundary, f = r.flipVariations, p = void 0 === f || f, c = r.allowedAutoPlacements; f = b(r = t.options.placement), n = n || (f !== r && p ? function (e) { if ("auto" === b(e)) return []; var t = j(e); return [E(e), t, E(t)] }(r) : [j(r)]); var u = [r].concat(n).reduce((function (e, r) { return e.concat("auto" === b(r) ? function (e, t) { void 0 === t && (t = {}); var r = t.boundary, n = t.rootBoundary, o = t.padding, i = t.flipVariations, a = t.allowedAutoPlacements, s = void 0 === a ? S : a, f = t.placement.split("-")[1], p = (f ? i ? q : q.filter((function (e) { return e.split("-")[1] === f })) : R).filter((function (e) { return 0 <= s.indexOf(e) })).reduce((function (t, i) { return t[i] = H(e, { placement: i, boundary: r, rootBoundary: n, padding: o })[b(i)], t }), {}); return Object.keys(p).sort((function (e, t) { return p[e] - p[t] })) }(t, { placement: r, boundary: i, rootBoundary: a, padding: o, flipVariations: p, allowedAutoPlacements: c }) : r) }), []); n = t.rects.reference, r = t.rects.popper; var l = new Map; f = !0; for (var d = u[0], m = 0; m < u.length; m++) { var h = u[m], v = b(h), g = "start" === h.split("-")[1], y = 0 <= ["top", "bottom"].indexOf(v), w = y ? "width" : "height", x = H(t, { placement: h, boundary: i, rootBoundary: a, altBoundary: s, padding: o }); if (g = y ? g ? "right" : "left" : g ? "bottom" : "top", n[w] > r[w] && (g = j(g)), w = j(g), (v = [0 >= x[v], 0 >= x[g], 0 >= x[w]]).every((function (e) { return e }))) { d = h, f = !1; break } l.set(h, v) } if (f) for (s = function (e) { var t = u.find((function (t) { if (t = l.get(t)) return t.slice(0, e).every((function (e) { return e })) })); if (t) return d = t, "break" }, n = p ? 3 : 1; 0 < n && "break" !== s(n); n--); t.placement !== d && (t.modifiersData[e]._skip = !0, t.placement = d, t.reset = !0) } }, requiresIfExists: ["offset"], data: { _skip: !1 } }, { name: "preventOverflow", enabled: !0, phase: "main", fn: function (e) { var t = e.state, r = e.options; e = e.name; var n = r.mainAxis, o = void 0 === n || n; n = void 0 !== (n = r.altAxis) && n; var i = r.tether; i = void 0 === i || i; var a = r.tetherOffset, s = void 0 === a ? 0 : a; r = H(t, { boundary: r.boundary, rootBoundary: r.rootBoundary, padding: r.padding, altBoundary: r.altBoundary }), a = b(t.placement); var f = t.placement.split("-")[1], p = !f, u = x(a); a = "x" === u ? "y" : "x"; var l = t.modifiersData.popperOffsets, d = t.rects.reference, m = t.rects.popper, v = "function" == typeof s ? s(Object.assign({}, t.rects, { placement: t.placement })) : s; if (s = { x: 0, y: 0 }, l) { if (o) { var g = "y" === u ? "top" : "left", y = "y" === u ? "bottom" : "right", w = "y" === u ? "height" : "width"; o = l[u]; var O = l[u] + r[g], M = l[u] - r[y], j = i ? -m[w] / 2 : 0, E = "start" === f ? d[w] : m[w]; f = "start" === f ? -m[w] : -d[w], m = t.elements.arrow, m = i && m ? c(m) : { width: 0, height: 0 }; var D = t.modifiersData["arrow#persistent"] ? t.modifiersData["arrow#persistent"].padding : { top: 0, right: 0, bottom: 0, left: 0 }; g = D[g], y = D[y], m = Math.max(0, Math.min(d[w], m[w])), E = p ? d[w] / 2 - j - m - g - v : E - m - g - v, p = p ? -d[w] / 2 + j + m + y + v : f + m + y + v, v = t.elements.arrow && h(t.elements.arrow), d = t.modifiersData.offset ? t.modifiersData.offset[t.placement][u] : 0, v = l[u] + E - d - (v ? "y" === u ? v.clientTop || 0 : v.clientLeft || 0 : 0), p = l[u] + p - d, i = Math.max(i ? Math.min(O, v) : O, Math.min(o, i ? Math.max(M, p) : M)), l[u] = i, s[u] = i - o } n && (n = l[a], i = Math.max(n + r["x" === u ? "top" : "left"], Math.min(n, n - r["x" === u ? "bottom" : "right"])), l[a] = i, s[a] = i - n), t.modifiersData[e] = s } }, requiresIfExists: ["offset"] }, { name: "arrow", enabled: !0, phase: "main", fn: function (e) { var t, r = e.state; e = e.name; var n = r.elements.arrow, o = r.modifiersData.popperOffsets, i = b(r.placement), a = x(i); if (i = 0 <= ["left", "right"].indexOf(i) ? "height" : "width", n && o) { var s = r.modifiersData[e + "#persistent"].padding; n = c(n); var f = "y" === a ? "top" : "left", p = "y" === a ? "bottom" : "right", u = r.rects.reference[i] + r.rects.reference[a] - o[a] - r.rects.popper[i]; o = o[a] - r.rects.reference[a]; var l = r.elements.arrow && h(r.elements.arrow); u = (l = l ? "y" === a ? l.clientHeight || 0 : l.clientWidth || 0 : 0) / 2 - n[i] / 2 + (u / 2 - o / 2), i = Math.max(s[f], Math.min(u, l - n[i] - s[p])), r.modifiersData[e] = ((t = {})[a] = i, t.centerOffset = i - u, t) } }, effect: function (e) { var t = e.state, r = e.options; e = e.name; var n = r.element; if (n = void 0 === n ? "[data-popper-arrow]" : n, r = void 0 === (r = r.padding) ? 0 : r, null != n) { if ("string" == typeof n && !(n = t.elements.popper.querySelector(n))) return; D(t.elements.popper, n) && (t.elements.arrow = n, t.modifiersData[e + "#persistent"] = { padding: B("number" != typeof r ? r : W(r, R)) }) } }, requires: ["popperOffsets"], requiresIfExists: ["preventOverflow"] }, { name: "hide", enabled: !0, phase: "main", requiresIfExists: ["preventOverflow"], fn: function (e) { var t = e.state; e = e.name; var r = t.rects.reference, n = t.rects.popper, o = t.modifiersData.preventOverflow, i = H(t, { elementContext: "reference" }), a = H(t, { altBoundary: !0 }); r = T(i, r), n = T(a, n, o), o = A(r), a = A(n), t.modifiersData[e] = { referenceClippingOffsets: r, popperEscapeOffsets: n, isReferenceHidden: o, hasPopperEscaped: a }, t.attributes.popper = Object.assign({}, t.attributes.popper, { "data-popper-reference-hidden": o, "data-popper-escaped": a }) } }], z = w({ defaultModifiers: U }); e.createPopper = z, e.defaultModifiers = U, e.detectOverflow = H, e.popperGenerator = w, Object.defineProperty(e, "__esModule", { value: !0 }) })); window.BlazorTablePopper = (reference, popper, arrow, placement) => { - new Popper(reference, popper, - { - placement, - modifiers: { - offset: { - offset: 0 - }, - flip: { - behavior: "flip" - }, - arrow: { + Popper.createPopper(reference, popper, { + placement, + modifiers: [ + { + name: 'arrow', + options: { element: arrow, - enabled: true }, - preventOverflow: { + }, + { + name: 'preventOverflow', + options: { boundary: "scrollParent" - } - } - } - ); + }, + }, + ], + }); return true; }; \ No newline at end of file From 4594fd07b117b841de43100d15bd9c389b10d26e Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Wed, 22 Apr 2020 22:35:54 -0700 Subject: [PATCH 02/13] altBoundary: true --- src/BlazorTable/wwwroot/BlazorTable.min.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/BlazorTable/wwwroot/BlazorTable.min.js b/src/BlazorTable/wwwroot/BlazorTable.min.js index 54b3c4d2..1d1aa1b2 100644 --- a/src/BlazorTable/wwwroot/BlazorTable.min.js +++ b/src/BlazorTable/wwwroot/BlazorTable.min.js @@ -17,7 +17,7 @@ window.BlazorTablePopper = (reference, popper, arrow, placement) => { { name: 'preventOverflow', options: { - boundary: "scrollParent" + altBoundary: true, // false by default }, }, ], From f2ea916dfce82629e7fdb7f5028b9cb418a8c48b Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Wed, 22 Apr 2020 22:41:07 -0700 Subject: [PATCH 03/13] boundary: "window" --- src/BlazorTable/wwwroot/BlazorTable.min.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/BlazorTable/wwwroot/BlazorTable.min.js b/src/BlazorTable/wwwroot/BlazorTable.min.js index 1d1aa1b2..04797669 100644 --- a/src/BlazorTable/wwwroot/BlazorTable.min.js +++ b/src/BlazorTable/wwwroot/BlazorTable.min.js @@ -17,7 +17,7 @@ window.BlazorTablePopper = (reference, popper, arrow, placement) => { { name: 'preventOverflow', options: { - altBoundary: true, // false by default + boundary: "window" }, }, ], From 476d10bf9bba6238175b36a49c2bb5ea36a53fc1 Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Wed, 22 Apr 2020 23:06:53 -0700 Subject: [PATCH 04/13] strategy: 'fixed' --- src/BlazorTable/wwwroot/BlazorTable.min.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/BlazorTable/wwwroot/BlazorTable.min.js b/src/BlazorTable/wwwroot/BlazorTable.min.js index 04797669..89bf85a3 100644 --- a/src/BlazorTable/wwwroot/BlazorTable.min.js +++ b/src/BlazorTable/wwwroot/BlazorTable.min.js @@ -7,6 +7,7 @@ window.BlazorTablePopper = (reference, popper, arrow, placement) => { Popper.createPopper(reference, popper, { placement, + strategy: 'fixed', modifiers: [ { name: 'arrow', @@ -15,10 +16,7 @@ window.BlazorTablePopper = (reference, popper, arrow, placement) => { }, }, { - name: 'preventOverflow', - options: { - boundary: "window" - }, + name: 'preventOverflow' }, ], }); From cfafffa256647305bf98fe6b227021d80f45776a Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Wed, 22 Apr 2020 23:29:29 -0700 Subject: [PATCH 05/13] minified --- src/BlazorTable/wwwroot/BlazorTable.min.js | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/src/BlazorTable/wwwroot/BlazorTable.min.js b/src/BlazorTable/wwwroot/BlazorTable.min.js index 89bf85a3..f3a1ba7c 100644 --- a/src/BlazorTable/wwwroot/BlazorTable.min.js +++ b/src/BlazorTable/wwwroot/BlazorTable.min.js @@ -4,22 +4,4 @@ "use strict"; !function (e, t) { "object" == typeof exports && "undefined" != typeof module ? t(exports) : "function" == typeof define && define.amd ? define(["exports"], t) : t((e = e || self).Popper = {}) }(this, (function (e) { function t(e) { return { width: (e = e.getBoundingClientRect()).width, height: e.height, top: e.top, right: e.right, bottom: e.bottom, left: e.left, x: e.left, y: e.top } } function r(e) { return "[object Window]" !== e.toString() ? (e = e.ownerDocument) ? e.defaultView : window : e } function n(e) { return { scrollLeft: (e = r(e)).pageXOffset, scrollTop: e.pageYOffset } } function o(e) { return e instanceof r(e).Element || e instanceof Element } function i(e) { return e instanceof r(e).HTMLElement || e instanceof HTMLElement } function a(e) { return e ? (e.nodeName || "").toLowerCase() : null } function s(e) { return (o(e) ? e.ownerDocument : e.document).documentElement } function f(e) { return t(s(e)).left + n(e).scrollLeft } function p(e, o, p) { void 0 === p && (p = !1), e = t(e); var c = { scrollLeft: 0, scrollTop: 0 }, u = { x: 0, y: 0 }; return p || ("body" !== a(o) && (c = o !== r(o) && i(o) ? { scrollLeft: o.scrollLeft, scrollTop: o.scrollTop } : n(o)), i(o) ? ((u = t(o)).x += o.clientLeft, u.y += o.clientTop) : (o = s(o)) && (u.x = f(o))), { x: e.left + c.scrollLeft - u.x, y: e.top + c.scrollTop - u.y, width: e.width, height: e.height } } function c(e) { return { x: e.offsetLeft, y: e.offsetTop, width: e.offsetWidth, height: e.offsetHeight } } function u(e) { return "html" === a(e) ? e : e.assignedSlot || e.parentNode || e.host || s(e) } function l(e) { return r(e).getComputedStyle(e) } function d(e, t) { void 0 === t && (t = []); var n = function e(t) { if (0 <= ["html", "body", "#document"].indexOf(a(t))) return t.ownerDocument.body; if (i(t)) { var r = l(t); if (/auto|scroll|overlay|hidden/.test(r.overflow + r.overflowY + r.overflowX)) return t } return e(u(t)) }(e); e = "body" === a(n); var o = r(n); return n = e ? [o].concat(o.visualViewport || []) : n, t = t.concat(n), e ? t : t.concat(d(u(n))) } function m(e) { return i(e) && "fixed" !== l(e).position ? e.offsetParent : null } function h(e) { var t = r(e); for (e = m(e); e && 0 <= ["table", "td", "th"].indexOf(a(e));)e = m(e); return e && "body" === a(e) && "static" === l(e).position ? t : e || t } function v(e) { var t = new Map, r = new Set, n = []; return e.forEach((function (e) { t.set(e.name, e) })), e.forEach((function (e) { r.has(e.name) || function e(o) { r.add(o.name), [].concat(o.requires || [], o.requiresIfExists || []).forEach((function (n) { r.has(n) || (n = t.get(n)) && e(n) })), n.push(o) }(e) })), n } function g(e) { var t; return function () { return t || (t = new Promise((function (r) { Promise.resolve().then((function () { t = void 0, r(e()) })) }))), t } } function b(e) { return e.split("-")[0] } function y() { for (var e = arguments.length, t = Array(e), r = 0; r < e; r++)t[r] = arguments[r]; return !t.some((function (e) { return !(e && "function" == typeof e.getBoundingClientRect) })) } function w(e) { void 0 === e && (e = {}); var t = e.defaultModifiers, r = void 0 === t ? [] : t, n = void 0 === (e = e.defaultOptions) ? F : e; return function (e, t, i) { function a() { f.forEach((function (e) { return e() })), f = [] } void 0 === i && (i = n); var s = { placement: "bottom", orderedModifiers: [], options: Object.assign({}, F, {}, n), modifiersData: {}, elements: { reference: e, popper: t }, attributes: {}, styles: {} }, f = [], u = !1, l = { state: s, setOptions: function (i) { return a(), s.options = Object.assign({}, n, {}, s.options, {}, i), s.scrollParents = { reference: o(e) ? d(e) : e.contextElement ? d(e.contextElement) : [], popper: d(t) }, i = function (e) { var t = v(e); return C.reduce((function (e, r) { return e.concat(t.filter((function (e) { return e.phase === r }))) }), []) }(function (e) { var t = e.reduce((function (e, t) { var r = e[t.name]; return e[t.name] = r ? Object.assign({}, r, {}, t, { options: Object.assign({}, r.options, {}, t.options), data: Object.assign({}, r.data, {}, t.data) }) : t, e }), {}); return Object.keys(t).map((function (e) { return t[e] })) }([].concat(r, s.options.modifiers))), s.orderedModifiers = i.filter((function (e) { return e.enabled })), s.orderedModifiers.forEach((function (e) { var t = e.name, r = e.options; r = void 0 === r ? {} : r, "function" == typeof (e = e.effect) && (t = e({ state: s, name: t, instance: l, options: r }), f.push(t || function () { })) })), l.update() }, forceUpdate: function () { if (!u) { var e = s.elements, t = e.reference; if (y(t, e = e.popper)) for (s.rects = { reference: p(t, h(e), "fixed" === s.options.strategy), popper: c(e) }, s.reset = !1, s.placement = s.options.placement, s.orderedModifiers.forEach((function (e) { return s.modifiersData[e.name] = Object.assign({}, e.data) })), t = 0; t < s.orderedModifiers.length; t++)if (!0 === s.reset) s.reset = !1, t = -1; else { var r = s.orderedModifiers[t]; e = r.fn; var n = r.options; n = void 0 === n ? {} : n, r = r.name, "function" == typeof e && (s = e({ state: s, options: n, name: r, instance: l }) || s) } } }, update: g((function () { return new Promise((function (e) { l.forceUpdate(), e(s) })) })), destroy: function () { a(), u = !0 } }; return y(e, t) ? (l.setOptions(i).then((function (e) { !u && i.onFirstUpdate && i.onFirstUpdate(e) })), l) : l } } function x(e) { return 0 <= ["top", "bottom"].indexOf(e) ? "x" : "y" } function O(e) { var t = e.reference, r = e.element, n = (e = e.placement) ? b(e) : null; e = e ? e.split("-")[1] : null; var o = t.x + t.width / 2 - r.width / 2, i = t.y + t.height / 2 - r.height / 2; switch (n) { case "top": o = { x: o, y: t.y - r.height }; break; case "bottom": o = { x: o, y: t.y + t.height }; break; case "right": o = { x: t.x + t.width, y: i }; break; case "left": o = { x: t.x - r.width, y: i }; break; default: o = { x: t.x, y: t.y } }if (null != (n = n ? x(n) : null)) switch (i = "y" === n ? "height" : "width", e) { case "start": o[n] = Math.floor(o[n]) - Math.floor(t[i] / 2 - r[i] / 2); break; case "end": o[n] = Math.floor(o[n]) + Math.ceil(t[i] / 2 - r[i] / 2) }return o } function M(e) { var t, n = e.popper, o = e.popperRect, i = e.placement, a = e.offsets, f = e.position, p = e.gpuAcceleration, c = e.adaptive, u = window.devicePixelRatio || 1; e = Math.round(a.x * u) / u || 0, u = Math.round(a.y * u) / u || 0; var l = a.hasOwnProperty("x"); a = a.hasOwnProperty("y"); var d, m = "left", v = "top", g = window; if (c) { var b = h(n); b === r(n) && (b = s(n)), "top" === i && (v = "bottom", u -= b.clientHeight - o.height, u *= p ? 1 : -1), "left" === i && (m = "right", e -= b.clientWidth - o.width, e *= p ? 1 : -1) } return n = Object.assign({ position: f }, c && V), p ? Object.assign({}, n, ((d = {})[v] = a ? "0" : "", d[m] = l ? "0" : "", d.transform = 2 > (g.devicePixelRatio || 1) ? "translate(" + e + "px, " + u + "px)" : "translate3d(" + e + "px, " + u + "px, 0)", d)) : Object.assign({}, n, ((t = {})[v] = a ? u + "px" : "", t[m] = l ? e + "px" : "", t.transform = "", t)) } function j(e) { return e.replace(/left|right|bottom|top/g, (function (e) { return I[e] })) } function E(e) { return e.replace(/start|end/g, (function (e) { return _[e] })) } function D(e, t) { var r = !(!t.getRootNode || !t.getRootNode().host); if (e.contains(t)) return !0; if (r) do { if (t && e.isSameNode(t)) return !0; t = t.parentNode || t.host } while (t); return !1 } function P(e) { return Object.assign({}, e, { left: e.x, top: e.y, right: e.x + e.width, bottom: e.y + e.height }) } function L(e, o) { if ("viewport" === o) { var a = r(e); e = a.visualViewport, o = a.innerWidth, a = a.innerHeight, e && /iPhone|iPod|iPad/.test(navigator.platform) && (o = e.width, a = e.height), e = P({ width: o, height: a, x: 0, y: 0 }) } else i(o) ? e = t(o) : (e = r(a = s(e)), o = n(a), (a = p(s(a), e)).height = Math.max(a.height, e.innerHeight), a.width = Math.max(a.width, e.innerWidth), a.x = -o.scrollLeft, a.y = -o.scrollTop, e = P(a)); return e } function k(e, t, n) { return t = "clippingParents" === t ? function (e) { var t = d(e), r = 0 <= ["absolute", "fixed"].indexOf(l(e).position) && i(e) ? h(e) : e; return o(r) ? t.filter((function (e) { return o(e) && D(e, r) })) : [] }(e) : [].concat(t), (n = (n = [].concat(t, [n])).reduce((function (t, n) { var o = L(e, n), p = r(n = i(n) ? n : s(e)), c = i(n) ? l(n) : {}; parseFloat(c.borderTopWidth); var u = parseFloat(c.borderRightWidth) || 0, d = parseFloat(c.borderBottomWidth) || 0, m = parseFloat(c.borderLeftWidth) || 0; c = "html" === a(n); var h = f(n), v = n.clientWidth + u, g = n.clientHeight + d; return c && 50 < p.innerHeight - n.clientHeight && (g = p.innerHeight - d), d = c ? 0 : n.clientTop, u = n.clientLeft > m ? u : c ? p.innerWidth - v - h : n.offsetWidth - v, p = c ? p.innerHeight - g : n.offsetHeight - g, n = c ? h : n.clientLeft, t.top = Math.max(o.top + d, t.top), t.right = Math.min(o.right - u, t.right), t.bottom = Math.min(o.bottom - p, t.bottom), t.left = Math.max(o.left + n, t.left), t }), L(e, n[0]))).width = n.right - n.left, n.height = n.bottom - n.top, n.x = n.left, n.y = n.top, n } function B(e) { return Object.assign({}, { top: 0, right: 0, bottom: 0, left: 0 }, {}, e) } function W(e, t) { return t.reduce((function (t, r) { return t[r] = e, t }), {}) } function H(e, r) { void 0 === r && (r = {}); var n = r; r = void 0 === (r = n.placement) ? e.placement : r; var i = n.boundary, a = void 0 === i ? "clippingParents" : i, f = void 0 === (i = n.rootBoundary) ? "viewport" : i; i = void 0 === (i = n.elementContext) ? "popper" : i; var p = n.altBoundary, c = void 0 !== p && p; n = B("number" != typeof (n = void 0 === (n = n.padding) ? 0 : n) ? n : W(n, R)); var u = e.elements.reference; p = e.rects.popper, a = k(o(c = e.elements[c ? "popper" === i ? "reference" : "popper" : i]) ? c : c.contextElement || s(e.elements.popper), a, f), c = O({ reference: f = t(u), element: p, strategy: "absolute", placement: r }), p = P(Object.assign({}, p, {}, c)), f = "popper" === i ? p : f; var l = { top: a.top - f.top + n.top, bottom: f.bottom - a.bottom + n.bottom, left: a.left - f.left + n.left, right: f.right - a.right + n.right }; if (e = e.modifiersData.offset, "popper" === i && e) { var d = e[r]; Object.keys(l).forEach((function (e) { var t = 0 <= ["right", "bottom"].indexOf(e) ? 1 : -1, r = 0 <= ["top", "bottom"].indexOf(e) ? "y" : "x"; l[e] += d[r] * t })) } return l } function T(e, t, r) { return void 0 === r && (r = { x: 0, y: 0 }), { top: e.top - t.height - r.y, right: e.right - t.width + r.x, bottom: e.bottom - t.height + r.y, left: e.left - t.width - r.x } } function A(e) { return ["top", "right", "bottom", "left"].some((function (t) { return 0 <= e[t] })) } var R = ["top", "bottom", "right", "left"], q = R.reduce((function (e, t) { return e.concat([t + "-start", t + "-end"]) }), []), S = [].concat(R, ["auto"]).reduce((function (e, t) { return e.concat([t, t + "-start", t + "-end"]) }), []), C = "beforeRead read afterRead beforeMain main afterMain beforeWrite write afterWrite".split(" "), F = { placement: "bottom", modifiers: [], strategy: "absolute" }, N = { passive: !0 }, V = { top: "auto", right: "auto", bottom: "auto", left: "auto" }, I = { left: "right", right: "left", bottom: "top", top: "bottom" }, _ = { start: "end", end: "start" }, U = [{ name: "eventListeners", enabled: !0, phase: "write", fn: function () { }, effect: function (e) { var t = e.state, n = e.instance, o = (e = e.options).scroll, i = void 0 === o || o, a = void 0 === (e = e.resize) || e, s = r(t.elements.popper), f = [].concat(t.scrollParents.reference, t.scrollParents.popper); return i && f.forEach((function (e) { e.addEventListener("scroll", n.update, N) })), a && s.addEventListener("resize", n.update, N), function () { i && f.forEach((function (e) { e.removeEventListener("scroll", n.update, N) })), a && s.removeEventListener("resize", n.update, N) } }, data: {} }, { name: "popperOffsets", enabled: !0, phase: "read", fn: function (e) { var t = e.state; t.modifiersData[e.name] = O({ reference: t.rects.reference, element: t.rects.popper, strategy: "absolute", placement: t.placement }) }, data: {} }, { name: "computeStyles", enabled: !0, phase: "beforeWrite", fn: function (e) { var t = e.state, r = e.options; e = void 0 === (e = r.gpuAcceleration) || e, r = void 0 === (r = r.adaptive) || r, e = { placement: b(t.placement), popper: t.elements.popper, popperRect: t.rects.popper, gpuAcceleration: e }, null != t.modifiersData.popperOffsets && (t.styles.popper = Object.assign({}, t.styles.popper, {}, M(Object.assign({}, e, { offsets: t.modifiersData.popperOffsets, position: t.options.strategy, adaptive: r })))), null != t.modifiersData.arrow && (t.styles.arrow = Object.assign({}, t.styles.arrow, {}, M(Object.assign({}, e, { offsets: t.modifiersData.arrow, position: "absolute", adaptive: !1 })))), t.attributes.popper = Object.assign({}, t.attributes.popper, { "data-popper-placement": t.placement }) }, data: {} }, { name: "applyStyles", enabled: !0, phase: "write", fn: function (e) { var t = e.state; Object.keys(t.elements).forEach((function (e) { var r = t.styles[e] || {}, n = t.attributes[e] || {}, o = t.elements[e]; i(o) && a(o) && (Object.assign(o.style, r), Object.keys(n).forEach((function (e) { var t = n[e]; !1 === t ? o.removeAttribute(e) : o.setAttribute(e, !0 === t ? "" : t) }))) })) }, effect: function (e) { var t = e.state, r = { popper: { position: t.options.strategy, left: "0", top: "0", margin: "0" }, arrow: { position: "absolute" }, reference: {} }; return Object.assign(t.elements.popper.style, r.popper), t.elements.arrow && Object.assign(t.elements.arrow.style, r.arrow), function () { Object.keys(t.elements).forEach((function (e) { var n = t.elements[e], o = t.attributes[e] || {}; e = Object.keys(t.styles.hasOwnProperty(e) ? t.styles[e] : r[e]).reduce((function (e, t) { return e[t] = "", e }), {}), i(n) && a(n) && (Object.assign(n.style, e), Object.keys(o).forEach((function (e) { n.removeAttribute(e) }))) })) } }, requires: ["computeStyles"] }, { name: "offset", enabled: !0, phase: "main", requires: ["popperOffsets"], fn: function (e) { var t = e.state, r = e.name, n = void 0 === (e = e.options.offset) ? [0, 0] : e, o = (e = S.reduce((function (e, r) { var o = t.rects, i = b(r), a = 0 <= ["left", "top"].indexOf(i) ? -1 : 1, s = "function" == typeof n ? n(Object.assign({}, o, { placement: r })) : n; return o = (o = s[0]) || 0, s = ((s = s[1]) || 0) * a, i = 0 <= ["left", "right"].indexOf(i) ? { x: s, y: o } : { x: o, y: s }, e[r] = i, e }), {}))[t.placement], i = o.x; o = o.y, null != t.modifiersData.popperOffsets && (t.modifiersData.popperOffsets.x += i, t.modifiersData.popperOffsets.y += o), t.modifiersData[r] = e } }, { name: "flip", enabled: !0, phase: "main", fn: function (e) { var t = e.state, r = e.options; if (e = e.name, !t.modifiersData[e]._skip) { var n = r.fallbackPlacements, o = r.padding, i = r.boundary, a = r.rootBoundary, s = r.altBoundary, f = r.flipVariations, p = void 0 === f || f, c = r.allowedAutoPlacements; f = b(r = t.options.placement), n = n || (f !== r && p ? function (e) { if ("auto" === b(e)) return []; var t = j(e); return [E(e), t, E(t)] }(r) : [j(r)]); var u = [r].concat(n).reduce((function (e, r) { return e.concat("auto" === b(r) ? function (e, t) { void 0 === t && (t = {}); var r = t.boundary, n = t.rootBoundary, o = t.padding, i = t.flipVariations, a = t.allowedAutoPlacements, s = void 0 === a ? S : a, f = t.placement.split("-")[1], p = (f ? i ? q : q.filter((function (e) { return e.split("-")[1] === f })) : R).filter((function (e) { return 0 <= s.indexOf(e) })).reduce((function (t, i) { return t[i] = H(e, { placement: i, boundary: r, rootBoundary: n, padding: o })[b(i)], t }), {}); return Object.keys(p).sort((function (e, t) { return p[e] - p[t] })) }(t, { placement: r, boundary: i, rootBoundary: a, padding: o, flipVariations: p, allowedAutoPlacements: c }) : r) }), []); n = t.rects.reference, r = t.rects.popper; var l = new Map; f = !0; for (var d = u[0], m = 0; m < u.length; m++) { var h = u[m], v = b(h), g = "start" === h.split("-")[1], y = 0 <= ["top", "bottom"].indexOf(v), w = y ? "width" : "height", x = H(t, { placement: h, boundary: i, rootBoundary: a, altBoundary: s, padding: o }); if (g = y ? g ? "right" : "left" : g ? "bottom" : "top", n[w] > r[w] && (g = j(g)), w = j(g), (v = [0 >= x[v], 0 >= x[g], 0 >= x[w]]).every((function (e) { return e }))) { d = h, f = !1; break } l.set(h, v) } if (f) for (s = function (e) { var t = u.find((function (t) { if (t = l.get(t)) return t.slice(0, e).every((function (e) { return e })) })); if (t) return d = t, "break" }, n = p ? 3 : 1; 0 < n && "break" !== s(n); n--); t.placement !== d && (t.modifiersData[e]._skip = !0, t.placement = d, t.reset = !0) } }, requiresIfExists: ["offset"], data: { _skip: !1 } }, { name: "preventOverflow", enabled: !0, phase: "main", fn: function (e) { var t = e.state, r = e.options; e = e.name; var n = r.mainAxis, o = void 0 === n || n; n = void 0 !== (n = r.altAxis) && n; var i = r.tether; i = void 0 === i || i; var a = r.tetherOffset, s = void 0 === a ? 0 : a; r = H(t, { boundary: r.boundary, rootBoundary: r.rootBoundary, padding: r.padding, altBoundary: r.altBoundary }), a = b(t.placement); var f = t.placement.split("-")[1], p = !f, u = x(a); a = "x" === u ? "y" : "x"; var l = t.modifiersData.popperOffsets, d = t.rects.reference, m = t.rects.popper, v = "function" == typeof s ? s(Object.assign({}, t.rects, { placement: t.placement })) : s; if (s = { x: 0, y: 0 }, l) { if (o) { var g = "y" === u ? "top" : "left", y = "y" === u ? "bottom" : "right", w = "y" === u ? "height" : "width"; o = l[u]; var O = l[u] + r[g], M = l[u] - r[y], j = i ? -m[w] / 2 : 0, E = "start" === f ? d[w] : m[w]; f = "start" === f ? -m[w] : -d[w], m = t.elements.arrow, m = i && m ? c(m) : { width: 0, height: 0 }; var D = t.modifiersData["arrow#persistent"] ? t.modifiersData["arrow#persistent"].padding : { top: 0, right: 0, bottom: 0, left: 0 }; g = D[g], y = D[y], m = Math.max(0, Math.min(d[w], m[w])), E = p ? d[w] / 2 - j - m - g - v : E - m - g - v, p = p ? -d[w] / 2 + j + m + y + v : f + m + y + v, v = t.elements.arrow && h(t.elements.arrow), d = t.modifiersData.offset ? t.modifiersData.offset[t.placement][u] : 0, v = l[u] + E - d - (v ? "y" === u ? v.clientTop || 0 : v.clientLeft || 0 : 0), p = l[u] + p - d, i = Math.max(i ? Math.min(O, v) : O, Math.min(o, i ? Math.max(M, p) : M)), l[u] = i, s[u] = i - o } n && (n = l[a], i = Math.max(n + r["x" === u ? "top" : "left"], Math.min(n, n - r["x" === u ? "bottom" : "right"])), l[a] = i, s[a] = i - n), t.modifiersData[e] = s } }, requiresIfExists: ["offset"] }, { name: "arrow", enabled: !0, phase: "main", fn: function (e) { var t, r = e.state; e = e.name; var n = r.elements.arrow, o = r.modifiersData.popperOffsets, i = b(r.placement), a = x(i); if (i = 0 <= ["left", "right"].indexOf(i) ? "height" : "width", n && o) { var s = r.modifiersData[e + "#persistent"].padding; n = c(n); var f = "y" === a ? "top" : "left", p = "y" === a ? "bottom" : "right", u = r.rects.reference[i] + r.rects.reference[a] - o[a] - r.rects.popper[i]; o = o[a] - r.rects.reference[a]; var l = r.elements.arrow && h(r.elements.arrow); u = (l = l ? "y" === a ? l.clientHeight || 0 : l.clientWidth || 0 : 0) / 2 - n[i] / 2 + (u / 2 - o / 2), i = Math.max(s[f], Math.min(u, l - n[i] - s[p])), r.modifiersData[e] = ((t = {})[a] = i, t.centerOffset = i - u, t) } }, effect: function (e) { var t = e.state, r = e.options; e = e.name; var n = r.element; if (n = void 0 === n ? "[data-popper-arrow]" : n, r = void 0 === (r = r.padding) ? 0 : r, null != n) { if ("string" == typeof n && !(n = t.elements.popper.querySelector(n))) return; D(t.elements.popper, n) && (t.elements.arrow = n, t.modifiersData[e + "#persistent"] = { padding: B("number" != typeof r ? r : W(r, R)) }) } }, requires: ["popperOffsets"], requiresIfExists: ["preventOverflow"] }, { name: "hide", enabled: !0, phase: "main", requiresIfExists: ["preventOverflow"], fn: function (e) { var t = e.state; e = e.name; var r = t.rects.reference, n = t.rects.popper, o = t.modifiersData.preventOverflow, i = H(t, { elementContext: "reference" }), a = H(t, { altBoundary: !0 }); r = T(i, r), n = T(a, n, o), o = A(r), a = A(n), t.modifiersData[e] = { referenceClippingOffsets: r, popperEscapeOffsets: n, isReferenceHidden: o, hasPopperEscaped: a }, t.attributes.popper = Object.assign({}, t.attributes.popper, { "data-popper-reference-hidden": o, "data-popper-escaped": a }) } }], z = w({ defaultModifiers: U }); e.createPopper = z, e.defaultModifiers = U, e.detectOverflow = H, e.popperGenerator = w, Object.defineProperty(e, "__esModule", { value: !0 }) })); -window.BlazorTablePopper = (reference, popper, arrow, placement) => { - Popper.createPopper(reference, popper, { - placement, - strategy: 'fixed', - modifiers: [ - { - name: 'arrow', - options: { - element: arrow, - }, - }, - { - name: 'preventOverflow' - }, - ], - }); - - return true; -}; \ No newline at end of file +window.BlazorTablePopper = (reference, popper, arrow, placement) => { Popper.createPopper(reference, popper, { placement, modifiers: [{ name: 'arrow', options: { element: arrow, }, }, { name: 'preventOverflow' },], }); return !0 } \ No newline at end of file From c0c6f48147ad7cba44b42b68d2355d6981b48084 Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Sun, 3 May 2020 17:17:08 -0700 Subject: [PATCH 06/13] Added Page Size Selector --- .../Pages/Index.razor | 3 +-- src/BlazorTable/Components/Pager.razor | 15 +++++++++++-- src/BlazorTable/Components/Pager.razor.cs | 22 +++++++++++++++++++ src/BlazorTable/Components/Table.razor | 4 +--- src/BlazorTable/Components/Table.razor.cs | 12 +++++++++- src/BlazorTable/Interfaces/ITable.cs | 6 +++++ 6 files changed, 54 insertions(+), 8 deletions(-) diff --git a/src/BlazorTable.Sample.Shared/Pages/Index.razor b/src/BlazorTable.Sample.Shared/Pages/Index.razor index 2ce94f0a..b1c0c2c2 100644 --- a/src/BlazorTable.Sample.Shared/Pages/Index.razor +++ b/src/BlazorTable.Sample.Shared/Pages/Index.razor @@ -63,7 +63,7 @@ - + @code @@ -92,7 +92,6 @@ /// Returns row CSS if price over 800 /// public string RowClass => price.GetValueOrDefault(0) > 800 ? "table-danger" : null; - } public enum CreditCard diff --git a/src/BlazorTable/Components/Pager.razor b/src/BlazorTable/Components/Pager.razor index 9a96f1c1..8ad1e370 100644 --- a/src/BlazorTable/Components/Pager.razor +++ b/src/BlazorTable/Components/Pager.razor @@ -4,6 +4,17 @@ {
    + @if (ShowPageSizes) + { +
  • + +
  • + } @if (ShowPageNumber) {
  • @@ -16,7 +27,7 @@ @Table.TotalCount
  • } - @if ((ShowPageNumber || ShowTotalCount)) + @if (ShowPageNumber || ShowTotalCount) {
  • First
  • -
  • +
  • Previous
  • diff --git a/src/BlazorTable/Components/Pager.razor.cs b/src/BlazorTable/Components/Pager.razor.cs index f6f9eeca..15d0c296 100644 --- a/src/BlazorTable/Components/Pager.razor.cs +++ b/src/BlazorTable/Components/Pager.razor.cs @@ -1,4 +1,6 @@ using Microsoft.AspNetCore.Components; +using System.Collections.Generic; +using System.Threading; namespace BlazorTable { @@ -27,5 +29,25 @@ public partial class Pager /// [Parameter] public bool ShowTotalCount { get; set; } + + /// + /// Page size options + /// + [Parameter] + public List PageSizes { get; set; } = new List() { 15, 30, 60 }; + + /// + /// Show Page Size Options + /// + [Parameter] + public bool ShowPageSizes { get; set; } + + private void SetPageSize(ChangeEventArgs args) + { + if (int.TryParse(args.Value.ToString(), out int result)) + { + Table.SetPageSize(result); + } + } } } diff --git a/src/BlazorTable/Components/Table.razor b/src/BlazorTable/Components/Table.razor index 9466cc0d..acba89e0 100644 --- a/src/BlazorTable/Components/Table.razor +++ b/src/BlazorTable/Components/Table.razor @@ -18,11 +18,9 @@ - @if (_detailTemplate != null) { - - + } @foreach (IColumn column in Columns) { diff --git a/src/BlazorTable/Components/Table.razor.cs b/src/BlazorTable/Components/Table.razor.cs index c6701deb..fbcdc684 100644 --- a/src/BlazorTable/Components/Table.razor.cs +++ b/src/BlazorTable/Components/Table.razor.cs @@ -325,7 +325,7 @@ public void SetEmptyDataTemplate(EmptyDataTemplate emptyDataTemplate) } private RenderFragment _emptyDataTemplate; - + /// /// Set the template to use for loading data /// @@ -456,5 +456,15 @@ private Expression> GlobalSearchQuery(string value) /// [Parameter] public bool ShowSearchBar { get; set; } + + /// + /// Set Table Page Size + /// + /// + public void SetPageSize(int pageSize) + { + PageSize = pageSize; + Update(); + } } } diff --git a/src/BlazorTable/Interfaces/ITable.cs b/src/BlazorTable/Interfaces/ITable.cs index d2634276..21cfbe5d 100644 --- a/src/BlazorTable/Interfaces/ITable.cs +++ b/src/BlazorTable/Interfaces/ITable.cs @@ -112,5 +112,11 @@ public interface ITable /// Shows Search Bar above the table /// bool ShowSearchBar { get; set; } + + /// + /// Set Table Page Size + /// + /// + void SetPageSize(int pageSize); } } \ No newline at end of file From bc3f6b9665e78f99d377d3a777e38f15b8a52b86 Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Sun, 3 May 2020 17:19:21 -0700 Subject: [PATCH 07/13] Updated to Blazor RC1 --- .../BlazorTable.Sample.Shared.csproj | 2 +- src/BlazorTable.Sample.Wasm/BlazorTable.Sample.Wasm.csproj | 6 +++--- src/BlazorTable.Tests/BlazorTable.Tests.csproj | 2 +- src/BlazorTable/BlazorTable.csproj | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/BlazorTable.Sample.Shared/BlazorTable.Sample.Shared.csproj b/src/BlazorTable.Sample.Shared/BlazorTable.Sample.Shared.csproj index 0bf52e24..190bc859 100644 --- a/src/BlazorTable.Sample.Shared/BlazorTable.Sample.Shared.csproj +++ b/src/BlazorTable.Sample.Shared/BlazorTable.Sample.Shared.csproj @@ -9,7 +9,7 @@ - + diff --git a/src/BlazorTable.Sample.Wasm/BlazorTable.Sample.Wasm.csproj b/src/BlazorTable.Sample.Wasm/BlazorTable.Sample.Wasm.csproj index e47270e1..8ec93d1a 100644 --- a/src/BlazorTable.Sample.Wasm/BlazorTable.Sample.Wasm.csproj +++ b/src/BlazorTable.Sample.Wasm/BlazorTable.Sample.Wasm.csproj @@ -6,9 +6,9 @@ - - - + + + diff --git a/src/BlazorTable.Tests/BlazorTable.Tests.csproj b/src/BlazorTable.Tests/BlazorTable.Tests.csproj index 3d3b137d..7d5014d2 100644 --- a/src/BlazorTable.Tests/BlazorTable.Tests.csproj +++ b/src/BlazorTable.Tests/BlazorTable.Tests.csproj @@ -7,7 +7,7 @@ - + diff --git a/src/BlazorTable/BlazorTable.csproj b/src/BlazorTable/BlazorTable.csproj index d518ea4d..39756968 100644 --- a/src/BlazorTable/BlazorTable.csproj +++ b/src/BlazorTable/BlazorTable.csproj @@ -25,7 +25,7 @@ - + all runtime; build; native; contentfiles; analyzers; buildtransitive From 2dab2317e34182efb033df174075d55e5aa280c5 Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Sun, 3 May 2020 17:47:03 -0700 Subject: [PATCH 08/13] added bug 114 repro --- src/BlazorTable.Sample.Shared/Bugs/114.razor | 56 ++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 src/BlazorTable.Sample.Shared/Bugs/114.razor diff --git a/src/BlazorTable.Sample.Shared/Bugs/114.razor b/src/BlazorTable.Sample.Shared/Bugs/114.razor new file mode 100644 index 00000000..7e60fce4 --- /dev/null +++ b/src/BlazorTable.Sample.Shared/Bugs/114.razor @@ -0,0 +1,56 @@ +@page "/114" + +@using BlazorTable + + + + +
    + + + + +
    + + + + +@code +{ + [Inject] + private HttpClient Http { get; set; } + + private PersonData[] data; + + protected override async Task OnInitializedAsync() + { + data = await Http.GetFromJsonAsync("sample-data/MOCK_DATA.json"); + } + + public class PersonData + { + public int? id { get; set; } + public string full_name { get; set; } + public string email { get; set; } + public bool? paid { get; set; } + public decimal? price { get; set; } + public CreditCard? cc_type { get; set; } + public DateTime? created_date { get; set; } + } + + public enum CreditCard + { + none = 0, + [Description("MasterCard")] + MasterCard = 1, + Visa = 2 + } + + private void HandleClick() + { + + } +} \ No newline at end of file From e68ffd90cafd46e96a29bc60c0ba180be06e96f7 Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Sun, 3 May 2020 19:57:08 -0700 Subject: [PATCH 09/13] fixed bug --- src/BlazorTable/Components/Pager.razor | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/BlazorTable/Components/Pager.razor b/src/BlazorTable/Components/Pager.razor index 8ad1e370..db0b9b47 100644 --- a/src/BlazorTable/Components/Pager.razor +++ b/src/BlazorTable/Components/Pager.razor @@ -37,7 +37,7 @@
  • First
  • -
  • +
  • Previous
  • From f856c063d538934eb78e7f8636b7fbb1990df217 Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Sun, 3 May 2020 20:01:53 -0700 Subject: [PATCH 10/13] Updated url --- src/BlazorTable/BlazorTable.csproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/BlazorTable/BlazorTable.csproj b/src/BlazorTable/BlazorTable.csproj index 39756968..b2e5e243 100644 --- a/src/BlazorTable/BlazorTable.csproj +++ b/src/BlazorTable/BlazorTable.csproj @@ -8,7 +8,7 @@ BlazorTable Blazor Table Component with Sorting, Paging and Filtering Ivan Josipovic - https://BlazorTable.netlify.com + https://BlazorTable.netlify.app Blazor;Table;Component;Grid;DataTable;Data;Sort;Filter;AspNetCore;AspNet icon.png https://github.com/IvanJosipovic/BlazorTable From 0f0bd3a613ddc9b454fc043ddb6e09ea19b56005 Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Sun, 3 May 2020 20:06:36 -0700 Subject: [PATCH 11/13] Fix for bug 114 --- src/BlazorTable/Components/Table.razor | 15 +++++++++------ src/BlazorTable/Components/Table.razor.cs | 9 ++++++--- 2 files changed, 15 insertions(+), 9 deletions(-) diff --git a/src/BlazorTable/Components/Table.razor b/src/BlazorTable/Components/Table.razor index acba89e0..83010050 100644 --- a/src/BlazorTable/Components/Table.razor +++ b/src/BlazorTable/Components/Table.razor @@ -39,9 +39,9 @@ @if (column.SortColumn) { if (column.SortDescending) - { } + { } else - { } + { } } @if (column.Filterable) @@ -86,12 +86,15 @@ { - @{int locali = i;} + @{ + int locali = i; + bool isOpen = detailsViewOpen.ContainsKey(locali) && detailsViewOpen[locali]; + } @if (_detailTemplate != null) { - - @(detailsViewOpen[locali] ? "➖" : "➕") + + @(isOpen ? "➖" : "➕") } @@ -113,7 +116,7 @@ } - if (_detailTemplate != null && detailsViewOpen[locali]) + if (_detailTemplate != null && isOpen) { diff --git a/src/BlazorTable/Components/Table.razor.cs b/src/BlazorTable/Components/Table.razor.cs index fbcdc684..fde77adc 100644 --- a/src/BlazorTable/Components/Table.razor.cs +++ b/src/BlazorTable/Components/Table.razor.cs @@ -165,14 +165,13 @@ private IEnumerable GetData() return Items; } - private bool[] detailsViewOpen; + private Dictionary detailsViewOpen = new Dictionary(); /// /// Gets Data and redraws the Table /// public void Update() { - detailsViewOpen = new bool[PageSize]; FilteredItems = GetData(); Refresh(); } @@ -212,6 +211,7 @@ public void FirstPage() if (PageNumber != 0) { PageNumber = 0; + detailsViewOpen.Clear(); Update(); } } @@ -224,6 +224,7 @@ public void NextPage() if (PageNumber + 1 < TotalPages) { PageNumber++; + detailsViewOpen.Clear(); Update(); } } @@ -236,6 +237,7 @@ public void PreviousPage() if (PageNumber > 0) { PageNumber--; + detailsViewOpen.Clear(); Update(); } } @@ -246,6 +248,7 @@ public void PreviousPage() public void LastPage() { PageNumber = TotalPages - 1; + detailsViewOpen.Clear(); Update(); } @@ -464,7 +467,7 @@ private Expression> GlobalSearchQuery(string value) public void SetPageSize(int pageSize) { PageSize = pageSize; - Update(); + Refresh(); } } } From 34c6945e6bcc3a6e31b35562b9481135a4a5a01e Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Sun, 3 May 2020 20:08:31 -0700 Subject: [PATCH 12/13] Fixed regression --- src/BlazorTable/Components/Table.razor.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/BlazorTable/Components/Table.razor.cs b/src/BlazorTable/Components/Table.razor.cs index fde77adc..23cb87b1 100644 --- a/src/BlazorTable/Components/Table.razor.cs +++ b/src/BlazorTable/Components/Table.razor.cs @@ -467,7 +467,7 @@ private Expression> GlobalSearchQuery(string value) public void SetPageSize(int pageSize) { PageSize = pageSize; - Refresh(); + Update(); } } } From 50769b260325422fdd11f70d93d0c0f043e4eb82 Mon Sep 17 00:00:00 2001 From: Ivan Josipovic <9521987+IvanJosipovic@users.noreply.github.com> Date: Sun, 3 May 2020 20:56:12 -0700 Subject: [PATCH 13/13] Replaced ASCII with images --- src/BlazorTable/Components/Table.razor | 21 ++++++++++++------- src/BlazorTable/wwwroot/images/filter.png | Bin 0 -> 435 bytes src/BlazorTable/wwwroot/images/minus.png | Bin 0 -> 185 bytes src/BlazorTable/wwwroot/images/plus.png | Bin 0 -> 420 bytes src/BlazorTable/wwwroot/images/sort-asc.png | Bin 0 -> 286 bytes src/BlazorTable/wwwroot/images/sort-desc.png | Bin 0 -> 285 bytes 6 files changed, 13 insertions(+), 8 deletions(-) create mode 100644 src/BlazorTable/wwwroot/images/filter.png create mode 100644 src/BlazorTable/wwwroot/images/minus.png create mode 100644 src/BlazorTable/wwwroot/images/plus.png create mode 100644 src/BlazorTable/wwwroot/images/sort-asc.png create mode 100644 src/BlazorTable/wwwroot/images/sort-desc.png diff --git a/src/BlazorTable/Components/Table.razor b/src/BlazorTable/Components/Table.razor index 83010050..1113bbe4 100644 --- a/src/BlazorTable/Components/Table.razor +++ b/src/BlazorTable/Components/Table.razor @@ -39,16 +39,18 @@ @if (column.SortColumn) { if (column.SortDescending) - { } + { } else - { } + { } } @if (column.Filterable) { @@ -94,7 +96,10 @@ { - @(isOpen ? "➖" : "➕") + @if (isOpen) + {} + else + {} } @@ -107,11 +112,11 @@ @if (IsEditMode && column.EditTemplate != null) @column.EditTemplate(item) - else - if (column.Template == null) + else + if (column.Template == null) @column.Render(item) - else - @column.Template(item) + else + @column.Template(item) } diff --git a/src/BlazorTable/wwwroot/images/filter.png b/src/BlazorTable/wwwroot/images/filter.png new file mode 100644 index 0000000000000000000000000000000000000000..39dc6c8eafce5c7455a6510dab28805273683086 GIT binary patch literal 435 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!60wlNoGJgf6SkfJR9T^xl_H+M9WCijSl0AZa z85pY67#JE_7#My5g&JNkFq9fFFuY1&V6d9Oz#v{QXIG#NP=YDR+uenMVO6iP5s=4O z;1OBOz`%C|gc+x5^GO2**-JcqUD=vpGOpiL2^4Ddba4#PIKTCjAs=I)h}*+{ zgS8P&hqO#K3zivlOIQc4$T`3zVy3vvS#=j@rIciT#p2?;qVE4PTn~?n^1QM7dQU)Y zooB7_*QAL&&y=pkS1mqzV&PKlWcf39r2kIv-jLH2H0g}1z?{_g8|7KIDzCWmvO(Z) z%7h2@2Ul9(k2?AF(M!%WujmJ#-Yzopr0P&}bB>(^b literal 0 HcmV?d00001 diff --git a/src/BlazorTable/wwwroot/images/minus.png b/src/BlazorTable/wwwroot/images/minus.png new file mode 100644 index 0000000000000000000000000000000000000000..00d6f0d1e6ab57d43a33900da9fac6ff2d017cc4 GIT binary patch literal 185 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|SkfJR9T^xl z_H+M9WCij$3p^r=85sDEfH31!Z9ZwBpr5CUV~B-+vIJ{0g8|bUet~CWK*PBX*?TXl7l@cE0iQ#NLLkrb)jf4NgsVaJt_( zr_C%zmccgCBdmFOh2{sb%D)P1<>K-BYzax6CuKe>HyQlfnpO<)aBk&y6ekT}x#Fhk*32vCj6Lf#|y9WQzOU=}#N zc;(^D1ELc|#P-Ph$_9vdGI$>1?AQ#Hw2bz zkn|E}F)@B1K1Gc~gOAy5Nku!eo12>e>#5GI3Ty%mB8{JpiKl#3D2?ECU<){0z`(}F ZFlGC>o7==ytbopE@O1TaS?83{1OO`2S|b1e literal 0 HcmV?d00001 diff --git a/src/BlazorTable/wwwroot/images/sort-desc.png b/src/BlazorTable/wwwroot/images/sort-desc.png new file mode 100644 index 0000000000000000000000000000000000000000..ba6d88227d7ca2231faaa2be7daa14293e9c75fa GIT binary patch literal 285 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|SkfJR9T^xl z_H+M9WCij$3p^r=85sDEfH31!Z9ZwB;3iKO#}EtuM*=w*yzc{pvQb;fr(?o>4yCQvlJH0 zWOQjhnB5>OFxzoPK?3)YG66Lq2R{i9&L>