feat(portal-shell): clean widget design tokens and fix lint:tokens (P1-6)
516 mechanical replacements across 25 widget files: - spacing xs/sm/md/lg/xl to numeric 1/2/3/4/6 - text-heading-3 to text-lg font-semibold - bg-danger to bg-destructive - border border dedup Fix .eslintrc.tokens.js to use typescript-eslint parser (was importing uninstalled @typescript-eslint/parser). lint:tokens now passes.
This commit is contained in:
@@ -2,16 +2,17 @@
|
||||
* ESLint Design Tokens 配置(独立运行:eslint -c .eslintrc.tokens.js src)
|
||||
*
|
||||
* 与 eslint.config.js 中的 design-tokens 规则等价,保留以对齐 teacher-portal 习惯。
|
||||
* 使用 typescript-eslint 包的 parser(与 eslint.config.js 一致)。
|
||||
* 关联:project_rules §3.10
|
||||
*/
|
||||
import tsParser from "@typescript-eslint/parser";
|
||||
import tseslint from "typescript-eslint";
|
||||
|
||||
/** @type {import('eslint').Linter.Config[]} */
|
||||
export default [
|
||||
export default tseslint.config(
|
||||
{
|
||||
files: ["**/*.{ts,tsx,js,jsx}"],
|
||||
languageOptions: {
|
||||
parser: tsParser,
|
||||
parser: tseslint.parser,
|
||||
ecmaVersion: 2024,
|
||||
sourceType: "module",
|
||||
parserOptions: {
|
||||
@@ -40,4 +41,4 @@ export default [
|
||||
"no-restricted-syntax": "off",
|
||||
},
|
||||
},
|
||||
];
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user