diff --git a/src/App.tsx b/src/App.tsx index 25f6058..5771624 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -1,13 +1,14 @@ import React from 'react'; import './App.css'; import {Layout, Row} from 'antd'; +import {Controller} from "./components/Controller"; function App() { return (
- Hello WOrld First + PROXY diff --git a/src/components/Controller.jsx b/src/components/Controller.jsx deleted file mode 100644 index 8ea4634..0000000 --- a/src/components/Controller.jsx +++ /dev/null @@ -1,10 +0,0 @@ -import React, {useState} from "react"; - -export const Controller = (props) => { - const [connected, setConnected] = useState(false); - return ( -
- -
- ) -} \ No newline at end of file diff --git a/src/components/Controller.tsx b/src/components/Controller.tsx new file mode 100644 index 0000000..46ba233 --- /dev/null +++ b/src/components/Controller.tsx @@ -0,0 +1,29 @@ +import React, {useEffect} from "react"; +import {Card} from "antd"; + +export interface ControllerProp { + +} + +export const Controller: React.FC = (props) => { + const [connected, setConnected] = React.useState(false) + const ref = React.useRef(null) + + useEffect(() => { + if (!ref) { + return + } + + // const update = () => { + // ref.current.click() + // } + // const id = setInterval(update, 10000) + // return () => { + // clearInterval(id) + // } + }, [ref]) + + return + Yakit 启动 + +}; \ No newline at end of file