@arbidocs/blocks 0.4.5 → 0.4.6

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.
Files changed (131) hide show
  1. package/README.md +46 -6
  2. package/dist/agents/index.cjs +163 -162
  3. package/dist/agents/index.js +6 -5
  4. package/dist/chat/ChatMessageContent.d.ts +16 -0
  5. package/dist/chat/ChatPage.d.ts +11 -8
  6. package/dist/chat/ChatThreads.d.ts +3 -1
  7. package/dist/chat/CitationMark.d.ts +18 -0
  8. package/dist/chat/chat-page-types.d.ts +75 -1
  9. package/dist/chat/index.cjs +126 -117
  10. package/dist/chat/index.d.ts +3 -1
  11. package/dist/chat/index.js +5 -4
  12. package/dist/{chunk-3MIQASHO.cjs → chunk-23XL6SVZ.cjs} +39 -19
  13. package/dist/chunk-23XL6SVZ.cjs.map +1 -0
  14. package/dist/{chunk-ULWRNGGE.cjs → chunk-2ZTONLT5.cjs} +4 -25
  15. package/dist/chunk-2ZTONLT5.cjs.map +1 -0
  16. package/dist/{chunk-O637DUKS.cjs → chunk-56BUD74K.cjs} +28 -28
  17. package/dist/{chunk-O637DUKS.cjs.map → chunk-56BUD74K.cjs.map} +1 -1
  18. package/dist/{chunk-YLOKCIQJ.cjs → chunk-5SLLMK5K.cjs} +421 -115
  19. package/dist/chunk-5SLLMK5K.cjs.map +1 -0
  20. package/dist/{chunk-SS23F63U.cjs → chunk-5ZBP7TCD.cjs} +55 -3
  21. package/dist/chunk-5ZBP7TCD.cjs.map +1 -0
  22. package/dist/{chunk-3PZPRAAR.cjs → chunk-67HGXV4I.cjs} +14 -14
  23. package/dist/{chunk-3PZPRAAR.cjs.map → chunk-67HGXV4I.cjs.map} +1 -1
  24. package/dist/{chunk-RCP6THBS.js → chunk-7OCFHEE6.js} +3 -3
  25. package/dist/{chunk-RCP6THBS.js.map → chunk-7OCFHEE6.js.map} +1 -1
  26. package/dist/{chunk-TX2ZICS7.js → chunk-CPMNAJLF.js} +4 -24
  27. package/dist/chunk-CPMNAJLF.js.map +1 -0
  28. package/dist/{chunk-5XTZFH65.js → chunk-CVFBSUXL.js} +5 -5
  29. package/dist/{chunk-5XTZFH65.js.map → chunk-CVFBSUXL.js.map} +1 -1
  30. package/dist/chunk-DCDVWPMB.cjs +29 -0
  31. package/dist/chunk-DCDVWPMB.cjs.map +1 -0
  32. package/dist/{chunk-TI4UTYRL.js → chunk-EY2RJW27.js} +258 -10
  33. package/dist/chunk-EY2RJW27.js.map +1 -0
  34. package/dist/{chunk-7YADKWZT.js → chunk-G2E3O3HI.js} +3 -3
  35. package/dist/{chunk-7YADKWZT.js.map → chunk-G2E3O3HI.js.map} +1 -1
  36. package/dist/{chunk-6YHWXMPQ.js → chunk-G2T3KTZ3.js} +419 -115
  37. package/dist/chunk-G2T3KTZ3.js.map +1 -0
  38. package/dist/{chunk-2NNTQLBY.js → chunk-IAKUTBPX.js} +4 -4
  39. package/dist/{chunk-2NNTQLBY.js.map → chunk-IAKUTBPX.js.map} +1 -1
  40. package/dist/{chunk-IZHWP6WQ.cjs → chunk-JG4TFS3Z.cjs} +6 -6
  41. package/dist/{chunk-IZHWP6WQ.cjs.map → chunk-JG4TFS3Z.cjs.map} +1 -1
  42. package/dist/chunk-JLOYWXRB.js +1156 -0
  43. package/dist/chunk-JLOYWXRB.js.map +1 -0
  44. package/dist/{chunk-WJZBJUPX.js → chunk-KXMDOTGW.js} +56 -4
  45. package/dist/chunk-KXMDOTGW.js.map +1 -0
  46. package/dist/{chunk-2VBJ763Y.js → chunk-KZJAG7T3.js} +37 -7
  47. package/dist/chunk-KZJAG7T3.js.map +1 -0
  48. package/dist/{chunk-RIL7G7AS.cjs → chunk-MGUHR3JI.cjs} +4 -4
  49. package/dist/{chunk-RIL7G7AS.cjs.map → chunk-MGUHR3JI.cjs.map} +1 -1
  50. package/dist/{chunk-NPKGUQU5.js → chunk-NJL4LIXX.js} +4 -4
  51. package/dist/{chunk-NPKGUQU5.js.map → chunk-NJL4LIXX.js.map} +1 -1
  52. package/dist/{chunk-DN3NFNIA.cjs → chunk-QMDLPO3M.cjs} +266 -10
  53. package/dist/chunk-QMDLPO3M.cjs.map +1 -0
  54. package/dist/chunk-TJMKFY5P.js +27 -0
  55. package/dist/chunk-TJMKFY5P.js.map +1 -0
  56. package/dist/{chunk-3PJCET7H.js → chunk-UHVNYKV2.js} +38 -18
  57. package/dist/chunk-UHVNYKV2.js.map +1 -0
  58. package/dist/{chunk-6CHMNKXC.cjs → chunk-UTYQPVIW.cjs} +11 -11
  59. package/dist/chunk-UTYQPVIW.cjs.map +1 -0
  60. package/dist/{chunk-KHX2BX3S.cjs → chunk-VGOFFCMT.cjs} +37 -5
  61. package/dist/chunk-VGOFFCMT.cjs.map +1 -0
  62. package/dist/{chunk-67MKU5U7.js → chunk-YMHGF6R5.js} +8 -8
  63. package/dist/chunk-YMHGF6R5.js.map +1 -0
  64. package/dist/chunk-YVIOCITQ.cjs +1186 -0
  65. package/dist/chunk-YVIOCITQ.cjs.map +1 -0
  66. package/dist/{chunk-MVNCQDDE.cjs → chunk-ZVPTFTGV.cjs} +4 -4
  67. package/dist/{chunk-MVNCQDDE.cjs.map → chunk-ZVPTFTGV.cjs.map} +1 -1
  68. package/dist/collaboration/index.cjs +38 -37
  69. package/dist/collaboration/index.js +3 -2
  70. package/dist/connect/index.cjs +358 -19
  71. package/dist/connect/index.cjs.map +1 -1
  72. package/dist/connect/index.d.ts +1 -0
  73. package/dist/connect/index.js +341 -9
  74. package/dist/connect/index.js.map +1 -1
  75. package/dist/connection/ConnectedSettings.d.ts +64 -0
  76. package/dist/facts/index.cjs +2 -2
  77. package/dist/facts/index.js +2 -2
  78. package/dist/files/index.cjs +15 -14
  79. package/dist/files/index.cjs.map +1 -1
  80. package/dist/files/index.js +5 -4
  81. package/dist/files/index.js.map +1 -1
  82. package/dist/home/index.cjs +19 -19
  83. package/dist/home/index.js +4 -4
  84. package/dist/index.cjs +526 -477
  85. package/dist/index.cjs.map +1 -1
  86. package/dist/index.js +17 -16
  87. package/dist/index.js.map +1 -1
  88. package/dist/lib/bottom-inset.d.ts +16 -0
  89. package/dist/lib/useElementSize.d.ts +13 -0
  90. package/dist/lib/useFillHeight.d.ts +10 -0
  91. package/dist/settings/account-views.d.ts +55 -0
  92. package/dist/settings/index.cjs +179 -1148
  93. package/dist/settings/index.cjs.map +1 -1
  94. package/dist/settings/index.d.ts +1 -0
  95. package/dist/settings/index.js +10 -1073
  96. package/dist/settings/index.js.map +1 -1
  97. package/dist/shell/InstallPrompt.d.ts +28 -0
  98. package/dist/shell/MobileBars.d.ts +1 -1
  99. package/dist/shell/index.cjs +85 -45
  100. package/dist/shell/index.d.ts +4 -0
  101. package/dist/shell/index.js +3 -3
  102. package/dist/shell/install-instructions.d.ts +19 -0
  103. package/dist/shell/types.d.ts +6 -0
  104. package/dist/shell/use-install-prompt.d.ts +49 -0
  105. package/dist/site/index.cjs +62 -62
  106. package/dist/site/index.js +2 -2
  107. package/dist/studio/index.cjs +78 -77
  108. package/dist/studio/index.cjs.map +1 -1
  109. package/dist/studio/index.js +8 -7
  110. package/dist/studio/index.js.map +1 -1
  111. package/dist/theme/ThemeEditor.d.ts +4 -2
  112. package/dist/workspaces/index.cjs +4 -3
  113. package/dist/workspaces/index.cjs.map +1 -1
  114. package/dist/workspaces/index.js +3 -2
  115. package/dist/workspaces/index.js.map +1 -1
  116. package/package.json +8 -4
  117. package/src/blocks.css +30 -0
  118. package/dist/chunk-2VBJ763Y.js.map +0 -1
  119. package/dist/chunk-3MIQASHO.cjs.map +0 -1
  120. package/dist/chunk-3PJCET7H.js.map +0 -1
  121. package/dist/chunk-67MKU5U7.js.map +0 -1
  122. package/dist/chunk-6CHMNKXC.cjs.map +0 -1
  123. package/dist/chunk-6YHWXMPQ.js.map +0 -1
  124. package/dist/chunk-DN3NFNIA.cjs.map +0 -1
  125. package/dist/chunk-KHX2BX3S.cjs.map +0 -1
  126. package/dist/chunk-SS23F63U.cjs.map +0 -1
  127. package/dist/chunk-TI4UTYRL.js.map +0 -1
  128. package/dist/chunk-TX2ZICS7.js.map +0 -1
  129. package/dist/chunk-ULWRNGGE.cjs.map +0 -1
  130. package/dist/chunk-WJZBJUPX.js.map +0 -1
  131. package/dist/chunk-YLOKCIQJ.cjs.map +0 -1
