diff --git a/.gitignore b/.gitignore index 0d065668..f5943cce 100644 --- a/.gitignore +++ b/.gitignore @@ -48,3 +48,4 @@ next-env.d.ts *.njsproj *.sln *.sw? +*_copy* \ No newline at end of file diff --git a/app/components/home/header/index.tsx b/app/components/home/header/index.tsx index 86eb5ac4..b9947189 100644 --- a/app/components/home/header/index.tsx +++ b/app/components/home/header/index.tsx @@ -11,9 +11,11 @@ import HomeMonitorHeaderMenu from './menu'; import useContextStore from '../../../context'; import Role from '../../../../shared/permissions/role'; import { PermissionsBits } from '../../../../shared/permissions/bitFlags'; +import type { MonitorType } from '../../../types/monitor'; const typeToText = { docker: 'Docker Container', + email: 'Email (SMTP)', http: 'HTTP/S', json: 'JSON Query', ping: 'Ping', @@ -28,6 +30,31 @@ interface HomeMonitorHeaderProps { isMobile?: boolean; } +const HeaderSubtitle = ({ type, url }: { type: MonitorType; url: string }) => { + const { t } = useTranslation(); + + if (!type || !url) return null; + + if (type === 'push') { + return ( +
|
+ |
+
|---|
+ + 🚨 Service Currently Unreachable +++ Our monitoring system has detected that{' '} + {serviceName} is + currently{' '} + down/unreachable. + + ++ Detected at: {timestamp} + + + + ++ You’ll be notified again when the service is back online. + + |
+
| + + Lunalytics + {' '} + - Made with ❤️ by KSJaay + | +
|
+ |
+
|---|
+ + 🚨 Service Currently Unreachable +++ Our monitoring system has detected that{' '} + {serviceName} is + currently{' '} + down/unreachable. + + ++ 📊 Monitor Information ++ +
+
+
+
+
+
+ ID:
+ {id}
+
+
+
+ Name:
+ {serviceName}
+
+
+
+ Address:
+ {address}
+
+
+
+ Type:
+ {type}
+
+
+
+
+ + 🌍 Status Breakdown ++
+
+
+
+
+
+
+
+ Status:
+ {status}
+
+
+
+ Latency:
+ {latency} ms
+
+
+
+ Message:
+ {statusMessage}
+
+
+
+ Timestamp:
+ {timestamp}
+
+
+
+
+ + You can manage notification preferences or review uptime logs in + your dashboard. + + |
+
| + + Lunalytics + {' '} + - Made with ❤️ by KSJaay + | +
|
+ |
+
|---|
+ + 🚨 Service Currently Unreachable +++ Our monitoring system has detected that{' '} + {serviceName} is + currently{' '} + down/unreachable. + + ++ Detected at {timestamp} + + ++ 📊 Monitor Information ++ +
+
+
+
+
+
+ Name:
+ {serviceName}
+
+
+ Latency:
+ {latency}ms
+
+
+ Status:
+ {status}
+
+
+ Message:
+ {message}
+
+
+ Timestamp:
+ {timestamp}
+ |
+
| + + Lunalytics + {' '} + - Made with ❤️ by KSJaay + | +
|
+ |
+
|---|
+ + ✅ Your monitored service is back online ++ ++ Lunalytics detected that{' '} + {serviceName} has + successfully recovered and is now{' '} + operational. + + ++ Resolved at: {timestamp} + + +
+
+
+
+
+ + Monitoring will continue to ensure your service remains + stable. You’ll be alerted again if any further issues occur. + ++ You can manage notification preferences or review uptime logs in + your dashboard. + + |
+
| + + Lunalytics + {' '} + - Made with ❤️ by KSJaay + | +