@arbidocs/react 0.5.164 → 0.5.166
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ai/MessageArtifactCard.js +16 -0
- package/dist/ai/MessageArtifactCard.js.map +2 -2
- package/dist/artifacts/artifact-kind.js +12 -1
- package/dist/artifacts/artifact-kind.js.map +2 -2
- package/dist/artifacts/index.cjs +26 -15
- package/dist/artifacts/index.cjs.map +1 -1
- package/dist/artifacts/index.d.ts +3 -20
- package/dist/artifacts/index.js +3 -1
- package/dist/artifacts/index.js.map +2 -2
- package/dist/calls/livekit/index.cjs +48 -48
- package/dist/chat/ChatBubble.js +56 -65
- package/dist/chat/ChatBubble.js.map +2 -2
- package/dist/chat/open-document.js +4 -1
- package/dist/chat/open-document.js.map +2 -2
- package/dist/{chunk-6HJZCIND.cjs → chunk-3DPOR5IR.cjs} +6 -3
- package/dist/chunk-3DPOR5IR.cjs.map +1 -0
- package/dist/{chunk-42X5ZO7Y.cjs → chunk-4TWXQFHU.cjs} +69 -69
- package/dist/{chunk-42X5ZO7Y.cjs.map → chunk-4TWXQFHU.cjs.map} +1 -1
- package/dist/{chunk-ZZBCZRA5.cjs → chunk-5QOZLKAY.cjs} +5 -2
- package/dist/chunk-5QOZLKAY.cjs.map +1 -0
- package/dist/{chunk-SUMXDNYG.cjs → chunk-BI4SYRLX.cjs} +70 -63
- package/dist/chunk-BI4SYRLX.cjs.map +1 -0
- package/dist/{chunk-ZBI5AMZC.cjs → chunk-HRQS27DO.cjs} +37 -37
- package/dist/{chunk-ZBI5AMZC.cjs.map → chunk-HRQS27DO.cjs.map} +1 -1
- package/dist/{chunk-V5WCKJEH.cjs → chunk-Q7BGWKHP.cjs} +44 -44
- package/dist/{chunk-V5WCKJEH.cjs.map → chunk-Q7BGWKHP.cjs.map} +1 -1
- package/dist/{chunk-6TJL4Z2F.cjs → chunk-TX7UCN73.cjs} +10 -10
- package/dist/{chunk-6TJL4Z2F.cjs.map → chunk-TX7UCN73.cjs.map} +1 -1
- package/dist/{chunk-WJIRX5MS.cjs → chunk-W4W75MSO.cjs} +134 -25
- package/dist/chunk-W4W75MSO.cjs.map +1 -0
- package/dist/chunk-WABJGKVA.cjs +246 -0
- package/dist/chunk-WABJGKVA.cjs.map +1 -0
- package/dist/databases.js.map +2 -2
- package/dist/directmessages/DmComposer.js +26 -10
- package/dist/directmessages/DmComposer.js.map +2 -2
- package/dist/directmessages/index.js +2 -0
- package/dist/directmessages/index.js.map +2 -2
- package/dist/directmessages/useChats.js +11 -0
- package/dist/directmessages/useChats.js.map +2 -2
- package/dist/document-tools/core.cjs +100 -100
- package/dist/document-tools/core.d.ts +2 -2
- package/dist/document-tools/index.cjs +102 -102
- package/dist/document-tools/index.d.ts +2 -2
- package/dist/entities/DocumentEntity.js +8 -3
- package/dist/entities/DocumentEntity.js.map +2 -2
- package/dist/entities/EntityActionsMenu.js +53 -0
- package/dist/entities/EntityActionsMenu.js.map +7 -0
- package/dist/entities/EntityPill.js +50 -16
- package/dist/entities/EntityPill.js.map +2 -2
- package/dist/entities/ProjectEntity.js +4 -0
- package/dist/entities/ProjectEntity.js.map +2 -2
- package/dist/entities/TagEntity.js +1 -0
- package/dist/entities/TagEntity.js.map +2 -2
- package/dist/entities/UserEntity.js +25 -3
- package/dist/entities/UserEntity.js.map +2 -2
- package/dist/entities/links.js +9 -0
- package/dist/entities/links.js.map +7 -0
- package/dist/entities/reference-data.js +56 -0
- package/dist/entities/reference-data.js.map +7 -0
- package/dist/{file-shares.d-Bwy9k3Db.d.ts → file-shares.d-Dlt7pKRi.d.ts} +3 -0
- package/dist/host/config.js.map +2 -2
- package/dist/index.cjs +1836 -1748
- package/dist/index.cjs.map +1 -1
- package/dist/{index.d-Dy_Pz6Vl.d.ts → index.d-BaZUctD1.d.ts} +34 -10
- package/dist/index.d.ts +164 -20
- package/dist/index.js +5 -0
- package/dist/index.js.map +2 -2
- package/dist/query-keys.js +3 -0
- package/dist/query-keys.js.map +2 -2
- package/dist/session/conversation-panels.js +5 -3
- package/dist/session/conversation-panels.js.map +2 -2
- package/dist/session/layout.js +5 -0
- package/dist/session/layout.js.map +2 -2
- package/dist/shell/index.cjs +37 -37
- package/dist/{stored-markdown.d-Bp18vrbr.d.ts → stored-markdown.d-BLQPny3e.d.ts} +21 -1
- package/dist/ui/index.cjs +155 -151
- package/dist/ui/index.d.ts +1 -1
- package/dist/ui/index.js +2 -0
- package/dist/ui/index.js.map +2 -2
- package/dist/viewers/AudioViewer.js +13 -3
- package/dist/viewers/AudioViewer.js.map +2 -2
- package/dist/viewers/MediaTranscriptPlayer.js +171 -0
- package/dist/viewers/MediaTranscriptPlayer.js.map +7 -0
- package/dist/viewers/VideoViewer.js +4 -11
- package/dist/viewers/VideoViewer.js.map +2 -2
- package/dist/viewers/index.cjs +8 -4
- package/dist/viewers/index.d.ts +17 -3
- package/dist/viewers/index.js +2 -0
- package/dist/viewers/index.js.map +2 -2
- package/package.json +3 -3
- package/dist/chunk-6HJZCIND.cjs.map +0 -1
- package/dist/chunk-SUMXDNYG.cjs.map +0 -1
- package/dist/chunk-TMPDW7J5.cjs +0 -79
- package/dist/chunk-TMPDW7J5.cjs.map +0 -1
- package/dist/chunk-WJIRX5MS.cjs.map +0 -1
- package/dist/chunk-ZZBCZRA5.cjs.map +0 -1
|
@@ -21,6 +21,8 @@ function useDeploymentDomain() {
|
|
|
21
21
|
|
|
22
22
|
// src/query-keys.ts
|
|
23
23
|
var arbiQueryKeys = {
|
|
24
|
+
entityReference: (workspaceId, id) => ["arbi", "entity-reference", workspaceId ?? null, id],
|
|
25
|
+
referenceDocuments: (workspaceId) => ["arbi", "documents", workspaceId, "reference"],
|
|
24
26
|
fileShares: () => ["arbi", "fileShares"],
|
|
25
27
|
fileShare: (id) => ["arbi", "fileShare", id],
|
|
26
28
|
fileSharePdf: (id, status) => ["arbi", "fileSharePdf", id, status],
|
|
@@ -115,6 +117,7 @@ var arbiQueryKeys = {
|
|
|
115
117
|
/** One thread's loaded messages, decrypted, oldest first (`ChatThreadData`). */
|
|
116
118
|
chatThread: (chatExtId) => ["arbi", "chats", "thread", chatExtId],
|
|
117
119
|
/** My own agent's progress on my last message to it (`agent_dm_status`), per agent. */
|
|
120
|
+
agentDmProgress: (ownerId, responseId) => ["arbi", "chats", "agentProgress", ownerId, responseId],
|
|
118
121
|
agentDmStatus: (agentExtId) => ["arbi", "chats", "agentStatus", agentExtId],
|
|
119
122
|
/** The paid features this person may use (`/v1/user/entitlements`). */
|
|
120
123
|
entitlements: () => ["arbi", "entitlements"],
|
|
@@ -381,5 +384,5 @@ exports.mailQueryKeys = mailQueryKeys;
|
|
|
381
384
|
exports.useArbi = useArbi;
|
|
382
385
|
exports.useArbiHost = useArbiHost;
|
|
383
386
|
exports.useDeploymentDomain = useDeploymentDomain;
|
|
384
|
-
//# sourceMappingURL=chunk-
|
|
385
|
-
//# sourceMappingURL=chunk-
|
|
387
|
+
//# sourceMappingURL=chunk-5QOZLKAY.cjs.map
|
|
388
|
+
//# sourceMappingURL=chunk-5QOZLKAY.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/host/config.ts","../src/useArbi.ts","../src/query-keys.ts"],"names":["useContext","ArbiHostContext"],"mappings":";;;;;AA+HO,SAAS,WAAA,GAA8B;AAC5C,EAAA,OAAOA,iBAAWC,iCAAe,CAAA;AACnC;;;AC1HO,SAAS,OAAA,GAAgB;AAC9B,EAAA,MAAM,EAAE,IAAA,EAAK,GAAI,WAAA,EAAY;AAC7B,EAAA,IAAI,CAAC,IAAA,EAAM;AACT,IAAA,MAAM,IAAI,MAAM,0DAA0D,CAAA;AAAA,EAC5E;AACA,EAAA,OAAO,IAAA;AACT;AAOO,SAAS,mBAAA,GAA0C;AACxD,EAAA,OAAO,WAAA,EAAY,CAAE,IAAA,EAAM,mBAAA,EAAoB;AACjD;;;ACNO,IAAM,aAAA,GAAgB;AAAA,EAC3B,eAAA,EAAiB,CAAC,WAAA,EA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AQ,MAAA,EAAQ,QAAA,EAAU,SAAA,EAAW,WAAW,IAAA,CAAK,GAAG,GAAG,SAAA,CAAU,IAAA,CAAK,GAAG,CAAC,CAAA;AAAA;AAAA;AAAA,EAGjF,YAAA,EAAc,MAAM,CAAC,MAAA,EAAQ,oBAAoB,CAAA;AAAA;AAAA,EAEjD,QAAA,EAAU,MAAM,CAAC,MAAA,EAAQ,QAAQ,UAAU,CAAA;AAAA;AAAA,EAE3C,YAAA,EAAc,CAAC,SAAA,EAA+B,OAAA,KAC5C,CAAC,MAAA,EAAQ,MAAA,EAAQ,eAAA,EAAiB,SAAA,EAAW,OAAO,CAAA;AAAA,EACtD,cAAA,EAAgB,CAAC,SAAA,EAAmB,SAAA,EAAmB,YAAA,KACrD,CAAC,MAAA,EAAQ,MAAA,EAAQ,iBAAA,EAAmB,SAAA,EAAW,SAAA,EAAW,YAAY;AAC1E;AAMO,IAAM,mBAAmB,CAC9B,WAAA,EACA,SACA,IAAA,KAEA,OAAA,KAAY,SACP,CAAC,MAAA,EAAQ,eAAA,EAAiB,WAAW,IACrC,CAAC,MAAA,EAAQ,iBAAiB,WAAA,EAAa,OAAA,EAAS,QAAQ,KAAK;AAG7D,SAAS,eAAA,CAAgB,UAA8B,MAAA,EAAqC;AACjG,EAAA,OAAO,MAAA,CAAO,MAAM,CAAC,IAAA,EAAM,MAAM,QAAA,CAAS,CAAC,MAAM,IAAI,CAAA;AACvD","file":"chunk-5QOZLKAY.cjs","sourcesContent":["import type { EntityLinks } from '../entities/links'\n/**\n * What a host hands the `@arbidocs/react` hooks, as one configuration (`<ArbiHost config>`). Every\n * field is optional: without one the hooks use their own default. `@arbidocs/blocks` extends it\n * with the blocks domains (environment, billing, viewer, …).\n *\n * A field whose value lives in the host's state is a hook (`use…`), called by the hooks and kits\n * that need it, so the configuration itself stays one stable object for the host's life.\n */\n\nimport { useContext } from 'react'\nimport type { Arbi } from '@arbidocs/sdk/browser'\nimport type { AccountClient } from '../account/client'\nimport type { CalendarSupport } from '../calendar/support'\nimport type { MeetingChatRef } from '../calls/meeting-chat'\nimport type { ActiveCall } from '../calls/session'\nimport type { ArbiChatHost } from '../chat/host'\nimport type { DocumentsSupport } from '../documents/support'\nimport type { MailClient } from '../mail/client'\nimport type { ArbiSessionStore } from '../session/store'\nimport type { DictateContextValue } from '../ui/DictateContext'\nimport type { EntityVocabulary } from '../entities/vocabulary'\nimport type { ArbiHostConnection } from './ArbiHost'\nimport type { ArbiFeatures } from './features'\nimport { ArbiHostContext } from './context'\nimport type { DashboardsHost } from '../datasets/registry'\n\n/** The mail client, and whether mail is on for the signed-in user. */\nexport interface MailHost {\n client: MailClient\n /**\n * Whether mail reads run (signed in and entitled), and the server session the mailbox is\n * unlocked for: unlocking runs again when it changes (`null`: none yet, nothing is unlocked).\n * Absent: on, for one session.\n */\n useStatus?: () => { enabled: boolean; sessionKey: string | null }\n /**\n * The mail waiting in this device's Outbox (written offline), by status, while `enabled` (Mail\n * switched on); the offline status counts it as waiting work. Absent: no Outbox.\n */\n useOutbox?: (enabled: boolean) => ReadonlyArray<{ status: string }>\n /** The Outbox's folder, opened through `openMail({ folder })`. */\n outboxFolder?: string\n}\n\n/** The account client of the settings kits, and whether account reads run (signed in). */\nexport interface AccountHost {\n client: AccountClient\n /** Absent: always. */\n useEnabled?: () => boolean\n}\n\n/** Where the call panel goes in the host's layout. */\nexport type CallSlotMode = 'docked' | 'main'\n\n/** What the calls need from the host: navigation and layout are the host's. */\nexport interface CallsHost {\n /**\n * Show a call's meeting chat: an end-to-end chat, or a workspace meeting thread. Absent: the\n * in-call \"Open meeting chat\" does nothing.\n */\n openMeetingChat?: (ref: MeetingChatRef) => void\n /**\n * Once connected, show the call's conversation (its chat and live transcript) beside the call.\n * Absent: nothing is shown.\n */\n showConversation?: (call: ActiveCall) => void | Promise<void>\n /**\n * The element whose box the shown call fills: the right-hand dock, or (a webinar's audience) the\n * main area. The host claims its slot while `shown` and calls `onLost` when another panel takes\n * it (the call then minimises). Absent: the call floats at the right edge.\n */\n useSlot?: (mode: CallSlotMode, shown: boolean, onLost: () => void) => HTMLElement | null\n}\n\nexport interface ArbiHostConfig {\n /** Canonical links used by entity reference menus. */\n entities?: EntityLinks\n /**\n * The SDK on the signed-in session. A host with its own login passes one on its session\n * (`new Arbi({ url, session })`); a blocks-only site gets one from `defaultHost`. A new instance (a\n * new session, a newly opened workspace) re-renders every hook.\n */\n arbi?: Arbi\n /** The session state the kits share. Absent: an in-memory one per top-level host. */\n session?: ArbiSessionStore\n /** Live processing, uploads and the host's document actions. Absent: the package's own. */\n documents?: DocumentsSupport\n /** The calendar kept on this device and account OAuth. Absent: online only, the user's connectors. */\n calendar?: CalendarSupport\n /** Absent: mail on the `arbi` session. */\n mail?: MailHost\n /** Absent: the account on the `arbi` session. */\n account?: AccountHost\n /** Absent: calls open no meeting chat from the room. */\n calls?: CallsHost\n /**\n * The parts of the product the user switches on or off, and where each switch is kept (the user's\n * settings, or this device), read with `useFeature(name)`. The call UI also follows the `calls`\n * feature, on top of the server's calls config. Absent, or a feature not listed: on.\n */\n features?: ArbiFeatures\n /** Dictation for every `dictate` field. Absent: no mic button. */\n dictate?: DictateContextValue\n /** The sign-in layer of a blocks-only site (`defaultHost` in `@arbidocs/blocks/connect`). */\n connection?: ArbiHostConnection\n /** Where the chat engine's side effects go (documents shown, mail drafts, used-up quota). */\n chat?: ArbiChatHost\n /**\n * The site's words for the entities (`{ PROJECT: 'Matter' }`), read by every kit through\n * `getEntityLabel`. Absent: the registry's (\"Project\", \"Workspace\", \"Thread\", …).\n */\n vocabulary?: EntityVocabulary\n /**\n * What the site calls its assistant where people address it: the `@<name>` offered in a chat's\n * mention menu, the draft a shared thread starts with, and the name a message is routed to the\n * assistant on. Absent: \"ARBI\".\n */\n assistantName?: string\n /**\n * Charts and dashboards: more data sources (an external feed, a source relabelled in the site's\n * words). Pages themselves are the workspace's (`/v1/pages`). Absent: the built-in sources.\n */\n dashboards?: DashboardsHost\n}\n\n/** The host configuration in scope (`{}` outside an `<ArbiHost>`). */\nexport function useArbiHost(): ArbiHostConfig {\n return useContext(ArbiHostContext) as ArbiHostConfig\n}\n","/**\n * The `Arbi` of the host configuration (`<ArbiHost config={{ arbi }}>`).\n */\n\nimport type { Arbi } from '@arbidocs/sdk/browser'\nimport { useArbiHost } from './host/config'\n\nexport function useArbi(): Arbi {\n const { arbi } = useArbiHost()\n if (!arbi) {\n throw new Error('useArbi() needs an <ArbiHost> whose config has an `arbi`')\n }\n return arbi\n}\n\n/**\n * The deployment domain the user's keys are derived for, as the host's `Arbi` computes it\n * (`deploymentDomain`, else the API URL's hostname). `undefined` without one. The document tools\n * default their `deploymentDomain` (needed for e-signing) to it.\n */\nexport function useDeploymentDomain(): string | undefined {\n return useArbiHost().arbi?.getDeploymentDomain()\n}\n","/**\n * The one query-key factory of the ARBI front end: every React Query key and mutation key the\n * packages and the app use is built here, under `['arbi', …]`. Literal key arrays anywhere else\n * fail the `arbi/query-keys-from-factory` lint rule and `query-keys.guard.test.ts`, so a key can't\n * drift from the queries it names (a stale literal reads or invalidates nothing, silently).\n *\n * Dependency-free on purpose (types only): e2e helpers import it and pass keys into the page.\n */\n\nimport type {\n CalendarWindow,\n ListEventsParams,\n OverlayLayerName,\n RoomQuery,\n} from '@arbidocs/sdk/browser'\n\nexport const arbiQueryKeys = {\n entityReference: (workspaceId: string | null | undefined, id: string) =>\n ['arbi', 'entity-reference', workspaceId ?? null, id] as const,\n referenceDocuments: (workspaceId: string) =>\n ['arbi', 'documents', workspaceId, 'reference'] as const,\n fileShares: () => ['arbi', 'fileShares'] as const,\n fileShare: (id: string) => ['arbi', 'fileShare', id] as const,\n fileSharePdf: (id: string, status?: string) => ['arbi', 'fileSharePdf', id, status] as const,\n workspaces: () => ['arbi', 'workspaces'] as const,\n /** Every workspace's member list: what a workspace switch drops. */\n allWorkspaceUsers: () => ['arbi', 'workspaceUsers'] as const,\n workspaceUsers: (workspaceId: string) => ['arbi', 'workspaceUsers', workspaceId] as const,\n /** Every workspace's documents list: the prefix a write patches when it does not know the workspace. */\n allDocuments: () => ['arbi', 'documents'] as const,\n documents: (workspaceId: string) => ['arbi', 'documents', workspaceId] as const,\n /** One document (a viewer's); writes keep it current next to the list. */\n document: (docId: string) => ['arbi', 'document', docId] as const,\n documentsById: (docIds: string[]) =>\n ['arbi', 'documentsById', [...docIds].sort().join(',')] as const,\n /** Every workspace's near-duplicate pairs. */\n allSimilarDocuments: () => ['arbi', 'similarDocuments'] as const,\n similarDocuments: (workspaceId: string, threshold: number) =>\n ['arbi', 'similarDocuments', workspaceId, threshold] as const,\n /** Every version list: the prefix a new version invalidates. */\n allDocumentVersions: () => ['arbi', 'documentVersions'] as const,\n documentVersions: (docId: string) => ['arbi', 'documentVersions', docId] as const,\n conversations: (workspaceId: string) => ['arbi', 'conversations', workspaceId] as const,\n /** Every workspace's conversation list (and threads): the prefix a conversation write invalidates. */\n allConversations: () => ['arbi', 'conversations'] as const,\n /** A conversation's threads, under the conversations prefix (ids are unique across workspaces). */\n conversationThreads: (conversationId: string) =>\n ['arbi', 'conversations', conversationId, 'threads'] as const,\n /** One stored message with everything the server keeps on it (its trace and metadata). */\n messageDetails: (messageId: string) => ['arbi', 'messageDetails', messageId] as const,\n /** The backend's built-in slash commands. */\n assistantCommands: () => ['arbi', 'assistantCommands'] as const,\n /** Every workspace's tags (lists, tables and kinds): what a cross-workspace change refreshes. */\n allTags: () => ['arbi', 'tags'] as const,\n tags: (workspaceId: string) => ['arbi', 'tags', workspaceId] as const,\n /** Under the workspace's tags: the kinds' fields (refreshed with the tags). */\n tagKinds: (workspaceId: string) => ['arbi', 'tags', workspaceId, 'kinds'] as const,\n /** Every filtered list (a table of tags): what a tag write refreshes, the whole list aside. */\n tagLists: (workspaceId: string) => ['arbi', 'tags', workspaceId, 'list'] as const,\n /** Under the workspace's tags: a tag, doctag or fact write that invalidates `tags` refreshes it. */\n tagList: (workspaceId: string, query: string) =>\n ['arbi', 'tags', workspaceId, 'list', query] as const,\n /** A kind's fields, under the workspace's tags. */\n tagKind: (workspaceId: string, kind: string) =>\n ['arbi', 'tags', workspaceId, 'kind', kind] as const,\n /** A task's history, under the conversations prefix: every conversation write refreshes it. */\n conversationActivity: (conversationId: string) =>\n ['arbi', 'conversations', conversationId, 'activity'] as const,\n thumbnails: (docIds: string[]) => ['arbi', 'thumbnails', [...docIds].sort().join(',')] as const,\n /** Every stage of a document's parsed content. */\n parsedDocument: (docId: string) => ['arbi', 'parsedDoc', docId] as const,\n parsedDoc: (docId: string, stage: string) => ['arbi', 'parsedDoc', docId, stage] as const,\n agents: () => ['arbi', 'agents'] as const,\n sessions: () => ['arbi', 'sessions'] as const,\n health: () => ['arbi', 'health'] as const,\n workflows: () => ['arbi', 'workflows'] as const,\n /** Under `workflows()`: a workflow write or run refreshes its runs too. */\n workflowRuns: (workflowId: string) => ['arbi', 'workflows', workflowId, 'runs'] as const,\n /** Under `workflows()`: one workflow with its steps. */\n workflow: (workflowId: string) => ['arbi', 'workflows', workflowId] as const,\n /** Every workspace's facts: the prefix a fact write invalidates. */\n allFacts: () => ['arbi', 'facts'] as const,\n facts: (workspaceId: string) => ['arbi', 'facts', workspaceId] as const,\n configs: () => ['arbi', 'configs'] as const,\n activity: () => ['arbi', 'activity'] as const,\n /** Every transfer query (jobs, lists, plans): what a finished job refreshes. */\n allWorkspaceTransfers: () => ['arbi', 'workspaceTransfers'] as const,\n /** The caller's recent transfer jobs out of a workspace. */\n workspaceTransfers: (workspaceId: string) =>\n ['arbi', 'workspaceTransfers', 'list', workspaceId] as const,\n /** One transfer job's progress. */\n workspaceTransfer: (transferId: string) =>\n ['arbi', 'workspaceTransfers', 'job', transferId] as const,\n /** One job's full ledger (read once it has finished). */\n workspaceTransferItems: (transferId: string) =>\n ['arbi', 'workspaceTransfers', 'items', transferId] as const,\n /** What a scope (serialised) would take in a workspace, for a mode. */\n workspaceTransferPlan: (workspaceId: string, scope: string, mode: string) =>\n ['arbi', 'workspaceTransfers', 'plan', workspaceId, scope, mode] as const,\n /**\n * A workspace's activity feed (all its pages), read `limit` entries a page (absent: the server's\n * default): each page size is its own entry, under the workspace's key.\n */\n workspaceActivity: (workspaceId: string, limit?: number) =>\n limit === undefined\n ? (['arbi', 'workspaceActivity', workspaceId] as const)\n : (['arbi', 'workspaceActivity', workspaceId, limit] as const),\n projects: () => ['arbi', 'projects'] as const,\n projectUsage: (projectExtId: string, monthsBack: number) =>\n ['arbi', 'projectUsage', projectExtId, monthsBack] as const,\n /** The usage of every project the user owns, in one read (under `projectUsage`'s prefix). */\n ownedProjectsUsage: (monthsBack: number) =>\n ['arbi', 'projectUsage', 'owned', monthsBack] as const,\n projectConversationUsage: (projectExtId: string, monthsBack: number) =>\n ['arbi', 'projectUsage', projectExtId, 'byConversation', monthsBack] as const,\n projectInvoices: (projectExtId: string) => ['arbi', 'projectInvoices', projectExtId] as const,\n /** The plans and add-ons on sale. */\n products: () => ['arbi', 'products'] as const,\n /** Prices of a purchase or a change (quotes, previews); nothing is bought. */\n billingQuotes: () => ['arbi', 'billingQuote'] as const,\n userUsageToday: () => ['arbi', 'userUsageToday'] as const,\n currentUser: () => ['arbi', 'currentUser'] as const,\n firmPool: () => ['arbi', 'firmPool'] as const,\n contacts: () => ['arbi', 'contacts'] as const,\n /** Every chat query (the list and each open thread). */\n chats: () => ['arbi', 'chats'] as const,\n /** My chats, raw (titles and last messages are ciphertext), most recently active first. */\n chatList: () => ['arbi', 'chats', 'list'] as const,\n /** One thread's loaded messages, decrypted, oldest first (`ChatThreadData`). */\n chatThread: (chatExtId: string) => ['arbi', 'chats', 'thread', chatExtId] as const,\n /** My own agent's progress on my last message to it (`agent_dm_status`), per agent. */\n agentDmProgress: (ownerId: string, responseId: string) =>\n ['arbi', 'chats', 'agentProgress', ownerId, responseId] as const,\n agentDmStatus: (agentExtId: string) => ['arbi', 'chats', 'agentStatus', agentExtId] as const,\n /** The paid features this person may use (`/v1/user/entitlements`). */\n entitlements: () => ['arbi', 'entitlements'] as const,\n skills: () => ['arbi', 'skills'] as const,\n /** A skill's main file (SKILL.md), as text. */\n skillSource: (docExtId: string) => ['arbi', 'skills', 'source', docExtId] as const,\n /** An agent's pinned config; `undefined` = the library default config. */\n agentConfig: (agentExtId?: string) => ['arbi', 'agentConfig', agentExtId ?? 'default'] as const,\n agentWorkspaces: (agentExtId: string) => ['arbi', 'agentWorkspaces', agentExtId] as const,\n /** An agent's own login, polled while its controls are open. */\n agentSession: (agentExtId: string) => ['arbi', 'agentSession', agentExtId] as const,\n agentChats: (agentExtId: string) => ['arbi', 'agentChats', agentExtId] as const,\n authorizeLimits: () => ['arbi', 'authorizeLimits'] as const,\n mcpTools: () => ['arbi', 'mcpTools'] as const,\n models: () => ['arbi', 'models'] as const,\n availableModels: () => ['arbi', 'availableModels'] as const,\n /** The workspace Assistant's brief. */\n assistantBrief: (workspaceId: string) => ['arbi', 'assistantBrief', workspaceId] as const,\n /** Whether the workspace Assistant is waiting, working or idle. */\n assistantStatus: (workspaceId: string) => ['arbi', 'assistantStatus', workspaceId] as const,\n /** What the workspace Assistant did with each arrival. */\n assistantArrivals: (workspaceId: string) => ['arbi', 'assistantArrivals', workspaceId] as const,\n modelConnections: (userId?: string) => ['arbi', 'modelConnections', userId] as const,\n directModelUsage: (userId?: string) => ['arbi', 'directModelUsage', userId] as const,\n /** The signed-in user's own profile (name, picture, email). */\n profile: () => ['arbi', 'profile'] as const,\n identity: () => ['arbi', 'identity'] as const,\n /** The signed-in user's settings record (notification preferences, flags). */\n userSettings: () => ['arbi', 'userSettings'] as const,\n /** Every notification list: the prefix a delete, a read receipt or an arrival invalidates. */\n allSupportTickets: () => ['arbi', 'support'] as const,\n supportTickets: () => ['arbi', 'support', 'tickets'] as const,\n supportTicket: (id: number) => ['arbi', 'support', 'tickets', id] as const,\n allNotifications: () => ['arbi', 'notifications'] as const,\n /** The newest `limit` notifications, received and sent. */\n notifications: (limit: number) => ['arbi', 'notifications', limit] as const,\n /** The documents a workspace may use as its Word house template. */\n houseTemplateCandidates: (workspaceId: string) =>\n ['arbi', 'houseTemplateCandidates', workspaceId] as const,\n // ── Storage, archive ────────────────────────────────────────────────────────────────────────\n /** Every storage view (projects, items, names, Recently deleted): what a restore or delete refreshes. */\n storage: () => ['arbi', 'storage'] as const,\n /** What each project stores; no params: every such list. */\n storageProjects: (params?: object) =>\n params === undefined\n ? (['arbi', 'storage', 'projects'] as const)\n : (['arbi', 'storage', 'projects', params] as const),\n /** The largest items stored; no params: every such list. */\n storageItems: (params?: object) =>\n params === undefined\n ? (['arbi', 'storage', 'items'] as const)\n : (['arbi', 'storage', 'items', params] as const),\n /** Decrypted document names of storage items. */\n storageItemNames: (params?: object) =>\n params === undefined\n ? (['arbi', 'storage', 'names'] as const)\n : (['arbi', 'storage', 'names', params] as const),\n /** The deployment's storage day by day. */\n storageSnapshots: (params?: object) =>\n params === undefined\n ? (['arbi', 'storage', 'snapshots'] as const)\n : (['arbi', 'storage', 'snapshots', params] as const),\n /** A workspace's Recently deleted documents; no id: every workspace's. */\n workspaceTrash: (workspaceId?: string) =>\n workspaceId === undefined\n ? (['arbi', 'storage', 'workspaceTrash'] as const)\n : (['arbi', 'storage', 'workspaceTrash', workspaceId] as const),\n /** A workspace's archive state; no id: every workspace's. */\n workspaceArchive: (workspaceId?: string) =>\n workspaceId === undefined\n ? (['arbi', 'workspaceArchive'] as const)\n : (['arbi', 'workspaceArchive', workspaceId] as const),\n // ── Databases ───────────────────────────────────────────────────────────────────────────────\n // Every key below names its workspace right after its kind: a list read in one workspace is never\n // served, or overwritten, in another (the list is the session's open workspace on the server).\n /** Every database query of every workspace (what a write or a switch refreshes). */\n databases: () => ['arbi', 'databases'] as const,\n /** A workspace's databases; no id: every workspace's. */\n databaseList: (workspaceId?: string) =>\n workspaceId === undefined\n ? (['arbi', 'databases', 'list'] as const)\n : (['arbi', 'databases', 'list', workspaceId] as const),\n /** One database of a workspace; no workspace: every one read. */\n database: (workspaceId?: string, databaseId?: string) =>\n workspaceId === undefined\n ? (['arbi', 'databases', 'one'] as const)\n : (['arbi', 'databases', 'one', workspaceId, databaseId ?? ''] as const),\n /**\n * A database's rows (a search); no workspace: every database's, no params: every search of one.\n * `['arbi', 'databases', 'rows', workspaceId, databaseId, params]`.\n */\n databaseRows: (workspaceId?: string, databaseId?: string, params?: object) =>\n workspaceId === undefined\n ? (['arbi', 'databases', 'rows'] as const)\n : params === undefined\n ? (['arbi', 'databases', 'rows', workspaceId, databaseId ?? ''] as const)\n : (['arbi', 'databases', 'rows', workspaceId, databaseId ?? '', params] as const),\n /** A workspace's pages; no id: every workspace's. */\n pages: (workspaceId?: string) =>\n workspaceId === undefined\n ? (['arbi', 'pages'] as const)\n : (['arbi', 'pages', workspaceId] as const),\n /**\n * Saved table views a workspace's session sees: of one table (a database id or `documents`);\n * no target: every table's; no workspace: every workspace's.\n */\n tableViews: (workspaceId?: string, target?: string) =>\n workspaceId === undefined\n ? (['arbi', 'table-views'] as const)\n : target === undefined\n ? (['arbi', 'table-views', workspaceId] as const)\n : (['arbi', 'table-views', workspaceId, target] as const),\n /**\n * A view's rows with its database (a page's table block), under `databaseRows`' prefix so every\n * row write refreshes it: the database is the view's, unknown until read.\n */\n tableViewRows: (workspaceId: string, viewId: string) =>\n ['arbi', 'databases', 'rows', workspaceId, '', { view: viewId }] as const,\n /** A workspace's items counted on the server (a chart); no workspace: every workspace's. */\n workspaceAggregate: (workspaceId?: string, query?: object) =>\n workspaceId === undefined\n ? (['arbi', 'workspaceAggregate'] as const)\n : (['arbi', 'workspaceAggregate', workspaceId, query ?? {}] as const),\n /** A database's rows grouped and measured (a chart); no workspace: every database's. */\n databaseAggregate: (workspaceId?: string, databaseId?: string, request?: object) =>\n workspaceId === undefined\n ? (['arbi', 'databases', 'aggregate'] as const)\n : (['arbi', 'databases', 'aggregate', workspaceId, databaseId ?? '', request ?? {}] as const),\n // ── Configs, health ─────────────────────────────────────────────────────────────────────────\n /** Under `configs()`: the saved configuration versions. */\n configVersions: () => ['arbi', 'configs', 'versions'] as const,\n /** Under `configs()`: the JSON schema of every config model. */\n configSchema: () => ['arbi', 'configs', 'schema'] as const,\n /** Under `configs()`: one configuration. */\n config: (configId: string) => ['arbi', 'configs', 'one', configId] as const,\n /** The remote model providers' health. */\n remoteModels: () => ['arbi', 'remoteModels'] as const,\n // ── Conversations ───────────────────────────────────────────────────────────────────────────\n /** Under the conversations prefix: what a parked run waits for the owner to allow. */\n conversationPendingAuth: (conversationId: string) =>\n ['arbi', 'conversations', conversationId, 'pending-auth'] as const,\n // ── Document tools ──────────────────────────────────────────────────────────────────────────\n /** Signatures on a document (a version); no id: every document's. */\n documentSignatures: (docId?: string, version?: number | null) =>\n docId === undefined\n ? (['arbi', 'documentSignatures'] as const)\n : (['arbi', 'documentSignatures', docId, version ?? null] as const),\n /** The certificate of a signature reference. */\n signatureVerification: (reference: string) =>\n ['arbi', 'signatureVerification', reference] as const,\n /** Every signature request list: what a request write refreshes. */\n signatureRequests: () => ['arbi', 'signatureRequests'] as const,\n signatureRequestsForDocument: (docId: string) =>\n ['arbi', 'signatureRequests', 'document', docId] as const,\n /** Who may sign in a workspace; no id: every workspace's. */\n signatureCandidates: (workspaceId?: string) =>\n workspaceId === undefined\n ? (['arbi', 'signatureRequests', 'candidates'] as const)\n : (['arbi', 'signatureRequests', 'candidates', workspaceId] as const),\n /** The user's saved (informal) signature. */\n savedSignature: () => ['arbi', 'savedSignature'] as const,\n /** An html/react artifact's source. */\n artifactSource: (docId: string) => ['arbi', 'artifactSource', docId] as const,\n /** An artifact's text, under its parsed content (refreshed with it). */\n artifactText: (docId: string) => ['arbi', 'parsedDoc', docId, 'marker', 'artifact-text'] as const,\n /** An image document's bytes as an object URL. */\n assetImage: (docId: string) => ['arbi', 'assetImage', docId] as const,\n // ── Misc ────────────────────────────────────────────────────────────────────────────────────\n /** An agent config's model tier (the builder's badge). */\n agentConfigModel: (configId: string) => ['arbi', 'agentConfigModel', configId] as const,\n /** Under `billingQuotes()`: the price of a plan change. */\n billingPreview: (projectExtId: string, change: unknown) =>\n ['arbi', 'billingQuote', 'preview', projectExtId, change] as const,\n billingPlanQuote: (projectExtId: string | null, body: unknown) =>\n ['arbi', 'billingQuote', 'plan', projectExtId, body] as const,\n billingAddonQuote: (projectExtId: string, kind: string) =>\n ['arbi', 'billingQuote', 'addon', projectExtId, kind] as const,\n /** Under `contacts()`: a search of the people one can reach. */\n contactSearch: (term: string) => ['arbi', 'contacts', 'search', term] as const,\n /** Under the workspace's facts: a filtered list. */\n factList: (workspaceId: string, filter: unknown) =>\n ['arbi', 'facts', workspaceId, filter] as const,\n /**\n * Under `skills()`: a workspace's list, hidden ones included or not. Without a marketplace the\n * server lists the open workspace's skills, so the list is kept per workspace.\n */\n skillList: (workspaceId: string, includeHidden: boolean) =>\n ['arbi', 'skills', 'list', workspaceId, includeHidden] as const,\n /** Under the project's events: one kind, one page size. */\n projectEventList: (projectExtId: string, kind: string, limit: number | 'default') =>\n ['arbi', 'projects', projectExtId, 'events', kind, limit] as const,\n /** The documents pinned for offline reading on this device. */\n offlineDocuments: () => ['arbi', 'offlineDocuments'] as const,\n /** Notifications of one kind for a deployment's user (polled). */\n typedNotifications: (kind: string, apiUrl: string, userId: string | undefined) =>\n ['arbi', 'typedNotifications', kind, apiUrl, userId ?? ''] as const,\n}\n\n/**\n * Keys of the mutations a host may need to follow (its own caches outside these hooks), e.g. with\n * a `MutationCache` subscription: a workflow run creates a task in the host's own task list.\n */\nexport const arbiMutationKeys = {\n /** A member's role changed. */\n setWorkspaceMemberRoles: () => ['arbi', 'workspaces', 'roles'] as const,\n runWorkflow: () => ['arbi', 'workflows', 'run'] as const,\n startWorkflow: () => ['arbi', 'workflows', 'start'] as const,\n updateTagKindSchema: () => ['arbi', 'tags', 'kinds', 'update'] as const,\n createTag: () => ['arbi', 'tags', 'create'] as const,\n updateTag: () => ['arbi', 'tags', 'update'] as const,\n deleteTag: () => ['arbi', 'tags', 'delete'] as const,\n extractEntities: () => ['arbi', 'tags', 'entities', 'extract'] as const,\n updateDocuments: () => ['arbi', 'documents', 'update'] as const,\n deleteDocuments: () => ['arbi', 'documents', 'delete'] as const,\n uploadDocuments: () => ['arbi', 'documents', 'upload'] as const,\n uploadUrls: () => ['arbi', 'documents', 'uploadUrls'] as const,\n assignDocTags: () => ['arbi', 'doctags', 'assign'] as const,\n removeDocTags: () => ['arbi', 'doctags', 'remove'] as const,\n updateDocTag: () => ['arbi', 'doctags', 'update'] as const,\n generateDocTags: () => ['arbi', 'doctags', 'generate'] as const,\n /** Members added to or removed from a workspace (leaving included). */\n workspaceMembership: () => ['arbi', 'workspaces', 'members'] as const,\n /** A chat turn being sent (the app's send pipeline). */\n sendMessage: () => ['arbi', 'conversations', 'send'] as const,\n}\n\n/**\n * Query keys of the calendar hooks, all under `['arbi', 'calendar']`. The calendar is the user's,\n * not a workspace's; only the overlays carry the open workspace.\n */\nexport const calendarQueryKeys = {\n all: () => ['arbi', 'calendar'] as const,\n settings: () => ['arbi', 'calendar', 'settings'] as const,\n calendars: () => ['arbi', 'calendar', 'calendars'] as const,\n /** Every event list: the prefix an event write invalidates. */\n events: () => ['arbi', 'calendar', 'events'] as const,\n eventList: (p: ListEventsParams) =>\n [\n 'arbi',\n 'calendar',\n 'events',\n { start: p.start, end: p.end, calendars: p.calendars?.join(',') ?? null },\n ] as const,\n /** Every single event read. */\n eventDetails: () => ['arbi', 'calendar', 'event'] as const,\n event: (id: string, recurrenceId?: string | null) =>\n ['arbi', 'calendar', 'event', id, recurrenceId ?? null] as const,\n shares: (calId: string) => ['arbi', 'calendar', 'shares', calId] as const,\n invitations: () => ['arbi', 'calendar', 'invitations'] as const,\n holidayCountries: () => ['arbi', 'calendar', 'holiday-countries'] as const,\n allRooms: () => ['arbi', 'calendar', 'rooms'] as const,\n rooms: (q: RoomQuery) => ['arbi', 'calendar', 'rooms', q] as const,\n freebusy: (attendees: string[], start: string, end: string) =>\n ['arbi', 'calendar', 'freebusy', attendees.join(','), start, end] as const,\n allLookups: () => ['arbi', 'calendar', 'lookup'] as const,\n lookup: (uid: string) => ['arbi', 'calendar', 'lookup', uid] as const,\n overlays: (workspaceId: string | null, w?: CalendarWindow, layers?: OverlayLayerName[]) =>\n [\n 'arbi',\n 'calendar',\n 'overlays',\n workspaceId,\n w ? { start: w.start, end: w.end, layers: layers?.join(',') } : null,\n ] as const,\n accounts: () => ['arbi', 'calendar', 'accounts'] as const,\n caldavProfiles: () => ['arbi', 'calendar', 'caldav-profiles'] as const,\n bookingPages: () => ['arbi', 'calendar', 'booking-pages'] as const,\n /** The offline outbox (writes made offline, not yet sent). */\n outbox: () => ['arbi', 'calendar', 'outbox'] as const,\n}\n\n/** Query keys of the call hooks, all under `['arbi', 'calls']`. Calls are the user's, not a workspace's. */\nexport const callQueryKeys = {\n all: () => ['arbi', 'calls'] as const,\n config: () => ['arbi', 'calls', 'config'] as const,\n call: (callExtId: string) => ['arbi', 'calls', 'call', callExtId] as const,\n /** Everything about a call's recordings: the prefix a recording event invalidates. */\n recordingsOf: (callExtId: string) => ['arbi', 'calls', 'recordings', callExtId] as const,\n recordings: (callExtId: string) => ['arbi', 'calls', 'recordings', callExtId, 'list'] as const,\n recording: (callExtId: string, recordingExtId: string) =>\n ['arbi', 'calls', 'recordings', callExtId, 'one', recordingExtId] as const,\n inviteLinks: (callExtId: string) => ['arbi', 'calls', 'invite-links', callExtId] as const,\n}\n\nexport const connectorQueryKeys = {\n all: () => ['arbi', 'connectors'] as const,\n catalog: () => ['arbi', 'connectors', 'catalog'] as const,\n mine: () => ['arbi', 'connectors', 'mine'] as const,\n mailboxFolders: (vendor: string) => ['arbi', 'connectors', 'folders', vendor] as const,\n mailboxSyncProgress: (vendor: string, workspaceExtId: string) =>\n ['arbi', 'connectors', 'sync-progress', vendor, workspaceExtId] as const,\n allMailboxSyncProgress: () => ['arbi', 'connectors', 'sync-progress'] as const,\n driveFolders: (vendor: string) => ['arbi', 'connectors', 'drive-folders', vendor] as const,\n driveFolderChildren: (vendor: string, itemId: string) =>\n ['arbi', 'connectors', 'drive-folder-children', vendor, itemId] as const,\n driveFolderDocCount: (vendor: string, itemId: string) =>\n ['arbi', 'connectors', 'drive-folder-doc-count', vendor, itemId] as const,\n driveSyncEstimate: (vendor: string) =>\n ['arbi', 'connectors', 'drive-sync-estimate', vendor] as const,\n driveSyncProgress: (vendor: string) =>\n ['arbi', 'connectors', 'drive-sync-progress', vendor] as const,\n allDriveSyncProgress: () => ['arbi', 'connectors', 'drive-sync-progress'] as const,\n slack: () => ['arbi', 'connectors', 'slack'] as const,\n}\n\nexport const mailQueryKeys = {\n all: () => ['arbi', 'mail'] as const,\n policy: () => ['arbi', 'mail', 'policy'] as const,\n accounts: () => ['arbi', 'mail', 'accounts'] as const,\n unlock: (accountId: string | undefined, sessionKey: string | null) =>\n ['arbi', 'mail', 'unlock', accountId, sessionKey ?? ''] as const,\n allFolders: () => ['arbi', 'mail', 'folders'] as const,\n folders: (accountId: string | undefined) => ['arbi', 'mail', 'folders', accountId] as const,\n allMessages: () => ['arbi', 'mail', 'messages'] as const,\n messages: (\n accountId: string | undefined,\n folderId: string | undefined,\n query: string,\n cursor: string | null\n ) => ['arbi', 'mail', 'messages', accountId, folderId, query, cursor] as const,\n message: (accountId: string | undefined, messageId: string | null | undefined) =>\n ['arbi', 'mail', 'message', accountId, messageId] as const,\n /** Every conversation list: the prefix a flag or move patches or refreshes. */\n allConversations: () => ['arbi', 'mail', 'conversations'] as const,\n conversations: (\n accountId: string | undefined,\n folderId: string | undefined,\n query: string,\n cursor: string | null\n ) => ['arbi', 'mail', 'conversations', accountId, folderId, query, cursor] as const,\n /** Every thread read of an account. */\n accountThreads: (accountId: string) => ['arbi', 'mail', 'thread', accountId] as const,\n thread: (\n accountId: string | undefined,\n threadId: string | null | undefined,\n folderId: string | undefined\n ) => ['arbi', 'mail', 'thread', accountId, threadId, folderId] as const,\n /** Where the ARBI mailbox files mail (folders and conversations, per workspace). */\n nativeFiling: () => ['arbi', 'mail', 'filing', 'native'] as const,\n /** Every filing lookup: refreshed after mail is added to a workspace or a rule is stopped. */\n allFiling: () => ['arbi', 'mail', 'filing'] as const,\n filing: (accountId: string | undefined, messageIds: string[], threadIds: string[]) =>\n ['arbi', 'mail', 'filing', accountId, messageIds.join(' '), threadIds.join(' ')] as const,\n /** The key the user's client keys older native mail with: outside the `['arbi', 'mail']` prefix, so\n * refreshing mail never fetches it again. */\n threadSecret: () => ['arbi', 'mail-thread-secret'] as const,\n /** The projects an email's AI work can be billed to. */\n projects: () => ['arbi', 'mail', 'projects'] as const,\n /** A saved draft prepared for editing. */\n draftCompose: (accountId: string | undefined, draftId: string | undefined) =>\n ['arbi', 'mail', 'draft-compose', accountId, draftId] as const,\n attachmentText: (accountId: string, messageId: string, attachmentId: string) =>\n ['arbi', 'mail', 'attachment-text', accountId, messageId, attachmentId] as const,\n}\n\n/** `pdf`: the document as a PDF; `original`: the stored file (an image, a recording, a sheet). */\nexport type DocumentBytesKind = 'pdf' | 'original'\n\n/** Every version and kind of a document's bytes: the prefix a new version invalidates. */\nexport const documentBytesKey = (\n documentRef: string,\n version?: number | null,\n kind?: DocumentBytesKind\n) =>\n version === undefined\n ? (['arbi', 'documentBytes', documentRef] as const)\n : (['arbi', 'documentBytes', documentRef, version, kind ?? 'pdf'] as const)\n\n/** Whether `queryKey` lies under `prefix` (a factory key): React Query's own prefix match. */\nexport function isUnderQueryKey(queryKey: readonly unknown[], prefix: readonly unknown[]): boolean {\n return prefix.every((part, i) => queryKey[i] === part)\n}\n"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk5QOZLKAY_cjs = require('./chunk-5QOZLKAY.cjs');
|
|
4
4
|
var chunkN73IMVFF_cjs = require('./chunk-N73IMVFF.cjs');
|
|
5
5
|
var chunkKULS4YWP_cjs = require('./chunk-KULS4YWP.cjs');
|
|
6
6
|
var client = require('@arbidocs/client');
|
|
@@ -1013,6 +1013,9 @@ function openPanelIn(panels, panelId, mode, options) {
|
|
|
1013
1013
|
popout: leave(panels.popout),
|
|
1014
1014
|
modes: { ...panels.modes, [panelId]: mode }
|
|
1015
1015
|
};
|
|
1016
|
+
if (options?.preserveOverlay && panels.overlay && panels.overlay !== panelId)
|
|
1017
|
+
next.retainedOverlay = panels.overlay;
|
|
1018
|
+
else if (panels.retainedOverlay === panelId) next.retainedOverlay = null;
|
|
1016
1019
|
if (mode === "docked") return { ...next, docked: panelId, overlay: null };
|
|
1017
1020
|
if (mode === "overlay")
|
|
1018
1021
|
return { ...next, overlay: panelId, docked: options?.preserveDocked ? next.docked : null };
|
|
@@ -1022,6 +1025,7 @@ function closePanelIn(panels, panelId) {
|
|
|
1022
1025
|
const leave = (slot) => slot === panelId ? null : slot;
|
|
1023
1026
|
return {
|
|
1024
1027
|
...panels,
|
|
1028
|
+
...panels.retainedOverlay === panelId ? { retainedOverlay: null } : {},
|
|
1025
1029
|
main: leave(panels.main),
|
|
1026
1030
|
docked: leave(panels.docked),
|
|
1027
1031
|
overlay: leave(panels.overlay),
|
|
@@ -1029,6 +1033,7 @@ function closePanelIn(panels, panelId) {
|
|
|
1029
1033
|
};
|
|
1030
1034
|
}
|
|
1031
1035
|
function panelPlace(panels, panelId) {
|
|
1036
|
+
if (panels.retainedOverlay === panelId) return "overlay";
|
|
1032
1037
|
return PANEL_MODES.find((mode) => panels[mode] === panelId) ?? null;
|
|
1033
1038
|
}
|
|
1034
1039
|
var DOCUMENT_VIEWER_PANEL = "document-viewer";
|
|
@@ -1557,7 +1562,7 @@ var createOwnStore = (host) => createArbiSessionStore(
|
|
|
1557
1562
|
var moduleDefault = null;
|
|
1558
1563
|
var defaultStore = () => moduleDefault ??= createArbiSessionStore();
|
|
1559
1564
|
function useArbiSessionStore() {
|
|
1560
|
-
const host =
|
|
1565
|
+
const host = chunk5QOZLKAY_cjs.useArbiHost();
|
|
1561
1566
|
if (host.session) return host.session;
|
|
1562
1567
|
const own = host[chunkN73IMVFF_cjs.OWN_SESSION_SLOT];
|
|
1563
1568
|
if (own) return own.current ??= createOwnStore(host);
|
|
@@ -1596,7 +1601,7 @@ var SIGNED_OUT = {
|
|
|
1596
1601
|
var noSubscription = () => () => {
|
|
1597
1602
|
};
|
|
1598
1603
|
function useArbiSession() {
|
|
1599
|
-
return useSignedInSession(
|
|
1604
|
+
return useSignedInSession(chunk5QOZLKAY_cjs.useArbiHost().arbi?.session ?? null);
|
|
1600
1605
|
}
|
|
1601
1606
|
function useSignedInSession(session) {
|
|
1602
1607
|
const state = react.useSyncExternalStore(
|
|
@@ -1887,7 +1892,9 @@ function createConversationPanels(source, options) {
|
|
|
1887
1892
|
const mode = defaultModes[panelId] ?? "docked";
|
|
1888
1893
|
const state = layout.getLayout();
|
|
1889
1894
|
const preserveDocked = mode === "overlay" && state.shell.panels.docked === conversationPanel && state.tabs.activeDm?.startsWith("agt-");
|
|
1890
|
-
|
|
1895
|
+
const preserveOverlay = (mode === "overlay" || mode === "docked") && panelId !== conversationPanel && state.shell.panels.overlay === conversationPanel && state.tabs.activeDm?.startsWith("agt-");
|
|
1896
|
+
if (preserveOverlay) layout.openPanel(panelId, mode, { preserveOverlay: true });
|
|
1897
|
+
else if (preserveDocked) layout.openPanel(panelId, mode, { preserveDocked: true });
|
|
1891
1898
|
else layout.openPanel(panelId, mode);
|
|
1892
1899
|
};
|
|
1893
1900
|
return {
|
|
@@ -1897,7 +1904,7 @@ function createConversationPanels(source, options) {
|
|
|
1897
1904
|
const state = layout.getLayout();
|
|
1898
1905
|
const { main } = state.shell.panels;
|
|
1899
1906
|
if (main === conversationPanel && state.tabs.activeDm?.startsWith("agt-"))
|
|
1900
|
-
layout.openPanel(conversationPanel, "
|
|
1907
|
+
layout.openPanel(conversationPanel, defaultModes[conversationPanel] ?? "overlay");
|
|
1901
1908
|
else if (main && mainAreaPanels.includes(main)) showPanel(main, false);
|
|
1902
1909
|
},
|
|
1903
1910
|
openDmTab(recipientId, messageId) {
|
|
@@ -1905,7 +1912,7 @@ function createConversationPanels(source, options) {
|
|
|
1905
1912
|
layout.openDmTab(recipientId ?? null, messageId);
|
|
1906
1913
|
if (recipientId?.startsWith("agt-")) {
|
|
1907
1914
|
showPanel(agentGalleryPanel, false);
|
|
1908
|
-
layout.openPanel(conversationPanel, "
|
|
1915
|
+
layout.openPanel(conversationPanel, defaultModes[conversationPanel] ?? "overlay");
|
|
1909
1916
|
} else if (!isPanelOpen(layout.getLayout(), conversationPanel)) showPanel(conversationPanel);
|
|
1910
1917
|
layout.setFocusedArea(conversationPanel);
|
|
1911
1918
|
}
|
|
@@ -1918,27 +1925,27 @@ function isUsageMetered(usage, subscription) {
|
|
|
1918
1925
|
return !(empty && subscription === "dev");
|
|
1919
1926
|
}
|
|
1920
1927
|
function useWorkspaces(options) {
|
|
1921
|
-
const arbi =
|
|
1928
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
1922
1929
|
return reactQuery.useQuery({
|
|
1923
|
-
queryKey:
|
|
1930
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.workspaces(),
|
|
1924
1931
|
queryFn: () => arbi.workspaces.list(),
|
|
1925
1932
|
enabled: (options?.enabled ?? true) && arbi.isLoggedIn
|
|
1926
1933
|
});
|
|
1927
1934
|
}
|
|
1928
1935
|
function useDocumentVersionList(docId, options) {
|
|
1929
|
-
const arbi =
|
|
1936
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
1930
1937
|
return reactQuery.useQuery({
|
|
1931
|
-
queryKey:
|
|
1938
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.documentVersions(docId ?? ""),
|
|
1932
1939
|
queryFn: () => arbi.documents.versions(docId),
|
|
1933
1940
|
enabled: (options?.enabled ?? true) && !!docId && arbi.hasWorkspace
|
|
1934
1941
|
});
|
|
1935
1942
|
}
|
|
1936
1943
|
function useConversations(workspaceId, options) {
|
|
1937
|
-
const arbi =
|
|
1944
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
1938
1945
|
const queryClient = reactQuery.useQueryClient();
|
|
1939
1946
|
const live = options?.live === true;
|
|
1940
1947
|
return reactQuery.useQuery({
|
|
1941
|
-
queryKey:
|
|
1948
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.conversations(workspaceId ?? ""),
|
|
1942
1949
|
// The request names the workspace, so a switch while it runs cannot answer for another.
|
|
1943
1950
|
queryFn: () => readConversationList(
|
|
1944
1951
|
queryClient,
|
|
@@ -1953,9 +1960,9 @@ function useConversations(workspaceId, options) {
|
|
|
1953
1960
|
});
|
|
1954
1961
|
}
|
|
1955
1962
|
function useBuiltinCommands() {
|
|
1956
|
-
const arbi =
|
|
1963
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
1957
1964
|
const query = reactQuery.useQuery({
|
|
1958
|
-
queryKey:
|
|
1965
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.assistantCommands(),
|
|
1959
1966
|
queryFn: () => arbi.assistant.commands(),
|
|
1960
1967
|
staleTime: 30 * 1e3,
|
|
1961
1968
|
enabled: arbi.isLoggedIn
|
|
@@ -1964,18 +1971,18 @@ function useBuiltinCommands() {
|
|
|
1964
1971
|
return { commands, isLoading: query.isLoading };
|
|
1965
1972
|
}
|
|
1966
1973
|
function useMessageDetails(messageId, options) {
|
|
1967
|
-
const arbi =
|
|
1974
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
1968
1975
|
return reactQuery.useQuery({
|
|
1969
|
-
queryKey:
|
|
1976
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.messageDetails(messageId ?? ""),
|
|
1970
1977
|
queryFn: () => arbi.conversations.getMessage(messageId),
|
|
1971
1978
|
enabled: (options?.enabled ?? true) && !!messageId && arbi.isLoggedIn
|
|
1972
1979
|
});
|
|
1973
1980
|
}
|
|
1974
1981
|
function useConversationThreads(conversationId, options) {
|
|
1975
|
-
const arbi =
|
|
1982
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
1976
1983
|
const session = useArbiSessionStore();
|
|
1977
1984
|
return reactQuery.useQuery({
|
|
1978
|
-
queryKey:
|
|
1985
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.conversationThreads(conversationId ?? ""),
|
|
1979
1986
|
queryFn: () => arbi.conversations.getThreads(conversationId),
|
|
1980
1987
|
enabled: (options?.enabled ?? true) && !!conversationId && arbi.hasWorkspace,
|
|
1981
1988
|
staleTime: 2 * 60 * 1e3,
|
|
@@ -1991,12 +1998,12 @@ var tagListKey = (query) => [
|
|
|
1991
1998
|
query.linksLimit !== void 0 ? `links:${query.linksLimit}` : ""
|
|
1992
1999
|
].filter(Boolean).join("|");
|
|
1993
2000
|
function useTags(workspaceId, options) {
|
|
1994
|
-
const arbi =
|
|
2001
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
1995
2002
|
const { enabled, ...query } = options ?? {};
|
|
1996
2003
|
const workspace = workspaceId ?? (arbi.hasWorkspace ? arbi.getWorkspaceId() : "");
|
|
1997
2004
|
const key = tagListKey(query);
|
|
1998
2005
|
return reactQuery.useQuery({
|
|
1999
|
-
queryKey: key ?
|
|
2006
|
+
queryKey: key ? chunk5QOZLKAY_cjs.arbiQueryKeys.tagList(workspace, key) : chunk5QOZLKAY_cjs.arbiQueryKeys.tags(workspace),
|
|
2000
2007
|
// The request names the workspace (opened for this session first when it is not the current
|
|
2001
2008
|
// one), so another workspace's tags can be listed and a switch cannot answer for it. The
|
|
2002
2009
|
// current workspace's list is also read under the switch guard.
|
|
@@ -2009,18 +2016,18 @@ function useTags(workspaceId, options) {
|
|
|
2009
2016
|
});
|
|
2010
2017
|
}
|
|
2011
2018
|
function useThumbnails(docIds, options) {
|
|
2012
|
-
const arbi =
|
|
2019
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2013
2020
|
return reactQuery.useQuery({
|
|
2014
|
-
queryKey:
|
|
2021
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.thumbnails(docIds),
|
|
2015
2022
|
queryFn: () => arbi.documents.getThumbnails(docIds),
|
|
2016
2023
|
enabled: (options?.enabled ?? true) && docIds.length > 0 && arbi.hasWorkspace,
|
|
2017
2024
|
staleTime: 5 * 6e4
|
|
2018
2025
|
});
|
|
2019
2026
|
}
|
|
2020
2027
|
function useParsedDocument(docId, stage = "final", options) {
|
|
2021
|
-
const arbi =
|
|
2028
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2022
2029
|
return reactQuery.useQuery({
|
|
2023
|
-
queryKey:
|
|
2030
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.parsedDoc(docId ?? "", stage),
|
|
2024
2031
|
queryFn: () => {
|
|
2025
2032
|
const { docId: id, version } = chunkKULS4YWP_cjs.parseVersionRef(docId);
|
|
2026
2033
|
return arbi.documents.getParsedContent(
|
|
@@ -2033,84 +2040,84 @@ function useParsedDocument(docId, stage = "final", options) {
|
|
|
2033
2040
|
});
|
|
2034
2041
|
}
|
|
2035
2042
|
function useAssistantQuery() {
|
|
2036
|
-
const arbi =
|
|
2043
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2037
2044
|
return reactQuery.useMutation({
|
|
2038
2045
|
mutationFn: ({ request, handlers }) => arbi.assistant.ask(request, handlers)
|
|
2039
2046
|
});
|
|
2040
2047
|
}
|
|
2041
2048
|
function useAgents(options) {
|
|
2042
|
-
const arbi =
|
|
2049
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2043
2050
|
return reactQuery.useQuery({
|
|
2044
|
-
queryKey:
|
|
2051
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.agents(),
|
|
2045
2052
|
queryFn: () => arbi.agents.list(),
|
|
2046
2053
|
enabled: (options?.enabled ?? true) && arbi.isLoggedIn
|
|
2047
2054
|
});
|
|
2048
2055
|
}
|
|
2049
2056
|
function useDeleteAgents() {
|
|
2050
|
-
const arbi =
|
|
2057
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2051
2058
|
const qc = reactQuery.useQueryClient();
|
|
2052
2059
|
return reactQuery.useMutation({
|
|
2053
2060
|
mutationFn: ({ agentExtIds }) => arbi.agents.delete(agentExtIds),
|
|
2054
2061
|
onSuccess: (_result, { agentExtIds }) => {
|
|
2055
2062
|
for (const id of agentExtIds) {
|
|
2056
|
-
qc.removeQueries({ queryKey:
|
|
2057
|
-
qc.removeQueries({ queryKey:
|
|
2063
|
+
qc.removeQueries({ queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.agentConfig(id) });
|
|
2064
|
+
qc.removeQueries({ queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.agentWorkspaces(id) });
|
|
2058
2065
|
}
|
|
2059
2066
|
return Promise.all([
|
|
2060
|
-
qc.invalidateQueries({ queryKey:
|
|
2061
|
-
qc.invalidateQueries({ queryKey:
|
|
2062
|
-
qc.invalidateQueries({ queryKey:
|
|
2063
|
-
qc.invalidateQueries({ queryKey:
|
|
2067
|
+
qc.invalidateQueries({ queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.agents() }),
|
|
2068
|
+
qc.invalidateQueries({ queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.workflows() }),
|
|
2069
|
+
qc.invalidateQueries({ queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.allConversations() }),
|
|
2070
|
+
qc.invalidateQueries({ queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.configs() })
|
|
2064
2071
|
]);
|
|
2065
2072
|
}
|
|
2066
2073
|
});
|
|
2067
2074
|
}
|
|
2068
2075
|
function useHealth(options) {
|
|
2069
|
-
const arbi =
|
|
2076
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2070
2077
|
return reactQuery.useQuery({
|
|
2071
|
-
queryKey:
|
|
2078
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.health(),
|
|
2072
2079
|
queryFn: () => arbi.health.check(),
|
|
2073
2080
|
enabled: options?.enabled
|
|
2074
2081
|
});
|
|
2075
2082
|
}
|
|
2076
2083
|
function useAvailableModels(options) {
|
|
2077
|
-
const arbi =
|
|
2084
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2078
2085
|
return reactQuery.useQuery({
|
|
2079
|
-
queryKey:
|
|
2086
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.availableModels(),
|
|
2080
2087
|
queryFn: () => arbi.health.models(),
|
|
2081
2088
|
staleTime: Infinity,
|
|
2082
2089
|
enabled: (options?.enabled ?? true) && arbi.isLoggedIn
|
|
2083
2090
|
});
|
|
2084
2091
|
}
|
|
2085
2092
|
function useConfigs(options) {
|
|
2086
|
-
const arbi =
|
|
2093
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2087
2094
|
return reactQuery.useQuery({
|
|
2088
|
-
queryKey:
|
|
2095
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.configVersions(),
|
|
2089
2096
|
queryFn: () => arbi.agentConfig.list(),
|
|
2090
2097
|
enabled: options?.enabled ?? arbi.isLoggedIn
|
|
2091
2098
|
});
|
|
2092
2099
|
}
|
|
2093
2100
|
function useConfig(configId, options) {
|
|
2094
|
-
const arbi =
|
|
2101
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2095
2102
|
return reactQuery.useQuery({
|
|
2096
|
-
queryKey:
|
|
2103
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.config(configId ?? ""),
|
|
2097
2104
|
queryFn: () => arbi.agentConfig.get(configId),
|
|
2098
2105
|
staleTime: 10 * 60 * 1e3,
|
|
2099
2106
|
enabled: (options?.enabled ?? true) && !!configId && arbi.isLoggedIn
|
|
2100
2107
|
});
|
|
2101
2108
|
}
|
|
2102
2109
|
function useActivity(options) {
|
|
2103
|
-
const arbi =
|
|
2110
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2104
2111
|
return reactQuery.useQuery({
|
|
2105
|
-
queryKey:
|
|
2112
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.activity(),
|
|
2106
2113
|
queryFn: () => arbi.dm.listActivity({ limit: options?.limit, offset: options?.offset }),
|
|
2107
2114
|
enabled: options?.enabled ?? arbi.isLoggedIn
|
|
2108
2115
|
});
|
|
2109
2116
|
}
|
|
2110
2117
|
function useWorkspaceActivity(workspaceId, options) {
|
|
2111
|
-
const arbi =
|
|
2118
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2112
2119
|
return reactQuery.useInfiniteQuery({
|
|
2113
|
-
queryKey:
|
|
2120
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.workspaceActivity(workspaceId ?? "", options?.limit),
|
|
2114
2121
|
queryFn: async ({ pageParam }) => {
|
|
2115
2122
|
await options?.beforeFetch?.();
|
|
2116
2123
|
return arbi.workspaces.activity(workspaceId, {
|
|
@@ -2124,17 +2131,17 @@ function useWorkspaceActivity(workspaceId, options) {
|
|
|
2124
2131
|
});
|
|
2125
2132
|
}
|
|
2126
2133
|
function useProjects(options) {
|
|
2127
|
-
const arbi =
|
|
2134
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2128
2135
|
return reactQuery.useQuery({
|
|
2129
|
-
queryKey:
|
|
2136
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.projects(),
|
|
2130
2137
|
queryFn: () => arbi.projects.list(),
|
|
2131
2138
|
enabled: options?.enabled ?? arbi.isLoggedIn
|
|
2132
2139
|
});
|
|
2133
2140
|
}
|
|
2134
2141
|
function useProjectUsage(projectExtId, monthsBack = 0, options) {
|
|
2135
|
-
const arbi =
|
|
2142
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2136
2143
|
const usage = reactQuery.useQuery({
|
|
2137
|
-
queryKey:
|
|
2144
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.projectUsage(projectExtId ?? "", monthsBack),
|
|
2138
2145
|
queryFn: () => arbi.projects.usage(projectExtId, monthsBack),
|
|
2139
2146
|
enabled: (options?.enabled ?? true) && !!projectExtId && arbi.isLoggedIn
|
|
2140
2147
|
});
|
|
@@ -2144,17 +2151,17 @@ function useProjectUsage(projectExtId, monthsBack = 0, options) {
|
|
|
2144
2151
|
return { ...usage, metered };
|
|
2145
2152
|
}
|
|
2146
2153
|
function useProjectInvoices(projectExtId, options) {
|
|
2147
|
-
const arbi =
|
|
2154
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2148
2155
|
return reactQuery.useQuery({
|
|
2149
|
-
queryKey:
|
|
2156
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.projectInvoices(projectExtId ?? ""),
|
|
2150
2157
|
queryFn: () => arbi.projects.invoices(projectExtId),
|
|
2151
2158
|
enabled: (options?.enabled ?? true) && !!projectExtId && arbi.isLoggedIn
|
|
2152
2159
|
});
|
|
2153
2160
|
}
|
|
2154
2161
|
function useCurrentUser(options) {
|
|
2155
|
-
const arbi =
|
|
2162
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2156
2163
|
return reactQuery.useQuery({
|
|
2157
|
-
queryKey:
|
|
2164
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.currentUser(),
|
|
2158
2165
|
queryFn: () => arbi.user.me(),
|
|
2159
2166
|
enabled: options?.enabled ?? arbi.isLoggedIn,
|
|
2160
2167
|
refetchOnWindowFocus: true,
|
|
@@ -2162,9 +2169,9 @@ function useCurrentUser(options) {
|
|
|
2162
2169
|
});
|
|
2163
2170
|
}
|
|
2164
2171
|
function useFirmPool(options) {
|
|
2165
|
-
const arbi =
|
|
2172
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2166
2173
|
return reactQuery.useQuery({
|
|
2167
|
-
queryKey:
|
|
2174
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.firmPool(),
|
|
2168
2175
|
queryFn: () => arbi.firm.pool(),
|
|
2169
2176
|
enabled: (options?.enabled ?? true) && arbi.isLoggedIn,
|
|
2170
2177
|
retry: false,
|
|
@@ -2215,9 +2222,9 @@ function useCanCreateWorkspaces() {
|
|
|
2215
2222
|
return me && (me.can_create_workspaces ?? me.can_create_projects);
|
|
2216
2223
|
}
|
|
2217
2224
|
function useUserUsageToday(options) {
|
|
2218
|
-
const arbi =
|
|
2225
|
+
const arbi = chunk5QOZLKAY_cjs.useArbi();
|
|
2219
2226
|
return reactQuery.useQuery({
|
|
2220
|
-
queryKey:
|
|
2227
|
+
queryKey: chunk5QOZLKAY_cjs.arbiQueryKeys.userUsageToday(),
|
|
2221
2228
|
queryFn: () => arbi.user.usageToday(),
|
|
2222
2229
|
enabled: (options?.enabled ?? true) && arbi.isLoggedIn,
|
|
2223
2230
|
refetchOnWindowFocus: true,
|
|
@@ -2245,7 +2252,7 @@ function writeLog(queryClient, key) {
|
|
|
2245
2252
|
return log;
|
|
2246
2253
|
}
|
|
2247
2254
|
function withLocalWrites(queryClient, workspaceId, rows, requestedAt) {
|
|
2248
|
-
return writeLog(queryClient,
|
|
2255
|
+
return writeLog(queryClient, chunk5QOZLKAY_cjs.arbiQueryKeys.conversations(workspaceId)).filter((w) => w.at >= requestedAt).reduce((list, w) => w.apply(list), rows);
|
|
2249
2256
|
}
|
|
2250
2257
|
async function readConversationList(queryClient, workspaceId, read) {
|
|
2251
2258
|
const requestedAt = Date.now();
|
|
@@ -2253,7 +2260,7 @@ async function readConversationList(queryClient, workspaceId, read) {
|
|
|
2253
2260
|
}
|
|
2254
2261
|
function seedConversationList(queryClient, workspaceId, rows, requestedAt) {
|
|
2255
2262
|
queryClient.setQueryData(
|
|
2256
|
-
|
|
2263
|
+
chunk5QOZLKAY_cjs.arbiQueryKeys.conversations(workspaceId),
|
|
2257
2264
|
withLocalWrites(queryClient, workspaceId, rows, requestedAt)
|
|
2258
2265
|
);
|
|
2259
2266
|
}
|
|
@@ -2272,7 +2279,7 @@ function patchLists(queryClient, reducer) {
|
|
|
2272
2279
|
}
|
|
2273
2280
|
function patchConversationList(queryClient, workspaceId, reducer) {
|
|
2274
2281
|
if (!workspaceId) return;
|
|
2275
|
-
const key =
|
|
2282
|
+
const key = chunk5QOZLKAY_cjs.arbiQueryKeys.conversations(workspaceId);
|
|
2276
2283
|
const current = queryClient.getQueryData(key) ?? [];
|
|
2277
2284
|
const next = reducer(current);
|
|
2278
2285
|
if (next !== current) writeList(queryClient, key, reducer, next);
|
|
@@ -2413,5 +2420,5 @@ exports.useUserUsageToday = useUserUsageToday;
|
|
|
2413
2420
|
exports.useWorkspaceActivity = useWorkspaceActivity;
|
|
2414
2421
|
exports.useWorkspaces = useWorkspaces;
|
|
2415
2422
|
exports.withLocalWrites = withLocalWrites;
|
|
2416
|
-
//# sourceMappingURL=chunk-
|
|
2417
|
-
//# sourceMappingURL=chunk-
|
|
2423
|
+
//# sourceMappingURL=chunk-BI4SYRLX.cjs.map
|
|
2424
|
+
//# sourceMappingURL=chunk-BI4SYRLX.cjs.map
|