fix icons size and message update formatting & add missing blahs
This commit is contained in:
parent
0a20562d9f
commit
50ebf57b4c
16 changed files with 132 additions and 104 deletions
|
|
@ -2598,8 +2598,18 @@ async function renderMessages(messages, isPrepend = false) {
|
|||
|
||||
let oldText = existingChild.querySelector('.chat-message-text');
|
||||
let newText = newChild.querySelector('.chat-message-text');
|
||||
if (oldText && newText && oldText.innerHTML !== newText.innerHTML) {
|
||||
oldText.innerHTML = newText.innerHTML;
|
||||
if (oldText && newText) {
|
||||
if (oldText.innerHTML !== newText.innerHTML) {
|
||||
oldText.innerHTML = newText.innerHTML;
|
||||
}
|
||||
if (oldText.getAttribute('style') !== newText.getAttribute('style')) {
|
||||
let newStyle = newText.getAttribute('style');
|
||||
if (newStyle) {
|
||||
oldText.setAttribute('style', newStyle);
|
||||
} else {
|
||||
oldText.removeAttribute('style');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
let oldReactions = existingChild.querySelector('.chat-message-reactions');
|
||||
|
|
@ -3218,7 +3228,7 @@ async function loadEmotes() {
|
|||
|
||||
reactionPickerMenuHtml = `
|
||||
<div style="display: flex; flex-direction: column; gap: 0.4rem; padding: 0.2rem; min-width: 14rem;">
|
||||
<input type="text" id="reaction-picker-search" placeholder="Type text / emoji..." oninput="filterReactions(this.value)" onkeydown="if(event.key === 'Enter') { if(this.value.trim() !== '') reactMessagePrompt(currentContextMenuMsgId, encodeURIComponent(this.value)); }" style="width: auto; align-self: stretch; margin: 0; box-sizing: border-box; padding: 0.5rem 0.6rem; border-radius: 0.65rem; border: var(--border-width) solid var(--light-border-color); background: transparent; color: var(--text-color); font-family: inherit;">
|
||||
<input type="text" id="reaction-picker-search" placeholder="{blah(placeholder.type.text.emoji)}" oninput="filterReactions(this.value)" onkeydown="if(event.key === 'Enter') { if(this.value.trim() !== '') reactMessagePrompt(currentContextMenuMsgId, encodeURIComponent(this.value)); }" style="width: auto; align-self: stretch; margin: 0; box-sizing: border-box; padding: 0.5rem 0.6rem; border-radius: 0.65rem; border: var(--border-width) solid var(--light-border-color); background: transparent; color: var(--text-color); font-family: inherit;">
|
||||
<div id="reaction-picker-grid" style="display: grid; grid-template-columns: repeat(5, 1fr); gap: 0.2rem; max-height: 12rem; overflow-y: auto; overflow-x: hidden;">
|
||||
${loadedEmotes.map(emoji => `<button onclick="reactMessagePrompt(currentContextMenuMsgId, encodeURIComponent('${emoji.char}'))" data-name="${emoji.name}" style="min-width: unset; width: 100%; aspect-ratio: 1; display: flex; justify-content: center; align-items: center; padding: 0; font-size: 1.2rem; border-radius: 0.65rem;" class="reaction-emoji-btn">${emoji.char}</button>`).join('')}
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue