feat: UI
This commit is contained in:
parent
7380574143
commit
7d7c89954b
|
@ -27,6 +27,7 @@ import {
|
||||||
|
|
||||||
import Download from './Download'
|
import Download from './Download'
|
||||||
import { Separator } from '@/components/ui/separator'
|
import { Separator } from '@/components/ui/separator'
|
||||||
|
import { Loader2 } from 'lucide-react'
|
||||||
|
|
||||||
const Panel: React.FC = () => {
|
const Panel: React.FC = () => {
|
||||||
const [macInputDisabled, setMacInputDisabled] = useState(false)
|
const [macInputDisabled, setMacInputDisabled] = useState(false)
|
||||||
|
@ -67,7 +68,7 @@ const Panel: React.FC = () => {
|
||||||
GetLatestVersion().then(res => {
|
GetLatestVersion().then(res => {
|
||||||
if (res === null) {
|
if (res === null) {
|
||||||
toast('Get database failed.', {
|
toast('Get database failed.', {
|
||||||
description: '⛓️💥 Please check your internet connection.'
|
description: '⛓️💥 Please check your internet connection.',
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
setNewVersion(res)
|
setNewVersion(res)
|
||||||
|
@ -186,6 +187,7 @@ const Panel: React.FC = () => {
|
||||||
onClick={handleCheck}
|
onClick={handleCheck}
|
||||||
disabled={checkDisabled}
|
disabled={checkDisabled}
|
||||||
>
|
>
|
||||||
|
{checkDisabled ?? <Loader2 className="mr-2 h-4 w-4 animate-spin" />}
|
||||||
Check
|
Check
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in New Issue