Merge branch 'develop' into swn

This commit is contained in:
tamaina
2021-10-28 20:36:20 +09:00
9 changed files with 70 additions and 79 deletions

View File

@@ -10,7 +10,12 @@ import { defineComponent } from 'vue';
import * as os from '@client/os';
export default defineComponent({
props: ['q'],
props: {
q: {
type: String,
required: true,
}
},
data() {
return {
query: null,
@@ -21,10 +26,7 @@ export default defineComponent({
},
methods: {
search() {
const engine = this.$store.state.webSearchEngine ||
'https://www.google.com/search?q={{query}}';
const url = engine.replace('{{query}}', this.query)
window.open(url, '_blank');
window.open(`https://www.google.com/search?q=${this.query}`, '_blank');
}
}
});

View File

@@ -35,7 +35,7 @@
<MkA class="item" active-class="active" to="/settings" v-click-anime>
<i class="fas fa-cog fa-fw"></i><span class="text">{{ $ts.settings }}</span>
</MkA>
<button class="item _button post" @click="post">
<button class="item _button post" @click="post" data-cy-open-post-form>
<i class="fas fa-pencil-alt fa-fw"></i><span class="text">{{ $ts.note }}</span>
</button>
</div>