about summary refs log tree commit diff
diff options
context:
space:
mode:
authorBaitinq <manuelpalenzuelamerino@gmail.com>2024-07-02 12:00:41 +0200
committerBaitinq <manuelpalenzuelamerino@gmail.com>2024-07-02 12:00:41 +0200
commit6082814fd0484f9afd8187f7e88f9365548813af (patch)
tree17acc8f66b822b91f6f72dae37c00450cec2bee0
parentHome: Start styling layout (diff)
downloadfs-tracer-frontend-6082814fd0484f9afd8187f7e88f9365548813af.tar.gz
fs-tracer-frontend-6082814fd0484f9afd8187f7e88f9365548813af.tar.bz2
fs-tracer-frontend-6082814fd0484f9afd8187f7e88f9365548813af.zip
LineGraph: Write title without plugins
-rw-r--r--src/components/Graphs/LineGraph.tsx13
1 files changed, 4 insertions, 9 deletions
diff --git a/src/components/Graphs/LineGraph.tsx b/src/components/Graphs/LineGraph.tsx
index 4cbea05..f16cc40 100644
--- a/src/components/Graphs/LineGraph.tsx
+++ b/src/components/Graphs/LineGraph.tsx
@@ -4,7 +4,6 @@ import {
 	LinearScale,
 	PointElement,
 	LineElement,
-	Title,
 	Tooltip,
 } from 'chart.js';
 import { Line } from 'react-chartjs-2';
@@ -14,19 +13,12 @@ ChartJS.register(
 	LinearScale,
 	PointElement,
 	LineElement,
-	Title,
 	Tooltip
 );
 
 export default function LineGraph() {
 	const options = {
 		responsive: true,
-		plugins: {
-			title: {
-				display: true,
-				text: 'File writes per second',
-			},
-		},
 		scales: {
 			x: {
 				grid: {
@@ -67,6 +59,9 @@ export default function LineGraph() {
 	};
 
 	return (
-		<Line data={data} options={options} />
+		<div>
+			<p className="text-center">File writes per second</p>
+			<Line data={data} options={options} />
+		</div>
 	)
 }