Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:datavisyn/lineupjs into develop
Browse files Browse the repository at this point in the history
# Conflicts:
#	src/model/CategoricalColumn.ts
#	src/model/ICategoricalColumn.ts
#	src/model/StringColumn.ts
  • Loading branch information
sgratzl committed Oct 30, 2018
2 parents e9e2a84 + 675a074 commit 6c585c8
Show file tree
Hide file tree
Showing 81 changed files with 2,875 additions and 2,428 deletions.
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,5 @@
"typescript.format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces": false,
"tsimporter.spaceBetweenBraces": false,
"tsimporter.noStatusBar": true,
"typescriptHero.codeOutline.enabled": false
"typescript.tsdk": "node_modules\\typescript\\lib"
}
2 changes: 1 addition & 1 deletion demo/builder2.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
// manually define columns
builder
.sidePanel(true, true)
.column(LineUpJS.buildStringColumn('d').label('Label').width(100))
.column(LineUpJS.buildStringColumn('d').label('Label').alignment('right').width(100))
.column(LineUpJS.buildCategoricalColumn('cat', cats).color('green'))
.column(LineUpJS.buildCategoricalColumn('cat2', cats).color('blue'))
.column(LineUpJS.buildNumberColumn('a', [0, 10]).color('blue'));
Expand Down
47 changes: 47 additions & 0 deletions demo/builder4.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<title>LineUp Builder Test</title>

<link href="./LineUpJS.css" rel="stylesheet">
<link href="./demo.css" rel="stylesheet">
</head>
<body>
<script src="./LineUpJS.js"></script>
<script src="./helper/testRules.js"></script>

<script>
window.onload = function () {
const arr = [];
const l = new Array(10).fill(0);
const cats = ['c1', 'c2', 'c3'];
for (let i = 0; i < 100; ++i) {
arr.push({
a: Math.random() * 10,
d: 'Row ' + i,
cat: cats[Math.floor(Math.random() * 3)],
cat2: cats[Math.floor(Math.random() * 3)],
as: l.map(() => Math.random() * 10)
})
}
const builder = LineUpJS.builder(arr);
builder.deriveColumns().animated(false);
// and two rankings
const ranking = LineUpJS.buildRanking()
.supportTypes()
.allColumns() // add all columns
.groupBy('cat')
.sortBy('a', 'desc')
.sortBy('d', 'asc')

builder
.ranking(ranking);


builder.buildTaggle(document.body);
};
</script>

</body>
</html>
36 changes: 36 additions & 0 deletions demo/link.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<title>LineUp Builder Test</title>

<link href="./LineUpJS.css" rel="stylesheet">
<link href="./demo.css" rel="stylesheet">
</head>
<body>
<script src="./LineUpJS.js"></script>

<script>
window.onload = function () {
const arr = [];
const cats = ['c1', 'c2', 'c3'];
const template = new Array(10).fill(0);
for (let i = 0; i < 100; ++i) {
arr.push({
a: Math.random() * 10,
d: 'Row ' + i,
cat: cats[Math.floor(Math.random() * 3)],
cat2: cats[Math.floor(Math.random() * 3)],
as: template.map((d) => Math.random() * 10)
})
}
const builder = LineUpJS.builder(arr);
builder.deriveColumns();
builder.column(LineUpJS.buildStringColumn('d').label('Link').pattern('https://duckduckgo.com/?q=${escapedValue}').width(100));

builder.buildTaggle(document.body);
};
</script>

</body>
</html>
6 changes: 3 additions & 3 deletions jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ module.exports = {
verbose: true,
globals: {
'ts-jest': {
tsConfigFile: 'tsconfig.test.json',
enableTsDiagnostics: true,
skipBabel: true
tsConfig: 'tsconfig.test.json',
diagnostics: true,
babelConfig: false
}
}
};
Loading

0 comments on commit 6c585c8

Please sign in to comment.