@@ -1,153 +1,154 @@
1
1
  "use client";
2
2
  'use strict';
3
3
 
4
- var chunkIZHWP6WQ_cjs = require('../chunk-IZHWP6WQ.cjs');
4
+ var chunkJG4TFS3Z_cjs = require('../chunk-JG4TFS3Z.cjs');
5
5
  require('../chunk-7G2LJMUG.cjs');
6
6
  var chunkVLCY46K6_cjs = require('../chunk-VLCY46K6.cjs');
7
- require('../chunk-ULWRNGGE.cjs');
7
+ require('../chunk-2ZTONLT5.cjs');
8
+ require('../chunk-DCDVWPMB.cjs');
8
9
  require('../chunk-MHVNT4J3.cjs');
9
10
 
10
11
 
11
12
 
12
13
  Object.defineProperty(exports, "ActionMenu", {
13
14
  enumerable: true,
14
- get: function () { return chunkIZHWP6WQ_cjs.ActionMenu; }
15
+ get: function () { return chunkJG4TFS3Z_cjs.ActionMenu; }
15
16
  });
16
17
  Object.defineProperty(exports, "AddContactsForm", {
17
18
  enumerable: true,
18
- get: function () { return chunkIZHWP6WQ_cjs.AddContactsForm; }
19
+ get: function () { return chunkJG4TFS3Z_cjs.AddContactsForm; }
19
20
  });
20
21
  Object.defineProperty(exports, "AddContactsResults", {
21
22
  enumerable: true,
22
- get: function () { return chunkIZHWP6WQ_cjs.AddContactsResults; }
23
+ get: function () { return chunkJG4TFS3Z_cjs.AddContactsResults; }
23
24
  });
24
25
  Object.defineProperty(exports, "DEFAULT_ADD_CONTACTS_LABELS", {
25
26
  enumerable: true,
26
- get: function () { return chunkIZHWP6WQ_cjs.DEFAULT_ADD_CONTACTS_LABELS; }
27
+ get: function () { return chunkJG4TFS3Z_cjs.DEFAULT_ADD_CONTACTS_LABELS; }
27
28
  });
