The force.
This commit is contained in:
parent
431748c489
commit
a55d15b635
@ -47,8 +47,12 @@ class ChatInputComponent extends HTMLElement {
|
|||||||
this.textarea.focus();
|
this.textarea.focus();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
async connectedCallback() {
|
async connectedCallback() {
|
||||||
this.user = await app.rpc.getUser(null);
|
this.user = null
|
||||||
|
app.rpc.getUser(null).then((user) => {
|
||||||
|
this.user=user
|
||||||
|
})
|
||||||
this.liveType = this.getAttribute("live-type") === "true";
|
this.liveType = this.getAttribute("live-type") === "true";
|
||||||
this.liveTypeInterval =
|
this.liveTypeInterval =
|
||||||
parseInt(this.getAttribute("live-type-interval")) || 3;
|
parseInt(this.getAttribute("live-type-interval")) || 3;
|
||||||
@ -152,6 +156,9 @@ class ChatInputComponent extends HTMLElement {
|
|||||||
});
|
});
|
||||||
app.rpc.sendMessage(this.channelUid, message);
|
app.rpc.sendMessage(this.channelUid, message);
|
||||||
});
|
});
|
||||||
|
setTimeout(()=>{
|
||||||
|
this.focus();
|
||||||
|
},1000)
|
||||||
}
|
}
|
||||||
|
|
||||||
trackSecondsBetweenEvents(event1Time, event2Time) {
|
trackSecondsBetweenEvents(event1Time, event2Time) {
|
||||||
|
@ -19,10 +19,14 @@ class MessageList extends HTMLElement {
|
|||||||
this.items = [];
|
this.items = [];
|
||||||
}
|
}
|
||||||
scrollToBottom(force) {
|
scrollToBottom(force) {
|
||||||
|
console.info("Scrolling down")
|
||||||
// if (force) {
|
// if (force) {
|
||||||
this.scrollTop = this.scrollHeight;
|
//this.scrollTop = this.scrollHeight;
|
||||||
//this.querySelector(".message-list-bottom").scrollIntoView();
|
|
||||||
|
this.querySelector(".message-list-bottom").scrollIntoView();
|
||||||
|
setTimeout(() => {
|
||||||
|
this.querySelector(".message-list-bottom").scrollIntoView();
|
||||||
|
},200)
|
||||||
// }
|
// }
|
||||||
}
|
}
|
||||||
updateMessageText(uid, message) {
|
updateMessageText(uid, message) {
|
||||||
|
Loading…
Reference in New Issue
Block a user