Storage improve (#6976)

* wip

* wip

* wip

* wip

* wip

* Update storage.ts

* wip

* wip

* wip

* wip

* Update storage.ts

* Update storage.ts

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* Update storage.ts

* wip

* wip

* wip

* wip

* 🍕

* wip

* wip

* wip

* wip

* wip

* wip

* Update deck-storage.ts

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* Update store.ts

* wip

* wip

* wip

* wip

* Update init.ts

* wip

* wip

* Update pizzax.ts

* wip

* wip

* Update timeline.vue

* Update init.ts

* wip

* wip

* Update init.ts
This commit is contained in:
syuilo
2020-12-19 10:55:52 +09:00
committed by GitHub
parent 57d0c19a98
commit 43930e6a84
146 changed files with 1458 additions and 1519 deletions

View File

@@ -110,7 +110,7 @@ const Component = defineComponent({
mounted() {
this.fetch();
if (this.$store.state.device.enableInfiniteScroll) {
if (this.$store.state.enableInfiniteScroll) {
this.$nextTick(() => this.ilObserver.observe(this.$refs.loadMore as Element));
}
},
@@ -224,7 +224,7 @@ const Component = defineComponent({
const _isBottom = isBottom(this.$el, 64);
this.messages.push(message);
if (message.userId != this.$store.state.i.id && !document.hidden) {
if (message.userId != this.$i.id && !document.hidden) {
this.connection.send('read', {
id: message.id
});
@@ -235,7 +235,7 @@ const Component = defineComponent({
this.$nextTick(() => {
this.scrollToBottom();
});
} else if (message.userId != this.$store.state.i.id) {
} else if (message.userId != this.$i.id) {
// Notify
this.notifyNewMessage();
}
@@ -299,7 +299,7 @@ const Component = defineComponent({
onVisibilitychange() {
if (document.hidden) return;
for (const message of this.messages) {
if (message.userId !== this.$store.state.i.id && !message.isRead) {
if (message.userId !== this.$i.id && !message.isRead) {
this.connection.send('read', {
id: message.id
});