@pi-unipi/footer 2.0.7 → 2.0.9
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 +4 -3
- package/src/commands.ts +1 -1
- package/src/events.ts +1 -1
- package/src/help.ts +2 -2
- package/src/index.ts +3 -3
- package/src/rendering/renderer.ts +2 -2
- package/src/rendering/theme.ts +1 -1
- package/src/segments/status-ext.ts +1 -1
- package/src/tui/settings-tui.ts +2 -2
- package/src/types.ts +1 -1
package/package.json
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pi-unipi/footer",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.9",
|
|
4
4
|
"description": "Persistent status bar for Unipi — subscribes to UNIPI_EVENTS and renders key stats from all unipi packages",
|
|
5
5
|
"type": "module",
|
|
6
|
+
"main": "src/index.ts",
|
|
6
7
|
"license": "MIT",
|
|
7
8
|
"author": "Neuron Mr White",
|
|
8
9
|
"repository": {
|
|
@@ -42,8 +43,8 @@
|
|
|
42
43
|
"@pi-unipi/core": "*"
|
|
43
44
|
},
|
|
44
45
|
"peerDependencies": {
|
|
45
|
-
"@
|
|
46
|
-
"@
|
|
46
|
+
"@earendil-works/pi-coding-agent": "^0.75.5",
|
|
47
|
+
"@earendil-works/pi-tui": "^0.75.5"
|
|
47
48
|
},
|
|
48
49
|
"devDependencies": {
|
|
49
50
|
"@types/node": "^25.6.0",
|
package/src/commands.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* /unipi:footer-settings.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import type { ExtensionAPI, ExtensionContext } from "@
|
|
8
|
+
import type { ExtensionAPI, ExtensionContext } from "@earendil-works/pi-coding-agent";
|
|
9
9
|
import { UNIPI_PREFIX, FOOTER_COMMANDS } from "@pi-unipi/core";
|
|
10
10
|
import { loadFooterSettings, saveFooterSettings } from "./config.js";
|
|
11
11
|
import { showFooterSettings } from "./tui/settings-tui.js";
|
package/src/events.ts
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* Note: pi.events.on() returns an unsubscribe function directly.
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
|
-
import type { ExtensionAPI } from "@
|
|
10
|
+
import type { ExtensionAPI } from "@earendil-works/pi-coding-agent";
|
|
11
11
|
import { UNIPI_EVENTS } from "@pi-unipi/core";
|
|
12
12
|
import type { FooterRegistry } from "./registry/index.js";
|
|
13
13
|
|
package/src/help.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* with icons, short labels, and descriptions.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import type { ExtensionAPI } from "@
|
|
8
|
+
import type { ExtensionAPI } from "@earendil-works/pi-coding-agent";
|
|
9
9
|
import type { FooterSegment, SegmentZone } from "./types.js";
|
|
10
10
|
import { getIcon } from "./rendering/icons.js";
|
|
11
11
|
import { loadFooterSettings, isSegmentEnabled } from "./config.js";
|
|
@@ -101,7 +101,7 @@ export function showFooterHelp(
|
|
|
101
101
|
// Use pi's custom UI overlay
|
|
102
102
|
const ctx = (pi as any)._ctx;
|
|
103
103
|
if (ctx?.ui?.custom) {
|
|
104
|
-
ctx.ui.custom((tui: import("@
|
|
104
|
+
ctx.ui.custom((tui: import("@earendil-works/pi-tui").TUI) => {
|
|
105
105
|
let scrollOffset = 0;
|
|
106
106
|
|
|
107
107
|
return {
|
package/src/index.ts
CHANGED
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
* initializes renderer on session_start.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import type { ExtensionAPI, Theme, ExtensionContext } from "@
|
|
9
|
-
import { truncateToWidth, visibleWidth } from "@
|
|
8
|
+
import type { ExtensionAPI, Theme, ExtensionContext } from "@earendil-works/pi-coding-agent";
|
|
9
|
+
import { truncateToWidth, visibleWidth } from "@earendil-works/pi-tui";
|
|
10
10
|
import { UNIPI_EVENTS, emitEvent, UNIPI_PREFIX, FOOTER_COMMANDS } from "@pi-unipi/core";
|
|
11
11
|
import { FooterRegistry, getFooterRegistry } from "./registry/index.js";
|
|
12
12
|
import { FooterRenderer } from "./rendering/renderer.js";
|
|
@@ -63,7 +63,7 @@ export interface FooterState {
|
|
|
63
63
|
unsubscribeEvents: (() => void) | null;
|
|
64
64
|
piContext: unknown;
|
|
65
65
|
footerData: unknown;
|
|
66
|
-
tuiRef: import("@
|
|
66
|
+
tuiRef: import("@earendil-works/pi-tui").TUI | null | undefined;
|
|
67
67
|
refreshTimer: ReturnType<typeof setInterval> | null;
|
|
68
68
|
/** Re-register footer + widgets with pi UI (for live enable) */
|
|
69
69
|
setupUI: ((pi: ExtensionAPI, ctx: ExtensionContext) => void) | null;
|
|
@@ -6,10 +6,10 @@
|
|
|
6
6
|
* Segments fit into available width; overflow goes to secondary.
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import type { Theme } from "@
|
|
9
|
+
import type { Theme } from "@earendil-works/pi-coding-agent";
|
|
10
10
|
import type { PresetDef, FooterSegmentContext, FooterSegment, ColorScheme, RenderedSegment, SegmentZone } from "../types.js";
|
|
11
11
|
import type { FooterRegistry } from "../registry/index.js";
|
|
12
|
-
import { visibleWidth as piVisibleWidth, truncateToWidth } from "@
|
|
12
|
+
import { visibleWidth as piVisibleWidth, truncateToWidth } from "@earendil-works/pi-tui";
|
|
13
13
|
import { getSeparator, separatorVisibleWidth } from "./separators.js";
|
|
14
14
|
import { getDefaultColors, setColorMode, refreshColorMode } from "./theme.js";
|
|
15
15
|
import { setIconStyle } from "./icons.js";
|
package/src/rendering/theme.ts
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
* silently swallows 24-bit escapes and renders the text uncoloured).
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
|
-
import type { Theme, ThemeColor } from "@
|
|
14
|
+
import type { Theme, ThemeColor } from "@earendil-works/pi-coding-agent";
|
|
15
15
|
import type { ColorScheme, ColorValue, SemanticColor, ThemeLike } from "../types.js";
|
|
16
16
|
|
|
17
17
|
// ─── Color mode detection ──────────────────────────────────────────────────
|
|
@@ -15,7 +15,7 @@ import type { FooterSegment, FooterSegmentContext, RenderedSegment } from "../ty
|
|
|
15
15
|
import { getIcon } from "../rendering/icons.js";
|
|
16
16
|
import { loadFooterSettings } from "../config.js";
|
|
17
17
|
import { getSeparator } from "../rendering/separators.js";
|
|
18
|
-
import { truncateToWidth, visibleWidth } from "@
|
|
18
|
+
import { truncateToWidth, visibleWidth } from "@earendil-works/pi-tui";
|
|
19
19
|
|
|
20
20
|
/** Map status keys to short display names and segment IDs for icons */
|
|
21
21
|
const STATUS_DISPLAY: Record<string, { short: string; segmentId: string }> = {
|
package/src/tui/settings-tui.ts
CHANGED
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
* Uses pi-tui SettingsList for vim/arrow keybinding support.
|
|
10
10
|
*/
|
|
11
11
|
|
|
12
|
-
import type { ExtensionAPI, ExtensionCommandContext } from "@
|
|
13
|
-
import { SettingsList, type SettingItem, type SettingsListTheme } from "@
|
|
12
|
+
import type { ExtensionAPI, ExtensionCommandContext } from "@earendil-works/pi-coding-agent";
|
|
13
|
+
import { SettingsList, type SettingItem, type SettingsListTheme } from "@earendil-works/pi-tui";
|
|
14
14
|
import { loadFooterSettings, saveFooterSettings } from "../config.js";
|
|
15
15
|
import { PRESET_NAMES } from "../presets.js";
|
|
16
16
|
import { setIconStyle } from "../rendering/icons.js";
|
package/src/types.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* presets, separators, theme.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import type { Theme, ThemeColor } from "@
|
|
8
|
+
import type { Theme, ThemeColor } from "@earendil-works/pi-coding-agent";
|
|
9
9
|
|
|
10
10
|
// ─── Semantic Colors ────────────────────────────────────────────────────────
|
|
11
11
|
|