Skip to content

Commit 1f38e22

Browse files
committed
Add document links and completions for @source
1 parent 040c8ca commit 1f38e22

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

packages/tailwindcss-language-service/src/completionProvider.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1537,7 +1537,7 @@ async function provideFileDirectiveCompletions(
15371537
}
15381538

15391539
let pattern = state.v4
1540-
? /@(config|plugin)\s*(?<partial>'[^']*|"[^"]*)$/
1540+
? /@(config|plugin|source)\s*(?<partial>'[^']*|"[^"]*)$/
15411541
: /@config\s*(?<partial>'[^']*|"[^"]*)$/
15421542

15431543
let text = document.getText({ start: { line: position.line, character: 0 }, end: position })

packages/tailwindcss-language-service/src/documentLinksProvider.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ export function getDocumentLinks(
2020
if (state.v4) {
2121
patterns.push(
2222
/@plugin\s*(?<path>'[^']+'|"[^"]+")/g,
23+
/@source\s*(?<path>'[^']+'|"[^"]+")/g,
2324
)
2425
}
2526

0 commit comments

Comments
 (0)