@arbidocs/blocks 0.4.159 → 0.4.161
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +48 -9
- package/dist/{ConnectedNativeDocxComparison-R6RU5TZE.cjs → ConnectedNativeDocxComparison-GLHOGUP6.cjs} +12 -11
- package/dist/{ConnectedNativeDocxComparison-R6RU5TZE.cjs.map → ConnectedNativeDocxComparison-GLHOGUP6.cjs.map} +1 -1
- package/dist/{ConnectedNativeDocxComparison-XMZ5KLD4.js → ConnectedNativeDocxComparison-LKIMKOTA.js} +11 -10
- package/dist/{ConnectedStreamedWordArtifact-IXRJ7MUE.js.map → ConnectedNativeDocxComparison-LKIMKOTA.js.map} +1 -1
- package/dist/{ConnectedNativeDocxEditor-NGUK2AX6.js → ConnectedNativeDocxEditor-6LNYWZ3P.js} +10 -9
- package/dist/{ConnectedNativeDocxEditor-NGUK2AX6.js.map → ConnectedNativeDocxEditor-6LNYWZ3P.js.map} +1 -1
- package/dist/{ConnectedNativeDocxEditor-LBATSM3M.cjs → ConnectedNativeDocxEditor-M3UGWL6K.cjs} +12 -11
- package/dist/{ConnectedNativeDocxEditor-LBATSM3M.cjs.map → ConnectedNativeDocxEditor-M3UGWL6K.cjs.map} +1 -1
- package/dist/{ConnectedStreamedWordArtifact-IXRJ7MUE.js → ConnectedStreamedWordArtifact-432HT7DK.js} +11 -10
- package/dist/{ConnectedNativeDocxComparison-XMZ5KLD4.js.map → ConnectedStreamedWordArtifact-432HT7DK.js.map} +1 -1
- package/dist/{ConnectedStreamedWordArtifact-CWFR6A37.cjs → ConnectedStreamedWordArtifact-COEXL5IT.cjs} +12 -11
- package/dist/ConnectedStreamedWordArtifact-COEXL5IT.cjs.map +1 -0
- package/dist/{FactTextEditor-YESAU2IJ.js → FactTextEditor-ABKKJOCY.js} +2 -2
- package/dist/FactTextEditor-ABKKJOCY.js.map +1 -0
- package/dist/{FactTextEditor-YUPBCTXK.cjs → FactTextEditor-GYN5RHJT.cjs} +2 -2
- package/dist/FactTextEditor-GYN5RHJT.cjs.map +1 -0
- package/dist/{WorkspaceTableView-EYLEUZZT.cjs → WorkspaceTableView-AQTF5F6T.cjs} +6 -5
- package/dist/WorkspaceTableView-AQTF5F6T.cjs.map +1 -0
- package/dist/{WorkspaceTableView-DWUE4VQF.js → WorkspaceTableView-PTB5BPVA.js} +4 -3
- package/dist/WorkspaceTableView-PTB5BPVA.js.map +1 -0
- package/dist/agents/index.cjs +263 -263
- package/dist/agents/index.js +6 -6
- package/dist/agents/skills/skillLibrary.d.ts +1 -1
- package/dist/{chunk-FPHTSNOE.js → chunk-2AKIMCDD.js} +3 -3
- package/dist/{chunk-FPHTSNOE.js.map → chunk-2AKIMCDD.js.map} +1 -1
- package/dist/{chunk-YNMO3DSR.js → chunk-2AMYT2HQ.js} +3 -3
- package/dist/{chunk-YNMO3DSR.js.map → chunk-2AMYT2HQ.js.map} +1 -1
- package/dist/{chunk-MSFQDELO.cjs → chunk-3CUORKDL.cjs} +4 -4
- package/dist/{chunk-MSFQDELO.cjs.map → chunk-3CUORKDL.cjs.map} +1 -1
- package/dist/{chunk-MNG7N6M2.js → chunk-3PQIWOTZ.js} +122 -57
- package/dist/chunk-3PQIWOTZ.js.map +1 -0
- package/dist/chunk-5C7DRQQE.cjs +1891 -0
- package/dist/chunk-5C7DRQQE.cjs.map +1 -0
- package/dist/{chunk-F57LNUSZ.js → chunk-5NWY3FXQ.js} +24 -57
- package/dist/chunk-5NWY3FXQ.js.map +1 -0
- package/dist/{chunk-ISHFVKVU.js → chunk-5WLORPGX.js} +4 -4
- package/dist/{chunk-ISHFVKVU.js.map → chunk-5WLORPGX.js.map} +1 -1
- package/dist/{chunk-FAXXN7KI.cjs → chunk-5Y6V7F6W.cjs} +53 -4
- package/dist/chunk-5Y6V7F6W.cjs.map +1 -0
- package/dist/{chunk-6QAAIDQQ.cjs → chunk-6UTIAHQG.cjs} +60 -60
- package/dist/{chunk-6QAAIDQQ.cjs.map → chunk-6UTIAHQG.cjs.map} +1 -1
- package/dist/{chunk-KCSIX7CY.js → chunk-6XIXNH26.js} +3 -3
- package/dist/{chunk-KCSIX7CY.js.map → chunk-6XIXNH26.js.map} +1 -1
- package/dist/{chunk-YBJ4QGNH.cjs → chunk-ANLTECZ6.cjs} +8 -8
- package/dist/{chunk-YBJ4QGNH.cjs.map → chunk-ANLTECZ6.cjs.map} +1 -1
- package/dist/{chunk-Q2XGM372.cjs → chunk-AR6A2PMV.cjs} +4 -4
- package/dist/{chunk-Q2XGM372.cjs.map → chunk-AR6A2PMV.cjs.map} +1 -1
- package/dist/{chunk-KBO75NLM.cjs → chunk-AYJZRBHG.cjs} +7 -7
- package/dist/{chunk-KBO75NLM.cjs.map → chunk-AYJZRBHG.cjs.map} +1 -1
- package/dist/{chunk-FM3IRQJW.cjs → chunk-AYKE6USO.cjs} +12 -12
- package/dist/chunk-AYKE6USO.cjs.map +1 -0
- package/dist/chunk-BGJZVJJM.cjs +63 -0
- package/dist/chunk-BGJZVJJM.cjs.map +1 -0
- package/dist/{chunk-ECW2R2KF.cjs → chunk-BPL5RLNN.cjs} +27 -27
- package/dist/{chunk-ECW2R2KF.cjs.map → chunk-BPL5RLNN.cjs.map} +1 -1
- package/dist/{chunk-CNHUJRQ4.cjs → chunk-EFEFLBRM.cjs} +21 -55
- package/dist/chunk-EFEFLBRM.cjs.map +1 -0
- package/dist/{chunk-ETZ5A3GU.js → chunk-EVO2UNX3.js} +3 -3
- package/dist/chunk-EVO2UNX3.js.map +1 -0
- package/dist/{chunk-P6RIBIVN.js → chunk-FMJGVAWX.js} +8 -9
- package/dist/chunk-FMJGVAWX.js.map +1 -0
- package/dist/chunk-H5542IOD.cjs +108 -0
- package/dist/chunk-H5542IOD.cjs.map +1 -0
- package/dist/{chunk-VF5EUAIV.js → chunk-H7PHANI4.js} +3 -3
- package/dist/chunk-H7PHANI4.js.map +1 -0
- package/dist/chunk-HQJL7FSY.js +58 -0
- package/dist/chunk-HQJL7FSY.js.map +1 -0
- package/dist/{chunk-OFV3PRF2.cjs → chunk-HRDVQERS.cjs} +7 -7
- package/dist/{chunk-OFV3PRF2.cjs.map → chunk-HRDVQERS.cjs.map} +1 -1
- package/dist/{chunk-3VULDTNL.cjs → chunk-HUNX4CQG.cjs} +4 -4
- package/dist/chunk-HUNX4CQG.cjs.map +1 -0
- package/dist/{chunk-2BHDRVVL.cjs → chunk-I6I34FDU.cjs} +38 -37
- package/dist/chunk-I6I34FDU.cjs.map +1 -0
- package/dist/chunk-IWVOZREF.js +12 -0
- package/dist/chunk-IWVOZREF.js.map +1 -0
- package/dist/chunk-J7YHBMBB.js +1834 -0
- package/dist/chunk-J7YHBMBB.js.map +1 -0
- package/dist/{chunk-SDOEHEJP.js → chunk-JMQLTMJ7.js} +53 -5
- package/dist/chunk-JMQLTMJ7.js.map +1 -0
- package/dist/{chunk-TF7HN5EU.js → chunk-JNE2XEXD.js} +12 -12
- package/dist/chunk-JNE2XEXD.js.map +1 -0
- package/dist/{chunk-QKR5LWDO.js → chunk-K7CZFNJ2.js} +7 -7
- package/dist/{chunk-QKR5LWDO.js.map → chunk-K7CZFNJ2.js.map} +1 -1
- package/dist/{chunk-4RPBUMHB.cjs → chunk-KMZO5W6D.cjs} +4 -4
- package/dist/chunk-KMZO5W6D.cjs.map +1 -0
- package/dist/{chunk-FTZ45WHY.js → chunk-KNCJSPXV.js} +5020 -4014
- package/dist/chunk-KNCJSPXV.js.map +1 -0
- package/dist/{chunk-3OCNUKGX.js → chunk-KQWC4YBX.js} +3 -3
- package/dist/{chunk-3OCNUKGX.js.map → chunk-KQWC4YBX.js.map} +1 -1
- package/dist/{chunk-TC3RQNEX.cjs → chunk-L4KWTDFE.cjs} +5 -5
- package/dist/chunk-L4KWTDFE.cjs.map +1 -0
- package/dist/{chunk-VTTZZ4FN.js → chunk-LH3JAZ33.js} +5 -5
- package/dist/chunk-LH3JAZ33.js.map +1 -0
- package/dist/{chunk-P2YM67Y5.cjs → chunk-LQYPOWKN.cjs} +14 -21
- package/dist/chunk-LQYPOWKN.cjs.map +1 -0
- package/dist/{chunk-RATEAOKT.js → chunk-NOXGEQQR.js} +7 -13
- package/dist/chunk-NOXGEQQR.js.map +1 -0
- package/dist/{chunk-NPLGB4LI.cjs → chunk-NUAC5GTQ.cjs} +5115 -4077
- package/dist/chunk-NUAC5GTQ.cjs.map +1 -0
- package/dist/chunk-NYECCTB3.js +101 -0
- package/dist/chunk-NYECCTB3.js.map +1 -0
- package/dist/{chunk-GC2FSPSQ.cjs → chunk-O5E3NKPI.cjs} +128 -58
- package/dist/chunk-O5E3NKPI.cjs.map +1 -0
- package/dist/{chunk-SZOFGU7W.js → chunk-O5XREO7H.js} +3 -3
- package/dist/{chunk-SZOFGU7W.js.map → chunk-O5XREO7H.js.map} +1 -1
- package/dist/{chunk-OOU4QLRK.cjs → chunk-OHCYJFV2.cjs} +9 -9
- package/dist/{chunk-OOU4QLRK.cjs.map → chunk-OHCYJFV2.cjs.map} +1 -1
- package/dist/{chunk-DEPF5LQI.js → chunk-OKRYNQPH.js} +3 -3
- package/dist/chunk-OKRYNQPH.js.map +1 -0
- package/dist/{chunk-KFMRBZQK.js → chunk-PCL7IEZO.js} +21 -20
- package/dist/chunk-PCL7IEZO.js.map +1 -0
- package/dist/chunk-RFB7B6XG.cjs +169 -0
- package/dist/chunk-RFB7B6XG.cjs.map +1 -0
- package/dist/{chunk-SZSJGZSO.js → chunk-SQQU3WRB.js} +714 -5
- package/dist/chunk-SQQU3WRB.js.map +1 -0
- package/dist/{chunk-OALEDG67.cjs → chunk-TNESYDBR.cjs} +5 -5
- package/dist/{chunk-OALEDG67.cjs.map → chunk-TNESYDBR.cjs.map} +1 -1
- package/dist/chunk-TTS353W2.js +163 -0
- package/dist/chunk-TTS353W2.js.map +1 -0
- package/dist/{chunk-CROGFB46.cjs → chunk-U7OUZHBH.cjs} +753 -2
- package/dist/chunk-U7OUZHBH.cjs.map +1 -0
- package/dist/{chunk-BQ77KSXU.js → chunk-UORU5S7Y.js} +3 -3
- package/dist/{chunk-BQ77KSXU.js.map → chunk-UORU5S7Y.js.map} +1 -1
- package/dist/{chunk-FYZXDZM7.js → chunk-VFF76GTB.js} +4 -4
- package/dist/{chunk-FYZXDZM7.js.map → chunk-VFF76GTB.js.map} +1 -1
- package/dist/{chunk-E4H5H2C3.cjs → chunk-VYTK2WJB.cjs} +4 -4
- package/dist/{chunk-E4H5H2C3.cjs.map → chunk-VYTK2WJB.cjs.map} +1 -1
- package/dist/{chunk-XI37A7HH.js → chunk-WKSP73RU.js} +3 -3
- package/dist/{chunk-XI37A7HH.js.map → chunk-WKSP73RU.js.map} +1 -1
- package/dist/chunk-WP4VIOOA.cjs +15 -0
- package/dist/chunk-WP4VIOOA.cjs.map +1 -0
- package/dist/{chunk-YF3QUHKN.cjs → chunk-X3XPXEIM.cjs} +14 -15
- package/dist/chunk-X3XPXEIM.cjs.map +1 -0
- package/dist/{chunk-VZPFYZZU.cjs → chunk-Z2HEBOA3.cjs} +8 -8
- package/dist/{chunk-VZPFYZZU.cjs.map → chunk-Z2HEBOA3.cjs.map} +1 -1
- package/dist/{chunk-Q7CQYYZW.cjs → chunk-ZMYW5M75.cjs} +5 -5
- package/dist/chunk-ZMYW5M75.cjs.map +1 -0
- package/dist/{chunk-7UENVUA6.js → chunk-ZW2AWACP.js} +3 -3
- package/dist/{chunk-7UENVUA6.js.map → chunk-ZW2AWACP.js.map} +1 -1
- package/dist/citations/index.cjs +10 -10
- package/dist/citations/index.js +2 -2
- package/dist/collaboration/contacts/contact-form.d.ts +47 -0
- package/dist/collaboration/contacts/index.d.ts +3 -1
- package/dist/collaboration/contacts/invite-plan.d.ts +46 -0
- package/dist/collaboration/contacts/parseEmails.d.ts +7 -0
- package/dist/collaboration/index.cjs +163 -83
- package/dist/collaboration/index.js +2 -2
- package/dist/components/ActionLink.d.ts +1 -1
- package/dist/components/TeamGrid.d.ts +1 -1
- package/dist/components/editorial/{ProfileCard.d.ts → EditorialProfileCard.d.ts} +2 -2
- package/dist/components/editorial/index.d.ts +1 -1
- package/dist/connect/docx.cjs +14 -13
- package/dist/connect/docx.d.ts +1 -1
- package/dist/connect/docx.js +10 -9
- package/dist/connect/index.cjs +22097 -14743
- package/dist/connect/index.cjs.map +1 -1
- package/dist/connect/index.d.ts +11 -7
- package/dist/connect/index.js +15203 -7912
- package/dist/connect/index.js.map +1 -1
- package/dist/connect/viewer.cjs +83 -138
- package/dist/connect/viewer.cjs.map +1 -1
- package/dist/connect/viewer.d.ts +3 -2
- package/dist/connect/viewer.js +25 -82
- package/dist/connect/viewer.js.map +1 -1
- package/dist/connection/ConnectedSettings.d.ts +3 -2
- package/dist/connection/ConnectionProvider.d.ts +5 -4
- package/dist/connection/StreamedArtifact.d.ts +1 -1
- package/dist/connection/billing/index.d.ts +3 -3
- package/dist/connection/billing/support.d.ts +4 -7
- package/dist/connection/contacts/ConnectedAddContacts.d.ts +9 -0
- package/dist/connection/contacts/ConnectedContactCardForm.d.ts +11 -0
- package/dist/connection/contacts/ConnectedContactToggle.d.ts +16 -0
- package/dist/connection/contacts/ConnectedContactsDirectory.d.ts +10 -0
- package/dist/connection/contacts/ImportVcf.d.ts +29 -0
- package/dist/connection/contacts/index.d.ts +5 -0
- package/dist/connection/defaultHost.d.ts +9 -0
- package/dist/connection/docx/ConnectedNativeDocxEditor.d.ts +3 -3
- package/dist/connection/docx/support.d.ts +10 -9
- package/dist/connection/files/bulk/ConnectedFilesBulkActions.d.ts +22 -0
- package/dist/connection/files/bulk/useDocumentBulkActions.d.ts +19 -0
- package/dist/connection/files/explorer/FileTiles.d.ts +6 -3
- package/dist/connection/files/fields/ConnectedBulkTagEditor.d.ts +16 -0
- package/dist/connection/files/fields/ConnectedFieldsEditor.d.ts +40 -0
- package/dist/connection/files/fields/ConnectedFieldsManager.d.ts +33 -0
- package/dist/connection/files/fields/ConnectedTagEditorDialog.d.ts +20 -0
- package/dist/connection/files/fields/ConnectedTagForm.d.ts +54 -0
- package/dist/connection/files/fields/DocumentFieldParts.d.ts +33 -0
- package/dist/connection/files/fields/DocumentUser.d.ts +11 -0
- package/dist/connection/files/fields/documentField.d.ts +48 -0
- package/dist/connection/files/fields/useFieldWrites.d.ts +20 -0
- package/dist/connection/files/fields/useFieldsApply.d.ts +49 -0
- package/dist/connection/files/fields/useMemberLookup.d.ts +3 -0
- package/dist/connection/files/grid/ConnectedTagEntity.d.ts +19 -0
- package/dist/connection/files/grid/cells.d.ts +85 -0
- package/dist/connection/files/grid/documentColumns.d.ts +66 -0
- package/dist/connection/files/grid/documentGridBus.d.ts +48 -0
- package/dist/connection/files/grid/documentStatus.d.ts +43 -0
- package/dist/connection/files/grid/familyMeta.d.ts +21 -0
- package/dist/connection/files/grid/tagColumn.d.ts +23 -0
- package/dist/connection/files/grid/useDocumentGridSync.d.ts +48 -0
- package/dist/connection/files/grid/useDocumentTable.d.ts +30 -0
- package/dist/connection/files/index.d.ts +36 -2
- package/dist/connection/files/move/ConnectedMoveToFolder.d.ts +31 -0
- package/dist/connection/files/page/ConnectedFilesPage.d.ts +86 -0
- package/dist/connection/files/page/DocumentsFilterBarActions.d.ts +39 -0
- package/dist/connection/files/page/DocumentsUploadButton.d.ts +25 -0
- package/dist/connection/files/page/PersistedGridView.d.ts +6 -0
- package/dist/connection/files/page/ProgressiveLoadingChip.d.ts +12 -0
- package/dist/connection/files/page/useDocumentNavigation.d.ts +20 -0
- package/dist/connection/files/review/ConnectedAiReview.d.ts +40 -0
- package/dist/connection/files/review/reviewProgress.d.ts +2 -0
- package/dist/connection/files/store.d.ts +96 -0
- package/dist/connection/files/useDocumentFilters.d.ts +54 -0
- package/dist/connection/files/views/ViewSelector.d.ts +33 -0
- package/dist/connection/files/views/tableViews.d.ts +22 -0
- package/dist/connection/files/views/useTableViews.d.ts +22 -0
- package/dist/connection/mail/ConnectedMailbox.d.ts +2 -2
- package/dist/connection/messenger/ChatAttachments.d.ts +15 -0
- package/dist/connection/messenger/ConnectedChatThread.d.ts +21 -0
- package/dist/connection/messenger/ConnectedGroupMembers.d.ts +20 -0
- package/dist/connection/messenger/ConnectedMessenger.d.ts +52 -0
- package/dist/connection/messenger/index.d.ts +6 -0
- package/dist/connection/messenger/types.d.ts +103 -0
- package/dist/connection/messenger/useMessengerRows.d.ts +19 -0
- package/dist/connection/tags/ConnectedTagsPage.d.ts +2 -35
- package/dist/connection/viewer/ConnectedDocumentToolsProvider.d.ts +19 -2
- package/dist/connection/viewer/ConnectedDocumentViewer.d.ts +1 -1
- package/dist/connection/viewer/support.d.ts +21 -15
- package/dist/connection/workspaceData.d.ts +134 -8
- package/dist/facts/index.cjs +3 -3
- package/dist/facts/index.js +2 -2
- package/dist/files/bulk/BulkActionsBar.d.ts +9 -5
- package/dist/files/cells/DocumentNameCell.d.ts +4 -2
- package/dist/files/cells/MultiSelectCellEditor.d.ts +13 -0
- package/dist/files/cells/RelatedDocsCell.d.ts +2 -1
- package/dist/files/cells/index.d.ts +1 -0
- package/dist/files/documentColumns.d.ts +15 -0
- package/dist/files/folders/DocumentsFolderButton.d.ts +26 -0
- package/dist/files/folders/FolderTreePicker.d.ts +16 -0
- package/dist/files/folders/index.d.ts +2 -0
- package/dist/files/index.cjs +430 -434
- package/dist/files/index.d.ts +4 -1
- package/dist/files/index.js +5 -5
- package/dist/files/navigator/DocumentSearchList.d.ts +19 -0
- package/dist/files/navigator/ExplorerFileNavigator.d.ts +23 -0
- package/dist/files/navigator/NavDocumentPicker.d.ts +15 -0
- package/dist/files/navigator/NavigatorPickerBar.d.ts +26 -0
- package/dist/files/navigator/index.d.ts +5 -0
- package/dist/files/navigator/types.d.ts +7 -0
- package/dist/files/tags/BulkTagEditor.d.ts +2 -1
- package/dist/files/tags/index.d.ts +0 -2
- package/dist/files/visibility.d.ts +6 -5
- package/dist/home/StartTiles.d.ts +1 -1
- package/dist/home/index.cjs +30 -30
- package/dist/home/index.js +5 -5
- package/dist/index.cjs +684 -694
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +22 -134
- package/dist/index.js.map +1 -1
- package/dist/provider/{BlocksProvider.d.ts → environment.d.ts} +8 -10
- package/dist/provider/host.d.ts +44 -0
- package/dist/retrieval/index.cjs +4 -4
- package/dist/retrieval/index.js +2 -2
- package/dist/shell/index.cjs +44 -44
- package/dist/shell/index.js +3 -3
- package/dist/shell/types.d.ts +1 -1
- package/dist/site/index.cjs +61 -61
- package/dist/site/index.js +2 -2
- package/dist/studio/index.cjs +86 -87
- package/dist/studio/index.cjs.map +1 -1
- package/dist/studio/index.js +15 -16
- package/dist/studio/index.js.map +1 -1
- package/dist/workflow-canvas/index.cjs +28 -27
- package/dist/workflow-canvas/index.cjs.map +1 -1
- package/dist/workflow-canvas/index.js +11 -10
- package/dist/workflow-canvas/index.js.map +1 -1
- package/dist/workspaces/WorkspaceCard.d.ts +1 -1
- package/dist/workspaces/index.cjs +20 -20
- package/dist/workspaces/index.js +4 -4
- package/node_modules/@arbidocs/coedit/package.json +1 -1
- package/package.json +5 -5
- package/dist/ConnectedStreamedWordArtifact-CWFR6A37.cjs.map +0 -1
- package/dist/FactTextEditor-YESAU2IJ.js.map +0 -1
- package/dist/FactTextEditor-YUPBCTXK.cjs.map +0 -1
- package/dist/WorkspaceTableView-DWUE4VQF.js.map +0 -1
- package/dist/WorkspaceTableView-EYLEUZZT.cjs.map +0 -1
- package/dist/chunk-2BHDRVVL.cjs.map +0 -1
- package/dist/chunk-3VULDTNL.cjs.map +0 -1
- package/dist/chunk-4RPBUMHB.cjs.map +0 -1
- package/dist/chunk-5ZIYPZYE.js +0 -2748
- package/dist/chunk-5ZIYPZYE.js.map +0 -1
- package/dist/chunk-6I6CVX5G.cjs +0 -22
- package/dist/chunk-6I6CVX5G.cjs.map +0 -1
- package/dist/chunk-7NL6WJER.cjs +0 -682
- package/dist/chunk-7NL6WJER.cjs.map +0 -1
- package/dist/chunk-CB4TIDEX.cjs +0 -54
- package/dist/chunk-CB4TIDEX.cjs.map +0 -1
- package/dist/chunk-CNHUJRQ4.cjs.map +0 -1
- package/dist/chunk-CROGFB46.cjs.map +0 -1
- package/dist/chunk-DEPF5LQI.js.map +0 -1
- package/dist/chunk-ETZ5A3GU.js.map +0 -1
- package/dist/chunk-EYJMMGXF.js +0 -19
- package/dist/chunk-EYJMMGXF.js.map +0 -1
- package/dist/chunk-F57LNUSZ.js.map +0 -1
- package/dist/chunk-FAXXN7KI.cjs.map +0 -1
- package/dist/chunk-FM3IRQJW.cjs.map +0 -1
- package/dist/chunk-FTZ45WHY.js.map +0 -1
- package/dist/chunk-GC2FSPSQ.cjs.map +0 -1
- package/dist/chunk-KDLX5AA7.js +0 -49
- package/dist/chunk-KDLX5AA7.js.map +0 -1
- package/dist/chunk-KFMRBZQK.js.map +0 -1
- package/dist/chunk-MNG7N6M2.js.map +0 -1
- package/dist/chunk-NPLGB4LI.cjs.map +0 -1
- package/dist/chunk-P2YM67Y5.cjs.map +0 -1
- package/dist/chunk-P6RIBIVN.js.map +0 -1
- package/dist/chunk-Q7CQYYZW.cjs.map +0 -1
- package/dist/chunk-QJFJ5JBF.cjs +0 -2838
- package/dist/chunk-QJFJ5JBF.cjs.map +0 -1
- package/dist/chunk-RATEAOKT.js.map +0 -1
- package/dist/chunk-SDOEHEJP.js.map +0 -1
- package/dist/chunk-SZSJGZSO.js.map +0 -1
- package/dist/chunk-TC3RQNEX.cjs.map +0 -1
- package/dist/chunk-TF7HN5EU.js.map +0 -1
- package/dist/chunk-VF5EUAIV.js.map +0 -1
- package/dist/chunk-VTTZZ4FN.js.map +0 -1
- package/dist/chunk-WK6FVIF7.js +0 -654
- package/dist/chunk-WK6FVIF7.js.map +0 -1
- package/dist/chunk-YF3QUHKN.cjs.map +0 -1
- package/dist/connection/ArbiAppProvider.d.ts +0 -16
- package/dist/connection/files/support.d.ts +0 -40
- package/dist/files/tags/DocTagPopover.d.ts +0 -113
- package/dist/files/tags/TagManager.d.ts +0 -54
|
@@ -2,8 +2,9 @@
|
|
|
2
2
|
import { RoleBadge } from './chunk-NBV56SGU.js';
|
|
3
3
|
import { GridView } from './chunk-N5YEF3LC.js';
|
|
4
4
|
import { testIdOr } from './chunk-7F6CBP3Z.js';
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
5
|
+
import { ModalSection, ModalSectionTitle } from './chunk-TX2ZICS7.js';
|
|
6
|
+
import { Clock, UserMinus, Trash2, Gift, AtSign, UserPlus, MoreVertical, Plus, KeyRound, Loader2, BellOff, Bell, X, ChevronsUpDown, Paperclip, Mail, AlertCircle, CheckCircle2, Send, ArrowLeft, Reply, Sparkles, Forward, RotateCcw, Archive, FolderOpen, XCircle, CheckCircle, ChevronDown, ChevronRight } from 'lucide-react';
|
|
7
|
+
import { cn, Tooltip, TooltipTrigger, Select, SelectTrigger, SelectContent, SelectItem, TooltipContent, SelectValue, Button, Textarea, DropdownMenu, DropdownMenuTrigger, DropdownMenuContent, DropdownMenuSeparator, DropdownMenuItem, ScrollArea, Dialog, DialogContent, DialogHeader, DialogTitle, DialogDescription, DialogFooter, Popover, PopoverTrigger, PopoverContent, Command, CommandInput, CommandList, CommandEmpty, CommandGroup, CommandItem, Checkbox } from '@arbidocs/react/ui';
|
|
7
8
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
8
9
|
import { useMemo, useState, useRef, useEffect } from 'react';
|
|
9
10
|
import DOMPurify from 'dompurify';
|
|
@@ -157,6 +158,714 @@ function RoleSelect({ value, roles, onChange, description }) {
|
|
|
157
158
|
] });
|
|
158
159
|
}
|
|
159
160
|
|
|
161
|
+
// src/collaboration/contacts/parseEmails.ts
|
|
162
|
+
var MAX_INVITE_EMAILS = 100;
|
|
163
|
+
var EMAIL = /^[^\s@,;]+@[^\s@,;]+\.[^\s@,;]+$/;
|
|
164
|
+
function parseEmails(text) {
|
|
165
|
+
const parts = text.split(/[\s,;]+/).map((e) => e.trim().toLowerCase());
|
|
166
|
+
return [...new Set(parts.filter((e) => EMAIL.test(e)))];
|
|
167
|
+
}
|
|
168
|
+
var DEFAULT_CONTACT_OUTCOME_LABELS = {
|
|
169
|
+
contact_added: "Added to contacts (existing user)",
|
|
170
|
+
already_contact: "Already in your contacts",
|
|
171
|
+
invited: "Invitation sent",
|
|
172
|
+
reinvited: "Previous invitation expired, new one sent",
|
|
173
|
+
not_resent_still_pending: "Invitation already pending, not resent",
|
|
174
|
+
failed: "Could not be invited",
|
|
175
|
+
added: "Added successfully"
|
|
176
|
+
};
|
|
177
|
+
function contactOutcomeMessage(row, labels = {}) {
|
|
178
|
+
const l = { ...DEFAULT_CONTACT_OUTCOME_LABELS, ...labels };
|
|
179
|
+
const base = row.outcome ? l[row.outcome] : row.status === "registered" ? l.contact_added : l.added;
|
|
180
|
+
return row.outcome_detail ? `${base} \u2014 ${row.outcome_detail}` : base;
|
|
181
|
+
}
|
|
182
|
+
function toAddContactsRow(row, labels = {}) {
|
|
183
|
+
return {
|
|
184
|
+
email: row.email ?? "",
|
|
185
|
+
status: row.outcome === "failed" ? "failed" : "success",
|
|
186
|
+
message: contactOutcomeMessage(row, labels)
|
|
187
|
+
};
|
|
188
|
+
}
|
|
189
|
+
var toAddContactsRows = (rows, labels) => rows.map((r) => toAddContactsRow(r, labels));
|
|
190
|
+
var DEFAULT_ADD_CONTACTS_LABELS = {
|
|
191
|
+
placeholder: "name@example.com",
|
|
192
|
+
hint: "Paste one or multiple emails \u2014 separated by commas, spaces, or new lines.",
|
|
193
|
+
add: (count) => `Add${count > 0 ? ` (${count})` : ""}`,
|
|
194
|
+
addOverMax: (count, max) => `Add (${count}) - Max ${max}`,
|
|
195
|
+
adding: "Adding...",
|
|
196
|
+
cancel: "Cancel",
|
|
197
|
+
results: "Results",
|
|
198
|
+
email: "Email",
|
|
199
|
+
status: "Status",
|
|
200
|
+
done: "Done",
|
|
201
|
+
addMore: "Add More",
|
|
202
|
+
reward: (amount) => /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
203
|
+
"Get ",
|
|
204
|
+
/* @__PURE__ */ jsxs("span", { className: "font-semibold text-foreground", children: [
|
|
205
|
+
amount,
|
|
206
|
+
" off your next invoice"
|
|
207
|
+
] }),
|
|
208
|
+
" for every invited contact who goes Pro. They get ",
|
|
209
|
+
amount,
|
|
210
|
+
" off theirs."
|
|
211
|
+
] })
|
|
212
|
+
};
|
|
213
|
+
function AddContactsForm({
|
|
214
|
+
value,
|
|
215
|
+
onChange,
|
|
216
|
+
emailCount: emailCountProp,
|
|
217
|
+
maxEmails = MAX_INVITE_EMAILS,
|
|
218
|
+
isPending,
|
|
219
|
+
onSubmit,
|
|
220
|
+
onCancel,
|
|
221
|
+
rewardAmount,
|
|
222
|
+
labels
|
|
223
|
+
}) {
|
|
224
|
+
const l = useMemo(() => ({ ...DEFAULT_ADD_CONTACTS_LABELS, ...labels }), [labels]);
|
|
225
|
+
const emails = useMemo(() => parseEmails(value), [value]);
|
|
226
|
+
const emailCount = emailCountProp ?? emails.length;
|
|
227
|
+
const overMax = emailCount > maxEmails;
|
|
228
|
+
return /* @__PURE__ */ jsxs("div", { className: "space-y-4", "data-slot": "add-contacts-form", children: [
|
|
229
|
+
rewardAmount && /* @__PURE__ */ jsxs(
|
|
230
|
+
"div",
|
|
231
|
+
{
|
|
232
|
+
className: "flex items-start gap-2 rounded-md bg-green-bg p-3 text-sm",
|
|
233
|
+
"data-testid": "invite-reward-banner",
|
|
234
|
+
children: [
|
|
235
|
+
/* @__PURE__ */ jsx(Gift, { className: "mt-0.5 size-4 shrink-0 text-green-text" }),
|
|
236
|
+
/* @__PURE__ */ jsx("p", { className: "text-muted-foreground", children: l.reward(rewardAmount) })
|
|
237
|
+
]
|
|
238
|
+
}
|
|
239
|
+
),
|
|
240
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
241
|
+
/* @__PURE__ */ jsx(
|
|
242
|
+
Textarea,
|
|
243
|
+
{
|
|
244
|
+
id: "invite-emails",
|
|
245
|
+
value,
|
|
246
|
+
onChange: (e) => onChange(e.target.value),
|
|
247
|
+
disabled: isPending,
|
|
248
|
+
placeholder: l.placeholder,
|
|
249
|
+
rows: 2,
|
|
250
|
+
autoFocus: true,
|
|
251
|
+
"data-testid": "invite-emails-input"
|
|
252
|
+
}
|
|
253
|
+
),
|
|
254
|
+
/* @__PURE__ */ jsx("p", { className: "mt-1.5 text-sm text-muted-foreground", children: l.hint })
|
|
255
|
+
] }),
|
|
256
|
+
/* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2 pt-2", children: [
|
|
257
|
+
/* @__PURE__ */ jsx(
|
|
258
|
+
Button,
|
|
259
|
+
{
|
|
260
|
+
onClick: () => onSubmit(emails),
|
|
261
|
+
disabled: emailCount === 0 || overMax || isPending,
|
|
262
|
+
className: "w-full",
|
|
263
|
+
"data-testid": "invite-send-button",
|
|
264
|
+
children: isPending ? l.adding : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
265
|
+
/* @__PURE__ */ jsx(AtSign, { className: "mr-2 size-4" }),
|
|
266
|
+
overMax ? l.addOverMax(emailCount, maxEmails) : l.add(emailCount)
|
|
267
|
+
] })
|
|
268
|
+
}
|
|
269
|
+
),
|
|
270
|
+
/* @__PURE__ */ jsx(Button, { variant: "outline", onClick: onCancel, disabled: isPending, className: "w-full", children: l.cancel })
|
|
271
|
+
] })
|
|
272
|
+
] });
|
|
273
|
+
}
|
|
274
|
+
var STATUS_ICON = {
|
|
275
|
+
success: /* @__PURE__ */ jsx(CheckCircle, { className: "size-4 shrink-0 text-green-text" }),
|
|
276
|
+
failed: /* @__PURE__ */ jsx(XCircle, { className: "size-4 shrink-0 text-red-text" }),
|
|
277
|
+
pending: /* @__PURE__ */ jsx(AlertCircle, { className: "size-4 shrink-0 text-yellow-text" })
|
|
278
|
+
};
|
|
279
|
+
function AddContactsResults({ rows, onDone, onAddMore, labels }) {
|
|
280
|
+
const l = useMemo(() => ({ ...DEFAULT_ADD_CONTACTS_LABELS, ...labels }), [labels]);
|
|
281
|
+
return /* @__PURE__ */ jsxs(ModalSection, { children: [
|
|
282
|
+
/* @__PURE__ */ jsx(ModalSectionTitle, { children: l.results }),
|
|
283
|
+
/* @__PURE__ */ jsx("div", { className: "max-h-80 overflow-y-auto rounded-md border", children: /* @__PURE__ */ jsxs("table", { className: "w-full", children: [
|
|
284
|
+
/* @__PURE__ */ jsx("thead", { className: "sticky top-0 bg-muted/50", children: /* @__PURE__ */ jsxs("tr", { children: [
|
|
285
|
+
/* @__PURE__ */ jsx("th", { className: "p-2 text-left font-medium", children: l.email }),
|
|
286
|
+
/* @__PURE__ */ jsx("th", { className: "p-2 text-left font-medium", children: l.status })
|
|
287
|
+
] }) }),
|
|
288
|
+
/* @__PURE__ */ jsx("tbody", { children: rows.map((row, index) => /* @__PURE__ */ jsxs(
|
|
289
|
+
"tr",
|
|
290
|
+
{
|
|
291
|
+
className: "border-t hover:bg-muted/30",
|
|
292
|
+
"data-testid": `email-status-row-${index}`,
|
|
293
|
+
children: [
|
|
294
|
+
/* @__PURE__ */ jsx("td", { className: "p-2", children: row.email }),
|
|
295
|
+
/* @__PURE__ */ jsx("td", { className: "p-2", children: /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
296
|
+
STATUS_ICON[row.status],
|
|
297
|
+
/* @__PURE__ */ jsx("span", { className: "text-muted-foreground", children: row.message })
|
|
298
|
+
] }) })
|
|
299
|
+
]
|
|
300
|
+
},
|
|
301
|
+
index
|
|
302
|
+
)) })
|
|
303
|
+
] }) }),
|
|
304
|
+
/* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2 pt-4", children: [
|
|
305
|
+
/* @__PURE__ */ jsx(Button, { onClick: onDone, className: "w-full", "data-testid": "close-results-button", children: l.done }),
|
|
306
|
+
/* @__PURE__ */ jsx(
|
|
307
|
+
Button,
|
|
308
|
+
{
|
|
309
|
+
variant: "outline",
|
|
310
|
+
onClick: onAddMore,
|
|
311
|
+
className: "w-full",
|
|
312
|
+
"data-testid": "start-over-button",
|
|
313
|
+
children: l.addMore
|
|
314
|
+
}
|
|
315
|
+
)
|
|
316
|
+
] })
|
|
317
|
+
] });
|
|
318
|
+
}
|
|
319
|
+
|
|
320
|
+
// src/collaboration/contacts/invite-plan.ts
|
|
321
|
+
function emailTokens(text) {
|
|
322
|
+
return [
|
|
323
|
+
...new Set(
|
|
324
|
+
text.split(/[,;\s]+/).map((e) => e.trim().toLowerCase()).filter(Boolean)
|
|
325
|
+
)
|
|
326
|
+
];
|
|
327
|
+
}
|
|
328
|
+
var EMAIL2 = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/;
|
|
329
|
+
var isInvitableEmail = (email) => EMAIL2.test(email) && !email.includes("..");
|
|
330
|
+
var DEFAULT_CONTACT_INVITE_LABELS = {
|
|
331
|
+
invalid: "Invalid email format (excluded)",
|
|
332
|
+
self: "Can't add yourself as a contact",
|
|
333
|
+
resending: "Resending invitation...",
|
|
334
|
+
sending: "Sending...",
|
|
335
|
+
alreadyInvited: "User already in contacts (invitation pending)",
|
|
336
|
+
alreadyRegistered: "User already in contacts (registered)",
|
|
337
|
+
notProcessed: "Not processed by server (may be rate limited or invalid)"
|
|
338
|
+
};
|
|
339
|
+
function planContactInvites(text, contacts, selfEmail, labels = {}) {
|
|
340
|
+
const l = { ...DEFAULT_CONTACT_INVITE_LABELS, ...labels };
|
|
341
|
+
const me = selfEmail?.toLowerCase();
|
|
342
|
+
const tokens = emailTokens(text);
|
|
343
|
+
const invalid = tokens.filter((e) => !isInvitableEmail(e));
|
|
344
|
+
const valid = tokens.filter((e) => isInvitableEmail(e));
|
|
345
|
+
const rows = invalid.map((email) => ({
|
|
346
|
+
email,
|
|
347
|
+
status: "failed",
|
|
348
|
+
message: l.invalid
|
|
349
|
+
}));
|
|
350
|
+
const self = valid.filter((e) => me && e === me);
|
|
351
|
+
rows.push(...self.map((email) => ({ email, status: "failed", message: l.self })));
|
|
352
|
+
const send = [];
|
|
353
|
+
for (const email of valid) {
|
|
354
|
+
if (me && email === me) continue;
|
|
355
|
+
const existing = contacts.find((c) => c.email?.toLowerCase() === email);
|
|
356
|
+
if (!existing) {
|
|
357
|
+
send.push(email);
|
|
358
|
+
rows.push({ email, status: "pending", message: l.sending });
|
|
359
|
+
} else if (existing.status === "expired") {
|
|
360
|
+
send.push(email);
|
|
361
|
+
rows.push({ email, status: "pending", message: l.resending });
|
|
362
|
+
} else
|
|
363
|
+
rows.push({
|
|
364
|
+
email,
|
|
365
|
+
status: "success",
|
|
366
|
+
message: existing.status === "invited" ? l.alreadyInvited : l.alreadyRegistered
|
|
367
|
+
});
|
|
368
|
+
}
|
|
369
|
+
return { rows, send };
|
|
370
|
+
}
|
|
371
|
+
function applyContactInviteResults(plan, response, labels = {}) {
|
|
372
|
+
const l = { ...DEFAULT_CONTACT_INVITE_LABELS, ...labels };
|
|
373
|
+
return plan.rows.map((row) => {
|
|
374
|
+
if (!plan.send.includes(row.email)) return row;
|
|
375
|
+
const answer = response.find((c) => c.email?.toLowerCase() === row.email);
|
|
376
|
+
return answer ? { ...toAddContactsRow(answer, labels), email: row.email } : { email: row.email, status: "failed", message: l.notProcessed };
|
|
377
|
+
});
|
|
378
|
+
}
|
|
379
|
+
function failContactInvites(plan, message) {
|
|
380
|
+
return plan.rows.map(
|
|
381
|
+
(row) => plan.send.includes(row.email) ? { ...row, status: "failed", message } : row
|
|
382
|
+
);
|
|
383
|
+
}
|
|
384
|
+
function summarizeContactInvites(response) {
|
|
385
|
+
const count = (...outcomes) => response.filter((c) => outcomes.includes(c.outcome)).length;
|
|
386
|
+
const added = count("contact_added");
|
|
387
|
+
const sent = count("invited", "reinvited");
|
|
388
|
+
const failed = count("failed");
|
|
389
|
+
const notResent = count("not_resent_still_pending");
|
|
390
|
+
const parts = [];
|
|
391
|
+
if (added) parts.push(`${added} contact${added !== 1 ? "s" : ""} added`);
|
|
392
|
+
if (sent) parts.push(`${sent} invitation email${sent !== 1 ? "s" : ""} sent`);
|
|
393
|
+
if (notResent) parts.push(`${notResent} already pending`);
|
|
394
|
+
if (failed) parts.push(`${failed} failed`);
|
|
395
|
+
return { message: parts.length ? parts.join(", ") : "No changes", failed: failed > 0 };
|
|
396
|
+
}
|
|
397
|
+
function summarizeUnsentInvites(rows, labels = {}) {
|
|
398
|
+
const l = { ...DEFAULT_CONTACT_INVITE_LABELS, ...labels };
|
|
399
|
+
const already = rows.filter(
|
|
400
|
+
(r) => r.message === l.alreadyInvited || r.message === l.alreadyRegistered
|
|
401
|
+
).length;
|
|
402
|
+
const excluded = rows.filter((r) => r.message === l.invalid).length;
|
|
403
|
+
if (already && excluded) return `${already} already in contacts, ${excluded} excluded`;
|
|
404
|
+
if (already) return `All ${already} email${already !== 1 ? "s are" : " is"} already in contacts`;
|
|
405
|
+
return "All emails excluded (invalid or duplicate)";
|
|
406
|
+
}
|
|
407
|
+
|
|
408
|
+
// src/collaboration/contacts/contact-form.ts
|
|
409
|
+
var EMPTY_CONTACT_FORM = {
|
|
410
|
+
name: "",
|
|
411
|
+
emails: [{ value: "", type: "" }],
|
|
412
|
+
phones: [{ value: "", type: "" }],
|
|
413
|
+
addresses: [],
|
|
414
|
+
organization: "",
|
|
415
|
+
title: "",
|
|
416
|
+
birthday: "",
|
|
417
|
+
anniversary: "",
|
|
418
|
+
note: "",
|
|
419
|
+
nickname: "",
|
|
420
|
+
urls: []
|
|
421
|
+
};
|
|
422
|
+
function str(v) {
|
|
423
|
+
return typeof v === "string" ? v : "";
|
|
424
|
+
}
|
|
425
|
+
function contactToForm(c) {
|
|
426
|
+
const pick = (rows, key) => (rows ?? []).map((row) => {
|
|
427
|
+
const r = row;
|
|
428
|
+
return { value: str(r[key]), type: str(r.type) };
|
|
429
|
+
});
|
|
430
|
+
const emails = pick(c.emails, "email");
|
|
431
|
+
const phones = pick(c.phones, "number");
|
|
432
|
+
return {
|
|
433
|
+
name: c.name ?? "",
|
|
434
|
+
emails: emails.length ? emails : [{ value: "", type: "" }],
|
|
435
|
+
phones: phones.length ? phones : [{ value: "", type: "" }],
|
|
436
|
+
addresses: pick(c.addresses, "value"),
|
|
437
|
+
organization: c.organization ?? "",
|
|
438
|
+
title: c.title ?? "",
|
|
439
|
+
birthday: c.birthday ?? "",
|
|
440
|
+
anniversary: c.anniversary ?? "",
|
|
441
|
+
note: c.note ?? "",
|
|
442
|
+
nickname: c.nickname ?? "",
|
|
443
|
+
urls: c.urls ?? []
|
|
444
|
+
};
|
|
445
|
+
}
|
|
446
|
+
var FULL_DATE = /^\d{4}-\d{2}-\d{2}$/;
|
|
447
|
+
var NO_YEAR = /^--\d{2}-\d{2}$/;
|
|
448
|
+
var MONTH_DAY = /^\d{2}-\d{2}$/;
|
|
449
|
+
function normalizeVCardDate(input) {
|
|
450
|
+
const v = input.trim();
|
|
451
|
+
if (!v) return null;
|
|
452
|
+
const candidate = MONTH_DAY.test(v) ? `--${v}` : v;
|
|
453
|
+
if (!FULL_DATE.test(candidate) && !NO_YEAR.test(candidate)) return void 0;
|
|
454
|
+
const [m, d] = candidate.slice(-5).split("-").map(Number);
|
|
455
|
+
if (m < 1 || m > 12 || d < 1 || d > 31) return void 0;
|
|
456
|
+
if (FULL_DATE.test(candidate)) {
|
|
457
|
+
const y = Number(candidate.slice(0, 4));
|
|
458
|
+
const t = new Date(Date.UTC(y, m - 1, d));
|
|
459
|
+
if (t.getUTCMonth() !== m - 1) return void 0;
|
|
460
|
+
} else {
|
|
461
|
+
const max = [31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31][m - 1];
|
|
462
|
+
if (d > max) return void 0;
|
|
463
|
+
}
|
|
464
|
+
return candidate;
|
|
465
|
+
}
|
|
466
|
+
var EMAIL3 = /^[^@\s]+@[^@\s]+\.[^@\s]+$/;
|
|
467
|
+
function validateContactForm(f) {
|
|
468
|
+
const errors = {};
|
|
469
|
+
if (!f.name.trim()) errors.name = "Enter a name";
|
|
470
|
+
if (f.emails.some((e) => e.value.trim() && !EMAIL3.test(e.value.trim())))
|
|
471
|
+
errors.emails = "Check the e-mail address";
|
|
472
|
+
if (normalizeVCardDate(f.birthday) === void 0)
|
|
473
|
+
errors.birthday = "Use YYYY-MM-DD, or --MM-DD without a year";
|
|
474
|
+
if (normalizeVCardDate(f.anniversary) === void 0)
|
|
475
|
+
errors.anniversary = "Use YYYY-MM-DD, or --MM-DD without a year";
|
|
476
|
+
return errors;
|
|
477
|
+
}
|
|
478
|
+
function formToContactCard(f) {
|
|
479
|
+
const rows = (list) => list.map((r) => ({ value: r.value.trim(), type: r.type.trim() || null })).filter((r) => r.value);
|
|
480
|
+
const opt = (v) => v.trim() || null;
|
|
481
|
+
return {
|
|
482
|
+
name: f.name.trim(),
|
|
483
|
+
emails: rows(f.emails).map((r) => ({ email: r.value, type: r.type })),
|
|
484
|
+
phones: rows(f.phones).map((r) => ({ number: r.value, type: r.type })),
|
|
485
|
+
addresses: rows(f.addresses).map((r) => ({ value: r.value, type: r.type })),
|
|
486
|
+
organization: opt(f.organization),
|
|
487
|
+
title: opt(f.title),
|
|
488
|
+
birthday: normalizeVCardDate(f.birthday) ?? null,
|
|
489
|
+
anniversary: normalizeVCardDate(f.anniversary) ?? null,
|
|
490
|
+
note: opt(f.note),
|
|
491
|
+
nickname: opt(f.nickname),
|
|
492
|
+
urls: f.urls.map((u) => u.trim()).filter(Boolean)
|
|
493
|
+
};
|
|
494
|
+
}
|
|
495
|
+
function inviteEmail(f) {
|
|
496
|
+
const first = f.emails.map((e) => e.value.trim()).find((e) => EMAIL3.test(e));
|
|
497
|
+
return first ? first.toLowerCase() : null;
|
|
498
|
+
}
|
|
499
|
+
function contactName(c) {
|
|
500
|
+
const user = c.user ? [c.user.given_name, c.user.family_name].filter(Boolean).join(" ") : "";
|
|
501
|
+
return c.card?.name || user || c.email || "";
|
|
502
|
+
}
|
|
503
|
+
function primaryEmail(c) {
|
|
504
|
+
return c.email || c.card?.emails?.[0]?.email || null;
|
|
505
|
+
}
|
|
506
|
+
function matchesContact(c, q) {
|
|
507
|
+
const term = q.trim().toLowerCase();
|
|
508
|
+
if (!term) return true;
|
|
509
|
+
const card = c.card;
|
|
510
|
+
const hay = [
|
|
511
|
+
contactName(c),
|
|
512
|
+
c.email,
|
|
513
|
+
card?.organization,
|
|
514
|
+
card?.title,
|
|
515
|
+
card?.nickname,
|
|
516
|
+
...(card?.emails ?? []).map((e) => e.email),
|
|
517
|
+
...(card?.phones ?? []).map((p) => p.number)
|
|
518
|
+
];
|
|
519
|
+
return hay.some((h) => h && h.toLowerCase().includes(term));
|
|
520
|
+
}
|
|
521
|
+
function contactStatusLabel(status) {
|
|
522
|
+
switch (status) {
|
|
523
|
+
case "registered":
|
|
524
|
+
return "On ARBI";
|
|
525
|
+
case "invited":
|
|
526
|
+
return "Invited";
|
|
527
|
+
case "expired":
|
|
528
|
+
return "Invite expired";
|
|
529
|
+
case "failed":
|
|
530
|
+
return "Invite failed";
|
|
531
|
+
default:
|
|
532
|
+
return null;
|
|
533
|
+
}
|
|
534
|
+
}
|
|
535
|
+
function summarizeImport(r) {
|
|
536
|
+
const parts = [`${r.added} added`];
|
|
537
|
+
if (r.matched) parts.push(`${r.matched} matched existing contact${r.matched === 1 ? "" : "s"}`);
|
|
538
|
+
if (r.skipped.length) parts.push(`${r.skipped.length} skipped`);
|
|
539
|
+
return parts.join(", ");
|
|
540
|
+
}
|
|
541
|
+
var DEFAULT_DM_INVITE_CHIP_LABELS = {
|
|
542
|
+
title: "Add a contact by email",
|
|
543
|
+
description: "Send an invitation to join you on ARBI"
|
|
544
|
+
};
|
|
545
|
+
function DmInviteChip({
|
|
546
|
+
onClick,
|
|
547
|
+
title,
|
|
548
|
+
description,
|
|
549
|
+
testId = "dm-invite-chip",
|
|
550
|
+
labels
|
|
551
|
+
}) {
|
|
552
|
+
const l = useMemo(() => ({ ...DEFAULT_DM_INVITE_CHIP_LABELS, ...labels }), [labels]);
|
|
553
|
+
return /* @__PURE__ */ jsxs(
|
|
554
|
+
"button",
|
|
555
|
+
{
|
|
556
|
+
type: "button",
|
|
557
|
+
onClick,
|
|
558
|
+
"data-testid": testId,
|
|
559
|
+
className: "flex w-full items-center gap-3 border-b border-border px-4 py-3 text-left transition-colors hover:bg-accent/60 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring pointer-coarse:min-h-11",
|
|
560
|
+
children: [
|
|
561
|
+
/* @__PURE__ */ jsx("span", { className: "flex size-9 shrink-0 items-center justify-center rounded-full bg-ai-accent-soft", children: /* @__PURE__ */ jsx(UserPlus, { className: "size-4 text-ai-accent" }) }),
|
|
562
|
+
/* @__PURE__ */ jsxs("span", { className: "min-w-0", children: [
|
|
563
|
+
/* @__PURE__ */ jsx("span", { className: "block text-sm font-semibold text-foreground", children: title ?? l.title }),
|
|
564
|
+
/* @__PURE__ */ jsx("span", { className: "block text-xs text-muted-foreground", children: description ?? l.description })
|
|
565
|
+
] })
|
|
566
|
+
]
|
|
567
|
+
}
|
|
568
|
+
);
|
|
569
|
+
}
|
|
570
|
+
function DmThreadHeader({
|
|
571
|
+
avatar,
|
|
572
|
+
name,
|
|
573
|
+
badge,
|
|
574
|
+
presence,
|
|
575
|
+
email,
|
|
576
|
+
menu,
|
|
577
|
+
testId = "dm-active-chip"
|
|
578
|
+
}) {
|
|
579
|
+
return /* @__PURE__ */ jsxs(
|
|
580
|
+
"div",
|
|
581
|
+
{
|
|
582
|
+
className: "flex items-center gap-1 border-b border-border pr-2",
|
|
583
|
+
"data-slot": "dm-thread-header",
|
|
584
|
+
children: [
|
|
585
|
+
/* @__PURE__ */ jsxs("div", { "data-testid": testId, className: "flex min-w-0 flex-1 items-center gap-3 px-4 py-2.5", children: [
|
|
586
|
+
avatar,
|
|
587
|
+
/* @__PURE__ */ jsxs("span", { className: "min-w-0 flex-1", children: [
|
|
588
|
+
/* @__PURE__ */ jsxs("span", { className: "flex min-w-0 items-center gap-1.5", children: [
|
|
589
|
+
/* @__PURE__ */ jsx("span", { className: "truncate text-sm font-semibold text-foreground", children: name }),
|
|
590
|
+
badge
|
|
591
|
+
] }),
|
|
592
|
+
/* @__PURE__ */ jsxs("span", { className: "flex min-w-0 items-center gap-1.5", children: [
|
|
593
|
+
presence,
|
|
594
|
+
presence && /* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: "\xB7" }),
|
|
595
|
+
/* @__PURE__ */ jsx("span", { className: "min-w-0 truncate text-xs text-muted-foreground", children: email ?? "" })
|
|
596
|
+
] })
|
|
597
|
+
] })
|
|
598
|
+
] }),
|
|
599
|
+
menu
|
|
600
|
+
]
|
|
601
|
+
}
|
|
602
|
+
);
|
|
603
|
+
}
|
|
604
|
+
var DEFAULT_DM_ACCESS_REQUEST_BANNER_LABELS = {
|
|
605
|
+
requestedAccess: " requested workspace access",
|
|
606
|
+
review: "Review"
|
|
607
|
+
};
|
|
608
|
+
var DEFAULT_DM_THREAD_FRAME_LABELS = {
|
|
609
|
+
noMessages: "No messages yet \u2014 say hi \u{1F44B}"
|
|
610
|
+
};
|
|
611
|
+
var DEFAULT_DM_GRANT_ACCESS_DIALOG_LABELS = {
|
|
612
|
+
title: "Grant workspace access",
|
|
613
|
+
description: (peerName) => `Give ${peerName} access to one of your workspaces. Access is permanent until you remove it.`,
|
|
614
|
+
noWorkspace: "Open the workspace you want to share, as its owner, and you can grant access to it from here.",
|
|
615
|
+
workspace: "Workspace",
|
|
616
|
+
role: "Role",
|
|
617
|
+
cancel: "Cancel",
|
|
618
|
+
grantAccess: "Grant access"
|
|
619
|
+
};
|
|
620
|
+
var DEFAULT_RECIPIENT_PICKER_LABELS = {
|
|
621
|
+
to: "To",
|
|
622
|
+
unmuteNotifications: "Unmute notifications",
|
|
623
|
+
muteNotifications: "Mute notifications",
|
|
624
|
+
removeRecipient: "Remove recipient",
|
|
625
|
+
selectRecipient: "Select recipient...",
|
|
626
|
+
addRecipient: "Add recipient",
|
|
627
|
+
searchUsers: "Search users...",
|
|
628
|
+
noKnownUsers: "No known users",
|
|
629
|
+
noMatchingUsers: "No matching users",
|
|
630
|
+
addContactsHint: "Add contacts or join workspaces to send private messages"
|
|
631
|
+
};
|
|
632
|
+
function ActionMenu({ label, testId, entries, contentClassName = "w-56" }) {
|
|
633
|
+
return /* @__PURE__ */ jsxs(DropdownMenu, { children: [
|
|
634
|
+
/* @__PURE__ */ jsx(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ jsx(
|
|
635
|
+
Button,
|
|
636
|
+
{
|
|
637
|
+
variant: "ghost",
|
|
638
|
+
size: "icon",
|
|
639
|
+
className: "size-7 shrink-0 text-muted-foreground hover:text-foreground pointer-coarse:size-11",
|
|
640
|
+
"aria-label": label,
|
|
641
|
+
"data-testid": testId,
|
|
642
|
+
onClick: (e) => e.stopPropagation(),
|
|
643
|
+
children: /* @__PURE__ */ jsx(MoreVertical, { className: "size-4" })
|
|
644
|
+
}
|
|
645
|
+
) }),
|
|
646
|
+
/* @__PURE__ */ jsx(DropdownMenuContent, { align: "end", className: contentClassName, children: entries.map(
|
|
647
|
+
(entry) => "separator" in entry ? /* @__PURE__ */ jsx(DropdownMenuSeparator, {}, entry.id) : /* @__PURE__ */ jsxs(
|
|
648
|
+
DropdownMenuItem,
|
|
649
|
+
{
|
|
650
|
+
onClick: entry.onSelect,
|
|
651
|
+
className: entry.destructive ? "text-destructive focus:text-destructive" : void 0,
|
|
652
|
+
"data-testid": entry.testId,
|
|
653
|
+
children: [
|
|
654
|
+
entry.icon && /* @__PURE__ */ jsx("span", { className: "mr-2 inline-flex size-4 items-center", children: entry.icon }),
|
|
655
|
+
entry.label
|
|
656
|
+
]
|
|
657
|
+
},
|
|
658
|
+
entry.id
|
|
659
|
+
)
|
|
660
|
+
) })
|
|
661
|
+
] });
|
|
662
|
+
}
|
|
663
|
+
function DmInviteAvatar() {
|
|
664
|
+
return /* @__PURE__ */ jsx("span", { className: "flex size-9 shrink-0 items-center justify-center rounded-full bg-muted text-muted-foreground", children: /* @__PURE__ */ jsx(AtSign, { className: "size-4" }) });
|
|
665
|
+
}
|
|
666
|
+
function DmNewTabIcon() {
|
|
667
|
+
return /* @__PURE__ */ jsx("div", { className: "flex h-5 w-5 items-center justify-center rounded-full bg-primary/10", children: /* @__PURE__ */ jsx(Plus, { className: "h-3 w-3 text-primary" }) });
|
|
668
|
+
}
|
|
669
|
+
function DmAccessRequestBanner({
|
|
670
|
+
name,
|
|
671
|
+
onReview,
|
|
672
|
+
labels
|
|
673
|
+
}) {
|
|
674
|
+
const l = useMemo(() => ({ ...DEFAULT_DM_ACCESS_REQUEST_BANNER_LABELS, ...labels }), [labels]);
|
|
675
|
+
return /* @__PURE__ */ jsxs("div", { className: "mx-4 mt-3 flex items-center gap-3 rounded-lg bg-muted px-3 py-2.5", children: [
|
|
676
|
+
/* @__PURE__ */ jsx(KeyRound, { className: "h-4 w-4 shrink-0 text-primary" }),
|
|
677
|
+
/* @__PURE__ */ jsxs("span", { className: "min-w-0 flex-1 text-sm text-foreground", children: [
|
|
678
|
+
/* @__PURE__ */ jsx("span", { className: "font-medium", children: name }),
|
|
679
|
+
l.requestedAccess
|
|
680
|
+
] }),
|
|
681
|
+
/* @__PURE__ */ jsx(Button, { size: "sm", onClick: onReview, "data-testid": "dm-review-access-button", children: l.review })
|
|
682
|
+
] });
|
|
683
|
+
}
|
|
684
|
+
function DmThreadFrame({
|
|
685
|
+
recipientPicker,
|
|
686
|
+
accessBanner,
|
|
687
|
+
hasRecipient,
|
|
688
|
+
isLoading,
|
|
689
|
+
history,
|
|
690
|
+
isEmpty,
|
|
691
|
+
noRecipientPrompt,
|
|
692
|
+
historyRef,
|
|
693
|
+
composer,
|
|
694
|
+
labels
|
|
695
|
+
}) {
|
|
696
|
+
const l = useMemo(() => ({ ...DEFAULT_DM_THREAD_FRAME_LABELS, ...labels }), [labels]);
|
|
697
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex h-full flex-col bg-background", children: [
|
|
698
|
+
recipientPicker,
|
|
699
|
+
accessBanner,
|
|
700
|
+
hasRecipient && /* @__PURE__ */ jsx("div", { className: "min-h-0 flex-1 overflow-hidden bg-background", ref: historyRef, children: /* @__PURE__ */ jsx(ScrollArea, { className: "h-full", children: /* @__PURE__ */ jsx("div", { className: "px-4 py-3", children: isLoading ? /* @__PURE__ */ jsx("div", { className: "flex h-32 items-center justify-center", children: /* @__PURE__ */ jsx(Loader2, { className: "h-6 w-6 animate-spin text-muted-foreground" }) }) : !isEmpty ? history : /* @__PURE__ */ jsx("div", { className: "flex h-32 items-center justify-center text-sm text-muted-foreground", children: l.noMessages }) }) }) }),
|
|
701
|
+
!hasRecipient && noRecipientPrompt && /* @__PURE__ */ jsx("div", { className: "flex min-h-0 flex-1 items-center justify-center bg-background p-4", children: /* @__PURE__ */ jsx("p", { className: "text-center text-sm text-muted-foreground", children: noRecipientPrompt }) }),
|
|
702
|
+
/* @__PURE__ */ jsx("div", { className: "shrink-0", children: composer })
|
|
703
|
+
] });
|
|
704
|
+
}
|
|
705
|
+
function DmGrantAccessDialogView({
|
|
706
|
+
open,
|
|
707
|
+
onOpenChange,
|
|
708
|
+
peerName,
|
|
709
|
+
workspaceName,
|
|
710
|
+
role,
|
|
711
|
+
onRoleChange,
|
|
712
|
+
roles,
|
|
713
|
+
isGranting,
|
|
714
|
+
onGrant,
|
|
715
|
+
labels
|
|
716
|
+
}) {
|
|
717
|
+
const l = useMemo(() => ({ ...DEFAULT_DM_GRANT_ACCESS_DIALOG_LABELS, ...labels }), [labels]);
|
|
718
|
+
return /* @__PURE__ */ jsx(Dialog, { open, onOpenChange, children: /* @__PURE__ */ jsxs(DialogContent, { presentation: "sheet", "data-testid": "dm-grant-access-modal", children: [
|
|
719
|
+
/* @__PURE__ */ jsxs(DialogHeader, { children: [
|
|
720
|
+
/* @__PURE__ */ jsx(DialogTitle, { children: l.title }),
|
|
721
|
+
/* @__PURE__ */ jsx(DialogDescription, { children: l.description(peerName) })
|
|
722
|
+
] }),
|
|
723
|
+
workspaceName === null ? /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground", "data-testid": "dm-grant-none", children: l.noWorkspace }) : /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
|
|
724
|
+
/* @__PURE__ */ jsxs("div", { className: "space-y-1.5", children: [
|
|
725
|
+
/* @__PURE__ */ jsx("label", { className: "text-sm font-medium", children: l.workspace }),
|
|
726
|
+
/* @__PURE__ */ jsx("p", { className: "rounded-lg bg-muted px-3 py-2 text-sm", "data-testid": "dm-grant-workspace", children: workspaceName })
|
|
727
|
+
] }),
|
|
728
|
+
/* @__PURE__ */ jsxs("div", { className: "space-y-1.5", children: [
|
|
729
|
+
/* @__PURE__ */ jsx("label", { className: "text-sm font-medium", children: l.role }),
|
|
730
|
+
/* @__PURE__ */ jsxs(Select, { value: role, onValueChange: onRoleChange, children: [
|
|
731
|
+
/* @__PURE__ */ jsx(SelectTrigger, { "data-testid": "dm-grant-role", children: /* @__PURE__ */ jsx(SelectValue, {}) }),
|
|
732
|
+
/* @__PURE__ */ jsx(SelectContent, { children: roles.map((r) => /* @__PURE__ */ jsxs(SelectItem, { value: r.value, children: [
|
|
733
|
+
r.label,
|
|
734
|
+
" \u2014 ",
|
|
735
|
+
r.hint
|
|
736
|
+
] }, r.value)) })
|
|
737
|
+
] })
|
|
738
|
+
] })
|
|
739
|
+
] }),
|
|
740
|
+
/* @__PURE__ */ jsxs(DialogFooter, { children: [
|
|
741
|
+
/* @__PURE__ */ jsx(Button, { variant: "ghost", onClick: () => onOpenChange(false), disabled: isGranting, children: l.cancel }),
|
|
742
|
+
/* @__PURE__ */ jsxs(
|
|
743
|
+
Button,
|
|
744
|
+
{
|
|
745
|
+
onClick: onGrant,
|
|
746
|
+
disabled: isGranting || workspaceName === null,
|
|
747
|
+
"data-testid": "dm-grant-submit",
|
|
748
|
+
children: [
|
|
749
|
+
isGranting && /* @__PURE__ */ jsx(Loader2, { className: "mr-2 size-4 animate-spin" }),
|
|
750
|
+
l.grantAccess
|
|
751
|
+
]
|
|
752
|
+
}
|
|
753
|
+
)
|
|
754
|
+
] })
|
|
755
|
+
] }) });
|
|
756
|
+
}
|
|
757
|
+
function RecipientPicker({
|
|
758
|
+
selected,
|
|
759
|
+
onRemove,
|
|
760
|
+
candidates,
|
|
761
|
+
onPick,
|
|
762
|
+
canAdd,
|
|
763
|
+
isOpen,
|
|
764
|
+
onOpenChange,
|
|
765
|
+
search,
|
|
766
|
+
onSearchChange,
|
|
767
|
+
hasNoKnownUsers,
|
|
768
|
+
labels
|
|
769
|
+
}) {
|
|
770
|
+
const l = useMemo(() => ({ ...DEFAULT_RECIPIENT_PICKER_LABELS, ...labels }), [labels]);
|
|
771
|
+
return /* @__PURE__ */ jsx("div", { className: "shrink-0 border-b px-6 py-4", children: /* @__PURE__ */ jsxs("div", { className: "flex items-start gap-3", children: [
|
|
772
|
+
/* @__PURE__ */ jsx(ModalSectionTitle, { className: "mb-0 shrink-0 py-1.5", children: l.to }),
|
|
773
|
+
/* @__PURE__ */ jsxs("div", { className: "flex flex-1 flex-col gap-1.5", children: [
|
|
774
|
+
selected.map((recipient) => /* @__PURE__ */ jsxs(
|
|
775
|
+
"div",
|
|
776
|
+
{
|
|
777
|
+
className: "flex items-center justify-between gap-2 rounded-md bg-muted/50 px-3 py-1.5",
|
|
778
|
+
children: [
|
|
779
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
780
|
+
recipient.identity,
|
|
781
|
+
/* @__PURE__ */ jsxs(Tooltip, { children: [
|
|
782
|
+
/* @__PURE__ */ jsx(
|
|
783
|
+
TooltipTrigger,
|
|
784
|
+
{
|
|
785
|
+
onClick: recipient.onToggleMute,
|
|
786
|
+
"aria-label": recipient.isMuted ? l.unmuteNotifications : l.muteNotifications,
|
|
787
|
+
"aria-pressed": recipient.isMuted,
|
|
788
|
+
className: `rounded p-1 transition-colors hover:bg-muted pointer-coarse:p-3 ${recipient.isMuted ? "text-muted-foreground" : "text-muted-foreground/40 hover:text-muted-foreground"}`,
|
|
789
|
+
disabled: recipient.isMuteBusy,
|
|
790
|
+
children: recipient.isMuted ? /* @__PURE__ */ jsx(BellOff, { size: 14, fill: "currentColor" }) : /* @__PURE__ */ jsx(Bell, { size: 14 })
|
|
791
|
+
}
|
|
792
|
+
),
|
|
793
|
+
/* @__PURE__ */ jsx(TooltipContent, { className: "max-w-[250px]", children: recipient.muteTooltip })
|
|
794
|
+
] })
|
|
795
|
+
] }),
|
|
796
|
+
/* @__PURE__ */ jsx(
|
|
797
|
+
"button",
|
|
798
|
+
{
|
|
799
|
+
type: "button",
|
|
800
|
+
onClick: () => onRemove(recipient.id),
|
|
801
|
+
className: "p-1 text-muted-foreground hover:text-destructive pointer-coarse:p-3",
|
|
802
|
+
title: l.removeRecipient,
|
|
803
|
+
"aria-label": l.removeRecipient,
|
|
804
|
+
children: /* @__PURE__ */ jsx(X, { className: "h-4 w-4" })
|
|
805
|
+
}
|
|
806
|
+
)
|
|
807
|
+
]
|
|
808
|
+
},
|
|
809
|
+
recipient.id
|
|
810
|
+
)),
|
|
811
|
+
canAdd && /* @__PURE__ */ jsxs(Popover, { open: isOpen, onOpenChange, children: [
|
|
812
|
+
/* @__PURE__ */ jsx(PopoverTrigger, { asChild: true, children: selected.length === 0 ? /* @__PURE__ */ jsxs(
|
|
813
|
+
Button,
|
|
814
|
+
{
|
|
815
|
+
variant: "outline",
|
|
816
|
+
size: "sm",
|
|
817
|
+
disabled: hasNoKnownUsers,
|
|
818
|
+
className: "w-full justify-start text-muted-foreground",
|
|
819
|
+
children: [
|
|
820
|
+
/* @__PURE__ */ jsx(ChevronsUpDown, { className: "mr-2 h-4 w-4" }),
|
|
821
|
+
l.selectRecipient
|
|
822
|
+
]
|
|
823
|
+
}
|
|
824
|
+
) : /* @__PURE__ */ jsx(
|
|
825
|
+
Button,
|
|
826
|
+
{
|
|
827
|
+
variant: "ghost",
|
|
828
|
+
size: "icon",
|
|
829
|
+
disabled: hasNoKnownUsers,
|
|
830
|
+
className: "h-7 w-7 rounded-full",
|
|
831
|
+
title: l.addRecipient,
|
|
832
|
+
"aria-label": l.addRecipient,
|
|
833
|
+
children: /* @__PURE__ */ jsx(Plus, { className: "h-4 w-4" })
|
|
834
|
+
}
|
|
835
|
+
) }),
|
|
836
|
+
/* @__PURE__ */ jsx(
|
|
837
|
+
PopoverContent,
|
|
838
|
+
{
|
|
839
|
+
className: "w-72 p-0",
|
|
840
|
+
align: "start",
|
|
841
|
+
onPointerDownOutside: (e) => e.preventDefault(),
|
|
842
|
+
children: /* @__PURE__ */ jsxs(Command, { shouldFilter: false, children: [
|
|
843
|
+
/* @__PURE__ */ jsx(
|
|
844
|
+
CommandInput,
|
|
845
|
+
{
|
|
846
|
+
placeholder: l.searchUsers,
|
|
847
|
+
value: search,
|
|
848
|
+
onValueChange: onSearchChange
|
|
849
|
+
}
|
|
850
|
+
),
|
|
851
|
+
/* @__PURE__ */ jsx(CommandList, { children: candidates.length === 0 ? /* @__PURE__ */ jsx(CommandEmpty, { children: hasNoKnownUsers ? l.noKnownUsers : l.noMatchingUsers }) : /* @__PURE__ */ jsx(CommandGroup, { children: candidates.map((candidate) => /* @__PURE__ */ jsx(
|
|
852
|
+
CommandItem,
|
|
853
|
+
{
|
|
854
|
+
onSelect: () => onPick(candidate.id),
|
|
855
|
+
className: "cursor-pointer justify-start",
|
|
856
|
+
children: candidate.identity
|
|
857
|
+
},
|
|
858
|
+
candidate.id
|
|
859
|
+
)) }) })
|
|
860
|
+
] })
|
|
861
|
+
}
|
|
862
|
+
)
|
|
863
|
+
] }),
|
|
864
|
+
hasNoKnownUsers && /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground", children: l.addContactsHint })
|
|
865
|
+
] })
|
|
866
|
+
] }) });
|
|
867
|
+
}
|
|
868
|
+
|
|
160
869
|
// src/collaboration/mail/mailFolders.ts
|
|
161
870
|
var isInboxFolder = (f) => f.id === "INBOX" || /^inbox$/i.test(f.name);
|
|
162
871
|
function buildMailFolderTree(folders) {
|
|
@@ -915,6 +1624,6 @@ function PlainMailBodyEditor({ text, disabled, onChange }) {
|
|
|
915
1624
|
);
|
|
916
1625
|
}
|
|
917
1626
|
|
|
918
|
-
export { DEFAULT_MAIL_FOLDER_TREE_LABELS, MailDeliveryBadge, MailDeliveryList, MailDocumentPicker, MailFolderTree, MailGrid, MailMessagePreview, MailMessageView, MemberBulkActions, MemberListLoading, MemberMutedText, MemberNameCell, MemberRoleCell, NEEDS_CONNECTION, PlainMailBodyEditor, RoleSelect, WorkspaceDeleteButton, buildMailFolderTree, descendantFolderIds, draftMailCompose, emptyMailCompose, hasCalendarPart, isInboxFolder, mailAddressLabel, parseMailRecipients, replyMailCompose, toggleMailFolder };
|
|
919
|
-
//# sourceMappingURL=chunk-
|
|
920
|
-
//# sourceMappingURL=chunk-
|
|
1627
|
+
export { ActionMenu, AddContactsForm, AddContactsResults, DEFAULT_ADD_CONTACTS_LABELS, DEFAULT_CONTACT_INVITE_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, EMPTY_CONTACT_FORM, MAX_INVITE_EMAILS, MailDeliveryBadge, MailDeliveryList, MailDocumentPicker, MailFolderTree, MailGrid, MailMessagePreview, MailMessageView, MemberBulkActions, MemberListLoading, MemberMutedText, MemberNameCell, MemberRoleCell, NEEDS_CONNECTION, PlainMailBodyEditor, RecipientPicker, RoleSelect, WorkspaceDeleteButton, applyContactInviteResults, buildMailFolderTree, contactName, contactOutcomeMessage, contactStatusLabel, contactToForm, descendantFolderIds, draftMailCompose, emailTokens, emptyMailCompose, failContactInvites, formToContactCard, hasCalendarPart, inviteEmail, isInboxFolder, isInvitableEmail, mailAddressLabel, matchesContact, normalizeVCardDate, parseEmails, parseMailRecipients, planContactInvites, primaryEmail, replyMailCompose, summarizeContactInvites, summarizeImport, summarizeUnsentInvites, toAddContactsRow, toAddContactsRows, toggleMailFolder, validateContactForm };
|
|
1628
|
+
//# sourceMappingURL=chunk-SQQU3WRB.js.map
|
|
1629
|
+
//# sourceMappingURL=chunk-SQQU3WRB.js.map
|