2020-12-09 19:03:29 +05:30
|
|
|
<template>
|
|
|
|
<div
|
|
|
|
class="uk-container uk-container-expand uk-light uk-height-viewport"
|
|
|
|
style="background: #0b0e0f"
|
|
|
|
>
|
|
|
|
<nav
|
|
|
|
class="uk-navbar-container uk-container-expand uk-light"
|
|
|
|
style="background: #0b0e0f"
|
|
|
|
uk-navbar
|
|
|
|
>
|
|
|
|
<div class="uk-navbar-left">
|
|
|
|
<router-link class="uk-navbar-item uk-logo uk-text-bold" to="/"
|
2021-01-02 01:35:44 +05:30
|
|
|
><img
|
|
|
|
src="../public/img/icons/logo.svg"
|
|
|
|
height="32"
|
|
|
|
width="32"
|
|
|
|
/>iped</router-link
|
|
|
|
>
|
|
|
|
</div>
|
2021-03-31 21:30:39 +05:30
|
|
|
<div class="uk-navbar-center uk-flex uk-visible@s">
|
2021-01-02 01:35:44 +05:30
|
|
|
<input
|
|
|
|
class="uk-input"
|
|
|
|
type="text"
|
|
|
|
placeholder="Search"
|
|
|
|
v-model="searchText"
|
2020-12-09 19:03:29 +05:30
|
|
|
@keypress="onChange($event)"
|
|
|
|
/>
|
|
|
|
</div>
|
|
|
|
<div class="uk-navbar-right">
|
|
|
|
<ul class="uk-navbar-nav">
|
|
|
|
<li>
|
|
|
|
<router-link to="/preferences">Preferences</router-link>
|
|
|
|
</li>
|
|
|
|
<li>
|
|
|
|
<router-link to="/login">Login</router-link>
|
|
|
|
</li>
|
|
|
|
<li>
|
|
|
|
<router-link to="/feed">Feed</router-link>
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
</div>
|
|
|
|
</nav>
|
2021-03-31 21:33:31 +05:30
|
|
|
<div class="uk-container-expand uk-hidden@s">
|
2021-03-31 21:30:39 +05:30
|
|
|
<input
|
2021-03-31 21:33:31 +05:30
|
|
|
class="uk-input"
|
2021-03-31 21:30:39 +05:30
|
|
|
type="text"
|
|
|
|
placeholder="Search"
|
|
|
|
v-model="searchText"
|
|
|
|
@keypress="onChange($event)"
|
|
|
|
/>
|
|
|
|
</div>
|
2020-12-09 19:03:29 +05:30
|
|
|
|
|
|
|
<router-view />
|
2021-03-29 12:08:29 +05:30
|
|
|
|
|
|
|
<div style="text-align: center">
|
|
|
|
<a href="https://github.com/TeamPiped/Piped">
|
|
|
|
<font-awesome-icon
|
|
|
|
:icon="['fab', 'github']"
|
|
|
|
></font-awesome-icon>
|
|
|
|
</a>
|
|
|
|
|
|
|
|
<a href="bitcoin://13MoHioctZkC7LDSZSb4m32TDT8xNmei1p">
|
|
|
|
<font-awesome-icon
|
|
|
|
:icon="['fab', 'bitcoin']"
|
|
|
|
></font-awesome-icon>
|
|
|
|
13MoHioctZkC7LDSZSb4m32TDT8xNmei1p
|
|
|
|
</a>
|
|
|
|
</div>
|
2020-12-09 19:03:29 +05:30
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
import Constants from "@/Constants.js";
|
|
|
|
export default {
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
searchText: "",
|
|
|
|
searchSuggestions: []
|
|
|
|
};
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
onChange(e) {
|
|
|
|
if (e.key === "Enter") {
|
|
|
|
this.$router.push({
|
|
|
|
name: "SearchResults",
|
|
|
|
query: { search_query: this.searchText }
|
|
|
|
});
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
2021-02-24 15:05:41 +05:30
|
|
|
this.fetchJson(
|
2020-12-09 19:03:29 +05:30
|
|
|
Constants.BASE_URL +
|
|
|
|
"/suggestions?query=" +
|
|
|
|
encodeURI(this.searchText + e.key)
|
2021-02-24 15:05:41 +05:30
|
|
|
);
|
2020-12-09 19:03:29 +05:30
|
|
|
}
|
|
|
|
}
|
|
|
|
};
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<style>
|
|
|
|
#app {
|
|
|
|
background: #0b0e0f;
|
|
|
|
}
|
|
|
|
|
|
|
|
::-webkit-scrollbar {
|
|
|
|
background-color: #15191a;
|
|
|
|
color: #c5bcae;
|
|
|
|
}
|
|
|
|
|
|
|
|
::-webkit-scrollbar-thumb {
|
|
|
|
background-color: #4b4f52;
|
|
|
|
}
|
|
|
|
|
|
|
|
::-webkit-scrollbar-thumb:hover {
|
|
|
|
background-color: #5b6469;
|
|
|
|
}
|
|
|
|
|
|
|
|
::-webkit-scrollbar-thumb:active {
|
|
|
|
background-color: #485053;
|
|
|
|
}
|
|
|
|
|
|
|
|
::-webkit-scrollbar-corner {
|
|
|
|
background-color: #0b0e0f;
|
|
|
|
}
|
|
|
|
|
2021-02-24 15:05:41 +05:30
|
|
|
* {
|
|
|
|
scrollbar-color: #15191a #444a4e;
|
|
|
|
}
|
|
|
|
</style>
|