-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ce33b10
commit f3af8e0
Showing
1 changed file
with
46 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,52 @@ | ||
import { useMemo } from 'react'; | ||
import Link from './link'; | ||
import Header from './header'; | ||
import UptimeRobot from './uptimerobot'; | ||
import Package from '../../package.json'; | ||
import { useMemo } from "react"; | ||
import Link from "./link"; | ||
import Header from "./header"; | ||
import UptimeRobot from "./uptimerobot"; | ||
import Package from "../../package.json"; | ||
|
||
function App() { | ||
const apikeys = useMemo(() => { | ||
const { ApiKeys } = window.Config; | ||
if (Array.isArray(ApiKeys)) return ApiKeys; | ||
if (typeof ApiKeys === "string") return [ApiKeys]; | ||
return []; | ||
}, []); | ||
|
||
const apikeys = useMemo(() => { | ||
const { ApiKeys } = window.Config; | ||
if (Array.isArray(ApiKeys)) return ApiKeys; | ||
if (typeof ApiKeys === 'string') return [ApiKeys]; | ||
return []; | ||
}, []); | ||
|
||
return ( | ||
<> | ||
<Header /> | ||
<div className='container'> | ||
<div id='uptime'> | ||
{apikeys.map((key) => ( | ||
<UptimeRobot key={key} apikey={key} /> | ||
))} | ||
</div> | ||
<div id='footer'> | ||
<p>基于 <Link to='https://uptimerobot.com/' text='UptimeRobot' /> 接口 | 检测频率 5 分钟</p> | ||
<p>Copyright © 2020 - 2022 <Link to='https://www.imsyy.top/' text='無名' /> | Powered by <Link to='https://github.com/yb/uptime-status' text='uptime-status' /> {Package.version}</p> | ||
</div> | ||
</div> | ||
</> | ||
); | ||
return ( | ||
<> | ||
<Header /> | ||
<div className="container"> | ||
<div id="uptime"> | ||
{apikeys.map((key) => ( | ||
<UptimeRobot key={key} apikey={key} /> | ||
))} | ||
</div> | ||
<div id="footer"> | ||
<p> | ||
基于 | ||
<Link | ||
to="https://uptimerobot.com/" | ||
text="UptimeRobot" | ||
/> | ||
接口 | 检测频率 5 分钟 | ||
</p> | ||
<p> | ||
Copyright © 2020 - 2022 | ||
<Link | ||
to="https://collect-diamond.top/" | ||
text="Collect_diamond" | ||
/> | ||
| Powered by | ||
<Link | ||
to="https://github.com/yb/uptime-status" | ||
text="uptime-status" | ||
/> | ||
{Package.version} | ||
</p> | ||
</div> | ||
</div> | ||
</> | ||
); | ||
} | ||
|
||
export default App; |
f3af8e0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
status-cd – ./
status-cd-collect-diamond.vercel.app
status.collect-diamond.top
status-cd-git-main-collect-diamond.vercel.app
status-cd.vercel.app