@likable-hair/svelte 3.1.49 → 3.1.51
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/simple/charts/GanymedeBarChart.svelte +5 -3
- package/dist/components/simple/charts/GanymedeBarChart.svelte.d.ts +2 -0
- package/dist/components/simple/charts/GanymedeLineChart.svelte +11 -5
- package/dist/components/simple/charts/GanymedeLineChart.svelte.d.ts +6 -1
- package/package.json +1 -1
|
@@ -25,7 +25,7 @@ ChartJS.register(
|
|
|
25
25
|
export let data = {
|
|
26
26
|
labels: [],
|
|
27
27
|
datasets: []
|
|
28
|
-
}, horizontal = false, responsive = true, maintainAspectRatio = true, showLegend = true, showYTicks = false, showXTicks = false, displayYGrid = true, lineWidth = 1, enableZoom = true, resetZoom = false, tooltipLabel = void 0, yTickLabel = void 0, xTickLabel = void 0, xTickStepSize = void 0, yTickStepSize = void 0;
|
|
28
|
+
}, horizontal = false, responsive = true, maintainAspectRatio = true, showLegend = true, showYTicks = false, showXTicks = false, displayYGrid = true, lineWidth = 1, enableZoom = true, resetZoom = false, tooltipLabel = void 0, yTickLabel = void 0, xTickLabel = void 0, xTickStepSize = void 0, yTickStepSize = void 0, xMax = void 0, yMax = void 0;
|
|
29
29
|
let mounted = false, zoomMounted = false;
|
|
30
30
|
onMount(() => {
|
|
31
31
|
mounted = true;
|
|
@@ -108,6 +108,7 @@ $:
|
|
|
108
108
|
},
|
|
109
109
|
scales: {
|
|
110
110
|
x: {
|
|
111
|
+
max: xMax,
|
|
111
112
|
display: true,
|
|
112
113
|
title: {
|
|
113
114
|
display: true
|
|
@@ -119,12 +120,13 @@ $:
|
|
|
119
120
|
display: false
|
|
120
121
|
},
|
|
121
122
|
ticks: {
|
|
122
|
-
display:
|
|
123
|
+
display: showXTicks,
|
|
123
124
|
callback: xTickLabel,
|
|
124
125
|
stepSize: xTickStepSize
|
|
125
126
|
}
|
|
126
127
|
},
|
|
127
128
|
y: {
|
|
129
|
+
max: yMax,
|
|
128
130
|
display: displayYGrid,
|
|
129
131
|
title: {},
|
|
130
132
|
grid: {
|
|
@@ -136,7 +138,7 @@ $:
|
|
|
136
138
|
display: false
|
|
137
139
|
},
|
|
138
140
|
ticks: {
|
|
139
|
-
display:
|
|
141
|
+
display: showYTicks,
|
|
140
142
|
callback: yTickLabel,
|
|
141
143
|
stepSize: yTickStepSize
|
|
142
144
|
}
|
|
@@ -27,6 +27,8 @@ declare const __propDef: {
|
|
|
27
27
|
xTickLabel?: ((tickValue: string | number, index: number, ticks: any[]) => (string | number)) | undefined;
|
|
28
28
|
xTickStepSize?: number | undefined;
|
|
29
29
|
yTickStepSize?: number | undefined;
|
|
30
|
+
xMax?: number | undefined;
|
|
31
|
+
yMax?: number | undefined;
|
|
30
32
|
rgbTooltipColor?: string | undefined;
|
|
31
33
|
rgbTooltipBackgroundColor?: string | undefined;
|
|
32
34
|
rgbBackgroundColor?: string | undefined;
|
|
@@ -28,7 +28,7 @@ onMount(async () => {
|
|
|
28
28
|
export let data = {
|
|
29
29
|
labels: [],
|
|
30
30
|
datasets: []
|
|
31
|
-
}, horizontal = false, responsive = true, maintainAspectRatio = true, showLegend = true, showYTicks = false, showXTicks = false, displayYGrid = true, lineWidth = 1, enableZoom = false, resetZoom = false;
|
|
31
|
+
}, horizontal = false, responsive = true, maintainAspectRatio = true, showLegend = true, showYTicks = false, showXTicks = false, displayYGrid = true, lineWidth = 1, enableZoom = false, resetZoom = false, xTickStepSize = void 0, yTickStepSize = void 0, xMax = void 0, yMax = void 0;
|
|
32
32
|
$:
|
|
33
33
|
gridColor = "rgb(" + (background || "200, 200, 200") + ", .3)";
|
|
34
34
|
let chart;
|
|
@@ -73,6 +73,7 @@ $:
|
|
|
73
73
|
},
|
|
74
74
|
scales: {
|
|
75
75
|
x: {
|
|
76
|
+
max: xMax,
|
|
76
77
|
display: true,
|
|
77
78
|
title: {
|
|
78
79
|
display: true
|
|
@@ -84,10 +85,12 @@ $:
|
|
|
84
85
|
display: false
|
|
85
86
|
},
|
|
86
87
|
ticks: {
|
|
87
|
-
display: showYTicks
|
|
88
|
+
display: showYTicks,
|
|
89
|
+
stepSize: yTickStepSize
|
|
88
90
|
}
|
|
89
91
|
},
|
|
90
92
|
y: {
|
|
93
|
+
max: yMax,
|
|
91
94
|
display: displayYGrid,
|
|
92
95
|
title: {},
|
|
93
96
|
grid: {
|
|
@@ -99,16 +102,19 @@ $:
|
|
|
99
102
|
display: false
|
|
100
103
|
},
|
|
101
104
|
ticks: {
|
|
102
|
-
display: showXTicks
|
|
105
|
+
display: showXTicks,
|
|
106
|
+
stepSize: xTickStepSize
|
|
103
107
|
}
|
|
104
108
|
}
|
|
105
109
|
}
|
|
106
110
|
};
|
|
111
|
+
$:
|
|
112
|
+
realData = data;
|
|
107
113
|
</script>
|
|
108
114
|
|
|
109
115
|
{#if zoomMounted || !enableZoom}
|
|
110
|
-
<Line
|
|
111
|
-
bind:data={
|
|
116
|
+
<Line
|
|
117
|
+
bind:data={realData}
|
|
112
118
|
options={chartOptions}
|
|
113
119
|
bind:chart={chart}
|
|
114
120
|
></Line>
|
|
@@ -5,11 +5,12 @@ declare const __propDef: {
|
|
|
5
5
|
labels: string[];
|
|
6
6
|
datasets: {
|
|
7
7
|
label: string;
|
|
8
|
-
data: number[];
|
|
8
|
+
data: (number | null)[];
|
|
9
9
|
backgroundColor?: string | undefined;
|
|
10
10
|
borderColor?: string | undefined;
|
|
11
11
|
hoverBackgroundColor?: string[] | undefined;
|
|
12
12
|
tension?: number | undefined;
|
|
13
|
+
spanGaps?: boolean | number | undefined;
|
|
13
14
|
}[];
|
|
14
15
|
} | undefined;
|
|
15
16
|
horizontal?: boolean | undefined;
|
|
@@ -22,6 +23,10 @@ declare const __propDef: {
|
|
|
22
23
|
lineWidth?: number | undefined;
|
|
23
24
|
enableZoom?: boolean | undefined;
|
|
24
25
|
resetZoom?: boolean | undefined;
|
|
26
|
+
xTickStepSize?: number | undefined;
|
|
27
|
+
yTickStepSize?: number | undefined;
|
|
28
|
+
xMax?: number | undefined;
|
|
29
|
+
yMax?: number | undefined;
|
|
25
30
|
};
|
|
26
31
|
events: {
|
|
27
32
|
[evt: string]: CustomEvent<any>;
|