mirror of
https://github.com/chylex/Firefox-SCsCC.git
synced 2025-05-11 06:34:03 +02:00
upgrade packages
This commit is contained in:
parent
058f549afd
commit
e22814bf28
9219
package-lock.json
generated
9219
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
26
package.json
26
package.json
@ -19,19 +19,19 @@
|
||||
"build": "npm-run-all clean build:webpack build:web-ext"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.8.0",
|
||||
"@babel/preset-env": "^7.8.0",
|
||||
"babel-loader": "^8.0.6",
|
||||
"copy-webpack-plugin": "^5.1.1",
|
||||
"cross-env": "^6.0.3",
|
||||
"eslint": "^6.8.0",
|
||||
"eslint-config-airbnb-base": "^14.0.0",
|
||||
"eslint-plugin-import": "^2.20.0",
|
||||
"@babel/core": "^7.12.3",
|
||||
"@babel/preset-env": "^7.12.1",
|
||||
"babel-loader": "^8.2.1",
|
||||
"copy-webpack-plugin": "^6.3.1",
|
||||
"cross-env": "^7.0.2",
|
||||
"eslint": "^7.13.0",
|
||||
"eslint-config-airbnb-base": "^14.2.1",
|
||||
"eslint-plugin-import": "^2.22.1",
|
||||
"npm-run-all": "^4.1.5",
|
||||
"rimraf": "^3.0.0",
|
||||
"web-ext": "^4.0.0",
|
||||
"webpack": "^4.41.5",
|
||||
"webpack-cli": "^3.3.10",
|
||||
"xregexp": "^4.2.4"
|
||||
"rimraf": "^3.0.2",
|
||||
"web-ext": "^5.3.0",
|
||||
"webpack": "^5.4.0",
|
||||
"webpack-cli": "^4.2.0",
|
||||
"xregexp": "^4.4.0"
|
||||
}
|
||||
}
|
||||
|
@ -28,7 +28,6 @@ const onError = (error) => {
|
||||
console.error('SCsCC - error:', error.message);
|
||||
};
|
||||
|
||||
|
||||
const openTab = (path) => {
|
||||
const url = browser.runtime.getURL(path);
|
||||
const notFoundErr = 'no opened tab found';
|
||||
@ -61,7 +60,6 @@ window.openOptionsPage = () => browser.runtime.openOptionsPage()
|
||||
openOptionsTab();
|
||||
});
|
||||
|
||||
|
||||
// get storage
|
||||
browser.storage.local.get()
|
||||
.then((storage) => {
|
||||
@ -115,7 +113,6 @@ browser.storage.onChanged.addListener((changes) => {
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
const checkCurrRate = (currRate, fromCurr, toCurr) => {
|
||||
const reqKey = `${fromCurr}to${toCurr}`;
|
||||
|
||||
|
@ -37,7 +37,6 @@ const refresh = () => {
|
||||
if (!document.hidden) refreshPrices();
|
||||
};
|
||||
|
||||
|
||||
const onPreferencesChange = (newPrefs) => {
|
||||
if (paused) {
|
||||
lastChanges.preferences = [newPrefs];
|
||||
@ -71,7 +70,6 @@ const onCurrRatesChange = (newCurrRates, hasNew) => {
|
||||
};
|
||||
currRates.onChange(onCurrRatesChange);
|
||||
|
||||
|
||||
const pause = () => {
|
||||
if (paused) return;
|
||||
paused = true;
|
||||
|
@ -88,7 +88,6 @@ const checkSiblingMatches = (textNode, toCurr, { numPatt, symbPatts }) => {
|
||||
return matches;
|
||||
};
|
||||
|
||||
|
||||
// check if there is any pattern match in a text node and return the matches
|
||||
export default (textNodes, toCurr, patts) => {
|
||||
const priceMatches = [];
|
||||
|
@ -21,7 +21,6 @@ export const checkPriceSpecCases = (txt, match) => {
|
||||
return match;
|
||||
};
|
||||
|
||||
|
||||
export const cleanPrice = (price) => {
|
||||
// remove currency symbols and spaces
|
||||
let cleanedPrice = price.replace(cleanSymbPatt, '');
|
||||
@ -43,7 +42,6 @@ export const cleanPrice = (price) => {
|
||||
return cleanedPrice;
|
||||
};
|
||||
|
||||
|
||||
export const formatPrice = (price, preferences) => {
|
||||
// set rounding
|
||||
let formattedPrice = (preferences.round) ? price.toFixed(0) : price.toFixed(2);
|
||||
|
@ -2,7 +2,6 @@ import getOptionRowElem from './utils/getOptionRowElem';
|
||||
import getButtonRowElem from './utils/getButtonRowElem';
|
||||
import getChangedPrefs from './utils/getChangedPrefs';
|
||||
|
||||
|
||||
const onChange = ({ target }) => {
|
||||
const changedPrefs = getChangedPrefs(target);
|
||||
|
||||
|
@ -48,28 +48,23 @@ module.exports = {
|
||||
new webpack.DefinePlugin({
|
||||
UNICODE_ALPHABETIC: JSON.stringify(XRegExp._getUnicodeProperty('Alphabetic').bmp), // eslint-disable-line no-underscore-dangle
|
||||
}),
|
||||
new CopyWebpackPlugin([
|
||||
{
|
||||
from: 'manifest.json',
|
||||
},
|
||||
{
|
||||
from: 'icons',
|
||||
to: 'icons',
|
||||
},
|
||||
{
|
||||
from: '*/*.+(html|css)',
|
||||
},
|
||||
]),
|
||||
new CopyWebpackPlugin({
|
||||
patterns: [
|
||||
{
|
||||
from: 'manifest.json',
|
||||
},
|
||||
{
|
||||
from: 'icons',
|
||||
to: 'icons',
|
||||
},
|
||||
{
|
||||
from: '*/*.+(html|css)',
|
||||
},
|
||||
],
|
||||
}),
|
||||
],
|
||||
|
||||
optimization: {
|
||||
minimize: false,
|
||||
},
|
||||
|
||||
stats: {
|
||||
// Examine all modules
|
||||
maxModules: Infinity,
|
||||
// Display bailout reasons
|
||||
optimizationBailout: true,
|
||||
},
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user