Update google.vue

This commit is contained in:
syuilo 2020-02-27 15:13:46 +09:00
parent 969cd16638
commit 3bd827d7da
1 changed files with 6 additions and 14 deletions

View File

@ -1,12 +1,13 @@
<template>
<div class="mk-google">
<input type="search" v-model="query" :placeholder="q">
<button @click="search"><fa icon="search"/> {{ $t('search') }}</button>
<button @click="search"><fa :icon="faSearch"/> {{ $t('search') }}</button>
</div>
</template>
<script lang="ts">
import Vue from 'vue';
import { faSearch } from '@fortawesome/free-solid-svg-icons';
import i18n from '../i18n';
export default Vue.extend({
@ -14,7 +15,8 @@ export default Vue.extend({
props: ['q'],
data() {
return {
query: null
query: null,
faSearch
};
},
mounted() {
@ -42,27 +44,17 @@ export default Vue.extend({
width: 100%;
height: 40px;
font-size: 16px;
color: var(--googleSearchFg);
background: var(--googleSearchBg);
border: solid 1px var(--googleSearchBorder);
border: solid 1px var(--divider);
border-radius: 4px 0 0 4px;
&:hover {
border-color: var(--googleSearchHoverBorder);
}
}
> button {
flex-shrink: 0;
padding: 0 16px;
border: solid 1px var(--googleSearchBorder);
border: solid 1px var(--divider);
border-left: none;
border-radius: 0 4px 4px 0;
&:hover {
background-color: var(--googleSearchHoverButton);
}
&:active {
box-shadow: 0 2px 4px rgba(#000, 0.15) inset;
}