Add the status indicator for new versions

This commit is contained in:
ajnart
2022-12-20 15:21:36 +09:00
parent 11b111209a
commit 9996ff1529
4 changed files with 89 additions and 17 deletions

View File

@@ -5,7 +5,7 @@ import CustomizationSettings from './Customization/CustomizationSettings';
import CommonSettings from './Common/CommonSettings';
import Credits from './Common/Credits';
function SettingsMenu() {
function SettingsMenu({ newVersionAvailable }: { newVersionAvailable: string }) {
const { t } = useTranslation('settings/common');
return (
@@ -33,7 +33,11 @@ interface SettingsDrawerProps {
closeDrawer: () => void;
}
export function SettingsDrawer({ opened, closeDrawer }: SettingsDrawerProps) {
export function SettingsDrawer({
opened,
closeDrawer,
newVersionAvailable,
}: SettingsDrawerProps & { newVersionAvailable: string }) {
const { t } = useTranslation('settings/common');
return (
@@ -45,7 +49,7 @@ export function SettingsDrawer({ opened, closeDrawer }: SettingsDrawerProps) {
opened={opened}
onClose={closeDrawer}
>
<SettingsMenu />
<SettingsMenu newVersionAvailable={newVersionAvailable} />
<Credits />
</Drawer>
);