Skip to content

Commit 5c52f85

Browse files
committed
upgrade intellij idea version
1 parent 9c23067 commit 5c52f85

File tree

9 files changed

+13
-19
lines changed

9 files changed

+13
-19
lines changed

build.gradle.kts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,19 +42,19 @@ intellij {
4242
// Example: platformPlugins = com.intellij.java, com.jetbrains.php:203.4449.22
4343
//
4444
// com.dmarcotte.handlebars: see https://plugins.jetbrains.com/plugin/6884-handlebars-mustache/versions
45-
plugins.set(listOf("JavaScriptLanguage", "CSS", "yaml", "com.dmarcotte.handlebars:223.7571.117"))
45+
plugins.set(listOf("JavaScript", "com.intellij.css", "org.jetbrains.plugins.yaml", "com.dmarcotte.handlebars:223.7571.117"))
4646

4747
sandboxDir.set(project.rootDir.canonicalPath + "/.sandbox")
4848
}
4949

5050
tasks {
5151
// Set the compatibility versions to 1.8
5252
withType<JavaCompile> {
53-
sourceCompatibility = "1.8"
54-
targetCompatibility = "1.8"
53+
sourceCompatibility = "17"
54+
targetCompatibility = "17"
5555
}
5656
withType<KotlinCompile> {
57-
kotlinOptions.jvmTarget = "1.8"
57+
kotlinOptions.jvmTarget = "17"
5858
}
5959

6060
publishPlugin {

src/main/kotlin/com/emberjs/EmberAttributeDescriptor.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ import com.intellij.psi.util.PsiTreeUtil
1111
import com.intellij.psi.xml.XmlAttribute
1212
import com.intellij.psi.xml.XmlElement
1313
import com.intellij.psi.xml.XmlTag
14-
import com.intellij.util.castSafelyTo
1514
import com.intellij.xml.XmlAttributeDescriptor
1615

1716
class EmberAttributeDescriptor(val context: XmlTag, value: String, isYield: Boolean = false, description: String?, reference: PsiReference?, references: Array<PsiReference>?) : XmlAttributeDescriptor {

src/main/kotlin/com/emberjs/cli/EmberCliFrameworkDetector.kt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@ import com.intellij.framework.detection.FileContentPattern
1212
import com.intellij.framework.detection.FrameworkDetectionContext
1313
import com.intellij.framework.detection.FrameworkDetector
1414
import com.intellij.ide.projectView.actions.MarkRootActionBase
15-
import com.intellij.javascript.nodejs.PackageJsonDependency
16-
import com.intellij.javascript.nodejs.packageJson.PackageJsonDependencies
1715
import com.intellij.javascript.nodejs.packageJson.PackageJsonFileManager
1816
import com.intellij.json.JsonFileType
1917
import com.intellij.openapi.application.ApplicationManager

src/main/kotlin/com/emberjs/cli/EmberCliProjectConfigurator.kt

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,8 @@ import com.emberjs.settings.EmberApplicationOptions
44
import com.emberjs.utils.*
55
import com.intellij.ide.projectView.actions.MarkRootActionBase
66
import com.intellij.javascript.nodejs.PackageJsonDependency
7-
import com.intellij.javascript.nodejs.library.NodeModulesDirectoryChecker
8-
import com.intellij.javascript.nodejs.library.NodeModulesDirectoryManager
9-
import com.intellij.javascript.nodejs.library.NodeModulesPackageJsonListener
107
import com.intellij.lang.javascript.dialects.JSLanguageLevel
118
import com.intellij.lang.javascript.library.JSLibraryManager
12-
import com.intellij.lang.javascript.linter.jshint.JSHintConfiguration
13-
import com.intellij.lang.javascript.linter.jshint.JSHintState
149
import com.intellij.lang.javascript.settings.JSRootConfiguration
1510
import com.intellij.openapi.application.ApplicationManager
1611
import com.intellij.openapi.module.Module
@@ -19,7 +14,6 @@ import com.intellij.openapi.project.Project
1914
import com.intellij.openapi.roots.ContentEntry
2015
import com.intellij.openapi.roots.ModifiableRootModel
2116
import com.intellij.openapi.roots.ModuleRootManager
22-
import com.intellij.openapi.roots.libraries.Library.ModifiableModel
2317
import com.intellij.openapi.util.Ref
2418
import com.intellij.openapi.vfs.VirtualFile
2519
import com.intellij.platform.DirectoryProjectConfigurator

src/main/kotlin/com/emberjs/glint/GlintLanguageService.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ class GlintTypeScriptService(private val project: Project) : TypeScriptService,
7575

7676
override fun isServiceCreated() = withServer { isRunning || isMalfunctioned } ?: false
7777

78-
override fun showStatusBar() = withServer { totalFilesOpened != 0 } ?: false
78+
override fun showStatusBar() = withServer { isServiceCreated() } ?: false
7979

8080
override fun getStatusText() = withServer {
8181
when {

src/main/kotlin/com/emberjs/navigation/EmberGotoClassContributor.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import com.intellij.util.indexing.FindSymbolParameters.searchScopeFor
1717
class EmberGotoClassContributor : GotoClassContributor {
1818
private val iconProvider by lazy { EmberIconProvider() }
1919

20-
override fun getQualifiedName(item: NavigationItem?): String? {
20+
override fun getQualifiedName(item: NavigationItem): String? {
2121
if (item is DelegatingNavigationItem) {
2222
return item.presentation?.presentableText?.replace("-", qualifiedNameSeparator)
2323
}

src/main/kotlin/com/emberjs/resolver/EmberModuleReferenceContributor.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import com.intellij.ide.highlighter.HtmlFileType
88
import com.intellij.lang.javascript.DialectDetector
99
import com.intellij.lang.javascript.frameworks.amd.JSModuleReference
1010
import com.intellij.lang.javascript.frameworks.modules.JSExactFileReference
11+
import com.intellij.lang.javascript.frameworks.modules.JSFileModuleReference
1112
import com.intellij.lang.javascript.psi.resolve.JSModuleReferenceContributor
1213
import com.intellij.openapi.util.TextRange
1314
import com.intellij.openapi.vfs.VirtualFile

src/main/kotlin/com/emberjs/utils/EmberUtils.kt

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,23 +16,24 @@ import com.emberjs.navigation.EmberGotoRelatedProvider
1616
import com.emberjs.psi.EmberNamedElement
1717
import com.emberjs.resolver.EmberJSModuleReference
1818
import com.intellij.injected.editor.VirtualFileWindow
19+
import com.intellij.javascript.JSModuleBaseReference
1920
import com.intellij.lang.Language
2021
import com.intellij.lang.ecmascript6.psi.ES6ImportExportDeclaration
2122
import com.intellij.lang.ecmascript6.psi.ES6ImportedBinding
2223
import com.intellij.lang.ecmascript6.resolve.ES6PsiUtil
2324
import com.intellij.lang.injection.InjectedLanguageManager
24-
import com.intellij.lang.javascript.frameworks.modules.JSModuleReferenceBase
25+
import com.intellij.lang.javascript.frameworks.amd.JSModuleReference
2526
import com.intellij.lang.javascript.psi.*
2627
import com.intellij.lang.javascript.psi.ecma6.*
2728
import com.intellij.lang.javascript.psi.ecma6.impl.TypeScriptClassImpl
2829
import com.intellij.lang.javascript.psi.ecma6.impl.TypeScriptTupleTypeImpl
2930
import com.intellij.lang.javascript.psi.ecmal4.JSClass
3031
import com.intellij.lang.javascript.psi.jsdoc.JSDocComment
3132
import com.intellij.lang.javascript.psi.types.*
32-
import com.intellij.lang.typescript.modules.TypeScriptFileModuleReference
3333
import com.intellij.psi.*
3434
import com.intellij.psi.impl.file.PsiDirectoryImpl
3535
import com.intellij.psi.impl.source.resolve.reference.impl.providers.FileReference
36+
import com.intellij.psi.impl.source.resolve.reference.impl.providers.FileReferenceSet
3637
import com.intellij.psi.impl.source.tree.LeafPsiElement
3738
import com.intellij.psi.search.ProjectScope
3839
import com.intellij.psi.util.PsiTreeUtil
@@ -259,9 +260,9 @@ class EmberUtils {
259260
fun followReferences(element: PsiElement?, path: String? = null): PsiElement? {
260261

261262
if (element is ES6ImportedBinding) {
262-
var ref: JSModuleReferenceBase? = element.declaration?.fromClause?.references?.find { it is EmberJSModuleReference } as EmberJSModuleReference?
263+
var ref: JSModuleReference? = element.declaration?.fromClause?.references?.find { it is EmberJSModuleReference } as EmberJSModuleReference?
263264
if (ref == null) {
264-
val tsFiles = element.declaration?.fromClause?.references?.mapNotNull { (it as? TypeScriptFileModuleReference)?.resolve() }
265+
val tsFiles = element.declaration?.fromClause?.references?.mapNotNull { (it as? FileReferenceSet)?.resolve() }
265266
return tsFiles?.maxByOrNull { it.virtualFile.path.length }
266267
}
267268

src/main/resources/META-INF/plugin.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
on how to target different products -->
3939
<depends>com.intellij.modules.lang</depends>
4040
<depends>JavaScript</depends>
41+
<depends>com.intellij.css</depends>
4142
<depends optional="true" config-file="yaml.xml">org.jetbrains.plugins.yaml</depends>
4243
<depends config-file="handlebars.xml">com.dmarcotte.handlebars</depends>
4344
<depends optional="true" config-file="hbs-injections.xml">org.intellij.intelliLang</depends>

0 commit comments

Comments
 (0)