misc: run prettier

This commit is contained in:
lyc8503 committed 2025-04-19 21:50:43 +08:00
1 parent 751373d5dd
commit 4bcf4173ea
22 files changed
+402 -302

No files matched your search

+12 -11
View File
@@ -22,21 +22,17 @@ export default function Home({
tooltip?: string
statusPageLink?: string
}) {
let state;
let state
if (stateStr !== undefined) {
state = JSON.parse(stateStr) as MonitorState
}
// Specify monitorId in URL hash to view a specific monitor (can be used in iframe)
const monitorId = window.location.hash.substring(1);
const monitorId = window.location.hash.substring(1)
if (monitorId) {
const monitor = monitors.find((monitor) => monitor.id === monitorId);
const monitor = monitors.find((monitor) => monitor.id === monitorId)
if (!monitor || !state) {
return (
<Text fw={700}>
Monitor with id {monitorId} not found!
</Text>
)
return <Text fw={700}>Monitor with id {monitorId} not found!</Text>
}
return (
<div style={{ maxWidth: '810px' }}>
@@ -70,9 +66,14 @@ export default function Home({
)}
<Divider mt="lg" />
<Text size="xs" mt="xs" mb="xs" style={{
textAlign: 'center'
}}>
<Text
size="xs"
mt="xs"
mb="xs"
style={{
textAlign: 'center',
}}
>
Open-source monitoring and status page powered by{' '}
<a href="https://github.com/lyc8503/UptimeFlare" target="_blank">
Uptimeflare