better nav back handling & replace call and pin icons
This commit is contained in:
parent
9968e7fd20
commit
def660e8a0
4 changed files with 38 additions and 8 deletions
|
|
@ -1513,6 +1513,21 @@ if (App) {
|
|||
}
|
||||
|
||||
function popstate() {
|
||||
if (fixedContextMenu && fixedContextMenu.classList.contains("show")) {
|
||||
fixedContextMenu.classList.remove("show");
|
||||
if (typeof clearContextMenuStyles === "function") clearContextMenuStyles();
|
||||
if (typeof setActiveSidebarIndicator === "function" && typeof currentMainIndicator !== "undefined") {
|
||||
setActiveSidebarIndicator(currentMainIndicator);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
let cropperPopup = document.getElementById("cropper-popup-container");
|
||||
if (cropperPopup && cropperPopup.classList.contains("show")) {
|
||||
cropperPopup.classList.remove("show");
|
||||
return;
|
||||
}
|
||||
|
||||
if (isProfileOpen) {
|
||||
closeProfile();
|
||||
return;
|
||||
|
|
@ -2561,7 +2576,8 @@ async function renderMessages(messages, isPrepend = false) {
|
|||
let style = rxCounts[rxVal].me ? "background: rgba(255, 255, 255, 0.12); border-color: var(--text-color);" : "background: rgba(255, 255, 255, 0.06);";
|
||||
let safeRx = encodeURIComponent(rxVal).replace(/'/g, "%27");
|
||||
let escapedRxVal = escapeHtml(rxVal);
|
||||
reactionsHtml += `<span class="reaction-pill" style="padding: 0.1rem 0.4rem; border-radius: 1rem; font-size: 0.85rem; border: var(--border-width) solid var(--light-border-color); cursor: pointer; ${style}" onclick="reactMessagePrompt('${msgId}', '${safeRx}')">${processBlah(escapedRxVal)} ${rxCounts[rxVal].count > 1 ? rxCounts[rxVal].count : ""}</span>`;
|
||||
let pillStyle = `display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.1rem 0.45rem; border-radius: 1rem; font-size: 0.85rem; border: var(--border-width) solid var(--light-border-color); cursor: pointer; ${style}`;
|
||||
reactionsHtml += `<span class="reaction-pill" style="${pillStyle}" onclick="reactMessagePrompt('${msgId}', '${safeRx}')"><span>${processBlah(escapedRxVal)}</span>${rxCounts[rxVal].count > 1 ? `<span style="opacity: 0.5;">${rxCounts[rxVal].count}</span>` : ""}</span>`;
|
||||
}
|
||||
reactionsHtml += `</div>`;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue