fix: Typisierung von timeUnit für Chart.js X-Achse korrigiert ('hour' | 'day')
This commit is contained in:
@@ -77,7 +77,7 @@ const LoopMeasurementChart = () => {
|
||||
const from = vonDatum ? parseISO(vonDatum) : null;
|
||||
const to = bisDatum ? parseISO(bisDatum) : null;
|
||||
const durationInHours = from && to ? differenceInHours(to, from) : 9999;
|
||||
const timeUnit = durationInHours <= 48 ? "hour" : "day";
|
||||
const timeUnit: "hour" | "day" = durationInHours <= 48 ? "hour" : "day";
|
||||
|
||||
useEffect(() => {
|
||||
import("chartjs-plugin-zoom").then((zoomPlugin) => {
|
||||
@@ -173,7 +173,7 @@ const LoopMeasurementChart = () => {
|
||||
x: {
|
||||
type: "time" as const,
|
||||
time: {
|
||||
unit: timeUnit as const,
|
||||
unit: timeUnit,
|
||||
tooltipFormat: "dd.MM.yyyy HH:mm:ss",
|
||||
displayFormats: {
|
||||
hour: "HH:mm",
|
||||
|
||||
@@ -6,5 +6,5 @@
|
||||
2: Patch oder Hotfix (Bugfixes oder kleine Änderungen).
|
||||
|
||||
*/
|
||||
const webVersion = "1.6.393";
|
||||
const webVersion = "1.6.394";
|
||||
export default webVersion;
|
||||
|
||||
Reference in New Issue
Block a user