Update ui-bindings.js

This commit is contained in:
2025-12-31 15:14:45 +08:00
committed by GitHub
parent 3fab375cb5
commit 809c8de2ff

View File

@@ -402,6 +402,24 @@ function bindEvents() {
toastr.error(`连接失败: ${result.error || '未知错误'}`); toastr.error(`连接失败: ${result.error || '未知错误'}`);
} }
}); });
// Mobile Navigation Logic
$('.acc-nav-btn').on('click', function() {
const targetClass = $(this).data('target');
// Update buttons
$('.acc-nav-btn').removeClass('active');
$(this).addClass('active');
// Update panels
$('.acc-column').removeClass('mobile-active');
$(`.${targetClass}`).addClass('mobile-active');
});
// Initialize mobile view (default to center panel)
if (window.innerWidth <= 768) {
$('.acc-center-panel').addClass('mobile-active');
}
} }
async function handleSendMessage() { async function handleSendMessage() {