Skip to content

Commit ce3779e

Browse files
fix browser back, logo click, navItem select and sidebar open large d… (codedthemes#23)
* fix browser back, logo click, navItem select and sidebar open large device fix * Task 5093: Code Review (fixed eslint, prettier, props, unused code and files) --------- Co-authored-by: ct-amit <[email protected]>
1 parent 019b9e5 commit ce3779e

File tree

107 files changed

+28193
-36420
lines changed

Some content is hidden

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

107 files changed

+28193
-36420
lines changed

.env

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
REACT_APP_VERSION = v1.1.0
1+
REACT_APP_VERSION = v1.1.1
22
GENERATE_SOURCEMAP = false

.eslintrc

+85-52
Original file line numberDiff line numberDiff line change
@@ -1,56 +1,89 @@
11
{
2-
"root": true,
3-
"env": {
4-
"browser": true,
5-
"es2021": true
2+
"root": true,
3+
"env": {
4+
"browser": true,
5+
"es2021": true
6+
},
7+
"extends": [
8+
"prettier",
9+
"plugin:react/jsx-runtime",
10+
"plugin:jsx-a11y/recommended",
11+
"plugin:react-hooks/recommended",
12+
"eslint:recommended",
13+
"plugin:react/recommended"
14+
],
15+
"settings": {
16+
"react": {
17+
"createClass": "createReactClass", // Regex for Component Factory to use,
18+
// default to "createReactClass"
19+
"pragma": "React", // Pragma to use, default to "React"
20+
"fragment": "Fragment", // Fragment to use (may be a property of <pragma>), default to "Fragment"
21+
"version": "detect", // React version. "detect" automatically picks the version you have installed.
22+
// You can also use `16.0`, `16.3`, etc, if you want to override the detected value.
23+
// It will default to "latest" and warn if missing, and to "detect" in the future
24+
"flowVersion": "0.53" // Flow version
625
},
7-
"extends": ["prettier", "plugin:react/jsx-runtime", "plugin:jsx-a11y/recommended", "plugin:react-hooks/recommended"],
8-
"settings": {
9-
"import/resolver": {
10-
"node": {
11-
"moduleDirectory": ["node_modules", "src/"]
12-
}
13-
}
14-
},
15-
"parser": "@babel/eslint-parser",
16-
"parserOptions": {
17-
"ecmaFeatures": {
18-
"experimentalObjectRestSpread": true,
19-
"impliedStrict": true
20-
},
21-
"ecmaVersion": 12
22-
},
23-
"plugins": ["prettier", "react", "react-hooks"],
24-
"rules": {
25-
"react/jsx-filename-extension": 0,
26-
"no-param-reassign": 0,
27-
"react/prop-types": 1,
28-
"react/require-default-props": 0,
29-
"react/no-array-index-key": 0,
30-
"react/jsx-props-no-spreading": 0,
31-
"react/forbid-prop-types": 0,
32-
"import/order": 0,
33-
"no-console": 0,
34-
"jsx-a11y/anchor-is-valid": 0,
35-
"prefer-destructuring": 0,
36-
"no-shadow": 0,
37-
"no-unused-vars": [
38-
1,
39-
{
40-
"ignoreRestSiblings": false
41-
}
42-
],
43-
"prettier/prettier": [
44-
2,
45-
{
46-
"bracketSpacing": true,
47-
"printWidth": 140,
48-
"singleQuote": true,
49-
"trailingComma": "none",
50-
"tabWidth": 4,
51-
"useTabs": false,
52-
"endOfLine": "auto"
53-
}
54-
]
26+
"import/resolver": {
27+
"node": {
28+
"moduleDirectory": ["node_modules", "src/"]
29+
}
5530
}
31+
},
32+
"parser": "@babel/eslint-parser",
33+
"parserOptions": {
34+
"ecmaFeatures": {
35+
"experimentalObjectRestSpread": true,
36+
"impliedStrict": true,
37+
"jsx": true
38+
},
39+
"ecmaVersion": 12
40+
},
41+
"plugins": ["prettier", "react", "react-hooks"],
42+
"rules": {
43+
"react/jsx-uses-react": "error",
44+
"react/jsx-uses-vars": "error",
45+
"react/react-in-jsx-scope": "off",
46+
"no-undef": "off",
47+
"react/display-name": "off",
48+
"react/jsx-filename-extension": "off",
49+
"no-param-reassign": "off",
50+
"react/prop-types": 1,
51+
"react/require-default-props": "off",
52+
"react/no-array-index-key": "off",
53+
"react/jsx-props-no-spreading": "off",
54+
"react/forbid-prop-types": "off",
55+
"import/order": "off",
56+
"import/no-cycle": "off",
57+
"no-console": "off",
58+
"jsx-a11y/anchor-is-valid": "off",
59+
"prefer-destructuring": "off",
60+
"no-shadow": "off",
61+
"import/no-named-as-default": "off",
62+
"import/no-extraneous-dependencies": "off",
63+
"jsx-a11y/no-autofocus": "off",
64+
"no-restricted-imports": [
65+
"error",
66+
{
67+
"patterns": ["@mui/*/*/*", "!@mui/material/test-utils/*"]
68+
}
69+
],
70+
"no-unused-vars": [
71+
"error",
72+
{
73+
"ignoreRestSiblings": false
74+
}
75+
],
76+
"prettier/prettier": [
77+
"warn",
78+
{
79+
"bracketSpacing": true,
80+
"printWidth": 140,
81+
"singleQuote": true,
82+
"trailingComma": "none",
83+
"tabWidth": 2,
84+
"useTabs": false,
85+
"endOfLine": "auto"
86+
}
87+
]
88+
}
5689
}

.github/ISSUE_TEMPLATE/bug_report.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,16 @@ If applicable, add screenshots to help explain your problem.
2525

2626
**Desktop (please complete the following information):**
2727

28-
- OS: [e.g. iOS]
29-
- Browser [e.g. chrome, safari]
30-
- Version [e.g. 22]
28+
- OS: [e.g. iOS]
29+
- Browser [e.g. chrome, safari]
30+
- Version [e.g. 22]
3131

3232
**Smartphone (please complete the following information):**
3333

34-
- Device: [e.g. iPhone6]
35-
- OS: [e.g. iOS8.1]
36-
- Browser [e.g. stock browser, safari]
37-
- Version [e.g. 22]
34+
- Device: [e.g. iPhone6]
35+
- OS: [e.g. iOS8.1]
36+
- Browser [e.g. stock browser, safari]
37+
- Version [e.g. 22]
3838

3939
**Additional context**
4040
Add any other context about the problem here.

.github/workflows/prod.yml

+29-29
Original file line numberDiff line numberDiff line change
@@ -2,38 +2,38 @@ name: Node - SSH deploy
22

33
# Controls when the action will run.
44
on:
5-
# Triggers the workflow on push or pull request events but only for the master branch
6-
push:
7-
branches: [main]
8-
pull_request:
9-
branches: [main]
5+
# Triggers the workflow on push or pull request events but only for the master branch
6+
push:
7+
branches: [main]
8+
pull_request:
9+
branches: [main]
1010

1111
jobs:
12-
SFTP-deploy:
13-
name: 🎉 Deploy
14-
runs-on: ubuntu-latest
12+
SFTP-deploy:
13+
name: 🎉 Deploy
14+
runs-on: ubuntu-latest
1515

16-
steps:
17-
- name: 🚚 Get latest code
18-
uses: actions/checkout@v2
16+
steps:
17+
- name: 🚚 Get latest code
18+
uses: actions/checkout@v2
1919

20-
- name: Use Node.js 16
21-
uses: actions/setup-node@v2-beta
22-
with:
23-
node-version: '16'
20+
- name: Use Node.js 16
21+
uses: actions/setup-node@v2-beta
22+
with:
23+
node-version: '16'
2424

25-
- name: 🔨 Build Project
26-
run: |
27-
yarn
28-
yarn build
25+
- name: 🔨 Build Project
26+
run: |
27+
yarn
28+
yarn build
2929
30-
- name: 📂 Deploy to Server
31-
uses: easingthemes/[email protected]
32-
env:
33-
SSH_PRIVATE_KEY: ${{ secrets.SERVER_SSH_KEY }}
34-
# ARGS: "-rltgoDzvO --delete"
35-
SOURCE: 'build/'
36-
REMOTE_HOST: 192.34.62.123
37-
REMOTE_USER: mantis
38-
TARGET: public_html/free
39-
EXCLUDE: '/dist/, /node_modules/'
30+
- name: 📂 Deploy to Server
31+
uses: easingthemes/[email protected]
32+
env:
33+
SSH_PRIVATE_KEY: ${{ secrets.SERVER_SSH_KEY }}
34+
# ARGS: "-rltgoDzvO --delete"
35+
SOURCE: 'build/'
36+
REMOTE_HOST: 192.34.62.123
37+
REMOTE_USER: mantis
38+
TARGET: public_html/free
39+
EXCLUDE: '/dist/, /node_modules/'

.prettierrc

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
2-
"bracketSpacing": true,
3-
"printWidth": 140,
4-
"singleQuote": true,
5-
"trailingComma": "none",
6-
"tabWidth": 4,
7-
"useTabs": false
2+
"bracketSpacing": true,
3+
"printWidth": 140,
4+
"singleQuote": true,
5+
"trailingComma": "none",
6+
"tabWidth": 2,
7+
"useTabs": false
88
}

CODE_OF_CONDUCT.md

+15-15
Original file line numberDiff line numberDiff line change
@@ -17,24 +17,24 @@ diverse, inclusive, and healthy community.
1717
Examples of behavior that contributes to a positive environment for our
1818
community include:
1919

20-
- Demonstrating empathy and kindness toward other people
21-
- Being respectful of differing opinions, viewpoints, and experiences
22-
- Giving and gracefully accepting constructive feedback
23-
- Accepting responsibility and apologizing to those affected by our mistakes,
24-
and learning from the experience
25-
- Focusing on what is best not just for us as individuals, but for the
26-
overall community
20+
- Demonstrating empathy and kindness toward other people
21+
- Being respectful of differing opinions, viewpoints, and experiences
22+
- Giving and gracefully accepting constructive feedback
23+
- Accepting responsibility and apologizing to those affected by our mistakes,
24+
and learning from the experience
25+
- Focusing on what is best not just for us as individuals, but for the
26+
overall community
2727

2828
Examples of unacceptable behavior include:
2929

30-
- The use of sexualized language or imagery, and sexual attention or
31-
advances of any kind
32-
- Trolling, insulting or derogatory comments, and personal or political attacks
33-
- Public or private harassment
34-
- Publishing others' private information, such as a physical or email
35-
address, without their explicit permission
36-
- Other conduct which could reasonably be considered inappropriate in a
37-
professional setting
30+
- The use of sexualized language or imagery, and sexual attention or
31+
advances of any kind
32+
- Trolling, insulting or derogatory comments, and personal or political attacks
33+
- Public or private harassment
34+
- Publishing others' private information, such as a physical or email
35+
address, without their explicit permission
36+
- Other conduct which could reasonably be considered inappropriate in a
37+
professional setting
3838

3939
## Enforcement Responsibilities
4040

0 commit comments

Comments
 (0)