webui rm shadowRoot references
diff --git a/webui/src/web-components/sketch-timeline-message.ts b/webui/src/web-components/sketch-timeline-message.ts
index 26246b2..a56911a 100644
--- a/webui/src/web-components/sketch-timeline-message.ts
+++ b/webui/src/web-components/sketch-timeline-message.ts
@@ -395,7 +395,7 @@
// Add a small delay to ensure the DOM is fully rendered
setTimeout(async () => {
// Find all mermaid containers in our shadow root
- const containers = this.shadowRoot?.querySelectorAll(".mermaid");
+ const containers = this.querySelectorAll(".mermaid");
if (!containers || containers.length === 0) return;
try {
@@ -453,8 +453,7 @@
setupCodeBlockCopyButtons() {
setTimeout(() => {
// Find all copy buttons in code blocks
- const copyButtons =
- this.shadowRoot?.querySelectorAll(".code-copy-button");
+ const copyButtons = this.querySelectorAll(".code-copy-button");
if (!copyButtons || copyButtons.length === 0) return;
// Add click event listener to each button
@@ -464,7 +463,7 @@
const codeId = (button as HTMLElement).dataset.codeId;
if (!codeId) return;
- const codeElement = this.shadowRoot?.querySelector(`#${codeId}`);
+ const codeElement = this.querySelector(`#${codeId}`);
if (!codeElement) return;
const codeText = codeElement.textContent || "";