Skip to content

Support MUI v5; removal of "@mui/styles" dependency; TypeScript rewrite; #338

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 25 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
fced3c0
Support MUI v5 (and upgrade to React v17).
sah Oct 1, 2021
af3f6c3
Adding @mui/styles as a peer dependency, and fixing docs references t…
sah Oct 3, 2021
bc1fb0e
Internal - removed Rollup in favor of TypeScript; added `tsconfig.json`;
Deckstar Dec 15, 2021
1f7846b
Internal - removed `.js` files to use `.ts` and `.tsx` extensions;
Deckstar Dec 15, 2021
e304eb5
New - updated ESLint setup & updated devDependencies;
Deckstar Dec 15, 2021
c0c902f
Internal - ran Prettier "/src" files;
Deckstar Dec 15, 2021
352428d
Internal - added @mui/styles to fix TS errors;
Deckstar Dec 15, 2021
77f46af
Internal - moved "index.d.ts" file into "/types" folder;
Deckstar Dec 15, 2021
a931691
Improve - converted all "/src" files to be written in TypeScript;
Deckstar Dec 15, 2021
1525458
Improve - moved JSDoc comments into TS interfaces so they would show …
Deckstar Dec 16, 2021
b08a413
Improve - removed `withStyles` in favor of MUI 5's new `styled` api; …
Deckstar Dec 16, 2021
7b808cf
Improve - better TS compilation settings:
Deckstar Dec 16, 2021
a52dea9
Internal - updated "/dist" folder to use files made with TSC;
Deckstar Dec 16, 2021
475f2d7
Internal - deleted "/dist" file;
Deckstar Dec 16, 2021
8445d24
Internal - added "/dist" folder to `.gitignore`;
Deckstar Dec 16, 2021
ddb08d8
Improve - updated package.json with new name,version and description;…
Deckstar Dec 16, 2021
fbf5914
Internal - updated README;
Deckstar Dec 16, 2021
a39d9a2
Internal - renamed package since previous name was unavailable;
Deckstar Dec 16, 2021
a557ad4
Fix - fixed npm package being published without dist folder;
Deckstar Dec 16, 2021
568b72a
Internal - renamed package to bypass 24-hour npm "no-republish" rule;
Deckstar Dec 16, 2021
139180d
Fix - fixed files not loading due to JSX not being converted;
Deckstar Dec 16, 2021
2e42cab
Fix - fixed styling and ref-forwarding issues;
Deckstar Dec 16, 2021
3aa3cae
4.0.1
Deckstar Dec 16, 2021
ae139bc
Add src packages to distribution
primal100 Aug 7, 2022
f8b742d
Merge pull request #1 from primal100/master
Deckstar Sep 17, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
123 changes: 57 additions & 66 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,91 +5,82 @@
"mocha": true,
"node": true
},
"parser": "babel-eslint",
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 7,
"sourceType": "module",
"ecmaFeatures": {
"jsx": true,
"experimentalObjectRestSpread": true
"experimentalObjectRestSpread": true,
"jsx": true
}
},
"globals": {
"React": true
"React": true,
"JSX": true
},
"settings": {
"import/resolver": {
"node": {
"extensions": [".js", ".jsx", ".d.ts", ".ts", ".tsx"]
}
},
"react": {
"version": "15.0"
"version": "detect"
}
},
"plugins": [
"babel",
"react"
"@typescript-eslint",
"react-hooks",
"react",
"simple-import-sort",
"import"
],
"extends": [
"eslint:recommended",
"plugin:react/recommended"
"plugin:react/recommended",
"plugin:import/errors",
"plugin:import/typescript",
"prettier"
],
"rules": {
"array-bracket-spacing": ["error", "never"],
"arrow-parens": "error",
"arrow-spacing": "error",
"brace-style": "error",
"comma-dangle": ["error", "always-multiline"],
"comma-spacing": ["error", {"before": false, "after": true}],
"comma-style": ["error", "last"],
"computed-property-spacing": ["error", "never"],
"consistent-return": "off",
"consistent-this": ["error", "self"],
"dot-location": ["error", "property"],
"dot-notation": "error",
"eol-last": "error",
"eqeqeq": ["error", "smart"],
"generator-star-spacing": "error",
"id-blacklist": ["error", "e"],
"indent": ["error", 4, {"SwitchCase": 1}],
"jsx-quotes": ["error", "prefer-double"],
"key-spacing": "error",
"keyword-spacing": "error",
"max-len": ["error", 120, 4, {"ignoreComments": true}],
"new-cap": ["off", {"capIsNew": true, "newIsCap": true}],
"no-await-in-loop": "error",
"no-case-declarations": "off",
"no-cond-assign": "error",
"no-dupe-args": "error",
"no-dupe-keys": "error",
"no-duplicate-case": "error",
"no-empty-pattern": "error",
"no-extra-boolean-cast": "error",
"no-extra-semi": "error",
"no-multi-spaces": "error",
"no-multiple-empty-lines": "error",
"no-shadow": "off",
"no-spaced-func": "error",
"no-trailing-spaces": "error",
"no-undef": "error",
"no-underscore-dangle": "error",
"no-unneeded-ternary": "error",
"@typescript-eslint/no-shadow": ["error", { "hoist": "never" }],
"@typescript-eslint/no-unused-vars": [
"error",
{
"args": "after-used",
"argsIgnorePattern": "^_",
"ignoreRestSiblings": true,
"varsIgnorePattern": "^_"
}
],
"arrow-body-style": 0,
"camelcase": 0,
"class-methods-use-this": 0,
"import/no-deprecated": "warn",
"import/no-duplicates": "error",
"import/no-extraneous-dependencies": 0,
"import/order": "off",
"no-confusing-arrow": 0,
"no-console": "warn",
"no-else-return": 0,
"no-nested-ternary": 0,
"no-param-reassign": ["error", { "props": false }],
"no-restricted-syntax": 0,
"no-return-assign": [2, "except-parens"],
"no-underscore-dangle": 0,
"no-unreachable": "error",
"no-unused-expressions": "error",
"no-unused-vars": "error",
"no-var": "error",
"object-curly-spacing": ["error", "never"],
"one-var": ["error", "never"],
"operator-linebreak": ["error", "after"],
"padded-blocks": ["error", "never"],
"prefer-arrow-callback": "off",
"prefer-const": "error",
"quotes": ["error", "single", "avoid-escape"],
"semi": ["error", "always"],
"space-before-blocks": ["error", "always"],
"space-before-function-paren": ["error", "never"],
"space-infix-ops": "error",
"space-unary-ops": ["error", {"words": true, "nonwords": false}],
"spaced-comment": "error",
"strict": "off",
"yoda": "error",
"babel/new-cap": "off",
"babel/object-shorthand": "off"
"no-unused-expressions": ["error", { "allowTernary": true }],
"prefer-arrow-callback": ["error", { "allowNamedFunctions": true }],
"react-hooks/exhaustive-deps": "error",
"react-hooks/rules-of-hooks": "error",
"react/destructuring-assignment": 0,
"react/jsx-filename-extension": 0,
"react/no-multi-comp": 0,
"react/no-unescaped-entities": 0,
"react/prop-types": 0,
"simple-import-sort/exports": "error",
"simple-import-sort/imports": "error",
"sort-imports": "off"
}
}
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ If applicable, add screenshots to help explain your problem.

