Skip to content

Commit 68ab875

Browse files
authored
chore: Migrate to tailwind (#1355)
1 parent 1bb8afc commit 68ab875

File tree

381 files changed

+15368
-19113
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

381 files changed

+15368
-19113
lines changed

.babelrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"presets": ["@babel/preset-env", "@babel/preset-react"],
2+
"presets": ["@babel/preset-env", "@babel/preset-react", "@babel/preset-typescript"],
33
"plugins": [
44
["babel-plugin-wildcard", { "exts": ["json"], "nostrip": true, "noModifyCase": true }],
55
[

.dockerignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
.vscode
55
.eslintrc.yml
66
.gitignore
7-
.sass-lint.yml
87
.travis.yml
98

109
node_modules

.eslintrc.yml

Lines changed: 48 additions & 83 deletions
Original file line numberDiff line numberDiff line change
@@ -11,116 +11,81 @@ ignorePatterns:
1111
extends:
1212
- 'eslint:recommended'
1313
- 'plugin:react/recommended'
14-
parser: '@babel/eslint-parser'
14+
- 'plugin:@typescript-eslint/recommended' # Add TypeScript rules
15+
- 'plugin:import/errors'
16+
- 'plugin:import/warnings'
17+
- 'plugin:import/typescript' # Import plugin with TypeScript support
18+
- 'plugin:jsx-a11y/recommended'
19+
- 'prettier' # If you use Prettier
20+
parser: '@typescript-eslint/parser' # Use the TypeScript parser
1521
parserOptions:
1622
ecmaFeatures:
17-
experimentalObjectRestSpread: true
1823
jsx: true
19-
legacyDecorators: true
2024
sourceType: module
25+
project: './tsconfig.json' # Required for full TypeScript support
2126
plugins:
2227
- react
2328
- jsx-a11y
2429
- import
30+
- '@typescript-eslint'
2531
- simple-import-sort
2632
- cypress
27-
- chai-friendly # See https://github.com/cypress-io/eslint-plugin-cypress#chai-and-no-unused-expressions
33+
- chai-friendly
2834
settings:
2935
react:
3036
version: detect
37+
import/resolver:
38+
typescript: {}
39+
node:
40+
extensions:
41+
- .js
42+
- .jsx
43+
- .ts
44+
- .tsx
45+
paths:
46+
- src
3147
rules:
48+
# Base rules
3249
linebreak-style: ['error', 'unix']
3350
quotes: ['warn', 'single', { avoidEscape: true }]
3451
semi: ['error', 'never']
35-
import/first: ['warn']
36-
simple-import-sort/imports: ['error']
37-
no-else-return: off
38-
no-trailing-spaces: ['warn']
39-
no-continue: off
40-
no-plusplus: off
41-
radix: off
42-
eol-last: ['warn']
52+
no-console: ['error']
4353
prefer-const: ['warn']
44-
no-restricted-globals: ['error', 'event', 'fdescribe']
45-
no-mixed-operators: ['warn']
46-
# See https://github.com/cypress-io/eslint-plugin-cypress#chai-and-no-unused-expressions
47-
no-unused-expressions: 0
48-
chai-friendly/no-unused-expressions: 2
49-
# React
54+
curly: ['error']
55+
import/no-named-as-default-member: ['off']
56+
57+
# Import sorting
58+
simple-import-sort/imports: ['error']
59+
import/first: ['warn']
60+
61+
# TypeScript-specific rules
62+
'@typescript-eslint/no-unused-vars': ['warn', { argsIgnorePattern: '^_' }]
63+
'@typescript-eslint/no-explicit-any': ['warn']
64+
'@typescript-eslint/explicit-function-return-type': ['off']
65+
'@typescript-eslint/no-empty-function': ['warn']
66+
67+
# React rules
5068
react/display-name: ['warn']
51-
react/destructuring-assignment: off
52-
react/jsx-indent-props: ['warn', 2]
53-
react/jsx-first-prop-new-line: ['warn']
54-
react/jsx-closing-bracket-location: ['warn']
55-
react/jsx-curly-spacing: ['warn']
56-
react/jsx-tag-spacing: ['warn', { beforeSelfClosing: 'allow' }]
57-
react/jsx-wrap-multilines: ['warn']
58-
react/no-unused-state: ['warn']
59-
react/jsx-max-props-per-line: ['warn', { when: 'multiline' }]
60-
react/jsx-closing-tag-location: ['warn']
61-
react/no-unescaped-entities: ['warn']
62-
react/no-unused-prop-types: ['warn']
63-
react/self-closing-comp: ['warn']
6469
react/jsx-indent: ['warn', 2]
70+
react/jsx-max-props-per-line: ['warn', { when: 'multiline' }]
6571
react/no-array-index-key: ['warn']
66-
react/prefer-stateless-function: off
67-
react/forbid-prop-types: off
68-
# JSX
72+
react/prop-types: ['off']
73+
74+
# Accessibility rules
6975
jsx-a11y/anchor-is-valid:
7076
- warn
7177
- components: ['Link']
72-
specialLink: ['To']
73-
jsx-a11y/alt-text: ['warn']
74-
jsx-a11y/label-has-for: ['warn']
75-
jsx-a11y/label-has-associated-control:
76-
- warn
77-
- controlComponents:
78-
- 'Field'
79-
jsx-a11y/click-events-have-key-events: ['warn']
80-
jsx-a11y/no-static-element-interactions: ['warn']
78+
specialLink: ['to']
79+
jsx-a11y/label-has-associated-control: ['warn']
8180
jsx-a11y/media-has-caption: ['warn']
82-
jsx-a11y/accessible-emoji: ['warn']
83-
jsx-a11y/anchor-has-content: off
84-
no-console: ['error']
85-
curly: ['error']
86-
87-
# Following rule haves been disabled for compatibility with
88-
# existing code. Some of them should be re-activated in the future.
89-
no-shadow: off
90-
nonblock-statement-body-position: off
91-
object-curly-spacing: off
92-
object-curly-newline: off
93-
object-property-newline: off
94-
comma-dangle: off
95-
function-paren-newline: off
96-
arrow-parens: off
97-
arrow-body-style: off
98-
no-use-before-define: off
99-
no-param-reassign: off
100-
camelcase: off
101-
no-underscore-dangle: off
102-
no-restricted-syntax: off
103-
prefer-destructuring: off
104-
consistent-return: off
105-
class-methods-use-this: off
106-
prefer-promise-reject-errors: off
107-
import/prefer-default-export: off
108-
import/export: off
109-
block-spacing: off
110-
brace-style: off
111-
no-multi-spaces: off
112-
max-len: off # Handled by prettier
113-
# React-specific temporarily disabled rules
114-
react/prop-types: off
115-
react/no-string-refs: off
116-
react/react-in-jsx-scope: off # Generates erros in tests
117-
react/sort-comp: off
118-
react/require-default-props: off
119-
react/jsx-one-expression-per-line: off
120-
react/jsx-no-bind: off
81+
react/no-unescaped-entities: ['warn']
12182

83+
overrides:
84+
- files: ['**/__tests__/**/*.[jt]s?(x)', '**/*.test.[jt]s?(x)', '**/*.spec.[jt]s?(x)']
85+
rules:
86+
react/react-in-jsx-scope: 'off'
87+
'@typescript-eslint/no-unused-expressions': 'off'
12288
globals:
123-
# For tests
12489
snapshot: false
12590
snapshotReducer: false
12691
snapshotComponent: false

.github/workflows/ci.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,30 @@ jobs:
2727
run: CYPRESS_INSTALL_BINARY=0 npm ci
2828
- run: npm run prettier:check
2929

30+
typescript:
31+
runs-on: ubuntu-latest
32+
steps:
33+
- uses: actions/checkout@v1
34+
- uses: actions/setup-node@v3
35+
with:
36+
node-version-file: '.tool-versions'
37+
cache: 'npm'
38+
- name: Install dependencies
39+
run: CYPRESS_INSTALL_BINARY=0 npm ci
40+
- run: npm run typescript
41+
42+
unused-exports:
43+
runs-on: ubuntu-latest
44+
steps:
45+
- uses: actions/checkout@v1
46+
- uses: actions/setup-node@v3
47+
with:
48+
node-version-file: '.tool-versions'
49+
cache: 'npm'
50+
- name: Install dependencies
51+
run: CYPRESS_INSTALL_BINARY=0 npm ci
52+
- run: npm run ts-unused-exports
53+
3054
test:
3155
name: Unit tests
3256
runs-on: ubuntu-latest

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
*.swp
99
*.vi
1010
*~
11-
*.sass-cache
1211

1312
# OS or Editor folders
1413
.DS_Store

.sass-lint.yml

Lines changed: 0 additions & 95 deletions
This file was deleted.

0 commit comments

Comments
 (0)