(file)
| 754 | } |
| 755 | |
| 756 | function detachLspForFile(file) { |
| 757 | if (!file || file.type !== "editor") return; |
| 758 | const uri = getFileLspUri(file); |
| 759 | if (!uri) return; |
| 760 | try { |
| 761 | lspClientManager.detach(uri); |
| 762 | } catch (error) { |
| 763 | console.warn(`Failed to detach LSP client for ${uri}`, error); |
| 764 | } |
| 765 | if (uri === lastLspUri && manager.activeFile?.id === file.id) { |
| 766 | lastLspUri = null; |
| 767 | editor.dispatch({ effects: lspCompartment.reconfigure([]) }); |
| 768 | } |
| 769 | } |
| 770 | |
| 771 | // Plugin already wires CSS completions; attach extras for related syntaxes. |
| 772 | const emmetCompletionSyntaxes = new Set([ |
no test coverage detected