Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 2 additions & 7 deletions plugins/pstack/extensions/potetomode/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,14 +49,9 @@ export default function potetomode(pi) {
return;
}

// Indicator matches ponytail's style: ● active, ○ idle
// Theme colors only: color emoji ignore the palette and render double-width, so they clash with the rest of the status line.
const indicator = isActive ? theme.fg("accent", "●") : theme.fg("dim", "○");
// 🥔 / 👑 poteto: PINNED
const pill =
indicator +
" 🥔 " +
theme.fg("muted", "poteto: ") +
theme.fg("warning", "👑 PINNED");
const pill = indicator + " " + theme.fg("muted", "poteto ") + theme.fg("warning", "pinned");

c.ui.setStatus("poteto-mode", pill);
};
Expand Down
4 changes: 2 additions & 2 deletions plugins/pstack/extensions/potetomode/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,12 @@ test("latest entry wins and a new session resets the previous override", async (
test("shortcut, status, command and injection share one effective state", async () => {
const session = host();
await session.start();
expect(session.status()).toContain("PINNED");
expect(session.status()).not.toBe("");
session.shortcut();
expect(session.status()).toBe("");
expect(await session.before()).toBeUndefined();
await session.command("on");
expect(session.status()).toContain("PINNED");
expect(session.status()).not.toBe("");
expect(await session.before()).toBeDefined();
await session.command("off");
expect(await session.before()).toBeUndefined();
Expand Down
Loading