-
Notifications
You must be signed in to change notification settings - Fork 27
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(JS) update autoHideNavbarSupport.uc.js
to fix an oversight in a previous version. switch to mozilla ESLint plugin, so add linter config and refactor all scripts to clear the current linter config. (CSS) fix some modal dialogs having abnormally large font size.
- Loading branch information
1 parent
2b4a435
commit f62a16d
Showing
77 changed files
with
3,642 additions
and
3,376 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
/* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this | ||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */ | ||
|
||
module.exports = { | ||
plugins: [ | ||
"@babel/plugin-syntax-jsx", | ||
], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,96 @@ | ||
/* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this | ||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */ | ||
|
||
"use strict"; | ||
|
||
const path = require("path"); | ||
|
||
module.exports = { | ||
parser: "@babel/eslint-parser", | ||
parserOptions: { | ||
sourceType: "script", | ||
babelOptions: { | ||
configFile: path.join(__dirname, ".babel-eslint.rc.js"), | ||
}, | ||
}, | ||
settings: { | ||
"import/extensions": [".mjs"], | ||
}, | ||
rules: { | ||
"no-implied-eval": "error", | ||
"consistent-return": "off", | ||
"no-empty": "off", | ||
complexity: ["warn", { max: 50 }], | ||
curly: ["error", "multi-line"], | ||
"no-console": "warn", | ||
"prettier/prettier": [ | ||
"error", | ||
{ | ||
"endOfLine": "auto", | ||
"arrowParens": "avoid", | ||
"printWidth": 100, | ||
"tabWidth": 2, | ||
"trailingComma": "es5", | ||
"quoteProps": "preserve", | ||
}, | ||
], | ||
}, | ||
ignorePatterns: ["node_modules", "utils/boot.jsm"], | ||
// Ignore eslint configurations in parent directories. | ||
root: true, | ||
// New rules and configurations should generally be added in | ||
// tools/lint/eslint/eslint-plugin-mozilla/lib/configs/recommended.js to | ||
// allow external repositories that use the plugin to pick them up as well. | ||
extends: ["plugin:mozilla/recommended"], | ||
plugins: ["mozilla", "import"], | ||
overrides: [ | ||
{ | ||
files: ["*@aminomancer/**", "extensions/**"], | ||
env: { webextensions: true }, | ||
}, | ||
{ | ||
// All .eslintrc.js files are in the node environment, so turn that | ||
// on here. | ||
// https://github.com/eslint/eslint/issues/13008 | ||
files: [".eslintrc.js"], | ||
env: { | ||
node: true, | ||
browser: false, | ||
}, | ||
}, | ||
{ | ||
files: ["*.mjs"], | ||
rules: { | ||
"import/default": "error", | ||
"import/export": "error", | ||
"import/named": "error", | ||
"import/namespace": "error", | ||
"import/newline-after-import": "error", | ||
"import/no-anonymous-default-export": "error", | ||
"import/no-duplicates": "error", | ||
"import/no-absolute-path": "error", | ||
"import/no-named-default": "error", | ||
"import/no-named-as-default": "error", | ||
"import/no-named-as-default-member": "error", | ||
"import/no-self-import": "error", | ||
"import/no-unassigned-import": "error", | ||
"import/no-unresolved": [ | ||
"error", | ||
// Bug 1773473 - Ignore resolver URLs for chrome and resource as we | ||
// do not yet have a resolver for them. | ||
{ ignore: ["chrome://", "resource://"] }, | ||
], | ||
"import/no-useless-path-segments": "error", | ||
}, | ||
}, | ||
{ | ||
files: ["*.html", "*.xhtml", "*.xml"], | ||
rules: { | ||
// Curly brackets are required for all the tree via recommended.js, | ||
// however these files aren't auto-fixable at the moment. | ||
curly: "off", | ||
}, | ||
}, | ||
], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
*.psd | ||
*.prproj | ||
custom-*.css | ||
boot.jsm | ||
resources/in-content/custom-content.css | ||
node_modules | ||
package-lock.json | ||
package.json | ||
*.psd | ||
*.prproj | ||
custom-*.css | ||
node_modules/ | ||
package-lock.json | ||
boot.jsm | ||
resources/in-content/custom-content.css |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
module.exports = { | ||
env: { | ||
node: false, | ||
browser: true, | ||
es2021: true, | ||
"mozilla/browser-window": true, | ||
"mozilla/jsm": true, | ||
// "mozilla/chrome-worker": true, | ||
// "mozilla/frame-script": true, | ||
// "mozilla/privileged": true, | ||
// "mozilla/simpletest": true, | ||
// "mozilla/sjs": true, | ||
// "mozilla/xpcshell": true, | ||
}, | ||
parserOptions: { | ||
sourceType: "script", | ||
ecmaVersion: "latest", | ||
}, | ||
overrides: [ | ||
{ | ||
files: [".eslintrc.js"], | ||
env: { | ||
node: true, | ||
browser: false, | ||
}, | ||
}, | ||
], | ||
globals: { | ||
_ucUtils: "writable", | ||
windowUtils: "writable", | ||
tabPreviews: "writable", | ||
gUnifiedExtensions: "writable", | ||
UIState: "writable", | ||
FxAccounts: "writable", | ||
EnsureFxAccountsWebChannel: "writable", | ||
SyncedTabs: "writable", | ||
MIN_STATUS_ANIMATION_DURATION: "writable", | ||
SyncedTabsPanelList: "writable", | ||
SyncedTabsDeckComponent: "writable", | ||
syncedTabsDeckComponent: "writable", | ||
}, | ||
rules: { | ||
"no-eval": "off", | ||
"mozilla/valid-lazy": "off", | ||
"no-unused-vars": "off", | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.