feat: on a computer the assistant's ball and chat can be dragged, the chat opening beside the ball; on a phone a smaller ball further from the edges; the send button the field's height

This commit is contained in:
redtea committed 2026-10-15 22:29:55 +03:00
1 parent ed77c8e0c1
commit 3044e650d3
2 files changed
+82 -3

No files matched your search

+14 -2
View File
@@ -820,11 +820,11 @@ dialog.machinedlg { max-width:1000px; width:94vw; max-height:90vh; padding:0; ov
.ai-form label { display:grid; gap:4px; font-size:13px; color:var(--muted); }
/* The assistant: a round button, and the chat over the page's corner. */
.ai-fab { position:fixed; right:18px; bottom:18px; z-index:40; width:52px; height:52px; padding:0; border-radius:50%;
.ai-fab { position:fixed; right:28px; bottom:28px; z-index:40; width:52px; height:52px; padding:0; border-radius:50%;
display:inline-flex; align-items:center; justify-content:center; box-shadow:0 8px 24px rgba(0,0,0,.45); }
.ai-fab[hidden] { display:none; }
body.touch.term-active .ai-fab { bottom:104px; }
.ai-box { position:fixed; right:18px; bottom:82px; z-index:41; width:360px; max-width:calc(100vw - 24px); height:min(500px, calc(100vh - 120px));
.ai-box { position:fixed; right:28px; bottom:96px; z-index:41; width:360px; max-width:calc(100vw - 24px); height:min(500px, calc(100vh - 120px));
display:flex; flex-direction:column; background:var(--panel); border:1px solid var(--border); border-radius:12px;
box-shadow:0 18px 44px rgba(0,0,0,.55); overflow:hidden; transform-origin:bottom right;
opacity:0; visibility:hidden; pointer-events:none; transform:translateY(14px) scale(.96);
@@ -876,3 +876,15 @@ dialog.uidlg { max-width:420px; width:92vw; }
.ai-think { margin:0 0 6px; font-size:12.5px; color:var(--muted); }
.ai-think summary { cursor:pointer; }
.ai-think > div { margin-top:4px; padding-left:10px; border-left:2px solid var(--border); max-height:200px; overflow:auto; }
/* The chat's title moves it on a computer. */
body:not(.touch) .ai-head { cursor:grab; user-select:none; }
body.ai-dragging, body.ai-dragging * { cursor:grabbing !important; user-select:none; }
body:not(.touch) .ai-fab { cursor:grab; touch-action:none; }
/* Send: the field's height, square. */
.ai-form-in textarea, .ai-send { box-sizing:border-box; }
.ai-send { width:40px; height:40px; align-self:flex-end; }
@media (max-width: 640px) {
.ai-fab { width:46px; height:46px; right:22px; bottom:24px; }
body.touch.term-active .ai-fab { bottom:110px; }
.ai-form-in textarea { font-size:16px; }
}