diff --git a/.eslintrc b/.eslintrc new file mode 100644 index 0000000..03d973a --- /dev/null +++ b/.eslintrc @@ -0,0 +1,45 @@ +{ + "rules": { + "indent": [2, 4], + "quotes": [2, "single"], + "linebreak-style": [2, "unix"], + "semi": [2, "always"], + "brace-style": 2, + "camelcase": [2, { "properties": "always" }], + "no-var": 2, + "no-const-assign": 2, + "arrow-parens": [2, "always"], + "arrow-spacing": 2, + "space-before-function-paren": [2, "never"], + "no-spaced-func": 2, + "prefer-template": 2, + "prefer-const": 1, + "no-this-before-super": 2, + "comma-spacing": [2, { "before": false, "after": true }], + "comma-dangle": [1, "always-multiline"], + "no-dupe-keys": 2, + "no-debugger": 2, + "no-unreachable": 2, + "valid-jsdoc": 2, + "require-jsdoc": 1, + "space-before-blocks": 2, + "space-infix-ops": 2, + "keyword-spacing": 2, + "no-trailing-spaces": 2, + "max-len": [2, 80, 4, { "ignoreUrls": true, "ignorePattern": "^\\s*const\\s.+=\\s*require\\s*\\(" }], + "guard-for-in": 2, + "no-alert": 2, + "no-throw-literal": 2, + "object-curly-spacing": [2, "never"], + "no-array-constructor": 2, + "no-new-object": 2, + "no-console": 2, + "one-var": [2, "never"] + }, + "env": { + "es6": true, + "node": true + }, + "extends": "eslint:recommended", + "root": true +} diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1f033ba --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +package-lock.json +node_modules +KhanAcademyLibs/math-translator.js diff --git a/options.html b/options.html index 5fc7662..b5f0970 100644 --- a/options.html +++ b/options.html @@ -81,6 +81,8 @@

Please select your language

  • Thousand separator
  • Multiplication
  • Division
  • +
  • Trigonometry functions
  • +
  • Coordinates and intervals
  • diff --git a/package.json b/package.json new file mode 100644 index 0000000..3762262 --- /dev/null +++ b/package.json @@ -0,0 +1,26 @@ +{ + "name": "khan-academy-dots", + "description": "Translate math notation in Khan Academy Crowdin strings.", + "author": "Daniel Hollas & Szymon Bubak & Krzysztof Krystek & Robert Pala", + "version": "3.3.0", + "main": "app.js", + "scripts": { + "lint": "eslint *.js" + }, + "repository": { + "type": "git", + "url": "https://github.com:szmeku/KhanAcademyDots" + }, + "license": "MIT", + "bugs": { + "url": "https://github.com/szmeku/KhanAcademyDots/issues" + }, + "homepage": "https://github.com/szmeku/KhanAcademyDots", + "devDependencies": { + "eslint": "^7.10.0", + "pre-commit": "^1.2.2" + }, + "pre-commit": [ + "lint" + ] +}