From 91afc54dab60311f511ede4ab35c9b409d870b43 Mon Sep 17 00:00:00 2001 From: pompurin404 Date: Tue, 22 Oct 2024 21:31:42 +0800 Subject: [PATCH] fix style --- src/renderer/src/App.tsx | 1 + .../src/components/updater/updater-button.tsx | 43 ++++++++++++++----- 2 files changed, 33 insertions(+), 11 deletions(-) diff --git a/src/renderer/src/App.tsx b/src/renderer/src/App.tsx index 4a45e3b7..fcb1c03d 100644 --- a/src/renderer/src/App.tsx +++ b/src/renderer/src/App.tsx @@ -200,6 +200,7 @@ const App: React.FC = () => { {platform !== 'darwin' && ( )} +
diff --git a/src/renderer/src/components/updater/updater-button.tsx b/src/renderer/src/components/updater/updater-button.tsx index 104feaf9..d3da9e06 100644 --- a/src/renderer/src/components/updater/updater-button.tsx +++ b/src/renderer/src/components/updater/updater-button.tsx @@ -5,9 +5,15 @@ import React, { useState } from 'react' import useSWR from 'swr' import UpdaterModal from './updater-modal' import { platform } from '@renderer/utils/init' +import { MdNewReleases } from 'react-icons/md' -const UpdaterButton: React.FC = () => { +interface Props { + iconOnly?: boolean +} + +const UpdaterButton: React.FC = (props) => { const { appConfig } = useAppConfig() + const { iconOnly } = props const { autoCheckUpdate, useWindowFrame = false } = appConfig || {} const [openModal, setOpenModal] = useState(false) const { data: latest } = useSWR( @@ -30,16 +36,31 @@ const UpdaterButton: React.FC = () => { }} /> )} - + {iconOnly ? ( + + ) : ( + + )} ) }