- OS: [e.g. iOS]
- Browser: [e.g. chrome, safari]
- `@material-ui/core` version: [e.g. 4.9.2]
- `@mui/material` version: [e.g. 5.0.2]
- `material-ui-dropzone` version: [e.g. 3.0.1]

### Additional context
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,5 @@
build/
node_modules/
styleguide/
tsconfig.tsbuildinfo
/dist
3 changes: 3 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"jsxSingleQuote": false
}
18 changes: 9 additions & 9 deletions .size-snapshot.json
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
{
"dist/index.js": {
"bundled": 57189,
"minified": 25753,
"gzipped": 5983
"bundled": 57136,
"minified": 25700,
"gzipped": 5981
},
"dist/index.es.js": {
"bundled": 56007,
"minified": 24741,
"gzipped": 5861,
"bundled": 55954,
"minified": 24688,
"gzipped": 5858,
"treeshaked": {
"rollup": {
"code": 10815,
"import_statements": 1533
"code": 10762,
"import_statements": 1480
},
"webpack": {
"code": 21871
"code": 21818
}
}
}
Expand Down
6 changes: 6 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"recommendations": [
"dbaeumer.vscode-eslint", // ESLint
"esbenp.prettier-vscode" // Prettier
]
}
22 changes: 22 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"editor.tabSize": 2,
"editor.insertSpaces": true,
"editor.formatOnSave": true,
"eslint.enable": true,
"eslint.lintTask.enable": true,
"eslint.lintTask.options": "--ext .js,.jsx,.ts,.tsx .",
"eslint.validate": [
"javascript",
"javascriptreact",
"typescript",
"typescriptreact"
],
"editor.codeActionsOnSave": {
"source.fixAll": true
},
"files.insertFinalNewline": true,
"files.trimTrailingWhitespace": true,
"[typescriptreact]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
}
}
Loading