fix: dark mode toggling
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { WebApplication } from '@/Application/Application'
|
||||
import { FeatureIdentifier, FeatureStatus, PrefKey } from '@standardnotes/snjs'
|
||||
import { FeatureIdentifier, FeatureStatus } from '@standardnotes/snjs'
|
||||
import { FunctionComponent, MouseEventHandler, useCallback, useMemo } from 'react'
|
||||
import Icon from '@/Components/Icon/Icon'
|
||||
import { usePremiumModal } from '@/Hooks/usePremiumModal'
|
||||
@@ -37,10 +37,6 @@ const ThemesMenuButton: FunctionComponent<Props> = ({ application, item }) => {
|
||||
|
||||
if (themeIsLayerableOrNotActive) {
|
||||
application.mutator.toggleTheme(item.component).catch(console.error)
|
||||
|
||||
if (!isThemeLayerable) {
|
||||
application.setPreference(PrefKey.DarkMode, false)
|
||||
}
|
||||
}
|
||||
} else {
|
||||
premiumModal.activate(`${item.name} theme`)
|
||||
|
||||
Reference in New Issue
Block a user