Compare commits

..

2 Commits

3 changed files with 7 additions and 15 deletions

View File

@ -112,7 +112,7 @@ const UpdateStage = ({ stage, status, percent, detail }) => {
const resolvedStatus =
status !== 'error' && resolvedPercent === 100 ? 'complete' : status
const color = getStageColor(resolvedStatus, token)
const showProgress = resolvedStatus === 'active'
const showProgress = resolvedStatus === 'active' && stage !== 'restart'
const StatusIcon =
resolvedStatus === 'complete'
@ -179,8 +179,6 @@ const AppUpdateProgress = ({ progress, update, onClose }) => {
const installDetail = installStatus === 'active' ? message : null
const restartDetail = restartStatus === 'active' ? message : null
return (
<Flex vertical gap='middle'>
<Text>
@ -203,11 +201,7 @@ const AppUpdateProgress = ({ progress, update, onClose }) => {
percent={installPercent}
detail={installDetail}
/>
<UpdateStage
stage='restart'
status={restartStatus}
detail={restartDetail}
/>
<UpdateStage stage='restart' status={restartStatus} />
</Flex>
<Modal

View File

@ -225,7 +225,7 @@ const DashboardNavigation = () => {
align='center'
style={{ marginTop: '-2px', marginRight: '6px' }}
>
<Space>
<Space style={{ paddingTop: '2px' }}>
<WebAppSwitcher />
<KeyboardShortcut
shortcut='alt+q'

View File

@ -1,10 +1,11 @@
import { useContext } from 'react'
import { useLocation, useNavigate } from 'react-router-dom'
import { Button, Tooltip } from 'antd'
import { Button } from 'antd'
import { ElectronContext } from '../context/ElectronContext'
import OpenInAppIcon from '../../Icons/OpenInAppIcon'
import OpenInBrowserIcon from '../../Icons/OpenInBrowserIcon'
import config from '../../../config'
import KeyboardShortcut from './KeyboardShortcut'
const WebAppSwitcher = () => {
const { isElectron, openExternalUrl } = useContext(ElectronContext)
@ -42,17 +43,14 @@ const WebAppSwitcher = () => {
}
return (
<Tooltip
title={isElectron ? 'Open in browser' : 'Open in app'}
arrow={false}
>
<KeyboardShortcut shortcut='alt+w' hint='ALT W' onTrigger={handleClick}>
<Button
icon={isElectron ? <OpenInBrowserIcon /> : <OpenInAppIcon />}
type='text'
style={{ marginTop: '4px' }}
onClick={handleClick}
/>
</Tooltip>
</KeyboardShortcut>
)
}