mirror of https://github.com/Lissy93/dashy.git
🐛 Fixes clearFilterInput Safari bug (#463) (Sentry: 2911601158)
This commit is contained in:
parent
d07a5f7e6f
commit
ad1fae5b66
|
@ -100,11 +100,13 @@ export default {
|
|||
this.settingsVisible = this.getSettingsVisibility();
|
||||
},
|
||||
methods: {
|
||||
/* Emit event to begin/ continue searching */
|
||||
userIsTypingSomething(something) {
|
||||
this.$emit('user-is-searchin', something);
|
||||
},
|
||||
/* Call function to clear search field, remove focus and reset results */
|
||||
clearFilterInput() {
|
||||
this.$refs.SearchBar.clearFilterInput();
|
||||
if (this.$refs.SearchBar) this.$refs.SearchBar.clearFilterInput();
|
||||
},
|
||||
getInitialTheme() {
|
||||
return this.appConfig.theme || '';
|
||||
|
@ -115,10 +117,12 @@ export default {
|
|||
if (typeof userThemes === 'string') return [userThemes];
|
||||
return userThemes;
|
||||
},
|
||||
/* Show / hide settings */
|
||||
toggleSettingsVisibility() {
|
||||
this.settingsVisible = !this.settingsVisible;
|
||||
localStorage.setItem(localStorageKeys.HIDE_SETTINGS, this.settingsVisible);
|
||||
},
|
||||
/* Get initial settings visibility, either from appConfig, local storage or browser type */
|
||||
getSettingsVisibility() {
|
||||
const screenWidth = document.body.clientWidth;
|
||||
if (screenWidth && screenWidth < 600) return false;
|
||||
|
|
Loading…
Reference in New Issue