Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
33 changes: 33 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"nyc": {
"all": true,
"include": [
"src/core/*.js"
"src/core/*.js",
"src/locale/locale.js"
],
"exclude": [
"**/*.spec.js"
Expand All @@ -29,7 +30,7 @@
"build": "webpack --config build/webpack.prod.js",
"build-locale": "webpack --config build/webpack.locale.js",
"lint": "./node_modules/eslint/bin/eslint.js src",
"test": "nyc ./node_modules/mocha/bin/mocha --require @babel/register test/*",
"test": "nyc ./node_modules/mocha/bin/mocha --require @babel/register --recursive test",
"coverage": "nyc report --reporter=text-lcov > coverage.lcov && codecov -t 31ecdb12-8ecb-46f7-a486-65c2516307dd",
"postinstall": "opencollective-postinstall"
},
Expand Down Expand Up @@ -64,6 +65,7 @@
"webpack-merge": "^4.1.4"
},
"dependencies": {
"hot-formula-parser": "^3.0.2",
"opencollective": "^1.0.3",
"opencollective-postinstall": "^2.0.2"
},
Expand Down
39 changes: 0 additions & 39 deletions src/algorithm/expression.js

This file was deleted.

7 changes: 4 additions & 3 deletions src/component/dropdown_formula.js
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
import Dropdown from './dropdown';
import Icon from './icon';
import { h } from './element';
import { baseFormulas } from '../core/formula';
import { cssPrefix } from '../config';

import { SUPPORTED_FORMULAS } from 'hot-formula-parser';

export default class DropdownFormula extends Dropdown {
constructor() {
const nformulas = baseFormulas.map(it => h('div', `${cssPrefix}-item`)
const nformulas = SUPPORTED_FORMULAS.map(it => h('div', `${cssPrefix}-item`)
.on('click', () => {
this.hide();
this.change(it);
})
.child(it.key));
.child(it));
super(new Icon('formula'), '180px', true, 'bottom-left', ...nformulas);
}
}
Loading