Skip to content

Commit f4e2858

Browse files
committed
chore: Set attributes in HTML, not just via component
1 parent 7ea4165 commit f4e2858

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

js/chat/chat.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -448,8 +448,11 @@ class ChatContainer extends LightElement {
448448
if (this.messages.lastChild instanceof ChatStatusMessage) {
449449
if (this.messages.lastChild.type == "dynamic") {
450450
// Update previous status message if last message was a status item
451-
this.messages.lastChild.content = event.detail.content;
452-
this.messages.lastChild.content_type = event.detail.content_type;
451+
this.messages.lastChild.setAttribute("content", event.detail.content);
452+
this.messages.lastChild.setAttribute(
453+
"content_type",
454+
event.detail.content_type
455+
);
453456
return;
454457
}
455458
}

shiny/www/py-shiny/chat/chat.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

shiny/www/py-shiny/chat/chat.js.map

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)