Minor fixes
This commit is contained in:
parent
6180a66405
commit
85a2296d56
@ -605,6 +605,8 @@ class ChatElement extends HTMLElement {
|
|||||||
|
|
||||||
if (!chatHeader || !messagesContainer) return;
|
if (!chatHeader || !messagesContainer) return;
|
||||||
|
|
||||||
|
messagesContainer.innerHTML = '';
|
||||||
|
|
||||||
const emojis = await addressToEmoji(pairingProcess);
|
const emojis = await addressToEmoji(pairingProcess);
|
||||||
|
|
||||||
const transaction = db.transaction("labels", "readonly");
|
const transaction = db.transaction("labels", "readonly");
|
||||||
@ -620,8 +622,6 @@ class ChatElement extends HTMLElement {
|
|||||||
chatHeader.textContent = `Chat with member (${emojis})`;
|
chatHeader.textContent = `Chat with member (${emojis})`;
|
||||||
};
|
};
|
||||||
|
|
||||||
messagesContainer.innerHTML = '';
|
|
||||||
|
|
||||||
let dmProcessId = await this.lookForDmProcess();
|
let dmProcessId = await this.lookForDmProcess();
|
||||||
|
|
||||||
if (dmProcessId === null) {
|
if (dmProcessId === null) {
|
||||||
@ -777,6 +777,8 @@ class ChatElement extends HTMLElement {
|
|||||||
|
|
||||||
if (!chatHeader || !messagesContainer) return;
|
if (!chatHeader || !messagesContainer) return;
|
||||||
|
|
||||||
|
messagesContainer.innerHTML = '';
|
||||||
|
|
||||||
const emojis = await addressToEmoji(pairingProcess);
|
const emojis = await addressToEmoji(pairingProcess);
|
||||||
|
|
||||||
const transaction = db.transaction("labels", "readonly");
|
const transaction = db.transaction("labels", "readonly");
|
||||||
@ -785,15 +787,16 @@ class ChatElement extends HTMLElement {
|
|||||||
|
|
||||||
request.onsuccess = () => {
|
request.onsuccess = () => {
|
||||||
const label = request.result;
|
const label = request.result;
|
||||||
|
if (this.selectedMember === pairingProcess) {
|
||||||
chatHeader.textContent = label ? `Chat with ${label.label} (${emojis})` : `Chat with member (${emojis})`;
|
chatHeader.textContent = label ? `Chat with ${label.label} (${emojis})` : `Chat with member (${emojis})`;
|
||||||
|
}
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
request.onerror = () => {
|
request.onerror = () => {
|
||||||
chatHeader.textContent = `Chat with member (${emojis})`;
|
chatHeader.textContent = `Chat with member (${emojis})`;
|
||||||
};
|
};
|
||||||
|
|
||||||
messagesContainer.innerHTML = '';
|
|
||||||
|
|
||||||
let dmProcessId = await this.processId;
|
let dmProcessId = await this.processId;
|
||||||
|
|
||||||
// Récupérer les messages depuis les états du processus
|
// Récupérer les messages depuis les états du processus
|
||||||
|
Loading…
x
Reference in New Issue
Block a user