@sheetxl/studio-vanilla 0.3.5 → 0.3.7
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/browser/cjs/{CvESC6HiL0-peppq.cjs → 3Z5ZVyA4M3n9q9T5.cjs} +4 -4
- package/browser/cjs/3rqWL42XEv7Zqb32.cjs +6 -0
- package/browser/cjs/{DKit140jXAUUSf-_.cjs → B1YWrCVgU7Kmnm1T.cjs} +2 -2
- package/browser/cjs/{D7NgrO__M-IUmM8o.cjs → BCU2ws0EwyUhMfyT.cjs} +1 -1
- package/browser/cjs/{BwocMiKAPb8s__1Z.cjs → BOV2jjPfpuXBZAW7.cjs} +2 -2
- package/browser/cjs/{BNtn_2pcq6Dd-2HL.cjs → BmhVFpv9CfTQVTjI.cjs} +3 -3
- package/browser/cjs/{CuY7mAREmYhHuYWx.cjs → BsMm_Huxnau2vwTD.cjs} +2 -2
- package/browser/cjs/{6e91IXsvk9_k3W5c.cjs → C-QeKeBTOY15puEV.cjs} +2 -2
- package/browser/cjs/{BW_fZwvTtMLqteuJ.cjs → C33i51TmHf4SHKrk.cjs} +1 -1
- package/browser/cjs/{Biyqj-Wu75uxLHv1.cjs → C3VTtTsAWlGWi885.cjs} +2 -2
- package/browser/cjs/{yvA5FY7oe6FILMqB.cjs → C7hVKc9K7iuGRIL7.cjs} +1 -1
- package/browser/cjs/{DCWZ2ZkLp-Horeca.cjs → CJJnLrYPa7KMRsHb.cjs} +1 -1
- package/browser/cjs/COHiox3mogLWfFMx.cjs +301 -0
- package/browser/cjs/{BiiW2FlRZHxGIWso.cjs → CRbPjo0Nd1eBuNIW.cjs} +1 -1
- package/browser/cjs/{BLHbDre9R0bvyb9G.cjs → CcUeWbB8gJ2hYZ0t.cjs} +2 -2
- package/browser/cjs/{DIawrhwQ7E_1l99b.cjs → CeLUWiIQ6znvqNGl.cjs} +6 -6
- package/browser/cjs/{qjPE6k7aYlu-R90s.cjs → Cp0Tq3YIgLuqFBEQ.cjs} +2 -2
- package/browser/cjs/{-aNm3r-RpjcRRCbw.cjs → CqQeZ0R_l-gQXaQx.cjs} +2 -2
- package/browser/cjs/{DeAt9vyyaeB2vbxQ.cjs → DNIUbptETcIIsG7h.cjs} +2 -2
- package/browser/cjs/{CdWBtYv7LuuDLPL2.cjs → DNomiR3OWZad9wQS.cjs} +1 -1
- package/browser/cjs/DOn5sCCoip2vELe9.cjs +19 -0
- package/browser/cjs/{Bg9KIoDuqtkhIYfN.cjs → DPDH_CuXvPlEStyU.cjs} +1 -1
- package/browser/cjs/{hSI9QVPgIxqt3pXc.cjs → DQuuY3WVgI5hH9Sc.cjs} +1 -1
- package/browser/cjs/{Ya4f5p9go_UndgNy.cjs → DtXRdjx-n_RIyAdz.cjs} +2 -2
- package/browser/cjs/{DKsZXMMHWKP9IZ4E.cjs → fE77FrBh8QMuUNxk.cjs} +1 -1
- package/browser/cjs/{BN0MiwKQ8NjKXgue.cjs → g35lb9qfQ7H4ytKa.cjs} +3 -3
- package/browser/cjs/index.cjs +2 -2
- package/browser/esm/{DDD5zfwNNPKuc_zZ.mjs → 1pCNUoxFKepRuyfa.mjs} +1 -1
- package/browser/esm/{CLTP12OHGQ2k4_Kt.mjs → B7vV_BImqZyJbVxt.mjs} +3 -3
- package/{cdn/assets/BzptX9H_YCM2l0DE.js → browser/esm/BJvTXvPtfJHHEwCI.mjs} +5 -5
- package/browser/esm/{BLsIMzjofsOnRFrU.mjs → BL-MGLoZVjIZRC8f.mjs} +6 -6
- package/browser/esm/BNrrWDYFBvlrgKLr.mjs +46 -0
- package/browser/esm/{ChMaIhqaEhF3SLLt.mjs → BY7jrGTT-6LIotvc.mjs} +7 -7
- package/browser/esm/{DFa_tXqv1VN1OZdv.mjs → BasVdd3zd4rzMJ3z.mjs} +17 -17
- package/browser/esm/{Btk74VwCVJ1T5LQD.mjs → BemHnQ5HC0MMwwpk.mjs} +3 -3
- package/{cdn/assets/mq5uPzTIc1x8unBP.js → browser/esm/Bvw4Wd4QZWwHwySN.mjs} +1 -1
- package/{cdn/assets/Did46-x6ZVwk_-r-.js → browser/esm/CARuwR8LCkOqbEvg.mjs} +1 -1
- package/browser/esm/{D0-tgawYa4KXYT2c.mjs → CHXrslW6QpPqYlQJ.mjs} +2 -2
- package/{cdn/assets/CvFAAktSd9TQK1h4.js → browser/esm/CNzhDDB3GbcIr1f1.mjs} +1 -1
- package/{cdn/assets/Bs-psXrTRw1jFety.js → browser/esm/CYOe-PNU1ddwNZxf.mjs} +8 -8
- package/browser/esm/{D244UwY3qPC_LNc5.mjs → Cgzk91uNsHby3_Xq.mjs} +2 -2
- package/browser/esm/{DdrICyX8Ead15N32.mjs → ClwDPpKvrRbivt_C.mjs} +1 -1
- package/{cdn/assets/DXMyzCcyP7039z13.js → browser/esm/DKgnlbWYgEPNFHp4.mjs} +799 -796
- package/browser/esm/DMgXE7S--oWb9q_g.mjs +22 -0
- package/browser/esm/{DJxioSY-hxyM7dmk.mjs → DSAItP5tyetml0Nl.mjs} +3 -3
- package/{cdn/assets/F-RqJeKWiW4i5344.js → browser/esm/Dh_t4LKcuJndwsWc.mjs} +10475 -10290
- package/browser/esm/{Q1yWEkJBu4cVEF33.mjs → Dm-FdeP6gtNunE-O.mjs} +6 -6
- package/{cdn/assets/CsVV_QnEl77BQM3V.js → browser/esm/F7X6GD2vCOnG9bfS.mjs} +1 -1
- package/{cdn/assets/C8omEbSXHWI_wNjp.js → browser/esm/FtQ1ejKmzNzLipib.mjs} +8 -8
- package/browser/esm/{CPWh2H15145LP-d5.mjs → dPSQKKcoZdfzlSna.mjs} +1 -1
- package/browser/esm/{CAm14rTtmPL5-rvQ.mjs → gPrNWR3Q7AraDNA8.mjs} +125 -125
- package/{cdn/assets/DCuLWmzd9eLWgI03.js → browser/esm/ggsYdlbjeTopGPhi.mjs} +1 -1
- package/{cdn/assets/C60KakDbde-A4anI.js → browser/esm/hZL13mv_yL17yqpF.mjs} +1 -1
- package/browser/esm/index.mjs +2 -2
- package/cdn/assets/{DDD5zfwNNPKuc_zZ.js → 1pCNUoxFKepRuyfa.js} +1 -1
- package/cdn/assets/{NHbXgEQMftGzY01r.js → B8qc1imSfDsRgnKK.js} +3 -3
- package/{browser/esm/CntwHkPpskE88Ixu.mjs → cdn/assets/BHYIY8ekfU8GIx-v.js} +5 -5
- package/{browser/esm/mq5uPzTIc1x8unBP.mjs → cdn/assets/Bvw4Wd4QZWwHwySN.js} +1 -1
- package/cdn/assets/{DLYF-18qErpwF9Q-.js → C0q06BpM_YiTdvYY.js} +6 -6
- package/{browser/esm/Did46-x6ZVwk_-r-.mjs → cdn/assets/CARuwR8LCkOqbEvg.js} +1 -1
- package/{browser/esm/Di2tNceI3NodSsgU.mjs → cdn/assets/CFDj1TcgC6DrzkQU.js} +8 -8
- package/{browser/esm/CvFAAktSd9TQK1h4.mjs → cdn/assets/CNzhDDB3GbcIr1f1.js} +1 -1
- package/cdn/assets/Cb8SYExA8SBt8-a7.js +22 -0
- package/cdn/assets/{Cz33L9W3cdQckAL5.js → CgJM1Sr8R1PNImSR.js} +3 -3
- package/cdn/assets/{CEXK9SXjFf1dGHZe.js → ClbAQfGnO0nqDI3Z.js} +6 -6
- package/cdn/assets/{DdrICyX8Ead15N32.js → ClwDPpKvrRbivt_C.js} +1 -1
- package/cdn/assets/{DBgbBl_3O65WhfWN.js → D7SAqf3XrQ0v7mGH.js} +7 -7
- package/cdn/assets/{BOl7blN8JotSzCHJ.js → DAOPH9ojNmrcS6Lb.js} +2 -2
- package/cdn/assets/{ClFGbVy7cnhMW-dO.js → DFfcguJ0tQZoGOZc.js} +2 -2
- package/cdn/assets/{CoCIP7n4THmzOggq.js → DIXOHjZSHBv_HKpE.js} +17 -17
- package/{browser/esm/BTQ-TGJnw7w1Y0CX.mjs → cdn/assets/DiomQ_bqytYxNeaP.js} +8 -8
- package/cdn/assets/{B41q92oKD_VR31Dd.js → Dkkb9tE81Tx0AvXw.js} +3 -3
- package/{browser/esm/CsVV_QnEl77BQM3V.mjs → cdn/assets/F7X6GD2vCOnG9bfS.js} +1 -1
- package/{browser/esm/CYXzmWJtZn5OJVBF.mjs → cdn/assets/UTibqrn6UrrGPGLU.js} +9723 -9844
- package/cdn/assets/{CPWh2H15145LP-d5.js → dPSQKKcoZdfzlSna.js} +1 -1
- package/{browser/esm/DCuLWmzd9eLWgI03.mjs → cdn/assets/ggsYdlbjeTopGPhi.js} +1 -1
- package/{browser/esm/C60KakDbde-A4anI.mjs → cdn/assets/hZL13mv_yL17yqpF.js} +1 -1
- package/{browser/esm/BdLAPrmXIfjGFhhA.mjs → cdn/assets/kLAnuk6Hj3XXu7B_.js} +799 -796
- package/cdn/assets/l2XreUqHdSx2sK06.js +46 -0
- package/cdn/assets/{Dj3GhNedlKE9TeTn.js → mjbXH-pivN9OKW3k.js} +125 -125
- package/cdn/index.js +8 -8
- package/cdn/loader.js +1 -1
- package/package.json +8 -8
- package/browser/cjs/Cxt39d6l0pu9k1vT.cjs +0 -19
- package/browser/cjs/DDhq2nYMdw5b7wP6.cjs +0 -301
- package/browser/cjs/Dkl2t2DSaDxPbm2V.cjs +0 -6
- package/browser/esm/BsDYj6xix3mlXry2.mjs +0 -46
- package/browser/esm/wziCLl5xvHu6Guu_.mjs +0 -22
- package/cdn/assets/C_E1C68wCcRpC6XN.js +0 -46
- package/cdn/assets/lM5it-aJgI7DLNH9.js +0 -22
|
@@ -1,187 +1,190 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import {
|
|
1
|
+
import { jsx as H, jsxs as We } from "react/jsx-runtime";
|
|
2
|
+
import { f as to, g as oo, u as no, m as ro, n as io, aT as Q, o as lo, q as so, aU as ao, aV as co, c as Z, aA as uo, aB as ho, av as wt, Q as fo, B as he, a as po, aF as mo, a0 as go, a2 as vo, ay as fe, at as _o, au as So, _ as yo, aW as wo, aX as Co, aY as De, aZ as xo, a_ as Ro, a$ as bo, J as ye, b0 as To, b1 as zo, b2 as K, b3 as Io, b4 as V, b5 as Po } from "./UTibqrn6UrrGPGLU.js";
|
|
3
3
|
import * as x from "react";
|
|
4
|
-
import
|
|
5
|
-
import { f as N } from "./
|
|
4
|
+
import Ct, { useState as pe, useMemo as ko, useEffect as je, cloneElement as Oo } from "react";
|
|
5
|
+
import { f as N } from "./mjbXH-pivN9OKW3k.js";
|
|
6
6
|
/**
|
|
7
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.3.
|
|
7
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.3.7
|
|
8
8
|
*
|
|
9
9
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
10
10
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
11
11
|
*/
|
|
12
|
-
const
|
|
13
|
-
function
|
|
14
|
-
return
|
|
12
|
+
const Mo = x.createContext(), Lo = x.createContext();
|
|
13
|
+
function Go(o) {
|
|
14
|
+
return oo("MuiTableCell", o);
|
|
15
15
|
}
|
|
16
|
-
const
|
|
16
|
+
const Ao = to("MuiTableCell", ["root", "head", "body", "footer", "sizeSmall", "sizeMedium", "paddingCheckbox", "paddingNone", "alignLeft", "alignCenter", "alignRight", "alignJustify", "stickyHeader"]), Eo = ro("td", { name: "MuiTableCell", slot: "Root", overridesResolver: (o, e) => {
|
|
17
17
|
const { ownerState: t } = o;
|
|
18
|
-
return [e.root, e[t.variant], e[`size${
|
|
19
|
-
} })(
|
|
20
|
-
${o.palette.mode === "light" ?
|
|
21
|
-
const t =
|
|
22
|
-
let
|
|
23
|
-
|
|
24
|
-
let
|
|
25
|
-
|
|
26
|
-
const S = d || u && u.variant, y = { ...t, align: n, component:
|
|
27
|
-
const { classes:
|
|
28
|
-
return
|
|
18
|
+
return [e.root, e[t.variant], e[`size${Q(t.size)}`], t.padding !== "normal" && e[`padding${Q(t.padding)}`], t.align !== "inherit" && e[`align${Q(t.align)}`], t.stickyHeader && e.stickyHeader];
|
|
19
|
+
} })(so(({ theme: o }) => ({ ...o.typography.body2, display: "table-cell", verticalAlign: "inherit", borderBottom: o.vars ? `1px solid ${o.vars.palette.TableCell.border}` : `1px solid
|
|
20
|
+
${o.palette.mode === "light" ? ao(Z(o.palette.divider, 1), 0.88) : co(Z(o.palette.divider, 1), 0.68)}`, textAlign: "left", padding: 16, variants: [{ props: { variant: "head" }, style: { color: (o.vars || o).palette.text.primary, lineHeight: o.typography.pxToRem(24), fontWeight: o.typography.fontWeightMedium } }, { props: { variant: "body" }, style: { color: (o.vars || o).palette.text.primary } }, { props: { variant: "footer" }, style: { color: (o.vars || o).palette.text.secondary, lineHeight: o.typography.pxToRem(21), fontSize: o.typography.pxToRem(12) } }, { props: { size: "small" }, style: { padding: "6px 16px", [`&.${Ao.paddingCheckbox}`]: { width: 24, padding: "0 12px 0 16px", "& > *": { padding: 0 } } } }, { props: { padding: "checkbox" }, style: { width: 48, padding: "0 0 0 4px" } }, { props: { padding: "none" }, style: { padding: 0 } }, { props: { align: "left" }, style: { textAlign: "left" } }, { props: { align: "center" }, style: { textAlign: "center" } }, { props: { align: "right" }, style: { textAlign: "right", flexDirection: "row-reverse" } }, { props: { align: "justify" }, style: { textAlign: "justify" } }, { props: ({ ownerState: e }) => e.stickyHeader, style: { position: "sticky", top: 0, zIndex: 2, backgroundColor: (o.vars || o).palette.background.default } }] }))), Fe = x.forwardRef(function(o, e) {
|
|
21
|
+
const t = no({ props: o, name: "MuiTableCell" }), { align: n = "inherit", className: r, component: l, padding: i, scope: a, size: s, sortDirection: c, variant: d, ...h } = t, f = x.useContext(Mo), u = x.useContext(Lo), v = u && u.variant === "head";
|
|
22
|
+
let m;
|
|
23
|
+
m = l || (v ? "th" : "td");
|
|
24
|
+
let _ = a;
|
|
25
|
+
m === "td" ? _ = void 0 : !_ && v && (_ = "col");
|
|
26
|
+
const S = d || u && u.variant, y = { ...t, align: n, component: m, padding: i || (f && f.padding ? f.padding : "normal"), size: s || (f && f.size ? f.size : "medium"), sortDirection: c, stickyHeader: S === "head" && f && f.stickyHeader, variant: S }, g = ((C) => {
|
|
27
|
+
const { classes: b, variant: R, align: z, padding: I, size: k, stickyHeader: P } = C, T = { root: ["root", R, P && "stickyHeader", z !== "inherit" && `align${Q(z)}`, I !== "normal" && `padding${Q(I)}`, `size${Q(k)}`] };
|
|
28
|
+
return lo(T, Go, b);
|
|
29
29
|
})(y);
|
|
30
|
-
let
|
|
31
|
-
return c && (
|
|
32
|
-
}),
|
|
33
|
-
function
|
|
30
|
+
let w = null;
|
|
31
|
+
return c && (w = c === "asc" ? "ascending" : "descending"), H(Eo, { as: m, ref: e, className: io(g.root, r), "aria-sort": w, scope: _, ownerState: y, ...h });
|
|
32
|
+
}), Ho = wo();
|
|
33
|
+
function we(o) {
|
|
34
34
|
return o !== "ownerState" && o !== "theme" && o !== "sx" && o !== "as";
|
|
35
35
|
}
|
|
36
|
-
function
|
|
36
|
+
function q(o, e) {
|
|
37
|
+
return e && o && typeof o == "object" && o.styles && !o.styles.startsWith("@layer") && (o.styles = `@layer ${e}{${String(o.styles)}}`), o;
|
|
38
|
+
}
|
|
39
|
+
function Wo(o) {
|
|
37
40
|
return o ? (e, t) => t[o] : null;
|
|
38
41
|
}
|
|
39
|
-
function
|
|
40
|
-
const
|
|
41
|
-
if (Array.isArray(
|
|
42
|
-
if (Array.isArray(
|
|
43
|
-
let
|
|
44
|
-
if (
|
|
42
|
+
function ve(o, e, t) {
|
|
43
|
+
const n = typeof e == "function" ? e(o) : e;
|
|
44
|
+
if (Array.isArray(n)) return n.flatMap((r) => ve(o, r, t));
|
|
45
|
+
if (Array.isArray(n?.variants)) {
|
|
46
|
+
let r;
|
|
47
|
+
if (n.isProcessed) r = t ? q(n.style, t) : n.style;
|
|
45
48
|
else {
|
|
46
|
-
const { variants:
|
|
47
|
-
|
|
49
|
+
const { variants: l, ...i } = n;
|
|
50
|
+
r = t ? q(K(i), t) : i;
|
|
48
51
|
}
|
|
49
|
-
return
|
|
52
|
+
return xt(o, n.variants, [r], t);
|
|
50
53
|
}
|
|
51
|
-
return
|
|
54
|
+
return n?.isProcessed ? t ? q(K(n.style), t) : n.style : t ? q(K(n), t) : n;
|
|
52
55
|
}
|
|
53
|
-
function
|
|
54
|
-
let
|
|
55
|
-
e: for (let
|
|
56
|
-
const i = e[
|
|
56
|
+
function xt(o, e, t = [], n = void 0) {
|
|
57
|
+
let r;
|
|
58
|
+
e: for (let l = 0; l < e.length; l += 1) {
|
|
59
|
+
const i = e[l];
|
|
57
60
|
if (typeof i.props == "function") {
|
|
58
|
-
if (
|
|
59
|
-
} else for (const
|
|
60
|
-
typeof i.style == "function" ? (
|
|
61
|
+
if (r ??= { ...o, ...o.ownerState, ownerState: o.ownerState }, !i.props(r)) continue;
|
|
62
|
+
} else for (const a in i.props) if (o[a] !== i.props[a] && o.ownerState?.[a] !== i.props[a]) continue e;
|
|
63
|
+
typeof i.style == "function" ? (r ??= { ...o, ...o.ownerState, ownerState: o.ownerState }, t.push(n ? q(K(i.style(r)), n) : i.style(r))) : t.push(n ? q(K(i.style), n) : i.style);
|
|
61
64
|
}
|
|
62
65
|
return t;
|
|
63
66
|
}
|
|
64
|
-
function
|
|
67
|
+
function Do(o) {
|
|
65
68
|
return o && o.charAt(0).toLowerCase() + o.slice(1);
|
|
66
69
|
}
|
|
67
|
-
const
|
|
68
|
-
const { themeId: e, defaultTheme: t =
|
|
69
|
-
function i
|
|
70
|
+
const jo = function(o = {}) {
|
|
71
|
+
const { themeId: e, defaultTheme: t = Ho, rootShouldForwardProp: n = we, slotShouldForwardProp: r = we } = o;
|
|
72
|
+
function l(i) {
|
|
70
73
|
var a, s, c;
|
|
71
|
-
s = e, c = t, (a =
|
|
74
|
+
s = e, c = t, (a = i).theme = function(d) {
|
|
72
75
|
for (const h in d) return !1;
|
|
73
76
|
return !0;
|
|
74
77
|
}(a.theme) ? c : a.theme[s] || a.theme;
|
|
75
78
|
}
|
|
76
|
-
return (
|
|
77
|
-
|
|
78
|
-
const { name: s, slot: c, skipVariantsResolver: d, skipSx: h, overridesResolver: f =
|
|
79
|
-
let
|
|
80
|
-
var
|
|
81
|
-
c === "Root" || c === "root" ?
|
|
82
|
-
const
|
|
83
|
-
if (
|
|
84
|
-
if (typeof
|
|
85
|
-
return
|
|
79
|
+
return (i, a = {}) => {
|
|
80
|
+
Co(i, (b) => b.filter((R) => R !== De));
|
|
81
|
+
const { name: s, slot: c, skipVariantsResolver: d, skipSx: h, overridesResolver: f = Wo(Do(c)), ...u } = a, v = s && s.startsWith("Mui") || c ? "components" : "custom", m = d !== void 0 ? d : c && c !== "Root" && c !== "root" || !1, _ = h || !1;
|
|
82
|
+
let S = we;
|
|
83
|
+
var y;
|
|
84
|
+
c === "Root" || c === "root" ? S = n : c ? S = r : typeof (y = i) == "string" && y.charCodeAt(0) > 96 && (S = void 0);
|
|
85
|
+
const g = xo(i, { shouldForwardProp: S, label: void 0, ...u }), w = (b) => {
|
|
86
|
+
if (b.__emotion_real === b) return b;
|
|
87
|
+
if (typeof b == "function") return function(R) {
|
|
88
|
+
return ve(R, b, R.theme.modularCssLayers ? v : void 0);
|
|
86
89
|
};
|
|
87
|
-
if (
|
|
88
|
-
const R = function(
|
|
89
|
-
const { variants:
|
|
90
|
-
return
|
|
91
|
-
typeof
|
|
92
|
-
}),
|
|
93
|
-
}(
|
|
94
|
-
return
|
|
95
|
-
return
|
|
96
|
-
}
|
|
90
|
+
if (zo(b)) {
|
|
91
|
+
const R = function(z) {
|
|
92
|
+
const { variants: I, ...k } = z, P = { variants: I, style: K(k), isProcessed: !0 };
|
|
93
|
+
return P.style === k || I && I.forEach((T) => {
|
|
94
|
+
typeof T.style != "function" && (T.style = K(T.style));
|
|
95
|
+
}), P;
|
|
96
|
+
}(b);
|
|
97
|
+
return function(z) {
|
|
98
|
+
return R.variants ? ve(z, R, z.theme.modularCssLayers ? v : void 0) : z.theme.modularCssLayers ? q(R.style, v) : R.style;
|
|
99
|
+
};
|
|
97
100
|
}
|
|
98
|
-
return
|
|
99
|
-
}, C = (...
|
|
100
|
-
const R = [],
|
|
101
|
-
if (R.push(
|
|
102
|
-
const
|
|
103
|
-
if (!
|
|
104
|
-
const
|
|
105
|
-
for (const
|
|
106
|
-
return f(
|
|
107
|
-
}), s && !
|
|
108
|
-
const
|
|
109
|
-
return
|
|
110
|
-
}),
|
|
111
|
-
const
|
|
112
|
-
let
|
|
113
|
-
|
|
101
|
+
return b;
|
|
102
|
+
}, C = (...b) => {
|
|
103
|
+
const R = [], z = b.map(w), I = [];
|
|
104
|
+
if (R.push(l), s && f && I.push(function(T) {
|
|
105
|
+
const L = T.theme, G = L.components?.[s]?.styleOverrides;
|
|
106
|
+
if (!G) return null;
|
|
107
|
+
const B = {};
|
|
108
|
+
for (const He in G) B[He] = ve(T, G[He], T.theme.modularCssLayers ? "theme" : void 0);
|
|
109
|
+
return f(T, B);
|
|
110
|
+
}), s && !m && I.push(function(T) {
|
|
111
|
+
const L = T.theme, G = L?.components?.[s]?.variants;
|
|
112
|
+
return G ? xt(T, G, [], T.theme.modularCssLayers ? "theme" : void 0) : null;
|
|
113
|
+
}), _ || I.push(De), Array.isArray(z[0])) {
|
|
114
|
+
const T = z.shift(), L = new Array(R.length).fill(""), G = new Array(I.length).fill("");
|
|
115
|
+
let B;
|
|
116
|
+
B = [...L, ...T, ...G], B.raw = [...L, ...T.raw, ...G], R.unshift(B);
|
|
114
117
|
}
|
|
115
|
-
const
|
|
116
|
-
return
|
|
118
|
+
const k = [...R, ...z, ...I], P = g(...k);
|
|
119
|
+
return i.muiName && (P.muiName = i.muiName), P;
|
|
117
120
|
};
|
|
118
|
-
return
|
|
121
|
+
return g.withConfig && (C.withConfig = g.withConfig), C;
|
|
119
122
|
};
|
|
120
|
-
}({ themeId:
|
|
123
|
+
}({ themeId: Ro, defaultTheme: bo, rootShouldForwardProp: (o) => /* @__PURE__ */ function(e) {
|
|
121
124
|
return e !== "ownerState" && e !== "theme" && e !== "sx" && e !== "as";
|
|
122
125
|
}(o) && o !== "classes" });
|
|
123
|
-
function
|
|
126
|
+
function A(o, e) {
|
|
124
127
|
if (!(o instanceof e)) throw new TypeError("Cannot call a class as a function");
|
|
125
128
|
}
|
|
126
|
-
function
|
|
127
|
-
return (
|
|
129
|
+
function ee(o) {
|
|
130
|
+
return (ee = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(e) {
|
|
128
131
|
return typeof e;
|
|
129
132
|
} : function(e) {
|
|
130
133
|
return e && typeof Symbol == "function" && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
|
|
131
134
|
})(o);
|
|
132
135
|
}
|
|
133
|
-
function
|
|
136
|
+
function Rt(o) {
|
|
134
137
|
var e = function(t) {
|
|
135
|
-
if (
|
|
138
|
+
if (ee(t) != "object" || !t) return t;
|
|
136
139
|
var n = t[Symbol.toPrimitive];
|
|
137
140
|
if (n !== void 0) {
|
|
138
141
|
var r = n.call(t, "string");
|
|
139
|
-
if (
|
|
142
|
+
if (ee(r) != "object") return r;
|
|
140
143
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
141
144
|
}
|
|
142
145
|
return String(t);
|
|
143
146
|
}(o);
|
|
144
|
-
return
|
|
147
|
+
return ee(e) == "symbol" ? e : e + "";
|
|
145
148
|
}
|
|
146
|
-
function
|
|
149
|
+
function Ne(o, e) {
|
|
147
150
|
for (var t = 0; t < e.length; t++) {
|
|
148
151
|
var n = e[t];
|
|
149
|
-
n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(o,
|
|
152
|
+
n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(o, Rt(n.key), n);
|
|
150
153
|
}
|
|
151
154
|
}
|
|
152
|
-
function
|
|
153
|
-
return e &&
|
|
155
|
+
function E(o, e, t) {
|
|
156
|
+
return e && Ne(o.prototype, e), t && Ne(o, t), Object.defineProperty(o, "prototype", { writable: !1 }), o;
|
|
154
157
|
}
|
|
155
158
|
function W(o, e) {
|
|
156
|
-
if (e && (
|
|
159
|
+
if (e && (ee(e) == "object" || typeof e == "function")) return e;
|
|
157
160
|
if (e !== void 0) throw new TypeError("Derived constructors may only return object or undefined");
|
|
158
161
|
return function(t) {
|
|
159
162
|
if (t === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
160
163
|
return t;
|
|
161
164
|
}(o);
|
|
162
165
|
}
|
|
163
|
-
function
|
|
164
|
-
return (
|
|
166
|
+
function O(o) {
|
|
167
|
+
return (O = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(e) {
|
|
165
168
|
return e.__proto__ || Object.getPrototypeOf(e);
|
|
166
169
|
})(o);
|
|
167
170
|
}
|
|
168
171
|
function D(o, e) {
|
|
169
172
|
if (typeof e != "function" && e !== null) throw new TypeError("Super expression must either be null or a function");
|
|
170
|
-
o.prototype = Object.create(e && e.prototype, { constructor: { value: o, writable: !0, configurable: !0 } }), Object.defineProperty(o, "prototype", { writable: !1 }), e &&
|
|
173
|
+
o.prototype = Object.create(e && e.prototype, { constructor: { value: o, writable: !0, configurable: !0 } }), Object.defineProperty(o, "prototype", { writable: !1 }), e && Io(o, e);
|
|
171
174
|
}
|
|
172
175
|
function p(o, e, t) {
|
|
173
|
-
return (e =
|
|
176
|
+
return (e = Rt(e)) in o ? Object.defineProperty(o, e, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : o[e] = t, o;
|
|
174
177
|
}
|
|
175
|
-
function
|
|
178
|
+
function bt() {
|
|
176
179
|
var o = this.constructor.getDerivedStateFromProps(this.props, this.state);
|
|
177
180
|
o != null && this.setState(o);
|
|
178
181
|
}
|
|
179
|
-
function
|
|
182
|
+
function Tt(o) {
|
|
180
183
|
this.setState(function(e) {
|
|
181
184
|
return this.constructor.getDerivedStateFromProps(o, e) ?? null;
|
|
182
185
|
}.bind(this));
|
|
183
186
|
}
|
|
184
|
-
function
|
|
187
|
+
function zt(o, e) {
|
|
185
188
|
try {
|
|
186
189
|
var t = this.props, n = this.state;
|
|
187
190
|
this.props = o, this.state = e, this.__reactInternalSnapshotFlag = !0, this.__reactInternalSnapshot = this.getSnapshotBeforeUpdate(t, n);
|
|
@@ -189,16 +192,16 @@ function bt(o, e) {
|
|
|
189
192
|
this.props = t, this.state = n;
|
|
190
193
|
}
|
|
191
194
|
}
|
|
192
|
-
function
|
|
195
|
+
function ue(o) {
|
|
193
196
|
var e = o.prototype;
|
|
194
197
|
if (!e || !e.isReactComponent) throw new Error("Can only polyfill class components");
|
|
195
198
|
if (typeof o.getDerivedStateFromProps != "function" && typeof e.getSnapshotBeforeUpdate != "function") return o;
|
|
196
199
|
var t = null, n = null, r = null;
|
|
197
200
|
if (typeof e.componentWillMount == "function" ? t = "componentWillMount" : typeof e.UNSAFE_componentWillMount == "function" && (t = "UNSAFE_componentWillMount"), typeof e.componentWillReceiveProps == "function" ? n = "componentWillReceiveProps" : typeof e.UNSAFE_componentWillReceiveProps == "function" && (n = "UNSAFE_componentWillReceiveProps"), typeof e.componentWillUpdate == "function" ? r = "componentWillUpdate" : typeof e.UNSAFE_componentWillUpdate == "function" && (r = "UNSAFE_componentWillUpdate"), t !== null || n !== null || r !== null) {
|
|
198
|
-
var
|
|
201
|
+
var l = o.displayName || o.name, i = typeof o.getDerivedStateFromProps == "function" ? "getDerivedStateFromProps()" : "getSnapshotBeforeUpdate()";
|
|
199
202
|
throw Error(`Unsafe legacy lifecycles will not be called for components using new component APIs.
|
|
200
203
|
|
|
201
|
-
` +
|
|
204
|
+
` + l + " uses " + i + " but also contains the following legacy lifecycles:" + (t !== null ? `
|
|
202
205
|
` + t : "") + (n !== null ? `
|
|
203
206
|
` + n : "") + (r !== null ? `
|
|
204
207
|
` + r : "") + `
|
|
@@ -206,9 +209,9 @@ function ce(o) {
|
|
|
206
209
|
The above lifecycles should be removed. Learn more about this warning here:
|
|
207
210
|
https://fb.me/react-async-component-lifecycle-hooks`);
|
|
208
211
|
}
|
|
209
|
-
if (typeof o.getDerivedStateFromProps == "function" && (e.componentWillMount =
|
|
212
|
+
if (typeof o.getDerivedStateFromProps == "function" && (e.componentWillMount = bt, e.componentWillReceiveProps = Tt), typeof e.getSnapshotBeforeUpdate == "function") {
|
|
210
213
|
if (typeof e.componentDidUpdate != "function") throw new Error("Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype");
|
|
211
|
-
e.componentWillUpdate =
|
|
214
|
+
e.componentWillUpdate = zt;
|
|
212
215
|
var a = e.componentDidUpdate;
|
|
213
216
|
e.componentDidUpdate = function(s, c, d) {
|
|
214
217
|
var h = this.__reactInternalSnapshotFlag ? this.__reactInternalSnapshot : d;
|
|
@@ -217,7 +220,7 @@ https://fb.me/react-async-component-lifecycle-hooks`);
|
|
|
217
220
|
}
|
|
218
221
|
return o;
|
|
219
222
|
}
|
|
220
|
-
function
|
|
223
|
+
function Be(o, e) {
|
|
221
224
|
var t = Object.keys(o);
|
|
222
225
|
if (Object.getOwnPropertySymbols) {
|
|
223
226
|
var n = Object.getOwnPropertySymbols(o);
|
|
@@ -227,40 +230,40 @@ function Fe(o, e) {
|
|
|
227
230
|
}
|
|
228
231
|
return t;
|
|
229
232
|
}
|
|
230
|
-
function
|
|
233
|
+
function Ue(o) {
|
|
231
234
|
for (var e = 1; e < arguments.length; e++) {
|
|
232
235
|
var t = arguments[e] != null ? arguments[e] : {};
|
|
233
|
-
e % 2 ?
|
|
236
|
+
e % 2 ? Be(Object(t), !0).forEach(function(n) {
|
|
234
237
|
p(o, n, t[n]);
|
|
235
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) :
|
|
238
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) : Be(Object(t)).forEach(function(n) {
|
|
236
239
|
Object.defineProperty(o, n, Object.getOwnPropertyDescriptor(t, n));
|
|
237
240
|
});
|
|
238
241
|
}
|
|
239
242
|
return o;
|
|
240
243
|
}
|
|
241
|
-
function
|
|
244
|
+
function It() {
|
|
242
245
|
try {
|
|
243
246
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
244
247
|
}));
|
|
245
248
|
} catch {
|
|
246
249
|
}
|
|
247
|
-
return (
|
|
250
|
+
return (It = function() {
|
|
248
251
|
return !!o;
|
|
249
252
|
})();
|
|
250
253
|
}
|
|
251
|
-
|
|
252
|
-
var
|
|
254
|
+
bt.__suppressDeprecationWarning = !0, Tt.__suppressDeprecationWarning = !0, zt.__suppressDeprecationWarning = !0;
|
|
255
|
+
var Ve = function() {
|
|
253
256
|
function o() {
|
|
254
257
|
var e, t, n, r;
|
|
255
|
-
|
|
256
|
-
for (var
|
|
257
|
-
return t = this, n = o, r = [].concat(
|
|
258
|
+
A(this, o);
|
|
259
|
+
for (var l = arguments.length, i = new Array(l), a = 0; a < l; a++) i[a] = arguments[a];
|
|
260
|
+
return t = this, n = o, r = [].concat(i), n = O(n), p(e = W(t, It() ? Reflect.construct(n, r || [], O(t).constructor) : n.apply(t, r)), "state", { scrollToColumn: 0, scrollToRow: 0, instanceProps: { prevScrollToColumn: 0, prevScrollToRow: 0 } }), p(e, "_columnStartIndex", 0), p(e, "_columnStopIndex", 0), p(e, "_rowStartIndex", 0), p(e, "_rowStopIndex", 0), p(e, "_onKeyDown", function(s) {
|
|
258
261
|
var c = e.props, d = c.columnCount, h = c.disabled, f = c.mode, u = c.rowCount;
|
|
259
262
|
if (!h) {
|
|
260
|
-
var
|
|
263
|
+
var v = e._getScrollState(), m = v.scrollToColumn, _ = v.scrollToRow, S = e._getScrollState(), y = S.scrollToColumn, g = S.scrollToRow;
|
|
261
264
|
switch (s.key) {
|
|
262
265
|
case "ArrowDown":
|
|
263
|
-
|
|
266
|
+
g = Math.min(f === "cells" ? g + 1 : e._rowStopIndex + 1, u - 1);
|
|
264
267
|
break;
|
|
265
268
|
case "ArrowLeft":
|
|
266
269
|
y = Math.max(f === "cells" ? y - 1 : e._columnStartIndex - 1, 0);
|
|
@@ -269,96 +272,96 @@ var Be = function() {
|
|
|
269
272
|
y = Math.min(f === "cells" ? y + 1 : e._columnStopIndex + 1, d - 1);
|
|
270
273
|
break;
|
|
271
274
|
case "ArrowUp":
|
|
272
|
-
|
|
275
|
+
g = Math.max(f === "cells" ? g - 1 : e._rowStartIndex - 1, 0);
|
|
273
276
|
}
|
|
274
|
-
y ===
|
|
277
|
+
y === m && g === _ || (s.preventDefault(), e._updateScrollState({ scrollToColumn: y, scrollToRow: g }));
|
|
275
278
|
}
|
|
276
279
|
}), p(e, "_onSectionRendered", function(s) {
|
|
277
280
|
var c = s.columnStartIndex, d = s.columnStopIndex, h = s.rowStartIndex, f = s.rowStopIndex;
|
|
278
281
|
e._columnStartIndex = c, e._columnStopIndex = d, e._rowStartIndex = h, e._rowStopIndex = f;
|
|
279
282
|
}), e;
|
|
280
283
|
}
|
|
281
|
-
return D(o, x.PureComponent),
|
|
284
|
+
return D(o, x.PureComponent), E(o, [{ key: "setScrollIndexes", value: function(e) {
|
|
282
285
|
var t = e.scrollToColumn, n = e.scrollToRow;
|
|
283
286
|
this.setState({ scrollToRow: n, scrollToColumn: t });
|
|
284
287
|
} }, { key: "render", value: function() {
|
|
285
|
-
var e = this.props, t = e.className, n = e.children, r = this._getScrollState(),
|
|
286
|
-
return x.createElement("div", { className: t, onKeyDown: this._onKeyDown }, n({ onSectionRendered: this._onSectionRendered, scrollToColumn:
|
|
288
|
+
var e = this.props, t = e.className, n = e.children, r = this._getScrollState(), l = r.scrollToColumn, i = r.scrollToRow;
|
|
289
|
+
return x.createElement("div", { className: t, onKeyDown: this._onKeyDown }, n({ onSectionRendered: this._onSectionRendered, scrollToColumn: l, scrollToRow: i }));
|
|
287
290
|
} }, { key: "_getScrollState", value: function() {
|
|
288
291
|
return this.props.isControlled ? this.props : this.state;
|
|
289
292
|
} }, { key: "_updateScrollState", value: function(e) {
|
|
290
|
-
var t = e.scrollToColumn, n = e.scrollToRow, r = this.props,
|
|
291
|
-
typeof
|
|
293
|
+
var t = e.scrollToColumn, n = e.scrollToRow, r = this.props, l = r.isControlled, i = r.onScrollToChange;
|
|
294
|
+
typeof i == "function" && i({ scrollToColumn: t, scrollToRow: n }), l || this.setState({ scrollToColumn: t, scrollToRow: n });
|
|
292
295
|
} }], [{ key: "getDerivedStateFromProps", value: function(e, t) {
|
|
293
|
-
return e.isControlled ? {} : e.scrollToColumn !== t.instanceProps.prevScrollToColumn || e.scrollToRow !== t.instanceProps.prevScrollToRow ?
|
|
296
|
+
return e.isControlled ? {} : e.scrollToColumn !== t.instanceProps.prevScrollToColumn || e.scrollToRow !== t.instanceProps.prevScrollToRow ? Ue(Ue({}, t), {}, { scrollToColumn: e.scrollToColumn, scrollToRow: e.scrollToRow, instanceProps: { prevScrollToColumn: e.scrollToColumn, prevScrollToRow: e.scrollToRow } }) : {};
|
|
294
297
|
} }]);
|
|
295
298
|
}();
|
|
296
|
-
function
|
|
299
|
+
function Pt(o, e) {
|
|
297
300
|
var t, n, r = (t = e !== void 0 ? e : typeof window < "u" ? window : typeof self < "u" ? self : global).document !== void 0 && t.document.attachEvent;
|
|
298
301
|
if (!r) {
|
|
299
|
-
var
|
|
300
|
-
return t.setTimeout(
|
|
301
|
-
}, function(
|
|
302
|
-
return n(
|
|
303
|
-
}),
|
|
304
|
-
var
|
|
305
|
-
return function(
|
|
306
|
-
return
|
|
302
|
+
var l = (n = t.requestAnimationFrame || t.mozRequestAnimationFrame || t.webkitRequestAnimationFrame || function(g) {
|
|
303
|
+
return t.setTimeout(g, 20);
|
|
304
|
+
}, function(g) {
|
|
305
|
+
return n(g);
|
|
306
|
+
}), i = function() {
|
|
307
|
+
var g = t.cancelAnimationFrame || t.mozCancelAnimationFrame || t.webkitCancelAnimationFrame || t.clearTimeout;
|
|
308
|
+
return function(w) {
|
|
309
|
+
return g(w);
|
|
307
310
|
};
|
|
308
|
-
}(), a = function(
|
|
309
|
-
var
|
|
310
|
-
|
|
311
|
-
}, s = function(
|
|
312
|
-
if (!(
|
|
313
|
-
var
|
|
314
|
-
a(this), this.__resizeRAF__ &&
|
|
315
|
-
var
|
|
316
|
-
((
|
|
317
|
-
|
|
311
|
+
}(), a = function(g) {
|
|
312
|
+
var w = g.__resizeTriggers__, C = w.firstElementChild, b = w.lastElementChild, R = C.firstElementChild;
|
|
313
|
+
b.scrollLeft = b.scrollWidth, b.scrollTop = b.scrollHeight, R.style.width = C.offsetWidth + 1 + "px", R.style.height = C.offsetHeight + 1 + "px", C.scrollLeft = C.scrollWidth, C.scrollTop = C.scrollHeight;
|
|
314
|
+
}, s = function(g) {
|
|
315
|
+
if (!(g.target.className && typeof g.target.className.indexOf == "function" && g.target.className.indexOf("contract-trigger") < 0 && g.target.className.indexOf("expand-trigger") < 0)) {
|
|
316
|
+
var w = this;
|
|
317
|
+
a(this), this.__resizeRAF__ && i(this.__resizeRAF__), this.__resizeRAF__ = l(function() {
|
|
318
|
+
var C;
|
|
319
|
+
((C = w).offsetWidth != C.__resizeLast__.width || C.offsetHeight != C.__resizeLast__.height) && (w.__resizeLast__.width = w.offsetWidth, w.__resizeLast__.height = w.offsetHeight, w.__resizeListeners__.forEach(function(b) {
|
|
320
|
+
b.call(w, g);
|
|
318
321
|
}));
|
|
319
322
|
});
|
|
320
323
|
}
|
|
321
|
-
}, c = !1, d = "", h = "animationstart", f = "Webkit Moz O ms".split(" "), u = "webkitAnimationStart animationstart oAnimationStart MSAnimationStart".split(" "),
|
|
322
|
-
if (
|
|
323
|
-
for (var
|
|
324
|
-
d = "-" + f[
|
|
324
|
+
}, c = !1, d = "", h = "animationstart", f = "Webkit Moz O ms".split(" "), u = "webkitAnimationStart animationstart oAnimationStart MSAnimationStart".split(" "), v = t.document.createElement("fakeelement");
|
|
325
|
+
if (v.style.animationName !== void 0 && (c = !0), c === !1) {
|
|
326
|
+
for (var m = 0; m < f.length; m++) if (v.style[f[m] + "AnimationName"] !== void 0) {
|
|
327
|
+
d = "-" + f[m].toLowerCase() + "-", h = u[m], c = !0;
|
|
325
328
|
break;
|
|
326
329
|
}
|
|
327
330
|
}
|
|
328
|
-
var
|
|
331
|
+
var _ = "resizeanim", S = "@" + d + "keyframes " + _ + " { from { opacity: 0; } to { opacity: 0; } } ", y = d + "animation: 1ms " + _ + "; ";
|
|
329
332
|
}
|
|
330
|
-
return { addResizeListener: function(
|
|
331
|
-
if (r)
|
|
333
|
+
return { addResizeListener: function(g, w) {
|
|
334
|
+
if (r) g.attachEvent("onresize", w);
|
|
332
335
|
else {
|
|
333
|
-
if (!
|
|
334
|
-
var
|
|
335
|
-
|
|
336
|
+
if (!g.__resizeTriggers__) {
|
|
337
|
+
var C = g.ownerDocument, b = t.getComputedStyle(g);
|
|
338
|
+
b && b.position == "static" && (g.style.position = "relative"), function(I) {
|
|
336
339
|
if (!I.getElementById("detectElementResize")) {
|
|
337
|
-
var
|
|
338
|
-
|
|
340
|
+
var k = (S || "") + ".resize-triggers { " + (y || "") + 'visibility: hidden; opacity: 0; } .resize-triggers, .resize-triggers > div, .contract-trigger:before { content: " "; display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; overflow: hidden; z-index: -1; } .resize-triggers > div { background: #eee; overflow: auto; } .contract-trigger:before { width: 200%; height: 200%; }', P = I.head || I.getElementsByTagName("head")[0], T = I.createElement("style");
|
|
341
|
+
T.id = "detectElementResize", T.type = "text/css", o != null && T.setAttribute("nonce", o), T.styleSheet ? T.styleSheet.cssText = k : T.appendChild(I.createTextNode(k)), P.appendChild(T);
|
|
339
342
|
}
|
|
340
|
-
}(
|
|
341
|
-
var
|
|
342
|
-
|
|
343
|
-
var
|
|
344
|
-
|
|
345
|
-
I.animationName ==
|
|
346
|
-
},
|
|
343
|
+
}(C), g.__resizeLast__ = {}, g.__resizeListeners__ = [], (g.__resizeTriggers__ = C.createElement("div")).className = "resize-triggers";
|
|
344
|
+
var R = C.createElement("div");
|
|
345
|
+
R.className = "expand-trigger", R.appendChild(C.createElement("div"));
|
|
346
|
+
var z = C.createElement("div");
|
|
347
|
+
z.className = "contract-trigger", g.__resizeTriggers__.appendChild(R), g.__resizeTriggers__.appendChild(z), g.appendChild(g.__resizeTriggers__), a(g), g.addEventListener("scroll", s, !0), h && (g.__resizeTriggers__.__animationListener__ = function(I) {
|
|
348
|
+
I.animationName == _ && a(g);
|
|
349
|
+
}, g.__resizeTriggers__.addEventListener(h, g.__resizeTriggers__.__animationListener__));
|
|
347
350
|
}
|
|
348
|
-
|
|
351
|
+
g.__resizeListeners__.push(w);
|
|
349
352
|
}
|
|
350
|
-
}, removeResizeListener: function(
|
|
351
|
-
if (r)
|
|
352
|
-
else if (
|
|
353
|
-
|
|
353
|
+
}, removeResizeListener: function(g, w) {
|
|
354
|
+
if (r) g.detachEvent("onresize", w);
|
|
355
|
+
else if (g.__resizeListeners__.splice(g.__resizeListeners__.indexOf(w), 1), !g.__resizeListeners__.length) {
|
|
356
|
+
g.removeEventListener("scroll", s, !0), g.__resizeTriggers__.__animationListener__ && (g.__resizeTriggers__.removeEventListener(h, g.__resizeTriggers__.__animationListener__), g.__resizeTriggers__.__animationListener__ = null);
|
|
354
357
|
try {
|
|
355
|
-
|
|
358
|
+
g.__resizeTriggers__ = !g.removeChild(g.__resizeTriggers__);
|
|
356
359
|
} catch {
|
|
357
360
|
}
|
|
358
361
|
}
|
|
359
362
|
} };
|
|
360
363
|
}
|
|
361
|
-
function
|
|
364
|
+
function $e(o, e) {
|
|
362
365
|
var t = Object.keys(o);
|
|
363
366
|
if (Object.getOwnPropertySymbols) {
|
|
364
367
|
var n = Object.getOwnPropertySymbols(o);
|
|
@@ -368,84 +371,84 @@ function Ue(o, e) {
|
|
|
368
371
|
}
|
|
369
372
|
return t;
|
|
370
373
|
}
|
|
371
|
-
function
|
|
374
|
+
function qe(o) {
|
|
372
375
|
for (var e = 1; e < arguments.length; e++) {
|
|
373
376
|
var t = arguments[e] != null ? arguments[e] : {};
|
|
374
|
-
e % 2 ?
|
|
377
|
+
e % 2 ? $e(Object(t), !0).forEach(function(n) {
|
|
375
378
|
p(o, n, t[n]);
|
|
376
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) :
|
|
379
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) : $e(Object(t)).forEach(function(n) {
|
|
377
380
|
Object.defineProperty(o, n, Object.getOwnPropertyDescriptor(t, n));
|
|
378
381
|
});
|
|
379
382
|
}
|
|
380
383
|
return o;
|
|
381
384
|
}
|
|
382
|
-
function
|
|
385
|
+
function kt() {
|
|
383
386
|
try {
|
|
384
387
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
385
388
|
}));
|
|
386
389
|
} catch {
|
|
387
390
|
}
|
|
388
|
-
return (
|
|
391
|
+
return (kt = function() {
|
|
389
392
|
return !!o;
|
|
390
393
|
})();
|
|
391
394
|
}
|
|
392
|
-
p(
|
|
393
|
-
var
|
|
395
|
+
p(Ve, "defaultProps", { disabled: !1, isControlled: !1, mode: "edges", scrollToColumn: 0, scrollToRow: 0 }), ue(Ve);
|
|
396
|
+
var Ot = function() {
|
|
394
397
|
function o() {
|
|
395
398
|
var e, t, n, r;
|
|
396
|
-
|
|
397
|
-
for (var
|
|
398
|
-
return t = this, n = o, r = [].concat(
|
|
399
|
+
A(this, o);
|
|
400
|
+
for (var l = arguments.length, i = new Array(l), a = 0; a < l; a++) i[a] = arguments[a];
|
|
401
|
+
return t = this, n = o, r = [].concat(i), n = O(n), p(e = W(t, kt() ? Reflect.construct(n, r || [], O(t).constructor) : n.apply(t, r)), "state", { height: e.props.defaultHeight || 0, width: e.props.defaultWidth || 0 }), p(e, "_parentNode", void 0), p(e, "_autoSizer", void 0), p(e, "_window", void 0), p(e, "_detectElementResize", void 0), p(e, "_onResize", function() {
|
|
399
402
|
var s = e.props, c = s.disableHeight, d = s.disableWidth, h = s.onResize;
|
|
400
403
|
if (e._parentNode) {
|
|
401
|
-
var f = e._parentNode.offsetHeight || 0, u = e._parentNode.offsetWidth || 0,
|
|
402
|
-
(!c && e.state.height !==
|
|
404
|
+
var f = e._parentNode.offsetHeight || 0, u = e._parentNode.offsetWidth || 0, v = (e._window || window).getComputedStyle(e._parentNode) || {}, m = parseInt(v.paddingLeft, 10) || 0, _ = parseInt(v.paddingRight, 10) || 0, S = parseInt(v.paddingTop, 10) || 0, y = parseInt(v.paddingBottom, 10) || 0, g = f - S - y, w = u - m - _;
|
|
405
|
+
(!c && e.state.height !== g || !d && e.state.width !== w) && (e.setState({ height: f - S - y, width: u - m - _ }), h({ height: f, width: u }));
|
|
403
406
|
}
|
|
404
407
|
}), p(e, "_setRef", function(s) {
|
|
405
408
|
e._autoSizer = s;
|
|
406
409
|
}), e;
|
|
407
410
|
}
|
|
408
|
-
return D(o, x.Component),
|
|
411
|
+
return D(o, x.Component), E(o, [{ key: "componentDidMount", value: function() {
|
|
409
412
|
var e = this.props.nonce;
|
|
410
|
-
this._autoSizer && this._autoSizer.parentNode && this._autoSizer.parentNode.ownerDocument && this._autoSizer.parentNode.ownerDocument.defaultView && this._autoSizer.parentNode instanceof this._autoSizer.parentNode.ownerDocument.defaultView.HTMLElement && (this._parentNode = this._autoSizer.parentNode, this._window = this._autoSizer.parentNode.ownerDocument.defaultView, this._detectElementResize =
|
|
413
|
+
this._autoSizer && this._autoSizer.parentNode && this._autoSizer.parentNode.ownerDocument && this._autoSizer.parentNode.ownerDocument.defaultView && this._autoSizer.parentNode instanceof this._autoSizer.parentNode.ownerDocument.defaultView.HTMLElement && (this._parentNode = this._autoSizer.parentNode, this._window = this._autoSizer.parentNode.ownerDocument.defaultView, this._detectElementResize = Pt(e, this._window), this._detectElementResize.addResizeListener(this._parentNode, this._onResize), this._onResize());
|
|
411
414
|
} }, { key: "componentWillUnmount", value: function() {
|
|
412
415
|
this._detectElementResize && this._parentNode && this._detectElementResize.removeResizeListener(this._parentNode, this._onResize);
|
|
413
416
|
} }, { key: "render", value: function() {
|
|
414
|
-
var e = this.props, t = e.children, n = e.className, r = e.disableHeight,
|
|
415
|
-
return r || (d.height = 0, h.height = s),
|
|
417
|
+
var e = this.props, t = e.children, n = e.className, r = e.disableHeight, l = e.disableWidth, i = e.style, a = this.state, s = a.height, c = a.width, d = { overflow: "visible" }, h = {};
|
|
418
|
+
return r || (d.height = 0, h.height = s), l || (d.width = 0, h.width = c), x.createElement("div", { className: n, ref: this._setRef, style: qe(qe({}, d), i) }, t(h));
|
|
416
419
|
} }]);
|
|
417
420
|
}();
|
|
418
|
-
function
|
|
421
|
+
function Mt() {
|
|
419
422
|
try {
|
|
420
423
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
421
424
|
}));
|
|
422
425
|
} catch {
|
|
423
426
|
}
|
|
424
|
-
return (
|
|
427
|
+
return (Mt = function() {
|
|
425
428
|
return !!o;
|
|
426
429
|
})();
|
|
427
430
|
}
|
|
428
|
-
p(
|
|
431
|
+
p(Ot, "defaultProps", { onResize: function() {
|
|
429
432
|
}, disableHeight: !1, disableWidth: !1, style: {} });
|
|
430
|
-
var
|
|
433
|
+
var Fo = function() {
|
|
431
434
|
function o() {
|
|
432
435
|
var e, t, n, r;
|
|
433
|
-
|
|
434
|
-
for (var
|
|
435
|
-
return t = this, n = o, r = [].concat(
|
|
436
|
-
var s = e.props, c = s.cache, d = s.columnIndex, h = d === void 0 ? 0 : d, f = s.parent, u = s.rowIndex,
|
|
437
|
-
|
|
436
|
+
A(this, o);
|
|
437
|
+
for (var l = arguments.length, i = new Array(l), a = 0; a < l; a++) i[a] = arguments[a];
|
|
438
|
+
return t = this, n = o, r = [].concat(i), n = O(n), p(e = W(t, Mt() ? Reflect.construct(n, r || [], O(t).constructor) : n.apply(t, r)), "_child", x.createRef()), p(e, "_measure", function() {
|
|
439
|
+
var s = e.props, c = s.cache, d = s.columnIndex, h = d === void 0 ? 0 : d, f = s.parent, u = s.rowIndex, v = u === void 0 ? e.props.index || 0 : u, m = e._getCellMeasurements(), _ = m.height, S = m.width;
|
|
440
|
+
_ === c.getHeight(v, h) && S === c.getWidth(v, h) || (c.set(v, h, S, _), f && typeof f.recomputeGridSize == "function" && f.recomputeGridSize({ columnIndex: h, rowIndex: v }));
|
|
438
441
|
}), p(e, "_registerChild", function(s) {
|
|
439
442
|
!s || s instanceof Element || console.warn("CellMeasurer registerChild expects to be passed Element or null"), e._child.current = s, s && e._maybeMeasureCell();
|
|
440
443
|
}), e;
|
|
441
444
|
}
|
|
442
|
-
return D(o, x.PureComponent),
|
|
445
|
+
return D(o, x.PureComponent), E(o, [{ key: "componentDidMount", value: function() {
|
|
443
446
|
this._maybeMeasureCell();
|
|
444
447
|
} }, { key: "componentDidUpdate", value: function() {
|
|
445
448
|
this._maybeMeasureCell();
|
|
446
449
|
} }, { key: "render", value: function() {
|
|
447
450
|
var e = this, t = this.props.children, n = typeof t == "function" ? t({ measure: this._measure, registerChild: this._registerChild }) : t;
|
|
448
|
-
return n === null ? n :
|
|
451
|
+
return n === null ? n : Oo(n, { ref: function(r) {
|
|
449
452
|
typeof n.ref == "function" ? n.ref(r) : n.ref && (n.ref.current = r), e._child.current = r;
|
|
450
453
|
} });
|
|
451
454
|
} }, { key: "_getCellMeasurements", value: function() {
|
|
@@ -453,42 +456,42 @@ var Do = function() {
|
|
|
453
456
|
if (t && t.ownerDocument && t.ownerDocument.defaultView && t instanceof t.ownerDocument.defaultView.HTMLElement) {
|
|
454
457
|
var n = t.style.width, r = t.style.height;
|
|
455
458
|
e.hasFixedWidth() || (t.style.width = "auto"), e.hasFixedHeight() || (t.style.height = "auto");
|
|
456
|
-
var
|
|
457
|
-
return n && (t.style.width = n), r && (t.style.height = r), { height:
|
|
459
|
+
var l = Math.ceil(t.offsetHeight), i = Math.ceil(t.offsetWidth);
|
|
460
|
+
return n && (t.style.width = n), r && (t.style.height = r), { height: l, width: i };
|
|
458
461
|
}
|
|
459
462
|
return { height: 0, width: 0 };
|
|
460
463
|
} }, { key: "_maybeMeasureCell", value: function() {
|
|
461
|
-
var e = this.props, t = e.cache, n = e.columnIndex, r = n === void 0 ? 0 : n,
|
|
464
|
+
var e = this.props, t = e.cache, n = e.columnIndex, r = n === void 0 ? 0 : n, l = e.parent, i = e.rowIndex, a = i === void 0 ? this.props.index || 0 : i;
|
|
462
465
|
if (!t.has(a, r)) {
|
|
463
466
|
var s = this._getCellMeasurements(), c = s.height, d = s.width;
|
|
464
|
-
t.set(a, r, d, c),
|
|
467
|
+
t.set(a, r, d, c), l && typeof l.invalidateCellSizeAfterRender == "function" && l.invalidateCellSizeAfterRender({ columnIndex: r, rowIndex: a });
|
|
465
468
|
}
|
|
466
469
|
} }]);
|
|
467
470
|
}();
|
|
468
|
-
function
|
|
471
|
+
function te() {
|
|
469
472
|
var o = !(arguments.length > 0 && arguments[0] !== void 0) || arguments[0], e = {};
|
|
470
473
|
return function(t) {
|
|
471
|
-
var n = t.callback, r = t.indices,
|
|
474
|
+
var n = t.callback, r = t.indices, l = Object.keys(r), i = !o || l.every(function(s) {
|
|
472
475
|
var c = r[s];
|
|
473
476
|
return Array.isArray(c) ? c.length > 0 : c >= 0;
|
|
474
|
-
}), a =
|
|
477
|
+
}), a = l.length !== Object.keys(e).length || l.some(function(s) {
|
|
475
478
|
var c = e[s], d = r[s];
|
|
476
479
|
return Array.isArray(d) ? c.join(",") !== d.join(",") : c !== d;
|
|
477
480
|
});
|
|
478
|
-
e = r,
|
|
481
|
+
e = r, i && a && n(r);
|
|
479
482
|
};
|
|
480
483
|
}
|
|
481
|
-
p(
|
|
482
|
-
const
|
|
483
|
-
var
|
|
484
|
-
function
|
|
485
|
-
if ((!
|
|
484
|
+
p(Fo, "__internalCellMeasurerFlag", !1);
|
|
485
|
+
const No = !(typeof window > "u" || !window.document || !window.document.createElement);
|
|
486
|
+
var me;
|
|
487
|
+
function Te(o) {
|
|
488
|
+
if ((!me && me !== 0 || o) && No) {
|
|
486
489
|
var e = document.createElement("div");
|
|
487
|
-
e.style.position = "absolute", e.style.top = "-9999px", e.style.width = "50px", e.style.height = "50px", e.style.overflow = "scroll", document.body.appendChild(e),
|
|
490
|
+
e.style.position = "absolute", e.style.top = "-9999px", e.style.width = "50px", e.style.height = "50px", e.style.overflow = "scroll", document.body.appendChild(e), me = e.offsetWidth - e.clientWidth, document.body.removeChild(e);
|
|
488
491
|
}
|
|
489
|
-
return
|
|
492
|
+
return me;
|
|
490
493
|
}
|
|
491
|
-
function
|
|
494
|
+
function Ke(o, e) {
|
|
492
495
|
var t = Object.keys(o);
|
|
493
496
|
if (Object.getOwnPropertySymbols) {
|
|
494
497
|
var n = Object.getOwnPropertySymbols(o);
|
|
@@ -498,100 +501,100 @@ function $e(o, e) {
|
|
|
498
501
|
}
|
|
499
502
|
return t;
|
|
500
503
|
}
|
|
501
|
-
function
|
|
504
|
+
function Xe(o) {
|
|
502
505
|
for (var e = 1; e < arguments.length; e++) {
|
|
503
506
|
var t = arguments[e] != null ? arguments[e] : {};
|
|
504
|
-
e % 2 ?
|
|
507
|
+
e % 2 ? Ke(Object(t), !0).forEach(function(n) {
|
|
505
508
|
p(o, n, t[n]);
|
|
506
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) :
|
|
509
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) : Ke(Object(t)).forEach(function(n) {
|
|
507
510
|
Object.defineProperty(o, n, Object.getOwnPropertyDescriptor(t, n));
|
|
508
511
|
});
|
|
509
512
|
}
|
|
510
513
|
return o;
|
|
511
514
|
}
|
|
512
|
-
function
|
|
515
|
+
function Lt() {
|
|
513
516
|
try {
|
|
514
517
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
515
518
|
}));
|
|
516
519
|
} catch {
|
|
517
520
|
}
|
|
518
|
-
return (
|
|
521
|
+
return (Lt = function() {
|
|
519
522
|
return !!o;
|
|
520
523
|
})();
|
|
521
524
|
}
|
|
522
|
-
var
|
|
525
|
+
var ne = "requested", _e = function() {
|
|
523
526
|
function o() {
|
|
524
527
|
var e, t, n, r;
|
|
525
|
-
|
|
526
|
-
for (var
|
|
527
|
-
return t = this, n = o, r = [].concat(
|
|
528
|
+
A(this, o);
|
|
529
|
+
for (var l = arguments.length, i = new Array(l), a = 0; a < l; a++) i[a] = arguments[a];
|
|
530
|
+
return t = this, n = o, r = [].concat(i), n = O(n), p(e = W(t, Lt() ? Reflect.construct(n, r || [], O(t).constructor) : n.apply(t, r)), "state", { isScrolling: !1, scrollLeft: 0, scrollTop: 0 }), p(e, "_calculateSizeAndPositionDataOnNextUpdate", !1), p(e, "_onSectionRenderedMemoizer", te()), p(e, "_onScrollMemoizer", te(!1)), p(e, "_invokeOnSectionRenderedHelper", function() {
|
|
528
531
|
var s = e.props, c = s.cellLayoutManager, d = s.onSectionRendered;
|
|
529
532
|
e._onSectionRenderedMemoizer({ callback: d, indices: { indices: c.getLastRenderedIndices() } });
|
|
530
533
|
}), p(e, "_setScrollingContainerRef", function(s) {
|
|
531
534
|
e._scrollingContainer = s;
|
|
532
535
|
}), p(e, "_updateScrollPositionForScrollToCell", function() {
|
|
533
|
-
var s = e.props, c = s.cellLayoutManager, d = s.height, h = s.scrollToAlignment, f = s.scrollToCell, u = s.width,
|
|
536
|
+
var s = e.props, c = s.cellLayoutManager, d = s.height, h = s.scrollToAlignment, f = s.scrollToCell, u = s.width, v = e.state, m = v.scrollLeft, _ = v.scrollTop;
|
|
534
537
|
if (f >= 0) {
|
|
535
|
-
var S = c.getScrollPositionForCell({ align: h, cellIndex: f, height: d, scrollLeft:
|
|
536
|
-
S.scrollLeft ===
|
|
538
|
+
var S = c.getScrollPositionForCell({ align: h, cellIndex: f, height: d, scrollLeft: m, scrollTop: _, width: u });
|
|
539
|
+
S.scrollLeft === m && S.scrollTop === _ || e._setScrollPosition(S);
|
|
537
540
|
}
|
|
538
541
|
}), p(e, "_onScroll", function(s) {
|
|
539
542
|
if (s.target === e._scrollingContainer) {
|
|
540
543
|
e._enablePointerEventsAfterDelay();
|
|
541
|
-
var c = e.props, d = c.cellLayoutManager, h = c.height, f = c.isScrollingChange, u = c.width,
|
|
542
|
-
if (e.state.scrollLeft !== y || e.state.scrollTop !==
|
|
543
|
-
var
|
|
544
|
-
e.state.isScrolling || f(!0), e.setState({ isScrolling: !0, scrollLeft: y, scrollPositionChangeReason:
|
|
544
|
+
var c = e.props, d = c.cellLayoutManager, h = c.height, f = c.isScrollingChange, u = c.width, v = e._scrollbarSize, m = d.getTotalSize(), _ = m.height, S = m.width, y = Math.max(0, Math.min(S - u + v, s.target.scrollLeft)), g = Math.max(0, Math.min(_ - h + v, s.target.scrollTop));
|
|
545
|
+
if (e.state.scrollLeft !== y || e.state.scrollTop !== g) {
|
|
546
|
+
var w = s.cancelable ? "observed" : ne;
|
|
547
|
+
e.state.isScrolling || f(!0), e.setState({ isScrolling: !0, scrollLeft: y, scrollPositionChangeReason: w, scrollTop: g });
|
|
545
548
|
}
|
|
546
|
-
e._invokeOnScrollMemoizer({ scrollLeft: y, scrollTop:
|
|
549
|
+
e._invokeOnScrollMemoizer({ scrollLeft: y, scrollTop: g, totalWidth: S, totalHeight: _ });
|
|
547
550
|
}
|
|
548
|
-
}), e._scrollbarSize =
|
|
551
|
+
}), e._scrollbarSize = Te(), e._scrollbarSize === void 0 ? (e._scrollbarSizeMeasured = !1, e._scrollbarSize = 0) : e._scrollbarSizeMeasured = !0, e;
|
|
549
552
|
}
|
|
550
|
-
return D(o, x.PureComponent),
|
|
553
|
+
return D(o, x.PureComponent), E(o, [{ key: "recomputeCellSizesAndPositions", value: function() {
|
|
551
554
|
this._calculateSizeAndPositionDataOnNextUpdate = !0, this.forceUpdate();
|
|
552
555
|
} }, { key: "componentDidMount", value: function() {
|
|
553
|
-
var e = this.props, t = e.cellLayoutManager, n = e.scrollLeft, r = e.scrollToCell,
|
|
554
|
-
this._scrollbarSizeMeasured || (this._scrollbarSize =
|
|
555
|
-
var
|
|
556
|
-
this._invokeOnScrollMemoizer({ scrollLeft: n || 0, scrollTop:
|
|
556
|
+
var e = this.props, t = e.cellLayoutManager, n = e.scrollLeft, r = e.scrollToCell, l = e.scrollTop;
|
|
557
|
+
this._scrollbarSizeMeasured || (this._scrollbarSize = Te(), this._scrollbarSizeMeasured = !0, this.setState({})), r >= 0 ? this._updateScrollPositionForScrollToCell() : (n >= 0 || l >= 0) && this._setScrollPosition({ scrollLeft: n, scrollTop: l }), this._invokeOnSectionRenderedHelper();
|
|
558
|
+
var i = t.getTotalSize(), a = i.height, s = i.width;
|
|
559
|
+
this._invokeOnScrollMemoizer({ scrollLeft: n || 0, scrollTop: l || 0, totalHeight: a, totalWidth: s });
|
|
557
560
|
} }, { key: "componentDidUpdate", value: function(e, t) {
|
|
558
|
-
var n = this.props, r = n.height,
|
|
559
|
-
d ===
|
|
561
|
+
var n = this.props, r = n.height, l = n.scrollToAlignment, i = n.scrollToCell, a = n.width, s = this.state, c = s.scrollLeft, d = s.scrollPositionChangeReason, h = s.scrollTop;
|
|
562
|
+
d === ne && (c >= 0 && c !== t.scrollLeft && c !== this._scrollingContainer.scrollLeft && (this._scrollingContainer.scrollLeft = c), h >= 0 && h !== t.scrollTop && h !== this._scrollingContainer.scrollTop && (this._scrollingContainer.scrollTop = h)), r === e.height && l === e.scrollToAlignment && i === e.scrollToCell && a === e.width || this._updateScrollPositionForScrollToCell(), this._invokeOnSectionRenderedHelper();
|
|
560
563
|
} }, { key: "componentWillUnmount", value: function() {
|
|
561
564
|
this._disablePointerEventsTimeoutId && clearTimeout(this._disablePointerEventsTimeoutId);
|
|
562
565
|
} }, { key: "render", value: function() {
|
|
563
|
-
var e = this.props, t = e.autoHeight, n = e.cellCount, r = e.cellLayoutManager,
|
|
566
|
+
var e = this.props, t = e.autoHeight, n = e.cellCount, r = e.cellLayoutManager, l = e.className, i = e.height, a = e.horizontalOverscanSize, s = e.id, c = e.noContentRenderer, d = e.style, h = e.verticalOverscanSize, f = e.width, u = this.state, v = u.isScrolling, m = u.scrollLeft, _ = u.scrollTop;
|
|
564
567
|
(this._lastRenderedCellCount !== n || this._lastRenderedCellLayoutManager !== r || this._calculateSizeAndPositionDataOnNextUpdate) && (this._lastRenderedCellCount = n, this._lastRenderedCellLayoutManager = r, this._calculateSizeAndPositionDataOnNextUpdate = !1, r.calculateSizeAndPositionData());
|
|
565
|
-
var S = r.getTotalSize(), y = S.height,
|
|
566
|
-
return I.overflowX =
|
|
568
|
+
var S = r.getTotalSize(), y = S.height, g = S.width, w = Math.max(0, m - a), C = Math.max(0, _ - h), b = Math.min(g, m + f + a), R = Math.min(y, _ + i + h), z = i > 0 && f > 0 ? r.cellRenderers({ height: R - C, isScrolling: v, width: b - w, x: w, y: C }) : [], I = { boxSizing: "border-box", direction: "ltr", height: t ? "auto" : i, position: "relative", WebkitOverflowScrolling: "touch", width: f, willChange: "transform" }, k = y > i ? this._scrollbarSize : 0, P = g > f ? this._scrollbarSize : 0;
|
|
569
|
+
return I.overflowX = g + k <= f ? "hidden" : "auto", I.overflowY = y + P <= i ? "hidden" : "auto", x.createElement("div", { ref: this._setScrollingContainerRef, "aria-label": this.props["aria-label"], className: N("ReactVirtualized__Collection", l), id: s, onScroll: this._onScroll, role: "grid", style: Xe(Xe({}, I), d), tabIndex: 0 }, n > 0 && x.createElement("div", { className: "ReactVirtualized__Collection__innerScrollContainer", style: { height: y, maxHeight: y, maxWidth: g, overflow: "hidden", pointerEvents: v ? "none" : "", width: g } }, z), n === 0 && c());
|
|
567
570
|
} }, { key: "_enablePointerEventsAfterDelay", value: function() {
|
|
568
571
|
var e = this;
|
|
569
572
|
this._disablePointerEventsTimeoutId && clearTimeout(this._disablePointerEventsTimeoutId), this._disablePointerEventsTimeoutId = setTimeout(function() {
|
|
570
573
|
(0, e.props.isScrollingChange)(!1), e._disablePointerEventsTimeoutId = null, e.setState({ isScrolling: !1 });
|
|
571
574
|
}, 150);
|
|
572
575
|
} }, { key: "_invokeOnScrollMemoizer", value: function(e) {
|
|
573
|
-
var t = this, n = e.scrollLeft, r = e.scrollTop,
|
|
576
|
+
var t = this, n = e.scrollLeft, r = e.scrollTop, l = e.totalHeight, i = e.totalWidth;
|
|
574
577
|
this._onScrollMemoizer({ callback: function(a) {
|
|
575
578
|
var s = a.scrollLeft, c = a.scrollTop, d = t.props, h = d.height;
|
|
576
|
-
(0, d.onScroll)({ clientHeight: h, clientWidth: d.width, scrollHeight:
|
|
579
|
+
(0, d.onScroll)({ clientHeight: h, clientWidth: d.width, scrollHeight: l, scrollLeft: s, scrollTop: c, scrollWidth: i });
|
|
577
580
|
}, indices: { scrollLeft: n, scrollTop: r } });
|
|
578
581
|
} }, { key: "_setScrollPosition", value: function(e) {
|
|
579
|
-
var t = e.scrollLeft, n = e.scrollTop, r = { scrollPositionChangeReason:
|
|
582
|
+
var t = e.scrollLeft, n = e.scrollTop, r = { scrollPositionChangeReason: ne };
|
|
580
583
|
t >= 0 && (r.scrollLeft = t), n >= 0 && (r.scrollTop = n), (t >= 0 && t !== this.state.scrollLeft || n >= 0 && n !== this.state.scrollTop) && this.setState(r);
|
|
581
584
|
} }], [{ key: "getDerivedStateFromProps", value: function(e, t) {
|
|
582
|
-
return e.cellCount !== 0 || t.scrollLeft === 0 && t.scrollTop === 0 ? e.scrollLeft !== t.scrollLeft || e.scrollTop !== t.scrollTop ? { scrollLeft: e.scrollLeft != null ? e.scrollLeft : t.scrollLeft, scrollTop: e.scrollTop != null ? e.scrollTop : t.scrollTop, scrollPositionChangeReason:
|
|
585
|
+
return e.cellCount !== 0 || t.scrollLeft === 0 && t.scrollTop === 0 ? e.scrollLeft !== t.scrollLeft || e.scrollTop !== t.scrollTop ? { scrollLeft: e.scrollLeft != null ? e.scrollLeft : t.scrollLeft, scrollTop: e.scrollTop != null ? e.scrollTop : t.scrollTop, scrollPositionChangeReason: ne } : null : { scrollLeft: 0, scrollTop: 0, scrollPositionChangeReason: ne };
|
|
583
586
|
} }]);
|
|
584
587
|
}();
|
|
585
|
-
p(
|
|
588
|
+
p(_e, "defaultProps", { "aria-label": "grid", horizontalOverscanSize: 0, noContentRenderer: function() {
|
|
586
589
|
return null;
|
|
587
590
|
}, onScroll: function() {
|
|
588
591
|
return null;
|
|
589
592
|
}, onSectionRendered: function() {
|
|
590
593
|
return null;
|
|
591
|
-
}, scrollToAlignment: "auto", scrollToCell: -1, style: {}, verticalOverscanSize: 0 }),
|
|
592
|
-
var
|
|
593
|
-
var t = e.height, n = e.width, r = e.x,
|
|
594
|
-
|
|
594
|
+
}, scrollToAlignment: "auto", scrollToCell: -1, style: {}, verticalOverscanSize: 0 }), _e.propTypes = {}, ue(_e);
|
|
595
|
+
var Bo = E(function o(e) {
|
|
596
|
+
var t = e.height, n = e.width, r = e.x, l = e.y;
|
|
597
|
+
A(this, o), this.height = t, this.width = n, this.x = r, this.y = l, this._indexMap = {}, this._indices = [];
|
|
595
598
|
}, [{ key: "addCellIndex", value: function(o) {
|
|
596
599
|
var e = o.index;
|
|
597
600
|
this._indexMap[e] || (this._indexMap[e] = !0, this._indices.push(e));
|
|
@@ -599,25 +602,25 @@ var Fo = A(function o(e) {
|
|
|
599
602
|
return this._indices;
|
|
600
603
|
} }, { key: "toString", value: function() {
|
|
601
604
|
return "".concat(this.x, ",").concat(this.y, " ").concat(this.width, "x").concat(this.height);
|
|
602
|
-
} }]),
|
|
605
|
+
} }]), Uo = E(function o() {
|
|
603
606
|
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 100;
|
|
604
|
-
|
|
607
|
+
A(this, o), this._sectionSize = e, this._cellMetadata = [], this._sections = {};
|
|
605
608
|
}, [{ key: "getCellIndices", value: function(o) {
|
|
606
|
-
var e = o.height, t = o.width, n = o.x, r = o.y,
|
|
607
|
-
return this.getSections({ height: e, width: t, x: n, y: r }).forEach(function(
|
|
608
|
-
return
|
|
609
|
-
|
|
609
|
+
var e = o.height, t = o.width, n = o.x, r = o.y, l = {};
|
|
610
|
+
return this.getSections({ height: e, width: t, x: n, y: r }).forEach(function(i) {
|
|
611
|
+
return i.getCellIndices().forEach(function(a) {
|
|
612
|
+
l[a] = a;
|
|
610
613
|
});
|
|
611
|
-
}), Object.keys(
|
|
612
|
-
return i
|
|
614
|
+
}), Object.keys(l).map(function(i) {
|
|
615
|
+
return l[i];
|
|
613
616
|
});
|
|
614
617
|
} }, { key: "getCellMetadata", value: function(o) {
|
|
615
618
|
var e = o.index;
|
|
616
619
|
return this._cellMetadata[e];
|
|
617
620
|
} }, { key: "getSections", value: function(o) {
|
|
618
|
-
for (var e = o.height, t = o.width, n = o.x, r = o.y,
|
|
621
|
+
for (var e = o.height, t = o.width, n = o.x, r = o.y, l = Math.floor(n / this._sectionSize), i = Math.floor((n + t - 1) / this._sectionSize), a = Math.floor(r / this._sectionSize), s = Math.floor((r + e - 1) / this._sectionSize), c = [], d = l; d <= i; d++) for (var h = a; h <= s; h++) {
|
|
619
622
|
var f = "".concat(d, ".").concat(h);
|
|
620
|
-
this._sections[f] || (this._sections[f] = new
|
|
623
|
+
this._sections[f] || (this._sections[f] = new Bo({ height: this._sectionSize, width: this._sectionSize, x: d * this._sectionSize, y: h * this._sectionSize })), c.push(this._sections[f]);
|
|
621
624
|
}
|
|
622
625
|
return c;
|
|
623
626
|
} }, { key: "getTotalSectionCount", value: function() {
|
|
@@ -633,68 +636,68 @@ var Fo = A(function o(e) {
|
|
|
633
636
|
return n.addCellIndex({ index: t });
|
|
634
637
|
});
|
|
635
638
|
} }]);
|
|
636
|
-
function
|
|
637
|
-
var e = o.align, t = e === void 0 ? "auto" : e, n = o.cellOffset, r = o.cellSize,
|
|
639
|
+
function Ye(o) {
|
|
640
|
+
var e = o.align, t = e === void 0 ? "auto" : e, n = o.cellOffset, r = o.cellSize, l = o.containerSize, i = o.currentOffset, a = n, s = a - l + r;
|
|
638
641
|
switch (t) {
|
|
639
642
|
case "start":
|
|
640
643
|
return a;
|
|
641
644
|
case "end":
|
|
642
645
|
return s;
|
|
643
646
|
case "center":
|
|
644
|
-
return a - (
|
|
647
|
+
return a - (l - r) / 2;
|
|
645
648
|
default:
|
|
646
|
-
return Math.max(s, Math.min(a,
|
|
649
|
+
return Math.max(s, Math.min(a, i));
|
|
647
650
|
}
|
|
648
651
|
}
|
|
649
|
-
function
|
|
652
|
+
function Gt() {
|
|
650
653
|
try {
|
|
651
654
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
652
655
|
}));
|
|
653
656
|
} catch {
|
|
654
657
|
}
|
|
655
|
-
return (
|
|
658
|
+
return (Gt = function() {
|
|
656
659
|
return !!o;
|
|
657
660
|
})();
|
|
658
661
|
}
|
|
659
|
-
var
|
|
662
|
+
var Je = function() {
|
|
660
663
|
function o(e, t) {
|
|
661
|
-
var n, r,
|
|
662
|
-
return
|
|
664
|
+
var n, r, l, i;
|
|
665
|
+
return A(this, o), r = this, i = [e, t], l = O(l = o), (n = W(r, Gt() ? Reflect.construct(l, i || [], O(r).constructor) : l.apply(r, i)))._cellMetadata = [], n._lastRenderedCellIndices = [], n._cellCache = [], n._isScrollingChange = n._isScrollingChange.bind(n), n._setCollectionViewRef = n._setCollectionViewRef.bind(n), n;
|
|
663
666
|
}
|
|
664
|
-
return D(o, x.PureComponent),
|
|
667
|
+
return D(o, x.PureComponent), E(o, [{ key: "forceUpdate", value: function() {
|
|
665
668
|
this._collectionView !== void 0 && this._collectionView.forceUpdate();
|
|
666
669
|
} }, { key: "recomputeCellSizesAndPositions", value: function() {
|
|
667
670
|
this._cellCache = [], this._collectionView.recomputeCellSizesAndPositions();
|
|
668
671
|
} }, { key: "render", value: function() {
|
|
669
|
-
var e =
|
|
672
|
+
var e = V({}, (function(t) {
|
|
670
673
|
if (t == null) throw new TypeError("Cannot destructure " + t);
|
|
671
674
|
}(this.props), this.props));
|
|
672
|
-
return x.createElement(
|
|
675
|
+
return x.createElement(_e, V({ cellLayoutManager: this, isScrollingChange: this._isScrollingChange, ref: this._setCollectionViewRef }, e));
|
|
673
676
|
} }, { key: "calculateSizeAndPositionData", value: function() {
|
|
674
677
|
var e = this.props, t = function(n) {
|
|
675
|
-
for (var r = n.cellCount,
|
|
676
|
-
var h =
|
|
678
|
+
for (var r = n.cellCount, l = n.cellSizeAndPositionGetter, i = [], a = new Uo(n.sectionSize), s = 0, c = 0, d = 0; d < r; d++) {
|
|
679
|
+
var h = l({ index: d });
|
|
677
680
|
if (h.height == null || isNaN(h.height) || h.width == null || isNaN(h.width) || h.x == null || isNaN(h.x) || h.y == null || isNaN(h.y)) throw Error("Invalid metadata returned for cell ".concat(d, `:
|
|
678
681
|
x:`).concat(h.x, ", y:").concat(h.y, ", width:").concat(h.width, ", height:").concat(h.height));
|
|
679
|
-
s = Math.max(s, h.y + h.height), c = Math.max(c, h.x + h.width),
|
|
682
|
+
s = Math.max(s, h.y + h.height), c = Math.max(c, h.x + h.width), i[d] = h, a.registerCell({ cellMetadatum: h, index: d });
|
|
680
683
|
}
|
|
681
|
-
return { cellMetadata:
|
|
684
|
+
return { cellMetadata: i, height: s, sectionManager: a, width: c };
|
|
682
685
|
}({ cellCount: e.cellCount, cellSizeAndPositionGetter: e.cellSizeAndPositionGetter, sectionSize: e.sectionSize });
|
|
683
686
|
this._cellMetadata = t.cellMetadata, this._sectionManager = t.sectionManager, this._height = t.height, this._width = t.width;
|
|
684
687
|
} }, { key: "getLastRenderedIndices", value: function() {
|
|
685
688
|
return this._lastRenderedCellIndices;
|
|
686
689
|
} }, { key: "getScrollPositionForCell", value: function(e) {
|
|
687
|
-
var t = e.align, n = e.cellIndex, r = e.height,
|
|
690
|
+
var t = e.align, n = e.cellIndex, r = e.height, l = e.scrollLeft, i = e.scrollTop, a = e.width, s = this.props.cellCount;
|
|
688
691
|
if (n >= 0 && n < s) {
|
|
689
692
|
var c = this._cellMetadata[n];
|
|
690
|
-
|
|
693
|
+
l = Ye({ align: t, cellOffset: c.x, cellSize: c.width, containerSize: a, currentOffset: l }), i = Ye({ align: t, cellOffset: c.y, cellSize: c.height, containerSize: r, currentOffset: i });
|
|
691
694
|
}
|
|
692
|
-
return { scrollLeft:
|
|
695
|
+
return { scrollLeft: l, scrollTop: i };
|
|
693
696
|
} }, { key: "getTotalSize", value: function() {
|
|
694
697
|
return { height: this._height, width: this._width };
|
|
695
698
|
} }, { key: "cellRenderers", value: function(e) {
|
|
696
|
-
var t = this, n = e.height, r = e.isScrolling,
|
|
697
|
-
return this._lastRenderedCellIndices = this._sectionManager.getCellIndices({ height: n, width:
|
|
699
|
+
var t = this, n = e.height, r = e.isScrolling, l = e.width, i = e.x, a = e.y, s = this.props, c = s.cellGroupRenderer, d = s.cellRenderer;
|
|
700
|
+
return this._lastRenderedCellIndices = this._sectionManager.getCellIndices({ height: n, width: l, x: i, y: a }), c({ cellCache: this._cellCache, cellRenderer: d, cellSizeAndPositionGetter: function(h) {
|
|
698
701
|
var f = h.index;
|
|
699
702
|
return t._sectionManager.getCellMetadata({ index: f });
|
|
700
703
|
}, indices: this._lastRenderedCellIndices, isScrolling: r });
|
|
@@ -704,48 +707,48 @@ var Xe = function() {
|
|
|
704
707
|
this._collectionView = e;
|
|
705
708
|
} }]);
|
|
706
709
|
}();
|
|
707
|
-
function
|
|
710
|
+
function At() {
|
|
708
711
|
try {
|
|
709
712
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
710
713
|
}));
|
|
711
714
|
} catch {
|
|
712
715
|
}
|
|
713
|
-
return (
|
|
716
|
+
return (At = function() {
|
|
714
717
|
return !!o;
|
|
715
718
|
})();
|
|
716
719
|
}
|
|
717
|
-
function
|
|
718
|
-
var e = o.cellCount, t = o.cellSize, n = o.computeMetadataCallback, r = o.computeMetadataCallbackProps,
|
|
719
|
-
e ===
|
|
720
|
+
function Ze(o) {
|
|
721
|
+
var e = o.cellCount, t = o.cellSize, n = o.computeMetadataCallback, r = o.computeMetadataCallbackProps, l = o.nextCellsCount, i = o.nextCellSize, a = o.nextScrollToIndex, s = o.scrollToIndex, c = o.updateScrollOffsetForScrollToIndex;
|
|
722
|
+
e === l && (typeof t != "number" && typeof i != "number" || t === i) || (n(r), s >= 0 && s === a && c());
|
|
720
723
|
}
|
|
721
|
-
function
|
|
724
|
+
function ie(o, e) {
|
|
722
725
|
if (o == null) return {};
|
|
723
|
-
var t, n, r =
|
|
726
|
+
var t, n, r = Po(o, e);
|
|
724
727
|
if (Object.getOwnPropertySymbols) {
|
|
725
|
-
var
|
|
726
|
-
for (n = 0; n <
|
|
728
|
+
var l = Object.getOwnPropertySymbols(o);
|
|
729
|
+
for (n = 0; n < l.length; n++) t = l[n], e.indexOf(t) === -1 && {}.propertyIsEnumerable.call(o, t) && (r[t] = o[t]);
|
|
727
730
|
}
|
|
728
731
|
return r;
|
|
729
732
|
}
|
|
730
|
-
p(
|
|
731
|
-
var e = o.cellCache, t = o.cellRenderer, n = o.cellSizeAndPositionGetter, r = o.indices,
|
|
732
|
-
return r.map(function(
|
|
733
|
-
var a = n({ index:
|
|
734
|
-
return
|
|
735
|
-
}).filter(function(
|
|
736
|
-
return !!
|
|
733
|
+
p(Je, "defaultProps", { "aria-label": "grid", cellGroupRenderer: function(o) {
|
|
734
|
+
var e = o.cellCache, t = o.cellRenderer, n = o.cellSizeAndPositionGetter, r = o.indices, l = o.isScrolling;
|
|
735
|
+
return r.map(function(i) {
|
|
736
|
+
var a = n({ index: i }), s = { index: i, isScrolling: l, key: i, style: { height: a.height, left: a.x, position: "absolute", top: a.y, width: a.width } };
|
|
737
|
+
return l ? (i in e || (e[i] = t(s)), e[i]) : t(s);
|
|
738
|
+
}).filter(function(i) {
|
|
739
|
+
return !!i;
|
|
737
740
|
});
|
|
738
|
-
} }),
|
|
741
|
+
} }), Je.propTypes = {}, function() {
|
|
739
742
|
function o(e, t) {
|
|
740
|
-
var n, r,
|
|
741
|
-
return
|
|
743
|
+
var n, r, l, i;
|
|
744
|
+
return A(this, o), r = this, i = [e, t], l = O(l = o), (n = W(r, At() ? Reflect.construct(l, i || [], O(r).constructor) : l.apply(r, i)))._registerChild = n._registerChild.bind(n), n;
|
|
742
745
|
}
|
|
743
|
-
return D(o, x.PureComponent),
|
|
744
|
-
var t = this.props, n = t.columnMaxWidth, r = t.columnMinWidth,
|
|
745
|
-
n === e.columnMaxWidth && r === e.columnMinWidth &&
|
|
746
|
+
return D(o, x.PureComponent), E(o, [{ key: "componentDidUpdate", value: function(e) {
|
|
747
|
+
var t = this.props, n = t.columnMaxWidth, r = t.columnMinWidth, l = t.columnCount, i = t.width;
|
|
748
|
+
n === e.columnMaxWidth && r === e.columnMinWidth && l === e.columnCount && i === e.width || this._registeredChild && this._registeredChild.recomputeGridSize();
|
|
746
749
|
} }, { key: "render", value: function() {
|
|
747
|
-
var e = this.props, t = e.children, n = e.columnMaxWidth, r = e.columnMinWidth,
|
|
748
|
-
return c = Math.max(a, c), c = Math.min(s, c), c = Math.floor(c), t({ adjustedWidth: Math.min(
|
|
750
|
+
var e = this.props, t = e.children, n = e.columnMaxWidth, r = e.columnMinWidth, l = e.columnCount, i = e.width, a = r || 1, s = n ? Math.min(n, i) : i, c = i / l;
|
|
751
|
+
return c = Math.max(a, c), c = Math.min(s, c), c = Math.floor(c), t({ adjustedWidth: Math.min(i, c * l), columnWidth: c, getColumnWidth: function() {
|
|
749
752
|
return c;
|
|
750
753
|
}, registerChild: this._registerChild });
|
|
751
754
|
} }, { key: "_registerChild", value: function(e) {
|
|
@@ -753,9 +756,9 @@ p(Xe, "defaultProps", { "aria-label": "grid", cellGroupRenderer: function(o) {
|
|
|
753
756
|
this._registeredChild = e, this._registeredChild && this._registeredChild.recomputeGridSize();
|
|
754
757
|
} }]);
|
|
755
758
|
}().propTypes = {};
|
|
756
|
-
var F,
|
|
759
|
+
var F, Vo = E(function o(e) {
|
|
757
760
|
var t = e.cellCount, n = e.cellSizeGetter, r = e.estimatedCellSize;
|
|
758
|
-
|
|
761
|
+
A(this, o), p(this, "_cellSizeAndPositionData", {}), p(this, "_lastMeasuredIndex", -1), p(this, "_lastBatchedIndex", -1), p(this, "_cellCount", void 0), p(this, "_cellSizeGetter", void 0), p(this, "_estimatedCellSize", void 0), this._cellSizeGetter = n, this._cellCount = t, this._estimatedCellSize = r;
|
|
759
762
|
}, [{ key: "areOffsetsAdjusted", value: function() {
|
|
760
763
|
return !1;
|
|
761
764
|
} }, { key: "configure", value: function(o) {
|
|
@@ -783,31 +786,31 @@ var F, Bo = A(function o(e) {
|
|
|
783
786
|
var o = this.getSizeAndPositionOfLastMeasuredCell();
|
|
784
787
|
return o.offset + o.size + (this._cellCount - this._lastMeasuredIndex - 1) * this._estimatedCellSize;
|
|
785
788
|
} }, { key: "getUpdatedOffsetForIndex", value: function(o) {
|
|
786
|
-
var e = o.align, t = e === void 0 ? "auto" : e, n = o.containerSize, r = o.currentOffset,
|
|
789
|
+
var e = o.align, t = e === void 0 ? "auto" : e, n = o.containerSize, r = o.currentOffset, l = o.targetIndex;
|
|
787
790
|
if (n <= 0) return 0;
|
|
788
|
-
var
|
|
791
|
+
var i, a = this.getSizeAndPositionOfCell(l), s = a.offset, c = s - n + a.size;
|
|
789
792
|
switch (t) {
|
|
790
793
|
case "start":
|
|
791
|
-
|
|
794
|
+
i = s;
|
|
792
795
|
break;
|
|
793
796
|
case "end":
|
|
794
|
-
|
|
797
|
+
i = c;
|
|
795
798
|
break;
|
|
796
799
|
case "center":
|
|
797
|
-
|
|
800
|
+
i = s - (n - a.size) / 2;
|
|
798
801
|
break;
|
|
799
802
|
default:
|
|
800
|
-
|
|
803
|
+
i = Math.max(c, Math.min(s, r));
|
|
801
804
|
}
|
|
802
805
|
var d = this.getTotalSize();
|
|
803
|
-
return Math.max(0, Math.min(d - n,
|
|
806
|
+
return Math.max(0, Math.min(d - n, i));
|
|
804
807
|
} }, { key: "getVisibleCellRange", value: function(o) {
|
|
805
808
|
var e = o.containerSize, t = o.offset;
|
|
806
809
|
if (this.getTotalSize() === 0) return {};
|
|
807
|
-
var n = t + e, r = this._findNearestCell(t),
|
|
808
|
-
t =
|
|
809
|
-
for (var
|
|
810
|
-
return { start: r, stop:
|
|
810
|
+
var n = t + e, r = this._findNearestCell(t), l = this.getSizeAndPositionOfCell(r);
|
|
811
|
+
t = l.offset + l.size;
|
|
812
|
+
for (var i = r; t < n && i < this._cellCount - 1; ) i++, t += this.getSizeAndPositionOfCell(i).size;
|
|
813
|
+
return { start: r, stop: i };
|
|
811
814
|
} }, { key: "resetCell", value: function(o) {
|
|
812
815
|
this._lastMeasuredIndex = Math.min(this._lastMeasuredIndex, o - 1);
|
|
813
816
|
} }, { key: "_binarySearch", value: function(o, e, t) {
|
|
@@ -825,9 +828,9 @@ var F, Bo = A(function o(e) {
|
|
|
825
828
|
o = Math.max(0, o);
|
|
826
829
|
var e = this.getSizeAndPositionOfLastMeasuredCell(), t = Math.max(0, this._lastMeasuredIndex);
|
|
827
830
|
return e.offset >= o ? this._binarySearch(t, 0, o) : this._exponentialSearch(t, o);
|
|
828
|
-
} }]),
|
|
829
|
-
var t = e.maxScrollSize, n = t === void 0 ? typeof window < "u" && window.chrome ? 16777100 : 15e5 : t, r =
|
|
830
|
-
|
|
831
|
+
} }]), $o = ["maxScrollSize"], Qe = E(function o(e) {
|
|
832
|
+
var t = e.maxScrollSize, n = t === void 0 ? typeof window < "u" && window.chrome ? 16777100 : 15e5 : t, r = ie(e, $o);
|
|
833
|
+
A(this, o), p(this, "_cellSizeAndPositionManager", void 0), p(this, "_maxScrollSize", void 0), this._cellSizeAndPositionManager = new Vo(r), this._maxScrollSize = n;
|
|
831
834
|
}, [{ key: "areOffsetsAdjusted", value: function() {
|
|
832
835
|
return this._cellSizeAndPositionManager.getTotalSize() > this._maxScrollSize;
|
|
833
836
|
} }, { key: "configure", value: function(o) {
|
|
@@ -839,8 +842,8 @@ var F, Bo = A(function o(e) {
|
|
|
839
842
|
} }, { key: "getLastMeasuredIndex", value: function() {
|
|
840
843
|
return this._cellSizeAndPositionManager.getLastMeasuredIndex();
|
|
841
844
|
} }, { key: "getOffsetAdjustment", value: function(o) {
|
|
842
|
-
var e = o.containerSize, t = o.offset, n = this._cellSizeAndPositionManager.getTotalSize(), r = this.getTotalSize(),
|
|
843
|
-
return Math.round(
|
|
845
|
+
var e = o.containerSize, t = o.offset, n = this._cellSizeAndPositionManager.getTotalSize(), r = this.getTotalSize(), l = this._getOffsetPercentage({ containerSize: e, offset: t, totalSize: r });
|
|
846
|
+
return Math.round(l * (r - n));
|
|
844
847
|
} }, { key: "getSizeAndPositionOfCell", value: function(o) {
|
|
845
848
|
return this._cellSizeAndPositionManager.getSizeAndPositionOfCell(o);
|
|
846
849
|
} }, { key: "getSizeAndPositionOfLastMeasuredCell", value: function() {
|
|
@@ -848,10 +851,10 @@ var F, Bo = A(function o(e) {
|
|
|
848
851
|
} }, { key: "getTotalSize", value: function() {
|
|
849
852
|
return Math.min(this._maxScrollSize, this._cellSizeAndPositionManager.getTotalSize());
|
|
850
853
|
} }, { key: "getUpdatedOffsetForIndex", value: function(o) {
|
|
851
|
-
var e = o.align, t = e === void 0 ? "auto" : e, n = o.containerSize, r = o.currentOffset,
|
|
854
|
+
var e = o.align, t = e === void 0 ? "auto" : e, n = o.containerSize, r = o.currentOffset, l = o.targetIndex;
|
|
852
855
|
r = this._safeOffsetToOffset({ containerSize: n, offset: r });
|
|
853
|
-
var
|
|
854
|
-
return this._offsetToSafeOffset({ containerSize: n, offset:
|
|
856
|
+
var i = this._cellSizeAndPositionManager.getUpdatedOffsetForIndex({ align: t, containerSize: n, currentOffset: r, targetIndex: l });
|
|
857
|
+
return this._offsetToSafeOffset({ containerSize: n, offset: i });
|
|
855
858
|
} }, { key: "getVisibleCellRange", value: function(o) {
|
|
856
859
|
var e = o.containerSize, t = o.offset;
|
|
857
860
|
return t = this._safeOffsetToOffset({ containerSize: e, offset: t }), this._cellSizeAndPositionManager.getVisibleCellRange({ containerSize: e, offset: t });
|
|
@@ -863,35 +866,35 @@ var F, Bo = A(function o(e) {
|
|
|
863
866
|
} }, { key: "_offsetToSafeOffset", value: function(o) {
|
|
864
867
|
var e = o.containerSize, t = o.offset, n = this._cellSizeAndPositionManager.getTotalSize(), r = this.getTotalSize();
|
|
865
868
|
if (n === r) return t;
|
|
866
|
-
var
|
|
867
|
-
return Math.round(
|
|
869
|
+
var l = this._getOffsetPercentage({ containerSize: e, offset: t, totalSize: n });
|
|
870
|
+
return Math.round(l * (r - e));
|
|
868
871
|
} }, { key: "_safeOffsetToOffset", value: function(o) {
|
|
869
872
|
var e = o.containerSize, t = o.offset, n = this._cellSizeAndPositionManager.getTotalSize(), r = this.getTotalSize();
|
|
870
873
|
if (n === r) return t;
|
|
871
|
-
var
|
|
872
|
-
return Math.round(
|
|
874
|
+
var l = this._getOffsetPercentage({ containerSize: e, offset: t, totalSize: r });
|
|
875
|
+
return Math.round(l * (n - e));
|
|
873
876
|
} }]);
|
|
874
|
-
function
|
|
875
|
-
var e = o.cellSize, t = o.cellSizeAndPositionManager, n = o.previousCellsCount, r = o.previousCellSize,
|
|
876
|
-
|
|
877
|
+
function et(o) {
|
|
878
|
+
var e = o.cellSize, t = o.cellSizeAndPositionManager, n = o.previousCellsCount, r = o.previousCellSize, l = o.previousScrollToAlignment, i = o.previousScrollToIndex, a = o.previousSize, s = o.scrollOffset, c = o.scrollToAlignment, d = o.scrollToIndex, h = o.size, f = o.sizeJustIncreasedFromZero, u = o.updateScrollIndexCallback, v = t.getCellCount(), m = d >= 0 && d < v;
|
|
879
|
+
m && (h !== a || f || !r || typeof e == "number" && e !== r || c !== l || d !== i) ? u(d) : !m && v > 0 && (h < a || v < n) && s > t.getTotalSize() - h && u(v - 1);
|
|
877
880
|
}
|
|
878
|
-
var
|
|
881
|
+
var qo = (F = typeof window < "u" ? window : typeof self < "u" ? self : {}).requestAnimationFrame || F.webkitRequestAnimationFrame || F.mozRequestAnimationFrame || F.oRequestAnimationFrame || F.msRequestAnimationFrame || function(o) {
|
|
879
882
|
return F.setTimeout(o, 1e3 / 60);
|
|
880
|
-
},
|
|
883
|
+
}, Ko = F.cancelAnimationFrame || F.webkitCancelAnimationFrame || F.mozCancelAnimationFrame || F.oCancelAnimationFrame || F.msCancelAnimationFrame || function(o) {
|
|
881
884
|
F.clearTimeout(o);
|
|
882
|
-
},
|
|
883
|
-
return
|
|
884
|
-
},
|
|
885
|
+
}, tt = qo, Xo = Ko, oe = function(o) {
|
|
886
|
+
return Xo(o.id);
|
|
887
|
+
}, Ge = function(o, e) {
|
|
885
888
|
var t;
|
|
886
889
|
Promise.resolve().then(function() {
|
|
887
890
|
t = Date.now();
|
|
888
891
|
});
|
|
889
892
|
var n = function() {
|
|
890
|
-
Date.now() - t >= e ? o.call() : r.id =
|
|
891
|
-
}, r = { id:
|
|
893
|
+
Date.now() - t >= e ? o.call() : r.id = tt(n);
|
|
894
|
+
}, r = { id: tt(n) };
|
|
892
895
|
return r;
|
|
893
896
|
};
|
|
894
|
-
function
|
|
897
|
+
function ot(o, e) {
|
|
895
898
|
var t = Object.keys(o);
|
|
896
899
|
if (Object.getOwnPropertySymbols) {
|
|
897
900
|
var n = Object.getOwnPropertySymbols(o);
|
|
@@ -904,61 +907,61 @@ function et(o, e) {
|
|
|
904
907
|
function j(o) {
|
|
905
908
|
for (var e = 1; e < arguments.length; e++) {
|
|
906
909
|
var t = arguments[e] != null ? arguments[e] : {};
|
|
907
|
-
e % 2 ?
|
|
910
|
+
e % 2 ? ot(Object(t), !0).forEach(function(n) {
|
|
908
911
|
p(o, n, t[n]);
|
|
909
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) :
|
|
912
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) : ot(Object(t)).forEach(function(n) {
|
|
910
913
|
Object.defineProperty(o, n, Object.getOwnPropertyDescriptor(t, n));
|
|
911
914
|
});
|
|
912
915
|
}
|
|
913
916
|
return o;
|
|
914
917
|
}
|
|
915
|
-
function
|
|
918
|
+
function Et() {
|
|
916
919
|
try {
|
|
917
920
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
918
921
|
}));
|
|
919
922
|
} catch {
|
|
920
923
|
}
|
|
921
|
-
return (
|
|
924
|
+
return (Et = function() {
|
|
922
925
|
return !!o;
|
|
923
926
|
})();
|
|
924
927
|
}
|
|
925
|
-
var
|
|
928
|
+
var nt = "requested", $ = function() {
|
|
926
929
|
function o(e) {
|
|
927
|
-
var t, n, r,
|
|
928
|
-
|
|
930
|
+
var t, n, r, l;
|
|
931
|
+
A(this, o), n = this, l = [e], r = O(r = o), p(t = W(n, Et() ? Reflect.construct(r, l || [], O(n).constructor) : r.apply(n, l)), "_onGridRenderedMemoizer", te()), p(t, "_onScrollMemoizer", te(!1)), p(t, "_deferredInvalidateColumnIndex", null), p(t, "_deferredInvalidateRowIndex", null), p(t, "_recomputeScrollLeftFlag", !1), p(t, "_recomputeScrollTopFlag", !1), p(t, "_horizontalScrollBarSize", 0), p(t, "_verticalScrollBarSize", 0), p(t, "_scrollbarPresenceChanged", !1), p(t, "_scrollingContainer", void 0), p(t, "_childrenToDisplay", void 0), p(t, "_columnStartIndex", void 0), p(t, "_columnStopIndex", void 0), p(t, "_rowStartIndex", void 0), p(t, "_rowStopIndex", void 0), p(t, "_renderedColumnStartIndex", 0), p(t, "_renderedColumnStopIndex", 0), p(t, "_renderedRowStartIndex", 0), p(t, "_renderedRowStopIndex", 0), p(t, "_initialScrollTop", void 0), p(t, "_initialScrollLeft", void 0), p(t, "_disablePointerEventsTimeoutId", void 0), p(t, "_styleCache", {}), p(t, "_cellCache", {}), p(t, "_debounceScrollEndedCallback", function() {
|
|
929
932
|
t._disablePointerEventsTimeoutId = null, t.setState({ isScrolling: !1, needToResetStyleCache: !1 });
|
|
930
933
|
}), p(t, "_invokeOnGridRenderedHelper", function() {
|
|
931
934
|
var s = t.props.onSectionRendered;
|
|
932
935
|
t._onGridRenderedMemoizer({ callback: s, indices: { columnOverscanStartIndex: t._columnStartIndex, columnOverscanStopIndex: t._columnStopIndex, columnStartIndex: t._renderedColumnStartIndex, columnStopIndex: t._renderedColumnStopIndex, rowOverscanStartIndex: t._rowStartIndex, rowOverscanStopIndex: t._rowStopIndex, rowStartIndex: t._renderedRowStartIndex, rowStopIndex: t._renderedRowStopIndex } });
|
|
933
936
|
}), p(t, "_setScrollingContainerRef", function(s) {
|
|
934
|
-
t._scrollingContainer = s, typeof t.props.elementRef == "function" ? t.props.elementRef(s) :
|
|
937
|
+
t._scrollingContainer = s, typeof t.props.elementRef == "function" ? t.props.elementRef(s) : ee(t.props.elementRef) === "object" && (t.props.elementRef.current = s);
|
|
935
938
|
}), p(t, "_onScroll", function(s) {
|
|
936
939
|
s.target === t._scrollingContainer && t.handleScrollEvent(s.target);
|
|
937
940
|
});
|
|
938
|
-
var
|
|
941
|
+
var i = new Qe({ cellCount: e.columnCount, cellSizeGetter: function(s) {
|
|
939
942
|
return o._wrapSizeGetter(e.columnWidth)(s);
|
|
940
|
-
}, estimatedCellSize: o._getEstimatedColumnSize(e) }), a = new
|
|
943
|
+
}, estimatedCellSize: o._getEstimatedColumnSize(e) }), a = new Qe({ cellCount: e.rowCount, cellSizeGetter: function(s) {
|
|
941
944
|
return o._wrapSizeGetter(e.rowHeight)(s);
|
|
942
945
|
}, estimatedCellSize: o._getEstimatedRowSize(e) });
|
|
943
|
-
return t.state = { instanceProps: { columnSizeAndPositionManager:
|
|
946
|
+
return t.state = { instanceProps: { columnSizeAndPositionManager: i, rowSizeAndPositionManager: a, prevColumnWidth: e.columnWidth, prevRowHeight: e.rowHeight, prevColumnCount: e.columnCount, prevRowCount: e.rowCount, prevIsScrolling: e.isScrolling === !0, prevScrollToColumn: e.scrollToColumn, prevScrollToRow: e.scrollToRow, scrollbarSize: 0, scrollbarSizeMeasured: !1 }, isScrolling: !1, scrollDirectionHorizontal: 1, scrollDirectionVertical: 1, scrollLeft: 0, scrollTop: 0, scrollPositionChangeReason: null, needToResetStyleCache: !1 }, e.scrollToRow > 0 && (t._initialScrollTop = t._getCalculatedScrollTop(e, t.state)), e.scrollToColumn > 0 && (t._initialScrollLeft = t._getCalculatedScrollLeft(e, t.state)), t;
|
|
944
947
|
}
|
|
945
|
-
return D(o, x.PureComponent),
|
|
946
|
-
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.alignment, n = t === void 0 ? this.props.scrollToAlignment : t, r = e.columnIndex,
|
|
948
|
+
return D(o, x.PureComponent), E(o, [{ key: "getOffsetForCell", value: function() {
|
|
949
|
+
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.alignment, n = t === void 0 ? this.props.scrollToAlignment : t, r = e.columnIndex, l = r === void 0 ? this.props.scrollToColumn : r, i = e.rowIndex, a = i === void 0 ? this.props.scrollToRow : i, s = j(j({}, this.props), {}, { scrollToAlignment: n, scrollToColumn: l, scrollToRow: a });
|
|
947
950
|
return { scrollLeft: this._getCalculatedScrollLeft(s), scrollTop: this._getCalculatedScrollTop(s) };
|
|
948
951
|
} }, { key: "getTotalRowsHeight", value: function() {
|
|
949
952
|
return this.state.instanceProps.rowSizeAndPositionManager.getTotalSize();
|
|
950
953
|
} }, { key: "getTotalColumnsWidth", value: function() {
|
|
951
954
|
return this.state.instanceProps.columnSizeAndPositionManager.getTotalSize();
|
|
952
955
|
} }, { key: "handleScrollEvent", value: function(e) {
|
|
953
|
-
var t = e.scrollLeft, n = t === void 0 ? 0 : t, r = e.scrollTop,
|
|
954
|
-
if (!(
|
|
956
|
+
var t = e.scrollLeft, n = t === void 0 ? 0 : t, r = e.scrollTop, l = r === void 0 ? 0 : r;
|
|
957
|
+
if (!(l < 0)) {
|
|
955
958
|
this._debounceScrollEnded();
|
|
956
|
-
var
|
|
957
|
-
if (this.state.scrollLeft !==
|
|
958
|
-
var S = { isScrolling: !0, scrollDirectionHorizontal:
|
|
959
|
-
a || (S.scrollTop =
|
|
959
|
+
var i = this.props, a = i.autoHeight, s = i.autoWidth, c = i.height, d = i.width, h = this.state.instanceProps, f = h.scrollbarSize, u = h.rowSizeAndPositionManager.getTotalSize(), v = h.columnSizeAndPositionManager.getTotalSize(), m = Math.min(Math.max(0, v - d + f), n), _ = Math.min(Math.max(0, u - c + f), l);
|
|
960
|
+
if (this.state.scrollLeft !== m || this.state.scrollTop !== _) {
|
|
961
|
+
var S = { isScrolling: !0, scrollDirectionHorizontal: m !== this.state.scrollLeft ? m > this.state.scrollLeft ? 1 : -1 : this.state.scrollDirectionHorizontal, scrollDirectionVertical: _ !== this.state.scrollTop ? _ > this.state.scrollTop ? 1 : -1 : this.state.scrollDirectionVertical, scrollPositionChangeReason: "observed" };
|
|
962
|
+
a || (S.scrollTop = _), s || (S.scrollLeft = m), S.needToResetStyleCache = !1, this.setState(S);
|
|
960
963
|
}
|
|
961
|
-
this._invokeOnScrollMemoizer({ scrollLeft:
|
|
964
|
+
this._invokeOnScrollMemoizer({ scrollLeft: m, scrollTop: _, totalColumnsWidth: v, totalRowsHeight: u });
|
|
962
965
|
}
|
|
963
966
|
} }, { key: "invalidateCellSizeAfterRender", value: function(e) {
|
|
964
967
|
var t = e.columnIndex, n = e.rowIndex;
|
|
@@ -967,82 +970,82 @@ var tt = "requested", V = function() {
|
|
|
967
970
|
var e = this.props, t = e.columnCount, n = e.rowCount, r = this.state.instanceProps;
|
|
968
971
|
r.columnSizeAndPositionManager.getSizeAndPositionOfCell(t - 1), r.rowSizeAndPositionManager.getSizeAndPositionOfCell(n - 1);
|
|
969
972
|
} }, { key: "recomputeGridSize", value: function() {
|
|
970
|
-
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.columnIndex, n = t === void 0 ? 0 : t, r = e.rowIndex,
|
|
971
|
-
c.columnSizeAndPositionManager.resetCell(n), c.rowSizeAndPositionManager.resetCell(
|
|
973
|
+
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.columnIndex, n = t === void 0 ? 0 : t, r = e.rowIndex, l = r === void 0 ? 0 : r, i = this.props, a = i.scrollToColumn, s = i.scrollToRow, c = this.state.instanceProps;
|
|
974
|
+
c.columnSizeAndPositionManager.resetCell(n), c.rowSizeAndPositionManager.resetCell(l), this._recomputeScrollLeftFlag = a >= 0 && (this.state.scrollDirectionHorizontal === 1 ? n <= a : n >= a), this._recomputeScrollTopFlag = s >= 0 && (this.state.scrollDirectionVertical === 1 ? l <= s : l >= s), this._styleCache = {}, this._cellCache = {}, this.forceUpdate();
|
|
972
975
|
} }, { key: "scrollToCell", value: function(e) {
|
|
973
|
-
var t = e.columnIndex, n = e.rowIndex, r = this.props.columnCount,
|
|
974
|
-
r > 1 && t !== void 0 && this._updateScrollLeftForScrollToColumn(j(j({},
|
|
976
|
+
var t = e.columnIndex, n = e.rowIndex, r = this.props.columnCount, l = this.props;
|
|
977
|
+
r > 1 && t !== void 0 && this._updateScrollLeftForScrollToColumn(j(j({}, l), {}, { scrollToColumn: t })), n !== void 0 && this._updateScrollTopForScrollToRow(j(j({}, l), {}, { scrollToRow: n }));
|
|
975
978
|
} }, { key: "componentDidMount", value: function() {
|
|
976
|
-
var e = this.props, t = e.getScrollbarSize, n = e.height, r = e.scrollLeft,
|
|
979
|
+
var e = this.props, t = e.getScrollbarSize, n = e.height, r = e.scrollLeft, l = e.scrollToColumn, i = e.scrollTop, a = e.scrollToRow, s = e.width, c = this.state.instanceProps;
|
|
977
980
|
if (this._initialScrollTop = 0, this._initialScrollLeft = 0, this._handleInvalidatedGridSize(), c.scrollbarSizeMeasured || this.setState(function(f) {
|
|
978
981
|
var u = j(j({}, f), {}, { needToResetStyleCache: !1 });
|
|
979
982
|
return u.instanceProps.scrollbarSize = t(), u.instanceProps.scrollbarSizeMeasured = !0, u;
|
|
980
|
-
}), typeof r == "number" && r >= 0 || typeof
|
|
981
|
-
var d = o._getScrollToPositionStateUpdate({ prevState: this.state, scrollLeft: r, scrollTop:
|
|
983
|
+
}), typeof r == "number" && r >= 0 || typeof i == "number" && i >= 0) {
|
|
984
|
+
var d = o._getScrollToPositionStateUpdate({ prevState: this.state, scrollLeft: r, scrollTop: i });
|
|
982
985
|
d && (d.needToResetStyleCache = !1, this.setState(d));
|
|
983
986
|
}
|
|
984
987
|
this._scrollingContainer && (this._scrollingContainer.scrollLeft !== this.state.scrollLeft && (this._scrollingContainer.scrollLeft = this.state.scrollLeft), this._scrollingContainer.scrollTop !== this.state.scrollTop && (this._scrollingContainer.scrollTop = this.state.scrollTop));
|
|
985
988
|
var h = n > 0 && s > 0;
|
|
986
|
-
|
|
989
|
+
l >= 0 && h && this._updateScrollLeftForScrollToColumn(), a >= 0 && h && this._updateScrollTopForScrollToRow(), this._invokeOnGridRenderedHelper(), this._invokeOnScrollMemoizer({ scrollLeft: r || 0, scrollTop: i || 0, totalColumnsWidth: c.columnSizeAndPositionManager.getTotalSize(), totalRowsHeight: c.rowSizeAndPositionManager.getTotalSize() }), this._maybeCallOnScrollbarPresenceChange();
|
|
987
990
|
} }, { key: "componentDidUpdate", value: function(e, t) {
|
|
988
|
-
var n = this, r = this.props,
|
|
991
|
+
var n = this, r = this.props, l = r.autoHeight, i = r.autoWidth, a = r.columnCount, s = r.height, c = r.rowCount, d = r.scrollToAlignment, h = r.scrollToColumn, f = r.scrollToRow, u = r.width, v = this.state, m = v.scrollLeft, _ = v.scrollPositionChangeReason, S = v.scrollTop, y = v.instanceProps;
|
|
989
992
|
this._handleInvalidatedGridSize();
|
|
990
|
-
var
|
|
991
|
-
|
|
992
|
-
var
|
|
993
|
-
if (this._recomputeScrollLeftFlag ? (this._recomputeScrollLeftFlag = !1, this._updateScrollLeftForScrollToColumn(this.props)) :
|
|
993
|
+
var g = a > 0 && e.columnCount === 0 || c > 0 && e.rowCount === 0;
|
|
994
|
+
_ === nt && (!i && m >= 0 && (m !== this._scrollingContainer.scrollLeft || g) && (this._scrollingContainer.scrollLeft = m), !l && S >= 0 && (S !== this._scrollingContainer.scrollTop || g) && (this._scrollingContainer.scrollTop = S));
|
|
995
|
+
var w = (e.width === 0 || e.height === 0) && s > 0 && u > 0;
|
|
996
|
+
if (this._recomputeScrollLeftFlag ? (this._recomputeScrollLeftFlag = !1, this._updateScrollLeftForScrollToColumn(this.props)) : et({ cellSizeAndPositionManager: y.columnSizeAndPositionManager, previousCellsCount: e.columnCount, previousCellSize: e.columnWidth, previousScrollToAlignment: e.scrollToAlignment, previousScrollToIndex: e.scrollToColumn, previousSize: e.width, scrollOffset: m, scrollToAlignment: d, scrollToIndex: h, size: u, sizeJustIncreasedFromZero: w, updateScrollIndexCallback: function() {
|
|
994
997
|
return n._updateScrollLeftForScrollToColumn(n.props);
|
|
995
|
-
} }), this._recomputeScrollTopFlag ? (this._recomputeScrollTopFlag = !1, this._updateScrollTopForScrollToRow(this.props)) :
|
|
998
|
+
} }), this._recomputeScrollTopFlag ? (this._recomputeScrollTopFlag = !1, this._updateScrollTopForScrollToRow(this.props)) : et({ cellSizeAndPositionManager: y.rowSizeAndPositionManager, previousCellsCount: e.rowCount, previousCellSize: e.rowHeight, previousScrollToAlignment: e.scrollToAlignment, previousScrollToIndex: e.scrollToRow, previousSize: e.height, scrollOffset: S, scrollToAlignment: d, scrollToIndex: f, size: s, sizeJustIncreasedFromZero: w, updateScrollIndexCallback: function() {
|
|
996
999
|
return n._updateScrollTopForScrollToRow(n.props);
|
|
997
|
-
} }), this._invokeOnGridRenderedHelper(),
|
|
998
|
-
var
|
|
999
|
-
this._invokeOnScrollMemoizer({ scrollLeft:
|
|
1000
|
+
} }), this._invokeOnGridRenderedHelper(), m !== t.scrollLeft || S !== t.scrollTop) {
|
|
1001
|
+
var C = y.rowSizeAndPositionManager.getTotalSize(), b = y.columnSizeAndPositionManager.getTotalSize();
|
|
1002
|
+
this._invokeOnScrollMemoizer({ scrollLeft: m, scrollTop: S, totalColumnsWidth: b, totalRowsHeight: C });
|
|
1000
1003
|
}
|
|
1001
1004
|
this._maybeCallOnScrollbarPresenceChange();
|
|
1002
1005
|
} }, { key: "componentWillUnmount", value: function() {
|
|
1003
|
-
this._disablePointerEventsTimeoutId &&
|
|
1006
|
+
this._disablePointerEventsTimeoutId && oe(this._disablePointerEventsTimeoutId);
|
|
1004
1007
|
} }, { key: "render", value: function() {
|
|
1005
|
-
var e = this.props, t = e.autoContainerWidth, n = e.autoHeight, r = e.autoWidth,
|
|
1008
|
+
var e = this.props, t = e.autoContainerWidth, n = e.autoHeight, r = e.autoWidth, l = e.className, i = e.containerProps, a = e.containerRole, s = e.containerStyle, c = e.height, d = e.id, h = e.noContentRenderer, f = e.role, u = e.style, v = e.tabIndex, m = e.width, _ = this.state, S = _.instanceProps, y = _.needToResetStyleCache, g = this._isScrolling(), w = { boxSizing: "border-box", direction: "ltr", height: n ? "auto" : c, position: "relative", width: r ? "auto" : m, WebkitOverflowScrolling: "touch", willChange: "transform" };
|
|
1006
1009
|
y && (this._styleCache = {}), this.state.isScrolling || this._resetStyleCache(), this._calculateChildrenToRender(this.props, this.state);
|
|
1007
|
-
var
|
|
1008
|
-
|
|
1009
|
-
var I = this._childrenToDisplay,
|
|
1010
|
-
return x.createElement("div",
|
|
1010
|
+
var C = S.columnSizeAndPositionManager.getTotalSize(), b = S.rowSizeAndPositionManager.getTotalSize(), R = b > c ? S.scrollbarSize : 0, z = C > m ? S.scrollbarSize : 0;
|
|
1011
|
+
z === this._horizontalScrollBarSize && R === this._verticalScrollBarSize || (this._horizontalScrollBarSize = z, this._verticalScrollBarSize = R, this._scrollbarPresenceChanged = !0), w.overflowX = C + R <= m ? "hidden" : "auto", w.overflowY = b + z <= c ? "hidden" : "auto";
|
|
1012
|
+
var I = this._childrenToDisplay, k = I.length === 0 && c > 0 && m > 0;
|
|
1013
|
+
return x.createElement("div", V({ ref: this._setScrollingContainerRef }, i, { "aria-label": this.props["aria-label"], "aria-readonly": this.props["aria-readonly"], className: N("ReactVirtualized__Grid", l), id: d, onScroll: this._onScroll, role: f, style: j(j({}, w), u), tabIndex: v }), I.length > 0 && x.createElement("div", { className: "ReactVirtualized__Grid__innerScrollContainer", role: a, style: j({ width: t ? "auto" : C, height: b, maxWidth: C, maxHeight: b, overflow: "hidden", pointerEvents: g ? "none" : "", position: "relative" }, s) }, I), k && h());
|
|
1011
1014
|
} }, { key: "_calculateChildrenToRender", value: function() {
|
|
1012
|
-
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : this.props, t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : this.state, n = e.cellRenderer, r = e.cellRangeRenderer,
|
|
1015
|
+
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : this.props, t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : this.state, n = e.cellRenderer, r = e.cellRangeRenderer, l = e.columnCount, i = e.deferredMeasurementCache, a = e.height, s = e.overscanColumnCount, c = e.overscanIndicesGetter, d = e.overscanRowCount, h = e.rowCount, f = e.width, u = e.isScrollingOptOut, v = t.scrollDirectionHorizontal, m = t.scrollDirectionVertical, _ = t.instanceProps, S = this._initialScrollTop > 0 ? this._initialScrollTop : t.scrollTop, y = this._initialScrollLeft > 0 ? this._initialScrollLeft : t.scrollLeft, g = this._isScrolling(e, t);
|
|
1013
1016
|
if (this._childrenToDisplay = [], a > 0 && f > 0) {
|
|
1014
|
-
var
|
|
1015
|
-
this._renderedColumnStartIndex =
|
|
1016
|
-
var
|
|
1017
|
-
if (
|
|
1018
|
-
if (!
|
|
1019
|
-
for (var
|
|
1020
|
-
|
|
1017
|
+
var w = _.columnSizeAndPositionManager.getVisibleCellRange({ containerSize: f, offset: y }), C = _.rowSizeAndPositionManager.getVisibleCellRange({ containerSize: a, offset: S }), b = _.columnSizeAndPositionManager.getOffsetAdjustment({ containerSize: f, offset: y }), R = _.rowSizeAndPositionManager.getOffsetAdjustment({ containerSize: a, offset: S });
|
|
1018
|
+
this._renderedColumnStartIndex = w.start, this._renderedColumnStopIndex = w.stop, this._renderedRowStartIndex = C.start, this._renderedRowStopIndex = C.stop;
|
|
1019
|
+
var z = c({ direction: "horizontal", cellCount: l, overscanCellsCount: s, scrollDirection: v, startIndex: typeof w.start == "number" ? w.start : 0, stopIndex: typeof w.stop == "number" ? w.stop : -1 }), I = c({ direction: "vertical", cellCount: h, overscanCellsCount: d, scrollDirection: m, startIndex: typeof C.start == "number" ? C.start : 0, stopIndex: typeof C.stop == "number" ? C.stop : -1 }), k = z.overscanStartIndex, P = z.overscanStopIndex, T = I.overscanStartIndex, L = I.overscanStopIndex;
|
|
1020
|
+
if (i) {
|
|
1021
|
+
if (!i.hasFixedHeight()) {
|
|
1022
|
+
for (var G = T; G <= L; G++) if (!i.has(G, 0)) {
|
|
1023
|
+
k = 0, P = l - 1;
|
|
1021
1024
|
break;
|
|
1022
1025
|
}
|
|
1023
1026
|
}
|
|
1024
|
-
if (!
|
|
1025
|
-
for (var
|
|
1026
|
-
|
|
1027
|
+
if (!i.hasFixedWidth()) {
|
|
1028
|
+
for (var B = k; B <= P; B++) if (!i.has(0, B)) {
|
|
1029
|
+
T = 0, L = h - 1;
|
|
1027
1030
|
break;
|
|
1028
1031
|
}
|
|
1029
1032
|
}
|
|
1030
1033
|
}
|
|
1031
|
-
this._childrenToDisplay = r({ cellCache: this._cellCache, cellRenderer: n, columnSizeAndPositionManager:
|
|
1034
|
+
this._childrenToDisplay = r({ cellCache: this._cellCache, cellRenderer: n, columnSizeAndPositionManager: _.columnSizeAndPositionManager, columnStartIndex: k, columnStopIndex: P, deferredMeasurementCache: i, horizontalOffsetAdjustment: b, isScrolling: g, isScrollingOptOut: u, parent: this, rowSizeAndPositionManager: _.rowSizeAndPositionManager, rowStartIndex: T, rowStopIndex: L, scrollLeft: y, scrollTop: S, styleCache: this._styleCache, verticalOffsetAdjustment: R, visibleColumnIndices: w, visibleRowIndices: C }), this._columnStartIndex = k, this._columnStopIndex = P, this._rowStartIndex = T, this._rowStopIndex = L;
|
|
1032
1035
|
}
|
|
1033
1036
|
} }, { key: "_debounceScrollEnded", value: function() {
|
|
1034
1037
|
var e = this.props.scrollingResetTimeInterval;
|
|
1035
|
-
this._disablePointerEventsTimeoutId &&
|
|
1038
|
+
this._disablePointerEventsTimeoutId && oe(this._disablePointerEventsTimeoutId), this._disablePointerEventsTimeoutId = Ge(this._debounceScrollEndedCallback, e);
|
|
1036
1039
|
} }, { key: "_handleInvalidatedGridSize", value: function() {
|
|
1037
1040
|
if (typeof this._deferredInvalidateColumnIndex == "number" && typeof this._deferredInvalidateRowIndex == "number") {
|
|
1038
1041
|
var e = this._deferredInvalidateColumnIndex, t = this._deferredInvalidateRowIndex;
|
|
1039
1042
|
this._deferredInvalidateColumnIndex = null, this._deferredInvalidateRowIndex = null, this.recomputeGridSize({ columnIndex: e, rowIndex: t });
|
|
1040
1043
|
}
|
|
1041
1044
|
} }, { key: "_invokeOnScrollMemoizer", value: function(e) {
|
|
1042
|
-
var t = this, n = e.scrollLeft, r = e.scrollTop,
|
|
1045
|
+
var t = this, n = e.scrollLeft, r = e.scrollTop, l = e.totalColumnsWidth, i = e.totalRowsHeight;
|
|
1043
1046
|
this._onScrollMemoizer({ callback: function(a) {
|
|
1044
1047
|
var s = a.scrollLeft, c = a.scrollTop, d = t.props, h = d.height;
|
|
1045
|
-
(0, d.onScroll)({ clientHeight: h, clientWidth: d.width, scrollHeight:
|
|
1048
|
+
(0, d.onScroll)({ clientHeight: h, clientWidth: d.width, scrollHeight: i, scrollLeft: s, scrollTop: c, scrollWidth: l });
|
|
1046
1049
|
}, indices: { scrollLeft: n, scrollTop: r } });
|
|
1047
1050
|
} }, { key: "_isScrolling", value: function() {
|
|
1048
1051
|
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : this.props, t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : this.state;
|
|
@@ -1067,9 +1070,9 @@ var tt = "requested", V = function() {
|
|
|
1067
1070
|
} }, { key: "_resetStyleCache", value: function() {
|
|
1068
1071
|
var e = this._styleCache, t = this._cellCache, n = this.props.isScrollingOptOut;
|
|
1069
1072
|
this._cellCache = {}, this._styleCache = {};
|
|
1070
|
-
for (var r = this._rowStartIndex; r <= this._rowStopIndex; r++) for (var
|
|
1071
|
-
var
|
|
1072
|
-
this._styleCache[
|
|
1073
|
+
for (var r = this._rowStartIndex; r <= this._rowStopIndex; r++) for (var l = this._columnStartIndex; l <= this._columnStopIndex; l++) {
|
|
1074
|
+
var i = "".concat(r, "-").concat(l);
|
|
1075
|
+
this._styleCache[i] = e[i], n && (this._cellCache[i] = t[i]);
|
|
1073
1076
|
}
|
|
1074
1077
|
} }, { key: "_updateScrollTopForScrollToRow", value: function() {
|
|
1075
1078
|
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : this.props, t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : this.state, n = o._getScrollTopForScrollToRowStateUpdate(e, t);
|
|
@@ -1077,42 +1080,42 @@ var tt = "requested", V = function() {
|
|
|
1077
1080
|
} }], [{ key: "getDerivedStateFromProps", value: function(e, t) {
|
|
1078
1081
|
var n = {};
|
|
1079
1082
|
e.columnCount === 0 && t.scrollLeft !== 0 || e.rowCount === 0 && t.scrollTop !== 0 ? (n.scrollLeft = 0, n.scrollTop = 0) : (e.scrollLeft !== t.scrollLeft && e.scrollToColumn < 0 || e.scrollTop !== t.scrollTop && e.scrollToRow < 0) && Object.assign(n, o._getScrollToPositionStateUpdate({ prevState: t, scrollLeft: e.scrollLeft, scrollTop: e.scrollTop }));
|
|
1080
|
-
var r,
|
|
1081
|
-
return n.needToResetStyleCache = !1, e.columnWidth ===
|
|
1082
|
-
return
|
|
1083
|
-
}, computeMetadataCallbackProps: e, nextCellsCount: e.columnCount, nextCellSize: typeof e.columnWidth == "number" ? e.columnWidth : null, nextScrollToIndex: e.scrollToColumn, scrollToIndex:
|
|
1083
|
+
var r, l, i = t.instanceProps;
|
|
1084
|
+
return n.needToResetStyleCache = !1, e.columnWidth === i.prevColumnWidth && e.rowHeight === i.prevRowHeight || (n.needToResetStyleCache = !0), i.columnSizeAndPositionManager.configure({ cellCount: e.columnCount, estimatedCellSize: o._getEstimatedColumnSize(e), cellSizeGetter: o._wrapSizeGetter(e.columnWidth) }), i.rowSizeAndPositionManager.configure({ cellCount: e.rowCount, estimatedCellSize: o._getEstimatedRowSize(e), cellSizeGetter: o._wrapSizeGetter(e.rowHeight) }), i.prevColumnCount !== 0 && i.prevRowCount !== 0 || (i.prevColumnCount = 0, i.prevRowCount = 0), e.autoHeight && e.isScrolling === !1 && i.prevIsScrolling === !0 && Object.assign(n, { isScrolling: !1 }), Ze({ cellCount: i.prevColumnCount, cellSize: typeof i.prevColumnWidth == "number" ? i.prevColumnWidth : null, computeMetadataCallback: function() {
|
|
1085
|
+
return i.columnSizeAndPositionManager.resetCell(0);
|
|
1086
|
+
}, computeMetadataCallbackProps: e, nextCellsCount: e.columnCount, nextCellSize: typeof e.columnWidth == "number" ? e.columnWidth : null, nextScrollToIndex: e.scrollToColumn, scrollToIndex: i.prevScrollToColumn, updateScrollOffsetForScrollToIndex: function() {
|
|
1084
1087
|
r = o._getScrollLeftForScrollToColumnStateUpdate(e, t);
|
|
1085
|
-
} }),
|
|
1086
|
-
return
|
|
1087
|
-
}, computeMetadataCallbackProps: e, nextCellsCount: e.rowCount, nextCellSize: typeof e.rowHeight == "number" ? e.rowHeight : null, nextScrollToIndex: e.scrollToRow, scrollToIndex:
|
|
1088
|
-
|
|
1089
|
-
} }),
|
|
1088
|
+
} }), Ze({ cellCount: i.prevRowCount, cellSize: typeof i.prevRowHeight == "number" ? i.prevRowHeight : null, computeMetadataCallback: function() {
|
|
1089
|
+
return i.rowSizeAndPositionManager.resetCell(0);
|
|
1090
|
+
}, computeMetadataCallbackProps: e, nextCellsCount: e.rowCount, nextCellSize: typeof e.rowHeight == "number" ? e.rowHeight : null, nextScrollToIndex: e.scrollToRow, scrollToIndex: i.prevScrollToRow, updateScrollOffsetForScrollToIndex: function() {
|
|
1091
|
+
l = o._getScrollTopForScrollToRowStateUpdate(e, t);
|
|
1092
|
+
} }), i.prevColumnCount = e.columnCount, i.prevColumnWidth = e.columnWidth, i.prevIsScrolling = e.isScrolling === !0, i.prevRowCount = e.rowCount, i.prevRowHeight = e.rowHeight, i.prevScrollToColumn = e.scrollToColumn, i.prevScrollToRow = e.scrollToRow, i.scrollbarSize = e.getScrollbarSize(), i.scrollbarSize === void 0 ? (i.scrollbarSizeMeasured = !1, i.scrollbarSize = 0) : i.scrollbarSizeMeasured = !0, n.instanceProps = i, j(j(j({}, n), r), l);
|
|
1090
1093
|
} }, { key: "_getEstimatedColumnSize", value: function(e) {
|
|
1091
1094
|
return typeof e.columnWidth == "number" ? e.columnWidth : e.estimatedColumnSize;
|
|
1092
1095
|
} }, { key: "_getEstimatedRowSize", value: function(e) {
|
|
1093
1096
|
return typeof e.rowHeight == "number" ? e.rowHeight : e.estimatedRowSize;
|
|
1094
1097
|
} }, { key: "_getScrollToPositionStateUpdate", value: function(e) {
|
|
1095
|
-
var t = e.prevState, n = e.scrollLeft, r = e.scrollTop,
|
|
1096
|
-
return typeof n == "number" && n >= 0 && (
|
|
1098
|
+
var t = e.prevState, n = e.scrollLeft, r = e.scrollTop, l = { scrollPositionChangeReason: nt };
|
|
1099
|
+
return typeof n == "number" && n >= 0 && (l.scrollDirectionHorizontal = n > t.scrollLeft ? 1 : -1, l.scrollLeft = n), typeof r == "number" && r >= 0 && (l.scrollDirectionVertical = r > t.scrollTop ? 1 : -1, l.scrollTop = r), typeof n == "number" && n >= 0 && n !== t.scrollLeft || typeof r == "number" && r >= 0 && r !== t.scrollTop ? l : {};
|
|
1097
1100
|
} }, { key: "_wrapSizeGetter", value: function(e) {
|
|
1098
1101
|
return typeof e == "function" ? e : function() {
|
|
1099
1102
|
return e;
|
|
1100
1103
|
};
|
|
1101
1104
|
} }, { key: "_getCalculatedScrollLeft", value: function(e, t) {
|
|
1102
|
-
var n = e.columnCount, r = e.height,
|
|
1105
|
+
var n = e.columnCount, r = e.height, l = e.scrollToAlignment, i = e.scrollToColumn, a = e.width, s = t.scrollLeft, c = t.instanceProps;
|
|
1103
1106
|
if (n > 0) {
|
|
1104
|
-
var d = n - 1, h =
|
|
1105
|
-
return c.columnSizeAndPositionManager.getUpdatedOffsetForIndex({ align:
|
|
1107
|
+
var d = n - 1, h = i < 0 ? d : Math.min(d, i), f = c.rowSizeAndPositionManager.getTotalSize(), u = c.scrollbarSizeMeasured && f > r ? c.scrollbarSize : 0;
|
|
1108
|
+
return c.columnSizeAndPositionManager.getUpdatedOffsetForIndex({ align: l, containerSize: a - u, currentOffset: s, targetIndex: h });
|
|
1106
1109
|
}
|
|
1107
1110
|
return 0;
|
|
1108
1111
|
} }, { key: "_getScrollLeftForScrollToColumnStateUpdate", value: function(e, t) {
|
|
1109
1112
|
var n = t.scrollLeft, r = o._getCalculatedScrollLeft(e, t);
|
|
1110
1113
|
return typeof r == "number" && r >= 0 && n !== r ? o._getScrollToPositionStateUpdate({ prevState: t, scrollLeft: r, scrollTop: -1 }) : {};
|
|
1111
1114
|
} }, { key: "_getCalculatedScrollTop", value: function(e, t) {
|
|
1112
|
-
var n = e.height, r = e.rowCount,
|
|
1115
|
+
var n = e.height, r = e.rowCount, l = e.scrollToAlignment, i = e.scrollToRow, a = e.width, s = t.scrollTop, c = t.instanceProps;
|
|
1113
1116
|
if (r > 0) {
|
|
1114
|
-
var d = r - 1, h =
|
|
1115
|
-
return c.rowSizeAndPositionManager.getUpdatedOffsetForIndex({ align:
|
|
1117
|
+
var d = r - 1, h = i < 0 ? d : Math.min(d, i), f = c.columnSizeAndPositionManager.getTotalSize(), u = c.scrollbarSizeMeasured && f > a ? c.scrollbarSize : 0;
|
|
1118
|
+
return c.rowSizeAndPositionManager.getUpdatedOffsetForIndex({ align: l, containerSize: n - u, currentOffset: s, targetIndex: h });
|
|
1116
1119
|
}
|
|
1117
1120
|
return 0;
|
|
1118
1121
|
} }, { key: "_getScrollTopForScrollToRowStateUpdate", value: function(e, t) {
|
|
@@ -1120,65 +1123,65 @@ var tt = "requested", V = function() {
|
|
|
1120
1123
|
return typeof r == "number" && r >= 0 && n !== r ? o._getScrollToPositionStateUpdate({ prevState: t, scrollLeft: -1, scrollTop: r }) : {};
|
|
1121
1124
|
} }]);
|
|
1122
1125
|
}();
|
|
1123
|
-
function
|
|
1124
|
-
var e = o.cellCount, t = o.overscanCellsCount, n = o.scrollDirection, r = o.startIndex,
|
|
1125
|
-
return t = Math.max(1, t), n === 1 ? { overscanStartIndex: Math.max(0, r - 1), overscanStopIndex: Math.min(e - 1,
|
|
1126
|
+
function Ht(o) {
|
|
1127
|
+
var e = o.cellCount, t = o.overscanCellsCount, n = o.scrollDirection, r = o.startIndex, l = o.stopIndex;
|
|
1128
|
+
return t = Math.max(1, t), n === 1 ? { overscanStartIndex: Math.max(0, r - 1), overscanStopIndex: Math.min(e - 1, l + t) } : { overscanStartIndex: Math.max(0, r - t), overscanStopIndex: Math.min(e - 1, l + 1) };
|
|
1126
1129
|
}
|
|
1127
|
-
function
|
|
1130
|
+
function ze(o, e) {
|
|
1128
1131
|
(e == null || e > o.length) && (e = o.length);
|
|
1129
1132
|
for (var t = 0, n = Array(e); t < e; t++) n[t] = o[t];
|
|
1130
1133
|
return n;
|
|
1131
1134
|
}
|
|
1132
|
-
function
|
|
1135
|
+
function Wt(o, e) {
|
|
1133
1136
|
if (o) {
|
|
1134
|
-
if (typeof o == "string") return
|
|
1137
|
+
if (typeof o == "string") return ze(o, e);
|
|
1135
1138
|
var t = {}.toString.call(o).slice(8, -1);
|
|
1136
|
-
return t === "Object" && o.constructor && (t = o.constructor.name), t === "Map" || t === "Set" ? Array.from(o) : t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ?
|
|
1139
|
+
return t === "Object" && o.constructor && (t = o.constructor.name), t === "Map" || t === "Set" ? Array.from(o) : t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? ze(o, e) : void 0;
|
|
1137
1140
|
}
|
|
1138
1141
|
}
|
|
1139
|
-
function
|
|
1142
|
+
function Dt() {
|
|
1140
1143
|
try {
|
|
1141
1144
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
1142
1145
|
}));
|
|
1143
1146
|
} catch {
|
|
1144
1147
|
}
|
|
1145
|
-
return (
|
|
1148
|
+
return (Dt = function() {
|
|
1146
1149
|
return !!o;
|
|
1147
1150
|
})();
|
|
1148
1151
|
}
|
|
1149
|
-
p(
|
|
1150
|
-
for (var e = o.cellCache, t = o.cellRenderer, n = o.columnSizeAndPositionManager, r = o.columnStartIndex,
|
|
1151
|
-
var
|
|
1152
|
-
|
|
1153
|
-
var
|
|
1154
|
-
!c && !s || a ||
|
|
1152
|
+
p($, "defaultProps", { "aria-label": "grid", "aria-readonly": !0, autoContainerWidth: !1, autoHeight: !1, autoWidth: !1, cellRangeRenderer: function(o) {
|
|
1153
|
+
for (var e = o.cellCache, t = o.cellRenderer, n = o.columnSizeAndPositionManager, r = o.columnStartIndex, l = o.columnStopIndex, i = o.deferredMeasurementCache, a = o.horizontalOffsetAdjustment, s = o.isScrolling, c = o.isScrollingOptOut, d = o.parent, h = o.rowSizeAndPositionManager, f = o.rowStartIndex, u = o.rowStopIndex, v = o.styleCache, m = o.verticalOffsetAdjustment, _ = o.visibleColumnIndices, S = o.visibleRowIndices, y = [], g = n.areOffsetsAdjusted() || h.areOffsetsAdjusted(), w = !s && !g, C = f; C <= u; C++) for (var b = h.getSizeAndPositionOfCell(C), R = r; R <= l; R++) {
|
|
1154
|
+
var z = n.getSizeAndPositionOfCell(R), I = R >= _.start && R <= _.stop && C >= S.start && C <= S.stop, k = "".concat(C, "-").concat(R), P = void 0;
|
|
1155
|
+
w && v[k] ? P = v[k] : i && !i.has(C, R) ? P = { height: "auto", left: 0, position: "absolute", top: 0, width: "auto" } : (P = { height: b.size, left: z.offset + a, position: "absolute", top: b.offset + m, width: z.size }, v[k] = P);
|
|
1156
|
+
var T = { columnIndex: R, isScrolling: s, isVisible: I, key: k, parent: d, rowIndex: C, style: P }, L = void 0;
|
|
1157
|
+
!c && !s || a || m ? L = t(T) : (e[k] || (e[k] = t(T)), L = e[k]), L != null && L !== !1 && (L.props.role || (L = Ct.cloneElement(L, { role: "gridcell" })), y.push(L));
|
|
1155
1158
|
}
|
|
1156
1159
|
return y;
|
|
1157
|
-
}, containerRole: "row", containerStyle: {}, estimatedColumnSize: 100, estimatedRowSize: 30, getScrollbarSize:
|
|
1160
|
+
}, containerRole: "row", containerStyle: {}, estimatedColumnSize: 100, estimatedRowSize: 30, getScrollbarSize: Te, noContentRenderer: function() {
|
|
1158
1161
|
return null;
|
|
1159
1162
|
}, onScroll: function() {
|
|
1160
1163
|
}, onScrollbarPresenceChange: function() {
|
|
1161
1164
|
}, onSectionRendered: function() {
|
|
1162
1165
|
}, overscanColumnCount: 0, overscanIndicesGetter: function(o) {
|
|
1163
|
-
var e = o.cellCount, t = o.overscanCellsCount, n = o.scrollDirection, r = o.startIndex,
|
|
1164
|
-
return n === 1 ? { overscanStartIndex: Math.max(0, r), overscanStopIndex: Math.min(e - 1,
|
|
1165
|
-
}, overscanRowCount: 10, role: "grid", scrollingResetTimeInterval: 150, scrollToAlignment: "auto", scrollToColumn: -1, scrollToRow: -1, style: {}, tabIndex: 0, isScrollingOptOut: !1 }),
|
|
1166
|
-
var
|
|
1166
|
+
var e = o.cellCount, t = o.overscanCellsCount, n = o.scrollDirection, r = o.startIndex, l = o.stopIndex;
|
|
1167
|
+
return n === 1 ? { overscanStartIndex: Math.max(0, r), overscanStopIndex: Math.min(e - 1, l + t) } : { overscanStartIndex: Math.max(0, r - t), overscanStopIndex: Math.min(e - 1, l) };
|
|
1168
|
+
}, overscanRowCount: 10, role: "grid", scrollingResetTimeInterval: 150, scrollToAlignment: "auto", scrollToColumn: -1, scrollToRow: -1, style: {}, tabIndex: 0, isScrollingOptOut: !1 }), ue($);
|
|
1169
|
+
var rt = function() {
|
|
1167
1170
|
function o(e, t) {
|
|
1168
|
-
var n, r,
|
|
1169
|
-
return
|
|
1171
|
+
var n, r, l, i;
|
|
1172
|
+
return A(this, o), r = this, i = [e, t], l = O(l = o), (n = W(r, Dt() ? Reflect.construct(l, i || [], O(r).constructor) : l.apply(r, i)))._loadMoreRowsMemoizer = te(), n._onRowsRendered = n._onRowsRendered.bind(n), n._registerChild = n._registerChild.bind(n), n;
|
|
1170
1173
|
}
|
|
1171
|
-
return D(o, x.PureComponent),
|
|
1172
|
-
this._loadMoreRowsMemoizer =
|
|
1174
|
+
return D(o, x.PureComponent), E(o, [{ key: "resetLoadMoreRowsCache", value: function(e) {
|
|
1175
|
+
this._loadMoreRowsMemoizer = te(), e && this._doStuff(this._lastRenderedStartIndex, this._lastRenderedStopIndex);
|
|
1173
1176
|
} }, { key: "render", value: function() {
|
|
1174
1177
|
return (0, this.props.children)({ onRowsRendered: this._onRowsRendered, registerChild: this._registerChild });
|
|
1175
1178
|
} }, { key: "_loadUnloadedRanges", value: function(e) {
|
|
1176
1179
|
var t = this, n = this.props.loadMoreRows;
|
|
1177
1180
|
e.forEach(function(r) {
|
|
1178
|
-
var
|
|
1179
|
-
|
|
1180
|
-
var
|
|
1181
|
-
(
|
|
1181
|
+
var l = n(r);
|
|
1182
|
+
l && l.then(function() {
|
|
1183
|
+
var i;
|
|
1184
|
+
(i = { lastRenderedStartIndex: t._lastRenderedStartIndex, lastRenderedStopIndex: t._lastRenderedStopIndex, startIndex: r.startIndex, stopIndex: r.stopIndex }).startIndex > i.lastRenderedStopIndex || i.stopIndex < i.lastRenderedStartIndex || t._registeredChild && function(a) {
|
|
1182
1185
|
var s = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0, c = typeof a.recomputeGridSize == "function" ? a.recomputeGridSize : a.recomputeRowHeights;
|
|
1183
1186
|
c ? c.call(a, s) : a.forceUpdate();
|
|
1184
1187
|
}(t._registeredChild, t._lastRenderedStartIndex);
|
|
@@ -1188,24 +1191,24 @@ var ot = function() {
|
|
|
1188
1191
|
var t = e.startIndex, n = e.stopIndex;
|
|
1189
1192
|
this._lastRenderedStartIndex = t, this._lastRenderedStopIndex = n, this._doStuff(t, n);
|
|
1190
1193
|
} }, { key: "_doStuff", value: function(e, t) {
|
|
1191
|
-
var n, r = this,
|
|
1192
|
-
for (var u = f.isRowLoaded,
|
|
1193
|
-
if (
|
|
1194
|
-
for (var
|
|
1195
|
-
S.push({ startIndex: y, stopIndex:
|
|
1194
|
+
var n, r = this, l = this.props, i = l.isRowLoaded, a = l.minimumBatchSize, s = l.rowCount, c = l.threshold, d = function(f) {
|
|
1195
|
+
for (var u = f.isRowLoaded, v = f.minimumBatchSize, m = f.rowCount, _ = f.stopIndex, S = [], y = null, g = null, w = f.startIndex; w <= _; w++) u({ index: w }) ? g !== null && (S.push({ startIndex: y, stopIndex: g }), y = g = null) : (g = w, y === null && (y = w));
|
|
1196
|
+
if (g !== null) {
|
|
1197
|
+
for (var C = Math.min(Math.max(g, y + v - 1), m - 1), b = g + 1; b <= C && !u({ index: b }); b++) g = b;
|
|
1198
|
+
S.push({ startIndex: y, stopIndex: g });
|
|
1196
1199
|
}
|
|
1197
|
-
if (S.length) for (var
|
|
1198
|
-
var
|
|
1199
|
-
if (u({ index:
|
|
1200
|
-
|
|
1200
|
+
if (S.length) for (var R = S[0]; R.stopIndex - R.startIndex + 1 < v && R.startIndex > 0; ) {
|
|
1201
|
+
var z = R.startIndex - 1;
|
|
1202
|
+
if (u({ index: z })) break;
|
|
1203
|
+
R.startIndex = z;
|
|
1201
1204
|
}
|
|
1202
1205
|
return S;
|
|
1203
|
-
}({ isRowLoaded:
|
|
1206
|
+
}({ isRowLoaded: i, minimumBatchSize: a, rowCount: s, startIndex: Math.max(0, e - c), stopIndex: Math.min(s - 1, t + c) }), h = (n = []).concat.apply(n, function(f) {
|
|
1204
1207
|
return function(u) {
|
|
1205
|
-
if (Array.isArray(u)) return
|
|
1208
|
+
if (Array.isArray(u)) return ze(u);
|
|
1206
1209
|
}(f) || function(u) {
|
|
1207
1210
|
if (typeof Symbol < "u" && u[Symbol.iterator] != null || u["@@iterator"] != null) return Array.from(u);
|
|
1208
|
-
}(f) ||
|
|
1211
|
+
}(f) || Wt(f) || function() {
|
|
1209
1212
|
throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
1210
1213
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
1211
1214
|
}();
|
|
@@ -1219,25 +1222,25 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
1219
1222
|
this._registeredChild = e;
|
|
1220
1223
|
} }]);
|
|
1221
1224
|
}();
|
|
1222
|
-
function
|
|
1225
|
+
function jt() {
|
|
1223
1226
|
try {
|
|
1224
1227
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
1225
1228
|
}));
|
|
1226
1229
|
} catch {
|
|
1227
1230
|
}
|
|
1228
|
-
return (
|
|
1231
|
+
return (jt = function() {
|
|
1229
1232
|
return !!o;
|
|
1230
1233
|
})();
|
|
1231
1234
|
}
|
|
1232
|
-
p(
|
|
1233
|
-
var
|
|
1235
|
+
p(rt, "defaultProps", { minimumBatchSize: 10, rowCount: 0, threshold: 15 }), rt.propTypes = {};
|
|
1236
|
+
var Yo = function() {
|
|
1234
1237
|
function o() {
|
|
1235
1238
|
var e, t, n, r;
|
|
1236
|
-
|
|
1237
|
-
for (var
|
|
1238
|
-
return t = this, n = o, r = [].concat(
|
|
1239
|
-
var c = s.parent, d = s.rowIndex, h = s.style, f = s.isScrolling, u = s.isVisible,
|
|
1240
|
-
return
|
|
1239
|
+
A(this, o);
|
|
1240
|
+
for (var l = arguments.length, i = new Array(l), a = 0; a < l; a++) i[a] = arguments[a];
|
|
1241
|
+
return t = this, n = o, r = [].concat(i), n = O(n), p(e = W(t, jt() ? Reflect.construct(n, r || [], O(t).constructor) : n.apply(t, r)), "Grid", void 0), p(e, "_cellRenderer", function(s) {
|
|
1242
|
+
var c = s.parent, d = s.rowIndex, h = s.style, f = s.isScrolling, u = s.isVisible, v = s.key, m = e.props.rowRenderer, _ = Object.getOwnPropertyDescriptor(h, "width");
|
|
1243
|
+
return _ && _.writable && (h.width = "100%"), m({ index: d, style: h, isScrolling: f, isVisible: u, key: v, parent: c });
|
|
1241
1244
|
}), p(e, "_setRef", function(s) {
|
|
1242
1245
|
e.Grid = s;
|
|
1243
1246
|
}), p(e, "_onScroll", function(s) {
|
|
@@ -1248,7 +1251,7 @@ var Ko = function() {
|
|
|
1248
1251
|
(0, e.props.onRowsRendered)({ overscanStartIndex: c, overscanStopIndex: d, startIndex: h, stopIndex: f });
|
|
1249
1252
|
}), e;
|
|
1250
1253
|
}
|
|
1251
|
-
return D(o, x.PureComponent),
|
|
1254
|
+
return D(o, x.PureComponent), E(o, [{ key: "forceUpdateGrid", value: function() {
|
|
1252
1255
|
this.Grid && this.Grid.forceUpdate();
|
|
1253
1256
|
} }, { key: "getOffsetForRow", value: function(e) {
|
|
1254
1257
|
var t = e.alignment, n = e.index;
|
|
@@ -1259,8 +1262,8 @@ var Ko = function() {
|
|
|
1259
1262
|
} }, { key: "measureAllRows", value: function() {
|
|
1260
1263
|
this.Grid && this.Grid.measureAllCells();
|
|
1261
1264
|
} }, { key: "recomputeGridSize", value: function() {
|
|
1262
|
-
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.columnIndex, n = t === void 0 ? 0 : t, r = e.rowIndex,
|
|
1263
|
-
this.Grid && this.Grid.recomputeGridSize({ rowIndex:
|
|
1265
|
+
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.columnIndex, n = t === void 0 ? 0 : t, r = e.rowIndex, l = r === void 0 ? 0 : r;
|
|
1266
|
+
this.Grid && this.Grid.recomputeGridSize({ rowIndex: l, columnIndex: n });
|
|
1264
1267
|
} }, { key: "recomputeRowHeights", value: function() {
|
|
1265
1268
|
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0;
|
|
1266
1269
|
this.Grid && this.Grid.recomputeGridSize({ rowIndex: e, columnIndex: 0 });
|
|
@@ -1271,188 +1274,188 @@ var Ko = function() {
|
|
|
1271
1274
|
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0;
|
|
1272
1275
|
this.Grid && this.Grid.scrollToCell({ columnIndex: 0, rowIndex: e });
|
|
1273
1276
|
} }, { key: "render", value: function() {
|
|
1274
|
-
var e = this.props, t = e.className, n = e.noRowsRenderer, r = e.scrollToIndex,
|
|
1275
|
-
return x.createElement(V
|
|
1277
|
+
var e = this.props, t = e.className, n = e.noRowsRenderer, r = e.scrollToIndex, l = e.width, i = N("ReactVirtualized__List", t);
|
|
1278
|
+
return x.createElement($, V({}, this.props, { autoContainerWidth: !0, cellRenderer: this._cellRenderer, className: i, columnWidth: l, columnCount: 1, noContentRenderer: n, onScroll: this._onScroll, onSectionRendered: this._onSectionRendered, ref: this._setRef, scrollToRow: r }));
|
|
1276
1279
|
} }]);
|
|
1277
1280
|
}();
|
|
1278
|
-
p(
|
|
1281
|
+
p(Yo, "defaultProps", { autoHeight: !1, estimatedRowSize: 30, onScroll: function() {
|
|
1279
1282
|
}, noRowsRenderer: function() {
|
|
1280
1283
|
return null;
|
|
1281
1284
|
}, onRowsRendered: function() {
|
|
1282
|
-
}, overscanIndicesGetter:
|
|
1283
|
-
const
|
|
1284
|
-
return typeof t == "function" ? function(
|
|
1285
|
-
for (var d = a + 1;
|
|
1286
|
-
var h =
|
|
1287
|
-
c(
|
|
1285
|
+
}, overscanIndicesGetter: Ht, overscanRowCount: 10, scrollToAlignment: "auto", scrollToIndex: -1, style: {} });
|
|
1286
|
+
const ge = function(o, e, t, n, r) {
|
|
1287
|
+
return typeof t == "function" ? function(l, i, a, s, c) {
|
|
1288
|
+
for (var d = a + 1; i <= a; ) {
|
|
1289
|
+
var h = i + a >>> 1;
|
|
1290
|
+
c(l[h], s) >= 0 ? (d = h, a = h - 1) : i = h + 1;
|
|
1288
1291
|
}
|
|
1289
1292
|
return d;
|
|
1290
|
-
}(o, n === void 0 ? 0 : 0 | n, r === void 0 ? o.length - 1 : 0 | r, e, t) : function(
|
|
1291
|
-
for (var c = a + 1;
|
|
1292
|
-
var d =
|
|
1293
|
-
|
|
1293
|
+
}(o, n === void 0 ? 0 : 0 | n, r === void 0 ? o.length - 1 : 0 | r, e, t) : function(l, i, a, s) {
|
|
1294
|
+
for (var c = a + 1; i <= a; ) {
|
|
1295
|
+
var d = i + a >>> 1;
|
|
1296
|
+
l[d] >= s ? (c = d, a = d - 1) : i = d + 1;
|
|
1294
1297
|
}
|
|
1295
1298
|
return c;
|
|
1296
1299
|
}(o, t === void 0 ? 0 : 0 | t, n === void 0 ? o.length - 1 : 0 | n, e);
|
|
1297
1300
|
};
|
|
1298
|
-
function
|
|
1301
|
+
function Ae(o, e, t, n, r) {
|
|
1299
1302
|
this.mid = o, this.left = e, this.right = t, this.leftPoints = n, this.rightPoints = r, this.count = (e ? e.count : 0) + (t ? t.count : 0) + n.length;
|
|
1300
1303
|
}
|
|
1301
|
-
var
|
|
1302
|
-
function
|
|
1304
|
+
var re = Ae.prototype;
|
|
1305
|
+
function Ce(o, e) {
|
|
1303
1306
|
o.mid = e.mid, o.left = e.left, o.right = e.right, o.leftPoints = e.leftPoints, o.rightPoints = e.rightPoints, o.count = e.count;
|
|
1304
1307
|
}
|
|
1305
|
-
function
|
|
1306
|
-
var t =
|
|
1308
|
+
function Ft(o, e) {
|
|
1309
|
+
var t = ce(e);
|
|
1307
1310
|
o.mid = t.mid, o.left = t.left, o.right = t.right, o.leftPoints = t.leftPoints, o.rightPoints = t.rightPoints, o.count = t.count;
|
|
1308
1311
|
}
|
|
1309
|
-
function
|
|
1312
|
+
function it(o, e) {
|
|
1310
1313
|
var t = o.intervals([]);
|
|
1311
|
-
t.push(e),
|
|
1314
|
+
t.push(e), Ft(o, t);
|
|
1312
1315
|
}
|
|
1313
|
-
function
|
|
1316
|
+
function lt(o, e) {
|
|
1314
1317
|
var t = o.intervals([]), n = t.indexOf(e);
|
|
1315
|
-
return n < 0 ? 0 : (t.splice(n, 1),
|
|
1318
|
+
return n < 0 ? 0 : (t.splice(n, 1), Ft(o, t), 1);
|
|
1316
1319
|
}
|
|
1317
|
-
function
|
|
1320
|
+
function st(o, e, t) {
|
|
1318
1321
|
for (var n = 0; n < o.length && o[n][0] <= e; ++n) {
|
|
1319
1322
|
var r = t(o[n]);
|
|
1320
1323
|
if (r) return r;
|
|
1321
1324
|
}
|
|
1322
1325
|
}
|
|
1323
|
-
function
|
|
1326
|
+
function at(o, e, t) {
|
|
1324
1327
|
for (var n = o.length - 1; n >= 0 && o[n][1] >= e; --n) {
|
|
1325
1328
|
var r = t(o[n]);
|
|
1326
1329
|
if (r) return r;
|
|
1327
1330
|
}
|
|
1328
1331
|
}
|
|
1329
|
-
function
|
|
1332
|
+
function ct(o, e) {
|
|
1330
1333
|
for (var t = 0; t < o.length; ++t) {
|
|
1331
1334
|
var n = e(o[t]);
|
|
1332
1335
|
if (n) return n;
|
|
1333
1336
|
}
|
|
1334
1337
|
}
|
|
1335
|
-
function
|
|
1338
|
+
function Jo(o, e) {
|
|
1336
1339
|
return o - e;
|
|
1337
1340
|
}
|
|
1338
|
-
function
|
|
1341
|
+
function Ie(o, e) {
|
|
1339
1342
|
return o[0] - e[0] || o[1] - e[1];
|
|
1340
1343
|
}
|
|
1341
|
-
function
|
|
1344
|
+
function Pe(o, e) {
|
|
1342
1345
|
return o[1] - e[1] || o[0] - e[0];
|
|
1343
1346
|
}
|
|
1344
|
-
function
|
|
1347
|
+
function ce(o) {
|
|
1345
1348
|
if (o.length === 0) return null;
|
|
1346
1349
|
for (var e = [], t = 0; t < o.length; ++t) e.push(o[t][0], o[t][1]);
|
|
1347
|
-
e.sort(
|
|
1348
|
-
var n = e[e.length >> 1], r = [],
|
|
1350
|
+
e.sort(Jo);
|
|
1351
|
+
var n = e[e.length >> 1], r = [], l = [], i = [];
|
|
1349
1352
|
for (t = 0; t < o.length; ++t) {
|
|
1350
1353
|
var a = o[t];
|
|
1351
|
-
a[1] < n ? r.push(a) : n < a[0] ?
|
|
1354
|
+
a[1] < n ? r.push(a) : n < a[0] ? l.push(a) : i.push(a);
|
|
1352
1355
|
}
|
|
1353
|
-
var s =
|
|
1354
|
-
return s.sort(
|
|
1356
|
+
var s = i, c = i.slice();
|
|
1357
|
+
return s.sort(Ie), c.sort(Pe), new Ae(n, ce(r), ce(l), s, c);
|
|
1355
1358
|
}
|
|
1356
|
-
function
|
|
1359
|
+
function Nt(o) {
|
|
1357
1360
|
this.root = o;
|
|
1358
1361
|
}
|
|
1359
|
-
|
|
1362
|
+
re.intervals = function(o) {
|
|
1360
1363
|
return o.push.apply(o, this.leftPoints), this.left && this.left.intervals(o), this.right && this.right.intervals(o), o;
|
|
1361
|
-
},
|
|
1364
|
+
}, re.insert = function(o) {
|
|
1362
1365
|
var e = this.count - this.leftPoints.length;
|
|
1363
|
-
if (this.count += 1, o[1] < this.mid) this.left ? 4 * (this.left.count + 1) > 3 * (e + 1) ?
|
|
1364
|
-
else if (o[0] > this.mid) this.right ? 4 * (this.right.count + 1) > 3 * (e + 1) ?
|
|
1366
|
+
if (this.count += 1, o[1] < this.mid) this.left ? 4 * (this.left.count + 1) > 3 * (e + 1) ? it(this, o) : this.left.insert(o) : this.left = ce([o]);
|
|
1367
|
+
else if (o[0] > this.mid) this.right ? 4 * (this.right.count + 1) > 3 * (e + 1) ? it(this, o) : this.right.insert(o) : this.right = ce([o]);
|
|
1365
1368
|
else {
|
|
1366
|
-
var t =
|
|
1369
|
+
var t = ge(this.leftPoints, o, Ie), n = ge(this.rightPoints, o, Pe);
|
|
1367
1370
|
this.leftPoints.splice(t, 0, o), this.rightPoints.splice(n, 0, o);
|
|
1368
1371
|
}
|
|
1369
|
-
},
|
|
1372
|
+
}, re.remove = function(o) {
|
|
1370
1373
|
var e = this.count - this.leftPoints;
|
|
1371
|
-
if (o[1] < this.mid) return this.left ? 4 * (this.right ? this.right.count : 0) > 3 * (e - 1) ?
|
|
1372
|
-
if (o[0] > this.mid) return this.right ? 4 * (this.left ? this.left.count : 0) > 3 * (e - 1) ?
|
|
1374
|
+
if (o[1] < this.mid) return this.left ? 4 * (this.right ? this.right.count : 0) > 3 * (e - 1) ? lt(this, o) : (l = this.left.remove(o)) === 2 ? (this.left = null, this.count -= 1, 1) : (l === 1 && (this.count -= 1), l) : 0;
|
|
1375
|
+
if (o[0] > this.mid) return this.right ? 4 * (this.left ? this.left.count : 0) > 3 * (e - 1) ? lt(this, o) : (l = this.right.remove(o)) === 2 ? (this.right = null, this.count -= 1, 1) : (l === 1 && (this.count -= 1), l) : 0;
|
|
1373
1376
|
if (this.count === 1) return this.leftPoints[0] === o ? 2 : 0;
|
|
1374
1377
|
if (this.leftPoints.length === 1 && this.leftPoints[0] === o) {
|
|
1375
1378
|
if (this.left && this.right) {
|
|
1376
1379
|
for (var t = this, n = this.left; n.right; ) t = n, n = n.right;
|
|
1377
1380
|
if (t === this) n.right = this.right;
|
|
1378
1381
|
else {
|
|
1379
|
-
var r = this.left,
|
|
1380
|
-
t.count -= n.count, t.right = n.left, n.left = r, n.right =
|
|
1382
|
+
var r = this.left, l = this.right;
|
|
1383
|
+
t.count -= n.count, t.right = n.left, n.left = r, n.right = l;
|
|
1381
1384
|
}
|
|
1382
|
-
|
|
1383
|
-
} else this.left ?
|
|
1385
|
+
Ce(this, n), this.count = (this.left ? this.left.count : 0) + (this.right ? this.right.count : 0) + this.leftPoints.length;
|
|
1386
|
+
} else this.left ? Ce(this, this.left) : Ce(this, this.right);
|
|
1384
1387
|
return 1;
|
|
1385
1388
|
}
|
|
1386
|
-
for (r =
|
|
1387
|
-
for (this.count -= 1, this.leftPoints.splice(r, 1),
|
|
1389
|
+
for (r = ge(this.leftPoints, o, Ie); r < this.leftPoints.length && this.leftPoints[r][0] === o[0]; ++r) if (this.leftPoints[r] === o) {
|
|
1390
|
+
for (this.count -= 1, this.leftPoints.splice(r, 1), l = ge(this.rightPoints, o, Pe); l < this.rightPoints.length && this.rightPoints[l][1] === o[1]; ++l) if (this.rightPoints[l] === o) return this.rightPoints.splice(l, 1), 1;
|
|
1388
1391
|
}
|
|
1389
1392
|
return 0;
|
|
1390
|
-
},
|
|
1391
|
-
return o < this.mid ? this.left && (t = this.left.queryPoint(o, e)) ? t :
|
|
1393
|
+
}, re.queryPoint = function(o, e) {
|
|
1394
|
+
return o < this.mid ? this.left && (t = this.left.queryPoint(o, e)) ? t : st(this.leftPoints, o, e) : o > this.mid ? this.right && (t = this.right.queryPoint(o, e)) ? t : at(this.rightPoints, o, e) : ct(this.leftPoints, e);
|
|
1392
1395
|
var t;
|
|
1393
|
-
},
|
|
1396
|
+
}, re.queryInterval = function(o, e, t) {
|
|
1394
1397
|
var n;
|
|
1395
|
-
return o < this.mid && this.left && (n = this.left.queryInterval(o, e, t)) || e > this.mid && this.right && (n = this.right.queryInterval(o, e, t)) ? n : e < this.mid ?
|
|
1398
|
+
return o < this.mid && this.left && (n = this.left.queryInterval(o, e, t)) || e > this.mid && this.right && (n = this.right.queryInterval(o, e, t)) ? n : e < this.mid ? st(this.leftPoints, e, t) : o > this.mid ? at(this.rightPoints, o, t) : ct(this.leftPoints, t);
|
|
1396
1399
|
};
|
|
1397
|
-
var
|
|
1398
|
-
|
|
1399
|
-
this.root ? this.root.insert(o) : this.root = new
|
|
1400
|
-
},
|
|
1400
|
+
var J = Nt.prototype;
|
|
1401
|
+
J.insert = function(o) {
|
|
1402
|
+
this.root ? this.root.insert(o) : this.root = new Ae(o[0], null, null, [o], [o]);
|
|
1403
|
+
}, J.remove = function(o) {
|
|
1401
1404
|
if (this.root) {
|
|
1402
1405
|
var e = this.root.remove(o);
|
|
1403
1406
|
return e === 2 && (this.root = null), e !== 0;
|
|
1404
1407
|
}
|
|
1405
1408
|
return !1;
|
|
1406
|
-
},
|
|
1409
|
+
}, J.queryPoint = function(o, e) {
|
|
1407
1410
|
if (this.root) return this.root.queryPoint(o, e);
|
|
1408
|
-
},
|
|
1411
|
+
}, J.queryInterval = function(o, e, t) {
|
|
1409
1412
|
if (o <= e && this.root) return this.root.queryInterval(o, e, t);
|
|
1410
|
-
}, Object.defineProperty(
|
|
1413
|
+
}, Object.defineProperty(J, "count", { get: function() {
|
|
1411
1414
|
return this.root ? this.root.count : 0;
|
|
1412
|
-
} }), Object.defineProperty(
|
|
1415
|
+
} }), Object.defineProperty(J, "intervals", { get: function() {
|
|
1413
1416
|
return this.root ? this.root.intervals([]) : [];
|
|
1414
1417
|
} });
|
|
1415
|
-
var
|
|
1416
|
-
|
|
1418
|
+
var xe = E(function o() {
|
|
1419
|
+
A(this, o), p(this, "_columnSizeMap", {}), p(this, "_intervalTree", new Nt(null)), p(this, "_leftMap", {});
|
|
1417
1420
|
}, [{ key: "estimateTotalHeight", value: function(o, e, t) {
|
|
1418
1421
|
var n = o - this.count;
|
|
1419
1422
|
return this.tallestColumnSize + Math.ceil(n / e) * t;
|
|
1420
1423
|
} }, { key: "range", value: function(o, e, t) {
|
|
1421
1424
|
var n = this;
|
|
1422
1425
|
this._intervalTree.queryInterval(o, o + e, function(r) {
|
|
1423
|
-
var
|
|
1426
|
+
var l = function(s, c) {
|
|
1424
1427
|
return function(d) {
|
|
1425
1428
|
if (Array.isArray(d)) return d;
|
|
1426
1429
|
}(s) || function(d, h) {
|
|
1427
1430
|
var f = d == null ? null : typeof Symbol < "u" && d[Symbol.iterator] || d["@@iterator"];
|
|
1428
1431
|
if (f != null) {
|
|
1429
|
-
var u,
|
|
1432
|
+
var u, v, m, _, S = [], y = !0, g = !1;
|
|
1430
1433
|
try {
|
|
1431
|
-
if (
|
|
1432
|
-
} catch (
|
|
1433
|
-
|
|
1434
|
+
if (m = (f = f.call(d)).next, h !== 0) for (; !(y = (u = m.call(f)).done) && (S.push(u.value), S.length !== h); y = !0) ;
|
|
1435
|
+
} catch (w) {
|
|
1436
|
+
g = !0, v = w;
|
|
1434
1437
|
} finally {
|
|
1435
1438
|
try {
|
|
1436
|
-
if (!y && f.return != null && (
|
|
1439
|
+
if (!y && f.return != null && (_ = f.return(), Object(_) !== _)) return;
|
|
1437
1440
|
} finally {
|
|
1438
|
-
if (
|
|
1441
|
+
if (g) throw v;
|
|
1439
1442
|
}
|
|
1440
1443
|
}
|
|
1441
1444
|
return S;
|
|
1442
1445
|
}
|
|
1443
|
-
}(s, c) ||
|
|
1446
|
+
}(s, c) || Wt(s, c) || function() {
|
|
1444
1447
|
throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
1445
1448
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
1446
1449
|
}();
|
|
1447
|
-
}(r, 3),
|
|
1448
|
-
|
|
1449
|
-
var a =
|
|
1450
|
-
return t(a, n._leftMap[a],
|
|
1450
|
+
}(r, 3), i = l[0];
|
|
1451
|
+
l[1];
|
|
1452
|
+
var a = l[2];
|
|
1453
|
+
return t(a, n._leftMap[a], i);
|
|
1451
1454
|
});
|
|
1452
1455
|
} }, { key: "setPosition", value: function(o, e, t, n) {
|
|
1453
1456
|
this._intervalTree.insert([t, t + n, o]), this._leftMap[o] = e;
|
|
1454
|
-
var r = this._columnSizeMap,
|
|
1455
|
-
r[e] =
|
|
1457
|
+
var r = this._columnSizeMap, l = r[e];
|
|
1458
|
+
r[e] = l === void 0 ? t + n : Math.max(l, t + n);
|
|
1456
1459
|
} }, { key: "count", get: function() {
|
|
1457
1460
|
return this._intervalTree.count;
|
|
1458
1461
|
} }, { key: "shortestColumnSize", get: function() {
|
|
@@ -1470,7 +1473,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
1470
1473
|
}
|
|
1471
1474
|
return e;
|
|
1472
1475
|
} }]);
|
|
1473
|
-
function
|
|
1476
|
+
function dt(o, e) {
|
|
1474
1477
|
var t = Object.keys(o);
|
|
1475
1478
|
if (Object.getOwnPropertySymbols) {
|
|
1476
1479
|
var n = Object.getOwnPropertySymbols(o);
|
|
@@ -1480,33 +1483,33 @@ function at(o, e) {
|
|
|
1480
1483
|
}
|
|
1481
1484
|
return t;
|
|
1482
1485
|
}
|
|
1483
|
-
function
|
|
1486
|
+
function Zo(o) {
|
|
1484
1487
|
for (var e = 1; e < arguments.length; e++) {
|
|
1485
1488
|
var t = arguments[e] != null ? arguments[e] : {};
|
|
1486
|
-
e % 2 ?
|
|
1489
|
+
e % 2 ? dt(Object(t), !0).forEach(function(n) {
|
|
1487
1490
|
p(o, n, t[n]);
|
|
1488
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) :
|
|
1491
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) : dt(Object(t)).forEach(function(n) {
|
|
1489
1492
|
Object.defineProperty(o, n, Object.getOwnPropertyDescriptor(t, n));
|
|
1490
1493
|
});
|
|
1491
1494
|
}
|
|
1492
1495
|
return o;
|
|
1493
1496
|
}
|
|
1494
|
-
function
|
|
1497
|
+
function Bt() {
|
|
1495
1498
|
try {
|
|
1496
1499
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
1497
1500
|
}));
|
|
1498
1501
|
} catch {
|
|
1499
1502
|
}
|
|
1500
|
-
return (
|
|
1503
|
+
return (Bt = function() {
|
|
1501
1504
|
return !!o;
|
|
1502
1505
|
})();
|
|
1503
1506
|
}
|
|
1504
|
-
var
|
|
1507
|
+
var ut = function() {
|
|
1505
1508
|
function o() {
|
|
1506
1509
|
var e, t, n, r;
|
|
1507
|
-
|
|
1508
|
-
for (var
|
|
1509
|
-
return t = this, n = o, r = [].concat(
|
|
1510
|
+
A(this, o);
|
|
1511
|
+
for (var l = arguments.length, i = new Array(l), a = 0; a < l; a++) i[a] = arguments[a];
|
|
1512
|
+
return t = this, n = o, r = [].concat(i), n = O(n), p(e = W(t, Bt() ? Reflect.construct(n, r || [], O(t).constructor) : n.apply(t, r)), "state", { isScrolling: !1, scrollTop: 0 }), p(e, "_debounceResetIsScrollingId", void 0), p(e, "_invalidateOnUpdateStartIndex", null), p(e, "_invalidateOnUpdateStopIndex", null), p(e, "_positionCache", new xe()), p(e, "_startIndex", null), p(e, "_startIndexMemoized", null), p(e, "_stopIndex", null), p(e, "_stopIndexMemoized", null), p(e, "_debounceResetIsScrollingCallback", function() {
|
|
1510
1513
|
e.setState({ isScrolling: !1 });
|
|
1511
1514
|
}), p(e, "_setScrollingContainerRef", function(s) {
|
|
1512
1515
|
e._scrollingContainer = s;
|
|
@@ -1515,26 +1518,26 @@ var ct = function() {
|
|
|
1515
1518
|
d === h && (e._debounceResetIsScrolling(), e.state.scrollTop !== h && e.setState({ isScrolling: !0, scrollTop: h }));
|
|
1516
1519
|
}), e;
|
|
1517
1520
|
}
|
|
1518
|
-
return D(o, x.PureComponent),
|
|
1519
|
-
this._positionCache = new
|
|
1521
|
+
return D(o, x.PureComponent), E(o, [{ key: "clearCellPositions", value: function() {
|
|
1522
|
+
this._positionCache = new xe(), this.forceUpdate();
|
|
1520
1523
|
} }, { key: "invalidateCellSizeAfterRender", value: function(e) {
|
|
1521
1524
|
var t = e.rowIndex;
|
|
1522
1525
|
this._invalidateOnUpdateStartIndex === null ? (this._invalidateOnUpdateStartIndex = t, this._invalidateOnUpdateStopIndex = t) : (this._invalidateOnUpdateStartIndex = Math.min(this._invalidateOnUpdateStartIndex, t), this._invalidateOnUpdateStopIndex = Math.max(this._invalidateOnUpdateStopIndex, t));
|
|
1523
1526
|
} }, { key: "recomputeCellPositions", value: function() {
|
|
1524
1527
|
var e = this._positionCache.count - 1;
|
|
1525
|
-
this._positionCache = new
|
|
1528
|
+
this._positionCache = new xe(), this._populatePositionCache(0, e), this.forceUpdate();
|
|
1526
1529
|
} }, { key: "componentDidMount", value: function() {
|
|
1527
1530
|
this._checkInvalidateOnUpdate(), this._invokeOnScrollCallback(), this._invokeOnCellsRenderedCallback();
|
|
1528
1531
|
} }, { key: "componentDidUpdate", value: function(e, t) {
|
|
1529
1532
|
this._checkInvalidateOnUpdate(), this._invokeOnScrollCallback(), this._invokeOnCellsRenderedCallback(), this.props.scrollTop !== e.scrollTop && this._debounceResetIsScrolling();
|
|
1530
1533
|
} }, { key: "componentWillUnmount", value: function() {
|
|
1531
|
-
this._debounceResetIsScrollingId &&
|
|
1534
|
+
this._debounceResetIsScrollingId && oe(this._debounceResetIsScrollingId);
|
|
1532
1535
|
} }, { key: "render", value: function() {
|
|
1533
|
-
var e, t = this, n = this.props, r = n.autoHeight,
|
|
1534
|
-
if (this._positionCache.range(Math.max(0,
|
|
1535
|
-
e === void 0 ? (I =
|
|
1536
|
-
}),
|
|
1537
|
-
return this._startIndex = I, this._stopIndex = e, x.createElement("div", { ref: this._setScrollingContainerRef, "aria-label": this.props["aria-label"], className: N("ReactVirtualized__Masonry", s), id: d, onScroll: this._onScroll, role: u, style:
|
|
1536
|
+
var e, t = this, n = this.props, r = n.autoHeight, l = n.cellCount, i = n.cellMeasurerCache, a = n.cellRenderer, s = n.className, c = n.height, d = n.id, h = n.keyMapper, f = n.overscanByPixels, u = n.role, v = n.style, m = n.tabIndex, _ = n.width, S = n.rowDirection, y = this.state, g = y.isScrolling, w = y.scrollTop, C = [], b = this._getEstimatedTotalHeight(), R = this._positionCache.shortestColumnSize, z = this._positionCache.count, I = 0;
|
|
1537
|
+
if (this._positionCache.range(Math.max(0, w - f), c + 2 * f, function(T, L, G) {
|
|
1538
|
+
e === void 0 ? (I = T, e = T) : (I = Math.min(I, T), e = Math.max(e, T)), C.push(a({ index: T, isScrolling: g, key: h(T), parent: t, style: p(p(p(p({ height: i.getHeight(T) }, S === "ltr" ? "left" : "right", L), "position", "absolute"), "top", G), "width", i.getWidth(T)) }));
|
|
1539
|
+
}), R < w + c + f && z < l) for (var k = Math.min(l - z, Math.ceil((w + c + f - R) / i.defaultHeight * _ / i.defaultWidth)), P = z; P < z + k; P++) e = P, C.push(a({ index: P, isScrolling: g, key: h(P), parent: this, style: { width: i.getWidth(P) } }));
|
|
1540
|
+
return this._startIndex = I, this._stopIndex = e, x.createElement("div", { ref: this._setScrollingContainerRef, "aria-label": this.props["aria-label"], className: N("ReactVirtualized__Masonry", s), id: d, onScroll: this._onScroll, role: u, style: Zo({ boxSizing: "border-box", direction: "ltr", height: r ? "auto" : c, overflowX: "hidden", overflowY: b < c ? "hidden" : "auto", position: "relative", width: _, WebkitOverflowScrolling: "touch", willChange: "transform" }, v), tabIndex: m }, x.createElement("div", { className: "ReactVirtualized__Masonry__innerScrollContainer", style: { width: "100%", height: b, maxWidth: "100%", maxHeight: b, overflow: "hidden", pointerEvents: g ? "none" : "", position: "relative" } }, C));
|
|
1538
1541
|
} }, { key: "_checkInvalidateOnUpdate", value: function() {
|
|
1539
1542
|
if (typeof this._invalidateOnUpdateStartIndex == "number") {
|
|
1540
1543
|
var e = this._invalidateOnUpdateStartIndex, t = this._invalidateOnUpdateStopIndex;
|
|
@@ -1542,40 +1545,40 @@ var ct = function() {
|
|
|
1542
1545
|
}
|
|
1543
1546
|
} }, { key: "_debounceResetIsScrolling", value: function() {
|
|
1544
1547
|
var e = this.props.scrollingResetTimeInterval;
|
|
1545
|
-
this._debounceResetIsScrollingId &&
|
|
1548
|
+
this._debounceResetIsScrollingId && oe(this._debounceResetIsScrollingId), this._debounceResetIsScrollingId = Ge(this._debounceResetIsScrollingCallback, e);
|
|
1546
1549
|
} }, { key: "_getEstimatedTotalHeight", value: function() {
|
|
1547
|
-
var e = this.props, t = e.cellCount, n = e.cellMeasurerCache, r = e.width,
|
|
1548
|
-
return this._positionCache.estimateTotalHeight(t,
|
|
1550
|
+
var e = this.props, t = e.cellCount, n = e.cellMeasurerCache, r = e.width, l = Math.max(1, Math.floor(r / n.defaultWidth));
|
|
1551
|
+
return this._positionCache.estimateTotalHeight(t, l, n.defaultHeight);
|
|
1549
1552
|
} }, { key: "_invokeOnScrollCallback", value: function() {
|
|
1550
1553
|
var e = this.props, t = e.height, n = e.onScroll, r = this.state.scrollTop;
|
|
1551
1554
|
this._onScrollMemoized !== r && (n({ clientHeight: t, scrollHeight: this._getEstimatedTotalHeight(), scrollTop: r }), this._onScrollMemoized = r);
|
|
1552
1555
|
} }, { key: "_invokeOnCellsRenderedCallback", value: function() {
|
|
1553
1556
|
this._startIndexMemoized === this._startIndex && this._stopIndexMemoized === this._stopIndex || ((0, this.props.onCellsRendered)({ startIndex: this._startIndex, stopIndex: this._stopIndex }), this._startIndexMemoized = this._startIndex, this._stopIndexMemoized = this._stopIndex);
|
|
1554
1557
|
} }, { key: "_populatePositionCache", value: function(e, t) {
|
|
1555
|
-
for (var n = this.props, r = n.cellMeasurerCache,
|
|
1556
|
-
var a = i
|
|
1557
|
-
this._positionCache.setPosition(
|
|
1558
|
+
for (var n = this.props, r = n.cellMeasurerCache, l = n.cellPositioner, i = e; i <= t; i++) {
|
|
1559
|
+
var a = l(i), s = a.left, c = a.top;
|
|
1560
|
+
this._positionCache.setPosition(i, s, c, r.getHeight(i));
|
|
1558
1561
|
}
|
|
1559
1562
|
} }], [{ key: "getDerivedStateFromProps", value: function(e, t) {
|
|
1560
1563
|
return e.scrollTop !== void 0 && t.scrollTop !== e.scrollTop ? { isScrolling: !0, scrollTop: e.scrollTop } : null;
|
|
1561
1564
|
} }]);
|
|
1562
1565
|
}();
|
|
1563
|
-
function
|
|
1566
|
+
function ht() {
|
|
1564
1567
|
}
|
|
1565
|
-
p(
|
|
1568
|
+
p(ut, "defaultProps", { autoHeight: !1, keyMapper: function(o) {
|
|
1566
1569
|
return o;
|
|
1567
|
-
}, onCellsRendered:
|
|
1568
|
-
var
|
|
1570
|
+
}, onCellsRendered: ht, onScroll: ht, overscanByPixels: 20, role: "grid", scrollingResetTimeInterval: 150, style: {}, tabIndex: 0, rowDirection: "ltr" }), ue(ut);
|
|
1571
|
+
var Re = E(function o() {
|
|
1569
1572
|
var e = this, t = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
|
|
1570
|
-
|
|
1573
|
+
A(this, o), p(this, "_cellMeasurerCache", void 0), p(this, "_columnIndexOffset", void 0), p(this, "_rowIndexOffset", void 0), p(this, "columnWidth", function(s) {
|
|
1571
1574
|
var c = s.index;
|
|
1572
1575
|
e._cellMeasurerCache.columnWidth({ index: c + e._columnIndexOffset });
|
|
1573
1576
|
}), p(this, "rowHeight", function(s) {
|
|
1574
1577
|
var c = s.index;
|
|
1575
1578
|
e._cellMeasurerCache.rowHeight({ index: c + e._rowIndexOffset });
|
|
1576
1579
|
});
|
|
1577
|
-
var n = t.cellMeasurerCache, r = t.columnIndexOffset,
|
|
1578
|
-
this._cellMeasurerCache = n, this._columnIndexOffset =
|
|
1580
|
+
var n = t.cellMeasurerCache, r = t.columnIndexOffset, l = r === void 0 ? 0 : r, i = t.rowIndexOffset, a = i === void 0 ? 0 : i;
|
|
1581
|
+
this._cellMeasurerCache = n, this._columnIndexOffset = l, this._rowIndexOffset = a;
|
|
1579
1582
|
}, [{ key: "clear", value: function(o, e) {
|
|
1580
1583
|
this._cellMeasurerCache.clear(o + this._rowIndexOffset, e + this._columnIndexOffset);
|
|
1581
1584
|
} }, { key: "clearAll", value: function() {
|
|
@@ -1599,8 +1602,8 @@ var Ce = A(function o() {
|
|
|
1599
1602
|
return this._cellMeasurerCache.has(o + this._rowIndexOffset, e + this._columnIndexOffset);
|
|
1600
1603
|
} }, { key: "set", value: function(o, e, t, n) {
|
|
1601
1604
|
this._cellMeasurerCache.set(o + this._rowIndexOffset, e + this._columnIndexOffset, t, n);
|
|
1602
|
-
} }]),
|
|
1603
|
-
function
|
|
1605
|
+
} }]), Qo = ["rowIndex"], en = ["columnIndex", "rowIndex"], tn = ["columnIndex"], on = ["onScroll", "onSectionRendered", "onScrollbarPresenceChange", "scrollLeft", "scrollToColumn", "scrollTop", "scrollToRow"];
|
|
1606
|
+
function ft(o, e) {
|
|
1604
1607
|
var t = Object.keys(o);
|
|
1605
1608
|
if (Object.getOwnPropertySymbols) {
|
|
1606
1609
|
var n = Object.getOwnPropertySymbols(o);
|
|
@@ -1610,54 +1613,54 @@ function ut(o, e) {
|
|
|
1610
1613
|
}
|
|
1611
1614
|
return t;
|
|
1612
1615
|
}
|
|
1613
|
-
function
|
|
1616
|
+
function M(o) {
|
|
1614
1617
|
for (var e = 1; e < arguments.length; e++) {
|
|
1615
1618
|
var t = arguments[e] != null ? arguments[e] : {};
|
|
1616
|
-
e % 2 ?
|
|
1619
|
+
e % 2 ? ft(Object(t), !0).forEach(function(n) {
|
|
1617
1620
|
p(o, n, t[n]);
|
|
1618
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) :
|
|
1621
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) : ft(Object(t)).forEach(function(n) {
|
|
1619
1622
|
Object.defineProperty(o, n, Object.getOwnPropertyDescriptor(t, n));
|
|
1620
1623
|
});
|
|
1621
1624
|
}
|
|
1622
1625
|
return o;
|
|
1623
1626
|
}
|
|
1624
|
-
function
|
|
1627
|
+
function Ut() {
|
|
1625
1628
|
try {
|
|
1626
1629
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
1627
1630
|
}));
|
|
1628
1631
|
} catch {
|
|
1629
1632
|
}
|
|
1630
|
-
return (
|
|
1633
|
+
return (Ut = function() {
|
|
1631
1634
|
return !!o;
|
|
1632
1635
|
})();
|
|
1633
1636
|
}
|
|
1634
|
-
var
|
|
1637
|
+
var be = function() {
|
|
1635
1638
|
function o(e, t) {
|
|
1636
|
-
var n, r,
|
|
1637
|
-
|
|
1639
|
+
var n, r, l, i;
|
|
1640
|
+
A(this, o), r = this, i = [e, t], l = O(l = o), p(n = W(r, Ut() ? Reflect.construct(l, i || [], O(r).constructor) : l.apply(r, i)), "state", { scrollLeft: 0, scrollTop: 0, scrollbarSize: 0, showHorizontalScrollbar: !1, showVerticalScrollbar: !1 }), p(n, "_deferredInvalidateColumnIndex", null), p(n, "_deferredInvalidateRowIndex", null), p(n, "_bottomLeftGridRef", function(d) {
|
|
1638
1641
|
n._bottomLeftGrid = d;
|
|
1639
1642
|
}), p(n, "_bottomRightGridRef", function(d) {
|
|
1640
1643
|
n._bottomRightGrid = d;
|
|
1641
1644
|
}), p(n, "_cellRendererBottomLeftGrid", function(d) {
|
|
1642
|
-
var h = d.rowIndex, f =
|
|
1643
|
-
return h === u.rowCount -
|
|
1645
|
+
var h = d.rowIndex, f = ie(d, Qo), u = n.props, v = u.cellRenderer, m = u.fixedRowCount;
|
|
1646
|
+
return h === u.rowCount - m ? x.createElement("div", { key: f.key, style: M(M({}, f.style), {}, { height: 20 }) }) : v(M(M({}, f), {}, { parent: n, rowIndex: h + m }));
|
|
1644
1647
|
}), p(n, "_cellRendererBottomRightGrid", function(d) {
|
|
1645
|
-
var h = d.columnIndex, f = d.rowIndex, u =
|
|
1646
|
-
return
|
|
1648
|
+
var h = d.columnIndex, f = d.rowIndex, u = ie(d, en), v = n.props, m = v.cellRenderer, _ = v.fixedColumnCount, S = v.fixedRowCount;
|
|
1649
|
+
return m(M(M({}, u), {}, { columnIndex: h + _, parent: n, rowIndex: f + S }));
|
|
1647
1650
|
}), p(n, "_cellRendererTopRightGrid", function(d) {
|
|
1648
|
-
var h = d.columnIndex, f =
|
|
1649
|
-
return h ===
|
|
1651
|
+
var h = d.columnIndex, f = ie(d, tn), u = n.props, v = u.cellRenderer, m = u.columnCount, _ = u.fixedColumnCount;
|
|
1652
|
+
return h === m - _ ? x.createElement("div", { key: f.key, style: M(M({}, f.style), {}, { width: 20 }) }) : v(M(M({}, f), {}, { columnIndex: h + _, parent: n }));
|
|
1650
1653
|
}), p(n, "_columnWidthRightGrid", function(d) {
|
|
1651
|
-
var h = d.index, f = n.props, u = f.columnCount,
|
|
1652
|
-
return
|
|
1654
|
+
var h = d.index, f = n.props, u = f.columnCount, v = f.fixedColumnCount, m = f.columnWidth, _ = n.state, S = _.scrollbarSize;
|
|
1655
|
+
return _.showHorizontalScrollbar && h === u - v ? S : typeof m == "function" ? m({ index: h + v }) : m;
|
|
1653
1656
|
}), p(n, "_onScroll", function(d) {
|
|
1654
1657
|
var h = d.scrollLeft, f = d.scrollTop;
|
|
1655
1658
|
n.setState({ scrollLeft: h, scrollTop: f });
|
|
1656
1659
|
var u = n.props.onScroll;
|
|
1657
1660
|
u && u(d);
|
|
1658
1661
|
}), p(n, "_onScrollbarPresenceChange", function(d) {
|
|
1659
|
-
var h = d.horizontal, f = d.size, u = d.vertical,
|
|
1660
|
-
if (h !==
|
|
1662
|
+
var h = d.horizontal, f = d.size, u = d.vertical, v = n.state, m = v.showHorizontalScrollbar, _ = v.showVerticalScrollbar;
|
|
1663
|
+
if (h !== m || u !== _) {
|
|
1661
1664
|
n.setState({ scrollbarSize: f, showHorizontalScrollbar: h, showVerticalScrollbar: u });
|
|
1662
1665
|
var S = n.props.onScrollbarPresenceChange;
|
|
1663
1666
|
typeof S == "function" && S({ horizontal: h, size: f, vertical: u });
|
|
@@ -1669,26 +1672,26 @@ var xe = function() {
|
|
|
1669
1672
|
var h = d.scrollTop;
|
|
1670
1673
|
n._onScroll({ scrollTop: h, scrollLeft: n.state.scrollLeft });
|
|
1671
1674
|
}), p(n, "_rowHeightBottomGrid", function(d) {
|
|
1672
|
-
var h = d.index, f = n.props, u = f.fixedRowCount,
|
|
1673
|
-
return
|
|
1675
|
+
var h = d.index, f = n.props, u = f.fixedRowCount, v = f.rowCount, m = f.rowHeight, _ = n.state, S = _.scrollbarSize;
|
|
1676
|
+
return _.showVerticalScrollbar && h === v - u ? S : typeof m == "function" ? m({ index: h + u }) : m;
|
|
1674
1677
|
}), p(n, "_topLeftGridRef", function(d) {
|
|
1675
1678
|
n._topLeftGrid = d;
|
|
1676
1679
|
}), p(n, "_topRightGridRef", function(d) {
|
|
1677
1680
|
n._topRightGrid = d;
|
|
1678
1681
|
});
|
|
1679
1682
|
var a = e.deferredMeasurementCache, s = e.fixedColumnCount, c = e.fixedRowCount;
|
|
1680
|
-
return n._maybeCalculateCachedStyles(!0), a && (n._deferredMeasurementCacheBottomLeftGrid = c > 0 ? new
|
|
1683
|
+
return n._maybeCalculateCachedStyles(!0), a && (n._deferredMeasurementCacheBottomLeftGrid = c > 0 ? new Re({ cellMeasurerCache: a, columnIndexOffset: 0, rowIndexOffset: c }) : a, n._deferredMeasurementCacheBottomRightGrid = s > 0 || c > 0 ? new Re({ cellMeasurerCache: a, columnIndexOffset: s, rowIndexOffset: c }) : a, n._deferredMeasurementCacheTopRightGrid = s > 0 ? new Re({ cellMeasurerCache: a, columnIndexOffset: s, rowIndexOffset: 0 }) : a), n;
|
|
1681
1684
|
}
|
|
1682
|
-
return D(o, x.PureComponent),
|
|
1685
|
+
return D(o, x.PureComponent), E(o, [{ key: "forceUpdateGrids", value: function() {
|
|
1683
1686
|
this._bottomLeftGrid && this._bottomLeftGrid.forceUpdate(), this._bottomRightGrid && this._bottomRightGrid.forceUpdate(), this._topLeftGrid && this._topLeftGrid.forceUpdate(), this._topRightGrid && this._topRightGrid.forceUpdate();
|
|
1684
1687
|
} }, { key: "invalidateCellSizeAfterRender", value: function() {
|
|
1685
|
-
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.columnIndex, n = t === void 0 ? 0 : t, r = e.rowIndex,
|
|
1686
|
-
this._deferredInvalidateColumnIndex = typeof this._deferredInvalidateColumnIndex == "number" ? Math.min(this._deferredInvalidateColumnIndex, n) : n, this._deferredInvalidateRowIndex = typeof this._deferredInvalidateRowIndex == "number" ? Math.min(this._deferredInvalidateRowIndex,
|
|
1688
|
+
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.columnIndex, n = t === void 0 ? 0 : t, r = e.rowIndex, l = r === void 0 ? 0 : r;
|
|
1689
|
+
this._deferredInvalidateColumnIndex = typeof this._deferredInvalidateColumnIndex == "number" ? Math.min(this._deferredInvalidateColumnIndex, n) : n, this._deferredInvalidateRowIndex = typeof this._deferredInvalidateRowIndex == "number" ? Math.min(this._deferredInvalidateRowIndex, l) : l;
|
|
1687
1690
|
} }, { key: "measureAllCells", value: function() {
|
|
1688
1691
|
this._bottomLeftGrid && this._bottomLeftGrid.measureAllCells(), this._bottomRightGrid && this._bottomRightGrid.measureAllCells(), this._topLeftGrid && this._topLeftGrid.measureAllCells(), this._topRightGrid && this._topRightGrid.measureAllCells();
|
|
1689
1692
|
} }, { key: "recomputeGridSize", value: function() {
|
|
1690
|
-
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.columnIndex, n = t === void 0 ? 0 : t, r = e.rowIndex,
|
|
1691
|
-
this._bottomLeftGrid && this._bottomLeftGrid.recomputeGridSize({ columnIndex: n, rowIndex: d }), this._bottomRightGrid && this._bottomRightGrid.recomputeGridSize({ columnIndex: c, rowIndex: d }), this._topLeftGrid && this._topLeftGrid.recomputeGridSize({ columnIndex: n, rowIndex:
|
|
1693
|
+
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.columnIndex, n = t === void 0 ? 0 : t, r = e.rowIndex, l = r === void 0 ? 0 : r, i = this.props, a = i.fixedColumnCount, s = i.fixedRowCount, c = Math.max(0, n - a), d = Math.max(0, l - s);
|
|
1694
|
+
this._bottomLeftGrid && this._bottomLeftGrid.recomputeGridSize({ columnIndex: n, rowIndex: d }), this._bottomRightGrid && this._bottomRightGrid.recomputeGridSize({ columnIndex: c, rowIndex: d }), this._topLeftGrid && this._topLeftGrid.recomputeGridSize({ columnIndex: n, rowIndex: l }), this._topRightGrid && this._topRightGrid.recomputeGridSize({ columnIndex: c, rowIndex: l }), this._leftGridWidth = null, this._topGridHeight = null, this._maybeCalculateCachedStyles(!0);
|
|
1692
1695
|
} }, { key: "componentDidMount", value: function() {
|
|
1693
1696
|
var e = this.props, t = e.scrollLeft, n = e.scrollTop;
|
|
1694
1697
|
if (t > 0 || n > 0) {
|
|
@@ -1703,16 +1706,16 @@ var xe = function() {
|
|
|
1703
1706
|
e.onScrollbarPresenceChange, e.scrollLeft;
|
|
1704
1707
|
var r = e.scrollToColumn;
|
|
1705
1708
|
e.scrollTop;
|
|
1706
|
-
var
|
|
1709
|
+
var l = e.scrollToRow, i = ie(e, on);
|
|
1707
1710
|
if (this._prepareForRender(), this.props.width === 0 || this.props.height === 0) return null;
|
|
1708
1711
|
var a = this.state, s = a.scrollLeft, c = a.scrollTop;
|
|
1709
|
-
return x.createElement("div", { style: this._containerOuterStyle }, x.createElement("div", { style: this._containerTopStyle }, this._renderTopLeftGrid(
|
|
1712
|
+
return x.createElement("div", { style: this._containerOuterStyle }, x.createElement("div", { style: this._containerTopStyle }, this._renderTopLeftGrid(i), this._renderTopRightGrid(M(M({}, i), {}, { onScroll: t, scrollLeft: s }))), x.createElement("div", { style: this._containerBottomStyle }, this._renderBottomLeftGrid(M(M({}, i), {}, { onScroll: t, scrollTop: c })), this._renderBottomRightGrid(M(M({}, i), {}, { onScroll: t, onSectionRendered: n, scrollLeft: s, scrollToColumn: r, scrollToRow: l, scrollTop: c }))));
|
|
1710
1713
|
} }, { key: "_getBottomGridHeight", value: function(e) {
|
|
1711
1714
|
return e.height - this._getTopGridHeight(e);
|
|
1712
1715
|
} }, { key: "_getLeftGridWidth", value: function(e) {
|
|
1713
1716
|
var t = e.fixedColumnCount, n = e.columnWidth;
|
|
1714
1717
|
if (this._leftGridWidth == null) if (typeof n == "function") {
|
|
1715
|
-
for (var r = 0,
|
|
1718
|
+
for (var r = 0, l = 0; l < t; l++) r += n({ index: l });
|
|
1716
1719
|
this._leftGridWidth = r;
|
|
1717
1720
|
} else this._leftGridWidth = n * t;
|
|
1718
1721
|
return this._leftGridWidth;
|
|
@@ -1721,7 +1724,7 @@ var xe = function() {
|
|
|
1721
1724
|
} }, { key: "_getTopGridHeight", value: function(e) {
|
|
1722
1725
|
var t = e.fixedRowCount, n = e.rowHeight;
|
|
1723
1726
|
if (this._topGridHeight == null) if (typeof n == "function") {
|
|
1724
|
-
for (var r = 0,
|
|
1727
|
+
for (var r = 0, l = 0; l < t; l++) r += n({ index: l });
|
|
1725
1728
|
this._topGridHeight = r;
|
|
1726
1729
|
} else this._topGridHeight = n * t;
|
|
1727
1730
|
return this._topGridHeight;
|
|
@@ -1731,79 +1734,79 @@ var xe = function() {
|
|
|
1731
1734
|
this._deferredInvalidateColumnIndex = null, this._deferredInvalidateRowIndex = null, this.recomputeGridSize({ columnIndex: e, rowIndex: t }), this.forceUpdate();
|
|
1732
1735
|
}
|
|
1733
1736
|
} }, { key: "_maybeCalculateCachedStyles", value: function(e) {
|
|
1734
|
-
var t = this.props, n = t.columnWidth, r = t.enableFixedColumnScroll,
|
|
1735
|
-
(e ||
|
|
1737
|
+
var t = this.props, n = t.columnWidth, r = t.enableFixedColumnScroll, l = t.enableFixedRowScroll, i = t.height, a = t.fixedColumnCount, s = t.fixedRowCount, c = t.rowHeight, d = t.style, h = t.styleBottomLeftGrid, f = t.styleBottomRightGrid, u = t.styleTopLeftGrid, v = t.styleTopRightGrid, m = t.width, _ = e || i !== this._lastRenderedHeight || m !== this._lastRenderedWidth, S = e || n !== this._lastRenderedColumnWidth || a !== this._lastRenderedFixedColumnCount, y = e || s !== this._lastRenderedFixedRowCount || c !== this._lastRenderedRowHeight;
|
|
1738
|
+
(e || _ || d !== this._lastRenderedStyle) && (this._containerOuterStyle = M({ height: i, overflow: "visible", width: m }, d)), (e || _ || y) && (this._containerTopStyle = { height: this._getTopGridHeight(this.props), position: "relative", width: m }, this._containerBottomStyle = { height: i - this._getTopGridHeight(this.props), overflow: "visible", position: "relative", width: m }), (e || h !== this._lastRenderedStyleBottomLeftGrid) && (this._bottomLeftGridStyle = M({ left: 0, overflowX: "hidden", overflowY: r ? "auto" : "hidden", position: "absolute" }, h)), (e || S || f !== this._lastRenderedStyleBottomRightGrid) && (this._bottomRightGridStyle = M({ left: this._getLeftGridWidth(this.props), position: "absolute" }, f)), (e || u !== this._lastRenderedStyleTopLeftGrid) && (this._topLeftGridStyle = M({ left: 0, overflowX: "hidden", overflowY: "hidden", position: "absolute", top: 0 }, u)), (e || S || v !== this._lastRenderedStyleTopRightGrid) && (this._topRightGridStyle = M({ left: this._getLeftGridWidth(this.props), overflowX: l ? "auto" : "hidden", overflowY: "hidden", position: "absolute", top: 0 }, v)), this._lastRenderedColumnWidth = n, this._lastRenderedFixedColumnCount = a, this._lastRenderedFixedRowCount = s, this._lastRenderedHeight = i, this._lastRenderedRowHeight = c, this._lastRenderedStyle = d, this._lastRenderedStyleBottomLeftGrid = h, this._lastRenderedStyleBottomRightGrid = f, this._lastRenderedStyleTopLeftGrid = u, this._lastRenderedStyleTopRightGrid = v, this._lastRenderedWidth = m;
|
|
1736
1739
|
} }, { key: "_prepareForRender", value: function() {
|
|
1737
1740
|
this._lastRenderedColumnWidth === this.props.columnWidth && this._lastRenderedFixedColumnCount === this.props.fixedColumnCount || (this._leftGridWidth = null), this._lastRenderedFixedRowCount === this.props.fixedRowCount && this._lastRenderedRowHeight === this.props.rowHeight || (this._topGridHeight = null), this._maybeCalculateCachedStyles(), this._lastRenderedColumnWidth = this.props.columnWidth, this._lastRenderedFixedColumnCount = this.props.fixedColumnCount, this._lastRenderedFixedRowCount = this.props.fixedRowCount, this._lastRenderedRowHeight = this.props.rowHeight;
|
|
1738
1741
|
} }, { key: "_renderBottomLeftGrid", value: function(e) {
|
|
1739
|
-
var t = e.enableFixedColumnScroll, n = e.fixedColumnCount, r = e.fixedRowCount,
|
|
1742
|
+
var t = e.enableFixedColumnScroll, n = e.fixedColumnCount, r = e.fixedRowCount, l = e.rowCount, i = e.hideBottomLeftGridScrollbar, a = this.state.showVerticalScrollbar;
|
|
1740
1743
|
if (!n) return null;
|
|
1741
|
-
var s = a ? 1 : 0, c = this._getBottomGridHeight(e), d = this._getLeftGridWidth(e), h = this.state.showVerticalScrollbar ? this.state.scrollbarSize : 0, f =
|
|
1742
|
-
return
|
|
1744
|
+
var s = a ? 1 : 0, c = this._getBottomGridHeight(e), d = this._getLeftGridWidth(e), h = this.state.showVerticalScrollbar ? this.state.scrollbarSize : 0, f = i ? d + h : d, u = x.createElement($, V({}, e, { cellRenderer: this._cellRendererBottomLeftGrid, className: this.props.classNameBottomLeftGrid, columnCount: n, deferredMeasurementCache: this._deferredMeasurementCacheBottomLeftGrid, height: c, onScroll: t ? this._onScrollTop : void 0, ref: this._bottomLeftGridRef, rowCount: Math.max(0, l - r) + s, rowHeight: this._rowHeightBottomGrid, style: this._bottomLeftGridStyle, tabIndex: null, width: f }));
|
|
1745
|
+
return i ? x.createElement("div", { className: "BottomLeftGrid_ScrollWrapper", style: M(M({}, this._bottomLeftGridStyle), {}, { height: c, width: d, overflowY: "hidden" }) }, u) : u;
|
|
1743
1746
|
} }, { key: "_renderBottomRightGrid", value: function(e) {
|
|
1744
|
-
var t = e.columnCount, n = e.fixedColumnCount, r = e.fixedRowCount,
|
|
1745
|
-
return x.createElement(V
|
|
1747
|
+
var t = e.columnCount, n = e.fixedColumnCount, r = e.fixedRowCount, l = e.rowCount, i = e.scrollToColumn, a = e.scrollToRow;
|
|
1748
|
+
return x.createElement($, V({}, e, { cellRenderer: this._cellRendererBottomRightGrid, className: this.props.classNameBottomRightGrid, columnCount: Math.max(0, t - n), columnWidth: this._columnWidthRightGrid, deferredMeasurementCache: this._deferredMeasurementCacheBottomRightGrid, height: this._getBottomGridHeight(e), onScroll: this._onScroll, onScrollbarPresenceChange: this._onScrollbarPresenceChange, ref: this._bottomRightGridRef, rowCount: Math.max(0, l - r), rowHeight: this._rowHeightBottomGrid, scrollToColumn: i - n, scrollToRow: a - r, style: this._bottomRightGridStyle, width: this._getRightGridWidth(e) }));
|
|
1746
1749
|
} }, { key: "_renderTopLeftGrid", value: function(e) {
|
|
1747
1750
|
var t = e.fixedColumnCount, n = e.fixedRowCount;
|
|
1748
|
-
return t && n ? x.createElement(V
|
|
1751
|
+
return t && n ? x.createElement($, V({}, e, { className: this.props.classNameTopLeftGrid, columnCount: t, height: this._getTopGridHeight(e), ref: this._topLeftGridRef, rowCount: n, style: this._topLeftGridStyle, tabIndex: null, width: this._getLeftGridWidth(e) })) : null;
|
|
1749
1752
|
} }, { key: "_renderTopRightGrid", value: function(e) {
|
|
1750
|
-
var t = e.columnCount, n = e.enableFixedRowScroll, r = e.fixedColumnCount,
|
|
1751
|
-
if (!
|
|
1752
|
-
var h = c ? 1 : 0, f = this._getTopGridHeight(e), u = this._getRightGridWidth(e),
|
|
1753
|
-
a && (
|
|
1754
|
-
var S = x.createElement(V
|
|
1755
|
-
return a ? x.createElement("div", { className: "TopRightGrid_ScrollWrapper", style:
|
|
1753
|
+
var t = e.columnCount, n = e.enableFixedRowScroll, r = e.fixedColumnCount, l = e.fixedRowCount, i = e.scrollLeft, a = e.hideTopRightGridScrollbar, s = this.state, c = s.showHorizontalScrollbar, d = s.scrollbarSize;
|
|
1754
|
+
if (!l) return null;
|
|
1755
|
+
var h = c ? 1 : 0, f = this._getTopGridHeight(e), u = this._getRightGridWidth(e), v = c ? d : 0, m = f, _ = this._topRightGridStyle;
|
|
1756
|
+
a && (m = f + v, _ = M(M({}, this._topRightGridStyle), {}, { left: 0 }));
|
|
1757
|
+
var S = x.createElement($, V({}, e, { cellRenderer: this._cellRendererTopRightGrid, className: this.props.classNameTopRightGrid, columnCount: Math.max(0, t - r) + h, columnWidth: this._columnWidthRightGrid, deferredMeasurementCache: this._deferredMeasurementCacheTopRightGrid, height: m, onScroll: n ? this._onScrollLeft : void 0, ref: this._topRightGridRef, rowCount: l, scrollLeft: i, style: _, tabIndex: null, width: u }));
|
|
1758
|
+
return a ? x.createElement("div", { className: "TopRightGrid_ScrollWrapper", style: M(M({}, this._topRightGridStyle), {}, { height: f, width: u, overflowX: "hidden" }) }, S) : S;
|
|
1756
1759
|
} }], [{ key: "getDerivedStateFromProps", value: function(e, t) {
|
|
1757
1760
|
return e.scrollLeft !== t.scrollLeft || e.scrollTop !== t.scrollTop ? { scrollLeft: e.scrollLeft != null && e.scrollLeft >= 0 ? e.scrollLeft : t.scrollLeft, scrollTop: e.scrollTop != null && e.scrollTop >= 0 ? e.scrollTop : t.scrollTop } : null;
|
|
1758
1761
|
} }]);
|
|
1759
1762
|
}();
|
|
1760
|
-
function
|
|
1763
|
+
function Vt() {
|
|
1761
1764
|
try {
|
|
1762
1765
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
1763
1766
|
}));
|
|
1764
1767
|
} catch {
|
|
1765
1768
|
}
|
|
1766
|
-
return (
|
|
1769
|
+
return (Vt = function() {
|
|
1767
1770
|
return !!o;
|
|
1768
1771
|
})();
|
|
1769
1772
|
}
|
|
1770
|
-
p(
|
|
1773
|
+
p(be, "defaultProps", { classNameBottomLeftGrid: "", classNameBottomRightGrid: "", classNameTopLeftGrid: "", classNameTopRightGrid: "", enableFixedColumnScroll: !1, enableFixedRowScroll: !1, fixedColumnCount: 0, fixedRowCount: 0, scrollToColumn: -1, scrollToRow: -1, style: {}, styleBottomLeftGrid: {}, styleBottomRightGrid: {}, styleTopLeftGrid: {}, styleTopRightGrid: {}, hideTopRightGridScrollbar: !1, hideBottomLeftGridScrollbar: !1 }), be.propTypes = {}, ue(be), function() {
|
|
1771
1774
|
function o(e, t) {
|
|
1772
|
-
var n, r,
|
|
1773
|
-
return
|
|
1775
|
+
var n, r, l, i;
|
|
1776
|
+
return A(this, o), r = this, i = [e, t], l = O(l = o), (n = W(r, Vt() ? Reflect.construct(l, i || [], O(r).constructor) : l.apply(r, i))).state = { clientHeight: 0, clientWidth: 0, scrollHeight: 0, scrollLeft: 0, scrollTop: 0, scrollWidth: 0 }, n._onScroll = n._onScroll.bind(n), n;
|
|
1774
1777
|
}
|
|
1775
|
-
return D(o, x.PureComponent),
|
|
1776
|
-
var e = this.props.children, t = this.state, n = t.clientHeight, r = t.clientWidth,
|
|
1777
|
-
return e({ clientHeight: n, clientWidth: r, onScroll: this._onScroll, scrollHeight:
|
|
1778
|
+
return D(o, x.PureComponent), E(o, [{ key: "render", value: function() {
|
|
1779
|
+
var e = this.props.children, t = this.state, n = t.clientHeight, r = t.clientWidth, l = t.scrollHeight, i = t.scrollLeft, a = t.scrollTop, s = t.scrollWidth;
|
|
1780
|
+
return e({ clientHeight: n, clientWidth: r, onScroll: this._onScroll, scrollHeight: l, scrollLeft: i, scrollTop: a, scrollWidth: s });
|
|
1778
1781
|
} }, { key: "_onScroll", value: function(e) {
|
|
1779
|
-
var t = e.clientHeight, n = e.clientWidth, r = e.scrollHeight,
|
|
1780
|
-
this.setState({ clientHeight: t, clientWidth: n, scrollHeight: r, scrollLeft:
|
|
1782
|
+
var t = e.clientHeight, n = e.clientWidth, r = e.scrollHeight, l = e.scrollLeft, i = e.scrollTop, a = e.scrollWidth;
|
|
1783
|
+
this.setState({ clientHeight: t, clientWidth: n, scrollHeight: r, scrollLeft: l, scrollTop: i, scrollWidth: a });
|
|
1781
1784
|
} }]);
|
|
1782
1785
|
}().propTypes = {};
|
|
1783
|
-
var
|
|
1784
|
-
function
|
|
1785
|
-
var e = o.sortDirection, t = N("ReactVirtualized__Table__sortableHeaderIcon", { "ReactVirtualized__Table__sortableHeaderIcon--ASC": e ===
|
|
1786
|
-
return x.createElement("svg", { className: t, width: 18, height: 18, viewBox: "0 0 24 24" }, e ===
|
|
1786
|
+
var de = "ASC", ke = "DESC";
|
|
1787
|
+
function $t(o) {
|
|
1788
|
+
var e = o.sortDirection, t = N("ReactVirtualized__Table__sortableHeaderIcon", { "ReactVirtualized__Table__sortableHeaderIcon--ASC": e === de, "ReactVirtualized__Table__sortableHeaderIcon--DESC": e === ke });
|
|
1789
|
+
return x.createElement("svg", { className: t, width: 18, height: 18, viewBox: "0 0 24 24" }, e === de ? x.createElement("path", { d: "M7 14l5-5 5 5z" }) : x.createElement("path", { d: "M7 10l5 5 5-5z" }), x.createElement("path", { d: "M0 0h24v24H0z", fill: "none" }));
|
|
1787
1790
|
}
|
|
1788
|
-
function
|
|
1791
|
+
function qt() {
|
|
1789
1792
|
try {
|
|
1790
1793
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
1791
1794
|
}));
|
|
1792
1795
|
} catch {
|
|
1793
1796
|
}
|
|
1794
|
-
return (
|
|
1797
|
+
return (qt = function() {
|
|
1795
1798
|
return !!o;
|
|
1796
1799
|
})();
|
|
1797
1800
|
}
|
|
1798
|
-
|
|
1799
|
-
var
|
|
1801
|
+
$t.propTypes = {};
|
|
1802
|
+
var Se = function() {
|
|
1800
1803
|
function o() {
|
|
1801
|
-
return
|
|
1804
|
+
return A(this, o), e = this, n = arguments, t = O(t = o), W(e, qt() ? Reflect.construct(t, n || [], O(e).constructor) : t.apply(e, n));
|
|
1802
1805
|
var e, t, n;
|
|
1803
1806
|
}
|
|
1804
|
-
return D(o, x.Component),
|
|
1807
|
+
return D(o, x.Component), E(o);
|
|
1805
1808
|
}();
|
|
1806
|
-
function
|
|
1809
|
+
function pt(o, e) {
|
|
1807
1810
|
var t = Object.keys(o);
|
|
1808
1811
|
if (Object.getOwnPropertySymbols) {
|
|
1809
1812
|
var n = Object.getOwnPropertySymbols(o);
|
|
@@ -1813,43 +1816,43 @@ function ht(o, e) {
|
|
|
1813
1816
|
}
|
|
1814
1817
|
return t;
|
|
1815
1818
|
}
|
|
1816
|
-
function
|
|
1819
|
+
function U(o) {
|
|
1817
1820
|
for (var e = 1; e < arguments.length; e++) {
|
|
1818
1821
|
var t = arguments[e] != null ? arguments[e] : {};
|
|
1819
|
-
e % 2 ?
|
|
1822
|
+
e % 2 ? pt(Object(t), !0).forEach(function(n) {
|
|
1820
1823
|
p(o, n, t[n]);
|
|
1821
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) :
|
|
1824
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) : pt(Object(t)).forEach(function(n) {
|
|
1822
1825
|
Object.defineProperty(o, n, Object.getOwnPropertyDescriptor(t, n));
|
|
1823
1826
|
});
|
|
1824
1827
|
}
|
|
1825
1828
|
return o;
|
|
1826
1829
|
}
|
|
1827
|
-
function
|
|
1830
|
+
function Kt() {
|
|
1828
1831
|
try {
|
|
1829
1832
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
1830
1833
|
}));
|
|
1831
1834
|
} catch {
|
|
1832
1835
|
}
|
|
1833
|
-
return (
|
|
1836
|
+
return (Kt = function() {
|
|
1834
1837
|
return !!o;
|
|
1835
1838
|
})();
|
|
1836
1839
|
}
|
|
1837
|
-
p(
|
|
1840
|
+
p(Se, "defaultProps", { cellDataGetter: function(o) {
|
|
1838
1841
|
var e = o.dataKey, t = o.rowData;
|
|
1839
1842
|
return typeof t.get == "function" ? t.get(e) : t[e];
|
|
1840
1843
|
}, cellRenderer: function(o) {
|
|
1841
1844
|
var e = o.cellData;
|
|
1842
1845
|
return e == null ? "" : String(e);
|
|
1843
|
-
}, defaultSortDirection:
|
|
1844
|
-
var e = o.dataKey, t = o.label, n = o.sortBy, r = o.sortDirection,
|
|
1845
|
-
return
|
|
1846
|
-
}, style: {} }),
|
|
1847
|
-
var
|
|
1846
|
+
}, defaultSortDirection: de, flexGrow: 0, flexShrink: 1, headerRenderer: function(o) {
|
|
1847
|
+
var e = o.dataKey, t = o.label, n = o.sortBy, r = o.sortDirection, l = n === e, i = [x.createElement("span", { className: "ReactVirtualized__Table__headerTruncatedText", key: "label", title: typeof t == "string" ? t : null }, t)];
|
|
1848
|
+
return l && i.push(x.createElement($t, { key: "SortIndicator", sortDirection: r })), i;
|
|
1849
|
+
}, style: {} }), Se.propTypes = {};
|
|
1850
|
+
var Oe = function() {
|
|
1848
1851
|
function o(e) {
|
|
1849
|
-
var t, n, r,
|
|
1850
|
-
return
|
|
1852
|
+
var t, n, r, l;
|
|
1853
|
+
return A(this, o), n = this, l = [e], r = O(r = o), (t = W(n, Kt() ? Reflect.construct(r, l || [], O(n).constructor) : r.apply(n, l))).state = { scrollbarWidth: 0 }, t._createColumn = t._createColumn.bind(t), t._createRow = t._createRow.bind(t), t._onScroll = t._onScroll.bind(t), t._onSectionRendered = t._onSectionRendered.bind(t), t._setRef = t._setRef.bind(t), t._setGridElementRef = t._setGridElementRef.bind(t), t;
|
|
1851
1854
|
}
|
|
1852
|
-
return D(o, x.PureComponent),
|
|
1855
|
+
return D(o, x.PureComponent), E(o, [{ key: "forceUpdateGrid", value: function() {
|
|
1853
1856
|
this.Grid && this.Grid.forceUpdate();
|
|
1854
1857
|
} }, { key: "getOffsetForRow", value: function(e) {
|
|
1855
1858
|
var t = e.alignment, n = e.index;
|
|
@@ -1860,8 +1863,8 @@ var Pe = function() {
|
|
|
1860
1863
|
} }, { key: "measureAllRows", value: function() {
|
|
1861
1864
|
this.Grid && this.Grid.measureAllCells();
|
|
1862
1865
|
} }, { key: "recomputeGridSize", value: function() {
|
|
1863
|
-
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.columnIndex, n = t === void 0 ? 0 : t, r = e.rowIndex,
|
|
1864
|
-
this.Grid && this.Grid.recomputeGridSize({ rowIndex:
|
|
1866
|
+
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = e.columnIndex, n = t === void 0 ? 0 : t, r = e.rowIndex, l = r === void 0 ? 0 : r;
|
|
1867
|
+
this.Grid && this.Grid.recomputeGridSize({ rowIndex: l, columnIndex: n });
|
|
1865
1868
|
} }, { key: "recomputeRowHeights", value: function() {
|
|
1866
1869
|
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0;
|
|
1867
1870
|
this.Grid && this.Grid.recomputeGridSize({ rowIndex: e });
|
|
@@ -1882,39 +1885,39 @@ var Pe = function() {
|
|
|
1882
1885
|
} }, { key: "componentDidUpdate", value: function() {
|
|
1883
1886
|
this._setScrollbarWidth();
|
|
1884
1887
|
} }, { key: "render", value: function() {
|
|
1885
|
-
var e = this, t = this.props, n = t.children, r = t.className,
|
|
1886
|
-
return this._cachedColumnStyles = [], x.Children.toArray(n).forEach(function(
|
|
1887
|
-
var
|
|
1888
|
-
e._cachedColumnStyles[
|
|
1889
|
-
}), x.createElement("div", { "aria-label": this.props["aria-label"], "aria-labelledby": this.props["aria-labelledby"], "aria-colcount": x.Children.toArray(n).length, "aria-rowcount": this.props.rowCount, className: N("ReactVirtualized__Table", r), id: h, role: "grid", style:
|
|
1888
|
+
var e = this, t = this.props, n = t.children, r = t.className, l = t.disableHeader, i = t.gridClassName, a = t.gridStyle, s = t.headerHeight, c = t.headerRowRenderer, d = t.height, h = t.id, f = t.noRowsRenderer, u = t.rowClassName, v = t.rowStyle, m = t.scrollToIndex, _ = t.style, S = t.width, y = this.state.scrollbarWidth, g = l ? d : d - s, w = typeof u == "function" ? u({ index: -1 }) : u, C = typeof v == "function" ? v({ index: -1 }) : v;
|
|
1889
|
+
return this._cachedColumnStyles = [], x.Children.toArray(n).forEach(function(b, R) {
|
|
1890
|
+
var z = e._getFlexStyleForColumn(b, b.props.style || Se.defaultProps.style);
|
|
1891
|
+
e._cachedColumnStyles[R] = U({ overflow: "hidden" }, z);
|
|
1892
|
+
}), x.createElement("div", { "aria-label": this.props["aria-label"], "aria-labelledby": this.props["aria-labelledby"], "aria-colcount": x.Children.toArray(n).length, "aria-rowcount": this.props.rowCount, className: N("ReactVirtualized__Table", r), id: h, role: "grid", style: _ }, !l && c({ className: N("ReactVirtualized__Table__headerRow", w), columns: this._getHeaderColumns(), style: U({ height: s, overflow: "hidden", paddingRight: y, width: S }, C) }), x.createElement($, V({}, this.props, { elementRef: this._setGridElementRef, "aria-readonly": null, autoContainerWidth: !0, className: N("ReactVirtualized__Table__Grid", i), cellRenderer: this._createRow, columnWidth: S, columnCount: 1, height: g, id: void 0, noContentRenderer: f, onScroll: this._onScroll, onSectionRendered: this._onSectionRendered, ref: this._setRef, role: "rowgroup", scrollbarWidth: y, scrollToRow: m, style: U(U({}, a), {}, { overflowX: "hidden" }) })));
|
|
1890
1893
|
} }, { key: "_createColumn", value: function(e) {
|
|
1891
|
-
var t = e.column, n = e.columnIndex, r = e.isScrolling,
|
|
1892
|
-
return x.createElement("div", { "aria-colindex": n + 1, "aria-describedby":
|
|
1893
|
-
s && s({ columnData: u, dataKey:
|
|
1894
|
-
}, role: "gridcell", style: S, title: y },
|
|
1894
|
+
var t = e.column, n = e.columnIndex, r = e.isScrolling, l = e.parent, i = e.rowData, a = e.rowIndex, s = this.props.onColumnClick, c = t.props, d = c.cellDataGetter, h = c.cellRenderer, f = c.className, u = c.columnData, v = c.dataKey, m = c.id, _ = h({ cellData: d({ columnData: u, dataKey: v, rowData: i }), columnData: u, columnIndex: n, dataKey: v, isScrolling: r, parent: l, rowData: i, rowIndex: a }), S = this._cachedColumnStyles[n], y = typeof _ == "string" ? _ : null;
|
|
1895
|
+
return x.createElement("div", { "aria-colindex": n + 1, "aria-describedby": m, className: N("ReactVirtualized__Table__rowColumn", f), key: "Row" + a + "-Col" + n, onClick: function(g) {
|
|
1896
|
+
s && s({ columnData: u, dataKey: v, event: g });
|
|
1897
|
+
}, role: "gridcell", style: S, title: y }, _);
|
|
1895
1898
|
} }, { key: "_createHeader", value: function(e) {
|
|
1896
|
-
var t, n, r,
|
|
1897
|
-
if (
|
|
1898
|
-
var
|
|
1899
|
-
|
|
1899
|
+
var t, n, r, l, i, a = e.column, s = e.index, c = this.props, d = c.headerClassName, h = c.headerStyle, f = c.onHeaderClick, u = c.sort, v = c.sortBy, m = c.sortDirection, _ = a.props, S = _.columnData, y = _.dataKey, g = _.defaultSortDirection, w = _.disableSort, C = _.headerRenderer, b = _.id, R = _.label, z = !w && u, I = N("ReactVirtualized__Table__headerColumn", d, a.props.headerClassName, { ReactVirtualized__Table__sortableHeaderColumn: z }), k = this._getFlexStyleForColumn(a, U(U({}, h), a.props.headerStyle)), P = C({ columnData: S, dataKey: y, disableSort: w, label: R, sortBy: v, sortDirection: m });
|
|
1900
|
+
if (z || f) {
|
|
1901
|
+
var T = v !== y ? g : m === ke ? de : ke, L = function(G) {
|
|
1902
|
+
z && u({ defaultSortDirection: g, event: G, sortBy: y, sortDirection: T }), f && f({ columnData: S, dataKey: y, event: G });
|
|
1900
1903
|
};
|
|
1901
|
-
|
|
1902
|
-
|
|
1904
|
+
i = a.props["aria-label"] || R || y, l = "none", r = 0, t = L, n = function(G) {
|
|
1905
|
+
G.key !== "Enter" && G.key !== " " || L(G);
|
|
1903
1906
|
};
|
|
1904
1907
|
}
|
|
1905
|
-
return
|
|
1908
|
+
return v === y && (l = m === de ? "ascending" : "descending"), x.createElement("div", { "aria-label": i, "aria-sort": l, className: I, id: b, key: "Header-Col" + s, onClick: t, onKeyDown: n, role: "columnheader", style: k, tabIndex: r }, P);
|
|
1906
1909
|
} }, { key: "_createRow", value: function(e) {
|
|
1907
|
-
var t = this, n = e.rowIndex, r = e.isScrolling,
|
|
1908
|
-
return t._createColumn({ column:
|
|
1909
|
-
}),
|
|
1910
|
-
return S({ className:
|
|
1910
|
+
var t = this, n = e.rowIndex, r = e.isScrolling, l = e.key, i = e.parent, a = e.style, s = this.props, c = s.children, d = s.onRowClick, h = s.onRowDoubleClick, f = s.onRowRightClick, u = s.onRowMouseOver, v = s.onRowMouseOut, m = s.rowClassName, _ = s.rowGetter, S = s.rowRenderer, y = s.rowStyle, g = this.state.scrollbarWidth, w = typeof m == "function" ? m({ index: n }) : m, C = typeof y == "function" ? y({ index: n }) : y, b = _({ index: n }), R = x.Children.toArray(c).map(function(k, P) {
|
|
1911
|
+
return t._createColumn({ column: k, columnIndex: P, isScrolling: r, parent: i, rowData: b, rowIndex: n, scrollbarWidth: g });
|
|
1912
|
+
}), z = N("ReactVirtualized__Table__row", w), I = U(U({}, a), {}, { height: this._getRowHeight(n), overflow: "hidden", paddingRight: g }, C);
|
|
1913
|
+
return S({ className: z, columns: R, index: n, isScrolling: r, key: l, onRowClick: d, onRowDoubleClick: h, onRowRightClick: f, onRowMouseOver: u, onRowMouseOut: v, rowData: b, style: I });
|
|
1911
1914
|
} }, { key: "_getFlexStyleForColumn", value: function(e) {
|
|
1912
|
-
var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, n = "".concat(e.props.flexGrow, " ").concat(e.props.flexShrink, " ").concat(e.props.width, "px"), r =
|
|
1915
|
+
var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, n = "".concat(e.props.flexGrow, " ").concat(e.props.flexShrink, " ").concat(e.props.width, "px"), r = U(U({}, t), {}, { flex: n, msFlex: n, WebkitFlex: n });
|
|
1913
1916
|
return e.props.maxWidth && (r.maxWidth = e.props.maxWidth), e.props.minWidth && (r.minWidth = e.props.minWidth), r;
|
|
1914
1917
|
} }, { key: "_getHeaderColumns", value: function() {
|
|
1915
1918
|
var e = this, t = this.props, n = t.children;
|
|
1916
|
-
return (t.disableHeader ? [] : x.Children.toArray(n)).map(function(r,
|
|
1917
|
-
return e._createHeader({ column: r, index:
|
|
1919
|
+
return (t.disableHeader ? [] : x.Children.toArray(n)).map(function(r, l) {
|
|
1920
|
+
return e._createHeader({ column: r, index: l });
|
|
1918
1921
|
});
|
|
1919
1922
|
} }, { key: "_getRowHeight", value: function(e) {
|
|
1920
1923
|
var t = this.props.rowHeight;
|
|
@@ -1923,8 +1926,8 @@ var Pe = function() {
|
|
|
1923
1926
|
var t = e.clientHeight, n = e.scrollHeight, r = e.scrollTop;
|
|
1924
1927
|
(0, this.props.onScroll)({ clientHeight: t, scrollHeight: n, scrollTop: r });
|
|
1925
1928
|
} }, { key: "_onSectionRendered", value: function(e) {
|
|
1926
|
-
var t = e.rowOverscanStartIndex, n = e.rowOverscanStopIndex, r = e.rowStartIndex,
|
|
1927
|
-
(0, this.props.onRowsRendered)({ overscanStartIndex: t, overscanStopIndex: n, startIndex: r, stopIndex:
|
|
1929
|
+
var t = e.rowOverscanStartIndex, n = e.rowOverscanStopIndex, r = e.rowStartIndex, l = e.rowStopIndex;
|
|
1930
|
+
(0, this.props.onRowsRendered)({ overscanStartIndex: t, overscanStopIndex: n, startIndex: r, stopIndex: l });
|
|
1928
1931
|
} }, { key: "_setRef", value: function(e) {
|
|
1929
1932
|
this.Grid = e;
|
|
1930
1933
|
} }, { key: "_setGridElementRef", value: function(e) {
|
|
@@ -1934,78 +1937,78 @@ var Pe = function() {
|
|
|
1934
1937
|
this.setState({ scrollbarWidth: e });
|
|
1935
1938
|
} }]);
|
|
1936
1939
|
}();
|
|
1937
|
-
p(
|
|
1940
|
+
p(Oe, "defaultProps", { disableHeader: !1, estimatedRowSize: 30, headerHeight: 0, headerStyle: {}, noRowsRenderer: function() {
|
|
1938
1941
|
return null;
|
|
1939
1942
|
}, onRowsRendered: function() {
|
|
1940
1943
|
return null;
|
|
1941
1944
|
}, onScroll: function() {
|
|
1942
1945
|
return null;
|
|
1943
|
-
}, overscanIndicesGetter:
|
|
1944
|
-
var e = o.className, t = o.columns, n = o.index, r = o.key,
|
|
1945
|
-
return (
|
|
1946
|
-
return i({ event: u, index: n, rowData: d });
|
|
1947
|
-
}), l && (f.onDoubleClick = function(u) {
|
|
1946
|
+
}, overscanIndicesGetter: Ht, overscanRowCount: 10, rowRenderer: function(o) {
|
|
1947
|
+
var e = o.className, t = o.columns, n = o.index, r = o.key, l = o.onRowClick, i = o.onRowDoubleClick, a = o.onRowMouseOut, s = o.onRowMouseOver, c = o.onRowRightClick, d = o.rowData, h = o.style, f = { "aria-rowindex": n + 1 };
|
|
1948
|
+
return (l || i || a || s || c) && (f["aria-label"] = "row", f.tabIndex = 0, l && (f.onClick = function(u) {
|
|
1948
1949
|
return l({ event: u, index: n, rowData: d });
|
|
1950
|
+
}), i && (f.onDoubleClick = function(u) {
|
|
1951
|
+
return i({ event: u, index: n, rowData: d });
|
|
1949
1952
|
}), a && (f.onMouseOut = function(u) {
|
|
1950
1953
|
return a({ event: u, index: n, rowData: d });
|
|
1951
1954
|
}), s && (f.onMouseOver = function(u) {
|
|
1952
1955
|
return s({ event: u, index: n, rowData: d });
|
|
1953
1956
|
}), c && (f.onContextMenu = function(u) {
|
|
1954
1957
|
return c({ event: u, index: n, rowData: d });
|
|
1955
|
-
})), x.createElement("div",
|
|
1958
|
+
})), x.createElement("div", V({}, f, { className: e, key: r, role: "row", style: h }), t);
|
|
1956
1959
|
}, headerRowRenderer: function(o) {
|
|
1957
1960
|
var e = o.className, t = o.columns, n = o.style;
|
|
1958
1961
|
return x.createElement("div", { className: e, role: "row", style: n }, t);
|
|
1959
|
-
}, rowStyle: {}, scrollToAlignment: "auto", scrollToIndex: -1, style: {} }),
|
|
1960
|
-
var
|
|
1961
|
-
function
|
|
1962
|
-
|
|
1962
|
+
}, rowStyle: {}, scrollToAlignment: "auto", scrollToIndex: -1, style: {} }), Oe.propTypes = {};
|
|
1963
|
+
var Y = [], ae = null, X = null;
|
|
1964
|
+
function Xt() {
|
|
1965
|
+
X && (X = null, document.body && ae != null && (document.body.style.pointerEvents = ae), ae = null);
|
|
1963
1966
|
}
|
|
1964
|
-
function
|
|
1965
|
-
|
|
1967
|
+
function nn() {
|
|
1968
|
+
Xt(), Y.forEach(function(o) {
|
|
1966
1969
|
return o.__resetIsScrolling();
|
|
1967
1970
|
});
|
|
1968
1971
|
}
|
|
1969
|
-
function
|
|
1970
|
-
o.currentTarget === window &&
|
|
1971
|
-
|
|
1972
|
+
function Yt(o) {
|
|
1973
|
+
o.currentTarget === window && ae == null && document.body && (ae = document.body.style.pointerEvents, document.body.style.pointerEvents = "none"), function() {
|
|
1974
|
+
X && oe(X);
|
|
1972
1975
|
var e = 0;
|
|
1973
|
-
|
|
1976
|
+
Y.forEach(function(t) {
|
|
1974
1977
|
e = Math.max(e, t.props.scrollingResetTimeInterval);
|
|
1975
|
-
}),
|
|
1976
|
-
}(),
|
|
1978
|
+
}), X = Ge(nn, e);
|
|
1979
|
+
}(), Y.forEach(function(e) {
|
|
1977
1980
|
e.props.scrollElement === o.currentTarget && e.__handleWindowScrollEvent();
|
|
1978
1981
|
});
|
|
1979
1982
|
}
|
|
1980
|
-
function
|
|
1981
|
-
|
|
1983
|
+
function mt(o, e) {
|
|
1984
|
+
Y.some(function(t) {
|
|
1982
1985
|
return t.props.scrollElement === e;
|
|
1983
|
-
}) || e.addEventListener("scroll",
|
|
1986
|
+
}) || e.addEventListener("scroll", Yt), Y.push(o);
|
|
1984
1987
|
}
|
|
1985
|
-
function
|
|
1986
|
-
(
|
|
1988
|
+
function gt(o, e) {
|
|
1989
|
+
(Y = Y.filter(function(t) {
|
|
1987
1990
|
return t !== o;
|
|
1988
|
-
})).length || (e.removeEventListener("scroll",
|
|
1991
|
+
})).length || (e.removeEventListener("scroll", Yt), X && (oe(X), Xt()));
|
|
1989
1992
|
}
|
|
1990
|
-
var
|
|
1993
|
+
var Ee = function(o) {
|
|
1991
1994
|
return o === window;
|
|
1992
|
-
},
|
|
1995
|
+
}, le = function(o) {
|
|
1993
1996
|
return o.getBoundingClientRect();
|
|
1994
1997
|
};
|
|
1995
|
-
function
|
|
1998
|
+
function vt(o, e) {
|
|
1996
1999
|
if (o) {
|
|
1997
|
-
if (
|
|
2000
|
+
if (Ee(o)) {
|
|
1998
2001
|
var t = window, n = t.innerHeight, r = t.innerWidth;
|
|
1999
2002
|
return { height: typeof n == "number" ? n : 0, width: typeof r == "number" ? r : 0 };
|
|
2000
2003
|
}
|
|
2001
|
-
return
|
|
2004
|
+
return le(o);
|
|
2002
2005
|
}
|
|
2003
2006
|
return { height: e.serverHeight, width: e.serverWidth };
|
|
2004
2007
|
}
|
|
2005
|
-
function
|
|
2006
|
-
return
|
|
2008
|
+
function _t(o) {
|
|
2009
|
+
return Ee(o) && document.documentElement ? { top: "scrollY" in window ? window.scrollY : document.documentElement.scrollTop, left: "scrollX" in window ? window.scrollX : document.documentElement.scrollLeft } : { top: o.scrollTop, left: o.scrollLeft };
|
|
2007
2010
|
}
|
|
2008
|
-
function
|
|
2011
|
+
function St(o, e) {
|
|
2009
2012
|
var t = Object.keys(o);
|
|
2010
2013
|
if (Object.getOwnPropertySymbols) {
|
|
2011
2014
|
var n = Object.getOwnPropertySymbols(o);
|
|
@@ -2015,35 +2018,35 @@ function vt(o, e) {
|
|
|
2015
2018
|
}
|
|
2016
2019
|
return t;
|
|
2017
2020
|
}
|
|
2018
|
-
function
|
|
2021
|
+
function yt(o) {
|
|
2019
2022
|
for (var e = 1; e < arguments.length; e++) {
|
|
2020
2023
|
var t = arguments[e] != null ? arguments[e] : {};
|
|
2021
|
-
e % 2 ?
|
|
2024
|
+
e % 2 ? St(Object(t), !0).forEach(function(n) {
|
|
2022
2025
|
p(o, n, t[n]);
|
|
2023
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) :
|
|
2026
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(o, Object.getOwnPropertyDescriptors(t)) : St(Object(t)).forEach(function(n) {
|
|
2024
2027
|
Object.defineProperty(o, n, Object.getOwnPropertyDescriptor(t, n));
|
|
2025
2028
|
});
|
|
2026
2029
|
}
|
|
2027
2030
|
return o;
|
|
2028
2031
|
}
|
|
2029
|
-
function
|
|
2032
|
+
function Jt() {
|
|
2030
2033
|
try {
|
|
2031
2034
|
var o = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
2032
2035
|
}));
|
|
2033
2036
|
} catch {
|
|
2034
2037
|
}
|
|
2035
|
-
return (
|
|
2038
|
+
return (Jt = function() {
|
|
2036
2039
|
return !!o;
|
|
2037
2040
|
})();
|
|
2038
2041
|
}
|
|
2039
|
-
var
|
|
2042
|
+
var Zt = function() {
|
|
2040
2043
|
return typeof window < "u" ? window : void 0;
|
|
2041
|
-
},
|
|
2044
|
+
}, rn = function() {
|
|
2042
2045
|
function o() {
|
|
2043
2046
|
var e, t, n, r;
|
|
2044
|
-
|
|
2045
|
-
for (var
|
|
2046
|
-
return t = this, n = o, r = [].concat(
|
|
2047
|
+
A(this, o);
|
|
2048
|
+
for (var l = arguments.length, i = new Array(l), a = 0; a < l; a++) i[a] = arguments[a];
|
|
2049
|
+
return t = this, n = o, r = [].concat(i), n = O(n), p(e = W(t, Jt() ? Reflect.construct(n, r || [], O(t).constructor) : n.apply(t, r)), "_window", Zt()), p(e, "_isMounted", !1), p(e, "_positionFromTop", 0), p(e, "_positionFromLeft", 0), p(e, "_detectElementResize", void 0), p(e, "_child", void 0), p(e, "_windowScrollerRef", x.createRef()), p(e, "state", yt(yt({}, vt(e.props.scrollElement, e.props)), {}, { isScrolling: !1, scrollLeft: 0, scrollTop: 0 })), p(e, "_registerChild", function(s) {
|
|
2047
2050
|
!s || s instanceof Element || console.warn("WindowScroller registerChild expects to be passed Element or null"), e._child = s, e.updatePosition();
|
|
2048
2051
|
}), p(e, "_onChildScroll", function(s) {
|
|
2049
2052
|
var c = s.scrollTop;
|
|
@@ -2061,7 +2064,7 @@ var Yt = function() {
|
|
|
2061
2064
|
if (e._isMounted) {
|
|
2062
2065
|
var s = e.props.onScroll, c = e.props.scrollElement;
|
|
2063
2066
|
if (c) {
|
|
2064
|
-
var d =
|
|
2067
|
+
var d = _t(c), h = Math.max(0, d.left - e._positionFromLeft), f = Math.max(0, d.top - e._positionFromTop);
|
|
2065
2068
|
e.setState({ isScrolling: !0, scrollLeft: h, scrollTop: f }), s({ scrollLeft: h, scrollTop: f });
|
|
2066
2069
|
}
|
|
2067
2070
|
}
|
|
@@ -2069,51 +2072,51 @@ var Yt = function() {
|
|
|
2069
2072
|
e.setState({ isScrolling: !1 });
|
|
2070
2073
|
}), e;
|
|
2071
2074
|
}
|
|
2072
|
-
return D(o, x.PureComponent),
|
|
2073
|
-
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : this.props.scrollElement, t = this.props.onResize, n = this.state, r = n.height,
|
|
2074
|
-
if (
|
|
2075
|
+
return D(o, x.PureComponent), E(o, [{ key: "updatePosition", value: function() {
|
|
2076
|
+
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : this.props.scrollElement, t = this.props.onResize, n = this.state, r = n.height, l = n.width, i = this._child || this._windowScrollerRef.current;
|
|
2077
|
+
if (i instanceof Element && e) {
|
|
2075
2078
|
var a = function(c, d) {
|
|
2076
|
-
if (
|
|
2077
|
-
var h = document.documentElement, f =
|
|
2079
|
+
if (Ee(d) && document.documentElement) {
|
|
2080
|
+
var h = document.documentElement, f = le(c), u = le(h);
|
|
2078
2081
|
return { top: f.top - u.top, left: f.left - u.left };
|
|
2079
2082
|
}
|
|
2080
|
-
var
|
|
2081
|
-
return { top:
|
|
2082
|
-
}(
|
|
2083
|
+
var v = _t(d), m = le(c), _ = le(d);
|
|
2084
|
+
return { top: m.top + v.top - _.top, left: m.left + v.left - _.left };
|
|
2085
|
+
}(i, e);
|
|
2083
2086
|
this._positionFromTop = a.top, this._positionFromLeft = a.left;
|
|
2084
2087
|
}
|
|
2085
|
-
var s =
|
|
2086
|
-
r === s.height &&
|
|
2088
|
+
var s = vt(e, this.props);
|
|
2089
|
+
r === s.height && l === s.width || (this.setState({ height: s.height, width: s.width }), t({ height: s.height, width: s.width })), this.props.updateScrollTopOnUpdatePosition === !0 && (this.__handleWindowScrollEvent(), this.__resetIsScrolling());
|
|
2087
2090
|
} }, { key: "componentDidMount", value: function() {
|
|
2088
2091
|
var e = this.props.scrollElement;
|
|
2089
|
-
this._detectElementResize =
|
|
2092
|
+
this._detectElementResize = Pt(), this.updatePosition(e), e && (mt(this, e), this._registerResizeListener(e)), this._isMounted = !0;
|
|
2090
2093
|
} }, { key: "componentDidUpdate", value: function(e, t) {
|
|
2091
2094
|
var n = this.props.scrollElement, r = e.scrollElement;
|
|
2092
|
-
r !== n && r != null && n != null && (this.updatePosition(n),
|
|
2095
|
+
r !== n && r != null && n != null && (this.updatePosition(n), gt(this, r), mt(this, n), this._unregisterResizeListener(r), this._registerResizeListener(n));
|
|
2093
2096
|
} }, { key: "componentWillUnmount", value: function() {
|
|
2094
2097
|
var e = this.props.scrollElement;
|
|
2095
|
-
e && (
|
|
2098
|
+
e && (gt(this, e), this._unregisterResizeListener(e)), this._isMounted = !1;
|
|
2096
2099
|
} }, { key: "render", value: function() {
|
|
2097
|
-
var e = this.props.children, t = this.state, n = t.isScrolling, r = t.scrollTop,
|
|
2098
|
-
return x.createElement("div", { ref: this._windowScrollerRef }, e({ onChildScroll: this._onChildScroll, registerChild: this._registerChild, height:
|
|
2100
|
+
var e = this.props.children, t = this.state, n = t.isScrolling, r = t.scrollTop, l = t.scrollLeft, i = t.height, a = t.width;
|
|
2101
|
+
return x.createElement("div", { ref: this._windowScrollerRef }, e({ onChildScroll: this._onChildScroll, registerChild: this._registerChild, height: i, isScrolling: n, scrollLeft: l, scrollTop: r, width: a }));
|
|
2099
2102
|
} }]);
|
|
2100
2103
|
}();
|
|
2101
|
-
p(
|
|
2104
|
+
p(rn, "defaultProps", { onResize: function() {
|
|
2102
2105
|
}, onScroll: function() {
|
|
2103
|
-
}, scrollingResetTimeInterval: 150, scrollElement:
|
|
2104
|
-
const
|
|
2105
|
-
class
|
|
2106
|
+
}, scrollingResetTimeInterval: 150, scrollElement: Zt(), serverHeight: 0, serverWidth: 0 });
|
|
2107
|
+
const se = "ReactVirtualizedDemo-flexContainer", Qt = "ReactVirtualizedDemo-tableRow", eo = "ReactVirtualizedDemo-tableRowHover", Me = "ReactVirtualizedDemo-tableCell", Le = "ReactVirtualizedDemo-noClick";
|
|
2108
|
+
class ln extends Ct.PureComponent {
|
|
2106
2109
|
constructor() {
|
|
2107
2110
|
super(...arguments), this.getRowClassName = ({ index: e }) => {
|
|
2108
2111
|
const { onRowClick: t } = this.props;
|
|
2109
|
-
return
|
|
2112
|
+
return ye(Qt, se, { [eo]: e !== -1 && t != null });
|
|
2110
2113
|
}, this.cellRenderer = ({ cellData: e, columnIndex: t, dataKey: n }) => {
|
|
2111
|
-
const { columns: r, rowHeight:
|
|
2112
|
-
let a = e, s = { height:
|
|
2113
|
-
return n === "shortcut" ? a =
|
|
2114
|
+
const { columns: r, rowHeight: l, onRowClick: i } = this.props;
|
|
2115
|
+
let a = e, s = { height: l, paddingRight: "2px", paddingTop: "0px", paddingBottom: "0px" };
|
|
2116
|
+
return n === "shortcut" ? a = To(e) : n === "description" && (s = { ...s, fontSize: ".75rem", display: "block", paddingTop: "4px", whiteSpace: "pre-line" }), H(Fe, { component: "div", className: ye(Me, se, { [Le]: i == null }), variant: "body", style: s, align: t != null && r[t].numeric ? "right" : "left", children: a });
|
|
2114
2117
|
}, this.headerRenderer = ({ label: e, columnIndex: t }) => {
|
|
2115
2118
|
const { headerHeight: n, columns: r } = this.props;
|
|
2116
|
-
return
|
|
2119
|
+
return H(Fe, { component: "div", className: ye(Me, se, Le), variant: "head", sx: { height: n, backgroundColor: (l) => l.palette.grey[300] }, align: r[t].numeric ? "right" : "left", children: H("span", { children: e }) });
|
|
2117
2120
|
};
|
|
2118
2121
|
}
|
|
2119
2122
|
static {
|
|
@@ -2121,55 +2124,55 @@ class nn extends yt.PureComponent {
|
|
|
2121
2124
|
}
|
|
2122
2125
|
render() {
|
|
2123
2126
|
const { columns: e, rowHeight: t, headerHeight: n, ...r } = this.props;
|
|
2124
|
-
return
|
|
2125
|
-
const f = c ?
|
|
2126
|
-
return
|
|
2127
|
+
return H(Ot, { children: ({ height: l, width: i }) => H(Oe, { height: l, width: i, rowHeight: t, gridStyle: { direction: "inherit" }, headerHeight: n, ...r, rowClassName: this.getRowClassName, children: e.map(({ dataKey: a, width: s, widthLess: c, ...d }, h) => {
|
|
2128
|
+
const f = c ? i - c : s;
|
|
2129
|
+
return H(Se, { headerRenderer: (u) => this.headerRenderer({ ...u, columnIndex: h }), className: se, cellRenderer: this.cellRenderer, dataKey: a, width: f, ...d }, a);
|
|
2127
2130
|
}) }) });
|
|
2128
2131
|
}
|
|
2129
2132
|
}
|
|
2130
|
-
const
|
|
2131
|
-
function
|
|
2132
|
-
const { commands: e, ...t } = o, [n, r] =
|
|
2133
|
+
const sn = jo(ln)(({ theme: o }) => ({ "& .ReactVirtualized__Table__headerRow": { ...o.direction === "rtl" && { paddingLeft: "0 !important" }, ...o.direction !== "rtl" && { paddingRight: void 0 } }, "& .ReactVirtualized__Table__Grid": { outline: "none" }, [`& .${se}`]: { display: "flex", alignItems: "center", boxSizing: "border-box" }, [`& .${Qt}`]: { cursor: "pointer" }, [`& .${eo}`]: { "&:hover:not([disabled])": { backgroundColor: o.palette.grey[200] } }, [`& .${Me}`]: { flex: 1 }, [`& .${Le}`]: { cursor: "initial" } }));
|
|
2134
|
+
function an(o) {
|
|
2135
|
+
const { commands: e, ...t } = o, [n, r] = pe(!1), [l, i] = pe(""), a = ko(() => {
|
|
2133
2136
|
let u = e.getAllCommands();
|
|
2134
|
-
n || (u = u.filter((
|
|
2135
|
-
const
|
|
2137
|
+
n || (u = u.filter((_) => _.command.shortcut())), u.sort((_, S) => _.command.label().localeCompare(S.command.label()));
|
|
2138
|
+
const v = [], m = (_) => _.replace(/\n\n/g, `
|
|
2136
2139
|
`);
|
|
2137
|
-
for (let
|
|
2138
|
-
const S = u[
|
|
2140
|
+
for (let _ = 0; _ < u.length; _++) {
|
|
2141
|
+
const S = u[_].command, y = S.shortcut();
|
|
2139
2142
|
if (Array.isArray(y)) {
|
|
2140
|
-
const
|
|
2141
|
-
for (let
|
|
2142
|
-
} else
|
|
2143
|
+
const g = y;
|
|
2144
|
+
for (let w = 0; w < g.length; w++) v.push({ label: S.label(), description: m(S.description()), shortcut: g[w] });
|
|
2145
|
+
} else v.push({ label: S.label(), description: m(S.description()), shortcut: S.shortcut() });
|
|
2143
2146
|
}
|
|
2144
|
-
return
|
|
2145
|
-
}, [n, e]), [s, c] =
|
|
2146
|
-
|
|
2147
|
-
import("./
|
|
2147
|
+
return v;
|
|
2148
|
+
}, [n, e]), [s, c] = pe(null);
|
|
2149
|
+
je(() => {
|
|
2150
|
+
import("./hZL13mv_yL17yqpF.js").then((u) => {
|
|
2148
2151
|
c(new u.default(a, { threshold: 0, ignoreLocation: !0, keys: ["label", "description"] }));
|
|
2149
2152
|
});
|
|
2150
2153
|
}, [a]);
|
|
2151
|
-
const [d, h] =
|
|
2152
|
-
return
|
|
2153
|
-
s &&
|
|
2154
|
-
if (
|
|
2155
|
-
const u = s.search(
|
|
2156
|
-
for (let
|
|
2157
|
-
h(
|
|
2154
|
+
const [d, h] = pe(a), f = l.length > 0 && d.length === 0;
|
|
2155
|
+
return je(() => {
|
|
2156
|
+
s && fo.debounce(() => {
|
|
2157
|
+
if (l.trim().length === 0) return void h(a);
|
|
2158
|
+
const u = s.search(l.trim()), v = new Array(u.length);
|
|
2159
|
+
for (let m = 0; m < u.length; m++) v[m] = u[m].item;
|
|
2160
|
+
h(v);
|
|
2158
2161
|
}, 90)();
|
|
2159
|
-
}, [s,
|
|
2160
|
-
|
|
2162
|
+
}, [s, l]), We(he, { style: { height: 440, width: "100%", display: "flex", flexDirection: "column" }, ...t, children: [We(he, { sx: { display: "flex", alignItems: "center", justifyContent: "end", marginBottom: (u) => u.spacing(2), color: (u) => u.palette.text.secondary }, children: [H(po, { InputProps: { sx: { backgroundImage: `linear-gradient(${Z("#fff", fe(5))}, ${Z("#fff", fe(5))})` }, inputProps: { className: "input", autoFocus: !0, spellCheck: !1, placeholder: "Type to search key bindings", autoComplete: "off", sx: { paddingTop: (u) => u.spacing(1), paddingBottom: (u) => u.spacing(1) } }, endAdornment: H(mo, { sx: { opacity: l.length > 0 ? 1 : 0, display: l.length > 0 ? "flex" : "none" }, position: "end", children: H(go, { "aria-label": "clear search", onClick: () => i(""), edge: "end", children: H(vo, {}) }) }) }, sx: { flex: "1 1 40%", marginRight: (u) => u.spacing(1), "& .MuiOutlinedInput-notchedOutline": { borderColor: (u) => f ? `${u.palette.error.main} !important` : void 0 }, "& .MuiInputLabel-outlined": { color: (u) => f ? `${u.palette.error.main} !important` : void 0 } }, value: l, onChange: (u) => {
|
|
2163
|
+
i(u.target.value);
|
|
2161
2164
|
}, onKeyDown: (u) => {
|
|
2162
|
-
u.which ===
|
|
2165
|
+
u.which === wt.Escape && l.length > 0 && (i(""), u.stopPropagation(), u.preventDefault());
|
|
2163
2166
|
}, onContextMenu: (u) => {
|
|
2164
2167
|
u.stopPropagation();
|
|
2165
|
-
} }),
|
|
2168
|
+
} }), H(_o, { sx: { flex: "1 1 60%" }, control: H(So, { checked: n, onChange: () => r(!n) }), label: "Show commands without key bindings", labelPlacement: "start" })] }), H(he, { sx: { flex: "1 1 100%", borderRadius: (u) => `${u.shape.borderRadius}px`, border: (u) => `solid ${u.palette.divider} 1px`, paddingRight: "1px", overflow: "hidden", "* .MuiTableCell-head": { background: (u) => u.palette.background.paper, backgroundImage: `linear-gradient(${Z("#fff", fe(5))}, ${Z("#fff", fe(5))})` } }, children: H(sn, { rowCount: d.length, rowGetter: (u) => d[u.index], columns: [{ width: 180, label: "Command", dataKey: "label" }, { width: 260, label: "Key Binding", dataKey: "shortcut" }, { width: 240, label: "Description", dataKey: "description", widthLess: 440 }] }) }), H(he, { sx: { display: "flex", flexShrink: "0", paddingLeft: (u) => u.spacing(1), paddingTop: (u) => u.spacing(1), paddingRight: (u) => u.spacing(1), userSelect: "none", justifyContent: "flex-end" }, children: H(yo, { noWrap: !0, component: "div", sx: { color: (u) => f ? u.palette.error.main : u.palette.text.secondary }, children: `${d.length === 0 ? "No" : d.length} shortcut key${d.length === 1 ? "" : "s"}${l.length > 0 ? " found" : ""}` }) })] });
|
|
2166
2169
|
}
|
|
2167
|
-
const
|
|
2170
|
+
const fn = (o) => {
|
|
2168
2171
|
const { title: e = "Shortcut Keys", commands: t, sx: n, ...r } = o;
|
|
2169
|
-
return
|
|
2170
|
-
|
|
2171
|
-
}, sx: { width: "780px", ...n }, title: e, autoFocusSel: ".input", ...r, children:
|
|
2172
|
+
return H(uo, { isModal: !0, onKeyDown: (l) => {
|
|
2173
|
+
l.keyCode === wt.F1 && l.preventDefault();
|
|
2174
|
+
}, sx: { width: "780px", ...n }, title: e, autoFocusSel: ".input", ...r, children: H(ho, { dividers: !0, children: H(an, { commands: t, sx: { marginBottom: "8px" } }) }) });
|
|
2172
2175
|
};
|
|
2173
2176
|
export {
|
|
2174
|
-
|
|
2177
|
+
fn as default
|
|
2175
2178
|
};
|