MCPcopy Create free account
hub / github.com/error311/FileRise / updateDualPaneTargetHint

Function updateDualPaneTargetHint

public/js/fileListView.js:2145–2165  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2143}
2144
2145function updateDualPaneTargetHint() {
2146 const hint = ensureDualPaneTargetHint();
2147 if (!hint) return;
2148 if (!window.dualPaneEnabled || !window.__frPaneState) {
2149 hint.style.display = 'none';
2150 return;
2151 }
2152 const active = normalizePaneKey(window.activePane);
2153 const other = active === 'secondary' ? 'primary' : 'secondary';
2154 const otherFolder = window.__frPaneState?.[other]?.currentFolder || '';
2155 if (!otherFolder) {
2156 hint.style.display = 'none';
2157 return;
2158 }
2159 const otherSourceId = window.__frPaneState?.[other]?.sourceId || '';
2160 const sideLabel = other === 'secondary' ? 'Right' : 'Left';
2161 const folderLabel = otherFolder === 'root' ? getRootLabel(otherSourceId) : otherFolder;
2162 hint.textContent = `Target: ${sideLabel} -> ${folderLabel}`;
2163 hint.title = `Copy/move target is the ${sideLabel.toLowerCase()} pane folder.`;
2164 hint.style.display = 'inline-flex';
2165}
2166
2167function syncFolderStripWithPaneState(paneKey) {
2168 const strip = document.getElementById('folderStripContainer');

Callers 4

setActivePaneFunction · 0.85
applyDualPaneModeFunction · 0.85
loadFileListFunction · 0.85

Calls 3

ensureDualPaneTargetHintFunction · 0.85
normalizePaneKeyFunction · 0.85
getRootLabelFunction · 0.70

Tested by

no test coverage detected