@expcat/tigercat-react 1.5.0 → 2.0.0-preview.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-SRC7JHME.mjs → chunk-25D5TXZH.mjs} +3 -3
- package/dist/{chunk-QKNORS26.mjs → chunk-2GSXSLGC.mjs} +25 -10
- package/dist/{chunk-GA4YOE57.mjs → chunk-2PZICT2T.mjs} +6 -6
- package/dist/{chunk-H7D7UBDC.mjs → chunk-2UFTDDPW.mjs} +1 -1
- package/dist/{chunk-MV54EEKO.mjs → chunk-2UOGBS3C.mjs} +1 -1
- package/dist/{chunk-TBMDIAZI.mjs → chunk-2YDLAZTK.mjs} +9 -9
- package/dist/chunk-3O3AQLNS.mjs +172 -0
- package/dist/{chunk-VAIWWELW.mjs → chunk-3OBUJIJI.mjs} +23 -10
- package/dist/{chunk-PTMVWEIC.mjs → chunk-4XGO3OSE.mjs} +4 -3
- package/dist/{chunk-LACDTZTE.mjs → chunk-533KLM7P.mjs} +1 -1
- package/dist/{chunk-HWZSMV2M.mjs → chunk-7PP6RECM.mjs} +2 -2
- package/dist/{chunk-PQOUWJAT.mjs → chunk-7S4TP4MZ.mjs} +1 -1
- package/dist/{chunk-NEHSCSQP.mjs → chunk-7TVZTASQ.mjs} +9 -9
- package/dist/{chunk-CSJGNEHR.mjs → chunk-AF3N4GJJ.mjs} +6 -6
- package/dist/{chunk-4MONGWU5.mjs → chunk-AKNWUI7K.mjs} +1 -1
- package/dist/{chunk-GOUSXJEY.mjs → chunk-AMEH5EHB.mjs} +3 -3
- package/dist/{chunk-PZB24FST.mjs → chunk-B3O6MAC3.mjs} +1 -1
- package/dist/chunk-BBK37UMR.mjs +134 -0
- package/dist/chunk-BPFKTAF2.mjs +49 -0
- package/dist/chunk-BPQEM6AF.mjs +110 -0
- package/dist/{chunk-QFUIGOOM.mjs → chunk-BSXPB2V6.mjs} +6 -6
- package/dist/{chunk-QOEE2PW5.mjs → chunk-D524E52A.mjs} +37 -22
- package/dist/{chunk-AQOXANET.mjs → chunk-EKILTLUO.mjs} +6 -6
- package/dist/{chunk-6BOSSZM3.mjs → chunk-EPWAROC2.mjs} +2 -2
- package/dist/chunk-FNBTGIDG.mjs +52 -0
- package/dist/{chunk-TRXNHYWB.mjs → chunk-G27UYCLT.mjs} +7 -15
- package/dist/{chunk-WGKNAOW7.mjs → chunk-G7D4QV7A.mjs} +16 -2
- package/dist/{chunk-AI4V7L6K.mjs → chunk-GFLKO46C.mjs} +50 -18
- package/dist/{chunk-BRPOEVRT.mjs → chunk-I3SE5HMH.mjs} +8 -8
- package/dist/{chunk-3RBRWBUG.mjs → chunk-IIWUQK2P.mjs} +2 -2
- package/dist/{chunk-4DRJA5ZK.mjs → chunk-J4HCTYJG.mjs} +3 -3
- package/dist/chunk-JNZHZVPW.mjs +143 -0
- package/dist/{chunk-LUABLBKS.mjs → chunk-JSBWEK6D.mjs} +49 -26
- package/dist/{chunk-DO3MVZZN.mjs → chunk-K6JLLCY7.mjs} +5 -5
- package/dist/{chunk-2L7QEOFD.mjs → chunk-KWVA2DN3.mjs} +1 -1
- package/dist/{chunk-WT72F56O.mjs → chunk-LJWQ7T57.mjs} +19 -2
- package/dist/{chunk-4MREOFVE.mjs → chunk-MMWF2OPA.mjs} +28 -19
- package/dist/{chunk-S4NGDDAM.mjs → chunk-MQ34GFHN.mjs} +5 -8
- package/dist/{chunk-DEQZZKY5.mjs → chunk-NRWH5IWZ.mjs} +1 -1
- package/dist/{chunk-FUE7IBTJ.mjs → chunk-OGG2TQDG.mjs} +4 -4
- package/dist/{chunk-MV2JQ6XQ.mjs → chunk-OL3RXYMG.mjs} +1 -1
- package/dist/{chunk-D7UR526A.mjs → chunk-Q327ESD2.mjs} +9 -5
- package/dist/{chunk-4V5RL25M.mjs → chunk-Q5JTIICP.mjs} +20 -3
- package/dist/{chunk-RYHM75MP.mjs → chunk-QWUDJC6K.mjs} +1 -1
- package/dist/{chunk-IXAPFTTD.mjs → chunk-R67HTROL.mjs} +2 -2
- package/dist/{chunk-ATSI3UKS.mjs → chunk-RCUL6RZU.mjs} +1 -1
- package/dist/{chunk-C44WSDEY.mjs → chunk-S7IB6YST.mjs} +2 -1
- package/dist/{chunk-WYPTAUCX.mjs → chunk-SHJNDDYK.mjs} +1 -1
- package/dist/{chunk-WOEX4S6J.mjs → chunk-SNE3E22Q.mjs} +9 -9
- package/dist/{chunk-SI3P3V75.mjs → chunk-TJDZFN2Z.mjs} +8 -9
- package/dist/{chunk-D4X3NBAI.mjs → chunk-UYJJLHVA.mjs} +1 -1
- package/dist/{chunk-4HMMH4XS.mjs → chunk-VBGJQPPI.mjs} +1 -1
- package/dist/{chunk-WTSG7QXK.mjs → chunk-VKIGZWRK.mjs} +10 -10
- package/dist/{chunk-P2WQIVXD.mjs → chunk-WKTIDYPD.mjs} +60 -6
- package/dist/{chunk-QANWBRNU.mjs → chunk-XHNR3A7A.mjs} +9 -9
- package/dist/{chunk-ZLP4XEAO.mjs → chunk-XSAKD4MX.mjs} +31 -14
- package/dist/{chunk-NITD53UU.mjs → chunk-YI7NQWUV.mjs} +38 -0
- package/dist/{chunk-O6YIPNXX.mjs → chunk-YORCCCQX.mjs} +5 -5
- package/dist/{chunk-W6T3CG7U.mjs → chunk-YTFQBXH4.mjs} +31 -13
- package/dist/{chunk-SYVMCKPR.mjs → chunk-Z2NZ2XC5.mjs} +5 -5
- package/dist/{chunk-GTDLZF7K.mjs → chunk-ZFGSZW7S.mjs} +6 -6
- package/dist/components/ActivityFeed.mjs +3 -3
- package/dist/components/Anchor.d.mts +1 -1
- package/dist/components/AreaChart.d.mts +4 -4
- package/dist/components/AreaChart.mjs +5 -5
- package/dist/components/AutoComplete.d.mts +1 -1
- package/dist/components/AutoComplete.mjs +1 -1
- package/dist/components/BackTop.mjs +1 -1
- package/dist/components/BarChart.mjs +5 -5
- package/dist/components/Carousel.d.mts +12 -0
- package/dist/components/Carousel.mjs +2 -1
- package/dist/components/Cascader.d.mts +2 -0
- package/dist/components/Cascader.mjs +1 -1
- package/dist/components/ChartTooltip.d.mts +1 -1
- package/dist/components/ChartTooltip.mjs +1 -1
- package/dist/components/ChatWindow.mjs +5 -5
- package/dist/components/Checkbox.d.mts +2 -2
- package/dist/components/Checkbox.mjs +3 -3
- package/dist/components/CheckboxGroup.d.mts +3 -3
- package/dist/components/CheckboxGroup.mjs +2 -2
- package/dist/components/CommentThread.mjs +4 -4
- package/dist/components/CropUpload.mjs +2 -2
- package/dist/components/DataTableWithToolbar.d.mts +5 -19
- package/dist/components/DataTableWithToolbar.mjs +11 -11
- package/dist/components/DatePicker.d.mts +9 -6
- package/dist/components/DatePicker.mjs +2 -2
- package/dist/components/Descriptions.d.mts +2 -2
- package/dist/components/DonutChart.d.mts +4 -4
- package/dist/components/DonutChart.mjs +5 -5
- package/dist/components/Drawer.d.mts +1 -1
- package/dist/components/Drawer.mjs +1 -1
- package/dist/components/Dropdown.d.mts +14 -2
- package/dist/components/Dropdown.mjs +3 -1
- package/dist/components/FloatButton.mjs +1 -1
- package/dist/components/Form.d.mts +2 -2
- package/dist/components/FunnelChart.mjs +4 -4
- package/dist/components/GaugeChart.mjs +2 -2
- package/dist/components/HeatmapChart.mjs +3 -3
- package/dist/components/Image.mjs +4 -4
- package/dist/components/ImageGroup.d.mts +2 -2
- package/dist/components/ImageGroup.mjs +2 -2
- package/dist/components/ImagePreview.mjs +1 -1
- package/dist/components/ImageViewer.d.mts +2 -14
- package/dist/components/Input.mjs +2 -2
- package/dist/components/InputGroup.d.mts +3 -3
- package/dist/components/InputNumber.mjs +2 -2
- package/dist/components/LineChart.mjs +5 -5
- package/dist/components/List.d.mts +2 -2
- package/dist/components/MarkdownEditor.mjs +2 -2
- package/dist/components/Menu.d.mts +92 -7
- package/dist/components/Menu.mjs +1 -1
- package/dist/components/Message.d.mts +4 -18
- package/dist/components/Message.mjs +162 -4
- package/dist/components/MessageContainer.d.mts +11 -0
- package/dist/components/MessageContainer.mjs +9 -0
- package/dist/components/MessageRoot.d.mts +9 -0
- package/dist/components/MessageRoot.mjs +6 -0
- package/dist/components/Modal.d.mts +4 -0
- package/dist/components/Modal.mjs +1 -1
- package/dist/components/Notification.d.mts +4 -17
- package/dist/components/Notification.mjs +188 -4
- package/dist/components/NotificationCenter.mjs +2 -2
- package/dist/components/NotificationContainer.d.mts +11 -0
- package/dist/components/NotificationContainer.mjs +9 -0
- package/dist/components/NotificationRoot.d.mts +9 -0
- package/dist/components/NotificationRoot.mjs +6 -0
- package/dist/components/PieChart.mjs +4 -4
- package/dist/components/Popconfirm.mjs +2 -2
- package/dist/components/Popover.mjs +2 -2
- package/dist/components/RadarChart.mjs +4 -4
- package/dist/components/Radio.mjs +3 -3
- package/dist/components/RadioGroup.d.mts +2 -2
- package/dist/components/RadioGroup.mjs +2 -2
- package/dist/components/RichTextEditor.mjs +2 -2
- package/dist/components/ScatterChart.mjs +5 -5
- package/dist/components/ScrollSpy.d.mts +1 -1
- package/dist/components/ScrollSpy.mjs +1 -1
- package/dist/components/Select.d.mts +1 -1
- package/dist/components/Select.mjs +1 -1
- package/dist/components/Spotlight.mjs +2 -2
- package/dist/components/SunburstChart.mjs +4 -4
- package/dist/components/Table.d.mts +1 -1
- package/dist/components/Table.mjs +7 -7
- package/dist/components/Tabs.d.mts +2 -2
- package/dist/components/Tabs.mjs +1 -1
- package/dist/components/Textarea.mjs +2 -2
- package/dist/components/TimePicker.d.mts +10 -9
- package/dist/components/TimePicker.mjs +2 -2
- package/dist/components/Tooltip.mjs +2 -2
- package/dist/components/Transfer.d.mts +3 -1
- package/dist/components/Transfer.mjs +1 -1
- package/dist/components/Tree.d.mts +12 -0
- package/dist/components/Tree.mjs +1 -1
- package/dist/components/TreeMapChart.mjs +4 -4
- package/dist/components/TreeSelect.d.mts +2 -0
- package/dist/components/TreeSelect.mjs +1 -1
- package/dist/components/Upload.mjs +2 -2
- package/dist/components/VirtualTable.d.mts +7 -8
- package/dist/components/VirtualTable.mjs +1 -1
- package/dist/hooks/useChartInteraction.d.mts +85 -0
- package/dist/hooks/useChartInteraction.mjs +6 -0
- package/dist/hooks/useControlledState.d.mts +33 -0
- package/dist/hooks/useControlledState.mjs +6 -0
- package/dist/hooks/useDrag.d.mts +39 -0
- package/dist/hooks/useDrag.mjs +6 -0
- package/dist/hooks/useFormController.d.mts +24 -0
- package/dist/hooks/useFormController.mjs +6 -0
- package/dist/index.d.mts +12 -183
- package/dist/index.mjs +2154 -896
- package/package.json +743 -13
- package/dist/chunk-23XPDNCA.js +0 -97
- package/dist/chunk-24NDLFPK.js +0 -468
- package/dist/chunk-2LKX6CE7.js +0 -376
- package/dist/chunk-2PV3F47T.js +0 -65
- package/dist/chunk-2WDCWFOM.js +0 -246
- package/dist/chunk-2ZA4MUO2.js +0 -486
- package/dist/chunk-3NVMKDMH.js +0 -174
- package/dist/chunk-3QFHVAZT.js +0 -72
- package/dist/chunk-3RQ3FHJ7.js +0 -632
- package/dist/chunk-4DTMFQCY.js +0 -167
- package/dist/chunk-4MQCUKIC.js +0 -80
- package/dist/chunk-4PPTEEDI.js +0 -81
- package/dist/chunk-4TEILQSN.js +0 -58
- package/dist/chunk-4TPRBVW7.js +0 -129
- package/dist/chunk-5ALMTE35.js +0 -109
- package/dist/chunk-5JYVN65W.js +0 -85
- package/dist/chunk-5QLSTNA3.js +0 -148
- package/dist/chunk-5UREMEDS.js +0 -463
- package/dist/chunk-6CWZXS5B.js +0 -152
- package/dist/chunk-6HDMUF23.js +0 -22
- package/dist/chunk-6LGCAGNG.js +0 -312
- package/dist/chunk-6OMCHC6W.js +0 -224
- package/dist/chunk-6S5QOTXZ.js +0 -72
- package/dist/chunk-6SG2N4WF.js +0 -443
- package/dist/chunk-7UZ7O7KX.js +0 -594
- package/dist/chunk-7YI5TAPT.js +0 -166
- package/dist/chunk-AX5XRD2Q.js +0 -36
- package/dist/chunk-B3CRHKTZ.mjs +0 -50
- package/dist/chunk-B5TUTAVX.js +0 -321
- package/dist/chunk-BR3WLDH7.js +0 -68
- package/dist/chunk-C5BPHZXK.js +0 -77
- package/dist/chunk-CHPJPIW6.js +0 -93
- package/dist/chunk-CXXOZLP4.js +0 -340
- package/dist/chunk-D6TKXVEB.js +0 -14
- package/dist/chunk-DBMC6FPU.js +0 -270
- package/dist/chunk-DEIVWO2D.mjs +0 -285
- package/dist/chunk-DH4B2COV.js +0 -1649
- package/dist/chunk-E355NVP7.mjs +0 -261
- package/dist/chunk-E5GD3H7L.js +0 -100
- package/dist/chunk-ENJMHEQU.js +0 -232
- package/dist/chunk-FBFCJCON.js +0 -129
- package/dist/chunk-FBIBHTBG.js +0 -497
- package/dist/chunk-FCCHM2B4.js +0 -115
- package/dist/chunk-FFDK6PEP.js +0 -91
- package/dist/chunk-FJDTVJTX.js +0 -19
- package/dist/chunk-FQO7BKXW.js +0 -65
- package/dist/chunk-FZHBVHQ6.js +0 -280
- package/dist/chunk-GADCSCH2.js +0 -177
- package/dist/chunk-GPAY5F7D.js +0 -98
- package/dist/chunk-HFGTJEQW.js +0 -702
- package/dist/chunk-HQ3QOT7H.js +0 -38
- package/dist/chunk-HVAG26CK.js +0 -252
- package/dist/chunk-I3CDTF4U.js +0 -48
- package/dist/chunk-I5UB4FN3.js +0 -337
- package/dist/chunk-I6VHGILW.js +0 -362
- package/dist/chunk-I7OSNH5T.js +0 -676
- package/dist/chunk-IFB3OECJ.js +0 -109
- package/dist/chunk-IZXU7DF6.js +0 -46
- package/dist/chunk-J4SNBXJM.js +0 -127
- package/dist/chunk-JB33A4S6.js +0 -136
- package/dist/chunk-JHRFG5PG.js +0 -412
- package/dist/chunk-JIFSUUGA.js +0 -120
- package/dist/chunk-KSXGH3FO.js +0 -305
- package/dist/chunk-KVWSVDAJ.js +0 -239
- package/dist/chunk-L3WPA2RP.js +0 -25
- package/dist/chunk-LJRCEB7F.js +0 -718
- package/dist/chunk-LODDAS62.js +0 -188
- package/dist/chunk-LZG24TDB.js +0 -73
- package/dist/chunk-M577W3TS.js +0 -211
- package/dist/chunk-MB3QU3US.js +0 -119
- package/dist/chunk-MOYZF62V.js +0 -303
- package/dist/chunk-MQIVMK24.js +0 -226
- package/dist/chunk-NG3OBMKV.js +0 -319
- package/dist/chunk-NGSJGXUZ.js +0 -411
- package/dist/chunk-NRLGZRK2.js +0 -227
- package/dist/chunk-O2N7ITWQ.js +0 -556
- package/dist/chunk-OBY4FYRZ.js +0 -64
- package/dist/chunk-OVJO5NYW.js +0 -230
- package/dist/chunk-PHAJXRGE.js +0 -285
- package/dist/chunk-PQF5VLNX.js +0 -351
- package/dist/chunk-PSCPLUGP.js +0 -366
- package/dist/chunk-PTEDJ6MA.js +0 -31
- package/dist/chunk-PZNVU37I.js +0 -50
- package/dist/chunk-PZWI4YNN.js +0 -325
- package/dist/chunk-Q2GPRAF4.js +0 -70
- package/dist/chunk-Q2OXQNWU.js +0 -213
- package/dist/chunk-Q4JMAQXJ.js +0 -46
- package/dist/chunk-QLATA4UB.js +0 -82
- package/dist/chunk-QMK4OFC5.js +0 -235
- package/dist/chunk-QQKP437L.js +0 -52
- package/dist/chunk-QYYAXM5F.js +0 -80
- package/dist/chunk-R4PMBWU3.js +0 -28
- package/dist/chunk-R56UOY6C.js +0 -222
- package/dist/chunk-RNHC7BON.js +0 -230
- package/dist/chunk-RRO752KE.js +0 -246
- package/dist/chunk-RTHC4KWM.js +0 -55
- package/dist/chunk-RYIYE2PY.js +0 -139
- package/dist/chunk-SA3N2LUB.js +0 -255
- package/dist/chunk-SFBSI3J7.js +0 -188
- package/dist/chunk-SH4BZYXO.js +0 -120
- package/dist/chunk-SHU7L4NM.js +0 -118
- package/dist/chunk-SK7PXSVE.js +0 -83
- package/dist/chunk-SO2ADQTB.js +0 -250
- package/dist/chunk-SQGFNVYT.js +0 -234
- package/dist/chunk-SQONS5PH.js +0 -46
- package/dist/chunk-STTQ5LXX.js +0 -153
- package/dist/chunk-SXHCMZ6U.js +0 -303
- package/dist/chunk-SXTMVZ4W.js +0 -177
- package/dist/chunk-SYJJKI7U.js +0 -261
- package/dist/chunk-TB2UHDOZ.js +0 -21
- package/dist/chunk-TDODFBBO.js +0 -101
- package/dist/chunk-TIDVBSXR.js +0 -762
- package/dist/chunk-TLDTBCT6.js +0 -98
- package/dist/chunk-TN7GMDME.js +0 -102
- package/dist/chunk-TO4SSBAJ.js +0 -193
- package/dist/chunk-TPU6S7G7.js +0 -278
- package/dist/chunk-TQOWIDQT.js +0 -51
- package/dist/chunk-TVEO2CFD.js +0 -330
- package/dist/chunk-U3M24RPH.js +0 -85
- package/dist/chunk-UEAXYZSE.js +0 -134
- package/dist/chunk-UF3DXKCI.js +0 -30
- package/dist/chunk-UKLVOR4E.js +0 -72
- package/dist/chunk-UKQMF3JV.js +0 -217
- package/dist/chunk-UQZ4RLTI.js +0 -698
- package/dist/chunk-V3QEV3TL.js +0 -457
- package/dist/chunk-VDF2BD2A.js +0 -135
- package/dist/chunk-VE3SYUMH.js +0 -45
- package/dist/chunk-VNMWPJDN.js +0 -147
- package/dist/chunk-VOSN3IQC.js +0 -168
- package/dist/chunk-W3VLCSJL.js +0 -26
- package/dist/chunk-WLORVPTR.js +0 -366
- package/dist/chunk-WN3ZI7FN.js +0 -144
- package/dist/chunk-WOSKRZOO.js +0 -89
- package/dist/chunk-WTASPL6V.js +0 -322
- package/dist/chunk-WYKUC5MM.js +0 -333
- package/dist/chunk-XKMZ5AMS.js +0 -220
- package/dist/chunk-XMD7CQQ2.js +0 -317
- package/dist/chunk-XTV5JLLC.js +0 -170
- package/dist/chunk-YMKA4L3Z.js +0 -28
- package/dist/chunk-YWTZALG5.js +0 -32
- package/dist/chunk-ZDXIP33Y.js +0 -67
- package/dist/chunk-ZLCVJXGL.js +0 -232
- package/dist/chunk-ZLNBE4IS.js +0 -92
- package/dist/chunk-ZXVLZKLT.js +0 -51
- package/dist/components/ActivityFeed.d.ts +0 -10
- package/dist/components/ActivityFeed.js +0 -18
- package/dist/components/Affix.d.ts +0 -11
- package/dist/components/Affix.js +0 -6
- package/dist/components/Alert.d.ts +0 -25
- package/dist/components/Alert.js +0 -7
- package/dist/components/Anchor.d.ts +0 -57
- package/dist/components/Anchor.js +0 -12
- package/dist/components/AnchorLink.d.mts +0 -3
- package/dist/components/AnchorLink.d.ts +0 -3
- package/dist/components/AnchorLink.js +0 -7
- package/dist/components/AnchorLink.mjs +0 -7
- package/dist/components/AreaChart.d.ts +0 -24
- package/dist/components/AreaChart.js +0 -15
- package/dist/components/AutoComplete.d.ts +0 -16
- package/dist/components/AutoComplete.js +0 -7
- package/dist/components/Avatar.d.ts +0 -12
- package/dist/components/Avatar.js +0 -7
- package/dist/components/AvatarGroup.d.ts +0 -14
- package/dist/components/AvatarGroup.js +0 -8
- package/dist/components/BackTop.d.ts +0 -21
- package/dist/components/BackTop.js +0 -8
- package/dist/components/Badge.d.ts +0 -9
- package/dist/components/Badge.js +0 -7
- package/dist/components/BarChart.d.ts +0 -16
- package/dist/components/BarChart.js +0 -15
- package/dist/components/Breadcrumb.d.ts +0 -32
- package/dist/components/Breadcrumb.js +0 -10
- package/dist/components/BreadcrumbItem.d.mts +0 -3
- package/dist/components/BreadcrumbItem.d.ts +0 -3
- package/dist/components/BreadcrumbItem.js +0 -6
- package/dist/components/BreadcrumbItem.mjs +0 -6
- package/dist/components/Button.d.ts +0 -10
- package/dist/components/Button.js +0 -7
- package/dist/components/ButtonGroup.d.ts +0 -15
- package/dist/components/ButtonGroup.js +0 -10
- package/dist/components/Calendar.d.ts +0 -7
- package/dist/components/Calendar.js +0 -9
- package/dist/components/Card.d.ts +0 -33
- package/dist/components/Card.js +0 -6
- package/dist/components/Carousel.d.ts +0 -26
- package/dist/components/Carousel.js +0 -6
- package/dist/components/Cascader.d.ts +0 -17
- package/dist/components/Cascader.js +0 -7
- package/dist/components/ChartAxis.d.ts +0 -9
- package/dist/components/ChartAxis.js +0 -8
- package/dist/components/ChartCanvas.d.ts +0 -9
- package/dist/components/ChartCanvas.js +0 -8
- package/dist/components/ChartGrid.d.ts +0 -10
- package/dist/components/ChartGrid.js +0 -8
- package/dist/components/ChartLegend.d.ts +0 -17
- package/dist/components/ChartLegend.js +0 -8
- package/dist/components/ChartSeries.d.ts +0 -17
- package/dist/components/ChartSeries.js +0 -8
- package/dist/components/ChartTooltip.d.ts +0 -12
- package/dist/components/ChartTooltip.js +0 -8
- package/dist/components/ChatWindow.d.ts +0 -12
- package/dist/components/ChatWindow.js +0 -19
- package/dist/components/Checkbox.d.ts +0 -48
- package/dist/components/Checkbox.js +0 -8
- package/dist/components/CheckboxGroup.d.ts +0 -39
- package/dist/components/CheckboxGroup.js +0 -9
- package/dist/components/Code.d.ts +0 -9
- package/dist/components/Code.js +0 -8
- package/dist/components/CodeEditor.d.ts +0 -18
- package/dist/components/CodeEditor.js +0 -8
- package/dist/components/Col.d.ts +0 -7
- package/dist/components/Col.js +0 -7
- package/dist/components/Collapse.d.ts +0 -29
- package/dist/components/Collapse.js +0 -10
- package/dist/components/CollapsePanel.d.ts +0 -24
- package/dist/components/CollapsePanel.js +0 -9
- package/dist/components/ColorPicker.d.ts +0 -12
- package/dist/components/ColorPicker.js +0 -6
- package/dist/components/ColorSwatch.d.ts +0 -11
- package/dist/components/ColorSwatch.js +0 -8
- package/dist/components/CommentThread.d.ts +0 -8
- package/dist/components/CommentThread.js +0 -18
- package/dist/components/ConfigProvider.d.ts +0 -21
- package/dist/components/ConfigProvider.js +0 -8
- package/dist/components/Container.d.ts +0 -13
- package/dist/components/Container.js +0 -6
- package/dist/components/Content.d.ts +0 -9
- package/dist/components/Content.js +0 -6
- package/dist/components/Countdown.d.ts +0 -12
- package/dist/components/Countdown.js +0 -8
- package/dist/components/CronEditor.d.ts +0 -12
- package/dist/components/CronEditor.js +0 -8
- package/dist/components/CropUpload.d.ts +0 -56
- package/dist/components/CropUpload.js +0 -12
- package/dist/components/DataTableWithToolbar.d.ts +0 -64
- package/dist/components/DataTableWithToolbar.js +0 -24
- package/dist/components/DatePicker.d.ts +0 -25
- package/dist/components/DatePicker.js +0 -8
- package/dist/components/Descriptions.d.ts +0 -53
- package/dist/components/Descriptions.js +0 -8
- package/dist/components/Divider.d.ts +0 -10
- package/dist/components/Divider.js +0 -6
- package/dist/components/DonutChart.d.ts +0 -20
- package/dist/components/DonutChart.js +0 -13
- package/dist/components/Drawer.d.ts +0 -21
- package/dist/components/Drawer.js +0 -8
- package/dist/components/Dropdown.d.ts +0 -35
- package/dist/components/Dropdown.js +0 -11
- package/dist/components/DropdownItem.d.mts +0 -17
- package/dist/components/DropdownItem.d.ts +0 -17
- package/dist/components/DropdownItem.js +0 -8
- package/dist/components/DropdownItem.mjs +0 -8
- package/dist/components/DropdownMenu.d.mts +0 -3
- package/dist/components/DropdownMenu.d.ts +0 -3
- package/dist/components/DropdownMenu.js +0 -8
- package/dist/components/DropdownMenu.mjs +0 -8
- package/dist/components/Empty.d.ts +0 -14
- package/dist/components/Empty.js +0 -7
- package/dist/components/FileManager.d.ts +0 -10
- package/dist/components/FileManager.js +0 -9
- package/dist/components/FloatButton.d.ts +0 -21
- package/dist/components/FloatButton.js +0 -8
- package/dist/components/Footer.d.ts +0 -9
- package/dist/components/Footer.js +0 -6
- package/dist/components/Form.d.ts +0 -92
- package/dist/components/Form.js +0 -9
- package/dist/components/FormItem.d.ts +0 -16
- package/dist/components/FormItem.js +0 -8
- package/dist/components/FormWizard.d.ts +0 -10
- package/dist/components/FormWizard.js +0 -12
- package/dist/components/FunnelChart.d.ts +0 -15
- package/dist/components/FunnelChart.js +0 -10
- package/dist/components/Gantt.d.ts +0 -16
- package/dist/components/Gantt.js +0 -7
- package/dist/components/GaugeChart.d.ts +0 -9
- package/dist/components/GaugeChart.js +0 -8
- package/dist/components/Header.d.ts +0 -9
- package/dist/components/Header.js +0 -6
- package/dist/components/HeatmapChart.d.ts +0 -13
- package/dist/components/HeatmapChart.js +0 -9
- package/dist/components/Icon.d.ts +0 -9
- package/dist/components/Icon.js +0 -6
- package/dist/components/Image.d.ts +0 -20
- package/dist/components/Image.js +0 -11
- package/dist/components/ImageAnnotation.d.ts +0 -19
- package/dist/components/ImageAnnotation.js +0 -7
- package/dist/components/ImageCropper.d.ts +0 -21
- package/dist/components/ImageCropper.js +0 -7
- package/dist/components/ImageGroup.d.ts +0 -30
- package/dist/components/ImageGroup.js +0 -11
- package/dist/components/ImagePreview.d.ts +0 -21
- package/dist/components/ImagePreview.js +0 -8
- package/dist/components/ImageViewer.d.ts +0 -23
- package/dist/components/ImageViewer.js +0 -7
- package/dist/components/InfiniteScroll.d.ts +0 -22
- package/dist/components/InfiniteScroll.js +0 -9
- package/dist/components/Input.d.ts +0 -46
- package/dist/components/Input.js +0 -8
- package/dist/components/InputGroup.d.ts +0 -20
- package/dist/components/InputGroup.js +0 -12
- package/dist/components/InputNumber.d.ts +0 -24
- package/dist/components/InputNumber.js +0 -8
- package/dist/components/Kanban.d.ts +0 -51
- package/dist/components/Kanban.js +0 -10
- package/dist/components/Layout.d.ts +0 -9
- package/dist/components/Layout.js +0 -6
- package/dist/components/LineChart.d.ts +0 -19
- package/dist/components/LineChart.js +0 -15
- package/dist/components/Link.d.ts +0 -10
- package/dist/components/Link.js +0 -6
- package/dist/components/List.d.ts +0 -126
- package/dist/components/List.js +0 -8
- package/dist/components/Loading.d.ts +0 -8
- package/dist/components/Loading.js +0 -8
- package/dist/components/MarkdownEditor.d.ts +0 -21
- package/dist/components/MarkdownEditor.js +0 -9
- package/dist/components/Mentions.d.ts +0 -18
- package/dist/components/Mentions.js +0 -8
- package/dist/components/Menu.d.ts +0 -13
- package/dist/components/Menu.js +0 -15
- package/dist/components/MenuItem.d.mts +0 -7
- package/dist/components/MenuItem.d.ts +0 -7
- package/dist/components/MenuItem.js +0 -8
- package/dist/components/MenuItem.mjs +0 -8
- package/dist/components/MenuItemGroup.d.mts +0 -7
- package/dist/components/MenuItemGroup.d.ts +0 -7
- package/dist/components/MenuItemGroup.js +0 -8
- package/dist/components/MenuItemGroup.mjs +0 -8
- package/dist/components/Message.d.ts +0 -29
- package/dist/components/Message.js +0 -11
- package/dist/components/Modal.d.ts +0 -56
- package/dist/components/Modal.js +0 -10
- package/dist/components/Notification.d.ts +0 -27
- package/dist/components/Notification.js +0 -11
- package/dist/components/NotificationCenter.d.ts +0 -8
- package/dist/components/NotificationCenter.js +0 -18
- package/dist/components/NumberKeyboard.d.ts +0 -13
- package/dist/components/NumberKeyboard.js +0 -9
- package/dist/components/OrgChart.d.ts +0 -16
- package/dist/components/OrgChart.js +0 -7
- package/dist/components/Pagination.d.ts +0 -15
- package/dist/components/Pagination.js +0 -9
- package/dist/components/PieChart.d.ts +0 -14
- package/dist/components/PieChart.js +0 -12
- package/dist/components/Popconfirm.d.ts +0 -24
- package/dist/components/Popconfirm.js +0 -8
- package/dist/components/Popover.d.ts +0 -22
- package/dist/components/Popover.js +0 -8
- package/dist/components/PrintLayout.d.ts +0 -22
- package/dist/components/PrintLayout.js +0 -8
- package/dist/components/Progress.d.ts +0 -8
- package/dist/components/Progress.js +0 -6
- package/dist/components/QRCode.d.ts +0 -17
- package/dist/components/QRCode.js +0 -9
- package/dist/components/RadarChart.d.ts +0 -31
- package/dist/components/RadarChart.js +0 -13
- package/dist/components/Radio.d.ts +0 -20
- package/dist/components/Radio.js +0 -8
- package/dist/components/RadioGroup.d.ts +0 -28
- package/dist/components/RadioGroup.js +0 -9
- package/dist/components/Rate.d.ts +0 -14
- package/dist/components/Rate.js +0 -6
- package/dist/components/Resizable.d.ts +0 -13
- package/dist/components/Resizable.js +0 -8
- package/dist/components/Result.d.ts +0 -14
- package/dist/components/Result.js +0 -7
- package/dist/components/RichTextEditor.d.ts +0 -33
- package/dist/components/RichTextEditor.js +0 -9
- package/dist/components/Row.d.ts +0 -11
- package/dist/components/Row.js +0 -8
- package/dist/components/ScatterChart.d.ts +0 -32
- package/dist/components/ScatterChart.js +0 -15
- package/dist/components/ScrollSpy.d.ts +0 -13
- package/dist/components/ScrollSpy.js +0 -8
- package/dist/components/Segmented.d.ts +0 -12
- package/dist/components/Segmented.js +0 -6
- package/dist/components/Select.d.ts +0 -26
- package/dist/components/Select.js +0 -7
- package/dist/components/Sidebar.d.ts +0 -9
- package/dist/components/Sidebar.js +0 -6
- package/dist/components/Signature.d.ts +0 -18
- package/dist/components/Signature.js +0 -9
- package/dist/components/Skeleton.d.ts +0 -7
- package/dist/components/Skeleton.js +0 -6
- package/dist/components/Slider.d.ts +0 -12
- package/dist/components/Slider.js +0 -6
- package/dist/components/Space.d.ts +0 -11
- package/dist/components/Space.js +0 -6
- package/dist/components/Splitter.d.ts +0 -18
- package/dist/components/Splitter.js +0 -8
- package/dist/components/Spotlight.d.ts +0 -11
- package/dist/components/Spotlight.js +0 -11
- package/dist/components/Statistic.d.ts +0 -8
- package/dist/components/Statistic.js +0 -6
- package/dist/components/Stepper.d.ts +0 -12
- package/dist/components/Stepper.js +0 -6
- package/dist/components/Steps.d.ts +0 -62
- package/dist/components/Steps.js +0 -10
- package/dist/components/StepsItem.d.mts +0 -3
- package/dist/components/StepsItem.d.ts +0 -3
- package/dist/components/StepsItem.js +0 -6
- package/dist/components/StepsItem.mjs +0 -6
- package/dist/components/SubMenu.d.mts +0 -7
- package/dist/components/SubMenu.d.ts +0 -7
- package/dist/components/SubMenu.js +0 -8
- package/dist/components/SubMenu.mjs +0 -8
- package/dist/components/SunburstChart.d.ts +0 -15
- package/dist/components/SunburstChart.js +0 -10
- package/dist/components/Switch.d.ts +0 -12
- package/dist/components/Switch.js +0 -6
- package/dist/components/TabPane.d.mts +0 -3
- package/dist/components/TabPane.d.ts +0 -3
- package/dist/components/TabPane.js +0 -6
- package/dist/components/TabPane.mjs +0 -6
- package/dist/components/Table.d.ts +0 -7
- package/dist/components/Table.js +0 -14
- package/dist/components/Tabs.d.ts +0 -147
- package/dist/components/Tabs.js +0 -10
- package/dist/components/Tag.d.ts +0 -16
- package/dist/components/Tag.js +0 -7
- package/dist/components/TaskBoard.d.ts +0 -15
- package/dist/components/TaskBoard.js +0 -9
- package/dist/components/Text.d.ts +0 -9
- package/dist/components/Text.js +0 -6
- package/dist/components/Textarea.d.ts +0 -13
- package/dist/components/Textarea.js +0 -8
- package/dist/components/TimePicker.d.ts +0 -29
- package/dist/components/TimePicker.js +0 -8
- package/dist/components/Timeline.d.ts +0 -51
- package/dist/components/Timeline.js +0 -7
- package/dist/components/Tooltip.d.ts +0 -15
- package/dist/components/Tooltip.js +0 -8
- package/dist/components/Tour.d.ts +0 -16
- package/dist/components/Tour.js +0 -9
- package/dist/components/Transfer.d.ts +0 -14
- package/dist/components/Transfer.js +0 -7
- package/dist/components/Tree.d.ts +0 -193
- package/dist/components/Tree.js +0 -10
- package/dist/components/TreeMapChart.d.ts +0 -15
- package/dist/components/TreeMapChart.js +0 -10
- package/dist/components/TreeSelect.d.ts +0 -14
- package/dist/components/TreeSelect.js +0 -7
- package/dist/components/Upload.d.ts +0 -16
- package/dist/components/Upload.js +0 -8
- package/dist/components/VirtualList.d.ts +0 -14
- package/dist/components/VirtualList.js +0 -6
- package/dist/components/VirtualTable.d.ts +0 -32
- package/dist/components/VirtualTable.js +0 -9
- package/dist/components/Watermark.d.ts +0 -9
- package/dist/components/Watermark.js +0 -6
- package/dist/index.d.ts +0 -325
- package/dist/index.js +0 -910
- package/dist/types-0oVwMXtR.d.ts +0 -33
- package/dist/types-CcgZY0mv.d.mts +0 -80
- package/dist/types-CcgZY0mv.d.ts +0 -80
- package/dist/{chunk-6QML6T3Y.mjs → chunk-DNOPEJ5I.mjs} +0 -0
- package/dist/{chunk-WHYHLUXG.mjs → chunk-MEFARVQI.mjs} +0 -0
- package/dist/{chunk-U337RHJB.mjs → chunk-MOLUSXVC.mjs} +3 -3
package/dist/chunk-DH4B2COV.js
DELETED
|
@@ -1,1649 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
|
-
|
|
3
|
-
var _chunkHFGTJEQWjs = require('./chunk-HFGTJEQW.js');
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
var _chunk5ALMTE35js = require('./chunk-5ALMTE35.js');
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
var _chunkBR3WLDH7js = require('./chunk-BR3WLDH7.js');
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
var _chunkLZG24TDBjs = require('./chunk-LZG24TDB.js');
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
var _chunkTDODFBBOjs = require('./chunk-TDODFBBO.js');
|
|
16
|
-
|
|
17
|
-
// src/components/Table.tsx
|
|
18
|
-
var _react = require('react'); var _react2 = _interopRequireDefault(_react);
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
var _tigercatcore = require('@expcat/tigercat-core');
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
// src/components/Table/icons.tsx
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
var _jsxruntime = require('react/jsx-runtime');
|
|
63
|
-
var spinnerSvg = _tigercatcore.getSpinnerSVG.call(void 0, "spinner");
|
|
64
|
-
var SortIcon = ({ direction }) => {
|
|
65
|
-
const active = direction !== null;
|
|
66
|
-
const pathD = direction === "asc" ? _tigercatcore.sortAscIcon16PathD : direction === "desc" ? _tigercatcore.sortDescIcon16PathD : _tigercatcore.sortBothIcon16PathD;
|
|
67
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
68
|
-
"svg",
|
|
69
|
-
{
|
|
70
|
-
className: _tigercatcore.getSortIconClasses.call(void 0, active),
|
|
71
|
-
width: "16",
|
|
72
|
-
height: "16",
|
|
73
|
-
viewBox: _tigercatcore.icon16ViewBox,
|
|
74
|
-
fill: "currentColor",
|
|
75
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { d: pathD })
|
|
76
|
-
}
|
|
77
|
-
);
|
|
78
|
-
};
|
|
79
|
-
var LockIcon = ({ locked }) => {
|
|
80
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { width: "14", height: "14", viewBox: _tigercatcore.icon24ViewBox, fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { d: locked ? _tigercatcore.lockClosedIcon24PathD : _tigercatcore.lockOpenIcon24PathD }) });
|
|
81
|
-
};
|
|
82
|
-
var ExpandIcon = ({ expanded }) => {
|
|
83
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
84
|
-
"svg",
|
|
85
|
-
{
|
|
86
|
-
className: _tigercatcore.getExpandIconClasses.call(void 0, expanded),
|
|
87
|
-
width: "16",
|
|
88
|
-
height: "16",
|
|
89
|
-
viewBox: _tigercatcore.icon16ViewBox,
|
|
90
|
-
fill: "currentColor",
|
|
91
|
-
"aria-hidden": "true",
|
|
92
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { d: _tigercatcore.expandChevronIcon16PathD })
|
|
93
|
-
}
|
|
94
|
-
);
|
|
95
|
-
};
|
|
96
|
-
var LoadingSpinner = () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
97
|
-
"svg",
|
|
98
|
-
{
|
|
99
|
-
className: _tigercatcore.getLoadingOverlaySpinnerClasses.call(void 0, ),
|
|
100
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
101
|
-
fill: "none",
|
|
102
|
-
viewBox: spinnerSvg.viewBox,
|
|
103
|
-
children: spinnerSvg.elements.map((el, index) => {
|
|
104
|
-
if (el.type === "circle") return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "circle", { ...el.attrs }, index);
|
|
105
|
-
if (el.type === "path") return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { ...el.attrs }, index);
|
|
106
|
-
return null;
|
|
107
|
-
})
|
|
108
|
-
}
|
|
109
|
-
);
|
|
110
|
-
|
|
111
|
-
// src/components/Table/state.ts
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
function useTableState(input) {
|
|
131
|
-
const {
|
|
132
|
-
columns,
|
|
133
|
-
dataSource,
|
|
134
|
-
hiddenColumnKeys,
|
|
135
|
-
defaultHiddenColumnKeys,
|
|
136
|
-
sort,
|
|
137
|
-
defaultSort,
|
|
138
|
-
filters,
|
|
139
|
-
defaultFilters,
|
|
140
|
-
pagination,
|
|
141
|
-
rowSelection,
|
|
142
|
-
expandable,
|
|
143
|
-
rowKey,
|
|
144
|
-
editable,
|
|
145
|
-
editableCells,
|
|
146
|
-
filterMode,
|
|
147
|
-
advancedFilterRules,
|
|
148
|
-
groupBy,
|
|
149
|
-
exportFormat,
|
|
150
|
-
exportFilename,
|
|
151
|
-
measuredColumnWidths,
|
|
152
|
-
onChange,
|
|
153
|
-
onRowClick,
|
|
154
|
-
onSelectionChange,
|
|
155
|
-
onSortChange,
|
|
156
|
-
onFilterChange,
|
|
157
|
-
onHiddenColumnKeysChange,
|
|
158
|
-
onPageChange,
|
|
159
|
-
onExpandChange,
|
|
160
|
-
onCellChange,
|
|
161
|
-
onColumnOrderChange,
|
|
162
|
-
onRowOrderChange,
|
|
163
|
-
onExport
|
|
164
|
-
} = input;
|
|
165
|
-
const isSortControlled = sort !== void 0;
|
|
166
|
-
const isFiltersControlled = filters !== void 0;
|
|
167
|
-
const isHiddenColumnsControlled = hiddenColumnKeys !== void 0;
|
|
168
|
-
const paginationConfig = pagination !== false && typeof pagination === "object" ? pagination : null;
|
|
169
|
-
const isCurrentPageControlled = _optionalChain([paginationConfig, 'optionalAccess', _ => _.current]) !== void 0;
|
|
170
|
-
const isPageSizeControlled = _optionalChain([paginationConfig, 'optionalAccess', _2 => _2.pageSize]) !== void 0;
|
|
171
|
-
const isSelectionControlled = _optionalChain([rowSelection, 'optionalAccess', _3 => _3.selectedRowKeys]) !== void 0 && Array.isArray(rowSelection.selectedRowKeys);
|
|
172
|
-
const isExpandControlled = _optionalChain([expandable, 'optionalAccess', _4 => _4.expandedRowKeys]) !== void 0 && Array.isArray(expandable.expandedRowKeys);
|
|
173
|
-
const [uncontrolledSortState, setUncontrolledSortState] = _react.useState.call(void 0,
|
|
174
|
-
_nullishCoalesce(defaultSort, () => ( { key: null, direction: null }))
|
|
175
|
-
);
|
|
176
|
-
const [uncontrolledHiddenColumnKeys, setUncontrolledHiddenColumnKeys] = _react.useState.call(void 0,
|
|
177
|
-
_nullishCoalesce(_nullishCoalesce(defaultHiddenColumnKeys, () => ( hiddenColumnKeys)), () => ( []))
|
|
178
|
-
);
|
|
179
|
-
const [uncontrolledFilterState, setUncontrolledFilterState] = _react.useState.call(void 0,
|
|
180
|
-
_nullishCoalesce(defaultFilters, () => ( {}))
|
|
181
|
-
);
|
|
182
|
-
const [uncontrolledCurrentPage, setUncontrolledCurrentPage] = _react.useState.call(void 0,
|
|
183
|
-
() => _nullishCoalesce(_nullishCoalesce(_optionalChain([paginationConfig, 'optionalAccess', _5 => _5.defaultCurrent]), () => ( _optionalChain([paginationConfig, 'optionalAccess', _6 => _6.current]))), () => ( 1))
|
|
184
|
-
);
|
|
185
|
-
const [uncontrolledCurrentPageSize, setUncontrolledCurrentPageSize] = _react.useState.call(void 0,
|
|
186
|
-
() => _nullishCoalesce(_nullishCoalesce(_optionalChain([paginationConfig, 'optionalAccess', _7 => _7.defaultPageSize]), () => ( _optionalChain([paginationConfig, 'optionalAccess', _8 => _8.pageSize]))), () => ( 10))
|
|
187
|
-
);
|
|
188
|
-
const [uncontrolledSelectedRowKeys, setUncontrolledSelectedRowKeys] = _react.useState.call(void 0, _nullishCoalesce(_nullishCoalesce(_optionalChain([rowSelection, 'optionalAccess', _9 => _9.defaultSelectedRowKeys]), () => ( _optionalChain([rowSelection, 'optionalAccess', _10 => _10.selectedRowKeys]))), () => ( [])));
|
|
189
|
-
const [uncontrolledExpandedRowKeys, setUncontrolledExpandedRowKeys] = _react.useState.call(void 0, _nullishCoalesce(_nullishCoalesce(_optionalChain([expandable, 'optionalAccess', _11 => _11.defaultExpandedRowKeys]), () => ( _optionalChain([expandable, 'optionalAccess', _12 => _12.expandedRowKeys]))), () => ( [])));
|
|
190
|
-
const sortState = isSortControlled ? sort : uncontrolledSortState;
|
|
191
|
-
const effectiveHiddenColumnKeys = isHiddenColumnsControlled ? hiddenColumnKeys : uncontrolledHiddenColumnKeys;
|
|
192
|
-
const filterState = isFiltersControlled ? filters : uncontrolledFilterState;
|
|
193
|
-
const currentPage = isCurrentPageControlled ? paginationConfig.current : uncontrolledCurrentPage;
|
|
194
|
-
const currentPageSize = isPageSizeControlled ? paginationConfig.pageSize : uncontrolledCurrentPageSize;
|
|
195
|
-
const selectedRowKeys = isSelectionControlled ? rowSelection.selectedRowKeys : uncontrolledSelectedRowKeys;
|
|
196
|
-
const expandedRowKeys = isExpandControlled ? expandable.expandedRowKeys : uncontrolledExpandedRowKeys;
|
|
197
|
-
_react.useEffect.call(void 0, () => {
|
|
198
|
-
if (isSortControlled && sort) {
|
|
199
|
-
setUncontrolledSortState(sort);
|
|
200
|
-
}
|
|
201
|
-
}, [isSortControlled, _optionalChain([sort, 'optionalAccess', _13 => _13.key]), _optionalChain([sort, 'optionalAccess', _14 => _14.direction])]);
|
|
202
|
-
_react.useEffect.call(void 0, () => {
|
|
203
|
-
if (isFiltersControlled && filters) {
|
|
204
|
-
setUncontrolledFilterState(filters);
|
|
205
|
-
}
|
|
206
|
-
}, [isFiltersControlled, filters]);
|
|
207
|
-
_react.useEffect.call(void 0, () => {
|
|
208
|
-
if (isCurrentPageControlled) {
|
|
209
|
-
setUncontrolledCurrentPage(paginationConfig.current);
|
|
210
|
-
}
|
|
211
|
-
}, [isCurrentPageControlled, _optionalChain([paginationConfig, 'optionalAccess', _15 => _15.current])]);
|
|
212
|
-
_react.useEffect.call(void 0, () => {
|
|
213
|
-
if (isPageSizeControlled) {
|
|
214
|
-
setUncontrolledCurrentPageSize(paginationConfig.pageSize);
|
|
215
|
-
}
|
|
216
|
-
}, [isPageSizeControlled, _optionalChain([paginationConfig, 'optionalAccess', _16 => _16.pageSize])]);
|
|
217
|
-
_react.useEffect.call(void 0, () => {
|
|
218
|
-
if (isSelectionControlled) {
|
|
219
|
-
setUncontrolledSelectedRowKeys(_nullishCoalesce(_optionalChain([rowSelection, 'optionalAccess', _17 => _17.selectedRowKeys]), () => ( [])));
|
|
220
|
-
}
|
|
221
|
-
}, [isSelectionControlled, _optionalChain([rowSelection, 'optionalAccess', _18 => _18.selectedRowKeys])]);
|
|
222
|
-
_react.useEffect.call(void 0, () => {
|
|
223
|
-
if (isHiddenColumnsControlled && hiddenColumnKeys) {
|
|
224
|
-
setUncontrolledHiddenColumnKeys(hiddenColumnKeys);
|
|
225
|
-
}
|
|
226
|
-
}, [isHiddenColumnsControlled, hiddenColumnKeys]);
|
|
227
|
-
_react.useEffect.call(void 0, () => {
|
|
228
|
-
if (isExpandControlled) {
|
|
229
|
-
setUncontrolledExpandedRowKeys(_nullishCoalesce(_optionalChain([expandable, 'optionalAccess', _19 => _19.expandedRowKeys]), () => ( [])));
|
|
230
|
-
}
|
|
231
|
-
}, [isExpandControlled, _optionalChain([expandable, 'optionalAccess', _20 => _20.expandedRowKeys])]);
|
|
232
|
-
const [fixedOverrides, setFixedOverrides] = _react.useState.call(void 0, {});
|
|
233
|
-
const displayColumns = _react.useMemo.call(void 0, () => {
|
|
234
|
-
const mapped = columns.map((column) => {
|
|
235
|
-
const hasOverride = Object.prototype.hasOwnProperty.call(fixedOverrides, column.key);
|
|
236
|
-
return {
|
|
237
|
-
...column,
|
|
238
|
-
fixed: hasOverride ? fixedOverrides[column.key] : column.fixed
|
|
239
|
-
};
|
|
240
|
-
});
|
|
241
|
-
return _tigercatcore.orderTableFixedColumns.call(void 0, _tigercatcore.filterHiddenColumns.call(void 0, mapped, effectiveHiddenColumnKeys));
|
|
242
|
-
}, [columns, fixedOverrides, effectiveHiddenColumnKeys]);
|
|
243
|
-
const totalColumnCount = _react.useMemo.call(void 0, () => {
|
|
244
|
-
let count = displayColumns.length;
|
|
245
|
-
if (_tigercatcore.hasTableSelectionColumn.call(void 0, rowSelection)) count++;
|
|
246
|
-
if (expandable) count++;
|
|
247
|
-
return count;
|
|
248
|
-
}, [displayColumns.length, rowSelection, expandable]);
|
|
249
|
-
const columnByKey = _react.useMemo.call(void 0, () => {
|
|
250
|
-
const map = {};
|
|
251
|
-
for (const column of displayColumns) {
|
|
252
|
-
map[column.key] = column;
|
|
253
|
-
}
|
|
254
|
-
return map;
|
|
255
|
-
}, [displayColumns]);
|
|
256
|
-
const fixedColumnsInfo = _react.useMemo.call(void 0,
|
|
257
|
-
() => _tigercatcore.getFixedColumnOffsets.call(void 0, displayColumns, measuredColumnWidths),
|
|
258
|
-
[displayColumns, measuredColumnWidths]
|
|
259
|
-
);
|
|
260
|
-
const [frozenColumnWidths, setFrozenColumnWidths] = _react.useState.call(void 0, {});
|
|
261
|
-
_react.useEffect.call(void 0, () => {
|
|
262
|
-
setFrozenColumnWidths(
|
|
263
|
-
(prev) => _tigercatcore.freezeTableColumnWidths.call(void 0, displayColumns, _nullishCoalesce(measuredColumnWidths, () => ( {})), prev)
|
|
264
|
-
);
|
|
265
|
-
}, [displayColumns, measuredColumnWidths]);
|
|
266
|
-
function handleSetHiddenColumns(hiddenKeys) {
|
|
267
|
-
if (!isHiddenColumnsControlled) {
|
|
268
|
-
setUncontrolledHiddenColumnKeys(hiddenKeys);
|
|
269
|
-
}
|
|
270
|
-
_optionalChain([onHiddenColumnKeysChange, 'optionalCall', _21 => _21(hiddenKeys)]);
|
|
271
|
-
}
|
|
272
|
-
function toggleColumnLock(columnKey) {
|
|
273
|
-
setFixedOverrides((prev) => {
|
|
274
|
-
const original = _optionalChain([columns, 'access', _22 => _22.find, 'call', _23 => _23((c) => c.key === columnKey), 'optionalAccess', _24 => _24.fixed]);
|
|
275
|
-
const current = Object.prototype.hasOwnProperty.call(prev, columnKey) ? prev[columnKey] : original;
|
|
276
|
-
const isLocked = current === "left" || current === "right";
|
|
277
|
-
return {
|
|
278
|
-
...prev,
|
|
279
|
-
[columnKey]: isLocked ? false : "left"
|
|
280
|
-
};
|
|
281
|
-
});
|
|
282
|
-
}
|
|
283
|
-
const processedData = _react.useMemo.call(void 0, () => {
|
|
284
|
-
let data = dataSource;
|
|
285
|
-
if (filterMode === "advanced" && advancedFilterRules.length > 0) {
|
|
286
|
-
data = _tigercatcore.filterDataAdvanced.call(void 0, data, advancedFilterRules);
|
|
287
|
-
} else {
|
|
288
|
-
data = _tigercatcore.filterTableData.call(void 0, data, columns, filterState);
|
|
289
|
-
}
|
|
290
|
-
if (sortState.key && sortState.direction) {
|
|
291
|
-
const column = columnByKey[sortState.key];
|
|
292
|
-
data = _tigercatcore.sortData.call(void 0, data, sortState.key, sortState.direction, _optionalChain([column, 'optionalAccess', _25 => _25.sortFn]));
|
|
293
|
-
}
|
|
294
|
-
return data;
|
|
295
|
-
}, [dataSource, columns, filterState, sortState, columnByKey, filterMode, advancedFilterRules]);
|
|
296
|
-
const paginatedData = _react.useMemo.call(void 0, () => {
|
|
297
|
-
if (pagination === false) {
|
|
298
|
-
return processedData;
|
|
299
|
-
}
|
|
300
|
-
return _tigercatcore.paginateData.call(void 0, processedData, currentPage, currentPageSize);
|
|
301
|
-
}, [processedData, currentPage, currentPageSize, pagination]);
|
|
302
|
-
const pageRowKeys = _react.useMemo.call(void 0,
|
|
303
|
-
() => _tigercatcore.createTableRowKeyCache.call(void 0, rowKey).getMany(paginatedData),
|
|
304
|
-
[paginatedData, rowKey]
|
|
305
|
-
);
|
|
306
|
-
const selectedRowKeySet = _react.useMemo.call(void 0,
|
|
307
|
-
() => new Set(selectedRowKeys),
|
|
308
|
-
[selectedRowKeys]
|
|
309
|
-
);
|
|
310
|
-
const expandedRowKeySet = _react.useMemo.call(void 0,
|
|
311
|
-
() => new Set(expandedRowKeys),
|
|
312
|
-
[expandedRowKeys]
|
|
313
|
-
);
|
|
314
|
-
const paginationInfo = _react.useMemo.call(void 0, () => {
|
|
315
|
-
if (pagination === false) {
|
|
316
|
-
return null;
|
|
317
|
-
}
|
|
318
|
-
const total = _optionalChain([paginationConfig, 'optionalAccess', _26 => _26.total]) !== void 0 && paginationConfig.total > 0 ? paginationConfig.total : processedData.length;
|
|
319
|
-
return _tigercatcore.calculatePagination.call(void 0, total, currentPage, currentPageSize);
|
|
320
|
-
}, [processedData.length, currentPage, currentPageSize, pagination, _optionalChain([paginationConfig, 'optionalAccess', _27 => _27.total])]);
|
|
321
|
-
function handleSetSort(newSortState) {
|
|
322
|
-
if (!isSortControlled) {
|
|
323
|
-
setUncontrolledSortState(newSortState);
|
|
324
|
-
}
|
|
325
|
-
_optionalChain([onSortChange, 'optionalCall', _28 => _28(newSortState)]);
|
|
326
|
-
_optionalChain([onChange, 'optionalCall', _29 => _29({
|
|
327
|
-
sort: newSortState,
|
|
328
|
-
filters: filterState,
|
|
329
|
-
pagination: pagination !== false ? { current: currentPage, pageSize: currentPageSize } : null
|
|
330
|
-
})]);
|
|
331
|
-
}
|
|
332
|
-
function handleSort(columnKey) {
|
|
333
|
-
const column = columnByKey[columnKey];
|
|
334
|
-
if (!column || !column.sortable) return;
|
|
335
|
-
let newDirection = "asc";
|
|
336
|
-
if (sortState.key === columnKey) {
|
|
337
|
-
if (sortState.direction === "asc") {
|
|
338
|
-
newDirection = "desc";
|
|
339
|
-
} else if (sortState.direction === "desc") {
|
|
340
|
-
newDirection = null;
|
|
341
|
-
}
|
|
342
|
-
}
|
|
343
|
-
handleSetSort({
|
|
344
|
-
key: newDirection ? columnKey : null,
|
|
345
|
-
direction: newDirection
|
|
346
|
-
});
|
|
347
|
-
}
|
|
348
|
-
function handleFilter(columnKey, value) {
|
|
349
|
-
const newFilterState = { ...filterState, [columnKey]: value };
|
|
350
|
-
if (!isFiltersControlled) {
|
|
351
|
-
setUncontrolledFilterState(newFilterState);
|
|
352
|
-
}
|
|
353
|
-
setUncontrolledCurrentPage(1);
|
|
354
|
-
_optionalChain([onFilterChange, 'optionalCall', _30 => _30(newFilterState)]);
|
|
355
|
-
_optionalChain([onChange, 'optionalCall', _31 => _31({
|
|
356
|
-
sort: sortState,
|
|
357
|
-
filters: newFilterState,
|
|
358
|
-
pagination: pagination !== false ? { current: 1, pageSize: currentPageSize } : null
|
|
359
|
-
})]);
|
|
360
|
-
}
|
|
361
|
-
function handlePageChange(page) {
|
|
362
|
-
setUncontrolledCurrentPage(page);
|
|
363
|
-
_optionalChain([onPageChange, 'optionalCall', _32 => _32({ current: page, pageSize: currentPageSize })]);
|
|
364
|
-
_optionalChain([onChange, 'optionalCall', _33 => _33({
|
|
365
|
-
sort: sortState,
|
|
366
|
-
filters: filterState,
|
|
367
|
-
pagination: { current: page, pageSize: currentPageSize }
|
|
368
|
-
})]);
|
|
369
|
-
}
|
|
370
|
-
function handlePageSizeChange(pageSize) {
|
|
371
|
-
setUncontrolledCurrentPageSize(pageSize);
|
|
372
|
-
setUncontrolledCurrentPage(1);
|
|
373
|
-
_optionalChain([onPageChange, 'optionalCall', _34 => _34({ current: 1, pageSize })]);
|
|
374
|
-
_optionalChain([onChange, 'optionalCall', _35 => _35({
|
|
375
|
-
sort: sortState,
|
|
376
|
-
filters: filterState,
|
|
377
|
-
pagination: { current: 1, pageSize }
|
|
378
|
-
})]);
|
|
379
|
-
}
|
|
380
|
-
function handleToggleExpand(key, record) {
|
|
381
|
-
const isExpanded = expandedRowKeySet.has(key);
|
|
382
|
-
const newKeys = isExpanded ? expandedRowKeys.filter((k) => k !== key) : [...expandedRowKeys, key];
|
|
383
|
-
if (!isExpandControlled) {
|
|
384
|
-
setUncontrolledExpandedRowKeys(newKeys);
|
|
385
|
-
}
|
|
386
|
-
_optionalChain([onExpandChange, 'optionalCall', _36 => _36(newKeys, record, !isExpanded)]);
|
|
387
|
-
}
|
|
388
|
-
function handleRowClick(record, index, key) {
|
|
389
|
-
_optionalChain([onRowClick, 'optionalCall', _37 => _37(record, index)]);
|
|
390
|
-
if (_optionalChain([expandable, 'optionalAccess', _38 => _38.expandRowByClick])) {
|
|
391
|
-
const isExpandableRow = _optionalChain([expandable, 'optionalAccess', _39 => _39.rowExpandable]) ? expandable.rowExpandable(record) : true;
|
|
392
|
-
if (isExpandableRow) {
|
|
393
|
-
handleToggleExpand(key, record);
|
|
394
|
-
}
|
|
395
|
-
}
|
|
396
|
-
}
|
|
397
|
-
function handleSelectRow(key, checked) {
|
|
398
|
-
let newKeys;
|
|
399
|
-
if (_optionalChain([rowSelection, 'optionalAccess', _40 => _40.type]) === "radio") {
|
|
400
|
-
newKeys = checked ? [key] : [];
|
|
401
|
-
} else {
|
|
402
|
-
if (checked) {
|
|
403
|
-
newKeys = [...selectedRowKeys, key];
|
|
404
|
-
} else {
|
|
405
|
-
newKeys = selectedRowKeys.filter((k) => k !== key);
|
|
406
|
-
}
|
|
407
|
-
}
|
|
408
|
-
if (!isSelectionControlled) {
|
|
409
|
-
setUncontrolledSelectedRowKeys(newKeys);
|
|
410
|
-
}
|
|
411
|
-
_optionalChain([onSelectionChange, 'optionalCall', _41 => _41(newKeys)]);
|
|
412
|
-
}
|
|
413
|
-
const selectionState = _react.useMemo.call(void 0,
|
|
414
|
-
() => _tigercatcore.getTableSelectionState.call(void 0, {
|
|
415
|
-
records: paginatedData,
|
|
416
|
-
rowKeys: pageRowKeys,
|
|
417
|
-
selectedRowKeys,
|
|
418
|
-
getCheckboxProps: _optionalChain([rowSelection, 'optionalAccess', _42 => _42.getCheckboxProps])
|
|
419
|
-
}),
|
|
420
|
-
[paginatedData, pageRowKeys, selectedRowKeys, rowSelection]
|
|
421
|
-
);
|
|
422
|
-
function handleSelectAll(checked) {
|
|
423
|
-
const newKeys = _tigercatcore.getNextTableSelectAllKeys.call(void 0,
|
|
424
|
-
selectedRowKeys,
|
|
425
|
-
selectionState.selectableRowKeys,
|
|
426
|
-
checked
|
|
427
|
-
);
|
|
428
|
-
if (!isSelectionControlled) {
|
|
429
|
-
setUncontrolledSelectedRowKeys(newKeys);
|
|
430
|
-
}
|
|
431
|
-
_optionalChain([onSelectionChange, 'optionalCall', _43 => _43(newKeys)]);
|
|
432
|
-
}
|
|
433
|
-
const allSelected = selectionState.allSelected;
|
|
434
|
-
const someSelected = selectionState.someSelected;
|
|
435
|
-
const [editingCell, setEditingCell] = _react.useState.call(void 0,
|
|
436
|
-
null
|
|
437
|
-
);
|
|
438
|
-
const [editingValue, setEditingValue] = _react.useState.call(void 0, "");
|
|
439
|
-
function isCellEditable(columnKey, rowIndex) {
|
|
440
|
-
if (!editable) return false;
|
|
441
|
-
if (!editableCells) return true;
|
|
442
|
-
return !!_optionalChain([editableCells, 'access', _44 => _44.get, 'call', _45 => _45(columnKey), 'optionalAccess', _46 => _46.has, 'call', _47 => _47(rowIndex)]);
|
|
443
|
-
}
|
|
444
|
-
function startEditing(rowIndex, columnKey, currentValue) {
|
|
445
|
-
setEditingCell({ rowIndex, columnKey });
|
|
446
|
-
setEditingValue(String(_nullishCoalesce(currentValue, () => ( ""))));
|
|
447
|
-
}
|
|
448
|
-
function commitEdit() {
|
|
449
|
-
if (editingCell) {
|
|
450
|
-
_optionalChain([onCellChange, 'optionalCall', _48 => _48(editingCell.rowIndex, editingCell.columnKey, editingValue)]);
|
|
451
|
-
setEditingCell(null);
|
|
452
|
-
}
|
|
453
|
-
}
|
|
454
|
-
function cancelEdit() {
|
|
455
|
-
setEditingCell(null);
|
|
456
|
-
}
|
|
457
|
-
function handleExport() {
|
|
458
|
-
const content = _tigercatcore.exportTableData.call(void 0, displayColumns, processedData, exportFormat);
|
|
459
|
-
_tigercatcore.downloadTableExport.call(void 0, content, exportFilename, exportFormat);
|
|
460
|
-
_optionalChain([onExport, 'optionalCall', _49 => _49(content)]);
|
|
461
|
-
}
|
|
462
|
-
const [dragColumnKey, setDragColumnKey] = _react.useState.call(void 0, null);
|
|
463
|
-
function handleDragStart(columnKey) {
|
|
464
|
-
setDragColumnKey(columnKey);
|
|
465
|
-
}
|
|
466
|
-
function handleDrop(targetKey) {
|
|
467
|
-
if (!dragColumnKey || dragColumnKey === targetKey) return;
|
|
468
|
-
const cols = [...displayColumns];
|
|
469
|
-
const fromIdx = cols.findIndex((c) => c.key === dragColumnKey);
|
|
470
|
-
const toIdx = cols.findIndex((c) => c.key === targetKey);
|
|
471
|
-
if (fromIdx >= 0 && toIdx >= 0) {
|
|
472
|
-
const [moved] = cols.splice(fromIdx, 1);
|
|
473
|
-
cols.splice(toIdx, 0, moved);
|
|
474
|
-
_optionalChain([onColumnOrderChange, 'optionalCall', _50 => _50(cols)]);
|
|
475
|
-
}
|
|
476
|
-
setDragColumnKey(null);
|
|
477
|
-
}
|
|
478
|
-
const [dragRowKey, setDragRowKey] = _react.useState.call(void 0, null);
|
|
479
|
-
function handleRowDragStart(rowKeyValue) {
|
|
480
|
-
setDragRowKey(rowKeyValue);
|
|
481
|
-
}
|
|
482
|
-
function handleRowDrop(targetKey) {
|
|
483
|
-
if (dragRowKey === null || dragRowKey === targetKey) return;
|
|
484
|
-
const rows = [...paginatedData];
|
|
485
|
-
const fromIdx = pageRowKeys.findIndex((key) => key === dragRowKey);
|
|
486
|
-
const toIdx = pageRowKeys.findIndex((key) => key === targetKey);
|
|
487
|
-
if (fromIdx >= 0 && toIdx >= 0) {
|
|
488
|
-
const [moved] = rows.splice(fromIdx, 1);
|
|
489
|
-
rows.splice(toIdx, 0, moved);
|
|
490
|
-
_optionalChain([onRowOrderChange, 'optionalCall', _51 => _51(rows)]);
|
|
491
|
-
}
|
|
492
|
-
setDragRowKey(null);
|
|
493
|
-
}
|
|
494
|
-
const groupedData = _react.useMemo.call(void 0, () => {
|
|
495
|
-
if (!groupBy) return null;
|
|
496
|
-
return _tigercatcore.groupDataByColumn.call(void 0, paginatedData, groupBy);
|
|
497
|
-
}, [groupBy, paginatedData]);
|
|
498
|
-
return {
|
|
499
|
-
paginationConfig,
|
|
500
|
-
displayColumns,
|
|
501
|
-
fixedColumnsInfo,
|
|
502
|
-
frozenColumnWidths,
|
|
503
|
-
processedData,
|
|
504
|
-
paginatedData,
|
|
505
|
-
pageRowKeys,
|
|
506
|
-
selectedRowKeySet,
|
|
507
|
-
expandedRowKeySet,
|
|
508
|
-
totalColumnCount,
|
|
509
|
-
paginationInfo,
|
|
510
|
-
allSelected,
|
|
511
|
-
someSelected,
|
|
512
|
-
groupedData,
|
|
513
|
-
sortState,
|
|
514
|
-
currentPage,
|
|
515
|
-
currentPageSize,
|
|
516
|
-
hiddenColumnKeys: effectiveHiddenColumnKeys,
|
|
517
|
-
editingCell,
|
|
518
|
-
editingValue,
|
|
519
|
-
setEditingValue,
|
|
520
|
-
toggleColumnLock,
|
|
521
|
-
handleSetHiddenColumns,
|
|
522
|
-
handleSort,
|
|
523
|
-
handleFilter,
|
|
524
|
-
handlePageChange,
|
|
525
|
-
handlePageSizeChange,
|
|
526
|
-
handleSetSort,
|
|
527
|
-
handleRowClick,
|
|
528
|
-
handleToggleExpand,
|
|
529
|
-
handleSelectRow,
|
|
530
|
-
handleSelectAll,
|
|
531
|
-
isCellEditable,
|
|
532
|
-
startEditing,
|
|
533
|
-
commitEdit,
|
|
534
|
-
cancelEdit,
|
|
535
|
-
handleExport,
|
|
536
|
-
handleDragStart,
|
|
537
|
-
handleDrop,
|
|
538
|
-
handleRowDragStart,
|
|
539
|
-
handleRowDrop
|
|
540
|
-
};
|
|
541
|
-
}
|
|
542
|
-
|
|
543
|
-
// src/components/Table/render-header.tsx
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
function renderTableHeader(ctx, view) {
|
|
556
|
-
const {
|
|
557
|
-
size,
|
|
558
|
-
stickyHeader,
|
|
559
|
-
rowSelection,
|
|
560
|
-
expandable,
|
|
561
|
-
columnLockable,
|
|
562
|
-
columnDraggable,
|
|
563
|
-
lockColumnAriaLabel,
|
|
564
|
-
unlockColumnAriaLabel,
|
|
565
|
-
labels
|
|
566
|
-
} = view;
|
|
567
|
-
const expandHeaderTh = expandable ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "th", { className: _tigercatcore.getExpandIconCellClasses.call(void 0, size), "aria-label": labels.expandText }) : null;
|
|
568
|
-
const expandAtStart = _optionalChain([expandable, 'optionalAccess', _52 => _52.expandIconPosition]) !== "end";
|
|
569
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "thead", { className: _tigercatcore.getTableHeaderClasses.call(void 0, stickyHeader), children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "tr", { children: [
|
|
570
|
-
expandAtStart && expandHeaderTh,
|
|
571
|
-
rowSelection && rowSelection.showCheckbox !== false && rowSelection.type !== "radio" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "th", { className: _tigercatcore.getCheckboxCellClasses.call(void 0, size), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
572
|
-
"input",
|
|
573
|
-
{
|
|
574
|
-
type: "checkbox",
|
|
575
|
-
className: "rounded border-gray-300 text-[var(--tiger-primary,#2563eb)] focus:ring-[var(--tiger-primary,#2563eb)]",
|
|
576
|
-
checked: ctx.allSelected,
|
|
577
|
-
ref: (el) => {
|
|
578
|
-
if (el) el.indeterminate = ctx.someSelected;
|
|
579
|
-
},
|
|
580
|
-
onChange: (e) => ctx.handleSelectAll(e.target.checked)
|
|
581
|
-
}
|
|
582
|
-
) }),
|
|
583
|
-
ctx.displayColumns.map((column) => {
|
|
584
|
-
const isSorted = ctx.sortState.key === column.key;
|
|
585
|
-
const sortDirection = isSorted ? ctx.sortState.direction : null;
|
|
586
|
-
const ariaSort = column.sortable ? sortDirection === "asc" ? "ascending" : sortDirection === "desc" ? "descending" : "none" : void 0;
|
|
587
|
-
const fixedStyle = _tigercatcore.getFixedColumnStyle.call(void 0, column, ctx.fixedColumnsInfo, 15);
|
|
588
|
-
const widthStyle = column.width ? {
|
|
589
|
-
width: typeof column.width === "number" ? `${column.width}px` : column.width
|
|
590
|
-
} : void 0;
|
|
591
|
-
const style = fixedStyle ? { ...widthStyle, ...fixedStyle } : widthStyle;
|
|
592
|
-
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
593
|
-
"th",
|
|
594
|
-
{
|
|
595
|
-
"data-tiger-table-column-key": column.key,
|
|
596
|
-
"aria-sort": ariaSort,
|
|
597
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
598
|
-
_tigercatcore.getTableHeaderCellClasses.call(void 0,
|
|
599
|
-
size,
|
|
600
|
-
column.align || "left",
|
|
601
|
-
!!column.sortable,
|
|
602
|
-
column.headerClassName
|
|
603
|
-
),
|
|
604
|
-
_tigercatcore.getTableFixedHeaderCellClasses.call(void 0, {
|
|
605
|
-
view: "table",
|
|
606
|
-
column,
|
|
607
|
-
stickyHeader,
|
|
608
|
-
fixedInfo: ctx.fixedColumnsInfo
|
|
609
|
-
})
|
|
610
|
-
),
|
|
611
|
-
style,
|
|
612
|
-
draggable: columnDraggable ? true : void 0,
|
|
613
|
-
onDragStart: columnDraggable ? () => ctx.handleDragStart(column.key) : void 0,
|
|
614
|
-
onDragOver: columnDraggable ? (e) => e.preventDefault() : void 0,
|
|
615
|
-
onDrop: columnDraggable ? () => ctx.handleDrop(column.key) : void 0,
|
|
616
|
-
onClick: column.sortable ? () => ctx.handleSort(column.key) : void 0,
|
|
617
|
-
children: [
|
|
618
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-2", children: [
|
|
619
|
-
column.renderHeader ? column.renderHeader() : column.title,
|
|
620
|
-
columnLockable && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
621
|
-
"button",
|
|
622
|
-
{
|
|
623
|
-
type: "button",
|
|
624
|
-
"aria-label": _tigercatcore.formatTableSortByText.call(void 0,
|
|
625
|
-
column.fixed === "left" || column.fixed === "right" ? unlockColumnAriaLabel : lockColumnAriaLabel,
|
|
626
|
-
String(column.title)
|
|
627
|
-
),
|
|
628
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
629
|
-
"inline-flex items-center",
|
|
630
|
-
column.fixed === "left" || column.fixed === "right" ? "text-[var(--tiger-primary,#2563eb)]" : "text-gray-400 hover:text-gray-700"
|
|
631
|
-
),
|
|
632
|
-
onClick: (e) => {
|
|
633
|
-
e.stopPropagation();
|
|
634
|
-
ctx.toggleColumnLock(column.key);
|
|
635
|
-
},
|
|
636
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, LockIcon, { locked: column.fixed === "left" || column.fixed === "right" })
|
|
637
|
-
}
|
|
638
|
-
),
|
|
639
|
-
column.sortable && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SortIcon, { direction: sortDirection })
|
|
640
|
-
] }),
|
|
641
|
-
column.filter && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mt-2", children: column.filter.type === "select" && column.filter.options ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
642
|
-
"select",
|
|
643
|
-
{
|
|
644
|
-
className: "w-full px-2 py-1 text-sm border border-gray-300 rounded",
|
|
645
|
-
onChange: (e) => ctx.handleFilter(column.key, e.target.value),
|
|
646
|
-
onClick: (e) => e.stopPropagation(),
|
|
647
|
-
children: [
|
|
648
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "option", { value: "", children: labels.allText }),
|
|
649
|
-
column.filter.options.map((opt) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "option", { value: opt.value, children: opt.label }, opt.value))
|
|
650
|
-
]
|
|
651
|
-
}
|
|
652
|
-
) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
653
|
-
"input",
|
|
654
|
-
{
|
|
655
|
-
type: "text",
|
|
656
|
-
className: "w-full px-2 py-1 text-sm border border-gray-300 rounded",
|
|
657
|
-
placeholder: column.filter.placeholder || labels.filterPlaceholder,
|
|
658
|
-
onInput: (e) => ctx.handleFilter(column.key, e.target.value),
|
|
659
|
-
onClick: (e) => e.stopPropagation()
|
|
660
|
-
}
|
|
661
|
-
) })
|
|
662
|
-
]
|
|
663
|
-
},
|
|
664
|
-
column.key
|
|
665
|
-
);
|
|
666
|
-
}),
|
|
667
|
-
!expandAtStart && expandHeaderTh
|
|
668
|
-
] }) });
|
|
669
|
-
}
|
|
670
|
-
|
|
671
|
-
// src/components/Table/render-body.tsx
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
function renderTableBody(ctx, view) {
|
|
692
|
-
const {
|
|
693
|
-
size,
|
|
694
|
-
hoverable,
|
|
695
|
-
striped,
|
|
696
|
-
loading,
|
|
697
|
-
emptyText,
|
|
698
|
-
rowSelection,
|
|
699
|
-
expandable,
|
|
700
|
-
labels,
|
|
701
|
-
rowClassName,
|
|
702
|
-
rowDraggable,
|
|
703
|
-
interactiveRows,
|
|
704
|
-
virtualWindow
|
|
705
|
-
} = view;
|
|
706
|
-
if (loading) {
|
|
707
|
-
return null;
|
|
708
|
-
}
|
|
709
|
-
if (ctx.paginatedData.length === 0) {
|
|
710
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "tbody", { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "tr", { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { colSpan: ctx.totalColumnCount, className: _tigercatcore.tableEmptyStateClasses, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { role: "status", "aria-live": "polite", children: emptyText }) }) }) });
|
|
711
|
-
}
|
|
712
|
-
function getDelegatedRow(event) {
|
|
713
|
-
const row = _optionalChain([event, 'access', _53 => _53.target, 'optionalAccess', _54 => _54.closest, 'call', _55 => _55(
|
|
714
|
-
"tr[data-tiger-table-row-index]"
|
|
715
|
-
)]);
|
|
716
|
-
if (!row) return null;
|
|
717
|
-
const index = Number(row.dataset.tigerTableRowIndex);
|
|
718
|
-
if (!Number.isInteger(index)) return null;
|
|
719
|
-
const record = ctx.paginatedData[index];
|
|
720
|
-
const key = ctx.pageRowKeys[index];
|
|
721
|
-
if (!record || key === void 0) return null;
|
|
722
|
-
return { key, record, index };
|
|
723
|
-
}
|
|
724
|
-
function handleBodyClick(event) {
|
|
725
|
-
const row = getDelegatedRow(event);
|
|
726
|
-
if (!row) return;
|
|
727
|
-
ctx.handleRowClick(row.record, row.index, row.key);
|
|
728
|
-
}
|
|
729
|
-
function handleBodyDragStart(event) {
|
|
730
|
-
if (!rowDraggable) return;
|
|
731
|
-
const row = getDelegatedRow(event);
|
|
732
|
-
if (!row) return;
|
|
733
|
-
ctx.handleRowDragStart(row.key);
|
|
734
|
-
}
|
|
735
|
-
function handleBodyDragOver(event) {
|
|
736
|
-
if (!rowDraggable) return;
|
|
737
|
-
event.preventDefault();
|
|
738
|
-
}
|
|
739
|
-
function handleBodyDrop(event) {
|
|
740
|
-
if (!rowDraggable) return;
|
|
741
|
-
const row = getDelegatedRow(event);
|
|
742
|
-
if (!row) return;
|
|
743
|
-
ctx.handleRowDrop(row.key);
|
|
744
|
-
}
|
|
745
|
-
function renderDataRow(record, index) {
|
|
746
|
-
const key = ctx.pageRowKeys[index];
|
|
747
|
-
const isSelected = ctx.selectedRowKeySet.has(key);
|
|
748
|
-
const isExpanded = ctx.expandedRowKeySet.has(key);
|
|
749
|
-
const isRowExpandable = expandable ? expandable.rowExpandable ? expandable.rowExpandable(record) : true : false;
|
|
750
|
-
const rowClass = typeof rowClassName === "function" ? rowClassName(record, index) : rowClassName;
|
|
751
|
-
const expandToggleCell = expandable ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: _tigercatcore.getExpandIconCellClasses.call(void 0, size), children: isRowExpandable && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
752
|
-
"button",
|
|
753
|
-
{
|
|
754
|
-
type: "button",
|
|
755
|
-
className: "inline-flex items-center justify-center",
|
|
756
|
-
"aria-label": isExpanded ? labels.collapseRowAriaLabel : labels.expandRowAriaLabel,
|
|
757
|
-
"aria-expanded": isExpanded,
|
|
758
|
-
onClick: (e) => {
|
|
759
|
-
e.stopPropagation();
|
|
760
|
-
ctx.handleToggleExpand(key, record);
|
|
761
|
-
},
|
|
762
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ExpandIcon, { expanded: isExpanded })
|
|
763
|
-
}
|
|
764
|
-
) }) : null;
|
|
765
|
-
const expandAtStart = _optionalChain([expandable, 'optionalAccess', _56 => _56.expandIconPosition]) !== "end";
|
|
766
|
-
const rowNode = /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
767
|
-
"tr",
|
|
768
|
-
{
|
|
769
|
-
"data-tiger-table-row-index": index,
|
|
770
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
771
|
-
_tigercatcore.getTableRowClasses.call(void 0, hoverable, striped, index % 2 === 0, rowClass),
|
|
772
|
-
ctx.fixedColumnsInfo.hasFixedColumns && "group"
|
|
773
|
-
),
|
|
774
|
-
"aria-selected": rowSelection ? isSelected : void 0,
|
|
775
|
-
tabIndex: interactiveRows ? 0 : void 0,
|
|
776
|
-
onKeyDown: interactiveRows ? (e) => {
|
|
777
|
-
if (e.target !== e.currentTarget) return;
|
|
778
|
-
if (_tigercatcore.isActivationKey.call(void 0, e)) {
|
|
779
|
-
e.preventDefault();
|
|
780
|
-
ctx.handleRowClick(record, index, key);
|
|
781
|
-
}
|
|
782
|
-
} : void 0,
|
|
783
|
-
draggable: rowDraggable ? true : void 0,
|
|
784
|
-
children: [
|
|
785
|
-
expandAtStart && expandToggleCell,
|
|
786
|
-
rowSelection && rowSelection.showCheckbox !== false && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: _tigercatcore.getCheckboxCellClasses.call(void 0, size), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
787
|
-
"input",
|
|
788
|
-
{
|
|
789
|
-
type: _optionalChain([rowSelection, 'optionalAccess', _57 => _57.type]) === "radio" ? "radio" : "checkbox",
|
|
790
|
-
className: _optionalChain([rowSelection, 'optionalAccess', _58 => _58.type]) === "radio" ? "border-gray-300 text-[var(--tiger-primary,#2563eb)] focus:ring-[var(--tiger-primary,#2563eb)]" : "rounded border-gray-300 text-[var(--tiger-primary,#2563eb)] focus:ring-[var(--tiger-primary,#2563eb)]",
|
|
791
|
-
checked: isSelected,
|
|
792
|
-
disabled: _optionalChain([rowSelection, 'optionalAccess', _59 => _59.getCheckboxProps, 'optionalCall', _60 => _60(record), 'optionalAccess', _61 => _61.disabled]),
|
|
793
|
-
onChange: (e) => ctx.handleSelectRow(key, e.target.checked),
|
|
794
|
-
onClick: (e) => e.stopPropagation()
|
|
795
|
-
}
|
|
796
|
-
) }),
|
|
797
|
-
ctx.displayColumns.map((column) => {
|
|
798
|
-
const dataKey = column.dataKey || column.key;
|
|
799
|
-
const cellValue = record[dataKey];
|
|
800
|
-
const fixedStyle = _tigercatcore.getFixedColumnStyle.call(void 0, column, ctx.fixedColumnsInfo, 10);
|
|
801
|
-
const widthStyle = column.width ? {
|
|
802
|
-
width: typeof column.width === "number" ? `${column.width}px` : column.width
|
|
803
|
-
} : void 0;
|
|
804
|
-
const style = fixedStyle ? { ...widthStyle, ...fixedStyle } : widthStyle;
|
|
805
|
-
const stickyCellClass = _tigercatcore.getTableFixedCellClasses.call(void 0, {
|
|
806
|
-
view: "table",
|
|
807
|
-
column,
|
|
808
|
-
record,
|
|
809
|
-
rowIndex: index,
|
|
810
|
-
striped,
|
|
811
|
-
stripedActive: striped && index % 2 === 0,
|
|
812
|
-
selected: isSelected,
|
|
813
|
-
hoverable,
|
|
814
|
-
fixedInfo: ctx.fixedColumnsInfo
|
|
815
|
-
});
|
|
816
|
-
const isEditing = _optionalChain([ctx, 'access', _62 => _62.editingCell, 'optionalAccess', _63 => _63.rowIndex]) === index && _optionalChain([ctx, 'access', _64 => _64.editingCell, 'optionalAccess', _65 => _65.columnKey]) === column.key;
|
|
817
|
-
const cellEditable = ctx.isCellEditable(column.key, index);
|
|
818
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
819
|
-
"td",
|
|
820
|
-
{
|
|
821
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
822
|
-
_tigercatcore.getTableCellClasses.call(void 0, size, column.align || "left", column.className),
|
|
823
|
-
stickyCellClass,
|
|
824
|
-
cellEditable && _tigercatcore.getEditableCellClasses.call(void 0, !!isEditing)
|
|
825
|
-
),
|
|
826
|
-
style,
|
|
827
|
-
onDoubleClick: cellEditable ? () => ctx.startEditing(index, column.key, cellValue) : void 0,
|
|
828
|
-
children: isEditing ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
829
|
-
"input",
|
|
830
|
-
{
|
|
831
|
-
className: _tigercatcore.editableCellInputClasses,
|
|
832
|
-
value: ctx.editingValue,
|
|
833
|
-
onChange: (e) => ctx.setEditingValue(e.target.value),
|
|
834
|
-
onBlur: ctx.commitEdit,
|
|
835
|
-
onKeyDown: (e) => {
|
|
836
|
-
if (e.key === "Enter") ctx.commitEdit();
|
|
837
|
-
if (e.key === "Escape") ctx.cancelEdit();
|
|
838
|
-
},
|
|
839
|
-
autoFocus: true
|
|
840
|
-
}
|
|
841
|
-
) : column.render ? column.render(record, index) : cellValue
|
|
842
|
-
},
|
|
843
|
-
column.key
|
|
844
|
-
);
|
|
845
|
-
}),
|
|
846
|
-
!expandAtStart && expandToggleCell
|
|
847
|
-
]
|
|
848
|
-
},
|
|
849
|
-
key
|
|
850
|
-
);
|
|
851
|
-
if (expandable && isExpanded && isRowExpandable) {
|
|
852
|
-
const expandedContent = expandable.expandedRowRender ? expandable.expandedRowRender(record, index) : null;
|
|
853
|
-
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _react2.default.Fragment, { children: [
|
|
854
|
-
rowNode,
|
|
855
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "tr", { className: _tigercatcore.getExpandedRowClasses.call(void 0, ), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { colSpan: ctx.totalColumnCount, className: _tigercatcore.getExpandedRowContentClasses.call(void 0, size), children: expandedContent }) }, `${key}-expanded`)
|
|
856
|
-
] }, key);
|
|
857
|
-
}
|
|
858
|
-
return rowNode;
|
|
859
|
-
}
|
|
860
|
-
if (ctx.groupedData) {
|
|
861
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
862
|
-
"tbody",
|
|
863
|
-
{
|
|
864
|
-
onClick: handleBodyClick,
|
|
865
|
-
onDragStart: rowDraggable ? handleBodyDragStart : void 0,
|
|
866
|
-
onDragOver: rowDraggable ? handleBodyDragOver : void 0,
|
|
867
|
-
onDrop: rowDraggable ? handleBodyDrop : void 0,
|
|
868
|
-
children: Array.from(ctx.groupedData.entries()).map(([groupKey, groupItems]) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _react2.default.Fragment, { children: [
|
|
869
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "tr", { className: _tigercatcore.tableGroupHeaderClasses, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "td", { colSpan: ctx.totalColumnCount, className: _tigercatcore.getGroupHeaderCellClasses.call(void 0, size), children: [
|
|
870
|
-
groupKey,
|
|
871
|
-
" (",
|
|
872
|
-
groupItems.length,
|
|
873
|
-
")"
|
|
874
|
-
] }) }),
|
|
875
|
-
groupItems.map((record, idx) => {
|
|
876
|
-
const globalIndex = ctx.paginatedData.indexOf(record);
|
|
877
|
-
return renderDataRow(record, globalIndex >= 0 ? globalIndex : idx);
|
|
878
|
-
})
|
|
879
|
-
] }, `group-${groupKey}`))
|
|
880
|
-
}
|
|
881
|
-
);
|
|
882
|
-
}
|
|
883
|
-
if (virtualWindow && virtualWindow.endIndex >= virtualWindow.startIndex) {
|
|
884
|
-
const { startIndex, endIndex, topPad, bottomPad } = virtualWindow;
|
|
885
|
-
const windowed = [];
|
|
886
|
-
if (topPad > 0) {
|
|
887
|
-
windowed.push(
|
|
888
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "tr", { "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { colSpan: ctx.totalColumnCount, style: { height: `${topPad}px`, padding: 0 } }) }, "virtual-top")
|
|
889
|
-
);
|
|
890
|
-
}
|
|
891
|
-
for (let index = startIndex; index <= endIndex; index++) {
|
|
892
|
-
windowed.push(renderDataRow(ctx.paginatedData[index], index));
|
|
893
|
-
}
|
|
894
|
-
if (bottomPad > 0) {
|
|
895
|
-
windowed.push(
|
|
896
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "tr", { "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { colSpan: ctx.totalColumnCount, style: { height: `${bottomPad}px`, padding: 0 } }) }, "virtual-bottom")
|
|
897
|
-
);
|
|
898
|
-
}
|
|
899
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
900
|
-
"tbody",
|
|
901
|
-
{
|
|
902
|
-
onClick: handleBodyClick,
|
|
903
|
-
onDragStart: rowDraggable ? handleBodyDragStart : void 0,
|
|
904
|
-
onDragOver: rowDraggable ? handleBodyDragOver : void 0,
|
|
905
|
-
onDrop: rowDraggable ? handleBodyDrop : void 0,
|
|
906
|
-
children: windowed
|
|
907
|
-
}
|
|
908
|
-
);
|
|
909
|
-
}
|
|
910
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
911
|
-
"tbody",
|
|
912
|
-
{
|
|
913
|
-
onClick: handleBodyClick,
|
|
914
|
-
onDragStart: rowDraggable ? handleBodyDragStart : void 0,
|
|
915
|
-
onDragOver: rowDraggable ? handleBodyDragOver : void 0,
|
|
916
|
-
onDrop: rowDraggable ? handleBodyDrop : void 0,
|
|
917
|
-
children: ctx.paginatedData.map((record, index) => renderDataRow(record, index))
|
|
918
|
-
}
|
|
919
|
-
);
|
|
920
|
-
}
|
|
921
|
-
|
|
922
|
-
// src/components/Table/render-summary.tsx
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
function renderSummaryRow(ctx, view) {
|
|
929
|
-
const { size, rowSelection, expandable, summaryRow } = view;
|
|
930
|
-
if (!_optionalChain([summaryRow, 'optionalAccess', _66 => _66.show])) return null;
|
|
931
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "tfoot", { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "tr", { className: _tigercatcore.tableSummaryRowClasses, children: [
|
|
932
|
-
rowSelection && rowSelection.showCheckbox !== false && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: _tigercatcore.getTableCellClasses.call(void 0, size, "left") }),
|
|
933
|
-
expandable && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: _tigercatcore.getTableCellClasses.call(void 0, size, "left") }),
|
|
934
|
-
ctx.displayColumns.map((column) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { className: _tigercatcore.getTableCellClasses.call(void 0, size, column.align || "left"), children: _nullishCoalesce(summaryRow.data[column.dataKey || column.key], () => ( "")) }, column.key))
|
|
935
|
-
] }) });
|
|
936
|
-
}
|
|
937
|
-
|
|
938
|
-
// src/components/Table/render-pagination.tsx
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
function renderPagination(ctx, view) {
|
|
954
|
-
const { pagination } = view;
|
|
955
|
-
if (pagination === false || !ctx.paginationInfo) {
|
|
956
|
-
return null;
|
|
957
|
-
}
|
|
958
|
-
const { totalPages, startIndex, endIndex, hasNext, hasPrev } = ctx.paginationInfo;
|
|
959
|
-
const paginationConfig = pagination;
|
|
960
|
-
const total = paginationConfig.total !== void 0 && paginationConfig.total > 0 ? paginationConfig.total : ctx.processedData.length;
|
|
961
|
-
const locale = view.disableI18n ? void 0 : view.locale;
|
|
962
|
-
const labels = _tigercatcore.getPaginationLabels.call(void 0, locale);
|
|
963
|
-
const localeCode = _optionalChain([locale, 'optionalAccess', _67 => _67.locale]);
|
|
964
|
-
const finalTotalText = paginationConfig.totalText ? paginationConfig.totalText(total, [startIndex, endIndex]) : _tigercatcore.formatPaginationTotal.call(void 0, labels.totalText, total, [startIndex, endIndex], localeCode);
|
|
965
|
-
const finalPrevText = paginationConfig.prevText || labels.prevPageAriaLabel;
|
|
966
|
-
const finalNextText = paginationConfig.nextText || labels.nextPageAriaLabel;
|
|
967
|
-
const finalPageIndicatorText = paginationConfig.pageIndicatorText ? paginationConfig.pageIndicatorText(ctx.currentPage, totalPages) : _tigercatcore.formatPaginationPageIndicator.call(void 0,
|
|
968
|
-
labels.pageIndicatorText,
|
|
969
|
-
ctx.currentPage,
|
|
970
|
-
totalPages,
|
|
971
|
-
localeCode
|
|
972
|
-
);
|
|
973
|
-
const finalPrevAriaLabel = view.disableI18n ? finalPrevText : labels.prevPageAriaLabel;
|
|
974
|
-
const finalNextAriaLabel = view.disableI18n ? finalNextText : labels.nextPageAriaLabel;
|
|
975
|
-
const normalizedPageSizeOptions = paginationConfig.pageSizeOptions || [
|
|
976
|
-
10,
|
|
977
|
-
20,
|
|
978
|
-
50,
|
|
979
|
-
100
|
|
980
|
-
];
|
|
981
|
-
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: _tigercatcore.getSimplePaginationContainerClasses.call(void 0, ), children: [
|
|
982
|
-
paginationConfig.showTotal !== false && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: _tigercatcore.getSimplePaginationTotalClasses.call(void 0, ), children: finalTotalText }),
|
|
983
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: _tigercatcore.getSimplePaginationControlsClasses.call(void 0, ), children: [
|
|
984
|
-
paginationConfig.showSizeChanger !== false && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
985
|
-
"select",
|
|
986
|
-
{
|
|
987
|
-
className: _tigercatcore.getSimplePaginationSelectClasses.call(void 0, ),
|
|
988
|
-
value: ctx.currentPageSize,
|
|
989
|
-
"aria-label": labels.itemsPerPageText,
|
|
990
|
-
onChange: (e) => ctx.handlePageSizeChange(Number(e.target.value)),
|
|
991
|
-
children: normalizedPageSizeOptions.map((option) => {
|
|
992
|
-
const value = typeof option === "number" ? option : option.value;
|
|
993
|
-
const label = typeof option === "number" ? `${_tigercatcore.formatIntlNumber.call(void 0, value, localeCode)} ${labels.itemsPerPageText}` : _nullishCoalesce(option.label, () => ( `${_tigercatcore.formatIntlNumber.call(void 0, value, localeCode)} ${labels.itemsPerPageText}`));
|
|
994
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "option", { value, children: paginationConfig.pageSizeText ? paginationConfig.pageSizeText(value) : label }, value);
|
|
995
|
-
})
|
|
996
|
-
}
|
|
997
|
-
),
|
|
998
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: _tigercatcore.getSimplePaginationButtonsWrapperClasses.call(void 0, ), children: [
|
|
999
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1000
|
-
"button",
|
|
1001
|
-
{
|
|
1002
|
-
className: _tigercatcore.getSimplePaginationButtonClasses.call(void 0, !hasPrev),
|
|
1003
|
-
disabled: !hasPrev,
|
|
1004
|
-
"aria-label": finalPrevAriaLabel,
|
|
1005
|
-
onClick: () => ctx.handlePageChange(ctx.currentPage - 1),
|
|
1006
|
-
children: finalPrevText
|
|
1007
|
-
}
|
|
1008
|
-
),
|
|
1009
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1010
|
-
"span",
|
|
1011
|
-
{
|
|
1012
|
-
className: _tigercatcore.getSimplePaginationPageIndicatorClasses.call(void 0, ),
|
|
1013
|
-
"aria-label": finalPageIndicatorText,
|
|
1014
|
-
children: finalPageIndicatorText
|
|
1015
|
-
}
|
|
1016
|
-
),
|
|
1017
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1018
|
-
"button",
|
|
1019
|
-
{
|
|
1020
|
-
className: _tigercatcore.getSimplePaginationButtonClasses.call(void 0, !hasNext),
|
|
1021
|
-
disabled: !hasNext,
|
|
1022
|
-
"aria-label": finalNextAriaLabel,
|
|
1023
|
-
onClick: () => ctx.handlePageChange(ctx.currentPage + 1),
|
|
1024
|
-
children: finalNextText
|
|
1025
|
-
}
|
|
1026
|
-
)
|
|
1027
|
-
] })
|
|
1028
|
-
] })
|
|
1029
|
-
] });
|
|
1030
|
-
}
|
|
1031
|
-
|
|
1032
|
-
// src/components/Table.tsx
|
|
1033
|
-
|
|
1034
|
-
function Table({
|
|
1035
|
-
columns,
|
|
1036
|
-
columnLockable = false,
|
|
1037
|
-
dataSource = [],
|
|
1038
|
-
hiddenColumnKeys,
|
|
1039
|
-
defaultHiddenColumnKeys,
|
|
1040
|
-
sort,
|
|
1041
|
-
defaultSort,
|
|
1042
|
-
filters,
|
|
1043
|
-
defaultFilters,
|
|
1044
|
-
size = "md",
|
|
1045
|
-
bordered = false,
|
|
1046
|
-
striped = false,
|
|
1047
|
-
hoverable = true,
|
|
1048
|
-
loading = false,
|
|
1049
|
-
locale,
|
|
1050
|
-
labels,
|
|
1051
|
-
emptyText,
|
|
1052
|
-
pagination = {
|
|
1053
|
-
current: 1,
|
|
1054
|
-
pageSize: 10,
|
|
1055
|
-
total: 0,
|
|
1056
|
-
pageSizeOptions: [10, 20, 50, 100],
|
|
1057
|
-
showSizeChanger: true,
|
|
1058
|
-
showTotal: true
|
|
1059
|
-
},
|
|
1060
|
-
rowSelection,
|
|
1061
|
-
expandable,
|
|
1062
|
-
rowKey = "id",
|
|
1063
|
-
rowClassName,
|
|
1064
|
-
stickyHeader = false,
|
|
1065
|
-
maxHeight,
|
|
1066
|
-
tableLayout = "auto",
|
|
1067
|
-
responsiveMode = "scroll",
|
|
1068
|
-
cardBreakpoint = "sm",
|
|
1069
|
-
cardClassName,
|
|
1070
|
-
renderCard,
|
|
1071
|
-
cardLayout,
|
|
1072
|
-
cardSelectionPosition = "controls-row",
|
|
1073
|
-
cardPadding,
|
|
1074
|
-
cardFieldGap = "gap-3",
|
|
1075
|
-
// v0.6.0 props
|
|
1076
|
-
virtual = false,
|
|
1077
|
-
autoVirtual = true,
|
|
1078
|
-
virtualHeight = 400,
|
|
1079
|
-
virtualItemHeight = 40,
|
|
1080
|
-
autoVirtualThreshold = 1e4,
|
|
1081
|
-
virtualThreshold = 1e3,
|
|
1082
|
-
editable = false,
|
|
1083
|
-
editableCells,
|
|
1084
|
-
filterMode = "basic",
|
|
1085
|
-
advancedFilterRules = [],
|
|
1086
|
-
columnDraggable = false,
|
|
1087
|
-
rowDraggable = false,
|
|
1088
|
-
summaryRow,
|
|
1089
|
-
groupBy,
|
|
1090
|
-
exportable = false,
|
|
1091
|
-
exportFormat = "csv",
|
|
1092
|
-
exportFilename = "export",
|
|
1093
|
-
onChange,
|
|
1094
|
-
onRowClick,
|
|
1095
|
-
onSelectionChange,
|
|
1096
|
-
onSortChange,
|
|
1097
|
-
onFilterChange,
|
|
1098
|
-
onHiddenColumnKeysChange,
|
|
1099
|
-
onPageChange,
|
|
1100
|
-
onExpandChange,
|
|
1101
|
-
onCellChange,
|
|
1102
|
-
onColumnOrderChange,
|
|
1103
|
-
onRowOrderChange,
|
|
1104
|
-
onExport,
|
|
1105
|
-
className,
|
|
1106
|
-
...props
|
|
1107
|
-
}) {
|
|
1108
|
-
const config = _chunkTDODFBBOjs.useTigerConfig.call(void 0, );
|
|
1109
|
-
const wrapperRef = _react.useRef.call(void 0, null);
|
|
1110
|
-
const tableRef = _react.useRef.call(void 0, null);
|
|
1111
|
-
const [measuredColumnWidths, setMeasuredColumnWidths] = _react.useState.call(void 0, {});
|
|
1112
|
-
const [measuredRowHeights, setMeasuredRowHeights] = _react.useState.call(void 0, []);
|
|
1113
|
-
const internalRowSelection = rowSelection;
|
|
1114
|
-
const internalExpandable = expandable;
|
|
1115
|
-
const internalRowClassName = rowClassName;
|
|
1116
|
-
const paginationLocaleInput = pagination !== false && typeof pagination === "object" ? pagination.locale : void 0;
|
|
1117
|
-
const tableLocaleInput = locale;
|
|
1118
|
-
const isPaginationI18nDisabled = paginationLocaleInput === false;
|
|
1119
|
-
const immediatePaginationLocale = _react.useMemo.call(void 0,
|
|
1120
|
-
() => paginationLocaleInput && !isPaginationI18nDisabled ? _tigercatcore.getImmediateTigerLocale.call(void 0, paginationLocaleInput) : void 0,
|
|
1121
|
-
[isPaginationI18nDisabled, paginationLocaleInput]
|
|
1122
|
-
);
|
|
1123
|
-
const [resolvedPaginationLocale, setResolvedPaginationLocale] = _react.useState.call(void 0, immediatePaginationLocale);
|
|
1124
|
-
const immediateTableLocale = _react.useMemo.call(void 0,
|
|
1125
|
-
() => tableLocaleInput ? _tigercatcore.getImmediateTigerLocale.call(void 0, tableLocaleInput) : void 0,
|
|
1126
|
-
[tableLocaleInput]
|
|
1127
|
-
);
|
|
1128
|
-
const [resolvedTableLocale, setResolvedTableLocale] = _react.useState.call(void 0,
|
|
1129
|
-
immediateTableLocale
|
|
1130
|
-
);
|
|
1131
|
-
_react.useEffect.call(void 0, () => {
|
|
1132
|
-
let active = true;
|
|
1133
|
-
setResolvedPaginationLocale(immediatePaginationLocale);
|
|
1134
|
-
if (paginationLocaleInput && !isPaginationI18nDisabled && _tigercatcore.isLazyTigerLocale.call(void 0, paginationLocaleInput)) {
|
|
1135
|
-
_tigercatcore.resolveTigerLocale.call(void 0, paginationLocaleInput).then((nextLocale) => {
|
|
1136
|
-
if (active) setResolvedPaginationLocale(nextLocale);
|
|
1137
|
-
}).catch(() => {
|
|
1138
|
-
if (active) setResolvedPaginationLocale(immediatePaginationLocale);
|
|
1139
|
-
});
|
|
1140
|
-
}
|
|
1141
|
-
return () => {
|
|
1142
|
-
active = false;
|
|
1143
|
-
};
|
|
1144
|
-
}, [isPaginationI18nDisabled, paginationLocaleInput, immediatePaginationLocale]);
|
|
1145
|
-
_react.useEffect.call(void 0, () => {
|
|
1146
|
-
let active = true;
|
|
1147
|
-
setResolvedTableLocale(immediateTableLocale);
|
|
1148
|
-
if (tableLocaleInput && _tigercatcore.isLazyTigerLocale.call(void 0, tableLocaleInput)) {
|
|
1149
|
-
_tigercatcore.resolveTigerLocale.call(void 0, tableLocaleInput).then((nextLocale) => {
|
|
1150
|
-
if (active) setResolvedTableLocale(nextLocale);
|
|
1151
|
-
}).catch(() => {
|
|
1152
|
-
if (active) setResolvedTableLocale(immediateTableLocale);
|
|
1153
|
-
});
|
|
1154
|
-
}
|
|
1155
|
-
return () => {
|
|
1156
|
-
active = false;
|
|
1157
|
-
};
|
|
1158
|
-
}, [tableLocaleInput, immediateTableLocale]);
|
|
1159
|
-
const paginationLocale = _react.useMemo.call(void 0,
|
|
1160
|
-
() => isPaginationI18nDisabled ? void 0 : _tigercatcore.mergeTigerLocale.call(void 0, config.locale, resolvedPaginationLocale),
|
|
1161
|
-
[config.locale, isPaginationI18nDisabled, resolvedPaginationLocale]
|
|
1162
|
-
);
|
|
1163
|
-
const tableLocale = _react.useMemo.call(void 0,
|
|
1164
|
-
() => _tigercatcore.mergeTigerLocale.call(void 0, config.locale, resolvedTableLocale),
|
|
1165
|
-
[config.locale, resolvedTableLocale]
|
|
1166
|
-
);
|
|
1167
|
-
const tableLabelOverrides = _react.useMemo.call(void 0,
|
|
1168
|
-
() => emptyText === void 0 ? labels : { ...labels, emptyText },
|
|
1169
|
-
[emptyText, labels]
|
|
1170
|
-
);
|
|
1171
|
-
const tableLabels = _react.useMemo.call(void 0,
|
|
1172
|
-
() => _tigercatcore.getTableLabels.call(void 0, tableLocale, tableLabelOverrides),
|
|
1173
|
-
[tableLabelOverrides, tableLocale]
|
|
1174
|
-
);
|
|
1175
|
-
const ctx = useTableState({
|
|
1176
|
-
columns,
|
|
1177
|
-
dataSource,
|
|
1178
|
-
hiddenColumnKeys,
|
|
1179
|
-
defaultHiddenColumnKeys,
|
|
1180
|
-
sort,
|
|
1181
|
-
defaultSort,
|
|
1182
|
-
filters,
|
|
1183
|
-
defaultFilters,
|
|
1184
|
-
pagination,
|
|
1185
|
-
rowSelection: internalRowSelection,
|
|
1186
|
-
expandable: internalExpandable,
|
|
1187
|
-
rowKey,
|
|
1188
|
-
editable,
|
|
1189
|
-
editableCells,
|
|
1190
|
-
filterMode,
|
|
1191
|
-
advancedFilterRules,
|
|
1192
|
-
groupBy,
|
|
1193
|
-
exportFormat,
|
|
1194
|
-
exportFilename,
|
|
1195
|
-
measuredColumnWidths,
|
|
1196
|
-
onChange,
|
|
1197
|
-
onRowClick,
|
|
1198
|
-
onSelectionChange,
|
|
1199
|
-
onSortChange,
|
|
1200
|
-
onFilterChange,
|
|
1201
|
-
onHiddenColumnKeysChange,
|
|
1202
|
-
onPageChange,
|
|
1203
|
-
onExpandChange,
|
|
1204
|
-
onCellChange,
|
|
1205
|
-
onColumnOrderChange,
|
|
1206
|
-
onRowOrderChange,
|
|
1207
|
-
onExport
|
|
1208
|
-
});
|
|
1209
|
-
const cardLayoutMap = _react.useMemo.call(void 0, () => {
|
|
1210
|
-
const map = /* @__PURE__ */ new Map();
|
|
1211
|
-
if (cardLayout) {
|
|
1212
|
-
for (const item of cardLayout) {
|
|
1213
|
-
map.set(item.key, item);
|
|
1214
|
-
}
|
|
1215
|
-
}
|
|
1216
|
-
return map;
|
|
1217
|
-
}, [cardLayout]);
|
|
1218
|
-
const hasCustomCardLayout = _react.useMemo.call(void 0, () => {
|
|
1219
|
-
return ctx.displayColumns.some((col) => col.cardGrid) || cardLayout && cardLayout.length > 0;
|
|
1220
|
-
}, [ctx.displayColumns, cardLayout]);
|
|
1221
|
-
const virtualRecommendation = _react.useMemo.call(void 0,
|
|
1222
|
-
() => _tigercatcore.getTableVirtualRecommendation.call(void 0, {
|
|
1223
|
-
virtual,
|
|
1224
|
-
autoVirtual,
|
|
1225
|
-
dataLength: dataSource.length,
|
|
1226
|
-
threshold: virtualThreshold,
|
|
1227
|
-
autoThreshold: autoVirtualThreshold
|
|
1228
|
-
}),
|
|
1229
|
-
[autoVirtual, autoVirtualThreshold, dataSource.length, virtual, virtualThreshold]
|
|
1230
|
-
);
|
|
1231
|
-
const effectiveVirtual = virtualRecommendation.enabled;
|
|
1232
|
-
const [virtualScrollTop, setVirtualScrollTop] = _react.useState.call(void 0, 0);
|
|
1233
|
-
const virtualWindow = _react.useMemo.call(void 0,
|
|
1234
|
-
() => effectiveVirtual ? _tigercatcore.getTableVirtualWindow.call(void 0,
|
|
1235
|
-
virtualScrollTop,
|
|
1236
|
-
typeof virtualHeight === "number" ? virtualHeight : 400,
|
|
1237
|
-
virtualItemHeight,
|
|
1238
|
-
ctx.paginatedData.length
|
|
1239
|
-
) : void 0,
|
|
1240
|
-
[effectiveVirtual, virtualScrollTop, virtualHeight, virtualItemHeight, ctx.paginatedData.length]
|
|
1241
|
-
);
|
|
1242
|
-
const wrapperStyle = _react.useMemo.call(void 0, () => {
|
|
1243
|
-
if (effectiveVirtual) {
|
|
1244
|
-
return {
|
|
1245
|
-
height: typeof virtualHeight === "number" ? `${virtualHeight}px` : virtualHeight,
|
|
1246
|
-
overflow: "auto"
|
|
1247
|
-
};
|
|
1248
|
-
}
|
|
1249
|
-
return maxHeight ? {
|
|
1250
|
-
maxHeight: typeof maxHeight === "number" ? `${maxHeight}px` : maxHeight
|
|
1251
|
-
} : void 0;
|
|
1252
|
-
}, [effectiveVirtual, maxHeight, virtualHeight]);
|
|
1253
|
-
_react.useEffect.call(void 0, () => {
|
|
1254
|
-
const wrapper = wrapperRef.current;
|
|
1255
|
-
if (!wrapper) {
|
|
1256
|
-
return void 0;
|
|
1257
|
-
}
|
|
1258
|
-
const controller = _tigercatcore.createTableResizeObserverController.call(void 0, {
|
|
1259
|
-
onResize: (snapshot) => {
|
|
1260
|
-
setMeasuredColumnWidths(
|
|
1261
|
-
(prev) => areNumberRecordsEqual(prev, snapshot.columnWidths) ? prev : snapshot.columnWidths
|
|
1262
|
-
);
|
|
1263
|
-
setMeasuredRowHeights(
|
|
1264
|
-
(prev) => areNumberArraysEqual(prev, snapshot.rowHeights) ? prev : snapshot.rowHeights
|
|
1265
|
-
);
|
|
1266
|
-
}
|
|
1267
|
-
});
|
|
1268
|
-
controller.observe(wrapper, tableRef.current);
|
|
1269
|
-
return () => controller.disconnect();
|
|
1270
|
-
}, [ctx.displayColumns.length, ctx.paginatedData.length]);
|
|
1271
|
-
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
1272
|
-
"div",
|
|
1273
|
-
{
|
|
1274
|
-
ref: wrapperRef,
|
|
1275
|
-
className: _tigercatcore.getTableWrapperClasses.call(void 0,
|
|
1276
|
-
bordered,
|
|
1277
|
-
maxHeight || (virtual ? virtualHeight : void 0)
|
|
1278
|
-
),
|
|
1279
|
-
style: wrapperStyle,
|
|
1280
|
-
onScroll: effectiveVirtual ? (e) => setVirtualScrollTop(e.target.scrollTop) : void 0,
|
|
1281
|
-
"data-tiger-virtual": virtualRecommendation.enabled ? "enabled" : void 0,
|
|
1282
|
-
"data-tiger-virtual-auto": virtualRecommendation.autoEnabled ? "true" : void 0,
|
|
1283
|
-
"data-tiger-virtual-recommended": virtualRecommendation.recommended ? "true" : void 0,
|
|
1284
|
-
"data-tiger-virtual-threshold": virtualRecommendation.recommended ? virtualRecommendation.threshold : void 0,
|
|
1285
|
-
"data-tiger-measured-row-height": measuredRowHeights[0] || void 0,
|
|
1286
|
-
"aria-busy": loading,
|
|
1287
|
-
children: [
|
|
1288
|
-
exportable && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mb-2 flex justify-end", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1289
|
-
"button",
|
|
1290
|
-
{
|
|
1291
|
-
type: "button",
|
|
1292
|
-
className: _tigercatcore.tableExportButtonClasses,
|
|
1293
|
-
"aria-label": exportFormat === "excel" ? tableLabels.exportExcelAriaLabel : tableLabels.exportCsvAriaLabel,
|
|
1294
|
-
onClick: ctx.handleExport,
|
|
1295
|
-
children: exportFormat === "excel" ? tableLabels.exportExcelText : tableLabels.exportCsvText
|
|
1296
|
-
}
|
|
1297
|
-
) }),
|
|
1298
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
1299
|
-
"table",
|
|
1300
|
-
{
|
|
1301
|
-
ref: tableRef,
|
|
1302
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
1303
|
-
_tigercatcore.tableBaseClasses,
|
|
1304
|
-
_tigercatcore.getTableResponsiveTableClasses.call(void 0, responsiveMode, cardBreakpoint),
|
|
1305
|
-
tableLayout === "fixed" ? "table-fixed" : "table-auto",
|
|
1306
|
-
className
|
|
1307
|
-
),
|
|
1308
|
-
...props,
|
|
1309
|
-
style: ctx.fixedColumnsInfo.hasFixedColumns && ctx.fixedColumnsInfo.minTableWidth ? {
|
|
1310
|
-
...props.style,
|
|
1311
|
-
minWidth: `${ctx.fixedColumnsInfo.minTableWidth}px`
|
|
1312
|
-
} : props.style,
|
|
1313
|
-
children: [
|
|
1314
|
-
(columnLockable || ctx.fixedColumnsInfo.hasFixedColumns) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "colgroup", { children: _tigercatcore.getTableColgroup.call(void 0, {
|
|
1315
|
-
columns: ctx.displayColumns,
|
|
1316
|
-
frozenWidths: ctx.frozenColumnWidths,
|
|
1317
|
-
size,
|
|
1318
|
-
hasSelectionColumn: !!internalRowSelection && internalRowSelection.showCheckbox !== false,
|
|
1319
|
-
expand: internalExpandable ? internalExpandable.expandIconPosition === "end" ? "end" : "start" : false
|
|
1320
|
-
}).map((entry, index) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1321
|
-
"col",
|
|
1322
|
-
{
|
|
1323
|
-
style: entry.width ? { width: entry.width } : void 0
|
|
1324
|
-
},
|
|
1325
|
-
`${entry.key}-${index}`
|
|
1326
|
-
)) }),
|
|
1327
|
-
renderTableHeader(ctx, {
|
|
1328
|
-
size,
|
|
1329
|
-
stickyHeader,
|
|
1330
|
-
rowSelection: internalRowSelection,
|
|
1331
|
-
expandable: internalExpandable,
|
|
1332
|
-
columnLockable,
|
|
1333
|
-
columnDraggable,
|
|
1334
|
-
lockColumnAriaLabel: tableLabels.lockColumnAriaLabel,
|
|
1335
|
-
unlockColumnAriaLabel: tableLabels.unlockColumnAriaLabel,
|
|
1336
|
-
labels: tableLabels
|
|
1337
|
-
}),
|
|
1338
|
-
renderTableBody(ctx, {
|
|
1339
|
-
size,
|
|
1340
|
-
hoverable,
|
|
1341
|
-
striped,
|
|
1342
|
-
loading,
|
|
1343
|
-
emptyText: tableLabels.emptyText,
|
|
1344
|
-
rowSelection: internalRowSelection,
|
|
1345
|
-
expandable: internalExpandable,
|
|
1346
|
-
labels: tableLabels,
|
|
1347
|
-
rowClassName: internalRowClassName,
|
|
1348
|
-
rowDraggable,
|
|
1349
|
-
interactiveRows: !!onRowClick || !!internalRowSelection,
|
|
1350
|
-
virtualWindow
|
|
1351
|
-
}),
|
|
1352
|
-
renderSummaryRow(ctx, {
|
|
1353
|
-
size,
|
|
1354
|
-
rowSelection: internalRowSelection,
|
|
1355
|
-
expandable: internalExpandable,
|
|
1356
|
-
summaryRow
|
|
1357
|
-
})
|
|
1358
|
-
]
|
|
1359
|
-
}
|
|
1360
|
-
),
|
|
1361
|
-
responsiveMode === "card" && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
1362
|
-
"div",
|
|
1363
|
-
{
|
|
1364
|
-
className: _tigercatcore.getTableResponsiveCardListClasses.call(void 0, cardBreakpoint),
|
|
1365
|
-
"data-tiger-table-mobile": "card",
|
|
1366
|
-
children: [
|
|
1367
|
-
_optionalChain([internalRowSelection, 'optionalAccess', _68 => _68.type]) !== "radio" && _optionalChain([internalRowSelection, 'optionalAccess', _69 => _69.showCheckbox]) !== false && internalRowSelection && ctx.paginatedData.length > 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex items-center justify-between rounded-[var(--tiger-radius-md,0.5rem)] border border-[var(--tiger-border,#e5e7eb)] bg-[var(--tiger-surface,#ffffff)] px-3 py-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1368
|
-
_chunkLZG24TDBjs.Checkbox,
|
|
1369
|
-
{
|
|
1370
|
-
size: "sm",
|
|
1371
|
-
checked: ctx.allSelected,
|
|
1372
|
-
indeterminate: ctx.someSelected,
|
|
1373
|
-
onChange: (checked) => ctx.handleSelectAll(checked),
|
|
1374
|
-
children: tableLabels.selectAllText
|
|
1375
|
-
}
|
|
1376
|
-
) }) : null,
|
|
1377
|
-
ctx.displayColumns.some((column) => column.sortable) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rounded-[var(--tiger-radius-md,0.5rem)] border border-[var(--tiger-border,#e5e7eb)] bg-[var(--tiger-surface,#ffffff)] px-3 py-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1378
|
-
_chunkHFGTJEQWjs.Select,
|
|
1379
|
-
{
|
|
1380
|
-
size: "sm",
|
|
1381
|
-
value: ctx.sortState.key && ctx.sortState.direction ? `${ctx.sortState.key}:${ctx.sortState.direction}` : "",
|
|
1382
|
-
options: [
|
|
1383
|
-
{ label: tableLabels.clearSortText, value: "" },
|
|
1384
|
-
...ctx.displayColumns.filter((column) => column.sortable).flatMap((column) => [
|
|
1385
|
-
{
|
|
1386
|
-
label: `${_tigercatcore.formatTableSortByText.call(void 0, tableLabels.sortByText, column.title)} \u2191`,
|
|
1387
|
-
value: `${column.key}:asc`
|
|
1388
|
-
},
|
|
1389
|
-
{
|
|
1390
|
-
label: `${_tigercatcore.formatTableSortByText.call(void 0, tableLabels.sortByText, column.title)} \u2193`,
|
|
1391
|
-
value: `${column.key}:desc`
|
|
1392
|
-
}
|
|
1393
|
-
])
|
|
1394
|
-
],
|
|
1395
|
-
clearable: false,
|
|
1396
|
-
onChange: (value) => {
|
|
1397
|
-
const nextValue = String(_nullishCoalesce(value, () => ( "")));
|
|
1398
|
-
if (!nextValue) {
|
|
1399
|
-
ctx.handleSetSort({ key: null, direction: null });
|
|
1400
|
-
return;
|
|
1401
|
-
}
|
|
1402
|
-
const separatorIndex = nextValue.lastIndexOf(":");
|
|
1403
|
-
const key = nextValue.slice(0, separatorIndex);
|
|
1404
|
-
const direction = nextValue.slice(separatorIndex + 1);
|
|
1405
|
-
ctx.handleSetSort({ key, direction });
|
|
1406
|
-
}
|
|
1407
|
-
}
|
|
1408
|
-
) }) : null,
|
|
1409
|
-
ctx.paginatedData.length === 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: _tigercatcore.getTableResponsiveCardClasses.call(void 0, cardPadding), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBR3WLDH7js.Empty, { showImage: false, description: tableLabels.emptyText }) }) : ctx.paginatedData.map((record, index) => {
|
|
1410
|
-
const key = ctx.pageRowKeys[index];
|
|
1411
|
-
const isExpanded = ctx.expandedRowKeySet.has(key);
|
|
1412
|
-
const isSelected = ctx.selectedRowKeySet.has(key);
|
|
1413
|
-
const isRowExpandable = internalExpandable ? internalExpandable.rowExpandable ? internalExpandable.rowExpandable(record) : true : false;
|
|
1414
|
-
const expandedContent = internalExpandable && isExpanded && isRowExpandable ? _optionalChain([internalExpandable, 'access', _70 => _70.expandedRowRender, 'optionalCall', _71 => _71(record, index)]) : null;
|
|
1415
|
-
const expandedNode = expandedContent;
|
|
1416
|
-
const renderContext = {
|
|
1417
|
-
record,
|
|
1418
|
-
index,
|
|
1419
|
-
columns: ctx.displayColumns,
|
|
1420
|
-
selected: isSelected,
|
|
1421
|
-
expanded: isExpanded,
|
|
1422
|
-
toggleExpand: () => ctx.handleToggleExpand(key, record),
|
|
1423
|
-
selectRow: (checked) => ctx.handleSelectRow(key, checked)
|
|
1424
|
-
};
|
|
1425
|
-
const customCard = _optionalChain([renderCard, 'optionalCall', _72 => _72(renderContext)]);
|
|
1426
|
-
const resolvedCardClassName = typeof cardClassName === "function" ? cardClassName(record, index) : cardClassName;
|
|
1427
|
-
const controlsNode = _optionalChain([internalRowSelection, 'optionalAccess', _73 => _73.showCheckbox]) !== false && internalRowSelection || internalExpandable && isRowExpandable ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
1428
|
-
internalRowSelection && internalRowSelection.showCheckbox !== false && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { onClick: (event) => event.stopPropagation(), children: internalRowSelection.type === "radio" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1429
|
-
_chunk5ALMTE35js.Radio,
|
|
1430
|
-
{
|
|
1431
|
-
value: key,
|
|
1432
|
-
checked: isSelected,
|
|
1433
|
-
disabled: _optionalChain([internalRowSelection, 'access', _74 => _74.getCheckboxProps, 'optionalCall', _75 => _75(record), 'optionalAccess', _76 => _76.disabled]),
|
|
1434
|
-
"aria-label": _tigercatcore.formatTableSelectRowAriaLabel.call(void 0,
|
|
1435
|
-
tableLabels.selectRowAriaLabel,
|
|
1436
|
-
index + 1,
|
|
1437
|
-
_optionalChain([tableLocale, 'optionalAccess', _77 => _77.locale])
|
|
1438
|
-
),
|
|
1439
|
-
onChange: () => ctx.handleSelectRow(key, true)
|
|
1440
|
-
}
|
|
1441
|
-
) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1442
|
-
_chunkLZG24TDBjs.Checkbox,
|
|
1443
|
-
{
|
|
1444
|
-
size: "sm",
|
|
1445
|
-
checked: isSelected,
|
|
1446
|
-
disabled: _optionalChain([internalRowSelection, 'access', _78 => _78.getCheckboxProps, 'optionalCall', _79 => _79(record), 'optionalAccess', _80 => _80.disabled]),
|
|
1447
|
-
"aria-label": _tigercatcore.formatTableSelectRowAriaLabel.call(void 0,
|
|
1448
|
-
tableLabels.selectRowAriaLabel,
|
|
1449
|
-
index + 1,
|
|
1450
|
-
_optionalChain([tableLocale, 'optionalAccess', _81 => _81.locale])
|
|
1451
|
-
),
|
|
1452
|
-
onChange: (checked) => ctx.handleSelectRow(key, checked)
|
|
1453
|
-
}
|
|
1454
|
-
) }),
|
|
1455
|
-
internalExpandable && isRowExpandable && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1456
|
-
"button",
|
|
1457
|
-
{
|
|
1458
|
-
type: "button",
|
|
1459
|
-
className: "text-sm text-[var(--tiger-primary,#2563eb)]",
|
|
1460
|
-
"aria-expanded": isExpanded,
|
|
1461
|
-
onClick: (event) => {
|
|
1462
|
-
event.stopPropagation();
|
|
1463
|
-
ctx.handleToggleExpand(key, record);
|
|
1464
|
-
},
|
|
1465
|
-
children: isExpanded ? tableLabels.collapseText : tableLabels.expandText
|
|
1466
|
-
}
|
|
1467
|
-
)
|
|
1468
|
-
] }) : null;
|
|
1469
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1470
|
-
"div",
|
|
1471
|
-
{
|
|
1472
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
1473
|
-
_tigercatcore.getTableResponsiveCardClasses.call(void 0, cardPadding),
|
|
1474
|
-
resolvedCardClassName
|
|
1475
|
-
),
|
|
1476
|
-
onClick: () => ctx.handleRowClick(record, index, key),
|
|
1477
|
-
children: customCard !== void 0 && customCard !== null ? customCard : /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
1478
|
-
(() => {
|
|
1479
|
-
const { titleColumn, bodyColumns } = _tigercatcore.getCardColumns.call(void 0, ctx.displayColumns);
|
|
1480
|
-
const renderCellContent = (column) => {
|
|
1481
|
-
const dataKey = column.dataKey || column.key;
|
|
1482
|
-
return column.render ? column.render(record, index) : record[dataKey];
|
|
1483
|
-
};
|
|
1484
|
-
if (hasCustomCardLayout) {
|
|
1485
|
-
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
1486
|
-
titleColumn && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
1487
|
-
"div",
|
|
1488
|
-
{
|
|
1489
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
1490
|
-
_tigercatcore.tableResponsiveCardTitleClasses,
|
|
1491
|
-
cardSelectionPosition === "title-inline" && controlsNode && "flex items-center gap-3"
|
|
1492
|
-
),
|
|
1493
|
-
children: [
|
|
1494
|
-
cardSelectionPosition === "title-inline" && controlsNode,
|
|
1495
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "min-w-0 flex-1", children: renderCellContent(titleColumn) })
|
|
1496
|
-
]
|
|
1497
|
-
}
|
|
1498
|
-
),
|
|
1499
|
-
(!titleColumn || cardSelectionPosition !== "title-inline") && controlsNode && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mb-2 flex items-center gap-3", children: controlsNode }),
|
|
1500
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: _tigercatcore.classNames.call(void 0, "grid grid-cols-12 mt-2", cardFieldGap), children: bodyColumns.map((column) => {
|
|
1501
|
-
const layoutItem = cardLayoutMap.get(column.key);
|
|
1502
|
-
const gridInfo = _tigercatcore.getCardGridInfo.call(void 0, column, layoutItem);
|
|
1503
|
-
if (gridInfo.hideLabel) {
|
|
1504
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1505
|
-
"div",
|
|
1506
|
-
{
|
|
1507
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
1508
|
-
gridInfo.className,
|
|
1509
|
-
gridInfo.divider && "border-t border-[var(--tiger-border,#e5e7eb)] pt-3"
|
|
1510
|
-
),
|
|
1511
|
-
children: renderCellContent(column)
|
|
1512
|
-
},
|
|
1513
|
-
column.key
|
|
1514
|
-
);
|
|
1515
|
-
}
|
|
1516
|
-
if (gridInfo.labelPosition === "top") {
|
|
1517
|
-
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
1518
|
-
"div",
|
|
1519
|
-
{
|
|
1520
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
1521
|
-
gridInfo.className,
|
|
1522
|
-
gridInfo.divider && "border-t border-[var(--tiger-border,#e5e7eb)] pt-3"
|
|
1523
|
-
),
|
|
1524
|
-
children: [
|
|
1525
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1526
|
-
"div",
|
|
1527
|
-
{
|
|
1528
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
1529
|
-
"text-xs font-medium uppercase tracking-wider text-[var(--tiger-text-muted,#6b7280)] mb-1",
|
|
1530
|
-
gridInfo.labelClassName
|
|
1531
|
-
),
|
|
1532
|
-
children: column.title
|
|
1533
|
-
}
|
|
1534
|
-
),
|
|
1535
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1536
|
-
"div",
|
|
1537
|
-
{
|
|
1538
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
1539
|
-
"min-w-0 text-sm text-[var(--tiger-text,#111827)] break-words",
|
|
1540
|
-
gridInfo.valueClassName
|
|
1541
|
-
),
|
|
1542
|
-
children: renderCellContent(column)
|
|
1543
|
-
}
|
|
1544
|
-
)
|
|
1545
|
-
]
|
|
1546
|
-
},
|
|
1547
|
-
column.key
|
|
1548
|
-
);
|
|
1549
|
-
}
|
|
1550
|
-
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
1551
|
-
"div",
|
|
1552
|
-
{
|
|
1553
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
1554
|
-
gridInfo.className,
|
|
1555
|
-
"grid grid-cols-[auto_1fr] gap-2 items-baseline",
|
|
1556
|
-
gridInfo.divider && "border-t border-[var(--tiger-border,#e5e7eb)] pt-3"
|
|
1557
|
-
),
|
|
1558
|
-
children: [
|
|
1559
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1560
|
-
"div",
|
|
1561
|
-
{
|
|
1562
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
1563
|
-
"text-xs font-medium uppercase tracking-wider text-[var(--tiger-text-muted,#6b7280)] shrink-0",
|
|
1564
|
-
gridInfo.labelClassName
|
|
1565
|
-
),
|
|
1566
|
-
children: column.title
|
|
1567
|
-
}
|
|
1568
|
-
),
|
|
1569
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1570
|
-
"div",
|
|
1571
|
-
{
|
|
1572
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
1573
|
-
"min-w-0 text-sm text-[var(--tiger-text,#111827)] break-words",
|
|
1574
|
-
gridInfo.valueClassName
|
|
1575
|
-
),
|
|
1576
|
-
children: renderCellContent(column)
|
|
1577
|
-
}
|
|
1578
|
-
)
|
|
1579
|
-
]
|
|
1580
|
-
},
|
|
1581
|
-
column.key
|
|
1582
|
-
);
|
|
1583
|
-
}) })
|
|
1584
|
-
] });
|
|
1585
|
-
}
|
|
1586
|
-
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
1587
|
-
titleColumn && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
1588
|
-
"div",
|
|
1589
|
-
{
|
|
1590
|
-
className: _tigercatcore.classNames.call(void 0,
|
|
1591
|
-
_tigercatcore.tableResponsiveCardTitleClasses,
|
|
1592
|
-
cardSelectionPosition === "title-inline" && controlsNode && "flex items-center gap-3"
|
|
1593
|
-
),
|
|
1594
|
-
children: [
|
|
1595
|
-
cardSelectionPosition === "title-inline" && controlsNode,
|
|
1596
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "min-w-0 flex-1", children: renderCellContent(titleColumn) })
|
|
1597
|
-
]
|
|
1598
|
-
}
|
|
1599
|
-
),
|
|
1600
|
-
(!titleColumn || cardSelectionPosition !== "title-inline") && controlsNode && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mb-2 flex items-center gap-3", children: controlsNode }),
|
|
1601
|
-
bodyColumns.map((column) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: _tigercatcore.tableResponsiveCardRowClasses, children: [
|
|
1602
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: _tigercatcore.tableResponsiveCardLabelClasses, children: column.title }),
|
|
1603
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: _tigercatcore.tableResponsiveCardValueClasses, children: renderCellContent(column) })
|
|
1604
|
-
] }, column.key))
|
|
1605
|
-
] });
|
|
1606
|
-
})(),
|
|
1607
|
-
expandedNode && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mt-3 border-t border-[var(--tiger-border,#e5e7eb)] pt-3", children: expandedNode })
|
|
1608
|
-
] })
|
|
1609
|
-
},
|
|
1610
|
-
key
|
|
1611
|
-
);
|
|
1612
|
-
})
|
|
1613
|
-
]
|
|
1614
|
-
}
|
|
1615
|
-
),
|
|
1616
|
-
loading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
1617
|
-
"div",
|
|
1618
|
-
{
|
|
1619
|
-
className: _tigercatcore.tableLoadingOverlayClasses,
|
|
1620
|
-
role: "status",
|
|
1621
|
-
"aria-live": "polite",
|
|
1622
|
-
"aria-label": tableLabels.loadingText,
|
|
1623
|
-
children: [
|
|
1624
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, LoadingSpinner, {}),
|
|
1625
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "sr-only", children: tableLabels.loadingText })
|
|
1626
|
-
]
|
|
1627
|
-
}
|
|
1628
|
-
),
|
|
1629
|
-
renderPagination(ctx, {
|
|
1630
|
-
pagination,
|
|
1631
|
-
locale: paginationLocale,
|
|
1632
|
-
disableI18n: isPaginationI18nDisabled
|
|
1633
|
-
})
|
|
1634
|
-
]
|
|
1635
|
-
}
|
|
1636
|
-
);
|
|
1637
|
-
}
|
|
1638
|
-
function areNumberRecordsEqual(current, next) {
|
|
1639
|
-
const currentKeys = Object.keys(current);
|
|
1640
|
-
const nextKeys = Object.keys(next);
|
|
1641
|
-
return currentKeys.length === nextKeys.length && nextKeys.every((key) => current[key] === next[key]);
|
|
1642
|
-
}
|
|
1643
|
-
function areNumberArraysEqual(current, next) {
|
|
1644
|
-
return current.length === next.length && next.every((value, index) => current[index] === value);
|
|
1645
|
-
}
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
exports.Table = Table;
|