@arbidocs/blocks 0.4.158 → 0.4.159
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ConnectedNativeDocxComparison-64RDIFEI.cjs → ConnectedNativeDocxComparison-R6RU5TZE.cjs} +12 -11
- package/dist/{ConnectedNativeDocxComparison-64RDIFEI.cjs.map → ConnectedNativeDocxComparison-R6RU5TZE.cjs.map} +1 -1
- package/dist/{ConnectedStreamedWordArtifact-GYBCBAJZ.js → ConnectedNativeDocxComparison-XMZ5KLD4.js} +11 -10
- package/dist/{ConnectedStreamedWordArtifact-GYBCBAJZ.js.map → ConnectedNativeDocxComparison-XMZ5KLD4.js.map} +1 -1
- package/dist/{ConnectedNativeDocxEditor-UAAICR4X.cjs → ConnectedNativeDocxEditor-LBATSM3M.cjs} +11 -10
- package/dist/{ConnectedNativeDocxEditor-UAAICR4X.cjs.map → ConnectedNativeDocxEditor-LBATSM3M.cjs.map} +1 -1
- package/dist/{ConnectedNativeDocxEditor-OT5DLWCM.js → ConnectedNativeDocxEditor-NGUK2AX6.js} +9 -8
- package/dist/{ConnectedNativeDocxEditor-OT5DLWCM.js.map → ConnectedNativeDocxEditor-NGUK2AX6.js.map} +1 -1
- package/dist/{ConnectedStreamedWordArtifact-AJXPNTT3.cjs → ConnectedStreamedWordArtifact-CWFR6A37.cjs} +12 -11
- package/dist/ConnectedStreamedWordArtifact-CWFR6A37.cjs.map +1 -0
- package/dist/{ConnectedNativeDocxComparison-JOWYEINS.js → ConnectedStreamedWordArtifact-IXRJ7MUE.js} +11 -10
- package/dist/{ConnectedNativeDocxComparison-JOWYEINS.js.map → ConnectedStreamedWordArtifact-IXRJ7MUE.js.map} +1 -1
- package/dist/{NativeDocxEditor-M3I776GD.cjs → NativeDocxEditor-T2PJIZMU.cjs} +9 -7
- package/dist/{NativeDocxEditor-M3I776GD.cjs.map → NativeDocxEditor-T2PJIZMU.cjs.map} +1 -1
- package/dist/{NativeDocxEditor-JBQMH3MP.js → NativeDocxEditor-TBTBD6TC.js} +5 -3
- package/dist/{NativeDocxEditor-JBQMH3MP.js.map → NativeDocxEditor-TBTBD6TC.js.map} +1 -1
- package/dist/{WorkspaceTableView-FQPJQWUE.js → WorkspaceTableView-DWUE4VQF.js} +7 -6
- package/dist/WorkspaceTableView-DWUE4VQF.js.map +1 -0
- package/dist/{WorkspaceTableView-CZEFIAVT.cjs → WorkspaceTableView-EYLEUZZT.cjs} +9 -8
- package/dist/WorkspaceTableView-EYLEUZZT.cjs.map +1 -0
- package/dist/agents/index.cjs +241 -241
- package/dist/agents/index.js +7 -7
- package/dist/calls/index.cjs +3 -3
- package/dist/calls/index.js +2 -2
- package/dist/chat/index.cjs +1 -1
- package/dist/chat/index.js +1 -1
- package/dist/{chunk-RJUXSXBH.cjs → chunk-2BHDRVVL.cjs} +18 -8
- package/dist/chunk-2BHDRVVL.cjs.map +1 -0
- package/dist/chunk-2R3GGNPA.js +151 -0
- package/dist/chunk-2R3GGNPA.js.map +1 -0
- package/dist/{chunk-Y7PPQ7UT.js → chunk-3OCNUKGX.js} +4 -4
- package/dist/{chunk-Y7PPQ7UT.js.map → chunk-3OCNUKGX.js.map} +1 -1
- package/dist/{chunk-D3WFIFRY.cjs → chunk-3VW7ZXQ6.cjs} +211 -5
- package/dist/chunk-3VW7ZXQ6.cjs.map +1 -0
- package/dist/{chunk-JSQEAPTC.cjs → chunk-4GITK3Q5.cjs} +398 -75
- package/dist/chunk-4GITK3Q5.cjs.map +1 -0
- package/dist/{chunk-7KWUQQIB.js → chunk-5ZIYPZYE.js} +3 -3
- package/dist/{chunk-7KWUQQIB.js.map → chunk-5ZIYPZYE.js.map} +1 -1
- package/dist/{chunk-AUDUNQO6.cjs → chunk-6QAAIDQQ.cjs} +50 -50
- package/dist/{chunk-AUDUNQO6.cjs.map → chunk-6QAAIDQQ.cjs.map} +1 -1
- package/dist/{chunk-V3HG3LK3.js → chunk-7UENVUA6.js} +4 -4
- package/dist/{chunk-V3HG3LK3.js.map → chunk-7UENVUA6.js.map} +1 -1
- package/dist/{chunk-EWCJXUBP.js → chunk-AVXRXPII.js} +3 -3
- package/dist/{chunk-EWCJXUBP.js.map → chunk-AVXRXPII.js.map} +1 -1
- package/dist/{chunk-TAWPVD6C.cjs → chunk-B3FMUFAW.cjs} +3 -3
- package/dist/{chunk-TAWPVD6C.cjs.map → chunk-B3FMUFAW.cjs.map} +1 -1
- package/dist/{chunk-7IRSCMNK.js → chunk-BGXWPVHR.js} +3 -3
- package/dist/{chunk-7IRSCMNK.js.map → chunk-BGXWPVHR.js.map} +1 -1
- package/dist/chunk-DAN7EJ4O.js +482 -0
- package/dist/chunk-DAN7EJ4O.js.map +1 -0
- package/dist/{chunk-ZAVEMQ37.cjs → chunk-DWZXSPMB.cjs} +3 -3
- package/dist/{chunk-ZAVEMQ37.cjs.map → chunk-DWZXSPMB.cjs.map} +1 -1
- package/dist/chunk-E4H5H2C3.cjs +18 -0
- package/dist/{chunk-DVIQWBDM.cjs.map → chunk-E4H5H2C3.cjs.map} +1 -1
- package/dist/{chunk-VY4UFXTM.cjs → chunk-ETJFC6MO.cjs} +4 -4
- package/dist/{chunk-VY4UFXTM.cjs.map → chunk-ETJFC6MO.cjs.map} +1 -1
- package/dist/{chunk-FGI3YFQH.js → chunk-FTZ45WHY.js} +4 -4
- package/dist/{chunk-FGI3YFQH.js.map → chunk-FTZ45WHY.js.map} +1 -1
- package/dist/{chunk-FBSIWJSG.cjs → chunk-GC2FSPSQ.cjs} +6 -6
- package/dist/{chunk-FBSIWJSG.cjs.map → chunk-GC2FSPSQ.cjs.map} +1 -1
- package/dist/{chunk-TQIY2SVY.cjs → chunk-GFVIFXWT.cjs} +5 -5
- package/dist/{chunk-TQIY2SVY.cjs.map → chunk-GFVIFXWT.cjs.map} +1 -1
- package/dist/chunk-JPWPR6QU.cjs +485 -0
- package/dist/chunk-JPWPR6QU.cjs.map +1 -0
- package/dist/{chunk-KQYPP72K.js → chunk-JTJCCL2E.js} +212 -9
- package/dist/chunk-JTJCCL2E.js.map +1 -0
- package/dist/{chunk-P6FMKXAB.js → chunk-KFMRBZQK.js} +16 -6
- package/dist/chunk-KFMRBZQK.js.map +1 -0
- package/dist/{chunk-VMFLWFXK.js → chunk-MNG7N6M2.js} +4 -4
- package/dist/{chunk-VMFLWFXK.js.map → chunk-MNG7N6M2.js.map} +1 -1
- package/dist/chunk-NMZI3K6R.cjs +159 -0
- package/dist/chunk-NMZI3K6R.cjs.map +1 -0
- package/dist/{chunk-UYC5BJCB.cjs → chunk-NPLGB4LI.cjs} +5 -5
- package/dist/{chunk-UYC5BJCB.cjs.map → chunk-NPLGB4LI.cjs.map} +1 -1
- package/dist/{chunk-SCK3GAE5.cjs → chunk-P2YM67Y5.cjs} +5 -5
- package/dist/{chunk-SCK3GAE5.cjs.map → chunk-P2YM67Y5.cjs.map} +1 -1
- package/dist/{chunk-VE6S6NRQ.js → chunk-P6RIBIVN.js} +4 -4
- package/dist/{chunk-VE6S6NRQ.js.map → chunk-P6RIBIVN.js.map} +1 -1
- package/dist/chunk-Q2XGM372.cjs +18 -0
- package/dist/{chunk-GWGUZ5X6.cjs.map → chunk-Q2XGM372.cjs.map} +1 -1
- package/dist/{chunk-FWIBFGUQ.cjs → chunk-QJFJ5JBF.cjs} +3 -3
- package/dist/{chunk-FWIBFGUQ.cjs.map → chunk-QJFJ5JBF.cjs.map} +1 -1
- package/dist/{chunk-2DQHFJNP.js → chunk-QKR5LWDO.js} +7 -7
- package/dist/{chunk-2DQHFJNP.js.map → chunk-QKR5LWDO.js.map} +1 -1
- package/dist/{chunk-GDRLM2EX.js → chunk-RATEAOKT.js} +3 -3
- package/dist/{chunk-GDRLM2EX.js.map → chunk-RATEAOKT.js.map} +1 -1
- package/dist/{chunk-NFI46I77.cjs → chunk-TQUYWUEE.cjs} +11 -157
- package/dist/chunk-TQUYWUEE.cjs.map +1 -0
- package/dist/{chunk-ECERC6TI.js → chunk-VHJHY7TT.js} +3 -3
- package/dist/{chunk-ECERC6TI.js.map → chunk-VHJHY7TT.js.map} +1 -1
- package/dist/{chunk-ZO7PJMCO.js → chunk-WU34CHU5.js} +3 -3
- package/dist/{chunk-ZO7PJMCO.js.map → chunk-WU34CHU5.js.map} +1 -1
- package/dist/{chunk-ONTUMV74.js → chunk-XER3JLC7.js} +398 -78
- package/dist/chunk-XER3JLC7.js.map +1 -0
- package/dist/{chunk-LY37J3AC.cjs → chunk-YF3QUHKN.cjs} +4 -4
- package/dist/{chunk-LY37J3AC.cjs.map → chunk-YF3QUHKN.cjs.map} +1 -1
- package/dist/{chunk-Y73X65FF.js → chunk-ZDOKJD44.js} +5 -144
- package/dist/chunk-ZDOKJD44.js.map +1 -0
- package/dist/collaboration/index.cjs +1 -1
- package/dist/collaboration/index.js +1 -1
- package/dist/connect/docx.cjs +15 -14
- package/dist/connect/docx.js +11 -10
- package/dist/connect/index.cjs +542 -540
- package/dist/connect/index.cjs.map +1 -1
- package/dist/connect/index.js +27 -25
- package/dist/connect/index.js.map +1 -1
- package/dist/connect/viewer.cjs +90 -69
- package/dist/connect/viewer.cjs.map +1 -1
- package/dist/connect/viewer.js +40 -19
- package/dist/connect/viewer.js.map +1 -1
- package/dist/connection/viewer/ViewerPdfPane.d.ts +7 -1
- package/dist/document-tools/AdoptSignatureDialog.d.ts +39 -4
- package/dist/document-tools/PlaceMySignatureButton.d.ts +16 -0
- package/dist/document-tools/SavedSignatureSettings.d.ts +10 -0
- package/dist/document-tools/index.cjs +38 -23
- package/dist/document-tools/index.d.ts +2 -0
- package/dist/document-tools/index.js +6 -3
- package/dist/document-tools/viewer/AnnotatedPdfViewer.d.ts +10 -1
- package/dist/document-tools/viewer/SignatureRequestEditor.d.ts +7 -4
- package/dist/document-tools/viewer/index.cjs +184 -18
- package/dist/document-tools/viewer/index.cjs.map +1 -1
- package/dist/document-tools/viewer/index.js +184 -18
- package/dist/document-tools/viewer/index.js.map +1 -1
- package/dist/docx/NativeDocxEditor.d.ts +5 -0
- package/dist/docx/index.cjs +61 -47
- package/dist/docx/index.d.ts +1 -0
- package/dist/docx/index.js +5 -3
- package/dist/docx/signatures/SignatureFields.d.ts +50 -0
- package/dist/facts/index.cjs +56 -56
- package/dist/facts/index.js +6 -6
- package/dist/files/index.cjs +239 -239
- package/dist/files/index.js +6 -6
- package/dist/home/index.cjs +2 -2
- package/dist/home/index.js +2 -2
- package/dist/index.cjs +409 -409
- package/dist/index.js +14 -14
- package/dist/retrieval/index.cjs +1 -1
- package/dist/retrieval/index.js +1 -1
- package/dist/settings/index.cjs +187 -186
- package/dist/settings/index.js +4 -3
- package/dist/shell/index.cjs +3 -3
- package/dist/shell/index.js +3 -3
- package/dist/studio/index.cjs +3 -3
- package/dist/studio/index.js +3 -3
- package/dist/workflow-canvas/index.cjs +19 -19
- package/dist/workflow-canvas/index.js +7 -7
- package/node_modules/@arbidocs/coedit/dist/commands.cjs +109 -16
- package/node_modules/@arbidocs/coedit/dist/commands.cjs.map +1 -1
- package/node_modules/@arbidocs/coedit/dist/commands.d.cts +84 -1
- package/node_modules/@arbidocs/coedit/dist/commands.d.ts +84 -1
- package/node_modules/@arbidocs/coedit/dist/commands.js +99 -17
- package/node_modules/@arbidocs/coedit/dist/commands.js.map +1 -1
- package/node_modules/@arbidocs/coedit/package.json +1 -1
- package/package.json +5 -5
- package/src/docx/styles.css +50 -0
- package/dist/ConnectedStreamedWordArtifact-AJXPNTT3.cjs.map +0 -1
- package/dist/WorkspaceTableView-CZEFIAVT.cjs.map +0 -1
- package/dist/WorkspaceTableView-FQPJQWUE.js.map +0 -1
- package/dist/chunk-6MG62I5B.cjs +0 -272
- package/dist/chunk-6MG62I5B.cjs.map +0 -1
- package/dist/chunk-D3WFIFRY.cjs.map +0 -1
- package/dist/chunk-DVIQWBDM.cjs +0 -18
- package/dist/chunk-EQB3WELX.js +0 -269
- package/dist/chunk-EQB3WELX.js.map +0 -1
- package/dist/chunk-GWGUZ5X6.cjs +0 -18
- package/dist/chunk-JSQEAPTC.cjs.map +0 -1
- package/dist/chunk-KQYPP72K.js.map +0 -1
- package/dist/chunk-NFI46I77.cjs.map +0 -1
- package/dist/chunk-ONTUMV74.js.map +0 -1
- package/dist/chunk-P6FMKXAB.js.map +0 -1
- package/dist/chunk-RJUXSXBH.cjs.map +0 -1
- package/dist/chunk-Y73X65FF.js.map +0 -1
package/dist/connect/index.cjs
CHANGED
|
@@ -1,74 +1,76 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var chunkP2YM67Y5_cjs = require('../chunk-P2YM67Y5.cjs');
|
|
5
5
|
var chunkMSFQDELO_cjs = require('../chunk-MSFQDELO.cjs');
|
|
6
6
|
var chunkJUUOJP7I_cjs = require('../chunk-JUUOJP7I.cjs');
|
|
7
7
|
var chunkOOU4QLRK_cjs = require('../chunk-OOU4QLRK.cjs');
|
|
8
8
|
var chunkOU3RGQFX_cjs = require('../chunk-OU3RGQFX.cjs');
|
|
9
9
|
require('../chunk-REH7PX3N.cjs');
|
|
10
|
-
var
|
|
11
|
-
var chunkNFI46I77_cjs = require('../chunk-NFI46I77.cjs');
|
|
10
|
+
var chunkTQUYWUEE_cjs = require('../chunk-TQUYWUEE.cjs');
|
|
12
11
|
var chunkKBO75NLM_cjs = require('../chunk-KBO75NLM.cjs');
|
|
13
|
-
var
|
|
12
|
+
var chunk2BHDRVVL_cjs = require('../chunk-2BHDRVVL.cjs');
|
|
14
13
|
var chunk6I6CVX5G_cjs = require('../chunk-6I6CVX5G.cjs');
|
|
14
|
+
var chunkQJFJ5JBF_cjs = require('../chunk-QJFJ5JBF.cjs');
|
|
15
|
+
require('../chunk-223D4727.cjs');
|
|
15
16
|
var chunkCB4TIDEX_cjs = require('../chunk-CB4TIDEX.cjs');
|
|
16
17
|
var chunkFM3IRQJW_cjs = require('../chunk-FM3IRQJW.cjs');
|
|
17
18
|
var chunkJH6JTI76_cjs = require('../chunk-JH6JTI76.cjs');
|
|
19
|
+
var chunkNMZI3K6R_cjs = require('../chunk-NMZI3K6R.cjs');
|
|
18
20
|
require('../chunk-464YPRAE.cjs');
|
|
19
|
-
require('../chunk-
|
|
20
|
-
|
|
21
|
-
var
|
|
21
|
+
require('../chunk-4GITK3Q5.cjs');
|
|
22
|
+
require('../chunk-JPWPR6QU.cjs');
|
|
23
|
+
var chunkB3FMUFAW_cjs = require('../chunk-B3FMUFAW.cjs');
|
|
22
24
|
var chunk2WLXQGWC_cjs = require('../chunk-2WLXQGWC.cjs');
|
|
23
|
-
require('../chunk-
|
|
24
|
-
var
|
|
25
|
+
var chunk5FYU7ZIU_cjs = require('../chunk-5FYU7ZIU.cjs');
|
|
26
|
+
var chunkGC2FSPSQ_cjs = require('../chunk-GC2FSPSQ.cjs');
|
|
25
27
|
var chunkXAJIKT6Y_cjs = require('../chunk-XAJIKT6Y.cjs');
|
|
26
28
|
var chunkGOWXP5KT_cjs = require('../chunk-GOWXP5KT.cjs');
|
|
27
|
-
var chunk4RPBUMHB_cjs = require('../chunk-4RPBUMHB.cjs');
|
|
28
29
|
var chunkQZTNTP75_cjs = require('../chunk-QZTNTP75.cjs');
|
|
29
30
|
require('../chunk-PCB2BPN3.cjs');
|
|
30
31
|
require('../chunk-NWNVWO6L.cjs');
|
|
31
|
-
var chunkVPPX5XUF_cjs = require('../chunk-VPPX5XUF.cjs');
|
|
32
32
|
var chunkCROGFB46_cjs = require('../chunk-CROGFB46.cjs');
|
|
33
33
|
require('../chunk-7G2LJMUG.cjs');
|
|
34
|
+
require('../chunk-FAXXN7KI.cjs');
|
|
34
35
|
var chunkV46W7YLI_cjs = require('../chunk-V46W7YLI.cjs');
|
|
35
36
|
var chunkLJJJ6CYH_cjs = require('../chunk-LJJJ6CYH.cjs');
|
|
36
37
|
require('../chunk-D54JXTPG.cjs');
|
|
37
38
|
var chunkQT3A4PFC_cjs = require('../chunk-QT3A4PFC.cjs');
|
|
39
|
+
var chunk4RPBUMHB_cjs = require('../chunk-4RPBUMHB.cjs');
|
|
40
|
+
var chunkVPPX5XUF_cjs = require('../chunk-VPPX5XUF.cjs');
|
|
38
41
|
var chunkRC25WMVB_cjs = require('../chunk-RC25WMVB.cjs');
|
|
39
|
-
require('../chunk-
|
|
40
|
-
var chunkLY37J3AC_cjs = require('../chunk-LY37J3AC.cjs');
|
|
42
|
+
var chunkYF3QUHKN_cjs = require('../chunk-YF3QUHKN.cjs');
|
|
41
43
|
var chunkRFIBUWLF_cjs = require('../chunk-RFIBUWLF.cjs');
|
|
42
44
|
var chunkYBJ4QGNH_cjs = require('../chunk-YBJ4QGNH.cjs');
|
|
43
45
|
var chunkOALEDG67_cjs = require('../chunk-OALEDG67.cjs');
|
|
44
46
|
var chunk2VHYOTWW_cjs = require('../chunk-2VHYOTWW.cjs');
|
|
45
47
|
require('../chunk-ZW6FPIFC.cjs');
|
|
46
|
-
require('../chunk-AHDJXIUB.cjs');
|
|
47
48
|
require('../chunk-SIB6C7P7.cjs');
|
|
48
49
|
require('../chunk-DVUZTGVL.cjs');
|
|
50
|
+
require('../chunk-AHDJXIUB.cjs');
|
|
51
|
+
require('../chunk-3VULDTNL.cjs');
|
|
49
52
|
var chunkV4ISCZJ7_cjs = require('../chunk-V4ISCZJ7.cjs');
|
|
50
53
|
var chunk2EI7NCUA_cjs = require('../chunk-2EI7NCUA.cjs');
|
|
51
|
-
require('../chunk-3VULDTNL.cjs');
|
|
52
54
|
var chunkC2CWWEHO_cjs = require('../chunk-C2CWWEHO.cjs');
|
|
53
55
|
var chunkQVBZESYQ_cjs = require('../chunk-QVBZESYQ.cjs');
|
|
54
56
|
require('../chunk-ADOKTJHV.cjs');
|
|
55
|
-
var chunkZAVEMQ37_cjs = require('../chunk-ZAVEMQ37.cjs');
|
|
56
|
-
var chunk7RGLTF76_cjs = require('../chunk-7RGLTF76.cjs');
|
|
57
57
|
var chunkLLYZGH3L_cjs = require('../chunk-LLYZGH3L.cjs');
|
|
58
58
|
var chunkBIXHB4LV_cjs = require('../chunk-BIXHB4LV.cjs');
|
|
59
|
-
var
|
|
60
|
-
var
|
|
61
|
-
var chunkULWRNGGE_cjs = require('../chunk-ULWRNGGE.cjs');
|
|
59
|
+
var chunkDWZXSPMB_cjs = require('../chunk-DWZXSPMB.cjs');
|
|
60
|
+
var chunk7RGLTF76_cjs = require('../chunk-7RGLTF76.cjs');
|
|
62
61
|
var chunk5A2QQAF5_cjs = require('../chunk-5A2QQAF5.cjs');
|
|
63
62
|
require('../chunk-B6MVQCXW.cjs');
|
|
64
63
|
var chunkJKB7WT7L_cjs = require('../chunk-JKB7WT7L.cjs');
|
|
65
64
|
var chunkJSTKEZBS_cjs = require('../chunk-JSTKEZBS.cjs');
|
|
66
65
|
require('../chunk-76L6LOP3.cjs');
|
|
67
|
-
require('../chunk-7UTB4PHM.cjs');
|
|
68
66
|
require('../chunk-32HW2Q33.cjs');
|
|
67
|
+
require('../chunk-7UTB4PHM.cjs');
|
|
69
68
|
var chunkFX3K6LNZ_cjs = require('../chunk-FX3K6LNZ.cjs');
|
|
70
69
|
require('../chunk-PPCATBOY.cjs');
|
|
71
70
|
require('../chunk-MHVNT4J3.cjs');
|
|
71
|
+
var chunkQ7CQYYZW_cjs = require('../chunk-Q7CQYYZW.cjs');
|
|
72
|
+
var chunkCNHUJRQ4_cjs = require('../chunk-CNHUJRQ4.cjs');
|
|
73
|
+
var chunkULWRNGGE_cjs = require('../chunk-ULWRNGGE.cjs');
|
|
72
74
|
var chunkKDG6FER6_cjs = require('../chunk-KDG6FER6.cjs');
|
|
73
75
|
require('../chunk-DES3K4SD.cjs');
|
|
74
76
|
var react = require('react');
|
|
@@ -164,7 +166,7 @@ function ConnectedWorkspaceActivity({
|
|
|
164
166
|
[feed.data]
|
|
165
167
|
);
|
|
166
168
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
167
|
-
|
|
169
|
+
chunkGC2FSPSQ_cjs.WorkspaceActivityList,
|
|
168
170
|
{
|
|
169
171
|
...listProps,
|
|
170
172
|
items,
|
|
@@ -592,7 +594,7 @@ function NotificationCenter({
|
|
|
592
594
|
}
|
|
593
595
|
];
|
|
594
596
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col h-full bg-background", "data-testid": "notifications-page", children: [
|
|
595
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
597
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.DraggableHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
596
598
|
chunk7RGLTF76_cjs.TabHeader,
|
|
597
599
|
{
|
|
598
600
|
tabs,
|
|
@@ -842,7 +844,7 @@ function ConnectedWorkspaceNotificationMenu({
|
|
|
842
844
|
}, [error, notify14]);
|
|
843
845
|
if (!workspaceId) return null;
|
|
844
846
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
845
|
-
|
|
847
|
+
chunkGC2FSPSQ_cjs.WorkspaceNotificationMenu,
|
|
846
848
|
{
|
|
847
849
|
...menuProps,
|
|
848
850
|
level,
|
|
@@ -861,7 +863,7 @@ function ConnectedThreadFollow({
|
|
|
861
863
|
enabled: live
|
|
862
864
|
});
|
|
863
865
|
if (!conversationId) return null;
|
|
864
|
-
const Control = as === "menu-item" ?
|
|
866
|
+
const Control = as === "menu-item" ? chunkGC2FSPSQ_cjs.ThreadFollowMenuItem : chunkGC2FSPSQ_cjs.ThreadFollowButton;
|
|
865
867
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
866
868
|
Control,
|
|
867
869
|
{
|
|
@@ -934,7 +936,7 @@ function ConnectedSkillUpload({ onDone, labels, className }) {
|
|
|
934
936
|
onChange: (e) => {
|
|
935
937
|
const file = e.target.files?.[0];
|
|
936
938
|
e.target.value = "";
|
|
937
|
-
if (file) void add(() =>
|
|
939
|
+
if (file) void add(() => chunkYF3QUHKN_cjs.importSkillFile(file));
|
|
938
940
|
}
|
|
939
941
|
}
|
|
940
942
|
),
|
|
@@ -959,7 +961,7 @@ function ConnectedSkillUpload({ onDone, labels, className }) {
|
|
|
959
961
|
className: "space-y-2",
|
|
960
962
|
onSubmit: (e) => {
|
|
961
963
|
e.preventDefault();
|
|
962
|
-
if (url.trim()) void add(() =>
|
|
964
|
+
if (url.trim()) void add(() => chunkYF3QUHKN_cjs.importSkillFromUrl(url));
|
|
963
965
|
},
|
|
964
966
|
children: [
|
|
965
967
|
/* @__PURE__ */ jsxRuntime.jsx(ui.Label, { htmlFor: "skills-add-url", children: l.fromLink }),
|
|
@@ -1023,9 +1025,9 @@ function ConnectedSkillsLibrary({
|
|
|
1023
1025
|
const [type, setType] = react.useState("all");
|
|
1024
1026
|
const [view, setView] = react.useState("gallery");
|
|
1025
1027
|
const [isBusy, setIsBusy] = react.useState(false);
|
|
1026
|
-
const all = react.useMemo(() =>
|
|
1028
|
+
const all = react.useMemo(() => chunkYF3QUHKN_cjs.buildLibrarySkills(builtins, listings ?? []), [builtins, listings]);
|
|
1027
1029
|
const shown = react.useMemo(
|
|
1028
|
-
() =>
|
|
1030
|
+
() => chunkYF3QUHKN_cjs.filterLibrarySkills(all, { query, source, type }),
|
|
1029
1031
|
[all, query, source, type]
|
|
1030
1032
|
);
|
|
1031
1033
|
const current = all.find((s) => s.slug === selected) ?? null;
|
|
@@ -1036,21 +1038,21 @@ function ConnectedSkillsLibrary({
|
|
|
1036
1038
|
const count = (s) => all.filter((x) => x.source === s).length;
|
|
1037
1039
|
const sourceOptions = [
|
|
1038
1040
|
{ id: "all", label: "All", count: all.length },
|
|
1039
|
-
{ id: "builtin", label:
|
|
1040
|
-
{ id: "mine", label:
|
|
1041
|
-
{ id: "shared", label:
|
|
1041
|
+
{ id: "builtin", label: chunkYF3QUHKN_cjs.SKILL_SOURCE_LABELS.builtin, count: count("builtin") },
|
|
1042
|
+
{ id: "mine", label: chunkYF3QUHKN_cjs.SKILL_SOURCE_LABELS.mine, count: count("mine") },
|
|
1043
|
+
{ id: "shared", label: chunkYF3QUHKN_cjs.SKILL_SOURCE_LABELS.shared, count: count("shared") }
|
|
1042
1044
|
];
|
|
1043
1045
|
const types = [...new Set(all.map((s) => s.type))];
|
|
1044
1046
|
const typeOptions = [
|
|
1045
1047
|
{ id: "all", label: "Any kind" },
|
|
1046
|
-
...types.map((t) => ({ id: t, label:
|
|
1048
|
+
...types.map((t) => ({ id: t, label: chunkYF3QUHKN_cjs.SKILL_TYPE_LABELS[t] ?? t }))
|
|
1047
1049
|
];
|
|
1048
1050
|
const pick = (slug) => {
|
|
1049
1051
|
setSelected(slug);
|
|
1050
1052
|
setMode("detail");
|
|
1051
1053
|
};
|
|
1052
1054
|
const markdownOf = async (skill) => {
|
|
1053
|
-
if (!skill.docExtId) return
|
|
1055
|
+
if (!skill.docExtId) return chunkYF3QUHKN_cjs.workflowToSkillMarkdown(skill.workflow);
|
|
1054
1056
|
const response = await arbi.documents.download(skill.docExtId);
|
|
1055
1057
|
if (!response.ok) throw new Error(`Could not read the skill (${response.status})`);
|
|
1056
1058
|
return response.text();
|
|
@@ -1058,7 +1060,7 @@ function ConnectedSkillsLibrary({
|
|
|
1058
1060
|
const saveAs = (slug, markdown, shared = false) => upload.mutateAsync([
|
|
1059
1061
|
{
|
|
1060
1062
|
folder: `${SKILL_FOLDER}${slug}`,
|
|
1061
|
-
fileName:
|
|
1063
|
+
fileName: chunkYF3QUHKN_cjs.SKILL_MAIN_FILENAME,
|
|
1062
1064
|
content: new Blob([markdown], { type: "text/markdown" }),
|
|
1063
1065
|
shared
|
|
1064
1066
|
}
|
|
@@ -1121,7 +1123,7 @@ function ConnectedSkillsLibrary({
|
|
|
1121
1123
|
try {
|
|
1122
1124
|
documentTools.downloadBlob(
|
|
1123
1125
|
new Blob([await markdownOf(skill)], { type: "text/markdown" }),
|
|
1124
|
-
|
|
1126
|
+
chunkYF3QUHKN_cjs.SKILL_MAIN_FILENAME
|
|
1125
1127
|
);
|
|
1126
1128
|
} catch (error) {
|
|
1127
1129
|
notify14(errorText(error, "Could not export the skill"), "error");
|
|
@@ -1162,10 +1164,10 @@ function ConnectedSkillsLibrary({
|
|
|
1162
1164
|
}
|
|
1163
1165
|
)
|
|
1164
1166
|
] }),
|
|
1165
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1167
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkYF3QUHKN_cjs.SkillViewToggle, { value: view, onChange: setView })
|
|
1166
1168
|
] }),
|
|
1167
1169
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1168
|
-
|
|
1170
|
+
chunkYF3QUHKN_cjs.SkillFilterChips,
|
|
1169
1171
|
{
|
|
1170
1172
|
label: "Show",
|
|
1171
1173
|
value: source,
|
|
@@ -1174,7 +1176,7 @@ function ConnectedSkillsLibrary({
|
|
|
1174
1176
|
}
|
|
1175
1177
|
),
|
|
1176
1178
|
types.length > 1 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
1177
|
-
|
|
1179
|
+
chunkYF3QUHKN_cjs.SkillFilterChips,
|
|
1178
1180
|
{
|
|
1179
1181
|
label: "Kind",
|
|
1180
1182
|
value: type,
|
|
@@ -1221,12 +1223,12 @@ function ConnectedSkillsLibrary({
|
|
|
1221
1223
|
view === "gallery" ? "grid grid-cols-[repeat(auto-fill,minmax(9.5rem,1fr))]" : "flex flex-col"
|
|
1222
1224
|
),
|
|
1223
1225
|
children: shown.map((skill) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1224
|
-
|
|
1226
|
+
chunkYF3QUHKN_cjs.SkillTile,
|
|
1225
1227
|
{
|
|
1226
1228
|
name: skill.title,
|
|
1227
1229
|
testId: `skill-tile-${skill.slug}`,
|
|
1228
1230
|
description: skill.description,
|
|
1229
|
-
sourceLabel: skill.isShared ? `${
|
|
1231
|
+
sourceLabel: skill.isShared ? `${chunkYF3QUHKN_cjs.SKILL_SOURCE_LABELS.mine}, shared` : chunkYF3QUHKN_cjs.SKILL_SOURCE_LABELS[skill.source],
|
|
1230
1232
|
type: skill.type,
|
|
1231
1233
|
icon,
|
|
1232
1234
|
layout: view,
|
|
@@ -1261,7 +1263,7 @@ function ConnectedSkillsLibrary({
|
|
|
1261
1263
|
}
|
|
1262
1264
|
),
|
|
1263
1265
|
mode === "new" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
1264
|
-
|
|
1266
|
+
chunkYF3QUHKN_cjs.SkillGenerateForm,
|
|
1265
1267
|
{
|
|
1266
1268
|
icon,
|
|
1267
1269
|
onGenerate: (desc) => {
|
|
@@ -1288,11 +1290,11 @@ function ConnectedSkillsLibrary({
|
|
|
1288
1290
|
),
|
|
1289
1291
|
mode === "add" && /* @__PURE__ */ jsxRuntime.jsx(ConnectedSkillUpload, { onDone: done }),
|
|
1290
1292
|
mode === "detail" && current && /* @__PURE__ */ jsxRuntime.jsx(
|
|
1291
|
-
|
|
1293
|
+
chunkYF3QUHKN_cjs.SkillLibraryDetail,
|
|
1292
1294
|
{
|
|
1293
1295
|
skill: current,
|
|
1294
1296
|
icon,
|
|
1295
|
-
instructions: current.docExtId ? currentText ?
|
|
1297
|
+
instructions: current.docExtId ? currentText ? chunkYF3QUHKN_cjs.parseSkillFrontmatter(currentText, chunkYF3QUHKN_cjs.SKILL_MAIN_FILENAME).content : "" : current.workflow.run.kind === "prompt" ? current.workflow.run.promptTemplate : "",
|
|
1296
1298
|
isLoading: !!current.docExtId && textLoading,
|
|
1297
1299
|
actions: {
|
|
1298
1300
|
onRun: () => onRun(current.slug),
|
|
@@ -1327,7 +1329,7 @@ function SkillEditor({
|
|
|
1327
1329
|
const [seeded, setSeeded] = react.useState(!isEditing);
|
|
1328
1330
|
const [nameError, setNameError] = react.useState(null);
|
|
1329
1331
|
if (isEditing && !seeded && text !== void 0) {
|
|
1330
|
-
const parsed =
|
|
1332
|
+
const parsed = chunkYF3QUHKN_cjs.parseSkillFrontmatter(text, chunkYF3QUHKN_cjs.SKILL_MAIN_FILENAME);
|
|
1331
1333
|
setDescription(parsed.description ?? "");
|
|
1332
1334
|
setBody(parsed.content ?? "");
|
|
1333
1335
|
setSeeded(true);
|
|
@@ -1341,15 +1343,15 @@ function SkillEditor({
|
|
|
1341
1343
|
notify14("Add a short description.", "error");
|
|
1342
1344
|
return;
|
|
1343
1345
|
}
|
|
1344
|
-
const slug =
|
|
1346
|
+
const slug = chunkYF3QUHKN_cjs.skillSlug(name);
|
|
1345
1347
|
try {
|
|
1346
|
-
await onSave(slug,
|
|
1348
|
+
await onSave(slug, chunkYF3QUHKN_cjs.serializeSkill({ name: slug, description, body }), isEditing);
|
|
1347
1349
|
} catch (err) {
|
|
1348
1350
|
notify14(errorText(err, "Could not save the skill"), "error");
|
|
1349
1351
|
}
|
|
1350
1352
|
};
|
|
1351
1353
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1352
|
-
|
|
1354
|
+
chunkYF3QUHKN_cjs.SkillEditForm,
|
|
1353
1355
|
{
|
|
1354
1356
|
name,
|
|
1355
1357
|
onNameChange: setName,
|
|
@@ -1385,9 +1387,9 @@ function ConnectedAgentCreator({
|
|
|
1385
1387
|
agent,
|
|
1386
1388
|
initialName,
|
|
1387
1389
|
onSaved,
|
|
1388
|
-
capabilities =
|
|
1389
|
-
templates =
|
|
1390
|
-
types =
|
|
1390
|
+
capabilities = chunkYF3QUHKN_cjs.DEFAULT_AGENT_CAPABILITIES,
|
|
1391
|
+
templates = chunkYF3QUHKN_cjs.DEFAULT_AGENT_TEMPLATES,
|
|
1392
|
+
types = chunkYF3QUHKN_cjs.DEFAULT_AGENT_TYPES,
|
|
1391
1393
|
canRevokeWorkspaces = false,
|
|
1392
1394
|
labels
|
|
1393
1395
|
}) {
|
|
@@ -1429,7 +1431,7 @@ function ConnectedAgentCreator({
|
|
|
1429
1431
|
const initialValues = react.useMemo(
|
|
1430
1432
|
() => ({
|
|
1431
1433
|
name: agent?.given_name ?? initialName ?? "",
|
|
1432
|
-
persona: isEdit ?
|
|
1434
|
+
persona: isEdit ? chunkYF3QUHKN_cjs.stripPersonaPreamble(String(agents.PERSONA ?? "")) : "",
|
|
1433
1435
|
modelName: String(agents.AGENT_MODEL_NAME ?? ""),
|
|
1434
1436
|
capabilities: Object.fromEntries(capabilities.map(({ key }) => [key, Boolean(agents[key])])),
|
|
1435
1437
|
type: "builtin",
|
|
@@ -1448,7 +1450,7 @@ function ConnectedAgentCreator({
|
|
|
1448
1450
|
try {
|
|
1449
1451
|
let agentExtId = agent?.external_id ?? early?.id ?? "";
|
|
1450
1452
|
if (!agentExtId) {
|
|
1451
|
-
if (!
|
|
1453
|
+
if (!chunkYF3QUHKN_cjs.isValidAgentName(values.name)) {
|
|
1452
1454
|
notify14("Give the agent a name first.", "error");
|
|
1453
1455
|
return;
|
|
1454
1456
|
}
|
|
@@ -1484,7 +1486,7 @@ function ConnectedAgentCreator({
|
|
|
1484
1486
|
title: `agent-${name}`,
|
|
1485
1487
|
sections: {
|
|
1486
1488
|
Agents: {
|
|
1487
|
-
PERSONA:
|
|
1489
|
+
PERSONA: chunkYF3QUHKN_cjs.composePersona(name, values.persona),
|
|
1488
1490
|
...values.modelName ? { AGENT_MODEL_NAME: values.modelName } : {},
|
|
1489
1491
|
...Object.fromEntries(capabilities.map(({ key }) => [key, !!values.capabilities[key]])),
|
|
1490
1492
|
ENABLED_SKILLS: values.capabilities.SKILLS_ENABLED && skills.length ? skills : null,
|
|
@@ -1507,7 +1509,7 @@ function ConnectedAgentCreator({
|
|
|
1507
1509
|
};
|
|
1508
1510
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
1509
1511
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1510
|
-
|
|
1512
|
+
chunkYF3QUHKN_cjs.AgentCreator,
|
|
1511
1513
|
{
|
|
1512
1514
|
open: ready,
|
|
1513
1515
|
onOpenChange,
|
|
@@ -1523,11 +1525,11 @@ function ConnectedAgentCreator({
|
|
|
1523
1525
|
) : void 0,
|
|
1524
1526
|
revokingWorkspaceId: revokeAccess.isPending ? revokeAccess.variables?.workspaceId : void 0,
|
|
1525
1527
|
avatar: (values) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1526
|
-
|
|
1528
|
+
chunkYF3QUHKN_cjs.AgentAvatarField,
|
|
1527
1529
|
{
|
|
1528
1530
|
picture,
|
|
1529
1531
|
isBusy: avatarBusy,
|
|
1530
|
-
canGenerate: isEdit ||
|
|
1532
|
+
canGenerate: isEdit || chunkYF3QUHKN_cjs.isValidAgentName(values.name),
|
|
1531
1533
|
onGenerate: () => handleGenerateAvatar(values)
|
|
1532
1534
|
}
|
|
1533
1535
|
),
|
|
@@ -1579,7 +1581,7 @@ function ConnectedAgentCreator({
|
|
|
1579
1581
|
/* @__PURE__ */ jsxRuntime.jsx(ui.DialogTitle, { children: "Connect your agent" }),
|
|
1580
1582
|
/* @__PURE__ */ jsxRuntime.jsx(ui.DialogDescription, { children: "This key is shown once. Run the script on the machine that will host the agent." })
|
|
1581
1583
|
] }),
|
|
1582
|
-
connect && /* @__PURE__ */ jsxRuntime.jsx(
|
|
1584
|
+
connect && /* @__PURE__ */ jsxRuntime.jsx(chunkYF3QUHKN_cjs.AgentConnectInstructions, { email: connect.email, signingKey: connect.signingKey })
|
|
1583
1585
|
]
|
|
1584
1586
|
}
|
|
1585
1587
|
) })
|
|
@@ -1616,7 +1618,7 @@ function ConnectedWorkflowHistory({
|
|
|
1616
1618
|
const { openConversation } = chunkCNHUJRQ4_cjs.useBlocksEnvironment();
|
|
1617
1619
|
const { data: runs = [], isLoading } = react$1.useWorkflowRuns(workflow?.external_id);
|
|
1618
1620
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1619
|
-
|
|
1621
|
+
chunkYF3QUHKN_cjs.TaskRunsDialog,
|
|
1620
1622
|
{
|
|
1621
1623
|
inline,
|
|
1622
1624
|
hideHeader,
|
|
@@ -1652,7 +1654,7 @@ function ConnectedTaskActivityDialog({
|
|
|
1652
1654
|
const activity = react$1.useConversationActivity(conversationId, { live });
|
|
1653
1655
|
const { data: agents = [] } = react$1.useAgents();
|
|
1654
1656
|
const { userId } = chunkFM3IRQJW_cjs.useConnectedWorkspace();
|
|
1655
|
-
const { members } =
|
|
1657
|
+
const { members } = chunk2BHDRVVL_cjs.useConnectedWorkspaceRole();
|
|
1656
1658
|
const renderPerson = react.useCallback(
|
|
1657
1659
|
(id) => {
|
|
1658
1660
|
const isMe = !!id && id === userId;
|
|
@@ -1668,7 +1670,7 @@ function ConnectedTaskActivityDialog({
|
|
|
1668
1670
|
[agents]
|
|
1669
1671
|
);
|
|
1670
1672
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1671
|
-
|
|
1673
|
+
chunkYF3QUHKN_cjs.TaskActivityDialog,
|
|
1672
1674
|
{
|
|
1673
1675
|
open: true,
|
|
1674
1676
|
onOpenChange: (open) => !open && onClose(),
|
|
@@ -1814,7 +1816,7 @@ function useWorkflowThread(workflow, options2 = {}) {
|
|
|
1814
1816
|
);
|
|
1815
1817
|
const conversation = conversations.data?.find((c) => c.external_id === threadId);
|
|
1816
1818
|
const steps = react.useMemo(
|
|
1817
|
-
() => chunkJSTKEZBS_cjs.workflowSteps(workflow).length > 0 ? chunkJSTKEZBS_cjs.workflowSteps(workflow) :
|
|
1819
|
+
() => chunkJSTKEZBS_cjs.workflowSteps(workflow).length > 0 ? chunkJSTKEZBS_cjs.workflowSteps(workflow) : chunkYF3QUHKN_cjs.fromPlanSteps(conversation?.plan?.steps ?? []),
|
|
1818
1820
|
[workflow, conversation?.plan?.steps]
|
|
1819
1821
|
);
|
|
1820
1822
|
const activity = react$1.useConversationActivity(threadId, { live: !!threadId });
|
|
@@ -1874,7 +1876,7 @@ function useWorkflowThread(workflow, options2 = {}) {
|
|
|
1874
1876
|
criteria: [],
|
|
1875
1877
|
max_passes: 3,
|
|
1876
1878
|
documents: [],
|
|
1877
|
-
steps:
|
|
1879
|
+
steps: chunkYF3QUHKN_cjs.toPlanSteps(workflow, {
|
|
1878
1880
|
inputs: values,
|
|
1879
1881
|
resolveWorkflow: options2.resolveWorkflow,
|
|
1880
1882
|
compose: options2.compose
|
|
@@ -1961,7 +1963,7 @@ function useWorkflowThread(workflow, options2 = {}) {
|
|
|
1961
1963
|
const anyRunning = Object.values(states).some((s) => s.status === "running");
|
|
1962
1964
|
const needsStart = !threadId || idle && !anyRunning;
|
|
1963
1965
|
const runError = idle ? conversation?.last_error ?? null : null;
|
|
1964
|
-
const view =
|
|
1966
|
+
const view = chunkYF3QUHKN_cjs.useWorkflowView({
|
|
1965
1967
|
steps,
|
|
1966
1968
|
states,
|
|
1967
1969
|
inputs,
|
|
@@ -2129,7 +2131,7 @@ function WorkflowWordDialog({
|
|
|
2129
2131
|
title: title ?? labels.wordTitle,
|
|
2130
2132
|
size: "xl",
|
|
2131
2133
|
testId: "workflow-word-dialog",
|
|
2132
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(chunkULWRNGGE_cjs.ModalScaffold.Body, { className: "h-[70dvh] p-0", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2134
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(chunkULWRNGGE_cjs.ModalScaffold.Body, { className: "h-[70dvh] p-0", children: /* @__PURE__ */ jsxRuntime.jsx(chunk2BHDRVVL_cjs.ConnectedNativeDocxEditor, { documentId: id, title: title ?? labels.wordTitle }) })
|
|
2133
2135
|
}
|
|
2134
2136
|
);
|
|
2135
2137
|
}
|
|
@@ -2438,7 +2440,7 @@ function ConnectedWorkflowRunner({
|
|
|
2438
2440
|
);
|
|
2439
2441
|
};
|
|
2440
2442
|
const runner = (compact) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2441
|
-
|
|
2443
|
+
chunkYF3QUHKN_cjs.WorkflowRunner,
|
|
2442
2444
|
{
|
|
2443
2445
|
people,
|
|
2444
2446
|
...runnerProps,
|
|
@@ -2484,7 +2486,7 @@ function ConnectedWorkflowRunner({
|
|
|
2484
2486
|
) }),
|
|
2485
2487
|
inThread && conversationId ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2486
2488
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2487
|
-
|
|
2489
|
+
chunkYF3QUHKN_cjs.WorkflowStepBar,
|
|
2488
2490
|
{
|
|
2489
2491
|
run: view,
|
|
2490
2492
|
levels: chunkJSTKEZBS_cjs.stepLevels(view.steps),
|
|
@@ -2655,10 +2657,10 @@ function cascadeTagCombination(tags, previous, next) {
|
|
|
2655
2657
|
function tagCombinationMatches(combination, items) {
|
|
2656
2658
|
if (!isCombining(combination)) return void 0;
|
|
2657
2659
|
const pass = (list) => new Set(
|
|
2658
|
-
|
|
2660
|
+
chunkTQUYWUEE_cjs.applyInvertedIndexFilter(
|
|
2659
2661
|
[...list],
|
|
2660
2662
|
combination,
|
|
2661
|
-
|
|
2663
|
+
chunkTQUYWUEE_cjs.buildInvertedIndex(
|
|
2662
2664
|
[...list],
|
|
2663
2665
|
(item) => item.id,
|
|
2664
2666
|
(item) => item.tagIds
|
|
@@ -2775,7 +2777,7 @@ function ConnectedTagTable({
|
|
|
2775
2777
|
const fail = (fallback) => (e) => notify14(browser.refusalReason(e, fallback), "error");
|
|
2776
2778
|
const snapshot2 = (data) => {
|
|
2777
2779
|
const title = exportTitle ?? ui.tagKindTitle(kind, { plural: true });
|
|
2778
|
-
const bytes =
|
|
2780
|
+
const bytes = chunkGC2FSPSQ_cjs.tagTableDocx(data, {
|
|
2779
2781
|
title,
|
|
2780
2782
|
nameOf: (id) => people.find((p) => p.value === id)?.label
|
|
2781
2783
|
});
|
|
@@ -2784,7 +2786,7 @@ function ConnectedTagTable({
|
|
|
2784
2786
|
return { blob: new Blob([bytes], { type: chunkQT3A4PFC_cjs.DOCX_MIME_TYPE }), name };
|
|
2785
2787
|
};
|
|
2786
2788
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2787
|
-
|
|
2789
|
+
chunkGC2FSPSQ_cjs.TagTable,
|
|
2788
2790
|
{
|
|
2789
2791
|
...props,
|
|
2790
2792
|
table,
|
|
@@ -2825,7 +2827,7 @@ function DocTagPassages({ docId, tagId, label, docOf, testId }) {
|
|
|
2825
2827
|
const [open, setOpen] = react.useState(false);
|
|
2826
2828
|
const doctag = docOf(docId)?.doctags?.find((dt) => dt.tag_ext_id === tagId);
|
|
2827
2829
|
const citations = react.useMemo(
|
|
2828
|
-
() =>
|
|
2830
|
+
() => chunkB3FMUFAW_cjs.toFactCitations(doctag?.citations) ?? [],
|
|
2829
2831
|
[doctag?.citations]
|
|
2830
2832
|
);
|
|
2831
2833
|
const { quoteFor, orderOf } = react$1.usePassageQuotes(
|
|
@@ -2834,7 +2836,7 @@ function DocTagPassages({ docId, tagId, label, docOf, testId }) {
|
|
|
2834
2836
|
const { openDocument } = chunkCNHUJRQ4_cjs.useBlocksEnvironment();
|
|
2835
2837
|
const viewingPassageId = react$1.useArbiSessionState((s) => s.viewingDocument?.passageId ?? null);
|
|
2836
2838
|
const id = testId ?? `doctag-passages-${docId}`;
|
|
2837
|
-
const refOf = (cited) =>
|
|
2839
|
+
const refOf = (cited) => chunkB3FMUFAW_cjs.citedVersionRef(cited.doc_ext_id, cited.version, docOf(cited.doc_ext_id)?.current_version);
|
|
2838
2840
|
const ordered = (cited) => [...cited.chunks].sort((a, b) => {
|
|
2839
2841
|
const oa = orderOf(a.chunk_id);
|
|
2840
2842
|
const ob = orderOf(b.chunk_id);
|
|
@@ -2865,7 +2867,7 @@ function DocTagPassages({ docId, tagId, label, docOf, testId }) {
|
|
|
2865
2867
|
const doc = docOf(cited.doc_ext_id);
|
|
2866
2868
|
const passages = ordered(cited);
|
|
2867
2869
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2868
|
-
|
|
2870
|
+
chunkB3FMUFAW_cjs.FactSourceGroup,
|
|
2869
2871
|
{
|
|
2870
2872
|
docId: cited.doc_ext_id,
|
|
2871
2873
|
hasPassages: passages.length > 0,
|
|
@@ -2922,9 +2924,9 @@ function GlossaryExport({ labelId, nameOf }) {
|
|
|
2922
2924
|
const narrowed = agreements.find((a) => a.id === narrowTo);
|
|
2923
2925
|
const title = narrowed ? `Glossary - ${narrowed.name}` : "Glossary";
|
|
2924
2926
|
const download = (format) => {
|
|
2925
|
-
const entries =
|
|
2926
|
-
const blob = format === "docx" ? new Blob([
|
|
2927
|
-
documentTools.downloadBlob(blob,
|
|
2927
|
+
const entries = chunkGC2FSPSQ_cjs.glossaryEntries(sources, { labelId: narrowed?.id });
|
|
2928
|
+
const blob = format === "docx" ? new Blob([chunkGC2FSPSQ_cjs.glossaryDocx(entries, { title })], { type: chunkQT3A4PFC_cjs.DOCX_MIME_TYPE }) : new Blob([chunkGC2FSPSQ_cjs.glossaryMarkdown(entries, { title })], { type: "text/markdown" });
|
|
2929
|
+
documentTools.downloadBlob(blob, chunkGC2FSPSQ_cjs.glossaryFileName(title, format));
|
|
2928
2930
|
};
|
|
2929
2931
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", "data-testid": "tags-glossary", children: [
|
|
2930
2932
|
agreements.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -3015,7 +3017,7 @@ function TagFilterChips({
|
|
|
3015
3017
|
const name = (id) => tags.find((t) => t.external_id === id)?.name ?? id;
|
|
3016
3018
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap items-center gap-1.5", "data-testid": "tags-filter-chips", children: [
|
|
3017
3019
|
set.map(([id, state]) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
3018
|
-
|
|
3020
|
+
chunkTQUYWUEE_cjs.FilterChip,
|
|
3019
3021
|
{
|
|
3020
3022
|
label: name(id),
|
|
3021
3023
|
state,
|
|
@@ -3143,7 +3145,7 @@ function KindSection({
|
|
|
3143
3145
|
{
|
|
3144
3146
|
testId: `tags-kind-${kind}`,
|
|
3145
3147
|
title: ui.tagKindTitle(kind, { plural: true }),
|
|
3146
|
-
description:
|
|
3148
|
+
description: chunkGC2FSPSQ_cjs.tagKindDescription(kind),
|
|
3147
3149
|
actions: picker,
|
|
3148
3150
|
children: [
|
|
3149
3151
|
browser.isEntityTag({ kind }) && extractingCount > 0 && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -3154,9 +3156,9 @@ function KindSection({
|
|
|
3154
3156
|
children: [
|
|
3155
3157
|
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Loader2, { className: "size-4 animate-spin" }),
|
|
3156
3158
|
"Extracting ",
|
|
3157
|
-
|
|
3159
|
+
chunkGC2FSPSQ_cjs.entitiesPhrase().toLowerCase(),
|
|
3158
3160
|
" from ",
|
|
3159
|
-
|
|
3161
|
+
chunkGC2FSPSQ_cjs.documentCount(extractingCount),
|
|
3160
3162
|
"\u2026"
|
|
3161
3163
|
]
|
|
3162
3164
|
}
|
|
@@ -3174,7 +3176,7 @@ function KindSection({
|
|
|
3174
3176
|
onOpenDocument: (id) => openDocument(id),
|
|
3175
3177
|
onOpenFact: ctx.onOpenFact,
|
|
3176
3178
|
onOpenThread: (id) => openConversation(id),
|
|
3177
|
-
labels:
|
|
3179
|
+
labels: chunkGC2FSPSQ_cjs.tagTableLabels(kind),
|
|
3178
3180
|
testId: `tags-table-${kind}`
|
|
3179
3181
|
}
|
|
3180
3182
|
)
|
|
@@ -3276,12 +3278,12 @@ function TagSection({
|
|
|
3276
3278
|
onOpenDocument: (id) => openDocument(id),
|
|
3277
3279
|
onOpenFact: ctx.onOpenFact,
|
|
3278
3280
|
onOpenThread: (id) => openConversation(id),
|
|
3279
|
-
labels:
|
|
3281
|
+
labels: chunkGC2FSPSQ_cjs.tagTableLabels(tag.kind),
|
|
3280
3282
|
testId: "tags-rows"
|
|
3281
3283
|
}
|
|
3282
3284
|
),
|
|
3283
3285
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3284
|
-
|
|
3286
|
+
chunkGC2FSPSQ_cjs.TagDetail,
|
|
3285
3287
|
{
|
|
3286
3288
|
row: detailRow && narrowTagRow(detailRow, ctx.filter.matches),
|
|
3287
3289
|
fields: schema.data?.fields ?? [],
|
|
@@ -3293,10 +3295,10 @@ function TagSection({
|
|
|
3293
3295
|
onOpenDocument: (id) => openDocument(id),
|
|
3294
3296
|
onOpenFact: ctx.onOpenFact,
|
|
3295
3297
|
onOpenThread: (id) => openConversation(id),
|
|
3296
|
-
noteLabel:
|
|
3298
|
+
noteLabel: chunkGC2FSPSQ_cjs.tagNoteLabel(tag.kind),
|
|
3297
3299
|
noteIsValue: tag.kind === "annotation",
|
|
3298
3300
|
renderPassages: (d, label) => renderPassages(d.doc_ext_id, label),
|
|
3299
|
-
labels:
|
|
3301
|
+
labels: chunkGC2FSPSQ_cjs.tagDetailLabels(),
|
|
3300
3302
|
testId: "tags-detail"
|
|
3301
3303
|
}
|
|
3302
3304
|
)
|
|
@@ -3385,7 +3387,7 @@ function ConnectedTagsPage({
|
|
|
3385
3387
|
const onDelete = async (t) => {
|
|
3386
3388
|
const nested = browser.getChildTags([...tags], t.external_id);
|
|
3387
3389
|
const uses = browser.tagUseCount(t);
|
|
3388
|
-
const n2 =
|
|
3390
|
+
const n2 = chunkGC2FSPSQ_cjs.tagsPageNouns();
|
|
3389
3391
|
const tagNoun = (count) => (count === 1 ? n2.tag : n2.tags).toLowerCase();
|
|
3390
3392
|
const carriers = uses === 1 ? `${n2.document}, ${n2.fact} or ${n2.thread}` : `${n2.documents}, ${n2.facts} and ${n2.threads}`;
|
|
3391
3393
|
const message = `Delete ${ui.tagKindNouns(t.kind).singular} "${t.name}"?` + (uses > 0 ? `
|
|
@@ -3406,16 +3408,16 @@ ${nested.length} nested ${tagNoun(nested.length)} ${nested.length === 1 ? "moves
|
|
|
3406
3408
|
try {
|
|
3407
3409
|
await extract.mutateAsync(docIds);
|
|
3408
3410
|
notify14(
|
|
3409
|
-
`Extracting ${
|
|
3411
|
+
`Extracting ${chunkGC2FSPSQ_cjs.entitiesPhrase().toLowerCase()} from ${chunkGC2FSPSQ_cjs.documentCount(docIds.length)}. You will be notified when it is done.`,
|
|
3410
3412
|
"info"
|
|
3411
3413
|
);
|
|
3412
3414
|
} catch (error) {
|
|
3413
|
-
notify14(browser.refusalReason(error, `Could not extract ${
|
|
3415
|
+
notify14(browser.refusalReason(error, `Could not extract ${chunkGC2FSPSQ_cjs.entitiesPhrase().toLowerCase()}`), "error");
|
|
3414
3416
|
throw error;
|
|
3415
3417
|
}
|
|
3416
3418
|
};
|
|
3417
3419
|
const picker = /* @__PURE__ */ jsxRuntime.jsx(
|
|
3418
|
-
|
|
3420
|
+
chunkGC2FSPSQ_cjs.TagPicker,
|
|
3419
3421
|
{
|
|
3420
3422
|
tags: viewTags,
|
|
3421
3423
|
selectedId: tag?.external_id,
|
|
@@ -3429,10 +3431,10 @@ ${nested.length} nested ${tagNoun(nested.length)} ${nested.length === 1 ? "moves
|
|
|
3429
3431
|
onOpenTag: openTag,
|
|
3430
3432
|
onOpenFact
|
|
3431
3433
|
};
|
|
3432
|
-
const n =
|
|
3434
|
+
const n = chunkGC2FSPSQ_cjs.tagsPageNouns();
|
|
3433
3435
|
const action = view === "person" || view === "organisation" ? {
|
|
3434
3436
|
label: "Extract",
|
|
3435
|
-
title: `Extract ${
|
|
3437
|
+
title: `Extract ${chunkGC2FSPSQ_cjs.entitiesPhrase().toLowerCase()} from ${n.documents.toLowerCase()}`,
|
|
3436
3438
|
icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Sparkles, { className: "h-4 w-4" }),
|
|
3437
3439
|
run: () => setExtracting(true),
|
|
3438
3440
|
testId: "tags-extract-entities"
|
|
@@ -3472,7 +3474,7 @@ ${nested.length} nested ${tagNoun(nested.length)} ${nested.length === 1 ? "moves
|
|
|
3472
3474
|
onTabChange: () => {
|
|
3473
3475
|
},
|
|
3474
3476
|
variant: "underline",
|
|
3475
|
-
firstTabContent: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3477
|
+
firstTabContent: /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.FilesFilterBar, { className: "flex-none", "data-testid": "tags-header-actions", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3476
3478
|
chunk2EI7NCUA_cjs.FilterInput,
|
|
3477
3479
|
{
|
|
3478
3480
|
value: filterText,
|
|
@@ -3500,7 +3502,7 @@ ${nested.length} nested ${tagNoun(nested.length)} ${nested.length === 1 ? "moves
|
|
|
3500
3502
|
)
|
|
3501
3503
|
}
|
|
3502
3504
|
) }),
|
|
3503
|
-
centerContent: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3505
|
+
centerContent: /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.FilesViewCenter, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3504
3506
|
chunk2WLXQGWC_cjs.ViewToggle,
|
|
3505
3507
|
{
|
|
3506
3508
|
options: browser.TAG_KINDS.map((k) => ({
|
|
@@ -3579,7 +3581,7 @@ ${nested.length} nested ${tagNoun(nested.length)} ${nested.length === 1 ? "moves
|
|
|
3579
3581
|
onCreated: openTag
|
|
3580
3582
|
}),
|
|
3581
3583
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3582
|
-
|
|
3584
|
+
chunkGC2FSPSQ_cjs.ExtractEntitiesDialog,
|
|
3583
3585
|
{
|
|
3584
3586
|
open: extracting,
|
|
3585
3587
|
onOpenChange: setExtracting,
|
|
@@ -3640,7 +3642,7 @@ function FactSourcesPopover({
|
|
|
3640
3642
|
reset();
|
|
3641
3643
|
}
|
|
3642
3644
|
};
|
|
3643
|
-
const refOf = (docId) =>
|
|
3645
|
+
const refOf = (docId) => chunkB3FMUFAW_cjs.citedVersionRef(
|
|
3644
3646
|
docId,
|
|
3645
3647
|
citations.find((d) => d.doc_ext_id === docId)?.version,
|
|
3646
3648
|
citedDocs?.[docId]?.current_version
|
|
@@ -3670,7 +3672,7 @@ function FactSourcesPopover({
|
|
|
3670
3672
|
const olderVersion = refOf(docId) !== docId ? refOf(docId).split("@v")[1] : null;
|
|
3671
3673
|
const cited = passagesOf(docId);
|
|
3672
3674
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
3673
|
-
|
|
3675
|
+
chunkB3FMUFAW_cjs.FactSourceGroup,
|
|
3674
3676
|
{
|
|
3675
3677
|
docId,
|
|
3676
3678
|
isViewing,
|
|
@@ -3739,8 +3741,8 @@ function FactMarkdownEditor({
|
|
|
3739
3741
|
citationContainer,
|
|
3740
3742
|
"data-testid": dataTestId
|
|
3741
3743
|
}) {
|
|
3742
|
-
const sources = react.useMemo(() =>
|
|
3743
|
-
const docIds =
|
|
3744
|
+
const sources = react.useMemo(() => chunkB3FMUFAW_cjs.toFactCitations(citations) ?? [], [citations]);
|
|
3745
|
+
const docIds = chunkB3FMUFAW_cjs.docIdsOf(sources);
|
|
3744
3746
|
const hasSources = docIds.length > 0;
|
|
3745
3747
|
const { quoteFor, orderOf } = react$1.usePassageQuotes(
|
|
3746
3748
|
react.useMemo(() => sources.filter((d) => d.chunks.length > 0).map((d) => d.doc_ext_id), [sources])
|
|
@@ -3759,7 +3761,7 @@ function FactMarkdownEditor({
|
|
|
3759
3761
|
const editorRef = react.useRef(null);
|
|
3760
3762
|
react.useEffect(() => {
|
|
3761
3763
|
if (!editorRef.current) return;
|
|
3762
|
-
return
|
|
3764
|
+
return chunkB3FMUFAW_cjs.enableFactTableColumnResize(editorRef.current);
|
|
3763
3765
|
}, []);
|
|
3764
3766
|
react.useEffect(() => {
|
|
3765
3767
|
if (!editing) return;
|
|
@@ -3774,14 +3776,14 @@ function FactMarkdownEditor({
|
|
|
3774
3776
|
return () => document.removeEventListener("pointerdown", onPointerDown, true);
|
|
3775
3777
|
}, [editing]);
|
|
3776
3778
|
const removeDoc = (docExtId) => {
|
|
3777
|
-
const remaining =
|
|
3779
|
+
const remaining = chunkB3FMUFAW_cjs.withoutDoc(sources, docExtId);
|
|
3778
3780
|
if (!remaining) setSourcesOpen(false);
|
|
3779
3781
|
onChange(value, remaining);
|
|
3780
3782
|
};
|
|
3781
3783
|
const citeDocument = (docExtId) => onCiteDocument(docExtId, { toggle: false });
|
|
3782
3784
|
const handleToggleDoc = (docExtId) => {
|
|
3783
3785
|
if (docIds.includes(docExtId)) removeDoc(docExtId);
|
|
3784
|
-
else onChange(value,
|
|
3786
|
+
else onChange(value, chunkB3FMUFAW_cjs.withDoc(sources, docExtId));
|
|
3785
3787
|
};
|
|
3786
3788
|
const expandToggle = /* @__PURE__ */ jsxRuntime.jsx(
|
|
3787
3789
|
"button",
|
|
@@ -4000,7 +4002,7 @@ function useFactComposer(notes, remove, gridApiRef, collector, composeRequested,
|
|
|
4000
4002
|
const [composing, setComposing] = react.useState(false);
|
|
4001
4003
|
const [draft, setDraft] = react.useState("");
|
|
4002
4004
|
const [baselineText, setBaselineText] = react.useState("");
|
|
4003
|
-
const [draftDateFields, setDraftDateFields] = react.useState(
|
|
4005
|
+
const [draftDateFields, setDraftDateFields] = react.useState(chunkB3FMUFAW_cjs.EMPTY_FACT_DATE_FIELDS);
|
|
4004
4006
|
const [composerError, setComposerError] = react.useState(null);
|
|
4005
4007
|
const [editingId, setEditingId] = react.useState(null);
|
|
4006
4008
|
const [draftShared, setDraftShared] = react.useState(false);
|
|
@@ -4057,9 +4059,9 @@ function useFactComposer(notes, remove, gridApiRef, collector, composeRequested,
|
|
|
4057
4059
|
if (!collector || !picked?.length || !collectingFor || !docBeingCollected) return;
|
|
4058
4060
|
const docExtId = docBeingCollected;
|
|
4059
4061
|
const apply = (prev) => {
|
|
4060
|
-
let next =
|
|
4062
|
+
let next = chunkB3FMUFAW_cjs.toFactCitations(prev);
|
|
4061
4063
|
for (const pending of picked) {
|
|
4062
|
-
next =
|
|
4064
|
+
next = chunkB3FMUFAW_cjs.withChunk(next, docExtId, { chunk_id: pending.chunk_id, page: pending.page ?? null });
|
|
4063
4065
|
}
|
|
4064
4066
|
return next ?? [];
|
|
4065
4067
|
};
|
|
@@ -4070,8 +4072,8 @@ function useFactComposer(notes, remove, gridApiRef, collector, composeRequested,
|
|
|
4070
4072
|
react.useEffect(() => {
|
|
4071
4073
|
if (!collector || !unpicked?.length || !collectingFor) return;
|
|
4072
4074
|
setDraftCitations((prev) => {
|
|
4073
|
-
let next =
|
|
4074
|
-
for (const chunkId of unpicked) next =
|
|
4075
|
+
let next = chunkB3FMUFAW_cjs.toFactCitations(prev);
|
|
4076
|
+
for (const chunkId of unpicked) next = chunkB3FMUFAW_cjs.withoutChunk(next, chunkId);
|
|
4075
4077
|
return next;
|
|
4076
4078
|
});
|
|
4077
4079
|
collector.consumeUnpicked();
|
|
@@ -4081,7 +4083,7 @@ function useFactComposer(notes, remove, gridApiRef, collector, composeRequested,
|
|
|
4081
4083
|
setBaselineText("");
|
|
4082
4084
|
setDraftCitations(null);
|
|
4083
4085
|
setDraftTagIds([]);
|
|
4084
|
-
setDraftDateFields(
|
|
4086
|
+
setDraftDateFields(chunkB3FMUFAW_cjs.EMPTY_FACT_DATE_FIELDS);
|
|
4085
4087
|
setDraftShared(false);
|
|
4086
4088
|
setDraftConfirmed(true);
|
|
4087
4089
|
setComposerError(null);
|
|
@@ -4095,7 +4097,7 @@ function useFactComposer(notes, remove, gridApiRef, collector, composeRequested,
|
|
|
4095
4097
|
setBaselineText("");
|
|
4096
4098
|
setDraftCitations(null);
|
|
4097
4099
|
setDraftTagIds([]);
|
|
4098
|
-
setDraftDateFields(
|
|
4100
|
+
setDraftDateFields(chunkB3FMUFAW_cjs.EMPTY_FACT_DATE_FIELDS);
|
|
4099
4101
|
setDraftShared(false);
|
|
4100
4102
|
setDraftConfirmed(true);
|
|
4101
4103
|
setComposerError(null);
|
|
@@ -4106,7 +4108,7 @@ function useFactComposer(notes, remove, gridApiRef, collector, composeRequested,
|
|
|
4106
4108
|
const content = chunkRC25WMVB_cjs.decodeWhitespaceEntities(draft).trim();
|
|
4107
4109
|
if (!content) return;
|
|
4108
4110
|
setComposerError(null);
|
|
4109
|
-
const span =
|
|
4111
|
+
const span = chunkB3FMUFAW_cjs.factDateFieldsToSpan(draftDateFields);
|
|
4110
4112
|
try {
|
|
4111
4113
|
let saved;
|
|
4112
4114
|
if (editingId) {
|
|
@@ -4144,7 +4146,7 @@ function useFactComposer(notes, remove, gridApiRef, collector, composeRequested,
|
|
|
4144
4146
|
setBaselineText(draft);
|
|
4145
4147
|
setDraftCitations(saved.citations ?? null);
|
|
4146
4148
|
setDraftTagIds(saved.tags.map((t) => t.tag_ext_id));
|
|
4147
|
-
setDraftDateFields(
|
|
4149
|
+
setDraftDateFields(chunkB3FMUFAW_cjs.factDateSpanToFields(saved.date_start, saved.date_end, saved.timezone));
|
|
4148
4150
|
setDraftShared(saved.shared ?? false);
|
|
4149
4151
|
setDraftConfirmed(saved.confirmed ?? true);
|
|
4150
4152
|
}
|
|
@@ -4169,7 +4171,7 @@ function useFactComposer(notes, remove, gridApiRef, collector, composeRequested,
|
|
|
4169
4171
|
setBaselineText(m.text);
|
|
4170
4172
|
setDraftCitations(m.citations ?? null);
|
|
4171
4173
|
setDraftTagIds(m.tags.map((t) => t.tag_ext_id));
|
|
4172
|
-
setDraftDateFields(
|
|
4174
|
+
setDraftDateFields(chunkB3FMUFAW_cjs.factDateSpanToFields(m.date_start, m.date_end, m.timezone));
|
|
4173
4175
|
setDraftShared(m.shared ?? false);
|
|
4174
4176
|
setDraftConfirmed(m.confirmed ?? true);
|
|
4175
4177
|
setComposerError(null);
|
|
@@ -4183,7 +4185,7 @@ function useFactComposer(notes, remove, gridApiRef, collector, composeRequested,
|
|
|
4183
4185
|
const textChanged = draft.trim() !== baselineText.trim();
|
|
4184
4186
|
const citationsChanged = JSON.stringify(draftCitations ?? null) !== JSON.stringify(f.citations ?? null);
|
|
4185
4187
|
const tagsChanged = JSON.stringify([...draftTagIds].sort()) !== JSON.stringify(f.tags.map((t) => t.tag_ext_id).sort());
|
|
4186
|
-
const dateChanged = JSON.stringify(draftDateFields) !== JSON.stringify(
|
|
4188
|
+
const dateChanged = JSON.stringify(draftDateFields) !== JSON.stringify(chunkB3FMUFAW_cjs.factDateSpanToFields(f.date_start, f.date_end, f.timezone));
|
|
4187
4189
|
const sharedChanged = draftShared !== (f.shared ?? false);
|
|
4188
4190
|
const confirmedChanged = draftConfirmed !== (f.confirmed ?? true);
|
|
4189
4191
|
return textChanged || citationsChanged || tagsChanged || dateChanged || sharedChanged || confirmedChanged;
|
|
@@ -4276,10 +4278,10 @@ function useFactFilters(notes, view, chat) {
|
|
|
4276
4278
|
const factFilters = view.filters;
|
|
4277
4279
|
const setFactFilters = view.setFilters;
|
|
4278
4280
|
const quickFilteredNotes = react.useMemo(
|
|
4279
|
-
() =>
|
|
4281
|
+
() => chunkTQUYWUEE_cjs.applyInvertedIndexFilter(
|
|
4280
4282
|
notes,
|
|
4281
4283
|
factFilters,
|
|
4282
|
-
|
|
4284
|
+
chunkTQUYWUEE_cjs.buildInvertedIndex(
|
|
4283
4285
|
notes,
|
|
4284
4286
|
(f) => f.external_id,
|
|
4285
4287
|
(f) => Object.entries(getFactFilterAttributes(f)).filter(([id, on]) => on && factFilterIds.includes(id)).map(([id]) => id)
|
|
@@ -4357,8 +4359,8 @@ function useFactFilters(notes, view, chat) {
|
|
|
4357
4359
|
const makeTagPicker = react.useCallback(
|
|
4358
4360
|
(selected, setSelected, opts) => {
|
|
4359
4361
|
const applied = new Set(selected);
|
|
4360
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
4361
|
-
|
|
4362
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkB3FMUFAW_cjs.FactFieldRow, { label: "Labels", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
4363
|
+
chunkQJFJ5JBF_cjs.FieldLabelsSelect,
|
|
4362
4364
|
{
|
|
4363
4365
|
options: labelOptions,
|
|
4364
4366
|
appliedIds: applied,
|
|
@@ -4548,14 +4550,14 @@ function useFactSelection(notes, gridApiRef, setFactTags, chat) {
|
|
|
4548
4550
|
}
|
|
4549
4551
|
function renderSourcesCell(params) {
|
|
4550
4552
|
const fact = params.data;
|
|
4551
|
-
const count =
|
|
4553
|
+
const count = chunkB3FMUFAW_cjs.sourceDocCount(fact);
|
|
4552
4554
|
if (!fact || count === 0) return /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground/40", children: "\u2014" });
|
|
4553
4555
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
4554
4556
|
"button",
|
|
4555
4557
|
{
|
|
4556
4558
|
type: "button",
|
|
4557
4559
|
onClick: () => params.context?.openEdit?.(fact),
|
|
4558
|
-
title:
|
|
4560
|
+
title: chunkB3FMUFAW_cjs.DEFAULT_FACT_COLUMN_LABELS.sourcedFrom(count),
|
|
4559
4561
|
"data-testid": `facts-grid-sources-${fact.external_id}`,
|
|
4560
4562
|
className: "inline-flex items-center gap-1 text-xs text-muted-foreground hover:text-foreground",
|
|
4561
4563
|
children: [
|
|
@@ -4584,7 +4586,7 @@ var FactHeader = react.memo(function FactHeader2({
|
|
|
4584
4586
|
if (params.enableSorting) params.progressSort(e.shiftKey);
|
|
4585
4587
|
},
|
|
4586
4588
|
children: [
|
|
4587
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
4589
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.FilterButton, { params, colId }),
|
|
4588
4590
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "order-2 min-w-0 flex-1 truncate", children: params.displayName }),
|
|
4589
4591
|
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "ag-sort-indicator-container order-2 flex-shrink-0", "aria-hidden": "true", children: [
|
|
4590
4592
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -4612,14 +4614,14 @@ function createFactPageColumns({
|
|
|
4612
4614
|
onToggleConfirmed,
|
|
4613
4615
|
onToggleShared
|
|
4614
4616
|
}) {
|
|
4615
|
-
const columns =
|
|
4617
|
+
const columns = chunkB3FMUFAW_cjs.createFactColumns({
|
|
4616
4618
|
onToggleInChat,
|
|
4617
4619
|
isInChat,
|
|
4618
4620
|
renderHeader: (params, colId) => /* @__PURE__ */ jsxRuntime.jsx(FactHeader, { params, colId }),
|
|
4619
4621
|
renderRowActions: (fact, params) => {
|
|
4620
4622
|
const ctx = params.context;
|
|
4621
4623
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
4622
|
-
|
|
4624
|
+
chunkB3FMUFAW_cjs.FactRowActions,
|
|
4623
4625
|
{
|
|
4624
4626
|
onEdit: () => ctx?.openEdit?.(fact),
|
|
4625
4627
|
canEdit: ctx?.canRewrite?.(fact) !== false,
|
|
@@ -4749,7 +4751,7 @@ function useFactsGrid({
|
|
|
4749
4751
|
);
|
|
4750
4752
|
const renderFactTags = react.useCallback(
|
|
4751
4753
|
(fact, rowHeight) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
4752
|
-
|
|
4754
|
+
chunkB3FMUFAW_cjs.FactLabelsCell,
|
|
4753
4755
|
{
|
|
4754
4756
|
options: labelOptions,
|
|
4755
4757
|
selectedIds: fact.tags.map((t) => t.tag_ext_id),
|
|
@@ -4848,7 +4850,7 @@ function useFactsGrid({
|
|
|
4848
4850
|
var DEFAULT_TIMELINE_LABEL_WIDTH = 240;
|
|
4849
4851
|
function useFactsPageView() {
|
|
4850
4852
|
const [view, setView] = react.useState("table");
|
|
4851
|
-
const [rowHeight, setRowHeight] = react.useState(
|
|
4853
|
+
const [rowHeight, setRowHeight] = react.useState(chunkQJFJ5JBF_cjs.ROW_MIN);
|
|
4852
4854
|
const [labelWidth, setLabelWidth] = react.useState(DEFAULT_TIMELINE_LABEL_WIDTH);
|
|
4853
4855
|
const [zoom, setZoom] = react.useState(1);
|
|
4854
4856
|
const [filterText, setFilterText] = react.useState("");
|
|
@@ -4881,7 +4883,7 @@ var citedDocIdsCache = /* @__PURE__ */ new WeakMap();
|
|
|
4881
4883
|
function citedDocIds(m) {
|
|
4882
4884
|
const cached = citedDocIdsCache.get(m);
|
|
4883
4885
|
if (cached) return cached;
|
|
4884
|
-
const ids =
|
|
4886
|
+
const ids = chunkB3FMUFAW_cjs.docIdsOf(chunkB3FMUFAW_cjs.toFactCitations(m.citations));
|
|
4885
4887
|
citedDocIdsCache.set(m, ids);
|
|
4886
4888
|
return ids;
|
|
4887
4889
|
}
|
|
@@ -4973,7 +4975,7 @@ function ConnectedFactsPage({
|
|
|
4973
4975
|
const citedDocs = react.useMemo(() => {
|
|
4974
4976
|
const wanted = /* @__PURE__ */ new Set([
|
|
4975
4977
|
...notes.flatMap((n) => citedDocIds(n)),
|
|
4976
|
-
...
|
|
4978
|
+
...chunkB3FMUFAW_cjs.docIdsOf(chunkB3FMUFAW_cjs.toFactCitations(composer.draftCitations))
|
|
4977
4979
|
]);
|
|
4978
4980
|
return Object.fromEntries(
|
|
4979
4981
|
documents.filter((d) => wanted.has(d.external_id)).map((d) => [d.external_id, d])
|
|
@@ -5002,7 +5004,7 @@ function ConnectedFactsPage({
|
|
|
5002
5004
|
setView(request.view === "list" ? "table" : request.view);
|
|
5003
5005
|
onRequestHandled?.("view");
|
|
5004
5006
|
}, [request?.view]);
|
|
5005
|
-
const factsRowHeight = pageView.rowHeight ===
|
|
5007
|
+
const factsRowHeight = pageView.rowHeight === chunkQJFJ5JBF_cjs.ROW_MIN ? chunkQJFJ5JBF_cjs.ROW_MIN : chunkQJFJ5JBF_cjs.rowHeightForLines(chunkQJFJ5JBF_cjs.linesForRowHeight(pageView.rowHeight));
|
|
5006
5008
|
const [isExportOpen, setIsExportOpen] = react.useState(false);
|
|
5007
5009
|
const [filterOpen, setFilterOpen] = react.useState(false);
|
|
5008
5010
|
const [factSection, setFactSection] = react.useState(null);
|
|
@@ -5027,7 +5029,7 @@ function ConnectedFactsPage({
|
|
|
5027
5029
|
};
|
|
5028
5030
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref: setFactSection, className: "relative flex h-full flex-col", "data-testid": "facts-page", children: [
|
|
5029
5031
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5030
|
-
|
|
5032
|
+
chunkB3FMUFAW_cjs.FactsToolbar,
|
|
5031
5033
|
{
|
|
5032
5034
|
count: filteredNotes.length,
|
|
5033
5035
|
hasActiveFilters: filters.hasActiveFilters,
|
|
@@ -5056,7 +5058,7 @@ function ConnectedFactsPage({
|
|
|
5056
5058
|
onNewFact: composing && !editingId ? () => void 0 : composer.startNewFact,
|
|
5057
5059
|
navSlotRef: setNavSlot,
|
|
5058
5060
|
navigator: view === "table" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
5059
|
-
|
|
5061
|
+
chunkGC2FSPSQ_cjs.GridRowNavigator,
|
|
5060
5062
|
{
|
|
5061
5063
|
gridApi,
|
|
5062
5064
|
selectedId: editingId,
|
|
@@ -5067,9 +5069,9 @@ function ConnectedFactsPage({
|
|
|
5067
5069
|
) : null,
|
|
5068
5070
|
showToolbarRow: view !== "smart_search",
|
|
5069
5071
|
tools: /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
5070
|
-
view === "table" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5072
|
+
view === "table" && /* @__PURE__ */ jsxRuntime.jsx(chunkB3FMUFAW_cjs.FactsFieldsButton, { getGridApi: () => gridApiRef.current }),
|
|
5071
5073
|
view === "table" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5072
|
-
|
|
5074
|
+
chunkQJFJ5JBF_cjs.RowDensityControl,
|
|
5073
5075
|
{
|
|
5074
5076
|
rowHeight: factsRowHeight,
|
|
5075
5077
|
onRowHeightChange: pageView.setRowHeight,
|
|
@@ -5088,7 +5090,7 @@ function ConnectedFactsPage({
|
|
|
5088
5090
|
}
|
|
5089
5091
|
),
|
|
5090
5092
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5091
|
-
|
|
5093
|
+
chunkB3FMUFAW_cjs.FactComposer,
|
|
5092
5094
|
{
|
|
5093
5095
|
isOpen: composing,
|
|
5094
5096
|
isEditing: !!editingId,
|
|
@@ -5121,7 +5123,7 @@ function ConnectedFactsPage({
|
|
|
5121
5123
|
reserveSourcesSpace: view === "gantt" || view === "calendar",
|
|
5122
5124
|
citationContainer: factSection,
|
|
5123
5125
|
renderDocumentPicker: (onSelect, selectedIds, onOpen, sourcesToggle, sourcesOpen) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
5124
|
-
|
|
5126
|
+
chunkB3FMUFAW_cjs.FactSourcesRow,
|
|
5125
5127
|
{
|
|
5126
5128
|
toggle: sourcesToggle,
|
|
5127
5129
|
picker: /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -5167,7 +5169,7 @@ function ConnectedFactsPage({
|
|
|
5167
5169
|
}
|
|
5168
5170
|
),
|
|
5169
5171
|
dateInput: /* @__PURE__ */ jsxRuntime.jsx(
|
|
5170
|
-
|
|
5172
|
+
chunkB3FMUFAW_cjs.FactDateInput,
|
|
5171
5173
|
{
|
|
5172
5174
|
value: composer.draftDateFields,
|
|
5173
5175
|
onChange: composer.setDraftDateFields,
|
|
@@ -5177,13 +5179,13 @@ function ConnectedFactsPage({
|
|
|
5177
5179
|
}
|
|
5178
5180
|
),
|
|
5179
5181
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "scrollbar-subtle flex-1 overflow-y-auto pb-2", children: [
|
|
5180
|
-
isLoading ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
5182
|
+
isLoading ? /* @__PURE__ */ jsxRuntime.jsx(chunkB3FMUFAW_cjs.FactsLoading, {}) : isError ? /* @__PURE__ */ jsxRuntime.jsx(chunkB3FMUFAW_cjs.FactsLoadError, { onRetry: () => refetch() }) : smartSearch ? (
|
|
5181
5183
|
// Searches facts only (never documents). Kept before the empty-state guard so the
|
|
5182
5184
|
// search UI is reachable even in an empty workspace.
|
|
5183
5185
|
smartSearch({ selectedFactId: editingId, onOpenFact: openFactById })
|
|
5184
5186
|
) : notes.length === 0 ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex min-h-full flex-col items-center justify-center", children: [
|
|
5185
5187
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5186
|
-
|
|
5188
|
+
chunkB3FMUFAW_cjs.FactsEmptyState,
|
|
5187
5189
|
{
|
|
5188
5190
|
onUseExample: (text) => {
|
|
5189
5191
|
composer.setDraft(text);
|
|
@@ -5194,7 +5196,7 @@ function ConnectedFactsPage({
|
|
|
5194
5196
|
),
|
|
5195
5197
|
emptyStateExtra
|
|
5196
5198
|
] }) : view === "calendar" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
5197
|
-
|
|
5199
|
+
chunkB3FMUFAW_cjs.FactsCalendar,
|
|
5198
5200
|
{
|
|
5199
5201
|
facts: filteredNotes,
|
|
5200
5202
|
onSelect: (n) => openEditIfAllowed(n),
|
|
@@ -5203,7 +5205,7 @@ function ConnectedFactsPage({
|
|
|
5203
5205
|
navigatorTotal: filteredNotes.length
|
|
5204
5206
|
}
|
|
5205
5207
|
) : view === "gantt" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
5206
|
-
|
|
5208
|
+
chunkB3FMUFAW_cjs.FactsGanttPane,
|
|
5207
5209
|
{
|
|
5208
5210
|
items: ganttItems,
|
|
5209
5211
|
labelWidth: pageView.labelWidth,
|
|
@@ -5253,7 +5255,7 @@ function ConnectedFactsPage({
|
|
|
5253
5255
|
)
|
|
5254
5256
|
] }),
|
|
5255
5257
|
selectable && notes.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5256
|
-
|
|
5258
|
+
chunkB3FMUFAW_cjs.FactsBulkBar,
|
|
5257
5259
|
{
|
|
5258
5260
|
count: selection.selectedFacts.length,
|
|
5259
5261
|
onClear: selection.clearSelection,
|
|
@@ -5373,13 +5375,13 @@ function ConnectedProfileCard({
|
|
|
5373
5375
|
}
|
|
5374
5376
|
});
|
|
5375
5377
|
const display = profile?.fullName || "Unnamed";
|
|
5376
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
5378
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(chunkNMZI3K6R_cjs.SettingsSection, { icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.UserCircle, {}), title, children: [
|
|
5377
5379
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5378
|
-
|
|
5380
|
+
chunkTQUYWUEE_cjs.ProfileCard,
|
|
5379
5381
|
{
|
|
5380
5382
|
avatar: /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
5381
5383
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5382
|
-
|
|
5384
|
+
chunkTQUYWUEE_cjs.AvatarPicker,
|
|
5383
5385
|
{
|
|
5384
5386
|
pictureUrl: profile?.picture,
|
|
5385
5387
|
initials: chunkKDG6FER6_cjs.initials(display),
|
|
@@ -5426,9 +5428,9 @@ function ConnectedIdentityVerification({
|
|
|
5426
5428
|
onNameAccepted: () => notify14("Name updated to match your ID", "success")
|
|
5427
5429
|
});
|
|
5428
5430
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
5429
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5431
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.IdentityVerificationCard, { flow, labels, onManageBilling }),
|
|
5430
5432
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5431
|
-
|
|
5433
|
+
chunkTQUYWUEE_cjs.IdentityVerificationDialog,
|
|
5432
5434
|
{
|
|
5433
5435
|
flow,
|
|
5434
5436
|
accountName: profile?.fullName ?? "",
|
|
@@ -5441,7 +5443,7 @@ function ConnectedIdentityVerification({
|
|
|
5441
5443
|
function ConnectedRequireVerified({ children, labels }) {
|
|
5442
5444
|
const { data: profile } = react$1.useProfile();
|
|
5443
5445
|
const flow = react$1.useIdentityVerification();
|
|
5444
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
5446
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.RequireVerified, { flow, accountName: profile?.fullName ?? "", labels, children });
|
|
5445
5447
|
}
|
|
5446
5448
|
function defaultUnmetPasswordRequirement(password) {
|
|
5447
5449
|
if (password.length < 8) return "Minimum 8 characters";
|
|
@@ -5474,7 +5476,7 @@ function ConnectedPasswordChangeDialog({
|
|
|
5474
5476
|
onRecoveryComplete
|
|
5475
5477
|
});
|
|
5476
5478
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
5477
|
-
|
|
5479
|
+
chunkTQUYWUEE_cjs.PasswordChangeDialog,
|
|
5478
5480
|
{
|
|
5479
5481
|
open,
|
|
5480
5482
|
onClose: form.onCancel,
|
|
@@ -5500,10 +5502,10 @@ function ConnectedSecuritySection({
|
|
|
5500
5502
|
children
|
|
5501
5503
|
}) {
|
|
5502
5504
|
const [open, setOpen] = react.useState(false);
|
|
5503
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
5504
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
5505
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(chunkNMZI3K6R_cjs.SettingsSection, { icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.KeyRound, {}), title: "Security", children: [
|
|
5506
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkNMZI3K6R_cjs.SettingsCard, { padding: "sm", children: [
|
|
5505
5507
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5506
|
-
|
|
5508
|
+
chunkNMZI3K6R_cjs.SettingsActionRow,
|
|
5507
5509
|
{
|
|
5508
5510
|
title: "Change password",
|
|
5509
5511
|
description: "Used to sign in and to unlock your account key. Changing it keeps everything readable and re-encrypts nothing.",
|
|
@@ -5524,23 +5526,23 @@ function ConnectedSecuritySection({
|
|
|
5524
5526
|
] });
|
|
5525
5527
|
}
|
|
5526
5528
|
function ConnectedNotificationPreferences({
|
|
5527
|
-
categories =
|
|
5529
|
+
categories = chunkTQUYWUEE_cjs.EMAIL_NOTIFICATION_CATEGORIES,
|
|
5528
5530
|
title = "Notifications"
|
|
5529
5531
|
}) {
|
|
5530
5532
|
const keys = react.useMemo(
|
|
5531
|
-
() => categories ===
|
|
5533
|
+
() => categories === chunkTQUYWUEE_cjs.EMAIL_NOTIFICATION_CATEGORIES ? chunkTQUYWUEE_cjs.EMAIL_NOTIFICATION_KEYS : categories.map((c) => c.key),
|
|
5532
5534
|
[categories]
|
|
5533
5535
|
);
|
|
5534
5536
|
const prefs = react$1.useNotificationPreferences(keys);
|
|
5535
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
5536
|
-
|
|
5537
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkNMZI3K6R_cjs.SettingsSection, { title, children: /* @__PURE__ */ jsxRuntime.jsx(chunkNMZI3K6R_cjs.SettingsCard, { className: "space-y-0", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
5538
|
+
chunkTQUYWUEE_cjs.NotificationCategoryList,
|
|
5537
5539
|
{
|
|
5538
5540
|
masterId: "emailNotifications",
|
|
5539
5541
|
masterTitle: "Email Notifications",
|
|
5540
5542
|
masterDescription: "Email me about activity when I\u2019m away",
|
|
5541
5543
|
masterChecked: prefs.masterChecked,
|
|
5542
5544
|
onMasterChange: prefs.setAll,
|
|
5543
|
-
categories:
|
|
5545
|
+
categories: chunkTQUYWUEE_cjs.toNotificationCategories(prefs.checked, categories),
|
|
5544
5546
|
onCategoryChange: prefs.setCategory
|
|
5545
5547
|
}
|
|
5546
5548
|
) }) });
|
|
@@ -5553,14 +5555,14 @@ function ConnectedSessionsRow({
|
|
|
5553
5555
|
const sessions = react$1.useSessions({ enabled: open });
|
|
5554
5556
|
const currentSessionId = react$1.useCurrentSessionId();
|
|
5555
5557
|
const terminate = react$1.useTerminateSession();
|
|
5556
|
-
const views =
|
|
5558
|
+
const views = chunkTQUYWUEE_cjs.toActiveSessionViews(sessions.data ?? [], {
|
|
5557
5559
|
currentSessionId,
|
|
5558
5560
|
terminatingId: terminate.isPending ? terminate.variables : null,
|
|
5559
5561
|
renderIcon: renderSessionIcon
|
|
5560
5562
|
});
|
|
5561
5563
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
5562
5564
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5563
|
-
|
|
5565
|
+
chunkNMZI3K6R_cjs.SettingsRow,
|
|
5564
5566
|
{
|
|
5565
5567
|
label: "Active sessions",
|
|
5566
5568
|
description: "Devices and agents currently signed in to your account.",
|
|
@@ -5582,7 +5584,7 @@ function ConnectedSessionsRow({
|
|
|
5582
5584
|
}
|
|
5583
5585
|
),
|
|
5584
5586
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5585
|
-
|
|
5587
|
+
chunkTQUYWUEE_cjs.ActiveSessionsDialog,
|
|
5586
5588
|
{
|
|
5587
5589
|
open,
|
|
5588
5590
|
onOpenChange: setOpen,
|
|
@@ -5624,7 +5626,7 @@ function ConnectedLogoutDialog({
|
|
|
5624
5626
|
signOut.mutate({ everywhere, reason: "manual" });
|
|
5625
5627
|
};
|
|
5626
5628
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
5627
|
-
|
|
5629
|
+
chunkTQUYWUEE_cjs.LogoutDialog,
|
|
5628
5630
|
{
|
|
5629
5631
|
open,
|
|
5630
5632
|
onClose,
|
|
@@ -5632,7 +5634,7 @@ function ConnectedLogoutDialog({
|
|
|
5632
5634
|
onLogoutAll: () => void run(true),
|
|
5633
5635
|
canLogoutAll,
|
|
5634
5636
|
isOnline,
|
|
5635
|
-
sessions:
|
|
5637
|
+
sessions: chunkTQUYWUEE_cjs.toLogoutSessionViews(sessions.data ?? []),
|
|
5636
5638
|
renderSessionIcon
|
|
5637
5639
|
}
|
|
5638
5640
|
);
|
|
@@ -5654,7 +5656,7 @@ function ConnectedDangerZone({ renderSubscriptionLink }) {
|
|
|
5654
5656
|
});
|
|
5655
5657
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
5656
5658
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5657
|
-
|
|
5659
|
+
chunkNMZI3K6R_cjs.SettingsDangerZone,
|
|
5658
5660
|
{
|
|
5659
5661
|
isOpen: zoneOpen,
|
|
5660
5662
|
onToggle: () => setZoneOpen((o) => !o),
|
|
@@ -5674,12 +5676,12 @@ function ConnectedDangerZone({ renderSubscriptionLink }) {
|
|
|
5674
5676
|
}
|
|
5675
5677
|
),
|
|
5676
5678
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5677
|
-
|
|
5679
|
+
chunkTQUYWUEE_cjs.DeleteAccountDialog,
|
|
5678
5680
|
{
|
|
5679
5681
|
open: dialogOpen,
|
|
5680
5682
|
onClose: flow.onClose,
|
|
5681
5683
|
step: flow.step,
|
|
5682
|
-
blockers:
|
|
5684
|
+
blockers: chunkTQUYWUEE_cjs.toDeleteBlockerViews(flow.blockers, renderSubscriptionLink),
|
|
5683
5685
|
onContinue: flow.onContinue,
|
|
5684
5686
|
onBack: flow.onBack,
|
|
5685
5687
|
userEmail,
|
|
@@ -5694,7 +5696,7 @@ function ConnectedDangerZone({ renderSubscriptionLink }) {
|
|
|
5694
5696
|
function ServerConnectionRow({ onRefresh, ...status }) {
|
|
5695
5697
|
const { runtimeConfig } = chunkCNHUJRQ4_cjs.useBlocksEnvironment();
|
|
5696
5698
|
const [isRefreshing, setIsRefreshing] = react.useState(false);
|
|
5697
|
-
const view =
|
|
5699
|
+
const view = chunkTQUYWUEE_cjs.serverConnectionView(status, runtimeConfig.deploymentDomain || "server");
|
|
5698
5700
|
const refresh = async () => {
|
|
5699
5701
|
setIsRefreshing(true);
|
|
5700
5702
|
try {
|
|
@@ -5703,8 +5705,8 @@ function ServerConnectionRow({ onRefresh, ...status }) {
|
|
|
5703
5705
|
setIsRefreshing(false);
|
|
5704
5706
|
}
|
|
5705
5707
|
};
|
|
5706
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
5707
|
-
|
|
5708
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkNMZI3K6R_cjs.SettingsRow, { label: "Server connection", description: view.description, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
5709
|
+
chunkTQUYWUEE_cjs.ServerConnectionButton,
|
|
5708
5710
|
{
|
|
5709
5711
|
state: view.state,
|
|
5710
5712
|
label: view.label,
|
|
@@ -5726,7 +5728,7 @@ function ConnectedAccountSettings({
|
|
|
5726
5728
|
renderSubscriptionLink
|
|
5727
5729
|
}) {
|
|
5728
5730
|
const [logoutOpen, setLogoutOpen] = react.useState(false);
|
|
5729
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
5731
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(chunkNMZI3K6R_cjs.SettingsPanel, { className: "max-w-2xl", children: [
|
|
5730
5732
|
/* @__PURE__ */ jsxRuntime.jsx(ConnectedProfileCard, { avatarClassName, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
5731
5733
|
ConnectedIdentityVerification,
|
|
5732
5734
|
{
|
|
@@ -5736,10 +5738,10 @@ function ConnectedAccountSettings({
|
|
|
5736
5738
|
) }),
|
|
5737
5739
|
afterProfile,
|
|
5738
5740
|
/* @__PURE__ */ jsxRuntime.jsx(ConnectedSecuritySection, { getUnmetRequirement: getUnmetPasswordRequirement, children: securityRows }),
|
|
5739
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5741
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkNMZI3K6R_cjs.SettingsSection, { icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Wifi, {}), title: "Session", children: /* @__PURE__ */ jsxRuntime.jsxs(chunkNMZI3K6R_cjs.SettingsCard, { children: [
|
|
5740
5742
|
connection && /* @__PURE__ */ jsxRuntime.jsx(ServerConnectionRow, { ...connection }),
|
|
5741
5743
|
/* @__PURE__ */ jsxRuntime.jsx(ConnectedSessionsRow, { renderSessionIcon }),
|
|
5742
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5744
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkNMZI3K6R_cjs.SettingsRow, { label: "Logout", description: "Sign out of your account on this device.", children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
5743
5745
|
ui.Button,
|
|
5744
5746
|
{
|
|
5745
5747
|
type: "button",
|
|
@@ -6021,10 +6023,10 @@ function ConnectedPrivacySettings({
|
|
|
6021
6023
|
const update = react$1.useUpdateUserSettings();
|
|
6022
6024
|
const hideOnlineStatus = settings?.hide_online_status ?? false;
|
|
6023
6025
|
const dismissedTips = settings?.dismissed_tips ?? [];
|
|
6024
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
6025
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6026
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(chunkNMZI3K6R_cjs.SettingsPanel, { className: "max-w-2xl", children: [
|
|
6027
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkNMZI3K6R_cjs.SettingsSection, { title: "Privacy and tips", children: /* @__PURE__ */ jsxRuntime.jsxs(chunkNMZI3K6R_cjs.SettingsCard, { children: [
|
|
6026
6028
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6027
|
-
|
|
6029
|
+
chunkNMZI3K6R_cjs.SettingsRow,
|
|
6028
6030
|
{
|
|
6029
6031
|
label: "Show Online Status",
|
|
6030
6032
|
labelFor: "showOnlineStatus",
|
|
@@ -6042,7 +6044,7 @@ function ConnectedPrivacySettings({
|
|
|
6042
6044
|
),
|
|
6043
6045
|
rows,
|
|
6044
6046
|
showTipsReset && /* @__PURE__ */ jsxRuntime.jsx(
|
|
6045
|
-
|
|
6047
|
+
chunkNMZI3K6R_cjs.SettingsRow,
|
|
6046
6048
|
{
|
|
6047
6049
|
label: "Hidden tips",
|
|
6048
6050
|
description: "Restore any Smart Tips you\u2019ve hidden with \u201Cdon\u2019t show again\u201D.",
|
|
@@ -6106,13 +6108,13 @@ var COLUMNS = [
|
|
|
6106
6108
|
flex: 1,
|
|
6107
6109
|
minWidth: 120,
|
|
6108
6110
|
cellRenderer: (params) => isStandard(params.data) ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
6109
|
-
|
|
6111
|
+
chunkTQUYWUEE_cjs.ModelProviderLabel,
|
|
6110
6112
|
{
|
|
6111
6113
|
logo: /* @__PURE__ */ jsxRuntime.jsx("img", { src: "/favicon.svg", alt: "ARBI", className: "size-3.5 flex-shrink-0 rounded-sm" }),
|
|
6112
6114
|
children: "ARBI CITY"
|
|
6113
6115
|
}
|
|
6114
6116
|
) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
6115
|
-
|
|
6117
|
+
chunkTQUYWUEE_cjs.ModelProviderLabel,
|
|
6116
6118
|
{
|
|
6117
6119
|
logo: /* @__PURE__ */ jsxRuntime.jsx(react$1.ProviderIcon, { modelName: params.data?.model_name, provider: params.value, size: 14 }),
|
|
6118
6120
|
children: PROVIDER_NAMES[params.value ?? ""] || params.value || "\u2014"
|
|
@@ -6188,8 +6190,8 @@ function ConnectedPremiumModels() {
|
|
|
6188
6190
|
[save]
|
|
6189
6191
|
);
|
|
6190
6192
|
if (premiumModels.length === 0) return null;
|
|
6191
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
6192
|
-
|
|
6193
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkNMZI3K6R_cjs.SettingsPanel, { className: "max-w-2xl space-y-4", children: /* @__PURE__ */ jsxRuntime.jsx(chunkNMZI3K6R_cjs.SettingsSection, { title: "Premium models", children: /* @__PURE__ */ jsxRuntime.jsx(chunkNMZI3K6R_cjs.SettingsCard, { className: "space-y-0", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
6194
|
+
chunkTQUYWUEE_cjs.PremiumModelsFrame,
|
|
6193
6195
|
{
|
|
6194
6196
|
enabled: premiumModel !== "",
|
|
6195
6197
|
onEnabledChange: (enabled) => {
|
|
@@ -6318,10 +6320,10 @@ function ConnectedAppsSettings({
|
|
|
6318
6320
|
}
|
|
6319
6321
|
};
|
|
6320
6322
|
if (isLoading) {
|
|
6321
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
6323
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.ConnectionsLoading, { message: "Loading connected apps\u2026" });
|
|
6322
6324
|
}
|
|
6323
6325
|
if (catalogError) {
|
|
6324
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
6326
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.ConnectionsError, { message: "Failed to load connector catalog. Please refresh and try again." });
|
|
6325
6327
|
}
|
|
6326
6328
|
const visibleCatalog = catalog.filter((c) => isVendorVisible(c.vendor_key));
|
|
6327
6329
|
const sharePointVisible = isVendorVisible("microsoft_sharepoint");
|
|
@@ -6330,7 +6332,7 @@ function ConnectedAppsSettings({
|
|
|
6330
6332
|
(c) => !react$1.isMailboxSyncVendor(c.vendor_key) && !react$1.isSharePointVendor(c.vendor_key)
|
|
6331
6333
|
);
|
|
6332
6334
|
const renderCard = (entry) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
6333
|
-
|
|
6335
|
+
chunkTQUYWUEE_cjs.ConnectionCard,
|
|
6334
6336
|
{
|
|
6335
6337
|
connection: toConnectionCardView(entry, connectedByVendor[entry.vendor_key], {
|
|
6336
6338
|
isDisconnecting: disconnect.isPending && disconnect.variables?.vendorKey === entry.vendor_key,
|
|
@@ -6347,12 +6349,12 @@ function ConnectedAppsSettings({
|
|
|
6347
6349
|
);
|
|
6348
6350
|
const renderGroup = (title, subtitle, icon2, entries) => {
|
|
6349
6351
|
if (entries.length === 0) return null;
|
|
6350
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
6352
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkNMZI3K6R_cjs.SettingsSection, { icon: icon2, title, children: /* @__PURE__ */ jsxRuntime.jsxs(chunkNMZI3K6R_cjs.SettingsCard, { className: "space-y-3", children: [
|
|
6351
6353
|
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground", children: subtitle }),
|
|
6352
6354
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-2", children: entries.map(renderCard) })
|
|
6353
6355
|
] }) });
|
|
6354
6356
|
};
|
|
6355
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
6357
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(chunkNMZI3K6R_cjs.SettingsPanel, { className: "max-w-2xl", children: [
|
|
6356
6358
|
/* @__PURE__ */ jsxRuntime.jsxs("section", { className: "rounded-xl border border-border bg-card px-5 py-4", children: [
|
|
6357
6359
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-4", children: [
|
|
6358
6360
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-0.5 flex h-10 w-10 shrink-0 items-center justify-center rounded-lg border border-border bg-background text-muted-foreground", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Mail, { className: "h-5 w-5" }) }),
|
|
@@ -6458,7 +6460,7 @@ function ConnectedAppsSettings({
|
|
|
6458
6460
|
}
|
|
6459
6461
|
)
|
|
6460
6462
|
] }),
|
|
6461
|
-
catalog.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
6463
|
+
catalog.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(chunkNMZI3K6R_cjs.SettingsCard, { children: /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.ConnectionsEmpty, { message: "No connectors available yet." }) }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
6462
6464
|
renderGroup("Email & Drive", EMAIL_AND_DRIVE_SUBTITLE, /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Mail, {}), emailCatalog),
|
|
6463
6465
|
renderGroup(
|
|
6464
6466
|
"Apps & Integrations (MCP)",
|
|
@@ -6535,7 +6537,7 @@ function ConnectedSettingsPage({
|
|
|
6535
6537
|
}, [requested]);
|
|
6536
6538
|
const controlled = section !== void 0;
|
|
6537
6539
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
6538
|
-
|
|
6540
|
+
chunkTQUYWUEE_cjs.SettingsPage,
|
|
6539
6541
|
{
|
|
6540
6542
|
...page,
|
|
6541
6543
|
sections,
|
|
@@ -6961,13 +6963,13 @@ function ConnectedWorkspaceSettings({
|
|
|
6961
6963
|
const [membersExpanded, setMembersExpanded] = react.useState(false);
|
|
6962
6964
|
const [shareOpen, setShareOpen] = react.useState(false);
|
|
6963
6965
|
if (!workspace) {
|
|
6964
|
-
return /* @__PURE__ */ jsxRuntime.jsx(chunkMSFQDELO_cjs.PageLoading, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
6966
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkMSFQDELO_cjs.PageLoading, { children: /* @__PURE__ */ jsxRuntime.jsx(chunkGC2FSPSQ_cjs.LoadingIndicator, { message: "Loading workspace..." }) });
|
|
6965
6967
|
}
|
|
6966
6968
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
6967
6969
|
/* @__PURE__ */ jsxRuntime.jsxs(chunkMSFQDELO_cjs.WorkspacePageFrame, { testId, children: [
|
|
6968
6970
|
/* @__PURE__ */ jsxRuntime.jsxs(chunkMSFQDELO_cjs.WorkspaceIdentityPanel, { children: [
|
|
6969
6971
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6970
|
-
|
|
6972
|
+
chunkGC2FSPSQ_cjs.EntityIdentityBar,
|
|
6971
6973
|
{
|
|
6972
6974
|
testId: "workspace-identity-bar",
|
|
6973
6975
|
canEdit: isOwner,
|
|
@@ -6984,7 +6986,7 @@ function ConnectedWorkspaceSettings({
|
|
|
6984
6986
|
label: "Name",
|
|
6985
6987
|
value: workspace.name,
|
|
6986
6988
|
placeholder: "Untitled",
|
|
6987
|
-
maxLength:
|
|
6989
|
+
maxLength: chunkGC2FSPSQ_cjs.IDENTITY_NAME_MAX_LENGTH,
|
|
6988
6990
|
valueClassName: "truncate text-base font-semibold",
|
|
6989
6991
|
testId: "workspace-home-title",
|
|
6990
6992
|
hideLabel: true,
|
|
@@ -7278,9 +7280,9 @@ function ConnectedMailboxSyncDialog({
|
|
|
7278
7280
|
showDescription: true,
|
|
7279
7281
|
className: "w-[92vw] sm:max-w-lg",
|
|
7280
7282
|
children: [
|
|
7281
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
7282
|
-
!lockedWorkspaceExtId && /* @__PURE__ */ jsxRuntime.jsx(
|
|
7283
|
-
|
|
7283
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.SyncDialogBody, { children: [
|
|
7284
|
+
!lockedWorkspaceExtId && /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncField, { label: "Target workspace", htmlFor: "sync-workspace", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
7285
|
+
chunkTQUYWUEE_cjs.SyncSelect,
|
|
7284
7286
|
{
|
|
7285
7287
|
id: "sync-workspace",
|
|
7286
7288
|
value: workspaceExtId,
|
|
@@ -7289,9 +7291,9 @@ function ConnectedMailboxSyncDialog({
|
|
|
7289
7291
|
options: memberWorkspaces.map((w) => ({ value: w.external_id, label: w.name }))
|
|
7290
7292
|
}
|
|
7291
7293
|
) }),
|
|
7292
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
7294
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.SyncField, { label: "Backfill window", htmlFor: "sync-backfill", children: [
|
|
7293
7295
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7294
|
-
|
|
7296
|
+
chunkTQUYWUEE_cjs.SyncSelect,
|
|
7295
7297
|
{
|
|
7296
7298
|
id: "sync-backfill",
|
|
7297
7299
|
value: backfill,
|
|
@@ -7311,17 +7313,17 @@ function ConnectedMailboxSyncDialog({
|
|
|
7311
7313
|
"aria-label": "Import emails since date"
|
|
7312
7314
|
}
|
|
7313
7315
|
),
|
|
7314
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7316
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncSmallNote, { children: "Emails are always imported from this date onward \u2014 the start point never moves." })
|
|
7315
7317
|
] })
|
|
7316
7318
|
] }),
|
|
7317
7319
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7318
|
-
|
|
7320
|
+
chunkTQUYWUEE_cjs.SyncField,
|
|
7319
7321
|
{
|
|
7320
7322
|
label: `Folders to import${selectedFolders.length > 0 ? ` (${selectedFolders.length})` : ""}`,
|
|
7321
7323
|
hint: "Select at least one folder to import.",
|
|
7322
|
-
actions: folders.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7324
|
+
actions: folders.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.SyncLinkRow, { children: [
|
|
7323
7325
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7324
|
-
|
|
7326
|
+
chunkTQUYWUEE_cjs.SyncLinkButton,
|
|
7325
7327
|
{
|
|
7326
7328
|
onClick: () => setExpandAllNonce((n) => n + 1),
|
|
7327
7329
|
testId: "mail-folders-expand-all",
|
|
@@ -7329,20 +7331,20 @@ function ConnectedMailboxSyncDialog({
|
|
|
7329
7331
|
}
|
|
7330
7332
|
),
|
|
7331
7333
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7332
|
-
|
|
7334
|
+
chunkTQUYWUEE_cjs.SyncLinkButton,
|
|
7333
7335
|
{
|
|
7334
7336
|
onClick: () => setCollapseAllNonce((n) => n + 1),
|
|
7335
7337
|
testId: "mail-folders-collapse-all",
|
|
7336
7338
|
children: "Collapse all"
|
|
7337
7339
|
}
|
|
7338
7340
|
),
|
|
7339
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7341
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncLinkButton, { onClick: toggleAllFolders, children: allSelected ? "Clear all" : "Select all" })
|
|
7340
7342
|
] }),
|
|
7341
|
-
children: foldersLoading ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
7343
|
+
children: foldersLoading ? /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncLoading, { children: "Loading folders\u2026" }) : foldersError ? (
|
|
7342
7344
|
// A failed fetch is not an empty mailbox: it hides auth/scope errors (e.g. a Gmail
|
|
7343
7345
|
// account needing reconnect).
|
|
7344
7346
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7345
|
-
|
|
7347
|
+
chunkTQUYWUEE_cjs.SyncReconnectNotice,
|
|
7346
7348
|
{
|
|
7347
7349
|
message: `Couldn\u2019t load folders from ${catalog.display_name}. Reconnect the account and try again.`,
|
|
7348
7350
|
onReconnect: () => void reconnect(),
|
|
@@ -7350,7 +7352,7 @@ function ConnectedMailboxSyncDialog({
|
|
|
7350
7352
|
testId: "folders-reconnect"
|
|
7351
7353
|
}
|
|
7352
7354
|
)
|
|
7353
|
-
) : folders.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
7355
|
+
) : folders.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncNote, { children: "No folders found." }) : /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncTreeFrame, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
7354
7356
|
chunkCROGFB46_cjs.MailFolderTree,
|
|
7355
7357
|
{
|
|
7356
7358
|
nodes: folderTree,
|
|
@@ -7362,9 +7364,9 @@ function ConnectedMailboxSyncDialog({
|
|
|
7362
7364
|
) })
|
|
7363
7365
|
}
|
|
7364
7366
|
),
|
|
7365
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
7367
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.SyncOptions, { children: [
|
|
7366
7368
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7367
|
-
|
|
7369
|
+
chunkTQUYWUEE_cjs.SyncOptionToggle,
|
|
7368
7370
|
{
|
|
7369
7371
|
checked: skipDuplicates,
|
|
7370
7372
|
onCheckedChange: setSkipDuplicates,
|
|
@@ -7374,7 +7376,7 @@ function ConnectedMailboxSyncDialog({
|
|
|
7374
7376
|
}
|
|
7375
7377
|
),
|
|
7376
7378
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7377
|
-
|
|
7379
|
+
chunkTQUYWUEE_cjs.SyncOptionToggle,
|
|
7378
7380
|
{
|
|
7379
7381
|
checked: autoRename,
|
|
7380
7382
|
onCheckedChange: setAutoRename,
|
|
@@ -7384,7 +7386,7 @@ function ConnectedMailboxSyncDialog({
|
|
|
7384
7386
|
}
|
|
7385
7387
|
),
|
|
7386
7388
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7387
|
-
|
|
7389
|
+
chunkTQUYWUEE_cjs.SyncOptionToggle,
|
|
7388
7390
|
{
|
|
7389
7391
|
checked: shared,
|
|
7390
7392
|
onCheckedChange: setShared,
|
|
@@ -7394,7 +7396,7 @@ function ConnectedMailboxSyncDialog({
|
|
|
7394
7396
|
}
|
|
7395
7397
|
),
|
|
7396
7398
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7397
|
-
|
|
7399
|
+
chunkTQUYWUEE_cjs.SyncOptionToggle,
|
|
7398
7400
|
{
|
|
7399
7401
|
checked: autoSync,
|
|
7400
7402
|
onCheckedChange: setAutoSync,
|
|
@@ -7406,7 +7408,7 @@ function ConnectedMailboxSyncDialog({
|
|
|
7406
7408
|
] })
|
|
7407
7409
|
] }),
|
|
7408
7410
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7409
|
-
|
|
7411
|
+
chunkTQUYWUEE_cjs.SyncDialogFooter,
|
|
7410
7412
|
{
|
|
7411
7413
|
onCancel: () => onOpenChange(false),
|
|
7412
7414
|
onSave: handleEnableSubmit,
|
|
@@ -7468,7 +7470,7 @@ function DriveFolderNode({
|
|
|
7468
7470
|
const mightHaveChildren = docCount == null || docCount > 0;
|
|
7469
7471
|
const orderedChildren = [...children].sort((a, b) => a.name.localeCompare(b.name));
|
|
7470
7472
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
7471
|
-
|
|
7473
|
+
chunkTQUYWUEE_cjs.SyncFolderRow,
|
|
7472
7474
|
{
|
|
7473
7475
|
id: folder.id,
|
|
7474
7476
|
name: folder.name,
|
|
@@ -7482,7 +7484,7 @@ function DriveFolderNode({
|
|
|
7482
7484
|
onCheckedChange: () => onToggle(folder.id),
|
|
7483
7485
|
count: typeof docCount === "number" ? docCount : void 0,
|
|
7484
7486
|
isCountLoading: isSelectable && countLoading,
|
|
7485
|
-
children: isLoading ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
7487
|
+
children: isLoading ? /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncFolderStatus, { depth, kind: "loading" }) : orderedChildren.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncFolderStatus, { depth, kind: "empty" }) : orderedChildren.map((child) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
7486
7488
|
DriveFolderNode,
|
|
7487
7489
|
{
|
|
7488
7490
|
vendorKey,
|
|
@@ -7628,9 +7630,9 @@ function ConnectedDriveSyncDialog({
|
|
|
7628
7630
|
showDescription: true,
|
|
7629
7631
|
className: "w-[92vw] sm:max-w-lg",
|
|
7630
7632
|
children: [
|
|
7631
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
7632
|
-
!lockedWorkspaceExtId && /* @__PURE__ */ jsxRuntime.jsx(
|
|
7633
|
-
|
|
7633
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.SyncDialogBody, { children: [
|
|
7634
|
+
!lockedWorkspaceExtId && /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncField, { label: "Target workspace", htmlFor: "drive-sync-workspace", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
7635
|
+
chunkTQUYWUEE_cjs.SyncSelect,
|
|
7634
7636
|
{
|
|
7635
7637
|
id: "drive-sync-workspace",
|
|
7636
7638
|
value: workspaceExtId,
|
|
@@ -7640,13 +7642,13 @@ function ConnectedDriveSyncDialog({
|
|
|
7640
7642
|
}
|
|
7641
7643
|
) }),
|
|
7642
7644
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7643
|
-
|
|
7645
|
+
chunkTQUYWUEE_cjs.SyncField,
|
|
7644
7646
|
{
|
|
7645
7647
|
label: `Folders to import${selectedFolders.length > 0 ? ` (${selectedFolders.length})` : ""}`,
|
|
7646
7648
|
hint: "Select at least one folder. Importing a folder includes everything inside it.",
|
|
7647
|
-
actions: orderedFolders.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7649
|
+
actions: orderedFolders.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.SyncLinkRow, { children: [
|
|
7648
7650
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7649
|
-
|
|
7651
|
+
chunkTQUYWUEE_cjs.SyncLinkButton,
|
|
7650
7652
|
{
|
|
7651
7653
|
onClick: () => setExpandAllNonce((n) => n + 1),
|
|
7652
7654
|
testId: "drive-folders-expand-all",
|
|
@@ -7654,7 +7656,7 @@ function ConnectedDriveSyncDialog({
|
|
|
7654
7656
|
}
|
|
7655
7657
|
),
|
|
7656
7658
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7657
|
-
|
|
7659
|
+
chunkTQUYWUEE_cjs.SyncLinkButton,
|
|
7658
7660
|
{
|
|
7659
7661
|
onClick: () => setCollapseAllNonce((n) => n + 1),
|
|
7660
7662
|
testId: "drive-folders-collapse-all",
|
|
@@ -7662,19 +7664,19 @@ function ConnectedDriveSyncDialog({
|
|
|
7662
7664
|
}
|
|
7663
7665
|
)
|
|
7664
7666
|
] }),
|
|
7665
|
-
children: foldersLoading ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
7666
|
-
|
|
7667
|
+
children: foldersLoading ? /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncLoading, { children: "Loading folders\u2026" }) : needsReconnect ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
7668
|
+
chunkTQUYWUEE_cjs.SyncReconnectNotice,
|
|
7667
7669
|
{
|
|
7668
7670
|
...reconnectButtonProps,
|
|
7669
7671
|
message: `Reconnect ${catalog.display_name} to enable ${productName} \u2014 your account needs to grant file access.`
|
|
7670
7672
|
}
|
|
7671
7673
|
) : foldersError ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
7672
|
-
|
|
7674
|
+
chunkTQUYWUEE_cjs.SyncReconnectNotice,
|
|
7673
7675
|
{
|
|
7674
7676
|
...reconnectButtonProps,
|
|
7675
7677
|
message: `Couldn\u2019t load folders from ${productName}. Reconnect the account and try again.`
|
|
7676
7678
|
}
|
|
7677
|
-
) : orderedFolders.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
7679
|
+
) : orderedFolders.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncNote, { children: "No folders found." }) : /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SyncTreeFrame, { children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-0.5", "data-testid": "drive-folder-tree", children: orderedFolders.map((f) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
7678
7680
|
DriveFolderNode,
|
|
7679
7681
|
{
|
|
7680
7682
|
vendorKey: catalog.vendor_key,
|
|
@@ -7691,9 +7693,9 @@ function ConnectedDriveSyncDialog({
|
|
|
7691
7693
|
)) }) })
|
|
7692
7694
|
}
|
|
7693
7695
|
),
|
|
7694
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
7696
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.SyncOptions, { children: [
|
|
7695
7697
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7696
|
-
|
|
7698
|
+
chunkTQUYWUEE_cjs.SyncOptionToggle,
|
|
7697
7699
|
{
|
|
7698
7700
|
checked: skipDuplicates,
|
|
7699
7701
|
onCheckedChange: setSkipDuplicates,
|
|
@@ -7702,7 +7704,7 @@ function ConnectedDriveSyncDialog({
|
|
|
7702
7704
|
}
|
|
7703
7705
|
),
|
|
7704
7706
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7705
|
-
|
|
7707
|
+
chunkTQUYWUEE_cjs.SyncOptionToggle,
|
|
7706
7708
|
{
|
|
7707
7709
|
checked: autoRename,
|
|
7708
7710
|
onCheckedChange: setAutoRename,
|
|
@@ -7711,7 +7713,7 @@ function ConnectedDriveSyncDialog({
|
|
|
7711
7713
|
}
|
|
7712
7714
|
),
|
|
7713
7715
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7714
|
-
|
|
7716
|
+
chunkTQUYWUEE_cjs.SyncOptionToggle,
|
|
7715
7717
|
{
|
|
7716
7718
|
checked: shared,
|
|
7717
7719
|
onCheckedChange: setShared,
|
|
@@ -7720,7 +7722,7 @@ function ConnectedDriveSyncDialog({
|
|
|
7720
7722
|
}
|
|
7721
7723
|
),
|
|
7722
7724
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7723
|
-
|
|
7725
|
+
chunkTQUYWUEE_cjs.SyncOptionToggle,
|
|
7724
7726
|
{
|
|
7725
7727
|
checked: autoSync,
|
|
7726
7728
|
onCheckedChange: setAutoSync,
|
|
@@ -7732,7 +7734,7 @@ function ConnectedDriveSyncDialog({
|
|
|
7732
7734
|
] })
|
|
7733
7735
|
] }),
|
|
7734
7736
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7735
|
-
|
|
7737
|
+
chunkTQUYWUEE_cjs.SyncDialogFooter,
|
|
7736
7738
|
{
|
|
7737
7739
|
onCancel: () => onOpenChange(false),
|
|
7738
7740
|
onSave: handleEnableSubmit,
|
|
@@ -7764,7 +7766,7 @@ function BillingProjectEntity({
|
|
|
7764
7766
|
subscription = "none",
|
|
7765
7767
|
...props
|
|
7766
7768
|
}) {
|
|
7767
|
-
const { stripeEnabled } =
|
|
7769
|
+
const { stripeEnabled } = chunkP2YM67Y5_cjs.useBillingSupport();
|
|
7768
7770
|
const isPaid2 = stripeEnabled && (subscription === "active" || subscription === "past_due" || subscription === "dev");
|
|
7769
7771
|
return /* @__PURE__ */ jsxRuntime.jsx(ui.ProjectEntity, { ...props, subscription, isPaid: isPaid2 });
|
|
7770
7772
|
}
|
|
@@ -7791,8 +7793,8 @@ function InvoicesModal({
|
|
|
7791
7793
|
key: inv.number ?? String(i),
|
|
7792
7794
|
date: formatInvoiceDate(inv.date),
|
|
7793
7795
|
kind: KIND_LABELS[inv.kind],
|
|
7794
|
-
amount:
|
|
7795
|
-
amountNote: inv.amount_ex_vat != null && inv.amount_ex_vat !== inv.amount ? `${
|
|
7796
|
+
amount: chunkP2YM67Y5_cjs.formatMoney(inv.amount, inv.currency),
|
|
7797
|
+
amountNote: inv.amount_ex_vat != null && inv.amount_ex_vat !== inv.amount ? `${chunkP2YM67Y5_cjs.formatMoney(inv.amount_ex_vat, inv.currency)} ex VAT` : void 0,
|
|
7796
7798
|
status: inv.status,
|
|
7797
7799
|
isPaid: isPaid2,
|
|
7798
7800
|
href: inv.hosted_invoice_url ?? inv.url ?? inv.pdf_url ?? void 0,
|
|
@@ -7800,7 +7802,7 @@ function InvoicesModal({
|
|
|
7800
7802
|
};
|
|
7801
7803
|
});
|
|
7802
7804
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
7803
|
-
|
|
7805
|
+
chunkTQUYWUEE_cjs.InvoicesDialog,
|
|
7804
7806
|
{
|
|
7805
7807
|
open,
|
|
7806
7808
|
onOpenChange,
|
|
@@ -7827,7 +7829,7 @@ function StripeCheckoutModal({
|
|
|
7827
7829
|
const [clientSecret, setClientSecret] = react.useState(null);
|
|
7828
7830
|
const [isCreating, setIsCreating] = react.useState(false);
|
|
7829
7831
|
const [stripe, setStripe] = react.useState(null);
|
|
7830
|
-
const { stripeEnabled, checkout } =
|
|
7832
|
+
const { stripeEnabled, checkout } = chunkP2YM67Y5_cjs.useBillingSupport();
|
|
7831
7833
|
const createCheckout = react$1.useCreateProjectCheckout();
|
|
7832
7834
|
const refreshProject = react$1.useRefreshProject();
|
|
7833
7835
|
const invalidateProjects = react$1.useInvalidateProjects();
|
|
@@ -7854,7 +7856,7 @@ function StripeCheckoutModal({
|
|
|
7854
7856
|
projectExtId,
|
|
7855
7857
|
body: {
|
|
7856
7858
|
interval,
|
|
7857
|
-
packs:
|
|
7859
|
+
packs: chunkP2YM67Y5_cjs.PRO_PACKS,
|
|
7858
7860
|
ai_blocks: aiBlocks,
|
|
7859
7861
|
storage_blocks: storageBlocks,
|
|
7860
7862
|
addon_budget_pence: addonBudgetPence,
|
|
@@ -7870,7 +7872,7 @@ function StripeCheckoutModal({
|
|
|
7870
7872
|
},
|
|
7871
7873
|
onError: (error) => {
|
|
7872
7874
|
console.error("Failed to create checkout session:", error);
|
|
7873
|
-
const reason =
|
|
7875
|
+
const reason = chunkP2YM67Y5_cjs.apiErrorDetail(error)?.message;
|
|
7874
7876
|
shell.notify.error(
|
|
7875
7877
|
reason ? `Checkout didn't start: ${reason}` : "Checkout didn't start. Try again."
|
|
7876
7878
|
);
|
|
@@ -7903,9 +7905,9 @@ function StripeCheckoutModal({
|
|
|
7903
7905
|
}
|
|
7904
7906
|
}, [open]);
|
|
7905
7907
|
const isStripeConfigured = stripeEnabled;
|
|
7906
|
-
const vatNote = quote ? `${
|
|
7908
|
+
const vatNote = quote ? `${chunkP2YM67Y5_cjs.checkoutItemsLabel(aiBlocks, storageBlocks)} \xB7 ${chunkP2YM67Y5_cjs.quoteTotalLine(quote)}` : null;
|
|
7907
7909
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
7908
|
-
|
|
7910
|
+
chunkTQUYWUEE_cjs.CheckoutDialogFrame,
|
|
7909
7911
|
{
|
|
7910
7912
|
open,
|
|
7911
7913
|
onOpenChange,
|
|
@@ -7915,7 +7917,7 @@ function StripeCheckoutModal({
|
|
|
7915
7917
|
children: clientSecret && !!stripe && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
7916
7918
|
vatNote && /* @__PURE__ */ jsxRuntime.jsx("p", { "data-testid": "checkout-vat-note", className: "mb-4 text-sm text-muted-foreground", children: vatNote }),
|
|
7917
7919
|
checkout?.render(stripe, { clientSecret, onComplete: handleComplete }),
|
|
7918
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-3", children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7920
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-3", children: /* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.MoreInfo, { title: "Paying", label: "Payment help", testId: "checkout-payment-help", children: [
|
|
7919
7921
|
/* @__PURE__ */ jsxRuntime.jsx("p", { "data-testid": "checkout-decline-note", children: "Card declined? Nothing was charged. Try again or use another card." }),
|
|
7920
7922
|
/* @__PURE__ */ jsxRuntime.jsx("p", { "data-testid": "checkout-vat-id-note", children: "No VAT number? Leave \u2018purchasing as a business\u2019 unticked." }),
|
|
7921
7923
|
/* @__PURE__ */ jsxRuntime.jsx("p", { children: "Add-ons chosen here are on the first invoice with the plan and renew with it until you reduce them." })
|
|
@@ -7957,31 +7959,31 @@ function defaultBillingCountry(languages = typeof navigator === "undefined" ? []
|
|
|
7957
7959
|
}
|
|
7958
7960
|
var choiceForPacks = (packs) => packs > 0 ? "pro" : "free";
|
|
7959
7961
|
function proCard(selected, isAnnual, prices) {
|
|
7960
|
-
const packs =
|
|
7962
|
+
const packs = chunkP2YM67Y5_cjs.PLAN_CHOICE_PACKS.pro;
|
|
7961
7963
|
const currency = prices.monthly?.currency ?? prices.annual?.currency ?? "gbp";
|
|
7962
|
-
const monthly =
|
|
7963
|
-
const annual =
|
|
7964
|
+
const monthly = chunkP2YM67Y5_cjs.packPrice(prices.monthly, packs);
|
|
7965
|
+
const annual = chunkP2YM67Y5_cjs.packPrice(prices.annual, packs);
|
|
7964
7966
|
const current = isAnnual ? annual : monthly;
|
|
7965
7967
|
const effectiveMonthly = current ? isAnnual ? current.amount_ex_vat / 12 : current.amount_ex_vat : null;
|
|
7966
7968
|
return {
|
|
7967
7969
|
id: packs,
|
|
7968
|
-
name:
|
|
7970
|
+
name: chunkP2YM67Y5_cjs.planNameForPacks(packs),
|
|
7969
7971
|
isSelected: selected === "pro",
|
|
7970
7972
|
price: current && effectiveMonthly != null ? {
|
|
7971
7973
|
annual: isAnnual,
|
|
7972
|
-
yearlyStrike: isAnnual && monthly && monthly.amount_ex_vat * 12 > current.amount_ex_vat ?
|
|
7973
|
-
yearlyTotal: isAnnual ?
|
|
7974
|
+
yearlyStrike: isAnnual && monthly && monthly.amount_ex_vat * 12 > current.amount_ex_vat ? chunkP2YM67Y5_cjs.formatMoney(monthly.amount_ex_vat * 12, currency) : void 0,
|
|
7975
|
+
yearlyTotal: isAnnual ? chunkP2YM67Y5_cjs.formatMoney(current.amount_ex_vat, currency) : void 0,
|
|
7974
7976
|
intervalLabel: isAnnual ? "/yr + VAT" : "/mo",
|
|
7975
|
-
monthly:
|
|
7977
|
+
monthly: chunkP2YM67Y5_cjs.formatMoney(Math.round(effectiveMonthly), currency),
|
|
7976
7978
|
taxLabel: "+ VAT",
|
|
7977
7979
|
// The inclusive figure for a UK customer, right under the headline.
|
|
7978
|
-
note: `${
|
|
7980
|
+
note: `${chunkP2YM67Y5_cjs.formatMoney(current.amount, currency)}${isAnnual ? "/yr" : "/mo"} incl. UK VAT`
|
|
7979
7981
|
} : void 0,
|
|
7980
7982
|
features: [
|
|
7981
|
-
`${react$1.formatGbp(
|
|
7982
|
-
`${
|
|
7983
|
+
`${react$1.formatGbp(chunkP2YM67Y5_cjs.PRO_AI_GBP)} of AI usage / month`,
|
|
7984
|
+
`${chunkP2YM67Y5_cjs.PRO_STORAGE_GB} GB storage`,
|
|
7983
7985
|
"Unlimited collaborators",
|
|
7984
|
-
...isAnnual ? [
|
|
7986
|
+
...isAnnual ? [chunkP2YM67Y5_cjs.ANNUAL_PREMIUM_AI_NOTE] : []
|
|
7985
7987
|
]
|
|
7986
7988
|
};
|
|
7987
7989
|
}
|
|
@@ -7993,9 +7995,9 @@ function buildPlanCards(selected, isAnnual, prices, isOnFree) {
|
|
|
7993
7995
|
isCurrent: isOnFree,
|
|
7994
7996
|
isSelected: selected === "free" && !isOnFree,
|
|
7995
7997
|
features: [
|
|
7996
|
-
`${react$1.formatGbp(
|
|
7997
|
-
`${
|
|
7998
|
-
|
|
7998
|
+
`${react$1.formatGbp(chunkP2YM67Y5_cjs.FREE_AI_GBP)} of AI usage / month`,
|
|
7999
|
+
`${chunkP2YM67Y5_cjs.FREE_STORAGE_MB.toLocaleString("en-US")} MB storage`,
|
|
8000
|
+
chunkP2YM67Y5_cjs.FREE_COLLABORATORS === 0 ? "Just you" : `${chunkP2YM67Y5_cjs.FREE_COLLABORATORS} collaborators`
|
|
7999
8001
|
]
|
|
8000
8002
|
};
|
|
8001
8003
|
return [free, proCard(selected, isAnnual, prices)];
|
|
@@ -8008,7 +8010,7 @@ function PlanChoiceCards({
|
|
|
8008
8010
|
isOnFree = false
|
|
8009
8011
|
}) {
|
|
8010
8012
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8011
|
-
|
|
8013
|
+
chunkTQUYWUEE_cjs.PlanCardGrid,
|
|
8012
8014
|
{
|
|
8013
8015
|
plans: buildPlanCards(selected, isAnnual, prices, isOnFree),
|
|
8014
8016
|
onSelect: (id) => onSelect(choiceForPacks(id))
|
|
@@ -8017,13 +8019,13 @@ function PlanChoiceCards({
|
|
|
8017
8019
|
}
|
|
8018
8020
|
function PlanInfoPopover2() {
|
|
8019
8021
|
const { openSettings } = chunkCNHUJRQ4_cjs.useBlocksEnvironment();
|
|
8020
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8022
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanInfoPopover, { onOpenModelList: () => openSettings("chat") });
|
|
8021
8023
|
}
|
|
8022
8024
|
function CheckoutAddonBudget({
|
|
8023
8025
|
value,
|
|
8024
8026
|
onChange
|
|
8025
8027
|
}) {
|
|
8026
|
-
const budget =
|
|
8028
|
+
const budget = chunkP2YM67Y5_cjs.parseBudgetPounds(value);
|
|
8027
8029
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8028
8030
|
"div",
|
|
8029
8031
|
{
|
|
@@ -8046,7 +8048,7 @@ function CheckoutAddonBudget({
|
|
|
8046
8048
|
step: 25,
|
|
8047
8049
|
className: "h-8 w-24",
|
|
8048
8050
|
value,
|
|
8049
|
-
placeholder: String(
|
|
8051
|
+
placeholder: String(chunkP2YM67Y5_cjs.DEFAULT_SPEND_CAP_PENCE / 100),
|
|
8050
8052
|
onChange: (e) => onChange(e.target.value),
|
|
8051
8053
|
"aria-invalid": budget === void 0,
|
|
8052
8054
|
"data-testid": "checkout-addon-budget-input"
|
|
@@ -8064,7 +8066,7 @@ function BlockStepper({
|
|
|
8064
8066
|
onChange,
|
|
8065
8067
|
testId
|
|
8066
8068
|
}) {
|
|
8067
|
-
const set = (n) => onChange(Math.max(0, Math.min(
|
|
8069
|
+
const set = (n) => onChange(Math.max(0, Math.min(chunkP2YM67Y5_cjs.MAX_CHECKOUT_BLOCKS, n)));
|
|
8068
8070
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8069
8071
|
"div",
|
|
8070
8072
|
{
|
|
@@ -8108,7 +8110,7 @@ function BlockStepper({
|
|
|
8108
8110
|
className: "size-8",
|
|
8109
8111
|
"aria-label": `More: ${label}`,
|
|
8110
8112
|
onClick: () => set(value + 1),
|
|
8111
|
-
disabled: value >=
|
|
8113
|
+
disabled: value >= chunkP2YM67Y5_cjs.MAX_CHECKOUT_BLOCKS,
|
|
8112
8114
|
"data-testid": `${testId}-increment`,
|
|
8113
8115
|
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { className: "size-4" })
|
|
8114
8116
|
}
|
|
@@ -8125,8 +8127,8 @@ function CheckoutAddonBlocks({
|
|
|
8125
8127
|
onStorageBlocksChange,
|
|
8126
8128
|
price
|
|
8127
8129
|
}) {
|
|
8128
|
-
const ai =
|
|
8129
|
-
const storage =
|
|
8130
|
+
const ai = chunkP2YM67Y5_cjs.addonPrice(price, "ai_usage");
|
|
8131
|
+
const storage = chunkP2YM67Y5_cjs.addonPrice(price, "storage");
|
|
8130
8132
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8131
8133
|
"div",
|
|
8132
8134
|
{
|
|
@@ -8136,8 +8138,8 @@ function CheckoutAddonBlocks({
|
|
|
8136
8138
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8137
8139
|
BlockStepper,
|
|
8138
8140
|
{
|
|
8139
|
-
label: `+${react$1.formatGbp(ai?.ai_gbp ||
|
|
8140
|
-
priceText:
|
|
8141
|
+
label: `+${react$1.formatGbp(ai?.ai_gbp || chunkP2YM67Y5_cjs.ADDON_BLOCK_AI_GBP)} of AI usage`,
|
|
8142
|
+
priceText: chunkP2YM67Y5_cjs.checkoutBlockPriceText(price, "ai_usage"),
|
|
8141
8143
|
value: aiBlocks,
|
|
8142
8144
|
onChange: onAiBlocksChange,
|
|
8143
8145
|
testId: "checkout-ai-blocks"
|
|
@@ -8146,8 +8148,8 @@ function CheckoutAddonBlocks({
|
|
|
8146
8148
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8147
8149
|
BlockStepper,
|
|
8148
8150
|
{
|
|
8149
|
-
label: `+${storage?.storage_gb ||
|
|
8150
|
-
priceText:
|
|
8151
|
+
label: `+${storage?.storage_gb || chunkP2YM67Y5_cjs.STORAGE_BLOCK_GB} GB storage`,
|
|
8152
|
+
priceText: chunkP2YM67Y5_cjs.checkoutBlockPriceText(price, "storage"),
|
|
8151
8153
|
value: storageBlocks,
|
|
8152
8154
|
onChange: onStorageBlocksChange,
|
|
8153
8155
|
testId: "checkout-storage-blocks"
|
|
@@ -8202,14 +8204,14 @@ function ReferralRewardSummary2({
|
|
|
8202
8204
|
if (!reward) return null;
|
|
8203
8205
|
const applied = totalCents != null && currency ? applyReferralReward(totalCents, reward, currency) : null;
|
|
8204
8206
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8205
|
-
|
|
8207
|
+
chunkTQUYWUEE_cjs.ReferralRewardSummary,
|
|
8206
8208
|
{
|
|
8207
|
-
amountLabel:
|
|
8209
|
+
amountLabel: chunkP2YM67Y5_cjs.formatMoney(reward.amount, reward.currency),
|
|
8208
8210
|
breakdown: applied && totalCents != null && currency ? {
|
|
8209
|
-
subtotal:
|
|
8210
|
-
reward:
|
|
8211
|
-
youPay:
|
|
8212
|
-
rollover: applied.remaining > 0 ?
|
|
8211
|
+
subtotal: chunkP2YM67Y5_cjs.formatMoney(totalCents, currency),
|
|
8212
|
+
reward: chunkP2YM67Y5_cjs.formatMoney(applied.bonus, currency),
|
|
8213
|
+
youPay: chunkP2YM67Y5_cjs.formatMoney(applied.youPay, currency),
|
|
8214
|
+
rollover: applied.remaining > 0 ? chunkP2YM67Y5_cjs.formatMoney(applied.remaining, currency) : void 0
|
|
8213
8215
|
} : void 0
|
|
8214
8216
|
}
|
|
8215
8217
|
);
|
|
@@ -8217,7 +8219,7 @@ function ReferralRewardSummary2({
|
|
|
8217
8219
|
function ReferralRewardNote2() {
|
|
8218
8220
|
const reward = useReferralReward();
|
|
8219
8221
|
if (!reward) return null;
|
|
8220
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8222
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.ReferralRewardNote, { amountLabel: chunkP2YM67Y5_cjs.formatMoney(reward.amount, reward.currency) });
|
|
8221
8223
|
}
|
|
8222
8224
|
function CheckoutTotal({
|
|
8223
8225
|
state,
|
|
@@ -8246,7 +8248,7 @@ function CheckoutTotal({
|
|
|
8246
8248
|
className: "text-sm font-medium text-foreground",
|
|
8247
8249
|
"data-testid": "checkout-total",
|
|
8248
8250
|
"aria-live": "polite",
|
|
8249
|
-
children: state.quote && !state.isLoading ?
|
|
8251
|
+
children: state.quote && !state.isLoading ? chunkP2YM67Y5_cjs.quoteTotalLine(state.quote) : state.isLoading ? "Calculating total\u2026" : state.error
|
|
8250
8252
|
}
|
|
8251
8253
|
)
|
|
8252
8254
|
] });
|
|
@@ -8279,13 +8281,13 @@ function useCheckoutQuote({
|
|
|
8279
8281
|
...aiBlocks || storageBlocks ? { addons: { ai_usage: aiBlocks, storage: storageBlocks } } : {}
|
|
8280
8282
|
} : null
|
|
8281
8283
|
);
|
|
8282
|
-
const { code, message } = query.isError ?
|
|
8283
|
-
const locationInvalid = code ===
|
|
8284
|
+
const { code, message } = query.isError ? chunkP2YM67Y5_cjs.quoteError(query.error) : {};
|
|
8285
|
+
const locationInvalid = code === chunkP2YM67Y5_cjs.TAX_LOCATION_INVALID;
|
|
8284
8286
|
const isLoading = enabled && (query.isLoading || postal !== postalCode.trim());
|
|
8285
8287
|
return {
|
|
8286
8288
|
quote: query.data,
|
|
8287
8289
|
isLoading,
|
|
8288
|
-
showPostcode:
|
|
8290
|
+
showPostcode: chunkP2YM67Y5_cjs.POSTCODE_COUNTRIES.includes(country) || locationInvalid || postalCode !== "",
|
|
8289
8291
|
error: query.isError ? locationInvalid ? message ?? "Enter your ZIP / postal code to see the total." : message ?? "Couldn't calculate tax. Stripe shows the total next." : null,
|
|
8290
8292
|
canContinue: !isLoading && (!!query.data || query.isError && !locationInvalid)
|
|
8291
8293
|
};
|
|
@@ -8294,7 +8296,7 @@ function SubscriptionPlans({ projectExtId, onDismiss }) {
|
|
|
8294
8296
|
const { data: products, isLoading, error } = react$1.useProducts();
|
|
8295
8297
|
const [isAnnual, setIsAnnual] = react.useState(false);
|
|
8296
8298
|
const [promoCode, setPromoCode] = react.useState("");
|
|
8297
|
-
const [addonBudget, setAddonBudget] = react.useState(String(
|
|
8299
|
+
const [addonBudget, setAddonBudget] = react.useState(String(chunkP2YM67Y5_cjs.DEFAULT_SPEND_CAP_PENCE / 100));
|
|
8298
8300
|
const [checkoutBudget, setCheckoutBudget] = react.useState(null);
|
|
8299
8301
|
const [aiBlocks, setAiBlocks] = react.useState(0);
|
|
8300
8302
|
const [storageBlocks, setStorageBlocks] = react.useState(0);
|
|
@@ -8312,31 +8314,31 @@ function SubscriptionPlans({ projectExtId, onDismiss }) {
|
|
|
8312
8314
|
storageBlocks,
|
|
8313
8315
|
enabled: !!products?.length
|
|
8314
8316
|
});
|
|
8315
|
-
if (isLoading) return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8316
|
-
if (error) return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8317
|
-
if (!products || products.length === 0) return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8318
|
-
const prices =
|
|
8317
|
+
if (isLoading) return /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanNotice, { children: "Loading plans\u2026" });
|
|
8318
|
+
if (error) return /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanNotice, { tone: "error", children: "Plans didn't load. Try again." });
|
|
8319
|
+
if (!products || products.length === 0) return /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanNotice, { children: "No plans available." });
|
|
8320
|
+
const prices = chunkP2YM67Y5_cjs.findProPrices(products);
|
|
8319
8321
|
const intervalPrice = isAnnual ? prices.annual : prices.monthly;
|
|
8320
|
-
const selectedPrice =
|
|
8322
|
+
const selectedPrice = chunkP2YM67Y5_cjs.packPrice(intervalPrice);
|
|
8321
8323
|
if (!intervalPrice) return null;
|
|
8322
8324
|
const interval = isAnnual ? "year" : "month";
|
|
8323
|
-
const savingsPercent =
|
|
8325
|
+
const savingsPercent = chunkP2YM67Y5_cjs.calcSavingsPercent(prices.monthly, prices.annual);
|
|
8324
8326
|
const handleSubscribe = () => {
|
|
8325
8327
|
setCheckoutInterval(interval);
|
|
8326
|
-
const parsed =
|
|
8327
|
-
setCheckoutBudget(parsed == null || parsed ===
|
|
8328
|
+
const parsed = chunkP2YM67Y5_cjs.parseBudgetPounds(addonBudget);
|
|
8329
|
+
setCheckoutBudget(parsed == null || parsed === chunkP2YM67Y5_cjs.DEFAULT_SPEND_CAP_PENCE ? null : parsed);
|
|
8328
8330
|
setCheckoutQuote(quote.quote);
|
|
8329
8331
|
setIsCheckoutModalOpen(true);
|
|
8330
8332
|
};
|
|
8331
8333
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8332
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
8334
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.PlanStack, { children: [
|
|
8333
8335
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8334
|
-
|
|
8336
|
+
chunkTQUYWUEE_cjs.PlanPickerHeader,
|
|
8335
8337
|
{
|
|
8336
8338
|
title: "Plan",
|
|
8337
8339
|
info: /* @__PURE__ */ jsxRuntime.jsx(PlanInfoPopover2, {}),
|
|
8338
8340
|
toggle: /* @__PURE__ */ jsxRuntime.jsx(
|
|
8339
|
-
|
|
8341
|
+
chunkTQUYWUEE_cjs.PricingToggle,
|
|
8340
8342
|
{
|
|
8341
8343
|
isAnnual,
|
|
8342
8344
|
onToggle: () => setIsAnnual(!isAnnual),
|
|
@@ -8373,7 +8375,7 @@ function SubscriptionPlans({ projectExtId, onDismiss }) {
|
|
|
8373
8375
|
currency: intervalPrice.currency
|
|
8374
8376
|
}
|
|
8375
8377
|
),
|
|
8376
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8378
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PromoCodeInput, { value: promoCode, onChange: setPromoCode }),
|
|
8377
8379
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8378
8380
|
CheckoutCountrySelect,
|
|
8379
8381
|
{
|
|
@@ -8385,9 +8387,9 @@ function SubscriptionPlans({ projectExtId, onDismiss }) {
|
|
|
8385
8387
|
}
|
|
8386
8388
|
),
|
|
8387
8389
|
/* @__PURE__ */ jsxRuntime.jsx(CheckoutTotal, { state: quote, postalCode, onPostalCodeChange: setPostalCode }),
|
|
8388
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
8390
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.PlanActionRow, { children: [
|
|
8389
8391
|
onDismiss && /* @__PURE__ */ jsxRuntime.jsx(
|
|
8390
|
-
|
|
8392
|
+
chunkTQUYWUEE_cjs.PlanActionButton,
|
|
8391
8393
|
{
|
|
8392
8394
|
tone: "muted",
|
|
8393
8395
|
fill: true,
|
|
@@ -8398,11 +8400,11 @@ function SubscriptionPlans({ projectExtId, onDismiss }) {
|
|
|
8398
8400
|
}
|
|
8399
8401
|
),
|
|
8400
8402
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8401
|
-
|
|
8403
|
+
chunkTQUYWUEE_cjs.PlanActionButton,
|
|
8402
8404
|
{
|
|
8403
8405
|
fill: true,
|
|
8404
8406
|
onClick: handleSubscribe,
|
|
8405
|
-
disabled: !selectedPrice ||
|
|
8407
|
+
disabled: !selectedPrice || chunkP2YM67Y5_cjs.parseBudgetPounds(addonBudget) === void 0 || !quote.canContinue,
|
|
8406
8408
|
size: "sm",
|
|
8407
8409
|
"data-testid": "subscribe-button",
|
|
8408
8410
|
children: "Continue to payment"
|
|
@@ -8442,7 +8444,7 @@ var FALLBACK_MESSAGES = {
|
|
|
8442
8444
|
BILLING_ADDRESS_REQUIRED: "Add a billing address first."
|
|
8443
8445
|
};
|
|
8444
8446
|
function addonErrorMessage(error) {
|
|
8445
|
-
const detail =
|
|
8447
|
+
const detail = chunkP2YM67Y5_cjs.apiErrorDetail(error);
|
|
8446
8448
|
if (detail && typeof detail === "object") {
|
|
8447
8449
|
const { code, message } = detail;
|
|
8448
8450
|
if (message) return message;
|
|
@@ -8464,18 +8466,18 @@ function chargeRefusalMessage(error) {
|
|
|
8464
8466
|
return code ? REFUSALS[code] : null;
|
|
8465
8467
|
}
|
|
8466
8468
|
function addonErrorCode(error) {
|
|
8467
|
-
const detail =
|
|
8469
|
+
const detail = chunkP2YM67Y5_cjs.apiErrorDetail(error);
|
|
8468
8470
|
if (detail && typeof detail === "object") {
|
|
8469
8471
|
const code = detail.code;
|
|
8470
8472
|
if (code && code in FALLBACK_MESSAGES) return code;
|
|
8471
8473
|
}
|
|
8472
8474
|
return null;
|
|
8473
8475
|
}
|
|
8474
|
-
var addedMessage = (kind, blockAiGbp, blockStorageGb) => kind === "ai_usage" ? `${react$1.formatGbp(blockAiGbp ??
|
|
8476
|
+
var addedMessage = (kind, blockAiGbp, blockStorageGb) => kind === "ai_usage" ? `${react$1.formatGbp(blockAiGbp ?? chunkP2YM67Y5_cjs.ADDON_BLOCK_AI_GBP)} of AI usage added` : `${blockStorageGb ?? chunkP2YM67Y5_cjs.STORAGE_BLOCK_GB} GB added`;
|
|
8475
8477
|
function useAddonPurchase() {
|
|
8476
8478
|
const addBlock = react$1.useAddProjectAddonBlock();
|
|
8477
8479
|
const { mutate } = addBlock;
|
|
8478
|
-
const { onAddonBlocksBought } =
|
|
8480
|
+
const { onAddonBlocksBought } = chunkP2YM67Y5_cjs.useBillingSupport();
|
|
8479
8481
|
const buy = react.useCallback(
|
|
8480
8482
|
(kind, projectExtId, options2) => {
|
|
8481
8483
|
mutate(
|
|
@@ -8519,7 +8521,7 @@ function PlanChangeLines({
|
|
|
8519
8521
|
isError,
|
|
8520
8522
|
className
|
|
8521
8523
|
}) {
|
|
8522
|
-
const lines = preview ?
|
|
8524
|
+
const lines = preview ? chunkP2YM67Y5_cjs.planPreviewLines(preview) : [{ id: "pay-today", text: isError ? chunkP2YM67Y5_cjs.PAY_TODAY_UNPRICED : "Checking price\u2026" }];
|
|
8523
8525
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className, "data-testid": "plan-change-lines", children: lines.map((line) => /* @__PURE__ */ jsxRuntime.jsx("p", { "data-testid": `plan-change-${line.id}`, children: line.text }, line.id)) });
|
|
8524
8526
|
}
|
|
8525
8527
|
var BANK_CONFIRM_PLAN_CHANGE = "Confirm with your bank. Nothing is charged until you do.";
|
|
@@ -8527,13 +8529,13 @@ function notifyPlanChange(data, fallback, planName2) {
|
|
|
8527
8529
|
const outcome = data?.plan_change;
|
|
8528
8530
|
switch (outcome?.result) {
|
|
8529
8531
|
case "upgraded": {
|
|
8530
|
-
const plan =
|
|
8531
|
-
const charged = outcome.charged_pence > 0 ? ` \xB7 ${
|
|
8532
|
+
const plan = chunkP2YM67Y5_cjs.planNameForPacks(data?.addons?.packs ?? data?.packs);
|
|
8533
|
+
const charged = outcome.charged_pence > 0 ? ` \xB7 ${chunkP2YM67Y5_cjs.formatMoney(outcome.charged_pence, "gbp")} charged` : "";
|
|
8532
8534
|
shell.notify.success(`Upgraded to ${plan}${charged}`);
|
|
8533
8535
|
break;
|
|
8534
8536
|
}
|
|
8535
8537
|
case "scheduled": {
|
|
8536
|
-
const when2 =
|
|
8538
|
+
const when2 = chunkP2YM67Y5_cjs.formatPeriodEnd(data?.addons?.period_end ?? data?.current_period_end);
|
|
8537
8539
|
shell.notify.success(when2 ? `Scheduled for ${when2}` : fallback);
|
|
8538
8540
|
break;
|
|
8539
8541
|
}
|
|
@@ -8566,23 +8568,23 @@ function ChangeProPlan({
|
|
|
8566
8568
|
const { data: products } = react$1.useProducts();
|
|
8567
8569
|
const changePlan = react$1.useChangeProjectPlan();
|
|
8568
8570
|
const cancel = react$1.useCancelProjectSubscription();
|
|
8569
|
-
const prices =
|
|
8571
|
+
const prices = chunkP2YM67Y5_cjs.findProPrices(products);
|
|
8570
8572
|
const addons = project.addons;
|
|
8571
8573
|
const isCanceling = project.cancel_at_period_end === true || project.subscription === "canceled";
|
|
8572
|
-
const currentPacks = Math.max(addons?.packs ?? project.packs ??
|
|
8573
|
-
const isLegacyMultiPack = currentPacks >
|
|
8574
|
+
const currentPacks = Math.max(addons?.packs ?? project.packs ?? chunkP2YM67Y5_cjs.PRO_PACKS, chunkP2YM67Y5_cjs.PRO_PACKS);
|
|
8575
|
+
const isLegacyMultiPack = currentPacks > chunkP2YM67Y5_cjs.PRO_PACKS;
|
|
8574
8576
|
const currentInterval = project.plan_interval === "year" ? "year" : "month";
|
|
8575
8577
|
const scheduledPacks = isCanceling ? 0 : addons?.packs_next ?? currentPacks;
|
|
8576
8578
|
const scheduledInterval = addons?.pending_interval ?? currentInterval;
|
|
8577
8579
|
const [targetPacks, setTargetPacks] = react.useState(scheduledPacks);
|
|
8578
8580
|
const [chosenInterval, setChosenInterval] = react.useState(scheduledInterval);
|
|
8579
|
-
const targetInterval = targetPacks >
|
|
8581
|
+
const targetInterval = targetPacks > chunkP2YM67Y5_cjs.PRO_PACKS ? currentInterval : chosenInterval;
|
|
8580
8582
|
const periodEnd = formatDate(addons?.period_end ?? project.current_period_end);
|
|
8581
8583
|
const when2 = periodEnd ?? "the end of the period";
|
|
8582
8584
|
const shortWhen = periodEnd ? periodEnd.replace(/ \d{4}$/, "") : "period end";
|
|
8583
8585
|
const isPending = changePlan.isPending || cancel.isPending;
|
|
8584
8586
|
const sameAsScheduled = targetPacks === scheduledPacks && (targetPacks === 0 || targetInterval === scheduledInterval);
|
|
8585
|
-
const packOptions = isLegacyMultiPack ? [currentPacks,
|
|
8587
|
+
const packOptions = isLegacyMultiPack ? [currentPacks, chunkP2YM67Y5_cjs.PRO_PACKS, 0] : [chunkP2YM67Y5_cjs.PRO_PACKS, 0];
|
|
8586
8588
|
const intervalPrice = targetInterval === "year" ? prices.annual : prices.monthly;
|
|
8587
8589
|
const currency = intervalPrice?.currency ?? project.currency ?? "gbp";
|
|
8588
8590
|
const preview = react$1.usePreviewProjectPlanChange(
|
|
@@ -8590,7 +8592,7 @@ function ChangeProPlan({
|
|
|
8590
8592
|
sameAsScheduled || targetPacks === 0 ? null : { packs: targetPacks, interval: targetInterval }
|
|
8591
8593
|
);
|
|
8592
8594
|
const noChange = sameAsScheduled || preview.data?.unchanged === true;
|
|
8593
|
-
const nameFor = (packs) => packs === currentPacks && packs > 0 ?
|
|
8595
|
+
const nameFor = (packs) => packs === currentPacks && packs > 0 ? chunkP2YM67Y5_cjs.proTierName(project) : chunkP2YM67Y5_cjs.planNameForPacks(packs);
|
|
8594
8596
|
const effects = [];
|
|
8595
8597
|
const target = nameFor(targetPacks);
|
|
8596
8598
|
if (targetPacks === 0) {
|
|
@@ -8600,7 +8602,7 @@ function ChangeProPlan({
|
|
|
8600
8602
|
if (targetPacks < currentPacks) {
|
|
8601
8603
|
effects.push(`Changes to one Pro licence on ${when2}. No refund.`);
|
|
8602
8604
|
} else if (!isCanceling && addons?.packs_next != null) {
|
|
8603
|
-
effects.push(`Cancels the change to ${
|
|
8605
|
+
effects.push(`Cancels the change to ${chunkP2YM67Y5_cjs.planNameForPacks(addons.packs_next)}.`);
|
|
8604
8606
|
}
|
|
8605
8607
|
if (targetInterval !== currentInterval) {
|
|
8606
8608
|
effects.push(`${targetInterval === "year" ? "Annual" : "Monthly"} billing from ${when2}.`);
|
|
@@ -8639,33 +8641,33 @@ function ChangeProPlan({
|
|
|
8639
8641
|
if (packs === 0) {
|
|
8640
8642
|
return {
|
|
8641
8643
|
total: "\xA30",
|
|
8642
|
-
summary: `${react$1.formatGbp(
|
|
8644
|
+
summary: `${react$1.formatGbp(chunkP2YM67Y5_cjs.FREE_AI_GBP)} of AI usage \xB7 ${chunkP2YM67Y5_cjs.FREE_STORAGE_MB} MB \xB7 just you`
|
|
8643
8645
|
};
|
|
8644
8646
|
}
|
|
8645
|
-
const allowance = `${react$1.formatGbp(
|
|
8646
|
-
const legacy = packs >
|
|
8647
|
-
const exVat = legacy ? project.amount_ex_vat :
|
|
8647
|
+
const allowance = `${react$1.formatGbp(chunkP2YM67Y5_cjs.PRO_AI_GBP * packs)} of AI usage \xB7 ${chunkP2YM67Y5_cjs.PRO_STORAGE_GB * packs} GB`;
|
|
8648
|
+
const legacy = packs > chunkP2YM67Y5_cjs.PRO_PACKS;
|
|
8649
|
+
const exVat = legacy ? project.amount_ex_vat : chunkP2YM67Y5_cjs.packPrice(intervalPrice)?.amount_ex_vat;
|
|
8648
8650
|
return {
|
|
8649
|
-
total: exVat != null ?
|
|
8651
|
+
total: exVat != null ? chunkP2YM67Y5_cjs.plusVat(exVat, currency) : void 0,
|
|
8650
8652
|
summary: allowance
|
|
8651
8653
|
};
|
|
8652
8654
|
};
|
|
8653
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8655
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.PlanStack, { gap: 4, testId: "change-pro-plan", children: [
|
|
8654
8656
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap items-center justify-between gap-2", children: [
|
|
8655
8657
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm font-medium text-foreground", children: "Billing" }),
|
|
8656
|
-
targetPacks >
|
|
8657
|
-
|
|
8658
|
+
targetPacks > chunkP2YM67Y5_cjs.PRO_PACKS ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-muted-foreground", "data-testid": "change-plan-interval-fixed", children: currentInterval === "year" ? "Annual" : "Monthly" }) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
8659
|
+
chunkTQUYWUEE_cjs.PricingToggle,
|
|
8658
8660
|
{
|
|
8659
8661
|
isAnnual: targetInterval === "year",
|
|
8660
8662
|
onToggle: () => setChosenInterval(targetInterval === "year" ? "month" : "year"),
|
|
8661
|
-
savingsPercent:
|
|
8663
|
+
savingsPercent: chunkP2YM67Y5_cjs.calcSavingsPercent(prices.monthly, prices.annual)
|
|
8662
8664
|
}
|
|
8663
8665
|
)
|
|
8664
8666
|
] }),
|
|
8665
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8667
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanStack, { gap: 2, children: packOptions.map((packs) => {
|
|
8666
8668
|
const { total, summary } = optionFor(packs);
|
|
8667
8669
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8668
|
-
|
|
8670
|
+
chunkTQUYWUEE_cjs.PlanTierOption,
|
|
8669
8671
|
{
|
|
8670
8672
|
onSelect: setTargetPacks,
|
|
8671
8673
|
option: {
|
|
@@ -8682,13 +8684,13 @@ function ChangeProPlan({
|
|
|
8682
8684
|
);
|
|
8683
8685
|
}) }),
|
|
8684
8686
|
isLegacyMultiPack && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap items-center gap-x-3 gap-y-1", children: [
|
|
8685
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
8686
|
-
|
|
8687
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.PlanNotice, { className: "text-xs", testId: "change-plan-legacy-note", children: [
|
|
8688
|
+
chunkP2YM67Y5_cjs.proTierName(project),
|
|
8687
8689
|
" is no longer sold"
|
|
8688
8690
|
] }),
|
|
8689
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
8691
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.MoreInfo, { title: "Legacy plan", testId: "change-plan-legacy-more-info", children: [
|
|
8690
8692
|
/* @__PURE__ */ jsxRuntime.jsxs("p", { children: [
|
|
8691
|
-
|
|
8693
|
+
chunkP2YM67Y5_cjs.proTierName(project),
|
|
8692
8694
|
" keeps renewing at its own price, with its allowance and add-ons, until you change it."
|
|
8693
8695
|
] }),
|
|
8694
8696
|
/* @__PURE__ */ jsxRuntime.jsxs("p", { children: [
|
|
@@ -8709,7 +8711,7 @@ function ChangeProPlan({
|
|
|
8709
8711
|
),
|
|
8710
8712
|
targetPacks > 0 && /* @__PURE__ */ jsxRuntime.jsx(ReferralRewardNote2, {}),
|
|
8711
8713
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8712
|
-
|
|
8714
|
+
chunkTQUYWUEE_cjs.PlanActionButton,
|
|
8713
8715
|
{
|
|
8714
8716
|
onClick: apply,
|
|
8715
8717
|
disabled: noChange || isPending,
|
|
@@ -8720,9 +8722,9 @@ function ChangeProPlan({
|
|
|
8720
8722
|
] });
|
|
8721
8723
|
}
|
|
8722
8724
|
function ChangePlanDialog({ project, open, onOpenChange }) {
|
|
8723
|
-
const isPro = !!project &&
|
|
8725
|
+
const isPro = !!project && chunkP2YM67Y5_cjs.isProProject(project);
|
|
8724
8726
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8725
|
-
|
|
8727
|
+
chunkTQUYWUEE_cjs.PlanDialogFrame,
|
|
8726
8728
|
{
|
|
8727
8729
|
open,
|
|
8728
8730
|
onOpenChange,
|
|
@@ -8742,14 +8744,14 @@ function ChangePlanDialog({ project, open, onOpenChange }) {
|
|
|
8742
8744
|
}
|
|
8743
8745
|
function ProjectsTable() {
|
|
8744
8746
|
const { data: projects, isLoading } = react$1.useProjects();
|
|
8745
|
-
const currentUserExtId =
|
|
8747
|
+
const currentUserExtId = chunkP2YM67Y5_cjs.useSelfExtId();
|
|
8746
8748
|
const { openProject } = chunkCNHUJRQ4_cjs.useBlocksEnvironment();
|
|
8747
8749
|
const updateProject = react$1.useUpdateProjectFields();
|
|
8748
8750
|
const [renameTarget, setRenameTarget] = react.useState(null);
|
|
8749
8751
|
const [renameValue, setRenameValue] = react.useState("");
|
|
8750
8752
|
const [invoicesTarget, setInvoicesTarget] = react.useState(null);
|
|
8751
8753
|
const [upgradeTarget, setUpgradeTarget] = react.useState(null);
|
|
8752
|
-
const { stripeEnabled } =
|
|
8754
|
+
const { stripeEnabled } = chunkP2YM67Y5_cjs.useBillingSupport();
|
|
8753
8755
|
const ownedProjects = react.useMemo(
|
|
8754
8756
|
() => (projects ?? []).filter((p) => p.created_by === currentUserExtId),
|
|
8755
8757
|
[projects, currentUserExtId]
|
|
@@ -8788,13 +8790,13 @@ function ProjectsTable() {
|
|
|
8788
8790
|
const hasPaid = p.subscription === "active" || p.subscription === "past_due";
|
|
8789
8791
|
const canUpgrade = stripeEnabled && !hasPaid && p.subscription !== "canceled" && p.subscription !== "dev";
|
|
8790
8792
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8791
|
-
|
|
8793
|
+
chunkTQUYWUEE_cjs.ProjectRow,
|
|
8792
8794
|
{
|
|
8793
8795
|
testId: `project-row-${p.external_id}`,
|
|
8794
8796
|
onOpen: () => openProject(p.external_id),
|
|
8795
8797
|
identity: /* @__PURE__ */ jsxRuntime.jsx(BillingProjectEntity, { name: p.name, relation: "mine", subscription: p.subscription, size: "sm" }),
|
|
8796
|
-
summary: stripeEnabled ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "flex items-center whitespace-nowrap", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
8797
|
-
usage: p.quotas ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
8798
|
+
summary: stripeEnabled ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "flex items-center whitespace-nowrap", children: /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanBadge, { ...chunkP2YM67Y5_cjs.planBadgeView(p) }) }) : void 0,
|
|
8799
|
+
usage: p.quotas ? /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.QuotaMeter, { items: chunkP2YM67Y5_cjs.getQuotaItems(p.quotas), size: "lg" }) : void 0,
|
|
8798
8800
|
actions: /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8799
8801
|
canUpgrade && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8800
8802
|
ui.Button,
|
|
@@ -8828,9 +8830,9 @@ function ProjectsTable() {
|
|
|
8828
8830
|
);
|
|
8829
8831
|
};
|
|
8830
8832
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8831
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8833
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.ProjectList, { isLoading, isEmpty: ownedProjects.length === 0, isFilteredOut: false, children: ownedProjects.map(renderRow) }),
|
|
8832
8834
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8833
|
-
|
|
8835
|
+
chunkTQUYWUEE_cjs.RenameDialog,
|
|
8834
8836
|
{
|
|
8835
8837
|
open: !!renameTarget,
|
|
8836
8838
|
onClose: () => setRenameTarget(null),
|
|
@@ -8861,7 +8863,7 @@ function ProjectsTable() {
|
|
|
8861
8863
|
}
|
|
8862
8864
|
function SharedProjects() {
|
|
8863
8865
|
const { data: projects } = react$1.useProjects();
|
|
8864
|
-
const currentUserExtId =
|
|
8866
|
+
const currentUserExtId = chunkP2YM67Y5_cjs.useSelfExtId();
|
|
8865
8867
|
const { data: usageToday } = react$1.useUserUsageToday();
|
|
8866
8868
|
const shared = react.useMemo(
|
|
8867
8869
|
() => (projects ?? []).filter((p) => p.created_by !== currentUserExtId),
|
|
@@ -8869,10 +8871,10 @@ function SharedProjects() {
|
|
|
8869
8871
|
);
|
|
8870
8872
|
if (shared.length === 0) return null;
|
|
8871
8873
|
const usedToday = usageToday?.used_gbp ?? 0;
|
|
8872
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8874
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.SharedProjectsSection, { footnote: "Your daily AI usage allowance in projects other people run \u2014 their plan and billing are theirs.", children: shared.map((p) => {
|
|
8873
8875
|
const cap = p.daily_cap_per_user;
|
|
8874
8876
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8875
|
-
|
|
8877
|
+
chunkTQUYWUEE_cjs.SharedProjectRow,
|
|
8876
8878
|
{
|
|
8877
8879
|
testId: `shared-project-${p.external_id}`,
|
|
8878
8880
|
identity: /* @__PURE__ */ jsxRuntime.jsx(BillingProjectEntity, { name: p.name, relation: "other", size: "sm" }),
|
|
@@ -8916,7 +8918,7 @@ function DailyCapEditor({ project }) {
|
|
|
8916
8918
|
);
|
|
8917
8919
|
};
|
|
8918
8920
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8919
|
-
|
|
8921
|
+
chunkTQUYWUEE_cjs.DailyCapField,
|
|
8920
8922
|
{
|
|
8921
8923
|
value,
|
|
8922
8924
|
onChange: setValue,
|
|
@@ -8929,11 +8931,11 @@ function DailyCapEditor({ project }) {
|
|
|
8929
8931
|
function SubscriptionStatus({ project }) {
|
|
8930
8932
|
const { quotas, cancel_at_period_end, subscription, current_period_end, addons } = project;
|
|
8931
8933
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
8932
|
-
|
|
8934
|
+
chunkTQUYWUEE_cjs.SubscriptionStatusView,
|
|
8933
8935
|
{
|
|
8934
|
-
resetDate:
|
|
8936
|
+
resetDate: chunkP2YM67Y5_cjs.formatResetDate(addons?.ai_usage_reset_at ?? current_period_end),
|
|
8935
8937
|
isCanceling: subscription === "canceled" || cancel_at_period_end === true,
|
|
8936
|
-
meters:
|
|
8938
|
+
meters: chunkP2YM67Y5_cjs.getQuotaItems(quotas).map((q) => ({
|
|
8937
8939
|
key: q.key,
|
|
8938
8940
|
icon: q.icon,
|
|
8939
8941
|
label: q.label,
|
|
@@ -8997,7 +8999,7 @@ function PendingChange({
|
|
|
8997
8999
|
}
|
|
8998
9000
|
);
|
|
8999
9001
|
}
|
|
9000
|
-
var titleFor = (kind, blockAiGbp, blockStorageGb) => kind === "ai_usage" ? `Add ${react$1.formatGbp(blockAiGbp ??
|
|
9002
|
+
var titleFor = (kind, blockAiGbp, blockStorageGb) => kind === "ai_usage" ? `Add ${react$1.formatGbp(blockAiGbp ?? chunkP2YM67Y5_cjs.ADDON_BLOCK_AI_GBP)} of AI usage` : `Add ${blockStorageGb ?? chunkP2YM67Y5_cjs.STORAGE_BLOCK_GB} GB storage`;
|
|
9001
9003
|
var blocksOf = (kind, project) => (kind === "ai_usage" ? project.addons?.ai_blocks : project.addons?.storage_blocks) ?? 0;
|
|
9002
9004
|
function Row({ label, children }) {
|
|
9003
9005
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-baseline justify-between gap-4", children: [
|
|
@@ -9018,11 +9020,11 @@ function AddAddonDialog({
|
|
|
9018
9020
|
const addons = project.addons;
|
|
9019
9021
|
if (!addons) return null;
|
|
9020
9022
|
const isAnnual = project.plan_interval === "year";
|
|
9021
|
-
const price =
|
|
9022
|
-
const nextCharge =
|
|
9023
|
-
const now = quote.data ?
|
|
9024
|
-
const renewal = quote.data ?
|
|
9025
|
-
const today = now ? { total:
|
|
9023
|
+
const price = chunkP2YM67Y5_cjs.addonCharge(kind, addons, isAnnual, addons.period_end ?? project.current_period_end);
|
|
9024
|
+
const nextCharge = chunkP2YM67Y5_cjs.formatPeriodEnd(addons.period_end ?? project.current_period_end);
|
|
9025
|
+
const now = quote.data ? chunkP2YM67Y5_cjs.quoteParts(quote.data.now) : null;
|
|
9026
|
+
const renewal = quote.data ? chunkP2YM67Y5_cjs.quoteParts(quote.data.renewal) : null;
|
|
9027
|
+
const today = now ? { total: chunkP2YM67Y5_cjs.money2(now.total), detail: chunkP2YM67Y5_cjs.taxDetail(now) } : { total: price.now, detail: `incl. VAT (${price.nowExVat} + ${price.nowVat} VAT)` };
|
|
9026
9028
|
const pricing = quote.isLoading;
|
|
9027
9029
|
const confirm = () => {
|
|
9028
9030
|
const before = blocksOf(kind, project);
|
|
@@ -9061,8 +9063,8 @@ function AddAddonDialog({
|
|
|
9061
9063
|
isAnnual ? "yearly" : "monthly",
|
|
9062
9064
|
" \xB7 no refund"
|
|
9063
9065
|
] }),
|
|
9064
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
9065
|
-
|
|
9066
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.MoreInfo, { title: "Adding a top-up", testId: "add-addon-more-info", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
9067
|
+
chunkTQUYWUEE_cjs.MoreInfoList,
|
|
9066
9068
|
{
|
|
9067
9069
|
items: [
|
|
9068
9070
|
{
|
|
@@ -9077,7 +9079,7 @@ function AddAddonDialog({
|
|
|
9077
9079
|
term: "Usage cap",
|
|
9078
9080
|
text: "Adding by hand is never blocked by the usage cap; the cap limits automatic top-ups only."
|
|
9079
9081
|
},
|
|
9080
|
-
...isAnnual && kind === "ai_usage" ? [{ term: "Annual", text: `${
|
|
9082
|
+
...isAnnual && kind === "ai_usage" ? [{ term: "Annual", text: `${chunkP2YM67Y5_cjs.ANNUAL_PREMIUM_AI_NOTE}.` }] : []
|
|
9081
9083
|
]
|
|
9082
9084
|
}
|
|
9083
9085
|
) })
|
|
@@ -9100,7 +9102,7 @@ function AddAddonDialog({
|
|
|
9100
9102
|
)
|
|
9101
9103
|
] }) }),
|
|
9102
9104
|
!pricing && /* @__PURE__ */ jsxRuntime.jsxs(Row, { label: "Next charge", children: [
|
|
9103
|
-
renewal ?
|
|
9105
|
+
renewal ? chunkP2YM67Y5_cjs.totalWithTaxWord(renewal) : price.then.replace(/\/(month|year)/, ""),
|
|
9104
9106
|
nextCharge ? ` on ${nextCharge}` : " at renewal"
|
|
9105
9107
|
] })
|
|
9106
9108
|
] }) }),
|
|
@@ -9131,11 +9133,11 @@ function ReduceAddonDialog({
|
|
|
9131
9133
|
const update = react$1.useUpdateProjectNextPeriodAddons();
|
|
9132
9134
|
const addons = project.addons;
|
|
9133
9135
|
if (!addons) return null;
|
|
9134
|
-
const { min, next } =
|
|
9136
|
+
const { min, next } = chunkP2YM67Y5_cjs.reduceBounds(kind, addons);
|
|
9135
9137
|
const keep = Math.max(min, next - 1);
|
|
9136
|
-
const size =
|
|
9137
|
-
const what =
|
|
9138
|
-
const from =
|
|
9138
|
+
const size = chunkP2YM67Y5_cjs.nextRemovedBlockSize(kind, addons);
|
|
9139
|
+
const what = chunkP2YM67Y5_cjs.stepLabel(kind, size);
|
|
9140
|
+
const from = chunkP2YM67Y5_cjs.formatPeriodEnd(addons.period_end ?? project.current_period_end) ?? "your next renewal";
|
|
9139
9141
|
const fromShort = from.replace(/ \d{4}$/, "");
|
|
9140
9142
|
const allowanceNext = kind === "ai_usage" ? addons.ai_allowance_next_gbp - size : addons.storage_allowance_next_gb - size;
|
|
9141
9143
|
const allowanceNow = kind === "ai_usage" ? addons.ai_allowance_gbp : addons.storage_allowance_gb;
|
|
@@ -9143,7 +9145,7 @@ function ReduceAddonDialog({
|
|
|
9143
9145
|
const save = () => update.mutate(
|
|
9144
9146
|
{
|
|
9145
9147
|
projectExtId: project.external_id,
|
|
9146
|
-
body:
|
|
9148
|
+
body: chunkP2YM67Y5_cjs.nextPeriodBody(kind, keep)
|
|
9147
9149
|
},
|
|
9148
9150
|
{
|
|
9149
9151
|
onSuccess: () => {
|
|
@@ -9171,7 +9173,7 @@ function ReduceAddonDialog({
|
|
|
9171
9173
|
fromShort,
|
|
9172
9174
|
" \xB7 no refund"
|
|
9173
9175
|
] }),
|
|
9174
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
9176
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.MoreInfo, { title: "Reducing a top-up", testId: "reduce-addon-more-info", children: [
|
|
9175
9177
|
/* @__PURE__ */ jsxRuntime.jsxs("p", { children: [
|
|
9176
9178
|
"The reduction applies from your next renewal (",
|
|
9177
9179
|
from,
|
|
@@ -9210,7 +9212,7 @@ function ReduceAddonDialog({
|
|
|
9210
9212
|
}
|
|
9211
9213
|
) });
|
|
9212
9214
|
}
|
|
9213
|
-
var gbp = (pence) =>
|
|
9215
|
+
var gbp = (pence) => chunkP2YM67Y5_cjs.formatMoney(pence, "gbp");
|
|
9214
9216
|
var gb2 = (n) => `${Math.round(n * 10) / 10} GB`;
|
|
9215
9217
|
var pct = (used, limit) => limit > 0 ? Math.min(100, used / limit * 100) : 0;
|
|
9216
9218
|
function formatShortDate(unix) {
|
|
@@ -9222,20 +9224,20 @@ function AutoTopupThreshold({
|
|
|
9222
9224
|
addons
|
|
9223
9225
|
}) {
|
|
9224
9226
|
const updateSettings = react$1.useUpdateProjectAddonSettings();
|
|
9225
|
-
const min = addons.min_auto_topup_threshold_gbp ||
|
|
9227
|
+
const min = addons.min_auto_topup_threshold_gbp || chunkP2YM67Y5_cjs.MIN_AUTO_TOPUP_THRESHOLD_GBP;
|
|
9226
9228
|
const saved = addons.auto_topup_threshold_gbp;
|
|
9227
9229
|
const [value, setValue] = react.useState(String(saved));
|
|
9228
9230
|
react.useEffect(() => setValue(String(saved)), [saved]);
|
|
9229
9231
|
const parsed = Number(value);
|
|
9230
9232
|
const valid = Number.isFinite(parsed) && parsed >= min;
|
|
9231
9233
|
const dirty = valid && parsed !== saved;
|
|
9232
|
-
const off =
|
|
9234
|
+
const off = chunkP2YM67Y5_cjs.isAddonBudgetZero(addons);
|
|
9233
9235
|
const save = () => {
|
|
9234
9236
|
if (!dirty) return;
|
|
9235
9237
|
updateSettings.mutate(
|
|
9236
9238
|
{
|
|
9237
9239
|
projectExtId: project.external_id,
|
|
9238
|
-
body:
|
|
9240
|
+
body: chunkP2YM67Y5_cjs.addonSettingsBody(addons, { auto_topup_threshold_gbp: parsed })
|
|
9239
9241
|
},
|
|
9240
9242
|
{
|
|
9241
9243
|
onSuccess: () => shell.notify.success(`Auto-add below ${react$1.formatGbp(parsed)} of AI usage left`),
|
|
@@ -9332,10 +9334,10 @@ function ResourceMeter({
|
|
|
9332
9334
|
const update = react$1.useUpdateProjectNextPeriodAddons();
|
|
9333
9335
|
const isAi = kind === "ai_usage";
|
|
9334
9336
|
const slug = isAi ? "ai-usage" : "storage";
|
|
9335
|
-
const periodEnd =
|
|
9337
|
+
const periodEnd = chunkP2YM67Y5_cjs.formatPeriodEnd(addons.period_end ?? project.current_period_end);
|
|
9336
9338
|
const from = periodEnd ?? "your next renewal";
|
|
9337
9339
|
const fromShort = formatShortDate(addons.period_end ?? project.current_period_end) ?? "renewal";
|
|
9338
|
-
const { min, current, next } =
|
|
9340
|
+
const { min, current, next } = chunkP2YM67Y5_cjs.reduceBounds(kind, addons);
|
|
9339
9341
|
const fmt = (n) => isAi ? react$1.formatGbp(n) : gb2(n);
|
|
9340
9342
|
const used = isAi ? addons.ai_used_gbp : addons.storage_used_gb;
|
|
9341
9343
|
const allowance = isAi ? addons.ai_allowance_gbp : addons.storage_allowance_gb;
|
|
@@ -9343,15 +9345,15 @@ function ResourceMeter({
|
|
|
9343
9345
|
const plan = isAi ? addons.plan_ai_gbp : addons.plan_storage_gb;
|
|
9344
9346
|
const topUps = Math.max(0, allowance - plan);
|
|
9345
9347
|
const blocks = isAi ? addons.ai_blocks : addons.storage_blocks;
|
|
9346
|
-
const hasLegacy =
|
|
9347
|
-
const room =
|
|
9348
|
-
const capZero =
|
|
9349
|
-
const resets = isAi ? formatShortDate(
|
|
9350
|
-
const removeSize =
|
|
9348
|
+
const hasLegacy = chunkP2YM67Y5_cjs.splitBlocks(kind, blocks, addons).legacy > 0;
|
|
9349
|
+
const room = chunkP2YM67Y5_cjs.autoRoom(kind, addons);
|
|
9350
|
+
const capZero = chunkP2YM67Y5_cjs.isAddonBudgetZero(addons);
|
|
9351
|
+
const resets = isAi ? formatShortDate(chunkP2YM67Y5_cjs.aiUsageResetTimestamp(project)) : null;
|
|
9352
|
+
const removeSize = chunkP2YM67Y5_cjs.nextRemovedBlockSize(kind, addons);
|
|
9351
9353
|
const undo = () => update.mutate(
|
|
9352
9354
|
{
|
|
9353
9355
|
projectExtId: project.external_id,
|
|
9354
|
-
body:
|
|
9356
|
+
body: chunkP2YM67Y5_cjs.nextPeriodBody(kind, current)
|
|
9355
9357
|
},
|
|
9356
9358
|
{
|
|
9357
9359
|
onSuccess: () => shell.notify.success("Kept"),
|
|
@@ -9368,7 +9370,7 @@ function ResourceMeter({
|
|
|
9368
9370
|
allowance: { used, plan, topUps, autoRoom: capZero ? 0 : room },
|
|
9369
9371
|
legend: {
|
|
9370
9372
|
plan: `Plan ${fmt(plan)}`,
|
|
9371
|
-
topUps: topUps > 0 ? `Top-ups ${fmt(topUps)}${hasLegacy ? ` (${
|
|
9373
|
+
topUps: topUps > 0 ? `Top-ups ${fmt(topUps)}${hasLegacy ? ` (${chunkP2YM67Y5_cjs.blocksLabel(kind, blocks, addons)})` : ""}` : void 0,
|
|
9372
9374
|
autoRoom: room != null && room > 0 && !capZero ? `Automatic up to ${fmt(room)}` : void 0
|
|
9373
9375
|
},
|
|
9374
9376
|
testId: `usage-meter-${slug}`,
|
|
@@ -9397,9 +9399,9 @@ function ResourceMeter({
|
|
|
9397
9399
|
{
|
|
9398
9400
|
icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { className: "size-3.5" }),
|
|
9399
9401
|
label: isAi ? react$1.formatGbp(addons.block_ai_gbp) : `${addons.block_storage_gb} GB`,
|
|
9400
|
-
caption:
|
|
9402
|
+
caption: chunkP2YM67Y5_cjs.addStepCaption(kind, addons),
|
|
9401
9403
|
onClick: onAdd,
|
|
9402
|
-
ariaLabel: `Add ${
|
|
9404
|
+
ariaLabel: `Add ${chunkP2YM67Y5_cjs.stepLabel(kind, isAi ? addons.block_ai_gbp : addons.block_storage_gb)}`,
|
|
9403
9405
|
testId: isAi ? "add-ai-block-button" : "add-storage-block-button"
|
|
9404
9406
|
}
|
|
9405
9407
|
),
|
|
@@ -9410,7 +9412,7 @@ function ResourceMeter({
|
|
|
9410
9412
|
label: isAi ? react$1.formatGbp(removeSize) : `${removeSize} GB`,
|
|
9411
9413
|
caption: `from ${fromShort}`,
|
|
9412
9414
|
onClick: onReduce,
|
|
9413
|
-
ariaLabel: `Remove ${
|
|
9415
|
+
ariaLabel: `Remove ${chunkP2YM67Y5_cjs.stepLabel(kind, removeSize)} from ${from}`,
|
|
9414
9416
|
testId: `reduce-${slug}-button`
|
|
9415
9417
|
}
|
|
9416
9418
|
)
|
|
@@ -9449,10 +9451,10 @@ function UsageCapEditor({ project, addons }) {
|
|
|
9449
9451
|
updateSettings.mutate(
|
|
9450
9452
|
{
|
|
9451
9453
|
projectExtId: project.external_id,
|
|
9452
|
-
body:
|
|
9454
|
+
body: chunkP2YM67Y5_cjs.addonSettingsBody(addons, { spend_cap_pence: nextCap })
|
|
9453
9455
|
},
|
|
9454
9456
|
{
|
|
9455
|
-
onSuccess: () => shell.notify.success(
|
|
9457
|
+
onSuccess: () => shell.notify.success(chunkP2YM67Y5_cjs.budgetSavedMessage(nextCap)),
|
|
9456
9458
|
onError: (error) => shell.notify.error(addonErrorMessage(error))
|
|
9457
9459
|
}
|
|
9458
9460
|
);
|
|
@@ -9463,14 +9465,14 @@ function UsageCapEditor({ project, addons }) {
|
|
|
9463
9465
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
9464
9466
|
chunkQZTNTP75_cjs.UsageMeter,
|
|
9465
9467
|
{
|
|
9466
|
-
label:
|
|
9468
|
+
label: chunkP2YM67Y5_cjs.USAGE_CAP_LABEL,
|
|
9467
9469
|
hint: spendResets && savedCap !== 0 ? `resets ${spendResets}` : void 0,
|
|
9468
9470
|
value: readout,
|
|
9469
9471
|
pct: savedCap != null && savedCap > 0 ? pct(spent, savedCap) : 0,
|
|
9470
9472
|
testId: "addon-spend"
|
|
9471
9473
|
}
|
|
9472
9474
|
),
|
|
9473
|
-
addons.cap_reached && savedCap != null && savedCap > 0 && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-muted-foreground", "data-testid": "addon-cap-reached", children:
|
|
9475
|
+
addons.cap_reached && savedCap != null && savedCap > 0 && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-muted-foreground", "data-testid": "addon-cap-reached", children: chunkP2YM67Y5_cjs.CAP_REACHED_MESSAGE }),
|
|
9474
9476
|
addons.manual_spent_pence > 0 && /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-xs text-muted-foreground", "data-testid": "addon-manual-spend", children: [
|
|
9475
9477
|
"Added by hand this month: ",
|
|
9476
9478
|
gbp(addons.manual_spent_pence),
|
|
@@ -9491,7 +9493,7 @@ function UsageCapEditor({ project, addons }) {
|
|
|
9491
9493
|
step: 25,
|
|
9492
9494
|
className: "h-9 w-28",
|
|
9493
9495
|
value: noCap ? "" : value,
|
|
9494
|
-
placeholder: noCap ? "No limit" : String(
|
|
9496
|
+
placeholder: noCap ? "No limit" : String(chunkP2YM67Y5_cjs.DEFAULT_SPEND_CAP_PENCE / 100),
|
|
9495
9497
|
disabled: noCap,
|
|
9496
9498
|
onChange: (e) => setValue(e.target.value),
|
|
9497
9499
|
onKeyDown: (e) => e.key === "Enter" && save(),
|
|
@@ -9517,7 +9519,7 @@ function UsageCapEditor({ project, addons }) {
|
|
|
9517
9519
|
checked: noCap,
|
|
9518
9520
|
onCheckedChange: (checked) => {
|
|
9519
9521
|
setNoCap(checked);
|
|
9520
|
-
if (!checked && value === "") setValue(String(
|
|
9522
|
+
if (!checked && value === "") setValue(String(chunkP2YM67Y5_cjs.DEFAULT_SPEND_CAP_PENCE / 100));
|
|
9521
9523
|
},
|
|
9522
9524
|
"data-testid": "no-cap-switch"
|
|
9523
9525
|
}
|
|
@@ -9530,8 +9532,8 @@ function UsageCapEditor({ project, addons }) {
|
|
|
9530
9532
|
function UsageInfo({ addons, isAnnual }) {
|
|
9531
9533
|
const period = isAnnual ? "year" : "month";
|
|
9532
9534
|
const legacy = (addons.legacy_ai_blocks ?? 0) > 0 || (addons.legacy_storage_blocks ?? 0) > 0;
|
|
9533
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
9534
|
-
|
|
9535
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.MoreInfo, { title: "Usage and top-ups", testId: "usage-more-info", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
9536
|
+
chunkTQUYWUEE_cjs.MoreInfoList,
|
|
9535
9537
|
{
|
|
9536
9538
|
items: [
|
|
9537
9539
|
{
|
|
@@ -9546,7 +9548,7 @@ function UsageInfo({ addons, isAnnual }) {
|
|
|
9546
9548
|
term: "Automatic top-ups",
|
|
9547
9549
|
text: "One step is added when AI usage drops below your auto top-up level, or when an upload needs more storage."
|
|
9548
9550
|
},
|
|
9549
|
-
{ term: "Usage cap", text:
|
|
9551
|
+
{ term: "Usage cap", text: chunkP2YM67Y5_cjs.USAGE_CAP_HELP },
|
|
9550
9552
|
{
|
|
9551
9553
|
term: "Reducing",
|
|
9552
9554
|
text: "\u2212 removes one step from your next renewal. You keep this period's allowance. No refunds."
|
|
@@ -9557,7 +9559,7 @@ function UsageInfo({ addons, isAnnual }) {
|
|
|
9557
9559
|
text: "Top-ups bought on an earlier price keep their size and price until removed; they are removed last."
|
|
9558
9560
|
}
|
|
9559
9561
|
] : [],
|
|
9560
|
-
...isAnnual ? [{ term: "Annual", text: `${
|
|
9562
|
+
...isAnnual ? [{ term: "Annual", text: `${chunkP2YM67Y5_cjs.ANNUAL_PREMIUM_AI_NOTE}.` }] : [],
|
|
9561
9563
|
{
|
|
9562
9564
|
term: "Prices",
|
|
9563
9565
|
text: "Shown ex VAT. The confirm step shows the total with VAT before you pay."
|
|
@@ -9649,7 +9651,7 @@ function formatShortDate2(unix) {
|
|
|
9649
9651
|
if (!unix) return null;
|
|
9650
9652
|
return new Date(unix * 1e3).toLocaleDateString("en-GB", { day: "numeric", month: "short" });
|
|
9651
9653
|
}
|
|
9652
|
-
var gbp2 = (pence) =>
|
|
9654
|
+
var gbp2 = (pence) => chunkP2YM67Y5_cjs.formatMoney(pence, "gbp");
|
|
9653
9655
|
var gbNum = (n) => `${Math.round(n * 10) / 10}`;
|
|
9654
9656
|
var pct2 = (used, limit) => limit > 0 ? Math.min(100, used / limit * 100) : 0;
|
|
9655
9657
|
function Meter({
|
|
@@ -9667,15 +9669,15 @@ function Meter({
|
|
|
9667
9669
|
] });
|
|
9668
9670
|
}
|
|
9669
9671
|
function usePlanPrice(project) {
|
|
9670
|
-
const { data: products } = react$1.useProducts({ enabled:
|
|
9671
|
-
if (!
|
|
9672
|
+
const { data: products } = react$1.useProducts({ enabled: chunkP2YM67Y5_cjs.isProProject(project) });
|
|
9673
|
+
if (!chunkP2YM67Y5_cjs.isProProject(project)) return null;
|
|
9672
9674
|
const isAnnual = project.plan_interval === "year";
|
|
9673
9675
|
if (project.amount != null) {
|
|
9674
9676
|
return { incl: project.amount, ex: project.amount_ex_vat ?? null, isAnnual };
|
|
9675
9677
|
}
|
|
9676
|
-
if ((project.packs ??
|
|
9677
|
-
const prices =
|
|
9678
|
-
const pp =
|
|
9678
|
+
if ((project.packs ?? chunkP2YM67Y5_cjs.PRO_PACKS) > chunkP2YM67Y5_cjs.PRO_PACKS) return null;
|
|
9679
|
+
const prices = chunkP2YM67Y5_cjs.findProPrices(products);
|
|
9680
|
+
const pp = chunkP2YM67Y5_cjs.packPrice(isAnnual ? prices.annual : prices.monthly);
|
|
9679
9681
|
return pp ? { incl: pp.amount, ex: pp.amount_ex_vat, isAnnual } : null;
|
|
9680
9682
|
}
|
|
9681
9683
|
function paidLine(payment, addons) {
|
|
@@ -9688,11 +9690,11 @@ function ProjectPlanCard({
|
|
|
9688
9690
|
onChangePlan
|
|
9689
9691
|
}) {
|
|
9690
9692
|
const { quotas, addons } = project;
|
|
9691
|
-
const isPro =
|
|
9693
|
+
const isPro = chunkP2YM67Y5_cjs.isProProject(project);
|
|
9692
9694
|
const used = quotas?.ai_usage?.used ?? 0;
|
|
9693
9695
|
const limit = quotas?.ai_usage?.limit ?? 0;
|
|
9694
|
-
const resetDate = formatShortDate2(
|
|
9695
|
-
const periodEnd =
|
|
9696
|
+
const resetDate = formatShortDate2(chunkP2YM67Y5_cjs.aiUsageResetTimestamp(project));
|
|
9697
|
+
const periodEnd = chunkP2YM67Y5_cjs.formatPeriodEnd(addons?.period_end ?? project.current_period_end);
|
|
9696
9698
|
const when2 = periodEnd ?? "the end of the period";
|
|
9697
9699
|
const storageUsed = quotas?.storage_gb?.used ?? 0;
|
|
9698
9700
|
const storageLimit = quotas?.storage_gb?.limit ?? 0;
|
|
@@ -9708,7 +9710,7 @@ function ProjectPlanCard({
|
|
|
9708
9710
|
project.external_id,
|
|
9709
9711
|
hasScheduledChange && addons ? { packs: packsNext ?? addons.packs, interval: pending ?? currentInterval } : null
|
|
9710
9712
|
).data;
|
|
9711
|
-
const tier = isPro ?
|
|
9713
|
+
const tier = isPro ? chunkP2YM67Y5_cjs.proTierName(project) : project.subscription === "dev" ? "Dev" : "Free";
|
|
9712
9714
|
const pendingPayment = addons?.payment?.status === "pending" ? addons.payment : null;
|
|
9713
9715
|
const confirmUrl = pendingPayment?.confirm_url ?? addons?.confirm_url;
|
|
9714
9716
|
const paidPayment = addons?.payment?.status === "paid" ? addons.payment : null;
|
|
@@ -9742,7 +9744,7 @@ function ProjectPlanCard({
|
|
|
9742
9744
|
isPro && " ",
|
|
9743
9745
|
isPro && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "ml-1 text-sm font-normal text-muted-foreground", children: currentInterval === "year" ? "Annual" : "Monthly" })
|
|
9744
9746
|
] }),
|
|
9745
|
-
isPro && periodEnd && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm text-muted-foreground", "data-testid": "project-plan-renews", children: isCanceling ? `Ends ${periodEnd}` : hasScheduledChange && nextBill ? `Next bill ${
|
|
9747
|
+
isPro && periodEnd && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm text-muted-foreground", "data-testid": "project-plan-renews", children: isCanceling ? `Ends ${periodEnd}` : hasScheduledChange && nextBill ? `Next bill ${chunkP2YM67Y5_cjs.totalWithTaxWord({
|
|
9746
9748
|
subtotal: nextBill.next_renewal_ex_vat_pence,
|
|
9747
9749
|
tax: nextBill.next_renewal_tax_pence,
|
|
9748
9750
|
total: nextBill.next_renewal_pence,
|
|
@@ -9751,7 +9753,7 @@ function ProjectPlanCard({
|
|
|
9751
9753
|
] }),
|
|
9752
9754
|
price && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "ml-auto text-right", "data-testid": "project-plan-price", children: [
|
|
9753
9755
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-lg font-semibold tabular-nums text-foreground", children: [
|
|
9754
|
-
price.ex != null ?
|
|
9756
|
+
price.ex != null ? chunkP2YM67Y5_cjs.plusVat(price.ex) : gbp2(price.incl),
|
|
9755
9757
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm font-normal text-muted-foreground", children: price.isAnnual ? "/year" : "/month" })
|
|
9756
9758
|
] }),
|
|
9757
9759
|
price.ex != null && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-xs text-muted-foreground", children: [
|
|
@@ -9789,7 +9791,7 @@ function ProjectPlanCard({
|
|
|
9789
9791
|
undoTestId: "undo-plan-change-button",
|
|
9790
9792
|
children: [
|
|
9791
9793
|
"Changes to ",
|
|
9792
|
-
|
|
9794
|
+
chunkP2YM67Y5_cjs.planNameForPacks(packsNext),
|
|
9793
9795
|
" on ",
|
|
9794
9796
|
when2,
|
|
9795
9797
|
"."
|
|
@@ -9834,8 +9836,8 @@ function ProjectPlanCard({
|
|
|
9834
9836
|
}
|
|
9835
9837
|
)
|
|
9836
9838
|
] }),
|
|
9837
|
-
addons?.billing_error && /* @__PURE__ */ jsxRuntime.jsx(
|
|
9838
|
-
confirmUrl ? /* @__PURE__ */ jsxRuntime.jsxs(
|
|
9839
|
+
addons?.billing_error && /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanNotice, { tone: "error", testId: "plan-billing-error", children: addons.billing_error }),
|
|
9840
|
+
confirmUrl ? /* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.PlanNotice, { testId: "plan-payment-state", children: [
|
|
9839
9841
|
"Waiting for your bank",
|
|
9840
9842
|
pendingPayment?.amount_pence ? ` \xB7 ${gbp2(pendingPayment.amount_pence)}` : "",
|
|
9841
9843
|
" \xB7",
|
|
@@ -9853,7 +9855,7 @@ function ProjectPlanCard({
|
|
|
9853
9855
|
]
|
|
9854
9856
|
}
|
|
9855
9857
|
)
|
|
9856
|
-
] }) : paidPayment && addons && /* @__PURE__ */ jsxRuntime.jsx(
|
|
9858
|
+
] }) : paidPayment && addons && /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanNotice, { testId: "plan-payment-state", children: paidLine(paidPayment, addons) }),
|
|
9857
9859
|
isPro && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
9858
9860
|
"button",
|
|
9859
9861
|
{
|
|
@@ -9880,7 +9882,7 @@ function ProjectBilling({
|
|
|
9880
9882
|
const { addons } = project;
|
|
9881
9883
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-4", "data-testid": "project-billing", children: [
|
|
9882
9884
|
/* @__PURE__ */ jsxRuntime.jsx(ProjectPlanCard, { project, onChangePlan }),
|
|
9883
|
-
addons &&
|
|
9885
|
+
addons && chunkP2YM67Y5_cjs.isProProject(project) && /* @__PURE__ */ jsxRuntime.jsx(ProjectUsageCard, { project, addons })
|
|
9884
9886
|
] });
|
|
9885
9887
|
}
|
|
9886
9888
|
var BREAKDOWN_LABELS = {
|
|
@@ -10011,13 +10013,13 @@ function ProjectUsageContent({
|
|
|
10011
10013
|
};
|
|
10012
10014
|
const quotaPct = effectiveUsage && aiUsageLimit ? Math.round(effectiveUsage.total_spend / aiUsageLimit * 100) : 0;
|
|
10013
10015
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
10014
|
-
|
|
10016
|
+
chunkTQUYWUEE_cjs.UsagePanel,
|
|
10015
10017
|
{
|
|
10016
10018
|
state,
|
|
10017
10019
|
dateRange,
|
|
10018
10020
|
emptyMessage: `No usage ${period === "current" ? "yet this month" : "last month"}.`,
|
|
10019
10021
|
period: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10020
|
-
|
|
10022
|
+
chunkTQUYWUEE_cjs.UsageToggle,
|
|
10021
10023
|
{
|
|
10022
10024
|
ariaLabel: "Period",
|
|
10023
10025
|
value: period,
|
|
@@ -10030,7 +10032,7 @@ function ProjectUsageContent({
|
|
|
10030
10032
|
),
|
|
10031
10033
|
actions: /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
10032
10034
|
effectiveUsage?.invoice_pdf && /* @__PURE__ */ jsxRuntime.jsx(
|
|
10033
|
-
|
|
10035
|
+
chunkTQUYWUEE_cjs.UsageActionButton,
|
|
10034
10036
|
{
|
|
10035
10037
|
label: "Download Stripe invoice PDF",
|
|
10036
10038
|
icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Download, { className: "size-3.5" }),
|
|
@@ -10038,7 +10040,7 @@ function ProjectUsageContent({
|
|
|
10038
10040
|
}
|
|
10039
10041
|
),
|
|
10040
10042
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10041
|
-
|
|
10043
|
+
chunkTQUYWUEE_cjs.UsageActionButton,
|
|
10042
10044
|
{
|
|
10043
10045
|
label: "Print usage summary",
|
|
10044
10046
|
icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Printer, { className: "size-3.5" }),
|
|
@@ -10048,7 +10050,7 @@ function ProjectUsageContent({
|
|
|
10048
10050
|
] }),
|
|
10049
10051
|
children: effectiveUsage && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
10050
10052
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10051
|
-
|
|
10053
|
+
chunkTQUYWUEE_cjs.UsageSummary,
|
|
10052
10054
|
{
|
|
10053
10055
|
stats: [
|
|
10054
10056
|
{
|
|
@@ -10056,7 +10058,7 @@ function ProjectUsageContent({
|
|
|
10056
10058
|
value: /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: react$1.formatGbp(effectiveUsage.total_spend) }),
|
|
10057
10059
|
label: /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
10058
10060
|
"AI usage",
|
|
10059
|
-
quotaPct > 0 ? /* @__PURE__ */ jsxRuntime.jsxs(
|
|
10061
|
+
quotaPct > 0 ? /* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.UsageQuotaHint, { children: [
|
|
10060
10062
|
"(",
|
|
10061
10063
|
quotaPct,
|
|
10062
10064
|
"% of quota)"
|
|
@@ -10077,7 +10079,7 @@ function ProjectUsageContent({
|
|
|
10077
10079
|
}
|
|
10078
10080
|
),
|
|
10079
10081
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10080
|
-
|
|
10082
|
+
chunkTQUYWUEE_cjs.UsageToggle,
|
|
10081
10083
|
{
|
|
10082
10084
|
ariaLabel: "Breakdown by",
|
|
10083
10085
|
size: "fill",
|
|
@@ -10090,12 +10092,12 @@ function ProjectUsageContent({
|
|
|
10090
10092
|
}
|
|
10091
10093
|
),
|
|
10092
10094
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10093
|
-
|
|
10095
|
+
chunkTQUYWUEE_cjs.UsageSection,
|
|
10094
10096
|
{
|
|
10095
|
-
footer: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10097
|
+
footer: /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.UsageLegend, { series }),
|
|
10096
10098
|
title: `Daily AI usage${breakdown === "model" ? ` by ${BREAKDOWN_LABELS[breakdown]}` : ""}`,
|
|
10097
10099
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10098
|
-
|
|
10100
|
+
chunkTQUYWUEE_cjs.UsageLineChart,
|
|
10099
10101
|
{
|
|
10100
10102
|
dates,
|
|
10101
10103
|
series,
|
|
@@ -10106,12 +10108,12 @@ function ProjectUsageContent({
|
|
|
10106
10108
|
}
|
|
10107
10109
|
),
|
|
10108
10110
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10109
|
-
|
|
10111
|
+
chunkTQUYWUEE_cjs.UsageSection,
|
|
10110
10112
|
{
|
|
10111
10113
|
title: "Breakdown",
|
|
10112
10114
|
gap: "md",
|
|
10113
10115
|
action: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10114
|
-
|
|
10116
|
+
chunkTQUYWUEE_cjs.UsageToggle,
|
|
10115
10117
|
{
|
|
10116
10118
|
ariaLabel: "Breakdown metric",
|
|
10117
10119
|
value: metric,
|
|
@@ -10123,7 +10125,7 @@ function ProjectUsageContent({
|
|
|
10123
10125
|
}
|
|
10124
10126
|
),
|
|
10125
10127
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10126
|
-
|
|
10128
|
+
chunkTQUYWUEE_cjs.UsageProportionBar,
|
|
10127
10129
|
{
|
|
10128
10130
|
metric,
|
|
10129
10131
|
items: breakdownItems.map((item) => ({
|
|
@@ -10141,13 +10143,13 @@ function ProjectUsageContent({
|
|
|
10141
10143
|
);
|
|
10142
10144
|
}
|
|
10143
10145
|
function ProjectDetail({ projectExtId, storage }) {
|
|
10144
|
-
const { stripeEnabled } =
|
|
10146
|
+
const { stripeEnabled } = chunkP2YM67Y5_cjs.useBillingSupport();
|
|
10145
10147
|
const [planOpen, setPlanOpen] = react.useState(false);
|
|
10146
10148
|
const [renameOpen, setRenameOpen] = react.useState(false);
|
|
10147
10149
|
const [renameValue, setRenameValue] = react.useState("");
|
|
10148
10150
|
const updateProject = react$1.useUpdateProjectFields();
|
|
10149
10151
|
const { data: projects, isLoading } = react$1.useProjects();
|
|
10150
|
-
const currentUserExtId =
|
|
10152
|
+
const currentUserExtId = chunkP2YM67Y5_cjs.useSelfExtId();
|
|
10151
10153
|
const project = projects?.find((p) => p.external_id === projectExtId);
|
|
10152
10154
|
const handleSaveRename = react.useCallback(() => {
|
|
10153
10155
|
const trimmed = renameValue.trim();
|
|
@@ -10181,7 +10183,7 @@ function ProjectDetail({ projectExtId, storage }) {
|
|
|
10181
10183
|
}
|
|
10182
10184
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-6 space-y-6 max-w-4xl", "data-testid": `project-detail-${project.external_id}`, children: [
|
|
10183
10185
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10184
|
-
|
|
10186
|
+
chunkTQUYWUEE_cjs.ProjectDetailHeader,
|
|
10185
10187
|
{
|
|
10186
10188
|
icon: /* @__PURE__ */ jsxRuntime.jsx(ui.EntityIcon, { entityType: "PROJECT" }),
|
|
10187
10189
|
name: project.name,
|
|
@@ -10189,11 +10191,11 @@ function ProjectDetail({ projectExtId, storage }) {
|
|
|
10189
10191
|
setRenameValue(project.name);
|
|
10190
10192
|
setRenameOpen(true);
|
|
10191
10193
|
},
|
|
10192
|
-
badge: stripeEnabled ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
10194
|
+
badge: stripeEnabled ? /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanBadge, { ...chunkP2YM67Y5_cjs.planBadgeView(project), size: "md" }) : void 0
|
|
10193
10195
|
}
|
|
10194
10196
|
),
|
|
10195
10197
|
hasBilling && /* @__PURE__ */ jsxRuntime.jsx(ProjectBilling, { project, onChangePlan: () => setPlanOpen(true) }),
|
|
10196
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
10198
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.ProjectDetailSection, { title: hasBilling ? "Collaborator limits" : "Plan limits", children: [
|
|
10197
10199
|
!hasBilling && /* @__PURE__ */ jsxRuntime.jsx(SubscriptionStatus, { project }),
|
|
10198
10200
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
10199
10201
|
"div",
|
|
@@ -10209,7 +10211,7 @@ function ProjectDetail({ projectExtId, storage }) {
|
|
|
10209
10211
|
}
|
|
10210
10212
|
)
|
|
10211
10213
|
] }),
|
|
10212
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10214
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.ProjectDetailSection, { title: "Usage", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10213
10215
|
ProjectUsageContent,
|
|
10214
10216
|
{
|
|
10215
10217
|
projectExtId: project.external_id,
|
|
@@ -10219,7 +10221,7 @@ function ProjectDetail({ projectExtId, storage }) {
|
|
|
10219
10221
|
) }),
|
|
10220
10222
|
storage,
|
|
10221
10223
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10222
|
-
|
|
10224
|
+
chunkTQUYWUEE_cjs.RenameDialog,
|
|
10223
10225
|
{
|
|
10224
10226
|
open: renameOpen,
|
|
10225
10227
|
onClose: () => setRenameOpen(false),
|
|
@@ -10234,7 +10236,7 @@ function ProjectDetail({ projectExtId, storage }) {
|
|
|
10234
10236
|
] });
|
|
10235
10237
|
}
|
|
10236
10238
|
function createProjectErrorMessage(error, fallback = "Failed to create project") {
|
|
10237
|
-
const detail =
|
|
10239
|
+
const detail = chunkP2YM67Y5_cjs.apiErrorDetail(error);
|
|
10238
10240
|
if (typeof detail === "string" && detail) return detail;
|
|
10239
10241
|
const message = detail?.message;
|
|
10240
10242
|
return typeof message === "string" && message ? message : fallback;
|
|
@@ -10244,7 +10246,7 @@ function NewProjectFlow({ open, onOpenChange, defaultName }) {
|
|
|
10244
10246
|
const [plan, setPlan] = react.useState("pro");
|
|
10245
10247
|
const [isAnnual, setIsAnnual] = react.useState(false);
|
|
10246
10248
|
const [promoCode, setPromoCode] = react.useState("");
|
|
10247
|
-
const [addonBudget, setAddonBudget] = react.useState(String(
|
|
10249
|
+
const [addonBudget, setAddonBudget] = react.useState(String(chunkP2YM67Y5_cjs.DEFAULT_SPEND_CAP_PENCE / 100));
|
|
10248
10250
|
const [checkoutBudget, setCheckoutBudget] = react.useState(null);
|
|
10249
10251
|
const [aiBlocks, setAiBlocks] = react.useState(0);
|
|
10250
10252
|
const [storageBlocks, setStorageBlocks] = react.useState(0);
|
|
@@ -10258,7 +10260,7 @@ function NewProjectFlow({ open, onOpenChange, defaultName }) {
|
|
|
10258
10260
|
const [checkoutProjectName, setCheckoutProjectName] = react.useState("");
|
|
10259
10261
|
const [checkoutInterval, setCheckoutInterval] = react.useState("month");
|
|
10260
10262
|
const paymentCompletedRef = react.useRef(false);
|
|
10261
|
-
const { stripeEnabled } =
|
|
10263
|
+
const { stripeEnabled } = chunkP2YM67Y5_cjs.useBillingSupport();
|
|
10262
10264
|
const { data: products, isLoading: productsLoading } = react$1.useProducts({
|
|
10263
10265
|
enabled: stripeEnabled
|
|
10264
10266
|
});
|
|
@@ -10287,18 +10289,18 @@ function NewProjectFlow({ open, onOpenChange, defaultName }) {
|
|
|
10287
10289
|
setPlan("pro");
|
|
10288
10290
|
setPromoCode("");
|
|
10289
10291
|
setPostalCode("");
|
|
10290
|
-
setAddonBudget(String(
|
|
10292
|
+
setAddonBudget(String(chunkP2YM67Y5_cjs.DEFAULT_SPEND_CAP_PENCE / 100));
|
|
10291
10293
|
setAiBlocks(0);
|
|
10292
10294
|
setStorageBlocks(0);
|
|
10293
10295
|
setIsCreating(false);
|
|
10294
10296
|
}
|
|
10295
10297
|
onOpenChange(newOpen);
|
|
10296
10298
|
};
|
|
10297
|
-
const prices =
|
|
10299
|
+
const prices = chunkP2YM67Y5_cjs.findProPrices(products);
|
|
10298
10300
|
const intervalPrice = isAnnual ? prices.annual : prices.monthly;
|
|
10299
|
-
const selectedPrice =
|
|
10301
|
+
const selectedPrice = chunkP2YM67Y5_cjs.packPrice(intervalPrice);
|
|
10300
10302
|
const currency = intervalPrice?.currency ?? "gbp";
|
|
10301
|
-
const savingsPercent =
|
|
10303
|
+
const savingsPercent = chunkP2YM67Y5_cjs.calcSavingsPercent(prices.monthly, prices.annual);
|
|
10302
10304
|
const isPro = stripeEnabled && plan !== "free";
|
|
10303
10305
|
const quote = useCheckoutQuote({
|
|
10304
10306
|
interval: isAnnual ? "year" : "month",
|
|
@@ -10308,14 +10310,14 @@ function NewProjectFlow({ open, onOpenChange, defaultName }) {
|
|
|
10308
10310
|
storageBlocks,
|
|
10309
10311
|
enabled: open && isPro && !!selectedPrice
|
|
10310
10312
|
});
|
|
10311
|
-
const canSubmit = !!projectName.trim() && !isCreating && !createProject.isPending && (!isPro || !!selectedPrice &&
|
|
10313
|
+
const canSubmit = !!projectName.trim() && !isCreating && !createProject.isPending && (!isPro || !!selectedPrice && chunkP2YM67Y5_cjs.parseBudgetPounds(addonBudget) !== void 0 && quote.canContinue);
|
|
10312
10314
|
const handleCreateFree = () => {
|
|
10313
10315
|
setIsCreating(true);
|
|
10314
10316
|
createProject.mutate(
|
|
10315
10317
|
{
|
|
10316
10318
|
name: projectName.trim(),
|
|
10317
10319
|
plan: "free",
|
|
10318
|
-
daily_cap_per_user:
|
|
10320
|
+
daily_cap_per_user: chunkP2YM67Y5_cjs.SUGGESTED_DAILY_CAP_PER_USER
|
|
10319
10321
|
},
|
|
10320
10322
|
{
|
|
10321
10323
|
onSuccess: () => {
|
|
@@ -10332,14 +10334,14 @@ function NewProjectFlow({ open, onOpenChange, defaultName }) {
|
|
|
10332
10334
|
};
|
|
10333
10335
|
const handleSubscribe = () => {
|
|
10334
10336
|
const interval = isAnnual ? "year" : "month";
|
|
10335
|
-
const parsed =
|
|
10336
|
-
const budgetToSend = parsed == null || parsed ===
|
|
10337
|
+
const parsed = chunkP2YM67Y5_cjs.parseBudgetPounds(addonBudget);
|
|
10338
|
+
const budgetToSend = parsed == null || parsed === chunkP2YM67Y5_cjs.DEFAULT_SPEND_CAP_PENCE ? null : parsed;
|
|
10337
10339
|
setIsCreating(true);
|
|
10338
10340
|
createProject.mutate(
|
|
10339
10341
|
{
|
|
10340
10342
|
name: projectName.trim(),
|
|
10341
10343
|
plan: "pro",
|
|
10342
|
-
daily_cap_per_user:
|
|
10344
|
+
daily_cap_per_user: chunkP2YM67Y5_cjs.SUGGESTED_DAILY_CAP_PER_USER
|
|
10343
10345
|
},
|
|
10344
10346
|
{
|
|
10345
10347
|
onSuccess: (newProject) => {
|
|
@@ -10380,8 +10382,8 @@ function NewProjectFlow({ open, onOpenChange, defaultName }) {
|
|
|
10380
10382
|
description: stripeEnabled ? "Name it and pick a plan." : "Projects group your workspaces.",
|
|
10381
10383
|
showDescription: true,
|
|
10382
10384
|
size: "xl",
|
|
10383
|
-
children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
10384
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
10385
|
+
children: /* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.PlanStack, { gap: 5, children: [
|
|
10386
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.PlanStack, { gap: 2, children: [
|
|
10385
10387
|
/* @__PURE__ */ jsxRuntime.jsx(ui.Label, { htmlFor: "new-project-name", children: "Name" }),
|
|
10386
10388
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10387
10389
|
ui.Input,
|
|
@@ -10397,16 +10399,16 @@ function NewProjectFlow({ open, onOpenChange, defaultName }) {
|
|
|
10397
10399
|
}
|
|
10398
10400
|
)
|
|
10399
10401
|
] }),
|
|
10400
|
-
stripeEnabled && (productsLoading ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
10401
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
10402
|
+
stripeEnabled && (productsLoading ? /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanNotice, { children: "Loading plans\u2026" }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
10403
|
+
/* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.PlanPickerCard, { children: [
|
|
10402
10404
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10403
|
-
|
|
10405
|
+
chunkTQUYWUEE_cjs.PlanPickerHeader,
|
|
10404
10406
|
{
|
|
10405
10407
|
title: "Plan",
|
|
10406
10408
|
info: /* @__PURE__ */ jsxRuntime.jsx(PlanInfoPopover2, {}),
|
|
10407
10409
|
infoPlacement: "toggle",
|
|
10408
10410
|
toggle: plan !== "free" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
10409
|
-
|
|
10411
|
+
chunkTQUYWUEE_cjs.PricingToggle,
|
|
10410
10412
|
{
|
|
10411
10413
|
isAnnual,
|
|
10412
10414
|
onToggle: () => setIsAnnual(!isAnnual),
|
|
@@ -10444,7 +10446,7 @@ function NewProjectFlow({ open, onOpenChange, defaultName }) {
|
|
|
10444
10446
|
currency
|
|
10445
10447
|
}
|
|
10446
10448
|
),
|
|
10447
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10449
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PromoCodeInput, { value: promoCode, onChange: setPromoCode }),
|
|
10448
10450
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10449
10451
|
CheckoutCountrySelect,
|
|
10450
10452
|
{
|
|
@@ -10463,10 +10465,10 @@ function NewProjectFlow({ open, onOpenChange, defaultName }) {
|
|
|
10463
10465
|
onPostalCodeChange: setPostalCode
|
|
10464
10466
|
}
|
|
10465
10467
|
)
|
|
10466
|
-
] }) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
10468
|
+
] }) : /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanNotice, { children: "Pro isn't available right now." }))
|
|
10467
10469
|
] })),
|
|
10468
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10469
|
-
isSlow && /* @__PURE__ */ jsxRuntime.jsx(
|
|
10470
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanActionButton, { onClick: submit, disabled: !canSubmit, children: isCreating ? "Creating\u2026" : isPro ? "Continue to payment" : "Create project" }),
|
|
10471
|
+
isSlow && /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PlanNotice, { className: "text-xs", testId: "new-project-still-working", children: "Still working. We'll update here." })
|
|
10470
10472
|
] })
|
|
10471
10473
|
}
|
|
10472
10474
|
),
|
|
@@ -10494,7 +10496,7 @@ function NewProjectFlow({ open, onOpenChange, defaultName }) {
|
|
|
10494
10496
|
function useAutoRefreshPendingProjects() {
|
|
10495
10497
|
const { data: projects } = react$1.useProjects();
|
|
10496
10498
|
const refreshProject = react$1.useRefreshProject();
|
|
10497
|
-
const currentUserExtId =
|
|
10499
|
+
const currentUserExtId = chunkP2YM67Y5_cjs.useSelfExtId();
|
|
10498
10500
|
const refreshedRef = react.useRef(/* @__PURE__ */ new Set());
|
|
10499
10501
|
react.useEffect(() => {
|
|
10500
10502
|
if (!projects || !currentUserExtId) return;
|
|
@@ -10540,7 +10542,7 @@ function WorkspaceCardsView({
|
|
|
10540
10542
|
createDisabledReason,
|
|
10541
10543
|
workspaceState
|
|
10542
10544
|
}) {
|
|
10543
|
-
const { stripeEnabled } =
|
|
10545
|
+
const { stripeEnabled } = chunkP2YM67Y5_cjs.useBillingSupport();
|
|
10544
10546
|
const workspaceLabel = ui.getEntityLabel("WORKSPACE");
|
|
10545
10547
|
const projectLabel = ui.getEntityLabel("PROJECT").toLowerCase();
|
|
10546
10548
|
const { groups, projects, selfId } = list;
|
|
@@ -10559,7 +10561,7 @@ function WorkspaceCardsView({
|
|
|
10559
10561
|
}
|
|
10560
10562
|
return /* @__PURE__ */ jsxRuntime.jsx(chunkMSFQDELO_cjs.WorkspaceList, { testId: "workspace-cards-list", children: groups.map((group) => {
|
|
10561
10563
|
const project = projects.find((p) => p.external_id === group.projectExtId);
|
|
10562
|
-
const { breakdown, readout } =
|
|
10564
|
+
const { breakdown, readout } = chunkP2YM67Y5_cjs.projectGroupBilling(project, {
|
|
10563
10565
|
isOwned: group.isOwned,
|
|
10564
10566
|
stripeEnabled
|
|
10565
10567
|
});
|
|
@@ -10718,7 +10720,7 @@ function useConnectedWorkspaceList({
|
|
|
10718
10720
|
[selfId, pinned]
|
|
10719
10721
|
);
|
|
10720
10722
|
const filtered = react.useMemo(
|
|
10721
|
-
() =>
|
|
10723
|
+
() => chunkTQUYWUEE_cjs.applyTriStateFilters(workspaces, filterMap, attributesOf),
|
|
10722
10724
|
[workspaces, filterMap, attributesOf]
|
|
10723
10725
|
);
|
|
10724
10726
|
const groups = react.useMemo(
|
|
@@ -10783,7 +10785,7 @@ function useConnectedWorkspaceList({
|
|
|
10783
10785
|
};
|
|
10784
10786
|
}
|
|
10785
10787
|
var WorkspaceTableView = react.lazy(
|
|
10786
|
-
() => import('../WorkspaceTableView-
|
|
10788
|
+
() => import('../WorkspaceTableView-EYLEUZZT.cjs').then((m) => ({ default: m.WorkspaceTableView }))
|
|
10787
10789
|
);
|
|
10788
10790
|
var WORKSPACES_TAB_ID = "workspaces";
|
|
10789
10791
|
var defaultRenderMember2 = (user, size) => {
|
|
@@ -10835,7 +10837,7 @@ function ConnectedWorkspaceList({
|
|
|
10835
10837
|
else void openWorkspace(workspace.external_id, { name: workspace.name });
|
|
10836
10838
|
};
|
|
10837
10839
|
const createDisabledReason = list.canCreateProjects === false ? react$1.PROJECT_CREATION_DENIED_REASON : void 0;
|
|
10838
|
-
if (list.isLoading) return /* @__PURE__ */ jsxRuntime.jsx(
|
|
10840
|
+
if (list.isLoading) return /* @__PURE__ */ jsxRuntime.jsx(chunkGC2FSPSQ_cjs.LoadingIndicator, { message: "Loading workspaces..." });
|
|
10839
10841
|
if (list.error) {
|
|
10840
10842
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
10841
10843
|
chunkOOU4QLRK_cjs.HomeLoadError,
|
|
@@ -10908,7 +10910,7 @@ function ConnectedWorkspaceList({
|
|
|
10908
10910
|
workspaceState
|
|
10909
10911
|
}
|
|
10910
10912
|
) })
|
|
10911
|
-
) : /* @__PURE__ */ jsxRuntime.jsx(react.Suspense, { fallback: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10913
|
+
) : /* @__PURE__ */ jsxRuntime.jsx(react.Suspense, { fallback: /* @__PURE__ */ jsxRuntime.jsx(chunkGC2FSPSQ_cjs.LoadingIndicator, { message: "Loading grid..." }), children: /* @__PURE__ */ jsxRuntime.jsx(chunkOOU4QLRK_cjs.HomeCenteredColumn, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10912
10914
|
WorkspaceTableView,
|
|
10913
10915
|
{
|
|
10914
10916
|
list,
|
|
@@ -10952,7 +10954,7 @@ function ConnectedProjectsPanel({
|
|
|
10952
10954
|
const { data: projects } = react$1.useProjects();
|
|
10953
10955
|
const canCreateProjects = react$1.useCanCreateProjects();
|
|
10954
10956
|
const { userId } = chunkFM3IRQJW_cjs.useConnectedWorkspace();
|
|
10955
|
-
const { stripeEnabled } =
|
|
10957
|
+
const { stripeEnabled } = chunkP2YM67Y5_cjs.useBillingSupport();
|
|
10956
10958
|
const billingPortal = useOpenBillingPortal();
|
|
10957
10959
|
const [newProjectOpen, setNewProjectOpen] = react.useState(false);
|
|
10958
10960
|
useAutoRefreshPendingProjects();
|
|
@@ -10979,15 +10981,15 @@ function ConnectedProjectsPanel({
|
|
|
10979
10981
|
[ownedCount, tabs, projects]
|
|
10980
10982
|
);
|
|
10981
10983
|
const paidProject = projects?.find(isPaid);
|
|
10982
|
-
const panel = /* @__PURE__ */ jsxRuntime.jsxs(
|
|
10983
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10984
|
+
const panel = /* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.PanelFrame, { className, testId: "projects-panel", children: [
|
|
10985
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.DraggableHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10984
10986
|
chunk7RGLTF76_cjs.TabHeader,
|
|
10985
10987
|
{
|
|
10986
10988
|
tabs: headerTabs,
|
|
10987
10989
|
activeTabId: activeProjectId ?? PROJECTS_BASE_TAB_ID,
|
|
10988
10990
|
onTabChange: (id) => tabs.onSelect(id === PROJECTS_BASE_TAB_ID ? null : id),
|
|
10989
10991
|
afterTabs: (isCompact) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
10990
|
-
|
|
10992
|
+
chunkTQUYWUEE_cjs.PanelAddButton,
|
|
10991
10993
|
{
|
|
10992
10994
|
label: "New project",
|
|
10993
10995
|
onClick: () => setNewProjectOpen(true),
|
|
@@ -11002,15 +11004,15 @@ function ConnectedProjectsPanel({
|
|
|
11002
11004
|
compactBreakpoint: 360
|
|
11003
11005
|
}
|
|
11004
11006
|
) }),
|
|
11005
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
11007
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PanelFrameBody, { children: activeProjectId ? /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PanelScroll, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
11006
11008
|
ProjectDetail,
|
|
11007
11009
|
{
|
|
11008
11010
|
projectExtId: activeProjectId,
|
|
11009
11011
|
storage: projectStorage?.(activeProjectId)
|
|
11010
11012
|
}
|
|
11011
|
-
) }) : /* @__PURE__ */ jsxRuntime.jsxs(
|
|
11013
|
+
) }) : /* @__PURE__ */ jsxRuntime.jsxs(chunkTQUYWUEE_cjs.PanelScroll, { variant: "padded", children: [
|
|
11012
11014
|
/* @__PURE__ */ jsxRuntime.jsx(ProjectsTable, {}),
|
|
11013
|
-
stripeEnabled && paidProject && /* @__PURE__ */ jsxRuntime.jsx(
|
|
11015
|
+
stripeEnabled && paidProject && /* @__PURE__ */ jsxRuntime.jsx(chunkTQUYWUEE_cjs.PanelActionsRow, { children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
11014
11016
|
ui.Button,
|
|
11015
11017
|
{
|
|
11016
11018
|
onClick: () => billingPortal.open(paidProject.external_id),
|
|
@@ -11065,7 +11067,7 @@ function recentConversations(conversations) {
|
|
|
11065
11067
|
return [...conversations].sort((a, b) => time(b.updated_at) - time(a.updated_at)).slice(0, RECENT_ROWS).map((c) => ({
|
|
11066
11068
|
id: c.external_id,
|
|
11067
11069
|
title: c.title?.trim() || "Untitled thread",
|
|
11068
|
-
subtitle: c.status ? [
|
|
11070
|
+
subtitle: c.status ? [chunkYF3QUHKN_cjs.STATUS_LABELS[chunkYF3QUHKN_cjs.asTaskStatus(c.status)], c.due_at ? `due ${shortDate(c.due_at)}` : null].filter(Boolean).join(" \xB7 ") : `${c.message_count} ${c.message_count === 1 ? "message" : "messages"}`,
|
|
11069
11071
|
time: timeAndDate(c.updated_at)
|
|
11070
11072
|
}));
|
|
11071
11073
|
}
|
|
@@ -11982,7 +11984,7 @@ var MailBodyEditor = react.lazy(
|
|
|
11982
11984
|
}))
|
|
11983
11985
|
);
|
|
11984
11986
|
var NativeDocxEditor = react.lazy(
|
|
11985
|
-
() => import('../NativeDocxEditor-
|
|
11987
|
+
() => import('../NativeDocxEditor-T2PJIZMU.cjs').then((m) => ({ default: m.NativeDocxEditor }))
|
|
11986
11988
|
);
|
|
11987
11989
|
var NO_WORD = {
|
|
11988
11990
|
adapter: {
|
|
@@ -13157,7 +13159,7 @@ function ConnectedMailbox({
|
|
|
13157
13159
|
onTabChange: () => {
|
|
13158
13160
|
},
|
|
13159
13161
|
compactBreakpoint: 360,
|
|
13160
|
-
firstTabContent: account ? /* @__PURE__ */ jsxRuntime.jsxs(
|
|
13162
|
+
firstTabContent: account ? /* @__PURE__ */ jsxRuntime.jsxs(chunkQJFJ5JBF_cjs.FilesFilterBar, { children: [
|
|
13161
13163
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
13162
13164
|
chunk2EI7NCUA_cjs.FilterInput,
|
|
13163
13165
|
{
|
|
@@ -13192,7 +13194,7 @@ function ConnectedMailbox({
|
|
|
13192
13194
|
}
|
|
13193
13195
|
),
|
|
13194
13196
|
folderList && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex shrink-0 items-center gap-2", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
13195
|
-
|
|
13197
|
+
chunkQJFJ5JBF_cjs.FolderFilterButton,
|
|
13196
13198
|
{
|
|
13197
13199
|
label: folderList.find((f) => f.id === folderId)?.name ?? "Folders",
|
|
13198
13200
|
isActive: false,
|
|
@@ -13200,7 +13202,7 @@ function ConnectedMailbox({
|
|
|
13200
13202
|
onOpenChange: setFolderMenuOpen,
|
|
13201
13203
|
testId: "mail-folder-button",
|
|
13202
13204
|
children: folderList.map((item) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
13203
|
-
|
|
13205
|
+
chunkQJFJ5JBF_cjs.FolderPickerRow,
|
|
13204
13206
|
{
|
|
13205
13207
|
label: item.name,
|
|
13206
13208
|
count: item.unread > 0 ? item.unread : void 0,
|
|
@@ -13465,7 +13467,7 @@ function ConnectedMailbox({
|
|
|
13465
13467
|
}
|
|
13466
13468
|
),
|
|
13467
13469
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
13468
|
-
|
|
13470
|
+
chunkDWZXSPMB_cjs.ConfirmDialog,
|
|
13469
13471
|
{
|
|
13470
13472
|
isOpen: confirmDelete !== null,
|
|
13471
13473
|
onClose: () => setConfirmDelete(null),
|
|
@@ -16951,7 +16953,7 @@ function TileStatusBadge({ doc, status }) {
|
|
|
16951
16953
|
case "failed":
|
|
16952
16954
|
tone = "danger";
|
|
16953
16955
|
icon2 = /* @__PURE__ */ jsxRuntime.jsx(
|
|
16954
|
-
|
|
16956
|
+
chunkQJFJ5JBF_cjs.FailedStageIcon,
|
|
16955
16957
|
{
|
|
16956
16958
|
stage: doc.failed_stage ?? null,
|
|
16957
16959
|
errorMessage: doc.error_message,
|
|
@@ -16978,7 +16980,7 @@ function TileStatusBadge({ doc, status }) {
|
|
|
16978
16980
|
return null;
|
|
16979
16981
|
}
|
|
16980
16982
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
16981
|
-
|
|
16983
|
+
chunkQJFJ5JBF_cjs.StatusPill,
|
|
16982
16984
|
{
|
|
16983
16985
|
tone,
|
|
16984
16986
|
icon: icon2,
|
|
@@ -16990,11 +16992,11 @@ function TileStatusBadge({ doc, status }) {
|
|
|
16990
16992
|
function TileVisibilityBadge({ doc }) {
|
|
16991
16993
|
const shared = !!doc.shared;
|
|
16992
16994
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
16993
|
-
|
|
16995
|
+
chunkQJFJ5JBF_cjs.StatusPill,
|
|
16994
16996
|
{
|
|
16995
16997
|
icon: /* @__PURE__ */ jsxRuntime.jsx(ui.VisibilityIcon, { isShared: shared, className: "size-3.5", "aria-hidden": true }),
|
|
16996
16998
|
label: shared ? ui.getEntityLabel("WORKSPACE") : "Only you",
|
|
16997
|
-
title:
|
|
16999
|
+
title: chunkQJFJ5JBF_cjs.visibilityAudience(shared),
|
|
16998
17000
|
testId: `explorer-file-visibility-${doc.external_id}`
|
|
16999
17001
|
}
|
|
17000
17002
|
);
|
|
@@ -17021,7 +17023,7 @@ function FileTooltipContent({
|
|
|
17021
17023
|
}) {
|
|
17022
17024
|
const labels = (doc.doctags ?? []).map((dt) => tagNameById.get(dt.tag_ext_id)).filter((name) => !!name);
|
|
17023
17025
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
17024
|
-
|
|
17026
|
+
chunkQJFJ5JBF_cjs.ExplorerFileTooltip,
|
|
17025
17027
|
{
|
|
17026
17028
|
title: ui.getDocumentTitle(doc, doc.file_name ?? ""),
|
|
17027
17029
|
summary: react$1.getDocumentSubject(doc),
|
|
@@ -17030,7 +17032,7 @@ function FileTooltipContent({
|
|
|
17030
17032
|
shared: !!doc.shared,
|
|
17031
17033
|
visibilityIcon: /* @__PURE__ */ jsxRuntime.jsx(ui.VisibilityIcon, { isShared: !!doc.shared, className: "h-3 w-3" }),
|
|
17032
17034
|
labels,
|
|
17033
|
-
uiLabels: { shared:
|
|
17035
|
+
uiLabels: { shared: chunkQJFJ5JBF_cjs.visibilityAudience(true), private: chunkQJFJ5JBF_cjs.visibilityAudience(false) }
|
|
17034
17036
|
}
|
|
17035
17037
|
);
|
|
17036
17038
|
}
|
|
@@ -17141,7 +17143,7 @@ var FileTile = react.memo(function FileTile2({
|
|
|
17141
17143
|
];
|
|
17142
17144
|
const tooltip = renaming || dndActive ? void 0 : /* @__PURE__ */ jsxRuntime.jsx(FileTooltipContent, { doc, modifiedBy, tagNameById });
|
|
17143
17145
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
17144
|
-
|
|
17146
|
+
chunkQJFJ5JBF_cjs.ExplorerFileTile,
|
|
17145
17147
|
{
|
|
17146
17148
|
id: doc.external_id,
|
|
17147
17149
|
title: ui.getDocumentTitle(doc, doc.file_name ?? ""),
|
|
@@ -17234,17 +17236,17 @@ var FolderTile = react.memo(function FolderTile2({
|
|
|
17234
17236
|
}
|
|
17235
17237
|
] : []
|
|
17236
17238
|
];
|
|
17237
|
-
const displayName = folder.path.length === 1 ?
|
|
17238
|
-
const providerIcon = folder.path.length === 1 &&
|
|
17239
|
+
const displayName = folder.path.length === 1 ? chunkQJFJ5JBF_cjs.formatFolderSegment(folder.name) : folder.name;
|
|
17240
|
+
const providerIcon = folder.path.length === 1 && chunkQJFJ5JBF_cjs.hasFolderProviderIcon(folder.name) ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
17239
17241
|
"span",
|
|
17240
17242
|
{
|
|
17241
17243
|
className: "flex items-center justify-center drop-shadow-sm",
|
|
17242
17244
|
style: { width: iconSize, height: iconSize },
|
|
17243
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
17245
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.FolderProviderIcon, { folderPath: folder.name, className: "h-full w-full" })
|
|
17244
17246
|
}
|
|
17245
17247
|
) : void 0;
|
|
17246
17248
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
17247
|
-
|
|
17249
|
+
chunkQJFJ5JBF_cjs.ExplorerFolderTile,
|
|
17248
17250
|
{
|
|
17249
17251
|
name: folder.name,
|
|
17250
17252
|
displayName: displayName === "" ? null : displayName,
|
|
@@ -17276,7 +17278,7 @@ var COMPACT_BELOW = 132;
|
|
|
17276
17278
|
var NO_DOCUMENTS = [];
|
|
17277
17279
|
function useFilesWorkspace() {
|
|
17278
17280
|
const { workspaceId, userId, live } = chunkFM3IRQJW_cjs.useConnectedWorkspace();
|
|
17279
|
-
const { members, role } =
|
|
17281
|
+
const { members, role } = chunk2BHDRVVL_cjs.useConnectedWorkspaceRole();
|
|
17280
17282
|
const { data: workspaces } = react$1.useWorkspaces({ enabled: live });
|
|
17281
17283
|
const workspaceName = workspaces?.find((w) => w.external_id === workspaceId)?.name;
|
|
17282
17284
|
return {
|
|
@@ -17350,8 +17352,8 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17350
17352
|
const { folders, files } = react.useMemo(() => {
|
|
17351
17353
|
const result = isSearching ? {
|
|
17352
17354
|
folders: [],
|
|
17353
|
-
files:
|
|
17354
|
-
} :
|
|
17355
|
+
files: chunkQJFJ5JBF_cjs.searchExplorerDocuments(documents, search, sort)
|
|
17356
|
+
} : chunkQJFJ5JBF_cjs.buildExplorerEntries(documents, currentPath, sort, [...pendingFolders]);
|
|
17355
17357
|
if (sortReversed) result.files = [...result.files].reverse();
|
|
17356
17358
|
return result;
|
|
17357
17359
|
}, [documents, currentPath, sort, isSearching, search, sortReversed, pendingFolders]);
|
|
@@ -17362,7 +17364,7 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17362
17364
|
const orderedFileIds = react.useMemo(() => files.map((d) => d.external_id), [files]);
|
|
17363
17365
|
const folderDocs = react.useMemo(() => {
|
|
17364
17366
|
const map = /* @__PURE__ */ new Map();
|
|
17365
|
-
for (const f of folders) map.set(f.path.join("/"),
|
|
17367
|
+
for (const f of folders) map.set(f.path.join("/"), chunkQJFJ5JBF_cjs.collectFolderDocs(documents, f.path));
|
|
17366
17368
|
return map;
|
|
17367
17369
|
}, [folders, documents]);
|
|
17368
17370
|
const folderSelection = react.useMemo(() => {
|
|
@@ -17510,7 +17512,7 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17510
17512
|
let name = base;
|
|
17511
17513
|
let i = 2;
|
|
17512
17514
|
while (siblings.has(name.toLowerCase())) name = `${base} ${i++}`;
|
|
17513
|
-
const path =
|
|
17515
|
+
const path = chunkQJFJ5JBF_cjs.joinFolderPath([...currentPath, name]);
|
|
17514
17516
|
if (!path) return;
|
|
17515
17517
|
addPendingFolder(wsId, path);
|
|
17516
17518
|
setEditingFolderPath(path);
|
|
@@ -17546,10 +17548,10 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17546
17548
|
notify14(`A folder named "${name}" already exists here.`, "error");
|
|
17547
17549
|
return;
|
|
17548
17550
|
}
|
|
17549
|
-
const oldPath =
|
|
17551
|
+
const oldPath = chunkQJFJ5JBF_cjs.joinFolderPath(folder.path);
|
|
17550
17552
|
const newPrefix = [...folder.path.slice(0, -1), name];
|
|
17551
|
-
const newPath =
|
|
17552
|
-
const docs =
|
|
17553
|
+
const newPath = chunkQJFJ5JBF_cjs.joinFolderPath(newPrefix);
|
|
17554
|
+
const docs = chunkQJFJ5JBF_cjs.collectFolderDocs(documents, folder.path);
|
|
17553
17555
|
try {
|
|
17554
17556
|
if (await renameFolder(docs, folder.path, newPrefix) > 0) {
|
|
17555
17557
|
notify14(`Renamed folder to "${name}"`, "success");
|
|
@@ -17608,7 +17610,7 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17608
17610
|
const handleToggleFolder = react.useCallback(
|
|
17609
17611
|
(folder, e) => {
|
|
17610
17612
|
e.stopPropagation();
|
|
17611
|
-
const ids =
|
|
17613
|
+
const ids = chunkQJFJ5JBF_cjs.collectFolderDocs(documents, folder.path).map((d) => d.external_id);
|
|
17612
17614
|
if (ids.length === 0) return;
|
|
17613
17615
|
if (ids.every((id) => selectedSet.has(id))) {
|
|
17614
17616
|
const remove = new Set(ids);
|
|
@@ -17669,9 +17671,9 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17669
17671
|
);
|
|
17670
17672
|
const handleDelete = react.useCallback(
|
|
17671
17673
|
async (doc) => {
|
|
17672
|
-
const name =
|
|
17674
|
+
const name = chunkQJFJ5JBF_cjs.getExplorerDisplayName(doc);
|
|
17673
17675
|
const confirmed = await confirm({
|
|
17674
|
-
message: `Delete "${name}"? ${
|
|
17676
|
+
message: `Delete "${name}"? ${chunkQJFJ5JBF_cjs.RECENTLY_DELETED_HINT}`,
|
|
17675
17677
|
title: "Delete file"
|
|
17676
17678
|
});
|
|
17677
17679
|
if (!confirmed) return;
|
|
@@ -17691,7 +17693,7 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17691
17693
|
);
|
|
17692
17694
|
const handleFolderDownload = react.useCallback(
|
|
17693
17695
|
(folder) => {
|
|
17694
|
-
const docs =
|
|
17696
|
+
const docs = chunkQJFJ5JBF_cjs.collectFolderDocs(documents, folder.path);
|
|
17695
17697
|
if (docs.length > 0) void downloadDocuments(docs);
|
|
17696
17698
|
},
|
|
17697
17699
|
[documents, downloadDocuments]
|
|
@@ -17700,7 +17702,7 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17700
17702
|
if (onFolderMove) return onFolderMove;
|
|
17701
17703
|
if (!onMoveSelected) return void 0;
|
|
17702
17704
|
return (folder) => {
|
|
17703
|
-
const ids =
|
|
17705
|
+
const ids = chunkQJFJ5JBF_cjs.collectFolderDocs(documents, folder.path).map((d) => d.external_id);
|
|
17704
17706
|
if (ids.length === 0) return;
|
|
17705
17707
|
onSelectionChange(ids);
|
|
17706
17708
|
onMoveSelected();
|
|
@@ -17708,14 +17710,14 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17708
17710
|
}, [documents, onFolderMove, onMoveSelected, onSelectionChange]);
|
|
17709
17711
|
const handleFolderDelete = react.useCallback(
|
|
17710
17712
|
async (folder) => {
|
|
17711
|
-
const docs =
|
|
17713
|
+
const docs = chunkQJFJ5JBF_cjs.collectFolderDocs(documents, folder.path);
|
|
17712
17714
|
if (docs.length === 0) {
|
|
17713
|
-
const path =
|
|
17715
|
+
const path = chunkQJFJ5JBF_cjs.joinFolderPath(folder.path);
|
|
17714
17716
|
if (wsId && path) removePendingFolder(wsId, path);
|
|
17715
17717
|
return;
|
|
17716
17718
|
}
|
|
17717
17719
|
const confirmed = await confirm({
|
|
17718
|
-
message: `Delete folder "${folder.name}" and its ${docs.length} item${docs.length === 1 ? "" : "s"}? ${
|
|
17720
|
+
message: `Delete folder "${folder.name}" and its ${docs.length} item${docs.length === 1 ? "" : "s"}? ${chunkQJFJ5JBF_cjs.RECENTLY_DELETED_HINT_PLURAL}`,
|
|
17719
17721
|
title: "Delete folder"
|
|
17720
17722
|
});
|
|
17721
17723
|
if (!confirmed) return;
|
|
@@ -17732,8 +17734,8 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17732
17734
|
[confirm, documents, deleteDocuments, onSelectionChange, removePendingFolder, wsId, notify14]
|
|
17733
17735
|
);
|
|
17734
17736
|
const canDeleteFolder = react.useCallback(
|
|
17735
|
-
(folder) => canUpload &&
|
|
17736
|
-
(doc) =>
|
|
17737
|
+
(folder) => canUpload && chunkQJFJ5JBF_cjs.collectFolderDocs(documents, folder.path).every(
|
|
17738
|
+
(doc) => chunkQJFJ5JBF_cjs.canDeleteDocument(doc, userId, role)
|
|
17737
17739
|
),
|
|
17738
17740
|
[canUpload, documents, userId, role]
|
|
17739
17741
|
);
|
|
@@ -17792,7 +17794,7 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17792
17794
|
setActiveDragId(null);
|
|
17793
17795
|
const data = event.over?.data.current;
|
|
17794
17796
|
if (data?.type === "folder" && data.path) {
|
|
17795
|
-
const targetFolder =
|
|
17797
|
+
const targetFolder = chunkQJFJ5JBF_cjs.joinFolderPath(data.path);
|
|
17796
17798
|
const moving = dragIdsRef.current.filter((id) => {
|
|
17797
17799
|
const doc = documents.find((d) => d.external_id === id);
|
|
17798
17800
|
return doc && (doc.folder ?? null) !== targetFolder;
|
|
@@ -17832,7 +17834,7 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17832
17834
|
const dropped = Array.from(e.dataTransfer.files ?? []);
|
|
17833
17835
|
if (dropped.length > 0) {
|
|
17834
17836
|
e.preventDefault();
|
|
17835
|
-
onUploadFiles(dropped,
|
|
17837
|
+
onUploadFiles(dropped, chunkQJFJ5JBF_cjs.joinFolderPath(currentPath));
|
|
17836
17838
|
}
|
|
17837
17839
|
},
|
|
17838
17840
|
[canUpload, currentPath, onUploadFiles]
|
|
@@ -17849,9 +17851,9 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17849
17851
|
onDragEnd: handleDragEnd,
|
|
17850
17852
|
onDragCancel: () => setActiveDragId(null),
|
|
17851
17853
|
children: [
|
|
17852
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17854
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.ExplorerFrame, { "data-testid": "documents-explorer", children: /* @__PURE__ */ jsxRuntime.jsxs(chunkQJFJ5JBF_cjs.ExplorerStage, { children: [
|
|
17853
17855
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17854
|
-
|
|
17856
|
+
chunkQJFJ5JBF_cjs.ExplorerScroller,
|
|
17855
17857
|
{
|
|
17856
17858
|
ref: scrollRef,
|
|
17857
17859
|
onClick: handleBackgroundClick,
|
|
@@ -17861,15 +17863,15 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17861
17863
|
onDragLeave: handleNativeDragLeave,
|
|
17862
17864
|
onDrop: handleNativeDrop,
|
|
17863
17865
|
"data-testid": "explorer-scroll",
|
|
17864
|
-
children: isLoading && documents.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
17865
|
-
|
|
17866
|
+
children: isLoading && documents.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.ExplorerLoadingTiles, {}) : entries.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
17867
|
+
chunkQJFJ5JBF_cjs.ExplorerEmpty,
|
|
17866
17868
|
{
|
|
17867
17869
|
title: isSearching ? `No files match "${search.trim()}"` : "This folder is empty",
|
|
17868
17870
|
description: isSearching ? "Try a different search." : canUpload ? "Drop files here or use Upload to add documents." : "No documents here yet."
|
|
17869
17871
|
}
|
|
17870
17872
|
) : containerWidth === 0 ? (
|
|
17871
17873
|
// Not measured yet: rendering now would flash one stretched column.
|
|
17872
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17874
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.ExplorerLoadingTiles, {})
|
|
17873
17875
|
) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
17874
17876
|
"div",
|
|
17875
17877
|
{
|
|
@@ -17929,7 +17931,7 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17929
17931
|
dragging: activeDragId === doc.external_id,
|
|
17930
17932
|
dndActive: activeDragId !== null,
|
|
17931
17933
|
renaming: renamingId === doc.external_id,
|
|
17932
|
-
canDelete:
|
|
17934
|
+
canDelete: chunkQJFJ5JBF_cjs.canDeleteDocument(doc, userId, role),
|
|
17933
17935
|
thumbnailUrl: thumbnailsById.get(doc.external_id),
|
|
17934
17936
|
modifiedBy: userById.get(
|
|
17935
17937
|
doc.updated_by_ext_id ?? doc.created_by_ext_id
|
|
@@ -17957,9 +17959,9 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17957
17959
|
)
|
|
17958
17960
|
}
|
|
17959
17961
|
),
|
|
17960
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17962
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.ExplorerMarquee, { ref: marqueeOverlayRef, "data-testid": "explorer-marquee" }),
|
|
17961
17963
|
isFileDragOver && /* @__PURE__ */ jsxRuntime.jsx(
|
|
17962
|
-
|
|
17964
|
+
chunkQJFJ5JBF_cjs.ExplorerDropOverlay,
|
|
17963
17965
|
{
|
|
17964
17966
|
label: `Drop to upload${currentPath.length > 0 ? ` to "${currentPath[currentPath.length - 1]}"` : ""}`
|
|
17965
17967
|
}
|
|
@@ -17973,7 +17975,7 @@ var ConnectedFilesExplorer = react.forwardRef(function ConnectedFilesExplorer2({
|
|
|
17973
17975
|
function DragPreview({ doc, count }) {
|
|
17974
17976
|
const Icon = ui.getFileTypeIcon(doc.file_name, { mime: doc.file_type });
|
|
17975
17977
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
17976
|
-
|
|
17978
|
+
chunkQJFJ5JBF_cjs.ExplorerDragPreview,
|
|
17977
17979
|
{
|
|
17978
17980
|
icon: /* @__PURE__ */ jsxRuntime.jsx(Icon, { size: 20 }),
|
|
17979
17981
|
title: ui.getDocumentTitle(doc, doc.file_name ?? "Untitled"),
|
|
@@ -18059,7 +18061,7 @@ function ConnectedUploadDropzone({
|
|
|
18059
18061
|
const onFiles = browse(fileInputRef);
|
|
18060
18062
|
const onFolder = browse(folderInputRef);
|
|
18061
18063
|
const dropTarget = /* @__PURE__ */ jsxRuntime.jsx(
|
|
18062
|
-
|
|
18064
|
+
chunkQJFJ5JBF_cjs.UploadDropArea,
|
|
18063
18065
|
{
|
|
18064
18066
|
isActive: dragActive,
|
|
18065
18067
|
isDisabled: disabled,
|
|
@@ -18073,11 +18075,11 @@ function ConnectedUploadDropzone({
|
|
|
18073
18075
|
onClick: (e) => {
|
|
18074
18076
|
if (e.target === e.currentTarget) onFiles();
|
|
18075
18077
|
},
|
|
18076
|
-
actions: compact ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
18078
|
+
actions: compact ? /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.UploadBrowseButtons, { onFiles, onFolder, isDisabled: disabled }) : void 0
|
|
18077
18079
|
}
|
|
18078
18080
|
);
|
|
18079
18081
|
const urlDialog = (trigger) => onUrlsSubmit ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
18080
|
-
|
|
18082
|
+
chunkQJFJ5JBF_cjs.UrlInputDialog,
|
|
18081
18083
|
{
|
|
18082
18084
|
onUrlsSubmit,
|
|
18083
18085
|
processing: disabled,
|
|
@@ -18090,12 +18092,12 @@ function ConnectedUploadDropzone({
|
|
|
18090
18092
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
18091
18093
|
dropTarget,
|
|
18092
18094
|
compactLeadingAction,
|
|
18093
|
-
onUrlsSubmit && /* @__PURE__ */ jsxRuntime.jsx(
|
|
18095
|
+
onUrlsSubmit && /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.UploadSourceSection, { isIsolated: true, className: "flex flex-wrap justify-center gap-2", children: urlDialog(/* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.UploadUrlButton, { isDisabled: disabled, isCompact: true })) })
|
|
18094
18096
|
] });
|
|
18095
18097
|
}
|
|
18096
18098
|
if (!source) {
|
|
18097
18099
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
18098
|
-
|
|
18100
|
+
chunkQJFJ5JBF_cjs.UploadSourcePicker,
|
|
18099
18101
|
{
|
|
18100
18102
|
isDisabled: disabled,
|
|
18101
18103
|
options: [
|
|
@@ -18131,14 +18133,14 @@ function ConnectedUploadDropzone({
|
|
|
18131
18133
|
}
|
|
18132
18134
|
if (source === "computer") {
|
|
18133
18135
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
18134
|
-
|
|
18136
|
+
chunkQJFJ5JBF_cjs.UploadSourceSection,
|
|
18135
18137
|
{
|
|
18136
18138
|
testId: "upload-source-computer",
|
|
18137
18139
|
className: "flex w-full flex-col gap-3 pointer-coarse:flex-col-reverse",
|
|
18138
18140
|
children: [
|
|
18139
18141
|
dropTarget,
|
|
18140
18142
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
18141
|
-
|
|
18143
|
+
chunkQJFJ5JBF_cjs.UploadBrowseButtons,
|
|
18142
18144
|
{
|
|
18143
18145
|
layout: "grid",
|
|
18144
18146
|
onFiles,
|
|
@@ -18151,15 +18153,15 @@ function ConnectedUploadDropzone({
|
|
|
18151
18153
|
);
|
|
18152
18154
|
}
|
|
18153
18155
|
if (source === "internet" && onUrlsSubmit) {
|
|
18154
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
18156
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.UploadSourceSection, { testId: "upload-source-internet", className: "flex flex-wrap gap-2", children: /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.UploadSourceSection, { isIsolated: true, children: urlDialog(/* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.UploadUrlButton, { isDisabled: disabled })) }) });
|
|
18155
18157
|
}
|
|
18156
18158
|
if (source === "email" && accounts) {
|
|
18157
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
18159
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.UploadSourceSection, { testId: "upload-source-email", isIsolated: true, children: accounts });
|
|
18158
18160
|
}
|
|
18159
18161
|
return null;
|
|
18160
18162
|
})();
|
|
18161
18163
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
18162
|
-
|
|
18164
|
+
chunkQJFJ5JBF_cjs.UploadFrame,
|
|
18163
18165
|
{
|
|
18164
18166
|
isCompact: compact,
|
|
18165
18167
|
isDimmed: disabled || processingMessage !== null,
|
|
@@ -18266,7 +18268,7 @@ function plural2(count) {
|
|
|
18266
18268
|
function DefaultFooter({ submit, shared, onSharedChange }) {
|
|
18267
18269
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex shrink-0 items-center justify-end gap-4 border-t border-border px-4 py-3 sm:px-6", children: [
|
|
18268
18270
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
18269
|
-
|
|
18271
|
+
chunkQJFJ5JBF_cjs.ShareToggle,
|
|
18270
18272
|
{
|
|
18271
18273
|
isVisible: shared,
|
|
18272
18274
|
onToggle: onSharedChange,
|
|
@@ -18431,7 +18433,7 @@ ${summary}`,
|
|
|
18431
18433
|
}
|
|
18432
18434
|
);
|
|
18433
18435
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex min-h-0 flex-1 flex-col", "data-testid": "upload-documents", children: [
|
|
18434
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "min-h-0 flex-1 overflow-y-auto pb-2", children: uploading === null ? /* @__PURE__ */ jsxRuntime.jsxs(
|
|
18436
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "min-h-0 flex-1 overflow-y-auto pb-2", children: uploading === null ? /* @__PURE__ */ jsxRuntime.jsxs(chunkQJFJ5JBF_cjs.UploadContainer, { className: "w-full px-4 pb-4 pt-2 sm:px-6", children: [
|
|
18435
18437
|
files.length === 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
18436
18438
|
ConnectedUploadDropzone,
|
|
18437
18439
|
{
|
|
@@ -18447,7 +18449,7 @@ ${summary}`,
|
|
|
18447
18449
|
}
|
|
18448
18450
|
),
|
|
18449
18451
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
18450
|
-
|
|
18452
|
+
chunkQJFJ5JBF_cjs.SelectedFilesList,
|
|
18451
18453
|
{
|
|
18452
18454
|
renderFileIcon,
|
|
18453
18455
|
files,
|
|
@@ -18456,10 +18458,10 @@ ${summary}`,
|
|
|
18456
18458
|
formatFileSize
|
|
18457
18459
|
}
|
|
18458
18460
|
),
|
|
18459
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
18460
|
-
error && /* @__PURE__ */ jsxRuntime.jsx(
|
|
18461
|
-
] }) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
18462
|
-
|
|
18461
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.RejectedFilesList, { files: refused, onClear: () => setRefused([]) }),
|
|
18462
|
+
error && /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.UploadErrorMessage, { message: error })
|
|
18463
|
+
] }) : /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.UploadContainer, { className: "w-full p-4 sm:p-6", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
18464
|
+
chunkQJFJ5JBF_cjs.UploadProgress,
|
|
18463
18465
|
{
|
|
18464
18466
|
fileCount: count,
|
|
18465
18467
|
entityLabel: plural2(count),
|
|
@@ -18501,7 +18503,7 @@ function AddFromAccountsButton({
|
|
|
18501
18503
|
className: "gap-2",
|
|
18502
18504
|
"data-testid": dataTestId,
|
|
18503
18505
|
children: [
|
|
18504
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "flex items-center gap-1", children: marks.map((m) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
18506
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "flex items-center gap-1", children: marks.map((m) => /* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.VendorLogo, { vendorKey: m.vendorKey, product: m.product, className: "h-4 w-4" }, m.key)) }),
|
|
18505
18507
|
"Add from accounts"
|
|
18506
18508
|
]
|
|
18507
18509
|
}
|
|
@@ -18531,7 +18533,7 @@ function EmptyWorkspaceUpload({
|
|
|
18531
18533
|
compactLeadingAction: onImportFromEmail && /* @__PURE__ */ jsxRuntime.jsx(AddFromAccountsButton, { onImportFromEmail })
|
|
18532
18534
|
}
|
|
18533
18535
|
),
|
|
18534
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
18536
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkQJFJ5JBF_cjs.PrivacyExplainerModal, {})
|
|
18535
18537
|
] })
|
|
18536
18538
|
}
|
|
18537
18539
|
);
|
|
@@ -18605,59 +18607,59 @@ function ConnectedAgentChatPanel({
|
|
|
18605
18607
|
|
|
18606
18608
|
Object.defineProperty(exports, "BillingSupportProvider", {
|
|
18607
18609
|
enumerable: true,
|
|
18608
|
-
get: function () { return
|
|
18610
|
+
get: function () { return chunkP2YM67Y5_cjs.BillingSupportProvider; }
|
|
18609
18611
|
});
|
|
18610
18612
|
Object.defineProperty(exports, "CAP_REACHED_MESSAGE", {
|
|
18611
18613
|
enumerable: true,
|
|
18612
|
-
get: function () { return
|
|
18614
|
+
get: function () { return chunkP2YM67Y5_cjs.CAP_REACHED_MESSAGE; }
|
|
18613
18615
|
});
|
|
18614
18616
|
Object.defineProperty(exports, "ZERO_BUDGET_MESSAGE", {
|
|
18615
18617
|
enumerable: true,
|
|
18616
|
-
get: function () { return
|
|
18618
|
+
get: function () { return chunkP2YM67Y5_cjs.ZERO_BUDGET_MESSAGE; }
|
|
18617
18619
|
});
|
|
18618
18620
|
Object.defineProperty(exports, "aiUsageResetTimestamp", {
|
|
18619
18621
|
enumerable: true,
|
|
18620
|
-
get: function () { return
|
|
18622
|
+
get: function () { return chunkP2YM67Y5_cjs.aiUsageResetTimestamp; }
|
|
18621
18623
|
});
|
|
18622
18624
|
Object.defineProperty(exports, "formatMoney", {
|
|
18623
18625
|
enumerable: true,
|
|
18624
|
-
get: function () { return
|
|
18626
|
+
get: function () { return chunkP2YM67Y5_cjs.formatMoney; }
|
|
18625
18627
|
});
|
|
18626
18628
|
Object.defineProperty(exports, "formatResetDate", {
|
|
18627
18629
|
enumerable: true,
|
|
18628
|
-
get: function () { return
|
|
18630
|
+
get: function () { return chunkP2YM67Y5_cjs.formatResetDate; }
|
|
18629
18631
|
});
|
|
18630
18632
|
Object.defineProperty(exports, "getQuotaItems", {
|
|
18631
18633
|
enumerable: true,
|
|
18632
|
-
get: function () { return
|
|
18634
|
+
get: function () { return chunkP2YM67Y5_cjs.getQuotaItems; }
|
|
18633
18635
|
});
|
|
18634
18636
|
Object.defineProperty(exports, "isAddonBudgetZero", {
|
|
18635
18637
|
enumerable: true,
|
|
18636
|
-
get: function () { return
|
|
18638
|
+
get: function () { return chunkP2YM67Y5_cjs.isAddonBudgetZero; }
|
|
18637
18639
|
});
|
|
18638
18640
|
Object.defineProperty(exports, "isProProject", {
|
|
18639
18641
|
enumerable: true,
|
|
18640
|
-
get: function () { return
|
|
18642
|
+
get: function () { return chunkP2YM67Y5_cjs.isProProject; }
|
|
18641
18643
|
});
|
|
18642
18644
|
Object.defineProperty(exports, "planBadgeView", {
|
|
18643
18645
|
enumerable: true,
|
|
18644
|
-
get: function () { return
|
|
18646
|
+
get: function () { return chunkP2YM67Y5_cjs.planBadgeView; }
|
|
18645
18647
|
});
|
|
18646
18648
|
Object.defineProperty(exports, "planName", {
|
|
18647
18649
|
enumerable: true,
|
|
18648
|
-
get: function () { return
|
|
18650
|
+
get: function () { return chunkP2YM67Y5_cjs.planName; }
|
|
18649
18651
|
});
|
|
18650
18652
|
Object.defineProperty(exports, "projectGroupBilling", {
|
|
18651
18653
|
enumerable: true,
|
|
18652
|
-
get: function () { return
|
|
18654
|
+
get: function () { return chunkP2YM67Y5_cjs.projectGroupBilling; }
|
|
18653
18655
|
});
|
|
18654
18656
|
Object.defineProperty(exports, "useBillingSupport", {
|
|
18655
18657
|
enumerable: true,
|
|
18656
|
-
get: function () { return
|
|
18658
|
+
get: function () { return chunkP2YM67Y5_cjs.useBillingSupport; }
|
|
18657
18659
|
});
|
|
18658
18660
|
Object.defineProperty(exports, "useRewardBalance", {
|
|
18659
18661
|
enumerable: true,
|
|
18660
|
-
get: function () { return
|
|
18662
|
+
get: function () { return chunkP2YM67Y5_cjs.useRewardBalance; }
|
|
18661
18663
|
});
|
|
18662
18664
|
Object.defineProperty(exports, "ConnectedAssistantDock", {
|
|
18663
18665
|
enumerable: true,
|
|
@@ -18693,43 +18695,43 @@ Object.defineProperty(exports, "useWorkspaceDocs", {
|
|
|
18693
18695
|
});
|
|
18694
18696
|
Object.defineProperty(exports, "ConnectedWorkflowDocumentsField", {
|
|
18695
18697
|
enumerable: true,
|
|
18696
|
-
get: function () { return
|
|
18698
|
+
get: function () { return chunk2BHDRVVL_cjs.ConnectedWorkflowDocumentsField; }
|
|
18697
18699
|
});
|
|
18698
18700
|
Object.defineProperty(exports, "ConnectedWorkflowLauncher", {
|
|
18699
18701
|
enumerable: true,
|
|
18700
|
-
get: function () { return
|
|
18702
|
+
get: function () { return chunk2BHDRVVL_cjs.ConnectedWorkflowLauncher; }
|
|
18701
18703
|
});
|
|
18702
18704
|
Object.defineProperty(exports, "ConnectedWorkflowsTable", {
|
|
18703
18705
|
enumerable: true,
|
|
18704
|
-
get: function () { return
|
|
18706
|
+
get: function () { return chunk2BHDRVVL_cjs.ConnectedWorkflowsTable; }
|
|
18705
18707
|
});
|
|
18706
18708
|
Object.defineProperty(exports, "DEFAULT_CONNECTED_WORKFLOWS_TABLE_LABELS", {
|
|
18707
18709
|
enumerable: true,
|
|
18708
|
-
get: function () { return
|
|
18710
|
+
get: function () { return chunk2BHDRVVL_cjs.DEFAULT_CONNECTED_WORKFLOWS_TABLE_LABELS; }
|
|
18709
18711
|
});
|
|
18710
18712
|
Object.defineProperty(exports, "NativeDocxSupportProvider", {
|
|
18711
18713
|
enumerable: true,
|
|
18712
|
-
get: function () { return
|
|
18714
|
+
get: function () { return chunk2BHDRVVL_cjs.NativeDocxSupportProvider; }
|
|
18713
18715
|
});
|
|
18714
18716
|
Object.defineProperty(exports, "toWorkflowFieldDocument", {
|
|
18715
18717
|
enumerable: true,
|
|
18716
|
-
get: function () { return
|
|
18718
|
+
get: function () { return chunk2BHDRVVL_cjs.toWorkflowFieldDocument; }
|
|
18717
18719
|
});
|
|
18718
18720
|
Object.defineProperty(exports, "useConnectedAgentOptions", {
|
|
18719
18721
|
enumerable: true,
|
|
18720
|
-
get: function () { return
|
|
18722
|
+
get: function () { return chunk2BHDRVVL_cjs.useConnectedAgentOptions; }
|
|
18721
18723
|
});
|
|
18722
18724
|
Object.defineProperty(exports, "useConnectedWorkflowScopeSource", {
|
|
18723
18725
|
enumerable: true,
|
|
18724
|
-
get: function () { return
|
|
18726
|
+
get: function () { return chunk2BHDRVVL_cjs.useConnectedWorkflowScopeSource; }
|
|
18725
18727
|
});
|
|
18726
18728
|
Object.defineProperty(exports, "useConnectedWorkspaceRole", {
|
|
18727
18729
|
enumerable: true,
|
|
18728
|
-
get: function () { return
|
|
18730
|
+
get: function () { return chunk2BHDRVVL_cjs.useConnectedWorkspaceRole; }
|
|
18729
18731
|
});
|
|
18730
18732
|
Object.defineProperty(exports, "useNativeDocxSupport", {
|
|
18731
18733
|
enumerable: true,
|
|
18732
|
-
get: function () { return
|
|
18734
|
+
get: function () { return chunk2BHDRVVL_cjs.useNativeDocxSupport; }
|
|
18733
18735
|
});
|
|
18734
18736
|
Object.defineProperty(exports, "DocumentViewerSupportProvider", {
|
|
18735
18737
|
enumerable: true,
|