@assistant-ui/react 0.15.30 → 0.15.31
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/cloud-renderer/CloudRendererHost.d.ts.map +1 -1
- package/dist/cloud-renderer/CloudRendererHost.js +1 -2
- package/dist/cloud-renderer/CloudRendererHost.js.map +1 -1
- package/dist/context/providers/AttachmentByIndexProvider.js +1 -2
- package/dist/context/providers/ChainOfThoughtByIndicesProvider.js +1 -2
- package/dist/context/providers/MessageByIndexProvider.js +1 -2
- package/dist/context/providers/PartByIndexProvider.js +1 -2
- package/dist/context/providers/SuggestionByIndexProvider.js +1 -2
- package/dist/context/providers/TextMessagePartProvider.js +1 -2
- package/dist/context/providers/ThreadListItemProvider.js +1 -2
- package/dist/index.d.ts +9 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -9
- package/dist/internal.d.ts +1 -1
- package/dist/internal.d.ts.map +1 -1
- package/dist/internal.js +1 -1
- package/dist/internal.js.map +1 -1
- package/dist/legacy-runtime/AssistantRuntimeProvider.d.ts +1 -1
- package/dist/legacy-runtime/AssistantRuntimeProvider.d.ts.map +1 -1
- package/dist/legacy-runtime/AssistantRuntimeProvider.js.map +1 -1
- package/dist/primitives/actionBar/ActionBarCopy.d.ts +1 -1
- package/dist/primitives/actionBar/ActionBarEdit.d.ts +1 -1
- package/dist/primitives/actionBar/ActionBarExportMarkdown.d.ts +1 -1
- package/dist/primitives/actionBar/ActionBarFeedbackNegative.d.ts +1 -1
- package/dist/primitives/actionBar/ActionBarFeedbackPositive.d.ts +1 -1
- package/dist/primitives/actionBar/ActionBarReload.d.ts +1 -1
- package/dist/primitives/actionBar/ActionBarRoot.d.ts +1 -1
- package/dist/primitives/actionBar/ActionBarSpeak.d.ts +1 -1
- package/dist/primitives/actionBar/ActionBarStopSpeaking.d.ts +1 -1
- package/dist/primitives/attachment/AttachmentRemove.d.ts +1 -1
- package/dist/primitives/attachment/AttachmentRoot.d.ts +1 -1
- package/dist/primitives/attachment/AttachmentThumb.d.ts +1 -1
- package/dist/primitives/branchPicker/BranchPickerNext.d.ts +1 -1
- package/dist/primitives/branchPicker/BranchPickerPrevious.d.ts +1 -1
- package/dist/primitives/branchPicker/BranchPickerRoot.d.ts +1 -1
- package/dist/primitives/chainOfThought/ChainOfThoughtAccordionTrigger.d.ts +1 -1
- package/dist/primitives/chainOfThought/ChainOfThoughtParts.js +1 -2
- package/dist/primitives/chainOfThought/ChainOfThoughtRoot.d.ts +1 -1
- package/dist/primitives/composer/ComposerAddAttachment.d.ts +1 -1
- package/dist/primitives/composer/ComposerAttachments.js +1 -2
- package/dist/primitives/composer/ComposerCancel.d.ts +1 -1
- package/dist/primitives/composer/ComposerDictate.d.ts +1 -1
- package/dist/primitives/composer/ComposerDictationTranscript.d.ts +1 -1
- package/dist/primitives/composer/ComposerIf.js +1 -2
- package/dist/primitives/composer/ComposerInput.d.ts.map +1 -1
- package/dist/primitives/composer/ComposerInput.js +3 -3
- package/dist/primitives/composer/ComposerInput.js.map +1 -1
- package/dist/primitives/composer/ComposerQueue.js +1 -2
- package/dist/primitives/composer/ComposerQuote.d.ts +3 -3
- package/dist/primitives/composer/ComposerResume.d.ts +1 -1
- package/dist/primitives/composer/ComposerRoot.d.ts +1 -1
- package/dist/primitives/composer/ComposerSend.d.ts +1 -1
- package/dist/primitives/composer/ComposerStopDictation.d.ts +1 -1
- package/dist/primitives/composer/trigger/TriggerPopover.d.ts +1 -1
- package/dist/primitives/composer/trigger/TriggerPopoverBack.d.ts +1 -1
- package/dist/primitives/composer/trigger/TriggerPopoverCategories.d.ts +2 -2
- package/dist/primitives/composer/trigger/TriggerPopoverItems.d.ts +2 -2
- package/dist/primitives/composer/trigger/index.d.ts +1 -1
- package/dist/primitives/composer/trigger/triggerSelectionResource.d.ts.map +1 -1
- package/dist/primitives/composer/trigger/triggerSelectionResource.js +2 -2
- package/dist/primitives/composer/trigger/triggerSelectionResource.js.map +1 -1
- package/dist/primitives/error/ErrorMessage.d.ts +1 -1
- package/dist/primitives/error/ErrorRoot.d.ts +1 -1
- package/dist/primitives/message/MessageAttachments.js +1 -2
- package/dist/primitives/message/MessageRoot.d.ts +1 -1
- package/dist/primitives/messagePart/MessagePartImage.d.ts +1 -1
- package/dist/primitives/messagePart/MessagePartInProgress.js +1 -2
- package/dist/primitives/messagePart/MessagePartText.d.ts +1 -1
- package/dist/primitives/queueItem/QueueItemRemove.d.ts +1 -1
- package/dist/primitives/queueItem/QueueItemSteer.d.ts +1 -1
- package/dist/primitives/queueItem/QueueItemText.d.ts +1 -1
- package/dist/primitives/selectionToolbar/SelectionToolbarQuote.d.ts +1 -1
- package/dist/primitives/selectionToolbar/SelectionToolbarRoot.d.ts +1 -1
- package/dist/primitives/suggestion/SuggestionDescription.d.ts +1 -1
- package/dist/primitives/suggestion/SuggestionTitle.d.ts +1 -1
- package/dist/primitives/suggestion/SuggestionTrigger.d.ts +1 -1
- package/dist/primitives/thread/ThreadLoadEarlier.d.ts +1 -1
- package/dist/primitives/thread/ThreadMessages.js +1 -2
- package/dist/primitives/thread/ThreadRoot.d.ts +1 -1
- package/dist/primitives/thread/ThreadScrollToBottom.d.ts +1 -1
- package/dist/primitives/thread/ThreadSuggestion.d.ts +1 -1
- package/dist/primitives/thread/ThreadSuggestions.js +1 -2
- package/dist/primitives/thread/ThreadViewport.d.ts +1 -1
- package/dist/primitives/thread/ThreadViewportFooter.d.ts +1 -1
- package/dist/primitives/thread/useThreadViewportAutoScroll.d.ts.map +1 -1
- package/dist/primitives/thread/useThreadViewportAutoScroll.js +6 -3
- package/dist/primitives/thread/useThreadViewportAutoScroll.js.map +1 -1
- package/dist/primitives/threadList/ThreadListItems.js +1 -2
- package/dist/primitives/threadList/ThreadListLoadMore.d.ts +1 -1
- package/dist/primitives/threadList/ThreadListNew.d.ts +1 -1
- package/dist/primitives/threadList/ThreadListRoot.d.ts +1 -1
- package/dist/primitives/threadListFocusGroup.d.ts +1 -1
- package/dist/primitives/threadListFocusGroup.d.ts.map +1 -1
- package/dist/primitives/threadListItem/ThreadListItemArchive.d.ts +1 -1
- package/dist/primitives/threadListItem/ThreadListItemDelete.d.ts +1 -1
- package/dist/primitives/threadListItem/ThreadListItemRoot.d.ts +1 -1
- package/dist/primitives/threadListItem/ThreadListItemTitle.js +1 -2
- package/dist/primitives/threadListItem/ThreadListItemTrigger.d.ts +1 -1
- package/dist/primitives/threadListItem/ThreadListItemUnarchive.d.ts +2 -2
- package/dist/primitives/threadListItem/ThreadListItemUnarchive.d.ts.map +1 -1
- package/dist/primitives/threadListItem/ThreadListItemUnarchive.js +2 -2
- package/dist/primitives/threadListItem/ThreadListItemUnarchive.js.map +1 -1
- package/dist/unstable/useComposerInput.js +1 -1
- package/dist/unstable/useComposerInput.js.map +1 -1
- package/dist/unstable/useComposerInputHistory.d.ts.map +1 -1
- package/dist/unstable/useComposerInputHistory.js +2 -2
- package/dist/unstable/useComposerInputHistory.js.map +1 -1
- package/dist/unstable/useLiveCompletionAdapter.d.ts.map +1 -1
- package/dist/unstable/useLiveCompletionAdapter.js +3 -2
- package/dist/unstable/useLiveCompletionAdapter.js.map +1 -1
- package/dist/utils/Primitive.d.ts +17 -17
- package/dist/utils/createActionButton.d.ts +1 -1
- package/package.json +12 -12
- package/src/adapters/OpenAIRealtimeVoiceAdapter.test.ts +14 -1
- package/src/cloud-renderer/CloudRendererHost.tsx +4 -2
- package/src/index.ts +9 -8
- package/src/internal.ts +1 -1
- package/src/legacy-runtime/AssistantRuntimeProvider.tsx +1 -1
- package/src/primitives/actionBar/ActionBarCopy.test.tsx +57 -0
- package/src/primitives/actionBar/ActionBarExportMarkdown.test.tsx +24 -5
- package/src/primitives/assistantModal/AssistantModalRoot.test.tsx +1 -1
- package/src/primitives/composer/ComposerInput.focus-on-run-start.test.tsx +1 -1
- package/src/primitives/composer/ComposerInput.test.tsx +1 -0
- package/src/primitives/composer/ComposerInput.text-change.test.tsx +68 -0
- package/src/primitives/composer/ComposerInput.thread-scope.test.tsx +82 -0
- package/src/primitives/composer/ComposerInput.tsx +4 -3
- package/src/primitives/composer/trigger/triggerSelectionResource.test.ts +6 -4
- package/src/primitives/composer/trigger/triggerSelectionResource.ts +2 -0
- package/src/primitives/thread/ThreadRoot.test.tsx +1 -1
- package/src/primitives/thread/ThreadViewport.thread-scope.test.tsx +51 -0
- package/src/primitives/thread/useThreadViewportAutoScroll.ts +8 -2
- package/src/primitives/threadListItem/ThreadListItemUnarchive.test.tsx +52 -0
- package/src/primitives/threadListItem/ThreadListItemUnarchive.ts +2 -2
- package/src/tests/DataRenderers.test.tsx +1 -1
- package/src/tests/MessageParts.loading.test.tsx +1 -1
- package/src/tests/RemoteThreadListRuntime.adapterProvider.test.tsx +1 -1
- package/src/tests/RemoteThreadListRuntime.deferredProvider.test.tsx +4 -2
- package/src/tests/RemoteThreadListRuntime.reloadMainThread.test.tsx +4 -2
- package/src/tests/generative-ui.primitive.test.tsx +1 -1
- package/src/tests/local-runtime-queue.test.tsx +2 -2
- package/src/tests/messagePartSwitchRace.test.tsx +2 -2
- package/src/tests/messagePartTypeMismatch.test.tsx +1 -1
- package/src/tests/threadListItemIsRunning.test.tsx +5 -3
- package/src/tests/toolCallTiming.test.tsx +1 -1
- package/src/unstable/useComposerInput.test.tsx +1 -1
- package/src/unstable/useComposerInput.ts +1 -1
- package/src/unstable/useComposerInputHistory.test.tsx +10 -7
- package/src/unstable/useComposerInputHistory.thread-scope.test.tsx +123 -0
- package/src/unstable/useComposerInputHistory.ts +3 -2
- package/src/unstable/useLiveCompletionAdapter.test.tsx +44 -0
- package/src/unstable/useLiveCompletionAdapter.ts +3 -2
- package/src/unstable/webmcp/convertTools.test.ts +11 -1
- package/src/utils/hooks/useMediaQuery.test.tsx +35 -0
- package/src/utils/smooth/useSmooth.test.tsx +37 -10
- package/dist/context/providers/ChainOfThoughtPartByIndexProvider.d.ts +0 -2
- package/dist/context/providers/ChainOfThoughtPartByIndexProvider.d.ts.map +0 -1
- package/dist/context/providers/ChainOfThoughtPartByIndexProvider.js +0 -3
- package/dist/legacy-runtime/RuntimeAdapter.d.ts +0 -2
- package/dist/legacy-runtime/RuntimeAdapter.d.ts.map +0 -1
- package/dist/legacy-runtime/RuntimeAdapter.js +0 -2
- package/dist/legacy-runtime/cloud/AssistantCloudThreadHistoryAdapter.d.ts +0 -2
- package/dist/legacy-runtime/cloud/AssistantCloudThreadHistoryAdapter.d.ts.map +0 -1
- package/dist/legacy-runtime/cloud/AssistantCloudThreadHistoryAdapter.js +0 -3
- package/dist/legacy-runtime/runtime/AssistantRuntime.d.ts +0 -3
- package/dist/legacy-runtime/runtime/AssistantRuntime.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime/AssistantRuntime.js +0 -2
- package/dist/legacy-runtime/runtime/AttachmentRuntime.d.ts +0 -3
- package/dist/legacy-runtime/runtime/AttachmentRuntime.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime/AttachmentRuntime.js +0 -2
- package/dist/legacy-runtime/runtime/ComposerRuntime.d.ts +0 -4
- package/dist/legacy-runtime/runtime/ComposerRuntime.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime/ComposerRuntime.js +0 -2
- package/dist/legacy-runtime/runtime/RuntimeBindings.d.ts +0 -3
- package/dist/legacy-runtime/runtime/RuntimeBindings.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime/RuntimeBindings.js +0 -0
- package/dist/legacy-runtime/runtime/RuntimePathTypes.d.ts +0 -2
- package/dist/legacy-runtime/runtime/RuntimePathTypes.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime/RuntimePathTypes.js +0 -0
- package/dist/legacy-runtime/runtime/ThreadListItemRuntime.d.ts +0 -5
- package/dist/legacy-runtime/runtime/ThreadListItemRuntime.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime/ThreadListItemRuntime.js +0 -2
- package/dist/legacy-runtime/runtime/ThreadRuntime.d.ts +0 -4
- package/dist/legacy-runtime/runtime/ThreadRuntime.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime/ThreadRuntime.js +0 -2
- package/dist/legacy-runtime/runtime-cores/adapters/RuntimeAdapterProvider.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/adapters/RuntimeAdapterProvider.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/adapters/RuntimeAdapterProvider.js +0 -3
- package/dist/legacy-runtime/runtime-cores/adapters/attachment/CloudFileAttachmentAdapter.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/adapters/attachment/CloudFileAttachmentAdapter.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/adapters/attachment/CloudFileAttachmentAdapter.js +0 -3
- package/dist/legacy-runtime/runtime-cores/composer/BaseComposerRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/composer/BaseComposerRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/composer/BaseComposerRuntimeCore.js +0 -2
- package/dist/legacy-runtime/runtime-cores/composer/DefaultEditComposerRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/composer/DefaultEditComposerRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/composer/DefaultEditComposerRuntimeCore.js +0 -2
- package/dist/legacy-runtime/runtime-cores/composer/DefaultThreadComposerRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/composer/DefaultThreadComposerRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/composer/DefaultThreadComposerRuntimeCore.js +0 -2
- package/dist/legacy-runtime/runtime-cores/core/AssistantRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/core/AssistantRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/core/AssistantRuntimeCore.js +0 -0
- package/dist/legacy-runtime/runtime-cores/core/BaseAssistantRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/core/BaseAssistantRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/core/BaseAssistantRuntimeCore.js +0 -2
- package/dist/legacy-runtime/runtime-cores/core/BaseThreadRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/core/BaseThreadRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/core/BaseThreadRuntimeCore.js +0 -2
- package/dist/legacy-runtime/runtime-cores/core/ComposerRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/core/ComposerRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/core/ComposerRuntimeCore.js +0 -0
- package/dist/legacy-runtime/runtime-cores/core/ThreadListRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/core/ThreadListRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/core/ThreadListRuntimeCore.js +0 -0
- package/dist/legacy-runtime/runtime-cores/core/ThreadRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/core/ThreadRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/core/ThreadRuntimeCore.js +0 -0
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreAdapter.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreAdapter.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreAdapter.js +0 -0
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreRuntimeCore.js +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreThreadListRuntimeCore.d.ts +0 -3
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreThreadListRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreThreadListRuntimeCore.js +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreThreadRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreThreadRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/external-store/ExternalStoreThreadRuntimeCore.js +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/ThreadMessageConverter.d.ts +0 -3
- package/dist/legacy-runtime/runtime-cores/external-store/ThreadMessageConverter.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/external-store/ThreadMessageConverter.js +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/ThreadMessageLike.d.ts +0 -3
- package/dist/legacy-runtime/runtime-cores/external-store/ThreadMessageLike.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/external-store/ThreadMessageLike.js +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/auto-status.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/auto-status.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/external-store/auto-status.js +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/createMessageConverter.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/createMessageConverter.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/external-store/createMessageConverter.js +0 -3
- package/dist/legacy-runtime/runtime-cores/external-store/external-message-converter.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/external-message-converter.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/external-store/external-message-converter.js +0 -3
- package/dist/legacy-runtime/runtime-cores/external-store/useExternalStoreRuntime.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/external-store/useExternalStoreRuntime.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/external-store/useExternalStoreRuntime.js +0 -3
- package/dist/legacy-runtime/runtime-cores/local/ChatModelAdapter.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/local/ChatModelAdapter.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/local/ChatModelAdapter.js +0 -0
- package/dist/legacy-runtime/runtime-cores/local/LocalRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/local/LocalRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/local/LocalRuntimeCore.js +0 -2
- package/dist/legacy-runtime/runtime-cores/local/LocalRuntimeOptions.d.ts +0 -4
- package/dist/legacy-runtime/runtime-cores/local/LocalRuntimeOptions.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/local/LocalRuntimeOptions.js +0 -2
- package/dist/legacy-runtime/runtime-cores/local/LocalThreadListRuntimeCore.d.ts +0 -3
- package/dist/legacy-runtime/runtime-cores/local/LocalThreadListRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/local/LocalThreadListRuntimeCore.js +0 -2
- package/dist/legacy-runtime/runtime-cores/local/LocalThreadRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/local/LocalThreadRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/local/LocalThreadRuntimeCore.js +0 -2
- package/dist/legacy-runtime/runtime-cores/local/shouldContinue.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/local/shouldContinue.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/local/shouldContinue.js +0 -2
- package/dist/legacy-runtime/runtime-cores/local/useLocalRuntime.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/local/useLocalRuntime.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/local/useLocalRuntime.js +0 -3
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/BaseSubscribable.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/BaseSubscribable.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/BaseSubscribable.js +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/EMPTY_THREAD_CORE.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/EMPTY_THREAD_CORE.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/EMPTY_THREAD_CORE.js +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/OptimisticState.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/OptimisticState.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/OptimisticState.js +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/RemoteThreadListHookInstanceManager.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/RemoteThreadListHookInstanceManager.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/RemoteThreadListHookInstanceManager.js +0 -3
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/RemoteThreadListThreadListRuntimeCore.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/RemoteThreadListThreadListRuntimeCore.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/RemoteThreadListThreadListRuntimeCore.js +0 -3
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/adapter/cloud.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/adapter/cloud.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/adapter/cloud.js +0 -3
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/adapter/in-memory.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/adapter/in-memory.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/adapter/in-memory.js +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/types.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/types.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/types.js +0 -0
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/useRemoteThreadListRuntime.d.ts +0 -2
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/useRemoteThreadListRuntime.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/remote-thread-list/useRemoteThreadListRuntime.js +0 -3
- package/dist/legacy-runtime/runtime-cores/utils/MessageRepository.d.ts +0 -4
- package/dist/legacy-runtime/runtime-cores/utils/MessageRepository.d.ts.map +0 -1
- package/dist/legacy-runtime/runtime-cores/utils/MessageRepository.js +0 -3
- package/dist/utils/hooks/useOnResizeContent.d.ts +0 -2
- package/dist/utils/hooks/useOnResizeContent.d.ts.map +0 -1
- package/dist/utils/hooks/useOnResizeContent.js +0 -21
- package/dist/utils/hooks/useOnResizeContent.js.map +0 -1
- package/src/context/providers/ChainOfThoughtPartByIndexProvider.tsx +0 -3
- package/src/legacy-runtime/RuntimeAdapter.ts +0 -1
- package/src/legacy-runtime/cloud/AssistantCloudThreadHistoryAdapter.ts +0 -3
- package/src/legacy-runtime/runtime/AssistantRuntime.ts +0 -2
- package/src/legacy-runtime/runtime/AttachmentRuntime.ts +0 -7
- package/src/legacy-runtime/runtime/ComposerRuntime.ts +0 -20
- package/src/legacy-runtime/runtime/RuntimeBindings.ts +0 -12
- package/src/legacy-runtime/runtime/RuntimePathTypes.ts +0 -8
- package/src/legacy-runtime/runtime/ThreadListItemRuntime.ts +0 -10
- package/src/legacy-runtime/runtime/ThreadRuntime.ts +0 -14
- package/src/legacy-runtime/runtime-cores/adapters/RuntimeAdapterProvider.tsx +0 -7
- package/src/legacy-runtime/runtime-cores/adapters/attachment/CloudFileAttachmentAdapter.ts +0 -3
- package/src/legacy-runtime/runtime-cores/composer/BaseComposerRuntimeCore.ts +0 -1
- package/src/legacy-runtime/runtime-cores/composer/DefaultEditComposerRuntimeCore.ts +0 -1
- package/src/legacy-runtime/runtime-cores/composer/DefaultThreadComposerRuntimeCore.ts +0 -1
- package/src/legacy-runtime/runtime-cores/core/AssistantRuntimeCore.ts +0 -1
- package/src/legacy-runtime/runtime-cores/core/BaseAssistantRuntimeCore.ts +0 -1
- package/src/legacy-runtime/runtime-cores/core/BaseThreadRuntimeCore.ts +0 -1
- package/src/legacy-runtime/runtime-cores/core/ComposerRuntimeCore.ts +0 -6
- package/src/legacy-runtime/runtime-cores/core/ThreadListRuntimeCore.ts +0 -4
- package/src/legacy-runtime/runtime-cores/core/ThreadRuntimeCore.ts +0 -13
- package/src/legacy-runtime/runtime-cores/external-store/ExternalStoreAdapter.ts +0 -6
- package/src/legacy-runtime/runtime-cores/external-store/ExternalStoreRuntimeCore.ts +0 -1
- package/src/legacy-runtime/runtime-cores/external-store/ExternalStoreThreadListRuntimeCore.ts +0 -2
- package/src/legacy-runtime/runtime-cores/external-store/ExternalStoreThreadRuntimeCore.ts +0 -4
- package/src/legacy-runtime/runtime-cores/external-store/ThreadMessageConverter.ts +0 -2
- package/src/legacy-runtime/runtime-cores/external-store/ThreadMessageLike.ts +0 -2
- package/src/legacy-runtime/runtime-cores/external-store/auto-status.ts +0 -1
- package/src/legacy-runtime/runtime-cores/external-store/createMessageConverter.ts +0 -2
- package/src/legacy-runtime/runtime-cores/external-store/external-message-converter.ts +0 -7
- package/src/legacy-runtime/runtime-cores/external-store/useExternalStoreRuntime.ts +0 -3
- package/src/legacy-runtime/runtime-cores/local/ChatModelAdapter.ts +0 -7
- package/src/legacy-runtime/runtime-cores/local/LocalRuntimeCore.ts +0 -1
- package/src/legacy-runtime/runtime-cores/local/LocalRuntimeOptions.ts +0 -3
- package/src/legacy-runtime/runtime-cores/local/LocalThreadListRuntimeCore.ts +0 -2
- package/src/legacy-runtime/runtime-cores/local/LocalThreadRuntimeCore.ts +0 -1
- package/src/legacy-runtime/runtime-cores/local/shouldContinue.ts +0 -1
- package/src/legacy-runtime/runtime-cores/local/useLocalRuntime.ts +0 -3
- package/src/legacy-runtime/runtime-cores/remote-thread-list/BaseSubscribable.ts +0 -1
- package/src/legacy-runtime/runtime-cores/remote-thread-list/EMPTY_THREAD_CORE.ts +0 -1
- package/src/legacy-runtime/runtime-cores/remote-thread-list/OptimisticState.ts +0 -1
- package/src/legacy-runtime/runtime-cores/remote-thread-list/RemoteThreadListHookInstanceManager.tsx +0 -3
- package/src/legacy-runtime/runtime-cores/remote-thread-list/RemoteThreadListThreadListRuntimeCore.tsx +0 -3
- package/src/legacy-runtime/runtime-cores/remote-thread-list/adapter/cloud.tsx +0 -3
- package/src/legacy-runtime/runtime-cores/remote-thread-list/adapter/in-memory.ts +0 -1
- package/src/legacy-runtime/runtime-cores/remote-thread-list/types.ts +0 -7
- package/src/legacy-runtime/runtime-cores/remote-thread-list/useRemoteThreadListRuntime.ts +0 -3
- package/src/legacy-runtime/runtime-cores/utils/MessageRepository.ts +0 -3
- package/src/utils/hooks/useOnResizeContent.ts +0 -15
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CloudRendererHost.d.ts","sourceRoot":"","sources":["../../src/cloud-renderer/CloudRendererHost.tsx"],"names":[],"mappings":"AAEA,OAAO,EAGL,KAAK,SAAS,EAMf,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"CloudRendererHost.d.ts","sourceRoot":"","sources":["../../src/cloud-renderer/CloudRendererHost.tsx"],"names":[],"mappings":"AAEA,OAAO,EAGL,KAAK,SAAS,EAMf,MAAM,OAAO,CAAC;AAaf,OAAO,EAAE,wBAAwB,EAAE,sDAAmD;AA0BtF,MAAM,MAAM,sBAAsB,GAAG;IACnC,yDAAyD;IACzD,QAAQ,EAAE,SAAS,CAAC;IACpB,iGAAiG;IACjG,cAAc,CAAC,EAAE,SAAS,MAAM,EAAE,GAAG,SAAS,CAAC;IAC/C,kJAAkJ;IAClJ,GAAG,CAAC,EAAE,wBAAwB,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IAC5C,MAAM,CAAC,EAAE,wBAAwB,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC;CACnD,CAAC;AAwEF,wBAAgB,iBAAiB,CAAC,EAChC,QAAQ,EACR,cAAwC,EACxC,GAAG,EACH,MAAM,GACP,EAAE,sBAAsB,GAAG,SAAS,CAmHpC"}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { AssistantRuntimeProvider } from "../legacy-runtime/AssistantRuntimeProvider.js";
|
|
3
|
-
import { useExternalStoreRuntime } from "../legacy-runtime/runtime-cores/external-store/useExternalStoreRuntime.js";
|
|
4
3
|
import { c } from "@assistant-ui/tap/react-shim/compiler-runtime";
|
|
5
|
-
import { ReadonlyThreadProvider } from "@assistant-ui/core/react";
|
|
4
|
+
import { ReadonlyThreadProvider, useExternalStoreRuntime } from "@assistant-ui/core/react";
|
|
6
5
|
import { Component, useEffect, useRef, useState, useSyncExternalStore } from "@assistant-ui/tap/react-shim";
|
|
7
6
|
import { AuiConfig, AuiProvider, useAui } from "@assistant-ui/store";
|
|
8
7
|
import { resource } from "@assistant-ui/tap";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CloudRendererHost.js","names":["c","_c","Component","ErrorInfo","ReactNode","useEffect","useMemo","useRef","useState","useSyncExternalStore","AuiConfig","AuiProvider","useAui","AssistantClient","resource","ReadonlyThreadProvider","ThreadMessage","AssistantRuntimeProvider","useExternalStoreRuntime","CHANNEL","toOrigin","value","url","URL","protocol","origin","undefined","DEFAULT_ALLOWED_ORIGINS","INERT_STORE","messages","isDisabled","onNew","HostMessage","channel","version","type","height","message","CloudRendererHostProps","children","allowedOrigins","aui","Props","config","RenderBoundary","onError","error","Error","failed","state","getDerivedStateFromError","componentDidCatch","_info","props","render","useReadonlyTools","$","tools","subscribe","getState","t0","mcpApp","t1","t2","setToolUI","ReadonlyTools","SuppressMcpApps","ReadonlyConversation","runtime","t3","t4","CloudRendererHost","rootRef","connectedOrigin","setRender","flatMap","_temp","join","originsKey","origins","split","current","includes","post","_temp2","origin_0","onMessage","event","source","window","parent","data","message_0","Record","Array","isArray","previous","revision","addEventListener","removeEventListener","t5","t6","root","frame","report","requestAnimationFrame","origin_1","getBoundingClientRect","Number","isFinite","postMessage","observer","ResizeObserver","observe","disconnect","cancelAnimationFrame","t7","Symbol","for","origin_2","reportError","t8","t9","node","inert","width","t10","t11","_c"],"sources":["../../src/cloud-renderer/CloudRendererHost.tsx"],"sourcesContent":["\"use client\";\n\nimport {\n Component,\n type ErrorInfo,\n type ReactNode,\n useEffect,\n useMemo,\n useRef,\n useState,\n useSyncExternalStore,\n} from \"react\";\nimport {\n AuiConfig,\n AuiProvider,\n useAui,\n type AssistantClient,\n} from \"@assistant-ui/store\";\nimport { resource } from \"@assistant-ui/tap\";\nimport { ReadonlyThreadProvider } from \"@assistant-ui/core/react\";\nimport type { ThreadMessage } from \"@assistant-ui/core\";\nimport { AssistantRuntimeProvider } from \"../legacy-runtime/AssistantRuntimeProvider\";\nimport { useExternalStoreRuntime } from \"../legacy-runtime/runtime-cores/external-store/useExternalStoreRuntime\";\n\nconst CHANNEL = \"assistant-ui/cloud-renderer\";\n\nconst toOrigin = (value: string) => {\n try {\n const url = new URL(value);\n return url.protocol === \"https:\" || url.protocol === \"http:\"\n ? url.origin\n : undefined;\n } catch {\n return undefined;\n }\n};\nconst DEFAULT_ALLOWED_ORIGINS = [\"https://cloud.assistant-ui.com\"];\nconst INERT_STORE = {\n messages: [] as ThreadMessage[],\n isDisabled: true,\n onNew: async () => {},\n};\n\ntype HostMessage =\n | { channel: typeof CHANNEL; version: 1; type: \"ready\" }\n | { channel: typeof CHANNEL; version: 1; type: \"size\"; height: number }\n | { channel: typeof CHANNEL; version: 1; type: \"error\"; message: string };\n\nexport type CloudRendererHostProps = {\n /** The app's thread UI, usually its own `<Thread />`. */\n children: ReactNode;\n /** Dashboard origins allowed to send a conversation. Defaults to Assistant Cloud's dashboard. */\n allowedOrigins?: readonly string[] | undefined;\n /** The same client or config the app passes to AssistantRuntimeProvider, so tool UIs, data UIs and generative UI render as they do in the app. */\n aui?: AssistantRuntimeProvider.Props[\"aui\"];\n config?: AssistantRuntimeProvider.Props[\"config\"];\n};\n\nclass RenderBoundary extends Component<\n { children: ReactNode; onError: (error: Error) => void },\n { failed: boolean }\n> {\n override state = { failed: false };\n\n static getDerivedStateFromError() {\n return { failed: true };\n }\n\n override componentDidCatch(error: Error, _info: ErrorInfo) {\n this.props.onError(error);\n }\n\n override render() {\n return this.state.failed ? null : this.props.children;\n }\n}\n\nconst useReadonlyTools = (aui: AssistantClient) => {\n const tools = useSyncExternalStore(aui.subscribe, aui.tools.getState);\n const state = useMemo(() => ({ ...tools, mcpApp: undefined }), [tools]);\n return {\n getState: () => state,\n setToolUI: aui.tools.setToolUI,\n };\n};\n\nconst ReadonlyTools = resource(useReadonlyTools);\n\nconst SuppressMcpApps = ({ children }: { children: ReactNode }) => {\n const aui = useAui();\n return (\n <AuiProvider\n extends={aui}\n config={AuiConfig({ tools: ReadonlyTools(aui) })}\n >\n {children}\n </AuiProvider>\n );\n};\n\nconst ReadonlyConversation = ({\n messages,\n children,\n aui,\n config,\n}: {\n messages: readonly ThreadMessage[];\n children: ReactNode;\n aui: CloudRendererHostProps[\"aui\"];\n config: CloudRendererHostProps[\"config\"];\n}) => {\n const runtime = useExternalStoreRuntime<ThreadMessage>(INERT_STORE);\n\n return (\n <AssistantRuntimeProvider\n runtime={runtime}\n {...(aui !== undefined && { aui })}\n {...(config !== undefined && { config })}\n >\n <SuppressMcpApps>\n <ReadonlyThreadProvider messages={messages}>\n {children}\n </ReadonlyThreadProvider>\n </SuppressMcpApps>\n </AssistantRuntimeProvider>\n );\n};\n\nexport function CloudRendererHost({\n children,\n allowedOrigins = DEFAULT_ALLOWED_ORIGINS,\n aui,\n config,\n}: CloudRendererHostProps): ReactNode {\n const rootRef = useRef<HTMLDivElement>(null);\n const connectedOrigin = useRef<string | null>(null);\n const [render, setRender] = useState<{\n messages: readonly ThreadMessage[];\n revision: number;\n } | null>(null);\n\n const originsKey = allowedOrigins\n .flatMap((value) => toOrigin(value) ?? [])\n .join(\" \");\n\n useEffect(() => {\n const origins = originsKey ? originsKey.split(\" \") : [];\n if (\n connectedOrigin.current !== null &&\n !origins.includes(connectedOrigin.current)\n ) {\n connectedOrigin.current = null;\n }\n const post = (origin: string, message: HostMessage) =>\n window.parent.postMessage(message, origin);\n\n for (const origin of origins) {\n post(origin, { channel: CHANNEL, version: 1, type: \"ready\" });\n }\n\n const onMessage = (event: MessageEvent) => {\n if (event.source !== window.parent || !origins.includes(event.origin))\n return;\n const data: unknown = event.data;\n if (typeof data !== \"object\" || data === null) return;\n const message = data as Record<string, unknown>;\n if (\n message.channel !== CHANNEL ||\n message.version !== 1 ||\n message.type !== \"render\" ||\n !Array.isArray(message.messages)\n )\n return;\n if (\n connectedOrigin.current !== null &&\n connectedOrigin.current !== event.origin\n )\n return;\n\n connectedOrigin.current = event.origin;\n setRender((previous) => ({\n messages: message.messages as ThreadMessage[],\n revision: (previous?.revision ?? 0) + 1,\n }));\n };\n\n window.addEventListener(\"message\", onMessage);\n return () => window.removeEventListener(\"message\", onMessage);\n }, [originsKey]);\n\n useEffect(() => {\n if (!render || !rootRef.current) return;\n const root = rootRef.current;\n let frame = 0;\n const report = () => {\n if (frame) return;\n frame = requestAnimationFrame(() => {\n frame = 0;\n const origin = connectedOrigin.current;\n const height = root.getBoundingClientRect().height;\n if (origin && Number.isFinite(height) && height >= 0) {\n window.parent.postMessage(\n { channel: CHANNEL, version: 1, type: \"size\", height },\n origin,\n );\n }\n });\n };\n const observer = new ResizeObserver(report);\n observer.observe(root);\n report();\n return () => {\n observer.disconnect();\n cancelAnimationFrame(frame);\n };\n }, [render]);\n\n const reportError = (error: Error) => {\n const origin = connectedOrigin.current;\n if (origin) {\n window.parent.postMessage(\n { channel: CHANNEL, version: 1, type: \"error\", message: error.message },\n origin,\n );\n }\n };\n\n return (\n <div\n ref={(node) => {\n rootRef.current = node;\n if (node) node.inert = true;\n }}\n style={{ width: \"100%\" }}\n >\n {render && (\n <RenderBoundary key={render.revision} onError={reportError}>\n <ReadonlyConversation\n messages={render.messages}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AAK;EAEvBF,KAAA,EAAAG,OAAS,OAAO;EAACrE,EAAA,KAAAiE;EAAAjE,EAAA,MAAAkE;CAAA,OAAA;EAAAD,KAAAjE,EAAA;EAAAkE,KAAAlE,EAAA;CAAA;CAAA,IAAAsE;CAAA,IAAAtE,EAAA,QAAAf,OAAAe,EAAA,QAAAjB,YAAAiB,EAAA,QAAAb,UAAAa,EAAA,QAAAF,QAAA;EAEvBwE,MAAAxE,UACC,oBAAC,gBAAD;GAA+CkE,SAAAA;GAC7C,UAAA,oBAAC,sBAAD;IACY,UAAAlE,OAAMzB;IACXY;IACGE;IAEPJ;GALkB,CAAA;EADR,GAAMe,OAAM2C,QAAZ;EAShBzC,EAAA,MAAAf;EAAAe,EAAA,MAAAjB;EAAAiB,EAAA,MAAAb;EAAAa,EAAA,MAAAF;EAAAE,EAAA,MAAAsE;CAAA,OAAAA,MAAAtE,EAAA;CAAA,IAAAuE;CAAA,IAAAvE,EAAA,QAAAsE,KAAA;EAjBHC,MAAA,oBAAA,OAAA;GACO,KAAAN;GAIE,OAAAC;GAENI,UAAAA;EAWG,CAAA;EAAAtE,EAAA,MAAAsE;EAAAtE,EAAA,MAAAuE;CAAA,OAAAA,MAAAvE,EAAA;CAAA,OAlBNuE;AAkBM;AAtHH,SAAA3C,OAAA3D,QAAAY,SAAA;CAAA,OA0BDoD,OAAMC,OAAOoB,YAAazE,SAASZ,MAAM;AAAC;AA1BzC,SAAAmD,MAAAvD,OAAA;CAAA,OAciBD,SAASC,KAAW,KAApB,CAAA;AAAqB"}
|
|
1
|
+
{"version":3,"file":"CloudRendererHost.js","names":["c","_c","Component","ErrorInfo","ReactNode","useEffect","useMemo","useRef","useState","useSyncExternalStore","AuiConfig","AuiProvider","useAui","AssistantClient","resource","ReadonlyThreadProvider","useExternalStoreRuntime","ThreadMessage","AssistantRuntimeProvider","CHANNEL","toOrigin","value","url","URL","protocol","origin","undefined","DEFAULT_ALLOWED_ORIGINS","INERT_STORE","messages","isDisabled","onNew","HostMessage","channel","version","type","height","message","CloudRendererHostProps","children","allowedOrigins","aui","Props","config","RenderBoundary","onError","error","Error","failed","state","getDerivedStateFromError","componentDidCatch","_info","props","render","useReadonlyTools","$","tools","subscribe","getState","t0","mcpApp","t1","t2","setToolUI","ReadonlyTools","SuppressMcpApps","ReadonlyConversation","runtime","t3","t4","CloudRendererHost","rootRef","connectedOrigin","setRender","flatMap","_temp","join","originsKey","origins","split","current","includes","post","_temp2","origin_0","onMessage","event","source","window","parent","data","message_0","Record","Array","isArray","previous","revision","addEventListener","removeEventListener","t5","t6","root","frame","report","requestAnimationFrame","origin_1","getBoundingClientRect","Number","isFinite","postMessage","observer","ResizeObserver","observe","disconnect","cancelAnimationFrame","t7","Symbol","for","origin_2","reportError","t8","t9","node","inert","width","t10","t11","_c"],"sources":["../../src/cloud-renderer/CloudRendererHost.tsx"],"sourcesContent":["\"use client\";\n\nimport {\n Component,\n type ErrorInfo,\n type ReactNode,\n useEffect,\n useMemo,\n useRef,\n useState,\n useSyncExternalStore,\n} from \"react\";\nimport {\n AuiConfig,\n AuiProvider,\n useAui,\n type AssistantClient,\n} from \"@assistant-ui/store\";\nimport { resource } from \"@assistant-ui/tap\";\nimport {\n ReadonlyThreadProvider,\n useExternalStoreRuntime,\n} from \"@assistant-ui/core/react\";\nimport type { ThreadMessage } from \"@assistant-ui/core\";\nimport { AssistantRuntimeProvider } from \"../legacy-runtime/AssistantRuntimeProvider\";\n\nconst CHANNEL = \"assistant-ui/cloud-renderer\";\n\nconst toOrigin = (value: string) => {\n try {\n const url = new URL(value);\n return url.protocol === \"https:\" || url.protocol === \"http:\"\n ? url.origin\n : undefined;\n } catch {\n return undefined;\n }\n};\nconst DEFAULT_ALLOWED_ORIGINS = [\"https://cloud.assistant-ui.com\"];\nconst INERT_STORE = {\n messages: [] as ThreadMessage[],\n isDisabled: true,\n onNew: async () => {},\n};\n\ntype HostMessage =\n | { channel: typeof CHANNEL; version: 1; type: \"ready\" }\n | { channel: typeof CHANNEL; version: 1; type: \"size\"; height: number }\n | { channel: typeof CHANNEL; version: 1; type: \"error\"; message: string };\n\nexport type CloudRendererHostProps = {\n /** The app's thread UI, usually its own `<Thread />`. */\n children: ReactNode;\n /** Dashboard origins allowed to send a conversation. Defaults to Assistant Cloud's dashboard. */\n allowedOrigins?: readonly string[] | undefined;\n /** The same client or config the app passes to AssistantRuntimeProvider, so tool UIs, data UIs and generative UI render as they do in the app. */\n aui?: AssistantRuntimeProvider.Props[\"aui\"];\n config?: AssistantRuntimeProvider.Props[\"config\"];\n};\n\nclass RenderBoundary extends Component<\n { children: ReactNode; onError: (error: Error) => void },\n { failed: boolean }\n> {\n override state = { failed: false };\n\n static getDerivedStateFromError() {\n return { failed: true };\n }\n\n override componentDidCatch(error: Error, _info: ErrorInfo) {\n this.props.onError(error);\n }\n\n override render() {\n return this.state.failed ? null : this.props.children;\n }\n}\n\nconst useReadonlyTools = (aui: AssistantClient) => {\n const tools = useSyncExternalStore(aui.subscribe, aui.tools.getState);\n const state = useMemo(() => ({ ...tools, mcpApp: undefined }), [tools]);\n return {\n getState: () => state,\n setToolUI: aui.tools.setToolUI,\n };\n};\n\nconst ReadonlyTools = resource(useReadonlyTools);\n\nconst SuppressMcpApps = ({ children }: { children: ReactNode }) => {\n const aui = useAui();\n return (\n <AuiProvider\n extends={aui}\n config={AuiConfig({ tools: ReadonlyTools(aui) })}\n >\n {children}\n </AuiProvider>\n );\n};\n\nconst ReadonlyConversation = ({\n messages,\n children,\n aui,\n config,\n}: {\n messages: readonly ThreadMessage[];\n children: ReactNode;\n aui: CloudRendererHostProps[\"aui\"];\n config: CloudRendererHostProps[\"config\"];\n}) => {\n const runtime = useExternalStoreRuntime<ThreadMessage>(INERT_STORE);\n\n return (\n <AssistantRuntimeProvider\n runtime={runtime}\n {...(aui !== undefined && { aui })}\n {...(config !== undefined && { config })}\n >\n <SuppressMcpApps>\n <ReadonlyThreadProvider messages={messages}>\n {children}\n </ReadonlyThreadProvider>\n </SuppressMcpApps>\n </AssistantRuntimeProvider>\n );\n};\n\nexport function CloudRendererHost({\n children,\n allowedOrigins = DEFAULT_ALLOWED_ORIGINS,\n aui,\n config,\n}: CloudRendererHostProps): ReactNode {\n const rootRef = useRef<HTMLDivElement>(null);\n const connectedOrigin = useRef<string | null>(null);\n const [render, setRender] = useState<{\n messages: readonly ThreadMessage[];\n revision: number;\n } | null>(null);\n\n const originsKey = allowedOrigins\n .flatMap((value) => toOrigin(value) ?? [])\n .join(\" \");\n\n useEffect(() => {\n const origins = originsKey ? originsKey.split(\" \") : [];\n if (\n connectedOrigin.current !== null &&\n !origins.includes(connectedOrigin.current)\n ) {\n connectedOrigin.current = null;\n }\n const post = (origin: string, message: HostMessage) =>\n window.parent.postMessage(message, origin);\n\n for (const origin of origins) {\n post(origin, { channel: CHANNEL, version: 1, type: \"ready\" });\n }\n\n const onMessage = (event: MessageEvent) => {\n if (event.source !== window.parent || !origins.includes(event.origin))\n return;\n const data: unknown = event.data;\n if (typeof data !== \"object\" || data === null) return;\n const message = data as Record<string, unknown>;\n if (\n message.channel !== CHANNEL ||\n message.version !== 1 ||\n message.type !== \"render\" ||\n !Array.isArray(message.messages)\n )\n return;\n if (\n connectedOrigin.current !== null &&\n connectedOrigin.current !== event.origin\n )\n return;\n\n connectedOrigin.current = event.origin;\n setRender((previous) => ({\n messages: message.messages as ThreadMessage[],\n revision: (previous?.revision ?? 0) + 1,\n }));\n };\n\n window.addEventListener(\"message\", onMessage);\n return () => window.removeEventListener(\"message\", onMessage);\n }, [originsKey]);\n\n useEffect(() => {\n if (!render || !rootRef.current) return;\n const root = rootRef.current;\n let frame = 0;\n const report = () => {\n if (frame) return;\n frame = requestAnimationFrame(() => {\n frame = 0;\n const origin = connectedOrigin.current;\n const height = root.getBoundingClientRect().height;\n if (origin && Number.isFinite(height) && height >= 0) {\n window.parent.postMessage(\n { channel: CHANNEL, version: 1, type: \"size\", height },\n origin,\n );\n }\n });\n };\n const observer = new ResizeObserver(report);\n observer.observe(root);\n report();\n return () => {\n observer.disconnect();\n cancelAnimationFrame(frame);\n };\n }, [render]);\n\n const reportError = (error: Error) => {\n const origin = connectedOrigin.current;\n if (origin) {\n window.parent.postMessage(\n { channel: CHANNEL, version: 1, type: \"error\", message: error.message },\n origin,\n );\n }\n };\n\n return (\n <div\n ref={(node) => {\n rootRef.current = node;\n if (node) node.inert = true;\n }}\n style={{ width: \"100%\" }}\n >\n {render && (\n <RenderBoundary key={render.revision} onError={reportError}>\n <ReadonlyConversation\n messages={render.messages}\n aui={aui}\n config={config}\n >\n {children}\n </ReadonlyConversation>\n </RenderBoundary>\n )}\n </div>\n );\n}\n"],"mappings":";;;;;;;;;AA0BA,MAAMmB,UAAU;AAEhB,MAAMC,YAAYC,UAAkB;CAClC,IAAI;EACF,MAAMC,MAAM,IAAIC,IAAIF,KAAK;EACzB,OAAOC,IAAIE,aAAa,YAAYF,IAAIE,aAAa,UACjDF,IAAIG,SACJC,KAAAA;CACN,QAAQ;EACN;CACF;AACF;AACA,MAAMC,0BAA0B,CAAC,gCAAgC;AACjE,MAAMC,cAAc;CAClBC,UAAU,CAAA;CACVC,YAAY;CACZC,OAAO,YAAY,CAAC;AACtB;AAiBA,IAAMa,iBAAN,cAA6B1C,UAG3B;CACA,QAAiB,EAAE8C,QAAQ,MAAM;CAEjC,OAAOE,2BAA2B;EAChC,OAAO,EAAEF,QAAQ,KAAK;CACxB;CAEA,kBAA2BF,OAAcM,OAAkB;EACzD,KAAKC,MAAMR,QAAQC,KAAK;CAC1B;CAEA,SAAkB;EAChB,OAAO,KAAKG,MAAMD,SAAS,OAAO,KAAKK,MAAMd;CAC/C;AACF;AAEA,MAAMgB,oBAAmBd,QAAA;CAAA,MAAAe,IAAAvD,EAAA,CAAA;CACvB,MAAAwD,QAAchD,qBAAqBgC,IAAGiB,WAAYjB,IAAGgB,MAAME,QAAS;CAAE,IAAAC;CAAA,IAAAJ,EAAA,OAAAC,OAAA;EACzCG,KAAA;GAAA,GAAKH;GAAKI,QAAUnC,K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AASC,KAAW,KAApB,CAAA;AAAqB"}
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
|
|
3
|
-
export { ComposerAttachmentByIndexProvider, MessageAttachmentByIndexProvider };
|
|
2
|
+
export { ComposerAttachmentByIndexProvider, MessageAttachmentByIndexProvider } from "@assistant-ui/core/react";
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
|
|
3
|
-
export { ThreadListItemByIndexProvider, ThreadListItemRuntimeProvider };
|
|
2
|
+
export { ThreadListItemByIndexProvider, ThreadListItemRuntimeProvider } from "@assistant-ui/core/react";
|
package/dist/index.d.ts
CHANGED
|
@@ -6,7 +6,7 @@ export { useCloudThreadListRuntime } from "@assistant-ui/core/react";
|
|
|
6
6
|
export { AssistantCloud, readAnonymousRefreshToken } from "assistant-cloud";
|
|
7
7
|
export type { AttachmentAdapter } from "@assistant-ui/core";
|
|
8
8
|
export { SimpleImageAttachmentAdapter, SimpleTextAttachmentAdapter, CompositeAttachmentAdapter, } from "@assistant-ui/core";
|
|
9
|
-
export { CloudFileAttachmentAdapter } from "
|
|
9
|
+
export { CloudFileAttachmentAdapter } from "@assistant-ui/core/react";
|
|
10
10
|
export type { RealtimeVoiceAdapter } from "@assistant-ui/core";
|
|
11
11
|
export { createVoiceSession } from "@assistant-ui/core";
|
|
12
12
|
export { OpenAIRealtimeVoiceAdapter, type OpenAIRealtimeVoiceAdapterOptions, } from "./adapters/OpenAIRealtimeVoiceAdapter.js";
|
|
@@ -28,7 +28,7 @@ export { getExternalStoreMessages, bindExternalStoreMessage, pickExternalStoreSh
|
|
|
28
28
|
export type { ExternalStoreAdapter, ExternalStoreMessageConverter, ExternalStoreSharedOptions, ExternalStoreThreadListAdapter, ExternalStoreThreadData, ExternalStoreBranchChange, } from "@assistant-ui/core";
|
|
29
29
|
export { MessageNotSentError, isMessageNotSentError } from "@assistant-ui/core";
|
|
30
30
|
export { createMessageQueue, type MessageQueueDriver, type MessageQueueController, type ExternalThreadQueueAdapter, type ExternalThreadBranchAdapter, } from "@assistant-ui/core";
|
|
31
|
-
export { useExternalStoreRuntime } from "
|
|
31
|
+
export { useExternalStoreRuntime } from "@assistant-ui/core/react";
|
|
32
32
|
export { useExternalStoreSharedOptions } from "@assistant-ui/core/react";
|
|
33
33
|
export { useExternalMessageConverter,
|
|
34
34
|
/** @deprecated Experimental since 2025-01-26. Not scheduled for removal; the API may change in any release. */
|
|
@@ -36,15 +36,15 @@ convertExternalMessages as unstable_convertExternalMessages,
|
|
|
36
36
|
/** @deprecated Experimental since 2026-09-15. Not scheduled for removal; the API may change in any release. */
|
|
37
37
|
createExternalMessageConversionCache as unstable_createExternalMessageConversionCache,
|
|
38
38
|
/** @deprecated Experimental since 2026-09-15. Not scheduled for removal; the API may change in any release. */
|
|
39
|
-
type ExternalMessageConversionCache as Unstable_ExternalMessageConversionCache, } from "
|
|
39
|
+
type ExternalMessageConversionCache as Unstable_ExternalMessageConversionCache, } from "@assistant-ui/core/react";
|
|
40
40
|
export {
|
|
41
41
|
/** @deprecated Experimental since 2025-02-02. Not scheduled for removal; the API may change in any release. */
|
|
42
|
-
createMessageConverter as unstable_createMessageConverter, } from "
|
|
42
|
+
createMessageConverter as unstable_createMessageConverter, } from "@assistant-ui/core/react";
|
|
43
43
|
export type { ChatModelAdapter, ChatModelRunOptions, ChatModelRunResult, ChatModelRunUpdate, LocalRuntimeOptionsBase, } from "@assistant-ui/core";
|
|
44
|
-
export { useLocalRuntime } from "
|
|
45
|
-
export type { LocalRuntimeOptions } from "
|
|
46
|
-
export { useRemoteThreadListRuntime } from "
|
|
47
|
-
export { useCloudThreadListAdapter } from "
|
|
44
|
+
export { useLocalRuntime } from "@assistant-ui/core/react";
|
|
45
|
+
export type { LocalRuntimeOptions } from "@assistant-ui/core/react";
|
|
46
|
+
export { useRemoteThreadListRuntime } from "@assistant-ui/core/react";
|
|
47
|
+
export { useCloudThreadListAdapter } from "@assistant-ui/core/react";
|
|
48
48
|
export type { RemoteThreadListAdapter, RemoteThreadListProviderComponent, } from "@assistant-ui/core";
|
|
49
49
|
export { InMemoryThreadListAdapter } from "@assistant-ui/core";
|
|
50
50
|
export type { ExportedMessageRepositoryItem } from "@assistant-ui/core";
|
|
@@ -59,6 +59,7 @@ export { tool } from "@assistant-ui/core";
|
|
|
59
59
|
export { Suggestions, type SuggestionConfig } from "@assistant-ui/core/store";
|
|
60
60
|
export type { QueueItemState, TaskState, TaskMethods, QueueItemMethods, } from "@assistant-ui/core/store";
|
|
61
61
|
export type { ComposerSendOptions } from "@assistant-ui/core/store";
|
|
62
|
+
export type { ComposerTextOrigin } from "@assistant-ui/core";
|
|
62
63
|
export { makeAssistantVisible } from "./model-context/makeAssistantVisible.js";
|
|
63
64
|
export { ModelContextRegistry } from "@assistant-ui/core";
|
|
64
65
|
export type { ModelContextRegistryToolHandle, ModelContextRegistryInstructionHandle, ModelContextRegistryProviderHandle, } from "@assistant-ui/core";
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAGA,OAAO,EACL,MAAM,EACN,WAAW,EACX,SAAS,EACT,WAAW,EACX,WAAW,EACX,KAAK,EACL,KAAK,eAAe,EACpB,KAAK,cAAc,EACnB,KAAK,mBAAmB,EACxB,KAAK,sBAAsB,EAC3B,KAAK,kBAAkB,EACvB,KAAK,qBAAqB,EAC1B,KAAK,sBAAsB,GAC5B,MAAM,qBAAqB,CAAC;AAG7B,YAAY,EACV,gBAAgB,EAChB,aAAa,EACb,WAAW,EACX,kBAAkB,EAClB,mBAAmB,EACnB,oBAAoB,EACpB,qBAAqB,EACrB,cAAc,EACd,YAAY,EACZ,mBAAmB,EACnB,kBAAkB,EAClB,gBAAgB,EAChB,eAAe,EACf,qBAAqB,EACrB,mBAAmB,EACnB,iBAAiB,EACjB,mBAAmB,EACnB,aAAa,EACb,oBAAoB,EACpB,iB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EACd,cAAc,EACd,kBAAkB,EAClB,iBAAiB,EACjB,mBAAmB,EACnB,cAAc,EACd,iBAAiB,EACjB,iBAAiB,EACjB,WAAW,EACX,wBAAwB,EACxB,oBAAoB,EACpB,sBAAsB,EACtB,oBAAoB,EACpB,8BAA8B,GAC/B,4BAAmB;AACpB,YAAY,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AACrE,YAAY,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAG3E,OAAO,EACL,0BAA0B,EAC1B,KAAK,8BAA8B,EACnC,KAAK,6BAA6B,GACnC,+CAA4C;AAC7C,OAAO;AACL,+GAA+G;AAC/G,mBAAmB,IAAI,4BAA4B,GACpD,0CAAuC;AAGxC,YAAY,EACV,YAAY,EACZ,sBAAsB,GACvB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,iCAAiC,EACjC,wBAAwB,GACzB,MAAM,0BAA0B,CAAC;AAClC,YAAY,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAC7D,YAAY,EACV,WAAW,EACX,uBAAuB,EACvB,SAAS,EACT,mBAAmB,GACpB,MAAM,oBAAoB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -3,7 +3,6 @@ import { useAssistantTransportRuntime, useAssistantTransportSendCommand, useAssi
|
|
|
3
3
|
import { useThreadViewport, useThreadViewportStore } from "./context/react/ThreadViewportContext.js";
|
|
4
4
|
import { DevToolsHooks, DevToolsProviderApi } from "./devtools/DevToolsHooks.js";
|
|
5
5
|
import { AssistantRuntimeProvider } from "./legacy-runtime/AssistantRuntimeProvider.js";
|
|
6
|
-
import { useExternalStoreRuntime } from "./legacy-runtime/runtime-cores/external-store/useExternalStoreRuntime.js";
|
|
7
6
|
import { CloudRendererHost } from "./cloud-renderer/CloudRendererHost.js";
|
|
8
7
|
import { ThreadListItemByIndexProvider, ThreadListItemRuntimeProvider } from "./context/providers/ThreadListItemProvider.js";
|
|
9
8
|
import { MessageByIndexProvider } from "./context/providers/MessageByIndexProvider.js";
|
|
@@ -17,12 +16,6 @@ import { ReadonlyThreadProvider } from "./context/index.js";
|
|
|
17
16
|
import { useMessageQuote } from "./hooks/useMessageQuote.js";
|
|
18
17
|
import { useMessageTiming } from "./hooks/useMessageTiming.js";
|
|
19
18
|
import { useToolCallElapsed } from "./hooks/useToolCallElapsed.js";
|
|
20
|
-
import { CloudFileAttachmentAdapter } from "./legacy-runtime/runtime-cores/adapters/attachment/CloudFileAttachmentAdapter.js";
|
|
21
|
-
import { convertExternalMessages, createExternalMessageConversionCache, useExternalMessageConverter } from "./legacy-runtime/runtime-cores/external-store/external-message-converter.js";
|
|
22
|
-
import { createMessageConverter } from "./legacy-runtime/runtime-cores/external-store/createMessageConverter.js";
|
|
23
|
-
import { useLocalRuntime } from "./legacy-runtime/runtime-cores/local/useLocalRuntime.js";
|
|
24
|
-
import { useRemoteThreadListRuntime } from "./legacy-runtime/runtime-cores/remote-thread-list/useRemoteThreadListRuntime.js";
|
|
25
|
-
import { useCloudThreadListAdapter } from "./legacy-runtime/runtime-cores/remote-thread-list/adapter/cloud.js";
|
|
26
19
|
import makeAssistantVisible from "./model-context/makeAssistantVisible.js";
|
|
27
20
|
import { useAssistantFrameHost } from "./model-context/frame/useAssistantFrameHost.js";
|
|
28
21
|
import { actionBar_exports } from "./primitives/actionBar.js";
|
|
@@ -66,8 +59,8 @@ import { McpAppsRemoteHost } from "./mcp-apps/McpAppsRemoteHost.js";
|
|
|
66
59
|
import { defaultWebMcpFilter } from "./unstable/webmcp/convertTools.js";
|
|
67
60
|
import { unstable_useWebMcpProvider } from "./unstable/webmcp/useWebMcpProvider.js";
|
|
68
61
|
import { AssistantFrameHost, AssistantFrameProvider, CompositeAttachmentAdapter, ExportedMessageRepository, FRAME_MESSAGE_CHANNEL, InMemoryThreadListAdapter, MessageNotSentError, ModelContextRegistry, SimpleImageAttachmentAdapter, SimpleTextAttachmentAdapter, WebSpeechDictationAdapter, WebSpeechSynthesisAdapter, bindExternalStoreMessage, createMessageQueue, createSuggestionAdapter, createVoiceSession, defaultDirectiveFormatter, fromThreadMessageLike, generateId, getExternalStoreMessages, isMessageNotSentError, mergeModelContexts, pickExternalStoreSharedOptions, tool, toolApprovalAcceptsText, unstable_defaultDirectiveFormatter, unstable_formatInteractableSnapshot, unstable_getInteractableSnapshots, unstable_getInteractableVersions } from "@assistant-ui/core";
|
|
69
|
-
import { ChainOfThoughtPartByIndexProvider, DataRenderers, GenerativeUIRender, GenerativeUIRenderError, Interactables, RuntimeAdapterProvider, Tools, createSimpleTitleAdapter, createThreadRowsSelector, defineMcpToolkit, defineToolkit, externalTool, groupPartByType, hitl, hitlTool, humanTool, makeAssistantDataUI, makeAssistantTool, makeAssistantToolUI, providerTool, stubTool, unstable_Interactables, unstable_interactableTool, unstable_useInteractable, unstable_useInteractableState, unstable_useInteractableVersions, unstable_useThreadMessageIds, useAssistantContext, useAssistantDataUI, useAssistantInstructions, useAssistantInteractable, useAssistantTool, useAssistantToolUI, useAuiToolOverrides, useCloudThreadListRuntime, useExternalStoreSharedOptions, useInlineRender, useInteractableState, useRuntimeAdapters, useToolArgsStatus, useVoiceControls, useVoiceState, useVoiceVolume } from "@assistant-ui/core/react";
|
|
62
|
+
import { ChainOfThoughtPartByIndexProvider, CloudFileAttachmentAdapter, DataRenderers, GenerativeUIRender, GenerativeUIRenderError, Interactables, RuntimeAdapterProvider, Tools, convertExternalMessages as unstable_convertExternalMessages, createExternalMessageConversionCache as unstable_createExternalMessageConversionCache, createMessageConverter as unstable_createMessageConverter, createSimpleTitleAdapter, createThreadRowsSelector, defineMcpToolkit, defineToolkit, externalTool, groupPartByType, hitl, hitlTool, humanTool, makeAssistantDataUI, makeAssistantTool, makeAssistantToolUI, providerTool, stubTool, unstable_Interactables, unstable_interactableTool, unstable_useInteractable, unstable_useInteractableState, unstable_useInteractableVersions, unstable_useThreadMessageIds, useAssistantContext, useAssistantDataUI, useAssistantInstructions, useAssistantInteractable, useAssistantTool, useAssistantToolUI, useAuiToolOverrides, useCloudThreadListAdapter, useCloudThreadListRuntime, useExternalMessageConverter, useExternalStoreRuntime, useExternalStoreSharedOptions, useInlineRender, useInteractableState, useLocalRuntime, useRemoteThreadListRuntime, useRuntimeAdapters, useToolArgsStatus, useVoiceControls, useVoiceState, useVoiceVolume } from "@assistant-ui/core/react";
|
|
70
63
|
import { AuiConfig, AuiIf, AuiProvider, useAui, useAuiEvent, useAuiState } from "@assistant-ui/store";
|
|
71
64
|
import { ChainOfThoughtClient, ExternalThread, InMemoryThreadList, ModelContext as ModelContextClient, RemoteThreadList, SingleThreadList, Suggestions } from "@assistant-ui/core/store";
|
|
72
65
|
import { AssistantCloud, readAnonymousRefreshToken } from "assistant-cloud";
|
|
73
|
-
export { actionBarMore_exports as ActionBarMorePrimitive, actionBar_exports as ActionBarPrimitive, AssistantCloud, AssistantFrameHost, AssistantFrameProvider, assistantModal_exports as AssistantModalPrimitive, AssistantRuntimeProvider, attachment_exports as AttachmentPrimitive, AuiConfig, AuiIf, AuiProvider, branchPicker_exports as BranchPickerPrimitive, ChainOfThoughtByIndicesProvider, ChainOfThoughtClient, ChainOfThoughtPartByIndexProvider, chainOfThought_exports as ChainOfThoughtPrimitive, CloudFileAttachmentAdapter, CloudRendererHost, ComposerAttachmentByIndexProvider, composer_exports as ComposerPrimitive, CompositeAttachmentAdapter, DataRenderers, DevToolsHooks, DevToolsProviderApi, error_exports as ErrorPrimitive, ExportedMessageRepository, ExternalThread, FRAME_MESSAGE_CHANNEL, GenerativeUIRender, GenerativeUIRenderError, internal_exports as INTERNAL, InMemoryThreadList, InMemoryThreadListAdapter, Interactables, McpAppRenderer, McpAppsRemoteHost, MessageAttachmentByIndexProvider, MessageByIndexProvider, MessageNotSentError, messagePart_exports as MessagePartPrimitive, message_exports as MessagePrimitive, MessageProvider, ModelContextClient, ModelContextRegistry, OpenAIRealtimeVoiceAdapter, PartByIndexProvider, queueItem_exports as QueueItemPrimitive, ReadonlyThreadProvider, RemoteThreadList, RuntimeAdapterProvider, selectionToolbar_exports as SelectionToolbarPrimitive, SimpleImageAttachmentAdapter, SimpleTextAttachmentAdapter, SingleThreadList, SuggestionByIndexProvider, suggestion_exports as SuggestionPrimitive, Suggestions, TextMessagePartProvider, ThreadListItemByIndexProvider, threadListItemMore_exports as ThreadListItemMorePrimitive, threadListItem_exports as ThreadListItemPrimitive, ThreadListItemRuntimeProvider, threadList_exports as ThreadListPrimitive, thread_exports as ThreadPrimitive, Tools, WebSpeechDictationAdapter, WebSpeechSynthesisAdapter, bindExternalStoreMessage, createMessageQueue, createSimpleTitleAdapter, createSuggestionAdapter, createThreadRowsSelector, createVoiceSession, defaultDirectiveFormatter, defineMcpToolkit, defineToolkit, externalTool, fromThreadMessageLike, generateId, getExternalStoreMessages, getMcpAppFromToolPart, groupPartByType, hitl, hitlTool, humanTool, isMessageNotSentError, makeAssistantDataUI, makeAssistantTool, makeAssistantToolUI, makeAssistantVisible, mergeModelContexts, pickExternalStoreSharedOptions, providerTool, readAnonymousRefreshToken, stubTool, tool, toolApprovalAcceptsText, unstable_Interactables,
|
|
66
|
+
export { actionBarMore_exports as ActionBarMorePrimitive, actionBar_exports as ActionBarPrimitive, AssistantCloud, AssistantFrameHost, AssistantFrameProvider, assistantModal_exports as AssistantModalPrimitive, AssistantRuntimeProvider, attachment_exports as AttachmentPrimitive, AuiConfig, AuiIf, AuiProvider, branchPicker_exports as BranchPickerPrimitive, ChainOfThoughtByIndicesProvider, ChainOfThoughtClient, ChainOfThoughtPartByIndexProvider, chainOfThought_exports as ChainOfThoughtPrimitive, CloudFileAttachmentAdapter, CloudRendererHost, ComposerAttachmentByIndexProvider, composer_exports as ComposerPrimitive, CompositeAttachmentAdapter, DataRenderers, DevToolsHooks, DevToolsProviderApi, error_exports as ErrorPrimitive, ExportedMessageRepository, ExternalThread, FRAME_MESSAGE_CHANNEL, GenerativeUIRender, GenerativeUIRenderError, internal_exports as INTERNAL, InMemoryThreadList, InMemoryThreadListAdapter, Interactables, McpAppRenderer, McpAppsRemoteHost, MessageAttachmentByIndexProvider, MessageByIndexProvider, MessageNotSentError, messagePart_exports as MessagePartPrimitive, message_exports as MessagePrimitive, MessageProvider, ModelContextClient, ModelContextRegistry, OpenAIRealtimeVoiceAdapter, PartByIndexProvider, queueItem_exports as QueueItemPrimitive, ReadonlyThreadProvider, RemoteThreadList, RuntimeAdapterProvider, selectionToolbar_exports as SelectionToolbarPrimitive, SimpleImageAttachmentAdapter, SimpleTextAttachmentAdapter, SingleThreadList, SuggestionByIndexProvider, suggestion_exports as SuggestionPrimitive, Suggestions, TextMessagePartProvider, ThreadListItemByIndexProvider, threadListItemMore_exports as ThreadListItemMorePrimitive, threadListItem_exports as ThreadListItemPrimitive, ThreadListItemRuntimeProvider, threadList_exports as ThreadListPrimitive, thread_exports as ThreadPrimitive, Tools, WebSpeechDictationAdapter, WebSpeechSynthesisAdapter, bindExternalStoreMessage, createMessageQueue, createSimpleTitleAdapter, createSuggestionAdapter, createThreadRowsSelector, createVoiceSession, defaultDirectiveFormatter, defineMcpToolkit, defineToolkit, externalTool, fromThreadMessageLike, generateId, getExternalStoreMessages, getMcpAppFromToolPart, groupPartByType, hitl, hitlTool, humanTool, isMessageNotSentError, makeAssistantDataUI, makeAssistantTool, makeAssistantToolUI, makeAssistantVisible, mergeModelContexts, pickExternalStoreSharedOptions, providerTool, readAnonymousRefreshToken, stubTool, tool, toolApprovalAcceptsText, unstable_Interactables, unstable_convertExternalMessages, unstable_createExternalMessageConversionCache, unstable_createMessageConverter, unstable_defaultDirectiveFormatter, defaultWebMcpFilter as unstable_defaultWebMcpFilter, unstable_formatInteractableSnapshot, unstable_getInteractableSnapshots, unstable_getInteractableVersions, unstable_interactableTool, unstable_useComposerInput, unstable_useComposerInputHistory, unstable_useInteractable, unstable_useInteractableState, unstable_useInteractableVersions, unstable_useLiveCompletionAdapter, unstable_useMentionAdapter, unstable_useMessageStallDetection, unstable_useSlashCommandAdapter, unstable_useThreadMessageIds, unstable_useTriggerPopoverAriaProps, useTriggerPopoverRootContext as unstable_useTriggerPopoverRootContext, useTriggerPopoverRootContextOptional as unstable_useTriggerPopoverRootContextOptional, useTriggerPopoverScopeContext as unstable_useTriggerPopoverScopeContext, useTriggerPopoverScopeContextOptional as unstable_useTriggerPopoverScopeContextOptional, useTriggerPopoverTriggers as unstable_useTriggerPopoverTriggers, useTriggerPopoverTriggersOptional as unstable_useTriggerPopoverTriggersOptional, unstable_useWebMcpProvider, useAssistantContext, useAssistantDataUI, useAssistantFrameHost, useAssistantInstructions, useAssistantInteractable, useAssistantTool, useAssistantToolUI, useAssistantTransportRuntime, useAssistantTransportSendCommand, useAssistantTransportState, useAui, useAuiEvent, useAuiState, useAuiToolOverrides, useCloudThreadListAdapter, useCloudThreadListRuntime, useExternalMessageConverter, useExternalStoreRuntime, useExternalStoreSharedOptions, useInlineRender, useInteractableState, useLocalRuntime, useMessagePartData, useMessagePartFile, useMessagePartImage, useMessagePartReasoning, useMessagePartSource, useMessagePartText, useMessageQuote, useMessageTiming, useRemoteThreadListRuntime, useRuntimeAdapters, useScrollLock, useSmooth, useThreadViewport, useThreadViewportAutoScroll, useThreadViewportStore, useToolArgsStatus, useToolCallElapsed, useVoiceControls, useVoiceState, useVoiceVolume };
|
package/dist/internal.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export type { ThreadRuntimeCore, ThreadListRuntimeCore, } from "@assistant-ui/core";
|
|
2
2
|
export { DefaultThreadComposerRuntimeCore, CompositeContextProvider, MessageRepository, BaseAssistantRuntimeCore, AssistantRuntimeImpl, ThreadRuntimeImpl, getAutoStatus, } from "@assistant-ui/core/internal";
|
|
3
3
|
export type { ThreadRuntimeCoreBinding, ThreadListItemRuntimeBinding, } from "@assistant-ui/core/internal";
|
|
4
|
-
export { splitLocalRuntimeOptions } from "
|
|
4
|
+
export { splitLocalRuntimeOptions } from "@assistant-ui/core/react";
|
|
5
5
|
export type { ToolExecutionStatus } from "@assistant-ui/core";
|
|
6
6
|
export { useSmooth } from "./utils/smooth/useSmooth.js";
|
|
7
7
|
export { useSmoothStatus, withSmoothContextProvider, } from "./utils/smooth/SmoothContext.js";
|
package/dist/internal.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../src/internal.ts"],"names":[],"mappings":"AACA,YAAY,EACV,iBAAiB,EACjB,qBAAqB,GACtB,MAAM,oBAAoB,CAAC;AAG5B,OAAO,EACL,gCAAgC,EAChC,wBAAwB,EACxB,iBAAiB,EACjB,wBAAwB,EACxB,oBAAoB,EACpB,iBAAiB,EACjB,aAAa,GACd,MAAM,6BAA6B,CAAC;AACrC,YAAY,EACV,wBAAwB,EACxB,4BAA4B,GAC7B,MAAM,6BAA6B,CAAC;AAGrC,OAAO,EAAE,wBAAwB,EAAE,
|
|
1
|
+
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../src/internal.ts"],"names":[],"mappings":"AACA,YAAY,EACV,iBAAiB,EACjB,qBAAqB,GACtB,MAAM,oBAAoB,CAAC;AAG5B,OAAO,EACL,gCAAgC,EAChC,wBAAwB,EACxB,iBAAiB,EACjB,wBAAwB,EACxB,oBAAoB,EACpB,iBAAiB,EACjB,aAAa,GACd,MAAM,6BAA6B,CAAC;AACrC,YAAY,EACV,wBAAwB,EACxB,4BAA4B,GAC7B,MAAM,6BAA6B,CAAC;AAGrC,OAAO,EAAE,wBAAwB,EAAE,MAAM,0BAA0B,CAAC;AACpE,YAAY,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAE9D,OAAO,EAAE,SAAS,EAAE,oCAAiC;AACrD,OAAO,EACL,eAAe,EACf,yBAAyB,GAC1B,wCAAqC;AAGtC,OAAO,EAAE,sCAAsC,EAAE,4DAAyD"}
|
package/dist/internal.js
CHANGED
|
@@ -2,7 +2,7 @@ import { __exportAll } from "./_virtual/_rolldown/runtime.js";
|
|
|
2
2
|
import { useComposerInputPluginRegistryOptional } from "./primitives/composer/ComposerInputPluginContext.js";
|
|
3
3
|
import { useSmoothStatus, withSmoothContextProvider } from "./utils/smooth/SmoothContext.js";
|
|
4
4
|
import { useSmooth } from "./utils/smooth/useSmooth.js";
|
|
5
|
-
import { splitLocalRuntimeOptions } from "
|
|
5
|
+
import { splitLocalRuntimeOptions } from "@assistant-ui/core/react";
|
|
6
6
|
import { AssistantRuntimeImpl, BaseAssistantRuntimeCore, CompositeContextProvider, DefaultThreadComposerRuntimeCore, MessageRepository, ThreadRuntimeImpl, getAutoStatus } from "@assistant-ui/core/internal";
|
|
7
7
|
//#region src/internal.ts
|
|
8
8
|
var internal_exports = /* @__PURE__ */ __exportAll({
|
package/dist/internal.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"internal.js","names":["ThreadRuntimeCore","ThreadListRuntimeCore","DefaultThreadComposerRuntimeCore","CompositeContextProvider","MessageRepository","BaseAssistantRuntimeCore","AssistantRuntimeImpl","ThreadRuntimeImpl","getAutoStatus","ThreadRuntimeCoreBinding","ThreadListItemRuntimeBinding","splitLocalRuntimeOptions","ToolExecutionStatus","useSmooth","useSmoothStatus","withSmoothContextProvider","useComposerInputPluginRegistryOptional"],"sources":["../src/internal.ts"],"sourcesContent":["// Re-export from @assistant-ui/core\nexport type {\n ThreadRuntimeCore,\n ThreadListRuntimeCore,\n} from \"@assistant-ui/core\";\n\n// Re-export from @assistant-ui/core/internal\nexport {\n DefaultThreadComposerRuntimeCore,\n CompositeContextProvider,\n MessageRepository,\n BaseAssistantRuntimeCore,\n AssistantRuntimeImpl,\n ThreadRuntimeImpl,\n getAutoStatus,\n} from \"@assistant-ui/core/internal\";\nexport type {\n ThreadRuntimeCoreBinding,\n ThreadListItemRuntimeBinding,\n} from \"@assistant-ui/core/internal\";\n\n// React-specific (stay in react)\nexport { splitLocalRuntimeOptions } from \"
|
|
1
|
+
{"version":3,"file":"internal.js","names":["ThreadRuntimeCore","ThreadListRuntimeCore","DefaultThreadComposerRuntimeCore","CompositeContextProvider","MessageRepository","BaseAssistantRuntimeCore","AssistantRuntimeImpl","ThreadRuntimeImpl","getAutoStatus","ThreadRuntimeCoreBinding","ThreadListItemRuntimeBinding","splitLocalRuntimeOptions","ToolExecutionStatus","useSmooth","useSmoothStatus","withSmoothContextProvider","useComposerInputPluginRegistryOptional"],"sources":["../src/internal.ts"],"sourcesContent":["// Re-export from @assistant-ui/core\nexport type {\n ThreadRuntimeCore,\n ThreadListRuntimeCore,\n} from \"@assistant-ui/core\";\n\n// Re-export from @assistant-ui/core/internal\nexport {\n DefaultThreadComposerRuntimeCore,\n CompositeContextProvider,\n MessageRepository,\n BaseAssistantRuntimeCore,\n AssistantRuntimeImpl,\n ThreadRuntimeImpl,\n getAutoStatus,\n} from \"@assistant-ui/core/internal\";\nexport type {\n ThreadRuntimeCoreBinding,\n ThreadListItemRuntimeBinding,\n} from \"@assistant-ui/core/internal\";\n\n// React-specific (stay in react)\nexport { splitLocalRuntimeOptions } from \"@assistant-ui/core/react\";\nexport type { ToolExecutionStatus } from \"@assistant-ui/core\";\n\nexport { useSmooth } from \"./utils/smooth/useSmooth\";\nexport {\n useSmoothStatus,\n withSmoothContextProvider,\n} from \"./utils/smooth/SmoothContext\";\n\n// ComposerInput plugin registry (used by react-lexical)\nexport { useComposerInputPluginRegistryOptional } from \"./primitives/composer/ComposerInputPluginContext\";\n"],"mappings":""}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type FC, type PropsWithChildren } from "react";
|
|
2
2
|
import { type AssistantClient, type AuiConfig } from "@assistant-ui/store";
|
|
3
|
-
import type { AssistantRuntime } from "
|
|
3
|
+
import type { AssistantRuntime } from "@assistant-ui/core";
|
|
4
4
|
export declare namespace AssistantRuntimeProvider {
|
|
5
5
|
type Props = PropsWithChildren<{
|
|
6
6
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AssistantRuntimeProvider.d.ts","sourceRoot":"","sources":["../../src/legacy-runtime/AssistantRuntimeProvider.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,EAAE,EAAQ,KAAK,iBAAiB,EAAa,MAAM,OAAO,CAAC;AACzE,OAAO,EACL,KAAK,eAAe,EACpB,KAAK,SAAS,EAEf,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,gBAAgB,EAAE,
|
|
1
|
+
{"version":3,"file":"AssistantRuntimeProvider.d.ts","sourceRoot":"","sources":["../../src/legacy-runtime/AssistantRuntimeProvider.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,EAAE,EAAQ,KAAK,iBAAiB,EAAa,MAAM,OAAO,CAAC;AACzE,OAAO,EACL,KAAK,eAAe,EACpB,KAAK,SAAS,EAEf,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAK3D,yBAAiB,wBAAwB,CAAC;IACxC,KAAY,KAAK,GAAG,iBAAiB,CAAC;QACpC;;;;WAIG;QACH,OAAO,EAAE,gBAAgB,CAAC;QAE1B;;;;;;WAMG;QACH,GAAG,CAAC,EAAE,eAAe,CAAC;QAEtB;;;WAGG;QACH,MAAM,CAAC,EAAE,SAAS,CAAC;KACpB,CAAC,CAAC;CACJ;AAYD,eAAO,MAAM,4BAA4B,EAAE,EAAE,CAC3C,wBAAwB,CAAC,KAAK,CAY/B,CAAC;AAEF,eAAO,MAAM,wBAAwB,sEAAqC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AssistantRuntimeProvider.js","names":["c","_c","FC","memo","PropsWithChildren","useEffect","AssistantClient","AuiConfig","useAui","AssistantRuntime","AssistantProviderBase","ThreadPrimitiveViewportProvider","DevToolsProviderApi","AssistantRuntimeProvider","Props","runtime","aui","config","DevToolsRegistration","$","t0","t1","process","env","NODE_ENV","register","AssistantRuntimeProviderImpl","children","t2","Symbol","for","t3","t4","_c"],"sources":["../../src/legacy-runtime/AssistantRuntimeProvider.tsx"],"sourcesContent":["\"use client\";\n\nimport { type FC, memo, type PropsWithChildren, useEffect } from \"react\";\nimport {\n type AssistantClient,\n type AuiConfig,\n useAui,\n} from \"@assistant-ui/store\";\nimport type { AssistantRuntime } from \"
|
|
1
|
+
{"version":3,"file":"AssistantRuntimeProvider.js","names":["c","_c","FC","memo","PropsWithChildren","useEffect","AssistantClient","AuiConfig","useAui","AssistantRuntime","AssistantProviderBase","ThreadPrimitiveViewportProvider","DevToolsProviderApi","AssistantRuntimeProvider","Props","runtime","aui","config","DevToolsRegistration","$","t0","t1","process","env","NODE_ENV","register","AssistantRuntimeProviderImpl","children","t2","Symbol","for","t3","t4","_c"],"sources":["../../src/legacy-runtime/AssistantRuntimeProvider.tsx"],"sourcesContent":["\"use client\";\n\nimport { type FC, memo, type PropsWithChildren, useEffect } from \"react\";\nimport {\n type AssistantClient,\n type AuiConfig,\n useAui,\n} from \"@assistant-ui/store\";\nimport type { AssistantRuntime } from \"@assistant-ui/core\";\nimport { AssistantProviderBase } from \"@assistant-ui/core/react\";\nimport { ThreadPrimitiveViewportProvider } from \"../context/providers/ThreadViewportProvider\";\nimport { DevToolsProviderApi } from \"../devtools/DevToolsHooks\";\n\nexport namespace AssistantRuntimeProvider {\n export type Props = PropsWithChildren<{\n /**\n * The assistant runtime to expose to descendants. Build one with\n * `useLocalRuntime`, `useExternalStoreRuntime`, or\n * `useAssistantTransportRuntime`.\n */\n runtime: AssistantRuntime;\n\n /**\n * Optional parent `AssistantClient` whose scopes are inherited by the\n * client created for this runtime. Use this when nesting an\n * `AssistantRuntimeProvider` inside another assistant context. Omit this\n * prop when there is no parent client.\n * @defaultValue undefined\n */\n aui?: AssistantClient;\n\n /**\n * Optional extra scopes provided alongside the runtime's `threads`\n * scope; build with `AuiConfig`.\n */\n config?: AuiConfig;\n }>;\n}\n\nconst DevToolsRegistration: FC = () => {\n const aui = useAui();\n useEffect(() => {\n if (typeof process === \"undefined\" || process.env.NODE_ENV === \"production\")\n return;\n return DevToolsProviderApi.register(aui);\n }, [aui]);\n return null;\n};\n\nexport const AssistantRuntimeProviderImpl: FC<\n AssistantRuntimeProvider.Props\n> = ({ children, aui, config, runtime }) => {\n return (\n <AssistantProviderBase runtime={runtime} aui={aui ?? null} config={config}>\n <DevToolsRegistration />\n {/* TODO temporarily allow accessing viewport state from outside the viewport */}\n {/* TODO figure out if this behavior should be deprecated, since it is quite hacky */}\n <ThreadPrimitiveViewportProvider>\n {children}\n </ThreadPrimitiveViewportProvider>\n </AssistantProviderBase>\n );\n};\n\nexport const AssistantRuntimeProvider = memo(AssistantRuntimeProviderImpl);\n"],"mappings":";;;;;;;;;AAuCA,MAAMkB,6BAA2B;CAAA,MAAAC,IAAAlB,EAAA,CAAA;CAC/B,MAAAe,MAAYR,OAAO;CAAE,IAAAY;CAAA,IAAAC;CAAA,IAAAF,EAAA,OAAAH,KAAA;EACXI,WAAA;GACR,IAAI,OAAOE,YAAY,eAAeA,QAAOC,IAAIC,aAAc,cAAY;GAClE,OACFZ,oBAAmBa,SAAUT,GAAG;EAAC;EACvCK,KAAA,CAACL,GAAG;EAACG,EAAA,KAAAH;EAAAG,EAAA,KAAAC;EAAAD,EAAA,KAAAE;CAAA,OAAA;EAAAD,KAAAD,EAAA;EAAAE,KAAAF,EAAA;CAAA;CAJRd,UAAUe,IAIPC,EAAK;CAAC,OACF;AAAI;AAGb,MAAaK,gCAETN,OAAA;CAAA,MAAAD,IAAAlB,EAAA,CAAA;CAAC,MAAA,EAAA0B,UAAAX,KAAAC,QAAAF,YAAAK;CAE6C,MAAAC,KAAAL,OAAA;CAAW,IAAAY;CAAA,IAAAT,EAAA,OAAAU,OAAAC,IAAA,2BAAA,GAAA;EACvDF,KAAA,oBAAC,sBAAD,CAAqB,CAAA;EAAGT,EAAA,KAAAS;CAAA,OAAAA,KAAAT,EAAA;CAAA,IAAAY;CAAA,IAAAZ,EAAA,OAAAQ,UAAA;EAGxBI,KAAA,oBAAC,iCAAD,EACGJ,SAD6B,CAAA;EAEER,EAAA,KAAAQ;EAAAR,EAAA,KAAAY;CAAA,OAAAA,KAAAZ,EAAA;CAAA,IAAAa;CAAA,IAAAb,EAAA,OAAAF,UAAAE,EAAA,OAAAJ,WAAAI,EAAA,OAAAE,MAAAF,EAAA,OAAAY,IAAA;EANpCC,KAAA,qBAAC,uBAAD;GAAgCjB;GAAc,KAAAM;GAAqBJ;GAAnE,UAAA,CACEW,IAGAG,EAJoB;;EAOEZ,EAAA,KAAAF;EAAAE,EAAA,KAAAJ;EAAAI,EAAA,KAAAE;EAAAF,EAAA,KAAAY;EAAAZ,EAAA,KAAAa;CAAA,OAAAA,KAAAb,EAAA;CAAA,OAPxBa;AAOwB;AAI5B,MAAanB,2BAA2BV,KAAKuB,4BAA4B"}
|
|
@@ -49,7 +49,7 @@ export declare namespace ActionBarPrimitiveCopy {
|
|
|
49
49
|
* ```
|
|
50
50
|
*/
|
|
51
51
|
export declare const ActionBarPrimitiveCopy: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
52
|
-
asChild?: boolean;
|
|
52
|
+
asChild?: boolean | undefined;
|
|
53
53
|
}, "ref"> & {
|
|
54
54
|
render?: import("react").ReactElement | undefined;
|
|
55
55
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & {
|
|
@@ -43,7 +43,7 @@ export declare namespace ActionBarPrimitiveEdit {
|
|
|
43
43
|
* ```
|
|
44
44
|
*/
|
|
45
45
|
export declare const ActionBarPrimitiveEdit: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
46
|
-
asChild?: boolean;
|
|
46
|
+
asChild?: boolean | undefined;
|
|
47
47
|
}, "ref"> & {
|
|
48
48
|
render?: import("react").ReactElement | undefined;
|
|
49
49
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -8,7 +8,7 @@ export declare namespace ActionBarPrimitiveExportMarkdown {
|
|
|
8
8
|
type Props = ActionButtonProps<typeof useActionBarExportMarkdown>;
|
|
9
9
|
}
|
|
10
10
|
export declare const ActionBarPrimitiveExportMarkdown: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
11
|
-
asChild?: boolean;
|
|
11
|
+
asChild?: boolean | undefined;
|
|
12
12
|
}, "ref"> & {
|
|
13
13
|
render?: import("react").ReactElement | undefined;
|
|
14
14
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & {
|
|
@@ -5,7 +5,7 @@ export declare namespace ActionBarPrimitiveFeedbackNegative {
|
|
|
5
5
|
type Props = ActionButtonProps<typeof useActionBarFeedbackNegative>;
|
|
6
6
|
}
|
|
7
7
|
export declare const ActionBarPrimitiveFeedbackNegative: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
8
|
-
asChild?: boolean;
|
|
8
|
+
asChild?: boolean | undefined;
|
|
9
9
|
}, "ref"> & {
|
|
10
10
|
render?: import("react").ReactElement | undefined;
|
|
11
11
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -5,7 +5,7 @@ export declare namespace ActionBarPrimitiveFeedbackPositive {
|
|
|
5
5
|
type Props = ActionButtonProps<typeof useActionBarFeedbackPositive>;
|
|
6
6
|
}
|
|
7
7
|
export declare const ActionBarPrimitiveFeedbackPositive: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
8
|
-
asChild?: boolean;
|
|
8
|
+
asChild?: boolean | undefined;
|
|
9
9
|
}, "ref"> & {
|
|
10
10
|
render?: import("react").ReactElement | undefined;
|
|
11
11
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -44,7 +44,7 @@ export declare namespace ActionBarPrimitiveReload {
|
|
|
44
44
|
* ```
|
|
45
45
|
*/
|
|
46
46
|
export declare const ActionBarPrimitiveReload: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
47
|
-
asChild?: boolean;
|
|
47
|
+
asChild?: boolean | undefined;
|
|
48
48
|
}, "ref"> & {
|
|
49
49
|
render?: import("react").ReactElement | undefined;
|
|
50
50
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -48,7 +48,7 @@ export declare namespace ActionBarPrimitiveRoot {
|
|
|
48
48
|
* ```
|
|
49
49
|
*/
|
|
50
50
|
export declare const ActionBarPrimitiveRoot: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
|
|
51
|
-
asChild?: boolean;
|
|
51
|
+
asChild?: boolean | undefined;
|
|
52
52
|
}, "ref"> & {
|
|
53
53
|
render?: import("react").ReactElement | undefined;
|
|
54
54
|
} & import("react").RefAttributes<HTMLDivElement>, "ref"> & {
|
|
@@ -5,7 +5,7 @@ export declare namespace ActionBarPrimitiveSpeak {
|
|
|
5
5
|
type Props = ActionButtonProps<typeof useActionBarSpeak>;
|
|
6
6
|
}
|
|
7
7
|
export declare const ActionBarPrimitiveSpeak: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
8
|
-
asChild?: boolean;
|
|
8
|
+
asChild?: boolean | undefined;
|
|
9
9
|
}, "ref"> & {
|
|
10
10
|
render?: import("react").ReactElement | undefined;
|
|
11
11
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -5,7 +5,7 @@ export declare namespace ActionBarPrimitiveStopSpeaking {
|
|
|
5
5
|
type Props = ActionButtonProps<typeof useActionBarStopSpeaking>;
|
|
6
6
|
}
|
|
7
7
|
export declare const ActionBarPrimitiveStopSpeaking: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
8
|
-
asChild?: boolean;
|
|
8
|
+
asChild?: boolean | undefined;
|
|
9
9
|
}, "ref"> & {
|
|
10
10
|
render?: import("react").ReactElement | undefined;
|
|
11
11
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -5,7 +5,7 @@ export declare namespace AttachmentPrimitiveRemove {
|
|
|
5
5
|
type Props = ActionButtonProps<typeof useAttachmentRemove>;
|
|
6
6
|
}
|
|
7
7
|
export declare const AttachmentPrimitiveRemove: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
8
|
-
asChild?: boolean;
|
|
8
|
+
asChild?: boolean | undefined;
|
|
9
9
|
}, "ref"> & {
|
|
10
10
|
render?: import("react").ReactElement | undefined;
|
|
11
11
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -24,7 +24,7 @@ export declare namespace AttachmentPrimitiveRoot {
|
|
|
24
24
|
* ```
|
|
25
25
|
*/
|
|
26
26
|
export declare const AttachmentPrimitiveRoot: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
|
|
27
|
-
asChild?: boolean;
|
|
27
|
+
asChild?: boolean | undefined;
|
|
28
28
|
}, "ref"> & {
|
|
29
29
|
render?: import("react").ReactElement | undefined;
|
|
30
30
|
} & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -6,7 +6,7 @@ export declare namespace AttachmentPrimitiveThumb {
|
|
|
6
6
|
type Props = PrimitiveDivProps;
|
|
7
7
|
}
|
|
8
8
|
export declare const AttachmentPrimitiveThumb: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
|
|
9
|
-
asChild?: boolean;
|
|
9
|
+
asChild?: boolean | undefined;
|
|
10
10
|
}, "ref"> & {
|
|
11
11
|
render?: import("react").ReactElement | undefined;
|
|
12
12
|
} & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -22,7 +22,7 @@ export declare namespace BranchPickerPrimitiveNext {
|
|
|
22
22
|
* ```
|
|
23
23
|
*/
|
|
24
24
|
export declare const BranchPickerPrimitiveNext: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
25
|
-
asChild?: boolean;
|
|
25
|
+
asChild?: boolean | undefined;
|
|
26
26
|
}, "ref"> & {
|
|
27
27
|
render?: import("react").ReactElement | undefined;
|
|
28
28
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -22,7 +22,7 @@ export declare namespace BranchPickerPrimitivePrevious {
|
|
|
22
22
|
* ```
|
|
23
23
|
*/
|
|
24
24
|
export declare const BranchPickerPrimitivePrevious: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
25
|
-
asChild?: boolean;
|
|
25
|
+
asChild?: boolean | undefined;
|
|
26
26
|
}, "ref"> & {
|
|
27
27
|
render?: import("react").ReactElement | undefined;
|
|
28
28
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -29,7 +29,7 @@ export declare namespace BranchPickerPrimitiveRoot {
|
|
|
29
29
|
* ```
|
|
30
30
|
*/
|
|
31
31
|
export declare const BranchPickerPrimitiveRoot: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
|
|
32
|
-
asChild?: boolean;
|
|
32
|
+
asChild?: boolean | undefined;
|
|
33
33
|
}, "ref"> & {
|
|
34
34
|
render?: import("react").ReactElement | undefined;
|
|
35
35
|
} & import("react").RefAttributes<HTMLDivElement>, "ref"> & {
|
|
@@ -22,7 +22,7 @@ export declare namespace ChainOfThoughtPrimitiveAccordionTrigger {
|
|
|
22
22
|
* ```
|
|
23
23
|
*/
|
|
24
24
|
export declare const ChainOfThoughtPrimitiveAccordionTrigger: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
25
|
-
asChild?: boolean;
|
|
25
|
+
asChild?: boolean | undefined;
|
|
26
26
|
}, "ref"> & {
|
|
27
27
|
render?: import("react").ReactElement | undefined;
|
|
28
28
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -22,7 +22,7 @@ export declare namespace ChainOfThoughtPrimitiveRoot {
|
|
|
22
22
|
* ```
|
|
23
23
|
*/
|
|
24
24
|
export declare const ChainOfThoughtPrimitiveRoot: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
|
|
25
|
-
asChild?: boolean;
|
|
25
|
+
asChild?: boolean | undefined;
|
|
26
26
|
}, "ref"> & {
|
|
27
27
|
render?: import("react").ReactElement | undefined;
|
|
28
28
|
} & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -8,7 +8,7 @@ export declare namespace ComposerPrimitiveAddAttachment {
|
|
|
8
8
|
type Props = ActionButtonProps<typeof useComposerAddAttachment>;
|
|
9
9
|
}
|
|
10
10
|
export declare const ComposerPrimitiveAddAttachment: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
11
|
-
asChild?: boolean;
|
|
11
|
+
asChild?: boolean | undefined;
|
|
12
12
|
}, "ref"> & {
|
|
13
13
|
render?: import("react").ReactElement | undefined;
|
|
14
14
|
} & import("react").RefAttributes<HTMLButtonElement>, "ref"> & {
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
|
|
3
|
-
export { ComposerPrimitiveAttachmentByIndex, ComposerPrimitiveAttachments };
|
|
2
|
+
export { ComposerPrimitiveAttachmentByIndex, ComposerPrimitiveAttachments } from "@assistant-ui/core/react";
|