28
29
  Object.defineProperty(exports, "DEFAULT_CONTACT_OUTCOME_LABELS", {
29
30
  enumerable: true,
30
- get: function () { return chunkIZHWP6WQ_cjs.DEFAULT_CONTACT_OUTCOME_LABELS; }
31
+ get: function () { return chunkJG4TFS3Z_cjs.DEFAULT_CONTACT_OUTCOME_LABELS; }
31
32
  });
32
33
  Object.defineProperty(exports, "DEFAULT_DM_ACCESS_REQUEST_BANNER_LABELS", {
33
34
  enumerable: true,
34
- get: function () { return chunkIZHWP6WQ_cjs.DEFAULT_DM_ACCESS_REQUEST_BANNER_LABELS; }
35
+ get: function () { return chunkJG4TFS3Z_cjs.DEFAULT_DM_ACCESS_REQUEST_BANNER_LABELS; }
35
36
  });
36
37
  Object.defineProperty(exports, "DEFAULT_DM_GRANT_ACCESS_DIALOG_LABELS", {
37
38
  enumerable: true,
38
- get: function () { return chunkIZHWP6WQ_cjs.DEFAULT_DM_GRANT_ACCESS_DIALOG_LABELS; }
39
+ get: function () { return chunkJG4TFS3Z_cjs.DEFAULT_DM_GRANT_ACCESS_DIALOG_LABELS; }
39
40
  });
40
41
  Object.defineProperty(exports, "DEFAULT_DM_INVITE_CHIP_LABELS", {
41
42
  enumerable: true,
42
- get: function () { return chunkIZHWP6WQ_cjs.DEFAULT_DM_INVITE_CHIP_LABELS; }
43
+ get: function () { return chunkJG4TFS3Z_cjs.DEFAULT_DM_INVITE_CHIP_LABELS; }
43
44
  });
44
45
  Object.defineProperty(exports, "DEFAULT_DM_THREAD_FRAME_LABELS", {
45
46
  enumerable: true,
46
- get: function () { return chunkIZHWP6WQ_cjs.DEFAULT_DM_THREAD_FRAME_LABELS; }
47
+ get: function () { return chunkJG4TFS3Z_cjs.DEFAULT_DM_THREAD_FRAME_LABELS; }
47
48
  });
48
49
  Object.defineProperty(exports, "DEFAULT_MAIL_FOLDER_TREE_LABELS", {
49
50
  enumerable: true,
50
- get: function () { return chunkIZHWP6WQ_cjs.DEFAULT_MAIL_FOLDER_TREE_LABELS; }
51
+ get: function () { return chunkJG4TFS3Z_cjs.DEFAULT_MAIL_FOLDER_TREE_LABELS; }
51
52
  });
52
53
  Object.defineProperty(exports, "DEFAULT_RECIPIENT_PICKER_LABELS", {
53
54
  enumerable: true,
54
- get: function () { return chunkIZHWP6WQ_cjs.DEFAULT_RECIPIENT_PICKER_LABELS; }
55
+ get: function () { return chunkJG4TFS3Z_cjs.DEFAULT_RECIPIENT_PICKER_LABELS; }
55
56
  });
56
57
  Object.defineProperty(exports, "DmAccessRequestBanner", {
57
58
  enumerable: true,
58
- get: function () { return chunkIZHWP6WQ_cjs.DmAccessRequestBanner; }
59
+ get: function () { return chunkJG4TFS3Z_cjs.DmAccessRequestBanner; }
59
60
  });
60
61
  Object.defineProperty(exports, "DmGrantAccessDialogView", {
61
62
  enumerable: true,
62
- get: function () { return chunkIZHWP6WQ_cjs.DmGrantAccessDialogView; }
63
+ get: function () { return chunkJG4TFS3Z_cjs.DmGrantAccessDialogView; }
63
64
  });
64
65
  Object.defineProperty(exports, "DmInviteAvatar", {
65
66
  enumerable: true,
66
- get: function () { return chunkIZHWP6WQ_cjs.DmInviteAvatar; }
67
+ get: function () { return chunkJG4TFS3Z_cjs.DmInviteAvatar; }
67
68
  });
68
69
  Object.defineProperty(exports, "DmInviteChip", {
69
70
  enumerable: true,
70
- get: function () { return chunkIZHWP6WQ_cjs.DmInviteChip; }
71
+ get: function () { return chunkJG4TFS3Z_cjs.DmInviteChip; }
71
72
  });
72
73
  Object.defineProperty(exports, "DmNewTabIcon", {
73
74
  enumerable: true,
74
- get: function () { return chunkIZHWP6WQ_cjs.DmNewTabIcon; }
75
+ get: function () { return chunkJG4TFS3Z_cjs.DmNewTabIcon; }
75
76
  });
76
77
  Object.defineProperty(exports, "DmThreadFrame", {
77
78
  enumerable: true,
78
- get: function () { return chunkIZHWP6WQ_cjs.DmThreadFrame; }
79
+ get: function () { return chunkJG4TFS3Z_cjs.DmThreadFrame; }
79
80
  });
80
81
  Object.defineProperty(exports, "DmThreadHeader", {
81
82
  enumerable: true,
82
- get: function () { return chunkIZHWP6WQ_cjs.DmThreadHeader; }
83
+ get: function () { return chunkJG4TFS3Z_cjs.DmThreadHeader; }
83
84
  });
84
85
  Object.defineProperty(exports, "MAX_INVITE_EMAILS", {
85
86
  enumerable: true,
86
- get: function () { return chunkIZHWP6WQ_cjs.MAX_INVITE_EMAILS; }
87
+ get: function () { return chunkJG4TFS3Z_cjs.MAX_INVITE_EMAILS; }
87
88
  });
88
89
  Object.defineProperty(exports, "MailFolderTree", {
89
90
  enumerable: true,
90
- get: function () { return chunkIZHWP6WQ_cjs.MailFolderTree; }
91
+ get: function () { return chunkJG4TFS3Z_cjs.MailFolderTree; }
91
92
  });
