Skip to content
This repository has been archived by the owner on Sep 12, 2023. It is now read-only.

Commit

Permalink
fix(post): update tags on client
Browse files Browse the repository at this point in the history
* using computed property

Co-authored-by: Kenneth Trecy Tobias <19201.tobias.kennethtrecy.c@gmail.com>
  • Loading branch information
lemredd and KennethTrecy committed Nov 23, 2022
1 parent d6b1479 commit 771df46
Show file tree
Hide file tree
Showing 3 changed files with 78 additions and 14 deletions.
17 changes: 14 additions & 3 deletions components/post/multiviewer/viewer/update_post_form.vue
Original file line number Diff line number Diff line change
Expand Up @@ -247,9 +247,20 @@ const roleID = computed<string>({
})
const postID = computed<string>(() => props.modelValue.id)
const tags = ref<DeserializedTagResource[]>([
...props.modelValue.tags.data
])
const tags = computed<DeserializedTagResource[]>({
get(): DeserializedTagResource[] {
return props.modelValue.tags.data
},
set(newValue: DeserializedTagResource[]): void {
emit("update:modelValue", {
...props.modelValue,
"tags": {
...props.modelValue.tags,
"data": newValue
}
})
}
})
const content = computed<string>({
get(): string {
return props.modelValue.content
Expand Down
11 changes: 0 additions & 11 deletions pages/about/index.page.vue

This file was deleted.

64 changes: 64 additions & 0 deletions pages/dev/index.page.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
<template>
<div class="secret-page-container">
<header class="secret-page-header">
<img src="@assets/logo_navbar.svg" class="logo"/>
<h1>This is a secret page.</h1>
</header>
<ul class="contributors">
<h3>
<span>❤️🖤💚🧡</span>
<span>Contributors</span>
<span>🧡💚🖤❤️</span>
</h3>
<li>Angelo Magtoto</li>
<li>Ardrin Gregorio</li>
<li>Jarlem Red De Peralta</li>
<li>John Jerome Pertez</li>
<li>Kenneth Trecy Tobias</li>
</ul>
<p class="description">
This page serves as a countermeasure for plagiarism
if ever this project is cloned without permission.
</p>
</div>
</template>

<style scoped lang="scss">
.secret-page-container {
@apply flex flex-col items-center;
.secret-page-header {
@apply flex flex-col items-center;
.logo {
@apply max-w-36;
}
h1 {
@apply my-4;
@apply text-xl;
}
}
.contributors {
@apply flex flex-col items-center;
h3 {
@apply flex flex-col mb-4;
@screen sm {
@apply flex-row mb-0;
}
}
li {
@apply text-center;
}
}
.description {
@apply my-4;
@apply text-center;
}
}
</style>

<script setup lang="ts"></script>

0 comments on commit 771df46

Please sign in to comment.