mirror of
https://github.com/agent0ai/agent-zero.git
synced 2026-12-04 09:28:56 +00:00
The no-scrollbar utility suppressed the indicator on the 120px-capped queue preview, so stacked messages looked cut off at the visible edge. The class is dropped so the app-wide slim scrollbar styles apply. Validation: pytest tests/test_webui_message_queue_static.py tests/test_webui_topbar_stack_static.py -q (4 passed); visual check on a nested mock instance
32 lines
1.1 KiB
Python
32 lines
1.1 KiB
Python
from pathlib import Path
|
|
|
|
|
|
PROJECT_ROOT = Path(__file__).resolve().parents[1]
|
|
|
|
|
|
def read(*parts: str) -> str:
|
|
return (PROJECT_ROOT / Path(*parts)).read_text(encoding="utf-8")
|
|
|
|
|
|
def test_pending_queue_thumbnails_use_local_blob_urls():
|
|
store_js = read("webui", "components", "chat", "message-queue", "message-queue-store.js")
|
|
queue_html = read("webui", "components", "chat", "message-queue", "message-queue.html")
|
|
|
|
assert "_pendingAttachmentUrls" in store_js
|
|
assert "getAttachmentUrl(item, filename)" in store_js
|
|
assert "attachmentUrls?.[filename]" in store_js
|
|
assert "getAttachmentUrl(item, att)" in queue_html
|
|
|
|
|
|
def test_failed_queue_adds_drop_pending_entries():
|
|
store_js = read("webui", "components", "chat", "message-queue", "message-queue-store.js")
|
|
|
|
assert store_js.count("_dropPendingItem(tempId)") >= 3
|
|
|
|
|
|
def test_queue_preview_keeps_app_scrollbar():
|
|
queue_html = read("webui", "components", "chat", "message-queue", "message-queue.html")
|
|
|
|
assert '<div class="queue-items">' in queue_html
|
|
assert 'queue-items no-scrollbar' not in queue_html
|