Introduce group basic federation, event new page and notifications
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
58
js/src/views/Todos/Todo.vue
Normal file
58
js/src/views/Todos/Todo.vue
Normal file
@@ -0,0 +1,58 @@
|
||||
<template>
|
||||
<section class="section container" v-if="todo">
|
||||
<nav class="breadcrumb" aria-label="breadcrumbs">
|
||||
<ul>
|
||||
<li>
|
||||
<router-link
|
||||
:to="{
|
||||
name: RouteName.GROUP,
|
||||
params: { preferredUsername: todo.todoList.actor.preferredUsername },
|
||||
}"
|
||||
>{{ todo.todoList.actor.preferredUsername }}</router-link
|
||||
>
|
||||
</li>
|
||||
<li>
|
||||
<router-link :to="{ name: RouteName.TODO_LIST, params: { id: todo.todoList.id } }">
|
||||
{{ todo.todoList.title }}
|
||||
</router-link>
|
||||
</li>
|
||||
<li class="is-active">
|
||||
<router-link :to="{ name: RouteName.TODO }" aria-current="page">
|
||||
{{ todo.title }}
|
||||
</router-link>
|
||||
</li>
|
||||
</ul>
|
||||
</nav>
|
||||
<full-todo :todo="todo" />
|
||||
</section>
|
||||
</template>
|
||||
<script lang="ts">
|
||||
import { Component, Prop, Vue } from "vue-property-decorator";
|
||||
import { GET_TODO } from "@/graphql/todos";
|
||||
import { ITodo } from "@/types/todos";
|
||||
import FullTodo from "@/components/Todo/FullTodo.vue";
|
||||
import RouteName from "../../router/name";
|
||||
|
||||
@Component({
|
||||
components: {
|
||||
FullTodo,
|
||||
},
|
||||
apollo: {
|
||||
todo: {
|
||||
query: GET_TODO,
|
||||
variables() {
|
||||
return {
|
||||
id: this.$route.params.todoId,
|
||||
};
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
export default class Todo extends Vue {
|
||||
@Prop({ type: String, required: true }) todoId!: string;
|
||||
|
||||
todo!: ITodo;
|
||||
|
||||
RouteName = RouteName;
|
||||
}
|
||||
</script>
|
||||
Reference in New Issue
Block a user