MCPcopy Create free account
hub / github.com/MiroMindAI/MiroThinker / toggleBrowserNav

Function toggleBrowserNav

apps/visualize-trace/static/js/script.js:1103–1116  ·  view source on GitHub ↗
(stepIndex, event)

Source from the content-addressed store, hash-verified

1101}
1102
1103function toggleBrowserNav(stepIndex, event) {
1104 event.stopPropagation(); // 阻止事件冒泡
1105
1106 const browserNavElement = document.getElementById(`browser-nav-${stepIndex}`);
1107 const toggleIcon = event.target.closest('.browser-toggle').querySelector('i');
1108
1109 if (browserNavElement.classList.contains('expanded')) {
1110 browserNavElement.classList.remove('expanded');
1111 toggleIcon.className = 'fas fa-chevron-down';
1112 } else {
1113 browserNavElement.classList.add('expanded');
1114 toggleIcon.className = 'fas fa-chevron-up';
1115 }
1116}
1117
1118function updateActiveNavItem(activeIndex, browserStepId = null) {
1119 // 移除所有活跃状态

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected