@marimo-team/islands 0.19.12-dev1 → 0.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Combination-Du-o_hC9.js +11897 -0
- package/dist/{ConnectedDataExplorerComponent-CkXO-pKy.js → ConnectedDataExplorerComponent-BMiGWK57.js} +19 -18
- package/dist/{_baseIsEqual-CBSjxu-D.js → _baseIsEqual-DN5YkPnl.js} +1 -1
- package/dist/{_baseProperty-BVGrW_NZ.js → _baseProperty-6juuyX7Z.js} +5 -5
- package/dist/{_baseUniq-4lqa8rDi.js → _baseUniq-BlF21ach.js} +1 -1
- package/dist/{any-language-editor-t_VsTNa-.js → any-language-editor-1OMbohwD.js} +19 -19
- package/dist/architecture-U656AL7Q-Jd2CvPgJ.js +6 -0
- package/dist/{architectureDiagram-VXUJARFQ-DmJQhcJb.js → architectureDiagram-VXUJARFQ-DhN0C3Xf.js} +15 -15
- package/dist/{blockDiagram-VD42YOAC-CRofISJs.js → blockDiagram-VD42YOAC-DrBkIcbV.js} +7 -7
- package/dist/{button-Cy0ElmIm.js → button-KYalaJYu.js} +783 -200
- package/dist/{c4Diagram-YG6GDRKO-Deqoag4I.js → c4Diagram-YG6GDRKO-pWt4zmu0.js} +4 -4
- package/dist/{channel-CMsnebrL.js → channel-C56Jz8EL.js} +1 -1
- package/dist/{check-DkNR52Mm.js → check-C50jsehH.js} +1 -1
- package/dist/{chunk-76Q3JFCE-jPuajZH_.js → chunk-76Q3JFCE-CQ6a2yGJ.js} +1 -1
- package/dist/{chunk-ABZYJK2D-BGWvKte3.js → chunk-ABZYJK2D-BwNsaa1P.js} +1 -1
- package/dist/{chunk-ATLVNIR6-BYZB6C5T.js → chunk-ATLVNIR6-DtFMAawc.js} +1 -1
- package/dist/{chunk-B4BG7PRW-CwYUp6Uj.js → chunk-B4BG7PRW-lfWcLlzS.js} +4 -4
- package/dist/{chunk-DI55MBZ5-Gyro6dvN.js → chunk-DI55MBZ5-RhhAimfG.js} +4 -4
- package/dist/{chunk-EXTU4WIE-BlA7aWEw.js → chunk-EXTU4WIE-Bmo660a9.js} +1 -1
- package/dist/{chunk-FPAJGGOC-CduL34ft.js → chunk-FPAJGGOC-quWdfNUB.js} +7 -7
- package/dist/{chunk-FWNWRKHM-C-2TI4gt.js → chunk-FWNWRKHM-DmrwhAQr.js} +1 -1
- package/dist/{chunk-JA3XYJ7Z-Cm-pccR-.js → chunk-JA3XYJ7Z-n8UTzfok.js} +2 -2
- package/dist/{chunk-JZLCHNYA-CoLqqXMe.js → chunk-JZLCHNYA-ChKqHUdB.js} +4 -4
- package/dist/{chunk-LBM3YZW2-DWgQiioW.js → chunk-LBM3YZW2-BkxsqkNK.js} +1 -1
- package/dist/{chunk-LHMN2FUI-Dj_AHSvI.js → chunk-LHMN2FUI-CgYPnxfN.js} +1 -1
- package/dist/{chunk-N4CR4FBY-ByLbY9L-.js → chunk-N4CR4FBY-BxOHGL3P.js} +5 -5
- package/dist/{chunk-O7ZBX7Z2-CRZ8i1rP.js → chunk-O7ZBX7Z2-CdpLwOP0.js} +1 -1
- package/dist/{chunk-QN33PNHL-eodIiY9F.js → chunk-QN33PNHL-Dda-55xY.js} +1 -1
- package/dist/{chunk-QXUST7PY-CuJlDW6A.js → chunk-QXUST7PY-ClIEpoCT.js} +5 -5
- package/dist/{chunk-S3R3BYOJ-CwDGYMVf.js → chunk-S3R3BYOJ-C_1SJcWo.js} +3 -3
- package/dist/{chunk-S6J4BHB3-DNVMr0_v.js → chunk-S6J4BHB3-zfWjyfUg.js} +1 -1
- package/dist/{chunk-T53DSG4Q-BFWkpOX5.js → chunk-T53DSG4Q-Bewz1tiU.js} +1 -1
- package/dist/{chunk-TZMSLE5B-DFDr5FCr.js → chunk-TZMSLE5B-XW3duOft.js} +1 -1
- package/dist/{classDiagram-2ON5EDUG-BDBX9etk.js → classDiagram-2ON5EDUG-CUJlS_eo.js} +10 -10
- package/dist/{classDiagram-v2-WZHVMYZB-Bzj_L_BF.js → classDiagram-v2-WZHVMYZB-BhSPpbkE.js} +10 -10
- package/dist/{clone-Cc_6PW77.js → clone-V9hndNcj.js} +1 -1
- package/dist/{constants-DrOu5vvd.js → constants-BGRTDzdW.js} +2 -2
- package/dist/{copy-DRaXIb_a.js → copy-oc-FcZzt.js} +2 -2
- package/dist/{dagre-6UL2VRFP-r2rSdJYL.js → dagre-6UL2VRFP-BArPH353.js} +11 -11
- package/dist/{dagre-D2F8UdM6.js → dagre-Dcgyn_Uy.js} +15 -15
- package/dist/{diagram-PSM6KHXK-BpxVUe9U.js → diagram-PSM6KHXK-B1xAkr9y.js} +16 -16
- package/dist/{diagram-QEK2KX5R-q3dHUcp6.js → diagram-QEK2KX5R-CaoqwzPb.js} +14 -14
- package/dist/{diagram-S2PKOQOG-MDBKrxSC.js → diagram-S2PKOQOG-NXCsFLvR.js} +14 -14
- package/dist/dist-B8Y11RWn.js +1381 -0
- package/dist/dist-BA-HK7pI.js +5 -0
- package/dist/dist-BD5GU948.js +5 -0
- package/dist/{dist-BfactX3G.js → dist-BGzkWRSl.js} +4 -4
- package/dist/dist-BIYmAsND.js +5 -0
- package/dist/{dist-CmZYrgd_.js → dist-BUEi7EKT.js} +1 -1
- package/dist/{dist-B94MxrQS.js → dist-B_i29Q6L.js} +2 -2
- package/dist/dist-BcKTJXJi.js +5 -0
- package/dist/dist-BgnrtcWg.js +8 -0
- package/dist/{dist-glA_fIK_.js → dist-BoagoQQw.js} +2 -2
- package/dist/{dist-C2-m5aEk.js → dist-BswsDM4k.js} +2 -2
- package/dist/dist-C1njTlBq.js +5 -0
- package/dist/{dist-B2-r9y-0.js → dist-C5QB1NtD.js} +3 -3
- package/dist/{dist-Crk9ejOy.js → dist-CD7uLx0M.js} +2 -2
- package/dist/{dist-B4tYJP_i.js → dist-CMOy93xY.js} +2 -2
- package/dist/dist-CSKHwJYH.js +5 -0
- package/dist/dist-CSKKyiIq.js +5 -0
- package/dist/{dist-iiugPhCC.js → dist-C_9IMrtt.js} +1 -1
- package/dist/{dist-CE43BRmt.js → dist-Cb3iqED3.js} +1 -1
- package/dist/{dist-Dit9tk8a.js → dist-CoZ8kKKW.js} +1 -1
- package/dist/{dist-B5ATpkxy.js → dist-CrAYcS_4.js} +2 -2
- package/dist/dist-CrQ_pOuK.js +6 -0
- package/dist/dist-Cskx1daf.js +5 -0
- package/dist/dist-D4i0Ef34.js +8 -0
- package/dist/{dist-T4g7Sr6e.js → dist-D8EhXZ4S.js} +3 -3
- package/dist/{dist-CJrHMxlI.js → dist-DOLQQtWK.js} +3 -3
- package/dist/dist-DOcn61TX.js +8 -0
- package/dist/{dist-DqJdzAYM.js → dist-Dmr_nXF6.js} +2 -2
- package/dist/{dist-yVJ4xE5n.js → dist-DpAbrLuF.js} +5 -5
- package/dist/{dist-CcOGT46m.js → dist-DrC0QKFK.js} +1 -1
- package/dist/{dist-BYmtF1W6.js → dist-Dv2Phbh5.js} +2 -2
- package/dist/dist-DwMejAPB.js +6 -0
- package/dist/dist-DzSe1wby.js +8 -0
- package/dist/{dist-BbBnU4tG.js → dist-EZFqUJhh.js} +1 -1
- package/dist/{dist-Cgf353Ki.js → dist-Ey9hP8-j.js} +1 -1
- package/dist/{dist-BLwfpZD-.js → dist-IlWGXVjO.js} +2 -2
- package/dist/{dist-DOil6y-3.js → dist-LNp8svLl.js} +4 -4
- package/dist/{dist-CPTE45iS.js → dist-W6TdeACj.js} +1 -1
- package/dist/{dist-Dc1SFk5I.js → dist-a6Obzr07.js} +2 -2
- package/dist/{dist-Bsv_ARko.js → dist-bz6WguLy.js} +2 -2
- package/dist/{dist-CC9VUnXd.js → dist-iDeoXzdN.js} +1 -1
- package/dist/{dist-BoAHOW2l.js → dist-iyBCcLRa.js} +2 -2
- package/dist/{dist-CkEUrAus.js → dist-xCB683Dh.js} +2 -2
- package/dist/{erDiagram-Q2GNP2WA-CX1XdqVD.js → erDiagram-Q2GNP2WA-DWCa11g5.js} +10 -10
- package/dist/error-banner-vCG-EbUQ.js +619 -0
- package/dist/{esm-BAS2d2Ad.js → esm-DZSk8vt3.js} +27 -27
- package/dist/{flatten-eGRGXrC3.js → flatten-CWZjF1fc.js} +1 -1
- package/dist/{flowDiagram-NV44I4VS-BCj-ONTw.js → flowDiagram-NV44I4VS-BQ5PQs4L.js} +10 -10
- package/dist/{ganttDiagram-JELNMOA3-D1l5ewiQ.js → ganttDiagram-JELNMOA3-NTOuNWeT.js} +3 -3
- package/dist/{gitGraph-F6HP7TQM-CDM3aU-T.js → gitGraph-F6HP7TQM-DfRNsaDw.js} +3 -3
- package/dist/{gitGraphDiagram-NY62KEGX-KdZh0iiW.js → gitGraphDiagram-NY62KEGX-CYke62Ot.js} +13 -13
- package/dist/{glide-data-editor-2RvcPqmc.js → glide-data-editor-DttqGjrT.js} +571 -572
- package/dist/{graphlib-7UgfJadv.js → graphlib-CwMnCnQ9.js} +8 -8
- package/dist/{info-NVLQJR56-CoL1x1Fy.js → info-NVLQJR56-CUaoPtis.js} +3 -3
- package/dist/{infoDiagram-WHAUD3N6-PSH7lQ0D.js → infoDiagram-WHAUD3N6-B42WjAPh.js} +13 -13
- package/dist/{isEmpty-DQXRKNtW.js → isEmpty-6z2uv6gM.js} +2 -2
- package/dist/{isString-Clqvtgmo.js → isString-D6abkXrl.js} +1 -1
- package/dist/{isSymbol-TWXhTa8k.js → isSymbol-hk7foJ70.js} +1 -1
- package/dist/{journeyDiagram-XKPGCS4Q-BrTAxQ1J.js → journeyDiagram-XKPGCS4Q-ahXD97kr.js} +3 -3
- package/dist/{kanban-definition-3W4ZIXB7-BoYCDp_9.js → kanban-definition-3W4ZIXB7-CiTIpnhy.js} +7 -7
- package/dist/{label-CxU5JNBW.js → label-Cc5tEavt.js} +250 -250
- package/dist/{loader-C0-eIoas.js → loader-Cob3XFOw.js} +2 -2
- package/dist/main.js +1791 -1056
- package/dist/{memoize-Bag7B41I.js → memoize-Ckyqzyu_.js} +1 -1
- package/dist/{merge-Dl1bfxsj.js → merge-Db4Uulx4.js} +1 -1
- package/dist/{mermaid-C2cSe5YL.js → mermaid-B5xl_2hx.js} +73 -62
- package/dist/{mermaid-parser.core-D20zFbMa.js → mermaid-parser.core-BXj7Il0J.js} +8 -8
- package/dist/{min-Bg4bqmiD.js → min-ypdVXicC.js} +4 -4
- package/dist/{mindmap-definition-VGOIOE7T-CmRjsKEt.js → mindmap-definition-VGOIOE7T-Mni766A_.js} +9 -9
- package/dist/{now-mivqkCIv.js → now-Dwu5ou19.js} +2 -2
- package/dist/{once-BqS42WgZ.js → once-C9dA9qgQ.js} +1 -1
- package/dist/{packet-BFZMPI3H-C6aZmgV-.js → packet-BFZMPI3H-DHtQCusE.js} +3 -3
- package/dist/{pie-7BOR55EZ-NB6xYwcB.js → pie-7BOR55EZ-2sVLYbpR.js} +3 -3
- package/dist/{pieDiagram-ADFJNKIX-CtxQlnsU.js → pieDiagram-ADFJNKIX-PbXpgT8_.js} +14 -14
- package/dist/{quadrantDiagram-AYHSOK5B-DllnB2Hl.js → quadrantDiagram-AYHSOK5B-BtXGnx8i.js} +2 -2
- package/dist/{radar-NHE76QYJ-RKhErikV.js → radar-NHE76QYJ-Be0pEUux.js} +3 -3
- package/dist/{range-LoQMRQIX.js → range-D9jxVFd_.js} +5 -5
- package/dist/{reduce-B9mZDxPo.js → reduce-C6NEPj6s.js} +4 -4
- package/dist/{requirementDiagram-UZGBJVZJ-D36MI1k0.js → requirementDiagram-UZGBJVZJ-DxzXQRgq.js} +9 -9
- package/dist/{sankeyDiagram-TZEHDZUN-D1mygNPC.js → sankeyDiagram-TZEHDZUN-D-I7dJ0_.js} +2 -2
- package/dist/{sequenceDiagram-WL72ISMW-CWdn91Rf.js → sequenceDiagram-WL72ISMW-VDme2ljw.js} +4 -4
- package/dist/{slides-component-DfwLApNr.js → slides-component-ql7-5GDI.js} +2 -2
- package/dist/{spec-HoYHAQo2.js → spec-GwhMEXwK.js} +8 -9
- package/dist/{stateDiagram-FKZM4ZOC-CPxroWXd.js → stateDiagram-FKZM4ZOC-g3GI1EcK.js} +12 -12
- package/dist/{stateDiagram-v2-4FDKWEC3-BpM9Q54b.js → stateDiagram-v2-4FDKWEC3-7i6jBXe6.js} +10 -10
- package/dist/stex-D2rme5UG.js +4 -0
- package/dist/style.css +1 -1
- package/dist/{timeline-definition-IT6M3QCI-CVnRHx_t.js → timeline-definition-IT6M3QCI-bhvLlX_b.js} +2 -2
- package/dist/{toString-C4TLO6FA.js → toString-BwTJvlyD.js} +2 -2
- package/dist/tooltip-CL8m4f9y.js +404 -0
- package/dist/{treemap-KMMF4GRG-B37ugcLd.js → treemap-KMMF4GRG-Ba9ifjpG.js} +3 -3
- package/dist/{types-Ckva8JJq.js → types-Dsh6yC4B.js} +412 -413
- package/dist/{useAsyncData-dr8GazGv.js → useAsyncData-BPpyKjTJ.js} +2 -2
- package/dist/{useDeepCompareMemoize-ChviuF5n.js → useDeepCompareMemoize-C8Ms87P-.js} +18 -19
- package/dist/{useIframeCapabilities-DurI5SJh.js → useIframeCapabilities-C7z8VrZ1.js} +2 -2
- package/dist/{useTheme-SlKl8MlS.js → useTheme-Cq-gIssy.js} +299 -300
- package/dist/{vega-component-CnG0vAjf.js → vega-component-B5sxdjMq.js} +10 -10
- package/dist/{xychartDiagram-PRI3JC2R-BltwMWKC.js → xychartDiagram-PRI3JC2R-CFxuifYY.js} +5 -5
- package/package.json +1 -1
- package/src/components/editor/Output.tsx +8 -6
- package/src/components/editor/__tests__/Output.test.tsx +59 -0
- package/src/components/editor/chrome/__tests__/state.test.ts +321 -0
- package/src/components/editor/chrome/state.ts +27 -2
- package/src/components/editor/file-tree/upload.tsx +46 -23
- package/src/components/editor/links/cell-link.tsx +3 -2
- package/src/components/editor/output/console/ConsoleOutput.tsx +13 -3
- package/src/components/pages/gallery-page.tsx +1 -1
- package/src/components/pages/home-page.tsx +5 -3
- package/src/components/tracing/tracing.tsx +50 -39
- package/src/core/documentation/DocHoverTarget.tsx +23 -0
- package/src/core/documentation/doc-lookup.ts +50 -0
- package/src/core/islands/main.ts +1 -0
- package/src/core/websocket/useMarimoKernelConnection.tsx +3 -0
- package/src/css/app/Cell.css +5 -0
- package/src/mount.tsx +2 -2
- package/src/plugins/core/RenderHTML.tsx +15 -0
- package/src/plugins/core/__test__/registerReactComponent.test.ts +204 -0
- package/src/plugins/core/registerReactComponent.tsx +33 -0
- package/src/plugins/impl/MatrixPlugin.tsx +275 -0
- package/src/plugins/impl/__tests__/MatrixPlugin.test.tsx +415 -0
- package/src/plugins/impl/anywidget/model.ts +1 -2
- package/src/plugins/impl/matplotlib/MatplotlibPlugin.tsx +70 -0
- package/src/plugins/impl/matplotlib/__tests__/matplotlib-renderer.test.ts +152 -0
- package/src/plugins/impl/matplotlib/matplotlib-renderer.ts +781 -0
- package/src/plugins/impl/matrix.css +45 -0
- package/src/plugins/layout/mermaid/mermaid.tsx +11 -3
- package/src/plugins/plugins.ts +4 -0
- package/src/utils/__tests__/download.test.tsx +47 -0
- package/src/utils/download.ts +13 -1
- package/src/utils/links.ts +1 -1
- package/src/utils/urls.ts +1 -1
- package/dist/Combination-BTMrlhzT.js +0 -2611
- package/dist/architecture-U656AL7Q-COfwZju8.js +0 -6
- package/dist/dist-4YNZxwMI.js +0 -8
- package/dist/dist-7nR3r2kG.js +0 -5
- package/dist/dist-B2gkyT3r.js +0 -5
- package/dist/dist-B8G3I6vJ.js +0 -8
- package/dist/dist-BJ96Ykfp.js +0 -8
- package/dist/dist-BKLIWGw4.js +0 -5
- package/dist/dist-Bf3ou00A.js +0 -6
- package/dist/dist-BvkKXuPm.js +0 -5
- package/dist/dist-C6NJ3n6r.js +0 -5
- package/dist/dist-CecLPYY5.js +0 -5
- package/dist/dist-Ch0SwRzK.js +0 -5
- package/dist/dist-D6eWHiFh.js +0 -6
- package/dist/dist-DCQ710Bv.js +0 -5
- package/dist/dist-P_pkS5f-.js +0 -8
- package/dist/error-banner-D2zjeN_a.js +0 -1015
- package/dist/hotkeys-B5WnGZXF.js +0 -587
- package/dist/stex-ChDHQs3R.js +0 -4
- package/dist/zod-bjADtMKr.js +0 -10663
- /package/dist/{_arrayReduce-DlK7U3Q6.js → _arrayReduce-REKcIEj3.js} +0 -0
- /package/dist/{_baseFor-DSVmVciX.js → _baseFor-B69PDbIz.js} +0 -0
- /package/dist/{_hasUnicode-Bz2x6u6r.js → _hasUnicode-DrSAc5A5.js} +0 -0
- /package/dist/{dist-r8ecBV-v.js → dist-CUOuFgHt.js} +0 -0
- /package/dist/{invariant-D9QLJ4SZ.js → invariant-D-K49MfV.js} +0 -0
- /package/dist/{main-DhFbkwoC.js → main-DmxVpB19.js} +0 -0
- /package/dist/{purify.es-Brw-U87Q.js → purify.es-D4vaFt5N.js} +0 -0
- /package/dist/{stex-DrxP7bb3.js → stex-DIvyJfNO.js} +0 -0
|
@@ -4,15 +4,14 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
4
4
|
import { s as __toESM, t as __commonJSMin } from "./chunk-BNovOVIE.js";
|
|
5
5
|
import { t as require_react } from "./react-Bs6Z0kvn.js";
|
|
6
6
|
import { t as require_compiler_runtime } from "./compiler-runtime-B_OLMU9S.js";
|
|
7
|
-
import { n as Copy, r as toast, t as copyToClipboard } from "./copy-
|
|
8
|
-
import "./
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import
|
|
12
|
-
import { s as Logger } from "./hotkeys-B5WnGZXF.js";
|
|
7
|
+
import { n as Copy, r as toast, t as copyToClipboard } from "./copy-oc-FcZzt.js";
|
|
8
|
+
import { O as logNever, i as SelectContent, l as SelectTrigger, o as SelectItem, r as Select, t as Label, u as SelectValue } from "./label-Cc5tEavt.js";
|
|
9
|
+
import { H as ErrorBoundary, U as require_prop_types, _ as DropdownMenuSeparator, b as DropdownMenuSubTrigger, d as DropdownMenu, f as DropdownMenuContent, ft as useNonce, g as DropdownMenuPortal, gn as Pencil, gt as capitalize_default, hn as Plus, i as Input, m as DropdownMenuItem, pn as Trash, pt as marked, t as BulkEdit, v as DropdownMenuSub, y as DropdownMenuSubContent } from "./types-Dsh6yC4B.js";
|
|
10
|
+
import { g as Logger, h as Events, t as Button } from "./button-KYalaJYu.js";
|
|
11
|
+
import "./Combination-Du-o_hC9.js";
|
|
13
12
|
import { t as require_jsx_runtime } from "./jsx-runtime-CTBg5pdT.js";
|
|
14
13
|
import "./react-dom-CqtLRVZP.js";
|
|
15
|
-
import {
|
|
14
|
+
import { C as useEvent_default, n as useTheme } from "./useTheme-Cq-gIssy.js";
|
|
16
15
|
import { A as require__Map, B as require__baseGetTag, C as require__hasPath, D as require_isArguments, E as require__isIndex, F as require_isFunction, G as assert, H as require__root, I as require_isObject, J as maybe, K as assertNever, L as require__isKey, M as require_eq, N as require__getNative, O as require__castPath, P as require__toSource, R as require_isSymbol, S as resolveCellsThunk, T as require_isLength, U as require__freeGlobal, V as require__Symbol, W as require_isArray, _ as isEditableGridCell, a as mergeAndRealizeTheme, b as isReadWriteCell, c as withAlpha, d as CompactSelection, f as GridCellKind, g as booleanCellIsEditable, h as InnerGridCellKind, i as makeCSSStyle, j as require__ListCache, k as require__MapCache, l as BooleanEmpty, m as GridColumnMenuIcon, n as ThemeContext, o as blend, p as GridColumnIcon, q as deepEqual, r as getDataEditorTheme, s as blendCache, t as ClickOutsideContainer, u as BooleanIndeterminate, v as isInnerOnlyCell, w as require__toKey, x as isSizedGridColumn, y as isObjectEditorCallbackResult, z as require_isObjectLike } from "./click-outside-container-C_k38vlR.js";
|
|
17
16
|
import { t as styled_default } from "./dist-DF_77D2B.js";
|
|
18
17
|
let GlideDataEditor, glide_data_editor_default;
|
|
@@ -3169,36 +3168,36 @@ let __tla = (async () => {
|
|
|
3169
3168
|
kind: GridCellKind.Loading,
|
|
3170
3169
|
allowOverlay: false
|
|
3171
3170
|
};
|
|
3172
|
-
function drawCells(e, t, n, r, i, a, o, s, c, l, u, f, m, h, g, y, x, S, C, E, D, O, k, A, j, M, N, P, F, I, L, Pr, B, Fr,
|
|
3173
|
-
let
|
|
3174
|
-
e.font =
|
|
3175
|
-
let
|
|
3171
|
+
function drawCells(e, t, n, r, i, a, o, s, c, l, u, f, m, h, g, y, x, S, C, E, D, O, k, A, j, M, N, P, F, I, L, Pr, B, Fr, Ir) {
|
|
3172
|
+
let V = (E == null ? void 0 : E.size) ?? 2 ** 53 - 1, Lr = performance.now(), H = I.baseFontFull;
|
|
3173
|
+
e.font = H;
|
|
3174
|
+
let Rr = {
|
|
3176
3175
|
ctx: e
|
|
3177
|
-
},
|
|
3176
|
+
}, U = [
|
|
3178
3177
|
0,
|
|
3179
3178
|
0
|
|
3180
|
-
],
|
|
3181
|
-
return walkColumns(t, s, a, o, i, (t2, a2, o2, s2,
|
|
3182
|
-
let
|
|
3179
|
+
], W = x > 0 ? getFreezeTrailingHeight(c, x, l) : 0, zr, G, K = getSkipPoint(C);
|
|
3180
|
+
return walkColumns(t, s, a, o, i, (t2, a2, o2, s2, Br) => {
|
|
3181
|
+
let Vr = Math.max(0, s2 - a2), Hr = a2 + Vr, Ur = i + 1, Wr = t2.width - Vr, Gr = r - i - 1;
|
|
3183
3182
|
if (C.length > 0) {
|
|
3184
3183
|
let e2 = false;
|
|
3185
3184
|
for (let t3 = 0; t3 < C.length; t3++) {
|
|
3186
3185
|
let n2 = C[t3];
|
|
3187
|
-
if (intersectRect(
|
|
3186
|
+
if (intersectRect(Hr, Ur, Wr, Gr, n2.x, n2.y, n2.width, n2.height)) {
|
|
3188
3187
|
e2 = true;
|
|
3189
3188
|
break;
|
|
3190
3189
|
}
|
|
3191
3190
|
}
|
|
3192
3191
|
if (!e2) return;
|
|
3193
3192
|
}
|
|
3194
|
-
let
|
|
3195
|
-
e.save(), e.beginPath(), e.rect(
|
|
3196
|
-
},
|
|
3197
|
-
|
|
3198
|
-
let
|
|
3199
|
-
return walkRowsInCol(
|
|
3193
|
+
let Kr = () => {
|
|
3194
|
+
e.save(), e.beginPath(), e.rect(Hr, Ur, Wr, Gr), e.clip();
|
|
3195
|
+
}, qr = D.columns.hasIndex(t2.sourceIndex), q = f(t2.group ?? "").overrideTheme, Jr = t2.themeOverride === void 0 && q === void 0 ? I : mergeAndRealizeTheme(I, q, t2.themeOverride), Yr = Jr.baseFontFull;
|
|
3196
|
+
Yr !== H && (H = Yr, e.font = Yr), Kr();
|
|
3197
|
+
let Xr;
|
|
3198
|
+
return walkRowsInCol(Br, o2, r, c, l, x, S, K, (i2, o3, l2, f2, x2) => {
|
|
3200
3199
|
var _a, _b, _c;
|
|
3201
|
-
if (o3 < 0 || (
|
|
3200
|
+
if (o3 < 0 || (U[0] = t2.sourceIndex, U[1] = o3, E !== void 0 && !E.has(U))) return;
|
|
3202
3201
|
if (C.length > 0) {
|
|
3203
3202
|
let e2 = false;
|
|
3204
3203
|
for (let n2 = 0; n2 < C.length; n2++) {
|
|
@@ -3210,66 +3209,66 @@ let __tla = (async () => {
|
|
|
3210
3209
|
}
|
|
3211
3210
|
if (!e2) return;
|
|
3212
3211
|
}
|
|
3213
|
-
let S2 = D.rows.hasIndex(o3),
|
|
3214
|
-
if (
|
|
3215
|
-
let [r2, c2] =
|
|
3216
|
-
if (
|
|
3217
|
-
|
|
3212
|
+
let S2 = D.rows.hasIndex(o3), K2 = h.hasIndex(o3), Br2 = o3 < c ? u(U) : loadingCell$1, Vr2 = a2, Hr2 = t2.width, Ur2 = false, Wr2 = false;
|
|
3213
|
+
if (Br2.span !== void 0) {
|
|
3214
|
+
let [r2, c2] = Br2.span, u2 = `${o3},${r2},${c2},${t2.sticky}`;
|
|
3215
|
+
if (G === void 0 && (G = /* @__PURE__ */ new Set()), G.has(u2)) {
|
|
3216
|
+
V--;
|
|
3218
3217
|
return;
|
|
3219
3218
|
} else {
|
|
3220
|
-
let r3 = getSpanBounds(
|
|
3221
|
-
if (!t2.sticky && r3[0] !== void 0 && (
|
|
3222
|
-
|
|
3219
|
+
let r3 = getSpanBounds(Br2.span, a2, i2, t2.width, l2, t2, n), o4 = t2.sticky ? r3[0] : r3[1];
|
|
3220
|
+
if (!t2.sticky && r3[0] !== void 0 && (Wr2 = true), o4 !== void 0) {
|
|
3221
|
+
Vr2 = o4.x, Hr2 = o4.width, G.add(u2), e.restore(), Xr = void 0, e.save(), e.beginPath();
|
|
3223
3222
|
let t3 = Math.max(0, s2 - o4.x);
|
|
3224
|
-
e.rect(o4.x + t3, i2, o4.width - t3, l2),
|
|
3223
|
+
e.rect(o4.x + t3, i2, o4.width - t3, l2), zr === void 0 && (zr = []), zr.push({
|
|
3225
3224
|
x: o4.x + t3,
|
|
3226
3225
|
y: i2,
|
|
3227
3226
|
width: o4.width - t3,
|
|
3228
3227
|
height: l2
|
|
3229
|
-
}), e.clip(),
|
|
3228
|
+
}), e.clip(), Ur2 = true;
|
|
3230
3229
|
}
|
|
3231
3230
|
}
|
|
3232
3231
|
}
|
|
3233
|
-
let
|
|
3232
|
+
let Gr2 = m == null ? void 0 : m(o3), q2 = x2 && ((_a = t2.trailingRowOptions) == null ? void 0 : _a.themeOverride) !== void 0 ? (_b = t2.trailingRowOptions) == null ? void 0 : _b.themeOverride : void 0, J = Br2.themeOverride === void 0 && Gr2 === void 0 && q2 === void 0 ? Jr : mergeAndRealizeTheme(Jr, Gr2, q2, Br2.themeOverride);
|
|
3234
3233
|
e.beginPath();
|
|
3235
|
-
let
|
|
3236
|
-
|
|
3237
|
-
let
|
|
3238
|
-
if ((f2 ||
|
|
3239
|
-
|
|
3240
|
-
for (let e2 = 0; e2 <
|
|
3234
|
+
let Zr = cellIsSelected(U, Br2, D), Y = cellIsInRange(U, Br2, D, y), Qr = Br2.span !== void 0 && D.columns.some((e2) => Br2.span !== void 0 && e2 >= Br2.span[0] && e2 <= Br2.span[1]);
|
|
3235
|
+
Zr && !g && y ? Y = 0 : Zr && y && (Y = Math.max(Y, 1)), Qr && Y++, Zr || (S2 && Y++, qr && !x2 && Y++);
|
|
3236
|
+
let $r = Br2.kind === GridCellKind.Protected ? J.bgCellMedium : J.bgCell, ti;
|
|
3237
|
+
if ((f2 || $r !== I.bgCell) && (ti = blend($r, ti)), Y > 0 || K2) {
|
|
3238
|
+
K2 && (ti = blend(J.bgHeader, ti));
|
|
3239
|
+
for (let e2 = 0; e2 < Y; e2++) ti = blend(J.accentLight, ti);
|
|
3241
3240
|
} else if (O !== void 0) {
|
|
3242
3241
|
for (let e2 of O) if (e2[0] === t2.sourceIndex && e2[1] === o3) {
|
|
3243
|
-
|
|
3242
|
+
ti = blend(J.bgSearchResult, ti);
|
|
3244
3243
|
break;
|
|
3245
3244
|
}
|
|
3246
3245
|
}
|
|
3247
3246
|
if (k !== void 0) for (let e2 = 0; e2 < k.length; e2++) {
|
|
3248
3247
|
let n2 = k[e2], r2 = n2.range;
|
|
3249
|
-
n2.style !== "solid-outline" && r2.x <= t2.sourceIndex && t2.sourceIndex < r2.x + r2.width && r2.y <= o3 && o3 < r2.y + r2.height && (
|
|
3248
|
+
n2.style !== "solid-outline" && r2.x <= t2.sourceIndex && t2.sourceIndex < r2.x + r2.width && r2.y <= o3 && o3 < r2.y + r2.height && (ti = blend(n2.color, ti));
|
|
3250
3249
|
}
|
|
3251
|
-
let
|
|
3250
|
+
let ni = false;
|
|
3252
3251
|
if (E !== void 0) {
|
|
3253
|
-
let t3 = i2 + 1, n2 = (f2 ? t3 + l2 - 1 : Math.min(t3 + l2 - 1, r -
|
|
3254
|
-
(n2 !== l2 - 1 ||
|
|
3252
|
+
let t3 = i2 + 1, n2 = (f2 ? t3 + l2 - 1 : Math.min(t3 + l2 - 1, r - W)) - t3;
|
|
3253
|
+
(n2 !== l2 - 1 || Vr2 + 1 <= s2) && (ni = true, e.save(), e.beginPath(), e.rect(Vr2 + 1, t3, Hr2 - 1, n2), e.clip()), ti = ti === void 0 ? J.bgCell : blend(ti, J.bgCell);
|
|
3255
3254
|
}
|
|
3256
|
-
let
|
|
3257
|
-
|
|
3258
|
-
let
|
|
3255
|
+
let ri = t2.sourceIndex === n.length - 1, ai = o3 === c - 1;
|
|
3256
|
+
ti !== void 0 && (e.fillStyle = ti, Xr !== void 0 && (Xr.fillStyle = ti), E === void 0 ? e.fillRect(Vr2, i2, Hr2, l2) : e.fillRect(Vr2 + 1, i2 + 1, Hr2 - (ri ? 2 : 1), l2 - (ai ? 2 : 1))), Br2.style === "faded" && (e.globalAlpha = 0.6);
|
|
3257
|
+
let oi;
|
|
3259
3258
|
for (let e2 = 0; e2 < M.length; e2++) {
|
|
3260
3259
|
let n2 = M[e2];
|
|
3261
3260
|
if (n2.item[0] === t2.sourceIndex && n2.item[1] === o3) {
|
|
3262
|
-
|
|
3261
|
+
oi = n2;
|
|
3263
3262
|
break;
|
|
3264
3263
|
}
|
|
3265
3264
|
}
|
|
3266
|
-
if (
|
|
3267
|
-
let n2 =
|
|
3268
|
-
n2 !==
|
|
3265
|
+
if (Hr2 > Ir && !Wr2) {
|
|
3266
|
+
let n2 = J.baseFontFull;
|
|
3267
|
+
n2 !== H && (e.font = n2, H = n2), Xr = drawCell(e, Br2, t2.sourceIndex, o3, ri, ai, Vr2, i2, Hr2, l2, Y > 0, J, ti ?? J.bgCell, A, j, (oi == null ? void 0 : oi.hoverAmount) ?? 0, N, F, Lr, P, Xr, L, Pr, B, Fr);
|
|
3269
3268
|
}
|
|
3270
|
-
return
|
|
3271
|
-
}), e.restore(),
|
|
3272
|
-
}),
|
|
3269
|
+
return ni && e.restore(), Br2.style === "faded" && (e.globalAlpha = 1), V--, Ur2 && (e.restore(), (_c = Xr == null ? void 0 : Xr.deprep) == null ? void 0 : _c.call(Xr, Rr), Xr = void 0, Kr(), H = Yr, e.font = Yr), V <= 0;
|
|
3270
|
+
}), e.restore(), V <= 0;
|
|
3271
|
+
}), zr;
|
|
3273
3272
|
}
|
|
3274
3273
|
var allocatedItem = [
|
|
3275
3274
|
0,
|
|
@@ -4403,34 +4402,34 @@ let __tla = (async () => {
|
|
|
4403
4402
|
}
|
|
4404
4403
|
function drawGrid(e, t) {
|
|
4405
4404
|
var _a;
|
|
4406
|
-
let { canvasCtx: n, headerCanvasCtx: r, width: i, height: a, cellXOffset: o, cellYOffset: s, translateX: c, translateY: l, mappedColumns: u, enableGroups: f, freezeColumns: m, dragAndDropState: h, theme: g, drawFocus: y, headerHeight: x, groupHeaderHeight: S, disabledRows: C, rowHeight: E, verticalBorder: D, overrideCursor: O, isResizing: k, selection: A, fillHandle: j, freezeTrailingRows: M, rows: N, getCellContent: P, getGroupDetails: F, getRowThemeOverride: I, isFocused: L, drawHeaderCallback: Pr, prelightCells: B, drawCellCallback: Fr, highlightRegions:
|
|
4405
|
+
let { canvasCtx: n, headerCanvasCtx: r, width: i, height: a, cellXOffset: o, cellYOffset: s, translateX: c, translateY: l, mappedColumns: u, enableGroups: f, freezeColumns: m, dragAndDropState: h, theme: g, drawFocus: y, headerHeight: x, groupHeaderHeight: S, disabledRows: C, rowHeight: E, verticalBorder: D, overrideCursor: O, isResizing: k, selection: A, fillHandle: j, freezeTrailingRows: M, rows: N, getCellContent: P, getGroupDetails: F, getRowThemeOverride: I, isFocused: L, drawHeaderCallback: Pr, prelightCells: B, drawCellCallback: Fr, highlightRegions: Ir, resizeCol: V, imageLoader: Lr, lastBlitData: H, hoverValues: Rr, hyperWrapping: U, hoverInfo: W, spriteManager: zr, maxScaleFactor: G, hasAppendRow: K, touchMode: Vr, enqueue: Hr, renderStateProvider: Ur, getCellRenderer: Wr, renderStrategy: Gr, bufferACtx: Kr, bufferBCtx: qr, damage: q, minimumCellWidth: Jr, resizeIndicator: Yr } = e;
|
|
4407
4406
|
if (i === 0 || a === 0) return;
|
|
4408
|
-
let
|
|
4409
|
-
(
|
|
4410
|
-
let
|
|
4411
|
-
(
|
|
4412
|
-
let
|
|
4413
|
-
|
|
4414
|
-
let
|
|
4415
|
-
if (
|
|
4416
|
-
let
|
|
4417
|
-
|
|
4418
|
-
let
|
|
4419
|
-
|
|
4420
|
-
let
|
|
4421
|
-
|
|
4422
|
-
let
|
|
4423
|
-
if (
|
|
4424
|
-
for (let e2 of
|
|
4407
|
+
let Xr = Gr === "double-buffer", J = Math.min(G, Math.ceil(window.devicePixelRatio ?? 1)), Zr = Gr !== "direct" && computeCanBlit(e, t), Y = n.canvas;
|
|
4408
|
+
(Y.width !== i * J || Y.height !== a * J) && (Y.width = i * J, Y.height = a * J, Y.style.width = i + "px", Y.style.height = a + "px");
|
|
4409
|
+
let Qr = r.canvas, $r = f ? S + x : x, ei = $r + 1;
|
|
4410
|
+
(Qr.width !== i * J || Qr.height !== ei * J) && (Qr.width = i * J, Qr.height = ei * J, Qr.style.width = i + "px", Qr.style.height = ei + "px");
|
|
4411
|
+
let ti = Kr.canvas, ni = qr.canvas;
|
|
4412
|
+
Xr && (ti.width !== i * J || ti.height !== a * J) && (ti.width = i * J, ti.height = a * J, H.current !== void 0 && (H.current.aBufferScroll = void 0)), Xr && (ni.width !== i * J || ni.height !== a * J) && (ni.width = i * J, ni.height = a * J, H.current !== void 0 && (H.current.bBufferScroll = void 0));
|
|
4413
|
+
let ri = H.current;
|
|
4414
|
+
if (Zr === true && o === (ri == null ? void 0 : ri.cellXOffset) && s === (ri == null ? void 0 : ri.cellYOffset) && c === (ri == null ? void 0 : ri.translateX) && l === (ri == null ? void 0 : ri.translateY)) return;
|
|
4415
|
+
let ii = null;
|
|
4416
|
+
Xr && (ii = n);
|
|
4417
|
+
let ai = r, oi;
|
|
4418
|
+
oi = Xr ? q === void 0 ? (ri == null ? void 0 : ri.lastBuffer) === "b" ? Kr : qr : (ri == null ? void 0 : ri.lastBuffer) === "b" ? qr : Kr : n;
|
|
4419
|
+
let si = oi.canvas, ci = Xr ? si === ti ? ni : ti : Y, li = typeof E == "number" ? () => E : E;
|
|
4420
|
+
ai.save(), oi.save(), ai.beginPath(), oi.beginPath(), ai.textBaseline = "middle", oi.textBaseline = "middle", J !== 1 && (ai.scale(J, J), oi.scale(J, J));
|
|
4421
|
+
let X = getEffectiveColumns(u, o, i, h, c), ui = [], di = y && ((_a = A.current) == null ? void 0 : _a.cell[1]) === s && l === 0, pi = false;
|
|
4422
|
+
if (Ir !== void 0) {
|
|
4423
|
+
for (let e2 of Ir) if (e2.style !== "no-outline" && e2.range.y === s && l === 0) {
|
|
4425
4424
|
pi = true;
|
|
4426
4425
|
break;
|
|
4427
4426
|
}
|
|
4428
4427
|
}
|
|
4429
4428
|
let mi = () => {
|
|
4430
|
-
drawGridHeaders(
|
|
4429
|
+
drawGridHeaders(ai, X, f, W, i, c, x, S, h, k, A, g, zr, Rr, D, F, q, Pr, Vr), drawGridLines(ai, X, s, c, l, i, a, void 0, void 0, S, $r, li, I, D, M, N, g, true), ai.beginPath(), ai.moveTo(0, ei - 0.5), ai.lineTo(i, ei - 0.5), ai.strokeStyle = blend(g.headerBottomBorderColor ?? g.horizontalBorderColor ?? g.borderColor, g.bgHeader), ai.stroke(), pi && drawHighlightRings(ai, i, a, o, s, c, l, u, m, x, S, E, M, N, Ir, g), di && drawFillHandle(ai, i, a, s, c, l, X, u, g, $r, A, li, P, M, K, j, N);
|
|
4431
4430
|
};
|
|
4432
|
-
if (
|
|
4433
|
-
let e2 =
|
|
4431
|
+
if (q !== void 0) {
|
|
4432
|
+
let e2 = X[X.length - 1].sourceIndex + 1, t2 = q.hasItemInRegion([
|
|
4434
4433
|
{
|
|
4435
4434
|
x: o,
|
|
4436
4435
|
y: -2,
|
|
@@ -4463,54 +4462,54 @@ let __tla = (async () => {
|
|
|
4463
4462
|
when: M > 0
|
|
4464
4463
|
}
|
|
4465
4464
|
]), n2 = (e3) => {
|
|
4466
|
-
drawCells(e3,
|
|
4465
|
+
drawCells(e3, X, u, a, $r, c, l, s, N, li, P, F, I, C, L, y, M, K, ui, q, A, B, Ir, Lr, zr, Rr, W, Fr, U, g, Hr, Ur, Wr, O, Jr);
|
|
4467
4466
|
let t3 = A.current;
|
|
4468
|
-
j && y && t3 !== void 0 &&
|
|
4467
|
+
j && y && t3 !== void 0 && q.has(rectBottomRight(t3.range)) && drawFillHandle(e3, i, a, s, c, l, X, u, g, $r, A, li, P, M, K, j, N);
|
|
4469
4468
|
};
|
|
4470
|
-
t2 && (n2(
|
|
4469
|
+
t2 && (n2(oi), ii !== null && (ii.save(), ii.scale(J, J), ii.textBaseline = "middle", n2(ii), ii.restore()), q.hasHeader() && (clipHeaderDamage(ai, X, i, S, $r, c, l, s, q), mi())), oi.restore(), ai.restore();
|
|
4471
4470
|
return;
|
|
4472
4471
|
}
|
|
4473
|
-
if ((
|
|
4474
|
-
assert(
|
|
4475
|
-
let { regions: e2 } = blitLastFrame(
|
|
4472
|
+
if ((Zr !== true || o !== (ri == null ? void 0 : ri.cellXOffset) || c !== (ri == null ? void 0 : ri.translateX) || di !== (ri == null ? void 0 : ri.mustDrawFocusOnHeader) || pi !== (ri == null ? void 0 : ri.mustDrawHighlightRingsOnHeader)) && mi(), Zr === true) {
|
|
4473
|
+
assert(ci !== void 0 && ri !== void 0);
|
|
4474
|
+
let { regions: e2 } = blitLastFrame(oi, ci, ci === ti ? ri.aBufferScroll : ri.bBufferScroll, ci === ti ? ri.bBufferScroll : ri.aBufferScroll, ri, o, s, c, l, M, i, a, N, $r, J, u, X, E, Xr);
|
|
4476
4475
|
ui = e2;
|
|
4477
|
-
} else
|
|
4478
|
-
overdrawStickyBoundaries(
|
|
4479
|
-
let hi = drawHighlightRings(
|
|
4480
|
-
if (
|
|
4481
|
-
|
|
4482
|
-
for (let e2 of ui)
|
|
4483
|
-
|
|
4484
|
-
} else
|
|
4485
|
-
let _i = drawCells(
|
|
4486
|
-
drawBlanks(
|
|
4487
|
-
let vi = getLastRow(
|
|
4488
|
-
|
|
4476
|
+
} else Zr !== false && (assert(ri !== void 0), ui = blitResizedCol(ri, o, s, c, l, i, a, $r, X, Zr));
|
|
4477
|
+
overdrawStickyBoundaries(oi, X, i, a, M, N, D, li, g);
|
|
4478
|
+
let hi = drawHighlightRings(oi, i, a, o, s, c, l, u, m, x, S, E, M, N, Ir, g), gi = y ? drawFillHandle(oi, i, a, s, c, l, X, u, g, $r, A, li, P, M, K, j, N) : void 0;
|
|
4479
|
+
if (oi.fillStyle = g.bgCell, ui.length > 0) {
|
|
4480
|
+
oi.beginPath();
|
|
4481
|
+
for (let e2 of ui) oi.rect(e2.x, e2.y, e2.width, e2.height);
|
|
4482
|
+
oi.clip(), oi.fill(), oi.beginPath();
|
|
4483
|
+
} else oi.fillRect(0, 0, i, a);
|
|
4484
|
+
let _i = drawCells(oi, X, u, a, $r, c, l, s, N, li, P, F, I, C, L, y, M, K, ui, q, A, B, Ir, Lr, zr, Rr, W, Fr, U, g, Hr, Ur, Wr, O, Jr);
|
|
4485
|
+
drawBlanks(oi, X, u, i, a, $r, c, l, s, N, li, I, A.rows, C, M, K, ui, q, g), drawExtraRowThemes(oi, X, s, c, l, i, a, ui, $r, li, I, D, M, N, g), drawGridLines(oi, X, s, c, l, i, a, ui, _i, S, $r, li, I, D, M, N, g), hi == null ? void 0 : hi(), gi == null ? void 0 : gi(), k && Yr !== "none" && walkColumns(X, 0, c, 0, $r, (e2, t2) => e2.sourceIndex === V ? (drawColumnResizeOutline(ai, t2 + e2.width, 0, $r + 1, blend(g.resizeIndicatorColor ?? g.accentLight, g.bgHeader)), Yr === "full" && drawColumnResizeOutline(oi, t2 + e2.width, $r, a, blend(g.resizeIndicatorColor ?? g.accentLight, g.bgCell)), true) : false), ii !== null && (ii.fillStyle = g.bgCell, ii.fillRect(0, 0, i, a), ii.drawImage(oi.canvas, 0, 0));
|
|
4486
|
+
let vi = getLastRow(X, a, $r, c, l, s, N, li, M, K);
|
|
4487
|
+
Lr == null ? void 0 : Lr.setWindow({
|
|
4489
4488
|
x: o,
|
|
4490
4489
|
y: s,
|
|
4491
|
-
width:
|
|
4490
|
+
width: X.length,
|
|
4492
4491
|
height: vi - s
|
|
4493
4492
|
}, m, Array.from({
|
|
4494
4493
|
length: M
|
|
4495
4494
|
}, (e2, t2) => N - 1 - t2));
|
|
4496
|
-
let yi =
|
|
4497
|
-
|
|
4495
|
+
let yi = ri !== void 0 && (o !== ri.cellXOffset || c !== ri.translateX), bi = ri !== void 0 && (s !== ri.cellYOffset || l !== ri.translateY);
|
|
4496
|
+
H.current = {
|
|
4498
4497
|
cellXOffset: o,
|
|
4499
4498
|
cellYOffset: s,
|
|
4500
4499
|
translateX: c,
|
|
4501
4500
|
translateY: l,
|
|
4502
4501
|
mustDrawFocusOnHeader: di,
|
|
4503
4502
|
mustDrawHighlightRingsOnHeader: pi,
|
|
4504
|
-
lastBuffer:
|
|
4505
|
-
aBufferScroll:
|
|
4503
|
+
lastBuffer: Xr ? si === ti ? "a" : "b" : void 0,
|
|
4504
|
+
aBufferScroll: si === ti ? [
|
|
4506
4505
|
yi,
|
|
4507
4506
|
bi
|
|
4508
|
-
] :
|
|
4509
|
-
bBufferScroll:
|
|
4507
|
+
] : ri == null ? void 0 : ri.aBufferScroll,
|
|
4508
|
+
bBufferScroll: si === ni ? [
|
|
4510
4509
|
yi,
|
|
4511
4510
|
bi
|
|
4512
|
-
] :
|
|
4513
|
-
},
|
|
4511
|
+
] : ri == null ? void 0 : ri.bBufferScroll
|
|
4512
|
+
}, oi.restore(), ai.restore();
|
|
4514
4513
|
}
|
|
4515
4514
|
var import_clamp$3 = __toESM(require_clamp(), 1), hoverTime = 80;
|
|
4516
4515
|
function easeOutCubic(e) {
|
|
@@ -4608,13 +4607,13 @@ let __tla = (async () => {
|
|
|
4608
4607
|
var _a;
|
|
4609
4608
|
return e.kind === GridCellKind.Custom ? e.copyData : ((_a = t == null ? void 0 : t(e)) == null ? void 0 : _a.getAccessibilityString(e)) ?? "";
|
|
4610
4609
|
}, data_grid_default = import_react.memo(import_react.forwardRef((e, t) => {
|
|
4611
|
-
let { width: n, height: r, accessibilityHeight: i, columns: a, cellXOffset: o, cellYOffset: s, headerHeight: c, fillHandle: l = false, groupHeaderHeight: u, rowHeight: f, rows: m, getCellContent: h, getRowThemeOverride: g, onHeaderMenuClick: y, onHeaderIndicatorClick: x, enableGroups: S, isFilling: C, onCanvasFocused: E, onCanvasBlur: D, isFocused: O, selection: k, freezeColumns: A, onContextMenu: j, freezeTrailingRows: M, fixedShadowX: N = true, fixedShadowY: P = true, drawFocusRing: F, onMouseDown: I, onMouseUp: L, onMouseMoveRaw: Pr, onMouseMove: B, onItemHovered: Fr, dragAndDropState:
|
|
4610
|
+
let { width: n, height: r, accessibilityHeight: i, columns: a, cellXOffset: o, cellYOffset: s, headerHeight: c, fillHandle: l = false, groupHeaderHeight: u, rowHeight: f, rows: m, getCellContent: h, getRowThemeOverride: g, onHeaderMenuClick: y, onHeaderIndicatorClick: x, enableGroups: S, isFilling: C, onCanvasFocused: E, onCanvasBlur: D, isFocused: O, selection: k, freezeColumns: A, onContextMenu: j, freezeTrailingRows: M, fixedShadowX: N = true, fixedShadowY: P = true, drawFocusRing: F, onMouseDown: I, onMouseUp: L, onMouseMoveRaw: Pr, onMouseMove: B, onItemHovered: Fr, dragAndDropState: Ir, firstColAccessible: V, onKeyDown: Lr, onKeyUp: H, highlightRegions: Rr, canvasRef: U, onDragStart: W, onDragEnd: zr, eventTargetRef: G, isResizing: K, resizeColumn: Vr, isDragging: Hr, isDraggable: Ur = false, allowResize: Wr, disabledRows: Gr, hasAppendRow: Kr, getGroupDetails: qr, theme: q, prelightCells: Jr, headerIcons: Yr, verticalBorder: Xr, drawCell: J, drawHeader: Zr, onCellFocused: Y, onDragOverCell: Qr, onDrop: $r, onDragLeave: ei, imageWindowLoader: ni, smoothScrollX: si = false, smoothScrollY: ci = false, experimental: li, getCellRenderer: X, resizeIndicator: ui = "full" } = e, di = e.translateX ?? 0, fi = e.translateY ?? 0, pi = Math.max(A, Math.min(a.length - 1, o)), mi = import_react.useRef(null), hi = import_react.useRef((li == null ? void 0 : li.eventTarget) ?? window), gi = hi.current, _i = ni, vi = import_react.useRef(), [bi, xi] = import_react.useState(false), Si = import_react.useRef([]), Ci = import_react.useRef(), [wi, Ti] = import_react.useState(), [Ei, Di] = import_react.useState(), Oi = import_react.useRef(null), [ki, Ai] = import_react.useState(), [ji, Mi] = import_react.useState(false), Ni = import_react.useRef(ji);
|
|
4612
4611
|
Ni.current = ji;
|
|
4613
|
-
let Pi = import_react.useMemo(() => new SpriteManager(
|
|
4612
|
+
let Pi = import_react.useMemo(() => new SpriteManager(Yr, () => {
|
|
4614
4613
|
Zi.current = void 0, na.current();
|
|
4615
4614
|
}), [
|
|
4616
|
-
|
|
4617
|
-
]), Fi = S ? u + c : c, Ii = import_react.useRef(-1), Li = ((
|
|
4615
|
+
Yr
|
|
4616
|
+
]), Fi = S ? u + c : c, Ii = import_react.useRef(-1), Li = ((li == null ? void 0 : li.enableFirefoxRescaling) ?? false) && browserIsFirefox.value, Ri = ((li == null ? void 0 : li.enableSafariRescaling) ?? false) && browserIsSafari.value;
|
|
4618
4617
|
import_react.useLayoutEffect(() => {
|
|
4619
4618
|
window.devicePixelRatio === 1 || !Li && !Ri || (Ii.current !== -1 && xi(true), window.clearTimeout(Ii.current), Ii.current = window.setTimeout(() => {
|
|
4620
4619
|
xi(false), Ii.current = -1;
|
|
@@ -4627,7 +4626,7 @@ let __tla = (async () => {
|
|
|
4627
4626
|
Li,
|
|
4628
4627
|
Ri
|
|
4629
4628
|
]);
|
|
4630
|
-
let zi = useMappedColumns(a, A), Bi = N ? getStickyWidth(zi,
|
|
4629
|
+
let zi = useMappedColumns(a, A), Bi = N ? getStickyWidth(zi, Ir) : 0, Vi = import_react.useCallback((e2, t2, i2) => {
|
|
4631
4630
|
let a2 = e2.getBoundingClientRect();
|
|
4632
4631
|
if (t2 >= zi.length || i2 >= m) return;
|
|
4633
4632
|
let o2 = a2.width / n, c2 = computeBounds(t2, i2, n, r, u, Fi, pi, s, di, fi, m, A, M, zi, f);
|
|
@@ -4795,7 +4794,7 @@ let __tla = (async () => {
|
|
|
4795
4794
|
Ki,
|
|
4796
4795
|
qi
|
|
4797
4796
|
]);
|
|
4798
|
-
let Ji = import_react.useMemo(() => new RenderStateProvider(), []), Yi = Li && bi ? 1 : Ri && bi ? 2 : 5, Xi = (
|
|
4797
|
+
let Ji = import_react.useMemo(() => new RenderStateProvider(), []), Yi = Li && bi ? 1 : Ri && bi ? 2 : 5, Xi = (li == null ? void 0 : li.disableMinimumCellWidth) === true ? 1 : 10, Zi = import_react.useRef(), Qi = import_react.useRef(null), $i = import_react.useRef(null), ea = import_react.useCallback(() => {
|
|
4799
4798
|
var _a2;
|
|
4800
4799
|
let e2 = mi.current, t2 = Oi.current;
|
|
4801
4800
|
if (e2 === null || t2 === null || (Qi.current === null && (Qi.current = e2.getContext("2d", {
|
|
@@ -4819,33 +4818,33 @@ let __tla = (async () => {
|
|
|
4819
4818
|
mappedColumns: zi,
|
|
4820
4819
|
enableGroups: S,
|
|
4821
4820
|
freezeColumns: A,
|
|
4822
|
-
dragAndDropState:
|
|
4823
|
-
theme:
|
|
4821
|
+
dragAndDropState: Ir,
|
|
4822
|
+
theme: q,
|
|
4824
4823
|
headerHeight: c,
|
|
4825
4824
|
groupHeaderHeight: u,
|
|
4826
|
-
disabledRows:
|
|
4825
|
+
disabledRows: Gr ?? CompactSelection.empty(),
|
|
4827
4826
|
rowHeight: f,
|
|
4828
|
-
verticalBorder:
|
|
4829
|
-
isResizing:
|
|
4830
|
-
resizeCol:
|
|
4827
|
+
verticalBorder: Xr,
|
|
4828
|
+
isResizing: K,
|
|
4829
|
+
resizeCol: Vr,
|
|
4831
4830
|
isFocused: O,
|
|
4832
4831
|
selection: k,
|
|
4833
4832
|
fillHandle: l,
|
|
4834
|
-
drawCellCallback:
|
|
4835
|
-
hasAppendRow:
|
|
4833
|
+
drawCellCallback: J,
|
|
4834
|
+
hasAppendRow: Kr,
|
|
4836
4835
|
overrideCursor: a2,
|
|
4837
4836
|
maxScaleFactor: Yi,
|
|
4838
4837
|
freezeTrailingRows: M,
|
|
4839
4838
|
rows: m,
|
|
4840
4839
|
drawFocus: F,
|
|
4841
4840
|
getCellContent: h,
|
|
4842
|
-
getGroupDetails:
|
|
4841
|
+
getGroupDetails: qr ?? ((e3) => ({
|
|
4843
4842
|
name: e3
|
|
4844
4843
|
})),
|
|
4845
4844
|
getRowThemeOverride: g,
|
|
4846
|
-
drawHeaderCallback:
|
|
4847
|
-
prelightCells:
|
|
4848
|
-
highlightRegions:
|
|
4845
|
+
drawHeaderCallback: Zr,
|
|
4846
|
+
prelightCells: Jr,
|
|
4847
|
+
highlightRegions: Rr,
|
|
4849
4848
|
imageLoader: _i,
|
|
4850
4849
|
lastBlitData: Ci,
|
|
4851
4850
|
damage: vi.current,
|
|
@@ -4853,12 +4852,12 @@ let __tla = (async () => {
|
|
|
4853
4852
|
hoverInfo: Gi.current,
|
|
4854
4853
|
spriteManager: Pi,
|
|
4855
4854
|
scrolling: bi,
|
|
4856
|
-
hyperWrapping: (
|
|
4855
|
+
hyperWrapping: (li == null ? void 0 : li.hyperWrapping) ?? false,
|
|
4857
4856
|
touchMode: ji,
|
|
4858
4857
|
enqueue: Wi.current,
|
|
4859
4858
|
renderStateProvider: Ji,
|
|
4860
|
-
renderStrategy: (
|
|
4861
|
-
getCellRenderer:
|
|
4859
|
+
renderStrategy: (li == null ? void 0 : li.renderStrategy) ?? (browserIsSafari.value ? "double-buffer" : "single-buffer"),
|
|
4860
|
+
getCellRenderer: X,
|
|
4862
4861
|
minimumCellWidth: Xi,
|
|
4863
4862
|
resizeIndicator: ui
|
|
4864
4863
|
};
|
|
@@ -4875,16 +4874,16 @@ let __tla = (async () => {
|
|
|
4875
4874
|
zi,
|
|
4876
4875
|
S,
|
|
4877
4876
|
A,
|
|
4878
|
-
|
|
4879
|
-
|
|
4877
|
+
Ir,
|
|
4878
|
+
q,
|
|
4880
4879
|
c,
|
|
4881
4880
|
u,
|
|
4882
|
-
Wr,
|
|
4883
|
-
f,
|
|
4884
|
-
Yr,
|
|
4885
|
-
q,
|
|
4886
4881
|
Gr,
|
|
4887
|
-
|
|
4882
|
+
f,
|
|
4883
|
+
Xr,
|
|
4884
|
+
K,
|
|
4885
|
+
Kr,
|
|
4886
|
+
Vr,
|
|
4888
4887
|
O,
|
|
4889
4888
|
k,
|
|
4890
4889
|
l,
|
|
@@ -4893,20 +4892,20 @@ let __tla = (async () => {
|
|
|
4893
4892
|
F,
|
|
4894
4893
|
Yi,
|
|
4895
4894
|
h,
|
|
4896
|
-
Kr,
|
|
4897
|
-
g,
|
|
4898
|
-
Y,
|
|
4899
|
-
Xr,
|
|
4900
4895
|
qr,
|
|
4901
|
-
|
|
4896
|
+
g,
|
|
4897
|
+
J,
|
|
4898
|
+
Zr,
|
|
4899
|
+
Jr,
|
|
4900
|
+
Rr,
|
|
4902
4901
|
_i,
|
|
4903
4902
|
Pi,
|
|
4904
4903
|
bi,
|
|
4905
|
-
|
|
4906
|
-
|
|
4904
|
+
li == null ? void 0 : li.hyperWrapping,
|
|
4905
|
+
li == null ? void 0 : li.renderStrategy,
|
|
4907
4906
|
ji,
|
|
4908
4907
|
Ji,
|
|
4909
|
-
|
|
4908
|
+
X,
|
|
4910
4909
|
Xi,
|
|
4911
4910
|
ui
|
|
4912
4911
|
]), na = import_react.useRef(ea);
|
|
@@ -4938,29 +4937,29 @@ let __tla = (async () => {
|
|
|
4938
4937
|
], true);
|
|
4939
4938
|
fa = e2.kind === InnerGridCellKind.NewRow || e2.kind === InnerGridCellKind.Marker && e2.markerKind !== "number", pa = e2.kind === GridCellKind.Boolean && booleanCellIsEditable(e2), ma = e2.cursor;
|
|
4940
4939
|
}
|
|
4941
|
-
let ha =
|
|
4940
|
+
let ha = Hr ? "grabbing" : (Ei ?? false) || K ? "col-resize" : oa || C ? "crosshair" : ma === void 0 ? ua || fa || pa || da ? "pointer" : "default" : ma, ga = import_react.useMemo(() => ({
|
|
4942
4941
|
contain: "strict",
|
|
4943
4942
|
display: "block",
|
|
4944
4943
|
cursor: ha
|
|
4945
4944
|
}), [
|
|
4946
4945
|
ha
|
|
4947
|
-
]), _a = import_react.useRef("default"), va =
|
|
4946
|
+
]), _a = import_react.useRef("default"), va = G == null ? void 0 : G.current;
|
|
4948
4947
|
va != null && _a.current !== ga.cursor && (va.style.cursor = _a.current = ga.cursor);
|
|
4949
4948
|
let ya = import_react.useCallback((e2, t2, n2, r2) => {
|
|
4950
|
-
if (
|
|
4951
|
-
let i2 =
|
|
4949
|
+
if (qr === void 0) return;
|
|
4950
|
+
let i2 = qr(e2);
|
|
4952
4951
|
if (i2.actions !== void 0) {
|
|
4953
4952
|
let e3 = getActionBoundsForGroup(t2, i2.actions);
|
|
4954
4953
|
for (let [a2, o2] of e3.entries()) if (pointInRect(o2, n2 + t2.x, r2 + o2.y)) return i2.actions[a2];
|
|
4955
4954
|
}
|
|
4956
4955
|
}, [
|
|
4957
|
-
|
|
4956
|
+
qr
|
|
4958
4957
|
]), ba = import_react.useCallback((e2, t2, n2, r2) => {
|
|
4959
4958
|
let i2 = zi[t2];
|
|
4960
|
-
if (!
|
|
4959
|
+
if (!Hr && !K && !(Ei ?? false)) {
|
|
4961
4960
|
let a2 = Vi(e2, t2, -1);
|
|
4962
4961
|
assert(a2 !== void 0);
|
|
4963
|
-
let o2 = computeHeaderLayout(void 0, i2, a2.x, a2.y, a2.width, a2.height,
|
|
4962
|
+
let o2 = computeHeaderLayout(void 0, i2, a2.x, a2.y, a2.width, a2.height, q, direction(i2.title) === "rtl");
|
|
4964
4963
|
if (i2.hasMenu === true && o2.menuBounds !== void 0 && pointInRect(o2.menuBounds, n2, r2)) return {
|
|
4965
4964
|
area: "menu",
|
|
4966
4965
|
bounds: o2.menuBounds
|
|
@@ -4974,11 +4973,11 @@ let __tla = (async () => {
|
|
|
4974
4973
|
zi,
|
|
4975
4974
|
Vi,
|
|
4976
4975
|
Ei,
|
|
4977
|
-
|
|
4978
|
-
|
|
4979
|
-
|
|
4976
|
+
Hr,
|
|
4977
|
+
K,
|
|
4978
|
+
q
|
|
4980
4979
|
]), xa = import_react.useRef(0), Sa = import_react.useRef(), Ca = import_react.useRef(false), wa = import_react.useCallback((e2) => {
|
|
4981
|
-
let t2 = mi.current, n2 =
|
|
4980
|
+
let t2 = mi.current, n2 = G == null ? void 0 : G.current;
|
|
4982
4981
|
if (t2 === null || e2.target !== t2 && e2.target !== n2) return;
|
|
4983
4982
|
Ca.current = true;
|
|
4984
4983
|
let r2, i2;
|
|
@@ -4987,10 +4986,10 @@ let __tla = (async () => {
|
|
|
4987
4986
|
if (r2 > e3.right || i2 > e3.bottom) return;
|
|
4988
4987
|
}
|
|
4989
4988
|
let a2 = Hi(t2, r2, i2, e2);
|
|
4990
|
-
Sa.current = a2.location, a2.isTouch && (xa.current = Date.now()), Ni.current !== a2.isTouch && Mi(a2.isTouch), !(a2.kind === "header" && ba(t2, a2.location[0], r2, i2) !== void 0) && (a2.kind === "group-header" && ya(a2.group, a2.bounds, a2.localEventX, a2.localEventY) !== void 0 || (I == null ? void 0 : I(a2), !a2.isTouch &&
|
|
4989
|
+
Sa.current = a2.location, a2.isTouch && (xa.current = Date.now()), Ni.current !== a2.isTouch && Mi(a2.isTouch), !(a2.kind === "header" && ba(t2, a2.location[0], r2, i2) !== void 0) && (a2.kind === "group-header" && ya(a2.group, a2.bounds, a2.localEventX, a2.localEventY) !== void 0 || (I == null ? void 0 : I(a2), !a2.isTouch && Ur !== true && Ur !== a2.kind && a2.button < 3 && a2.button !== 1 && e2.preventDefault()));
|
|
4991
4990
|
}, [
|
|
4992
|
-
|
|
4993
|
-
|
|
4991
|
+
G,
|
|
4992
|
+
Ur,
|
|
4994
4993
|
Hi,
|
|
4995
4994
|
ya,
|
|
4996
4995
|
ba,
|
|
@@ -5003,7 +5002,7 @@ let __tla = (async () => {
|
|
|
5003
5002
|
Ta.current = Date.now();
|
|
5004
5003
|
let n2 = mi.current;
|
|
5005
5004
|
if (Ca.current = false, L === void 0 || n2 === null) return;
|
|
5006
|
-
let r2 =
|
|
5005
|
+
let r2 = G == null ? void 0 : G.current, i2 = e2.target !== n2 && e2.target !== r2, a2, o2, s2 = true;
|
|
5007
5006
|
if (e2 instanceof MouseEvent) {
|
|
5008
5007
|
if (a2 = e2.clientX, o2 = e2.clientY, s2 = e2.button < 3, e2.pointerType === "touch") return;
|
|
5009
5008
|
} else a2 = e2.changedTouches[0].clientX, o2 = e2.changedTouches[0].clientY;
|
|
@@ -5029,7 +5028,7 @@ let __tla = (async () => {
|
|
|
5029
5028
|
L(c2, i2);
|
|
5030
5029
|
}, [
|
|
5031
5030
|
L,
|
|
5032
|
-
|
|
5031
|
+
G,
|
|
5033
5032
|
Hi,
|
|
5034
5033
|
ba,
|
|
5035
5034
|
ya
|
|
@@ -5038,7 +5037,7 @@ let __tla = (async () => {
|
|
|
5038
5037
|
var _a2, _b;
|
|
5039
5038
|
let t2 = mi.current;
|
|
5040
5039
|
if (t2 === null) return;
|
|
5041
|
-
let n2 =
|
|
5040
|
+
let n2 = G == null ? void 0 : G.current, r2 = e2.target !== t2 && e2.target !== n2, i2, a2, o2 = true;
|
|
5042
5041
|
e2 instanceof MouseEvent ? (i2 = e2.clientX, a2 = e2.clientY, o2 = e2.button < 3) : (i2 = e2.changedTouches[0].clientX, a2 = e2.changedTouches[0].clientY);
|
|
5043
5042
|
let s2 = Hi(t2, i2, a2, e2);
|
|
5044
5043
|
Ni.current !== s2.isTouch && Mi(s2.isTouch), !r2 && e2.cancelable && o2 && e2.preventDefault();
|
|
@@ -5051,22 +5050,22 @@ let __tla = (async () => {
|
|
|
5051
5050
|
e3 !== void 0 && s2.button === 0 && e3.onClick(s2);
|
|
5052
5051
|
}
|
|
5053
5052
|
}, [
|
|
5054
|
-
|
|
5053
|
+
G,
|
|
5055
5054
|
Hi,
|
|
5056
5055
|
ba,
|
|
5057
5056
|
y,
|
|
5058
5057
|
x,
|
|
5059
5058
|
ya
|
|
5060
5059
|
]), gi, false), useEventListener("contextmenu", import_react.useCallback((e2) => {
|
|
5061
|
-
let t2 = mi.current, n2 =
|
|
5060
|
+
let t2 = mi.current, n2 = G == null ? void 0 : G.current;
|
|
5062
5061
|
t2 === null || e2.target !== t2 && e2.target !== n2 || j === void 0 || j(Hi(t2, e2.clientX, e2.clientY, e2), () => {
|
|
5063
5062
|
e2.cancelable && e2.preventDefault();
|
|
5064
5063
|
});
|
|
5065
5064
|
}, [
|
|
5066
|
-
|
|
5065
|
+
G,
|
|
5067
5066
|
Hi,
|
|
5068
5067
|
j
|
|
5069
|
-
]), (
|
|
5068
|
+
]), (G == null ? void 0 : G.current) ?? null, false);
|
|
5070
5069
|
let Oa = import_react.useCallback((e2) => {
|
|
5071
5070
|
vi.current = new CellSet(e2.map((e3) => e3.item)), Si.current = e2, na.current(), vi.current = void 0;
|
|
5072
5071
|
}, []), ka = import_react.useMemo(() => new AnimationManager(Oa), [
|
|
@@ -5078,11 +5077,11 @@ let __tla = (async () => {
|
|
|
5078
5077
|
e2.setHovered(Ui);
|
|
5079
5078
|
return;
|
|
5080
5079
|
}
|
|
5081
|
-
let t2 = h(Ui, true), n2 =
|
|
5080
|
+
let t2 = h(Ui, true), n2 = X(t2), r2 = n2 === void 0 && t2.kind === GridCellKind.Custom || (n2 == null ? void 0 : n2.needsHover) !== void 0 && (typeof n2.needsHover == "boolean" ? n2.needsHover : n2.needsHover(t2));
|
|
5082
5081
|
e2.setHovered(r2 ? Ui : void 0);
|
|
5083
5082
|
}, [
|
|
5084
5083
|
h,
|
|
5085
|
-
|
|
5084
|
+
X,
|
|
5086
5085
|
Ui
|
|
5087
5086
|
]);
|
|
5088
5087
|
let ja = import_react.useRef();
|
|
@@ -5090,7 +5089,7 @@ let __tla = (async () => {
|
|
|
5090
5089
|
var _a2;
|
|
5091
5090
|
let t2 = mi.current;
|
|
5092
5091
|
if (t2 === null) return;
|
|
5093
|
-
let n2 =
|
|
5092
|
+
let n2 = G == null ? void 0 : G.current, r2 = e2.target !== t2 && e2.target !== n2, i2 = Hi(t2, e2.clientX, e2.clientY, e2);
|
|
5094
5093
|
if (i2.kind !== "out-of-bounds" && r2 && !Ca.current && !i2.isTouch) return;
|
|
5095
5094
|
let a2 = (e3, t3) => {
|
|
5096
5095
|
Ti((n3) => n3 === e3 || (n3 == null ? void 0 : n3[0][0]) === (e3 == null ? void 0 : e3[0][0]) && (n3 == null ? void 0 : n3[0][1]) === (e3 == null ? void 0 : e3[0][1]) && ((n3 == null ? void 0 : n3[1][0]) === (e3 == null ? void 0 : e3[1][0]) && (n3 == null ? void 0 : n3[1][1]) === (e3 == null ? void 0 : e3[1][1]) || !t3) ? n3 : e3);
|
|
@@ -5106,7 +5105,7 @@ let __tla = (async () => {
|
|
|
5106
5105
|
let e3 = false, t3 = true;
|
|
5107
5106
|
if (i2.kind === "cell") {
|
|
5108
5107
|
let n4 = h(i2.location);
|
|
5109
|
-
t3 = ((_a2 =
|
|
5108
|
+
t3 = ((_a2 = X(n4)) == null ? void 0 : _a2.needsHoverPosition) ?? n4.kind === GridCellKind.Custom, e3 = t3;
|
|
5110
5109
|
} else e3 = true;
|
|
5111
5110
|
let n3 = [
|
|
5112
5111
|
i2.location,
|
|
@@ -5119,25 +5118,25 @@ let __tla = (async () => {
|
|
|
5119
5118
|
i2.location
|
|
5120
5119
|
]));
|
|
5121
5120
|
}
|
|
5122
|
-
let o2 = i2.location[0] >= (
|
|
5123
|
-
Di(i2.kind === "header" && i2.isEdge && o2 &&
|
|
5121
|
+
let o2 = i2.location[0] >= (V ? 0 : 1);
|
|
5122
|
+
Di(i2.kind === "header" && i2.isEdge && o2 && Wr === true), sa(i2.kind === "cell" && i2.isFillHandle), Pr == null ? void 0 : Pr(e2), B(i2);
|
|
5124
5123
|
}, [
|
|
5125
|
-
|
|
5124
|
+
G,
|
|
5126
5125
|
Hi,
|
|
5127
|
-
|
|
5128
|
-
|
|
5126
|
+
V,
|
|
5127
|
+
Wr,
|
|
5129
5128
|
Pr,
|
|
5130
5129
|
B,
|
|
5131
5130
|
Fr,
|
|
5132
5131
|
h,
|
|
5133
|
-
|
|
5132
|
+
X,
|
|
5134
5133
|
ia
|
|
5135
5134
|
]), gi, true);
|
|
5136
5135
|
let Ma = import_react.useCallback((e2) => {
|
|
5137
5136
|
let t2 = mi.current;
|
|
5138
5137
|
if (t2 === null) return;
|
|
5139
5138
|
let n2, r2;
|
|
5140
|
-
k.current !== void 0 && (n2 = Vi(t2, k.current.cell[0], k.current.cell[1]), r2 = k.current.cell),
|
|
5139
|
+
k.current !== void 0 && (n2 = Vi(t2, k.current.cell[0], k.current.cell[1]), r2 = k.current.cell), Lr == null ? void 0 : Lr({
|
|
5141
5140
|
bounds: n2,
|
|
5142
5141
|
stopPropagation: () => e2.stopPropagation(),
|
|
5143
5142
|
preventDefault: () => e2.preventDefault(),
|
|
@@ -5152,14 +5151,14 @@ let __tla = (async () => {
|
|
|
5152
5151
|
location: r2
|
|
5153
5152
|
});
|
|
5154
5153
|
}, [
|
|
5155
|
-
|
|
5154
|
+
Lr,
|
|
5156
5155
|
k,
|
|
5157
5156
|
Vi
|
|
5158
5157
|
]), Pa = import_react.useCallback((e2) => {
|
|
5159
5158
|
let t2 = mi.current;
|
|
5160
5159
|
if (t2 === null) return;
|
|
5161
5160
|
let n2, r2;
|
|
5162
|
-
k.current !== void 0 && (n2 = Vi(t2, k.current.cell[0], k.current.cell[1]), r2 = k.current.cell),
|
|
5161
|
+
k.current !== void 0 && (n2 = Vi(t2, k.current.cell[0], k.current.cell[1]), r2 = k.current.cell), H == null ? void 0 : H({
|
|
5163
5162
|
bounds: n2,
|
|
5164
5163
|
stopPropagation: () => e2.stopPropagation(),
|
|
5165
5164
|
preventDefault: () => e2.preventDefault(),
|
|
@@ -5174,28 +5173,28 @@ let __tla = (async () => {
|
|
|
5174
5173
|
location: r2
|
|
5175
5174
|
});
|
|
5176
5175
|
}, [
|
|
5177
|
-
|
|
5176
|
+
H,
|
|
5178
5177
|
k,
|
|
5179
5178
|
Vi
|
|
5180
5179
|
]), Fa = import_react.useCallback((e2) => {
|
|
5181
|
-
if (mi.current = e2,
|
|
5180
|
+
if (mi.current = e2, U !== void 0 && (U.current = e2), li == null ? void 0 : li.eventTarget) hi.current = li.eventTarget;
|
|
5182
5181
|
else if (e2 === null) hi.current = window;
|
|
5183
5182
|
else {
|
|
5184
5183
|
let t2 = e2.getRootNode();
|
|
5185
5184
|
t2 === document && (hi.current = window), hi.current = t2;
|
|
5186
5185
|
}
|
|
5187
5186
|
}, [
|
|
5188
|
-
|
|
5189
|
-
|
|
5187
|
+
U,
|
|
5188
|
+
li == null ? void 0 : li.eventTarget
|
|
5190
5189
|
]);
|
|
5191
5190
|
useEventListener("dragstart", import_react.useCallback((e2) => {
|
|
5192
5191
|
let t2 = mi.current;
|
|
5193
|
-
if (t2 === null ||
|
|
5192
|
+
if (t2 === null || Ur === false || K) {
|
|
5194
5193
|
e2.preventDefault();
|
|
5195
5194
|
return;
|
|
5196
5195
|
}
|
|
5197
5196
|
let n2, r2, i2 = Hi(t2, e2.clientX, e2.clientY);
|
|
5198
|
-
if (
|
|
5197
|
+
if (Ur !== true && i2.kind !== Ur) {
|
|
5199
5198
|
e2.preventDefault();
|
|
5200
5199
|
return;
|
|
5201
5200
|
}
|
|
@@ -5204,7 +5203,7 @@ let __tla = (async () => {
|
|
|
5204
5203
|
}, o2, s2, c2, l2 = (e3, t3, n3) => {
|
|
5205
5204
|
o2 = e3, s2 = t3, c2 = n3;
|
|
5206
5205
|
}, u2 = false;
|
|
5207
|
-
if (
|
|
5206
|
+
if (W == null ? void 0 : W({
|
|
5208
5207
|
...i2,
|
|
5209
5208
|
setData: a2,
|
|
5210
5209
|
setDragImage: l2,
|
|
@@ -5219,105 +5218,105 @@ let __tla = (async () => {
|
|
|
5219
5218
|
let o3 = Math.ceil(window.devicePixelRatio ?? 1);
|
|
5220
5219
|
i3.width = a3.width * o3, i3.height = a3.height * o3;
|
|
5221
5220
|
let s3 = i3.getContext("2d");
|
|
5222
|
-
s3 !== null && (s3.scale(o3, o3), s3.textBaseline = "middle", r3 === -1 ? (s3.font =
|
|
5221
|
+
s3 !== null && (s3.scale(o3, o3), s3.textBaseline = "middle", r3 === -1 ? (s3.font = q.headerFontFull, s3.fillStyle = q.bgHeader, s3.fillRect(0, 0, i3.width, i3.height), drawHeader(s3, 0, 0, a3.width, a3.height, zi[n3], false, q, false, void 0, void 0, false, 0, Pi, Zr, false)) : (s3.font = q.baseFontFull, s3.fillStyle = q.bgCell, s3.fillRect(0, 0, i3.width, i3.height), drawCell(s3, h([
|
|
5223
5222
|
n3,
|
|
5224
5223
|
r3
|
|
5225
|
-
]), 0, r3, false, false, 0, 0, a3.width, a3.height, false,
|
|
5224
|
+
]), 0, r3, false, false, 0, 0, a3.width, a3.height, false, q, q.bgCell, _i, Pi, 1, void 0, false, 0, void 0, void 0, void 0, Ji, X, () => void 0))), i3.style.left = "-100%", i3.style.position = "absolute", i3.style.width = `${a3.width}px`, i3.style.height = `${a3.height}px`, document.body.append(i3), e2.dataTransfer.setDragImage(i3, a3.width / 2, a3.height / 2), window.setTimeout(() => {
|
|
5226
5225
|
i3.remove();
|
|
5227
5226
|
}, 0);
|
|
5228
5227
|
}
|
|
5229
5228
|
}
|
|
5230
5229
|
else e2.preventDefault();
|
|
5231
5230
|
}, [
|
|
5232
|
-
|
|
5233
|
-
|
|
5231
|
+
Ur,
|
|
5232
|
+
K,
|
|
5234
5233
|
Hi,
|
|
5235
|
-
|
|
5234
|
+
W,
|
|
5236
5235
|
Vi,
|
|
5237
|
-
|
|
5236
|
+
q,
|
|
5238
5237
|
zi,
|
|
5239
5238
|
Pi,
|
|
5240
|
-
|
|
5239
|
+
Zr,
|
|
5241
5240
|
h,
|
|
5242
5241
|
_i,
|
|
5243
5242
|
Ji,
|
|
5244
|
-
|
|
5245
|
-
]), (
|
|
5243
|
+
X
|
|
5244
|
+
]), (G == null ? void 0 : G.current) ?? null, false, false);
|
|
5246
5245
|
let Ia = import_react.useRef();
|
|
5247
5246
|
useEventListener("dragover", import_react.useCallback((e2) => {
|
|
5248
5247
|
let t2 = mi.current;
|
|
5249
|
-
if (
|
|
5250
|
-
let [n2, r2] = Hi(t2, e2.clientX, e2.clientY).location, i2 = n2 - (
|
|
5248
|
+
if ($r !== void 0 && e2.preventDefault(), t2 === null || Qr === void 0) return;
|
|
5249
|
+
let [n2, r2] = Hi(t2, e2.clientX, e2.clientY).location, i2 = n2 - (V ? 0 : 1), [a2, o2] = Ia.current ?? [];
|
|
5251
5250
|
(a2 !== i2 || o2 !== r2) && (Ia.current = [
|
|
5252
5251
|
i2,
|
|
5253
5252
|
r2
|
|
5254
|
-
],
|
|
5253
|
+
], Qr([
|
|
5255
5254
|
i2,
|
|
5256
5255
|
r2
|
|
5257
5256
|
], e2.dataTransfer));
|
|
5258
5257
|
}, [
|
|
5259
|
-
|
|
5258
|
+
V,
|
|
5260
5259
|
Hi,
|
|
5261
|
-
|
|
5262
|
-
|
|
5263
|
-
]), (
|
|
5264
|
-
Ia.current = void 0,
|
|
5260
|
+
Qr,
|
|
5261
|
+
$r
|
|
5262
|
+
]), (G == null ? void 0 : G.current) ?? null, false, false), useEventListener("dragend", import_react.useCallback(() => {
|
|
5263
|
+
Ia.current = void 0, zr == null ? void 0 : zr();
|
|
5265
5264
|
}, [
|
|
5266
|
-
|
|
5267
|
-
]), (
|
|
5265
|
+
zr
|
|
5266
|
+
]), (G == null ? void 0 : G.current) ?? null, false, false), useEventListener("drop", import_react.useCallback((e2) => {
|
|
5268
5267
|
let t2 = mi.current;
|
|
5269
|
-
if (t2 === null ||
|
|
5268
|
+
if (t2 === null || $r === void 0) return;
|
|
5270
5269
|
e2.preventDefault();
|
|
5271
5270
|
let [n2, r2] = Hi(t2, e2.clientX, e2.clientY).location;
|
|
5272
|
-
|
|
5273
|
-
n2 - (
|
|
5271
|
+
$r([
|
|
5272
|
+
n2 - (V ? 0 : 1),
|
|
5274
5273
|
r2
|
|
5275
5274
|
], e2.dataTransfer);
|
|
5276
5275
|
}, [
|
|
5277
|
-
|
|
5276
|
+
V,
|
|
5278
5277
|
Hi,
|
|
5279
|
-
Qr
|
|
5280
|
-
]), (K == null ? void 0 : K.current) ?? null, false, false), useEventListener("dragleave", import_react.useCallback(() => {
|
|
5281
|
-
$r == null ? void 0 : $r();
|
|
5282
|
-
}, [
|
|
5283
5278
|
$r
|
|
5284
|
-
]), (
|
|
5279
|
+
]), (G == null ? void 0 : G.current) ?? null, false, false), useEventListener("dragleave", import_react.useCallback(() => {
|
|
5280
|
+
ei == null ? void 0 : ei();
|
|
5281
|
+
}, [
|
|
5282
|
+
ei
|
|
5283
|
+
]), (G == null ? void 0 : G.current) ?? null, false, false);
|
|
5285
5284
|
let Ra = import_react.useRef(k);
|
|
5286
5285
|
Ra.current = k;
|
|
5287
5286
|
let Va = import_react.useRef(null), Ha = import_react.useCallback((e2) => {
|
|
5288
5287
|
var _a2;
|
|
5289
|
-
mi.current === null || !mi.current.contains(document.activeElement) || (e2 === null && Ra.current.current !== void 0 ? (_a2 =
|
|
5288
|
+
mi.current === null || !mi.current.contains(document.activeElement) || (e2 === null && Ra.current.current !== void 0 ? (_a2 = U == null ? void 0 : U.current) == null ? void 0 : _a2.focus({
|
|
5290
5289
|
preventScroll: true
|
|
5291
5290
|
}) : e2 !== null && e2.focus({
|
|
5292
5291
|
preventScroll: true
|
|
5293
5292
|
}), Va.current = e2);
|
|
5294
5293
|
}, [
|
|
5295
|
-
|
|
5294
|
+
U
|
|
5296
5295
|
]);
|
|
5297
5296
|
import_react.useImperativeHandle(t, () => ({
|
|
5298
5297
|
focus: () => {
|
|
5299
5298
|
var _a2;
|
|
5300
5299
|
let e2 = Va.current;
|
|
5301
|
-
e2 === null || !document.contains(e2) ? (_a2 =
|
|
5300
|
+
e2 === null || !document.contains(e2) ? (_a2 = U == null ? void 0 : U.current) == null ? void 0 : _a2.focus({
|
|
5302
5301
|
preventScroll: true
|
|
5303
5302
|
}) : e2.focus({
|
|
5304
5303
|
preventScroll: true
|
|
5305
5304
|
});
|
|
5306
5305
|
},
|
|
5307
5306
|
getBounds: (e2, t2) => {
|
|
5308
|
-
if (!(
|
|
5307
|
+
if (!(U === void 0 || U.current === null)) return Vi(U.current, e2 ?? 0, t2 ?? -1);
|
|
5309
5308
|
},
|
|
5310
5309
|
damage: aa
|
|
5311
5310
|
}), [
|
|
5312
|
-
|
|
5311
|
+
U,
|
|
5313
5312
|
aa,
|
|
5314
5313
|
Vi
|
|
5315
5314
|
]);
|
|
5316
5315
|
let Ua = import_react.useRef(), Wa = useDebouncedMemo(() => {
|
|
5317
5316
|
var _a2, _b, _c;
|
|
5318
|
-
if (n < 50 || (
|
|
5319
|
-
let e2 = getEffectiveColumns(zi, pi, n,
|
|
5320
|
-
!
|
|
5317
|
+
if (n < 50 || (li == null ? void 0 : li.disableAccessibilityTree) === true) return null;
|
|
5318
|
+
let e2 = getEffectiveColumns(zi, pi, n, Ir, di), t2 = V ? 0 : -1;
|
|
5319
|
+
!V && ((_a2 = e2[0]) == null ? void 0 : _a2.sourceIndex) === 0 && (e2 = e2.slice(1));
|
|
5321
5320
|
let [r2, a2] = ((_b = k.current) == null ? void 0 : _b.cell) ?? [], o2 = (_c = k.current) == null ? void 0 : _c.range, c2 = e2.map((e3) => e3.sourceIndex), l2 = (0, import_range$1.default)(s, Math.min(m, s + i));
|
|
5322
5321
|
return r2 !== void 0 && a2 !== void 0 && !(c2.includes(r2) && l2.includes(a2)) && Ha(null), import_react.createElement("table", {
|
|
5323
5322
|
key: "access-tree",
|
|
@@ -5336,7 +5335,7 @@ let __tla = (async () => {
|
|
|
5336
5335
|
"aria-colindex": e3.sourceIndex + 1 + t2,
|
|
5337
5336
|
tabIndex: -1,
|
|
5338
5337
|
onFocus: (t3) => {
|
|
5339
|
-
if (t3.target !== Va.current) return
|
|
5338
|
+
if (t3.target !== Va.current) return Y == null ? void 0 : Y([
|
|
5340
5339
|
e3.sourceIndex,
|
|
5341
5340
|
-1
|
|
5342
5341
|
]);
|
|
@@ -5363,8 +5362,8 @@ let __tla = (async () => {
|
|
|
5363
5362
|
id: u2,
|
|
5364
5363
|
"data-testid": u2,
|
|
5365
5364
|
onClick: () => {
|
|
5366
|
-
let e4 =
|
|
5367
|
-
if (e4 != null) return
|
|
5365
|
+
let e4 = U == null ? void 0 : U.current;
|
|
5366
|
+
if (e4 != null) return Lr == null ? void 0 : Lr({
|
|
5368
5367
|
bounds: Vi(e4, i2, n2),
|
|
5369
5368
|
cancel: () => void 0,
|
|
5370
5369
|
preventDefault: () => void 0,
|
|
@@ -5381,17 +5380,17 @@ let __tla = (async () => {
|
|
|
5381
5380
|
},
|
|
5382
5381
|
onFocusCapture: (e4) => {
|
|
5383
5382
|
var _a3, _b2;
|
|
5384
|
-
if (!(e4.target === Va.current || ((_a3 = Ua.current) == null ? void 0 : _a3[0]) === i2 && ((_b2 = Ua.current) == null ? void 0 : _b2[1]) === n2)) return Ua.current = f2,
|
|
5383
|
+
if (!(e4.target === Va.current || ((_a3 = Ua.current) == null ? void 0 : _a3[0]) === i2 && ((_b2 = Ua.current) == null ? void 0 : _b2[1]) === n2)) return Ua.current = f2, Y == null ? void 0 : Y(f2);
|
|
5385
5384
|
},
|
|
5386
5385
|
ref: c3 ? Ha : void 0,
|
|
5387
5386
|
tabIndex: -1
|
|
5388
|
-
}, getRowData(m2,
|
|
5387
|
+
}, getRowData(m2, X));
|
|
5389
5388
|
})))));
|
|
5390
5389
|
}, [
|
|
5391
5390
|
n,
|
|
5392
5391
|
zi,
|
|
5393
5392
|
pi,
|
|
5394
|
-
|
|
5393
|
+
Ir,
|
|
5395
5394
|
di,
|
|
5396
5395
|
m,
|
|
5397
5396
|
s,
|
|
@@ -5399,10 +5398,10 @@ let __tla = (async () => {
|
|
|
5399
5398
|
k,
|
|
5400
5399
|
Ha,
|
|
5401
5400
|
h,
|
|
5402
|
-
|
|
5403
|
-
|
|
5401
|
+
U,
|
|
5402
|
+
Lr,
|
|
5404
5403
|
Vi,
|
|
5405
|
-
|
|
5404
|
+
Y
|
|
5406
5405
|
], 200), Ga = A === 0 || !N ? 0 : pi > A ? 1 : (0, import_clamp$2.default)(-di / 100, 0, 1), Ka = -s * 32 + fi, qa = P ? (0, import_clamp$2.default)(-Ka / 100, 0, 1) : 0, Ja = import_react.useMemo(() => {
|
|
5407
5406
|
if (!Ga && !qa) return null;
|
|
5408
5407
|
let e2 = {
|
|
@@ -5413,7 +5412,7 @@ let __tla = (async () => {
|
|
|
5413
5412
|
height: r,
|
|
5414
5413
|
opacity: Ga,
|
|
5415
5414
|
pointerEvents: "none",
|
|
5416
|
-
transition:
|
|
5415
|
+
transition: si ? void 0 : "opacity 0.2s",
|
|
5417
5416
|
boxShadow: "inset 13px 0 10px -13px rgba(0, 0, 0, 0.2)"
|
|
5418
5417
|
}, t2 = {
|
|
5419
5418
|
position: "absolute",
|
|
@@ -5423,7 +5422,7 @@ let __tla = (async () => {
|
|
|
5423
5422
|
height: r,
|
|
5424
5423
|
opacity: qa,
|
|
5425
5424
|
pointerEvents: "none",
|
|
5426
|
-
transition:
|
|
5425
|
+
transition: ci ? void 0 : "opacity 0.2s",
|
|
5427
5426
|
boxShadow: "inset 0 13px 10px -13px rgba(0, 0, 0, 0.2)"
|
|
5428
5427
|
};
|
|
5429
5428
|
return import_react.createElement(import_react.Fragment, null, Ga > 0 && import_react.createElement("div", {
|
|
@@ -5438,10 +5437,10 @@ let __tla = (async () => {
|
|
|
5438
5437
|
qa,
|
|
5439
5438
|
Bi,
|
|
5440
5439
|
n,
|
|
5441
|
-
|
|
5440
|
+
si,
|
|
5442
5441
|
Fi,
|
|
5443
5442
|
r,
|
|
5444
|
-
|
|
5443
|
+
ci
|
|
5445
5444
|
]), Ya = import_react.useMemo(() => ({
|
|
5446
5445
|
position: "absolute",
|
|
5447
5446
|
top: 0,
|
|
@@ -5465,94 +5464,94 @@ let __tla = (async () => {
|
|
|
5465
5464
|
return (0, import_clamp$1.default)(Math.round(t - (e.growOffset ?? 0)), Math.ceil(n), Math.floor(r));
|
|
5466
5465
|
}
|
|
5467
5466
|
var data_grid_dnd_default = (e) => {
|
|
5468
|
-
let [t, n] = import_react.useState(), [r, i] = import_react.useState(), [a, o] = import_react.useState(), [s, c] = import_react.useState(), [l, u] = import_react.useState(false), [f, m] = import_react.useState(), [h, g] = import_react.useState(), [y, x] = import_react.useState(), [S, C] = import_react.useState(false), [E, D] = import_react.useState(), { onHeaderMenuClick: O, onHeaderIndicatorClick: k, getCellContent: A, onColumnMoved: j, onColumnResize: M, onColumnResizeStart: N, onColumnResizeEnd: P, gridRef: F, maxColumnWidth: I, minColumnWidth: L, onRowMoved: Pr, lockColumns: B, onColumnProposeMove: Fr, onMouseDown:
|
|
5467
|
+
let [t, n] = import_react.useState(), [r, i] = import_react.useState(), [a, o] = import_react.useState(), [s, c] = import_react.useState(), [l, u] = import_react.useState(false), [f, m] = import_react.useState(), [h, g] = import_react.useState(), [y, x] = import_react.useState(), [S, C] = import_react.useState(false), [E, D] = import_react.useState(), { onHeaderMenuClick: O, onHeaderIndicatorClick: k, getCellContent: A, onColumnMoved: j, onColumnResize: M, onColumnResizeStart: N, onColumnResizeEnd: P, gridRef: F, maxColumnWidth: I, minColumnWidth: L, onRowMoved: Pr, lockColumns: B, onColumnProposeMove: Fr, onMouseDown: Ir, onMouseUp: V, onItemHovered: Lr, onDragStart: H, canvasRef: Rr } = e, U = (M ?? P ?? N) !== void 0, { columns: W, selection: zr } = e, G = zr.columns, K = import_react.useCallback((e2) => {
|
|
5469
5468
|
let [t2, n2] = e2.location;
|
|
5470
|
-
a !== void 0 && s !== t2 && t2 >= B ? (u(true), c(t2)) : h !== void 0 && n2 !== void 0 ? (C(true), x(Math.max(0, n2))) : r === void 0 && !l && !S && (
|
|
5469
|
+
a !== void 0 && s !== t2 && t2 >= B ? (u(true), c(t2)) : h !== void 0 && n2 !== void 0 ? (C(true), x(Math.max(0, n2))) : r === void 0 && !l && !S && (Lr == null ? void 0 : Lr(e2));
|
|
5471
5470
|
}, [
|
|
5472
5471
|
a,
|
|
5473
5472
|
h,
|
|
5474
5473
|
s,
|
|
5475
|
-
|
|
5474
|
+
Lr,
|
|
5476
5475
|
B,
|
|
5477
5476
|
r,
|
|
5478
5477
|
l,
|
|
5479
5478
|
S
|
|
5480
|
-
]),
|
|
5479
|
+
]), Br = j !== void 0, Vr = import_react.useCallback((e2) => {
|
|
5481
5480
|
var _a;
|
|
5482
5481
|
if (e2.button === 0) {
|
|
5483
5482
|
let [t2, r2] = e2.location;
|
|
5484
|
-
if (e2.kind === "out-of-bounds" && e2.isEdge &&
|
|
5485
|
-
let e3 = (_a = F == null ? void 0 : F.current) == null ? void 0 : _a.getBounds(
|
|
5486
|
-
e3 !== void 0 && (n(e3.x), i(
|
|
5483
|
+
if (e2.kind === "out-of-bounds" && e2.isEdge && U) {
|
|
5484
|
+
let e3 = (_a = F == null ? void 0 : F.current) == null ? void 0 : _a.getBounds(W.length - 1, -1);
|
|
5485
|
+
e3 !== void 0 && (n(e3.x), i(W.length - 1));
|
|
5487
5486
|
} else if (e2.kind === "header" && t2 >= B) {
|
|
5488
|
-
let r3 =
|
|
5489
|
-
if (e2.isEdge &&
|
|
5487
|
+
let r3 = Rr == null ? void 0 : Rr.current;
|
|
5488
|
+
if (e2.isEdge && U && r3) {
|
|
5490
5489
|
n(e2.bounds.x), i(t2);
|
|
5491
5490
|
let a2 = r3.getBoundingClientRect().width / r3.offsetWidth, o2 = e2.bounds.width / a2;
|
|
5492
|
-
N == null ? void 0 : N(
|
|
5493
|
-
} else e2.kind === "header" &&
|
|
5491
|
+
N == null ? void 0 : N(W[t2], o2, t2, o2 + (W[t2].growOffset ?? 0));
|
|
5492
|
+
} else e2.kind === "header" && Br && (m(e2.bounds.x), o(t2));
|
|
5494
5493
|
} else e2.kind === "cell" && B > 0 && t2 === 0 && r2 !== void 0 && Pr !== void 0 && (D(e2.bounds.y), g(r2));
|
|
5495
5494
|
}
|
|
5496
|
-
|
|
5495
|
+
Ir == null ? void 0 : Ir(e2);
|
|
5497
5496
|
}, [
|
|
5498
|
-
|
|
5499
|
-
|
|
5497
|
+
Ir,
|
|
5498
|
+
U,
|
|
5500
5499
|
B,
|
|
5501
5500
|
Pr,
|
|
5502
5501
|
F,
|
|
5503
|
-
|
|
5504
|
-
|
|
5502
|
+
W,
|
|
5503
|
+
Br,
|
|
5505
5504
|
N,
|
|
5506
|
-
|
|
5507
|
-
]),
|
|
5505
|
+
Rr
|
|
5506
|
+
]), Hr = import_react.useCallback((e2, t2) => {
|
|
5508
5507
|
l || S || (O == null ? void 0 : O(e2, t2));
|
|
5509
5508
|
}, [
|
|
5510
5509
|
l,
|
|
5511
5510
|
S,
|
|
5512
5511
|
O
|
|
5513
|
-
]),
|
|
5512
|
+
]), Ur = import_react.useCallback((e2, t2) => {
|
|
5514
5513
|
l || S || (k == null ? void 0 : k(e2, t2));
|
|
5515
5514
|
}, [
|
|
5516
5515
|
l,
|
|
5517
5516
|
S,
|
|
5518
5517
|
k
|
|
5519
|
-
]),
|
|
5520
|
-
|
|
5521
|
-
}, []),
|
|
5518
|
+
]), Wr = import_react.useRef(-1), Gr = import_react.useCallback(() => {
|
|
5519
|
+
Wr.current = -1, g(void 0), x(void 0), D(void 0), C(false), o(void 0), c(void 0), m(void 0), u(false), i(void 0), n(void 0);
|
|
5520
|
+
}, []), Kr = import_react.useCallback((e2, t2) => {
|
|
5522
5521
|
if (e2.button === 0) {
|
|
5523
5522
|
if (r !== void 0) {
|
|
5524
|
-
if ((
|
|
5523
|
+
if ((G == null ? void 0 : G.hasIndex(r)) === true) for (let e4 of G) {
|
|
5525
5524
|
if (e4 === r) continue;
|
|
5526
|
-
let t3 =
|
|
5525
|
+
let t3 = W[e4], n2 = offsetColumnSize(t3, Wr.current, L, I);
|
|
5527
5526
|
M == null ? void 0 : M(t3, n2, e4, n2 + (t3.growOffset ?? 0));
|
|
5528
5527
|
}
|
|
5529
|
-
let e3 = offsetColumnSize(
|
|
5530
|
-
if (P == null ? void 0 : P(
|
|
5528
|
+
let e3 = offsetColumnSize(W[r], Wr.current, L, I);
|
|
5529
|
+
if (P == null ? void 0 : P(W[r], e3, r, e3 + (W[r].growOffset ?? 0)), G.hasIndex(r)) for (let e4 of G) {
|
|
5531
5530
|
if (e4 === r) continue;
|
|
5532
|
-
let t3 =
|
|
5531
|
+
let t3 = W[e4], n2 = offsetColumnSize(t3, Wr.current, L, I);
|
|
5533
5532
|
P == null ? void 0 : P(t3, n2, e4, n2 + (t3.growOffset ?? 0));
|
|
5534
5533
|
}
|
|
5535
5534
|
}
|
|
5536
|
-
|
|
5535
|
+
Gr(), a !== void 0 && s !== void 0 && (j == null ? void 0 : j(a, s)), h !== void 0 && y !== void 0 && (Pr == null ? void 0 : Pr(h, y));
|
|
5537
5536
|
}
|
|
5538
|
-
|
|
5537
|
+
V == null ? void 0 : V(e2, t2);
|
|
5539
5538
|
}, [
|
|
5540
|
-
|
|
5539
|
+
V,
|
|
5541
5540
|
r,
|
|
5542
5541
|
a,
|
|
5543
5542
|
s,
|
|
5544
5543
|
h,
|
|
5545
5544
|
y,
|
|
5546
|
-
K,
|
|
5547
|
-
P,
|
|
5548
5545
|
G,
|
|
5546
|
+
P,
|
|
5547
|
+
W,
|
|
5549
5548
|
L,
|
|
5550
5549
|
I,
|
|
5551
5550
|
M,
|
|
5552
5551
|
j,
|
|
5553
5552
|
Pr,
|
|
5554
|
-
|
|
5555
|
-
]),
|
|
5553
|
+
Gr
|
|
5554
|
+
]), qr = import_react.useMemo(() => {
|
|
5556
5555
|
if (!(a === void 0 || s === void 0) && a !== s && (Fr == null ? void 0 : Fr(a, s)) !== false) return {
|
|
5557
5556
|
src: a,
|
|
5558
5557
|
dest: s
|
|
@@ -5561,15 +5560,15 @@ let __tla = (async () => {
|
|
|
5561
5560
|
a,
|
|
5562
5561
|
s,
|
|
5563
5562
|
Fr
|
|
5564
|
-
]),
|
|
5565
|
-
let n2 =
|
|
5563
|
+
]), q = import_react.useCallback((e2) => {
|
|
5564
|
+
let n2 = Rr == null ? void 0 : Rr.current;
|
|
5566
5565
|
if (a !== void 0 && f !== void 0) Math.abs(e2.clientX - f) > 20 && u(true);
|
|
5567
5566
|
else if (h !== void 0 && E !== void 0) Math.abs(e2.clientY - E) > 20 && C(true);
|
|
5568
5567
|
else if (r !== void 0 && t !== void 0 && n2) {
|
|
5569
|
-
let i2 = n2.getBoundingClientRect().width / n2.offsetWidth, a2 = (e2.clientX - t) / i2, o2 =
|
|
5570
|
-
if (M == null ? void 0 : M(o2, s2, r, s2 + (o2.growOffset ?? 0)),
|
|
5568
|
+
let i2 = n2.getBoundingClientRect().width / n2.offsetWidth, a2 = (e2.clientX - t) / i2, o2 = W[r], s2 = offsetColumnSize(o2, a2, L, I);
|
|
5569
|
+
if (M == null ? void 0 : M(o2, s2, r, s2 + (o2.growOffset ?? 0)), Wr.current = a2, (G == null ? void 0 : G.first()) === r) for (let e3 of G) {
|
|
5571
5570
|
if (e3 === r) continue;
|
|
5572
|
-
let t2 =
|
|
5571
|
+
let t2 = W[e3], n3 = offsetColumnSize(t2, Wr.current, L, I);
|
|
5573
5572
|
M == null ? void 0 : M(t2, n3, e3, n3 + (t2.growOffset ?? 0));
|
|
5574
5573
|
}
|
|
5575
5574
|
}
|
|
@@ -5580,13 +5579,13 @@ let __tla = (async () => {
|
|
|
5580
5579
|
E,
|
|
5581
5580
|
r,
|
|
5582
5581
|
t,
|
|
5583
|
-
|
|
5582
|
+
W,
|
|
5584
5583
|
L,
|
|
5585
5584
|
I,
|
|
5586
5585
|
M,
|
|
5587
|
-
|
|
5588
|
-
|
|
5589
|
-
]),
|
|
5586
|
+
G,
|
|
5587
|
+
Rr
|
|
5588
|
+
]), Jr = import_react.useCallback((e2, t2) => {
|
|
5590
5589
|
if (h === void 0 || y === void 0) return A(e2, t2);
|
|
5591
5590
|
let [n2, r2] = e2;
|
|
5592
5591
|
return r2 === y ? r2 = h : (r2 > y && --r2, r2 >= h && (r2 += 1)), A([
|
|
@@ -5597,11 +5596,11 @@ let __tla = (async () => {
|
|
|
5597
5596
|
h,
|
|
5598
5597
|
y,
|
|
5599
5598
|
A
|
|
5600
|
-
]),
|
|
5601
|
-
|
|
5599
|
+
]), Yr = import_react.useCallback((e2) => {
|
|
5600
|
+
H == null ? void 0 : H(e2), e2.defaultPrevented() || Gr();
|
|
5602
5601
|
}, [
|
|
5603
|
-
|
|
5604
|
-
|
|
5602
|
+
Gr,
|
|
5603
|
+
H
|
|
5605
5604
|
]);
|
|
5606
5605
|
return import_react.createElement(data_grid_default, {
|
|
5607
5606
|
accessibilityHeight: e.accessibilityHeight,
|
|
@@ -5659,18 +5658,18 @@ let __tla = (async () => {
|
|
|
5659
5658
|
resizeIndicator: e.resizeIndicator,
|
|
5660
5659
|
verticalBorder: e.verticalBorder,
|
|
5661
5660
|
width: e.width,
|
|
5662
|
-
getCellContent:
|
|
5661
|
+
getCellContent: Jr,
|
|
5663
5662
|
isResizing: r !== void 0,
|
|
5664
|
-
onHeaderMenuClick:
|
|
5665
|
-
onHeaderIndicatorClick:
|
|
5663
|
+
onHeaderMenuClick: Hr,
|
|
5664
|
+
onHeaderIndicatorClick: Ur,
|
|
5666
5665
|
isDragging: l,
|
|
5667
|
-
onItemHovered:
|
|
5668
|
-
onDragStart:
|
|
5669
|
-
onMouseDown:
|
|
5670
|
-
allowResize:
|
|
5671
|
-
onMouseUp:
|
|
5672
|
-
dragAndDropState:
|
|
5673
|
-
onMouseMoveRaw:
|
|
5666
|
+
onItemHovered: K,
|
|
5667
|
+
onDragStart: Yr,
|
|
5668
|
+
onMouseDown: Vr,
|
|
5669
|
+
allowResize: U,
|
|
5670
|
+
onMouseUp: Kr,
|
|
5671
|
+
dragAndDropState: qr,
|
|
5672
|
+
onMouseMoveRaw: q,
|
|
5674
5673
|
ref: F
|
|
5675
5674
|
});
|
|
5676
5675
|
};
|
|
@@ -5820,31 +5819,31 @@ let __tla = (async () => {
|
|
|
5820
5819
|
O.current = e2, g !== void 0 && (g.current = e2);
|
|
5821
5820
|
}, [
|
|
5822
5821
|
g
|
|
5823
|
-
]),
|
|
5822
|
+
]), Ir = 0, V = 0;
|
|
5824
5823
|
for (x.push(import_react.createElement("div", {
|
|
5825
|
-
key:
|
|
5824
|
+
key: Ir++,
|
|
5826
5825
|
style: {
|
|
5827
5826
|
width: i,
|
|
5828
5827
|
height: 0
|
|
5829
5828
|
}
|
|
5830
|
-
}));
|
|
5831
|
-
let e2 = Math.min(5e6, r -
|
|
5829
|
+
})); V < r; ) {
|
|
5830
|
+
let e2 = Math.min(5e6, r - V);
|
|
5832
5831
|
x.push(import_react.createElement("div", {
|
|
5833
|
-
key:
|
|
5832
|
+
key: Ir++,
|
|
5834
5833
|
style: {
|
|
5835
5834
|
width: 0,
|
|
5836
5835
|
height: e2
|
|
5837
5836
|
}
|
|
5838
|
-
})),
|
|
5839
|
-
}
|
|
5840
|
-
let { ref:
|
|
5841
|
-
return typeof window < "u" && (((_a = Pr.current) == null ? void 0 : _a.height) !==
|
|
5842
|
-
width:
|
|
5843
|
-
height:
|
|
5844
|
-
}), (
|
|
5845
|
-
ref:
|
|
5837
|
+
})), V += e2;
|
|
5838
|
+
}
|
|
5839
|
+
let { ref: Lr, width: H, height: Rr } = useResizeDetector(y);
|
|
5840
|
+
return typeof window < "u" && (((_a = Pr.current) == null ? void 0 : _a.height) !== Rr || ((_b = Pr.current) == null ? void 0 : _b.width) !== H) && (window.setTimeout(() => L.current(), 0), Pr.current = {
|
|
5841
|
+
width: H,
|
|
5842
|
+
height: Rr
|
|
5843
|
+
}), (H ?? 0) === 0 || (Rr ?? 0) === 0 ? import_react.createElement("div", {
|
|
5844
|
+
ref: Lr
|
|
5846
5845
|
}) : import_react.createElement("div", {
|
|
5847
|
-
ref:
|
|
5846
|
+
ref: Lr
|
|
5848
5847
|
}, import_react.createElement(ScrollRegionStyle, {
|
|
5849
5848
|
isSafari: browserIsSafari.value
|
|
5850
5849
|
}, import_react.createElement("div", {
|
|
@@ -5867,7 +5866,7 @@ let __tla = (async () => {
|
|
|
5867
5866
|
}), import_react.createElement("div", {
|
|
5868
5867
|
ref: j,
|
|
5869
5868
|
style: {
|
|
5870
|
-
height:
|
|
5869
|
+
height: Rr,
|
|
5871
5870
|
maxHeight: n - Math.ceil(k % 1),
|
|
5872
5871
|
position: "sticky",
|
|
5873
5872
|
top: 0,
|
|
@@ -5885,7 +5884,7 @@ let __tla = (async () => {
|
|
|
5885
5884
|
if (typeof r == "number") B += n * r;
|
|
5886
5885
|
else for (let e2 = 0; e2 < n; e2++) B += r(e2);
|
|
5887
5886
|
C !== void 0 && (B += C);
|
|
5888
|
-
let Fr = import_react.useRef(),
|
|
5887
|
+
let Fr = import_react.useRef(), Ir = import_react.useCallback(() => {
|
|
5889
5888
|
var _a, _b;
|
|
5890
5889
|
if (Fr.current === void 0) return;
|
|
5891
5890
|
let e2 = {
|
|
@@ -5936,15 +5935,15 @@ let __tla = (async () => {
|
|
|
5936
5935
|
s,
|
|
5937
5936
|
D,
|
|
5938
5937
|
O
|
|
5939
|
-
]),
|
|
5940
|
-
Fr.current = e2,
|
|
5938
|
+
]), V = import_react.useCallback((e2) => {
|
|
5939
|
+
Fr.current = e2, Ir();
|
|
5941
5940
|
}, [
|
|
5942
|
-
|
|
5941
|
+
Ir
|
|
5943
5942
|
]);
|
|
5944
5943
|
return import_react.useEffect(() => {
|
|
5945
|
-
|
|
5944
|
+
Ir();
|
|
5946
5945
|
}, [
|
|
5947
|
-
|
|
5946
|
+
Ir
|
|
5948
5947
|
]), import_react.createElement(InfiniteScroller, {
|
|
5949
5948
|
scrollRef: h,
|
|
5950
5949
|
className: f,
|
|
@@ -5958,7 +5957,7 @@ let __tla = (async () => {
|
|
|
5958
5957
|
paddingBottom: j,
|
|
5959
5958
|
paddingRight: A,
|
|
5960
5959
|
rightElementProps: x,
|
|
5961
|
-
update:
|
|
5960
|
+
update: V,
|
|
5962
5961
|
initialSize: E
|
|
5963
5962
|
}, import_react.createElement(data_grid_dnd_default, {
|
|
5964
5963
|
eventTargetRef: h,
|
|
@@ -6213,18 +6212,18 @@ let __tla = (async () => {
|
|
|
6213
6212
|
}, [
|
|
6214
6213
|
N
|
|
6215
6214
|
]);
|
|
6216
|
-
let [
|
|
6215
|
+
let [Ir, V] = import_react.useState(false);
|
|
6217
6216
|
import_react.useEffect(() => {
|
|
6218
|
-
if (f)
|
|
6217
|
+
if (f) V(true);
|
|
6219
6218
|
else {
|
|
6220
|
-
let e2 = setTimeout(() =>
|
|
6219
|
+
let e2 = setTimeout(() => V(false), 150);
|
|
6221
6220
|
return () => clearTimeout(e2);
|
|
6222
6221
|
}
|
|
6223
6222
|
}, [
|
|
6224
6223
|
f
|
|
6225
6224
|
]);
|
|
6226
|
-
let
|
|
6227
|
-
if (!f && !
|
|
6225
|
+
let Lr = import_react.useMemo(() => {
|
|
6226
|
+
if (!f && !Ir) return null;
|
|
6228
6227
|
let e2;
|
|
6229
6228
|
C !== void 0 && (e2 = C.results >= 1e3 ? "over 1000" : `${C.results} result${C.results === 1 ? "" : "s"}`, C.selectedIndex >= 0 && (e2 = `${C.selectedIndex + 1} of ${e2}`));
|
|
6230
6229
|
let t2 = (e3) => {
|
|
@@ -6281,7 +6280,7 @@ let __tla = (async () => {
|
|
|
6281
6280
|
})));
|
|
6282
6281
|
}, [
|
|
6283
6282
|
f,
|
|
6284
|
-
|
|
6283
|
+
Ir,
|
|
6285
6284
|
C,
|
|
6286
6285
|
r,
|
|
6287
6286
|
h,
|
|
@@ -6374,7 +6373,7 @@ let __tla = (async () => {
|
|
|
6374
6373
|
smoothScrollX: e.smoothScrollX,
|
|
6375
6374
|
smoothScrollY: e.smoothScrollY,
|
|
6376
6375
|
resizeIndicator: e.resizeIndicator
|
|
6377
|
-
}),
|
|
6376
|
+
}), Lr);
|
|
6378
6377
|
}, _exp$2 = () => (e) => Math.max(16, e.targetHeight - 10), RenameInput = styled_default("input")({
|
|
6379
6378
|
name: "RenameInput",
|
|
6380
6379
|
class: "gdg-r17m35ur",
|
|
@@ -7416,7 +7415,7 @@ let __tla = (async () => {
|
|
|
7416
7415
|
};
|
|
7417
7416
|
const DataEditor = import_react.forwardRef((e, t) => {
|
|
7418
7417
|
var _a2, _b, _c2;
|
|
7419
|
-
let [n, r] = import_react.useState(emptyGridSelection), [i, a] = import_react.useState(), o = import_react.useRef(null), s = import_react.useRef(null), [c, l] = import_react.useState(), u = import_react.useRef(), f = typeof window > "u" ? null : window, { imageEditorOverride: m, getRowThemeOverride: h, markdownDivCreateNode: g, width: y, height: x, columns: S, rows: C, getCellContent: E, onCellClicked: D, onCellActivated: O, onFillPattern: k, onFinishedEditing: A, coercePasteValue: j, drawHeader: M, drawCell: N, editorBloom: P, onHeaderClicked: F, onColumnProposeMove: I, rangeSelectionColumnSpanning: L = true, spanRangeBehavior: Pr = "default", onGroupHeaderClicked: B, onCellContextMenu: Fr, className:
|
|
7418
|
+
let [n, r] = import_react.useState(emptyGridSelection), [i, a] = import_react.useState(), o = import_react.useRef(null), s = import_react.useRef(null), [c, l] = import_react.useState(), u = import_react.useRef(), f = typeof window > "u" ? null : window, { imageEditorOverride: m, getRowThemeOverride: h, markdownDivCreateNode: g, width: y, height: x, columns: S, rows: C, getCellContent: E, onCellClicked: D, onCellActivated: O, onFillPattern: k, onFinishedEditing: A, coercePasteValue: j, drawHeader: M, drawCell: N, editorBloom: P, onHeaderClicked: F, onColumnProposeMove: I, rangeSelectionColumnSpanning: L = true, spanRangeBehavior: Pr = "default", onGroupHeaderClicked: B, onCellContextMenu: Fr, className: Ir, onHeaderContextMenu: V, getCellsForSelection: Lr, onGroupHeaderContextMenu: H, onGroupHeaderRenamed: Rr, onCellEdited: U, onCellsEdited: W, onSearchResultsChanged: zr, searchResults: G, onSearchValueChange: K, searchValue: Vr, onKeyDown: Hr, onKeyUp: Gr, keybindings: Kr, editOnType: qr = true, onRowAppended: q, onColumnMoved: Jr, validateCell: Yr, highlightRegions: Xr, rangeSelect: J = "rect", columnSelect: Zr = "multi", rowSelect: Y = "multi", rangeSelectionBlending: Qr = "exclusive", columnSelectionBlending: ai = "exclusive", rowSelectionBlending: ci = "exclusive", onDelete: li, onDragStart: X, onMouseMove: ui, onPaste: fi, copyHeaders: pi = false, freezeColumns: mi = 0, cellActivationBehavior: gi = "second-click", rowSelectionMode: _i = "auto", onHeaderMenuClick: vi, onHeaderIndicatorClick: bi, getGroupDetails: xi, rowGrouping: Ci, onSearchClose: wi, onItemHovered: Ti, onSelectionCleared: Ei, showSearch: Di, onVisibleRegionChanged: Oi, gridSelection: ki, onGridSelectionChange: Ai, minColumnWidth: ji = 50, maxColumnWidth: Mi = 500, maxColumnAutoWidth: Ni, provideEditor: Pi, trailingRowOptions: Fi, freezeTrailingRows: Ii = 0, allowedFillDirections: Li = "orthogonal", scrollOffsetX: Ri, scrollOffsetY: zi, verticalBorder: Bi, onDragOverCell: Vi, onDrop: Hi, onColumnResize: Ui, onColumnResizeEnd: Wi, onColumnResizeStart: Gi, customRenderers: qi, fillHandle: Ji, experimental: Yi, fixedShadowX: Xi, fixedShadowY: Zi, headerIcons: Qi, imageWindowLoader: $i, initialSize: ea, isDraggable: ta, onDragLeave: na, onRowMoved: ra, overscrollX: ia, overscrollY: aa, preventDiagonalScrolling: oa, rightElement: sa, rightElementProps: ca, trapFocus: la = false, smoothScrollX: ua, smoothScrollY: da, scaleToRem: fa = false, rowHeight: pa = 34, headerHeight: ma = 36, groupHeaderHeight: ha = ma, theme: ga, isOutsideClick: _a, renderers: va, resizeIndicator: ya, scrollToActiveCell: ba = true, drawFocusRing: xa = true } = e, Sa = xa === "no-editor" ? i === void 0 : xa, Ca = typeof e.rowMarkers == "string" ? void 0 : e.rowMarkers, wa = (Ca == null ? void 0 : Ca.kind) ?? e.rowMarkers ?? "none", Ta = (Ca == null ? void 0 : Ca.width) ?? e.rowMarkerWidth, Ea = (Ca == null ? void 0 : Ca.startIndex) ?? e.rowMarkerStartIndex ?? 1, Da = (Ca == null ? void 0 : Ca.theme) ?? e.rowMarkerTheme, Aa = Ca == null ? void 0 : Ca.headerTheme, Na = Ca == null ? void 0 : Ca.headerAlwaysVisible, Pa = Y !== "multi", Fa = (Ca == null ? void 0 : Ca.checkboxStyle) ?? "square", Ia = Math.max(ji, 20), La = Math.max(Mi, Ia), za = Math.max(Ni ?? La, Ia), Ba = import_react.useMemo(() => typeof window > "u" ? {
|
|
7420
7419
|
fontSize: "16px"
|
|
7421
7420
|
} : window.getComputedStyle(document.documentElement), []), { rows: Z, rowNumberMapper: Va, rowHeight: Ha, getRowThemeOverride: Ua } = useRowGroupingInner(Ci, C, pa, h), { rowHeight: Wa, headerHeight: Ga, groupHeaderHeight: Ka, theme: qa, overscrollX: Ja, overscrollY: Ya } = useRemAdjuster({
|
|
7422
7421
|
groupHeaderHeight: ha,
|
|
@@ -7429,7 +7428,7 @@ let __tla = (async () => {
|
|
|
7429
7428
|
rowHeight: Ha,
|
|
7430
7429
|
scaleToRem: fa,
|
|
7431
7430
|
theme: ga
|
|
7432
|
-
}), Xa = useKeybindingsWithDefaults(
|
|
7431
|
+
}), Xa = useKeybindingsWithDefaults(Kr), Za = Ta ?? (C > 1e4 ? 48 : C > 1e3 ? 44 : C > 100 ? 36 : 32), Qa = wa !== "none", Q = Qa ? 1 : 0, $a = q !== void 0, eo = (Fi == null ? void 0 : Fi.sticky) === true, [to, no] = import_react.useState(false), ro = Di ?? to, io = import_react.useCallback(() => {
|
|
7433
7432
|
wi === void 0 ? no(false) : wi();
|
|
7434
7433
|
}, [
|
|
7435
7434
|
wi
|
|
@@ -7438,16 +7437,16 @@ let __tla = (async () => {
|
|
|
7438
7437
|
Q
|
|
7439
7438
|
]) ?? n, ao = import_react.useRef();
|
|
7440
7439
|
ao.current === void 0 && (ao.current = new AbortController()), import_react.useEffect(() => () => ao == null ? void 0 : ao.current.abort(), []);
|
|
7441
|
-
let [oo, so] = useCellsForSelection(
|
|
7442
|
-
if (
|
|
7440
|
+
let [oo, so] = useCellsForSelection(Lr, E, Q, ao.current, Z), co = import_react.useCallback((e2, t2, n2) => {
|
|
7441
|
+
if (Yr === void 0) return true;
|
|
7443
7442
|
let r2 = [
|
|
7444
7443
|
e2[0] - Q,
|
|
7445
7444
|
e2[1]
|
|
7446
7445
|
];
|
|
7447
|
-
return
|
|
7446
|
+
return Yr == null ? void 0 : Yr(r2, t2, n2);
|
|
7448
7447
|
}, [
|
|
7449
7448
|
Q,
|
|
7450
|
-
|
|
7449
|
+
Yr
|
|
7451
7450
|
]), lo = import_react.useRef(ki), uo = import_react.useCallback((e2, t2) => {
|
|
7452
7451
|
t2 && (e2 = expandSelection(e2, oo, Q, Pr, ao.current)), Ai === void 0 ? r(e2) : (lo.current = shiftSelection(e2, -Q), Ai(lo.current));
|
|
7453
7452
|
}, [
|
|
@@ -7486,15 +7485,15 @@ let __tla = (async () => {
|
|
|
7486
7485
|
N,
|
|
7487
7486
|
Q
|
|
7488
7487
|
])), _o = import_react.useCallback((e2) => {
|
|
7489
|
-
if (
|
|
7490
|
-
let t2 =
|
|
7488
|
+
if (li !== void 0) {
|
|
7489
|
+
let t2 = li(shiftSelection(e2, -Q));
|
|
7491
7490
|
return typeof t2 == "boolean" ? t2 : shiftSelection(t2, Q);
|
|
7492
7491
|
}
|
|
7493
7492
|
return true;
|
|
7494
7493
|
}, [
|
|
7495
|
-
|
|
7494
|
+
li,
|
|
7496
7495
|
Q
|
|
7497
|
-
]), [vo, yo, bo] = useSelectionBehavior($, uo,
|
|
7496
|
+
]), [vo, yo, bo] = useSelectionBehavior($, uo, Qr, ai, ci, J, L), xo = import_react.useMemo(() => mergeAndRealizeTheme(getDataEditorTheme(), qa), [
|
|
7498
7497
|
qa
|
|
7499
7498
|
]), [So, Co] = import_react.useState([
|
|
7500
7499
|
0,
|
|
@@ -7559,17 +7558,17 @@ let __tla = (async () => {
|
|
|
7559
7558
|
e3.location[0] - Q,
|
|
7560
7559
|
e3.location[1]
|
|
7561
7560
|
]
|
|
7562
|
-
})), n2 =
|
|
7563
|
-
if (n2 !== true) for (let e3 of t2)
|
|
7561
|
+
})), n2 = W == null ? void 0 : W(t2);
|
|
7562
|
+
if (n2 !== true) for (let e3 of t2) U == null ? void 0 : U(e3.location, e3.value);
|
|
7564
7563
|
return n2;
|
|
7565
7564
|
}, [
|
|
7565
|
+
U,
|
|
7566
7566
|
W,
|
|
7567
|
-
G,
|
|
7568
7567
|
Q
|
|
7569
7568
|
]), [Wo, Go] = import_react.useState(), Ko = $.current !== void 0 && $.current.range.width * $.current.range.height > 1 ? $.current.range : void 0, qo = Sa ? (_a2 = $.current) == null ? void 0 : _a2.cell : void 0, Jo = qo == null ? void 0 : qo[0], Yo = qo == null ? void 0 : qo[1], Xo = import_react.useMemo(() => {
|
|
7570
|
-
if ((
|
|
7569
|
+
if ((Xr === void 0 || Xr.length === 0) && (Ko ?? Jo ?? Yo ?? Wo) === void 0) return;
|
|
7571
7570
|
let e2 = [];
|
|
7572
|
-
if (
|
|
7571
|
+
if (Xr !== void 0) for (let t2 of Xr) {
|
|
7573
7572
|
let n2 = Mo.length - t2.range.x - Q;
|
|
7574
7573
|
n2 > 0 && e2.push({
|
|
7575
7574
|
color: t2.color,
|
|
@@ -7604,7 +7603,7 @@ let __tla = (async () => {
|
|
|
7604
7603
|
Ko,
|
|
7605
7604
|
Jo,
|
|
7606
7605
|
Yo,
|
|
7607
|
-
|
|
7606
|
+
Xr,
|
|
7608
7607
|
Mo.length,
|
|
7609
7608
|
xo.accentColor,
|
|
7610
7609
|
Q
|
|
@@ -7681,7 +7680,7 @@ let __tla = (async () => {
|
|
|
7681
7680
|
let t2 = (xi == null ? void 0 : xi(e2)) ?? {
|
|
7682
7681
|
name: e2
|
|
7683
7682
|
};
|
|
7684
|
-
return
|
|
7683
|
+
return Rr !== void 0 && e2 !== "" && (t2 = {
|
|
7685
7684
|
icon: t2.icon,
|
|
7686
7685
|
name: t2.name,
|
|
7687
7686
|
overrideTheme: t2.overrideTheme,
|
|
@@ -7699,7 +7698,7 @@ let __tla = (async () => {
|
|
|
7699
7698
|
}), t2;
|
|
7700
7699
|
}, [
|
|
7701
7700
|
xi,
|
|
7702
|
-
|
|
7701
|
+
Rr
|
|
7703
7702
|
]), es = import_react.useCallback((e2) => {
|
|
7704
7703
|
var _a3;
|
|
7705
7704
|
let [t2, n2] = e2.cell, r2 = Mo[t2], i2 = (r2 == null ? void 0 : r2.group) === void 0 ? void 0 : (_a3 = $o(r2.group)) == null ? void 0 : _a3.overrideTheme, o2 = r2 == null ? void 0 : r2.themeOverride, s2 = Ua == null ? void 0 : Ua(n2);
|
|
@@ -7865,7 +7864,7 @@ let __tla = (async () => {
|
|
|
7865
7864
|
let ss = import_react.useCallback(async (e2, t2 = true) => {
|
|
7866
7865
|
var _a3, _b2;
|
|
7867
7866
|
if (((_b2 = (_a3 = Mo[e2]) == null ? void 0 : _a3.trailingRowOptions) == null ? void 0 : _b2.disabled) === true) return;
|
|
7868
|
-
let n2 =
|
|
7867
|
+
let n2 = q == null ? void 0 : q(), r2, i2 = true;
|
|
7869
7868
|
n2 !== void 0 && (r2 = await n2, r2 === "top" && (i2 = false), typeof r2 == "number" && (i2 = false));
|
|
7870
7869
|
let a2 = 0, o2 = () => {
|
|
7871
7870
|
if (os.current <= Z) {
|
|
@@ -7896,7 +7895,7 @@ let __tla = (async () => {
|
|
|
7896
7895
|
o2();
|
|
7897
7896
|
}, [
|
|
7898
7897
|
Mo,
|
|
7899
|
-
|
|
7898
|
+
q,
|
|
7900
7899
|
Q,
|
|
7901
7900
|
Z,
|
|
7902
7901
|
vo
|
|
@@ -7923,13 +7922,13 @@ let __tla = (async () => {
|
|
|
7923
7922
|
xo
|
|
7924
7923
|
]), { mapper: fs } = useRowGrouping(Ci, C), ps = Ci == null ? void 0 : Ci.navigationBehavior, ms = import_react.useCallback((e2) => {
|
|
7925
7924
|
var _a3, _b2, _c3;
|
|
7926
|
-
let t2 = browserIsOSX.value ? e2.metaKey : e2.ctrlKey, n2 = t2 &&
|
|
7925
|
+
let t2 = browserIsOSX.value ? e2.metaKey : e2.ctrlKey, n2 = t2 && Y === "multi", r2 = t2 && Zr === "multi", [i2, o2] = e2.location, s2 = $.columns, c2 = $.rows, [l2, u2] = ((_a3 = $.current) == null ? void 0 : _a3.cell) ?? [];
|
|
7927
7926
|
if (e2.kind === "cell") {
|
|
7928
7927
|
if (us.current = void 0, gs.current = [
|
|
7929
7928
|
i2,
|
|
7930
7929
|
o2
|
|
7931
7930
|
], i2 === 0 && Qa) {
|
|
7932
|
-
if ($a === true && o2 === Z || wa === "number" ||
|
|
7931
|
+
if ($a === true && o2 === Z || wa === "number" || Y === "none") return;
|
|
7933
7932
|
let r3 = Qo(e2.location);
|
|
7934
7933
|
if (r3.kind !== InnerGridCellKind.Marker) return;
|
|
7935
7934
|
if (ra !== void 0) {
|
|
@@ -7948,13 +7947,13 @@ let __tla = (async () => {
|
|
|
7948
7947
|
}
|
|
7949
7948
|
a(void 0), Vo();
|
|
7950
7949
|
let i3 = c2.hasIndex(o2), s3 = ls.current;
|
|
7951
|
-
if (
|
|
7950
|
+
if (Y === "multi" && (e2.shiftKey || e2.isLongTouch === true) && s3 !== void 0 && c2.hasIndex(s3)) {
|
|
7952
7951
|
let e3 = [
|
|
7953
7952
|
Math.min(s3, o2),
|
|
7954
7953
|
Math.max(s3, o2) + 1
|
|
7955
7954
|
];
|
|
7956
7955
|
n2 || _i === "multi" ? yo(void 0, e3, true) : yo(CompactSelection.fromSingleSelection(e3), void 0, n2);
|
|
7957
|
-
} else
|
|
7956
|
+
} else Y === "multi" && (n2 || e2.isTouch || _i === "multi") ? i3 ? yo(c2.remove(o2), void 0, true) : (yo(void 0, o2, true), ls.current = o2) : i3 && c2.length === 1 ? yo(CompactSelection.empty(), void 0, t2) : (yo(CompactSelection.fromSingleSelection(o2), void 0, t2), ls.current = o2);
|
|
7958
7957
|
} else if (i2 >= Q && $a && o2 === Z) ss(cs(i2) ?? i2);
|
|
7959
7958
|
else if (l2 !== i2 || u2 !== o2) {
|
|
7960
7959
|
let n3 = Qo(e2.location), r3 = To(n3);
|
|
@@ -8000,19 +7999,19 @@ let __tla = (async () => {
|
|
|
8000
7999
|
} else if (e2.kind === "header") if (gs.current = [
|
|
8001
8000
|
i2,
|
|
8002
8001
|
o2
|
|
8003
|
-
], a(void 0), Qa && i2 === 0) ls.current = void 0, us.current = void 0,
|
|
8002
|
+
], a(void 0), Qa && i2 === 0) ls.current = void 0, us.current = void 0, Y === "multi" && (c2.length === Z ? yo(CompactSelection.empty(), void 0, t2) : yo(CompactSelection.fromSingleSelection([
|
|
8004
8003
|
0,
|
|
8005
8004
|
Z
|
|
8006
8005
|
]), void 0, t2), Vo());
|
|
8007
8006
|
else {
|
|
8008
8007
|
let n3 = us.current;
|
|
8009
|
-
if (
|
|
8008
|
+
if (Zr === "multi" && (e2.shiftKey || e2.isLongTouch === true) && n3 !== void 0 && s2.hasIndex(n3)) {
|
|
8010
8009
|
let e3 = [
|
|
8011
8010
|
Math.min(n3, i2),
|
|
8012
8011
|
Math.max(n3, i2) + 1
|
|
8013
8012
|
];
|
|
8014
8013
|
r2 ? bo(void 0, e3, t2) : bo(CompactSelection.fromSingleSelection(e3), void 0, t2);
|
|
8015
|
-
} else r2 ? (s2.hasIndex(i2) ? bo(s2.remove(i2), void 0, t2) : bo(void 0, i2, t2), us.current = i2) :
|
|
8014
|
+
} else r2 ? (s2.hasIndex(i2) ? bo(s2.remove(i2), void 0, t2) : bo(void 0, i2, t2), us.current = i2) : Zr !== "none" && (bo(CompactSelection.fromSingleSelection(i2), void 0, t2), us.current = i2);
|
|
8016
8015
|
ls.current = void 0, Vo();
|
|
8017
8016
|
}
|
|
8018
8017
|
else e2.kind === "group-header" ? gs.current = [
|
|
@@ -8020,8 +8019,8 @@ let __tla = (async () => {
|
|
|
8020
8019
|
o2
|
|
8021
8020
|
] : e2.kind === "out-of-bounds" && !e2.isMaybeScrollbar && (uo(emptyGridSelection, false), a(void 0), Vo(), Ei == null ? void 0 : Ei(), ls.current = void 0, us.current = void 0);
|
|
8022
8021
|
}, [
|
|
8023
|
-
|
|
8024
|
-
|
|
8022
|
+
Y,
|
|
8023
|
+
Zr,
|
|
8025
8024
|
$,
|
|
8026
8025
|
Qa,
|
|
8027
8026
|
Q,
|
|
@@ -8064,7 +8063,7 @@ let __tla = (async () => {
|
|
|
8064
8063
|
$,
|
|
8065
8064
|
ms
|
|
8066
8065
|
]), [bs, xs] = import_react.useState(), Ss = import_react.useCallback((e2) => {
|
|
8067
|
-
if (e2.kind !== "group-header" ||
|
|
8066
|
+
if (e2.kind !== "group-header" || Zr !== "multi") return;
|
|
8068
8067
|
let t2 = browserIsOSX.value ? e2.metaKey : e2.ctrlKey, [n2] = e2.location, r2 = $.columns;
|
|
8069
8068
|
if (n2 < Q) return;
|
|
8070
8069
|
let i2 = Mo[n2], a2 = n2, o2 = n2;
|
|
@@ -8086,7 +8085,7 @@ let __tla = (async () => {
|
|
|
8086
8085
|
o2 + 1
|
|
8087
8086
|
]), void 0, t2);
|
|
8088
8087
|
}, [
|
|
8089
|
-
|
|
8088
|
+
Zr,
|
|
8090
8089
|
Vo,
|
|
8091
8090
|
$.columns,
|
|
8092
8091
|
Mo,
|
|
@@ -8278,14 +8277,14 @@ let __tla = (async () => {
|
|
|
8278
8277
|
});
|
|
8279
8278
|
return;
|
|
8280
8279
|
} else if (e2.kind === "header" && $.columns.hasIndex(r2)) {
|
|
8281
|
-
|
|
8280
|
+
V == null ? void 0 : V(f2, {
|
|
8282
8281
|
...e2,
|
|
8283
8282
|
preventDefault: s2
|
|
8284
8283
|
});
|
|
8285
8284
|
return;
|
|
8286
8285
|
} else if (e2.kind === "group-header") {
|
|
8287
8286
|
if (f2 < 0) return;
|
|
8288
|
-
|
|
8287
|
+
H == null ? void 0 : H(f2, {
|
|
8289
8288
|
...e2,
|
|
8290
8289
|
preventDefault: s2
|
|
8291
8290
|
});
|
|
@@ -8332,8 +8331,8 @@ let __tla = (async () => {
|
|
|
8332
8331
|
O,
|
|
8333
8332
|
ts,
|
|
8334
8333
|
Fr,
|
|
8334
|
+
V,
|
|
8335
8335
|
H,
|
|
8336
|
-
U,
|
|
8337
8336
|
ms,
|
|
8338
8337
|
B,
|
|
8339
8338
|
F,
|
|
@@ -8419,11 +8418,11 @@ let __tla = (async () => {
|
|
|
8419
8418
|
Ii,
|
|
8420
8419
|
Fo,
|
|
8421
8420
|
Oi
|
|
8422
|
-
]), Is = whenDefined(
|
|
8423
|
-
|
|
8421
|
+
]), Is = whenDefined(Jr, import_react.useCallback((e2, t2) => {
|
|
8422
|
+
Jr == null ? void 0 : Jr(e2 - Q, t2 - Q), Zr !== "none" && bo(CompactSelection.fromSingleSelection(t2), void 0, true);
|
|
8424
8423
|
}, [
|
|
8425
|
-
|
|
8426
|
-
|
|
8424
|
+
Zr,
|
|
8425
|
+
Jr,
|
|
8427
8426
|
Q,
|
|
8428
8427
|
bo
|
|
8429
8428
|
])), Ls = import_react.useRef(false), Rs = import_react.useCallback((e2) => {
|
|
@@ -8431,7 +8430,7 @@ let __tla = (async () => {
|
|
|
8431
8430
|
e2.preventDefault();
|
|
8432
8431
|
return;
|
|
8433
8432
|
}
|
|
8434
|
-
|
|
8433
|
+
X == null ? void 0 : X({
|
|
8435
8434
|
...e2,
|
|
8436
8435
|
location: [
|
|
8437
8436
|
e2.location[0] - Q,
|
|
@@ -8439,7 +8438,7 @@ let __tla = (async () => {
|
|
|
8439
8438
|
]
|
|
8440
8439
|
}), e2.defaultPrevented() || (Ls.current = true), l(void 0);
|
|
8441
8440
|
}, [
|
|
8442
|
-
|
|
8441
|
+
X,
|
|
8443
8442
|
Q
|
|
8444
8443
|
]), zs = import_react.useCallback(() => {
|
|
8445
8444
|
Ls.current = false;
|
|
@@ -8461,14 +8460,14 @@ let __tla = (async () => {
|
|
|
8461
8460
|
]), Hs = import_react.useRef(), Us = import_react.useCallback((e2) => {
|
|
8462
8461
|
var _a3, _b2, _c3;
|
|
8463
8462
|
if (!mouseEventArgsAreEqual(e2, Hs.current) && (Hs.current = e2, !(((_a3 = vs == null ? void 0 : vs.current) == null ? void 0 : _a3.button) !== void 0 && vs.current.button >= 1))) {
|
|
8464
|
-
if (e2.buttons !== 0 && c !== void 0 && ((_b2 = vs.current) == null ? void 0 : _b2.location[0]) === 0 && e2.location[0] === 0 && Q === 1 &&
|
|
8463
|
+
if (e2.buttons !== 0 && c !== void 0 && ((_b2 = vs.current) == null ? void 0 : _b2.location[0]) === 0 && e2.location[0] === 0 && Q === 1 && Y === "multi" && c.previousSelection && !c.previousSelection.rows.hasIndex(vs.current.location[1]) && $.rows.hasIndex(vs.current.location[1])) {
|
|
8465
8464
|
let t2 = Math.min(vs.current.location[1], e2.location[1]), n2 = Math.max(vs.current.location[1], e2.location[1]) + 1;
|
|
8466
8465
|
yo(CompactSelection.fromSingleSelection([
|
|
8467
8466
|
t2,
|
|
8468
8467
|
n2
|
|
8469
8468
|
]), void 0, false);
|
|
8470
8469
|
}
|
|
8471
|
-
if (e2.buttons !== 0 && c !== void 0 && $.current !== void 0 && !Ls.current && !hs.current && (
|
|
8470
|
+
if (e2.buttons !== 0 && c !== void 0 && $.current !== void 0 && !Ls.current && !hs.current && (J === "rect" || J === "multi-rect")) {
|
|
8472
8471
|
let [t2, n2] = $.current.cell, [r2, i2] = e2.location;
|
|
8473
8472
|
if (i2 < 0 && (i2 = No.current.y), c.fillHandle === true && ((_c3 = c.previousSelection) == null ? void 0 : _c3.current) !== void 0) {
|
|
8474
8473
|
let e3 = c.previousSelection.current.range;
|
|
@@ -8503,9 +8502,9 @@ let __tla = (async () => {
|
|
|
8503
8502
|
}, [
|
|
8504
8503
|
c,
|
|
8505
8504
|
Q,
|
|
8506
|
-
X,
|
|
8507
|
-
$,
|
|
8508
8505
|
Y,
|
|
8506
|
+
$,
|
|
8507
|
+
J,
|
|
8509
8508
|
Ti,
|
|
8510
8509
|
yo,
|
|
8511
8510
|
$a,
|
|
@@ -8769,7 +8768,7 @@ let __tla = (async () => {
|
|
|
8769
8768
|
if (n2.didMatch) return t2(), true;
|
|
8770
8769
|
if ($.current === void 0) return false;
|
|
8771
8770
|
let [l2, u2] = $.current.cell, [, f2] = $.current.cell, m2 = false, h2 = false;
|
|
8772
|
-
if (isHotkey(c2.scrollToSelectedCell, e2, n2) ? ac.current(l2 - Q, u2) :
|
|
8771
|
+
if (isHotkey(c2.scrollToSelectedCell, e2, n2) ? ac.current(l2 - Q, u2) : Zr !== "none" && isHotkey(c2.selectColumn, e2, n2) ? i2.hasIndex(l2) ? bo(i2.remove(l2), void 0, true) : Zr === "single" ? bo(CompactSelection.fromSingleSelection(l2), void 0, true) : bo(void 0, l2, true) : Y !== "none" && isHotkey(c2.selectRow, e2, n2) ? s2.hasIndex(u2) ? yo(s2.remove(u2), void 0, true) : Y === "single" ? yo(CompactSelection.fromSingleSelection(u2), void 0, true) : yo(void 0, u2, true) : !Xs && r2 !== void 0 && isHotkey(c2.activateCell, e2, n2) ? u2 === Z && $a ? window.setTimeout(() => {
|
|
8773
8772
|
ss(cs(l2) ?? l2);
|
|
8774
8773
|
}, 0) : (O == null ? void 0 : O([
|
|
8775
8774
|
l2 - Q,
|
|
@@ -8780,7 +8779,7 @@ let __tla = (async () => {
|
|
|
8780
8779
|
])) : isHotkey(c2.selectToLastCell, e2, n2) ? (a(void 0), Ws([
|
|
8781
8780
|
2,
|
|
8782
8781
|
2
|
|
8783
|
-
])) : Xs ? (isHotkey(c2.closeOverlay, e2, n2) && a(void 0), isHotkey(c2.acceptOverlayDown, e2, n2) && (a(void 0), u2++), isHotkey(c2.acceptOverlayUp, e2, n2) && (a(void 0), u2--), isHotkey(c2.acceptOverlayLeft, e2, n2) && (a(void 0), l2--), isHotkey(c2.acceptOverlayRight, e2, n2) && (a(void 0), l2++)) : (isHotkey(c2.goDownCell, e2, n2) ? u2 += 1 : isHotkey(c2.goUpCell, e2, n2) ? --u2 : isHotkey(c2.goRightCell, e2, n2) ? l2 += 1 : isHotkey(c2.goLeftCell, e2, n2) ? --l2 : isHotkey(c2.goDownCellRetainSelection, e2, n2) ? (u2 += 1, m2 = true) : isHotkey(c2.goUpCellRetainSelection, e2, n2) ? (--u2, m2 = true) : isHotkey(c2.goRightCellRetainSelection, e2, n2) ? (l2 += 1, m2 = true) : isHotkey(c2.goLeftCellRetainSelection, e2, n2) ? (--l2, m2 = true) : isHotkey(c2.goToLastRow, e2, n2) ? u2 = Z - 1 : isHotkey(c2.goToFirstRow, e2, n2) ? u2 = -(2 ** 53 - 1) : isHotkey(c2.goToLastColumn, e2, n2) ? l2 = 2 ** 53 - 1 : isHotkey(c2.goToFirstColumn, e2, n2) ? l2 = -(2 ** 53 - 1) : (
|
|
8782
|
+
])) : Xs ? (isHotkey(c2.closeOverlay, e2, n2) && a(void 0), isHotkey(c2.acceptOverlayDown, e2, n2) && (a(void 0), u2++), isHotkey(c2.acceptOverlayUp, e2, n2) && (a(void 0), u2--), isHotkey(c2.acceptOverlayLeft, e2, n2) && (a(void 0), l2--), isHotkey(c2.acceptOverlayRight, e2, n2) && (a(void 0), l2++)) : (isHotkey(c2.goDownCell, e2, n2) ? u2 += 1 : isHotkey(c2.goUpCell, e2, n2) ? --u2 : isHotkey(c2.goRightCell, e2, n2) ? l2 += 1 : isHotkey(c2.goLeftCell, e2, n2) ? --l2 : isHotkey(c2.goDownCellRetainSelection, e2, n2) ? (u2 += 1, m2 = true) : isHotkey(c2.goUpCellRetainSelection, e2, n2) ? (--u2, m2 = true) : isHotkey(c2.goRightCellRetainSelection, e2, n2) ? (l2 += 1, m2 = true) : isHotkey(c2.goLeftCellRetainSelection, e2, n2) ? (--l2, m2 = true) : isHotkey(c2.goToLastRow, e2, n2) ? u2 = Z - 1 : isHotkey(c2.goToFirstRow, e2, n2) ? u2 = -(2 ** 53 - 1) : isHotkey(c2.goToLastColumn, e2, n2) ? l2 = 2 ** 53 - 1 : isHotkey(c2.goToFirstColumn, e2, n2) ? l2 = -(2 ** 53 - 1) : (J === "rect" || J === "multi-rect") && (isHotkey(c2.selectGrowDown, e2, n2) ? Ws([
|
|
8784
8783
|
0,
|
|
8785
8784
|
1
|
|
8786
8785
|
]) : isHotkey(c2.selectGrowUp, e2, n2) ? Ws([
|
|
@@ -8821,9 +8820,9 @@ let __tla = (async () => {
|
|
|
8821
8820
|
Xs,
|
|
8822
8821
|
$,
|
|
8823
8822
|
Xa,
|
|
8824
|
-
|
|
8825
|
-
X,
|
|
8823
|
+
Zr,
|
|
8826
8824
|
Y,
|
|
8825
|
+
J,
|
|
8827
8826
|
Q,
|
|
8828
8827
|
fs,
|
|
8829
8828
|
Z,
|
|
@@ -8846,14 +8845,14 @@ let __tla = (async () => {
|
|
|
8846
8845
|
Ws
|
|
8847
8846
|
]), Qs = import_react.useCallback((e2) => {
|
|
8848
8847
|
let t2 = false;
|
|
8849
|
-
if (
|
|
8848
|
+
if (Hr !== void 0 && Hr({
|
|
8850
8849
|
...e2,
|
|
8851
8850
|
cancel: () => {
|
|
8852
8851
|
t2 = true;
|
|
8853
8852
|
}
|
|
8854
8853
|
}), t2 || Zs(e2) || $.current === void 0) return;
|
|
8855
8854
|
let [n2, r2] = $.current.cell, i2 = No.current;
|
|
8856
|
-
if (
|
|
8855
|
+
if (qr && !e2.metaKey && !e2.ctrlKey && $.current !== void 0 && e2.key.length === 1 && /[ -~]/g.test(e2.key) && e2.bounds !== void 0 && isReadWriteCell(E([
|
|
8857
8856
|
n2 - Q,
|
|
8858
8857
|
Math.max(0, Math.min(r2, Z - 1))
|
|
8859
8858
|
]))) {
|
|
@@ -8861,8 +8860,8 @@ let __tla = (async () => {
|
|
|
8861
8860
|
ts(e2.bounds, true, e2.key), e2.stopPropagation(), e2.preventDefault();
|
|
8862
8861
|
}
|
|
8863
8862
|
}, [
|
|
8864
|
-
|
|
8865
|
-
|
|
8863
|
+
qr,
|
|
8864
|
+
Hr,
|
|
8866
8865
|
Zs,
|
|
8867
8866
|
$,
|
|
8868
8867
|
E,
|
|
@@ -8872,12 +8871,12 @@ let __tla = (async () => {
|
|
|
8872
8871
|
ts
|
|
8873
8872
|
]), $s = import_react.useCallback((e2, t2) => {
|
|
8874
8873
|
let n2 = e2.location[0] - Q;
|
|
8875
|
-
if (e2.kind === "header" && (
|
|
8874
|
+
if (e2.kind === "header" && (V == null ? void 0 : V(n2, {
|
|
8876
8875
|
...e2,
|
|
8877
8876
|
preventDefault: t2
|
|
8878
8877
|
})), e2.kind === "group-header") {
|
|
8879
8878
|
if (n2 < 0) return;
|
|
8880
|
-
|
|
8879
|
+
H == null ? void 0 : H(n2, {
|
|
8881
8880
|
...e2,
|
|
8882
8881
|
preventDefault: t2
|
|
8883
8882
|
});
|
|
@@ -8895,8 +8894,8 @@ let __tla = (async () => {
|
|
|
8895
8894
|
}, [
|
|
8896
8895
|
$,
|
|
8897
8896
|
Fr,
|
|
8898
|
-
U,
|
|
8899
8897
|
H,
|
|
8898
|
+
V,
|
|
8900
8899
|
Q,
|
|
8901
8900
|
Ks
|
|
8902
8901
|
]), ec = import_react.useCallback(async (e2) => {
|
|
@@ -9095,11 +9094,11 @@ let __tla = (async () => {
|
|
|
9095
9094
|
_o
|
|
9096
9095
|
]), f, false, false);
|
|
9097
9096
|
let nc = import_react.useCallback((e2, t2) => {
|
|
9098
|
-
if (
|
|
9097
|
+
if (zr !== void 0) {
|
|
9099
9098
|
Q !== 0 && (e2 = e2.map((e3) => [
|
|
9100
9099
|
e3[0] - Q,
|
|
9101
9100
|
e3[1]
|
|
9102
|
-
])),
|
|
9101
|
+
])), zr(e2, t2);
|
|
9103
9102
|
return;
|
|
9104
9103
|
}
|
|
9105
9104
|
if (e2.length === 0 || t2 === -1) return;
|
|
@@ -9109,7 +9108,7 @@ let __tla = (async () => {
|
|
|
9109
9108
|
r2
|
|
9110
9109
|
], Ks(n2, r2, false, false));
|
|
9111
9110
|
}, [
|
|
9112
|
-
|
|
9111
|
+
zr,
|
|
9113
9112
|
Q,
|
|
9114
9113
|
Ks
|
|
9115
9114
|
]), [rc, ic] = ((_c2 = ki == null ? void 0 : ki.current) == null ? void 0 : _c2.cell) ?? [], ac = import_react.useRef(rs);
|
|
@@ -9143,11 +9142,11 @@ let __tla = (async () => {
|
|
|
9143
9142
|
canvasBounds: n2,
|
|
9144
9143
|
onClose: () => xs(void 0),
|
|
9145
9144
|
onFinish: (e3) => {
|
|
9146
|
-
xs(void 0),
|
|
9145
|
+
xs(void 0), Rr == null ? void 0 : Rr(t2, e3);
|
|
9147
9146
|
}
|
|
9148
9147
|
});
|
|
9149
9148
|
}, [
|
|
9150
|
-
|
|
9149
|
+
Rr,
|
|
9151
9150
|
bs
|
|
9152
9151
|
]), uc = Math.min(Mo.length, mi + (Qa ? 1 : 0));
|
|
9153
9152
|
import_react.useImperativeHandle(t, () => ({
|
|
@@ -9255,7 +9254,7 @@ let __tla = (async () => {
|
|
|
9255
9254
|
let [dc, fc] = Ps ?? [], pc = import_react.useCallback((e2) => {
|
|
9256
9255
|
let [t2, n2] = e2;
|
|
9257
9256
|
if (n2 === -1) {
|
|
9258
|
-
|
|
9257
|
+
Zr !== "none" && (bo(CompactSelection.fromSingleSelection(t2), void 0, false), Vo());
|
|
9259
9258
|
return;
|
|
9260
9259
|
}
|
|
9261
9260
|
dc === t2 && fc === n2 || (vo({
|
|
@@ -9268,7 +9267,7 @@ let __tla = (async () => {
|
|
|
9268
9267
|
}
|
|
9269
9268
|
}, true, false, "keyboard-nav"), rs(t2, n2));
|
|
9270
9269
|
}, [
|
|
9271
|
-
|
|
9270
|
+
Zr,
|
|
9272
9271
|
Vo,
|
|
9273
9272
|
rs,
|
|
9274
9273
|
dc,
|
|
@@ -9326,7 +9325,7 @@ let __tla = (async () => {
|
|
|
9326
9325
|
value: xo
|
|
9327
9326
|
}, import_react.createElement(DataEditorContainer, {
|
|
9328
9327
|
style: xc,
|
|
9329
|
-
className:
|
|
9328
|
+
className: Ir,
|
|
9330
9329
|
inWidth: y ?? yc,
|
|
9331
9330
|
inHeight: x ?? bc
|
|
9332
9331
|
}, import_react.createElement(data_grid_search_default, {
|
|
@@ -9349,7 +9348,7 @@ let __tla = (async () => {
|
|
|
9349
9348
|
rightElementProps: ca,
|
|
9350
9349
|
smoothScrollX: ua,
|
|
9351
9350
|
smoothScrollY: da,
|
|
9352
|
-
className:
|
|
9351
|
+
className: Ir,
|
|
9353
9352
|
enableGroups: Oo,
|
|
9354
9353
|
onCanvasFocused: _c,
|
|
9355
9354
|
onCanvasBlur: vc,
|
|
@@ -9395,7 +9394,7 @@ let __tla = (async () => {
|
|
|
9395
9394
|
isFilling: (c == null ? void 0 : c.fillHandle) === true,
|
|
9396
9395
|
onMouseMove: js,
|
|
9397
9396
|
onKeyDown: Qs,
|
|
9398
|
-
onKeyUp:
|
|
9397
|
+
onKeyUp: Gr,
|
|
9399
9398
|
onMouseDown: ys,
|
|
9400
9399
|
onMouseUp: As,
|
|
9401
9400
|
onDragOverCell: Vi,
|
|
@@ -9404,9 +9403,9 @@ let __tla = (async () => {
|
|
|
9404
9403
|
onVisibleRegionChanged: Fs,
|
|
9405
9404
|
clientSize: So,
|
|
9406
9405
|
rowHeight: Wa,
|
|
9407
|
-
searchResults:
|
|
9408
|
-
searchValue:
|
|
9409
|
-
onSearchValueChange:
|
|
9406
|
+
searchResults: G,
|
|
9407
|
+
searchValue: Vr,
|
|
9408
|
+
onSearchValueChange: K,
|
|
9410
9409
|
rows: Ho,
|
|
9411
9410
|
scrollRef: Lo,
|
|
9412
9411
|
selection: $,
|
|
@@ -10404,8 +10403,8 @@ let __tla = (async () => {
|
|
|
10404
10403
|
}), t[8] = h) : h = t[8];
|
|
10405
10404
|
let g;
|
|
10406
10405
|
t[9] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (g = (e2) => o(e2.target.value), t[9] = g) : g = t[9];
|
|
10407
|
-
let
|
|
10408
|
-
t[10] !== u || t[11] !== a ? (
|
|
10406
|
+
let y;
|
|
10407
|
+
t[10] !== u || t[11] !== a ? (y = (0, import_jsx_runtime.jsxs)("div", {
|
|
10409
10408
|
children: [
|
|
10410
10409
|
h,
|
|
10411
10410
|
(0, import_jsx_runtime.jsx)(Input, {
|
|
@@ -10416,17 +10415,17 @@ let __tla = (async () => {
|
|
|
10416
10415
|
onKeyDown: u
|
|
10417
10416
|
})
|
|
10418
10417
|
]
|
|
10419
|
-
}), t[10] = u, t[11] = a, t[12] =
|
|
10420
|
-
let
|
|
10421
|
-
t[13] !== c || t[14] !==
|
|
10418
|
+
}), t[10] = u, t[11] = a, t[12] = y) : y = t[12];
|
|
10419
|
+
let x = !a.trim(), C;
|
|
10420
|
+
t[13] !== c || t[14] !== x ? (C = (0, import_jsx_runtime.jsx)(Button, {
|
|
10422
10421
|
onClick: c,
|
|
10423
|
-
disabled:
|
|
10422
|
+
disabled: x,
|
|
10424
10423
|
size: "sm",
|
|
10425
10424
|
className: "w-full",
|
|
10426
10425
|
children: "Rename"
|
|
10427
|
-
}), t[13] = c, t[14] =
|
|
10428
|
-
let
|
|
10429
|
-
return t[16] !==
|
|
10426
|
+
}), t[13] = c, t[14] = x, t[15] = C) : C = t[15];
|
|
10427
|
+
let E;
|
|
10428
|
+
return t[16] !== y || t[17] !== C ? (E = (0, import_jsx_runtime.jsxs)(DropdownMenuSub, {
|
|
10430
10429
|
children: [
|
|
10431
10430
|
f,
|
|
10432
10431
|
(0, import_jsx_runtime.jsx)(DropdownMenuPortal, {
|
|
@@ -10435,128 +10434,128 @@ let __tla = (async () => {
|
|
|
10435
10434
|
children: (0, import_jsx_runtime.jsxs)("div", {
|
|
10436
10435
|
className: "space-y-3",
|
|
10437
10436
|
children: [
|
|
10438
|
-
|
|
10439
|
-
|
|
10437
|
+
y,
|
|
10438
|
+
C
|
|
10440
10439
|
]
|
|
10441
10440
|
})
|
|
10442
10441
|
})
|
|
10443
10442
|
})
|
|
10444
10443
|
]
|
|
10445
|
-
}), t[16] =
|
|
10444
|
+
}), t[16] = y, t[17] = C, t[18] = E) : E = t[18], E;
|
|
10446
10445
|
}, AddColumnSub = (e) => {
|
|
10447
|
-
let t = (0, import_compiler_runtime.c)(77), { direction: n, onAdd: r, onCancel: i } = e, [a, o] = (0, import_react.useState)(""), [s, u] = (0, import_react.useState)("string"), g, x, C, E, D, k,
|
|
10446
|
+
let t = (0, import_compiler_runtime.c)(77), { direction: n, onAdd: r, onCancel: i } = e, [a, o] = (0, import_react.useState)(""), [s, u] = (0, import_react.useState)("string"), g, y, x, C, E, D, k, A, N, P, F, I, B, Fr, V;
|
|
10448
10447
|
if (t[0] !== a || t[1] !== s || t[2] !== n || t[3] !== r || t[4] !== i) {
|
|
10449
10448
|
let e2 = [
|
|
10450
10449
|
"string",
|
|
10451
10450
|
"number",
|
|
10452
10451
|
"boolean",
|
|
10453
10452
|
"datetime"
|
|
10454
|
-
],
|
|
10455
|
-
t[20] !== a || t[21] !== s || t[22] !== r ? (
|
|
10453
|
+
], Ir;
|
|
10454
|
+
t[20] !== a || t[21] !== s || t[22] !== r ? (Ir = () => {
|
|
10456
10455
|
a.trim() && (r(a.trim(), s), o(""), u("string"));
|
|
10457
|
-
}, t[20] = a, t[21] = s, t[22] = r, t[23] =
|
|
10458
|
-
let Ir2;
|
|
10459
|
-
t[24] !== k || t[25] !== i ? (Ir2 = (e3) => {
|
|
10460
|
-
e3.key === "Enter" ? k() : e3.key === "Escape" && i();
|
|
10461
|
-
}, t[24] = k, t[25] = i, t[26] = Ir2) : Ir2 = t[26];
|
|
10462
|
-
let U2 = Ir2;
|
|
10463
|
-
D = DropdownMenuSub;
|
|
10456
|
+
}, t[20] = a, t[21] = s, t[22] = r, t[23] = Ir) : Ir = t[23], D = Ir;
|
|
10464
10457
|
let Lr2;
|
|
10465
|
-
t[
|
|
10458
|
+
t[24] !== D || t[25] !== i ? (Lr2 = (e3) => {
|
|
10459
|
+
e3.key === "Enter" ? D() : e3.key === "Escape" && i();
|
|
10460
|
+
}, t[24] = D, t[25] = i, t[26] = Lr2) : Lr2 = t[26];
|
|
10461
|
+
let H2 = Lr2;
|
|
10462
|
+
E = DropdownMenuSub;
|
|
10463
|
+
let Rr2;
|
|
10464
|
+
t[27] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (Rr2 = (0, import_jsx_runtime.jsx)(Plus, {
|
|
10466
10465
|
className: "mr-2 h-3.5 w-3.5"
|
|
10467
|
-
}), t[27] =
|
|
10466
|
+
}), t[27] = Rr2) : Rr2 = t[27], t[28] === n ? V = t[29] : (V = (0, import_jsx_runtime.jsxs)(DropdownMenuSubTrigger, {
|
|
10468
10467
|
children: [
|
|
10469
|
-
|
|
10468
|
+
Rr2,
|
|
10470
10469
|
"Add column to the ",
|
|
10471
10470
|
n
|
|
10472
10471
|
]
|
|
10473
|
-
}), t[28] = n, t[29] =
|
|
10474
|
-
let
|
|
10475
|
-
t[30] ===
|
|
10476
|
-
htmlFor:
|
|
10472
|
+
}), t[28] = n, t[29] = V), C = DropdownMenuPortal, x = DropdownMenuSubContent, Fr = "w-64 p-4", I = "space-y-3";
|
|
10473
|
+
let U2 = `add-column-input-${n}`, W2;
|
|
10474
|
+
t[30] === U2 ? W2 = t[31] : (W2 = (0, import_jsx_runtime.jsx)(Label, {
|
|
10475
|
+
htmlFor: U2,
|
|
10477
10476
|
children: "Column name"
|
|
10478
|
-
}), t[30] =
|
|
10479
|
-
let
|
|
10480
|
-
t[32] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
10481
|
-
let
|
|
10482
|
-
t[33] !== a || t[34] !==
|
|
10483
|
-
id:
|
|
10477
|
+
}), t[30] = U2, t[31] = W2);
|
|
10478
|
+
let zr2 = `add-column-input-${n}`, G2;
|
|
10479
|
+
t[32] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (G2 = (e3) => o(e3.target.value), t[32] = G2) : G2 = t[32];
|
|
10480
|
+
let K2;
|
|
10481
|
+
t[33] !== a || t[34] !== H2 || t[35] !== zr2 ? (K2 = (0, import_jsx_runtime.jsx)(Input, {
|
|
10482
|
+
id: zr2,
|
|
10484
10483
|
value: a,
|
|
10485
|
-
onChange:
|
|
10484
|
+
onChange: G2,
|
|
10486
10485
|
placeholder: "Enter column name",
|
|
10487
10486
|
className: "mt-1",
|
|
10488
|
-
onKeyDown:
|
|
10489
|
-
}), t[33] = a, t[34] =
|
|
10487
|
+
onKeyDown: H2
|
|
10488
|
+
}), t[33] = a, t[34] = H2, t[35] = zr2, t[36] = K2) : K2 = t[36], t[37] !== W2 || t[38] !== K2 ? (B = (0, import_jsx_runtime.jsxs)("div", {
|
|
10490
10489
|
children: [
|
|
10491
|
-
|
|
10492
|
-
|
|
10490
|
+
W2,
|
|
10491
|
+
K2
|
|
10493
10492
|
]
|
|
10494
|
-
}), t[37] =
|
|
10495
|
-
let
|
|
10496
|
-
t[40] ===
|
|
10497
|
-
htmlFor:
|
|
10493
|
+
}), t[37] = W2, t[38] = K2, t[39] = B) : B = t[39];
|
|
10494
|
+
let Br2 = `add-column-type-${n}`;
|
|
10495
|
+
t[40] === Br2 ? F = t[41] : (F = (0, import_jsx_runtime.jsx)(Label, {
|
|
10496
|
+
htmlFor: Br2,
|
|
10498
10497
|
children: "Data type"
|
|
10499
|
-
}), t[40] =
|
|
10500
|
-
let
|
|
10501
|
-
t[43] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
10502
|
-
id:
|
|
10498
|
+
}), t[40] = Br2, t[41] = F), y = Select, A = s, t[42] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (N = (e3) => u(e3), t[42] = N) : N = t[42];
|
|
10499
|
+
let Vr = `add-column-type-${n}`, Hr;
|
|
10500
|
+
t[43] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (Hr = (0, import_jsx_runtime.jsx)(SelectValue, {}), t[43] = Hr) : Hr = t[43], t[44] === Vr ? P = t[45] : (P = (0, import_jsx_runtime.jsx)(SelectTrigger, {
|
|
10501
|
+
id: Vr,
|
|
10503
10502
|
className: "mt-1",
|
|
10504
|
-
children:
|
|
10505
|
-
}), t[44] =
|
|
10506
|
-
} else g = t[5],
|
|
10507
|
-
let
|
|
10508
|
-
t[46] !== g || t[47] !==
|
|
10509
|
-
children:
|
|
10510
|
-
}), t[46] = g, t[47] =
|
|
10511
|
-
let
|
|
10512
|
-
t[49] !==
|
|
10513
|
-
value:
|
|
10503
|
+
children: Hr
|
|
10504
|
+
}), t[44] = Vr, t[45] = P), g = SelectContent, k = e2.map(_temp), t[0] = a, t[1] = s, t[2] = n, t[3] = r, t[4] = i, t[5] = g, t[6] = y, t[7] = x, t[8] = C, t[9] = E, t[10] = D, t[11] = k, t[12] = A, t[13] = N, t[14] = P, t[15] = F, t[16] = I, t[17] = B, t[18] = Fr, t[19] = V;
|
|
10505
|
+
} else g = t[5], y = t[6], x = t[7], C = t[8], E = t[9], D = t[10], k = t[11], A = t[12], N = t[13], P = t[14], F = t[15], I = t[16], B = t[17], Fr = t[18], V = t[19];
|
|
10506
|
+
let Lr;
|
|
10507
|
+
t[46] !== g || t[47] !== k ? (Lr = (0, import_jsx_runtime.jsx)(g, {
|
|
10508
|
+
children: k
|
|
10509
|
+
}), t[46] = g, t[47] = k, t[48] = Lr) : Lr = t[48];
|
|
10510
|
+
let H;
|
|
10511
|
+
t[49] !== y || t[50] !== Lr || t[51] !== A || t[52] !== N || t[53] !== P ? (H = (0, import_jsx_runtime.jsxs)(y, {
|
|
10512
|
+
value: A,
|
|
10514
10513
|
onValueChange: N,
|
|
10515
10514
|
children: [
|
|
10516
10515
|
P,
|
|
10517
|
-
|
|
10516
|
+
Lr
|
|
10518
10517
|
]
|
|
10519
|
-
}), t[49] =
|
|
10520
|
-
let
|
|
10521
|
-
t[55] !==
|
|
10518
|
+
}), t[49] = y, t[50] = Lr, t[51] = A, t[52] = N, t[53] = P, t[54] = H) : H = t[54];
|
|
10519
|
+
let Rr;
|
|
10520
|
+
t[55] !== H || t[56] !== F ? (Rr = (0, import_jsx_runtime.jsxs)("div", {
|
|
10522
10521
|
children: [
|
|
10523
10522
|
F,
|
|
10524
|
-
|
|
10523
|
+
H
|
|
10525
10524
|
]
|
|
10526
|
-
}), t[55] =
|
|
10527
|
-
let
|
|
10528
|
-
t[58] !==
|
|
10529
|
-
onClick:
|
|
10530
|
-
disabled:
|
|
10525
|
+
}), t[55] = H, t[56] = F, t[57] = Rr) : Rr = t[57];
|
|
10526
|
+
let U = !a.trim(), W;
|
|
10527
|
+
t[58] !== D || t[59] !== U ? (W = (0, import_jsx_runtime.jsx)(Button, {
|
|
10528
|
+
onClick: D,
|
|
10529
|
+
disabled: U,
|
|
10531
10530
|
size: "sm",
|
|
10532
10531
|
className: "w-full",
|
|
10533
10532
|
children: "Add"
|
|
10534
|
-
}), t[58] =
|
|
10535
|
-
let
|
|
10536
|
-
t[61] !==
|
|
10537
|
-
className:
|
|
10533
|
+
}), t[58] = D, t[59] = U, t[60] = W) : W = t[60];
|
|
10534
|
+
let zr;
|
|
10535
|
+
t[61] !== Rr || t[62] !== W || t[63] !== I || t[64] !== B ? (zr = (0, import_jsx_runtime.jsxs)("div", {
|
|
10536
|
+
className: I,
|
|
10538
10537
|
children: [
|
|
10539
10538
|
B,
|
|
10540
|
-
|
|
10541
|
-
|
|
10539
|
+
Rr,
|
|
10540
|
+
W
|
|
10542
10541
|
]
|
|
10543
|
-
}), t[61] =
|
|
10542
|
+
}), t[61] = Rr, t[62] = W, t[63] = I, t[64] = B, t[65] = zr) : zr = t[65];
|
|
10543
|
+
let G;
|
|
10544
|
+
t[66] !== x || t[67] !== zr || t[68] !== Fr ? (G = (0, import_jsx_runtime.jsx)(x, {
|
|
10545
|
+
className: Fr,
|
|
10546
|
+
children: zr
|
|
10547
|
+
}), t[66] = x, t[67] = zr, t[68] = Fr, t[69] = G) : G = t[69];
|
|
10544
10548
|
let K;
|
|
10545
|
-
t[
|
|
10546
|
-
|
|
10547
|
-
|
|
10548
|
-
|
|
10549
|
-
|
|
10550
|
-
t[70] !== E || t[71] !== K ? (q = (0, import_jsx_runtime.jsx)(E, {
|
|
10551
|
-
children: K
|
|
10552
|
-
}), t[70] = E, t[71] = K, t[72] = q) : q = t[72];
|
|
10553
|
-
let zr;
|
|
10554
|
-
return t[73] !== D || t[74] !== q || t[75] !== H ? (zr = (0, import_jsx_runtime.jsxs)(D, {
|
|
10549
|
+
t[70] !== C || t[71] !== G ? (K = (0, import_jsx_runtime.jsx)(C, {
|
|
10550
|
+
children: G
|
|
10551
|
+
}), t[70] = C, t[71] = G, t[72] = K) : K = t[72];
|
|
10552
|
+
let Br;
|
|
10553
|
+
return t[73] !== E || t[74] !== K || t[75] !== V ? (Br = (0, import_jsx_runtime.jsxs)(E, {
|
|
10555
10554
|
children: [
|
|
10556
|
-
|
|
10557
|
-
|
|
10555
|
+
V,
|
|
10556
|
+
K
|
|
10558
10557
|
]
|
|
10559
|
-
}), t[73] =
|
|
10558
|
+
}), t[73] = E, t[74] = K, t[75] = V, t[76] = Br) : Br = t[76], Br;
|
|
10560
10559
|
};
|
|
10561
10560
|
function _temp(e) {
|
|
10562
10561
|
return (0, import_jsx_runtime.jsx)(SelectItem, {
|
|
@@ -10627,37 +10626,37 @@ let __tla = (async () => {
|
|
|
10627
10626
|
}
|
|
10628
10627
|
}
|
|
10629
10628
|
}
|
|
10630
|
-
GlideDataEditor = ({ data: e, setData: t, columnFields: n, setColumnFields: r, editableColumns: c, edits: l, onAddEdits: u, onAddRows: f, onDeleteRows: m, onRenameColumn: h, onDeleteColumn:
|
|
10631
|
-
let { theme:
|
|
10629
|
+
GlideDataEditor = ({ data: e, setData: t, columnFields: n, setColumnFields: r, editableColumns: c, edits: l, onAddEdits: u, onAddRows: f, onDeleteRows: m, onRenameColumn: h, onDeleteColumn: y, onAddColumn: S }) => {
|
|
10630
|
+
let { theme: O } = useTheme(), k = (0, import_react.useRef)(null), [A, j] = (0, import_react.useState)(), [M, F] = (0, import_react.useState)(false), [L, Pr] = import_react.useState({
|
|
10632
10631
|
columns: CompactSelection.empty(),
|
|
10633
10632
|
rows: CompactSelection.empty()
|
|
10634
|
-
}), [
|
|
10633
|
+
}), [B, V] = (0, import_react.useState)({}), Rr = useNonce(), U = (0, import_react.useRef)(false), W = (0, import_react.useMemo)(() => {
|
|
10635
10634
|
let e2 = [];
|
|
10636
10635
|
for (let [t2, r2] of Object.entries(n)) {
|
|
10637
10636
|
let n2 = c === "all" || c.includes(t2);
|
|
10638
10637
|
e2.push({
|
|
10639
10638
|
id: t2,
|
|
10640
10639
|
title: t2,
|
|
10641
|
-
width:
|
|
10640
|
+
width: B[t2],
|
|
10642
10641
|
icon: n2 ? getColumnHeaderIcon(r2) : GridColumnIcon.ProtectedColumnOverlay,
|
|
10643
10642
|
style: "normal",
|
|
10644
10643
|
kind: getColumnKind(r2),
|
|
10645
10644
|
dataType: r2,
|
|
10646
10645
|
hasMenu: true,
|
|
10647
10646
|
themeOverride: n2 ? void 0 : {
|
|
10648
|
-
bgCell:
|
|
10647
|
+
bgCell: O === "light" ? "#F9F9FA" : "#1e1e21"
|
|
10649
10648
|
}
|
|
10650
10649
|
});
|
|
10651
10650
|
}
|
|
10652
10651
|
return e2;
|
|
10653
10652
|
}, [
|
|
10654
10653
|
n,
|
|
10655
|
-
|
|
10654
|
+
B,
|
|
10656
10655
|
c,
|
|
10657
|
-
|
|
10656
|
+
O
|
|
10658
10657
|
]);
|
|
10659
10658
|
(0, import_react.useEffect)(() => {
|
|
10660
|
-
if (
|
|
10659
|
+
if (U.current || e.length === 0 || (U.current = true, l.length === 0)) return;
|
|
10661
10660
|
let n2 = /* @__PURE__ */ new Map();
|
|
10662
10661
|
for (let i2 of l) if (isPositionalEdit(i2)) if (i2.rowIdx >= e.length) {
|
|
10663
10662
|
n2.has(i2.rowIdx) || n2.set(i2.rowIdx, {});
|
|
@@ -10687,7 +10686,7 @@ let __tla = (async () => {
|
|
|
10687
10686
|
})), t((e2) => insertColumn(e2, i2.newName));
|
|
10688
10687
|
break;
|
|
10689
10688
|
case BulkEdit.Rename: {
|
|
10690
|
-
let e2 =
|
|
10689
|
+
let e2 = W[i2.columnIdx].title, n3 = i2.newName;
|
|
10691
10690
|
if (!e2 || !n3) return;
|
|
10692
10691
|
r((e3) => modifyColumnFields({
|
|
10693
10692
|
columnFields: e3,
|
|
@@ -10704,12 +10703,12 @@ let __tla = (async () => {
|
|
|
10704
10703
|
i.length > 0 && t((e2) => [
|
|
10705
10704
|
...e2,
|
|
10706
10705
|
...i
|
|
10707
|
-
]),
|
|
10706
|
+
]), Rr();
|
|
10708
10707
|
}, [
|
|
10709
10708
|
e.length
|
|
10710
10709
|
]);
|
|
10711
|
-
let
|
|
10712
|
-
let [n2, r2] = t2, i = e[r2][
|
|
10710
|
+
let zr = (0, import_react.useCallback)((t2) => {
|
|
10711
|
+
let [n2, r2] = t2, i = e[r2][W[n2].title], a = W[n2].kind, o = c === "all" || c.includes(W[n2].title);
|
|
10713
10712
|
if (a === GridCellKind.Boolean) {
|
|
10714
10713
|
let e2 = !!i;
|
|
10715
10714
|
return {
|
|
@@ -10733,11 +10732,11 @@ let __tla = (async () => {
|
|
|
10733
10732
|
data: String(i)
|
|
10734
10733
|
};
|
|
10735
10734
|
}, [
|
|
10736
|
-
|
|
10735
|
+
W,
|
|
10737
10736
|
e,
|
|
10738
10737
|
c
|
|
10739
|
-
]),
|
|
10740
|
-
let [r2, i] = e2, a =
|
|
10738
|
+
]), G = (0, import_react.useCallback)((e2, n2) => {
|
|
10739
|
+
let [r2, i] = e2, a = W[r2], o = a.title, s = n2.data;
|
|
10741
10740
|
(a.dataType === "number" || a.dataType === "integer") && (n2.data === void 0 || n2.data === "") && (s = null), t((e3) => {
|
|
10742
10741
|
let t2 = [
|
|
10743
10742
|
...e3
|
|
@@ -10751,17 +10750,17 @@ let __tla = (async () => {
|
|
|
10751
10750
|
}
|
|
10752
10751
|
]);
|
|
10753
10752
|
}, [
|
|
10754
|
-
|
|
10753
|
+
W,
|
|
10755
10754
|
u,
|
|
10756
10755
|
t
|
|
10757
|
-
]),
|
|
10758
|
-
|
|
10756
|
+
]), K = (0, import_react.useCallback)((e2, t2) => {
|
|
10757
|
+
V((n2) => ({
|
|
10759
10758
|
...n2,
|
|
10760
10759
|
[e2.title]: t2
|
|
10761
10760
|
}));
|
|
10762
|
-
}, []),
|
|
10761
|
+
}, []), Br = (0, import_react.useCallback)((e2, t2, r2) => {
|
|
10763
10762
|
let [i, a] = e2;
|
|
10764
|
-
switch (n[
|
|
10763
|
+
switch (n[W[i].title]) {
|
|
10765
10764
|
case "number":
|
|
10766
10765
|
case "integer":
|
|
10767
10766
|
if (Number.isNaN(Number(t2.data))) return false;
|
|
@@ -10773,42 +10772,42 @@ let __tla = (async () => {
|
|
|
10773
10772
|
return true;
|
|
10774
10773
|
}, [
|
|
10775
10774
|
n,
|
|
10776
|
-
|
|
10777
|
-
]),
|
|
10778
|
-
if (
|
|
10775
|
+
W
|
|
10776
|
+
]), Vr = (0, import_react.useCallback)((n2) => {
|
|
10777
|
+
if (k.current) {
|
|
10779
10778
|
if (Events.isMetaOrCtrl(n2) && n2.key === "c") {
|
|
10780
|
-
|
|
10779
|
+
k.current.emit("copy");
|
|
10781
10780
|
return;
|
|
10782
10781
|
}
|
|
10783
10782
|
if (Events.isMetaOrCtrl(n2) && n2.key === "v") {
|
|
10784
10783
|
pasteCells({
|
|
10785
|
-
selection:
|
|
10784
|
+
selection: L,
|
|
10786
10785
|
data: e,
|
|
10787
10786
|
setData: t,
|
|
10788
|
-
columns:
|
|
10787
|
+
columns: W,
|
|
10789
10788
|
editableColumns: c,
|
|
10790
10789
|
onAddEdits: u
|
|
10791
10790
|
});
|
|
10792
10791
|
return;
|
|
10793
10792
|
}
|
|
10794
10793
|
if (Events.isMetaOrCtrl(n2) && n2.key === "f") {
|
|
10795
|
-
|
|
10794
|
+
F((e2) => !e2), n2.stopPropagation(), n2.preventDefault();
|
|
10796
10795
|
return;
|
|
10797
10796
|
}
|
|
10798
10797
|
if (n2.key === "Escape") {
|
|
10799
|
-
|
|
10798
|
+
F(false);
|
|
10800
10799
|
return;
|
|
10801
10800
|
}
|
|
10802
10801
|
}
|
|
10803
10802
|
}, [
|
|
10804
|
-
|
|
10803
|
+
W,
|
|
10805
10804
|
e,
|
|
10806
10805
|
c,
|
|
10807
10806
|
u,
|
|
10808
|
-
|
|
10807
|
+
L,
|
|
10809
10808
|
t
|
|
10810
|
-
]),
|
|
10811
|
-
let e2 = Object.fromEntries(
|
|
10809
|
+
]), Hr = (0, import_react.useCallback)(() => {
|
|
10810
|
+
let e2 = Object.fromEntries(W.map((e3) => {
|
|
10812
10811
|
let t2 = e3.dataType;
|
|
10813
10812
|
switch (t2) {
|
|
10814
10813
|
case "boolean":
|
|
@@ -10849,154 +10848,154 @@ let __tla = (async () => {
|
|
|
10849
10848
|
e2
|
|
10850
10849
|
]);
|
|
10851
10850
|
}, [
|
|
10852
|
-
|
|
10851
|
+
W,
|
|
10853
10852
|
f,
|
|
10854
10853
|
t
|
|
10855
|
-
]),
|
|
10856
|
-
let e2 =
|
|
10854
|
+
]), Ur = () => {
|
|
10855
|
+
let e2 = L.rows.toArray();
|
|
10857
10856
|
m(e2);
|
|
10858
10857
|
let n2 = 0;
|
|
10859
10858
|
for (let r2 of e2) {
|
|
10860
10859
|
let e3 = r2 - n2;
|
|
10861
10860
|
t((t2) => t2.filter((t3, n3) => n3 !== e3)), n2++;
|
|
10862
10861
|
}
|
|
10863
|
-
|
|
10862
|
+
Pr({
|
|
10864
10863
|
columns: CompactSelection.empty(),
|
|
10865
10864
|
rows: CompactSelection.empty()
|
|
10866
10865
|
});
|
|
10867
|
-
},
|
|
10868
|
-
|
|
10866
|
+
}, Wr = useEvent_default((e2, t2) => {
|
|
10867
|
+
j({
|
|
10869
10868
|
col: e2,
|
|
10870
10869
|
bounds: t2
|
|
10871
10870
|
});
|
|
10872
|
-
}),
|
|
10873
|
-
if (
|
|
10874
|
-
let e2 =
|
|
10875
|
-
await copyToClipboard(e2),
|
|
10871
|
+
}), Gr = async () => {
|
|
10872
|
+
if (A) {
|
|
10873
|
+
let e2 = W[A.col].title;
|
|
10874
|
+
await copyToClipboard(e2), j(void 0);
|
|
10876
10875
|
}
|
|
10877
10876
|
};
|
|
10878
|
-
function
|
|
10877
|
+
function Kr(e2) {
|
|
10879
10878
|
toast({
|
|
10880
10879
|
title: `Column '${e2}' already exists`,
|
|
10881
10880
|
description: "Please enter a different column name",
|
|
10882
10881
|
variant: "danger"
|
|
10883
10882
|
});
|
|
10884
10883
|
}
|
|
10885
|
-
let
|
|
10886
|
-
if (
|
|
10887
|
-
let i =
|
|
10884
|
+
let qr = (e2) => {
|
|
10885
|
+
if (A) {
|
|
10886
|
+
let i = W[A.col].title;
|
|
10888
10887
|
if (n[e2]) {
|
|
10889
|
-
|
|
10888
|
+
Kr(e2);
|
|
10890
10889
|
return;
|
|
10891
10890
|
}
|
|
10892
|
-
let a =
|
|
10893
|
-
h(
|
|
10891
|
+
let a = W[A.col].dataType;
|
|
10892
|
+
h(A.col, e2), r((t2) => modifyColumnFields({
|
|
10894
10893
|
columnFields: t2,
|
|
10895
|
-
columnIdx:
|
|
10894
|
+
columnIdx: A.col,
|
|
10896
10895
|
type: "rename",
|
|
10897
10896
|
dataType: a,
|
|
10898
10897
|
newColumnName: e2
|
|
10899
|
-
})), t((t2) => renameColumn(t2, i, e2)),
|
|
10898
|
+
})), t((t2) => renameColumn(t2, i, e2)), j(void 0);
|
|
10900
10899
|
}
|
|
10901
|
-
},
|
|
10902
|
-
|
|
10900
|
+
}, q = () => {
|
|
10901
|
+
A && (y(A.col), r((e2) => modifyColumnFields({
|
|
10903
10902
|
columnFields: e2,
|
|
10904
|
-
columnIdx:
|
|
10903
|
+
columnIdx: A.col,
|
|
10905
10904
|
type: "remove"
|
|
10906
|
-
})), t((e2) => removeColumn(e2,
|
|
10907
|
-
},
|
|
10905
|
+
})), t((e2) => removeColumn(e2, A.col)), j(void 0));
|
|
10906
|
+
}, Jr = (e2) => {
|
|
10908
10907
|
let { direction: i, columnName: a, dataType: o } = e2;
|
|
10909
|
-
if (
|
|
10910
|
-
let e3 =
|
|
10908
|
+
if (A) {
|
|
10909
|
+
let e3 = A.col + (i === "left" ? 0 : 1), s = Math.max(0, Math.min(e3, W.length));
|
|
10911
10910
|
if (n[a]) {
|
|
10912
|
-
|
|
10911
|
+
Kr(a);
|
|
10913
10912
|
return;
|
|
10914
10913
|
}
|
|
10915
|
-
|
|
10914
|
+
S(s, a), r((e4) => modifyColumnFields({
|
|
10916
10915
|
columnFields: e4,
|
|
10917
10916
|
columnIdx: s,
|
|
10918
10917
|
type: "insert",
|
|
10919
10918
|
dataType: o,
|
|
10920
10919
|
newColumnName: a
|
|
10921
|
-
})), t((e4) => insertColumn(e4, a)),
|
|
10920
|
+
})), t((e4) => insertColumn(e4, a)), j(void 0);
|
|
10922
10921
|
}
|
|
10923
|
-
},
|
|
10922
|
+
}, Yr = (A == null ? void 0 : A.col) === W.length - 1, Xr = A !== void 0, J = "mr-2 h-3.5 w-3.5", Zr = {
|
|
10924
10923
|
hint: "New row",
|
|
10925
10924
|
sticky: true,
|
|
10926
10925
|
tint: true
|
|
10927
|
-
},
|
|
10926
|
+
}, Y = e.length > 1e5, Qr = c === "all";
|
|
10928
10927
|
return (0, import_jsx_runtime.jsxs)("div", {
|
|
10929
10928
|
className: "relative w-full min-w-0",
|
|
10930
10929
|
children: [
|
|
10931
10930
|
(0, import_jsx_runtime.jsx)(ErrorBoundary, {
|
|
10932
10931
|
children: (0, import_jsx_runtime.jsx)(DataEditorAll, {
|
|
10933
|
-
ref:
|
|
10934
|
-
getCellContent:
|
|
10935
|
-
columns:
|
|
10936
|
-
gridSelection:
|
|
10937
|
-
onGridSelectionChange:
|
|
10932
|
+
ref: k,
|
|
10933
|
+
getCellContent: zr,
|
|
10934
|
+
columns: W,
|
|
10935
|
+
gridSelection: L,
|
|
10936
|
+
onGridSelectionChange: Pr,
|
|
10938
10937
|
rows: e.length,
|
|
10939
10938
|
overscrollX: 50,
|
|
10940
|
-
smoothScrollX: !
|
|
10941
|
-
smoothScrollY: !
|
|
10942
|
-
validateCell:
|
|
10939
|
+
smoothScrollX: !Y,
|
|
10940
|
+
smoothScrollY: !Y,
|
|
10941
|
+
validateCell: Br,
|
|
10943
10942
|
getCellsForSelection: true,
|
|
10944
10943
|
onPaste: true,
|
|
10945
|
-
showSearch:
|
|
10944
|
+
showSearch: M,
|
|
10946
10945
|
fillHandle: true,
|
|
10947
10946
|
allowedFillDirections: "vertical",
|
|
10948
|
-
onKeyDown:
|
|
10947
|
+
onKeyDown: Vr,
|
|
10949
10948
|
height: e.length > 10 ? 450 : void 0,
|
|
10950
10949
|
width: "100%",
|
|
10951
10950
|
rowMarkers: {
|
|
10952
10951
|
kind: "both"
|
|
10953
10952
|
},
|
|
10954
10953
|
rowSelectionMode: "multi",
|
|
10955
|
-
onCellEdited:
|
|
10956
|
-
onColumnResize:
|
|
10957
|
-
onHeaderMenuClick:
|
|
10958
|
-
theme: getGlideTheme(
|
|
10959
|
-
trailingRowOptions:
|
|
10960
|
-
onRowAppended:
|
|
10954
|
+
onCellEdited: G,
|
|
10955
|
+
onColumnResize: K,
|
|
10956
|
+
onHeaderMenuClick: Wr,
|
|
10957
|
+
theme: getGlideTheme(O),
|
|
10958
|
+
trailingRowOptions: Zr,
|
|
10959
|
+
onRowAppended: Hr,
|
|
10961
10960
|
maxColumnAutoWidth: 600,
|
|
10962
10961
|
maxColumnWidth: 600
|
|
10963
10962
|
})
|
|
10964
10963
|
}),
|
|
10965
10964
|
(() => {
|
|
10966
|
-
if (!
|
|
10965
|
+
if (!Xr) return;
|
|
10967
10966
|
let e2 = (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, {
|
|
10968
10967
|
children: [
|
|
10969
|
-
|
|
10970
|
-
currentColumnName:
|
|
10971
|
-
onRename:
|
|
10972
|
-
onCancel: () =>
|
|
10968
|
+
Qr && (0, import_jsx_runtime.jsx)(RenameColumnSub, {
|
|
10969
|
+
currentColumnName: W[A.col].title,
|
|
10970
|
+
onRename: qr,
|
|
10971
|
+
onCancel: () => j(void 0)
|
|
10973
10972
|
}),
|
|
10974
10973
|
(0, import_jsx_runtime.jsx)(DropdownMenuSeparator, {}),
|
|
10975
10974
|
(0, import_jsx_runtime.jsx)(AddColumnSub, {
|
|
10976
10975
|
direction: "left",
|
|
10977
|
-
onAdd: (e3, t2) =>
|
|
10976
|
+
onAdd: (e3, t2) => Jr({
|
|
10978
10977
|
direction: "left",
|
|
10979
10978
|
columnName: e3,
|
|
10980
10979
|
dataType: t2
|
|
10981
10980
|
}),
|
|
10982
|
-
onCancel: () =>
|
|
10981
|
+
onCancel: () => j(void 0)
|
|
10983
10982
|
}),
|
|
10984
10983
|
(0, import_jsx_runtime.jsx)(AddColumnSub, {
|
|
10985
10984
|
direction: "right",
|
|
10986
|
-
onAdd: (e3, t2) =>
|
|
10985
|
+
onAdd: (e3, t2) => Jr({
|
|
10987
10986
|
direction: "right",
|
|
10988
10987
|
columnName: e3,
|
|
10989
10988
|
dataType: t2
|
|
10990
10989
|
}),
|
|
10991
|
-
onCancel: () =>
|
|
10990
|
+
onCancel: () => j(void 0)
|
|
10992
10991
|
}),
|
|
10993
10992
|
(0, import_jsx_runtime.jsx)(DropdownMenuSeparator, {}),
|
|
10994
|
-
!
|
|
10995
|
-
onClick:
|
|
10993
|
+
!Yr && Qr && (0, import_jsx_runtime.jsxs)(DropdownMenuItem, {
|
|
10994
|
+
onClick: q,
|
|
10996
10995
|
className: "text-destructive focus:text-destructive",
|
|
10997
10996
|
children: [
|
|
10998
10997
|
(0, import_jsx_runtime.jsx)(Trash, {
|
|
10999
|
-
className:
|
|
10998
|
+
className: J
|
|
11000
10999
|
}),
|
|
11001
11000
|
"Delete column"
|
|
11002
11001
|
]
|
|
@@ -11004,25 +11003,25 @@ let __tla = (async () => {
|
|
|
11004
11003
|
]
|
|
11005
11004
|
});
|
|
11006
11005
|
return (0, import_jsx_runtime.jsx)(DropdownMenu, {
|
|
11007
|
-
open:
|
|
11008
|
-
onOpenChange: (e3) => !e3 &&
|
|
11006
|
+
open: Xr,
|
|
11007
|
+
onOpenChange: (e3) => !e3 && j(void 0),
|
|
11009
11008
|
children: (0, import_jsx_runtime.jsxs)(DropdownMenuContent, {
|
|
11010
11009
|
style: {
|
|
11011
|
-
left: (
|
|
11012
|
-
top: ((
|
|
11010
|
+
left: (A == null ? void 0 : A.bounds.x) ?? 0,
|
|
11011
|
+
top: ((A == null ? void 0 : A.bounds.y) ?? 0) + ((A == null ? void 0 : A.bounds.height) ?? 0)
|
|
11013
11012
|
},
|
|
11014
11013
|
className: "fixed w-52",
|
|
11015
11014
|
children: [
|
|
11016
11015
|
(0, import_jsx_runtime.jsxs)(DropdownMenuItem, {
|
|
11017
|
-
onClick:
|
|
11016
|
+
onClick: Gr,
|
|
11018
11017
|
children: [
|
|
11019
11018
|
(0, import_jsx_runtime.jsx)(Copy, {
|
|
11020
|
-
className:
|
|
11019
|
+
className: J
|
|
11021
11020
|
}),
|
|
11022
11021
|
"Copy column name"
|
|
11023
11022
|
]
|
|
11024
11023
|
}),
|
|
11025
|
-
!
|
|
11024
|
+
!Y && e2
|
|
11026
11025
|
]
|
|
11027
11026
|
})
|
|
11028
11027
|
});
|
|
@@ -11032,10 +11031,10 @@ let __tla = (async () => {
|
|
|
11032
11031
|
children: (0, import_jsx_runtime.jsx)(Button, {
|
|
11033
11032
|
variant: "destructive",
|
|
11034
11033
|
size: "sm",
|
|
11035
|
-
disabled:
|
|
11034
|
+
disabled: L.rows.length === 0,
|
|
11036
11035
|
className: "right-2 h-7",
|
|
11037
|
-
onClick:
|
|
11038
|
-
children:
|
|
11036
|
+
onClick: Ur,
|
|
11037
|
+
children: L.rows.length <= 1 ? "Delete row" : "Delete rows"
|
|
11039
11038
|
})
|
|
11040
11039
|
})
|
|
11041
11040
|
]
|