Prettier.
diff --git a/loop/webui/src/web-components/aggregateAgentMessages.ts b/loop/webui/src/web-components/aggregateAgentMessages.ts
index 2fbd435..3dc11f8 100644
--- a/loop/webui/src/web-components/aggregateAgentMessages.ts
+++ b/loop/webui/src/web-components/aggregateAgentMessages.ts
@@ -2,7 +2,8 @@
export function aggregateAgentMessages(
arr1: AgentMessage[],
- arr2: AgentMessage[]): AgentMessage[] {
+ arr2: AgentMessage[],
+): AgentMessage[] {
const mergedArray = [...arr1, ...arr2];
const seenIds = new Set<number>();
const toolCallResults = new Map<string, AgentMessage>();
diff --git a/loop/webui/src/web-components/demo/sketch-chat-input.demo.html b/loop/webui/src/web-components/demo/sketch-chat-input.demo.html
index e76aed7..afc79fb 100644
--- a/loop/webui/src/web-components/demo/sketch-chat-input.demo.html
+++ b/loop/webui/src/web-components/demo/sketch-chat-input.demo.html
@@ -2,8 +2,7 @@
<head>
<title>sketch-chat-input demo</title>
<link rel="stylesheet" href="demo.css" />
- <script type="module" src="../sketch-chat-input.ts"
- ></script>
+ <script type="module" src="../sketch-chat-input.ts"></script>
<script>
document.addEventListener("DOMContentLoaded", () => {
diff --git a/loop/webui/src/web-components/demo/sketch-container-status.demo.html b/loop/webui/src/web-components/demo/sketch-container-status.demo.html
index e18440d..0945d70 100644
--- a/loop/webui/src/web-components/demo/sketch-container-status.demo.html
+++ b/loop/webui/src/web-components/demo/sketch-container-status.demo.html
@@ -2,8 +2,7 @@
<head>
<title>sketch-container-status demo</title>
<link rel="stylesheet" href="demo.css" />
- <script type="module" src="../sketch-container-status.ts"
- ></script>
+ <script type="module" src="../sketch-container-status.ts"></script>
<script>
document.addEventListener("DOMContentLoaded", () => {
diff --git a/loop/webui/src/web-components/demo/sketch-diff-view.demo.html b/loop/webui/src/web-components/demo/sketch-diff-view.demo.html
index 1dc9337..6ab6e62 100644
--- a/loop/webui/src/web-components/demo/sketch-diff-view.demo.html
+++ b/loop/webui/src/web-components/demo/sketch-diff-view.demo.html
@@ -8,9 +8,7 @@
rel="stylesheet"
href="../../../node_modules/diff2html/bundles/css/diff2html.min.css"
/>
- <script
- type="module" src="../sketch-diff-view.ts"
- ></script>
+ <script type="module" src="../sketch-diff-view.ts"></script>
<style>
body {
font-family:
diff --git a/loop/webui/src/web-components/demo/sketch-network-status.demo.html b/loop/webui/src/web-components/demo/sketch-network-status.demo.html
index 04c118c..f248a5d 100644
--- a/loop/webui/src/web-components/demo/sketch-network-status.demo.html
+++ b/loop/webui/src/web-components/demo/sketch-network-status.demo.html
@@ -2,8 +2,7 @@
<head>
<title>sketch-network-status demo</title>
<link rel="stylesheet" href="demo.css" />
- <script type="module" src="../sketch-network-status.ts"
- ></script>
+ <script type="module" src="../sketch-network-status.ts"></script>
</head>
<body>
<h1>sketch-network-status demo</h1>
diff --git a/loop/webui/src/web-components/demo/sketch-timeline-message.demo.html b/loop/webui/src/web-components/demo/sketch-timeline-message.demo.html
index a97145e..a8f35d4 100644
--- a/loop/webui/src/web-components/demo/sketch-timeline-message.demo.html
+++ b/loop/webui/src/web-components/demo/sketch-timeline-message.demo.html
@@ -2,8 +2,7 @@
<head>
<title>sketch-timeline-message demo</title>
<link rel="stylesheet" href="demo.css" />
- <script type="module" src="../sketch-timeline-message.ts"
- ></script>
+ <script type="module" src="../sketch-timeline-message.ts"></script>
<script>
const messages = [
diff --git a/loop/webui/src/web-components/demo/sketch-timeline.demo.html b/loop/webui/src/web-components/demo/sketch-timeline.demo.html
index 58abdb2..ddec327 100644
--- a/loop/webui/src/web-components/demo/sketch-timeline.demo.html
+++ b/loop/webui/src/web-components/demo/sketch-timeline.demo.html
@@ -2,8 +2,7 @@
<head>
<title>sketch-timeline demo</title>
<link rel="stylesheet" href="demo.css" />
- <script type="module" src="../sketch-timeline.ts"
- ></script>
+ <script type="module" src="../sketch-timeline.ts"></script>
<script>
const messages = [
{
diff --git a/loop/webui/src/web-components/demo/sketch-tool-calls.demo.html b/loop/webui/src/web-components/demo/sketch-tool-calls.demo.html
index 7bedf11..e6ea669 100644
--- a/loop/webui/src/web-components/demo/sketch-tool-calls.demo.html
+++ b/loop/webui/src/web-components/demo/sketch-tool-calls.demo.html
@@ -3,8 +3,7 @@
<title>sketch-tool-calls demo</title>
<link rel="stylesheet" href="demo.css" />
- <script type="module" src="../sketch-tool-calls.ts"
- ></script>
+ <script type="module" src="../sketch-tool-calls.ts"></script>
<script>
const toolCalls = [
diff --git a/loop/webui/src/web-components/demo/sketch-tool-card.demo.html b/loop/webui/src/web-components/demo/sketch-tool-card.demo.html
index 3926f2e..2f887df 100644
--- a/loop/webui/src/web-components/demo/sketch-tool-card.demo.html
+++ b/loop/webui/src/web-components/demo/sketch-tool-card.demo.html
@@ -3,8 +3,7 @@
<title>sketch-tool-card demo</title>
<link rel="stylesheet" href="demo.css" />
- <script type="module" src="../sketch-tool-card.ts"
- ></script>
+ <script type="module" src="../sketch-tool-card.ts"></script>
<script>
const toolCalls = [
diff --git a/loop/webui/src/web-components/demo/sketch-view-mode-select.demo.html b/loop/webui/src/web-components/demo/sketch-view-mode-select.demo.html
index af2f1fb..0068616 100644
--- a/loop/webui/src/web-components/demo/sketch-view-mode-select.demo.html
+++ b/loop/webui/src/web-components/demo/sketch-view-mode-select.demo.html
@@ -3,8 +3,7 @@
<title>sketch-view-mode-select demo</title>
<link rel="stylesheet" href="demo.css" />
- <script type="module" src="../sketch-view-mode-select.ts"
- ></script>
+ <script type="module" src="../sketch-view-mode-select.ts"></script>
<script>
document.addEventListener("DOMContentLoaded", () => {
diff --git a/loop/webui/src/web-components/sketch-app-shell.ts b/loop/webui/src/web-components/sketch-app-shell.ts
index 3350cac..7560bd6 100644
--- a/loop/webui/src/web-components/sketch-app-shell.ts
+++ b/loop/webui/src/web-components/sketch-app-shell.ts
@@ -227,11 +227,11 @@
// register event listeners
this.dataManager.addEventListener(
"dataChanged",
- this.handleDataChanged.bind(this)
+ this.handleDataChanged.bind(this),
);
this.dataManager.addEventListener(
"connectionStatusChanged",
- this.handleConnectionStatusChanged.bind(this)
+ this.handleConnectionStatusChanged.bind(this),
);
// Initialize the data manager
@@ -251,11 +251,11 @@
// unregister data manager event listeners
this.dataManager.removeEventListener(
"dataChanged",
- this.handleDataChanged.bind(this)
+ this.handleDataChanged.bind(this),
);
this.dataManager.removeEventListener(
"connectionStatusChanged",
- this.handleConnectionStatusChanged.bind(this)
+ this.handleConnectionStatusChanged.bind(this),
);
// Disconnect mutation observer if it exists
@@ -277,7 +277,7 @@
if (mode !== "chat") {
url.searchParams.set("view", mode);
const diffView = this.shadowRoot?.querySelector(
- ".diff-view"
+ ".diff-view",
) as SketchDiffView;
// If in diff view and there's a commit hash, include that too
@@ -414,7 +414,7 @@
// Update view mode buttons
const viewModeSelect = this.shadowRoot?.querySelector(
- "sketch-view-mode-select"
+ "sketch-view-mode-select",
);
if (viewModeSelect) {
const event = new CustomEvent("update-active-mode", {
@@ -464,14 +464,14 @@
// Log information about the message update
if (this.messages.length > oldMessageCount) {
console.log(
- `Auto-scroll: Messages updated from ${oldMessageCount} to ${this.messages.length}`
+ `Auto-scroll: Messages updated from ${oldMessageCount} to ${this.messages.length}`,
);
}
}
private handleConnectionStatusChanged(
status: ConnectionStatus,
- errorMessage?: string
+ errorMessage?: string,
): void {
this.connectionStatus = status;
this.connectionErrorMessage = errorMessage || "";
@@ -601,11 +601,11 @@
// Initial scroll to bottom when component is first rendered
setTimeout(
() => this.scrollTo({ top: this.scrollHeight, behavior: "smooth" }),
- 50
+ 50,
);
const pollToggleCheckbox = this.renderRoot?.querySelector(
- "#pollToggle"
+ "#pollToggle",
) as HTMLInputElement;
pollToggleCheckbox?.addEventListener("change", () => {
this.dataManager.setPollingEnabled(pollToggleCheckbox.checked);
diff --git a/loop/webui/src/web-components/sketch-chat-input.test.ts b/loop/webui/src/web-components/sketch-chat-input.test.ts
index 6dd946a..efb303f 100644
--- a/loop/webui/src/web-components/sketch-chat-input.test.ts
+++ b/loop/webui/src/web-components/sketch-chat-input.test.ts
@@ -56,7 +56,7 @@
(event) => {
resolve((event as CustomEvent).detail);
},
- { once: true }
+ { once: true },
);
});
});
@@ -87,7 +87,7 @@
(event) => {
resolve((event as CustomEvent).detail);
},
- { once: true }
+ { once: true },
);
});
});
@@ -144,7 +144,7 @@
},
});
const origHeight = await component.evaluate(
- (el: SketchChatInput) => el.chatInput.style.height
+ (el: SketchChatInput) => el.chatInput.style.height,
);
// Enter very tall text in the textarea
@@ -155,9 +155,9 @@
// Check that textarea resized
const newHeight = await component.evaluate(
- (el: SketchChatInput) => el.chatInput.style.height
+ (el: SketchChatInput) => el.chatInput.style.height,
);
expect(Number.parseInt(newHeight)).toBeGreaterThan(
- Number.parseInt(origHeight)
+ Number.parseInt(origHeight),
);
});
diff --git a/loop/webui/src/web-components/sketch-diff-view.ts b/loop/webui/src/web-components/sketch-diff-view.ts
index ba20816..47c14f3 100644
--- a/loop/webui/src/web-components/sketch-diff-view.ts
+++ b/loop/webui/src/web-components/sketch-diff-view.ts
@@ -190,7 +190,7 @@
if (!response.ok) {
console.error(
- `Failed to load diff2html CSS: ${response.status} ${response.statusText}`
+ `Failed to load diff2html CSS: ${response.status} ${response.statusText}`,
);
return;
}
@@ -240,7 +240,7 @@
if (!response.ok) {
throw new Error(
- `Server returned ${response.status}: ${response.statusText}`
+ `Server returned ${response.status}: ${response.statusText}`,
);
}
@@ -367,7 +367,7 @@
// Target code lines first, then find their parent rows
const codeLines = diff2htmlContent.querySelectorAll(
- ".d2h-code-side-line, .d2h-code-line"
+ ".d2h-code-side-line, .d2h-code-line",
);
// Create a Set to store unique rows to avoid duplicates
@@ -392,7 +392,7 @@
// Find the code line number element (first TD in the row)
const lineNumberCell = rowElem.querySelector(
- ".d2h-code-side-linenumber, .d2h-code-linenumber"
+ ".d2h-code-side-linenumber, .d2h-code-linenumber",
);
if (!lineNumberCell) return;
@@ -460,7 +460,7 @@
// Reset the comment input
const commentInput = this.shadowRoot?.getElementById(
- "diffCommentInput"
+ "diffCommentInput",
) as HTMLTextAreaElement;
if (commentInput) {
commentInput.value = "";
@@ -473,13 +473,18 @@
if (row) {
// Get the position of the row
const rowRect = row.getBoundingClientRect();
- const diffContainerRect = this.shadowRoot?.querySelector(".diff-container")?.getBoundingClientRect();
-
+ const diffContainerRect = this.shadowRoot
+ ?.querySelector(".diff-container")
+ ?.getBoundingClientRect();
+
if (diffContainerRect) {
// Position the comment box below the row
- const topPosition = rowRect.bottom - diffContainerRect.top + this.shadowRoot!.querySelector(".diff-container")!.scrollTop;
+ const topPosition =
+ rowRect.bottom -
+ diffContainerRect.top +
+ this.shadowRoot!.querySelector(".diff-container")!.scrollTop;
const leftPosition = rowRect.left - diffContainerRect.left;
-
+
commentBox.style.top = `${topPosition}px`;
commentBox.style.left = `${leftPosition}px`;
commentBox.style.display = "block";
@@ -527,7 +532,7 @@
*/
private submitDiffComment(): void {
const commentInput = this.shadowRoot?.getElementById(
- "diffCommentInput"
+ "diffCommentInput",
) as HTMLTextAreaElement;
if (!commentInput) return;
diff --git a/loop/webui/src/web-components/sketch-terminal.ts b/loop/webui/src/web-components/sketch-terminal.ts
index 78f1c12..4ffccfd 100644
--- a/loop/webui/src/web-components/sketch-terminal.ts
+++ b/loop/webui/src/web-components/sketch-terminal.ts
@@ -92,7 +92,7 @@
if (!response.ok) {
console.error(
- `Failed to load xterm CSS: ${response.status} ${response.statusText}`
+ `Failed to load xterm CSS: ${response.status} ${response.statusText}`,
);
return;
}
@@ -117,7 +117,7 @@
*/
public async initializeTerminal(): Promise<void> {
const terminalContainer = this.renderRoot.querySelector(
- "#terminalContainer"
+ "#terminalContainer",
) as HTMLElement;
if (!terminalContainer) {
@@ -223,7 +223,7 @@
console.error("Failed to connect to terminal:", error);
if (this.terminal) {
this.terminal.write(
- `\r\n\x1b[1;31mFailed to connect: ${error}\x1b[0m\r\n`
+ `\r\n\x1b[1;31mFailed to connect: ${error}\x1b[0m\r\n`,
);
}
}
@@ -283,12 +283,12 @@
headers: {
"Content-Type": "text/plain",
},
- }
+ },
);
if (!response.ok) {
console.error(
- `Failed to send terminal input: ${response.status} ${response.statusText}`
+ `Failed to send terminal input: ${response.status} ${response.statusText}`,
);
}
} catch (error) {
@@ -324,12 +324,12 @@
headers: {
"Content-Type": "application/json",
},
- }
+ },
);
if (!response.ok) {
console.error(
- `Failed to send terminal resize: ${response.status} ${response.statusText}`
+ `Failed to send terminal resize: ${response.status} ${response.statusText}`,
);
}
} catch (error) {
diff --git a/loop/webui/src/web-components/sketch-timeline-message.ts b/loop/webui/src/web-components/sketch-timeline-message.ts
index 3db3b50..36f1640 100644
--- a/loop/webui/src/web-components/sketch-timeline-message.ts
+++ b/loop/webui/src/web-components/sketch-timeline-message.ts
@@ -644,7 +644,15 @@
<div class="commit-boxes-row">
<div class="commit-box">
<div class="commit-preview">
- <span class="commit-hash" title="Click to copy: ${commit.hash}" @click=${(e) => this.copyToClipboard(commit.hash.substring(0, 8), e)}>
+ <span
+ class="commit-hash"
+ title="Click to copy: ${commit.hash}"
+ @click=${(e) =>
+ this.copyToClipboard(
+ commit.hash.substring(0, 8),
+ e,
+ )}
+ >
${commit.hash.substring(0, 8)}
</span>
${commit.pushed_branch
diff --git a/loop/webui/src/web-components/sketch-timeline.ts b/loop/webui/src/web-components/sketch-timeline.ts
index 1e63f32..e2c8ee7 100644
--- a/loop/webui/src/web-components/sketch-timeline.ts
+++ b/loop/webui/src/web-components/sketch-timeline.ts
@@ -142,7 +142,7 @@
Math.abs(
this.scrollContainer.scrollHeight -
this.scrollContainer.clientHeight -
- this.scrollContainer.scrollTop
+ this.scrollContainer.scrollTop,
) <= 1;
if (isAtBottom) {
this.scrollingState = "pinToLatest";
@@ -159,7 +159,7 @@
// Listen for showCommitDiff events from the renderer
document.addEventListener(
"showCommitDiff",
- this._handleShowCommitDiff as EventListener
+ this._handleShowCommitDiff as EventListener,
);
this.scrollContainer?.addEventListener("scroll", this._handleScroll);
}
@@ -171,7 +171,7 @@
// Remove event listeners
document.removeEventListener(
"showCommitDiff",
- this._handleShowCommitDiff as EventListener
+ this._handleShowCommitDiff as EventListener,
);
this.scrollContainer?.removeEventListener("scroll", this._handleScroll);