From 3e5e171896c6c12a80acd63c45545bb5fee287e3 Mon Sep 17 00:00:00 2001 From: Patrick Pircher Date: Fri, 20 Jun 2025 13:46:17 +0200 Subject: [PATCH 1/2] fix glint when manually configured --- src/main/kotlin/com/emberjs/glint/GlintLspSupportProvider.kt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/main/kotlin/com/emberjs/glint/GlintLspSupportProvider.kt b/src/main/kotlin/com/emberjs/glint/GlintLspSupportProvider.kt index 5ebd5f70..da1656a6 100644 --- a/src/main/kotlin/com/emberjs/glint/GlintLspSupportProvider.kt +++ b/src/main/kotlin/com/emberjs/glint/GlintLspSupportProvider.kt @@ -139,7 +139,6 @@ class GlintLspServerDescriptor(private val myProject: Project) : LspServerDescri fun getGlintVersion(): String? { val workingDir = lastDir!! - val workDirectory = VfsUtilCore.virtualToIoFile(workingDir) var path = workingDir.findFileByRelativePath("node_modules/@glint/core/package.json") ?: return null return PackageJsonData.getOrCreate(path).version?.rawVersion } @@ -152,7 +151,7 @@ class GlintLspServerDescriptor(private val myProject: Project) : LspServerDescri val pkg = config.getPackage() val pkgPath = pkg.`package`.constantPackage?.systemIndependentPath if (pkgPath != null && File(pkgPath).exists()) { - path = File(pkgPath).parentFile.parentFile.path + path = File(pkgPath).parentFile.parentFile.parentFile.path } path = path.replace("\\", "/") this.isWsl = false From d1f4ef97c1628c7e7d7aef8fab9d07165833fd2a Mon Sep 17 00:00:00 2001 From: Patrick Pircher Date: Fri, 27 Jun 2025 10:04:33 +0200 Subject: [PATCH 2/2] fix missing completions for component args in hbs --- src/main/kotlin/com/emberjs/hbs/TagReferencesProvider.kt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main/kotlin/com/emberjs/hbs/TagReferencesProvider.kt b/src/main/kotlin/com/emberjs/hbs/TagReferencesProvider.kt index abf5c1bf..8723e29e 100644 --- a/src/main/kotlin/com/emberjs/hbs/TagReferencesProvider.kt +++ b/src/main/kotlin/com/emberjs/hbs/TagReferencesProvider.kt @@ -199,6 +199,9 @@ fun toAttributeReference(target: XmlAttribute): PsiReference? { if (name.length == 1) { return null } + if (!name.contains("|")) { + return null + } var range = TextRange(0, name.length) if (name.startsWith("|")) { range = TextRange(1, range.endOffset)