fix size and display in phone
This commit is contained in:
parent
09eace4190
commit
13e04e6c2c
10
index.html
10
index.html
@ -11,3 +11,13 @@
|
||||
<script type="module" src="/src/main.ts"></script>
|
||||
</body>
|
||||
</html>
|
||||
<style>
|
||||
html {
|
||||
background: url("public/background.jpg");
|
||||
background-repeat: no-repeat;
|
||||
background-size: 1000px auto;
|
||||
background-position: center top;
|
||||
background-attachment: fixed;
|
||||
overflow-y: clip;
|
||||
}
|
||||
</style>
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 317 KiB |
33
src/App.vue
33
src/App.vue
@ -29,5 +29,38 @@
|
||||
margin-top: 8px;
|
||||
padding: 0 12px;
|
||||
overflow-y: scroll;
|
||||
max-height: 620px !important;
|
||||
}
|
||||
|
||||
body {
|
||||
position: absolute;
|
||||
width: 342px;
|
||||
max-height: 620px !important;
|
||||
top: 118px;
|
||||
left: calc(50% - 174px);
|
||||
}
|
||||
.v-application__wrap {
|
||||
width: 342px;
|
||||
min-height: 708px !important;
|
||||
}
|
||||
|
||||
.v-toolbar {
|
||||
border-radius: 36px 36px 0 0 !important;
|
||||
top: 118px !important;
|
||||
left: calc(50% - 174px) !important;
|
||||
width: 342px !important;
|
||||
}
|
||||
|
||||
.v-application {
|
||||
border-radius: 36px;
|
||||
}
|
||||
|
||||
.recommandations {
|
||||
position: fixed;
|
||||
bottom: calc(100vh - 825px);
|
||||
width: 342px;
|
||||
left: calc(50% - 174px) !important;
|
||||
border-radius: 0 0 36px 36px !important;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
@ -26,7 +26,7 @@ async function getSimilarBooks() {
|
||||
params.collection = true;
|
||||
}
|
||||
|
||||
return getBookRecommandations(book.id, params)
|
||||
return getBookRecommandations(book!.id, params)
|
||||
.then(result => {
|
||||
books.value = result;
|
||||
})
|
||||
@ -47,7 +47,7 @@ watch(selectedOption, getSimilarBooks)
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<v-sheet>
|
||||
<v-sheet class="recommandation-books">
|
||||
<span class="d-flex ga-1 bg-white pa-2">
|
||||
<v-select
|
||||
v-model="selectedOption"
|
||||
@ -92,7 +92,7 @@ watch(selectedOption, getSimilarBooks)
|
||||
</v-sheet>
|
||||
</template>
|
||||
|
||||
<style>
|
||||
<style scoped>
|
||||
.v-slide-group__prev, .v-slide-group__next {
|
||||
flex-basis: 24px;
|
||||
min-width: 24px;
|
||||
|
||||
@ -12,27 +12,54 @@ const {filters} = storeToRefs(useBooksStore());
|
||||
<div class="selected-filters">
|
||||
<v-chip-group column>
|
||||
<template v-if="filters.mot_clef">
|
||||
<v-chip>Mot-clef: {{ filters.mot_clef }}</v-chip>
|
||||
<v-chip
|
||||
closable
|
||||
@click:close="filters.mot_clef = ''"
|
||||
>
|
||||
Mot-clef: {{ filters.mot_clef }}
|
||||
</v-chip>
|
||||
</template>
|
||||
<template v-if="filters.collections">
|
||||
<v-chip
|
||||
v-for="collection in filters.collections"
|
||||
:key="collection"
|
||||
closable
|
||||
@click:close="filters.collections = filters.collections.filter(c => c !== collection)"
|
||||
>
|
||||
Collection: {{ collection }}
|
||||
</v-chip>
|
||||
</template>
|
||||
<template v-if="filters.nb_de_pages.min">
|
||||
<v-chip>📚 Nombre de pages minimum: {{ filters.nb_de_pages.min }}</v-chip>
|
||||
<v-chip
|
||||
closable
|
||||
@click:close="filters.nb_de_pages.min = undefined"
|
||||
>
|
||||
📚 Nombre de pages minimum: {{ filters.nb_de_pages.min }}
|
||||
</v-chip>
|
||||
</template>
|
||||
<template v-if="filters.nb_de_pages.max">
|
||||
<v-chip>📚 Nombre de pages maximum: {{ filters.nb_de_pages.max }}</v-chip>
|
||||
<v-chip
|
||||
closable
|
||||
@click:close="filters.nb_de_pages.max = undefined"
|
||||
>
|
||||
📚 Nombre de pages maximum: {{ filters.nb_de_pages.max }}
|
||||
</v-chip>
|
||||
</template>
|
||||
<template v-if="filters.date_de_parution.après">
|
||||
<v-chip>🗓️ Publié après: {{ filters.date_de_parution.après }}</v-chip>
|
||||
<v-chip
|
||||
closable
|
||||
@click:close="filters.date_de_parution.après = undefined"
|
||||
>
|
||||
🗓️ Publié après: {{ filters.date_de_parution.après }}
|
||||
</v-chip>
|
||||
</template>
|
||||
<template v-if="filters.date_de_parution.avant">
|
||||
<v-chip>🗓️ Publié avant : {{ filters.date_de_parution.avant }}</v-chip>
|
||||
<v-chip
|
||||
closable
|
||||
@click:close="filters.date_de_parution.avant = undefined"
|
||||
>
|
||||
🗓️ Publié avant : {{ filters.date_de_parution.avant }}
|
||||
</v-chip>
|
||||
</template>
|
||||
</v-chip-group>
|
||||
</div>
|
||||
|
||||
@ -9,12 +9,14 @@ defineEmits(["close"]);
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<v-expand-x-transition class="panel">
|
||||
<v-expand-x-transition
|
||||
class="panel"
|
||||
mode="out-in"
|
||||
>
|
||||
<v-card
|
||||
v-show="isPanelOpened"
|
||||
class="mx-auto"
|
||||
bg-color="white"
|
||||
height="100%"
|
||||
width="100%"
|
||||
@keydown.esc="$emit('close')"
|
||||
>
|
||||
@ -37,9 +39,12 @@ defineEmits(["close"]);
|
||||
<style scoped>
|
||||
.panel {
|
||||
position: absolute;
|
||||
width: 80%;
|
||||
top: 64px;
|
||||
right: 0;
|
||||
z-index: 1;
|
||||
height: calc(100% - 64px);
|
||||
border-radius: 0 0 36px 36px;
|
||||
opacity: 0.95;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
@ -116,7 +116,7 @@ const shouldShowReco = ref(false);
|
||||
>
|
||||
<v-slide-y-reverse-transition v-if="!isLoading">
|
||||
<v-card v-show="shouldShowReco">
|
||||
<Suggestion :book="book!"/>
|
||||
<Suggestion v-if="book" :book="book!"/>
|
||||
</v-card>
|
||||
</v-slide-y-reverse-transition>
|
||||
<v-btn
|
||||
@ -143,14 +143,6 @@ const shouldShowReco = ref(false);
|
||||
margin-left: calc((100% - 300px) / 2);
|
||||
}
|
||||
|
||||
.recommandations {
|
||||
position: fixed;
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
left: 0
|
||||
|
||||
}
|
||||
|
||||
section {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user