Spaces:
Running
Running
Download widget.html from Pep1900/chat-widget-pro: direct link, hf CLI and curl.
- Browser
- Download file 3.73 kB
-
https://huggingface.co/spaces/Pep1900/chat-widget-pro/resolve/main/widget.html
- Command line
-
hf download hf://spaces/Pep1900/chat-widget-pro/widget.html
-
curl -L -o widget.html https://huggingface.co/spaces/Pep1900/chat-widget-pro/resolve/main/widget.html
3.73 kB
| <html lang="ru"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Чат-виджет</title> | |
| <script src="https://cdn.tailwindcss.com"></script> | |
| <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css"> | |
| </head> | |
| <body class="bg-gray-100 h-screen flex flex-col"> | |
| <!-- Шапка виджета --> | |
| <div class="bg-gradient-to-r from-blue-500 to-indigo-600 text-white p-4 flex items-center justify-between"> | |
| <div class="flex items-center space-x-3"> | |
| <div class="bg-white p-1 rounded-full"> | |
| <img src="http://static.photos/people/200x200/42" alt="Агент" class="rounded-full w-8 h-8 object-cover"> | |
| </div> | |
| <div> | |
| <h2 class="font-bold">Поддержка</h2> | |
| <p class="text-xs text-blue-100">Обычно отвечает за несколько минут</p> | |
| </div> | |
| </div> | |
| <button onclick="window.close()" class="text-white hover:text-gray-200"> | |
| <i class="fas fa-times"></i> | |
| </button> | |
| </div> | |
| <!-- Основная область чата --> | |
| <div class="flex-1 overflow-y-auto p-4 space-y-4"> | |
| <!-- Сообщение от агента --> | |
| <div class="flex items-start space-x-2"> | |
| <img src="http://static.photos/people/200x200/42" alt="Агент" class="rounded-full w-8 h-8 object-cover"> | |
| <div class="bg-white p-3 rounded-lg rounded-tl-none max-w-xs md:max-w-md"> | |
| <p class="text-gray-800">Здравствуйте! Как я могу вам помочь?</p> | |
| <span class="text-xs text-gray-500 block mt-1">10:00</span> | |
| </div> | |
| </div> | |
| <!-- Сообщение от пользователя --> | |
| <div class="flex justify-end"> | |
| <div class="bg-blue-500 text-white p-3 rounded-lg rounded-tr-none max-w-xs md:max-w-md"> | |
| <p>Привет! У меня вопрос по вашему сервису.</p> | |
| <span class="text-xs text-blue-100 block mt-1 text-right">10:02</span> | |
| </div> | |
| </div> | |
| <!-- Сообщение от агента --> | |
| <div class="flex items-start space-x-2"> | |
| <img src="http://static.photos/people/200x200/42" alt="Агент" class="rounded-full w-8 h-8 object-cover"> | |
| <div class="bg-white p-3 rounded-lg rounded-tl-none max-w-xs md:max-w-md"> | |
| <p class="text-gray-800">Конечно, задавайте ваш вопрос и я постараюсь помочь!</p> | |
| <span class="text-xs text-gray-500 block mt-1">10:03</span> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Поле ввода --> | |
| <div class="bg-white p-3 border-t border-gray-200"> | |
| <div class="flex items-center"> | |
| <input | |
| type="text" | |
| placeholder="Введите сообщение..." | |
| class="flex-1 border border-gray-300 rounded-l-lg py-2 px-4 focus:outline-none focus:ring-2 focus:ring-blue-300 focus:border-transparent" | |
| > | |
| <button class="bg-gradient-to-r from-blue-500 to-indigo-600 text-white py-2 px-4 rounded-r-lg hover:from-blue-600 hover:to-indigo-700 transition-colors"> | |
| <i class="fas fa-paper-plane"></i> | |
| </button> | |
| </div> | |
| <div class="flex justify-between mt-2 text-xs text-gray-500"> | |
| <span>Нажмите Enter для отправки</span> | |
| <span>Защита данных</span> | |
| </div> | |
| </div> | |
| </body> | |
| </html> |