92
93
  Object.defineProperty(exports, "MemberBulkActions", {
93
94
  enumerable: true,
94
- get: function () { return chunkIZHWP6WQ_cjs.MemberBulkActions; }
95
+ get: function () { return chunkJG4TFS3Z_cjs.MemberBulkActions; }
95
96
  });
96
97
  Object.defineProperty(exports, "MemberListLoading", {
97
98
  enumerable: true,
98
- get: function () { return chunkIZHWP6WQ_cjs.MemberListLoading; }
99
+ get: function () { return chunkJG4TFS3Z_cjs.MemberListLoading; }
99
100
  });
100
101
  Object.defineProperty(exports, "MemberMutedText", {
101
102
  enumerable: true,
102
- get: function () { return chunkIZHWP6WQ_cjs.MemberMutedText; }
103
+ get: function () { return chunkJG4TFS3Z_cjs.MemberMutedText; }
103
104
  });
104
105
  Object.defineProperty(exports, "MemberNameCell", {
105
106
  enumerable: true,
106
- get: function () { return chunkIZHWP6WQ_cjs.MemberNameCell; }
107
+ get: function () { return chunkJG4TFS3Z_cjs.MemberNameCell; }
107
108
  });
108
109
  Object.defineProperty(exports, "MemberRoleCell", {
109
110
  enumerable: true,
110
- get: function () { return chunkIZHWP6WQ_cjs.MemberRoleCell; }
111
+ get: function () { return chunkJG4TFS3Z_cjs.MemberRoleCell; }
111
112
  });
112
113
  Object.defineProperty(exports, "RecipientPicker", {
113
114
  enumerable: true,
114
- get: function () { return chunkIZHWP6WQ_cjs.RecipientPicker; }
115
+ get: function () { return chunkJG4TFS3Z_cjs.RecipientPicker; }
115
116
  });
116
117
  Object.defineProperty(exports, "RoleSelect", {
117
118
  enumerable: true,
118
- get: function () { return chunkIZHWP6WQ_cjs.RoleSelect; }
119
+ get: function () { return chunkJG4TFS3Z_cjs.RoleSelect; }
119
120
  });
120
121
  Object.defineProperty(exports, "WorkspaceDeleteButton", {
121
122
  enumerable: true,
122
- get: function () { return chunkIZHWP6WQ_cjs.WorkspaceDeleteButton; }
123
+ get: function () { return chunkJG4TFS3Z_cjs.WorkspaceDeleteButton; }
123
124
  });
124
125
  Object.defineProperty(exports, "buildMailFolderTree", {
125
126
  enumerable: true,
126
- get: function () { return chunkIZHWP6WQ_cjs.buildMailFolderTree; }
127
+ get: function () { return chunkJG4TFS3Z_cjs.buildMailFolderTree; }
127
128
  });
128
129
  Object.defineProperty(exports, "descendantFolderIds", {
129
130
  enumerable: true,
130
- get: function () { return chunkIZHWP6WQ_cjs.descendantFolderIds; }
131
+ get: function () { return chunkJG4TFS3Z_cjs.descendantFolderIds; }
131
132
  });
132
133
  Object.defineProperty(exports, "isInboxFolder", {
133
134
  enumerable: true,
134
- get: function () { return chunkIZHWP6WQ_cjs.isInboxFolder; }
135
+ get: function () { return chunkJG4TFS3Z_cjs.isInboxFolder; }
135
136
  });
136
137
  Object.defineProperty(exports, "parseEmails", {
137
138
  enumerable: true,
138
- get: function () { return chunkIZHWP6WQ_cjs.parseEmails; }
139
+ get: function () { return chunkJG4TFS3Z_cjs.parseEmails; }
139
140
  });
140
141
  Object.defineProperty(exports, "toAddContactsRow", {
141
142
  enumerable: true,
142
- get: function () { return chunkIZHWP6WQ_cjs.toAddContactsRow; }
143
+ get: function () { return chunkJG4TFS3Z_cjs.toAddContactsRow; }
143
144
  });
144
145
  Object.defineProperty(exports, "toAddContactsRows", {
145
146
  enumerable: true,
146
- get: function () { return chunkIZHWP6WQ_cjs.toAddContactsRows; }
147
+ get: function () { return chunkJG4TFS3Z_cjs.toAddContactsRows; }
147
148
  });
148
149
  Object.defineProperty(exports, "toggleMailFolder", {
149
150
  enumerable: true,
150
- get: function () { return chunkIZHWP6WQ_cjs.toggleMailFolder; }
151
+ get: function () { return chunkJG4TFS3Z_cjs.toggleMailFolder; }
151
152
  });
