mirror of
https://github.com/Drop-OSS/drop-app.git
synced 2025-11-14 00:31:33 +10:00
slight ui/ux fixes and updates to auth protocol
This commit is contained in:
@ -10,12 +10,18 @@
|
||||
</NuxtLink>
|
||||
<nav class="inline-flex items-center mt-0.5">
|
||||
<ol class="inline-flex items-center gap-x-6">
|
||||
<li
|
||||
class="transition text-zinc-300 hover:text-zinc-100 uppercase font-display font-semibold text-md"
|
||||
<NuxtLink
|
||||
v-for="(nav, navIdx) in navigation"
|
||||
:class="[
|
||||
'transition uppercase font-display font-semibold text-md',
|
||||
navIdx === currentPageIndex
|
||||
? 'text-zinc-100'
|
||||
: 'text-zinc-400 hover:text-zinc-200',
|
||||
]"
|
||||
:href="nav.route"
|
||||
>
|
||||
{{ nav.label }}
|
||||
</li>
|
||||
</NuxtLink>
|
||||
</ol>
|
||||
</nav>
|
||||
</div>
|
||||
@ -68,6 +74,8 @@ const navigation: Array<NavigationItem> = [
|
||||
},
|
||||
];
|
||||
|
||||
const currentPageIndex = useCurrentNavigationIndex(navigation);
|
||||
|
||||
const quickActions: Array<QuickActionNav> = [
|
||||
{
|
||||
icon: UserGroupIcon,
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
<template>{{state}}</template>
|
||||
<template />
|
||||
|
||||
<script setup lang="ts">
|
||||
const state = useAppState();
|
||||
</script>
|
||||
const router = useRouter();
|
||||
router.replace("/store");
|
||||
</script>
|
||||
|
||||
3
pages/store/index.vue
Normal file
3
pages/store/index.vue
Normal file
@ -0,0 +1,3 @@
|
||||
<template>
|
||||
|
||||
</template>
|
||||
@ -1,8 +1,9 @@
|
||||
use core::time;
|
||||
use std::{
|
||||
borrow::{Borrow, BorrowMut},
|
||||
env,
|
||||
fmt::format,
|
||||
sync::Mutex,
|
||||
sync::Mutex, time::{SystemTime, UNIX_EPOCH},
|
||||
};
|
||||
|
||||
use log::{info, warn};
|
||||
@ -69,7 +70,12 @@ pub fn generate_authorization_header() -> String {
|
||||
db.auth.clone().unwrap()
|
||||
};
|
||||
|
||||
let nonce = Uuid::new_v4().to_string();
|
||||
let start = SystemTime::now();
|
||||
let timestamp = start
|
||||
.duration_since(UNIX_EPOCH)
|
||||
.expect("Time went backwards");
|
||||
let nonce = timestamp.as_millis().to_string();
|
||||
|
||||
let signature = sign_nonce(certs.private, nonce.clone()).unwrap();
|
||||
|
||||
return format!("Nonce {} {} {}", certs.clientId, nonce, signature);
|
||||
|
||||
Reference in New Issue
Block a user