pi-claude-code-ui 1.0.82 → 1.0.83
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/extensions/index.ts +27 -10
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,12 @@
|
|
|
3
3
|
> [!IMPORTANT]
|
|
4
4
|
> **1.0.69 — package rename (permanent).** Canonical npm name is now [`pi-claude-code-ui`](https://www.npmjs.com/package/pi-claude-code-ui). `pi-claude-style-tools` is legacy and will not receive further releases. Install with `pi install npm:pi-claude-code-ui` or `npm i pi-claude-code-ui`.
|
|
5
5
|
|
|
6
|
+
## 1.0.83 — 2026-09-07
|
|
7
|
+
|
|
8
|
+
### Fixed
|
|
9
|
+
|
|
10
|
+
- **Support Pi 0.85+ MouseRegion-wrapped thinking blocks** — unwrap `MouseRegion` containers in `replaceHiddenThinkingPlaceholders` and the assistant message Markdown post-processor. Resolves an issue in newer Pi versions where thinking blocks were rendered in raw italics and collapsed thoughts remained stuck on "Thinking…" instead of transitioning to "Thought for Xs". Preserves native Pi 0.85 mouse click-to-expand and click-to-collapse functionality.
|
|
11
|
+
|
|
6
12
|
## 1.0.80 — 2026-08-24
|
|
7
13
|
|
|
8
14
|
### Fixed
|
package/extensions/index.ts
CHANGED
|
@@ -2043,9 +2043,10 @@ function replaceHiddenThinkingPlaceholders(container: { children?: any[] }, mess
|
|
|
2043
2043
|
let firstReplaced = false;
|
|
2044
2044
|
for (let i = 0; i < container.children.length; i++) {
|
|
2045
2045
|
const child = container.children[i];
|
|
2046
|
-
|
|
2046
|
+
const inner = (child as any)?.child ?? child;
|
|
2047
|
+
if (inner instanceof HiddenThinkingSummary || (inner as any)?.constructor?.name === "HiddenThinkingSummary") {
|
|
2047
2048
|
if (!firstReplaced) {
|
|
2048
|
-
|
|
2049
|
+
inner.setSummary(summary);
|
|
2049
2050
|
firstReplaced = true;
|
|
2050
2051
|
} else {
|
|
2051
2052
|
container.children.splice(i, 1);
|
|
@@ -2053,9 +2054,14 @@ function replaceHiddenThinkingPlaceholders(container: { children?: any[] }, mess
|
|
|
2053
2054
|
}
|
|
2054
2055
|
continue;
|
|
2055
2056
|
}
|
|
2056
|
-
if (isHiddenThinkingPlaceholderText(
|
|
2057
|
+
if (isHiddenThinkingPlaceholderText(inner)) {
|
|
2057
2058
|
if (!firstReplaced) {
|
|
2058
|
-
|
|
2059
|
+
const summaryComp = new HiddenThinkingSummary(summary);
|
|
2060
|
+
if ((child as any)?.child !== undefined) {
|
|
2061
|
+
(child as any).child = summaryComp;
|
|
2062
|
+
} else {
|
|
2063
|
+
container.children[i] = summaryComp;
|
|
2064
|
+
}
|
|
2059
2065
|
firstReplaced = true;
|
|
2060
2066
|
} else {
|
|
2061
2067
|
container.children.splice(i, 1);
|
|
@@ -2459,15 +2465,26 @@ function patchAssistantMessages(): void {
|
|
|
2459
2465
|
const mdTheme = (this as any).markdownTheme;
|
|
2460
2466
|
for (let i = container.children.length - 1; i >= 0; i--) {
|
|
2461
2467
|
const child = container.children[i];
|
|
2462
|
-
|
|
2463
|
-
|
|
2468
|
+
const inner = (child as any)?.child ?? child;
|
|
2469
|
+
if (isMarkdownComponent(inner)) {
|
|
2470
|
+
const text = (inner as any).text;
|
|
2464
2471
|
if (!text) continue;
|
|
2465
|
-
const isThinking = !!(
|
|
2472
|
+
const isThinking = !!(inner as any).defaultTextStyle?.italic;
|
|
2466
2473
|
if (isThinking) {
|
|
2467
|
-
const style = (
|
|
2468
|
-
|
|
2474
|
+
const style = (inner as any).defaultTextStyle;
|
|
2475
|
+
const replacement = new ThinkingParagraph(text, mdTheme, style);
|
|
2476
|
+
if ((child as any)?.child !== undefined) {
|
|
2477
|
+
(child as any).child = replacement;
|
|
2478
|
+
} else {
|
|
2479
|
+
container.children[i] = replacement;
|
|
2480
|
+
}
|
|
2469
2481
|
} else {
|
|
2470
|
-
|
|
2482
|
+
const replacement = new DottedParagraph(text, mdTheme);
|
|
2483
|
+
if ((child as any)?.child !== undefined) {
|
|
2484
|
+
(child as any).child = replacement;
|
|
2485
|
+
} else {
|
|
2486
|
+
container.children[i] = replacement;
|
|
2487
|
+
}
|
|
2471
2488
|
}
|
|
2472
2489
|
}
|
|
2473
2490
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-claude-code-ui",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.83",
|
|
4
4
|
"description": "Claude Code-style grouped tool rows for pi with Ctrl+O/Ctrl+Shift+O previews, math rendering, and consistent built-in, MCP, and custom tool rendering",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"pi-package",
|