152
153
  Object.defineProperty(exports, "DEFAULT_SHARE_CONTROL_LABELS", {
153
154
  enumerable: true,
@@ -1,8 +1,9 @@
1
1
  "use client";
2
- export { ActionMenu, AddContactsForm, AddContactsResults, DEFAULT_ADD_CONTACTS_LABELS, DEFAULT_CONTACT_OUTCOME_LABELS, DEFAULT_DM_ACCESS_REQUEST_BANNER_LABELS, DEFAULT_DM_GRANT_ACCESS_DIALOG_LABELS, DEFAULT_DM_INVITE_CHIP_LABELS, DEFAULT_DM_THREAD_FRAME_LABELS, DEFAULT_MAIL_FOLDER_TREE_LABELS, DEFAULT_RECIPIENT_PICKER_LABELS, DmAccessRequestBanner, DmGrantAccessDialogView, DmInviteAvatar, DmInviteChip, DmNewTabIcon, DmThreadFrame, DmThreadHeader, MAX_INVITE_EMAILS, MailFolderTree, MemberBulkActions, MemberListLoading, MemberMutedText, MemberNameCell, MemberRoleCell, RecipientPicker, RoleSelect, WorkspaceDeleteButton, buildMailFolderTree, descendantFolderIds, isInboxFolder, parseEmails, toAddContactsRow, toAddContactsRows, toggleMailFolder } from '../chunk-7YADKWZT.js';
2
+ export { ActionMenu, AddContactsForm, AddContactsResults, DEFAULT_ADD_CONTACTS_LABELS, DEFAULT_CONTACT_OUTCOME_LABELS, DEFAULT_DM_ACCESS_REQUEST_BANNER_LABELS, DEFAULT_DM_GRANT_ACCESS_DIALOG_LABELS, DEFAULT_DM_INVITE_CHIP_LABELS, DEFAULT_DM_THREAD_FRAME_LABELS, DEFAULT_MAIL_FOLDER_TREE_LABELS, DEFAULT_RECIPIENT_PICKER_LABELS, DmAccessRequestBanner, DmGrantAccessDialogView, DmInviteAvatar, DmInviteChip, DmNewTabIcon, DmThreadFrame, DmThreadHeader, MAX_INVITE_EMAILS, MailFolderTree, MemberBulkActions, MemberListLoading, MemberMutedText, MemberNameCell, MemberRoleCell, RecipientPicker, RoleSelect, WorkspaceDeleteButton, buildMailFolderTree, descendantFolderIds, isInboxFolder, parseEmails, toAddContactsRow, toAddContactsRows, toggleMailFolder } from '../chunk-G2E3O3HI.js';
3
3
  import '../chunk-NBV56SGU.js';
4
4
  export { DEFAULT_SHARE_CONTROL_LABELS, ShareControl } from '../chunk-K4BGOPGG.js';
5
- import '../chunk-TX2ZICS7.js';
5
+ import '../chunk-CPMNAJLF.js';
6
+ import '../chunk-TJMKFY5P.js';
6
7
  import '../chunk-7F6CBP3Z.js';
7
8
  //# sourceMappingURL=index.js.map
8
9
  //# sourceMappingURL=index.js.map
@@ -1,18 +1,24 @@
1
1
  "use client";
2
2
  'use strict';
3
3
 
4
- var chunk3MIQASHO_cjs = require('../chunk-3MIQASHO.cjs');
5
- require('../chunk-YLOKCIQJ.cjs');
6
- require('../chunk-KHX2BX3S.cjs');
4
+ var chunkYVIOCITQ_cjs = require('../chunk-YVIOCITQ.cjs');
5
+ var chunk23XL6SVZ_cjs = require('../chunk-23XL6SVZ.cjs');
6
+ require('../chunk-ADOKTJHV.cjs');
7
+ require('../chunk-5SLLMK5K.cjs');
8
+ require('../chunk-VGOFFCMT.cjs');
9
+ require('../chunk-PPCATBOY.cjs');
10
+ var chunkKDG6FER6_cjs = require('../chunk-KDG6FER6.cjs');
11
+ require('../chunk-DCDVWPMB.cjs');
7
12
  require('../chunk-MHVNT4J3.cjs');
8
- require('../chunk-KDG6FER6.cjs');
9
13
  var react = require('react');
10
14
  var reactQuery = require('@tanstack/react-query');
11
15
  var react$1 = require('@arbidocs/react');
12
16
  var jsxRuntime = require('react/jsx-runtime');
17
+ var lucideReact = require('lucide-react');
18
+ var ui = require('@arbidocs/react/ui');
13
19
 
14
20
  function ConnectionBoundWebSocket({ children }) {
15
- const { status } = chunk3MIQASHO_cjs.useConnection();
21
+ const { status } = chunk23XL6SVZ_cjs.useConnection();
16
22
  return /* @__PURE__ */ jsxRuntime.jsx(react$1.ArbiWebSocketProvider, { enabled: status === "authenticated", children });
17
23
  }
18
24
  function ArbiAppProvider({
@@ -25,10 +31,10 @@ function ArbiAppProvider({
25
31
  })
26
32
  );
27
33
  const providerUrl = config.apiUrl || config.demoApiUrl || "https://demo.arbi.local";
28
- return /* @__PURE__ */ jsxRuntime.jsx(reactQuery.QueryClientProvider, { client: queryClient, children: /* @__PURE__ */ jsxRuntime.jsx(react$1.ArbiProvider, { url: providerUrl, children: /* @__PURE__ */ jsxRuntime.jsx(chunk3MIQASHO_cjs.ConnectionProvider, { config, children: /* @__PURE__ */ jsxRuntime.jsx(ConnectionBoundWebSocket, { children }) }) }) });
34
+ return /* @__PURE__ */ jsxRuntime.jsx(reactQuery.QueryClientProvider, { client: queryClient, children: /* @__PURE__ */ jsxRuntime.jsx(react$1.ArbiProvider, { url: providerUrl, children: /* @__PURE__ */ jsxRuntime.jsx(chunk23XL6SVZ_cjs.ConnectionProvider, { config, children: /* @__PURE__ */ jsxRuntime.jsx(ConnectionBoundWebSocket, { children }) }) }) });
29
35
  }
30
36
  function useConnectedShellWorkspaces(options = {}) {
31
- const { workspaceId, setWorkspace } = chunk3MIQASHO_cjs.useConnection();
37
+ const { workspaceId, setWorkspace } = chunk23XL6SVZ_cjs.useConnection();
32
38
  const query = react$1.useWorkspaces();
33
39
  return react$1.useShellWorkspaces({
34
40
  ...options,
@@ -39,56 +45,389 @@ function useConnectedShellWorkspaces(options = {}) {
39
45
  select: (workspace) => setWorkspace(workspace.id)
40
46
  });
41
47
  }
48
+ function errorText(error, fallback) {
49
+ const body = error?.apiError;
50
+ return typeof body?.detail === "string" ? body.detail : fallback;
51
+ }
52
+ var AVATAR_PROBLEMS = {
53
+ "not-image": "Please choose an image file",
54
+ "too-large": "Image must be 5 MB or smaller",
55
+ unreadable: "Couldn't read that image \u2014 try a different file"
56
+ };
57
+ function ConnectedProfileCard({ notify, title = "Profile" }) {
58
+ const { data: profile } = react$1.useProfile();
59
+ const updateProfile = react$1.useUpdateProfile();
60
+ const requestEmailChange = react$1.useRequestEmailChange();
61
+ const confirmEmailChange = react$1.useConfirmEmailChange();
62
+ const { user } = chunk23XL6SVZ_cjs.useConnection();
63
+ const name = react$1.useNameEditor({
64
+ givenName: profile?.givenName,
65
+ familyName: profile?.familyName,
66
+ save: async (next) => {
67
+ try {
68
+ await updateProfile.mutateAsync(next);
69
+ notify?.("Name updated", "success");
70
+ } catch (e) {
71
+ notify?.("Failed to update name", "error");
72
+ throw e;
73
+ }
74
+ }
75
+ });
76
+ const avatar = react$1.useAvatarCrop({
77
+ upload: async (picture) => {
78
+ try {
79
+ await updateProfile.mutateAsync({ picture });
80
+ notify?.("Profile picture updated", "success");
81
+ } catch (e) {
82
+ notify?.("Failed to update picture", "error");
83
+ throw e;
84
+ }
85
+ },
86
+ onProblem: (problem) => notify?.(AVATAR_PROBLEMS[problem], "error")
87
+ });
88
+ const email = react$1.useEmailChange({
89
+ requestCode: async (address) => {
90
+ try {
91
+ await requestEmailChange.mutateAsync(address);
92
+ notify?.("Verification code sent to your new email", "success");
93
+ } catch (e) {
94
+ notify?.(errorText(e, "Failed to send verification code"), "error");
95
+ throw e;
96
+ }
97
+ },
98
+ confirm: async (args) => {
99
+ try {
100
+ await confirmEmailChange.mutateAsync(args);
101
+ notify?.("Email address updated", "success");
102
+ } catch (e) {
103
+ notify?.(errorText(e, "Invalid or expired verification code"), "error");
104
+ throw e;
105
+ }
106
+ }
107
+ });
108
+ const display = profile?.fullName || user?.name || "Unnamed";
109
+ return /* @__PURE__ */ jsxRuntime.jsx(chunkYVIOCITQ_cjs.SettingsSection, { icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.UserCircle, {}), title, children: /* @__PURE__ */ jsxRuntime.jsx(
110
+ chunkYVIOCITQ_cjs.ProfileCard,
111
+ {
112
+ avatar: /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
113
+ /* @__PURE__ */ jsxRuntime.jsx(
114
+ chunkYVIOCITQ_cjs.AvatarPicker,
115
+ {
116
+ pictureUrl: profile?.picture ?? user?.picture,
117
+ initials: chunkKDG6FER6_cjs.initials(display),
118
+ fallbackClassName: "bg-primary text-primary-foreground",
119
+ isUploading: avatar.isUploading,
120
+ onFileChosen: avatar.onFileChosen
121
+ }
122
+ ),
123
+ /* @__PURE__ */ jsxRuntime.jsx(
124
+ react$1.ImageCropModal,
125
+ {
126
+ open: avatar.pendingImage !== null,
127
+ image: avatar.pendingImage,
128
+ title: "Crop your photo",
129
+ aspect: 1,
130
+ cropShape: "round",
131
+ output: { maxSize: 128, mimeType: "image/jpeg", quality: 0.85 },
132
+ onComplete: avatar.onCropComplete,
133
+ onCancel: avatar.onCropCancel
134
+ }
135
+ )
136
+ ] }),
137
+ name: { ...name, display, isSaving: name.isSaving },
138
+ email: profile?.email ?? user?.email ?? "",
139
+ isSso: profile?.isSso ?? false,
140
+ onStartEmailChange: email.onStart,
141
+ emailChange: email.isOpen ? email : void 0
142
+ }
143
+ ) });
144
+ }
145
+ function defaultUnmetPasswordRequirement(password) {
146
+ if (password.length < 8) return "Minimum 8 characters";
147
+ if (!/[A-Z!@#$%^&*()_+\-=[\]{};':"\\|,.<>/?]/.test(password)) {
148
+ return "At least one uppercase letter or special character";
149
+ }
150
+ if (!/[0-9]/.test(password)) return "At least one number";
151
+ return null;
152
+ }
153
+ function ConnectedSecuritySection({
154
+ notify,
155
+ getUnmetRequirement = defaultUnmetPasswordRequirement,
156
+ renderRecoveryKey,
157
+ children
158
+ }) {
159
+ const [open, setOpen] = react.useState(false);
160
+ const change = react$1.usePasswordChange();
161
+ const { data: workspaces } = react$1.useWorkspaces({ enabled: open });
162
+ const workspaceCount = (workspaces ?? []).filter((w) => w.is_member).length;
163
+ const form = react$1.usePasswordChangeForm({
164
+ getUnmetRequirement,
165
+ submit: async (vars) => {
166
+ const result = await change.mutateAsync(vars);
167
+ notify?.("Password changed successfully", "success");
168
+ return result;
169
+ },
170
+ onClose: () => setOpen(false)
171
+ });
172
+ return /* @__PURE__ */ jsxRuntime.jsxs(chunkYVIOCITQ_cjs.SettingsSection, { icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.KeyRound, {}), title: "Security", children: [
173
+ /* @__PURE__ */ jsxRuntime.jsxs(chunkYVIOCITQ_cjs.SettingsCard, { padding: "sm", children: [
174
+ /* @__PURE__ */ jsxRuntime.jsx(
175
+ chunkYVIOCITQ_cjs.SettingsActionRow,
176
+ {
177
+ title: "Change password",
178
+ description: "Used to sign in and to encrypt your data. Changing it re-encrypts everything in your account.",
179
+ onClick: () => setOpen(true),
180
+ testId: "change-password-button"
181
+ }
182
+ ),
183
+ children
184
+ ] }),
185
+ /* @__PURE__ */ jsxRuntime.jsx(
186
+ chunkYVIOCITQ_cjs.PasswordChangeDialog,
187
+ {
188
+ open,
189
+ onClose: form.onCancel,
190
+ recoveryMode: false,
191
+ currentPassword: form.currentPassword,
192
+ onCurrentPasswordChange: form.onCurrentPasswordChange,
193
+ newPassword: form.newPassword,
194
+ onNewPasswordChange: form.onNewPasswordChange,
195
+ confirmPassword: form.confirmPassword,
196
+ onConfirmPasswordChange: form.onConfirmPasswordChange,
197
+ getUnmetRequirement,
198
+ workspaceCount,
199
+ error: form.error,
200
+ isProcessing: form.isProcessing,
201
+ isSubmitDisabled: form.isSubmitDisabled,
202
+ onSubmit: form.onSubmit,
203
+ success: form.result ? renderRecoveryKey?.(form.result) ?? /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, {}) : null,
204
+ onDone: form.onDone
205
+ }
206
+ )
207
+ ] });
208
+ }
209
+ function ConnectedNotificationPreferences({
210
+ categories = chunkYVIOCITQ_cjs.EMAIL_NOTIFICATION_CATEGORIES,
211
+ title = "Notifications"
212
+ }) {
213
+ const keys = react.useMemo(
214
+ () => categories === chunkYVIOCITQ_cjs.EMAIL_NOTIFICATION_CATEGORIES ? chunkYVIOCITQ_cjs.EMAIL_NOTIFICATION_KEYS : categories.map((c) => c.key),
215
+ [categories]
216
+ );
217
+ const prefs = react$1.useNotificationPreferences(keys);
218
+ return /* @__PURE__ */ jsxRuntime.jsx(chunkYVIOCITQ_cjs.SettingsSection, { title, children: /* @__PURE__ */ jsxRuntime.jsx(chunkYVIOCITQ_cjs.SettingsCard, { className: "space-y-0", children: /* @__PURE__ */ jsxRuntime.jsx(
219
+ chunkYVIOCITQ_cjs.NotificationCategoryList,
220
+ {
221
+ masterId: "emailNotifications",
222
+ masterTitle: "Email Notifications",
223
+ masterDescription: "Email me about activity when I\u2019m away",
224
+ masterChecked: prefs.masterChecked,
225
+ onMasterChange: prefs.setAll,
226
+ categories: chunkYVIOCITQ_cjs.toNotificationCategories(prefs.checked, categories),
227
+ onCategoryChange: prefs.setCategory
228
+ }
229
+ ) }) });
230
+ }
231
+ function ConnectedSessionsRow({
232
+ notify,
233
+ confirm,
234
+ renderSessionIcon
235
+ }) {
236
+ const [open, setOpen] = react.useState(false);
237
+ const sessions = react$1.useSessions({ enabled: open });
238
+ const currentSessionId = react$1.useCurrentSessionId();
239
+ const terminate = react$1.useTerminateSession();
240
+ const views = chunkYVIOCITQ_cjs.toActiveSessionViews(sessions.data ?? [], {
241
+ currentSessionId,
242
+ terminatingId: terminate.isPending ? terminate.variables : null,
243
+ renderIcon: renderSessionIcon
244
+ });
245
+ return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
246
+ /* @__PURE__ */ jsxRuntime.jsx(
247
+ chunkYVIOCITQ_cjs.SettingsRow,
248
+ {
249
+ label: "Active sessions",
250
+ description: "Devices and agents currently signed in to your account.",
251
+ children: /* @__PURE__ */ jsxRuntime.jsxs(
252
+ ui.Button,
253
+ {
254
+ type: "button",
255
+ variant: "outline",
256
+ size: "sm",
257
+ onClick: () => setOpen(true),
258
+ className: "flex items-center gap-2",
259
+ "data-testid": "active-sessions-button",
260
+ children: [
261
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Radio, { className: "h-4 w-4" }),
262
+ "Manage"
263
+ ]
264
+ }
265
+ )
266
+ }
267
+ ),
268
+ /* @__PURE__ */ jsxRuntime.jsx(
269
+ chunkYVIOCITQ_cjs.ActiveSessionsDialog,
270
+ {
271
+ open,
272
+ onOpenChange: setOpen,
273
+ isLoading: sessions.isLoading,
274
+ sessions: views,
275
+ onTerminate: (id) => {
276
+ void (async () => {
277
+ const view = views.find((v) => v.id === id);
278
+ const label = view?.detail.split(" \xB7 ")[0];
279
+ const ok = await confirm?.(
280
+ `End the session on ${label}? It will be signed out immediately.`
281
+ ) ?? true;
282
+ if (!ok) return;
283
+ try {
284
+ await terminate.mutateAsync(id);
285
+ } catch {
286
+ notify?.("Failed to end session. Please try again.", "error");
287
+ }
288
+ })();
289
+ }
290
+ }
291
+ )
292
+ ] });
293
+ }
294
+ function ConnectedLogoutDialog({
295
+ open,
296
+ onClose,
297
+ isOnline = true,
298
+ renderSessionIcon
299
+ }) {
300
+ const { logout } = chunk23XL6SVZ_cjs.useConnection();
301
+ const sessions = react$1.useSessions({ enabled: open });
302
+ const logoutAll = react$1.useLogoutAllSessions();
303
+ return /* @__PURE__ */ jsxRuntime.jsx(
304
+ chunkYVIOCITQ_cjs.LogoutDialog,
305
+ {
306
+ open,
307
+ onClose,
308
+ onLogoutThis: () => {
309
+ onClose();
310
+ logout();
311
+ },
312
+ onLogoutAll: () => {
313
+ onClose();
314
+ void logoutAll.mutateAsync().finally(logout);
315
+ },
316
+ canLogoutAll: true,
317
+ isOnline,
318
+ sessions: chunkYVIOCITQ_cjs.toLogoutSessionViews(sessions.data ?? []),
319
+ renderSessionIcon
320
+ }
321
+ );
322
+ }
323
+ function ConnectedDangerZone({ notify, renderSubscriptionLink }) {
324
+ const [zoneOpen, setZoneOpen] = react.useState(false);
325
+ const [dialogOpen, setDialogOpen] = react.useState(false);
326
+ const { user, logout } = chunk23XL6SVZ_cjs.useConnection();
327
+ const remove = react$1.useDeleteAccount();
328
+ const flow = react$1.useDeleteAccountFlow({
329
+ userEmail: user?.email ?? "",
330
+ remove: () => remove.mutateAsync(),
331
+ onClose: () => setDialogOpen(false),
332
+ onDeleted: logout,
333
+ onError: () => notify?.("Failed to delete account. Please try again.", "error")
334
+ });
335
+ return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
336
+ /* @__PURE__ */ jsxRuntime.jsx(
337
+ chunkYVIOCITQ_cjs.SettingsDangerZone,
338
+ {
339
+ isOpen: zoneOpen,
340
+ onToggle: () => setZoneOpen((o) => !o),
341
+ title: "Delete your account",
342
+ description: "Once deleted, your account will be immediately closed and you will be logged out. This action cannot be undone.",
343
+ action: /* @__PURE__ */ jsxRuntime.jsx(
344
+ ui.Button,
345
+ {
346
+ variant: "destructive",
347
+ size: "sm",
348
+ disabled: !user?.email,
349
+ onClick: () => setDialogOpen(true),
350
+ "data-testid": "delete-account-button",
351
+ children: "Delete Account"
352
+ }
353
+ )
354
+ }
355
+ ),
356
+ /* @__PURE__ */ jsxRuntime.jsx(
357
+ chunkYVIOCITQ_cjs.DeleteAccountDialog,
358
+ {
359
+ open: dialogOpen,
360
+ onClose: flow.onClose,
361
+ step: flow.step,
362
+ blockers: chunkYVIOCITQ_cjs.toDeleteBlockerViews(flow.blockers, renderSubscriptionLink),
363
+ onContinue: flow.onContinue,
364
+ onBack: flow.onBack,
365
+ userEmail: user?.email ?? "",
366
+ confirmEmail: flow.confirmEmail,
367
+ onConfirmEmailChange: flow.onConfirmEmailChange,
368
+ isDeleting: flow.isDeleting,
369
+ onSubmit: flow.onSubmit
370
+ }
371
+ )
372
+ ] });
373
+ }
42
374
 
