|
- @page "/chatroom_base/{typellm:int}"
- @page "/chatroom_base/{typellm:int}/{conversationid}"
-
- <script>
- window.autoResizeTextarea = function (elementId) {
- const element = document.getElementById(elementId);
- if (!element) return;
-
- element.style.height = 'auto';
- element.style.height = Math.min(element.scrollHeight, 200) + 'px';
- };
-
- window.setupTextareaAutoResize = function (textareaId) {
- const textarea = document.getElementById(textareaId);
- if (!textarea) return;
-
- textarea.addEventListener('input', function () {
- window.autoResizeTextarea(this);
- });
-
- // Initial resize
- window.autoResizeTextarea(textarea);
- };
- </script>
-
- @if (TypeLLM == 0)
- {
- <!-- Vue Home -->
- <div class="home-container">
- <div class="home-content">
- <!-- Section bienvenue -->
- <div class="welcome-section">
- <h1 class="welcome-title">Bonjour !</h1>
- <p class="welcome-subtitle">Qu'est-ce qu'on fait aujourd'hui ?</p>
- </div>
-
- <!-- Zone de saisie -->
- <div class="input-container">
- @if (UploadedDocuments.Any())
- {
- <div class="input-files">
- @foreach (var doc in UploadedDocuments)
- {
- <div class="file-item">
- <div class="file-preview">
- <div class="file-icon">
- <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 16 16">
- <path d="M14 4.5V14a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V2a2 2 0 0 1 2-2h5.5zm-3 0A1.5 1.5 0 0 1 9.5 3V1H4a1 1 0 0 0-1 1v12a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1V4.5z" />
- </svg>
- </div>
- </div>
- <div class="file-info">
- <span class="file-name">@doc.FileName</span>
- <span class="file-size">@FormatFileSize(doc.Bytes.Length)</span>
- </div>
- <button class="remove-file-button" @onclick="() => RemoveDocument(doc)" aria-label="Supprimer le fichier">
- <svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" fill="currentColor" viewBox="0 0 16 16">
- <path d="M2.146 2.854a.5.5 0 1 1 .708-.708L8 7.293l5.146-5.147a.5.5 0 0 1 .708.708L8.707 8l5.147 5.146a.5.5 0 0 1-.708.708L8 8.707l-5.146 5.147a.5.5 0 0 1-.708-.708L7.293 8z" />
- </svg>
- </button>
- </div>
- }
- </div>
- }
-
- <div class="input-wrapper @(UploadedDocuments.Any() ? "has-files" : "")">
- <textarea id="homeTextarea"
- @bind="CurrentInput"
- @oninput="OnHomeTextareaInput"
- placeholder="Nouvelle conversation..."
- rows="1"
- disabled="@isDisabled"></textarea>
-
- <div class="input-actions">
- <label class="attach-button" for="fileInputHome">
- <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" viewBox="0 0 16 16">
- <path d="M4.5 3a2.5 2.5 0 0 1 5 0v9a1.5 1.5 0 0 1-3 0V5a.5.5 0 0 1 1 0v7a.5.5 0 0 0 1 0V3a1.5 1.5 0 1 0-3 0v9a2.5 2.5 0 0 0 5 0V5a.5.5 0 0 1 1 0v7a3.5 3.5 0 1 1-7 0z" />
- </svg>
- <span>Importer un fichier</span>
- <InputFile id="fileInputHome" OnChange="HandleFileSelection" multiple style="display: none;" />
- </label>
-
- <div class="input-right-actions">
- @if (!hiddenDomain && SelectedAgentType == 2 && RagDomains.Any())
- {
- <select class="domain-select" @bind="SelectedDomain">
- @foreach (var domain in RagDomains)
- {
- <option value="@domain">@domain</option>
- }
- </select>
- }
- <button class="voice-button" @onclick="RecordVoice" aria-label="Message vocal">
- <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" viewBox="0 0 16 16">
- <path fill-rule="evenodd" d="M8.5 2a.5.5 0 0 1 .5.5v11a.5.5 0 0 1-1 0v-11a.5.5 0 0 1 .5-.5m-2 2a.5.5 0 0 1 .5.5v7a.5.5 0 0 1-1 0v-7a.5.5 0 0 1 .5-.5m4 0a.5.5 0 0 1 .5.5v7a.5.5 0 0 1-1 0v-7a.5.5 0 0 1 .5-.5m-6 1.5A.5.5 0 0 1 5 6v4a.5.5 0 0 1-1 0V6a.5.5 0 0 1 .5-.5m8 0a.5.5 0 0 1 .5.5v4a.5.5 0 0 1-1 0V6a.5.5 0 0 1 .5-.5m-10 1A.5.5 0 0 1 3 7v2a.5.5 0 0 1-1 0V7a.5.5 0 0 1 .5-.5m12 0a.5.5 0 0 1 .5.5v2a.5.5 0 0 1-1 0V7a.5.5 0 0 1 .5-.5" />
- </svg>
- </button>
-
- <button class="send-button"
- @onclick="SendMessageFromHome"
- disabled="@((string.IsNullOrWhiteSpace(CurrentInput) && !UploadedDocuments.Any()) || isDisabled)"
- aria-label="Envoyer le message">
- <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" viewBox="0 0 16 16">
- <path fill-rule="evenodd" d="M8 15a.5.5 0 0 0 .5-.5V2.707l3.146 3.147a.5.5 0 0 0 .708-.708l-4-4a.5.5 0 0 0-.708 0l-4 4a.5.5 0 1 0 .708.708L7.5 2.707V14.5a.5.5 0 0 0 .5.5" />
- </svg>
- </button>
- </div>
- </div>
- </div>
-
- <!-- Cartes des agents -->
- <div class="agents-grid">
- <label class="agent-card @(SelectedAgentType == 1 ? "selected" : "")" for="agent1">
- <input type="radio"
- id="agent1"
- name="agentType"
- value="1"
- checked="@(SelectedAgentType == 1)"
- @onchange="() => SelectAgent(1)" />
- <div class="agent-icon">
- <svg xmlns="http://www.w3.org/2000/svg" width="26" height="26" fill="currentColor" viewBox="0 0 16 16">
- <path d="M12.146.146a.5.5 0 0 1 .708 0l3 3a.5.5 0 0 1 0 .708l-10 10a.5.5 0 0 1-.168.11l-5 2a.5.5 0 0 1-.65-.65l2-5a.5.5 0 0 1 .11-.168zM11.207 2.5 13.5 4.793 14.793 3.5 12.5 1.207zm1.586 3L10.5 3.207 4 9.707V10h.5a.5.5 0 0 1 .5.5v.5h.5a.5.5 0 0 1 .5.5v.5h.293zm-9.761 5.175-.106.106-1.528 3.821 3.821-1.528.106-.106A.5.5 0 0 1 5 12.5V12h-.5a.5.5 0 0 1-.5-.5V11h-.5a.5.5 0 0 1-.468-.325" />
- </svg>
- </div>
- <div class="agent-content">
- <h3 class="agent-name">conversation</h3>
- <p class="agent-description">
- Discutez avec un agent IA ayant une bonne connaissance de votre secteur d'activité
- </p>
- </div>
- <div class="agent-check">
- <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 16 16">
- <path d="M10.97 4.97a.75.75 0 0 1 1.07 1.05l-3.99 4.99a.75.75 0 0 1-1.08.02L4.324 8.384a.75.75 0 1 1 1.06-1.06l2.094 2.093 3.473-4.425z"/>
- </svg>
- </div>
- </label>
-
- <label class="agent-card @(SelectedAgentType == 2 ? "selected" : "")" for="agent2">
- <input type="radio"
- id="agent2"
- name="agentType"
- value="2"
- checked="@(SelectedAgentType == 2)"
- @onchange="() => SelectAgent(2)" />
- <div class="agent-icon">
- <svg xmlns="http://www.w3.org/2000/svg" width="26" height="26" fill="currentColor" viewBox="0 0 16 16">
- <path fill-rule="evenodd" d="M5 11.5a.5.5 0 0 1 .5-.5h9a.5.5 0 0 1 0 1h-9a.5.5 0 0 1-.5-.5m0-4a.5.5 0 0 1 .5-.5h9a.5.5 0 0 1 0 1h-9a.5.5 0 0 1-.5-.5m0-4a.5.5 0 0 1 .5-.5h9a.5.5 0 0 1 0 1h-9a.5.5 0 0 1-.5-.5M3.854 2.146a.5.5 0 0 1 0 .708l-1.5 1.5a.5.5 0 0 1-.708 0l-.5-.5a.5.5 0 1 1 .708-.708L2 3.293l1.146-1.147a.5.5 0 0 1 .708 0m0 4a.5.5 0 0 1 0 .708l-1.5 1.5a.5.5 0 0 1-.708 0l-.5-.5a.5.5 0 1 1 .708-.708L2 7.293l1.146-1.147a.5.5 0 0 1 .708 0m0 4a.5.5 0 0 1 0 .708l-1.5 1.5a.5.5 0 0 1-.708 0l-.5-.5a.5.5 0 0 1 .708-.708l.146.147 1.146-1.147a.5.5 0 0 1 .708 0" />
- </svg>
- </div>
- <div class="agent-content">
- <h3 class="agent-name">Agent RAG</h3>
- <p class="agent-description">
- un agent possédant une excellente connaissance de votre base documentaire
- </p>
- </div>
- <div class="agent-check">
- <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 16 16">
- <path d="M10.97 4.97a.75.75 0 0 1 1.07 1.05l-3.99 4.99a.75.75 0 0 1-1.08.02L4.324 8.384a.75.75 0 1 1 1.06-1.06l2.094 2.093 3.473-4.425z"/>
- </svg>
- </div>
- </label>
-
- <label class="agent-card @(SelectedAgentType == 3 ? "selected" : "")" for="agent3">
- <input type="radio"
- id="agent3"
- name="agentType"
- value="3"
- checked="@(SelectedAgentType == 3)"
- @onchange="() => SelectAgent(3)" />
- <div class="agent-icon">
- <svg xmlns="http://www.w3.org/2000/svg" width="26" height="26" fill="currentColor" viewBox="0 0 16 16">
- <path fill-rule="evenodd" d="M10.854 6.146a.5.5 0 0 1 0 .708l-3 3a.5.5 0 0 1-.708 0l-1.5-1.5a.5.5 0 1 1 .708-.708L7.5 8.793l2.646-2.647a.5.5 0 0 1 .708 0" />
- <path d="M3 0h10a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2v-1h1v1a1 1 0 0 0 1 1h10a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1H3a1 1 0 0 0-1 1v1H1V2a2 2 0 0 1 2-2" />
- <path d="M1 5v-.5a.5.5 0 0 1 1 0V5h.5a.5.5 0 0 1 0 1h-2a.5.5 0 0 1 0-1zm0 3v-.5a.5.5 0 0 1 1 0V8h.5a.5.5 0 0 1 0 1h-2a.5.5 0 0 1 0-1zm0 3v-.5a.5.5 0 0 1 1 0v.5h.5a.5.5 0 0 1 0 1h-2a.5.5 0 0 1 0-1z" />
- </svg>
- </div>
- <div class="agent-content">
- <h3 class="agent-name">L'agent Audit</h3>
- <p class="agent-description">
- Un agent IA spécialisé dans l'étude de vos documents et dans la réalisation d'audit financier
- </p>
- </div>
- <div class="agent-check">
- <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 16 16">
- <path d="M10.97 4.97a.75.75 0 0 1 1.07 1.05l-3.99 4.99a.75.75 0 0 1-1.08.02L4.324 8.384a.75.75 0 1 1 1.06-1.06l2.094 2.093 3.473-4.425z"/>
- </svg>
- </div>
- </label>
-
- <label class="agent-card @(SelectedAgentType == 4 ? "selected" : "")" for="agent4">
- <input type="radio"
- id="agent4"
- name="agentType"
- value="4"
- checked="@(SelectedAgentType == 4)"
- @onchange="() => SelectAgent(4)" />
- <div class="agent-icon">
- <svg xmlns="http://www.w3.org/2000/svg" width="26" height="26" fill="currentColor" viewBox="0 0 16 16">
- <path d="M.05 3.555A2 2 0 0 1 2 2h12a2 2 0 0 1 1.95 1.555L8 8.414zM0 4.697v7.104l5.803-3.558zM6.761 8.83l-6.57 4.027A2 2 0 0 0 2 14h12a2 2 0 0 0 1.808-1.144l-6.57-4.027L8 9.586zm3.436-.586L16 11.801V4.697z" />
- </svg>
- </div>
- <div class="agent-content">
- <h3 class="agent-name">L'agent mail spécialisé</h3>
- <p class="agent-description">
- un agent IA spécialisé dans le traitement de vos mails avec une approche humaine et experte
- </p>
- </div>
- <div class="agent-check">
- <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 16 16">
- <path d="M10.97 4.97a.75.75 0 0 1 1.07 1.05l-3.99 4.99a.75.75 0 0 1-1.08.02L4.324 8.384a.75.75 0 1 1 1.06-1.06l2.094 2.093 3.473-4.425z"/>
- </svg>
- </div>
- </label>
- </div>
- </div>
- </div>
- </div>
-
- }
- else
- {
- <!-- Vue ChatRoom -->
- <div class="chatroom-container">
- <!-- Zone de messages -->
- <div class="chatroom-messages">
- @if (SelectedConversation == null || !Messages.Any())
- {
- <div class="chatroom-empty">
- <div class="empty-icon">💬</div>
- <h3>Commencez une conversation</h3>
- <p>Posez une question ou envoyez un message pour démarrer</p>
- </div>
- }
- else
- {
- @foreach (var msg in Messages)
- {
- <div class="message-row @(msg.IsUser ? "user" : "assistant")">
- <div class="avatar @(msg.IsUser ? "avatar-user" : "avatar-assistant")">
- @if (msg.IsUser)
- {
- <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 16 16">
- <path d="M11 6a3 3 0 1 1-6 0 3 3 0 0 1 6 0" />
- <path fill-rule="evenodd" d="M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8m8-7a7 7 0 0 0-5.468 11.37C3.242 11.226 4.805 10 8 10s4.757 1.225 5.468 2.37A7 7 0 0 0 8 1" />
- </svg>
- }
- else
- {
- <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 16 16">
- <path d="M6 12.5a.5.5 0 0 1 .5-.5h3a.5.5 0 0 1 0 1h-3a.5.5 0 0 1-.5-.5M3 8.062C3 6.76 4.235 5.765 5.53 5.886a26.6 26.6 0 0 0 4.94 0C11.765 5.765 13 6.76 13 8.062v1.157a.93.93 0 0 1-.765.935c-.845.147-2.34.346-4.235.346s-3.39-.2-4.235-.346A.93.93 0 0 1 3 9.219zm4.542-.827a.25.25 0 0 0-.217.068l-.92.9a25 25 0 0 1-1.871-.183.25.25 0 0 0-.068.495c.55.076 1.232.149 2.02.193a.25.25 0 0 0 .189-.071l.754-.736.847 1.71a.25.25 0 0 0 .404.062l.932-.97a25 25 0 0 0 1.922-.188.25.25 0 0 0-.068-.495c-.538.074-1.207.145-1.98.189a.25.25 0 0 0-.166.076l-.754.785-.842-1.7a.25.25 0 0 0-.182-.135" />
- <path d="M8.5 1.866a1 1 0 1 0-1 0V3h-2A4.5 4.5 0 0 0 1 7.5V8a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1v1a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-1a1 1 0 0 0 1-1V9a1 1 0 0 0-1-1v-.5A4.5 4.5 0 0 0 10.5 3h-2zM14 7.5V13a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1V7.5A3.5 3.5 0 0 1 5.5 4h5A3.5 3.5 0 0 1 14 7.5" />
- </svg>
- }
- </div>
-
- <div class="message-content-wrapper">
- <div class="bubble @(msg.IsUser ? "bubble-user" : "bubble-assistant")">
- @msg.Text
- </div>
-
- @if (!msg.IsUser)
- {
- <div class="message-actions">
- <button class="btn-message-action" @onclick="() => CopyMessage(msg.Text)" title="Copier">
- <svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" fill="currentColor" viewBox="0 0 16 16">
- <path d="M4 1.5H3a2 2 0 0 0-2 2V14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V3.5a2 2 0 0 0-2-2h-1v1h1a1 1 0 0 1 1 1V14a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1V3.5a1 1 0 0 1 1-1h1z" />
- <path d="M9.5 1a.5.5 0 0 1 .5.5v1a.5.5 0 0 1-.5.5h-3a.5.5 0 0 1-.5-.5v-1a.5.5 0 0 1 .5-.5zm-3-1A1.5 1.5 0 0 0 5 1.5v1A1.5 1.5 0 0 0 6.5 4h3A1.5 1.5 0 0 0 11 2.5v-1A1.5 1.5 0 0 0 9.5 0z" />
- </svg>
- </button>
- </div>
- }
- </div>
- </div>
- }
-
- @if (isTyping)
- {
- <div class="message-row assistant">
- <div class="avatar avatar-assistant">
- <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 16 16">
- <path d="M6 12.5a.5.5 0 0 1 .5-.5h3a.5.5 0 0 1 0 1h-3a.5.5 0 0 1-.5-.5M3 8.062C3 6.76 4.235 5.765 5.53 5.886a26.6 26.6 0 0 0 4.94 0C11.765 5.765 13 6.76 13 8.062v1.157a.93.93 0 0 1-.765.935c-.845.147-2.34.346-4.235.346s-3.39-.2-4.235-.346A.93.93 0 0 1 3 9.219zm4.542-.827a.25.25 0 0 0-.217.068l-.92.9a25 25 0 0 1-1.871-.183.25.25 0 0 0-.068.495c.55.076 1.232.149 2.02.193a.25.25 0 0 0 .189-.071l.754-.736.847 1.71a.25.25 0 0 0 .404.062l.932-.97a25 25 0 0 0 1.922-.188.25.25 0 0 0-.068-.495c-.538.074-1.207.145-1.98.189a.25.25 0 0 0-.166.076l-.754.785-.842-1.7a.25.25 0 0 0-.182-.135" />
- <path d="M8.5 1.866a1 1 0 1 0-1 0V3h-2A4.5 4.5 0 0 0 1 7.5V8a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1v1a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-1a1 1 0 0 0 1-1V9a1 1 0 0 0-1-1v-.5A4.5 4.5 0 0 0 10.5 3h-2zM14 7.5V13a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1V7.5A3.5 3.5 0 0 1 5.5 4h5A3.5 3.5 0 0 1 14 7.5" />
- </svg>
- </div>
- <div class="message-content-wrapper">
- <div class="bubble bubble-assistant">
- <div class="typing-indicator">
- <span></span>
- <span></span>
- <span></span>
- </div>
- </div>
- </div>
- </div>
- }
- }
- </div>
-
- <!-- Zone de saisie moderne -->
- <div class="chat-input-container">
- <!-- Fichiers attachés -->
- @if (UploadedDocuments.Any())
- {
- <div class="attached-files">
- @foreach (var doc in UploadedDocuments)
- {
- <div class="file-item">
- <div class="file-preview">
- <div class="file-icon">
- <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="currentColor" viewBox="0 0 16 16">
- <path d="M14 4.5V14a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V2a2 2 0 0 1 2-2h5.5zm-3 0A1.5 1.5 0 0 1 9.5 3V1H4a1 1 0 0 0-1 1v12a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1V4.5z" />
- </svg>
- </div>
- </div>
- <div class="file-info">
- <span class="file-name">@doc.FileName</span>
- <span class="file-size">@FormatFileSize(doc.Bytes.Length)</span>
- </div>
- <button class="remove-file-button" @onclick="() => RemoveDocument(doc)" aria-label="Supprimer le fichier">
- <svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" fill="currentColor" viewBox="0 0 16 16">
- <path d="M2.146 2.854a.5.5 0 1 1 .708-.708L8 7.293l5.146-5.147a.5.5 0 0 1 .708.708L8.707 8l5.147 5.146a.5.5 0 0 1-.708.708L8 8.707l-5.146 5.147a.5.5 0 0 1-.708-.708L7.293 8z" />
- </svg>
- </button>
- </div>
- }
- </div>
- }
-
- <!-- Input wrapper -->
- <div class="input-wrapper @(UploadedDocuments.Any() ? "has-files" : "")">
- <textarea id="chatroomTextarea"
- @bind="CurrentInput"
- @oninput="OnChatroomTextareaInput"
- @onkeydown="HandleKeyPress"
- placeholder="Nouvelle conversation..."
- rows="1"></textarea>
-
- <div class="actions-row">
- <!-- Bouton attachement -->
- <label class="attach-button" for="fileUpload">
- <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" viewBox="0 0 16 16">
- <path d="M4.5 3a2.5 2.5 0 0 1 5 0v9a1.5 1.5 0 0 1-3 0V5a.5.5 0 0 1 1 0v7a.5.5 0 0 0 1 0V3a1.5 1.5 0 1 0-3 0v9a2.5 2.5 0 0 0 5 0V5a.5.5 0 0 1 1 0v7a3.5 3.5 0 1 1-7 0z" />
- </svg>
- <span>Importer un fichier</span>
- <InputFile id="fileUpload" OnChange="UploadDocuments" multiple style="display: none;" />
- </label>
-
- <div class="right-actions">
- <!-- Sélecteur de domaine RAG -->
- @if (!hiddenDomain && RagDomains.Any())
- {
- <select class="domain-select" @bind="SelectedDomain">
- @foreach (var domain in RagDomains)
- {
- <option value="@domain">@domain</option>
- }
- </select>
- }
-
- <!-- Bouton historique -->
- <button class="history-button @(IsWithHistorique ? "active" : "desactive")" @onclick="ToggleHistory" title="@(IsWithHistorique ? "Historique activé" : "Historique désactivé")">
- <svg xmlns="http://www.w3.org/2000/svg" width="18" height="18" fill="currentColor" viewBox="0 0 16 16">
- <path d="M8.515 1.019A7 7 0 0 0 8 1V0a8 8 0 0 1 .589.022zm2.004.45a7 7 0 0 0-.985-.299l.219-.976q.576.129 1.126.342zm1.37.71a7 7 0 0 0-.439-.27l.493-.87a8 8 0 0 1 .979.654l-.615.789a7 7 0 0 0-.418-.302zm1.834 1.79a7 7 0 0 0-.653-.796l.724-.69q.406.429.747.91zm.744 1.352a7 7 0 0 0-.214-.468l.893-.45a8 8 0 0 1 .45 1.088l-.95.313a7 7 0 0 0-.179-.483m.53 2.507a7 7 0 0 0-.1-1.025l.985-.17q.1.58.116 1.17zm-.131 1.538q.05-.254.081-.51l.993.123a8 8 0 0 1-.23 1.155l-.964-.267q.069-.247.12-.501m-.952 2.379q.276-.436.486-.908l.914.405q-.24.54-.555 1.038zm-.964 1.205q.183-.183.35-.378l.758.653a8 8 0 0 1-.401.432z" />
- <path d="M8 1a7 7 0 1 0 4.95 11.95l.707.707A8.001 8.001 0 1 1 8 0z" />
- <path d="M7.5 3a.5.5 0 0 1 .5.5v5.21l3.248 1.856a.5.5 0 0 1-.496.868l-3.5-2A.5.5 0 0 1 7 9V3.5a.5.5 0 0 1 .5-.5" />
- </svg>
- </button>
- <button class="voice-button" @onclick="RecordVoice" aria-label="Message vocal">
- <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" viewBox="0 0 16 16">
- <path fill-rule="evenodd" d="M8.5 2a.5.5 0 0 1 .5.5v11a.5.5 0 0 1-1 0v-11a.5.5 0 0 1 .5-.5m-2 2a.5.5 0 0 1 .5.5v7a.5.5 0 0 1-1 0v-7a.5.5 0 0 1 .5-.5m4 0a.5.5 0 0 1 .5.5v7a.5.5 0 0 1-1 0v-7a.5.5 0 0 1 .5-.5m-6 1.5A.5.5 0 0 1 5 6v4a.5.5 0 0 1-1 0V6a.5.5 0 0 1 .5-.5m8 0a.5.5 0 0 1 .5.5v4a.5.5 0 0 1-1 0V6a.5.5 0 0 1 .5-.5m-10 1A.5.5 0 0 1 3 7v2a.5.5 0 0 1-1 0V7a.5.5 0 0 1 .5-.5m12 0a.5.5 0 0 1 .5.5v2a.5.5 0 0 1-1 0V7a.5.5 0 0 1 .5-.5" />
- </svg>
- </button>
-
- <!-- Bouton envoyer -->
- <button class="send-button"
- @onclick="SendMessage"
- disabled="@(string.IsNullOrWhiteSpace(CurrentInput) && !UploadedDocuments.Any())"
- aria-label="Envoyer le message">
- <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" viewBox="0 0 16 16">
- <path fill-rule="evenodd" d="M8 15a.5.5 0 0 0 .5-.5V2.707l3.146 3.147a.5.5 0 0 0 .708-.708l-4-4a.5.5 0 0 0-.708 0l-4 4a.5.5 0 1 0 .708.708L7.5 2.707V14.5a.5.5 0 0 0 .5.5" />
- </svg>
- </button>
- </div>
- </div>
- </div>
- </div>
- </div>
- }
|