silver-ui 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +306 -0
- package/dist/chunk-25OAUQRF.cjs +151 -0
- package/dist/chunk-25OAUQRF.cjs.map +1 -0
- package/dist/chunk-2FPZULX3.cjs +713 -0
- package/dist/chunk-2FPZULX3.cjs.map +1 -0
- package/dist/chunk-2FUG6NKO.js +390 -0
- package/dist/chunk-2FUG6NKO.js.map +1 -0
- package/dist/chunk-2OXKEUKG.cjs +17 -0
- package/dist/chunk-2OXKEUKG.cjs.map +1 -0
- package/dist/chunk-2PHHFBJ3.cjs +102 -0
- package/dist/chunk-2PHHFBJ3.cjs.map +1 -0
- package/dist/chunk-2QK2NZN5.js +370 -0
- package/dist/chunk-2QK2NZN5.js.map +1 -0
- package/dist/chunk-2QM5XBX4.cjs +32 -0
- package/dist/chunk-2QM5XBX4.cjs.map +1 -0
- package/dist/chunk-2UTRYTT3.cjs +285 -0
- package/dist/chunk-2UTRYTT3.cjs.map +1 -0
- package/dist/chunk-2WP6NYYY.cjs +113 -0
- package/dist/chunk-2WP6NYYY.cjs.map +1 -0
- package/dist/chunk-2XCNB2O6.js +614 -0
- package/dist/chunk-2XCNB2O6.js.map +1 -0
- package/dist/chunk-2ZGGJWJY.cjs +145 -0
- package/dist/chunk-2ZGGJWJY.cjs.map +1 -0
- package/dist/chunk-32XQJNKY.cjs +211 -0
- package/dist/chunk-32XQJNKY.cjs.map +1 -0
- package/dist/chunk-3DE4GOZU.js +207 -0
- package/dist/chunk-3DE4GOZU.js.map +1 -0
- package/dist/chunk-3L3M7SJ3.js +24 -0
- package/dist/chunk-3L3M7SJ3.js.map +1 -0
- package/dist/chunk-3PSQDJQH.js +207 -0
- package/dist/chunk-3PSQDJQH.js.map +1 -0
- package/dist/chunk-3UUZY42Z.js +207 -0
- package/dist/chunk-3UUZY42Z.js.map +1 -0
- package/dist/chunk-47BELFYO.cjs +3549 -0
- package/dist/chunk-47BELFYO.cjs.map +1 -0
- package/dist/chunk-4A4EI26N.cjs +771 -0
- package/dist/chunk-4A4EI26N.cjs.map +1 -0
- package/dist/chunk-4W7L63LH.js +86 -0
- package/dist/chunk-4W7L63LH.js.map +1 -0
- package/dist/chunk-4XRVXUJQ.cjs +242 -0
- package/dist/chunk-4XRVXUJQ.cjs.map +1 -0
- package/dist/chunk-5EQN3YMQ.cjs +234 -0
- package/dist/chunk-5EQN3YMQ.cjs.map +1 -0
- package/dist/chunk-5G3BY75L.cjs +28 -0
- package/dist/chunk-5G3BY75L.cjs.map +1 -0
- package/dist/chunk-5OS5A27C.js +179 -0
- package/dist/chunk-5OS5A27C.js.map +1 -0
- package/dist/chunk-6BSEY2DF.js +258 -0
- package/dist/chunk-6BSEY2DF.js.map +1 -0
- package/dist/chunk-6NIFOTUZ.cjs +439 -0
- package/dist/chunk-6NIFOTUZ.cjs.map +1 -0
- package/dist/chunk-6SHL7FYO.cjs +29 -0
- package/dist/chunk-6SHL7FYO.cjs.map +1 -0
- package/dist/chunk-6SPQDYHC.cjs +455 -0
- package/dist/chunk-6SPQDYHC.cjs.map +1 -0
- package/dist/chunk-6UVJUY7Z.cjs +142 -0
- package/dist/chunk-6UVJUY7Z.cjs.map +1 -0
- package/dist/chunk-7EXVJWG5.js +151 -0
- package/dist/chunk-7EXVJWG5.js.map +1 -0
- package/dist/chunk-A45WLNF7.cjs +10 -0
- package/dist/chunk-A45WLNF7.cjs.map +1 -0
- package/dist/chunk-AFT635BR.cjs +308 -0
- package/dist/chunk-AFT635BR.cjs.map +1 -0
- package/dist/chunk-AZDWQGAX.cjs +286 -0
- package/dist/chunk-AZDWQGAX.cjs.map +1 -0
- package/dist/chunk-BCJ25X7C.js +281 -0
- package/dist/chunk-BCJ25X7C.js.map +1 -0
- package/dist/chunk-BSBEPQLM.cjs +93 -0
- package/dist/chunk-BSBEPQLM.cjs.map +1 -0
- package/dist/chunk-BTBOTNOE.cjs +261 -0
- package/dist/chunk-BTBOTNOE.cjs.map +1 -0
- package/dist/chunk-C2CNRYZI.cjs +453 -0
- package/dist/chunk-C2CNRYZI.cjs.map +1 -0
- package/dist/chunk-CA6645TQ.js +287 -0
- package/dist/chunk-CA6645TQ.js.map +1 -0
- package/dist/chunk-CK3UJQRI.cjs +104 -0
- package/dist/chunk-CK3UJQRI.cjs.map +1 -0
- package/dist/chunk-CR4NB42L.cjs +375 -0
- package/dist/chunk-CR4NB42L.cjs.map +1 -0
- package/dist/chunk-CVH6X6ND.js +125 -0
- package/dist/chunk-CVH6X6ND.js.map +1 -0
- package/dist/chunk-CWUC4TOQ.js +255 -0
- package/dist/chunk-CWUC4TOQ.js.map +1 -0
- package/dist/chunk-CXBB2LN7.js +12 -0
- package/dist/chunk-CXBB2LN7.js.map +1 -0
- package/dist/chunk-CZJUKLFD.cjs +169 -0
- package/dist/chunk-CZJUKLFD.cjs.map +1 -0
- package/dist/chunk-D6KXW75E.js +424 -0
- package/dist/chunk-D6KXW75E.js.map +1 -0
- package/dist/chunk-DFF72N57.js +192 -0
- package/dist/chunk-DFF72N57.js.map +1 -0
- package/dist/chunk-DHUK3GNK.cjs +258 -0
- package/dist/chunk-DHUK3GNK.cjs.map +1 -0
- package/dist/chunk-DJW7T3WJ.js +2019 -0
- package/dist/chunk-DJW7T3WJ.js.map +1 -0
- package/dist/chunk-DNVOWNQG.cjs +209 -0
- package/dist/chunk-DNVOWNQG.cjs.map +1 -0
- package/dist/chunk-DONU5ALC.cjs +330 -0
- package/dist/chunk-DONU5ALC.cjs.map +1 -0
- package/dist/chunk-E4TIWN4Z.cjs +153 -0
- package/dist/chunk-E4TIWN4Z.cjs.map +1 -0
- package/dist/chunk-E7EO3YVJ.js +323 -0
- package/dist/chunk-E7EO3YVJ.js.map +1 -0
- package/dist/chunk-EB5EHX6I.js +143 -0
- package/dist/chunk-EB5EHX6I.js.map +1 -0
- package/dist/chunk-EBUSMPS6.js +306 -0
- package/dist/chunk-EBUSMPS6.js.map +1 -0
- package/dist/chunk-EETTQWW5.cjs +142 -0
- package/dist/chunk-EETTQWW5.cjs.map +1 -0
- package/dist/chunk-EHBV6ZMM.js +239 -0
- package/dist/chunk-EHBV6ZMM.js.map +1 -0
- package/dist/chunk-ELCRG7WZ.js +2090 -0
- package/dist/chunk-ELCRG7WZ.js.map +1 -0
- package/dist/chunk-EM2F6BZ2.js +355 -0
- package/dist/chunk-EM2F6BZ2.js.map +1 -0
- package/dist/chunk-F7AUYO3H.cjs +211 -0
- package/dist/chunk-F7AUYO3H.cjs.map +1 -0
- package/dist/chunk-FVIEYPDB.js +490 -0
- package/dist/chunk-FVIEYPDB.js.map +1 -0
- package/dist/chunk-G44NDBPN.cjs +62 -0
- package/dist/chunk-G44NDBPN.cjs.map +1 -0
- package/dist/chunk-GI3NLBCW.cjs +375 -0
- package/dist/chunk-GI3NLBCW.cjs.map +1 -0
- package/dist/chunk-GKG47NK6.cjs +2505 -0
- package/dist/chunk-GKG47NK6.cjs.map +1 -0
- package/dist/chunk-GUF4ZNPQ.js +138 -0
- package/dist/chunk-GUF4ZNPQ.js.map +1 -0
- package/dist/chunk-GZ5SRSD4.js +194 -0
- package/dist/chunk-GZ5SRSD4.js.map +1 -0
- package/dist/chunk-H6OY6FLC.js +139 -0
- package/dist/chunk-H6OY6FLC.js.map +1 -0
- package/dist/chunk-HPZ7LLXK.js +367 -0
- package/dist/chunk-HPZ7LLXK.js.map +1 -0
- package/dist/chunk-HWCL6JFB.js +149 -0
- package/dist/chunk-HWCL6JFB.js.map +1 -0
- package/dist/chunk-HXT6A6GH.cjs +61 -0
- package/dist/chunk-HXT6A6GH.cjs.map +1 -0
- package/dist/chunk-I25KF3UF.js +519 -0
- package/dist/chunk-I25KF3UF.js.map +1 -0
- package/dist/chunk-I6IGTQLG.cjs +251 -0
- package/dist/chunk-I6IGTQLG.cjs.map +1 -0
- package/dist/chunk-I7PJTLP2.cjs +425 -0
- package/dist/chunk-I7PJTLP2.cjs.map +1 -0
- package/dist/chunk-IT72TF72.js +612 -0
- package/dist/chunk-IT72TF72.js.map +1 -0
- package/dist/chunk-IWSS5745.js +307 -0
- package/dist/chunk-IWSS5745.js.map +1 -0
- package/dist/chunk-JAX62FUE.cjs +75 -0
- package/dist/chunk-JAX62FUE.cjs.map +1 -0
- package/dist/chunk-JCYPM27J.js +153 -0
- package/dist/chunk-JCYPM27J.js.map +1 -0
- package/dist/chunk-K574UTWP.cjs +182 -0
- package/dist/chunk-K574UTWP.cjs.map +1 -0
- package/dist/chunk-KLMODPEE.js +8 -0
- package/dist/chunk-KLMODPEE.js.map +1 -0
- package/dist/chunk-KVREBGWA.js +711 -0
- package/dist/chunk-KVREBGWA.js.map +1 -0
- package/dist/chunk-KXXRALHT.cjs +304 -0
- package/dist/chunk-KXXRALHT.cjs.map +1 -0
- package/dist/chunk-KXXTWWJZ.cjs +71 -0
- package/dist/chunk-KXXTWWJZ.cjs.map +1 -0
- package/dist/chunk-KYDRDJRM.cjs +326 -0
- package/dist/chunk-KYDRDJRM.cjs.map +1 -0
- package/dist/chunk-L3G7SHEP.cjs +525 -0
- package/dist/chunk-L3G7SHEP.cjs.map +1 -0
- package/dist/chunk-LBRKUZSQ.cjs +258 -0
- package/dist/chunk-LBRKUZSQ.cjs.map +1 -0
- package/dist/chunk-LFZXGIR6.cjs +492 -0
- package/dist/chunk-LFZXGIR6.cjs.map +1 -0
- package/dist/chunk-MCOVG6W6.js +254 -0
- package/dist/chunk-MCOVG6W6.js.map +1 -0
- package/dist/chunk-MKAOIB2O.cjs +146 -0
- package/dist/chunk-MKAOIB2O.cjs.map +1 -0
- package/dist/chunk-NAELQLZN.js +73 -0
- package/dist/chunk-NAELQLZN.js.map +1 -0
- package/dist/chunk-NGWNIMMX.js +247 -0
- package/dist/chunk-NGWNIMMX.js.map +1 -0
- package/dist/chunk-NILB6Y4Z.cjs +313 -0
- package/dist/chunk-NILB6Y4Z.cjs.map +1 -0
- package/dist/chunk-NJDV3LDH.js +722 -0
- package/dist/chunk-NJDV3LDH.js.map +1 -0
- package/dist/chunk-NMHCRHRI.cjs +163 -0
- package/dist/chunk-NMHCRHRI.cjs.map +1 -0
- package/dist/chunk-NOZ6U6ZJ.js +140 -0
- package/dist/chunk-NOZ6U6ZJ.js.map +1 -0
- package/dist/chunk-NPJXGQOF.cjs +2031 -0
- package/dist/chunk-NPJXGQOF.cjs.map +1 -0
- package/dist/chunk-NSHWBZL4.cjs +197 -0
- package/dist/chunk-NSHWBZL4.cjs.map +1 -0
- package/dist/chunk-O32BKXTR.cjs +271 -0
- package/dist/chunk-O32BKXTR.cjs.map +1 -0
- package/dist/chunk-O5RVLBKN.cjs +252 -0
- package/dist/chunk-O5RVLBKN.cjs.map +1 -0
- package/dist/chunk-OA4KIVLO.cjs +243 -0
- package/dist/chunk-OA4KIVLO.cjs.map +1 -0
- package/dist/chunk-OAUKYH6C.cjs +15 -0
- package/dist/chunk-OAUKYH6C.cjs.map +1 -0
- package/dist/chunk-OKKL652L.js +449 -0
- package/dist/chunk-OKKL652L.js.map +1 -0
- package/dist/chunk-OX4ZMUF4.js +16 -0
- package/dist/chunk-OX4ZMUF4.js.map +1 -0
- package/dist/chunk-OZNNBPMP.cjs +288 -0
- package/dist/chunk-OZNNBPMP.cjs.map +1 -0
- package/dist/chunk-P5AZUUM2.cjs +155 -0
- package/dist/chunk-P5AZUUM2.cjs.map +1 -0
- package/dist/chunk-PBZWX2RJ.js +142 -0
- package/dist/chunk-PBZWX2RJ.js.map +1 -0
- package/dist/chunk-PDXZDPOY.cjs +617 -0
- package/dist/chunk-PDXZDPOY.cjs.map +1 -0
- package/dist/chunk-PGKOWMP4.js +297 -0
- package/dist/chunk-PGKOWMP4.js.map +1 -0
- package/dist/chunk-PHFEQG4E.cjs +89 -0
- package/dist/chunk-PHFEQG4E.cjs.map +1 -0
- package/dist/chunk-PLFKU46A.js +204 -0
- package/dist/chunk-PLFKU46A.js.map +1 -0
- package/dist/chunk-PPNETWIP.js +8 -0
- package/dist/chunk-PPNETWIP.js.map +1 -0
- package/dist/chunk-PZO5MZ46.js +3543 -0
- package/dist/chunk-PZO5MZ46.js.map +1 -0
- package/dist/chunk-QFO5ZTZZ.js +68 -0
- package/dist/chunk-QFO5ZTZZ.js.map +1 -0
- package/dist/chunk-QRDRZNCS.cjs +393 -0
- package/dist/chunk-QRDRZNCS.cjs.map +1 -0
- package/dist/chunk-QRXMW7MQ.cjs +730 -0
- package/dist/chunk-QRXMW7MQ.cjs.map +1 -0
- package/dist/chunk-QSEDH7T2.js +84 -0
- package/dist/chunk-QSEDH7T2.js.map +1 -0
- package/dist/chunk-QXI446BK.cjs +209 -0
- package/dist/chunk-QXI446BK.cjs.map +1 -0
- package/dist/chunk-R2NQNVEV.js +2476 -0
- package/dist/chunk-R2NQNVEV.js.map +1 -0
- package/dist/chunk-R37R7DEV.cjs +20 -0
- package/dist/chunk-R37R7DEV.cjs.map +1 -0
- package/dist/chunk-RCAA2CZJ.js +232 -0
- package/dist/chunk-RCAA2CZJ.js.map +1 -0
- package/dist/chunk-RDNMAV5B.js +269 -0
- package/dist/chunk-RDNMAV5B.js.map +1 -0
- package/dist/chunk-RGPL6EDK.js +110 -0
- package/dist/chunk-RGPL6EDK.js.map +1 -0
- package/dist/chunk-RJQQ2UIQ.js +422 -0
- package/dist/chunk-RJQQ2UIQ.js.map +1 -0
- package/dist/chunk-RJXHAQCR.cjs +141 -0
- package/dist/chunk-RJXHAQCR.cjs.map +1 -0
- package/dist/chunk-RLQYXUDO.js +59 -0
- package/dist/chunk-RLQYXUDO.js.map +1 -0
- package/dist/chunk-S5NFDKPL.js +161 -0
- package/dist/chunk-S5NFDKPL.js.map +1 -0
- package/dist/chunk-SGLIDI6R.js +27 -0
- package/dist/chunk-SGLIDI6R.js.map +1 -0
- package/dist/chunk-SMF3YBH5.cjs +2099 -0
- package/dist/chunk-SMF3YBH5.cjs.map +1 -0
- package/dist/chunk-SPDVNY2Z.cjs +10 -0
- package/dist/chunk-SPDVNY2Z.cjs.map +1 -0
- package/dist/chunk-T55MB2CA.js +90 -0
- package/dist/chunk-T55MB2CA.js.map +1 -0
- package/dist/chunk-TPSOUQG7.cjs +309 -0
- package/dist/chunk-TPSOUQG7.cjs.map +1 -0
- package/dist/chunk-U35V3GVC.js +64 -0
- package/dist/chunk-U35V3GVC.js.map +1 -0
- package/dist/chunk-UHQRL4OA.js +278 -0
- package/dist/chunk-UHQRL4OA.js.map +1 -0
- package/dist/chunk-UWG5UQFV.cjs +66 -0
- package/dist/chunk-UWG5UQFV.cjs.map +1 -0
- package/dist/chunk-UZNSGQT3.cjs +431 -0
- package/dist/chunk-UZNSGQT3.cjs.map +1 -0
- package/dist/chunk-V5W7NZN5.js +30 -0
- package/dist/chunk-V5W7NZN5.js.map +1 -0
- package/dist/chunk-VIJHDURK.js +78 -0
- package/dist/chunk-VIJHDURK.js.map +1 -0
- package/dist/chunk-VL6IDFI2.js +206 -0
- package/dist/chunk-VL6IDFI2.js.map +1 -0
- package/dist/chunk-VLIQPSPM.js +310 -0
- package/dist/chunk-VLIQPSPM.js.map +1 -0
- package/dist/chunk-VT7VKCHL.cjs +362 -0
- package/dist/chunk-VT7VKCHL.cjs.map +1 -0
- package/dist/chunk-VTQRXV32.js +565 -0
- package/dist/chunk-VTQRXV32.js.map +1 -0
- package/dist/chunk-VVYUCQHP.js +328 -0
- package/dist/chunk-VVYUCQHP.js.map +1 -0
- package/dist/chunk-W6B55MNU.js +371 -0
- package/dist/chunk-W6B55MNU.js.map +1 -0
- package/dist/chunk-WA4DRAQ7.js +236 -0
- package/dist/chunk-WA4DRAQ7.js.map +1 -0
- package/dist/chunk-WBPIJ4D5.js +58 -0
- package/dist/chunk-WBPIJ4D5.js.map +1 -0
- package/dist/chunk-WE3ECIRS.cjs +616 -0
- package/dist/chunk-WE3ECIRS.cjs.map +1 -0
- package/dist/chunk-WEEYUS7M.cjs +222 -0
- package/dist/chunk-WEEYUS7M.cjs.map +1 -0
- package/dist/chunk-WIIDQ44X.cjs +209 -0
- package/dist/chunk-WIIDQ44X.cjs.map +1 -0
- package/dist/chunk-WIO3XITR.js +769 -0
- package/dist/chunk-WIO3XITR.js.map +1 -0
- package/dist/chunk-WIW2YR46.js +88 -0
- package/dist/chunk-WIW2YR46.js.map +1 -0
- package/dist/chunk-WM66IPV4.cjs +567 -0
- package/dist/chunk-WM66IPV4.cjs.map +1 -0
- package/dist/chunk-WSAZHUB3.cjs +373 -0
- package/dist/chunk-WSAZHUB3.cjs.map +1 -0
- package/dist/chunk-XQMLA75S.js +436 -0
- package/dist/chunk-XQMLA75S.js.map +1 -0
- package/dist/chunk-Y73472IA.js +99 -0
- package/dist/chunk-Y73472IA.js.map +1 -0
- package/dist/chunk-YHR44PWO.js +217 -0
- package/dist/chunk-YHR44PWO.js.map +1 -0
- package/dist/chunk-YLXM3CGV.js +209 -0
- package/dist/chunk-YLXM3CGV.js.map +1 -0
- package/dist/chunk-YMC56K6R.cjs +289 -0
- package/dist/chunk-YMC56K6R.cjs.map +1 -0
- package/dist/chunk-YOFCBZAX.js +286 -0
- package/dist/chunk-YOFCBZAX.js.map +1 -0
- package/dist/chunk-YOWRLFMF.cjs +128 -0
- package/dist/chunk-YOWRLFMF.cjs.map +1 -0
- package/dist/chunk-YQJJCYJP.js +449 -0
- package/dist/chunk-YQJJCYJP.js.map +1 -0
- package/dist/chunk-YRXGCYT2.js +354 -0
- package/dist/chunk-YRXGCYT2.js.map +1 -0
- package/dist/chunk-YT3UWEVY.js +81 -0
- package/dist/chunk-YT3UWEVY.js.map +1 -0
- package/dist/chunk-YX7DI3O3.cjs +358 -0
- package/dist/chunk-YX7DI3O3.cjs.map +1 -0
- package/dist/chunk-YZUBJ2L2.cjs +195 -0
- package/dist/chunk-YZUBJ2L2.cjs.map +1 -0
- package/dist/chunk-Z2STCD6I.js +165 -0
- package/dist/chunk-Z2STCD6I.js.map +1 -0
- package/dist/chunk-Z2UFJIZU.cjs +207 -0
- package/dist/chunk-Z2UFJIZU.cjs.map +1 -0
- package/dist/chunk-Z4TZAJS3.js +14 -0
- package/dist/chunk-Z4TZAJS3.js.map +1 -0
- package/dist/chunk-ZC7H4S4T.cjs +81 -0
- package/dist/chunk-ZC7H4S4T.cjs.map +1 -0
- package/dist/chunk-ZHFAFEI2.js +247 -0
- package/dist/chunk-ZHFAFEI2.js.map +1 -0
- package/dist/chunk-ZVBVKZ4P.cjs +84 -0
- package/dist/chunk-ZVBVKZ4P.cjs.map +1 -0
- package/dist/chunk-ZW4XKNDR.cjs +91 -0
- package/dist/chunk-ZW4XKNDR.cjs.map +1 -0
- package/dist/components/Accordion/Accordion.d.ts +87 -0
- package/dist/components/Accordion/Accordion.d.ts.map +1 -0
- package/dist/components/Accordion/AccordionContext.d.ts +6 -0
- package/dist/components/Accordion/AccordionContext.d.ts.map +1 -0
- package/dist/components/Accordion/AccordionItem.d.ts +64 -0
- package/dist/components/Accordion/AccordionItem.d.ts.map +1 -0
- package/dist/components/Accordion/Collapsible.d.ts +60 -0
- package/dist/components/Accordion/Collapsible.d.ts.map +1 -0
- package/dist/components/Accordion/index.cjs +24 -0
- package/dist/components/Accordion/index.cjs.map +1 -0
- package/dist/components/Accordion/index.d.ts +4 -0
- package/dist/components/Accordion/index.d.ts.map +1 -0
- package/dist/components/Accordion/index.js +7 -0
- package/dist/components/Accordion/index.js.map +1 -0
- package/dist/components/Accordion/useCollapsible.d.ts +15 -0
- package/dist/components/Accordion/useCollapsible.d.ts.map +1 -0
- package/dist/components/Alert/Alert.d.ts +79 -0
- package/dist/components/Alert/Alert.d.ts.map +1 -0
- package/dist/components/Alert/Alert.recipe.d.ts +48 -0
- package/dist/components/Alert/Alert.recipe.d.ts.map +1 -0
- package/dist/components/Alert/index.cjs +29 -0
- package/dist/components/Alert/index.cjs.map +1 -0
- package/dist/components/Alert/index.d.ts +3 -0
- package/dist/components/Alert/index.d.ts.map +1 -0
- package/dist/components/Alert/index.js +16 -0
- package/dist/components/Alert/index.js.map +1 -0
- package/dist/components/AlertDialog/AlertDialog.d.ts +72 -0
- package/dist/components/AlertDialog/AlertDialog.d.ts.map +1 -0
- package/dist/components/AlertDialog/index.cjs +32 -0
- package/dist/components/AlertDialog/index.cjs.map +1 -0
- package/dist/components/AlertDialog/index.d.ts +3 -0
- package/dist/components/AlertDialog/index.d.ts.map +1 -0
- package/dist/components/AlertDialog/index.js +19 -0
- package/dist/components/AlertDialog/index.js.map +1 -0
- package/dist/components/AlertDialog/useAlertDialog.d.ts +23 -0
- package/dist/components/AlertDialog/useAlertDialog.d.ts.map +1 -0
- package/dist/components/AppShell/AppShell.d.ts +74 -0
- package/dist/components/AppShell/AppShell.d.ts.map +1 -0
- package/dist/components/AppShell/AppShell.recipe.d.ts +21 -0
- package/dist/components/AppShell/AppShell.recipe.d.ts.map +1 -0
- package/dist/components/AppShell/AppShellMobileContext.d.ts +12 -0
- package/dist/components/AppShell/AppShellMobileContext.d.ts.map +1 -0
- package/dist/components/AppShell/index.cjs +44 -0
- package/dist/components/AppShell/index.cjs.map +1 -0
- package/dist/components/AppShell/index.d.ts +4 -0
- package/dist/components/AppShell/index.d.ts.map +1 -0
- package/dist/components/AppShell/index.js +23 -0
- package/dist/components/AppShell/index.js.map +1 -0
- package/dist/components/AppShell/useSlotPresence.d.ts +5 -0
- package/dist/components/AppShell/useSlotPresence.d.ts.map +1 -0
- package/dist/components/AspectRatio/AspectRatio.d.ts +19 -0
- package/dist/components/AspectRatio/AspectRatio.d.ts.map +1 -0
- package/dist/components/AspectRatio/AspectRatio.recipe.d.ts +4 -0
- package/dist/components/AspectRatio/AspectRatio.recipe.d.ts.map +1 -0
- package/dist/components/AspectRatio/index.cjs +19 -0
- package/dist/components/AspectRatio/index.cjs.map +1 -0
- package/dist/components/AspectRatio/index.d.ts +3 -0
- package/dist/components/AspectRatio/index.d.ts.map +1 -0
- package/dist/components/AspectRatio/index.js +6 -0
- package/dist/components/AspectRatio/index.js.map +1 -0
- package/dist/components/AutocompleteInput/AutocompleteInput.d.ts +127 -0
- package/dist/components/AutocompleteInput/AutocompleteInput.d.ts.map +1 -0
- package/dist/components/AutocompleteInput/AutocompleteInputItem.d.ts +46 -0
- package/dist/components/AutocompleteInput/AutocompleteInputItem.d.ts.map +1 -0
- package/dist/components/AutocompleteInput/BaseAutocompleteInput.d.ts +108 -0
- package/dist/components/AutocompleteInput/BaseAutocompleteInput.d.ts.map +1 -0
- package/dist/components/AutocompleteInput/index.cjs +43 -0
- package/dist/components/AutocompleteInput/index.cjs.map +1 -0
- package/dist/components/AutocompleteInput/index.d.ts +5 -0
- package/dist/components/AutocompleteInput/index.d.ts.map +1 -0
- package/dist/components/AutocompleteInput/index.js +22 -0
- package/dist/components/AutocompleteInput/index.js.map +1 -0
- package/dist/components/AutocompleteInput/types.d.ts +41 -0
- package/dist/components/AutocompleteInput/types.d.ts.map +1 -0
- package/dist/components/Avatar/Avatar.d.ts +59 -0
- package/dist/components/Avatar/Avatar.d.ts.map +1 -0
- package/dist/components/Avatar/Avatar.recipe.d.ts +19 -0
- package/dist/components/Avatar/Avatar.recipe.d.ts.map +1 -0
- package/dist/components/Avatar/AvatarSizeContext.d.ts +3 -0
- package/dist/components/Avatar/AvatarSizeContext.d.ts.map +1 -0
- package/dist/components/Avatar/AvatarStatusDot.d.ts +43 -0
- package/dist/components/Avatar/AvatarStatusDot.d.ts.map +1 -0
- package/dist/components/Avatar/index.cjs +28 -0
- package/dist/components/Avatar/index.cjs.map +1 -0
- package/dist/components/Avatar/index.d.ts +4 -0
- package/dist/components/Avatar/index.d.ts.map +1 -0
- package/dist/components/Avatar/index.js +7 -0
- package/dist/components/Avatar/index.js.map +1 -0
- package/dist/components/AvatarGroup/AvatarGroup.d.ts +44 -0
- package/dist/components/AvatarGroup/AvatarGroup.d.ts.map +1 -0
- package/dist/components/AvatarGroup/AvatarGroup.recipe.d.ts +2 -0
- package/dist/components/AvatarGroup/AvatarGroup.recipe.d.ts.map +1 -0
- package/dist/components/AvatarGroup/AvatarGroupContext.d.ts +9 -0
- package/dist/components/AvatarGroup/AvatarGroupContext.d.ts.map +1 -0
- package/dist/components/AvatarGroup/AvatarGroupOverflow.d.ts +42 -0
- package/dist/components/AvatarGroup/AvatarGroupOverflow.d.ts.map +1 -0
- package/dist/components/AvatarGroup/index.cjs +25 -0
- package/dist/components/AvatarGroup/index.cjs.map +1 -0
- package/dist/components/AvatarGroup/index.d.ts +4 -0
- package/dist/components/AvatarGroup/index.d.ts.map +1 -0
- package/dist/components/AvatarGroup/index.js +8 -0
- package/dist/components/AvatarGroup/index.js.map +1 -0
- package/dist/components/Badge/Badge.d.ts +59 -0
- package/dist/components/Badge/Badge.d.ts.map +1 -0
- package/dist/components/Badge/Badge.recipe.d.ts +83 -0
- package/dist/components/Badge/Badge.recipe.d.ts.map +1 -0
- package/dist/components/Badge/index.cjs +20 -0
- package/dist/components/Badge/index.cjs.map +1 -0
- package/dist/components/Badge/index.d.ts +3 -0
- package/dist/components/Badge/index.d.ts.map +1 -0
- package/dist/components/Badge/index.js +7 -0
- package/dist/components/Badge/index.js.map +1 -0
- package/dist/components/Blockquote/Blockquote.d.ts +38 -0
- package/dist/components/Blockquote/Blockquote.d.ts.map +1 -0
- package/dist/components/Blockquote/index.cjs +50 -0
- package/dist/components/Blockquote/index.cjs.map +1 -0
- package/dist/components/Blockquote/index.d.ts +2 -0
- package/dist/components/Blockquote/index.d.ts.map +1 -0
- package/dist/components/Blockquote/index.js +48 -0
- package/dist/components/Blockquote/index.js.map +1 -0
- package/dist/components/Breadcrumbs/BreadcrumbItem.d.ts +54 -0
- package/dist/components/Breadcrumbs/BreadcrumbItem.d.ts.map +1 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +47 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.d.ts.map +1 -0
- package/dist/components/Breadcrumbs/BreadcrumbsContext.d.ts +8 -0
- package/dist/components/Breadcrumbs/BreadcrumbsContext.d.ts.map +1 -0
- package/dist/components/Breadcrumbs/index.cjs +29 -0
- package/dist/components/Breadcrumbs/index.cjs.map +1 -0
- package/dist/components/Breadcrumbs/index.d.ts +4 -0
- package/dist/components/Breadcrumbs/index.d.ts.map +1 -0
- package/dist/components/Breadcrumbs/index.js +12 -0
- package/dist/components/Breadcrumbs/index.js.map +1 -0
- package/dist/components/Button/Button.d.ts +193 -0
- package/dist/components/Button/Button.d.ts.map +1 -0
- package/dist/components/Button/Button.recipe.d.ts +96 -0
- package/dist/components/Button/Button.recipe.d.ts.map +1 -0
- package/dist/components/Button/index.cjs +28 -0
- package/dist/components/Button/index.cjs.map +1 -0
- package/dist/components/Button/index.d.ts +3 -0
- package/dist/components/Button/index.d.ts.map +1 -0
- package/dist/components/Button/index.js +15 -0
- package/dist/components/Button/index.js.map +1 -0
- package/dist/components/ButtonGroup/ButtonGroup.d.ts +54 -0
- package/dist/components/ButtonGroup/ButtonGroup.d.ts.map +1 -0
- package/dist/components/ButtonGroup/ButtonGroup.recipe.d.ts +35 -0
- package/dist/components/ButtonGroup/ButtonGroup.recipe.d.ts.map +1 -0
- package/dist/components/ButtonGroup/ButtonGroupContext.d.ts +10 -0
- package/dist/components/ButtonGroup/ButtonGroupContext.d.ts.map +1 -0
- package/dist/components/ButtonGroup/index.cjs +20 -0
- package/dist/components/ButtonGroup/index.cjs.map +1 -0
- package/dist/components/ButtonGroup/index.d.ts +4 -0
- package/dist/components/ButtonGroup/index.d.ts.map +1 -0
- package/dist/components/ButtonGroup/index.js +7 -0
- package/dist/components/ButtonGroup/index.js.map +1 -0
- package/dist/components/Calendar/Calendar.d.ts +120 -0
- package/dist/components/Calendar/Calendar.d.ts.map +1 -0
- package/dist/components/Calendar/index.cjs +27 -0
- package/dist/components/Calendar/index.cjs.map +1 -0
- package/dist/components/Calendar/index.d.ts +2 -0
- package/dist/components/Calendar/index.d.ts.map +1 -0
- package/dist/components/Calendar/index.js +18 -0
- package/dist/components/Calendar/index.js.map +1 -0
- package/dist/components/Card/Card.d.ts +30 -0
- package/dist/components/Card/Card.d.ts.map +1 -0
- package/dist/components/Card/Card.recipe.d.ts +82 -0
- package/dist/components/Card/Card.recipe.d.ts.map +1 -0
- package/dist/components/Card/index.cjs +19 -0
- package/dist/components/Card/index.cjs.map +1 -0
- package/dist/components/Card/index.d.ts +3 -0
- package/dist/components/Card/index.d.ts.map +1 -0
- package/dist/components/Card/index.js +6 -0
- package/dist/components/Card/index.js.map +1 -0
- package/dist/components/Center/Center.d.ts +38 -0
- package/dist/components/Center/Center.d.ts.map +1 -0
- package/dist/components/Center/Center.recipe.d.ts +23 -0
- package/dist/components/Center/Center.recipe.d.ts.map +1 -0
- package/dist/components/Center/index.cjs +20 -0
- package/dist/components/Center/index.cjs.map +1 -0
- package/dist/components/Center/index.d.ts +3 -0
- package/dist/components/Center/index.d.ts.map +1 -0
- package/dist/components/Center/index.js +7 -0
- package/dist/components/Center/index.js.map +1 -0
- package/dist/components/CheckboxInput/CheckboxInput.d.ts +110 -0
- package/dist/components/CheckboxInput/CheckboxInput.d.ts.map +1 -0
- package/dist/components/CheckboxInput/index.cjs +26 -0
- package/dist/components/CheckboxInput/index.cjs.map +1 -0
- package/dist/components/CheckboxInput/index.d.ts +2 -0
- package/dist/components/CheckboxInput/index.d.ts.map +1 -0
- package/dist/components/CheckboxInput/index.js +17 -0
- package/dist/components/CheckboxInput/index.js.map +1 -0
- package/dist/components/CodeBlock/CodeBlock.d.ts +89 -0
- package/dist/components/CodeBlock/CodeBlock.d.ts.map +1 -0
- package/dist/components/CodeBlock/index.cjs +25 -0
- package/dist/components/CodeBlock/index.cjs.map +1 -0
- package/dist/components/CodeBlock/index.d.ts +2 -0
- package/dist/components/CodeBlock/index.d.ts.map +1 -0
- package/dist/components/CodeBlock/index.js +16 -0
- package/dist/components/CodeBlock/index.js.map +1 -0
- package/dist/components/ContextMenu/ContextMenu.d.ts +74 -0
- package/dist/components/ContextMenu/ContextMenu.d.ts.map +1 -0
- package/dist/components/ContextMenu/index.cjs +34 -0
- package/dist/components/ContextMenu/index.cjs.map +1 -0
- package/dist/components/ContextMenu/index.d.ts +2 -0
- package/dist/components/ContextMenu/index.d.ts.map +1 -0
- package/dist/components/ContextMenu/index.js +21 -0
- package/dist/components/ContextMenu/index.js.map +1 -0
- package/dist/components/DateInput/DateInput.d.ts +101 -0
- package/dist/components/DateInput/DateInput.d.ts.map +1 -0
- package/dist/components/DateInput/index.cjs +32 -0
- package/dist/components/DateInput/index.cjs.map +1 -0
- package/dist/components/DateInput/index.d.ts +2 -0
- package/dist/components/DateInput/index.d.ts.map +1 -0
- package/dist/components/DateInput/index.js +23 -0
- package/dist/components/DateInput/index.js.map +1 -0
- package/dist/components/DateRangeInput/DateRangeInput.d.ts +106 -0
- package/dist/components/DateRangeInput/DateRangeInput.d.ts.map +1 -0
- package/dist/components/DateRangeInput/index.cjs +32 -0
- package/dist/components/DateRangeInput/index.cjs.map +1 -0
- package/dist/components/DateRangeInput/index.d.ts +2 -0
- package/dist/components/DateRangeInput/index.d.ts.map +1 -0
- package/dist/components/DateRangeInput/index.js +23 -0
- package/dist/components/DateRangeInput/index.js.map +1 -0
- package/dist/components/DateTimeInput/DateTimeInput.d.ts +97 -0
- package/dist/components/DateTimeInput/DateTimeInput.d.ts.map +1 -0
- package/dist/components/DateTimeInput/index.cjs +34 -0
- package/dist/components/DateTimeInput/index.cjs.map +1 -0
- package/dist/components/DateTimeInput/index.d.ts +2 -0
- package/dist/components/DateTimeInput/index.d.ts.map +1 -0
- package/dist/components/DateTimeInput/index.js +25 -0
- package/dist/components/DateTimeInput/index.js.map +1 -0
- package/dist/components/Dialog/Dialog.d.ts +86 -0
- package/dist/components/Dialog/Dialog.d.ts.map +1 -0
- package/dist/components/Dialog/Dialog.recipe.d.ts +24 -0
- package/dist/components/Dialog/Dialog.recipe.d.ts.map +1 -0
- package/dist/components/Dialog/DialogContext.d.ts +6 -0
- package/dist/components/Dialog/DialogContext.d.ts.map +1 -0
- package/dist/components/Dialog/index.cjs +33 -0
- package/dist/components/Dialog/index.cjs.map +1 -0
- package/dist/components/Dialog/index.d.ts +5 -0
- package/dist/components/Dialog/index.d.ts.map +1 -0
- package/dist/components/Dialog/index.js +8 -0
- package/dist/components/Dialog/index.js.map +1 -0
- package/dist/components/Dialog/useDialog.d.ts +11 -0
- package/dist/components/Dialog/useDialog.d.ts.map +1 -0
- package/dist/components/Divider/Divider.d.ts +50 -0
- package/dist/components/Divider/Divider.d.ts.map +1 -0
- package/dist/components/Divider/Divider.recipe.d.ts +22 -0
- package/dist/components/Divider/Divider.recipe.d.ts.map +1 -0
- package/dist/components/Divider/index.cjs +19 -0
- package/dist/components/Divider/index.cjs.map +1 -0
- package/dist/components/Divider/index.d.ts +3 -0
- package/dist/components/Divider/index.d.ts.map +1 -0
- package/dist/components/Divider/index.js +6 -0
- package/dist/components/Divider/index.js.map +1 -0
- package/dist/components/Drawer/Drawer.d.ts +53 -0
- package/dist/components/Drawer/Drawer.d.ts.map +1 -0
- package/dist/components/Drawer/index.cjs +203 -0
- package/dist/components/Drawer/index.cjs.map +1 -0
- package/dist/components/Drawer/index.d.ts +3 -0
- package/dist/components/Drawer/index.d.ts.map +1 -0
- package/dist/components/Drawer/index.js +200 -0
- package/dist/components/Drawer/index.js.map +1 -0
- package/dist/components/Drawer/useDrawer.d.ts +11 -0
- package/dist/components/Drawer/useDrawer.d.ts.map +1 -0
- package/dist/components/DropdownMenu/DropdownMenu.d.ts +70 -0
- package/dist/components/DropdownMenu/DropdownMenu.d.ts.map +1 -0
- package/dist/components/DropdownMenu/DropdownMenuContext.d.ts +8 -0
- package/dist/components/DropdownMenu/DropdownMenuContext.d.ts.map +1 -0
- package/dist/components/DropdownMenu/DropdownMenuItem.d.ts +53 -0
- package/dist/components/DropdownMenu/DropdownMenuItem.d.ts.map +1 -0
- package/dist/components/DropdownMenu/index.cjs +41 -0
- package/dist/components/DropdownMenu/index.cjs.map +1 -0
- package/dist/components/DropdownMenu/index.d.ts +4 -0
- package/dist/components/DropdownMenu/index.d.ts.map +1 -0
- package/dist/components/DropdownMenu/index.js +20 -0
- package/dist/components/DropdownMenu/index.js.map +1 -0
- package/dist/components/DropdownMenu/menuUtils.d.ts +6 -0
- package/dist/components/DropdownMenu/menuUtils.d.ts.map +1 -0
- package/dist/components/DropdownMenu/types.d.ts +46 -0
- package/dist/components/DropdownMenu/types.d.ts.map +1 -0
- package/dist/components/EmptyState/EmptyState.d.ts +54 -0
- package/dist/components/EmptyState/EmptyState.d.ts.map +1 -0
- package/dist/components/EmptyState/EmptyState.recipe.d.ts +13 -0
- package/dist/components/EmptyState/EmptyState.recipe.d.ts.map +1 -0
- package/dist/components/EmptyState/index.cjs +23 -0
- package/dist/components/EmptyState/index.cjs.map +1 -0
- package/dist/components/EmptyState/index.d.ts +3 -0
- package/dist/components/EmptyState/index.d.ts.map +1 -0
- package/dist/components/EmptyState/index.js +10 -0
- package/dist/components/EmptyState/index.js.map +1 -0
- package/dist/components/Field/Field.d.ts +113 -0
- package/dist/components/Field/Field.d.ts.map +1 -0
- package/dist/components/Field/Field.recipe.d.ts +40 -0
- package/dist/components/Field/Field.recipe.d.ts.map +1 -0
- package/dist/components/Field/index.cjs +38 -0
- package/dist/components/Field/index.cjs.map +1 -0
- package/dist/components/Field/index.d.ts +5 -0
- package/dist/components/Field/index.d.ts.map +1 -0
- package/dist/components/Field/index.js +13 -0
- package/dist/components/Field/index.js.map +1 -0
- package/dist/components/Field/inputStyles.d.ts +60 -0
- package/dist/components/Field/inputStyles.d.ts.map +1 -0
- package/dist/components/Field/inputUtils.d.ts +6 -0
- package/dist/components/Field/inputUtils.d.ts.map +1 -0
- package/dist/components/Field/types.d.ts +13 -0
- package/dist/components/Field/types.d.ts.map +1 -0
- package/dist/components/FileInput/FileInput.d.ts +125 -0
- package/dist/components/FileInput/FileInput.d.ts.map +1 -0
- package/dist/components/FileInput/index.cjs +25 -0
- package/dist/components/FileInput/index.cjs.map +1 -0
- package/dist/components/FileInput/index.d.ts +2 -0
- package/dist/components/FileInput/index.d.ts.map +1 -0
- package/dist/components/FileInput/index.js +16 -0
- package/dist/components/FileInput/index.js.map +1 -0
- package/dist/components/HoverCard/HoverCard.d.ts +73 -0
- package/dist/components/HoverCard/HoverCard.d.ts.map +1 -0
- package/dist/components/HoverCard/index.cjs +19 -0
- package/dist/components/HoverCard/index.cjs.map +1 -0
- package/dist/components/HoverCard/index.d.ts +3 -0
- package/dist/components/HoverCard/index.d.ts.map +1 -0
- package/dist/components/HoverCard/index.js +6 -0
- package/dist/components/HoverCard/index.js.map +1 -0
- package/dist/components/HoverCard/useHoverCard.d.ts +26 -0
- package/dist/components/HoverCard/useHoverCard.d.ts.map +1 -0
- package/dist/components/Icon/Icon.d.ts +45 -0
- package/dist/components/Icon/Icon.d.ts.map +1 -0
- package/dist/components/Icon/Icon.recipe.d.ts +81 -0
- package/dist/components/Icon/Icon.recipe.d.ts.map +1 -0
- package/dist/components/Icon/index.cjs +19 -0
- package/dist/components/Icon/index.cjs.map +1 -0
- package/dist/components/Icon/index.d.ts +3 -0
- package/dist/components/Icon/index.d.ts.map +1 -0
- package/dist/components/Icon/index.js +6 -0
- package/dist/components/Icon/index.js.map +1 -0
- package/dist/components/InputGroup/InputGroup.d.ts +63 -0
- package/dist/components/InputGroup/InputGroup.d.ts.map +1 -0
- package/dist/components/InputGroup/InputGroup.recipe.d.ts +75 -0
- package/dist/components/InputGroup/InputGroup.recipe.d.ts.map +1 -0
- package/dist/components/InputGroup/InputGroupContext.d.ts +11 -0
- package/dist/components/InputGroup/InputGroupContext.d.ts.map +1 -0
- package/dist/components/InputGroup/InputGroupText.d.ts +13 -0
- package/dist/components/InputGroup/InputGroupText.d.ts.map +1 -0
- package/dist/components/InputGroup/index.cjs +35 -0
- package/dist/components/InputGroup/index.cjs.map +1 -0
- package/dist/components/InputGroup/index.d.ts +4 -0
- package/dist/components/InputGroup/index.d.ts.map +1 -0
- package/dist/components/InputGroup/index.js +14 -0
- package/dist/components/InputGroup/index.js.map +1 -0
- package/dist/components/Item/Item.d.ts +129 -0
- package/dist/components/Item/Item.d.ts.map +1 -0
- package/dist/components/Item/index.cjs +22 -0
- package/dist/components/Item/index.cjs.map +1 -0
- package/dist/components/Item/index.d.ts +2 -0
- package/dist/components/Item/index.d.ts.map +1 -0
- package/dist/components/Item/index.js +13 -0
- package/dist/components/Item/index.js.map +1 -0
- package/dist/components/Kbd/Kbd.d.ts +41 -0
- package/dist/components/Kbd/Kbd.d.ts.map +1 -0
- package/dist/components/Kbd/Kbd.recipe.d.ts +25 -0
- package/dist/components/Kbd/Kbd.recipe.d.ts.map +1 -0
- package/dist/components/Kbd/index.cjs +15 -0
- package/dist/components/Kbd/index.cjs.map +1 -0
- package/dist/components/Kbd/index.d.ts +2 -0
- package/dist/components/Kbd/index.d.ts.map +1 -0
- package/dist/components/Kbd/index.js +6 -0
- package/dist/components/Kbd/index.js.map +1 -0
- package/dist/components/Layout/Layout.d.ts +60 -0
- package/dist/components/Layout/Layout.d.ts.map +1 -0
- package/dist/components/Layout/Layout.recipe.d.ts +88 -0
- package/dist/components/Layout/Layout.recipe.d.ts.map +1 -0
- package/dist/components/Layout/LayoutContent.d.ts +37 -0
- package/dist/components/Layout/LayoutContent.d.ts.map +1 -0
- package/dist/components/Layout/LayoutContext.d.ts +16 -0
- package/dist/components/Layout/LayoutContext.d.ts.map +1 -0
- package/dist/components/Layout/LayoutFooter.d.ts +70 -0
- package/dist/components/Layout/LayoutFooter.d.ts.map +1 -0
- package/dist/components/Layout/LayoutHeader.d.ts +69 -0
- package/dist/components/Layout/LayoutHeader.d.ts.map +1 -0
- package/dist/components/Layout/LayoutPanel.d.ts +37 -0
- package/dist/components/Layout/LayoutPanel.d.ts.map +1 -0
- package/dist/components/Layout/index.cjs +46 -0
- package/dist/components/Layout/index.cjs.map +1 -0
- package/dist/components/Layout/index.d.ts +8 -0
- package/dist/components/Layout/index.d.ts.map +1 -0
- package/dist/components/Layout/index.js +17 -0
- package/dist/components/Layout/index.js.map +1 -0
- package/dist/components/Layout/types.d.ts +5 -0
- package/dist/components/Layout/types.d.ts.map +1 -0
- package/dist/components/Lightbox/Lightbox.d.ts +86 -0
- package/dist/components/Lightbox/Lightbox.d.ts.map +1 -0
- package/dist/components/Lightbox/index.cjs +29 -0
- package/dist/components/Lightbox/index.cjs.map +1 -0
- package/dist/components/Lightbox/index.d.ts +3 -0
- package/dist/components/Lightbox/index.d.ts.map +1 -0
- package/dist/components/Lightbox/index.js +16 -0
- package/dist/components/Lightbox/index.js.map +1 -0
- package/dist/components/Lightbox/useLightbox.d.ts +57 -0
- package/dist/components/Lightbox/useLightbox.d.ts.map +1 -0
- package/dist/components/Link/Link.d.ts +140 -0
- package/dist/components/Link/Link.d.ts.map +1 -0
- package/dist/components/Link/Link.recipe.d.ts +83 -0
- package/dist/components/Link/Link.recipe.d.ts.map +1 -0
- package/dist/components/Link/LinkContext.d.ts +6 -0
- package/dist/components/Link/LinkContext.d.ts.map +1 -0
- package/dist/components/Link/LinkProvider.d.ts +11 -0
- package/dist/components/Link/LinkProvider.d.ts.map +1 -0
- package/dist/components/Link/index.cjs +32 -0
- package/dist/components/Link/index.cjs.map +1 -0
- package/dist/components/Link/index.d.ts +6 -0
- package/dist/components/Link/index.d.ts.map +1 -0
- package/dist/components/Link/index.js +11 -0
- package/dist/components/Link/index.js.map +1 -0
- package/dist/components/Link/types.d.ts +30 -0
- package/dist/components/Link/types.d.ts.map +1 -0
- package/dist/components/Link/useLinkComponent.d.ts +3 -0
- package/dist/components/Link/useLinkComponent.d.ts.map +1 -0
- package/dist/components/List/List.d.ts +52 -0
- package/dist/components/List/List.d.ts.map +1 -0
- package/dist/components/List/ListContext.d.ts +7 -0
- package/dist/components/List/ListContext.d.ts.map +1 -0
- package/dist/components/List/ListItem.d.ts +69 -0
- package/dist/components/List/ListItem.d.ts.map +1 -0
- package/dist/components/List/index.cjs +27 -0
- package/dist/components/List/index.cjs.map +1 -0
- package/dist/components/List/index.d.ts +3 -0
- package/dist/components/List/index.d.ts.map +1 -0
- package/dist/components/List/index.js +14 -0
- package/dist/components/List/index.js.map +1 -0
- package/dist/components/MetadataList/MetadataList.d.ts +41 -0
- package/dist/components/MetadataList/MetadataList.d.ts.map +1 -0
- package/dist/components/MetadataList/MetadataListContext.d.ts +6 -0
- package/dist/components/MetadataList/MetadataListContext.d.ts.map +1 -0
- package/dist/components/MetadataList/MetadataListItem.d.ts +43 -0
- package/dist/components/MetadataList/MetadataListItem.d.ts.map +1 -0
- package/dist/components/MetadataList/index.cjs +24 -0
- package/dist/components/MetadataList/index.cjs.map +1 -0
- package/dist/components/MetadataList/index.d.ts +4 -0
- package/dist/components/MetadataList/index.d.ts.map +1 -0
- package/dist/components/MetadataList/index.js +11 -0
- package/dist/components/MetadataList/index.js.map +1 -0
- package/dist/components/MultiSelect/MultiSelect.d.ts +175 -0
- package/dist/components/MultiSelect/MultiSelect.d.ts.map +1 -0
- package/dist/components/MultiSelect/index.cjs +32 -0
- package/dist/components/MultiSelect/index.cjs.map +1 -0
- package/dist/components/MultiSelect/index.d.ts +2 -0
- package/dist/components/MultiSelect/index.d.ts.map +1 -0
- package/dist/components/MultiSelect/index.js +23 -0
- package/dist/components/MultiSelect/index.js.map +1 -0
- package/dist/components/NavIcon/NavIcon.d.ts +32 -0
- package/dist/components/NavIcon/NavIcon.d.ts.map +1 -0
- package/dist/components/NavIcon/index.cjs +42 -0
- package/dist/components/NavIcon/index.cjs.map +1 -0
- package/dist/components/NavIcon/index.d.ts +2 -0
- package/dist/components/NavIcon/index.d.ts.map +1 -0
- package/dist/components/NavIcon/index.js +40 -0
- package/dist/components/NavIcon/index.js.map +1 -0
- package/dist/components/NumberInput/NumberInput.d.ts +157 -0
- package/dist/components/NumberInput/NumberInput.d.ts.map +1 -0
- package/dist/components/NumberInput/index.cjs +26 -0
- package/dist/components/NumberInput/index.cjs.map +1 -0
- package/dist/components/NumberInput/index.d.ts +2 -0
- package/dist/components/NumberInput/index.d.ts.map +1 -0
- package/dist/components/NumberInput/index.js +17 -0
- package/dist/components/NumberInput/index.js.map +1 -0
- package/dist/components/Pagination/Pagination.d.ts +83 -0
- package/dist/components/Pagination/Pagination.d.ts.map +1 -0
- package/dist/components/Pagination/index.cjs +25 -0
- package/dist/components/Pagination/index.cjs.map +1 -0
- package/dist/components/Pagination/index.d.ts +2 -0
- package/dist/components/Pagination/index.d.ts.map +1 -0
- package/dist/components/Pagination/index.js +16 -0
- package/dist/components/Pagination/index.js.map +1 -0
- package/dist/components/PasswordInput/PasswordInput.d.ts +16 -0
- package/dist/components/PasswordInput/PasswordInput.d.ts.map +1 -0
- package/dist/components/PasswordInput/index.cjs +63 -0
- package/dist/components/PasswordInput/index.cjs.map +1 -0
- package/dist/components/PasswordInput/index.d.ts +2 -0
- package/dist/components/PasswordInput/index.d.ts.map +1 -0
- package/dist/components/PasswordInput/index.js +61 -0
- package/dist/components/PasswordInput/index.js.map +1 -0
- package/dist/components/Popover/Popover.d.ts +103 -0
- package/dist/components/Popover/Popover.d.ts.map +1 -0
- package/dist/components/Popover/index.cjs +30 -0
- package/dist/components/Popover/index.cjs.map +1 -0
- package/dist/components/Popover/index.d.ts +3 -0
- package/dist/components/Popover/index.d.ts.map +1 -0
- package/dist/components/Popover/index.js +17 -0
- package/dist/components/Popover/index.js.map +1 -0
- package/dist/components/Popover/usePopover.d.ts +34 -0
- package/dist/components/Popover/usePopover.d.ts.map +1 -0
- package/dist/components/Progress/Progress.d.ts +77 -0
- package/dist/components/Progress/Progress.d.ts.map +1 -0
- package/dist/components/Progress/Progress.recipe.d.ts +40 -0
- package/dist/components/Progress/Progress.recipe.d.ts.map +1 -0
- package/dist/components/Progress/index.cjs +20 -0
- package/dist/components/Progress/index.cjs.map +1 -0
- package/dist/components/Progress/index.d.ts +3 -0
- package/dist/components/Progress/index.d.ts.map +1 -0
- package/dist/components/Progress/index.js +7 -0
- package/dist/components/Progress/index.js.map +1 -0
- package/dist/components/RadioGroup/RadioGroup.d.ts +79 -0
- package/dist/components/RadioGroup/RadioGroup.d.ts.map +1 -0
- package/dist/components/RadioGroup/RadioGroupContext.d.ts +13 -0
- package/dist/components/RadioGroup/RadioGroupContext.d.ts.map +1 -0
- package/dist/components/RadioGroup/RadioGroupItem.d.ts +52 -0
- package/dist/components/RadioGroup/RadioGroupItem.d.ts.map +1 -0
- package/dist/components/RadioGroup/index.cjs +30 -0
- package/dist/components/RadioGroup/index.cjs.map +1 -0
- package/dist/components/RadioGroup/index.d.ts +4 -0
- package/dist/components/RadioGroup/index.d.ts.map +1 -0
- package/dist/components/RadioGroup/index.js +17 -0
- package/dist/components/RadioGroup/index.js.map +1 -0
- package/dist/components/Rating/Rating.d.ts +71 -0
- package/dist/components/Rating/Rating.d.ts.map +1 -0
- package/dist/components/Rating/index.cjs +185 -0
- package/dist/components/Rating/index.cjs.map +1 -0
- package/dist/components/Rating/index.d.ts +2 -0
- package/dist/components/Rating/index.d.ts.map +1 -0
- package/dist/components/Rating/index.js +183 -0
- package/dist/components/Rating/index.js.map +1 -0
- package/dist/components/Schedule/CalendarEvent.d.ts +30 -0
- package/dist/components/Schedule/CalendarEvent.d.ts.map +1 -0
- package/dist/components/Schedule/DayView.d.ts +23 -0
- package/dist/components/Schedule/DayView.d.ts.map +1 -0
- package/dist/components/Schedule/ListView.d.ts +13 -0
- package/dist/components/Schedule/ListView.d.ts.map +1 -0
- package/dist/components/Schedule/MonthlyView.d.ts +13 -0
- package/dist/components/Schedule/MonthlyView.d.ts.map +1 -0
- package/dist/components/Schedule/Schedule.d.ts +60 -0
- package/dist/components/Schedule/Schedule.d.ts.map +1 -0
- package/dist/components/Schedule/TimeGridView.d.ts +26 -0
- package/dist/components/Schedule/TimeGridView.d.ts.map +1 -0
- package/dist/components/Schedule/WeeklyView.d.ts +28 -0
- package/dist/components/Schedule/WeeklyView.d.ts.map +1 -0
- package/dist/components/Schedule/context.d.ts +20 -0
- package/dist/components/Schedule/context.d.ts.map +1 -0
- package/dist/components/Schedule/dateMath.d.ts +14 -0
- package/dist/components/Schedule/dateMath.d.ts.map +1 -0
- package/dist/components/Schedule/index.cjs +72 -0
- package/dist/components/Schedule/index.cjs.map +1 -0
- package/dist/components/Schedule/index.d.ts +13 -0
- package/dist/components/Schedule/index.d.ts.map +1 -0
- package/dist/components/Schedule/index.js +23 -0
- package/dist/components/Schedule/index.js.map +1 -0
- package/dist/components/Schedule/plugins/PaginationPlugin.d.ts +7 -0
- package/dist/components/Schedule/plugins/PaginationPlugin.d.ts.map +1 -0
- package/dist/components/Schedule/plugins/ViewSelectorPlugin.d.ts +11 -0
- package/dist/components/Schedule/plugins/ViewSelectorPlugin.d.ts.map +1 -0
- package/dist/components/Schedule/plugins/index.d.ts +5 -0
- package/dist/components/Schedule/plugins/index.d.ts.map +1 -0
- package/dist/components/Schedule/shared.d.ts +59 -0
- package/dist/components/Schedule/shared.d.ts.map +1 -0
- package/dist/components/Schedule/types.d.ts +44 -0
- package/dist/components/Schedule/types.d.ts.map +1 -0
- package/dist/components/Schedule/useCurrentTime.d.ts +3 -0
- package/dist/components/Schedule/useCurrentTime.d.ts.map +1 -0
- package/dist/components/Schedule/zonedDateTime.d.ts +14 -0
- package/dist/components/Schedule/zonedDateTime.d.ts.map +1 -0
- package/dist/components/SearchFilterInput/SearchFilterInput.d.ts +143 -0
- package/dist/components/SearchFilterInput/SearchFilterInput.d.ts.map +1 -0
- package/dist/components/SearchFilterInput/SearchFilterInputEditPopover.d.ts +43 -0
- package/dist/components/SearchFilterInput/SearchFilterInputEditPopover.d.ts.map +1 -0
- package/dist/components/SearchFilterInput/SearchFilterInputFilterEditor.d.ts +9 -0
- package/dist/components/SearchFilterInput/SearchFilterInputFilterEditor.d.ts.map +1 -0
- package/dist/components/SearchFilterInput/SearchFilterInputTag.d.ts +9 -0
- package/dist/components/SearchFilterInput/SearchFilterInputTag.d.ts.map +1 -0
- package/dist/components/SearchFilterInput/SearchFilterInputValueEditor.d.ts +13 -0
- package/dist/components/SearchFilterInput/SearchFilterInputValueEditor.d.ts.map +1 -0
- package/dist/components/SearchFilterInput/formatFilterValue.d.ts +4 -0
- package/dist/components/SearchFilterInput/formatFilterValue.d.ts.map +1 -0
- package/dist/components/SearchFilterInput/index.cjs +73 -0
- package/dist/components/SearchFilterInput/index.cjs.map +1 -0
- package/dist/components/SearchFilterInput/index.d.ts +9 -0
- package/dist/components/SearchFilterInput/index.d.ts.map +1 -0
- package/dist/components/SearchFilterInput/index.js +36 -0
- package/dist/components/SearchFilterInput/index.js.map +1 -0
- package/dist/components/SearchFilterInput/internalConfig.d.ts +11 -0
- package/dist/components/SearchFilterInput/internalConfig.d.ts.map +1 -0
- package/dist/components/SearchFilterInput/types.d.ts +240 -0
- package/dist/components/SearchFilterInput/types.d.ts.map +1 -0
- package/dist/components/SearchFilterInput/useSearchFilterInputConfig.d.ts +31 -0
- package/dist/components/SearchFilterInput/useSearchFilterInputConfig.d.ts.map +1 -0
- package/dist/components/SearchFilterInput/useSearchFilterInputSource.d.ts +5 -0
- package/dist/components/SearchFilterInput/useSearchFilterInputSource.d.ts.map +1 -0
- package/dist/components/SegmentedControl/SegmentedControl.d.ts +59 -0
- package/dist/components/SegmentedControl/SegmentedControl.d.ts.map +1 -0
- package/dist/components/SegmentedControl/SegmentedControlContext.d.ts +12 -0
- package/dist/components/SegmentedControl/SegmentedControlContext.d.ts.map +1 -0
- package/dist/components/SegmentedControl/SegmentedControlItem.d.ts +50 -0
- package/dist/components/SegmentedControl/SegmentedControlItem.d.ts.map +1 -0
- package/dist/components/SegmentedControl/index.cjs +22 -0
- package/dist/components/SegmentedControl/index.cjs.map +1 -0
- package/dist/components/SegmentedControl/index.d.ts +4 -0
- package/dist/components/SegmentedControl/index.d.ts.map +1 -0
- package/dist/components/SegmentedControl/index.js +9 -0
- package/dist/components/SegmentedControl/index.js.map +1 -0
- package/dist/components/Select/Select.d.ts +149 -0
- package/dist/components/Select/Select.d.ts.map +1 -0
- package/dist/components/Select/SelectOption.d.ts +44 -0
- package/dist/components/Select/SelectOption.d.ts.map +1 -0
- package/dist/components/Select/index.cjs +36 -0
- package/dist/components/Select/index.cjs.map +1 -0
- package/dist/components/Select/index.d.ts +3 -0
- package/dist/components/Select/index.d.ts.map +1 -0
- package/dist/components/Select/index.js +23 -0
- package/dist/components/Select/index.js.map +1 -0
- package/dist/components/SideNav/SideNav.d.ts +53 -0
- package/dist/components/SideNav/SideNav.d.ts.map +1 -0
- package/dist/components/SideNav/SideNav.recipe.d.ts +21 -0
- package/dist/components/SideNav/SideNav.recipe.d.ts.map +1 -0
- package/dist/components/SideNav/SideNavContext.d.ts +11 -0
- package/dist/components/SideNav/SideNavContext.d.ts.map +1 -0
- package/dist/components/SideNav/SideNavHeading.d.ts +21 -0
- package/dist/components/SideNav/SideNavHeading.d.ts.map +1 -0
- package/dist/components/SideNav/SideNavItem.d.ts +79 -0
- package/dist/components/SideNav/SideNavItem.d.ts.map +1 -0
- package/dist/components/SideNav/SideNavSection.d.ts +17 -0
- package/dist/components/SideNav/SideNavSection.d.ts.map +1 -0
- package/dist/components/SideNav/index.cjs +51 -0
- package/dist/components/SideNav/index.cjs.map +1 -0
- package/dist/components/SideNav/index.d.ts +7 -0
- package/dist/components/SideNav/index.d.ts.map +1 -0
- package/dist/components/SideNav/index.js +18 -0
- package/dist/components/SideNav/index.js.map +1 -0
- package/dist/components/SideNav/internal/SideNavCollapseButton.d.ts +9 -0
- package/dist/components/SideNav/internal/SideNavCollapseButton.d.ts.map +1 -0
- package/dist/components/Skeleton/Skeleton.d.ts +57 -0
- package/dist/components/Skeleton/Skeleton.d.ts.map +1 -0
- package/dist/components/Skeleton/index.cjs +14 -0
- package/dist/components/Skeleton/index.cjs.map +1 -0
- package/dist/components/Skeleton/index.d.ts +2 -0
- package/dist/components/Skeleton/index.d.ts.map +1 -0
- package/dist/components/Skeleton/index.js +5 -0
- package/dist/components/Skeleton/index.js.map +1 -0
- package/dist/components/Slider/Slider.d.ts +134 -0
- package/dist/components/Slider/Slider.d.ts.map +1 -0
- package/dist/components/Slider/index.cjs +23 -0
- package/dist/components/Slider/index.cjs.map +1 -0
- package/dist/components/Slider/index.d.ts +2 -0
- package/dist/components/Slider/index.d.ts.map +1 -0
- package/dist/components/Slider/index.js +14 -0
- package/dist/components/Slider/index.js.map +1 -0
- package/dist/components/Spinner/Spinner.d.ts +51 -0
- package/dist/components/Spinner/Spinner.d.ts.map +1 -0
- package/dist/components/Spinner/Spinner.recipe.d.ts +36 -0
- package/dist/components/Spinner/Spinner.recipe.d.ts.map +1 -0
- package/dist/components/Spinner/index.cjs +23 -0
- package/dist/components/Spinner/index.cjs.map +1 -0
- package/dist/components/Spinner/index.d.ts +3 -0
- package/dist/components/Spinner/index.d.ts.map +1 -0
- package/dist/components/Spinner/index.js +10 -0
- package/dist/components/Spinner/index.js.map +1 -0
- package/dist/components/Stack/HStack.d.ts +14 -0
- package/dist/components/Stack/HStack.d.ts.map +1 -0
- package/dist/components/Stack/Stack.d.ts +69 -0
- package/dist/components/Stack/Stack.d.ts.map +1 -0
- package/dist/components/Stack/Stack.recipe.d.ts +59 -0
- package/dist/components/Stack/Stack.recipe.d.ts.map +1 -0
- package/dist/components/Stack/VStack.d.ts +14 -0
- package/dist/components/Stack/VStack.d.ts.map +1 -0
- package/dist/components/Stack/index.cjs +24 -0
- package/dist/components/Stack/index.cjs.map +1 -0
- package/dist/components/Stack/index.d.ts +5 -0
- package/dist/components/Stack/index.d.ts.map +1 -0
- package/dist/components/Stack/index.js +7 -0
- package/dist/components/Stack/index.js.map +1 -0
- package/dist/components/Stepper/Step.d.ts +62 -0
- package/dist/components/Stepper/Step.d.ts.map +1 -0
- package/dist/components/Stepper/Step.recipe.d.ts +95 -0
- package/dist/components/Stepper/Step.recipe.d.ts.map +1 -0
- package/dist/components/Stepper/Stepper.d.ts +51 -0
- package/dist/components/Stepper/Stepper.d.ts.map +1 -0
- package/dist/components/Stepper/StepperContext.d.ts +10 -0
- package/dist/components/Stepper/StepperContext.d.ts.map +1 -0
- package/dist/components/Stepper/index.cjs +28 -0
- package/dist/components/Stepper/index.cjs.map +1 -0
- package/dist/components/Stepper/index.d.ts +4 -0
- package/dist/components/Stepper/index.d.ts.map +1 -0
- package/dist/components/Stepper/index.js +11 -0
- package/dist/components/Stepper/index.js.map +1 -0
- package/dist/components/Switch/Switch.d.ts +92 -0
- package/dist/components/Switch/Switch.d.ts.map +1 -0
- package/dist/components/Switch/index.cjs +23 -0
- package/dist/components/Switch/index.cjs.map +1 -0
- package/dist/components/Switch/index.d.ts +2 -0
- package/dist/components/Switch/index.d.ts.map +1 -0
- package/dist/components/Switch/index.js +14 -0
- package/dist/components/Switch/index.js.map +1 -0
- package/dist/components/Table/BaseTable.d.ts +6 -0
- package/dist/components/Table/BaseTable.d.ts.map +1 -0
- package/dist/components/Table/Table.d.ts +42 -0
- package/dist/components/Table/Table.d.ts.map +1 -0
- package/dist/components/Table/TableBody.d.ts +31 -0
- package/dist/components/Table/TableBody.d.ts.map +1 -0
- package/dist/components/Table/TableCell.d.ts +47 -0
- package/dist/components/Table/TableCell.d.ts.map +1 -0
- package/dist/components/Table/TableContext.d.ts +4 -0
- package/dist/components/Table/TableContext.d.ts.map +1 -0
- package/dist/components/Table/TableFooter.d.ts +31 -0
- package/dist/components/Table/TableFooter.d.ts.map +1 -0
- package/dist/components/Table/TableHeader.d.ts +31 -0
- package/dist/components/Table/TableHeader.d.ts.map +1 -0
- package/dist/components/Table/TableHeaderCell.d.ts +36 -0
- package/dist/components/Table/TableHeaderCell.d.ts.map +1 -0
- package/dist/components/Table/TableRow.d.ts +31 -0
- package/dist/components/Table/TableRow.d.ts.map +1 -0
- package/dist/components/Table/columnUtils.d.ts +19 -0
- package/dist/components/Table/columnUtils.d.ts.map +1 -0
- package/dist/components/Table/index.cjs +156 -0
- package/dist/components/Table/index.cjs.map +1 -0
- package/dist/components/Table/index.d.ts +18 -0
- package/dist/components/Table/index.d.ts.map +1 -0
- package/dist/components/Table/index.js +39 -0
- package/dist/components/Table/index.js.map +1 -0
- package/dist/components/Table/plugins/columnResize/index.d.ts +2 -0
- package/dist/components/Table/plugins/columnResize/index.d.ts.map +1 -0
- package/dist/components/Table/plugins/columnResize/useTableColumnResize.d.ts +10 -0
- package/dist/components/Table/plugins/columnResize/useTableColumnResize.d.ts.map +1 -0
- package/dist/components/Table/plugins/columnSettings/index.d.ts +3 -0
- package/dist/components/Table/plugins/columnSettings/index.d.ts.map +1 -0
- package/dist/components/Table/plugins/columnSettings/useTableColumnSettings.d.ts +11 -0
- package/dist/components/Table/plugins/columnSettings/useTableColumnSettings.d.ts.map +1 -0
- package/dist/components/Table/plugins/columnSettings/useTableColumnSettingsState.d.ts +19 -0
- package/dist/components/Table/plugins/columnSettings/useTableColumnSettingsState.d.ts.map +1 -0
- package/dist/components/Table/plugins/filtering/index.d.ts +3 -0
- package/dist/components/Table/plugins/filtering/index.d.ts.map +1 -0
- package/dist/components/Table/plugins/filtering/useTableFilterState.d.ts +8 -0
- package/dist/components/Table/plugins/filtering/useTableFilterState.d.ts.map +1 -0
- package/dist/components/Table/plugins/filtering/useTableFiltering.d.ts +22 -0
- package/dist/components/Table/plugins/filtering/useTableFiltering.d.ts.map +1 -0
- package/dist/components/Table/plugins/pagination/index.d.ts +3 -0
- package/dist/components/Table/plugins/pagination/index.d.ts.map +1 -0
- package/dist/components/Table/plugins/pagination/paginateData.d.ts +6 -0
- package/dist/components/Table/plugins/pagination/paginateData.d.ts.map +1 -0
- package/dist/components/Table/plugins/pagination/useTablePagination.d.ts +16 -0
- package/dist/components/Table/plugins/pagination/useTablePagination.d.ts.map +1 -0
- package/dist/components/Table/plugins/selection/index.d.ts +3 -0
- package/dist/components/Table/plugins/selection/index.d.ts.map +1 -0
- package/dist/components/Table/plugins/selection/useTableSelection.d.ts +17 -0
- package/dist/components/Table/plugins/selection/useTableSelection.d.ts.map +1 -0
- package/dist/components/Table/plugins/selection/useTableSelectionState.d.ts +14 -0
- package/dist/components/Table/plugins/selection/useTableSelectionState.d.ts.map +1 -0
- package/dist/components/Table/plugins/sortable/index.d.ts +3 -0
- package/dist/components/Table/plugins/sortable/index.d.ts.map +1 -0
- package/dist/components/Table/plugins/sortable/useTableSortable.d.ts +15 -0
- package/dist/components/Table/plugins/sortable/useTableSortable.d.ts.map +1 -0
- package/dist/components/Table/plugins/sortable/useTableSortableState.d.ts +19 -0
- package/dist/components/Table/plugins/sortable/useTableSortableState.d.ts.map +1 -0
- package/dist/components/Table/types.d.ts +107 -0
- package/dist/components/Table/types.d.ts.map +1 -0
- package/dist/components/Table/useBaseTablePlugins.d.ts +3 -0
- package/dist/components/Table/useBaseTablePlugins.d.ts.map +1 -0
- package/dist/components/Tabs/Tab.d.ts +74 -0
- package/dist/components/Tabs/Tab.d.ts.map +1 -0
- package/dist/components/Tabs/TabMenu.d.ts +59 -0
- package/dist/components/Tabs/TabMenu.d.ts.map +1 -0
- package/dist/components/Tabs/Tabs.d.ts +60 -0
- package/dist/components/Tabs/Tabs.d.ts.map +1 -0
- package/dist/components/Tabs/TabsContext.d.ts +11 -0
- package/dist/components/Tabs/TabsContext.d.ts.map +1 -0
- package/dist/components/Tabs/index.cjs +43 -0
- package/dist/components/Tabs/index.cjs.map +1 -0
- package/dist/components/Tabs/index.d.ts +5 -0
- package/dist/components/Tabs/index.d.ts.map +1 -0
- package/dist/components/Tabs/index.js +18 -0
- package/dist/components/Tabs/index.js.map +1 -0
- package/dist/components/Tag/Tag.d.ts +86 -0
- package/dist/components/Tag/Tag.d.ts.map +1 -0
- package/dist/components/Tag/Tag.recipe.d.ts +121 -0
- package/dist/components/Tag/Tag.recipe.d.ts.map +1 -0
- package/dist/components/Tag/index.cjs +25 -0
- package/dist/components/Tag/index.cjs.map +1 -0
- package/dist/components/Tag/index.d.ts +3 -0
- package/dist/components/Tag/index.d.ts.map +1 -0
- package/dist/components/Tag/index.js +12 -0
- package/dist/components/Tag/index.js.map +1 -0
- package/dist/components/TagsInput/TagsInput.d.ts +190 -0
- package/dist/components/TagsInput/TagsInput.d.ts.map +1 -0
- package/dist/components/TagsInput/index.cjs +32 -0
- package/dist/components/TagsInput/index.cjs.map +1 -0
- package/dist/components/TagsInput/index.d.ts +2 -0
- package/dist/components/TagsInput/index.d.ts.map +1 -0
- package/dist/components/TagsInput/index.js +23 -0
- package/dist/components/TagsInput/index.js.map +1 -0
- package/dist/components/Text/Heading.d.ts +78 -0
- package/dist/components/Text/Heading.d.ts.map +1 -0
- package/dist/components/Text/Text.d.ts +98 -0
- package/dist/components/Text/Text.d.ts.map +1 -0
- package/dist/components/Text/Text.recipe.d.ts +283 -0
- package/dist/components/Text/Text.recipe.d.ts.map +1 -0
- package/dist/components/Text/Text.utils.d.ts +2 -0
- package/dist/components/Text/Text.utils.d.ts.map +1 -0
- package/dist/components/Text/index.cjs +29 -0
- package/dist/components/Text/index.cjs.map +1 -0
- package/dist/components/Text/index.d.ts +4 -0
- package/dist/components/Text/index.d.ts.map +1 -0
- package/dist/components/Text/index.js +8 -0
- package/dist/components/Text/index.js.map +1 -0
- package/dist/components/Text/useTruncation.d.ts +12 -0
- package/dist/components/Text/useTruncation.d.ts.map +1 -0
- package/dist/components/TextArea/TextArea.d.ts +120 -0
- package/dist/components/TextArea/TextArea.d.ts.map +1 -0
- package/dist/components/TextArea/index.cjs +25 -0
- package/dist/components/TextArea/index.cjs.map +1 -0
- package/dist/components/TextArea/index.d.ts +2 -0
- package/dist/components/TextArea/index.d.ts.map +1 -0
- package/dist/components/TextArea/index.js +16 -0
- package/dist/components/TextArea/index.js.map +1 -0
- package/dist/components/TextInput/TextInput.d.ts +122 -0
- package/dist/components/TextInput/TextInput.d.ts.map +1 -0
- package/dist/components/TextInput/index.cjs +26 -0
- package/dist/components/TextInput/index.cjs.map +1 -0
- package/dist/components/TextInput/index.d.ts +2 -0
- package/dist/components/TextInput/index.d.ts.map +1 -0
- package/dist/components/TextInput/index.js +17 -0
- package/dist/components/TextInput/index.js.map +1 -0
- package/dist/components/Theme/Theme.d.ts +216 -0
- package/dist/components/Theme/Theme.d.ts.map +1 -0
- package/dist/components/Theme/index.cjs +13 -0
- package/dist/components/Theme/index.cjs.map +1 -0
- package/dist/components/Theme/index.d.ts +2 -0
- package/dist/components/Theme/index.d.ts.map +1 -0
- package/dist/components/Theme/index.js +4 -0
- package/dist/components/Theme/index.js.map +1 -0
- package/dist/components/Thumbnail/Thumbnail.d.ts +59 -0
- package/dist/components/Thumbnail/Thumbnail.d.ts.map +1 -0
- package/dist/components/Thumbnail/index.cjs +26 -0
- package/dist/components/Thumbnail/index.cjs.map +1 -0
- package/dist/components/Thumbnail/index.d.ts +2 -0
- package/dist/components/Thumbnail/index.d.ts.map +1 -0
- package/dist/components/Thumbnail/index.js +17 -0
- package/dist/components/Thumbnail/index.js.map +1 -0
- package/dist/components/TimeInput/TimeInput.d.ts +115 -0
- package/dist/components/TimeInput/TimeInput.d.ts.map +1 -0
- package/dist/components/TimeInput/index.cjs +25 -0
- package/dist/components/TimeInput/index.cjs.map +1 -0
- package/dist/components/TimeInput/index.d.ts +2 -0
- package/dist/components/TimeInput/index.d.ts.map +1 -0
- package/dist/components/TimeInput/index.js +16 -0
- package/dist/components/TimeInput/index.js.map +1 -0
- package/dist/components/Toast/Toast.d.ts +57 -0
- package/dist/components/Toast/Toast.d.ts.map +1 -0
- package/dist/components/Toast/ToastContext.d.ts +8 -0
- package/dist/components/Toast/ToastContext.d.ts.map +1 -0
- package/dist/components/Toast/ToastViewport.d.ts +70 -0
- package/dist/components/Toast/ToastViewport.d.ts.map +1 -0
- package/dist/components/Toast/index.cjs +34 -0
- package/dist/components/Toast/index.cjs.map +1 -0
- package/dist/components/Toast/index.d.ts +5 -0
- package/dist/components/Toast/index.d.ts.map +1 -0
- package/dist/components/Toast/index.js +17 -0
- package/dist/components/Toast/index.js.map +1 -0
- package/dist/components/Toast/types.d.ts +50 -0
- package/dist/components/Toast/types.d.ts.map +1 -0
- package/dist/components/Toast/useToast.d.ts +8 -0
- package/dist/components/Toast/useToast.d.ts.map +1 -0
- package/dist/components/ToggleButton/ToggleButton.d.ts +81 -0
- package/dist/components/ToggleButton/ToggleButton.d.ts.map +1 -0
- package/dist/components/ToggleButton/ToggleButtonGroup.d.ts +90 -0
- package/dist/components/ToggleButton/ToggleButtonGroup.d.ts.map +1 -0
- package/dist/components/ToggleButton/index.cjs +29 -0
- package/dist/components/ToggleButton/index.cjs.map +1 -0
- package/dist/components/ToggleButton/index.d.ts +3 -0
- package/dist/components/ToggleButton/index.d.ts.map +1 -0
- package/dist/components/ToggleButton/index.js +16 -0
- package/dist/components/ToggleButton/index.js.map +1 -0
- package/dist/components/Tooltip/Tooltip.d.ts +80 -0
- package/dist/components/Tooltip/Tooltip.d.ts.map +1 -0
- package/dist/components/Tooltip/index.cjs +19 -0
- package/dist/components/Tooltip/index.cjs.map +1 -0
- package/dist/components/Tooltip/index.d.ts +3 -0
- package/dist/components/Tooltip/index.d.ts.map +1 -0
- package/dist/components/Tooltip/index.js +6 -0
- package/dist/components/Tooltip/index.js.map +1 -0
- package/dist/components/Tooltip/useTooltip.d.ts +49 -0
- package/dist/components/Tooltip/useTooltip.d.ts.map +1 -0
- package/dist/components/TopNav/TopNav.d.ts +54 -0
- package/dist/components/TopNav/TopNav.d.ts.map +1 -0
- package/dist/components/TopNav/TopNav.recipe.d.ts +17 -0
- package/dist/components/TopNav/TopNav.recipe.d.ts.map +1 -0
- package/dist/components/TopNav/TopNavContext.d.ts +9 -0
- package/dist/components/TopNav/TopNavContext.d.ts.map +1 -0
- package/dist/components/TopNav/TopNavHeading.d.ts +26 -0
- package/dist/components/TopNav/TopNavHeading.d.ts.map +1 -0
- package/dist/components/TopNav/TopNavItem.d.ts +77 -0
- package/dist/components/TopNav/TopNavItem.d.ts.map +1 -0
- package/dist/components/TopNav/TopNavItem.recipe.d.ts +35 -0
- package/dist/components/TopNav/TopNavItem.recipe.d.ts.map +1 -0
- package/dist/components/TopNav/index.cjs +51 -0
- package/dist/components/TopNav/index.cjs.map +1 -0
- package/dist/components/TopNav/index.d.ts +6 -0
- package/dist/components/TopNav/index.d.ts.map +1 -0
- package/dist/components/TopNav/index.js +18 -0
- package/dist/components/TopNav/index.js.map +1 -0
- package/dist/components/TreeView/TreeView.d.ts +42 -0
- package/dist/components/TreeView/TreeView.d.ts.map +1 -0
- package/dist/components/TreeView/TreeViewBranches.d.ts +19 -0
- package/dist/components/TreeView/TreeViewBranches.d.ts.map +1 -0
- package/dist/components/TreeView/TreeViewItem.d.ts +111 -0
- package/dist/components/TreeView/TreeViewItem.d.ts.map +1 -0
- package/dist/components/TreeView/index.cjs +16 -0
- package/dist/components/TreeView/index.cjs.map +1 -0
- package/dist/components/TreeView/index.d.ts +3 -0
- package/dist/components/TreeView/index.d.ts.map +1 -0
- package/dist/components/TreeView/index.js +7 -0
- package/dist/components/TreeView/index.js.map +1 -0
- package/dist/components/TreeView/types.d.ts +61 -0
- package/dist/components/TreeView/types.d.ts.map +1 -0
- package/dist/index.cjs +867 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.ts +72 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +86 -0
- package/dist/index.js.map +1 -0
- package/dist/internal/HoverLayerTrigger.d.ts +17 -0
- package/dist/internal/HoverLayerTrigger.d.ts.map +1 -0
- package/dist/internal/MobileNav/MobileNav.d.ts +58 -0
- package/dist/internal/MobileNav/MobileNav.d.ts.map +1 -0
- package/dist/internal/MobileNav/MobileNav.recipe.d.ts +11 -0
- package/dist/internal/MobileNav/MobileNav.recipe.d.ts.map +1 -0
- package/dist/internal/MobileNav/MobileNavToggle.d.ts +37 -0
- package/dist/internal/MobileNav/MobileNavToggle.d.ts.map +1 -0
- package/dist/internal/MobileNav/index.d.ts +3 -0
- package/dist/internal/MobileNav/index.d.ts.map +1 -0
- package/dist/internal/OverflowList.d.ts +18 -0
- package/dist/internal/OverflowList.d.ts.map +1 -0
- package/dist/internal/VisuallyHidden.d.ts +10 -0
- package/dist/internal/VisuallyHidden.d.ts.map +1 -0
- package/dist/internal/cx.d.ts +2 -0
- package/dist/internal/cx.d.ts.map +1 -0
- package/dist/internal/dateTypes.d.ts +8 -0
- package/dist/internal/dateTypes.d.ts.map +1 -0
- package/dist/internal/formatFileSize.d.ts +2 -0
- package/dist/internal/formatFileSize.d.ts.map +1 -0
- package/dist/internal/index.d.ts +2 -0
- package/dist/internal/index.d.ts.map +1 -0
- package/dist/internal/linkAccessibility.d.ts +7 -0
- package/dist/internal/linkAccessibility.d.ts.map +1 -0
- package/dist/internal/mergeRefs.d.ts +3 -0
- package/dist/internal/mergeRefs.d.ts.map +1 -0
- package/dist/internal/parseDateInput.d.ts +8 -0
- package/dist/internal/parseDateInput.d.ts.map +1 -0
- package/dist/internal/plainDate.d.ts +22 -0
- package/dist/internal/plainDate.d.ts.map +1 -0
- package/dist/internal/sharedResizeObserver.d.ts +5 -0
- package/dist/internal/sharedResizeObserver.d.ts.map +1 -0
- package/dist/internal/time.d.ts +4 -0
- package/dist/internal/time.d.ts.map +1 -0
- package/dist/internal/toPixelSize.d.ts +3 -0
- package/dist/internal/toPixelSize.d.ts.map +1 -0
- package/dist/internal/useFocusTrap.d.ts +10 -0
- package/dist/internal/useFocusTrap.d.ts.map +1 -0
- package/dist/internal/useGridFocus.d.ts +17 -0
- package/dist/internal/useGridFocus.d.ts.map +1 -0
- package/dist/internal/useHoverLayer.d.ts +30 -0
- package/dist/internal/useHoverLayer.d.ts.map +1 -0
- package/dist/internal/useIsomorphicLayoutEffect.d.ts +3 -0
- package/dist/internal/useIsomorphicLayoutEffect.d.ts.map +1 -0
- package/dist/internal/useLayer.d.ts +27 -0
- package/dist/internal/useLayer.d.ts.map +1 -0
- package/dist/internal/useListboxNavigation.d.ts +24 -0
- package/dist/internal/useListboxNavigation.d.ts.map +1 -0
- package/dist/internal/useMediaQuery.d.ts +5 -0
- package/dist/internal/useMediaQuery.d.ts.map +1 -0
- package/dist/internal/useSelectListbox.d.ts +63 -0
- package/dist/internal/useSelectListbox.d.ts.map +1 -0
- package/dist/styles.css +1 -0
- package/dist/theme/generate-color-scale.d.ts +6 -0
- package/dist/theme/generate-color-scale.d.ts.map +1 -0
- package/package.json +116 -0
|
@@ -0,0 +1,2099 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkCZJUKLFD_cjs = require('./chunk-CZJUKLFD.cjs');
|
|
4
|
+
var chunkWE3ECIRS_cjs = require('./chunk-WE3ECIRS.cjs');
|
|
5
|
+
var chunk6NIFOTUZ_cjs = require('./chunk-6NIFOTUZ.cjs');
|
|
6
|
+
var chunkWIIDQ44X_cjs = require('./chunk-WIIDQ44X.cjs');
|
|
7
|
+
var chunkRJXHAQCR_cjs = require('./chunk-RJXHAQCR.cjs');
|
|
8
|
+
var chunkEETTQWW5_cjs = require('./chunk-EETTQWW5.cjs');
|
|
9
|
+
var chunkTPSOUQG7_cjs = require('./chunk-TPSOUQG7.cjs');
|
|
10
|
+
var chunkCK3UJQRI_cjs = require('./chunk-CK3UJQRI.cjs');
|
|
11
|
+
var chunkPDXZDPOY_cjs = require('./chunk-PDXZDPOY.cjs');
|
|
12
|
+
var chunkQRDRZNCS_cjs = require('./chunk-QRDRZNCS.cjs');
|
|
13
|
+
var chunkWSAZHUB3_cjs = require('./chunk-WSAZHUB3.cjs');
|
|
14
|
+
var chunkR37R7DEV_cjs = require('./chunk-R37R7DEV.cjs');
|
|
15
|
+
var chunkNILB6Y4Z_cjs = require('./chunk-NILB6Y4Z.cjs');
|
|
16
|
+
var chunk47BELFYO_cjs = require('./chunk-47BELFYO.cjs');
|
|
17
|
+
var chunkAZDWQGAX_cjs = require('./chunk-AZDWQGAX.cjs');
|
|
18
|
+
var lucideReact = require('lucide-react');
|
|
19
|
+
var react = require('react');
|
|
20
|
+
var polyfill = require('@js-temporal/polyfill');
|
|
21
|
+
var jsxRuntime = require('react/jsx-runtime');
|
|
22
|
+
|
|
23
|
+
function enumItemsToSearchableItems(values) {
|
|
24
|
+
return values.map((item) => ({ id: item.value, label: item.label }));
|
|
25
|
+
}
|
|
26
|
+
function emptySource() {
|
|
27
|
+
return { bootstrap: () => [], search: () => [] };
|
|
28
|
+
}
|
|
29
|
+
function StringEditor({
|
|
30
|
+
operatorValue,
|
|
31
|
+
filterValue,
|
|
32
|
+
onChange
|
|
33
|
+
}) {
|
|
34
|
+
const currentValue = filterValue?.type === "string" ? filterValue.value : "";
|
|
35
|
+
if (operatorValue.searchSource != null) {
|
|
36
|
+
const selectedItem = currentValue === "" ? null : { id: currentValue, label: currentValue };
|
|
37
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
38
|
+
chunkPDXZDPOY_cjs.AutocompleteInput,
|
|
39
|
+
{
|
|
40
|
+
debounceMs: 150,
|
|
41
|
+
isLabelHidden: true,
|
|
42
|
+
label: "Value",
|
|
43
|
+
onChange: (item) => {
|
|
44
|
+
onChange({ type: "string", value: item?.label ?? "" }, item != null);
|
|
45
|
+
},
|
|
46
|
+
placeholder: "Search...",
|
|
47
|
+
searchSource: operatorValue.searchSource,
|
|
48
|
+
value: selectedItem
|
|
49
|
+
}
|
|
50
|
+
);
|
|
51
|
+
}
|
|
52
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
53
|
+
chunkRJXHAQCR_cjs.TextInput,
|
|
54
|
+
{
|
|
55
|
+
isLabelHidden: true,
|
|
56
|
+
label: "Value",
|
|
57
|
+
onChange: (value) => onChange({ type: "string", value }),
|
|
58
|
+
placeholder: "Enter value...",
|
|
59
|
+
value: currentValue
|
|
60
|
+
}
|
|
61
|
+
);
|
|
62
|
+
}
|
|
63
|
+
function StringListEditor({
|
|
64
|
+
operatorValue,
|
|
65
|
+
filterValue,
|
|
66
|
+
onChange
|
|
67
|
+
}) {
|
|
68
|
+
const currentValue = react.useMemo(() => {
|
|
69
|
+
if (filterValue?.type !== "string_list") {
|
|
70
|
+
return [];
|
|
71
|
+
}
|
|
72
|
+
return filterValue.value.map((value) => ({ id: value, label: value }));
|
|
73
|
+
}, [filterValue]);
|
|
74
|
+
const source = operatorValue.searchSource ?? emptySource();
|
|
75
|
+
const hasCreate = operatorValue.isArbitraryStringAllowed === true || operatorValue.searchSource == null;
|
|
76
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
77
|
+
chunkWE3ECIRS_cjs.TagsInput,
|
|
78
|
+
{
|
|
79
|
+
debounceMs: operatorValue.searchSource == null ? 0 : 150,
|
|
80
|
+
hasCreate,
|
|
81
|
+
isLabelHidden: true,
|
|
82
|
+
label: "Values",
|
|
83
|
+
onChange: (items) => {
|
|
84
|
+
onChange({
|
|
85
|
+
type: "string_list",
|
|
86
|
+
value: items.map((item) => item.label)
|
|
87
|
+
});
|
|
88
|
+
},
|
|
89
|
+
placeholder: "Add values...",
|
|
90
|
+
searchSource: source,
|
|
91
|
+
value: currentValue
|
|
92
|
+
}
|
|
93
|
+
);
|
|
94
|
+
}
|
|
95
|
+
function IntegerEditor({
|
|
96
|
+
operatorValue,
|
|
97
|
+
filterValue,
|
|
98
|
+
onChange
|
|
99
|
+
}) {
|
|
100
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
101
|
+
chunkWIIDQ44X_cjs.NumberInput,
|
|
102
|
+
{
|
|
103
|
+
isIntegerOnly: true,
|
|
104
|
+
isLabelHidden: true,
|
|
105
|
+
label: "Value",
|
|
106
|
+
max: operatorValue.maxValue,
|
|
107
|
+
min: operatorValue.minValue,
|
|
108
|
+
onChange: (value) => onChange({ type: "integer", value }),
|
|
109
|
+
placeholder: "Enter number...",
|
|
110
|
+
units: operatorValue.units,
|
|
111
|
+
value: filterValue?.type === "integer" ? filterValue.value : null
|
|
112
|
+
}
|
|
113
|
+
);
|
|
114
|
+
}
|
|
115
|
+
function FloatEditor({
|
|
116
|
+
operatorValue,
|
|
117
|
+
filterValue,
|
|
118
|
+
onChange
|
|
119
|
+
}) {
|
|
120
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
121
|
+
chunkWIIDQ44X_cjs.NumberInput,
|
|
122
|
+
{
|
|
123
|
+
isLabelHidden: true,
|
|
124
|
+
label: "Value",
|
|
125
|
+
max: operatorValue.maxValue,
|
|
126
|
+
min: operatorValue.minValue,
|
|
127
|
+
onChange: (value) => onChange({ type: "float", value }),
|
|
128
|
+
placeholder: "Enter number...",
|
|
129
|
+
units: operatorValue.units,
|
|
130
|
+
value: filterValue?.type === "float" ? filterValue.value : null
|
|
131
|
+
}
|
|
132
|
+
);
|
|
133
|
+
}
|
|
134
|
+
function TimeEditor({
|
|
135
|
+
operatorValue,
|
|
136
|
+
filterValue,
|
|
137
|
+
onChange
|
|
138
|
+
}) {
|
|
139
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
140
|
+
chunkEETTQWW5_cjs.TimeInput,
|
|
141
|
+
{
|
|
142
|
+
isLabelHidden: true,
|
|
143
|
+
label: "Time",
|
|
144
|
+
max: typeof operatorValue.maxValue === "string" ? polyfill.Temporal.PlainTime.from(operatorValue.maxValue) : void 0,
|
|
145
|
+
min: typeof operatorValue.minValue === "string" ? polyfill.Temporal.PlainTime.from(operatorValue.minValue) : void 0,
|
|
146
|
+
onChange: (value) => {
|
|
147
|
+
if (value != null) {
|
|
148
|
+
onChange({ type: "time", value: value.toString() });
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
value: filterValue?.type === "time" ? polyfill.Temporal.PlainTime.from(filterValue.value) : void 0
|
|
152
|
+
}
|
|
153
|
+
);
|
|
154
|
+
}
|
|
155
|
+
function DateAbsoluteEditor({
|
|
156
|
+
filterValue,
|
|
157
|
+
onChange,
|
|
158
|
+
timezoneID
|
|
159
|
+
}) {
|
|
160
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
161
|
+
chunkTPSOUQG7_cjs.DateInput,
|
|
162
|
+
{
|
|
163
|
+
isLabelHidden: true,
|
|
164
|
+
label: "Date",
|
|
165
|
+
onChange: (value) => {
|
|
166
|
+
if (value != null) {
|
|
167
|
+
onChange({
|
|
168
|
+
type: "date_absolute",
|
|
169
|
+
unixSeconds: chunkCK3UJQRI_cjs.plainDateToUnixSeconds(value, timezoneID)
|
|
170
|
+
});
|
|
171
|
+
}
|
|
172
|
+
},
|
|
173
|
+
value: filterValue?.type === "date_absolute" ? chunkCK3UJQRI_cjs.plainDateFromUnixSeconds(filterValue.unixSeconds, timezoneID) : void 0
|
|
174
|
+
}
|
|
175
|
+
);
|
|
176
|
+
}
|
|
177
|
+
function DateRelativeEditor({
|
|
178
|
+
operatorValue,
|
|
179
|
+
filterValue,
|
|
180
|
+
onChange
|
|
181
|
+
}) {
|
|
182
|
+
const options = react.useMemo(() => {
|
|
183
|
+
const result = [];
|
|
184
|
+
const units = [
|
|
185
|
+
{ plural: "days", unit: "day" },
|
|
186
|
+
{ plural: "weeks", unit: "week" },
|
|
187
|
+
{ plural: "months", unit: "month" }
|
|
188
|
+
];
|
|
189
|
+
for (const { plural, unit } of units) {
|
|
190
|
+
const amounts = unit === "day" ? [1, 3, 7, 14, 30] : unit === "week" ? [1, 2, 4] : [1, 3, 6, 12];
|
|
191
|
+
for (const amount of amounts) {
|
|
192
|
+
if (operatorValue.isPastAllowed !== false) {
|
|
193
|
+
result.push({
|
|
194
|
+
label: `${amount} ${amount === 1 ? unit : plural} ago`,
|
|
195
|
+
value: `${amount}${unit[0]}_ago`
|
|
196
|
+
});
|
|
197
|
+
}
|
|
198
|
+
if (operatorValue.isFutureAllowed !== false) {
|
|
199
|
+
result.push({
|
|
200
|
+
label: `${amount} ${amount === 1 ? unit : plural} from now`,
|
|
201
|
+
value: `${amount}${unit[0]}_from_now`
|
|
202
|
+
});
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
return result;
|
|
207
|
+
}, [operatorValue.isFutureAllowed, operatorValue.isPastAllowed]);
|
|
208
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
209
|
+
chunk6NIFOTUZ_cjs.Select,
|
|
210
|
+
{
|
|
211
|
+
isLabelHidden: true,
|
|
212
|
+
label: "Relative date",
|
|
213
|
+
onChange: (value) => {
|
|
214
|
+
if (value != null) {
|
|
215
|
+
onChange({ type: "date_relative", value }, true);
|
|
216
|
+
}
|
|
217
|
+
},
|
|
218
|
+
options,
|
|
219
|
+
value: filterValue?.type === "date_relative" ? filterValue.value : null
|
|
220
|
+
}
|
|
221
|
+
);
|
|
222
|
+
}
|
|
223
|
+
function DateRangeEditor({
|
|
224
|
+
filterValue,
|
|
225
|
+
onChange,
|
|
226
|
+
timezoneID
|
|
227
|
+
}) {
|
|
228
|
+
const startValue = filterValue?.type === "date_range" && filterValue.value.start.type === "ABSOLUTE" ? chunkCK3UJQRI_cjs.plainDateFromUnixSeconds(
|
|
229
|
+
filterValue.value.start.unixSeconds,
|
|
230
|
+
timezoneID
|
|
231
|
+
) : void 0;
|
|
232
|
+
const endValue = filterValue?.type === "date_range" && filterValue.value.end.type === "ABSOLUTE" ? chunkCK3UJQRI_cjs.plainDateFromUnixSeconds(filterValue.value.end.unixSeconds, timezoneID) : void 0;
|
|
233
|
+
const handleStartChange = react.useCallback(
|
|
234
|
+
(value) => {
|
|
235
|
+
const existingEnd = filterValue?.type === "date_range" ? filterValue.value.end : { type: "NOW" };
|
|
236
|
+
onChange({
|
|
237
|
+
type: "date_range",
|
|
238
|
+
value: {
|
|
239
|
+
end: existingEnd,
|
|
240
|
+
start: {
|
|
241
|
+
type: "ABSOLUTE",
|
|
242
|
+
unixSeconds: value == null ? 0 : chunkCK3UJQRI_cjs.plainDateToUnixSeconds(value, timezoneID)
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
});
|
|
246
|
+
},
|
|
247
|
+
[filterValue, onChange, timezoneID]
|
|
248
|
+
);
|
|
249
|
+
const handleEndChange = react.useCallback(
|
|
250
|
+
(value) => {
|
|
251
|
+
const existingStart = filterValue?.type === "date_range" ? filterValue.value.start : { type: "NOW" };
|
|
252
|
+
onChange({
|
|
253
|
+
type: "date_range",
|
|
254
|
+
value: {
|
|
255
|
+
end: {
|
|
256
|
+
type: "ABSOLUTE",
|
|
257
|
+
unixSeconds: value == null ? 0 : chunkCK3UJQRI_cjs.plainDateToUnixSeconds(value, timezoneID)
|
|
258
|
+
},
|
|
259
|
+
start: existingStart
|
|
260
|
+
}
|
|
261
|
+
});
|
|
262
|
+
},
|
|
263
|
+
[filterValue, onChange, timezoneID]
|
|
264
|
+
);
|
|
265
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
266
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
267
|
+
chunkTPSOUQG7_cjs.DateInput,
|
|
268
|
+
{
|
|
269
|
+
isLabelHidden: true,
|
|
270
|
+
label: "Start date",
|
|
271
|
+
onChange: handleStartChange,
|
|
272
|
+
value: startValue
|
|
273
|
+
}
|
|
274
|
+
),
|
|
275
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
276
|
+
chunkTPSOUQG7_cjs.DateInput,
|
|
277
|
+
{
|
|
278
|
+
isLabelHidden: true,
|
|
279
|
+
label: "End date",
|
|
280
|
+
onChange: handleEndChange,
|
|
281
|
+
value: endValue
|
|
282
|
+
}
|
|
283
|
+
)
|
|
284
|
+
] });
|
|
285
|
+
}
|
|
286
|
+
function EnumEditor({
|
|
287
|
+
operatorValue,
|
|
288
|
+
filterValue,
|
|
289
|
+
onChange
|
|
290
|
+
}) {
|
|
291
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
292
|
+
chunk6NIFOTUZ_cjs.Select,
|
|
293
|
+
{
|
|
294
|
+
isLabelHidden: true,
|
|
295
|
+
label: "Value",
|
|
296
|
+
onChange: (value) => {
|
|
297
|
+
if (value != null) {
|
|
298
|
+
onChange({ type: "enum", value }, true);
|
|
299
|
+
}
|
|
300
|
+
},
|
|
301
|
+
options: operatorValue.values.map((item) => ({
|
|
302
|
+
icon: item.icon,
|
|
303
|
+
label: item.label,
|
|
304
|
+
value: item.value
|
|
305
|
+
})),
|
|
306
|
+
value: filterValue?.type === "enum" ? filterValue.value : null
|
|
307
|
+
}
|
|
308
|
+
);
|
|
309
|
+
}
|
|
310
|
+
function EnumListEditor({
|
|
311
|
+
operatorValue,
|
|
312
|
+
filterValue,
|
|
313
|
+
onChange
|
|
314
|
+
}) {
|
|
315
|
+
const items = react.useMemo(
|
|
316
|
+
() => enumItemsToSearchableItems(operatorValue.values),
|
|
317
|
+
[operatorValue.values]
|
|
318
|
+
);
|
|
319
|
+
const source = react.useMemo(() => chunkPDXZDPOY_cjs.createStaticSource(items), [items]);
|
|
320
|
+
const currentValue = react.useMemo(() => {
|
|
321
|
+
if (filterValue?.type !== "enum_list") {
|
|
322
|
+
return [];
|
|
323
|
+
}
|
|
324
|
+
return filterValue.value.map((value) => ({
|
|
325
|
+
id: value,
|
|
326
|
+
label: operatorValue.values.find((item) => item.value === value)?.label ?? value
|
|
327
|
+
}));
|
|
328
|
+
}, [filterValue, operatorValue.values]);
|
|
329
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
330
|
+
chunkWE3ECIRS_cjs.TagsInput,
|
|
331
|
+
{
|
|
332
|
+
debounceMs: 0,
|
|
333
|
+
hasEntriesOnFocus: true,
|
|
334
|
+
isLabelHidden: true,
|
|
335
|
+
label: "Values",
|
|
336
|
+
onChange: (items2) => {
|
|
337
|
+
onChange({ type: "enum_list", value: items2.map((item) => item.id) });
|
|
338
|
+
},
|
|
339
|
+
placeholder: "Select values...",
|
|
340
|
+
searchSource: source,
|
|
341
|
+
value: currentValue
|
|
342
|
+
}
|
|
343
|
+
);
|
|
344
|
+
}
|
|
345
|
+
function EntityListEditor({
|
|
346
|
+
operatorValue,
|
|
347
|
+
filterValue,
|
|
348
|
+
onChange
|
|
349
|
+
}) {
|
|
350
|
+
const source = operatorValue.searchSource ?? emptySource();
|
|
351
|
+
const currentValue = react.useMemo(() => {
|
|
352
|
+
if (filterValue?.type !== "entity_list") {
|
|
353
|
+
return [];
|
|
354
|
+
}
|
|
355
|
+
return filterValue.value.map((entity) => ({
|
|
356
|
+
auxiliaryData: entity.photo == null ? void 0 : { photo: entity.photo },
|
|
357
|
+
id: entity.id,
|
|
358
|
+
label: entity.label
|
|
359
|
+
}));
|
|
360
|
+
}, [filterValue]);
|
|
361
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
362
|
+
chunkWE3ECIRS_cjs.TagsInput,
|
|
363
|
+
{
|
|
364
|
+
debounceMs: operatorValue.searchSource == null ? 0 : 150,
|
|
365
|
+
isLabelHidden: true,
|
|
366
|
+
label: "Entities",
|
|
367
|
+
onChange: (items) => {
|
|
368
|
+
onChange({
|
|
369
|
+
type: "entity_list",
|
|
370
|
+
value: items.map((item) => ({
|
|
371
|
+
id: item.id,
|
|
372
|
+
label: item.label,
|
|
373
|
+
...typeof item.auxiliaryData === "object" && item.auxiliaryData != null && "photo" in item.auxiliaryData ? { photo: String(item.auxiliaryData.photo) } : {}
|
|
374
|
+
}))
|
|
375
|
+
});
|
|
376
|
+
},
|
|
377
|
+
placeholder: "Search...",
|
|
378
|
+
renderItem: operatorValue.renderItem,
|
|
379
|
+
searchSource: source,
|
|
380
|
+
value: currentValue
|
|
381
|
+
}
|
|
382
|
+
);
|
|
383
|
+
}
|
|
384
|
+
function CustomEditor({
|
|
385
|
+
operatorValue,
|
|
386
|
+
filterValue,
|
|
387
|
+
isDisabled,
|
|
388
|
+
onChange
|
|
389
|
+
}) {
|
|
390
|
+
const EditorComponent = operatorValue.Editor;
|
|
391
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
392
|
+
EditorComponent,
|
|
393
|
+
{
|
|
394
|
+
isDisabled,
|
|
395
|
+
onChange: (value) => {
|
|
396
|
+
if (value != null) {
|
|
397
|
+
onChange({ type: "custom", value });
|
|
398
|
+
}
|
|
399
|
+
},
|
|
400
|
+
placeholder: "Enter value...",
|
|
401
|
+
value: filterValue?.type === "custom" ? filterValue.value : null
|
|
402
|
+
}
|
|
403
|
+
);
|
|
404
|
+
}
|
|
405
|
+
function SearchFilterInputValueEditor({
|
|
406
|
+
filterValue,
|
|
407
|
+
isDisabled,
|
|
408
|
+
onChange,
|
|
409
|
+
onEnter,
|
|
410
|
+
operatorValue,
|
|
411
|
+
timezoneID
|
|
412
|
+
}) {
|
|
413
|
+
const effectiveTimezoneID = timezoneID ?? chunkR37R7DEV_cjs.getBrowserTimezoneID();
|
|
414
|
+
switch (operatorValue.type) {
|
|
415
|
+
case "empty":
|
|
416
|
+
case "nested":
|
|
417
|
+
return null;
|
|
418
|
+
case "string":
|
|
419
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
420
|
+
StringEditor,
|
|
421
|
+
{
|
|
422
|
+
filterValue,
|
|
423
|
+
onChange,
|
|
424
|
+
operatorValue
|
|
425
|
+
}
|
|
426
|
+
);
|
|
427
|
+
case "string_list":
|
|
428
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
429
|
+
StringListEditor,
|
|
430
|
+
{
|
|
431
|
+
filterValue,
|
|
432
|
+
onChange,
|
|
433
|
+
operatorValue
|
|
434
|
+
}
|
|
435
|
+
);
|
|
436
|
+
case "integer":
|
|
437
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
438
|
+
IntegerEditor,
|
|
439
|
+
{
|
|
440
|
+
filterValue,
|
|
441
|
+
onChange,
|
|
442
|
+
operatorValue
|
|
443
|
+
}
|
|
444
|
+
);
|
|
445
|
+
case "float":
|
|
446
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
447
|
+
FloatEditor,
|
|
448
|
+
{
|
|
449
|
+
filterValue,
|
|
450
|
+
onChange,
|
|
451
|
+
operatorValue
|
|
452
|
+
}
|
|
453
|
+
);
|
|
454
|
+
case "time":
|
|
455
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
456
|
+
TimeEditor,
|
|
457
|
+
{
|
|
458
|
+
filterValue,
|
|
459
|
+
onChange,
|
|
460
|
+
operatorValue
|
|
461
|
+
}
|
|
462
|
+
);
|
|
463
|
+
case "date_absolute":
|
|
464
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
465
|
+
DateAbsoluteEditor,
|
|
466
|
+
{
|
|
467
|
+
filterValue,
|
|
468
|
+
onChange,
|
|
469
|
+
timezoneID: effectiveTimezoneID
|
|
470
|
+
}
|
|
471
|
+
);
|
|
472
|
+
case "date_relative":
|
|
473
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
474
|
+
DateRelativeEditor,
|
|
475
|
+
{
|
|
476
|
+
filterValue,
|
|
477
|
+
onChange,
|
|
478
|
+
operatorValue
|
|
479
|
+
}
|
|
480
|
+
);
|
|
481
|
+
case "date_range":
|
|
482
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
483
|
+
DateRangeEditor,
|
|
484
|
+
{
|
|
485
|
+
filterValue,
|
|
486
|
+
onChange,
|
|
487
|
+
timezoneID: effectiveTimezoneID
|
|
488
|
+
}
|
|
489
|
+
);
|
|
490
|
+
case "enum":
|
|
491
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
492
|
+
EnumEditor,
|
|
493
|
+
{
|
|
494
|
+
filterValue,
|
|
495
|
+
onChange,
|
|
496
|
+
operatorValue
|
|
497
|
+
}
|
|
498
|
+
);
|
|
499
|
+
case "enum_list":
|
|
500
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
501
|
+
EnumListEditor,
|
|
502
|
+
{
|
|
503
|
+
filterValue,
|
|
504
|
+
onChange,
|
|
505
|
+
operatorValue
|
|
506
|
+
}
|
|
507
|
+
);
|
|
508
|
+
case "entity_list":
|
|
509
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
510
|
+
EntityListEditor,
|
|
511
|
+
{
|
|
512
|
+
filterValue,
|
|
513
|
+
onChange,
|
|
514
|
+
operatorValue
|
|
515
|
+
}
|
|
516
|
+
);
|
|
517
|
+
case "custom":
|
|
518
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
519
|
+
CustomEditor,
|
|
520
|
+
{
|
|
521
|
+
filterValue,
|
|
522
|
+
isDisabled,
|
|
523
|
+
onChange,
|
|
524
|
+
operatorValue
|
|
525
|
+
}
|
|
526
|
+
);
|
|
527
|
+
}
|
|
528
|
+
}
|
|
529
|
+
var styles = {
|
|
530
|
+
root: chunkAZDWQGAX_cjs.css({
|
|
531
|
+
overflow: "hidden",
|
|
532
|
+
minW: "100"
|
|
533
|
+
}),
|
|
534
|
+
content: chunkAZDWQGAX_cjs.css({
|
|
535
|
+
p: "4"
|
|
536
|
+
}),
|
|
537
|
+
footer: chunkAZDWQGAX_cjs.css({
|
|
538
|
+
px: "3",
|
|
539
|
+
pb: "3"
|
|
540
|
+
}),
|
|
541
|
+
fieldSelector: chunkAZDWQGAX_cjs.css({
|
|
542
|
+
flexShrink: 0
|
|
543
|
+
}),
|
|
544
|
+
operatorSelector: chunkAZDWQGAX_cjs.css({
|
|
545
|
+
flex: "1 0 auto"
|
|
546
|
+
}),
|
|
547
|
+
valueEditor: chunkAZDWQGAX_cjs.css({
|
|
548
|
+
flex: "2 1 0",
|
|
549
|
+
minW: 0
|
|
550
|
+
}),
|
|
551
|
+
nestedList: chunkAZDWQGAX_cjs.css({
|
|
552
|
+
display: "flex",
|
|
553
|
+
flexDirection: "column",
|
|
554
|
+
gap: "2",
|
|
555
|
+
w: "full",
|
|
556
|
+
listStyleType: "none",
|
|
557
|
+
m: 0,
|
|
558
|
+
p: 0
|
|
559
|
+
}),
|
|
560
|
+
nestedNode: chunkAZDWQGAX_cjs.css({
|
|
561
|
+
display: "flex",
|
|
562
|
+
flexDirection: "column",
|
|
563
|
+
gap: "2",
|
|
564
|
+
ps: "3",
|
|
565
|
+
borderInlineStartWidth: "default",
|
|
566
|
+
borderInlineStartStyle: "solid",
|
|
567
|
+
borderColor: "border"
|
|
568
|
+
}),
|
|
569
|
+
nestedRow: chunkAZDWQGAX_cjs.css({
|
|
570
|
+
display: "flex",
|
|
571
|
+
alignItems: "center",
|
|
572
|
+
gap: "2",
|
|
573
|
+
w: "full"
|
|
574
|
+
}),
|
|
575
|
+
nestedCell: chunkAZDWQGAX_cjs.css({
|
|
576
|
+
minW: 0
|
|
577
|
+
}),
|
|
578
|
+
nestedField: chunkAZDWQGAX_cjs.css({
|
|
579
|
+
flex: "0 0 200px"
|
|
580
|
+
}),
|
|
581
|
+
nestedOperator: chunkAZDWQGAX_cjs.css({
|
|
582
|
+
flex: "0 0 180px"
|
|
583
|
+
}),
|
|
584
|
+
nestedValue: chunkAZDWQGAX_cjs.css({
|
|
585
|
+
flex: "2 1 0"
|
|
586
|
+
})
|
|
587
|
+
};
|
|
588
|
+
function initEditableFilter(config, filter) {
|
|
589
|
+
const operator = config.getOperator(filter.field, filter.operator);
|
|
590
|
+
if (operator?.value.type === "nested" && filter.value.type === "nested") {
|
|
591
|
+
return {
|
|
592
|
+
_subFilters: filter.value.value.map(
|
|
593
|
+
(subFilter) => initEditableFilter(config, subFilter)
|
|
594
|
+
),
|
|
595
|
+
field: filter.field,
|
|
596
|
+
operator: filter.operator,
|
|
597
|
+
value: filter.value
|
|
598
|
+
};
|
|
599
|
+
}
|
|
600
|
+
return {
|
|
601
|
+
field: filter.field,
|
|
602
|
+
operator: filter.operator,
|
|
603
|
+
value: filter.value
|
|
604
|
+
};
|
|
605
|
+
}
|
|
606
|
+
function isEditableFilterComplete(config, filter) {
|
|
607
|
+
if (filter.operator == null) {
|
|
608
|
+
return false;
|
|
609
|
+
}
|
|
610
|
+
const operator = config.getOperator(filter.field, filter.operator);
|
|
611
|
+
if (operator?.value.type === "nested") {
|
|
612
|
+
const subFilters = filter._subFilters ?? [];
|
|
613
|
+
return subFilters.length > 0 && subFilters.every((subFilter) => isEditableFilterComplete(config, subFilter));
|
|
614
|
+
}
|
|
615
|
+
return filter.value != null;
|
|
616
|
+
}
|
|
617
|
+
function editableToCompleteFilter(config, filter) {
|
|
618
|
+
if (filter.operator == null) {
|
|
619
|
+
return null;
|
|
620
|
+
}
|
|
621
|
+
const operator = config.getOperator(filter.field, filter.operator);
|
|
622
|
+
if (operator?.value.type === "nested") {
|
|
623
|
+
return {
|
|
624
|
+
field: filter.field,
|
|
625
|
+
operator: filter.operator,
|
|
626
|
+
value: {
|
|
627
|
+
type: "nested",
|
|
628
|
+
value: (filter._subFilters ?? []).map((subFilter) => editableToCompleteFilter(config, subFilter)).filter(
|
|
629
|
+
(subFilter) => subFilter != null
|
|
630
|
+
)
|
|
631
|
+
}
|
|
632
|
+
};
|
|
633
|
+
}
|
|
634
|
+
if (filter.value == null) {
|
|
635
|
+
return null;
|
|
636
|
+
}
|
|
637
|
+
return { field: filter.field, operator: filter.operator, value: filter.value };
|
|
638
|
+
}
|
|
639
|
+
function NestedSubFilterRow({
|
|
640
|
+
config,
|
|
641
|
+
isReadOnly,
|
|
642
|
+
onChange,
|
|
643
|
+
onRemove,
|
|
644
|
+
subFilter
|
|
645
|
+
}) {
|
|
646
|
+
const fieldOptions = react.useMemo(
|
|
647
|
+
() => config.getVisibleFields().map((field) => ({ label: field.label, value: field.key })),
|
|
648
|
+
[config]
|
|
649
|
+
);
|
|
650
|
+
const operatorOptions = react.useMemo(
|
|
651
|
+
() => config.getVisibleOperators(subFilter.field).map((operator) => ({ label: operator.label, value: operator.key })),
|
|
652
|
+
[config, subFilter.field]
|
|
653
|
+
);
|
|
654
|
+
const currentOperator = subFilter.operator == null ? void 0 : config.getOperator(subFilter.field, subFilter.operator);
|
|
655
|
+
const operatorValue = currentOperator?.value;
|
|
656
|
+
const isNested = operatorValue?.type === "nested";
|
|
657
|
+
const isEmpty = operatorValue?.type === "empty";
|
|
658
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles.nestedRow, children: [
|
|
659
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: `${styles.nestedCell} ${styles.nestedField}`, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
660
|
+
chunk6NIFOTUZ_cjs.Select,
|
|
661
|
+
{
|
|
662
|
+
isDisabled: isReadOnly,
|
|
663
|
+
isLabelHidden: true,
|
|
664
|
+
label: "Field",
|
|
665
|
+
onChange: (fieldKey) => {
|
|
666
|
+
if (fieldKey == null) {
|
|
667
|
+
return;
|
|
668
|
+
}
|
|
669
|
+
const defaultOperator = config.getDefaultOperator(fieldKey);
|
|
670
|
+
const nextOperator = defaultOperator == null ? void 0 : config.getOperator(fieldKey, defaultOperator.key);
|
|
671
|
+
onChange({
|
|
672
|
+
_subFilters: nextOperator?.value.type === "nested" ? [] : void 0,
|
|
673
|
+
field: fieldKey,
|
|
674
|
+
operator: defaultOperator?.key,
|
|
675
|
+
value: void 0
|
|
676
|
+
});
|
|
677
|
+
},
|
|
678
|
+
options: fieldOptions,
|
|
679
|
+
value: subFilter.field
|
|
680
|
+
}
|
|
681
|
+
) }),
|
|
682
|
+
operatorOptions.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: `${styles.nestedCell} ${styles.nestedOperator}`, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
683
|
+
chunk6NIFOTUZ_cjs.Select,
|
|
684
|
+
{
|
|
685
|
+
isDisabled: isReadOnly,
|
|
686
|
+
isLabelHidden: true,
|
|
687
|
+
label: "Operator",
|
|
688
|
+
onChange: (operatorKey) => {
|
|
689
|
+
if (operatorKey == null) {
|
|
690
|
+
return;
|
|
691
|
+
}
|
|
692
|
+
const nextOperator = config.getOperator(
|
|
693
|
+
subFilter.field,
|
|
694
|
+
operatorKey
|
|
695
|
+
);
|
|
696
|
+
const keepValue = nextOperator != null && nextOperator.value.type === currentOperator?.value.type;
|
|
697
|
+
onChange({
|
|
698
|
+
...subFilter,
|
|
699
|
+
_subFilters: nextOperator?.value.type === "nested" ? subFilter._subFilters ?? [] : void 0,
|
|
700
|
+
operator: operatorKey,
|
|
701
|
+
value: keepValue ? subFilter.value : void 0
|
|
702
|
+
});
|
|
703
|
+
},
|
|
704
|
+
options: operatorOptions,
|
|
705
|
+
value: subFilter.operator ?? null
|
|
706
|
+
}
|
|
707
|
+
) }) : null,
|
|
708
|
+
operatorValue != null && !isEmpty && !isNested ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: `${styles.nestedCell} ${styles.nestedValue}`, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
709
|
+
SearchFilterInputValueEditor,
|
|
710
|
+
{
|
|
711
|
+
config,
|
|
712
|
+
filterValue: subFilter.value,
|
|
713
|
+
isDisabled: isReadOnly,
|
|
714
|
+
onChange: (value) => onChange({ ...subFilter, value }),
|
|
715
|
+
operatorValue
|
|
716
|
+
}
|
|
717
|
+
) }) : null,
|
|
718
|
+
!isReadOnly ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
719
|
+
chunkNILB6Y4Z_cjs.Button,
|
|
720
|
+
{
|
|
721
|
+
icon: lucideReact.X,
|
|
722
|
+
isIconOnly: true,
|
|
723
|
+
label: "Remove filter",
|
|
724
|
+
onClick: onRemove,
|
|
725
|
+
size: "sm",
|
|
726
|
+
variant: "ghost"
|
|
727
|
+
}
|
|
728
|
+
) : null
|
|
729
|
+
] });
|
|
730
|
+
}
|
|
731
|
+
function NestedEditor({
|
|
732
|
+
config,
|
|
733
|
+
isReadOnly,
|
|
734
|
+
onPartialFilterChange,
|
|
735
|
+
onOperatorChange,
|
|
736
|
+
operatorOptions,
|
|
737
|
+
partialFilter
|
|
738
|
+
}) {
|
|
739
|
+
const [subFilters, setSubFilters] = react.useState(() => {
|
|
740
|
+
if (partialFilter.value?.type === "nested") {
|
|
741
|
+
return partialFilter.value.value.map(
|
|
742
|
+
(filter) => initEditableFilter(config, filter)
|
|
743
|
+
);
|
|
744
|
+
}
|
|
745
|
+
return [];
|
|
746
|
+
});
|
|
747
|
+
const syncToParent = react.useCallback(
|
|
748
|
+
(nextSubFilters) => {
|
|
749
|
+
if (nextSubFilters.length > 0 && nextSubFilters.every((filter) => isEditableFilterComplete(config, filter))) {
|
|
750
|
+
onPartialFilterChange({
|
|
751
|
+
...partialFilter,
|
|
752
|
+
value: {
|
|
753
|
+
type: "nested",
|
|
754
|
+
value: nextSubFilters.map((filter) => editableToCompleteFilter(config, filter)).filter(
|
|
755
|
+
(filter) => filter != null
|
|
756
|
+
)
|
|
757
|
+
}
|
|
758
|
+
});
|
|
759
|
+
} else {
|
|
760
|
+
onPartialFilterChange({ ...partialFilter, value: void 0 });
|
|
761
|
+
}
|
|
762
|
+
},
|
|
763
|
+
[config, onPartialFilterChange, partialFilter]
|
|
764
|
+
);
|
|
765
|
+
const addSubFilter = () => {
|
|
766
|
+
const fields = config.getVisibleFields();
|
|
767
|
+
if (fields.length === 0) {
|
|
768
|
+
return;
|
|
769
|
+
}
|
|
770
|
+
const field = fields[0];
|
|
771
|
+
const operator = config.getDefaultOperator(field.key);
|
|
772
|
+
const next = {
|
|
773
|
+
field: field.key,
|
|
774
|
+
operator: operator?.key,
|
|
775
|
+
value: void 0,
|
|
776
|
+
_subFilters: operator?.value.type === "nested" ? [] : void 0
|
|
777
|
+
};
|
|
778
|
+
setSubFilters((previous) => {
|
|
779
|
+
const updated = [...previous, next];
|
|
780
|
+
syncToParent(updated);
|
|
781
|
+
return updated;
|
|
782
|
+
});
|
|
783
|
+
};
|
|
784
|
+
const updateSubFilter = (index, nextSubFilter) => {
|
|
785
|
+
setSubFilters((previous) => {
|
|
786
|
+
const updated = [...previous];
|
|
787
|
+
updated[index] = nextSubFilter;
|
|
788
|
+
syncToParent(updated);
|
|
789
|
+
return updated;
|
|
790
|
+
});
|
|
791
|
+
};
|
|
792
|
+
const removeSubFilter = (index) => {
|
|
793
|
+
setSubFilters((previous) => {
|
|
794
|
+
const updated = previous.filter((_, i) => i !== index);
|
|
795
|
+
syncToParent(updated);
|
|
796
|
+
return updated;
|
|
797
|
+
});
|
|
798
|
+
};
|
|
799
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(chunkCZJUKLFD_cjs.VStack, { gap: 2, children: [
|
|
800
|
+
operatorOptions.length > 1 ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
801
|
+
chunk6NIFOTUZ_cjs.Select,
|
|
802
|
+
{
|
|
803
|
+
isDisabled: isReadOnly,
|
|
804
|
+
isLabelHidden: true,
|
|
805
|
+
label: "Group operator",
|
|
806
|
+
onChange: (operatorKey) => {
|
|
807
|
+
if (operatorKey != null) {
|
|
808
|
+
onOperatorChange(operatorKey);
|
|
809
|
+
}
|
|
810
|
+
},
|
|
811
|
+
options: operatorOptions,
|
|
812
|
+
value: partialFilter.operator ?? null
|
|
813
|
+
}
|
|
814
|
+
) : null,
|
|
815
|
+
/* @__PURE__ */ jsxRuntime.jsx("ul", { className: styles.nestedList, role: "group", children: subFilters.map((subFilter, index) => /* @__PURE__ */ jsxRuntime.jsx("li", { className: styles.nestedNode, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
816
|
+
NestedSubFilterRow,
|
|
817
|
+
{
|
|
818
|
+
config,
|
|
819
|
+
isReadOnly,
|
|
820
|
+
onChange: (nextSubFilter) => updateSubFilter(index, nextSubFilter),
|
|
821
|
+
onRemove: () => removeSubFilter(index),
|
|
822
|
+
subFilter
|
|
823
|
+
}
|
|
824
|
+
) }, `${subFilter.field}-${index}`)) }),
|
|
825
|
+
!isReadOnly ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
826
|
+
chunkNILB6Y4Z_cjs.Button,
|
|
827
|
+
{
|
|
828
|
+
label: "+ Add filter",
|
|
829
|
+
onClick: addSubFilter,
|
|
830
|
+
size: "sm",
|
|
831
|
+
variant: "ghost"
|
|
832
|
+
}
|
|
833
|
+
) : null
|
|
834
|
+
] });
|
|
835
|
+
}
|
|
836
|
+
function SearchFilterInputEditPopover({
|
|
837
|
+
config,
|
|
838
|
+
filter: initialFilter,
|
|
839
|
+
isReadOnly = false,
|
|
840
|
+
maxOperatorMenuItems,
|
|
841
|
+
mode,
|
|
842
|
+
onCancel,
|
|
843
|
+
onSave,
|
|
844
|
+
saveButtonLabel = "Apply"
|
|
845
|
+
}) {
|
|
846
|
+
const [partialFilter, setPartialFilter] = react.useState(initialFilter);
|
|
847
|
+
const valueEditorRef = react.useRef(null);
|
|
848
|
+
const currentOperator = partialFilter.operator == null ? void 0 : config.getOperator(partialFilter.field, partialFilter.operator);
|
|
849
|
+
const operatorValue = currentOperator?.value;
|
|
850
|
+
const isEmptyType = operatorValue?.type === "empty";
|
|
851
|
+
const isNestedType = operatorValue?.type === "nested";
|
|
852
|
+
react.useEffect(() => {
|
|
853
|
+
let innerFrame;
|
|
854
|
+
const frame = requestAnimationFrame(() => {
|
|
855
|
+
innerFrame = requestAnimationFrame(() => {
|
|
856
|
+
valueEditorRef.current?.querySelector(
|
|
857
|
+
'input:not([disabled]), button:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"])'
|
|
858
|
+
)?.focus();
|
|
859
|
+
});
|
|
860
|
+
});
|
|
861
|
+
return () => {
|
|
862
|
+
cancelAnimationFrame(frame);
|
|
863
|
+
if (innerFrame != null) {
|
|
864
|
+
cancelAnimationFrame(innerFrame);
|
|
865
|
+
}
|
|
866
|
+
};
|
|
867
|
+
}, []);
|
|
868
|
+
react.useEffect(() => {
|
|
869
|
+
if (isEmptyType && partialFilter.operator != null) {
|
|
870
|
+
onSave({
|
|
871
|
+
field: partialFilter.field,
|
|
872
|
+
operator: partialFilter.operator,
|
|
873
|
+
value: { type: "empty" }
|
|
874
|
+
});
|
|
875
|
+
}
|
|
876
|
+
}, [isEmptyType, onSave, partialFilter.field, partialFilter.operator]);
|
|
877
|
+
const fieldOptions = react.useMemo(
|
|
878
|
+
() => config.getVisibleFields().map((field) => ({ label: field.label, value: field.key })),
|
|
879
|
+
[config]
|
|
880
|
+
);
|
|
881
|
+
const operatorOptions = react.useMemo(() => {
|
|
882
|
+
const allOptions = config.getVisibleOperators(partialFilter.field).map((operator) => ({ label: operator.label, value: operator.key }));
|
|
883
|
+
return maxOperatorMenuItems != null ? allOptions.slice(0, maxOperatorMenuItems) : allOptions;
|
|
884
|
+
}, [config, maxOperatorMenuItems, partialFilter.field]);
|
|
885
|
+
const isSaveDisabled = partialFilter.operator == null || partialFilter.value == null;
|
|
886
|
+
const handleSave = () => {
|
|
887
|
+
if (partialFilter.operator != null && partialFilter.value != null) {
|
|
888
|
+
onSave({
|
|
889
|
+
field: partialFilter.field,
|
|
890
|
+
operator: partialFilter.operator,
|
|
891
|
+
value: partialFilter.value
|
|
892
|
+
});
|
|
893
|
+
}
|
|
894
|
+
};
|
|
895
|
+
const handleFieldChange = (fieldKey) => {
|
|
896
|
+
if (fieldKey == null) {
|
|
897
|
+
return;
|
|
898
|
+
}
|
|
899
|
+
const defaultOperator = config.getDefaultOperator(fieldKey);
|
|
900
|
+
setPartialFilter({
|
|
901
|
+
field: fieldKey,
|
|
902
|
+
operator: defaultOperator?.key,
|
|
903
|
+
value: void 0
|
|
904
|
+
});
|
|
905
|
+
};
|
|
906
|
+
const handleOperatorChange = (operatorKey) => {
|
|
907
|
+
if (operatorKey == null) {
|
|
908
|
+
return;
|
|
909
|
+
}
|
|
910
|
+
const nextOperator = config.getOperator(partialFilter.field, operatorKey);
|
|
911
|
+
const keepValue = nextOperator != null && nextOperator.value.type === currentOperator?.value.type;
|
|
912
|
+
setPartialFilter((previous) => ({
|
|
913
|
+
...previous,
|
|
914
|
+
operator: operatorKey,
|
|
915
|
+
value: keepValue ? previous.value : void 0
|
|
916
|
+
}));
|
|
917
|
+
};
|
|
918
|
+
const footer = !isEmptyType ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: styles.footer, children: /* @__PURE__ */ jsxRuntime.jsxs(chunkCZJUKLFD_cjs.HStack, { gap: 2, hAlign: "between", children: [
|
|
919
|
+
!isReadOnly && mode === "edit" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
920
|
+
chunkNILB6Y4Z_cjs.Button,
|
|
921
|
+
{
|
|
922
|
+
label: "Delete",
|
|
923
|
+
onClick: () => onSave(null),
|
|
924
|
+
size: "sm",
|
|
925
|
+
variant: "ghost"
|
|
926
|
+
}
|
|
927
|
+
) : /* @__PURE__ */ jsxRuntime.jsx("div", {}),
|
|
928
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkCZJUKLFD_cjs.HStack, { gap: 2, children: [
|
|
929
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkNILB6Y4Z_cjs.Button, { label: "Cancel", onClick: onCancel, size: "sm", variant: "ghost" }),
|
|
930
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
931
|
+
chunkNILB6Y4Z_cjs.Button,
|
|
932
|
+
{
|
|
933
|
+
isDisabled: isSaveDisabled,
|
|
934
|
+
label: saveButtonLabel,
|
|
935
|
+
onClick: handleSave,
|
|
936
|
+
size: "sm",
|
|
937
|
+
variant: "primary"
|
|
938
|
+
}
|
|
939
|
+
)
|
|
940
|
+
] })
|
|
941
|
+
] }) }) : null;
|
|
942
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
943
|
+
"div",
|
|
944
|
+
{
|
|
945
|
+
className: styles.root,
|
|
946
|
+
onKeyDown: (event) => {
|
|
947
|
+
if (event.key === "Enter" && !isSaveDisabled) {
|
|
948
|
+
const target = event.target;
|
|
949
|
+
const isInsideSelect = target.closest('[role="listbox"]') != null || target.closest('[role="option"]') != null || target.getAttribute("aria-expanded") === "true";
|
|
950
|
+
if (!isInsideSelect) {
|
|
951
|
+
event.preventDefault();
|
|
952
|
+
handleSave();
|
|
953
|
+
}
|
|
954
|
+
} else if (event.key === "Escape" && !event.defaultPrevented) {
|
|
955
|
+
event.preventDefault();
|
|
956
|
+
onCancel();
|
|
957
|
+
}
|
|
958
|
+
},
|
|
959
|
+
children: [
|
|
960
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: styles.content, children: /* @__PURE__ */ jsxRuntime.jsxs(chunkCZJUKLFD_cjs.VStack, { gap: 2, children: [
|
|
961
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkCZJUKLFD_cjs.HStack, { gap: 2, children: [
|
|
962
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: styles.fieldSelector, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
963
|
+
chunk6NIFOTUZ_cjs.Select,
|
|
964
|
+
{
|
|
965
|
+
isDisabled: isReadOnly,
|
|
966
|
+
isLabelHidden: true,
|
|
967
|
+
label: "Field",
|
|
968
|
+
onChange: handleFieldChange,
|
|
969
|
+
options: fieldOptions,
|
|
970
|
+
value: partialFilter.field
|
|
971
|
+
}
|
|
972
|
+
) }),
|
|
973
|
+
!isNestedType && operatorOptions.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: styles.operatorSelector, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
974
|
+
chunk6NIFOTUZ_cjs.Select,
|
|
975
|
+
{
|
|
976
|
+
isDisabled: isReadOnly,
|
|
977
|
+
isLabelHidden: true,
|
|
978
|
+
label: "Operator",
|
|
979
|
+
onChange: handleOperatorChange,
|
|
980
|
+
options: operatorOptions,
|
|
981
|
+
value: partialFilter.operator ?? null
|
|
982
|
+
}
|
|
983
|
+
) }) : null,
|
|
984
|
+
operatorValue != null && !isEmptyType && !isNestedType ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: styles.valueEditor, ref: valueEditorRef, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
985
|
+
SearchFilterInputValueEditor,
|
|
986
|
+
{
|
|
987
|
+
config,
|
|
988
|
+
filterValue: partialFilter.value,
|
|
989
|
+
isDisabled: isReadOnly,
|
|
990
|
+
onChange: (value, shouldSave) => {
|
|
991
|
+
const updated = { ...partialFilter, value };
|
|
992
|
+
setPartialFilter(updated);
|
|
993
|
+
if (shouldSave === true && updated.operator != null) {
|
|
994
|
+
onSave({
|
|
995
|
+
field: updated.field,
|
|
996
|
+
operator: updated.operator,
|
|
997
|
+
value: updated.value
|
|
998
|
+
});
|
|
999
|
+
}
|
|
1000
|
+
},
|
|
1001
|
+
onEnter: handleSave,
|
|
1002
|
+
operatorValue
|
|
1003
|
+
}
|
|
1004
|
+
) }) : null
|
|
1005
|
+
] }),
|
|
1006
|
+
isNestedType ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
1007
|
+
NestedEditor,
|
|
1008
|
+
{
|
|
1009
|
+
config,
|
|
1010
|
+
isReadOnly,
|
|
1011
|
+
onOperatorChange: (operatorKey) => setPartialFilter((previous) => ({
|
|
1012
|
+
...previous,
|
|
1013
|
+
operator: operatorKey
|
|
1014
|
+
})),
|
|
1015
|
+
onPartialFilterChange: setPartialFilter,
|
|
1016
|
+
operatorOptions,
|
|
1017
|
+
partialFilter
|
|
1018
|
+
}
|
|
1019
|
+
) : null
|
|
1020
|
+
] }) }),
|
|
1021
|
+
footer
|
|
1022
|
+
]
|
|
1023
|
+
}
|
|
1024
|
+
);
|
|
1025
|
+
}
|
|
1026
|
+
SearchFilterInputEditPopover.displayName = "SearchFilterInputEditPopover";
|
|
1027
|
+
|
|
1028
|
+
// src/components/SearchFilterInput/formatFilterValue.ts
|
|
1029
|
+
function truncate(value, maxLength) {
|
|
1030
|
+
return value.length > maxLength ? `${value.slice(0, maxLength - 1)}...` : value;
|
|
1031
|
+
}
|
|
1032
|
+
function enumLabel(value, values) {
|
|
1033
|
+
return values.find((item) => item.value === value)?.label ?? value;
|
|
1034
|
+
}
|
|
1035
|
+
function numberValue(value, units) {
|
|
1036
|
+
const formatted = new Intl.NumberFormat().format(value);
|
|
1037
|
+
return units == null ? formatted : `${formatted} ${units}`;
|
|
1038
|
+
}
|
|
1039
|
+
function formatFilterValue(_config, operatorValue, filterValue, maxLength, timezoneID) {
|
|
1040
|
+
switch (filterValue.type) {
|
|
1041
|
+
case "empty":
|
|
1042
|
+
return "";
|
|
1043
|
+
case "string":
|
|
1044
|
+
return truncate(filterValue.value, maxLength);
|
|
1045
|
+
case "string_list": {
|
|
1046
|
+
const joined = filterValue.value.join(", ");
|
|
1047
|
+
return joined.length <= maxLength ? joined : `${filterValue.value.length} items`;
|
|
1048
|
+
}
|
|
1049
|
+
case "integer":
|
|
1050
|
+
return numberValue(
|
|
1051
|
+
filterValue.value,
|
|
1052
|
+
operatorValue.type === "integer" ? operatorValue.units : void 0
|
|
1053
|
+
);
|
|
1054
|
+
case "float":
|
|
1055
|
+
return numberValue(
|
|
1056
|
+
filterValue.value,
|
|
1057
|
+
operatorValue.type === "float" ? operatorValue.units : void 0
|
|
1058
|
+
);
|
|
1059
|
+
case "time":
|
|
1060
|
+
return filterValue.value;
|
|
1061
|
+
case "date_absolute":
|
|
1062
|
+
return truncate(
|
|
1063
|
+
new Intl.DateTimeFormat(void 0, {
|
|
1064
|
+
day: "numeric",
|
|
1065
|
+
hour: "numeric",
|
|
1066
|
+
minute: "2-digit",
|
|
1067
|
+
month: "short",
|
|
1068
|
+
timeZone: timezoneID,
|
|
1069
|
+
year: "numeric"
|
|
1070
|
+
}).format(filterValue.unixSeconds * 1e3),
|
|
1071
|
+
maxLength
|
|
1072
|
+
);
|
|
1073
|
+
case "date_relative":
|
|
1074
|
+
return filterValue.value;
|
|
1075
|
+
case "date_range":
|
|
1076
|
+
return "date range";
|
|
1077
|
+
case "enum":
|
|
1078
|
+
return truncate(
|
|
1079
|
+
operatorValue.type === "enum" ? enumLabel(filterValue.value, operatorValue.values) : filterValue.value,
|
|
1080
|
+
maxLength
|
|
1081
|
+
);
|
|
1082
|
+
case "enum_list": {
|
|
1083
|
+
const labels = operatorValue.type === "enum_list" ? filterValue.value.map(
|
|
1084
|
+
(value) => enumLabel(value, operatorValue.values)
|
|
1085
|
+
) : filterValue.value;
|
|
1086
|
+
const joined = labels.join(", ");
|
|
1087
|
+
return joined.length <= maxLength ? joined : `${labels.length} items`;
|
|
1088
|
+
}
|
|
1089
|
+
case "entity_list": {
|
|
1090
|
+
const joined = filterValue.value.map((entity) => entity.label).join(", ");
|
|
1091
|
+
return joined.length <= maxLength ? joined : `${filterValue.value.length} entities`;
|
|
1092
|
+
}
|
|
1093
|
+
case "custom":
|
|
1094
|
+
return truncate(
|
|
1095
|
+
operatorValue.type === "custom" ? operatorValue.getString(filterValue.value) : filterValue.value,
|
|
1096
|
+
maxLength
|
|
1097
|
+
);
|
|
1098
|
+
case "nested":
|
|
1099
|
+
return filterValue.value.length === 1 ? "1 filter" : `${filterValue.value.length} filters`;
|
|
1100
|
+
}
|
|
1101
|
+
}
|
|
1102
|
+
function useInternalSearchFilterInputConfig(config) {
|
|
1103
|
+
return react.useMemo(() => {
|
|
1104
|
+
const fieldMap = /* @__PURE__ */ new Map();
|
|
1105
|
+
const operatorMap = /* @__PURE__ */ new Map();
|
|
1106
|
+
for (const field of config.fields) {
|
|
1107
|
+
fieldMap.set(field.key, field);
|
|
1108
|
+
operatorMap.set(
|
|
1109
|
+
field.key,
|
|
1110
|
+
new Map(field.operators.map((operator) => [operator.key, operator]))
|
|
1111
|
+
);
|
|
1112
|
+
}
|
|
1113
|
+
return {
|
|
1114
|
+
config,
|
|
1115
|
+
getDefaultOperator(fieldKey) {
|
|
1116
|
+
const field = fieldMap.get(fieldKey);
|
|
1117
|
+
if (field == null) {
|
|
1118
|
+
return void 0;
|
|
1119
|
+
}
|
|
1120
|
+
if (field.defaultOperator != null) {
|
|
1121
|
+
return operatorMap.get(fieldKey)?.get(field.defaultOperator);
|
|
1122
|
+
}
|
|
1123
|
+
return field.operators[0];
|
|
1124
|
+
},
|
|
1125
|
+
getField: (key) => fieldMap.get(key),
|
|
1126
|
+
getOperator: (fieldKey, operatorKey) => operatorMap.get(fieldKey)?.get(operatorKey),
|
|
1127
|
+
getVisibleFields: () => config.fields,
|
|
1128
|
+
getVisibleOperators(fieldKey) {
|
|
1129
|
+
return fieldMap.get(fieldKey)?.operators ?? [];
|
|
1130
|
+
}
|
|
1131
|
+
};
|
|
1132
|
+
}, [config]);
|
|
1133
|
+
}
|
|
1134
|
+
function useSearchFilterInputSource(config) {
|
|
1135
|
+
return react.useMemo(() => {
|
|
1136
|
+
const allItems = buildFieldItems(config);
|
|
1137
|
+
return {
|
|
1138
|
+
bootstrap: () => allItems,
|
|
1139
|
+
search(query) {
|
|
1140
|
+
const lower = query.toLowerCase().trim();
|
|
1141
|
+
if (lower === "") {
|
|
1142
|
+
return allItems;
|
|
1143
|
+
}
|
|
1144
|
+
const results = [];
|
|
1145
|
+
const seen = /* @__PURE__ */ new Set();
|
|
1146
|
+
for (const field of config.getVisibleFields()) {
|
|
1147
|
+
if (field.comboboxMinQueryLength != null && lower.length < field.comboboxMinQueryLength) {
|
|
1148
|
+
continue;
|
|
1149
|
+
}
|
|
1150
|
+
const fieldMatches = field.label.toLowerCase().includes(lower) || field.comboboxAliases?.some(
|
|
1151
|
+
(alias) => alias.toLowerCase().includes(lower)
|
|
1152
|
+
) === true;
|
|
1153
|
+
if (fieldMatches) {
|
|
1154
|
+
const defaultOperator = config.getDefaultOperator(field.key);
|
|
1155
|
+
if (!seen.has(field.key)) {
|
|
1156
|
+
seen.add(field.key);
|
|
1157
|
+
results.push({
|
|
1158
|
+
auxiliaryData: {
|
|
1159
|
+
fieldKey: field.key,
|
|
1160
|
+
operatorKey: defaultOperator?.key
|
|
1161
|
+
},
|
|
1162
|
+
id: field.key,
|
|
1163
|
+
label: field.label
|
|
1164
|
+
});
|
|
1165
|
+
}
|
|
1166
|
+
}
|
|
1167
|
+
for (const operator of field.operators) {
|
|
1168
|
+
const combinedLabel = `${field.label} ${operator.label}`.toLowerCase();
|
|
1169
|
+
if (combinedLabel.includes(lower)) {
|
|
1170
|
+
const id = `${field.key}:${operator.key}`;
|
|
1171
|
+
if (!seen.has(id)) {
|
|
1172
|
+
seen.add(id);
|
|
1173
|
+
results.push({
|
|
1174
|
+
auxiliaryData: {
|
|
1175
|
+
fieldKey: field.key,
|
|
1176
|
+
operatorKey: operator.key
|
|
1177
|
+
},
|
|
1178
|
+
id,
|
|
1179
|
+
label: `${field.label} ${operator.label}`
|
|
1180
|
+
});
|
|
1181
|
+
}
|
|
1182
|
+
}
|
|
1183
|
+
}
|
|
1184
|
+
}
|
|
1185
|
+
for (const field of config.getVisibleFields()) {
|
|
1186
|
+
if (field.isValueMatchAllowed === false) {
|
|
1187
|
+
continue;
|
|
1188
|
+
}
|
|
1189
|
+
const fieldLabel = field.label.toLowerCase();
|
|
1190
|
+
let hasExactOperatorMatch = false;
|
|
1191
|
+
for (const operator of field.operators) {
|
|
1192
|
+
const prefix = `${fieldLabel} ${operator.label.toLowerCase()} `;
|
|
1193
|
+
if (lower.startsWith(prefix) && lower.length > prefix.length) {
|
|
1194
|
+
const rawValue = query.slice(prefix.length);
|
|
1195
|
+
const matches = resolveValueMatches(operator, rawValue);
|
|
1196
|
+
if (matches.length > 0) {
|
|
1197
|
+
hasExactOperatorMatch = true;
|
|
1198
|
+
}
|
|
1199
|
+
for (const match of matches) {
|
|
1200
|
+
const id = `${field.key}:${operator.key}:value:${match.displayValue}`;
|
|
1201
|
+
if (!seen.has(id)) {
|
|
1202
|
+
seen.add(id);
|
|
1203
|
+
results.push({
|
|
1204
|
+
auxiliaryData: {
|
|
1205
|
+
fieldKey: field.key,
|
|
1206
|
+
filterValue: match.filterValue,
|
|
1207
|
+
operatorKey: operator.key
|
|
1208
|
+
},
|
|
1209
|
+
id,
|
|
1210
|
+
label: `${field.label} ${operator.label} ${match.quoted ? `"${match.displayValue}"` : match.displayValue}`
|
|
1211
|
+
});
|
|
1212
|
+
}
|
|
1213
|
+
}
|
|
1214
|
+
}
|
|
1215
|
+
}
|
|
1216
|
+
const fieldPrefix = `${fieldLabel} `;
|
|
1217
|
+
if (!hasExactOperatorMatch && lower.startsWith(fieldPrefix) && lower.length > fieldPrefix.length) {
|
|
1218
|
+
const remainder = lower.slice(fieldPrefix.length);
|
|
1219
|
+
const isOperatorPrefix = field.operators.some(
|
|
1220
|
+
(operator) => operator.label.toLowerCase().startsWith(remainder)
|
|
1221
|
+
);
|
|
1222
|
+
if (!isOperatorPrefix) {
|
|
1223
|
+
const rawValue = query.slice(fieldPrefix.length);
|
|
1224
|
+
for (const operator of field.operators) {
|
|
1225
|
+
const matches = resolveValueMatches(operator, rawValue);
|
|
1226
|
+
for (const match of matches) {
|
|
1227
|
+
const id = `${field.key}:${operator.key}:value:${match.displayValue}`;
|
|
1228
|
+
if (!seen.has(id)) {
|
|
1229
|
+
seen.add(id);
|
|
1230
|
+
results.push({
|
|
1231
|
+
auxiliaryData: {
|
|
1232
|
+
fieldKey: field.key,
|
|
1233
|
+
filterValue: match.filterValue,
|
|
1234
|
+
operatorKey: operator.key
|
|
1235
|
+
},
|
|
1236
|
+
id,
|
|
1237
|
+
label: `${field.label} ${operator.label} ${match.quoted ? `"${match.displayValue}"` : match.displayValue}`
|
|
1238
|
+
});
|
|
1239
|
+
}
|
|
1240
|
+
}
|
|
1241
|
+
}
|
|
1242
|
+
}
|
|
1243
|
+
}
|
|
1244
|
+
}
|
|
1245
|
+
const contentFieldKey = config.config.contentSearchFieldKey;
|
|
1246
|
+
const hasExactMatch = config.getVisibleFields().some(
|
|
1247
|
+
(field) => field.label.toLowerCase() === lower || field.operators.some(
|
|
1248
|
+
(operator) => `${field.label} ${operator.label}`.toLowerCase() === lower
|
|
1249
|
+
)
|
|
1250
|
+
);
|
|
1251
|
+
if (contentFieldKey != null && !hasExactMatch) {
|
|
1252
|
+
const contentField = config.getField(contentFieldKey);
|
|
1253
|
+
const contentOperator = config.getDefaultOperator(contentFieldKey);
|
|
1254
|
+
if (contentField != null && contentOperator != null) {
|
|
1255
|
+
results.unshift({
|
|
1256
|
+
auxiliaryData: {
|
|
1257
|
+
fieldKey: contentFieldKey,
|
|
1258
|
+
filterValue: { type: "string", value: query },
|
|
1259
|
+
operatorKey: contentOperator.key
|
|
1260
|
+
},
|
|
1261
|
+
id: `__content_search__:${query}`,
|
|
1262
|
+
label: `"${query}"`
|
|
1263
|
+
});
|
|
1264
|
+
}
|
|
1265
|
+
}
|
|
1266
|
+
return results;
|
|
1267
|
+
}
|
|
1268
|
+
};
|
|
1269
|
+
}, [config]);
|
|
1270
|
+
}
|
|
1271
|
+
function resolveValueMatches(operator, rawValue) {
|
|
1272
|
+
if (operator.value.type === "string") {
|
|
1273
|
+
return [
|
|
1274
|
+
{
|
|
1275
|
+
displayValue: rawValue,
|
|
1276
|
+
filterValue: { type: "string", value: rawValue },
|
|
1277
|
+
quoted: true
|
|
1278
|
+
}
|
|
1279
|
+
];
|
|
1280
|
+
}
|
|
1281
|
+
if (operator.value.type === "string_list") {
|
|
1282
|
+
return [
|
|
1283
|
+
{
|
|
1284
|
+
displayValue: rawValue,
|
|
1285
|
+
filterValue: { type: "string_list", value: [rawValue] },
|
|
1286
|
+
quoted: true
|
|
1287
|
+
}
|
|
1288
|
+
];
|
|
1289
|
+
}
|
|
1290
|
+
if (operator.value.type === "enum") {
|
|
1291
|
+
const lower = rawValue.toLowerCase();
|
|
1292
|
+
return operator.value.values.filter((item) => item.label.toLowerCase().includes(lower)).map((item) => ({
|
|
1293
|
+
displayValue: item.label,
|
|
1294
|
+
filterValue: { type: "enum", value: item.value },
|
|
1295
|
+
quoted: false
|
|
1296
|
+
}));
|
|
1297
|
+
}
|
|
1298
|
+
if (operator.value.type === "enum_list") {
|
|
1299
|
+
const lower = rawValue.toLowerCase();
|
|
1300
|
+
return operator.value.values.filter((item) => item.label.toLowerCase().includes(lower)).map((item) => ({
|
|
1301
|
+
displayValue: item.label,
|
|
1302
|
+
filterValue: { type: "enum_list", value: [item.value] },
|
|
1303
|
+
quoted: false
|
|
1304
|
+
}));
|
|
1305
|
+
}
|
|
1306
|
+
return [];
|
|
1307
|
+
}
|
|
1308
|
+
function buildFieldItems(config) {
|
|
1309
|
+
return config.getVisibleFields().map((field) => {
|
|
1310
|
+
const defaultOperator = config.getDefaultOperator(field.key);
|
|
1311
|
+
return {
|
|
1312
|
+
auxiliaryData: {
|
|
1313
|
+
fieldKey: field.key,
|
|
1314
|
+
operatorKey: defaultOperator?.key
|
|
1315
|
+
},
|
|
1316
|
+
id: field.key,
|
|
1317
|
+
label: field.label
|
|
1318
|
+
};
|
|
1319
|
+
});
|
|
1320
|
+
}
|
|
1321
|
+
var styles2 = {
|
|
1322
|
+
entityPhoto: chunkAZDWQGAX_cjs.css({
|
|
1323
|
+
width: "16px",
|
|
1324
|
+
height: "16px",
|
|
1325
|
+
borderRadius: "full",
|
|
1326
|
+
objectFit: "cover",
|
|
1327
|
+
flexShrink: 0
|
|
1328
|
+
}),
|
|
1329
|
+
root: chunkAZDWQGAX_cjs.css({
|
|
1330
|
+
w: "full"
|
|
1331
|
+
}),
|
|
1332
|
+
popover: chunkAZDWQGAX_cjs.css({
|
|
1333
|
+
minW: "400px"
|
|
1334
|
+
}),
|
|
1335
|
+
resultCount: chunkAZDWQGAX_cjs.css({
|
|
1336
|
+
whiteSpace: "nowrap"
|
|
1337
|
+
}),
|
|
1338
|
+
value: chunkAZDWQGAX_cjs.css({
|
|
1339
|
+
fontWeight: "bold"
|
|
1340
|
+
})
|
|
1341
|
+
};
|
|
1342
|
+
function SearchFilterInput({
|
|
1343
|
+
className,
|
|
1344
|
+
components,
|
|
1345
|
+
config: configFromProps,
|
|
1346
|
+
"data-testid": dataTestId,
|
|
1347
|
+
endContent,
|
|
1348
|
+
filters,
|
|
1349
|
+
handleRef,
|
|
1350
|
+
hasAutoFocus = false,
|
|
1351
|
+
hasClear = true,
|
|
1352
|
+
isDisabled = false,
|
|
1353
|
+
isLabelHidden = true,
|
|
1354
|
+
isReadOnly = false,
|
|
1355
|
+
label = "Search",
|
|
1356
|
+
maxOperatorMenuItems,
|
|
1357
|
+
maxTagLength = 40,
|
|
1358
|
+
onBlur,
|
|
1359
|
+
onChange,
|
|
1360
|
+
onFocus,
|
|
1361
|
+
placeholder = "Search...",
|
|
1362
|
+
popoverSaveButtonLabel = "Apply",
|
|
1363
|
+
ref,
|
|
1364
|
+
resultCount,
|
|
1365
|
+
size = "md",
|
|
1366
|
+
startIcon,
|
|
1367
|
+
status,
|
|
1368
|
+
style,
|
|
1369
|
+
tagOverflowBehavior,
|
|
1370
|
+
timezoneID
|
|
1371
|
+
}) {
|
|
1372
|
+
const config = useInternalSearchFilterInputConfig(configFromProps);
|
|
1373
|
+
const searchSource = useSearchFilterInputSource(config);
|
|
1374
|
+
const tagsInputRef = react.useRef(null);
|
|
1375
|
+
const rootRef = react.useRef(null);
|
|
1376
|
+
const [popoverState, setPopoverState] = react.useState({
|
|
1377
|
+
type: "idle"
|
|
1378
|
+
});
|
|
1379
|
+
react.useImperativeHandle(handleRef, () => ({
|
|
1380
|
+
blurInput: () => tagsInputRef.current?.blur(),
|
|
1381
|
+
focusInput: () => tagsInputRef.current?.focus()
|
|
1382
|
+
}));
|
|
1383
|
+
const tagsInputValue = react.useMemo(
|
|
1384
|
+
() => filters.map((filter, index) => {
|
|
1385
|
+
const field = config.getField(filter.field);
|
|
1386
|
+
const operator = config.getOperator(filter.field, filter.operator);
|
|
1387
|
+
const operatorLabel = operator?.label ? ` ${operator.label}` : "";
|
|
1388
|
+
const value = operator == null ? "" : formatFilterValue(
|
|
1389
|
+
config,
|
|
1390
|
+
operator.value,
|
|
1391
|
+
filter.value,
|
|
1392
|
+
maxTagLength,
|
|
1393
|
+
timezoneID
|
|
1394
|
+
);
|
|
1395
|
+
return {
|
|
1396
|
+
auxiliaryData: {
|
|
1397
|
+
fieldKey: filter.field,
|
|
1398
|
+
filterIndex: index,
|
|
1399
|
+
filterValue: filter.value,
|
|
1400
|
+
operatorKey: filter.operator
|
|
1401
|
+
},
|
|
1402
|
+
id: `filter-${index}-${filter.field}-${filter.operator}`,
|
|
1403
|
+
label: value ? `${field?.label ?? filter.field}${operatorLabel} ${value}` : `${field?.label ?? filter.field}${operatorLabel}`
|
|
1404
|
+
};
|
|
1405
|
+
}),
|
|
1406
|
+
[config, filters, maxTagLength, timezoneID]
|
|
1407
|
+
);
|
|
1408
|
+
const openEditor = react.useCallback(
|
|
1409
|
+
(state) => {
|
|
1410
|
+
tagsInputRef.current?.blur();
|
|
1411
|
+
setPopoverState(state);
|
|
1412
|
+
},
|
|
1413
|
+
[]
|
|
1414
|
+
);
|
|
1415
|
+
const handleTagsInputChange = react.useCallback(
|
|
1416
|
+
(_items, change) => {
|
|
1417
|
+
if (change.type === "remove") {
|
|
1418
|
+
const index = change.item.auxiliaryData?.filterIndex;
|
|
1419
|
+
if (index != null) {
|
|
1420
|
+
onChange(
|
|
1421
|
+
filters.filter((_, i) => i !== index),
|
|
1422
|
+
"remove",
|
|
1423
|
+
index
|
|
1424
|
+
);
|
|
1425
|
+
}
|
|
1426
|
+
return;
|
|
1427
|
+
}
|
|
1428
|
+
if (change.type !== "add") {
|
|
1429
|
+
return;
|
|
1430
|
+
}
|
|
1431
|
+
const auxiliaryData = change.item.auxiliaryData;
|
|
1432
|
+
if (auxiliaryData == null) {
|
|
1433
|
+
return;
|
|
1434
|
+
}
|
|
1435
|
+
const operator = auxiliaryData.operatorKey == null ? config.getDefaultOperator(auxiliaryData.fieldKey) : config.getOperator(
|
|
1436
|
+
auxiliaryData.fieldKey,
|
|
1437
|
+
auxiliaryData.operatorKey
|
|
1438
|
+
);
|
|
1439
|
+
if (operator == null) {
|
|
1440
|
+
return;
|
|
1441
|
+
}
|
|
1442
|
+
if (auxiliaryData.filterValue != null) {
|
|
1443
|
+
const nextFilter = {
|
|
1444
|
+
field: auxiliaryData.fieldKey,
|
|
1445
|
+
operator: operator.key,
|
|
1446
|
+
value: auxiliaryData.filterValue
|
|
1447
|
+
};
|
|
1448
|
+
onChange([...filters, nextFilter], "add", filters.length);
|
|
1449
|
+
return;
|
|
1450
|
+
}
|
|
1451
|
+
if (operator.value.type === "empty") {
|
|
1452
|
+
const nextFilter = {
|
|
1453
|
+
field: auxiliaryData.fieldKey,
|
|
1454
|
+
operator: operator.key,
|
|
1455
|
+
value: { type: "empty" }
|
|
1456
|
+
};
|
|
1457
|
+
onChange([...filters, nextFilter], "add", filters.length);
|
|
1458
|
+
return;
|
|
1459
|
+
}
|
|
1460
|
+
openEditor({
|
|
1461
|
+
partialFilter: {
|
|
1462
|
+
field: auxiliaryData.fieldKey,
|
|
1463
|
+
operator: operator.key,
|
|
1464
|
+
value: void 0
|
|
1465
|
+
},
|
|
1466
|
+
type: "adding"
|
|
1467
|
+
});
|
|
1468
|
+
},
|
|
1469
|
+
[config, filters, onChange, openEditor]
|
|
1470
|
+
);
|
|
1471
|
+
const handleTagClick = (index) => {
|
|
1472
|
+
if (isReadOnly || isDisabled) {
|
|
1473
|
+
return;
|
|
1474
|
+
}
|
|
1475
|
+
const filter = filters[index];
|
|
1476
|
+
if (filter.isReadOnly === true) {
|
|
1477
|
+
return;
|
|
1478
|
+
}
|
|
1479
|
+
openEditor({
|
|
1480
|
+
filterIndex: index,
|
|
1481
|
+
partialFilter: {
|
|
1482
|
+
field: filter.field,
|
|
1483
|
+
operator: filter.operator,
|
|
1484
|
+
value: filter.value
|
|
1485
|
+
},
|
|
1486
|
+
type: "editing"
|
|
1487
|
+
});
|
|
1488
|
+
};
|
|
1489
|
+
const renderTag = (item, onRemove) => {
|
|
1490
|
+
const auxiliaryData = item.auxiliaryData;
|
|
1491
|
+
const filterIndex = auxiliaryData?.filterIndex ?? -1;
|
|
1492
|
+
const filter = filterIndex >= 0 ? filters[filterIndex] : void 0;
|
|
1493
|
+
const field = auxiliaryData == null ? void 0 : config.getField(auxiliaryData.fieldKey);
|
|
1494
|
+
const operator = auxiliaryData?.operatorKey == null ? void 0 : config.getOperator(auxiliaryData.fieldKey, auxiliaryData.operatorKey);
|
|
1495
|
+
const canInteract = !isReadOnly && !isDisabled && filter?.isReadOnly !== true;
|
|
1496
|
+
const TagOverride = operator == null ? void 0 : components?.[operator.value.type]?.Tag;
|
|
1497
|
+
if (TagOverride != null && filter != null && field != null && operator != null) {
|
|
1498
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1499
|
+
TagOverride,
|
|
1500
|
+
{
|
|
1501
|
+
config: configFromProps,
|
|
1502
|
+
field,
|
|
1503
|
+
filter,
|
|
1504
|
+
isDisabled,
|
|
1505
|
+
maxLength: maxTagLength,
|
|
1506
|
+
onClick: canInteract ? () => handleTagClick(filterIndex) : void 0,
|
|
1507
|
+
onRemove: canInteract ? onRemove : void 0,
|
|
1508
|
+
operator
|
|
1509
|
+
}
|
|
1510
|
+
);
|
|
1511
|
+
}
|
|
1512
|
+
const value = operator != null && filter != null ? formatFilterValue(
|
|
1513
|
+
config,
|
|
1514
|
+
operator.value,
|
|
1515
|
+
filter.value,
|
|
1516
|
+
Math.max(
|
|
1517
|
+
maxTagLength - (field?.label.length ?? 0) - operator.label.length,
|
|
1518
|
+
10
|
|
1519
|
+
),
|
|
1520
|
+
timezoneID
|
|
1521
|
+
) : "";
|
|
1522
|
+
const entityPhoto = filter?.value.type === "entity_list" ? (() => {
|
|
1523
|
+
const entities = filter.value.value;
|
|
1524
|
+
return entities.length === 1 && entities[0].photo != null ? entities[0].photo : void 0;
|
|
1525
|
+
})() : void 0;
|
|
1526
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1527
|
+
chunkQRDRZNCS_cjs.Tag,
|
|
1528
|
+
{
|
|
1529
|
+
endContent: value === "" ? void 0 : /* @__PURE__ */ jsxRuntime.jsx("span", { className: styles2.value, children: value }),
|
|
1530
|
+
isDisabled,
|
|
1531
|
+
label: `${field?.label ?? ""} ${operator?.label ?? ""}`.trim(),
|
|
1532
|
+
onClick: canInteract ? (event) => {
|
|
1533
|
+
event.stopPropagation();
|
|
1534
|
+
handleTagClick(filterIndex);
|
|
1535
|
+
} : void 0,
|
|
1536
|
+
onRemove: canInteract ? onRemove : void 0,
|
|
1537
|
+
size,
|
|
1538
|
+
startContent: entityPhoto != null ? /* @__PURE__ */ jsxRuntime.jsx("img", { alt: "", className: styles2.entityPhoto, src: entityPhoto }) : void 0
|
|
1539
|
+
}
|
|
1540
|
+
);
|
|
1541
|
+
};
|
|
1542
|
+
const renderItem = (item) => {
|
|
1543
|
+
const field = item.auxiliaryData == null ? void 0 : config.getField(item.auxiliaryData.fieldKey);
|
|
1544
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1545
|
+
chunkPDXZDPOY_cjs.AutocompleteInputItem,
|
|
1546
|
+
{
|
|
1547
|
+
description: field?.description,
|
|
1548
|
+
icon: field?.icon ?? lucideReact.Search,
|
|
1549
|
+
item
|
|
1550
|
+
}
|
|
1551
|
+
);
|
|
1552
|
+
};
|
|
1553
|
+
const handleSave = (savedFilter) => {
|
|
1554
|
+
if (popoverState.type === "adding") {
|
|
1555
|
+
if (savedFilter != null) {
|
|
1556
|
+
onChange([...filters, savedFilter], "add", filters.length);
|
|
1557
|
+
}
|
|
1558
|
+
} else if (popoverState.type === "editing") {
|
|
1559
|
+
if (savedFilter == null) {
|
|
1560
|
+
onChange(
|
|
1561
|
+
filters.filter((_, index) => index !== popoverState.filterIndex),
|
|
1562
|
+
"remove",
|
|
1563
|
+
popoverState.filterIndex
|
|
1564
|
+
);
|
|
1565
|
+
} else {
|
|
1566
|
+
const nextFilters = [...filters];
|
|
1567
|
+
nextFilters[popoverState.filterIndex] = savedFilter;
|
|
1568
|
+
onChange(nextFilters, "edit", popoverState.filterIndex);
|
|
1569
|
+
}
|
|
1570
|
+
}
|
|
1571
|
+
setPopoverState({ type: "idle" });
|
|
1572
|
+
requestAnimationFrame(() => tagsInputRef.current?.focus());
|
|
1573
|
+
};
|
|
1574
|
+
const partialFilter = popoverState.type === "idle" ? null : popoverState.partialFilter;
|
|
1575
|
+
const EditorOverride = partialFilter?.operator == null ? void 0 : components?.[config.getOperator(partialFilter.field, partialFilter.operator)?.value.type ?? "empty"]?.Editor;
|
|
1576
|
+
const editorContent = partialFilter == null ? null : EditorOverride != null ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
1577
|
+
EditorOverride,
|
|
1578
|
+
{
|
|
1579
|
+
config: configFromProps,
|
|
1580
|
+
filter: partialFilter,
|
|
1581
|
+
isReadOnly,
|
|
1582
|
+
mode: popoverState.type === "editing" ? "edit" : "create",
|
|
1583
|
+
onCancel: () => setPopoverState({ type: "idle" }),
|
|
1584
|
+
onSave: handleSave,
|
|
1585
|
+
saveButtonLabel: popoverSaveButtonLabel,
|
|
1586
|
+
timezoneID
|
|
1587
|
+
}
|
|
1588
|
+
) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
1589
|
+
SearchFilterInputEditPopover,
|
|
1590
|
+
{
|
|
1591
|
+
config,
|
|
1592
|
+
filter: partialFilter,
|
|
1593
|
+
isReadOnly,
|
|
1594
|
+
maxOperatorMenuItems,
|
|
1595
|
+
mode: popoverState.type === "editing" ? "edit" : "create",
|
|
1596
|
+
onCancel: () => setPopoverState({ type: "idle" }),
|
|
1597
|
+
onSave: handleSave,
|
|
1598
|
+
saveButtonLabel: popoverSaveButtonLabel
|
|
1599
|
+
}
|
|
1600
|
+
);
|
|
1601
|
+
const resultCountNode = resultCount == null ? null : /* @__PURE__ */ jsxRuntime.jsx(
|
|
1602
|
+
chunk47BELFYO_cjs.Text,
|
|
1603
|
+
{
|
|
1604
|
+
as: "span",
|
|
1605
|
+
className: styles2.resultCount,
|
|
1606
|
+
color: "secondary",
|
|
1607
|
+
type: "supporting",
|
|
1608
|
+
children: typeof resultCount === "number" ? `${new Intl.NumberFormat().format(resultCount)} ${resultCount === 1 ? "result" : "results"}` : resultCount
|
|
1609
|
+
}
|
|
1610
|
+
);
|
|
1611
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
1612
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: styles2.root, ref: rootRef, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1613
|
+
chunkWE3ECIRS_cjs.TagsInput,
|
|
1614
|
+
{
|
|
1615
|
+
className,
|
|
1616
|
+
"data-testid": dataTestId,
|
|
1617
|
+
debounceMs: 0,
|
|
1618
|
+
endContent: /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
1619
|
+
resultCountNode,
|
|
1620
|
+
endContent
|
|
1621
|
+
] }),
|
|
1622
|
+
handleRef: tagsInputRef,
|
|
1623
|
+
hasAutoFocus,
|
|
1624
|
+
hasClear: hasClear && !isReadOnly,
|
|
1625
|
+
hasEntriesOnFocus: true,
|
|
1626
|
+
isDisabled,
|
|
1627
|
+
isLabelHidden,
|
|
1628
|
+
isReadOnly,
|
|
1629
|
+
label,
|
|
1630
|
+
onBlur,
|
|
1631
|
+
onChange: handleTagsInputChange,
|
|
1632
|
+
onFocus,
|
|
1633
|
+
placeholder: isReadOnly ? "" : filters.length === 0 ? placeholder : "",
|
|
1634
|
+
ref,
|
|
1635
|
+
renderItem,
|
|
1636
|
+
renderTag,
|
|
1637
|
+
searchSource,
|
|
1638
|
+
size,
|
|
1639
|
+
startIcon,
|
|
1640
|
+
status,
|
|
1641
|
+
style,
|
|
1642
|
+
tagOverflowBehavior,
|
|
1643
|
+
value: tagsInputValue
|
|
1644
|
+
}
|
|
1645
|
+
) }),
|
|
1646
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1647
|
+
chunkWSAZHUB3_cjs.Popover,
|
|
1648
|
+
{
|
|
1649
|
+
anchorRef: rootRef,
|
|
1650
|
+
className: styles2.popover,
|
|
1651
|
+
content: editorContent,
|
|
1652
|
+
hasAutoFocus: false,
|
|
1653
|
+
hasCloseButton: false,
|
|
1654
|
+
hasLightDismiss: false,
|
|
1655
|
+
isOpen: popoverState.type !== "idle",
|
|
1656
|
+
onOpenChange: (isOpen) => {
|
|
1657
|
+
if (!isOpen) {
|
|
1658
|
+
setPopoverState({ type: "idle" });
|
|
1659
|
+
}
|
|
1660
|
+
}
|
|
1661
|
+
}
|
|
1662
|
+
)
|
|
1663
|
+
] });
|
|
1664
|
+
}
|
|
1665
|
+
SearchFilterInput.displayName = "SearchFilterInput";
|
|
1666
|
+
function SearchFilterInputFilterEditor({
|
|
1667
|
+
config,
|
|
1668
|
+
filter,
|
|
1669
|
+
isReadOnly,
|
|
1670
|
+
mode,
|
|
1671
|
+
onCancel,
|
|
1672
|
+
onSave,
|
|
1673
|
+
saveButtonLabel
|
|
1674
|
+
}) {
|
|
1675
|
+
const internalConfig = useInternalSearchFilterInputConfig(config);
|
|
1676
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1677
|
+
SearchFilterInputEditPopover,
|
|
1678
|
+
{
|
|
1679
|
+
config: internalConfig,
|
|
1680
|
+
filter,
|
|
1681
|
+
isReadOnly,
|
|
1682
|
+
mode,
|
|
1683
|
+
onCancel,
|
|
1684
|
+
onSave,
|
|
1685
|
+
saveButtonLabel
|
|
1686
|
+
}
|
|
1687
|
+
);
|
|
1688
|
+
}
|
|
1689
|
+
SearchFilterInputFilterEditor.displayName = "SearchFilterInputFilterEditor";
|
|
1690
|
+
var styles3 = {
|
|
1691
|
+
value: chunkAZDWQGAX_cjs.css({
|
|
1692
|
+
fontWeight: "bold"
|
|
1693
|
+
}),
|
|
1694
|
+
entityPhoto: chunkAZDWQGAX_cjs.css({
|
|
1695
|
+
width: "16px",
|
|
1696
|
+
height: "16px",
|
|
1697
|
+
borderRadius: "full",
|
|
1698
|
+
objectFit: "cover",
|
|
1699
|
+
flexShrink: 0
|
|
1700
|
+
})
|
|
1701
|
+
};
|
|
1702
|
+
function getSingleEntityPhoto(value) {
|
|
1703
|
+
if (value.type !== "entity_list") {
|
|
1704
|
+
return void 0;
|
|
1705
|
+
}
|
|
1706
|
+
const entities = value.value;
|
|
1707
|
+
if (entities.length === 1 && entities[0].photo != null) {
|
|
1708
|
+
return entities[0].photo;
|
|
1709
|
+
}
|
|
1710
|
+
return void 0;
|
|
1711
|
+
}
|
|
1712
|
+
function SearchFilterInputTag({
|
|
1713
|
+
config: configFromProps,
|
|
1714
|
+
field,
|
|
1715
|
+
filter,
|
|
1716
|
+
isDisabled,
|
|
1717
|
+
maxLength,
|
|
1718
|
+
onClick,
|
|
1719
|
+
onRemove,
|
|
1720
|
+
operator
|
|
1721
|
+
}) {
|
|
1722
|
+
const config = useInternalSearchFilterInputConfig(configFromProps);
|
|
1723
|
+
const tagLabel = `${field.label}${operator.label ? ` ${operator.label}` : ""}`;
|
|
1724
|
+
const adjustedMaxLength = Math.max(
|
|
1725
|
+
maxLength - field.label.length - operator.label.length,
|
|
1726
|
+
10
|
|
1727
|
+
);
|
|
1728
|
+
const value = formatFilterValue(
|
|
1729
|
+
config,
|
|
1730
|
+
operator.value,
|
|
1731
|
+
filter.value,
|
|
1732
|
+
adjustedMaxLength
|
|
1733
|
+
);
|
|
1734
|
+
const entityPhoto = getSingleEntityPhoto(filter.value);
|
|
1735
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1736
|
+
chunkQRDRZNCS_cjs.Tag,
|
|
1737
|
+
{
|
|
1738
|
+
endContent: value === "" ? void 0 : /* @__PURE__ */ jsxRuntime.jsx("span", { className: styles3.value, children: value }),
|
|
1739
|
+
isDisabled,
|
|
1740
|
+
label: tagLabel,
|
|
1741
|
+
onClick: onClick == null ? void 0 : (event) => {
|
|
1742
|
+
event.stopPropagation();
|
|
1743
|
+
onClick();
|
|
1744
|
+
},
|
|
1745
|
+
onRemove,
|
|
1746
|
+
startContent: entityPhoto != null ? /* @__PURE__ */ jsxRuntime.jsx("img", { alt: "", className: styles3.entityPhoto, src: entityPhoto }) : void 0
|
|
1747
|
+
}
|
|
1748
|
+
);
|
|
1749
|
+
}
|
|
1750
|
+
SearchFilterInputTag.displayName = "SearchFilterInputTag";
|
|
1751
|
+
var StringOps = {
|
|
1752
|
+
CONTAINS: "contains",
|
|
1753
|
+
ENDS_WITH: "ends_with",
|
|
1754
|
+
IS: "is",
|
|
1755
|
+
IS_NOT: "is_not",
|
|
1756
|
+
NOT_CONTAINS: "not_contains",
|
|
1757
|
+
NOT_ENDS_WITH: "not_ends_with",
|
|
1758
|
+
NOT_STARTS_WITH: "not_starts_with",
|
|
1759
|
+
STARTS_WITH: "starts_with"
|
|
1760
|
+
};
|
|
1761
|
+
var NumberOps = {
|
|
1762
|
+
EQUALS: "equals",
|
|
1763
|
+
GREATER_THAN: "greater_than",
|
|
1764
|
+
GREATER_THAN_OR_EQUAL: "greater_than_or_equal",
|
|
1765
|
+
LESS_THAN: "less_than",
|
|
1766
|
+
LESS_THAN_OR_EQUAL: "less_than_or_equal",
|
|
1767
|
+
NOT_EQUALS: "not_equals"
|
|
1768
|
+
};
|
|
1769
|
+
var DateOps = {
|
|
1770
|
+
AFTER: "after",
|
|
1771
|
+
BEFORE: "before",
|
|
1772
|
+
BETWEEN: "between"
|
|
1773
|
+
};
|
|
1774
|
+
var BooleanOps = {
|
|
1775
|
+
IS_FALSE: "is_false",
|
|
1776
|
+
IS_TRUE: "is_true"
|
|
1777
|
+
};
|
|
1778
|
+
var EnumOps = {
|
|
1779
|
+
IS: "is",
|
|
1780
|
+
IS_NOT: "is_not"
|
|
1781
|
+
};
|
|
1782
|
+
var ListOps = {
|
|
1783
|
+
IS_ANY_OF: "is_any_of",
|
|
1784
|
+
IS_NONE_OF: "is_none_of"
|
|
1785
|
+
};
|
|
1786
|
+
function stringOperators() {
|
|
1787
|
+
return {
|
|
1788
|
+
defaultOperator: StringOps.CONTAINS,
|
|
1789
|
+
operators: [
|
|
1790
|
+
{ key: StringOps.CONTAINS, label: "contains", value: { type: "string" } },
|
|
1791
|
+
{
|
|
1792
|
+
key: StringOps.NOT_CONTAINS,
|
|
1793
|
+
label: "does not contain",
|
|
1794
|
+
value: { type: "string" }
|
|
1795
|
+
},
|
|
1796
|
+
{
|
|
1797
|
+
key: StringOps.STARTS_WITH,
|
|
1798
|
+
label: "starts with",
|
|
1799
|
+
value: { type: "string" }
|
|
1800
|
+
},
|
|
1801
|
+
{
|
|
1802
|
+
key: StringOps.NOT_STARTS_WITH,
|
|
1803
|
+
label: "does not start with",
|
|
1804
|
+
value: { type: "string" }
|
|
1805
|
+
},
|
|
1806
|
+
{ key: StringOps.ENDS_WITH, label: "ends with", value: { type: "string" } },
|
|
1807
|
+
{
|
|
1808
|
+
key: StringOps.NOT_ENDS_WITH,
|
|
1809
|
+
label: "does not end with",
|
|
1810
|
+
value: { type: "string" }
|
|
1811
|
+
},
|
|
1812
|
+
{ key: StringOps.IS, label: "is", value: { type: "string" } },
|
|
1813
|
+
{ key: StringOps.IS_NOT, label: "is not", value: { type: "string" } }
|
|
1814
|
+
]
|
|
1815
|
+
};
|
|
1816
|
+
}
|
|
1817
|
+
function numberOperators() {
|
|
1818
|
+
return {
|
|
1819
|
+
defaultOperator: NumberOps.EQUALS,
|
|
1820
|
+
operators: [
|
|
1821
|
+
{ key: NumberOps.EQUALS, label: "is", value: { type: "float" } },
|
|
1822
|
+
{ key: NumberOps.NOT_EQUALS, label: "is not", value: { type: "float" } },
|
|
1823
|
+
{
|
|
1824
|
+
key: NumberOps.GREATER_THAN,
|
|
1825
|
+
label: "is greater than",
|
|
1826
|
+
value: { type: "float" }
|
|
1827
|
+
},
|
|
1828
|
+
{
|
|
1829
|
+
key: NumberOps.LESS_THAN,
|
|
1830
|
+
label: "is less than",
|
|
1831
|
+
value: { type: "float" }
|
|
1832
|
+
},
|
|
1833
|
+
{
|
|
1834
|
+
key: NumberOps.GREATER_THAN_OR_EQUAL,
|
|
1835
|
+
label: "is greater than or equal to",
|
|
1836
|
+
value: { type: "float" }
|
|
1837
|
+
},
|
|
1838
|
+
{
|
|
1839
|
+
key: NumberOps.LESS_THAN_OR_EQUAL,
|
|
1840
|
+
label: "is less than or equal to",
|
|
1841
|
+
value: { type: "float" }
|
|
1842
|
+
}
|
|
1843
|
+
]
|
|
1844
|
+
};
|
|
1845
|
+
}
|
|
1846
|
+
function operatorsFor(definition) {
|
|
1847
|
+
switch (definition.type) {
|
|
1848
|
+
case "string":
|
|
1849
|
+
return stringOperators();
|
|
1850
|
+
case "number":
|
|
1851
|
+
return numberOperators();
|
|
1852
|
+
case "date":
|
|
1853
|
+
return {
|
|
1854
|
+
defaultOperator: DateOps.AFTER,
|
|
1855
|
+
operators: [
|
|
1856
|
+
{
|
|
1857
|
+
key: DateOps.BEFORE,
|
|
1858
|
+
label: "is before",
|
|
1859
|
+
value: { type: "date_absolute" }
|
|
1860
|
+
},
|
|
1861
|
+
{
|
|
1862
|
+
key: DateOps.AFTER,
|
|
1863
|
+
label: "is after",
|
|
1864
|
+
value: { type: "date_absolute" }
|
|
1865
|
+
},
|
|
1866
|
+
{
|
|
1867
|
+
key: DateOps.BETWEEN,
|
|
1868
|
+
label: "is between",
|
|
1869
|
+
value: { type: "date_range" }
|
|
1870
|
+
}
|
|
1871
|
+
]
|
|
1872
|
+
};
|
|
1873
|
+
case "boolean":
|
|
1874
|
+
return {
|
|
1875
|
+
defaultOperator: BooleanOps.IS_TRUE,
|
|
1876
|
+
operators: [
|
|
1877
|
+
{ key: BooleanOps.IS_TRUE, label: "is true", value: { type: "empty" } },
|
|
1878
|
+
{ key: BooleanOps.IS_FALSE, label: "is false", value: { type: "empty" } }
|
|
1879
|
+
]
|
|
1880
|
+
};
|
|
1881
|
+
case "enum":
|
|
1882
|
+
return {
|
|
1883
|
+
defaultOperator: EnumOps.IS,
|
|
1884
|
+
operators: [
|
|
1885
|
+
{
|
|
1886
|
+
key: EnumOps.IS,
|
|
1887
|
+
label: "is",
|
|
1888
|
+
value: { type: "enum", values: definition.enumValues ?? [] }
|
|
1889
|
+
},
|
|
1890
|
+
{
|
|
1891
|
+
key: EnumOps.IS_NOT,
|
|
1892
|
+
label: "is not",
|
|
1893
|
+
value: { type: "enum", values: definition.enumValues ?? [] }
|
|
1894
|
+
},
|
|
1895
|
+
{
|
|
1896
|
+
key: ListOps.IS_ANY_OF,
|
|
1897
|
+
label: "is any of",
|
|
1898
|
+
value: { type: "enum_list", values: definition.enumValues ?? [] }
|
|
1899
|
+
},
|
|
1900
|
+
{
|
|
1901
|
+
key: ListOps.IS_NONE_OF,
|
|
1902
|
+
label: "is none of",
|
|
1903
|
+
value: { type: "enum_list", values: definition.enumValues ?? [] }
|
|
1904
|
+
}
|
|
1905
|
+
]
|
|
1906
|
+
};
|
|
1907
|
+
case "enum_list":
|
|
1908
|
+
return {
|
|
1909
|
+
defaultOperator: ListOps.IS_ANY_OF,
|
|
1910
|
+
operators: [
|
|
1911
|
+
{
|
|
1912
|
+
key: ListOps.IS_ANY_OF,
|
|
1913
|
+
label: "is any of",
|
|
1914
|
+
value: { type: "enum_list", values: definition.enumValues ?? [] }
|
|
1915
|
+
},
|
|
1916
|
+
{
|
|
1917
|
+
key: ListOps.IS_NONE_OF,
|
|
1918
|
+
label: "is none of",
|
|
1919
|
+
value: { type: "enum_list", values: definition.enumValues ?? [] }
|
|
1920
|
+
}
|
|
1921
|
+
]
|
|
1922
|
+
};
|
|
1923
|
+
case "string_list":
|
|
1924
|
+
return {
|
|
1925
|
+
defaultOperator: ListOps.IS_ANY_OF,
|
|
1926
|
+
operators: [
|
|
1927
|
+
{
|
|
1928
|
+
key: ListOps.IS_ANY_OF,
|
|
1929
|
+
label: "is any of",
|
|
1930
|
+
value: { type: "string_list" }
|
|
1931
|
+
},
|
|
1932
|
+
{
|
|
1933
|
+
key: ListOps.IS_NONE_OF,
|
|
1934
|
+
label: "is none of",
|
|
1935
|
+
value: { type: "string_list" }
|
|
1936
|
+
}
|
|
1937
|
+
]
|
|
1938
|
+
};
|
|
1939
|
+
}
|
|
1940
|
+
}
|
|
1941
|
+
function nowUnixSeconds() {
|
|
1942
|
+
return Math.floor(chunkR37R7DEV_cjs.nowEpochMilliseconds() / 1e3);
|
|
1943
|
+
}
|
|
1944
|
+
function toUnixSeconds(value) {
|
|
1945
|
+
return value instanceof polyfill.Temporal.Instant ? Math.floor(value.epochMilliseconds / 1e3) : value;
|
|
1946
|
+
}
|
|
1947
|
+
function toStringArray(value) {
|
|
1948
|
+
if (typeof value === "string") {
|
|
1949
|
+
return [value];
|
|
1950
|
+
}
|
|
1951
|
+
if (Array.isArray(value) && value.every((item) => typeof item === "string")) {
|
|
1952
|
+
return value;
|
|
1953
|
+
}
|
|
1954
|
+
return null;
|
|
1955
|
+
}
|
|
1956
|
+
function resolveRangePart(part) {
|
|
1957
|
+
switch (part.type) {
|
|
1958
|
+
case "NOW":
|
|
1959
|
+
return nowUnixSeconds();
|
|
1960
|
+
case "ABSOLUTE":
|
|
1961
|
+
return part.unixSeconds;
|
|
1962
|
+
case "RELATIVE": {
|
|
1963
|
+
const multipliers = {
|
|
1964
|
+
day: 86400,
|
|
1965
|
+
hour: 3600,
|
|
1966
|
+
minute: 60,
|
|
1967
|
+
month: 2592e3,
|
|
1968
|
+
second: 1,
|
|
1969
|
+
week: 604800,
|
|
1970
|
+
year: 31536e3
|
|
1971
|
+
};
|
|
1972
|
+
return nowUnixSeconds() - part.backValue * multipliers[part.unit];
|
|
1973
|
+
}
|
|
1974
|
+
}
|
|
1975
|
+
}
|
|
1976
|
+
function matchesFilter(row, filter) {
|
|
1977
|
+
const fieldValue = row[filter.field];
|
|
1978
|
+
const { operator, value } = filter;
|
|
1979
|
+
switch (value.type) {
|
|
1980
|
+
case "empty":
|
|
1981
|
+
return operator === BooleanOps.IS_TRUE ? Boolean(fieldValue) === true : operator === BooleanOps.IS_FALSE ? Boolean(fieldValue) === false : true;
|
|
1982
|
+
case "string": {
|
|
1983
|
+
if (typeof fieldValue !== "string") {
|
|
1984
|
+
return false;
|
|
1985
|
+
}
|
|
1986
|
+
const source = fieldValue.toLowerCase();
|
|
1987
|
+
const target = value.value.toLowerCase();
|
|
1988
|
+
switch (operator) {
|
|
1989
|
+
case StringOps.CONTAINS:
|
|
1990
|
+
return source.includes(target);
|
|
1991
|
+
case StringOps.NOT_CONTAINS:
|
|
1992
|
+
return !source.includes(target);
|
|
1993
|
+
case StringOps.STARTS_WITH:
|
|
1994
|
+
return source.startsWith(target);
|
|
1995
|
+
case StringOps.NOT_STARTS_WITH:
|
|
1996
|
+
return !source.startsWith(target);
|
|
1997
|
+
case StringOps.ENDS_WITH:
|
|
1998
|
+
return source.endsWith(target);
|
|
1999
|
+
case StringOps.NOT_ENDS_WITH:
|
|
2000
|
+
return !source.endsWith(target);
|
|
2001
|
+
case StringOps.IS:
|
|
2002
|
+
return source === target;
|
|
2003
|
+
case StringOps.IS_NOT:
|
|
2004
|
+
return source !== target;
|
|
2005
|
+
default:
|
|
2006
|
+
return true;
|
|
2007
|
+
}
|
|
2008
|
+
}
|
|
2009
|
+
case "float":
|
|
2010
|
+
case "integer": {
|
|
2011
|
+
if (typeof fieldValue !== "number") {
|
|
2012
|
+
return false;
|
|
2013
|
+
}
|
|
2014
|
+
switch (operator) {
|
|
2015
|
+
case NumberOps.EQUALS:
|
|
2016
|
+
return fieldValue === value.value;
|
|
2017
|
+
case NumberOps.NOT_EQUALS:
|
|
2018
|
+
return fieldValue !== value.value;
|
|
2019
|
+
case NumberOps.GREATER_THAN:
|
|
2020
|
+
return fieldValue > value.value;
|
|
2021
|
+
case NumberOps.LESS_THAN:
|
|
2022
|
+
return fieldValue < value.value;
|
|
2023
|
+
case NumberOps.GREATER_THAN_OR_EQUAL:
|
|
2024
|
+
return fieldValue >= value.value;
|
|
2025
|
+
case NumberOps.LESS_THAN_OR_EQUAL:
|
|
2026
|
+
return fieldValue <= value.value;
|
|
2027
|
+
default:
|
|
2028
|
+
return true;
|
|
2029
|
+
}
|
|
2030
|
+
}
|
|
2031
|
+
case "date_absolute": {
|
|
2032
|
+
if (!(fieldValue instanceof polyfill.Temporal.Instant) && typeof fieldValue !== "number") {
|
|
2033
|
+
return false;
|
|
2034
|
+
}
|
|
2035
|
+
const unixSeconds = toUnixSeconds(fieldValue);
|
|
2036
|
+
return operator === DateOps.BEFORE ? unixSeconds < value.unixSeconds : operator === DateOps.AFTER ? unixSeconds > value.unixSeconds : true;
|
|
2037
|
+
}
|
|
2038
|
+
case "date_range": {
|
|
2039
|
+
if (!(fieldValue instanceof polyfill.Temporal.Instant) && typeof fieldValue !== "number") {
|
|
2040
|
+
return false;
|
|
2041
|
+
}
|
|
2042
|
+
const unixSeconds = toUnixSeconds(fieldValue);
|
|
2043
|
+
return unixSeconds >= resolveRangePart(value.value.start) && unixSeconds <= resolveRangePart(value.value.end);
|
|
2044
|
+
}
|
|
2045
|
+
case "enum":
|
|
2046
|
+
return typeof fieldValue === "string" ? operator === EnumOps.IS ? fieldValue === value.value : operator === EnumOps.IS_NOT ? fieldValue !== value.value : true : false;
|
|
2047
|
+
case "enum_list":
|
|
2048
|
+
case "string_list": {
|
|
2049
|
+
const values = toStringArray(fieldValue);
|
|
2050
|
+
if (values == null) {
|
|
2051
|
+
return false;
|
|
2052
|
+
}
|
|
2053
|
+
return operator === ListOps.IS_ANY_OF ? values.some((item) => value.value.includes(item)) : operator === ListOps.IS_NONE_OF ? values.every((item) => !value.value.includes(item)) : true;
|
|
2054
|
+
}
|
|
2055
|
+
case "custom":
|
|
2056
|
+
case "date_relative":
|
|
2057
|
+
case "entity_list":
|
|
2058
|
+
case "nested":
|
|
2059
|
+
case "time":
|
|
2060
|
+
return true;
|
|
2061
|
+
}
|
|
2062
|
+
}
|
|
2063
|
+
function createSearchFilterInputConfig(definitions, configName) {
|
|
2064
|
+
const config = {
|
|
2065
|
+
fields: definitions.map((definition) => ({
|
|
2066
|
+
key: definition.key,
|
|
2067
|
+
label: definition.label ?? definition.key,
|
|
2068
|
+
...operatorsFor(definition)
|
|
2069
|
+
})),
|
|
2070
|
+
name: configName ?? "SearchFilterInputConfig"
|
|
2071
|
+
};
|
|
2072
|
+
return {
|
|
2073
|
+
applyFilters(filters, data) {
|
|
2074
|
+
return filters.length === 0 ? [...data] : data.filter(
|
|
2075
|
+
(row) => filters.every(
|
|
2076
|
+
(filter) => matchesFilter(row, filter)
|
|
2077
|
+
)
|
|
2078
|
+
);
|
|
2079
|
+
},
|
|
2080
|
+
config
|
|
2081
|
+
};
|
|
2082
|
+
}
|
|
2083
|
+
function useSearchFilterInputConfig(definitions, configName) {
|
|
2084
|
+
return react.useMemo(
|
|
2085
|
+
() => createSearchFilterInputConfig(definitions, configName),
|
|
2086
|
+
[configName, definitions]
|
|
2087
|
+
);
|
|
2088
|
+
}
|
|
2089
|
+
|
|
2090
|
+
exports.SearchFilterInput = SearchFilterInput;
|
|
2091
|
+
exports.SearchFilterInputEditPopover = SearchFilterInputEditPopover;
|
|
2092
|
+
exports.SearchFilterInputFilterEditor = SearchFilterInputFilterEditor;
|
|
2093
|
+
exports.SearchFilterInputTag = SearchFilterInputTag;
|
|
2094
|
+
exports.createSearchFilterInputConfig = createSearchFilterInputConfig;
|
|
2095
|
+
exports.formatFilterValue = formatFilterValue;
|
|
2096
|
+
exports.useSearchFilterInputConfig = useSearchFilterInputConfig;
|
|
2097
|
+
exports.useSearchFilterInputSource = useSearchFilterInputSource;
|
|
2098
|
+
//# sourceMappingURL=chunk-SMF3YBH5.cjs.map
|
|
2099
|
+
//# sourceMappingURL=chunk-SMF3YBH5.cjs.map
|