add basic support for custom emoji

This commit is contained in:
りき萌 2023-08-27 18:25:21 +02:00
parent dccfddaec1
commit d794e88bdc
10 changed files with 163 additions and 12 deletions

View file

@ -237,3 +237,10 @@ nav .logo {
opacity: 100%;
color: var(--text-color);
}
/* Style emojis to be readable */
img.emoji {
max-height: 1.375em;
vertical-align: bottom;
}

BIN
static/emoji/hueh.png Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

View file

@ -135,6 +135,7 @@ async function navigateToBranch(fragment) {
let [_root, ...path] = fullPath;
if (path !== undefined) {
let isNotAtIndexHtml = window.location.pathname != "/index.html";
let lastBranch = null;
for (let linked of path) {
let branch = LinkedBranch.byLink.get(linked);
@ -144,7 +145,10 @@ async function navigateToBranch(fragment) {
}
await branch.loadTree("navigateToBranch");
branch.details.open = true;
lastBranch = branch;
}
if (lastBranch != null) {
expandDetailsRecursively(lastBranch.details);
}
window.location.hash = window.location.hash;
}