43
375
  Object.defineProperty(exports, "ConnectedAssistantDock", {
44
376
  enumerable: true,
45
- get: function () { return chunk3MIQASHO_cjs.ConnectedAssistantDock; }
377
+ get: function () { return chunk23XL6SVZ_cjs.ConnectedAssistantDock; }
46
378
  });
47
379
  Object.defineProperty(exports, "ConnectionProvider", {
48
380
  enumerable: true,
49
- get: function () { return chunk3MIQASHO_cjs.ConnectionProvider; }
381
+ get: function () { return chunk23XL6SVZ_cjs.ConnectionProvider; }
50
382
  });
51
383
  Object.defineProperty(exports, "SESSION_EXPIRED_MESSAGE", {
52
384
  enumerable: true,
53
- get: function () { return chunk3MIQASHO_cjs.SESSION_EXPIRED_MESSAGE; }
385
+ get: function () { return chunk23XL6SVZ_cjs.SESSION_EXPIRED_MESSAGE; }
54
386
  });
55
387
  Object.defineProperty(exports, "isAuthenticated", {
56
388
  enumerable: true,
57
- get: function () { return chunk3MIQASHO_cjs.isAuthenticated; }
389
+ get: function () { return chunk23XL6SVZ_cjs.isAuthenticated; }
58
390
  });
