From 35ffd89064afa95a0e19eac1f44ad5cd38e9dc3f Mon Sep 17 00:00:00 2001 From: Dinesh Srini Date: Thu, 19 Oct 2023 15:02:34 -0300 Subject: [PATCH] Adding fileTypes and updating docs. --- CHANGELOG.md | 4 ++++ README.md | 2 ++ gradle.properties | 2 +- .../action/editor/codeIntellisense/annotator/NgxsAnnotator.kt | 2 ++ src/main/resources/META-INF/plugin.xml | 2 ++ 5 files changed, 11 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3815d8e..b58891e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,10 @@ # ngxs Changelog ## [Unreleased] +### Added +- Introducing FileTypes for `*.state.ts;*actions.ts;*.selectors.ts` for Jetbrains to recommend NGXS plugin +### Fixed +- Fixed Error - Java.lang.RuntimeException: java.lang.Exception: NgxsAnnotator ## [0.0.7] - 2023-10-15 diff --git a/README.md b/README.md index 7c02df6..b473b2b 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,8 @@ auto-completions for Jetbrains IDE. # Features +> Checkout the [Feature](https://plugins.jetbrains.com/plugin/22604-ngxs/features) documentation for more details. + - Simply right click -> New -> NGXS CLI/Schematics to generate a boiler plate store. - Navigate to Action Implementation using Gutter Icons - LiveTemplate to autocompletion for creating `@Actions`, `@Selectors` and `export class NewActions` quickly diff --git a/gradle.properties b/gradle.properties index 15dedbc..39c6cf4 100644 --- a/gradle.properties +++ b/gradle.properties @@ -4,7 +4,7 @@ pluginGroup = com.github.dinbtechit.ngxs pluginName = ngxs pluginRepositoryUrl = https://github.com/dinbtechit/ngxs # SemVer format -> https://semver.org -pluginVersion = 0.0.7 +pluginVersion = 0.0.8 # Supported build number ranges and IntelliJ Platform versions -> https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html pluginSinceBuild = 223 diff --git a/src/main/kotlin/com/github/dinbtechit/ngxs/action/editor/codeIntellisense/annotator/NgxsAnnotator.kt b/src/main/kotlin/com/github/dinbtechit/ngxs/action/editor/codeIntellisense/annotator/NgxsAnnotator.kt index 96355cc..882f9c7 100644 --- a/src/main/kotlin/com/github/dinbtechit/ngxs/action/editor/codeIntellisense/annotator/NgxsAnnotator.kt +++ b/src/main/kotlin/com/github/dinbtechit/ngxs/action/editor/codeIntellisense/annotator/NgxsAnnotator.kt @@ -29,6 +29,8 @@ class NgxsAnnotator : Annotator { var actionFileName: String? = null var actionVirtualFile: VirtualFile? = null + if (!element.containingFile.name.contains(".ts")) return + if (NgxsActionsPsiUtil.isActionClass(element)) { isImplementationExist = NgxsActionsPsiUtil.isActionImplExist(element) problemType = ProblemHighlightType.LIKE_UNUSED_SYMBOL diff --git a/src/main/resources/META-INF/plugin.xml b/src/main/resources/META-INF/plugin.xml index 60f14c5..018d7e2 100644 --- a/src/main/resources/META-INF/plugin.xml +++ b/src/main/resources/META-INF/plugin.xml @@ -10,6 +10,8 @@ messages.NgxsBundle +