added frontend and updated backend with docker, wrote some initial instructions

This commit is contained in:
Elmar Kresse
2023-09-19 21:34:29 +02:00
parent b8a638a5fe
commit c051995823
87 changed files with 4987 additions and 1574 deletions

View File

@@ -0,0 +1,49 @@
<script lang="ts" setup>
import tokenStore from "../store/tokenStore.ts";
import { useToast } from "primevue/usetoast";
import { onMounted } from "vue";
import router from "../router";
const toast = useToast();
const show = () => {
toast.add({
severity: "info",
summary: "Info",
detail: "Link copied to clipboard",
life: 3000,
});
};
onMounted(() => {
rerouteIfTokenIsEmpty();
});
function rerouteIfTokenIsEmpty() {
if (tokenStore().token == "") {
router.push("/");
}
}
function copyToClipboard() {
const text = "http://localhost:8090/api/feed?token=" + tokenStore().token;
// Copy the text inside the text field
navigator.clipboard.writeText(text);
show();
}
</script>
<template>
<Toast />
<div class="flex flex-column">
<div class="flex align-items-center justify-content-center h-4rem m-2">
<h2>
{{ "http://localhost:8090/api/feed?token=" + tokenStore().token }}
</h2>
</div>
<div class="flex align-items-center justify-content-center h-4rem m-2">
<Button @click="copyToClipboard">Copy iCal Link</Button>
</div>
</div>
</template>
<style scoped></style>