summaryrefslogtreecommitdiff
path: root/src/client/app/desktop/views/components/detail-notes.vue
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/app/desktop/views/components/detail-notes.vue')
-rw-r--r--src/client/app/desktop/views/components/detail-notes.vue56
1 files changed, 56 insertions, 0 deletions
diff --git a/src/client/app/desktop/views/components/detail-notes.vue b/src/client/app/desktop/views/components/detail-notes.vue
new file mode 100644
index 0000000000..e50dda7c6f
--- /dev/null
+++ b/src/client/app/desktop/views/components/detail-notes.vue
@@ -0,0 +1,56 @@
+<template>
+<div class="ecsvsegy" v-if="!fetching">
+ <sequential-entrance animation="entranceFromTop" delay="25">
+ <template v-for="note in notes">
+ <mk-note-detail class="post" :note="note" :key="note.id"/>
+ </template>
+ </sequential-entrance>
+ <div class="more" v-if="more">
+ <ui-button inline @click="fetchMore()">{{ $t('@.load-more') }}</ui-button>
+ </div>
+</div>
+</template>
+
+<script lang="ts">
+import Vue from 'vue';
+import i18n from '../../../i18n';
+import paging from '../../../common/scripts/paging';
+
+export default Vue.extend({
+ i18n: i18n(),
+
+ mixins: [
+ paging({
+ captureWindowScroll: true,
+ }),
+ ],
+
+ props: {
+ pagination: {
+ required: true
+ },
+ extract: {
+ required: false
+ }
+ },
+
+ computed: {
+ notes() {
+ return this.extract ? this.extract(this.items) : this.items;
+ }
+ }
+});
+</script>
+
+<style lang="stylus" scoped>
+.ecsvsegy
+ margin 0 auto
+
+ > * > .post
+ margin-bottom 16px
+
+ > .more
+ margin 32px 16px 16px 16px
+ text-align center
+
+</style>