1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-06 00:13:28 +00:00

[CL-660] Forbid non tailwind classes from web and libs (#14422)

* Forbid non tailwind classes from web and libs

* Ignore vault filter section
This commit is contained in:
Oscar Hinton
2025-07-25 17:52:01 +02:00
committed by GitHub
parent 2db31d1228
commit 22b8fc5f7d
2 changed files with 21 additions and 0 deletions

View File

@@ -310,6 +310,26 @@ export default tseslint.config(
"no-console": "off",
},
},
// Tailwind migrated clients & libs
{
files: ["apps/web/**/*.html", "bitwarden_license/bit-web/**/*.html", "libs/**/*.html"],
rules: {
"tailwindcss/no-custom-classname": [
"error",
{
// In migrated clients we only allow tailwind classes plus the following exceptions
whitelist: [
"((bwi)\\-?).*", // Font icons
"logo",
"logo-themed",
"file-selector",
"mfaType.*",
"filter.*", // Temporary until filters are migrated
],
},
],
},
},
/// Bandaids for keeping existing circular dependencies from getting worse and new ones from being created
/// Will be removed after Nx is implemented and existing circular dependencies are removed.
{