ssb: Tried to do the right lit things to prevent unnecessary re-rendering. Ended up doing a lazy JSON thing.
All checks were successful
Build Tilde Friends / Build-All (push) Successful in 26m48s

This commit is contained in:
2025-01-11 14:09:42 -05:00
parent 02759c6f83
commit aa15da50ab
5 changed files with 17 additions and 12 deletions

View File

@ -1,4 +1,4 @@
import {LitElement, html, render, unsafeHTML} from './lit-all.min.js';
import {LitElement, html, repeat, render, unsafeHTML} from './lit-all.min.js';
import * as tfrpc from '/static/tfrpc.js';
import * as tfutils from './tf-utils.js';
import * as emojis from './emojis.js';
@ -313,7 +313,9 @@ class TfMessageElement extends LitElement {
@click=${() => self.set_expanded(false)}
>
Collapse</button
>${(this.message.child_messages || []).map(
>${repeat(
this.message.child_messages || [],
(x) => x.id,
(x) =>
html`<tf-message
.message=${x}