aboutsummaryrefslogtreecommitdiff
path: root/src/components/search_bar
diff options
context:
space:
mode:
authorShpuld Shpuldson <shp@cock.li>2020-11-24 12:32:42 +0200
committerShpuld Shpuldson <shp@cock.li>2020-11-24 12:32:42 +0200
commit7b99d98c553f40ec4d633d0d4fdf65f275c80e77 (patch)
treeb856ab6b3682b0f1df44511d142d99ae98310416 /src/components/search_bar
parent14ce0c1c073e17060a7d3cbe4352a5e9881c03dd (diff)
Replace all use of <a> + href='#' with proper buttons
Diffstat (limited to 'src/components/search_bar')
-rw-r--r--src/components/search_bar/search_bar.vue32
1 files changed, 19 insertions, 13 deletions
diff --git a/src/components/search_bar/search_bar.vue b/src/components/search_bar/search_bar.vue
index 89a601c8..6cf9179e 100644
--- a/src/components/search_bar/search_bar.vue
+++ b/src/components/search_bar/search_bar.vue
@@ -3,17 +3,18 @@
class="SearchBar"
:class="{ '-expanded': !hidden }"
>
- <a
+ <button
v-if="hidden"
- href="#"
- class="nav-icon"
+ class="button-unstyled nav-icon"
:title="$t('nav.search')"
- ><FAIcon
- fixed-width
- class="fa-scale-110 fa-old-padding"
- icon="search"
@click.prevent.stop="toggleHidden"
- /></a>
+ >
+ <FAIcon
+ fixed-width
+ class="fa-scale-110 fa-old-padding"
+ icon="search"
+ />
+ </button>
<template v-else>
<input
id="search-bar-input"
@@ -25,7 +26,7 @@
@keyup.enter="find(searchTerm)"
>
<button
- class="btn search-button"
+ class="button-default search-button"
@click="find(searchTerm)"
>
<FAIcon
@@ -33,14 +34,16 @@
icon="search"
/>
</button>
- <span>
+ <button
+ class="button-unstyled cancel-search"
+ @click.prevent.stop="toggleHidden"
+ >
<FAIcon
fixed-width
icon="times"
class="cancel-icon fa-scale-110 fa-old-padding"
- @click.prevent.stop="toggleHidden"
/>
- </span>
+ </button>
</template>
</div>
</template>
@@ -69,8 +72,11 @@
flex: 1 0 auto;
}
+ .cancel-search {
+ height: 50px;
+ }
+
.cancel-icon {
- cursor: pointer;
color: $fallback--text;
color: var(--btnTopBarText, $fallback--text);
}