59
391
  Object.defineProperty(exports, "redlineStats", {
60
392
  enumerable: true,
61
- get: function () { return chunk3MIQASHO_cjs.redlineStats; }
393
+ get: function () { return chunk23XL6SVZ_cjs.redlineStats; }
62
394
  });
63
395
  Object.defineProperty(exports, "textToArtifact", {
64
396
  enumerable: true,
65
- get: function () { return chunk3MIQASHO_cjs.textToArtifact; }
397
+ get: function () { return chunk23XL6SVZ_cjs.textToArtifact; }
66
398
  });
67
399
  Object.defineProperty(exports, "toRedlineMarkdown", {
68
400
  enumerable: true,
69
- get: function () { return chunk3MIQASHO_cjs.toRedlineMarkdown; }
401
+ get: function () { return chunk23XL6SVZ_cjs.toRedlineMarkdown; }
70
402
  });
71
403
  Object.defineProperty(exports, "useConnectedAiTask", {
72
404
  enumerable: true,
73
- get: function () { return chunk3MIQASHO_cjs.useConnectedAiTask; }
405
+ get: function () { return chunk23XL6SVZ_cjs.useConnectedAiTask; }
74
406
  });
75
407
  Object.defineProperty(exports, "useConnectedChat", {
76
408
  enumerable: true,
77
- get: function () { return chunk3MIQASHO_cjs.useConnectedChat; }
409
+ get: function () { return chunk23XL6SVZ_cjs.useConnectedChat; }
78
410
  });
