MCPcopy Create free account
hub / github.com/CodeClash-ai/CodeClash / toggleModelDropdown

Function toggleModelDropdown

codeclash/viewer/static/js/picker.js:1038–1054  ·  view source on GitHub ↗
(event)

Source from the content-addressed store, hash-verified

1036}
1037
1038function toggleModelDropdown(event) {
1039 event.stopPropagation();
1040 const dropdown = document.getElementById("model-filter-options");
1041 const button = document.getElementById("model-filter-button");
1042 const isVisible = dropdown.style.display !== "none";
1043
1044 if (isVisible) {
1045 dropdown.style.display = "none";
1046 } else {
1047 // Calculate position based on button location
1048 const buttonRect = button.getBoundingClientRect();
1049 dropdown.style.left = buttonRect.left + "px";
1050 dropdown.style.top = buttonRect.bottom + 4 + "px";
1051 dropdown.style.width = buttonRect.width + "px";
1052 dropdown.style.display = "block";
1053 }
1054}
1055
1056function handleGameNameClick(event, gameName) {
1057 event.stopPropagation();

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected