diff --git a/src/client/app/desktop/views/components/ui.header.nav.vue b/src/client/app/desktop/views/components/ui.header.nav.vue index 8e792b3df5..fe2637cec3 100644 --- a/src/client/app/desktop/views/components/ui.header.nav.vue +++ b/src/client/app/desktop/views/components/ui.header.nav.vue @@ -11,7 +11,7 @@
  • %fa:columns% -

    %i18n:@deck%

    +

    %i18n:@deck% (beta)

  • diff --git a/src/client/app/desktop/views/pages/deck/deck.column.vue b/src/client/app/desktop/views/pages/deck/deck.column.vue index e0fc394f33..8d0b3c0fdb 100644 --- a/src/client/app/desktop/views/pages/deck/deck.column.vue +++ b/src/client/app/desktop/views/pages/deck/deck.column.vue @@ -1,10 +1,10 @@ @@ -17,9 +17,23 @@ export default Vue.extend({ components: { XTl }, + provide() { + return { + getColumn() { + return this; + }, + getScrollContainer() { + return this.$refs.body; + } + }; + }, mounted() { this.$nextTick(() => { - this.$refs.tl.mount(this.$refs.body); + this.$emit('mounted'); + + setInterval(() => { + this.$emit('mounted'); + }, 100); }); } }); @@ -31,6 +45,7 @@ export default Vue.extend({ root(isDark) flex 1 min-width 330px + max-width 330px height 100% margin-right 16px background isDark ? #282C37 : #fff @@ -40,14 +55,14 @@ root(isDark) > header z-index 1 - line-height 48px + line-height 42px padding 0 16px color isDark ? #e3e5e8 : #888 background isDark ? #313543 : #fff box-shadow 0 1px rgba(#000, 0.15) > div - height calc(100% - 48px) + height calc(100% - 42px) overflow auto overflow-x hidden diff --git a/src/client/app/desktop/views/pages/deck/deck.notes.vue b/src/client/app/desktop/views/pages/deck/deck.notes.vue index ff871b049d..48be4e585c 100644 --- a/src/client/app/desktop/views/pages/deck/deck.notes.vue +++ b/src/client/app/desktop/views/pages/deck/deck.notes.vue @@ -73,16 +73,20 @@ export default Vue.extend({ } }, + inject: ['getColumn', 'getScrollContainer'], + + created() { + this.getColumn().$once('mounted', () => { + this.rootEl = this.getScrollContainer(); + this.rootEl.addEventListener('scroll', this.onScroll); + }) + }, + beforeDestroy() { - this.root.removeEventListener('scroll', this.onScroll); + this.rootEl.removeEventListener('scroll', this.onScroll); }, methods: { - mount(root) { - this.rootEl = root; - this.rootEl.addEventListener('scroll', this.onScroll); - }, - isScrollTop() { if (this.rootEl == null) return true; return this.rootEl.scrollTop <= 8; diff --git a/src/client/app/desktop/views/pages/deck/deck.tl-column.vue b/src/client/app/desktop/views/pages/deck/deck.tl-column.vue new file mode 100644 index 0000000000..674f04077f --- /dev/null +++ b/src/client/app/desktop/views/pages/deck/deck.tl-column.vue @@ -0,0 +1,33 @@ + + + diff --git a/src/client/app/desktop/views/pages/deck/deck.tl.vue b/src/client/app/desktop/views/pages/deck/deck.tl.vue index ce9a77703f..0a788b32ed 100644 --- a/src/client/app/desktop/views/pages/deck/deck.tl.vue +++ b/src/client/app/desktop/views/pages/deck/deck.tl.vue @@ -14,10 +14,6 @@ export default Vue.extend({ }, props: { - root: { - type: Object, - required: false - }, src: { type: String, required: false, diff --git a/src/client/app/desktop/views/pages/deck/deck.vue b/src/client/app/desktop/views/pages/deck/deck.vue index 0c32b7d665..dfd480029c 100644 --- a/src/client/app/desktop/views/pages/deck/deck.vue +++ b/src/client/app/desktop/views/pages/deck/deck.vue @@ -1,21 +1,20 @@ diff --git a/src/services/note/create.ts b/src/services/note/create.ts index 37d21fecad..f820182a42 100644 --- a/src/services/note/create.ts +++ b/src/services/note/create.ts @@ -221,7 +221,9 @@ export default async (user: IUser, data: { } // Publish note to global timeline stream - publishGlobalTimelineStream(noteObj); + if (note.visibility == 'public' && note.replyId == null) { + publishGlobalTimelineStream(noteObj); + } if (note.visibility == 'specified') { data.visibleUsers.forEach(async u => {