/** * @license * Copyright 2023 Nuraly, Laabidi Aymen * SPDX-License-Identifier: MIT */ import { TemplateResult } from 'lit'; import { MessageTemplateHandlers } from './message.template.js'; import { SuggestionTemplateHandlers } from './suggestion.template.js'; import { InputBoxTemplateData, InputBoxTemplateHandlers } from './input-box.template.js'; import { ThreadSidebarTemplateData, ThreadSidebarTemplateHandlers } from './thread-sidebar.template.js'; import { FileUploadAreaTemplateHandlers } from './file-upload-area.template.js'; import { UrlModalTemplateData, UrlModalTemplateHandlers } from './url-modal.template.js'; import { ArtifactPanelTemplateData, ArtifactPanelTemplateHandlers } from './artifact-panel.template.js'; import { ChatbotMessage, ChatbotSuggestion, ChatbotLoadingType, ChatbotI18n } from '../chatbot.types.js'; export interface ChatbotMainTemplateData { boxed?: boolean; /** Show messages area (set to false for input-only mode) */ showMessages?: boolean; /** Welcome heading shown when the messages list is empty. Falls back to i18n.messages.startConversationLabel. */ welcomeMessage?: string; /** True when activeThreadId points at a thread that has not yet been loaded. Renders a loading state in the messages area. */ isPendingThread?: boolean; /** True while a selected thread's messages are being lazily fetched. Renders skeleton bubbles in the conversation layout. */ loadingMessages?: boolean; /** Anchor messages to the bottom via flex-direction: column-reverse. New messages stay anchored without JS scroll. */ invertedScroll?: boolean; /** Transient error message shown when a dropped/picked file fails validation. */ fileRejectionMessage?: string; /** Called when the user clicks the dismiss button on the file rejection pill. */ onDismissFileRejection?: () => void; messages: ChatbotMessage[]; isTyping: boolean; loadingIndicator?: ChatbotLoadingType; loadingText?: string; chatStarted: boolean; suggestions: ChatbotSuggestion[]; inputBox: InputBoxTemplateData; enableThreads: boolean; enableThreadCreation: boolean; isThreadSidebarOpen: boolean; threadSidebar?: ThreadSidebarTemplateData; enableFileUpload: boolean; isDragging: boolean; i18n: ChatbotI18n; urlModal?: UrlModalTemplateData; enableArtifacts?: boolean; artifactPanel?: ArtifactPanelTemplateData; } export interface ChatbotMainTemplateHandlers { message: MessageTemplateHandlers; suggestion: SuggestionTemplateHandlers; inputBox: InputBoxTemplateHandlers; threadSidebar?: ThreadSidebarTemplateHandlers; fileUploadArea: FileUploadAreaTemplateHandlers; urlModal?: UrlModalTemplateHandlers; artifactPanel?: ArtifactPanelTemplateHandlers; onToggleThreadSidebar?: () => void; } /** * Main chatbot template that orchestrates all sub-templates */ export declare function renderChatbotMain(data: ChatbotMainTemplateData, handlers: ChatbotMainTemplateHandlers): TemplateResult; //# sourceMappingURL=chatbot-main.template.d.ts.map