Improve search

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2022-08-22 12:12:09 +02:00
parent 444e0d6a0c
commit baac00f678
36 changed files with 1343 additions and 1013 deletions

View File

@@ -9,7 +9,7 @@
</h2>
<button
v-if="suggestGeoloc && isIPLocation"
v-if="suggestGeoloc"
class="inline-flex bg-primary rounded text-white flex-initial px-4 py-2 justify-center w-full md:w-min whitespace-nowrap"
@click="emit('doGeoLoc')"
>
@@ -21,7 +21,7 @@
<div class="hidden sm:block" v-show="showScrollLeftButton">
<button
@click="scrollLeft"
class="absolute inset-y-0 my-auto z-10 rounded-full bg-white w-10 h-10 border border-shadowColor -left-5"
class="absolute inset-y-0 my-auto z-10 rounded-full bg-white dark:bg-transparent w-10 h-10 border border-shadowColor -left-5"
>
<div class="">&lt;</div>
</button>
@@ -38,7 +38,7 @@
<div class="hidden sm:block" v-show="showScrollRightButton">
<button
@click="scrollRight"
class="absolute inset-y-0 my-auto z-10 rounded-full bg-white w-10 h-10 border border-shadowColor -right-5"
class="absolute inset-y-0 my-auto z-10 rounded-full bg-white dark:bg-transparent w-10 h-10 border border-shadowColor -right-5"
>
<div class="">&gt;</div>
</button>
@@ -47,9 +47,8 @@
</template>
<script lang="ts" setup>
import { computed, inject, onMounted, onUnmounted, ref } from "vue";
import { onMounted, onUnmounted, ref } from "vue";
import { useI18n } from "vue-i18n";
import { LocationType } from "../../types/user-location.model";
withDefaults(
defineProps<{
@@ -62,14 +61,6 @@ const emit = defineEmits(["doGeoLoc"]);
const { t } = useI18n({ useScope: "global" });
const userLocationInjection = inject<{
userLocation: LocationType;
}>("userLocation");
const isIPLocation = computed(
() => userLocationInjection?.userLocation.isIPLocation
);
const showScrollRightButton = ref(true);
const showScrollLeftButton = ref(false);