diff options
author | 2023-05-27 18:48:38 +0530 | |
---|---|---|
committer | 2023-05-27 18:48:38 +0530 | |
commit | eaa8e80efadc55d42462af0a5381f2552acc3c88 (patch) | |
tree | b54868af925e2db3fc6d5444475cd14bd3255f1c /src/components/services/tabs/TabItem.tsx | |
parent | update react version to 18.2.0 and it related changes (diff) | |
download | ferdium-app-eaa8e80efadc55d42462af0a5381f2552acc3c88.tar.gz ferdium-app-eaa8e80efadc55d42462af0a5381f2552acc3c88.tar.zst ferdium-app-eaa8e80efadc55d42462af0a5381f2552acc3c88.zip |
Expose "Clear service cache" in the service settings screen and the sidebar context menu for individual services (#1053)
Diffstat (limited to 'src/components/services/tabs/TabItem.tsx')
-rw-r--r-- | src/components/services/tabs/TabItem.tsx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/components/services/tabs/TabItem.tsx b/src/components/services/tabs/TabItem.tsx index 2ed595919..289597db9 100644 --- a/src/components/services/tabs/TabItem.tsx +++ b/src/components/services/tabs/TabItem.tsx | |||
@@ -129,6 +129,7 @@ interface IProps extends WrappedComponentProps, WithStylesProps<typeof styles> { | |||
129 | toggleDarkMode: () => void; | 129 | toggleDarkMode: () => void; |
130 | openSettings: (args: { path: string }) => void; | 130 | openSettings: (args: { path: string }) => void; |
131 | deleteService: () => void; | 131 | deleteService: () => void; |
132 | clearCache: () => void; | ||
132 | disableService: () => void; | 133 | disableService: () => void; |
133 | enableService: () => void; | 134 | enableService: () => void; |
134 | hibernateService: () => void; | 135 | hibernateService: () => void; |
@@ -220,6 +221,7 @@ class TabItem extends Component<IProps, IState> { | |||
220 | toggleAudio, | 221 | toggleAudio, |
221 | toggleDarkMode, | 222 | toggleDarkMode, |
222 | deleteService, | 223 | deleteService, |
224 | clearCache, | ||
223 | disableService, | 225 | disableService, |
224 | enableService, | 226 | enableService, |
225 | hibernateService, | 227 | hibernateService, |
@@ -298,6 +300,11 @@ class TabItem extends Component<IProps, IState> { | |||
298 | enabled: service.isEnabled && service.canHibernate, | 300 | enabled: service.isEnabled && service.canHibernate, |
299 | }, | 301 | }, |
300 | { | 302 | { |
303 | label: intl.formatMessage(globalMessages.clearCache), | ||
304 | click: () => clearCache(), | ||
305 | enabled: service.isEnabled, | ||
306 | }, | ||
307 | { | ||
301 | type: 'separator', | 308 | type: 'separator', |
302 | }, | 309 | }, |
303 | { | 310 | { |