test: 38 layout mode tests + fix half/full/float CSS positioning
- Fix side panel and full screen not covering full viewport - Fix floating mode initial position (near chat button, not top-right) - Reset width/height inline styles when switching modes - Add 84-chat-layout-modes.test.mjs: 38 assertions covering compact, side panel, full screen, floating, drag, rapid switching, and user avatar rendering
This commit is contained in:
@@ -210,10 +210,13 @@ document.addEventListener('htmx:afterRequest', function(event) {
|
||||
function setChatSize(size) {
|
||||
var panel = document.getElementById('chat-panel');
|
||||
panel.classList.remove('chat-half', 'chat-full', 'chat-float');
|
||||
// Reset all inline styles from drag/resize
|
||||
panel.style.top = '';
|
||||
panel.style.left = '';
|
||||
panel.style.right = '';
|
||||
panel.style.bottom = '';
|
||||
panel.style.width = '';
|
||||
panel.style.height = '';
|
||||
if (size) panel.classList.add(size);
|
||||
// Update active button
|
||||
document.querySelectorAll('.chat-mode-btn[data-mode]').forEach(function(btn) {
|
||||
|
||||
Reference in New Issue
Block a user