commit
32724464c0
2
fittrackee/dist/index.html
vendored
2
fittrackee/dist/index.html
vendored
@ -1 +1 @@
|
|||||||
<!doctype html><html lang="en"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1"><!--[if IE]><link rel="icon" href="/favicon.ico"><![endif]--><link rel="stylesheet" href="/static/css/fork-awesome.min.css"/><link rel="stylesheet" href="/static/css/leaflet.css"/><title>FitTrackee</title><script defer="defer" src="/static/js/chunk-vendors.a53c2257.js"></script><script defer="defer" src="/static/js/app.9b093906.js"></script><link href="/static/css/app.a587cef2.css" rel="stylesheet"><link rel="icon" type="image/png" sizes="32x32" href="/img/icons/favicon-32x32.png"><link rel="icon" type="image/png" sizes="16x16" href="/img/icons/favicon-16x16.png"><link rel="manifest" href="/manifest.json"><meta name="theme-color" content="#4DBA87"><meta name="apple-mobile-web-app-capable" content="no"><meta name="apple-mobile-web-app-status-bar-style" content="default"><meta name="apple-mobile-web-app-title" content="fittrackee_client"><link rel="apple-touch-icon" href="/img/icons/apple-touch-icon-152x152.png"><link rel="mask-icon" href="/img/icons/safari-pinned-tab.svg" color="#4DBA87"><meta name="msapplication-TileImage" content="/img/icons/msapplication-icon-144x144.png"><meta name="msapplication-TileColor" content="#000000"></head><body><noscript><strong>We're sorry but FitTrackee doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div></body></html>
|
<!doctype html><html lang="en"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1"><!--[if IE]><link rel="icon" href="/favicon.ico"><![endif]--><link rel="stylesheet" href="/static/css/fork-awesome.min.css"/><link rel="stylesheet" href="/static/css/leaflet.css"/><title>FitTrackee</title><script defer="defer" src="/static/js/chunk-vendors.a53c2257.js"></script><script defer="defer" src="/static/js/app.2b040ac6.js"></script><link href="/static/css/app.a587cef2.css" rel="stylesheet"><link rel="icon" type="image/png" sizes="32x32" href="/img/icons/favicon-32x32.png"><link rel="icon" type="image/png" sizes="16x16" href="/img/icons/favicon-16x16.png"><link rel="manifest" href="/manifest.json"><meta name="theme-color" content="#4DBA87"><meta name="apple-mobile-web-app-capable" content="no"><meta name="apple-mobile-web-app-status-bar-style" content="default"><meta name="apple-mobile-web-app-title" content="fittrackee_client"><link rel="apple-touch-icon" href="/img/icons/apple-touch-icon-152x152.png"><link rel="mask-icon" href="/img/icons/safari-pinned-tab.svg" color="#4DBA87"><meta name="msapplication-TileImage" content="/img/icons/msapplication-icon-144x144.png"><meta name="msapplication-TileColor" content="#000000"></head><body><noscript><strong>We're sorry but FitTrackee doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div></body></html>
|
2
fittrackee/dist/service-worker.js
vendored
2
fittrackee/dist/service-worker.js
vendored
File diff suppressed because one or more lines are too long
2
fittrackee/dist/service-worker.js.map
vendored
2
fittrackee/dist/service-worker.js.map
vendored
File diff suppressed because one or more lines are too long
2
fittrackee/dist/static/js/app.2b040ac6.js
vendored
Normal file
2
fittrackee/dist/static/js/app.2b040ac6.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
fittrackee/dist/static/js/app.2b040ac6.js.map
vendored
Normal file
1
fittrackee/dist/static/js/app.2b040ac6.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
2
fittrackee/dist/static/js/app.9b093906.js
vendored
2
fittrackee/dist/static/js/app.9b093906.js
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -19,8 +19,8 @@
|
|||||||
"invalid credentials": "Identifiants invalides.",
|
"invalid credentials": "Identifiants invalides.",
|
||||||
"invalid payload": "Données fournies incorrectes.",
|
"invalid payload": "Données fournies incorrectes.",
|
||||||
"invalid token, please log in again": "Jeton de connexion invalide, merci de vous reconnecter.",
|
"invalid token, please log in again": "Jeton de connexion invalide, merci de vous reconnecter.",
|
||||||
"invalid token, please request a new token": "Jeton de connexion, merci de vous reconnecter.",
|
"invalid token, please request a new token": "Jeton de connexion invalide, veuillez demander un nouveau jeton.",
|
||||||
"new email must be different than current email": "La nouvelle addresse électronique doit être differente de l'adresse actuelle",
|
"new email must be different than current email": "La nouvelle adresse électronique doit être différente de l'adresse actuelle",
|
||||||
"no file part": "Pas de fichier fourni.",
|
"no file part": "Pas de fichier fourni.",
|
||||||
"no selected file": "Pas de fichier sélectionné.",
|
"no selected file": "Pas de fichier sélectionné.",
|
||||||
"no tracks in gpx file": "Pas de trace (<trk>) dans le fichier .gpx.",
|
"no tracks in gpx file": "Pas de trace (<trk>) dans le fichier .gpx.",
|
||||||
|
@ -53,6 +53,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
props: { action: 'login' },
|
props: { action: 'login' },
|
||||||
meta: {
|
meta: {
|
||||||
title: 'user.LOGIN',
|
title: 'user.LOGIN',
|
||||||
|
withoutAuth: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -62,6 +63,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
props: { action: 'register' },
|
props: { action: 'register' },
|
||||||
meta: {
|
meta: {
|
||||||
title: 'user.REGISTER',
|
title: 'user.REGISTER',
|
||||||
|
withoutAuth: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -73,6 +75,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
),
|
),
|
||||||
meta: {
|
meta: {
|
||||||
title: 'user.ACCOUNT_CONFIRMATION',
|
title: 'user.ACCOUNT_CONFIRMATION',
|
||||||
|
withoutAuth: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -85,6 +88,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
props: { action: 'account-confirmation-resend' },
|
props: { action: 'account-confirmation-resend' },
|
||||||
meta: {
|
meta: {
|
||||||
title: 'buttons.ACCOUNT-CONFIRMATION-RESEND',
|
title: 'buttons.ACCOUNT-CONFIRMATION-RESEND',
|
||||||
|
withoutAuth: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -97,6 +101,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
props: { action: 'email-sent' },
|
props: { action: 'email-sent' },
|
||||||
meta: {
|
meta: {
|
||||||
title: 'buttons.ACCOUNT-CONFIRMATION-RESEND',
|
title: 'buttons.ACCOUNT-CONFIRMATION-RESEND',
|
||||||
|
withoutAuth: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -109,6 +114,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
props: { action: 'request-sent' },
|
props: { action: 'request-sent' },
|
||||||
meta: {
|
meta: {
|
||||||
title: 'user.PASSWORD_RESET',
|
title: 'user.PASSWORD_RESET',
|
||||||
|
withoutAuth: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -121,6 +127,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
props: { action: 'reset-request' },
|
props: { action: 'reset-request' },
|
||||||
meta: {
|
meta: {
|
||||||
title: 'user.PASSWORD_RESET',
|
title: 'user.PASSWORD_RESET',
|
||||||
|
withoutAuth: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -133,6 +140,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
props: { action: 'password-updated' },
|
props: { action: 'password-updated' },
|
||||||
meta: {
|
meta: {
|
||||||
title: 'user.PASSWORD_RESET',
|
title: 'user.PASSWORD_RESET',
|
||||||
|
withoutAuth: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -145,6 +153,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
props: { action: 'reset' },
|
props: { action: 'reset' },
|
||||||
meta: {
|
meta: {
|
||||||
title: 'user.PASSWORD_RESET',
|
title: 'user.PASSWORD_RESET',
|
||||||
|
withoutAuth: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -156,6 +165,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
),
|
),
|
||||||
meta: {
|
meta: {
|
||||||
title: 'user.EMAIL_UPDATE',
|
title: 'user.EMAIL_UPDATE',
|
||||||
|
withoutChecks: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -447,6 +457,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
component: AboutView,
|
component: AboutView,
|
||||||
meta: {
|
meta: {
|
||||||
title: 'common.ABOUT',
|
title: 'common.ABOUT',
|
||||||
|
withoutChecks: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -455,6 +466,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||||||
component: PrivacyPolicyView,
|
component: PrivacyPolicyView,
|
||||||
meta: {
|
meta: {
|
||||||
title: 'privacy_policy.TITLE',
|
title: 'privacy_policy.TITLE',
|
||||||
|
withoutChecks: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -472,20 +484,6 @@ const router = createRouter({
|
|||||||
routes,
|
routes,
|
||||||
})
|
})
|
||||||
|
|
||||||
const pathsWithoutAuthentication = [
|
|
||||||
'/login',
|
|
||||||
'/password-reset',
|
|
||||||
'/password-reset/password-updated',
|
|
||||||
'/password-reset/request',
|
|
||||||
'/password-reset/sent',
|
|
||||||
'/register',
|
|
||||||
'/account-confirmation',
|
|
||||||
'/account-confirmation/resend',
|
|
||||||
'/account-confirmation/email-sent',
|
|
||||||
]
|
|
||||||
|
|
||||||
const pathsWithoutChecks = ['/email-update', '/about', '/privacy-policy']
|
|
||||||
|
|
||||||
router.beforeEach((to, from, next) => {
|
router.beforeEach((to, from, next) => {
|
||||||
if ('title' in to.meta) {
|
if ('title' in to.meta) {
|
||||||
const title = typeof to.meta.title === 'string' ? to.meta.title : ''
|
const title = typeof to.meta.title === 'string' ? to.meta.title : ''
|
||||||
@ -501,18 +499,18 @@ router.beforeEach((to, from, next) => {
|
|||||||
store
|
store
|
||||||
.dispatch(AUTH_USER_STORE.ACTIONS.CHECK_AUTH_USER)
|
.dispatch(AUTH_USER_STORE.ACTIONS.CHECK_AUTH_USER)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
if (pathsWithoutChecks.includes(to.path)) {
|
if (to.meta.withoutChecks) {
|
||||||
return next()
|
return next()
|
||||||
}
|
}
|
||||||
if (
|
if (
|
||||||
store.getters[AUTH_USER_STORE.GETTERS.IS_AUTHENTICATED] &&
|
store.getters[AUTH_USER_STORE.GETTERS.IS_AUTHENTICATED] &&
|
||||||
pathsWithoutAuthentication.includes(to.path)
|
to.meta.withoutAuth
|
||||||
) {
|
) {
|
||||||
return next('/')
|
return next('/')
|
||||||
}
|
}
|
||||||
if (
|
if (
|
||||||
!store.getters[AUTH_USER_STORE.GETTERS.IS_AUTHENTICATED] &&
|
!store.getters[AUTH_USER_STORE.GETTERS.IS_AUTHENTICATED] &&
|
||||||
!pathsWithoutAuthentication.includes(to.path)
|
!to.meta.withoutAuth
|
||||||
) {
|
) {
|
||||||
const path =
|
const path =
|
||||||
to.path === '/'
|
to.path === '/'
|
||||||
|
Loading…
Reference in New Issue
Block a user