pi-ext
bugabingas pi extensions
owned by bugabinga
goal: use alt+g for widget toggle
f34e142a5d5aca24d64737fab894b13f35557551
Oliver Krylow <o.krylow@isp-insoft.de> ·
unsigned
Browse filesCompare with HEAD
Change the goal widget shortcut from ctrl+shift+g to alt+g.
Update the compact widget hint, README, and unit coverage.
Changed files (3)
extensions/goal/README.md
Modified178 178 The widget is registered once per goal display to keep ordering stable
179 179 relative to other widgets while live timer updates continue.
180 - `/goal widget` or `ctrl+shift+g` toggles expanded mode with wrapped objective,
180 + `/goal widget` or `alt+g` toggles expanded mode with wrapped objective,
181 181 elapsed/budget info, criteria preview, and last judge verdict glyph/reason.
182 182 - Active/queued/judging goals set the streaming working message and spinner
183 183 frames as a heartbeat; terminal/passive states restore the default loader.
extensions/goal/__tests__/unit.test.ts
Modified 214 214 __goalTest.
goalCompactWidgetLine(
goal()
as never,
"normal",
96),
215 - ).
toContain(
"ctrl+shift+g expand");
215 + ).
toContain(
"alt+g expand");
216 216 expect(__goalTest.
insetWidgetLine(
"╭ goal active ╮",
30)).
toBe(
217 217 " ╭ goal active ╮ ",
extensions/goal/index.ts
Modified1105 1105 ? ` · ${verdictGlyph(state.lastVerdict)} ${sanitizeGoalText(state.lastReason, 48)}` 1107 1107 return truncateToWidth(
1108 - `◇ ${footerPhaseText(state, mode)} · ctrl+shift+g expand · ${budgetText(state)}${criteria} · ${sanitizeGoalText(state.objective, 160)}${reason}`,
1108 + `◇ ${footerPhaseText(state, mode)} · alt+g expand · ${budgetText(state)}${criteria} · ${sanitizeGoalText(state.objective, 160)}${reason}`,
1109 1109 Math.
max(
0, width),
2228 2228 const syncUpdateGoalTool = ()
=> 2229 2229 setToolActive(pi,
"update_goal",
canUseUpdateGoal(state));
2231 - pi.
registerShortcut(
"ctrl+shift+g", {
2231 + pi.
registerShortcut(
"alt+g", {
2232 2232 description:
"Toggle /goal widget compact/expanded",
2233 2233 handler:
async (ctx)
=> {
2234 2234 liveGoalWidgetMode
=