@arhen/pi-core-subagent 1.1.21 → 1.1.22
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/package.json +1 -1
- package/src/index.ts +2 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@arhen/pi-core-subagent",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.22",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "pi extension: fast in-process subagents with single/parallel/chain, background runs, intercom and agent-to-agent mailbox. Leader defines agents inline.",
|
|
6
6
|
"license": "MIT",
|
package/src/index.ts
CHANGED
|
@@ -232,7 +232,8 @@ function taskLine(task: TaskSnapshot): string {
|
|
|
232
232
|
* inside the ANSI escape codes themselves ("38;2;139;136;122m16 tools").
|
|
233
233
|
*/
|
|
234
234
|
export function colorNums(text: string, theme: Theme): string {
|
|
235
|
-
|
|
235
|
+
// A value keeps its unit: "460.6k" and "2m30s" each color as one token, not digit-by-digit.
|
|
236
|
+
return text.replace(/((?:\d+(?:\.\d+)?[a-zA-Z]*)+)|([^\d]+)/g, (_m, num?: string, rest?: string) => (num ? theme.fg("syntaxNumber", num) : theme.fg("muted", rest ?? "")));
|
|
236
237
|
}
|
|
237
238
|
/**
|
|
238
239
|
* Themed one-liner. Finished tasks dim entirely (stats included); live tasks
|