aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/TitleBar
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/TitleBar')
-rw-r--r--src/components/TitleBar/TitleBar.tsx26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/components/TitleBar/TitleBar.tsx b/src/components/TitleBar/TitleBar.tsx
new file mode 100644
index 0000000..85fbfbd
--- /dev/null
+++ b/src/components/TitleBar/TitleBar.tsx
@@ -0,0 +1,26 @@
+import React from 'react';
+
+interface TitleBarProps {
+ title: string;
+ redirectUrl?: string;
+ showHomeButton?: boolean;
+}
+
+const TitleBar: React.FC<TitleBarProps> = ({ title, redirectUrl, showHomeButton }) => {
+ return (
+ <div className="title-bar p-5 shadow-md" style={{ backgroundColor: '#2D4B71' }}>
+ <div style={{ display: 'flex', justifyContent: 'space-between', alignItems: 'center' }}>
+ <a href={redirectUrl}>
+ <span className="text-white text-4xl font-bold">{title}</span>
+ </a>
+ {showHomeButton && (
+ <a href="/">
+ <button className="bg-white text-blue-500 hover:bg-blue-500 hover:text-white font-bold py-2 px-4 rounded-full">Home</button>
+ </a>
+ )}
+ </div>
+ </div>
+ );
+};
+
+export default TitleBar; \ No newline at end of file
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage