@pi-unipi/utility 2.1.3 → 2.2.0
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
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pi-unipi/utility",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.2.0",
|
|
4
4
|
"description": "Utility commands and tools for Pi coding agent — lifecycle, diagnostics, cache, analytics, display, batch execution",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "src/index.ts",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"access": "public"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@pi-unipi/core": "2.
|
|
37
|
+
"@pi-unipi/core": "2.2.0",
|
|
38
38
|
"diff": "^7.0.0",
|
|
39
39
|
"@shikijs/cli": "^4.0.2"
|
|
40
40
|
},
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
import type { Component } from "@earendil-works/pi-tui";
|
|
10
10
|
import { truncateToWidth, visibleWidth } from "@earendil-works/pi-tui";
|
|
11
11
|
import type { CachedModel } from "@pi-unipi/core";
|
|
12
|
-
import { readModelCache } from "@pi-unipi/core";
|
|
12
|
+
import { readModelCache, boxInnerWidth } from "@pi-unipi/core";
|
|
13
13
|
import {
|
|
14
14
|
readBadgeSettings,
|
|
15
15
|
writeBadgeSettings,
|
|
@@ -275,7 +275,7 @@ export class BadgeSettingsTui implements Component {
|
|
|
275
275
|
*/
|
|
276
276
|
render(width: number): string[] {
|
|
277
277
|
const lines: string[] = [];
|
|
278
|
-
const innerWidth =
|
|
278
|
+
const innerWidth = boxInnerWidth(width);
|
|
279
279
|
|
|
280
280
|
const padVisible = (content: string, targetWidth: number): string => {
|
|
281
281
|
const vw = visibleWidth(content);
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
import type { Component } from "@earendil-works/pi-tui";
|
|
12
12
|
import { truncateToWidth, visibleWidth } from "@earendil-works/pi-tui";
|
|
13
13
|
import type { CachedModel } from "@pi-unipi/core";
|
|
14
|
-
import { readModelCache } from "@pi-unipi/core";
|
|
14
|
+
import { readModelCache, boxInnerWidth } from "@pi-unipi/core";
|
|
15
15
|
import {
|
|
16
16
|
readUtilSettings,
|
|
17
17
|
writeUtilSettings,
|
|
@@ -370,7 +370,7 @@ export class UtilSettingsTui implements Component {
|
|
|
370
370
|
*/
|
|
371
371
|
render(width: number): string[] {
|
|
372
372
|
const lines: string[] = [];
|
|
373
|
-
const innerWidth =
|
|
373
|
+
const innerWidth = boxInnerWidth(width);
|
|
374
374
|
|
|
375
375
|
const padVisible = (content: string, targetWidth: number): string => {
|
|
376
376
|
const vw = visibleWidth(content);
|