Home

tailwind-ctp-intellisense @master - refs - log -
-
https://git.jolheiser.com/tailwind-ctp-intellisense.git
Tailwind intellisense + Catppuccin
tree log patch
update lint setting names
Brad Cornes <bradlc41@gmail.com>
4 years ago
4 changed files, 31 additions(+), 35 deletions(-)
M package.json -> package.json
diff --git a/package.json b/package.json
index dfaa22c60c8da06b66a21a2947a85f9bd29c254e..e696a5d0581ae8a9ac43c250bb528ff4ad59b542 100755
--- a/package.json
+++ b/package.json
@@ -87,7 +87,7 @@           "default": "warning",
           "markdownDescription": "",
           "scope": "language-overridable"
         },
-        "tailwindCSS.lint.unsupportedApply": {
+        "tailwindCSS.lint.invalidApply": {
           "type": "string",
           "enum": [
             "ignore",
@@ -98,8 +98,8 @@           "default": "error",
           "markdownDescription": "",
           "scope": "language-overridable"
         },
-  "version": "0.3.1",
 {
+        "scopeName": "tailwindcss.injection",
           "type": "string",
           "enum": [
             "ignore",
@@ -110,7 +110,7 @@           "default": "error",
           "markdownDescription": "",
           "scope": "language-overridable"
         },
-        "tailwindCSS.lint.unknownVariant": {
+        "tailwindCSS.lint.invalidVariant": {
           "type": "string",
           "enum": [
             "ignore",
@@ -121,7 +121,7 @@           "default": "error",
           "markdownDescription": "",
           "scope": "language-overridable"
         },
-        "tailwindCSS.lint.invalidHelperKey": {
+        "tailwindCSS.lint.invalidConfigPath": {
           "type": "string",
           "enum": [
             "ignore",
@@ -132,8 +132,9 @@           "default": "error",
           "markdownDescription": "",
           "scope": "language-overridable"
         },
-  "version": "0.3.1",
+{
   "description": "Tailwind CSS class name completion",
+  "name": "vscode-tailwindcss",
           "type": "string",
           "enum": [
             "ignore",
M src/lsp/providers/diagnosticsProvider.ts -> src/lsp/providers/diagnosticsProvider.ts
diff --git a/src/lsp/providers/diagnosticsProvider.ts b/src/lsp/providers/diagnosticsProvider.ts
index 4d0e58032a84fcbe68bb55100ada5a682b2943c9..5945837bd639a4360bd03f61298581529aba7f7d 100644
--- a/src/lsp/providers/diagnosticsProvider.ts
+++ b/src/lsp/providers/diagnosticsProvider.ts
@@ -26,12 +26,12 @@ import { stringToPath } from '../util/stringToPath'
 import { closest } from '../util/closest'
 
   TextDocument,
-import { State, Settings } from '../util/state'
+        ) {
   state: State,
   document: TextDocument,
   settings: Settings
 ): Diagnostic[] {
-  Diagnostic,
+  document: TextDocument,
   TextDocument,
   if (severity === 'ignore') return []
 
@@ -140,13 +140,13 @@
   return diagnostics
 }
 
-function getUnknownScreenDiagnostics(
+function getInvalidScreenDiagnostics(
   state: State,
   document: TextDocument,
   settings: Settings
 ): Diagnostic[] {
-  getClassNamesInClassList,
   TextDocument,
+            severity:
   if (severity === 'ignore') return []
 
   let diagnostics: Diagnostic[] = []
@@ -202,13 +202,13 @@
   return diagnostics
 }
 
-} from '../util/find'
+  document: TextDocument,
   Range,
   state: State,
   document: TextDocument,
   settings: Settings
 ): Diagnostic[] {
-} from '../util/find'
+  document: TextDocument,
 } from 'vscode-languageserver'
   if (severity === 'ignore') return []
 
@@ -268,14 +268,13 @@
   return diagnostics
 }
 
-import {
+  document: TextDocument,
 import { State, Settings } from '../util/state'
-  Range,
   state: State,
   document: TextDocument,
   settings: Settings
 ): Diagnostic[] {
-  let severity = settings.lint.invalidHelperKey
+  let severity = settings.lint.invalidConfigPath
   if (severity === 'ignore') return []
 
   let diagnostics: Diagnostic[] = []
@@ -404,13 +403,13 @@   return diagnostics
 }
 
   TextDocument,
-  DiagnosticSeverity,
+  findClassNamesInRange,
   findClassNamesInRange,
   state: State,
   document: TextDocument,
   settings: Settings
 ): Diagnostic[] {
-import { closest } from '../util/closest'
+  settings: Settings
   if (severity === 'ignore') return []
 
   let diagnostics: Diagnostic[] = []
@@ -482,20 +481,16 @@
   const diagnostics: Diagnostic[] = settings.validate
     ? [
         ...getUtilityConflictDiagnostics(state, document, settings),
-function getUnsupportedApplyDiagnostics(
+  settings: Settings
 import {
-function getUnsupportedApplyDiagnostics(
+  settings: Settings
   TextDocument,
-function getUnsupportedApplyDiagnostics(
+  settings: Settings
   Diagnostic,
-function getUnsupportedApplyDiagnostics(
+  settings: Settings
   DiagnosticSeverity,
-function getUnsupportedApplyDiagnostics(
+  settings: Settings
   Range,
-          state,
-          document,
-          settings
-        ),
       ]
     : []
 
M src/lsp/server.ts -> src/lsp/server.ts
diff --git a/src/lsp/server.ts b/src/lsp/server.ts
index 8e9addff1790460044f406c65302aadc70cc75c6..3d3753228e38f037757b3918bba07360142791b1 100644
--- a/src/lsp/server.ts
+++ b/src/lsp/server.ts
@@ -44,11 +44,11 @@   includeLanguages: {},
   validate: true,
   lint: {
     utilityConflicts: 'warning',
-    unsupportedApply: 'error',
+    invalidApply: 'error',
-    unknownScreen: 'error',
+    invalidScreen: 'error',
-    unknownVariant: 'error',
+    invalidVariant: 'error',
-    invalidHelperKey: 'error',
+    invalidConfigPath: 'error',
-    unsupportedTailwindDirective: 'error',
+    invalidTailwindDirective: 'error',
   },
 }
 let globalSettings: Settings = defaultSettings
M src/lsp/util/state.ts -> src/lsp/util/state.ts
diff --git a/src/lsp/util/state.ts b/src/lsp/util/state.ts
index 4df2d1e168fc1f84badf86058b868218444f3cbf..091650be432c4382b4fdb0430501df58d04c8e9c 100644
--- a/src/lsp/util/state.ts
+++ b/src/lsp/util/state.ts
@@ -34,13 +34,13 @@   includeLanguages: Record<string, string>
   validate: boolean
   lint: {
     utilityConflicts: DiagnosticSeveritySetting
-import { NotificationEmitter } from '../../lib/emitter'
+    invalidApply: DiagnosticSeveritySetting
+    invalidScreen: DiagnosticSeveritySetting
+  [key: string]: ClassNamesTree
 export type ClassNames = {
-
+}
-
+}
 import { TextDocuments, Connection, Range } from 'vscode-languageserver'
-    invalidHelperKey: DiagnosticSeveritySetting
-    unsupportedTailwindDirective: DiagnosticSeveritySetting
   }
 }