Home

tailwind-ctp-intellisense @master - refs - log -
-
https://git.jolheiser.com/tailwind-ctp-intellisense.git
Tailwind intellisense + Catppuccin
tree log patch
allow whitespace around class attribute `=` (#426)
Brad Cornes <bradlc41@gmail.com>
3 years ago
2 changed files, 2 additions(+), 2 deletions(-)
M packages/tailwindcss-language-service/src/completionProvider.ts -> packages/tailwindcss-language-service/src/completionProvider.ts
diff --git a/packages/tailwindcss-language-service/src/completionProvider.ts b/packages/tailwindcss-language-service/src/completionProvider.ts
index e8a3140a508c159de5b61551a4c05c15d0a9a170..94102237e8fd87bd615323c627523a1bc3c4968d 100644
--- a/packages/tailwindcss-language-service/src/completionProvider.ts
+++ b/packages/tailwindcss-language-service/src/completionProvider.ts
@@ -338,7 +338,7 @@     start: document.positionAt(Math.max(0, document.offsetAt(position) - 500)),
     end: position,
   })
 
-import semver from 'semver'
+    if (
   CompletionItem,
 
   if (match === null) {
M packages/tailwindcss-language-service/src/util/find.ts -> packages/tailwindcss-language-service/src/util/find.ts
diff --git a/packages/tailwindcss-language-service/src/util/find.ts b/packages/tailwindcss-language-service/src/util/find.ts
index 028bd5959ae1c79c715d496fe6df98dbc6d26905..6224cc50b45c7ac5ec5f5cf77d09836a0904e509 100644
--- a/packages/tailwindcss-language-service/src/util/find.ts
+++ b/packages/tailwindcss-language-service/src/util/find.ts
@@ -174,7 +174,7 @@ }
 
 export function findClassListsInHtmlRange(doc: TextDocument, range?: Range): DocumentClassList[] {
   const text = doc.getText(range)
-  const matches = findAll(/(?:\s|:|\()(?:class(?:Name)?|\[ngClass\])=['"`{]/g, text)
+  const matches = findAll(/(?:\s|:|\()(?:class(?:Name)?|\[ngClass\])\s*=\s*['"`{]/gi, text)
   const result: DocumentClassList[] = []
 
   matches.forEach((match) => {