async function generateSpans(text) {
const tokens = encode(text).slice(1);
const htmlPromises = tokens.map(async (t) => {
let text = decode([1, t]);
return `<span style="
padding: 3px;
border-right: 3px solid white;
line-height: 3em;
font-family: courier;
background-color: ${await stringToPastelColor(text)};
position: relative;
"><span style="position: absolute; top: 5.5ch; line-height: 1em; left: -0.5px; font-size: 0.45em">${t}</span>${text}</span>`;
});
const html = await Promise.all(htmlPromises);
return html.join("");
}