π The open-source, offline-first Notion, Obsidian & Confluence alternative. Advanced Markdown, multi-tenant teams, OIDC/SSO, and local S3 backups. Deploy in one command.
Vue dockergolangkanbanknowledge-baseknowledge-managementmarkdownnote-takingnotesnotes-appnotionnuxtnuxtjsoffline-firstoidcpwaselfhostedssovuevuejswiki
Improvments
Smaug6739e15929e7e9d6
diff --git a/frontend/components/DataTable.vue b/frontend/components/DataTable.vueindex 091fbadf..afa9b0f2 100644--- a/frontend/components/DataTable.vue+++ b/frontend/components/DataTable.vue@@ -25,21 +25,28 @@<tr v-for="row in data"><td v-for="header in headers"><span v-if="row[header.key]?.type === 'html'" v-html="row[header.key]?.content"></span>- <NuxtLink v-else-if="row[header.key]?.type === 'link'" v-html="row[header.key]?.content" :to="row[header.key]?.to"></NuxtLink>+ <NuxtLink v-else-if="row[header.key]?.type === 'link'" v-html="row[header.key]?.content"+ :to="row[header.key]?.to"></NuxtLink><span v-else v-text="row[header.key]?.content"></span></td></tr><tr><td colspan="100%"><div class="footer">- <p>Showing {{ paginator.startIndex.value }} to {{ paginator.endIndex.value }} of {{ paginator.totalItems.value }} entries</p>+ <p>Showing {{ paginator.startIndex.value }} to {{ paginator.endIndex.value }} of {{+ paginator.totalItems.value }} entries</p><div class="pagination"><button type="button" @click="paginator.previous()" :disabled="!paginator.hasPrevious()"><</button>- <button v-if="shouldShowPage(1)" @click="paginator.setPage(1)" :class="{ active: paginator.currentPage.value === 1 }">1</button>+ <button v-if="shouldShowPage(1)" @click="paginator.setPage(1)"+ :class="{ active: paginator.currentPage.value === 1 }">1</button><span v-if="shouldShowEllipsisBefore" class="ellipsis">...</span>- <button v-for="page in visiblePages" :key="page" @click="paginator.setPage(page)" :class="{ active: paginator.currentPage.value === page }">{{ page }}</button>+ <button v-for="page in visiblePages" :key="page" @click="paginator.setPage(page)"+ :class="{ active: paginator.currentPage.value === page }">{{ page }}</button><span v-if="shouldShowEllipsisAfter" class="ellipsis">...</span>- <button v-if="shouldShowPage(paginator.totalPages.value)" @click="paginator.setPage(paginator.totalPages.value)" :class="{ active: paginator.currentPage.value === paginator.totalPages.value }">{{ paginator.totalPages.value }}</button>+ <button v-if="shouldShowPage(paginator.totalPages.value)"+ @click="paginator.setPage(paginator.totalPages.value)"+ :class="{ active: paginator.currentPage.value === paginator.totalPages.value }">{{+ paginator.totalPages.value }}</button><button type="button" @click="paginator.next()" :disabled="!paginator.hasNext()">></button></div></div>@@ -49,6 +56,7 @@</table></div></template>+<script lang="ts" setup>import { Paginator } from '../helpers/paginator';const props = defineProps<{ headers: Header[]; rows: Field[] }>();diff --git a/frontend/components/Notification/Notification.vue b/frontend/components/Notification.vuesimilarity index 100%rename from frontend/components/Notification/Notification.vuerename to frontend/components/Notification.vuediff --git a/frontend/pages/dashboard.vue b/frontend/pages/dashboard.vueindex 4391b1f1..edfba336 100644--- a/frontend/pages/dashboard.vue+++ b/frontend/pages/dashboard.vue@@ -9,5 +9,5 @@</template><script setup lang="ts">import Sidebar from '~/components/sidebar/Sidebar.vue';-definePageMeta({ breadcrumb: 'Dashboard' });+definePageMeta({ breadcrumb: 'Home' });</script>\ No newline at end of filediff --git a/frontend/pages/dashboard/docs/index.vue b/frontend/pages/dashboard/docs/index.vueindex 0bc77e32..584d35b0 100644--- a/frontend/pages/dashboard/docs/index.vue+++ b/frontend/pages/dashboard/docs/index.vue@@ -16,7 +16,7 @@ const headers = [{ label: 'Status', key: 'status' },{ label: 'Actions', key: 'actions' },];-const rows = computed(() => documents.value.map((doc) => {+const rows: any = computed(() => documents.value.map((doc) => {let badges = '';switch (doc.accessibility) {case 1:@@ -36,7 +36,7 @@ const rows = computed(() => documents.value.map((doc) => {name: { content: doc.name, type: 'link', to: `/dashboard/docs/${doc.id}` },category: { content: categoriesStore.getById(doc.category || '')?.name || '' },tags: { content: doc.tags?.trim().length ? doc.tags?.trim().split(',').map(t => `<span class="tag blue">${t.trim()}</span>`).join('') : '', type: 'html' },- last_update: { content: new Date(parseInt(doc.updated_timestamp)).toDateString() },+ last_update: { content: new Date(parseInt(doc.updated_timestamp)).toLocaleDateString() },status: { content: badges, type: 'html' },actions: { content: seeIcon + editIcon, type: 'link', to: `/dashboard/docs/${doc.id}` },};