79
411
  Object.defineProperty(exports, "useConnection", {
80
412
  enumerable: true,
81
- get: function () { return chunk3MIQASHO_cjs.useConnection; }
413
+ get: function () { return chunk23XL6SVZ_cjs.useConnection; }
82
414
  });
83
415
  Object.defineProperty(exports, "useSemanticSearch", {
84
416
  enumerable: true,
85
- get: function () { return chunk3MIQASHO_cjs.useSemanticSearch; }
417
+ get: function () { return chunk23XL6SVZ_cjs.useSemanticSearch; }
86
418
  });
87
419
  Object.defineProperty(exports, "useWorkspaceDocs", {
88
420
  enumerable: true,
89
- get: function () { return chunk3MIQASHO_cjs.useWorkspaceDocs; }
421
+ get: function () { return chunk23XL6SVZ_cjs.useWorkspaceDocs; }
90
422
  });
91
423
  exports.ArbiAppProvider = ArbiAppProvider;
424
+ exports.ConnectedDangerZone = ConnectedDangerZone;
425
+ exports.ConnectedLogoutDialog = ConnectedLogoutDialog;
426
+ exports.ConnectedNotificationPreferences = ConnectedNotificationPreferences;
427
+ exports.ConnectedProfileCard = ConnectedProfileCard;
428
+ exports.ConnectedSecuritySection = ConnectedSecuritySection;
429
+ exports.ConnectedSessionsRow = ConnectedSessionsRow;
430
+ exports.defaultUnmetPasswordRequirement = defaultUnmetPasswordRequirement;
92
431
  exports.useConnectedShellWorkspaces = useConnectedShellWorkspaces;
93
432
  //# sourceMappingURL=index.cjs.map
94
433
  //# sourceMappingURL=index.cjs.map