@mieweb/ui 0.8.0 → 0.9.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/README.md +162 -739
- package/agent/mieweb-ui.instructions.md +34 -16
- package/dist/Animated-Cs-naa2g.d.cts +175 -0
- package/dist/Animated-Cs-naa2g.d.ts +175 -0
- package/dist/CsvBlock-D7Z6ZCRP.js +6 -0
- package/dist/{CsvBlock-PUSTBQ5B.js.map → CsvBlock-D7Z6ZCRP.js.map} +1 -1
- package/dist/CsvBlock-QXXZ7ZUM.cjs +15 -0
- package/dist/{CsvBlock-OTFG3PYZ.cjs.map → CsvBlock-QXXZ7ZUM.cjs.map} +1 -1
- package/dist/HtmlPreviewBlock-AADG7MVB.cjs +15 -0
- package/dist/{HtmlPreviewBlock-QHLSIMWJ.cjs.map → HtmlPreviewBlock-AADG7MVB.cjs.map} +1 -1
- package/dist/HtmlPreviewBlock-F5VDM2EN.js +6 -0
- package/dist/{HtmlPreviewBlock-YF2YVKKX.js.map → HtmlPreviewBlock-F5VDM2EN.js.map} +1 -1
- package/dist/MermaidBlock-6PLITRBZ.js +6 -0
- package/dist/{MermaidBlock-H3TWNC4D.js.map → MermaidBlock-6PLITRBZ.js.map} +1 -1
- package/dist/MermaidBlock-TQ2O5CLV.cjs +15 -0
- package/dist/{MermaidBlock-ZLLBO3VY.cjs.map → MermaidBlock-TQ2O5CLV.cjs.map} +1 -1
- package/dist/SurveyBlock-OYL3VNU5.cjs +15 -0
- package/dist/{SurveyBlock-M2ZRTGVJ.cjs.map → SurveyBlock-OYL3VNU5.cjs.map} +1 -1
- package/dist/SurveyBlock-W5PSQ62F.js +6 -0
- package/dist/{SurveyBlock-JLHS3YQD.js.map → SurveyBlock-W5PSQ62F.js.map} +1 -1
- package/dist/ag-grid.cjs +5 -5
- package/dist/ag-grid.js +1 -1
- package/dist/brands/index.cjs +7 -7
- package/dist/brands/index.js +2 -2
- package/dist/{chunk-RZJXCI53.js → chunk-22CYDCXA.js} +3 -3
- package/dist/{chunk-RZJXCI53.js.map → chunk-22CYDCXA.js.map} +1 -1
- package/dist/{chunk-OTQ72WX3.js → chunk-2BPIVWAK.js} +3 -3
- package/dist/{chunk-OTQ72WX3.js.map → chunk-2BPIVWAK.js.map} +1 -1
- package/dist/{chunk-6EWJGRC3.js → chunk-3JWAABYI.js} +6 -6
- package/dist/chunk-3JWAABYI.js.map +1 -0
- package/dist/{chunk-5JZIDILK.cjs → chunk-3LHICE4I.cjs} +6 -6
- package/dist/chunk-3LHICE4I.cjs.map +1 -0
- package/dist/{chunk-JHZW3Y62.js → chunk-3RB35GYK.js} +5 -5
- package/dist/chunk-3RB35GYK.js.map +1 -0
- package/dist/{chunk-BOW7ZGI2.cjs → chunk-4SM3I7WE.cjs} +170 -10
- package/dist/chunk-4SM3I7WE.cjs.map +1 -0
- package/dist/{chunk-26DPQUSB.cjs → chunk-5BVFVXHN.cjs} +224 -157
- package/dist/chunk-5BVFVXHN.cjs.map +1 -0
- package/dist/{chunk-QHTDWIED.js → chunk-5H7SAEQO.js} +5 -5
- package/dist/{chunk-QHTDWIED.js.map → chunk-5H7SAEQO.js.map} +1 -1
- package/dist/{chunk-EMMYFHOT.js → chunk-5WOB4UBD.js} +3 -3
- package/dist/{chunk-EMMYFHOT.js.map → chunk-5WOB4UBD.js.map} +1 -1
- package/dist/{chunk-4CUFXCC5.cjs → chunk-5Z6UPVGC.cjs} +6 -6
- package/dist/{chunk-4CUFXCC5.cjs.map → chunk-5Z6UPVGC.cjs.map} +1 -1
- package/dist/{chunk-YIXTGWT4.cjs → chunk-6QKMMKRY.cjs} +5 -5
- package/dist/{chunk-YIXTGWT4.cjs.map → chunk-6QKMMKRY.cjs.map} +1 -1
- package/dist/{chunk-F57VRLKP.js → chunk-6SAYPXHX.js} +4 -4
- package/dist/{chunk-F57VRLKP.js.map → chunk-6SAYPXHX.js.map} +1 -1
- package/dist/{chunk-SK7H3Z67.cjs → chunk-6XDPJWSC.cjs} +99 -83
- package/dist/chunk-6XDPJWSC.cjs.map +1 -0
- package/dist/{chunk-4AE2L6AO.cjs → chunk-7FTBPLA6.cjs} +8 -8
- package/dist/chunk-7FTBPLA6.cjs.map +1 -0
- package/dist/{chunk-KVE7PQ5P.cjs → chunk-7KN6J7XV.cjs} +20 -20
- package/dist/{chunk-KVE7PQ5P.cjs.map → chunk-7KN6J7XV.cjs.map} +1 -1
- package/dist/{chunk-K4S4FAYX.cjs → chunk-AHINB2TP.cjs} +11 -11
- package/dist/{chunk-K4S4FAYX.cjs.map → chunk-AHINB2TP.cjs.map} +1 -1
- package/dist/{chunk-MYFZYUPR.cjs → chunk-AOHJILLU.cjs} +38 -3
- package/dist/chunk-AOHJILLU.cjs.map +1 -0
- package/dist/chunk-BKSPDTX4.js +3 -0
- package/dist/{chunk-3PXOIAF6.js.map → chunk-BKSPDTX4.js.map} +1 -1
- package/dist/chunk-BN75TLUN.cjs +163 -0
- package/dist/chunk-BN75TLUN.cjs.map +1 -0
- package/dist/{chunk-WWJIW2IH.cjs → chunk-BVMABVC4.cjs} +3 -3
- package/dist/{chunk-WWJIW2IH.cjs.map → chunk-BVMABVC4.cjs.map} +1 -1
- package/dist/{chunk-H7QSGFMZ.cjs → chunk-BZAGP5W6.cjs} +17 -10
- package/dist/chunk-BZAGP5W6.cjs.map +1 -0
- package/dist/{chunk-RS5VA6QU.cjs → chunk-C3DUS2VE.cjs} +3 -3
- package/dist/{chunk-RS5VA6QU.cjs.map → chunk-C3DUS2VE.cjs.map} +1 -1
- package/dist/{chunk-NLBT5O2X.js → chunk-CK3KLRNF.js} +3 -3
- package/dist/{chunk-NLBT5O2X.js.map → chunk-CK3KLRNF.js.map} +1 -1
- package/dist/{chunk-L6D4CKLV.cjs → chunk-CXDMZT45.cjs} +135 -4
- package/dist/chunk-CXDMZT45.cjs.map +1 -0
- package/dist/{chunk-TXRQQMG5.js → chunk-CYMZ2QS5.js} +2 -2
- package/dist/{chunk-TXRQQMG5.js.map → chunk-CYMZ2QS5.js.map} +1 -1
- package/dist/{chunk-DX64KLSN.js → chunk-D25WH7MH.js} +7 -7
- package/dist/{chunk-DX64KLSN.js.map → chunk-D25WH7MH.js.map} +1 -1
- package/dist/{chunk-XBKOZRDO.js → chunk-DFYMIRMW.js} +4 -4
- package/dist/{chunk-XBKOZRDO.js.map → chunk-DFYMIRMW.js.map} +1 -1
- package/dist/{chunk-AESFOMSH.js → chunk-DGRXAIWK.js} +135 -4
- package/dist/chunk-DGRXAIWK.js.map +1 -0
- package/dist/{chunk-UZ5NGGMI.js → chunk-EG7XFZ3W.js} +4 -4
- package/dist/{chunk-UZ5NGGMI.js.map → chunk-EG7XFZ3W.js.map} +1 -1
- package/dist/{chunk-RYQ3S3KO.cjs → chunk-FQBTGS3E.cjs} +23 -20
- package/dist/chunk-FQBTGS3E.cjs.map +1 -0
- package/dist/{chunk-LQHI44OZ.cjs → chunk-FUFBRKOG.cjs} +59 -59
- package/dist/{chunk-LQHI44OZ.cjs.map → chunk-FUFBRKOG.cjs.map} +1 -1
- package/dist/{chunk-DG7KE4YJ.cjs → chunk-FYAKUU2A.cjs} +38 -21
- package/dist/chunk-FYAKUU2A.cjs.map +1 -0
- package/dist/{chunk-7L7OPISJ.cjs → chunk-H4AVMUOC.cjs} +12 -6
- package/dist/chunk-H4AVMUOC.cjs.map +1 -0
- package/dist/{chunk-I2ECTLON.cjs → chunk-HXSA6QC5.cjs} +3 -3
- package/dist/{chunk-I2ECTLON.cjs.map → chunk-HXSA6QC5.cjs.map} +1 -1
- package/dist/{chunk-DCBMTFLE.js → chunk-HZ4MBUC3.js} +3 -3
- package/dist/{chunk-DCBMTFLE.js.map → chunk-HZ4MBUC3.js.map} +1 -1
- package/dist/{chunk-X5ZPYYMS.js → chunk-I3DQXUSC.js} +3 -3
- package/dist/{chunk-X5ZPYYMS.js.map → chunk-I3DQXUSC.js.map} +1 -1
- package/dist/{chunk-FN6VHMLM.cjs → chunk-IB54SKWB.cjs} +8 -8
- package/dist/{chunk-FN6VHMLM.cjs.map → chunk-IB54SKWB.cjs.map} +1 -1
- package/dist/{chunk-JP5SGIXA.cjs → chunk-IFDC4TXM.cjs} +4 -4
- package/dist/{chunk-JP5SGIXA.cjs.map → chunk-IFDC4TXM.cjs.map} +1 -1
- package/dist/{chunk-RDGRKYQ5.cjs → chunk-IINZWUGK.cjs} +58 -6
- package/dist/chunk-IINZWUGK.cjs.map +1 -0
- package/dist/{chunk-U3JU6BI5.cjs → chunk-JEIW7BSV.cjs} +3 -3
- package/dist/{chunk-U3JU6BI5.cjs.map → chunk-JEIW7BSV.cjs.map} +1 -1
- package/dist/{chunk-D2GID3YK.js → chunk-KREUYVMZ.js} +58 -6
- package/dist/chunk-KREUYVMZ.js.map +1 -0
- package/dist/{chunk-Y6YSJPVC.js → chunk-KRU6IGV7.js} +11 -3
- package/dist/chunk-KRU6IGV7.js.map +1 -0
- package/dist/{chunk-LZU7YBXG.js → chunk-KU3XRHWA.js} +169 -10
- package/dist/chunk-KU3XRHWA.js.map +1 -0
- package/dist/{chunk-P2VTQ5AR.cjs → chunk-L52N6BEN.cjs} +39 -23
- package/dist/chunk-L52N6BEN.cjs.map +1 -0
- package/dist/{chunk-XWYKLEKG.js → chunk-L5W7TJQ5.js} +11 -5
- package/dist/chunk-L5W7TJQ5.js.map +1 -0
- package/dist/{chunk-PAM5UUBL.cjs → chunk-L7L5S2HO.cjs} +18 -2
- package/dist/{chunk-PAM5UUBL.cjs.map → chunk-L7L5S2HO.cjs.map} +1 -1
- package/dist/{chunk-SEPYBAML.js → chunk-LAEIVOIY.js} +38 -21
- package/dist/chunk-LAEIVOIY.js.map +1 -0
- package/dist/{chunk-Z5KFXHDP.cjs → chunk-MM7QKUE3.cjs} +5 -5
- package/dist/{chunk-Z5KFXHDP.cjs.map → chunk-MM7QKUE3.cjs.map} +1 -1
- package/dist/{chunk-FJ7YPVKV.js → chunk-MUIDWFYJ.js} +3 -3
- package/dist/{chunk-FJ7YPVKV.js.map → chunk-MUIDWFYJ.js.map} +1 -1
- package/dist/{chunk-FDV7EQWH.js → chunk-MXQ7J4BB.js} +21 -18
- package/dist/chunk-MXQ7J4BB.js.map +1 -0
- package/dist/{chunk-YMHOF6WA.cjs → chunk-MYAU2ZUC.cjs} +3 -3
- package/dist/{chunk-YMHOF6WA.cjs.map → chunk-MYAU2ZUC.cjs.map} +1 -1
- package/dist/{chunk-5J5PEUUA.js → chunk-NHN6A3ZO.js} +6 -6
- package/dist/{chunk-5J5PEUUA.js.map → chunk-NHN6A3ZO.js.map} +1 -1
- package/dist/{chunk-EPQPUFS6.cjs → chunk-NYJIXR4Y.cjs} +6 -6
- package/dist/chunk-NYJIXR4Y.cjs.map +1 -0
- package/dist/{chunk-EKRT7K2K.js → chunk-O6GJ4IYS.js} +222 -157
- package/dist/chunk-O6GJ4IYS.js.map +1 -0
- package/dist/{chunk-WIYQI35R.cjs → chunk-O7XHHTTP.cjs} +8 -8
- package/dist/{chunk-WIYQI35R.cjs.map → chunk-O7XHHTTP.cjs.map} +1 -1
- package/dist/{chunk-IILJGFI5.js → chunk-OAZUDUGX.js} +8 -6
- package/dist/chunk-OAZUDUGX.js.map +1 -0
- package/dist/{chunk-JHGMZX4I.cjs → chunk-OCV33S5Q.cjs} +6 -6
- package/dist/{chunk-JHGMZX4I.cjs.map → chunk-OCV33S5Q.cjs.map} +1 -1
- package/dist/{chunk-IYXCFIMP.js → chunk-ODYQYLO2.js} +33 -17
- package/dist/chunk-ODYQYLO2.js.map +1 -0
- package/dist/{chunk-FPVRQCCL.js → chunk-OHDIJOGG.js} +4 -4
- package/dist/{chunk-FPVRQCCL.js.map → chunk-OHDIJOGG.js.map} +1 -1
- package/dist/{chunk-GQVL2JKQ.cjs → chunk-OHKO5THF.cjs} +3 -3
- package/dist/{chunk-GQVL2JKQ.cjs.map → chunk-OHKO5THF.cjs.map} +1 -1
- package/dist/{chunk-LMBXJZLG.js → chunk-ON4JULCA.js} +3 -3
- package/dist/{chunk-LMBXJZLG.js.map → chunk-ON4JULCA.js.map} +1 -1
- package/dist/{chunk-A5YOIJKL.js → chunk-ONNY7UO4.js} +15 -15
- package/dist/{chunk-A5YOIJKL.js.map → chunk-ONNY7UO4.js.map} +1 -1
- package/dist/{chunk-DWCYEPTT.js → chunk-OSPTA4UR.js} +4 -4
- package/dist/{chunk-DWCYEPTT.js.map → chunk-OSPTA4UR.js.map} +1 -1
- package/dist/{chunk-FDUA6OGN.js → chunk-PFKRHNYV.js} +8 -8
- package/dist/chunk-PFKRHNYV.js.map +1 -0
- package/dist/{chunk-XMECP2MD.js → chunk-PHK4XBO5.js} +4 -4
- package/dist/{chunk-XMECP2MD.js.map → chunk-PHK4XBO5.js.map} +1 -1
- package/dist/{chunk-ZZJ4ZVYR.cjs → chunk-PJ6CC53R.cjs} +3 -3
- package/dist/{chunk-ZZJ4ZVYR.cjs.map → chunk-PJ6CC53R.cjs.map} +1 -1
- package/dist/{chunk-N3Y43KOB.js → chunk-PYHFVYVZ.js} +12 -5
- package/dist/chunk-PYHFVYVZ.js.map +1 -0
- package/dist/{chunk-XMCIXHGH.js → chunk-Q7G56ZIO.js} +39 -23
- package/dist/chunk-Q7G56ZIO.js.map +1 -0
- package/dist/{chunk-4PIW3Y5M.js → chunk-QAKASRE6.js} +34 -26
- package/dist/chunk-QAKASRE6.js.map +1 -0
- package/dist/{chunk-QGZC43L7.js → chunk-QAQOCS2J.js} +5 -5
- package/dist/{chunk-QGZC43L7.js.map → chunk-QAQOCS2J.js.map} +1 -1
- package/dist/{chunk-YVIH26FG.cjs → chunk-QKAYRHWP.cjs} +12 -12
- package/dist/{chunk-YVIH26FG.cjs.map → chunk-QKAYRHWP.cjs.map} +1 -1
- package/dist/{chunk-P3JEMF6E.cjs → chunk-RSCA5AZW.cjs} +4 -4
- package/dist/{chunk-P3JEMF6E.cjs.map → chunk-RSCA5AZW.cjs.map} +1 -1
- package/dist/{chunk-5Y5FSR4N.js → chunk-SCXELRRZ.js} +3 -3
- package/dist/{chunk-5Y5FSR4N.js.map → chunk-SCXELRRZ.js.map} +1 -1
- package/dist/{chunk-JWTCEWQ4.cjs → chunk-SNEQXSC5.cjs} +2 -2
- package/dist/{chunk-JWTCEWQ4.cjs.map → chunk-SNEQXSC5.cjs.map} +1 -1
- package/dist/{chunk-U5TTXN45.cjs → chunk-SRA2L3SQ.cjs} +9 -7
- package/dist/chunk-SRA2L3SQ.cjs.map +1 -0
- package/dist/{chunk-5U6GETAW.js → chunk-TQDZLRIE.js} +3 -3
- package/dist/chunk-TQDZLRIE.js.map +1 -0
- package/dist/{chunk-HK3AMH3Q.cjs → chunk-VROIMIHB.cjs} +11 -3
- package/dist/chunk-VROIMIHB.cjs.map +1 -0
- package/dist/{chunk-3SHLOF4V.cjs → chunk-VTR2KGLY.cjs} +9 -9
- package/dist/{chunk-3SHLOF4V.cjs.map → chunk-VTR2KGLY.cjs.map} +1 -1
- package/dist/{chunk-XO3WLK65.js → chunk-VVDE4CHU.js} +3 -3
- package/dist/{chunk-XO3WLK65.js.map → chunk-VVDE4CHU.js.map} +1 -1
- package/dist/{chunk-XS35KPBZ.cjs → chunk-WIAQQNFU.cjs} +4 -4
- package/dist/{chunk-XS35KPBZ.cjs.map → chunk-WIAQQNFU.cjs.map} +1 -1
- package/dist/{chunk-BOOJDRJO.js → chunk-WSNMQQ4P.js} +38 -3
- package/dist/chunk-WSNMQQ4P.js.map +1 -0
- package/dist/chunk-WYMO3IIK.js +136 -0
- package/dist/chunk-WYMO3IIK.js.map +1 -0
- package/dist/{chunk-SPWVKDGC.cjs → chunk-X5QRRMGB.cjs} +35 -27
- package/dist/chunk-X5QRRMGB.cjs.map +1 -0
- package/dist/{chunk-SH6B4MG5.js → chunk-XBXDUAIM.js} +4 -4
- package/dist/{chunk-SH6B4MG5.js.map → chunk-XBXDUAIM.js.map} +1 -1
- package/dist/{chunk-56QJHQ5C.cjs → chunk-XEEVDZDK.cjs} +5 -5
- package/dist/{chunk-56QJHQ5C.cjs.map → chunk-XEEVDZDK.cjs.map} +1 -1
- package/dist/{chunk-GXODR6V4.js → chunk-XOIIUO6O.js} +3 -3
- package/dist/{chunk-GXODR6V4.js.map → chunk-XOIIUO6O.js.map} +1 -1
- package/dist/{chunk-ELYGV32O.cjs → chunk-XTHMC76F.cjs} +5 -5
- package/dist/{chunk-ELYGV32O.cjs.map → chunk-XTHMC76F.cjs.map} +1 -1
- package/dist/{chunk-FF235PKY.cjs → chunk-XWZEECEX.cjs} +3 -3
- package/dist/chunk-XWZEECEX.cjs.map +1 -0
- package/dist/{chunk-TVLZZI5Q.cjs → chunk-YJP6DUFO.cjs} +9 -9
- package/dist/{chunk-TVLZZI5Q.cjs.map → chunk-YJP6DUFO.cjs.map} +1 -1
- package/dist/{chunk-EHQ77LL5.js → chunk-ZB54MTMQ.js} +3 -3
- package/dist/{chunk-EHQ77LL5.js.map → chunk-ZB54MTMQ.js.map} +1 -1
- package/dist/components/Accordion/index.cjs +2 -2
- package/dist/components/Accordion/index.js +1 -1
- package/dist/components/Alert/index.cjs +5 -5
- package/dist/components/Alert/index.d.cts +1 -1
- package/dist/components/Alert/index.d.ts +1 -1
- package/dist/components/Alert/index.js +1 -1
- package/dist/components/AlertDialog/index.cjs +6 -5
- package/dist/components/AlertDialog/index.js +5 -4
- package/dist/components/AudioPlayer/index.cjs +6 -6
- package/dist/components/AudioPlayer/index.js +1 -1
- package/dist/components/Autocomplete/index.cjs +4 -4
- package/dist/components/Autocomplete/index.js +3 -3
- package/dist/components/Avatar/index.cjs +5 -5
- package/dist/components/Avatar/index.js +1 -1
- package/dist/components/Badge/index.d.cts +1 -1
- package/dist/components/Badge/index.d.ts +1 -1
- package/dist/components/Breadcrumb/index.cjs +3 -3
- package/dist/components/Breadcrumb/index.js +1 -1
- package/dist/components/Button/index.cjs +3 -3
- package/dist/components/Button/index.js +1 -1
- package/dist/components/Card/index.d.cts +2 -2
- package/dist/components/Card/index.d.ts +2 -2
- package/dist/components/CountryCodeDropdown/index.cjs +6 -6
- package/dist/components/CountryCodeDropdown/index.d.cts +11 -1
- package/dist/components/CountryCodeDropdown/index.d.ts +11 -1
- package/dist/components/CountryCodeDropdown/index.js +3 -3
- package/dist/components/CustomizableDashboard/index.cjs +11 -11
- package/dist/components/CustomizableDashboard/index.js +4 -4
- package/dist/components/DateInput/index.cjs +4 -4
- package/dist/components/DateInput/index.js +3 -3
- package/dist/components/Dropdown/index.cjs +13 -9
- package/dist/components/Dropdown/index.d.cts +38 -2
- package/dist/components/Dropdown/index.d.ts +38 -2
- package/dist/components/Dropdown/index.js +3 -3
- package/dist/components/FloatingWindow/index.cjs +4 -4
- package/dist/components/FloatingWindow/index.js +2 -2
- package/dist/components/GlossaryTooltip/index.cjs +4 -4
- package/dist/components/GlossaryTooltip/index.js +3 -3
- package/dist/components/KeyboardShortcutsOverlay/index.cjs +6 -5
- package/dist/components/KeyboardShortcutsOverlay/index.js +4 -3
- package/dist/components/Markdown/index.cjs +19 -19
- package/dist/components/Markdown/index.js +7 -7
- package/dist/components/MediaEditor/index.cjs +15 -14
- package/dist/components/MediaEditor/index.js +10 -9
- package/dist/components/MediaPlayer/index.cjs +6 -6
- package/dist/components/MediaPlayer/index.js +3 -3
- package/dist/components/Modal/index.cjs +11 -10
- package/dist/components/Modal/index.d.cts +1 -1
- package/dist/components/Modal/index.d.ts +1 -1
- package/dist/components/Modal/index.js +3 -2
- package/dist/components/Pagination/index.cjs +4 -4
- package/dist/components/Pagination/index.d.cts +1 -1
- package/dist/components/Pagination/index.d.ts +1 -1
- package/dist/components/Pagination/index.js +1 -1
- package/dist/components/PhoneInput/index.cjs +4 -4
- package/dist/components/PhoneInput/index.js +2 -2
- package/dist/components/Progress/index.d.cts +1 -1
- package/dist/components/Progress/index.d.ts +1 -1
- package/dist/components/QuickAction/index.cjs +6 -6
- package/dist/components/QuickAction/index.js +1 -1
- package/dist/components/RecordButton/index.d.cts +1 -1
- package/dist/components/RecordButton/index.d.ts +1 -1
- package/dist/components/RichTextEditor/index.cjs +9 -9
- package/dist/components/RichTextEditor/index.js +6 -6
- package/dist/components/SectionSpyNav/index.cjs +4 -4
- package/dist/components/SectionSpyNav/index.js +3 -3
- package/dist/components/Select/index.cjs +5 -5
- package/dist/components/Select/index.js +3 -3
- package/dist/components/Sheet/index.cjs +11 -11
- package/dist/components/Sheet/index.js +2 -2
- package/dist/components/Slider/index.cjs +5 -5
- package/dist/components/Slider/index.d.cts +2 -2
- package/dist/components/Slider/index.d.ts +2 -2
- package/dist/components/Slider/index.js +1 -1
- package/dist/components/SourceTip/index.cjs +4 -4
- package/dist/components/SourceTip/index.js +3 -3
- package/dist/components/SuperChat/index.cjs +264 -106
- package/dist/components/SuperChat/index.cjs.map +1 -1
- package/dist/components/SuperChat/index.d.cts +13 -5
- package/dist/components/SuperChat/index.d.ts +13 -5
- package/dist/components/SuperChat/index.js +255 -97
- package/dist/components/SuperChat/index.js.map +1 -1
- package/dist/components/SuperChat/plugins/index.cjs +7 -7
- package/dist/components/SuperChat/plugins/index.cjs.map +1 -1
- package/dist/components/SuperChat/plugins/index.d.cts +2 -2
- package/dist/components/SuperChat/plugins/index.d.ts +2 -2
- package/dist/components/SuperChat/plugins/index.js +6 -6
- package/dist/components/SuperChat/plugins/index.js.map +1 -1
- package/dist/components/Text/index.d.cts +1 -1
- package/dist/components/Text/index.d.ts +1 -1
- package/dist/components/ThemeProvider/index.cjs +9 -9
- package/dist/components/ThemeProvider/index.d.cts +1 -1
- package/dist/components/ThemeProvider/index.d.ts +1 -1
- package/dist/components/ThemeProvider/index.js +3 -3
- package/dist/components/Toggle/index.d.cts +1 -1
- package/dist/components/Toggle/index.d.ts +1 -1
- package/dist/components/Tooltip/index.cjs +3 -3
- package/dist/components/Tooltip/index.js +2 -2
- package/dist/components/TranscriptView/index.cjs +3 -3
- package/dist/components/TranscriptView/index.js +1 -1
- package/dist/datavis.cjs +2 -2
- package/dist/datavis.js +1 -1
- package/dist/esheet.cjs +15 -14
- package/dist/esheet.cjs.map +1 -1
- package/dist/esheet.js +12 -11
- package/dist/esheet.js.map +1 -1
- package/dist/hooks/index.cjs +3 -3
- package/dist/hooks/index.d.cts +1 -1
- package/dist/hooks/index.d.ts +1 -1
- package/dist/hooks/index.js +2 -2
- package/dist/index.cjs +2399 -1640
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +278 -43
- package/dist/index.d.ts +278 -43
- package/dist/index.js +1296 -574
- package/dist/index.js.map +1 -1
- package/dist/motion.cjs +87 -0
- package/dist/motion.cjs.map +1 -0
- package/dist/motion.d.cts +52 -0
- package/dist/motion.d.ts +52 -0
- package/dist/motion.js +50 -0
- package/dist/motion.js.map +1 -0
- package/dist/styles/init.css +25 -0
- package/dist/styles.css +1 -1
- package/dist/tailwind-preset.cjs +4 -4
- package/dist/tailwind-preset.js +1 -1
- package/dist/{types-BoTeTPdH.d.ts → types-9vK_YdEb.d.ts} +12 -1
- package/dist/{types-DyIB9HYT.d.cts → types-DZDroUW8.d.cts} +12 -1
- package/dist/{useAnchoredPosition-C7PNglzD.d.ts → useAnchoredPosition-CKwLSQW8.d.cts} +10 -3
- package/dist/{useAnchoredPosition-C7PNglzD.d.cts → useAnchoredPosition-CKwLSQW8.d.ts} +10 -3
- package/package.json +21 -2
- package/dist/CsvBlock-OTFG3PYZ.cjs +0 -15
- package/dist/CsvBlock-PUSTBQ5B.js +0 -6
- package/dist/HtmlPreviewBlock-QHLSIMWJ.cjs +0 -15
- package/dist/HtmlPreviewBlock-YF2YVKKX.js +0 -6
- package/dist/MermaidBlock-H3TWNC4D.js +0 -6
- package/dist/MermaidBlock-ZLLBO3VY.cjs +0 -15
- package/dist/SurveyBlock-JLHS3YQD.js +0 -6
- package/dist/SurveyBlock-M2ZRTGVJ.cjs +0 -15
- package/dist/chunk-26DPQUSB.cjs.map +0 -1
- package/dist/chunk-3PXOIAF6.js +0 -3
- package/dist/chunk-4AE2L6AO.cjs.map +0 -1
- package/dist/chunk-4PIW3Y5M.js.map +0 -1
- package/dist/chunk-5JZIDILK.cjs.map +0 -1
- package/dist/chunk-5U6GETAW.js.map +0 -1
- package/dist/chunk-6EWJGRC3.js.map +0 -1
- package/dist/chunk-7L7OPISJ.cjs.map +0 -1
- package/dist/chunk-AESFOMSH.js.map +0 -1
- package/dist/chunk-BOOJDRJO.js.map +0 -1
- package/dist/chunk-BOW7ZGI2.cjs.map +0 -1
- package/dist/chunk-D2GID3YK.js.map +0 -1
- package/dist/chunk-DG7KE4YJ.cjs.map +0 -1
- package/dist/chunk-EKRT7K2K.js.map +0 -1
- package/dist/chunk-EPQPUFS6.cjs.map +0 -1
- package/dist/chunk-FDUA6OGN.js.map +0 -1
- package/dist/chunk-FDV7EQWH.js.map +0 -1
- package/dist/chunk-FF235PKY.cjs.map +0 -1
- package/dist/chunk-H7QSGFMZ.cjs.map +0 -1
- package/dist/chunk-HK3AMH3Q.cjs.map +0 -1
- package/dist/chunk-IILJGFI5.js.map +0 -1
- package/dist/chunk-IYXCFIMP.js.map +0 -1
- package/dist/chunk-JHZW3Y62.js.map +0 -1
- package/dist/chunk-L6D4CKLV.cjs.map +0 -1
- package/dist/chunk-LZU7YBXG.js.map +0 -1
- package/dist/chunk-MYFZYUPR.cjs.map +0 -1
- package/dist/chunk-N3Y43KOB.js.map +0 -1
- package/dist/chunk-P2VTQ5AR.cjs.map +0 -1
- package/dist/chunk-RDGRKYQ5.cjs.map +0 -1
- package/dist/chunk-RYQ3S3KO.cjs.map +0 -1
- package/dist/chunk-SEPYBAML.js.map +0 -1
- package/dist/chunk-SK7H3Z67.cjs.map +0 -1
- package/dist/chunk-SPWVKDGC.cjs.map +0 -1
- package/dist/chunk-U5TTXN45.cjs.map +0 -1
- package/dist/chunk-XMCIXHGH.js.map +0 -1
- package/dist/chunk-XWYKLEKG.js.map +0 -1
- package/dist/chunk-Y6YSJPVC.js.map +0 -1
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var chunkMYFZYUPR_cjs = require('./chunk-MYFZYUPR.cjs');
|
|
4
3
|
var chunkS5RVSXDV_cjs = require('./chunk-S5RVSXDV.cjs');
|
|
5
|
-
var
|
|
4
|
+
var chunkAOHJILLU_cjs = require('./chunk-AOHJILLU.cjs');
|
|
5
|
+
var React3 = require('react');
|
|
6
6
|
var jsxRuntime = require('react/jsx-runtime');
|
|
7
|
-
var reactDom = require('react-dom');
|
|
8
7
|
var classVarianceAuthority = require('class-variance-authority');
|
|
8
|
+
var reactDom = require('react-dom');
|
|
9
9
|
|
|
10
10
|
function _interopNamespace(e) {
|
|
11
11
|
if (e && e.__esModule) return e;
|
|
@@ -25,7 +25,7 @@ function _interopNamespace(e) {
|
|
|
25
25
|
return Object.freeze(n);
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
-
var
|
|
28
|
+
var React3__namespace = /*#__PURE__*/_interopNamespace(React3);
|
|
29
29
|
|
|
30
30
|
function getFileType(mimeType) {
|
|
31
31
|
if (mimeType.startsWith("image/")) return "image";
|
|
@@ -71,6 +71,7 @@ function AttachmentPreviewItem({
|
|
|
71
71
|
attachment,
|
|
72
72
|
onRemove,
|
|
73
73
|
onRetry,
|
|
74
|
+
disabled = false,
|
|
74
75
|
className
|
|
75
76
|
}) {
|
|
76
77
|
const { file, previewUrl, type, state, progress } = attachment;
|
|
@@ -90,7 +91,20 @@ function AttachmentPreviewItem({
|
|
|
90
91
|
),
|
|
91
92
|
children: [
|
|
92
93
|
(isImage || isVideo) && previewUrl ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative h-20 w-20", children: [
|
|
93
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
94
|
+
isVideo ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
95
|
+
"video",
|
|
96
|
+
{
|
|
97
|
+
src: previewUrl,
|
|
98
|
+
"aria-label": file.name,
|
|
99
|
+
muted: true,
|
|
100
|
+
playsInline: true,
|
|
101
|
+
preload: "metadata",
|
|
102
|
+
className: chunkS5RVSXDV_cjs.cn(
|
|
103
|
+
"h-full w-full object-cover",
|
|
104
|
+
(isUploading || isFailed) && "opacity-50"
|
|
105
|
+
)
|
|
106
|
+
}
|
|
107
|
+
) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
94
108
|
"img",
|
|
95
109
|
{
|
|
96
110
|
src: previewUrl,
|
|
@@ -133,7 +147,7 @@ function AttachmentPreviewItem({
|
|
|
133
147
|
)
|
|
134
148
|
}
|
|
135
149
|
),
|
|
136
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "mt-1 max-w-full truncate px-1 text-xs text-neutral-
|
|
150
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "mt-1 max-w-full truncate px-1 text-xs text-neutral-600 dark:text-neutral-400", children: file.name.split(".").pop()?.toUpperCase() })
|
|
137
151
|
] })
|
|
138
152
|
),
|
|
139
153
|
isUploading && progress !== void 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute inset-0 flex items-center justify-center bg-black/50", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center text-white", children: [
|
|
@@ -197,7 +211,8 @@ function AttachmentPreviewItem({
|
|
|
197
211
|
{
|
|
198
212
|
type: "button",
|
|
199
213
|
onClick: onRetry,
|
|
200
|
-
|
|
214
|
+
disabled,
|
|
215
|
+
className: "mt-1 text-xs text-white underline hover:no-underline disabled:no-underline disabled:opacity-50",
|
|
201
216
|
children: "Retry"
|
|
202
217
|
}
|
|
203
218
|
)
|
|
@@ -207,13 +222,15 @@ function AttachmentPreviewItem({
|
|
|
207
222
|
{
|
|
208
223
|
type: "button",
|
|
209
224
|
onClick: onRemove,
|
|
225
|
+
disabled,
|
|
210
226
|
className: chunkS5RVSXDV_cjs.cn(
|
|
211
|
-
"absolute -
|
|
227
|
+
"absolute -end-1 -top-1 z-10",
|
|
212
228
|
"rounded-full p-1",
|
|
213
229
|
"bg-neutral-900 text-white",
|
|
214
230
|
"opacity-0 group-hover:opacity-100",
|
|
215
231
|
"focus:ring-primary-500 focus:opacity-100 focus:ring-2 focus:outline-none",
|
|
216
|
-
"transition-opacity"
|
|
232
|
+
"transition-opacity",
|
|
233
|
+
"disabled:cursor-not-allowed disabled:group-hover:opacity-0"
|
|
217
234
|
),
|
|
218
235
|
"aria-label": `Remove ${file.name}`,
|
|
219
236
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -241,7 +258,7 @@ function AttachmentPreviewItem({
|
|
|
241
258
|
"div",
|
|
242
259
|
{
|
|
243
260
|
className: chunkS5RVSXDV_cjs.cn(
|
|
244
|
-
"absolute
|
|
261
|
+
"absolute start-0 end-0 bottom-0",
|
|
245
262
|
"bg-black/70 px-1 py-0.5",
|
|
246
263
|
"opacity-0 group-hover:opacity-100",
|
|
247
264
|
"transition-opacity"
|
|
@@ -254,7 +271,7 @@ function AttachmentPreviewItem({
|
|
|
254
271
|
);
|
|
255
272
|
}
|
|
256
273
|
AttachmentPreviewItem.displayName = "AttachmentPreviewItem";
|
|
257
|
-
var AttachmentPicker =
|
|
274
|
+
var AttachmentPicker = React3__namespace.forwardRef(
|
|
258
275
|
({
|
|
259
276
|
onFilesSelected,
|
|
260
277
|
acceptedTypes = ["image/*", "video/*", ".pdf", ".doc", ".docx"],
|
|
@@ -267,8 +284,8 @@ var AttachmentPicker = React2__namespace.forwardRef(
|
|
|
267
284
|
className,
|
|
268
285
|
children
|
|
269
286
|
}, ref) => {
|
|
270
|
-
const inputRef =
|
|
271
|
-
|
|
287
|
+
const inputRef = React3__namespace.useRef(null);
|
|
288
|
+
React3__namespace.useImperativeHandle(ref, () => inputRef.current);
|
|
272
289
|
const handleClick = () => {
|
|
273
290
|
inputRef.current?.click();
|
|
274
291
|
};
|
|
@@ -357,11 +374,12 @@ function DragDropZone({
|
|
|
357
374
|
maxFiles = 10,
|
|
358
375
|
disabled = false,
|
|
359
376
|
onError,
|
|
377
|
+
overlayLabel = "Drop files here",
|
|
360
378
|
children,
|
|
361
379
|
className
|
|
362
380
|
}) {
|
|
363
|
-
const [isDragging, setIsDragging] =
|
|
364
|
-
const dragCounterRef =
|
|
381
|
+
const [isDragging, setIsDragging] = React3__namespace.useState(false);
|
|
382
|
+
const dragCounterRef = React3__namespace.useRef(0);
|
|
365
383
|
const handleDragEnter = (event) => {
|
|
366
384
|
event.preventDefault();
|
|
367
385
|
event.stopPropagation();
|
|
@@ -448,7 +466,7 @@ function DragDropZone({
|
|
|
448
466
|
)
|
|
449
467
|
}
|
|
450
468
|
),
|
|
451
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-primary-700 dark:text-primary-300 mt-2 text-sm font-medium", children:
|
|
469
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-primary-700 dark:text-primary-300 mt-2 text-sm font-medium", children: overlayLabel })
|
|
452
470
|
] })
|
|
453
471
|
}
|
|
454
472
|
)
|
|
@@ -463,7 +481,7 @@ function CameraButton({
|
|
|
463
481
|
disabled = false,
|
|
464
482
|
className
|
|
465
483
|
}) {
|
|
466
|
-
const inputRef =
|
|
484
|
+
const inputRef = React3__namespace.useRef(null);
|
|
467
485
|
const handleClick = () => {
|
|
468
486
|
inputRef.current?.click();
|
|
469
487
|
};
|
|
@@ -548,6 +566,162 @@ function activeMentionQuery(value, caret) {
|
|
|
548
566
|
const query = match[2];
|
|
549
567
|
return { query, start: caret - query.length - 1 };
|
|
550
568
|
}
|
|
569
|
+
function useMentionAutocomplete({
|
|
570
|
+
options,
|
|
571
|
+
value,
|
|
572
|
+
setValue,
|
|
573
|
+
textareaRef
|
|
574
|
+
}) {
|
|
575
|
+
const enabled = !!options && options.length > 0;
|
|
576
|
+
const [mention, setMention] = React3__namespace.useState(null);
|
|
577
|
+
const [highlight, setHighlight] = React3__namespace.useState(0);
|
|
578
|
+
const listId = React3__namespace.useId();
|
|
579
|
+
const optionId = React3__namespace.useCallback(
|
|
580
|
+
(index) => `${listId}-option-${index}`,
|
|
581
|
+
[listId]
|
|
582
|
+
);
|
|
583
|
+
const suggestions = React3__namespace.useMemo(() => {
|
|
584
|
+
if (!mention || !options) return [];
|
|
585
|
+
const q = mention.query.toLowerCase();
|
|
586
|
+
return options.filter((o) => o.label.toLowerCase().includes(q));
|
|
587
|
+
}, [mention, options]);
|
|
588
|
+
const menuOpen = enabled && mention !== null && suggestions.length > 0;
|
|
589
|
+
const {
|
|
590
|
+
anchorRef,
|
|
591
|
+
floatingRef,
|
|
592
|
+
style: menuStyle
|
|
593
|
+
} = chunkAOHJILLU_cjs.useAnchoredPosition({
|
|
594
|
+
open: menuOpen,
|
|
595
|
+
placement: "top-start",
|
|
596
|
+
maxHeight: 224
|
|
597
|
+
});
|
|
598
|
+
const clampedHighlight = menuOpen ? Math.min(highlight, suggestions.length - 1) : -1;
|
|
599
|
+
const activeOptionId = menuOpen ? optionId(clampedHighlight) : void 0;
|
|
600
|
+
const sync = React3__namespace.useCallback(
|
|
601
|
+
(nextValue, caret) => {
|
|
602
|
+
if (!enabled) return;
|
|
603
|
+
setMention(activeMentionQuery(nextValue, caret));
|
|
604
|
+
setHighlight(0);
|
|
605
|
+
},
|
|
606
|
+
[enabled]
|
|
607
|
+
);
|
|
608
|
+
const insert = (option) => {
|
|
609
|
+
if (!mention) return;
|
|
610
|
+
const insertValue = option.value ?? option.label.split(" ")[0];
|
|
611
|
+
const before = value.slice(0, mention.start);
|
|
612
|
+
const after = value.slice(mention.start + 1 + mention.query.length);
|
|
613
|
+
const insertText = `@${insertValue} `;
|
|
614
|
+
setValue(before + insertText + after);
|
|
615
|
+
setMention(null);
|
|
616
|
+
const caret = before.length + insertText.length;
|
|
617
|
+
requestAnimationFrame(() => {
|
|
618
|
+
const el = textareaRef.current;
|
|
619
|
+
if (el) {
|
|
620
|
+
el.focus();
|
|
621
|
+
el.setSelectionRange(caret, caret);
|
|
622
|
+
}
|
|
623
|
+
});
|
|
624
|
+
};
|
|
625
|
+
const handleKeyDown = (event) => {
|
|
626
|
+
if (!menuOpen) return false;
|
|
627
|
+
if (event.key === "ArrowDown") {
|
|
628
|
+
event.preventDefault();
|
|
629
|
+
setHighlight(
|
|
630
|
+
(h) => (Math.min(h, suggestions.length - 1) + 1) % suggestions.length
|
|
631
|
+
);
|
|
632
|
+
return true;
|
|
633
|
+
}
|
|
634
|
+
if (event.key === "ArrowUp") {
|
|
635
|
+
event.preventDefault();
|
|
636
|
+
setHighlight(
|
|
637
|
+
(h) => (Math.min(h, suggestions.length - 1) - 1 + suggestions.length) % suggestions.length
|
|
638
|
+
);
|
|
639
|
+
return true;
|
|
640
|
+
}
|
|
641
|
+
if (event.key === "Enter" || event.key === "Tab") {
|
|
642
|
+
event.preventDefault();
|
|
643
|
+
const chosen = suggestions[clampedHighlight];
|
|
644
|
+
if (chosen) insert(chosen);
|
|
645
|
+
return true;
|
|
646
|
+
}
|
|
647
|
+
if (event.key === "Escape") {
|
|
648
|
+
event.preventDefault();
|
|
649
|
+
setMention(null);
|
|
650
|
+
return true;
|
|
651
|
+
}
|
|
652
|
+
return false;
|
|
653
|
+
};
|
|
654
|
+
const inputProps = enabled ? {
|
|
655
|
+
"aria-controls": menuOpen ? listId : void 0,
|
|
656
|
+
"aria-activedescendant": activeOptionId,
|
|
657
|
+
"aria-autocomplete": "list"
|
|
658
|
+
} : {};
|
|
659
|
+
return {
|
|
660
|
+
enabled,
|
|
661
|
+
menuOpen,
|
|
662
|
+
suggestions,
|
|
663
|
+
highlight: clampedHighlight,
|
|
664
|
+
listId,
|
|
665
|
+
optionId,
|
|
666
|
+
anchorRef,
|
|
667
|
+
floatingRef,
|
|
668
|
+
menuStyle,
|
|
669
|
+
sync,
|
|
670
|
+
insert,
|
|
671
|
+
setHighlight,
|
|
672
|
+
handleKeyDown,
|
|
673
|
+
inputProps
|
|
674
|
+
};
|
|
675
|
+
}
|
|
676
|
+
function MentionMenu({
|
|
677
|
+
mention,
|
|
678
|
+
label = "Mention",
|
|
679
|
+
dataSlot = "composer-mention-list"
|
|
680
|
+
}) {
|
|
681
|
+
if (!mention.menuOpen) return null;
|
|
682
|
+
return reactDom.createPortal(
|
|
683
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
684
|
+
"ul",
|
|
685
|
+
{
|
|
686
|
+
ref: mention.floatingRef,
|
|
687
|
+
style: mention.menuStyle,
|
|
688
|
+
id: mention.listId,
|
|
689
|
+
role: "listbox",
|
|
690
|
+
"aria-label": label,
|
|
691
|
+
"data-slot": dataSlot,
|
|
692
|
+
className: "w-64 overflow-y-auto rounded-lg border border-neutral-200 bg-white py-1 shadow-lg dark:border-neutral-700 dark:bg-neutral-800",
|
|
693
|
+
children: mention.suggestions.map((option, i) => /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
694
|
+
"button",
|
|
695
|
+
{
|
|
696
|
+
type: "button",
|
|
697
|
+
id: mention.optionId(i),
|
|
698
|
+
role: "option",
|
|
699
|
+
"aria-selected": i === mention.highlight,
|
|
700
|
+
onMouseDown: (e) => {
|
|
701
|
+
e.preventDefault();
|
|
702
|
+
mention.insert(option);
|
|
703
|
+
},
|
|
704
|
+
onMouseEnter: () => mention.setHighlight(i),
|
|
705
|
+
className: chunkS5RVSXDV_cjs.cn(
|
|
706
|
+
"flex w-full items-center gap-2 px-3 py-1.5 text-start text-sm",
|
|
707
|
+
i === mention.highlight ? "bg-primary-100 text-primary-900 dark:bg-primary-900/40 dark:text-primary-100" : "text-neutral-700 dark:text-neutral-200"
|
|
708
|
+
),
|
|
709
|
+
children: [
|
|
710
|
+
option.icon,
|
|
711
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "min-w-0 flex-1 truncate", children: [
|
|
712
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-medium", children: option.label }),
|
|
713
|
+
option.description && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "ms-1 text-xs text-neutral-400", children: option.description })
|
|
714
|
+
] }),
|
|
715
|
+
option.meta && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] text-neutral-400", children: option.meta })
|
|
716
|
+
]
|
|
717
|
+
}
|
|
718
|
+
) }, option.id))
|
|
719
|
+
}
|
|
720
|
+
),
|
|
721
|
+
document.body
|
|
722
|
+
);
|
|
723
|
+
}
|
|
724
|
+
MentionMenu.displayName = "MentionMenu";
|
|
551
725
|
function isFileAccepted(file, accepted) {
|
|
552
726
|
if (!accepted || accepted.length === 0) return true;
|
|
553
727
|
const mime = file.type;
|
|
@@ -619,7 +793,7 @@ var sendButtonVariants = classVarianceAuthority.cva(
|
|
|
619
793
|
}
|
|
620
794
|
}
|
|
621
795
|
);
|
|
622
|
-
var SendButton =
|
|
796
|
+
var SendButton = React3__namespace.forwardRef(
|
|
623
797
|
({ className, variant, canSend, isLoading, disabled, ...props }, ref) => {
|
|
624
798
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
625
799
|
"button",
|
|
@@ -684,7 +858,7 @@ var SendButton = React2__namespace.forwardRef(
|
|
|
684
858
|
}
|
|
685
859
|
);
|
|
686
860
|
SendButton.displayName = "SendButton";
|
|
687
|
-
var MessageComposer =
|
|
861
|
+
var MessageComposer = React3__namespace.forwardRef(
|
|
688
862
|
({
|
|
689
863
|
onSend,
|
|
690
864
|
onTypingStart,
|
|
@@ -710,11 +884,11 @@ var MessageComposer = React2__namespace.forwardRef(
|
|
|
710
884
|
mentionOptions,
|
|
711
885
|
className
|
|
712
886
|
}, ref) => {
|
|
713
|
-
const textareaRef =
|
|
714
|
-
const [internalContent, setInternalContent] =
|
|
887
|
+
const textareaRef = React3__namespace.useRef(null);
|
|
888
|
+
const [internalContent, setInternalContent] = React3__namespace.useState("");
|
|
715
889
|
const isControlled = controlledValue !== void 0;
|
|
716
890
|
const content = isControlled ? controlledValue : internalContent;
|
|
717
|
-
const setContent =
|
|
891
|
+
const setContent = React3__namespace.useCallback(
|
|
718
892
|
(val) => {
|
|
719
893
|
if (isControlled) {
|
|
720
894
|
const newVal = typeof val === "function" ? val(controlledValue) : val;
|
|
@@ -725,20 +899,20 @@ var MessageComposer = React2__namespace.forwardRef(
|
|
|
725
899
|
},
|
|
726
900
|
[isControlled, controlledValue, onValueChange]
|
|
727
901
|
);
|
|
728
|
-
const [attachments, setAttachments] =
|
|
902
|
+
const [attachments, setAttachments] = React3__namespace.useState(
|
|
729
903
|
[]
|
|
730
904
|
);
|
|
731
|
-
const [isTyping, setIsTyping] =
|
|
732
|
-
const typingTimeoutRef =
|
|
733
|
-
|
|
734
|
-
|
|
905
|
+
const [isTyping, setIsTyping] = React3__namespace.useState(false);
|
|
906
|
+
const typingTimeoutRef = React3__namespace.useRef(null);
|
|
907
|
+
React3__namespace.useImperativeHandle(ref, () => textareaRef.current);
|
|
908
|
+
React3__namespace.useEffect(() => {
|
|
735
909
|
const textarea = textareaRef.current;
|
|
736
910
|
if (textarea) {
|
|
737
911
|
textarea.style.height = "auto";
|
|
738
912
|
textarea.style.height = `${Math.min(textarea.scrollHeight, 150)}px`;
|
|
739
913
|
}
|
|
740
914
|
}, [content]);
|
|
741
|
-
|
|
915
|
+
React3__namespace.useEffect(() => {
|
|
742
916
|
if (content.length > 0 && !isTyping) {
|
|
743
917
|
setIsTyping(true);
|
|
744
918
|
onTypingStart?.();
|
|
@@ -758,63 +932,22 @@ var MessageComposer = React2__namespace.forwardRef(
|
|
|
758
932
|
}
|
|
759
933
|
};
|
|
760
934
|
}, [content, isTyping, onTypingStart, onTypingStop]);
|
|
761
|
-
|
|
935
|
+
React3__namespace.useEffect(() => {
|
|
762
936
|
if (autoFocus) {
|
|
763
937
|
textareaRef.current?.focus();
|
|
764
938
|
}
|
|
765
939
|
}, [autoFocus]);
|
|
766
|
-
|
|
940
|
+
React3__namespace.useEffect(() => {
|
|
767
941
|
if (replyTo) {
|
|
768
942
|
textareaRef.current?.focus();
|
|
769
943
|
}
|
|
770
944
|
}, [replyTo]);
|
|
771
|
-
const
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
const mentionSuggestions = React2__namespace.useMemo(() => {
|
|
777
|
-
if (!mention || !mentionOptions) return [];
|
|
778
|
-
const q = mention.query.toLowerCase();
|
|
779
|
-
return mentionOptions.filter((o) => o.label.toLowerCase().includes(q));
|
|
780
|
-
}, [mention, mentionOptions]);
|
|
781
|
-
const mentionMenuOpen = mentionsEnabled && mention !== null && mentionSuggestions.length > 0;
|
|
782
|
-
const {
|
|
783
|
-
anchorRef: mentionAnchorRef,
|
|
784
|
-
floatingRef: mentionFloatingRef,
|
|
785
|
-
style: mentionStyle
|
|
786
|
-
} = chunkMYFZYUPR_cjs.useAnchoredPosition({
|
|
787
|
-
open: mentionMenuOpen,
|
|
788
|
-
placement: "top-start",
|
|
789
|
-
maxHeight: 224
|
|
945
|
+
const mention = useMentionAutocomplete({
|
|
946
|
+
options: mentionOptions,
|
|
947
|
+
value: content,
|
|
948
|
+
setValue: setContent,
|
|
949
|
+
textareaRef
|
|
790
950
|
});
|
|
791
|
-
const clampedMentionHighlight = mentionMenuOpen ? Math.min(mentionHighlight, mentionSuggestions.length - 1) : -1;
|
|
792
|
-
const activeMentionOptionId = mentionMenuOpen ? mentionOptionId(clampedMentionHighlight) : void 0;
|
|
793
|
-
const syncMention = React2__namespace.useCallback(
|
|
794
|
-
(value, caret) => {
|
|
795
|
-
if (!mentionsEnabled) return;
|
|
796
|
-
setMention(activeMentionQuery(value, caret));
|
|
797
|
-
setMentionHighlight(0);
|
|
798
|
-
},
|
|
799
|
-
[mentionsEnabled]
|
|
800
|
-
);
|
|
801
|
-
const insertMention = (option) => {
|
|
802
|
-
if (!mention) return;
|
|
803
|
-
const insertValue = option.value ?? option.label.split(" ")[0];
|
|
804
|
-
const before = content.slice(0, mention.start);
|
|
805
|
-
const after = content.slice(mention.start + 1 + mention.query.length);
|
|
806
|
-
const insert = `@${insertValue} `;
|
|
807
|
-
setContent(before + insert + after);
|
|
808
|
-
setMention(null);
|
|
809
|
-
const caret = before.length + insert.length;
|
|
810
|
-
requestAnimationFrame(() => {
|
|
811
|
-
const el = textareaRef.current;
|
|
812
|
-
if (el) {
|
|
813
|
-
el.focus();
|
|
814
|
-
el.setSelectionRange(caret, caret);
|
|
815
|
-
}
|
|
816
|
-
});
|
|
817
|
-
};
|
|
818
951
|
const canSend = (content.trim().length > 0 || attachments.length > 0) && content.length <= maxLength && !disabled && !isSending;
|
|
819
952
|
const handleSubmit = async (event) => {
|
|
820
953
|
event.preventDefault();
|
|
@@ -836,31 +969,7 @@ var MessageComposer = React2__namespace.forwardRef(
|
|
|
836
969
|
}
|
|
837
970
|
};
|
|
838
971
|
const handleKeyDown = (event) => {
|
|
839
|
-
if (
|
|
840
|
-
if (event.key === "ArrowDown") {
|
|
841
|
-
event.preventDefault();
|
|
842
|
-
setMentionHighlight((h) => (h + 1) % mentionSuggestions.length);
|
|
843
|
-
return;
|
|
844
|
-
}
|
|
845
|
-
if (event.key === "ArrowUp") {
|
|
846
|
-
event.preventDefault();
|
|
847
|
-
setMentionHighlight(
|
|
848
|
-
(h) => (h - 1 + mentionSuggestions.length) % mentionSuggestions.length
|
|
849
|
-
);
|
|
850
|
-
return;
|
|
851
|
-
}
|
|
852
|
-
if (event.key === "Enter" || event.key === "Tab") {
|
|
853
|
-
event.preventDefault();
|
|
854
|
-
const chosen = mentionSuggestions[mentionHighlight] ?? mentionSuggestions[0];
|
|
855
|
-
if (chosen) insertMention(chosen);
|
|
856
|
-
return;
|
|
857
|
-
}
|
|
858
|
-
if (event.key === "Escape") {
|
|
859
|
-
event.preventDefault();
|
|
860
|
-
setMention(null);
|
|
861
|
-
return;
|
|
862
|
-
}
|
|
863
|
-
}
|
|
972
|
+
if (mention.handleKeyDown(event)) return;
|
|
864
973
|
if (event.key === "Enter" && !event.shiftKey) {
|
|
865
974
|
event.preventDefault();
|
|
866
975
|
if (canSend) {
|
|
@@ -906,7 +1015,7 @@ var MessageComposer = React2__namespace.forwardRef(
|
|
|
906
1015
|
return prev.filter((a) => a.id !== attachmentId);
|
|
907
1016
|
});
|
|
908
1017
|
};
|
|
909
|
-
|
|
1018
|
+
React3__namespace.useEffect(() => {
|
|
910
1019
|
const currentAttachments = attachments;
|
|
911
1020
|
return () => {
|
|
912
1021
|
currentAttachments.forEach((a) => {
|
|
@@ -940,7 +1049,7 @@ var MessageComposer = React2__namespace.forwardRef(
|
|
|
940
1049
|
className: chunkS5RVSXDV_cjs.cn(
|
|
941
1050
|
"flex items-center gap-2 px-4 py-2",
|
|
942
1051
|
"bg-neutral-50 dark:bg-neutral-800/50",
|
|
943
|
-
"border-primary-500 border-
|
|
1052
|
+
"border-primary-500 border-s-4"
|
|
944
1053
|
),
|
|
945
1054
|
children: [
|
|
946
1055
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0 flex-1", children: [
|
|
@@ -1037,49 +1146,9 @@ var MessageComposer = React2__namespace.forwardRef(
|
|
|
1037
1146
|
{
|
|
1038
1147
|
"data-slot": "composer-input-wrapper",
|
|
1039
1148
|
className: "relative flex-1",
|
|
1040
|
-
ref:
|
|
1149
|
+
ref: mention.anchorRef,
|
|
1041
1150
|
children: [
|
|
1042
|
-
|
|
1043
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1044
|
-
"ul",
|
|
1045
|
-
{
|
|
1046
|
-
ref: mentionFloatingRef,
|
|
1047
|
-
style: mentionStyle,
|
|
1048
|
-
id: mentionListId,
|
|
1049
|
-
role: "listbox",
|
|
1050
|
-
"aria-label": "Mention",
|
|
1051
|
-
"data-slot": "composer-mention-list",
|
|
1052
|
-
className: "w-64 overflow-y-auto rounded-lg border border-neutral-200 bg-white py-1 shadow-lg dark:border-neutral-700 dark:bg-neutral-800",
|
|
1053
|
-
children: mentionSuggestions.map((option, i) => /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1054
|
-
"button",
|
|
1055
|
-
{
|
|
1056
|
-
type: "button",
|
|
1057
|
-
id: mentionOptionId(i),
|
|
1058
|
-
role: "option",
|
|
1059
|
-
"aria-selected": i === clampedMentionHighlight,
|
|
1060
|
-
onMouseDown: (e) => {
|
|
1061
|
-
e.preventDefault();
|
|
1062
|
-
insertMention(option);
|
|
1063
|
-
},
|
|
1064
|
-
onMouseEnter: () => setMentionHighlight(i),
|
|
1065
|
-
className: chunkS5RVSXDV_cjs.cn(
|
|
1066
|
-
"flex w-full items-center gap-2 px-3 py-1.5 text-left text-sm",
|
|
1067
|
-
i === clampedMentionHighlight ? "bg-primary-100 text-primary-900 dark:bg-primary-900/40 dark:text-primary-100" : "text-neutral-700 dark:text-neutral-200"
|
|
1068
|
-
),
|
|
1069
|
-
children: [
|
|
1070
|
-
option.icon,
|
|
1071
|
-
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "min-w-0 flex-1 truncate", children: [
|
|
1072
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-medium", children: option.label }),
|
|
1073
|
-
option.description && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "ml-1 text-xs text-neutral-400", children: option.description })
|
|
1074
|
-
] }),
|
|
1075
|
-
option.meta && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] text-neutral-400", children: option.meta })
|
|
1076
|
-
]
|
|
1077
|
-
}
|
|
1078
|
-
) }, option.id))
|
|
1079
|
-
}
|
|
1080
|
-
),
|
|
1081
|
-
document.body
|
|
1082
|
-
),
|
|
1151
|
+
/* @__PURE__ */ jsxRuntime.jsx(MentionMenu, { mention }),
|
|
1083
1152
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1084
1153
|
"textarea",
|
|
1085
1154
|
{
|
|
@@ -1088,14 +1157,14 @@ var MessageComposer = React2__namespace.forwardRef(
|
|
|
1088
1157
|
value: content,
|
|
1089
1158
|
onChange: (e) => {
|
|
1090
1159
|
setContent(e.target.value);
|
|
1091
|
-
|
|
1160
|
+
mention.sync(
|
|
1092
1161
|
e.target.value,
|
|
1093
1162
|
e.target.selectionStart ?? e.target.value.length
|
|
1094
1163
|
);
|
|
1095
1164
|
},
|
|
1096
1165
|
onClick: (e) => {
|
|
1097
1166
|
const el = e.currentTarget;
|
|
1098
|
-
|
|
1167
|
+
mention.sync(el.value, el.selectionStart ?? el.value.length);
|
|
1099
1168
|
},
|
|
1100
1169
|
onKeyDown: handleKeyDown,
|
|
1101
1170
|
onPaste: handlePaste,
|
|
@@ -1104,7 +1173,7 @@ var MessageComposer = React2__namespace.forwardRef(
|
|
|
1104
1173
|
rows: 1,
|
|
1105
1174
|
className: chunkS5RVSXDV_cjs.cn(
|
|
1106
1175
|
"w-full resize-none rounded-2xl py-2.5",
|
|
1107
|
-
inputTrailing ? "
|
|
1176
|
+
inputTrailing ? "ps-4 pe-10" : "px-4",
|
|
1108
1177
|
"bg-neutral-100 dark:bg-neutral-800",
|
|
1109
1178
|
"text-neutral-900 dark:text-neutral-100",
|
|
1110
1179
|
"placeholder:text-neutral-400 dark:placeholder:text-neutral-500",
|
|
@@ -1115,18 +1184,14 @@ var MessageComposer = React2__namespace.forwardRef(
|
|
|
1115
1184
|
),
|
|
1116
1185
|
"aria-label": "Message",
|
|
1117
1186
|
"aria-describedby": showCharacterCount ? "char-count" : void 0,
|
|
1118
|
-
...
|
|
1119
|
-
"aria-controls": mentionMenuOpen ? mentionListId : void 0,
|
|
1120
|
-
"aria-activedescendant": activeMentionOptionId,
|
|
1121
|
-
"aria-autocomplete": "list"
|
|
1122
|
-
} : {}
|
|
1187
|
+
...mention.inputProps
|
|
1123
1188
|
}
|
|
1124
1189
|
),
|
|
1125
1190
|
inputTrailing && /* @__PURE__ */ jsxRuntime.jsx(
|
|
1126
1191
|
"div",
|
|
1127
1192
|
{
|
|
1128
1193
|
"data-slot": "composer-input-trailing",
|
|
1129
|
-
className: "pointer-events-none absolute top-0
|
|
1194
|
+
className: "pointer-events-none absolute end-1 top-0 flex h-[44px] items-center [&>*]:pointer-events-auto",
|
|
1130
1195
|
children: inputTrailing
|
|
1131
1196
|
}
|
|
1132
1197
|
),
|
|
@@ -1135,7 +1200,7 @@ var MessageComposer = React2__namespace.forwardRef(
|
|
|
1135
1200
|
{
|
|
1136
1201
|
"data-slot": "composer-char-count",
|
|
1137
1202
|
id: "char-count",
|
|
1138
|
-
className: "absolute
|
|
1203
|
+
className: "absolute end-3 bottom-1.5",
|
|
1139
1204
|
children: /* @__PURE__ */ jsxRuntime.jsx(CharacterCounter, { current: content.length, max: maxLength })
|
|
1140
1205
|
}
|
|
1141
1206
|
)
|
|
@@ -1167,11 +1232,13 @@ exports.AttachmentPreviewItem = AttachmentPreviewItem;
|
|
|
1167
1232
|
exports.CameraButton = CameraButton;
|
|
1168
1233
|
exports.CharacterCounter = CharacterCounter;
|
|
1169
1234
|
exports.DragDropZone = DragDropZone;
|
|
1235
|
+
exports.MentionMenu = MentionMenu;
|
|
1170
1236
|
exports.MessageComposer = MessageComposer;
|
|
1171
1237
|
exports.SendButton = SendButton;
|
|
1172
1238
|
exports.generateAttachmentId = generateAttachmentId;
|
|
1173
1239
|
exports.getFileType = getFileType;
|
|
1174
1240
|
exports.sendButtonVariants = sendButtonVariants;
|
|
1241
|
+
exports.useMentionAutocomplete = useMentionAutocomplete;
|
|
1175
1242
|
exports.validateFile = validateFile;
|
|
1176
|
-
//# sourceMappingURL=chunk-
|
|
1177
|
-
//# sourceMappingURL=chunk-
|
|
1243
|
+
//# sourceMappingURL=chunk-5BVFVXHN.cjs.map
|
|
1244
|
+
//# sourceMappingURL=chunk-5BVFVXHN.cjs.map
|