From 63442282a9a824ba77ed1c0d551213ff3e6abf99 Mon Sep 17 00:00:00 2001 From: bob1520 <80553357+hockerschwan@users.noreply.github.com> Date: Fri, 24 Jun 2022 21:53:17 +0000 Subject: [PATCH] clear filter in userplaylists and history when clicked "clear input" (#2349) --- src/renderer/components/ft-input/ft-input.js | 2 ++ src/renderer/views/History/History.vue | 1 + src/renderer/views/UserPlaylists/UserPlaylists.vue | 1 + 3 files changed, 4 insertions(+) diff --git a/src/renderer/components/ft-input/ft-input.js b/src/renderer/components/ft-input/ft-input.js index f4fb14c9..98d2afae 100644 --- a/src/renderer/components/ft-input/ft-input.js +++ b/src/renderer/components/ft-input/ft-input.js @@ -126,6 +126,8 @@ export default Vue.extend({ // Focus on input element after text is clear for better UX inputElement.focus() + + this.$emit('clear') }, handleActionIconChange: function() { diff --git a/src/renderer/views/History/History.vue b/src/renderer/views/History/History.vue index 9703421c..4b6e6424 100644 --- a/src/renderer/views/History/History.vue +++ b/src/renderer/views/History/History.vue @@ -16,6 +16,7 @@ :show-clear-text-button="true" :show-action-button="false" @input="(input) => query = input" + @clear="query = ''" />