pi-note 0.15.0 → 0.15.1

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/README.md CHANGED
@@ -68,7 +68,7 @@ task, so existing values can be configured without creating another task.
68
68
  Type in the task picker to filter by text, ID, tag, or state (all words must match).
69
69
  Use ↑/↓ and Enter to select, or Esc to cancel. Rows show **●** for in progress or
70
70
  **○** for active, followed by the tag (`[Untagged]` when absent).
71
- The normal Pi status area shows selected-task controls and title without replacing other footers. The footer omits the task ID and state and shows only the first line, bounded by `footer.titleWidth` (default 60 terminal columns including the pin, controls, tag and title). Overflow ends with `...`. The title remains clickable for preview; task controls are separate. At very small widths controls are hidden (pin only). The pin and controls are bundled in `icons/note.txt`, `icons/check.txt`, `icons/cross.txt`, and `icons/add.txt`; they use terminal fonts, not a Nerd Font or icon theme.
71
+ The normal Pi status area shows selected-task controls and title without replacing other footers. The footer omits the task ID and state and shows only the first line, bounded by `footer.titleWidth` (default 60 terminal columns including the pin, controls, tag and title). Overflow ends with `...`. The title remains clickable for preview; task controls are separate. At very small widths controls are hidden (pin only). The pin and controls are bundled in `icons/note.txt`, `icons/check.txt`, `icons/cross.txt`, and `icons/add.txt`; they use terminal fonts, not a Nerd Font or icon theme. Icons are bold; their apparent weight depends on the terminal font, and emoji may look unchanged.
72
72
 
73
73
  ### Display-only preview
74
74
 
@@ -185,7 +185,7 @@ asking in chat. The pin footer shows a pending suggestion, distinct from a selec
185
185
 
186
186
  ```text
187
187
  📌 ✕ + · [tag] Task title...
188
- 📌 ✓ · [tag] Task title...
188
+ 📌 ✓ · [tag] Task title...
189
189
  ```
190
190
 
191
191
  ![Suggested task controls](../docs/images/pi-task-suggestion.png)
@@ -195,7 +195,7 @@ asking in chat. The pin footer shows a pending suggestion, distinct from a selec
195
195
  - Accent **+** creates, starts, and selects the suggested task.
196
196
  - Green **✓** completes the selected task, starts a clean unselected session, and reloads Pi without a completion prompt. Menu **Done** and `/pi-note-done` do the same.
197
197
 
198
- Done occupies the former ✕ position, not the + position, so clicking Add twice cannot accidentally complete the new task. The former + cell stays blank. The selected task's title is a separate preview link.
198
+ Done occupies the former ✕ position, not the + position, so clicking Add twice cannot accidentally complete the new task. The selected row removes the former + cell's padding. The selected task's title is a separate preview link.
199
199
 
200
200
  The configured `footer.titleWidth` bounds the entire row (default 60 columns). Controls stay first; the tag is dropped before truncating the first-line title with `...`. Tiny widths hide controls (pin only). Pi can still clip the combined status row on narrow terminals.
201
201
 
package/index.ts CHANGED
@@ -306,7 +306,7 @@ export default function (pi: ExtensionAPI) {
306
306
  if (alive && generation === epoch && serial === refreshSerial) {
307
307
  previewBridge?.invalidate();
308
308
  clearTaskFooter(ctx);
309
- ctx.ui.setStatus("pinote", suggestionStatus(ctx) ?? `${noteIcon} Pinote unavailable · ${cliState === "upgrade" ? "/pi-note-upgrade" : cliState === "setup" ? "/pi-note-setup" : "/pi-note"}`);
309
+ ctx.ui.setStatus("pinote", suggestionStatus(ctx) ?? `${ctx.ui.theme.bold(noteIcon)} Pinote unavailable · ${cliState === "upgrade" ? "/pi-note-upgrade" : cliState === "setup" ? "/pi-note-setup" : "/pi-note"}`);
310
310
  }
311
311
  }
312
312
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-note",
3
- "version": "0.15.0",
3
+ "version": "0.15.1",
4
4
  "description": "Persistent pinote tasks, Markdown handoffs, and task status for Pi",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -11,11 +11,11 @@ const add = readFileSync(new URL("./icons/add.txt", import.meta.url), "utf8").tr
11
11
  const gap = "\u00a0";
12
12
  const link = (label: string, url?: string) => url ? `\x1b]8;;${url}\x07${label}\x1b]8;;\x07` : label;
13
13
  type Task = { text: string; tag?: string | null };
14
- type Colors = Pick<Theme, "fg">;
14
+ type Colors = Pick<Theme, "fg" | "bold">;
15
15
 
16
16
  function renderTask(task: Task, width: number, theme: Colors, prefix: string, previewUrl?: string): string {
17
17
  // All controls or none: never let a narrow budget reveal only one pending choice.
18
- if (visibleWidth(prefix) > width) return truncateToWidth(pin, width, "");
18
+ if (visibleWidth(prefix) > width) return truncateToWidth(theme.bold(pin), width, "");
19
19
  const remaining = width - visibleWidth(prefix) - 3; // separator: " · "
20
20
  if (remaining < 4) return prefix.trimEnd();
21
21
  const clean = (value: string) => stripVTControlCharacters(value).replace(/[\x00-\x1f\x7f-\x9f]/gu, " ").replace(/\s+/gu, " ").trim();
@@ -30,12 +30,12 @@ function renderTask(task: Task, width: number, theme: Colors, prefix: string, pr
30
30
 
31
31
  export function renderSuggestion(task: Task, width: number, theme: Colors, urls: { yes?: string; no?: string }): string {
32
32
  return renderTask(task, width, theme,
33
- `${pin} ${theme.fg("muted", link(cross, urls.no))}${gap.repeat(2)}${theme.fg("accent", link(add, urls.yes))}`);
33
+ `${theme.bold(pin)} ${theme.fg("muted", link(theme.bold(cross), urls.no))}${gap.repeat(2)}${theme.fg("accent", link(theme.bold(add), urls.yes))}`);
34
34
  }
35
35
 
36
36
  export function renderSelectedTask(task: Task, width: number, theme: Colors, urls: { preview?: string; done?: string }): string {
37
- // Reserve the former '+' cell: accepting twice at the same position cannot click Done.
37
+ // Done stays in the former '✕' cell, never the Add cell.
38
38
  return renderTask(task, width, theme,
39
- `${pin} ${theme.fg("success", link(check, urls.done))}${gap.repeat(visibleWidth(cross) + 2 + visibleWidth(add) - visibleWidth(check))}`,
39
+ `${theme.bold(pin)} ${theme.fg("success", link(theme.bold(check), urls.done))}`,
40
40
  urls.preview);
41
41
  }