mirror of
https://github.com/antebudimir/feishin.git
synced 2025-12-31 10:03:33 +00:00
hide mediasession setting on desktop non-windows
This commit is contained in:
parent
1081829aa4
commit
40e7eda882
1 changed files with 5 additions and 0 deletions
|
|
@ -1,3 +1,4 @@
|
|||
import isElectron from 'is-electron';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import {
|
||||
|
|
@ -7,6 +8,9 @@ import {
|
|||
import { usePlaybackSettings, useSettingsStoreActions } from '/@/renderer/store/settings.store';
|
||||
import { Switch } from '/@/shared/components/switch/switch';
|
||||
|
||||
const isWindows = window.api.utils.isWindows();
|
||||
const isDesktop = isElectron();
|
||||
|
||||
export const MediaSessionSettings = () => {
|
||||
const { t } = useTranslation();
|
||||
const { mediaSession } = usePlaybackSettings();
|
||||
|
|
@ -31,6 +35,7 @@ export const MediaSessionSettings = () => {
|
|||
context: 'description',
|
||||
postProcess: 'sentenceCase',
|
||||
}),
|
||||
isHidden: isDesktop && !isWindows,
|
||||
note: t('common.restartRequired', { postProcess: 'sentenceCase' }),
|
||||
title: t('setting.mediaSession', { postProcess: 'sentenceCase' }),
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue