@juristr/nx-tailwind-sync 0.0.6 → 0.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -23,7 +23,7 @@ function findTailwindCssFile(tree, projectRoot, additionalPaths = []) {
23
23
  for (const relPath of searchPaths) {
24
24
  const fullPath = (0, path_1.join)(projectRoot, relPath);
25
25
  const content = tree.read(fullPath)?.toString();
26
- if (content?.match(/@import\s+['"]tailwindcss[^'"]*['"]/)) {
26
+ if (content?.match(/@import\s+['"]tailwindcss[^'"]*['"](\s+source\([^)]*\))?/)) {
27
27
  return fullPath;
28
28
  }
29
29
  }
@@ -143,7 +143,7 @@ function updateSourceDirectives(tree, projectName, cssFilePath, projectGraph) {
143
143
  // Remove any existing bare @source directives (migration from old format)
144
144
  const cleanedContent = currentContent.replace(/\n@source\s+["'][^"']*packages\/[^"']+["'];/g, '');
145
145
  // Try to find @import 'tailwindcss' first
146
- const tailwindImportRegex = /@import\s+['"]tailwindcss[^'"]*['"];/;
146
+ const tailwindImportRegex = /@import\s+['"]tailwindcss[^'"]*['"](\s+source\([^)]*\))?;/;
147
147
  const tailwindImportMatch = cleanedContent.match(tailwindImportRegex);
148
148
  // If not found, look for any @import statement
149
149
  const anyImportRegex = /@import\s+['"][^'"]+['"];/;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@juristr/nx-tailwind-sync",
3
- "version": "0.0.6",
3
+ "version": "0.0.7",
4
4
  "author": "Juri Strumpflohner",
5
5
  "license": "MIT",
6
6
  "repository": {