Added support for maxTimeDelta and dateFormat
This commit is contained in:
14
test.html
14
test.html
@@ -16,8 +16,18 @@
|
||||
import { createChartElement } from './dist/uchart.js';
|
||||
|
||||
const container = document.getElementById('chartContainer');
|
||||
const chart = createChartElement([], { showYAxis:true, yTicks:5 });
|
||||
container.appendChild(chart.element);
|
||||
const chart = createChartElement([], {
|
||||
showYAxis: true,
|
||||
yTicks: 5,
|
||||
dateFormat: (ts) => new Date(ts).toLocaleString('cs-CZ', {
|
||||
hour: '2-digit',
|
||||
minute: '2-digit',
|
||||
second: '2-digit',
|
||||
day: '2-digit',
|
||||
month: '2-digit',
|
||||
year: 'numeric'
|
||||
})
|
||||
}); container.appendChild(chart.element);
|
||||
|
||||
let phase = 0;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user