Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const PATTERN_CUSTOM_V3 = /@(?<directive>config)\s*(?<partial>'[^']*|"[^"]*)$/
// @import … source('…')
// @tailwind utilities source('…')
const PATTERN_IMPORT_SOURCE =
/@(?<directive>(?:import|reference))\s*(?<path>'[^']*'|"[^"]*")\s*source\((?<partial>'[^']*|"[^"]*)$/
/@(?<directive>(?:import|reference))\s*(?<path>'[^']*'|"[^"]*")\s*(layer\([^)]+\)\s*)?source\((?<partial>'[^']*|"[^"]*)$/
const PATTERN_UTIL_SOURCE =
/@(?<directive>tailwind)\s+utilities\s+source\((?<partial>'[^']*|"[^"]*)?$/

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { absoluteRange } from '../util/absoluteRange'
// @import … source('…')
// @tailwind utilities source('…')
const PATTERN_IMPORT_SOURCE =
/(?:\s|^)@(?<directive>(?:import|reference))\s*(?<path>'[^']*'|"[^"]*")\s*source\((?<source>'[^']*'?|"[^"]*"?|[a-z]*|\)|;)/dg
/(?:\s|^)@(?<directive>(?:import|reference))\s*(?<path>'[^']*'|"[^"]*")\s*(layer\([^)]+\)\s*)?source\((?<source>'[^']*'?|"[^"]*"?|[a-z]*|\)|;)/dg
const PATTERN_UTIL_SOURCE =
/(?:\s|^)@(?<directive>tailwind)\s+(?<layer>\S+)\s+source\((?<source>'[^']*'?|"[^"]*"?|[a-z]*|\)|;)/dg

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export function getDocumentLinks(
patterns.push(
/@plugin\s*(?<path>'[^']+'|"[^"]+")/g,
/@source\s*(?<path>'[^']+'|"[^"]+")/g,
/@import\s*('[^']*'|"[^"]*")\s*source\((?<path>'[^']*'?|"[^"]*"?)/g,
/@import\s*('[^']*'|"[^"]*")\s*(layer\([^)]+\)\s*)?source\((?<path>'[^']*'?|"[^"]*"?)/g,
/@reference\s*('[^']*'|"[^"]*")\s*source\((?<path>'[^']*'?|"[^"]*"?)/g,
/@tailwind\s*utilities\s*source\((?<path>'[^']*'?|"[^"]*"?)/g,
)
Expand Down
1 change: 1 addition & 0 deletions packages/vscode-tailwindcss/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

- Show light color swatch from light-dark() functions ([#1199](https://github.com/tailwindlabs/tailwindcss-intellisense/pull/1199))
- Ignore comments when matching class attributes ([#1202](https://github.com/tailwindlabs/tailwindcss-intellisense/pull/1202))
- Show source diagnostics when imports contain a layer ([#1204](https://github.com/tailwindlabs/tailwindcss-intellisense/pull/1204))

## 0.14.4

Expand Down