forked from Ivasoft/geovisio-website
wip
This commit is contained in:
2
.env
2
.env
@@ -1 +1 @@
|
||||
VITE_API_URL=https://geovisio-backend-dev.osc-fr1.scalingo.io/
|
||||
VITE_API_URL=https://geovisio-backend-dev.osc-fr1.scalingo.io/api/
|
||||
@@ -46,25 +46,18 @@
|
||||
<div class="wrapper-right-entries">
|
||||
<div class="item-with-sub">
|
||||
<Link
|
||||
type="external"
|
||||
icon="bi bi-person-circle"
|
||||
path="authentification"
|
||||
:path="userUrl"
|
||||
:text="userName"
|
||||
/>
|
||||
<i v-if="isLogged" class="chevron bi bi-chevron-up"></i>
|
||||
<div v-if="isLogged" class="sub-nav-block">
|
||||
<div class="logged-link">
|
||||
<Link
|
||||
path="mon-compte"
|
||||
:text="$t('general.header.account_text')"
|
||||
/>
|
||||
</div>
|
||||
<div class="logged-link">
|
||||
<Link
|
||||
type="external"
|
||||
:path="logoutUrl"
|
||||
:text="$t('general.header.logout_text')"
|
||||
/>
|
||||
</div>
|
||||
<Link
|
||||
type="external"
|
||||
:path="logoutUrl"
|
||||
:text="$t('general.header.logout_text')"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<button class="menu-burger" @click="toggleMenu">
|
||||
@@ -97,7 +90,12 @@ const isLogged = computed((): boolean => {
|
||||
return !!cookies.get('user_id')
|
||||
})
|
||||
const logoutUrl = computed((): string => {
|
||||
return `${import.meta.env.VITE_API_URL}api/auth/logout?next_url=${route.path}`
|
||||
return `${import.meta.env.VITE_API_URL}auth/logout?next_url=${route.path}`
|
||||
})
|
||||
const userUrl = computed((): string => {
|
||||
return isLogged.value
|
||||
? ''
|
||||
: `${import.meta.env.VITE_API_URL}auth/login?next_url=${route.path}`
|
||||
})
|
||||
const userName = computed((): string => {
|
||||
return isLogged.value
|
||||
@@ -150,6 +148,7 @@ const userName = computed((): string => {
|
||||
margin-left: 0.5rem;
|
||||
}
|
||||
.sub-nav-block {
|
||||
padding: 1rem 2rem 1rem 1rem;
|
||||
display: none;
|
||||
border-radius: 0.5rem;
|
||||
border: 1px solid var(--black);
|
||||
@@ -159,19 +158,6 @@ const userName = computed((): string => {
|
||||
top: 3.5rem;
|
||||
z-index: 1;
|
||||
}
|
||||
.logged-link {
|
||||
padding: 1rem 2rem 1rem 1rem;
|
||||
}
|
||||
.logged-link:first-child {
|
||||
padding-top: 1.5rem;
|
||||
}
|
||||
.logged-link:nth-child(2) {
|
||||
padding-bottom: 1.5rem;
|
||||
}
|
||||
.logged-link:hover {
|
||||
border-radius: 0.5rem;
|
||||
background-color: var(--grey);
|
||||
}
|
||||
.item-with-sub:hover .sub-nav-block {
|
||||
display: block;
|
||||
}
|
||||
|
||||
@@ -63,7 +63,7 @@ onMounted(async () => {
|
||||
try {
|
||||
await new GeoVisio(
|
||||
'viewer', // Div ID
|
||||
`${import.meta.env.VITE_API_URL}api/search`, // STAC API search endpoint
|
||||
`${import.meta.env.VITE_API_URL}search`, // STAC API search endpoint
|
||||
{
|
||||
map: {
|
||||
startWide: true,
|
||||
|
||||
@@ -1,43 +1,16 @@
|
||||
<template>
|
||||
<Header />
|
||||
<main class="entry-page">
|
||||
<iframe :src="myAccountUrl" class="iframe"></iframe>
|
||||
<main>
|
||||
<iframe
|
||||
src="https://panoramax.ign.fr/oauth/realms/geovisio/account/#/personal-info"
|
||||
height="100%"
|
||||
width="100%"
|
||||
></iframe>
|
||||
</main>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
<script setup>
|
||||
import Header from '@/components/Header.vue'
|
||||
import { computed } from 'vue'
|
||||
|
||||
const myAccountUrl = computed<string>(
|
||||
() => `${import.meta.env.VITE_API_URL}oauth/realms/geovisio/account`
|
||||
)
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.entry-page {
|
||||
padding-right: 4rem;
|
||||
padding-left: 8rem;
|
||||
}
|
||||
.iframe {
|
||||
width: 100%;
|
||||
min-height: calc(100vh - 9rem);
|
||||
}
|
||||
|
||||
@media (max-width: 848px) {
|
||||
.entry-page {
|
||||
padding-top: 4rem;
|
||||
}
|
||||
}
|
||||
@media (max-width: 768px) {
|
||||
.entry-page {
|
||||
padding-right: 2rem;
|
||||
padding-left: 2rem;
|
||||
}
|
||||
}
|
||||
@media (max-width: 500px) {
|
||||
.entry-page {
|
||||
padding-top: 14rem;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<style scoped></style>
|
||||
|
||||
Reference in New Issue
Block a user