@deepseek-harness-tui/dsh-tui 0.12.0 → 0.13.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/README.md +41 -5
- package/assets/deepy/README.md +60 -0
- package/assets/deepy/frames.json +1 -0
- package/assets/whale-girl/whale-girl-happy.png +0 -0
- package/assets/whaleGirl/README.md +7 -0
- package/assets/whaleGirl/frames.json +1 -0
- package/assets/whaleGirl/img/building/00.png +0 -0
- package/assets/whaleGirl/img/building/01.png +0 -0
- package/assets/whaleGirl/img/building/02.png +0 -0
- package/assets/whaleGirl/img/building/03.png +0 -0
- package/assets/whaleGirl/img/building/04.png +0 -0
- package/assets/whaleGirl/img/building/05.png +0 -0
- package/assets/whaleGirl/img/building/06.png +0 -0
- package/assets/whaleGirl/img/building/07.png +0 -0
- package/assets/whaleGirl/img/building/08.png +0 -0
- package/assets/whaleGirl/img/building/09.png +0 -0
- package/assets/whaleGirl/img/building/10.png +0 -0
- package/assets/whaleGirl/img/building/11.png +0 -0
- package/assets/whaleGirl/img/building/12.png +0 -0
- package/assets/whaleGirl/img/building/13.png +0 -0
- package/assets/whaleGirl/img/building/14.png +0 -0
- package/assets/whaleGirl/img/building/15.png +0 -0
- package/assets/whaleGirl/img/building/16.png +0 -0
- package/assets/whaleGirl/img/building/17.png +0 -0
- package/assets/whaleGirl/img/building/18.png +0 -0
- package/assets/whaleGirl/img/building/19.png +0 -0
- package/assets/whaleGirl/img/building/20.png +0 -0
- package/assets/whaleGirl/img/building/21.png +0 -0
- package/assets/whaleGirl/img/building/22.png +0 -0
- package/assets/whaleGirl/img/building/23.png +0 -0
- package/assets/whaleGirl/img/carrying/00.png +0 -0
- package/assets/whaleGirl/img/carrying/01.png +0 -0
- package/assets/whaleGirl/img/carrying/02.png +0 -0
- package/assets/whaleGirl/img/carrying/03.png +0 -0
- package/assets/whaleGirl/img/carrying/04.png +0 -0
- package/assets/whaleGirl/img/carrying/05.png +0 -0
- package/assets/whaleGirl/img/carrying/06.png +0 -0
- package/assets/whaleGirl/img/carrying/07.png +0 -0
- package/assets/whaleGirl/img/compacting/00.png +0 -0
- package/assets/whaleGirl/img/compacting/01.png +0 -0
- package/assets/whaleGirl/img/compacting/02.png +0 -0
- package/assets/whaleGirl/img/compacting/03.png +0 -0
- package/assets/whaleGirl/img/compacting/04.png +0 -0
- package/assets/whaleGirl/img/compacting/05.png +0 -0
- package/assets/whaleGirl/img/compacting/06.png +0 -0
- package/assets/whaleGirl/img/compacting/07.png +0 -0
- package/assets/whaleGirl/img/compacting/08.png +0 -0
- package/assets/whaleGirl/img/compacting/09.png +0 -0
- package/assets/whaleGirl/img/conducting/00.png +0 -0
- package/assets/whaleGirl/img/conducting/01.png +0 -0
- package/assets/whaleGirl/img/conducting/02.png +0 -0
- package/assets/whaleGirl/img/conducting/03.png +0 -0
- package/assets/whaleGirl/img/conducting/04.png +0 -0
- package/assets/whaleGirl/img/conducting/05.png +0 -0
- package/assets/whaleGirl/img/conducting/06.png +0 -0
- package/assets/whaleGirl/img/conducting/07.png +0 -0
- package/assets/whaleGirl/img/conducting/08.png +0 -0
- package/assets/whaleGirl/img/conducting/09.png +0 -0
- package/assets/whaleGirl/img/conducting/10.png +0 -0
- package/assets/whaleGirl/img/conducting/11.png +0 -0
- package/assets/whaleGirl/img/drag/00.png +0 -0
- package/assets/whaleGirl/img/drag/01.png +0 -0
- package/assets/whaleGirl/img/drag/02.png +0 -0
- package/assets/whaleGirl/img/drag/03.png +0 -0
- package/assets/whaleGirl/img/drag/04.png +0 -0
- package/assets/whaleGirl/img/drag/05.png +0 -0
- package/assets/whaleGirl/img/drag/06.png +0 -0
- package/assets/whaleGirl/img/drag/07.png +0 -0
- package/assets/whaleGirl/img/drag/08.png +0 -0
- package/assets/whaleGirl/img/drag/09.png +0 -0
- package/assets/whaleGirl/img/error/00.png +0 -0
- package/assets/whaleGirl/img/error/01.png +0 -0
- package/assets/whaleGirl/img/error/02.png +0 -0
- package/assets/whaleGirl/img/error/03.png +0 -0
- package/assets/whaleGirl/img/error/04.png +0 -0
- package/assets/whaleGirl/img/error/05.png +0 -0
- package/assets/whaleGirl/img/error/06.png +0 -0
- package/assets/whaleGirl/img/error/07.png +0 -0
- package/assets/whaleGirl/img/error/08.png +0 -0
- package/assets/whaleGirl/img/error/09.png +0 -0
- package/assets/whaleGirl/img/happy/00.png +0 -0
- package/assets/whaleGirl/img/happy/01.png +0 -0
- package/assets/whaleGirl/img/happy/02.png +0 -0
- package/assets/whaleGirl/img/happy/03.png +0 -0
- package/assets/whaleGirl/img/happy/04.png +0 -0
- package/assets/whaleGirl/img/happy/05.png +0 -0
- package/assets/whaleGirl/img/happy/06.png +0 -0
- package/assets/whaleGirl/img/happy/07.png +0 -0
- package/assets/whaleGirl/img/happy/08.png +0 -0
- package/assets/whaleGirl/img/happy/09.png +0 -0
- package/assets/whaleGirl/img/happy/10.png +0 -0
- package/assets/whaleGirl/img/idle/00.png +0 -0
- package/assets/whaleGirl/img/idle/01.png +0 -0
- package/assets/whaleGirl/img/idle/02.png +0 -0
- package/assets/whaleGirl/img/idle/03.png +0 -0
- package/assets/whaleGirl/img/idle/04.png +0 -0
- package/assets/whaleGirl/img/idle/05.png +0 -0
- package/assets/whaleGirl/img/idle/06.png +0 -0
- package/assets/whaleGirl/img/idle/07.png +0 -0
- package/assets/whaleGirl/img/idle/08.png +0 -0
- package/assets/whaleGirl/img/idle/09.png +0 -0
- package/assets/whaleGirl/img/idle/10.png +0 -0
- package/assets/whaleGirl/img/idle/11.png +0 -0
- package/assets/whaleGirl/img/idle/12.png +0 -0
- package/assets/whaleGirl/img/idle/13.png +0 -0
- package/assets/whaleGirl/img/idle/14.png +0 -0
- package/assets/whaleGirl/img/idle/15.png +0 -0
- package/assets/whaleGirl/img/idle/16.png +0 -0
- package/assets/whaleGirl/img/idle/17.png +0 -0
- package/assets/whaleGirl/img/idle/18.png +0 -0
- package/assets/whaleGirl/img/idle/19.png +0 -0
- package/assets/whaleGirl/img/idle/20.png +0 -0
- package/assets/whaleGirl/img/idle-look/00.png +0 -0
- package/assets/whaleGirl/img/idle-look/01.png +0 -0
- package/assets/whaleGirl/img/idle-look/02.png +0 -0
- package/assets/whaleGirl/img/idle-look/03.png +0 -0
- package/assets/whaleGirl/img/idle-look/04.png +0 -0
- package/assets/whaleGirl/img/idle-look/05.png +0 -0
- package/assets/whaleGirl/img/idle-look/06.png +0 -0
- package/assets/whaleGirl/img/idle-look/07.png +0 -0
- package/assets/whaleGirl/img/idle-look/08.png +0 -0
- package/assets/whaleGirl/img/idle-look/09.png +0 -0
- package/assets/whaleGirl/img/idle-look/10.png +0 -0
- package/assets/whaleGirl/img/idle-look/11.png +0 -0
- package/assets/whaleGirl/img/idle-look/12.png +0 -0
- package/assets/whaleGirl/img/idle-spout/00.png +0 -0
- package/assets/whaleGirl/img/idle-spout/01.png +0 -0
- package/assets/whaleGirl/img/idle-spout/02.png +0 -0
- package/assets/whaleGirl/img/idle-spout/03.png +0 -0
- package/assets/whaleGirl/img/idle-spout/04.png +0 -0
- package/assets/whaleGirl/img/idle-spout/05.png +0 -0
- package/assets/whaleGirl/img/idle-spout/06.png +0 -0
- package/assets/whaleGirl/img/idle-spout/07.png +0 -0
- package/assets/whaleGirl/img/idle-spout/08.png +0 -0
- package/assets/whaleGirl/img/idle-spout/09.png +0 -0
- package/assets/whaleGirl/img/idle-spout/10.png +0 -0
- package/assets/whaleGirl/img/music/00.png +0 -0
- package/assets/whaleGirl/img/music/01.png +0 -0
- package/assets/whaleGirl/img/music/02.png +0 -0
- package/assets/whaleGirl/img/music/03.png +0 -0
- package/assets/whaleGirl/img/music/04.png +0 -0
- package/assets/whaleGirl/img/music/05.png +0 -0
- package/assets/whaleGirl/img/music/06.png +0 -0
- package/assets/whaleGirl/img/music/07.png +0 -0
- package/assets/whaleGirl/img/notification/00.png +0 -0
- package/assets/whaleGirl/img/notification/01.png +0 -0
- package/assets/whaleGirl/img/notification/02.png +0 -0
- package/assets/whaleGirl/img/notification/03.png +0 -0
- package/assets/whaleGirl/img/notification/04.png +0 -0
- package/assets/whaleGirl/img/notification/05.png +0 -0
- package/assets/whaleGirl/img/notification/06.png +0 -0
- package/assets/whaleGirl/img/notification/07.png +0 -0
- package/assets/whaleGirl/img/poke-left/00.png +0 -0
- package/assets/whaleGirl/img/poke-left/01.png +0 -0
- package/assets/whaleGirl/img/poke-left/02.png +0 -0
- package/assets/whaleGirl/img/poke-left/03.png +0 -0
- package/assets/whaleGirl/img/poke-left/04.png +0 -0
- package/assets/whaleGirl/img/poke-left/05.png +0 -0
- package/assets/whaleGirl/img/poke-left/06.png +0 -0
- package/assets/whaleGirl/img/poke-left/07.png +0 -0
- package/assets/whaleGirl/img/poke-left/08.png +0 -0
- package/assets/whaleGirl/img/poke-left/09.png +0 -0
- package/assets/whaleGirl/img/poke-left/10.png +0 -0
- package/assets/whaleGirl/img/poke-right/00.png +0 -0
- package/assets/whaleGirl/img/poke-right/01.png +0 -0
- package/assets/whaleGirl/img/poke-right/02.png +0 -0
- package/assets/whaleGirl/img/poke-right/03.png +0 -0
- package/assets/whaleGirl/img/poke-right/04.png +0 -0
- package/assets/whaleGirl/img/poke-right/05.png +0 -0
- package/assets/whaleGirl/img/poke-right/06.png +0 -0
- package/assets/whaleGirl/img/poke-right/07.png +0 -0
- package/assets/whaleGirl/img/poke-right/08.png +0 -0
- package/assets/whaleGirl/img/poke-right/09.png +0 -0
- package/assets/whaleGirl/img/poke-right/10.png +0 -0
- package/assets/whaleGirl/img/sleeping/00.png +0 -0
- package/assets/whaleGirl/img/sleeping/01.png +0 -0
- package/assets/whaleGirl/img/sleeping/02.png +0 -0
- package/assets/whaleGirl/img/sleeping/03.png +0 -0
- package/assets/whaleGirl/img/sleeping/04.png +0 -0
- package/assets/whaleGirl/img/sleeping/05.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/00.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/01.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/02.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/03.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/04.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/05.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/06.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/07.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/08.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/09.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/10.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/11.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/12.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/13.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/14.png +0 -0
- package/assets/whaleGirl/img/smile-hearts/15.png +0 -0
- package/assets/whaleGirl/img/swim/00.png +0 -0
- package/assets/whaleGirl/img/swim/01.png +0 -0
- package/assets/whaleGirl/img/swim/02.png +0 -0
- package/assets/whaleGirl/img/swim/03.png +0 -0
- package/assets/whaleGirl/img/swim/04.png +0 -0
- package/assets/whaleGirl/img/swim/05.png +0 -0
- package/assets/whaleGirl/img/swim/06.png +0 -0
- package/assets/whaleGirl/img/swim/07.png +0 -0
- package/assets/whaleGirl/img/thinking/00.png +0 -0
- package/assets/whaleGirl/img/thinking/01.png +0 -0
- package/assets/whaleGirl/img/thinking/02.png +0 -0
- package/assets/whaleGirl/img/thinking/03.png +0 -0
- package/assets/whaleGirl/img/thinking/04.png +0 -0
- package/assets/whaleGirl/img/thinking/05.png +0 -0
- package/assets/whaleGirl/img/thinking/06.png +0 -0
- package/assets/whaleGirl/img/thinking/07.png +0 -0
- package/assets/whaleGirl/img/thinking/08.png +0 -0
- package/assets/whaleGirl/img/thinking/09.png +0 -0
- package/assets/whaleGirl/img/thinking/10.png +0 -0
- package/assets/whaleGirl/img/thinking/11.png +0 -0
- package/assets/whaleGirl/img/thinking/12.png +0 -0
- package/assets/whaleGirl/img/thinking/13.png +0 -0
- package/assets/whaleGirl/img/thinking/14.png +0 -0
- package/assets/whaleGirl/img/thinking/15.png +0 -0
- package/assets/whaleGirl/img/thinking/16.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/00.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/01.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/02.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/03.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/04.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/05.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/06.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/07.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/08.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/09.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/10.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/11.png +0 -0
- package/assets/whaleGirl/img/thumbs-up/12.png +0 -0
- package/assets/whaleGirl/img/tickle/00.png +0 -0
- package/assets/whaleGirl/img/tickle/01.png +0 -0
- package/assets/whaleGirl/img/tickle/02.png +0 -0
- package/assets/whaleGirl/img/tickle/03.png +0 -0
- package/assets/whaleGirl/img/tickle/04.png +0 -0
- package/assets/whaleGirl/img/tickle/05.png +0 -0
- package/assets/whaleGirl/img/tickle/06.png +0 -0
- package/assets/whaleGirl/img/tickle/07.png +0 -0
- package/assets/whaleGirl/img/tickle/08.png +0 -0
- package/assets/whaleGirl/img/tickle/09.png +0 -0
- package/assets/whaleGirl/img/tickle/10.png +0 -0
- package/assets/whaleGirl/img/tickle/11.png +0 -0
- package/assets/whaleGirl/img/tickle/12.png +0 -0
- package/assets/whaleGirl/img/tickle/13.png +0 -0
- package/assets/whaleGirl/img/timings.json +1 -0
- package/assets/whaleGirl/img/typing/00.png +0 -0
- package/assets/whaleGirl/img/typing/01.png +0 -0
- package/assets/whaleGirl/img/typing/02.png +0 -0
- package/assets/whaleGirl/img/typing/03.png +0 -0
- package/assets/whaleGirl/img/typing/04.png +0 -0
- package/assets/whaleGirl/img/typing/05.png +0 -0
- package/assets/whaleGirl/img/typing/06.png +0 -0
- package/assets/whaleGirl/img/typing/07.png +0 -0
- package/assets/whaleGirl/img/typing/08.png +0 -0
- package/assets/whaleGirl/img/typing/09.png +0 -0
- package/assets/whaleGirl/img/typing/10.png +0 -0
- package/assets/whaleGirl/img/typing/11.png +0 -0
- package/assets/whaleGirl/img/typing/12.png +0 -0
- package/assets/whaleGirl/img/typing/13.png +0 -0
- package/assets/whaleGirl/img/waking/00.png +0 -0
- package/assets/whaleGirl/img/waking/01.png +0 -0
- package/assets/whaleGirl/img/waking/02.png +0 -0
- package/assets/whaleGirl/img/waking/03.png +0 -0
- package/assets/whaleGirl/img/waking/04.png +0 -0
- package/assets/whaleGirl/img/waking/05.png +0 -0
- package/assets/whaleGirl/img/waking/06.png +0 -0
- package/assets/whaleGirl/img/waking/07.png +0 -0
- package/assets/whaleGirl/img/waking/08.png +0 -0
- package/assets/whaleGirl/img/waking/09.png +0 -0
- package/assets/whaleGirl/img/waking/10.png +0 -0
- package/bin/dsh-tui.js +8 -3
- package/cordis.patch.yml +7 -1
- package/guide/dsh-tui-guide/configuration.en.md +6 -1
- package/guide/dsh-tui-guide/configuration.md +6 -1
- package/guide/dsh-tui-guide/getting-started.en.md +6 -3
- package/guide/dsh-tui-guide/getting-started.md +4 -2
- package/guide/dsh-tui-guide/interaction.en.md +68 -4
- package/guide/dsh-tui-guide/interaction.md +49 -3
- package/guide/dsh-tui-guide/plugins.en.md +16 -6
- package/guide/dsh-tui-guide/plugins.md +14 -6
- package/guide/dsh-tui-guide/themes.en.md +7 -2
- package/guide/dsh-tui-guide/themes.md +5 -2
- package/guide/dsh-tui-guide/user-guide.en.md +124 -21
- package/guide/dsh-tui-guide/user-guide.md +96 -16
- package/lib/settings.json +215 -1
- package/lib/types/adapter/channel/ui-policy.d.ts +6 -2
- package/lib/types/adapter/channel/ui-policy.d.ts.map +1 -1
- package/lib/types/adapter/channel/ui-policy.js +14 -1
- package/lib/types/adapter/index.d.ts +1 -1
- package/lib/types/adapter/index.js +1 -1
- package/lib/types/adapter/kernel/host-facade.d.ts +4 -1
- package/lib/types/adapter/kernel/host-facade.d.ts.map +1 -1
- package/lib/types/adapter/kernel/host-facade.js +8 -1
- package/lib/types/adapter/kernel/runtime.d.ts.map +1 -1
- package/lib/types/adapter/kernel/runtime.js +13 -0
- package/lib/types/adapter/kernel/slices/index.d.ts +1 -0
- package/lib/types/adapter/kernel/slices/index.d.ts.map +1 -1
- package/lib/types/adapter/kernel/slices/index.js +3 -0
- package/lib/types/adapter/kernel/slices/panels.d.ts +3 -0
- package/lib/types/adapter/kernel/slices/panels.d.ts.map +1 -0
- package/lib/types/adapter/kernel/slices/panels.js +14 -0
- package/lib/types/adapter/ports/channel-capabilities.d.ts +48 -0
- package/lib/types/adapter/ports/channel-capabilities.d.ts.map +1 -0
- package/lib/types/adapter/ports/channel-capabilities.js +2 -0
- package/lib/types/adapter/ports/channel-catalog.d.ts +7 -0
- package/lib/types/adapter/ports/channel-catalog.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel-display.d.ts +10 -0
- package/lib/types/adapter/ports/channel-display.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel-ui.d.ts +62 -2
- package/lib/types/adapter/ports/channel-ui.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel-view.d.ts +94 -0
- package/lib/types/adapter/ports/channel-view.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel.d.ts +1 -1
- package/lib/types/adapter/ports/channel.js +1 -1
- package/lib/types/adapter/ports/descriptor.d.ts +1 -1
- package/lib/types/adapter/ports/descriptor.js +1 -1
- package/lib/types/adapter/ports/index.d.ts +1 -1
- package/lib/types/adapter/ports/index.js +1 -1
- package/lib/types/adapter/ports/panels.d.ts +28 -0
- package/lib/types/adapter/ports/panels.d.ts.map +1 -0
- package/lib/types/adapter/ports/panels.js +8 -0
- package/lib/types/adapter/ports/workspace.d.ts +1 -1
- package/lib/types/adapter/ports/workspace.js +1 -1
- package/lib/types/adapter/spec/index.d.ts +2 -2
- package/lib/types/adapter/spec/index.js +2 -2
- package/lib/types/adapter/spec/profile.d.ts +6 -6
- package/lib/types/adapter/spec/profile.d.ts.map +1 -1
- package/lib/types/adapter/spec/profile.js +6 -6
- package/lib/types/adapter/spec/protocol-constants.d.ts +3 -3
- package/lib/types/adapter/spec/protocol-constants.d.ts.map +1 -1
- package/lib/types/adapter/spec/protocol-constants.js +5 -5
- package/lib/types/adapter/spec/tui-contributions.d.ts +4 -4
- package/lib/types/adapter/spec/tui-contributions.d.ts.map +1 -1
- package/lib/types/adapter/spec/tui-contributions.js +5 -5
- package/lib/types/adapter/standard/descriptor.js +1 -1
- package/lib/types/adapter/standard/index.d.ts +3 -3
- package/lib/types/adapter/standard/index.js +3 -3
- package/lib/types/adapter/standard/registry.d.ts +3 -2
- package/lib/types/adapter/standard/registry.d.ts.map +1 -1
- package/lib/types/adapter/standard/registry.js +6 -5
- package/lib/types/adapter/standard/tui-extension.d.ts +1 -1
- package/lib/types/adapter/standard/tui-extension.js +1 -1
- package/lib/types/adapter/upstream/index.d.ts +1 -0
- package/lib/types/adapter/upstream/index.d.ts.map +1 -1
- package/lib/types/adapter/upstream/index.js +1 -0
- package/lib/types/adapter/upstream/panels-driver.d.ts +18 -0
- package/lib/types/adapter/upstream/panels-driver.d.ts.map +1 -0
- package/lib/types/adapter/upstream/panels-driver.js +159 -0
- package/lib/types/api.d.ts +2 -0
- package/lib/types/api.d.ts.map +1 -1
- package/lib/types/api.js +3 -1
- package/lib/types/commands.d.ts.map +1 -1
- package/lib/types/commands.js +12 -4
- package/lib/types/components/ActivityLine.d.ts +6 -9
- package/lib/types/components/ActivityLine.d.ts.map +1 -1
- package/lib/types/components/ActivityLine.js +7 -8
- package/lib/types/components/Chat/JobCard.d.ts +18 -1
- package/lib/types/components/Chat/JobCard.d.ts.map +1 -1
- package/lib/types/components/Chat/JobCard.js +90 -22
- package/lib/types/components/Chat/JobGroupHeader.d.ts +27 -0
- package/lib/types/components/Chat/JobGroupHeader.d.ts.map +1 -0
- package/lib/types/components/Chat/JobGroupHeader.js +62 -0
- package/lib/types/components/GoalTodoPanel.d.ts +13 -1
- package/lib/types/components/GoalTodoPanel.d.ts.map +1 -1
- package/lib/types/components/GoalTodoPanel.js +55 -14
- package/lib/types/components/JobsPanel.d.ts +42 -2
- package/lib/types/components/JobsPanel.d.ts.map +1 -1
- package/lib/types/components/JobsPanel.js +147 -14
- package/lib/types/components/LogoV2.d.ts +43 -3
- package/lib/types/components/LogoV2.d.ts.map +1 -1
- package/lib/types/components/LogoV2.js +42 -15
- package/lib/types/components/MessageList.d.ts +8 -2
- package/lib/types/components/MessageList.d.ts.map +1 -1
- package/lib/types/components/MessageList.js +212 -18
- package/lib/types/components/OverlayAbove.d.ts +11 -1
- package/lib/types/components/OverlayAbove.d.ts.map +1 -1
- package/lib/types/components/OverlayAbove.js +2 -12
- package/lib/types/components/PageMargin.d.ts.map +1 -1
- package/lib/types/components/PageMargin.js +3 -1
- package/lib/types/components/PluginSceneBoundary.d.ts +1 -1
- package/lib/types/components/PluginSceneBoundary.js +1 -1
- package/lib/types/components/PromptInput.d.ts +20 -22
- package/lib/types/components/PromptInput.d.ts.map +1 -1
- package/lib/types/components/PromptInput.js +413 -156
- package/lib/types/components/SearchBox.d.ts +22 -5
- package/lib/types/components/SearchBox.d.ts.map +1 -1
- package/lib/types/components/SearchBox.js +17 -13
- package/lib/types/components/SubagentCard.d.ts.map +1 -1
- package/lib/types/components/SubagentCard.js +17 -2
- package/lib/types/components/SubagentDashboard.d.ts +18 -3
- package/lib/types/components/SubagentDashboard.d.ts.map +1 -1
- package/lib/types/components/SubagentDashboard.js +53 -5
- package/lib/types/components/SubagentDetailScene.d.ts +7 -1
- package/lib/types/components/SubagentDetailScene.d.ts.map +1 -1
- package/lib/types/components/SubagentDetailScene.js +54 -5
- package/lib/types/components/SurfaceEdges.d.ts +21 -0
- package/lib/types/components/SurfaceEdges.d.ts.map +1 -0
- package/lib/types/components/SurfaceEdges.js +7 -0
- package/lib/types/components/ThemePicker.d.ts +9 -0
- package/lib/types/components/ThemePicker.d.ts.map +1 -1
- package/lib/types/components/ThemePicker.js +74 -10
- package/lib/types/components/ThemePreviewPane.d.ts +26 -0
- package/lib/types/components/ThemePreviewPane.d.ts.map +1 -0
- package/lib/types/components/ThemePreviewPane.js +99 -0
- package/lib/types/components/design-system/Divider.d.ts.map +1 -1
- package/lib/types/components/design-system/Divider.js +14 -9
- package/lib/types/components/launchpadActions.d.ts +73 -0
- package/lib/types/components/launchpadActions.d.ts.map +1 -0
- package/lib/types/components/launchpadActions.js +111 -0
- package/lib/types/components/launchpadLayout.d.ts +62 -0
- package/lib/types/components/launchpadLayout.d.ts.map +1 -0
- package/lib/types/components/launchpadLayout.js +176 -0
- package/lib/types/components/onboardingModel.d.ts +83 -0
- package/lib/types/components/onboardingModel.d.ts.map +1 -0
- package/lib/types/components/onboardingModel.js +128 -0
- package/lib/types/components/sidePanel/InfoPanel.d.ts +17 -0
- package/lib/types/components/sidePanel/InfoPanel.d.ts.map +1 -0
- package/lib/types/components/sidePanel/InfoPanel.js +124 -0
- package/lib/types/components/sidePanel/PanelBar.d.ts +45 -0
- package/lib/types/components/sidePanel/PanelBar.d.ts.map +1 -0
- package/lib/types/components/sidePanel/PanelBar.js +104 -0
- package/lib/types/components/sidePanel/PanelErrorBoundary.d.ts +21 -0
- package/lib/types/components/sidePanel/PanelErrorBoundary.d.ts.map +1 -0
- package/lib/types/components/sidePanel/PanelErrorBoundary.js +30 -0
- package/lib/types/components/sidePanel/PanelHost.d.ts +36 -0
- package/lib/types/components/sidePanel/PanelHost.d.ts.map +1 -0
- package/lib/types/components/sidePanel/PanelHost.js +81 -0
- package/lib/types/components/sidePanel/PanelPicker.d.ts +24 -0
- package/lib/types/components/sidePanel/PanelPicker.d.ts.map +1 -0
- package/lib/types/components/sidePanel/PanelPicker.js +45 -0
- package/lib/types/components/sidePanel/PanelStore.d.ts +55 -0
- package/lib/types/components/sidePanel/PanelStore.d.ts.map +1 -0
- package/lib/types/components/sidePanel/PanelStore.js +109 -0
- package/lib/types/components/sidePanel/SidePanelColumn.d.ts +31 -0
- package/lib/types/components/sidePanel/SidePanelColumn.d.ts.map +1 -0
- package/lib/types/components/sidePanel/SidePanelColumn.js +70 -0
- package/lib/types/components/sidePanel/SidePanelLayout.d.ts +54 -0
- package/lib/types/components/sidePanel/SidePanelLayout.d.ts.map +1 -0
- package/lib/types/components/sidePanel/SidePanelLayout.js +81 -0
- package/lib/types/components/sidePanel/SidePanelRuntimeContext.d.ts +43 -0
- package/lib/types/components/sidePanel/SidePanelRuntimeContext.d.ts.map +1 -0
- package/lib/types/components/sidePanel/SidePanelRuntimeContext.js +26 -0
- package/lib/types/components/sidePanel/TrajectoryPanel.d.ts +7 -0
- package/lib/types/components/sidePanel/TrajectoryPanel.d.ts.map +1 -0
- package/lib/types/components/sidePanel/TrajectoryPanel.js +263 -0
- package/lib/types/components/sidePanel/WorkspacePanel.d.ts +4 -0
- package/lib/types/components/sidePanel/WorkspacePanel.d.ts.map +1 -0
- package/lib/types/components/sidePanel/WorkspacePanel.js +171 -0
- package/lib/types/components/sidePanel/builtinPanels.d.ts +3 -0
- package/lib/types/components/sidePanel/builtinPanels.d.ts.map +1 -0
- package/lib/types/components/sidePanel/builtinPanels.js +229 -0
- package/lib/types/components/sidePanel/companion/CompanionPanel.d.ts +53 -0
- package/lib/types/components/sidePanel/companion/CompanionPanel.d.ts.map +1 -0
- package/lib/types/components/sidePanel/companion/CompanionPanel.js +528 -0
- package/lib/types/components/sidePanel/companion/SplashMascot.d.ts +32 -0
- package/lib/types/components/sidePanel/companion/SplashMascot.d.ts.map +1 -0
- package/lib/types/components/sidePanel/companion/SplashMascot.js +103 -0
- package/lib/types/components/sidePanel/companion/deepy.d.ts +75 -0
- package/lib/types/components/sidePanel/companion/deepy.d.ts.map +1 -0
- package/lib/types/components/sidePanel/companion/deepy.js +222 -0
- package/lib/types/components/sidePanel/companion/mood.d.ts +176 -0
- package/lib/types/components/sidePanel/companion/mood.d.ts.map +1 -0
- package/lib/types/components/sidePanel/companion/mood.js +212 -0
- package/lib/types/components/sidePanel/companion/pose.d.ts +43 -0
- package/lib/types/components/sidePanel/companion/pose.d.ts.map +1 -0
- package/lib/types/components/sidePanel/companion/pose.js +34 -0
- package/lib/types/components/sidePanel/companion/skins.d.ts +102 -0
- package/lib/types/components/sidePanel/companion/skins.d.ts.map +1 -0
- package/lib/types/components/sidePanel/companion/skins.js +408 -0
- package/lib/types/components/sidePanel/dimensions.d.ts +60 -0
- package/lib/types/components/sidePanel/dimensions.d.ts.map +1 -0
- package/lib/types/components/sidePanel/dimensions.js +75 -0
- package/lib/types/components/sidePanel/jobsFocusStore.d.ts +21 -0
- package/lib/types/components/sidePanel/jobsFocusStore.d.ts.map +1 -0
- package/lib/types/components/sidePanel/jobsFocusStore.js +30 -0
- package/lib/types/components/sidePanel/panelBridge.d.ts +44 -0
- package/lib/types/components/sidePanel/panelBridge.d.ts.map +1 -0
- package/lib/types/components/sidePanel/panelBridge.js +55 -0
- package/lib/types/components/sidePanel/pluginPanelAdapter.d.ts +22 -0
- package/lib/types/components/sidePanel/pluginPanelAdapter.d.ts.map +1 -0
- package/lib/types/components/sidePanel/pluginPanelAdapter.js +148 -0
- package/lib/types/components/sidePanel/types.d.ts +110 -0
- package/lib/types/components/sidePanel/types.d.ts.map +1 -0
- package/lib/types/components/sidePanel/types.js +1 -0
- package/lib/types/components/sidePanel/usePanelInput.d.ts +5 -0
- package/lib/types/components/sidePanel/usePanelInput.d.ts.map +1 -0
- package/lib/types/components/sidePanel/usePanelInput.js +44 -0
- package/lib/types/components/sidePanel/useSidePanel.d.ts +47 -0
- package/lib/types/components/sidePanel/useSidePanel.d.ts.map +1 -0
- package/lib/types/components/sidePanel/useSidePanel.js +284 -0
- package/lib/types/components/workspaces/HomeWorkspaceRow.d.ts +3 -1
- package/lib/types/components/workspaces/HomeWorkspaceRow.d.ts.map +1 -1
- package/lib/types/components/workspaces/HomeWorkspaceRow.js +3 -2
- package/lib/types/deepseekPricing.d.ts +10 -9
- package/lib/types/deepseekPricing.d.ts.map +1 -1
- package/lib/types/deepseekPricing.js +18 -11
- package/lib/types/dsh-adapter/channel/attached-context.d.ts +58 -0
- package/lib/types/dsh-adapter/channel/attached-context.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/attached-context.js +109 -0
- package/lib/types/dsh-adapter/channel/binding-events.d.ts +6 -0
- package/lib/types/dsh-adapter/channel/binding-events.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/binding-events.js +43 -0
- package/lib/types/dsh-adapter/channel/capabilities.d.ts +82 -0
- package/lib/types/dsh-adapter/channel/capabilities.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/capabilities.js +165 -0
- package/lib/types/dsh-adapter/channel/command-completions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/command-completions.js +8 -0
- package/lib/types/dsh-adapter/channel/context-bookkeeping.d.ts +4 -12
- package/lib/types/dsh-adapter/channel/context-bookkeeping.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/context-bookkeeping.js +9 -4
- package/lib/types/dsh-adapter/channel/input-delivery.d.ts +13 -2
- package/lib/types/dsh-adapter/channel/input-delivery.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/input-delivery.js +18 -1
- package/lib/types/dsh-adapter/channel/mode-actions.d.ts +0 -3
- package/lib/types/dsh-adapter/channel/mode-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/mode-actions.js +7 -2
- package/lib/types/dsh-adapter/channel/mode-permission-actions.d.ts +8 -1
- package/lib/types/dsh-adapter/channel/mode-permission-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/mode-permission-actions.js +0 -1
- package/lib/types/dsh-adapter/channel/preferences.d.ts +1 -1
- package/lib/types/dsh-adapter/channel/preferences.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/preferences.js +9 -1
- package/lib/types/dsh-adapter/channel/projection.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/projection.js +42 -37
- package/lib/types/dsh-adapter/channel/reports.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/reports.js +13 -4
- package/lib/types/dsh-adapter/channel/session-reset.d.ts +5 -1
- package/lib/types/dsh-adapter/channel/session-reset.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/session-reset.js +1 -0
- package/lib/types/dsh-adapter/channel/state.d.ts +18 -2
- package/lib/types/dsh-adapter/channel/state.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/state.js +2 -1
- package/lib/types/dsh-adapter/channel/types.d.ts +1 -1
- package/lib/types/dsh-adapter/channel/types.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/usage.d.ts +18 -1
- package/lib/types/dsh-adapter/channel/usage.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/usage.js +97 -2
- package/lib/types/dsh-adapter/channel.d.ts +1 -1
- package/lib/types/dsh-adapter/channel.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel.js +56 -3
- package/lib/types/dsh-adapter/context-occupancy.d.ts +204 -0
- package/lib/types/dsh-adapter/context-occupancy.d.ts.map +1 -0
- package/lib/types/dsh-adapter/context-occupancy.js +299 -0
- package/lib/types/dsh-adapter/contract.d.ts +14 -0
- package/lib/types/dsh-adapter/contract.d.ts.map +1 -1
- package/lib/types/dsh-adapter/contract.js +24 -0
- package/lib/types/dsh-adapter/index.d.ts +32 -0
- package/lib/types/dsh-adapter/index.d.ts.map +1 -1
- package/lib/types/dsh-adapter/index.js +20 -1
- package/lib/types/dsh-adapter/migrate/sessionize.d.ts.map +1 -1
- package/lib/types/dsh-adapter/migrate/sessionize.js +11 -12
- package/lib/types/dsh-adapter/panel-runtime-registry.d.ts +39 -0
- package/lib/types/dsh-adapter/panel-runtime-registry.d.ts.map +1 -0
- package/lib/types/dsh-adapter/panel-runtime-registry.js +84 -0
- package/lib/types/dsh-adapter/panels.d.ts +251 -0
- package/lib/types/dsh-adapter/panels.d.ts.map +1 -0
- package/lib/types/dsh-adapter/panels.js +407 -0
- package/lib/types/dsh-adapter/plugin-host.js +1 -1
- package/lib/types/dsh-adapter/plugin.d.ts +17 -1
- package/lib/types/dsh-adapter/plugin.d.ts.map +1 -1
- package/lib/types/dsh-adapter/plugin.js +169 -32
- package/lib/types/dsh-adapter/presets.d.ts +26 -6
- package/lib/types/dsh-adapter/presets.d.ts.map +1 -1
- package/lib/types/dsh-adapter/presets.js +29 -7
- package/lib/types/dsh-adapter/startup-args.d.ts +8 -0
- package/lib/types/dsh-adapter/startup-args.d.ts.map +1 -0
- package/lib/types/dsh-adapter/startup-args.js +34 -0
- package/lib/types/history.d.ts +24 -7
- package/lib/types/history.d.ts.map +1 -1
- package/lib/types/history.js +77 -18
- package/lib/types/i18n.d.ts +734 -15
- package/lib/types/i18n.d.ts.map +1 -1
- package/lib/types/i18n.js +302 -6
- package/lib/types/ink/components/App.d.ts +14 -1
- package/lib/types/ink/components/App.d.ts.map +1 -1
- package/lib/types/ink/components/App.js +62 -61
- package/lib/types/ink/components/TerminalSizeContext.d.ts +7 -0
- package/lib/types/ink/components/TerminalSizeContext.d.ts.map +1 -1
- package/lib/types/ink/hooks/use-input.d.ts +11 -0
- package/lib/types/ink/hooks/use-input.d.ts.map +1 -1
- package/lib/types/ink/hooks/use-input.js +8 -2
- package/lib/types/ink/hooks/use-terminal-viewport.d.ts.map +1 -1
- package/lib/types/ink/hooks/use-terminal-viewport.js +3 -1
- package/lib/types/ink/ink.d.ts +18 -0
- package/lib/types/ink/ink.d.ts.map +1 -1
- package/lib/types/ink/ink.js +51 -8
- package/lib/types/ink/output.d.ts +10 -1
- package/lib/types/ink/output.d.ts.map +1 -1
- package/lib/types/ink/output.js +3 -3
- package/lib/types/ink/parse-keypress.d.ts +36 -3
- package/lib/types/ink/parse-keypress.d.ts.map +1 -1
- package/lib/types/ink/parse-keypress.js +262 -108
- package/lib/types/ink/render-node-to-output.d.ts +1 -1
- package/lib/types/ink/render-node-to-output.d.ts.map +1 -1
- package/lib/types/ink/render-node-to-output.js +37 -5
- package/lib/types/ink/screen.d.ts +26 -1
- package/lib/types/ink/screen.d.ts.map +1 -1
- package/lib/types/ink/screen.js +96 -1
- package/lib/types/ink/selection.d.ts +23 -1
- package/lib/types/ink/selection.d.ts.map +1 -1
- package/lib/types/ink/selection.js +102 -26
- package/lib/types/ink/sixel-codec.d.ts +11 -0
- package/lib/types/ink/sixel-codec.d.ts.map +1 -1
- package/lib/types/ink/sixel-codec.js +42 -8
- package/lib/types/math/renderer.d.ts +2 -0
- package/lib/types/math/renderer.d.ts.map +1 -1
- package/lib/types/math/renderer.js +4 -0
- package/lib/types/onboardingPrefs.d.ts +52 -0
- package/lib/types/onboardingPrefs.d.ts.map +1 -0
- package/lib/types/onboardingPrefs.js +107 -0
- package/lib/types/panels.d.ts +4 -0
- package/lib/types/panels.d.ts.map +1 -0
- package/lib/types/panels.js +4 -0
- package/lib/types/screens/Chat.d.ts +22 -1
- package/lib/types/screens/Chat.d.ts.map +1 -1
- package/lib/types/screens/Chat.js +1126 -299
- package/lib/types/screens/Launchpad.d.ts +194 -0
- package/lib/types/screens/Launchpad.d.ts.map +1 -0
- package/lib/types/screens/Launchpad.js +607 -0
- package/lib/types/screens/Onboarding.d.ts +37 -0
- package/lib/types/screens/Onboarding.d.ts.map +1 -0
- package/lib/types/screens/Onboarding.js +492 -0
- package/lib/types/screens/SessionSupervisor.d.ts.map +1 -1
- package/lib/types/screens/SessionSupervisor.js +18 -12
- package/lib/types/screens/StatusLine.d.ts.map +1 -1
- package/lib/types/screens/StatusLine.js +32 -14
- package/lib/types/screens/StatusMetrics.d.ts +22 -0
- package/lib/types/screens/StatusMetrics.d.ts.map +1 -1
- package/lib/types/screens/StatusMetrics.js +20 -0
- package/lib/types/screens/chatOverlay.d.ts +18 -1
- package/lib/types/screens/chatOverlay.d.ts.map +1 -1
- package/lib/types/screens/chatOverlay.js +3 -0
- package/lib/types/screens/sessionSupervisor/model.d.ts +1 -2
- package/lib/types/screens/sessionSupervisor/model.d.ts.map +1 -1
- package/lib/types/screens/sessionSupervisor/model.js +4 -2
- package/lib/types/screens/sessionSupervisor/useSessionSupervisor.d.ts.map +1 -1
- package/lib/types/screens/sessionSupervisor/useSessionSupervisor.js +7 -3
- package/lib/types/settings/definitions.d.ts +93 -0
- package/lib/types/settings/definitions.d.ts.map +1 -1
- package/lib/types/settings/definitions.js +83 -0
- package/lib/types/tips.js +5 -5
- package/lib/types/tuiDisplayPrefs.d.ts +42 -2
- package/lib/types/tuiDisplayPrefs.d.ts.map +1 -1
- package/lib/types/tuiDisplayPrefs.js +74 -0
- package/lib/types/update.d.ts +53 -9
- package/lib/types/update.d.ts.map +1 -1
- package/lib/types/update.js +101 -44
- package/lib/types/utils/bmp.d.ts.map +1 -1
- package/lib/types/utils/bmp.js +8 -1
- package/lib/types/utils/clipboard.d.ts.map +1 -1
- package/lib/types/utils/clipboard.js +25 -6
- package/lib/types/utils/credentials.d.ts.map +1 -1
- package/lib/types/utils/credentials.js +5 -1
- package/lib/types/utils/draftWordBoundary.d.ts +23 -0
- package/lib/types/utils/draftWordBoundary.d.ts.map +1 -0
- package/lib/types/utils/draftWordBoundary.js +161 -0
- package/lib/types/utils/fileTarget.d.ts.map +1 -1
- package/lib/types/utils/fileTarget.js +7 -9
- package/lib/types/utils/inputPaste.d.ts +62 -0
- package/lib/types/utils/inputPaste.d.ts.map +1 -0
- package/lib/types/utils/inputPaste.js +111 -0
- package/lib/types/utils/intl.d.ts +8 -0
- package/lib/types/utils/intl.d.ts.map +1 -1
- package/lib/types/utils/intl.js +11 -0
- package/lib/types/utils/keymap.d.ts +13 -3
- package/lib/types/utils/keymap.d.ts.map +1 -1
- package/lib/types/utils/keymap.js +27 -5
- package/package.json +19 -8
- package/{dsh-ecosystem-spec → tui-profile}/registry/README.md +1 -1
- package/{dsh-ecosystem-spec → tui-profile}/registry/registry-0.15.json +1 -1
- /package/{dsh-ecosystem-spec → tui-profile}/protocols/profile-definitions.d.ts +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/protocols/profile-definitions.js +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/protocols/tui-channel-http.d.ts +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/protocols/tui-channel-http.js +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/protocols/tui-channel.d.ts +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/protocols/tui-channel.js +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/protocols/tui-contributions.d.ts +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/protocols/tui-contributions.js +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/registry/contracts/decision-events-v1alpha1.json +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/registry/contracts/scene-v1alpha1.json +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/registry/contracts/settings-section-v1alpha1.json +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/registry/contracts/tui-channel-v1alpha1.json +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/registry/contracts/workspace-provider-v1alpha1.json +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/registry/host-descriptor.tui.example.json +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/registry/permissions-0.1.json +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/schemas/conformance-claim.schema.json +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/schemas/effect-ledger-record.schema.json +0 -0
- /package/{dsh-ecosystem-spec → tui-profile}/schemas/host-descriptor.schema.json +0 -0
|
@@ -0,0 +1,492 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { Box, Text, useInput, useTerminalSize } from '../ui.js';
|
|
4
|
+
import { Divider } from '../components/design-system/Divider.js';
|
|
5
|
+
import { HintLine } from '../components/design-system/HintLine.js';
|
|
6
|
+
import { ListItem } from '../components/design-system/ListItem.js';
|
|
7
|
+
import { LangPicker } from '../components/LangPicker.js';
|
|
8
|
+
import { ThemePicker } from '../components/ThemePicker.js';
|
|
9
|
+
import { EffortSlider } from '../components/EffortSlider.js';
|
|
10
|
+
import { listWindow } from '../components/listWindow.js';
|
|
11
|
+
import { WorkspacePicker } from '../components/WorkspacePicker.js';
|
|
12
|
+
import { getThemeOptions } from '../components/ThemePicker.js';
|
|
13
|
+
import { useTheme } from '../components/design-system/ThemeProvider.js';
|
|
14
|
+
import { t, getLang, LANGS } from '../i18n.js';
|
|
15
|
+
import { isPlainReturn } from '../utils/modifiers.js';
|
|
16
|
+
import { LoadingState } from '../components/design-system/LoadingState.js';
|
|
17
|
+
import { ONBOARDING_STEPS, STEP_BAR_MIN_COLUMNS, STEP_BAR_MIN_ROWS, TUTORIAL_CARDS, connFailText, credentialSourceText, formatBalance, modelGroupsOf, stepDescKey, stepTitleKey, } from '../components/onboardingModel.js';
|
|
18
|
+
/**
|
|
19
|
+
* 打断类键位卡上显示的键。
|
|
20
|
+
*
|
|
21
|
+
* `Esc` 与 `Ctrl+C` 是**硬绑定**,不在 `utils/keymap` 的可重绑动作表里
|
|
22
|
+
* (那张表是可配置动作的白名单),所以这里不调 `effectiveComboDisplay`——
|
|
23
|
+
* 那个函数的入参是 `ShortcutActionId`,塞一个不在表里的 id 进去是编译期
|
|
24
|
+
* 就能抓到的错误,也正是它拦住我不去编一个不存在的动作。
|
|
25
|
+
*/
|
|
26
|
+
const CANCEL_COMBO = 'Esc · Ctrl+C';
|
|
27
|
+
/** 模型区的行数(分组层 = provider 数;列表层 = 该 provider 的模型数)。 */
|
|
28
|
+
function modelRowCount(models, group, providers) {
|
|
29
|
+
const listed = models ?? [];
|
|
30
|
+
if (group === undefined)
|
|
31
|
+
return modelGroupsOf(listed, providers).length;
|
|
32
|
+
return listed.filter(model => model.provider === group).length;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Onboarding —— 首次运行的引导向导(`~/.dsh-tui/onboarding.json` 走一次性记账)。
|
|
36
|
+
*
|
|
37
|
+
* 身为一个屏幕,它跟 `SessionSupervisor` 同规矩:所有 hook 先跑完,再由
|
|
38
|
+
* `Chat` 的渲染链提前 return。它**自己读 channel**(`describeCredential` /
|
|
39
|
+
* `balanceInfo` / `listModels` / `listWorkspaces`…),不把十几份数据从 Chat
|
|
40
|
+
* 传进来——那正是 supervisor 的做法。
|
|
41
|
+
*
|
|
42
|
+
* 键盘归它独占(`Chat` 在 `supervisorOpen` 那一层之前让位),所以每一步
|
|
43
|
+
* 的 picker 都能借用同一份 `focusIndex`,不需要各自注册 `useInput`。
|
|
44
|
+
*
|
|
45
|
+
* **凭证永远只报"有没有",不报值**:`describeCredential` 回的是不含秘密的
|
|
46
|
+
* 元数据,界面上也照它的原样画。
|
|
47
|
+
*/
|
|
48
|
+
export function Onboarding({ channel, themeHost, onClose, onRunCommand, onApplyLang, initialStep = 0, externalNotice, }) {
|
|
49
|
+
const { columns, rows } = useTerminalSize();
|
|
50
|
+
const [stepIndex, setStepIndex] = React.useState(() => Math.max(0, Math.min(initialStep, ONBOARDING_STEPS.length - 1)));
|
|
51
|
+
const step = ONBOARDING_STEPS[stepIndex];
|
|
52
|
+
const [focusIndex, setFocusIndex] = React.useState(0);
|
|
53
|
+
const [notice, setNotice] = React.useState(externalNotice);
|
|
54
|
+
// ── 第一步:凭证 + 连通性 ────────────────────────────────────────────
|
|
55
|
+
const [credential, setCredential] = React.useState(undefined);
|
|
56
|
+
const [conn, setConn] = React.useState({ kind: 'idle' });
|
|
57
|
+
const [checkNonce, setCheckNonce] = React.useState(0);
|
|
58
|
+
React.useEffect(() => {
|
|
59
|
+
let alive = true;
|
|
60
|
+
setCredential(undefined);
|
|
61
|
+
setConn({ kind: 'running' });
|
|
62
|
+
void (async () => {
|
|
63
|
+
const status = await channel.describeCredential('DEEPSEEK_API_KEY').catch(() => undefined);
|
|
64
|
+
if (!alive)
|
|
65
|
+
return;
|
|
66
|
+
setCredential(status);
|
|
67
|
+
const [models, balance] = await Promise.all([
|
|
68
|
+
channel.listModels().catch(() => []),
|
|
69
|
+
channel.balanceInfo().catch(() => ({ ok: false, reason: 'network' })),
|
|
70
|
+
]);
|
|
71
|
+
if (!alive)
|
|
72
|
+
return;
|
|
73
|
+
// 连通性的判定口径:余额接口是唯一一次真的打服务端的调用,所以以它
|
|
74
|
+
// 为准;模型列表只用来给成功态添一个数字(某些 provider 会走缓存)。
|
|
75
|
+
setConn(balance.ok
|
|
76
|
+
? { kind: 'ok', models: models.length, balance: formatBalance(balance) }
|
|
77
|
+
: {
|
|
78
|
+
kind: 'fail',
|
|
79
|
+
reason: balance.reason,
|
|
80
|
+
status: balance.ok ? undefined : balance.status,
|
|
81
|
+
});
|
|
82
|
+
})();
|
|
83
|
+
return () => {
|
|
84
|
+
alive = false;
|
|
85
|
+
};
|
|
86
|
+
}, [channel, checkNonce]);
|
|
87
|
+
// ── 第二步:语言 + 主题 ──────────────────────────────────────────────
|
|
88
|
+
const [themeName, setTheme] = useTheme();
|
|
89
|
+
const [lookPane, setLookPane] = React.useState('lang');
|
|
90
|
+
const [langIndex, setLangIndex] = React.useState(() => Math.max(0, LANGS.indexOf(getLang())));
|
|
91
|
+
const themeOptions = React.useMemo(() => getThemeOptions(themeHost), [themeHost]);
|
|
92
|
+
const [themeIndex, setThemeIndex] = React.useState(() => {
|
|
93
|
+
const index = themeOptions.findIndex(option => option.value === themeName);
|
|
94
|
+
return index >= 0 ? index : 0;
|
|
95
|
+
});
|
|
96
|
+
// ── 第三步:模型 / 强度 / 工作区 ─────────────────────────────────────
|
|
97
|
+
const [zone, setZone] = React.useState('model');
|
|
98
|
+
const [models, setModels] = React.useState(null);
|
|
99
|
+
const [providers, setProviders] = React.useState([]);
|
|
100
|
+
const [efforts, setEfforts] = React.useState([]);
|
|
101
|
+
const [effortIndex, setEffortIndex] = React.useState(0);
|
|
102
|
+
const [workspaces, setWorkspaces] = React.useState(null);
|
|
103
|
+
const [workspaceOpen, setWorkspaceOpen] = React.useState(false);
|
|
104
|
+
const [workspaceIndex, setWorkspaceIndex] = React.useState(0);
|
|
105
|
+
const [modelGroup, setModelGroup] = React.useState(undefined);
|
|
106
|
+
React.useEffect(() => {
|
|
107
|
+
let alive = true;
|
|
108
|
+
void (async () => {
|
|
109
|
+
const listed = await channel.listModels().catch(() => []);
|
|
110
|
+
const providerInfos = await channel.listProviders().catch(() => []);
|
|
111
|
+
const { efforts: tiers, defaultEffort } = await channel.listEfforts()
|
|
112
|
+
.catch(() => ({ efforts: [], defaultEffort: undefined }));
|
|
113
|
+
if (!alive)
|
|
114
|
+
return;
|
|
115
|
+
setModels(listed);
|
|
116
|
+
setProviders(providerInfos);
|
|
117
|
+
setEfforts(tiers);
|
|
118
|
+
const current = channel.reasoningEffort ?? defaultEffort;
|
|
119
|
+
const index = tiers.findIndex(tier => tier.id === current);
|
|
120
|
+
setEffortIndex(index >= 0 ? index : 0);
|
|
121
|
+
})();
|
|
122
|
+
return () => {
|
|
123
|
+
alive = false;
|
|
124
|
+
};
|
|
125
|
+
}, [channel]);
|
|
126
|
+
// ── 第四步:招式卡 ──────────────────────────────────────────────────
|
|
127
|
+
const [tried, setTried] = React.useState(() => new Set());
|
|
128
|
+
const finish = React.useCallback((outcome) => {
|
|
129
|
+
onClose(outcome);
|
|
130
|
+
}, [onClose]);
|
|
131
|
+
const goToStep = React.useCallback((next) => {
|
|
132
|
+
// 夹到**最后一格**,不是 `length`:越界会让 `step` 变成 undefined,
|
|
133
|
+
// 正文整块消失、只剩一个没有内容的空步(`→` 在最后一步上就会踩到)。
|
|
134
|
+
const clamped = Math.max(0, Math.min(next, ONBOARDING_STEPS.length - 1));
|
|
135
|
+
setFocusIndex(0);
|
|
136
|
+
setNotice(undefined);
|
|
137
|
+
setStepIndex(clamped);
|
|
138
|
+
}, []);
|
|
139
|
+
/** 进入下一步;最后一步的"下一步"就是完成。 */
|
|
140
|
+
const advance = React.useCallback(() => {
|
|
141
|
+
if (stepIndex >= ONBOARDING_STEPS.length - 1) {
|
|
142
|
+
finish('done');
|
|
143
|
+
return;
|
|
144
|
+
}
|
|
145
|
+
goToStep(stepIndex + 1);
|
|
146
|
+
}, [finish, goToStep, stepIndex]);
|
|
147
|
+
const openWorkspacePicker = React.useCallback(() => {
|
|
148
|
+
setWorkspaceOpen(true);
|
|
149
|
+
setWorkspaceIndex(0);
|
|
150
|
+
if (workspaces === null) {
|
|
151
|
+
void channel.listWorkspaces().then((targets) => {
|
|
152
|
+
setWorkspaces(targets);
|
|
153
|
+
const index = targets.findIndex(target => target.cwd === channel.cwd);
|
|
154
|
+
setWorkspaceIndex(index >= 0 ? index : 0);
|
|
155
|
+
}).catch(() => setWorkspaces([]));
|
|
156
|
+
}
|
|
157
|
+
}, [channel, workspaces]);
|
|
158
|
+
const applyTheme = React.useCallback((index) => {
|
|
159
|
+
const option = themeOptions[index];
|
|
160
|
+
if (option === undefined)
|
|
161
|
+
return;
|
|
162
|
+
// 与 `/theme <name>` 同一条路:`setTheme` 自己校验并落盘 theme.json。
|
|
163
|
+
setTheme(option.value);
|
|
164
|
+
}, [setTheme, themeOptions]);
|
|
165
|
+
const pickCard = React.useCallback((card, tryIt) => {
|
|
166
|
+
if (!tryIt || card.command === undefined)
|
|
167
|
+
return;
|
|
168
|
+
setTried(previous => new Set(previous).add(card.id));
|
|
169
|
+
onRunCommand(card.command);
|
|
170
|
+
}, [onRunCommand]);
|
|
171
|
+
/** 当前这一步有多少可移动的行(决定 ↑/↓ 的上限与回车落点)。 */
|
|
172
|
+
const rowCount = step === 'apikey'
|
|
173
|
+
? 1
|
|
174
|
+
: step === 'look'
|
|
175
|
+
? (lookPane === 'lang' ? LANGS.length : themeOptions.length)
|
|
176
|
+
: step === 'model'
|
|
177
|
+
? (zone === 'model' ? modelRowCount(models, modelGroup, providers) : zone === 'effort' ? efforts.length : 1)
|
|
178
|
+
: TUTORIAL_CARDS.length;
|
|
179
|
+
useInput((input, key, event) => {
|
|
180
|
+
// 工作区选择是引导内部的模态层:开着的时候键盘全归它。
|
|
181
|
+
if (workspaceOpen) {
|
|
182
|
+
const targets = workspaces ?? [];
|
|
183
|
+
if (key.escape) {
|
|
184
|
+
setWorkspaceOpen(false);
|
|
185
|
+
return;
|
|
186
|
+
}
|
|
187
|
+
if (key.upArrow || key.downArrow) {
|
|
188
|
+
setWorkspaceIndex(previous => Math.max(0, Math.min(previous + (key.upArrow ? -1 : 1), Math.max(0, targets.length - 1))));
|
|
189
|
+
return;
|
|
190
|
+
}
|
|
191
|
+
if (isPlainReturn(key)) {
|
|
192
|
+
const target = targets[workspaceIndex];
|
|
193
|
+
setWorkspaceOpen(false);
|
|
194
|
+
if (target === undefined)
|
|
195
|
+
return;
|
|
196
|
+
void channel.switchWorkspace(target).then((ok) => {
|
|
197
|
+
setWorkspaces(null);
|
|
198
|
+
setNotice(ok
|
|
199
|
+
? t('onboarding-workspace-switched', { name: target.label })
|
|
200
|
+
: t('onboarding-workspace-failed', { name: target.label }));
|
|
201
|
+
});
|
|
202
|
+
}
|
|
203
|
+
return;
|
|
204
|
+
}
|
|
205
|
+
if (key.ctrl && input === 'c') {
|
|
206
|
+
finish('skipped');
|
|
207
|
+
event.stopImmediatePropagation();
|
|
208
|
+
return;
|
|
209
|
+
}
|
|
210
|
+
if (key.escape) {
|
|
211
|
+
// 模型分组钻进去之后,Esc 先退一层。这条判定必须排在"跳过整个向导"**之前**:
|
|
212
|
+
// 它原来写在 model 分支里(在全局 Esc 之后)永远轮不到,钻进去就成了单向门。
|
|
213
|
+
if (step === 'model' && modelGroup !== undefined) {
|
|
214
|
+
setModelGroup(undefined);
|
|
215
|
+
setFocusIndex(0);
|
|
216
|
+
event.stopImmediatePropagation();
|
|
217
|
+
return;
|
|
218
|
+
}
|
|
219
|
+
finish('skipped');
|
|
220
|
+
event.stopImmediatePropagation();
|
|
221
|
+
return;
|
|
222
|
+
}
|
|
223
|
+
// 左右换步骤——引导自己的骨架,不跟任何 picker 抢(那些用 ↑/↓ 与
|
|
224
|
+
// 各自的 ←/→;这里把它们让给 picker 的是 `lookPane === 'theme'` 与
|
|
225
|
+
// `zone === 'effort'` 两个分支)。
|
|
226
|
+
// 只有**真的有人接**的横向键才从骨架手里拿走:强度滑块与钻进去之后的
|
|
227
|
+
// 模型层。语言 / 主题两个面板都是纯展示(`Select` / `ThemePicker` 都不
|
|
228
|
+
// 注册 `useInput`,`onPick` 收的是 ClickEvent),把 ←/→ 让出去只会让它们
|
|
229
|
+
// 变成死键——而底部提示写的是「←/→ 换步骤」。
|
|
230
|
+
const horizontalOwnedByChild = (step === 'model' && zone === 'effort')
|
|
231
|
+
|| (step === 'model' && zone === 'model' && modelGroup !== undefined);
|
|
232
|
+
if (!horizontalOwnedByChild && (key.leftArrow || key.rightArrow)) {
|
|
233
|
+
goToStep(stepIndex + (key.leftArrow ? -1 : 1));
|
|
234
|
+
event.stopImmediatePropagation();
|
|
235
|
+
return;
|
|
236
|
+
}
|
|
237
|
+
if (key.tab) {
|
|
238
|
+
if (step === 'look')
|
|
239
|
+
setLookPane(previous => (previous === 'lang' ? 'theme' : 'lang'));
|
|
240
|
+
if (step === 'model') {
|
|
241
|
+
setZone(previous => previous === 'model' ? 'effort' : previous === 'effort' ? 'workspace' : 'model');
|
|
242
|
+
}
|
|
243
|
+
event.stopImmediatePropagation();
|
|
244
|
+
return;
|
|
245
|
+
}
|
|
246
|
+
if (step === 'look') {
|
|
247
|
+
if (key.upArrow || key.downArrow) {
|
|
248
|
+
const count = lookPane === 'lang' ? LANGS.length : themeOptions.length;
|
|
249
|
+
setFocusIndex(previous => Math.max(0, Math.min(previous + (key.upArrow ? -1 : 1), count - 1)));
|
|
250
|
+
// 主题**实时预览**:移动光标就换,回车只是把焦点钉住继续。这与
|
|
251
|
+
// `/theme` picker 的"只换色块预览"不同——引导里用户是来试穿的,
|
|
252
|
+
// 看不见整体效果就没法选。离开这一步不还原:`setTheme` 已经落盘,
|
|
253
|
+
// 半途反悔的用户可以在 /settings 里改回去,而"悄悄退回原样"会让
|
|
254
|
+
// 他刚看到的选择凭空消失。
|
|
255
|
+
if (lookPane === 'theme')
|
|
256
|
+
applyTheme(Math.max(0, Math.min(focusIndex + (key.upArrow ? -1 : 1), themeOptions.length - 1)));
|
|
257
|
+
return;
|
|
258
|
+
}
|
|
259
|
+
if (isPlainReturn(key)) {
|
|
260
|
+
// 两个面板的键盘路径都归这里:picker 自己只处理鼠标点击。
|
|
261
|
+
if (lookPane === 'theme')
|
|
262
|
+
applyTheme(focusIndex);
|
|
263
|
+
else {
|
|
264
|
+
const lang = LANGS[Math.min(focusIndex, LANGS.length - 1)];
|
|
265
|
+
if (lang !== undefined)
|
|
266
|
+
onApplyLang(lang);
|
|
267
|
+
}
|
|
268
|
+
advance();
|
|
269
|
+
return;
|
|
270
|
+
}
|
|
271
|
+
return;
|
|
272
|
+
}
|
|
273
|
+
if (step === 'model') {
|
|
274
|
+
if (zone === 'effort') {
|
|
275
|
+
if (isPlainReturn(key)) {
|
|
276
|
+
// Enter 的语义 = "这一格到此为止、进入下一个区域":滑块本身就是
|
|
277
|
+
// 控件(←/→ 移动即 setEffort 生效),Enter 再去"应用"是空操作;
|
|
278
|
+
// 而整个向导里 Enter 的分工都是"落点/前进"(钻分组、换模型、
|
|
279
|
+
// 开工作区、完成),所以这里对齐 Tab 的走法把焦点交给下一个区域
|
|
280
|
+
// (工作区),不给它第三种含义——否则滑块上的 Enter 就是死键。
|
|
281
|
+
setZone('workspace');
|
|
282
|
+
event.stopImmediatePropagation();
|
|
283
|
+
return;
|
|
284
|
+
}
|
|
285
|
+
if (key.leftArrow || key.rightArrow) {
|
|
286
|
+
const next = Math.max(0, Math.min(effortIndex + (key.leftArrow ? -1 : 1), efforts.length - 1));
|
|
287
|
+
setEffortIndex(next);
|
|
288
|
+
const option = efforts[next];
|
|
289
|
+
// 与 `/effort` 滑块同一条路:滑块本身就是控件,移动即生效。
|
|
290
|
+
if (option !== undefined) {
|
|
291
|
+
void channel.setEffort(option.id);
|
|
292
|
+
setNotice(t('onboarding-effort-switched', { name: option.name }));
|
|
293
|
+
}
|
|
294
|
+
event.stopImmediatePropagation();
|
|
295
|
+
}
|
|
296
|
+
return;
|
|
297
|
+
}
|
|
298
|
+
if (zone === 'workspace') {
|
|
299
|
+
if (isPlainReturn(key))
|
|
300
|
+
openWorkspacePicker();
|
|
301
|
+
return;
|
|
302
|
+
}
|
|
303
|
+
// 模型区:第一层是 provider 分组,进去之后是模型列表。
|
|
304
|
+
if (key.upArrow || key.downArrow) {
|
|
305
|
+
setFocusIndex(previous => Math.max(0, Math.min(previous + (key.upArrow ? -1 : 1), Math.max(0, rowCount - 1))));
|
|
306
|
+
return;
|
|
307
|
+
}
|
|
308
|
+
if (isPlainReturn(key)) {
|
|
309
|
+
const groups = modelGroupsOf(models ?? [], providers);
|
|
310
|
+
if (modelGroup === undefined) {
|
|
311
|
+
const group = groups[focusIndex];
|
|
312
|
+
if (group === undefined)
|
|
313
|
+
return;
|
|
314
|
+
setModelGroup(group.provider);
|
|
315
|
+
setFocusIndex(0);
|
|
316
|
+
return;
|
|
317
|
+
}
|
|
318
|
+
const model = (models ?? []).filter(entry => entry.provider === modelGroup)[focusIndex];
|
|
319
|
+
if (model === undefined)
|
|
320
|
+
return;
|
|
321
|
+
void channel.switchModel(model.provider, model.id).then((ok) => {
|
|
322
|
+
setNotice(ok
|
|
323
|
+
? t('onboarding-model-switched', { name: model.name })
|
|
324
|
+
: t('onboarding-model-switch-failed', { name: model.name }));
|
|
325
|
+
});
|
|
326
|
+
return;
|
|
327
|
+
}
|
|
328
|
+
return;
|
|
329
|
+
}
|
|
330
|
+
if (step === 'keys') {
|
|
331
|
+
if (key.upArrow || key.downArrow) {
|
|
332
|
+
setFocusIndex(previous => Math.max(0, Math.min(previous + (key.upArrow ? -1 : 1), TUTORIAL_CARDS.length - 1)));
|
|
333
|
+
return;
|
|
334
|
+
}
|
|
335
|
+
if (isPlainReturn(key)) {
|
|
336
|
+
const card = TUTORIAL_CARDS[focusIndex];
|
|
337
|
+
// 键位卡(没有命令的)不假装能试:Enter 归"完成"——底部那行
|
|
338
|
+
// `onboarding-hint-last` 承诺的就是它,而它也是唯一会写
|
|
339
|
+
// `~/.dsh-tui/onboarding.json` 的出口(Esc 走 skipped,刻意不记账)。
|
|
340
|
+
// 命令卡保留"试一下":那是这一屏真正的价值,不能为了出口把它换掉。
|
|
341
|
+
if (card !== undefined && card.command !== undefined)
|
|
342
|
+
pickCard(card, true);
|
|
343
|
+
else
|
|
344
|
+
advance();
|
|
345
|
+
return;
|
|
346
|
+
}
|
|
347
|
+
return;
|
|
348
|
+
}
|
|
349
|
+
// 第一步:只有"重新检查"一个动作。
|
|
350
|
+
if (step === 'apikey' && isPlainReturn(key)) {
|
|
351
|
+
setCheckNonce(nonce => nonce + 1);
|
|
352
|
+
return;
|
|
353
|
+
}
|
|
354
|
+
});
|
|
355
|
+
const onLast = stepIndex >= ONBOARDING_STEPS.length - 1;
|
|
356
|
+
const showSteps = rows >= STEP_BAR_MIN_ROWS && columns >= STEP_BAR_MIN_COLUMNS;
|
|
357
|
+
return (_jsxs(Box, { flexDirection: "column", width: columns, height: rows, children: [_jsx(Box, { height: 1, flexShrink: 0, overflow: "hidden", children: _jsxs(Box, { flexGrow: 1, flexShrink: 1, overflow: "hidden", children: [_jsx(Text, { color: "remember", bold: true, children: t('onboarding-title') }), _jsx(Text, { dimColor: true, children: ' ' + t('onboarding-step-progress', { n: stepIndex + 1, total: ONBOARDING_STEPS.length }) })] }) }), _jsx(Divider, { bleed: true }), showSteps && (_jsx(Box, { flexShrink: 0, overflow: "hidden", children: ONBOARDING_STEPS.map((entry, index) => (_jsx(Box, { flexShrink: 0, children: _jsx(Text, { color: index === stepIndex ? 'suggestion' : index < stepIndex ? 'success' : undefined, dimColor: index > stepIndex, children: ' ' + (index < stepIndex ? '✓' : index === stepIndex ? '❯' : '·') + ' ' + t(stepTitleKey(entry)) }) }, entry))) })), _jsxs(Box, { flexDirection: "column", flexGrow: 1, flexShrink: 1, paddingX: 2, paddingTop: 1, children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { dimColor: true, wrap: "truncate-end", children: t(stepDescKey(step)) }) }), step === 'apikey' && (_jsx(ApiKeyStep, { credential: credential, conn: conn, focusIndex: focusIndex, onRetry: () => setCheckNonce(n => n + 1), onHover: setFocusIndex })), step === 'look' && (_jsxs(Box, { flexDirection: "column", children: [_jsxs(Box, { flexDirection: "row", gap: 4, marginBottom: 1, children: [_jsx(PaneTab, { label: t('lang-picker-title'), active: lookPane === 'lang', onClick: (event) => {
|
|
358
|
+
event.stopImmediatePropagation();
|
|
359
|
+
setLookPane('lang');
|
|
360
|
+
} }), _jsx(PaneTab, { label: t('picker-title-theme'), active: lookPane === 'theme', onClick: (event) => {
|
|
361
|
+
event.stopImmediatePropagation();
|
|
362
|
+
setLookPane('theme');
|
|
363
|
+
} }), _jsx(Box, { children: _jsx(Text, { dimColor: true, children: ' ' + t('onboarding-look-preview-note') }) })] }), lookPane === 'lang' ? (_jsx(LangPicker, { focusIndex: Math.min(focusIndex, LANGS.length - 1), currentLang: getLang(), onPick: (index) => {
|
|
364
|
+
setFocusIndex(index);
|
|
365
|
+
const lang = LANGS[index];
|
|
366
|
+
if (lang !== undefined)
|
|
367
|
+
onApplyLang(lang);
|
|
368
|
+
} })) : (_jsx(ThemePicker, { focusIndex: Math.min(focusIndex, Math.max(0, themeOptions.length - 1)), currentTheme: themeName, themeHost: themeHost, onPick: (index) => {
|
|
369
|
+
setFocusIndex(index);
|
|
370
|
+
applyTheme(index);
|
|
371
|
+
} }))] })), step === 'model' && (_jsx(ModelStep, { channel: channel, models: models, providers: providers, modelGroup: modelGroup, zone: zone, focusIndex: focusIndex, efforts: efforts, effortIndex: effortIndex, workspaceLabel: channel.displayCwd, onFocus: setFocusIndex, onZone: setZone, onDrill: (provider) => {
|
|
372
|
+
setModelGroup(provider);
|
|
373
|
+
setFocusIndex(0);
|
|
374
|
+
}, onBack: () => {
|
|
375
|
+
setModelGroup(undefined);
|
|
376
|
+
setFocusIndex(0);
|
|
377
|
+
}, onModel: (model) => {
|
|
378
|
+
void channel.switchModel(model.provider, model.id).then((ok) => {
|
|
379
|
+
setNotice(ok
|
|
380
|
+
? t('onboarding-model-switched', { name: model.name })
|
|
381
|
+
: t('onboarding-model-switch-failed', { name: model.name }));
|
|
382
|
+
});
|
|
383
|
+
}, onEffort: (index) => {
|
|
384
|
+
setEffortIndex(index);
|
|
385
|
+
const option = efforts[index];
|
|
386
|
+
if (option !== undefined) {
|
|
387
|
+
void channel.setEffort(option.id);
|
|
388
|
+
setNotice(t('onboarding-effort-switched', { name: option.name }));
|
|
389
|
+
}
|
|
390
|
+
}, onOpenWorkspace: openWorkspacePicker })), step === 'keys' && (_jsx(TutorialCards, { focusIndex: focusIndex, tried: tried, onFocus: setFocusIndex, onPick: pickCard }))] }), workspaceOpen && (_jsx(Box, { flexDirection: "column", paddingX: 2, children: _jsx(WorkspacePicker, { targets: workspaces ?? [], focusIndex: workspaceIndex, currentCwd: channel.cwd, onPick: (index) => {
|
|
391
|
+
setWorkspaceIndex(index);
|
|
392
|
+
const target = (workspaces ?? [])[index];
|
|
393
|
+
setWorkspaceOpen(false);
|
|
394
|
+
if (target === undefined)
|
|
395
|
+
return;
|
|
396
|
+
void channel.switchWorkspace(target).then((ok) => {
|
|
397
|
+
setWorkspaces(null);
|
|
398
|
+
setNotice(ok
|
|
399
|
+
? t('onboarding-workspace-switched', { name: target.label })
|
|
400
|
+
: t('onboarding-workspace-failed', { name: target.label }));
|
|
401
|
+
});
|
|
402
|
+
} }) })), notice !== undefined && (_jsx(Box, { paddingX: 2, children: _jsx(Text, { color: "success", wrap: "truncate-end", children: notice }) })), _jsx(Divider, { bleed: true, color: "subtle" }), _jsx(Box, { flexShrink: 0, height: 1, paddingX: 2, children: _jsx(Text, { dimColor: true, italic: true, children: _jsx(HintLine, { text: t(onLast ? 'onboarding-hint-last' : 'onboarding-hint') }) }) })] }));
|
|
403
|
+
}
|
|
404
|
+
/**
|
|
405
|
+
* 第二步顶部的面板标签("[ 界面语言 ]" / "[ 颜色主题 ]")。
|
|
406
|
+
*
|
|
407
|
+
* 以前只是两个纯 Text,视觉上像页签、鼠标却点不动——只有 Tab 能切,
|
|
408
|
+
* 用户实测"颜色主题那里根本没法点"。现在照 ListItem 的既有鼠标契约做成
|
|
409
|
+
* 可点 + 可悬停:只有真的挂了 onClick(可点)才给 onMouseEnter/Leave 与
|
|
410
|
+
* hover 底色(userMessageBackgroundHover),hover 反馈就是"这里能点"的
|
|
411
|
+
* 唯一暗示,契约与 ListItem/Select 完全一致。鼠标事件只在
|
|
412
|
+
* AlternateScreen 里触发(Chat 非 fullscreen 时会包一层),与仓库既定
|
|
413
|
+
* 前提一致。
|
|
414
|
+
*/
|
|
415
|
+
function PaneTab({ label, active, onClick, }) {
|
|
416
|
+
const [hovered, setHovered] = React.useState(false);
|
|
417
|
+
return (_jsx(Box, { onClick: onClick, onMouseEnter: () => setHovered(true), onMouseLeave: () => setHovered(false), backgroundColor: hovered ? 'userMessageBackgroundHover' : undefined, children: _jsx(Text, { color: active ? 'suggestion' : undefined, children: '[ ' + label + ' ]' }) }));
|
|
418
|
+
}
|
|
419
|
+
/** 第一步:凭证状态 + 真连通性检查。 */
|
|
420
|
+
function ApiKeyStep({ credential, conn, focusIndex, onRetry, onHover, }) {
|
|
421
|
+
const configured = credential?.configured === true;
|
|
422
|
+
return (_jsxs(Box, { flexDirection: "column", children: [_jsx(Box, { children: credential === undefined
|
|
423
|
+
? _jsx(Text, { dimColor: true, children: t('onboarding-key-checking') })
|
|
424
|
+
: configured
|
|
425
|
+
? _jsx(Text, { color: "success", children: '✓ ' + t('onboarding-key-configured') })
|
|
426
|
+
: _jsx(Text, { color: "warning", children: '✗ ' + t('onboarding-key-missing') }) }), credential !== undefined && configured && (_jsx(Text, { dimColor: true, children: ' ' + credentialSourceText(credential.source) })), credential !== undefined && !configured && (_jsxs(Box, { flexDirection: "column", marginTop: 1, children: [_jsx(Text, { dimColor: true, children: ' ' + t('onboarding-key-shape') }), _jsx(Text, { dimColor: true, children: ' ' + t('onboarding-key-howto-env') }), _jsx(Text, { children: ' DEEPSEEK_API_KEY=sk-… (PowerShell: $env:DEEPSEEK_API_KEY="sk-…")' }), _jsx(Text, { dimColor: true, children: ' ' + t('onboarding-key-howto-config') }), _jsx(Text, { children: ' ~/.deepseek/config.json { "apiKey": "sk-…" }' })] })), _jsxs(Box, { marginTop: 1, flexDirection: "column", children: [conn.kind === 'running' && _jsx(LoadingState, { message: t('onboarding-conn-running'), dimColor: true }), conn.kind === 'ok' && (_jsxs(Box, { flexDirection: "column", children: [_jsx(Box, { children: _jsx(Text, { color: "success", children: '✓ ' + t('onboarding-conn-ok') }) }), _jsx(Text, { dimColor: true, children: ' ' + t('onboarding-conn-models', { count: conn.models }) }), _jsx(Text, { dimColor: true, children: ' ' + (conn.balance === null ? t('onboarding-conn-balance-none') : t('onboarding-conn-balance', { amount: conn.balance })) })] })), conn.kind === 'fail' && (_jsxs(Box, { flexDirection: "column", children: [_jsx(Box, { children: _jsx(Text, { color: "error", children: '✗ ' + connFailText(conn.reason, conn.status) }) }), _jsx(Box, { marginTop: 1, onMouseEnter: () => onHover(0), children: _jsx(ListItem, { isFocused: focusIndex === 0, declareCursor: false, onClick: (event) => {
|
|
427
|
+
event.stopImmediatePropagation();
|
|
428
|
+
onRetry();
|
|
429
|
+
}, children: t('onboarding-key-retry') }) })] }))] })] }));
|
|
430
|
+
}
|
|
431
|
+
/** 第三步:模型 / 强度 / 工作区三块,Tab 换焦点区。 */
|
|
432
|
+
function ModelStep({ channel, models, providers, modelGroup, zone, focusIndex, efforts, effortIndex, workspaceLabel, onFocus, onZone, onDrill, onBack, onModel, onEffort, onOpenWorkspace, }) {
|
|
433
|
+
if (models === null)
|
|
434
|
+
return _jsx(Text, { dimColor: true, children: t('onboarding-model-loading') });
|
|
435
|
+
const groups = modelGroupsOf(models, providers);
|
|
436
|
+
const rows = modelGroup === undefined ? groups : models.filter(model => model.provider === modelGroup);
|
|
437
|
+
if (models.length === 0)
|
|
438
|
+
return _jsx(Text, { dimColor: true, children: t('onboarding-model-empty') });
|
|
439
|
+
return (_jsxs(Box, { flexDirection: "column", children: [_jsxs(Box, { flexDirection: "column", children: [_jsxs(Box, { children: [_jsx(Text, { color: zone === 'model' ? 'suggestion' : undefined, bold: true, children: t('picker-title-model') }), _jsx(Text, { dimColor: true, children: ' ' + (modelGroup === undefined ? channel.provider : modelGroup) })] }), (() => {
|
|
440
|
+
// 与 /model(ModelPicker)同一条窗口化路:按焦点切片,而不是硬截
|
|
441
|
+
// 前 6 行——用户实测第 7 个及以后的 provider(deepseek-official 就
|
|
442
|
+
// 排在那)被切掉,最该出现的分组反而不见。键盘 ↑/↓ 本就能走到
|
|
443
|
+
// rowCount-1(见 modelRowCount),这里只是让渲染跟上焦点;窗口边
|
|
444
|
+
// 缘用 ListItem 自带的 ▲/▼ 提示还有折叠项。每行恒 1 行高
|
|
445
|
+
// (ListItem 压平换行),listWindow 按行预算即按项数预算。
|
|
446
|
+
const windowRows = 6;
|
|
447
|
+
const focus = zone === 'model' ? Math.min(Math.max(focusIndex, 0), Math.max(0, rows.length - 1)) : 0;
|
|
448
|
+
const { start, end } = listWindow(rows.map(() => 1), focus, windowRows);
|
|
449
|
+
return rows.slice(start, end).map((row, index) => {
|
|
450
|
+
const absoluteIndex = start + index;
|
|
451
|
+
const isGroup = modelGroup === undefined;
|
|
452
|
+
const label = isGroup ? row.label : row.name;
|
|
453
|
+
const key = isGroup ? row.provider : row.id;
|
|
454
|
+
const selected = isGroup
|
|
455
|
+
? row.provider === channel.provider
|
|
456
|
+
: row.id === channel.model;
|
|
457
|
+
return (_jsx(Box, { onMouseEnter: () => { onZone('model'); onFocus(absoluteIndex); }, children: _jsx(ListItem, { isFocused: zone === 'model' && focusIndex === absoluteIndex, isSelected: selected, declareCursor: false, showScrollUp: absoluteIndex === start && start > 0, showScrollDown: absoluteIndex === end - 1 && end < rows.length, onClick: (event) => {
|
|
458
|
+
event.stopImmediatePropagation();
|
|
459
|
+
onZone('model');
|
|
460
|
+
onFocus(absoluteIndex);
|
|
461
|
+
if (isGroup)
|
|
462
|
+
onDrill(row.provider);
|
|
463
|
+
else
|
|
464
|
+
onModel(row);
|
|
465
|
+
}, children: label }) }, key));
|
|
466
|
+
});
|
|
467
|
+
})(), modelGroup !== undefined && (_jsx(Box, { onMouseEnter: () => onZone('model'), children: _jsx(ListItem, { isFocused: false, declareCursor: false, onClick: (event) => {
|
|
468
|
+
event.stopImmediatePropagation();
|
|
469
|
+
onBack();
|
|
470
|
+
}, children: t('onboarding-model-back') }) }))] }), _jsx(Box, { flexDirection: "column", marginTop: 1, children: _jsx(EffortSlider, { options: efforts, focusIndex: effortIndex, currentId: channel.reasoningEffort, onPick: (index) => {
|
|
471
|
+
onZone('effort');
|
|
472
|
+
onEffort(index);
|
|
473
|
+
} }) }), _jsxs(Box, { flexDirection: "column", marginTop: 1, children: [_jsxs(Box, { children: [_jsx(Text, { color: zone === 'workspace' ? 'suggestion' : undefined, bold: true, children: t('onboarding-model-workspace') }), _jsx(Text, { dimColor: true, children: ' ' + t('onboarding-model-workspace-note') })] }), _jsx(Box, { onMouseEnter: () => onZone('workspace'), children: _jsx(ListItem, { isFocused: zone === 'workspace', isSelected: true, declareCursor: false, onClick: (event) => {
|
|
474
|
+
event.stopImmediatePropagation();
|
|
475
|
+
onZone('workspace');
|
|
476
|
+
onOpenWorkspace();
|
|
477
|
+
}, children: workspaceLabel }) })] })] }));
|
|
478
|
+
}
|
|
479
|
+
/** 第四步:招式卡。可试的命令卡多一个"试一下",键位卡只读。 */
|
|
480
|
+
function TutorialCards({ focusIndex, tried, onFocus, onPick, }) {
|
|
481
|
+
return (_jsxs(Box, { flexDirection: "column", children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { dimColor: true, children: t('onboarding-cards-title') }) }), TUTORIAL_CARDS.map((card, index) => {
|
|
482
|
+
const isTried = tried.has(card.id);
|
|
483
|
+
const combo = card.command !== undefined
|
|
484
|
+
? '/' + card.command
|
|
485
|
+
: card.action !== undefined ? CANCEL_COMBO : (card.literal ?? '');
|
|
486
|
+
return (_jsxs(Box, { flexDirection: "column", marginBottom: 1, onMouseEnter: () => onFocus(index), children: [_jsxs(Box, { children: [_jsx(Text, { color: focusIndex === index ? 'suggestion' : undefined, bold: true, children: t(card.titleKey) }), combo !== '' && _jsx(Text, { color: "accent", children: ' ' + combo }), isTried && _jsx(Text, { color: "success", children: ' ' + t('onboarding-card-tried') })] }), _jsx(Box, { paddingLeft: 2, children: _jsx(Text, { dimColor: true, wrap: "truncate-end", children: t(card.descKey) }) }), card.command !== undefined && (_jsx(Box, { paddingLeft: 2, onMouseEnter: () => onFocus(index), children: _jsx(ListItem, { isFocused: focusIndex === index, declareCursor: false, onClick: (event) => {
|
|
487
|
+
event.stopImmediatePropagation();
|
|
488
|
+
onFocus(index);
|
|
489
|
+
onPick(card, true);
|
|
490
|
+
}, children: t('onboarding-card-try') }) }))] }, card.id));
|
|
491
|
+
})] }));
|
|
492
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SessionSupervisor.d.ts","sourceRoot":"","sources":["../../../src/screens/SessionSupervisor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAiD,MAAM,OAAO,CAAA;AAarE,OAAO,EAAE,YAAY,EAAE,MAAM,uCAAuC,CAAA;AAEpE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAA;AASnE,OAAO,KAAK,EAAqB,kBAAkB,EAAE,MAAM,kBAAkB,CAAA;AAC7E,OAAO,KAAK,EAAE,SAAS,IAAI,OAAO,EAAE,MAAM,iCAAiC,CAAA;AAC3E,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAA;AAMpE,OAAO,
|
|
1
|
+
{"version":3,"file":"SessionSupervisor.d.ts","sourceRoot":"","sources":["../../../src/screens/SessionSupervisor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAiD,MAAM,OAAO,CAAA;AAarE,OAAO,EAAE,YAAY,EAAE,MAAM,uCAAuC,CAAA;AAEpE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAA;AASnE,OAAO,KAAK,EAAqB,kBAAkB,EAAE,MAAM,kBAAkB,CAAA;AAC7E,OAAO,KAAK,EAAE,SAAS,IAAI,OAAO,EAAE,MAAM,iCAAiC,CAAA;AAC3E,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAA;AAMpE,OAAO,EAA2L,mBAAmB,EAAsD,mBAAmB,EAAE,MAAM,8BAA8B,CAAA;AACpU,OAAO,EAAE,mBAAmB,EAAE,CAAA;AAE9B;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,wBAAgB,iBAAiB,CAAC,EAChC,OAAO,EACP,IAAI,EACJ,OAAO,EACP,aAAa,EACb,YAAY,EACZ,aAAa,EACb,QAAQ,EACR,SAAS,EACT,WAAW,GACZ,EAAE;IACD,OAAO,EAAE,OAAO,CAAA;IAChB,mDAAmD;IACnD,IAAI,EAAE,MAAM,CAAA;IACZ,kDAAkD;IAClD,OAAO,IAAI,IAAI,CAAA;IACf,qEAAqE;IACrE,aAAa,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,CAAC,CAAA;IACvD,wDAAwD;IACxD,YAAY,CAAC,MAAM,EAAE,kBAAkB,GAAG,OAAO,CAAC,OAAO,CAAC,CAAA;IAC1D,6EAA6E;IAC7E,aAAa,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAAA;IAClD;;;;OAIG;IACH,QAAQ,EAAE,gBAAgB,GAAG,IAAI,CAAA;IACjC,SAAS,CAAC,OAAO,EAAE,cAAc,GAAG,UAAU,GAAG,IAAI,CAAA;IACrD;;;;OAIG;IACH,WAAW,CAAC,SAAS,EAAE,MAAM,GAAG,mBAAmB,GAAG,SAAS,CAAA;CAChE,GAAG,KAAK,CAAC,SAAS,CAmuBlB;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,MAAM,CAOzF;AAED,+EAA+E;AAC/E,OAAO,EAAE,YAAY,EAAE,CAAA"}
|
|
@@ -19,7 +19,7 @@ import { DSH_TAB, useForeignSessions } from './sessionSupervisor/useForeignSessi
|
|
|
19
19
|
import { ForeignSessionPanes } from './sessionSupervisor/ForeignSessionPanes.js';
|
|
20
20
|
import { SourceTabs, layoutSourceTabs, sourceTabsWidth } from '../components/sessions/SourceTabs.js';
|
|
21
21
|
import { stringWidth } from '../ink/stringWidth.js';
|
|
22
|
-
import { SESSION_ROW_LINES,
|
|
22
|
+
import { SESSION_ROW_LINES, MENU_WIDTH, MENU_LABEL_KEYS, menuActionsFor, samePath, sessionMatchesQuery } from './sessionSupervisor/model.js';
|
|
23
23
|
export { sessionMatchesQuery };
|
|
24
24
|
/**
|
|
25
25
|
* The unified session screen — `/resume`, `/agentview`, `/home` and the 🏠
|
|
@@ -54,6 +54,8 @@ export function SessionSupervisor({ channel, home, onClose, onOpenSession, onNew
|
|
|
54
54
|
const inset = React.useContext(PageInsetContext);
|
|
55
55
|
const isTerminalFocused = useTerminalFocus();
|
|
56
56
|
const { entries, sessions, loading, refreshing, notice, setNotice, query, setQuery, holderOf, listedSessions, railEntries, countOf, railFocus, setRailFocus, setFocusSessionId, activePane, pins, menu, setMenu, rename, setRename, confirmRemove, setConfirmRemove, railRef, menuRef, queryRef, now, reload, selected, visibleSessions, sessionIndex, cardFocused, sessionAt, activateList, activateRail, railWidth, railVisible, sessionWidth, railEntryCapacity, sessionListHeight, noticeRows, persistPin, selectEntry, openSession, newSessionIn, renameEntry, removeEntry, stopSession, closeMenu, activateMenu, moveRail, moveSession, focusedSession, } = useSessionSupervisor({ channel, home, onOpenSession, onNewSession, onStopSession, liveStateOf, columns, rows });
|
|
57
|
+
const menuEntry = menu === undefined ? undefined : railEntries.find(entry => samePath(entry.path, menu.path));
|
|
58
|
+
const menuActions = menuEntry === undefined ? [] : menuActionsFor(menuEntry);
|
|
57
59
|
/**
|
|
58
60
|
* The source tab: this screen's own sessions ({@link DSH_TAB}) or another
|
|
59
61
|
* coding agent's, by agent id. Every open starts on DSH — the screen is
|
|
@@ -137,23 +139,25 @@ export function SessionSupervisor({ channel, home, onClose, onOpenSession, onNew
|
|
|
137
139
|
return;
|
|
138
140
|
}
|
|
139
141
|
if (menuRef.current !== undefined) {
|
|
142
|
+
const current = menuRef.current;
|
|
143
|
+
const entry = railEntries.find(candidate => samePath(candidate.path, current.path));
|
|
144
|
+
if (entry === undefined) {
|
|
145
|
+
closeMenu();
|
|
146
|
+
return;
|
|
147
|
+
}
|
|
148
|
+
const actionCount = menuActionsFor(entry).length;
|
|
140
149
|
if (key.upArrow) {
|
|
141
|
-
const
|
|
142
|
-
const next = { ...current, item: (current.item + MENU_ACTIONS.length - 1) % MENU_ACTIONS.length };
|
|
150
|
+
const next = { ...current, item: (current.item + actionCount - 1) % actionCount };
|
|
143
151
|
menuRef.current = next;
|
|
144
152
|
setMenu(next);
|
|
145
153
|
}
|
|
146
154
|
else if (key.downArrow) {
|
|
147
|
-
const
|
|
148
|
-
const next = { ...current, item: (current.item + 1) % MENU_ACTIONS.length };
|
|
155
|
+
const next = { ...current, item: (current.item + 1) % actionCount };
|
|
149
156
|
menuRef.current = next;
|
|
150
157
|
setMenu(next);
|
|
151
158
|
}
|
|
152
159
|
else if (isPlainReturn(key)) {
|
|
153
|
-
|
|
154
|
-
const entry = railEntries.find(candidate => samePath(candidate.path, current.path));
|
|
155
|
-
if (entry !== undefined)
|
|
156
|
-
activateMenu(entry, current.item);
|
|
160
|
+
activateMenu(entry, current.item);
|
|
157
161
|
}
|
|
158
162
|
else {
|
|
159
163
|
closeMenu();
|
|
@@ -399,9 +403,11 @@ export function SessionSupervisor({ channel, home, onClose, onOpenSession, onNew
|
|
|
399
403
|
setTabMenu(next);
|
|
400
404
|
} }) }))] }), _jsx(Divider, { bleed: true }), tab !== DSH_TAB && (_jsx(ForeignSessionPanes, { model: foreign, sourceLabel: activeSource?.label ?? tab, home: home, now: now, query: query, notice: notice, railVisible: railVisible, railWidth: railWidth, railEntryCapacity: railEntryCapacity, sessionWidth: sessionWidth, rows: rows, isTerminalFocused: isTerminalFocused })), tab === DSH_TAB && (_jsxs(Box, { flexDirection: "row", flexGrow: 1, flexShrink: 1, overflow: "hidden", children: [railVisible && (_jsxs("ink-box", { style: { flexDirection: 'column', width: railWidth, height: '100%', flexShrink: 0, overflow: 'hidden' }, onClick: activateRail, onMouseEnter: activateRail, onWheel: (event) => {
|
|
401
405
|
moveRail(event.deltaY >= 0 ? 1 : -1);
|
|
402
|
-
}, children: [_jsx(Box, { height: 1, flexShrink: 0, overflow: "hidden", paddingX: 1, children: _jsx(Text, { dimColor: true, children: truncateWidth(
|
|
406
|
+
}, children: [_jsx(Box, { height: 1, flexShrink: 0, overflow: "hidden", paddingX: 1, children: _jsx(Text, { dimColor: true, children: truncateWidth(railEntries.length === entries.length
|
|
407
|
+
? t('home-section-workspaces', { n: entries.length })
|
|
408
|
+
: t('supervisor-workspace-groups', { registered: entries.length, history: railEntries.length - entries.length }), railWidth - 2) }) }), !loading && railEntries.length === 0 && (_jsx(Box, { paddingX: 1, children: _jsx(Text, { dimColor: true, italic: true, wrap: "truncate-end", children: truncateWidth(t('home-no-workspaces'), railWidth - 2) }) })), visibleRailRows.map((entry) => {
|
|
403
409
|
const absolute = railEntries.indexOf(entry);
|
|
404
|
-
return (_jsx(HomeWorkspaceRow, { title: entry.title, path: entry.path, home: home, sessionCount: countOf(entry), present: entry.present, selected: selected !== undefined && selected.id === entry.id, focused: activePane === 'rail' && railFocus === absolute, width: railWidth, onSelect: (event) => {
|
|
410
|
+
return (_jsx(HomeWorkspaceRow, { title: entry.title, path: entry.path, home: home, sessionCount: countOf(entry), historyOnly: entry.from === 'unregistered', present: entry.present, selected: selected !== undefined && selected.id === entry.id, focused: activePane === 'rail' && railFocus === absolute, width: railWidth, onSelect: (event) => {
|
|
405
411
|
event.stopImmediatePropagation();
|
|
406
412
|
railRef.current = absolute;
|
|
407
413
|
setRailFocus(absolute);
|
|
@@ -443,7 +449,7 @@ export function SessionSupervisor({ channel, home, onClose, onOpenSession, onNew
|
|
|
443
449
|
const path = confirmRemove;
|
|
444
450
|
setConfirmRemove(undefined);
|
|
445
451
|
removeEntry(path);
|
|
446
|
-
}, children: _jsx(Text, { color: "error", children: truncateWidth(` ${t('home-remove-title', { name: railEntries.find(entry => samePath(entry.path, confirmRemove))?.title ?? confirmRemove })} · ${t('home-remove-detail')}`, columns - 3) }) })), menu !== undefined && (_jsx(Box, { position: "absolute", left: Math.max(0, Math.min(menu.col - inset.x + 1, Math.max(0, columns - MENU_WIDTH))), top: Math.max(0, Math.min(menu.row - inset.y + 1, Math.max(0, rows -
|
|
452
|
+
}, children: _jsx(Text, { color: "error", children: truncateWidth(` ${t('home-remove-title', { name: railEntries.find(entry => samePath(entry.path, confirmRemove))?.title ?? confirmRemove })} · ${t('home-remove-detail')}`, columns - 3) }) })), menu !== undefined && menuEntry !== undefined && (_jsx(Box, { position: "absolute", left: Math.max(0, Math.min(menu.col - inset.x + 1, Math.max(0, columns - MENU_WIDTH))), top: Math.max(0, Math.min(menu.row - inset.y + 1, Math.max(0, rows - (menuActions.length + 2)))), width: MENU_WIDTH, height: menuActions.length + 2, flexDirection: "column", flexShrink: 0, borderStyle: "round", borderColor: "permission", backgroundColor: "toolCardBackground", children: menuActions.map((action, index) => (_jsx(Box, { height: 1, flexShrink: 0, backgroundColor: index === menu.item ? 'userMessageBackgroundHover' : undefined, onMouseEnter: () => setMenu(current => (current === undefined ? current : { ...current, item: index })), onClick: (event) => {
|
|
447
453
|
event.stopImmediatePropagation();
|
|
448
454
|
const entry = railEntries.find(candidate => samePath(candidate.path, menu.path));
|
|
449
455
|
if (entry !== undefined)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StatusLine.d.ts","sourceRoot":"","sources":["../../../src/screens/StatusLine.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAOzB,OAAO,EAAoC,KAAK,iBAAiB,EAAE,MAAM,+BAA+B,CAAA;AAOxG,OAAO,KAAK,EAAE,SAAS,IAAI,OAAO,EAAE,MAAM,iCAAiC,CAAA;
|
|
1
|
+
{"version":3,"file":"StatusLine.d.ts","sourceRoot":"","sources":["../../../src/screens/StatusLine.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAOzB,OAAO,EAAoC,KAAK,iBAAiB,EAAE,MAAM,+BAA+B,CAAA;AAOxG,OAAO,KAAK,EAAE,SAAS,IAAI,OAAO,EAAE,MAAM,iCAAiC,CAAA;AAsB3E,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,yBAAyB,CAAA;AAsHvD,wBAAgB,UAAU,CAAC,EACzB,OAAO,EACP,eAAuB,EACvB,QAAgB,EAChB,IAAI,EACJ,QAAQ,EAAE,iBAAiB,GAC5B,EAAE;IACD,OAAO,EAAE,OAAO,CAAA;IAChB,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;kFAC8E;IAC9E,QAAQ,CAAC,EAAE,iBAAiB,CAAA;IAC5B;;;;;;;;OAQG;IACH,IAAI,CAAC,EAAE;QACL,IAAI,EAAE,QAAQ,CAAA;QACd,IAAI,CAAC,EAAE,MAAM,CAAA;QACb,IAAI,EAAE,MAAM,CAAA;QACZ,8DAA8D;QAC9D,MAAM,CAAC,EAAE,MAAM,IAAI,CAAA;QACnB,2DAA2D;QAC3D,SAAS,CAAC,EAAE,MAAM,CAAA;KACnB,CAAA;CACF,qBAqbA;AAED,KAAK,aAAa,GAAG;IACnB,KAAK,EAAE,MAAM,CAAA;IACb,SAAS,EAAE,MAAM,CAAA;IACjB,UAAU,EAAE,MAAM,CAAA;CACnB,CAAA;AAwMD,8EAA8E;AAC9E,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,aAAa,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,CAKvF;AAED;;;;;;;GAOG;AACH,wBAAgB,oBAAoB,CAClC,SAAS,EACL;IAAE,SAAS,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,OAAO,CAAA;CAAE,GACzD,SAAS,GACZ,MAAM,GAAG,SAAS,CAIpB"}
|