diff --git a/integrations/intellij/gradle.properties b/integrations/intellij/gradle.properties index 887e89e60ec..e998be544cc 100644 --- a/integrations/intellij/gradle.properties +++ b/integrations/intellij/gradle.properties @@ -8,7 +8,7 @@ pluginVersion = 1.27.2 # See https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html # for insight into build numbers and IntelliJ Platform versions. pluginSinceBuild = 231 -pluginUntilBuild = 232 +pluginUntilBuild = 233.* # Plugin Verifier integration -> https://github.com/JetBrains/gradle-intellij-plugin#plugin-verifier-dsl # See https://jb.gg/intellij-platform-builds-list for available build versions. diff --git a/integrations/intellij/src/main/kotlin/com/previewjs/intellij/plugin/services/ProjectService.kt b/integrations/intellij/src/main/kotlin/com/previewjs/intellij/plugin/services/ProjectService.kt index c4fb31aa19d..c6d934be681 100644 --- a/integrations/intellij/src/main/kotlin/com/previewjs/intellij/plugin/services/ProjectService.kt +++ b/integrations/intellij/src/main/kotlin/com/previewjs/intellij/plugin/services/ProjectService.kt @@ -1,6 +1,6 @@ package com.previewjs.intellij.plugin.services -import com.intellij.codeInsight.hints.InlayHintsPassFactory +import com.intellij.codeInsight.daemon.DaemonCodeAnalyzer import com.intellij.execution.filters.TextConsoleBuilderFactory import com.intellij.execution.ui.ConsoleView import com.intellij.execution.ui.ConsoleViewContentType @@ -215,9 +215,13 @@ class ProjectService(private val project: Project) : Disposable { private fun recrawlFile(file: VirtualFile, text: String) { crawlFile(file) { components -> componentMap[file.path] = Pair(text, components) - @Suppress("UnstableApiUsage") app.invokeLater { - InlayHintsPassFactory.forceHintsUpdateOnNextPass() + // This is very inefficient but there is no better way since + // InlayHintsPassFactory was moved to an internal package in + // IJ 2023.3. + // + // See https://youtrack.jetbrains.com/issue/IDEA-333164 + DaemonCodeAnalyzer.getInstance(project).restart() } } }