Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: add improved scrolling #45

Open
wants to merge 10 commits into
base: main
Choose a base branch
from
Prev Previous commit
Next Next commit
feat(scroll): add key inputs for page up and down
  • Loading branch information
CamKem committed Dec 29, 2024
commit 322d791c34049d486ceaedef7028b9ff7cfc7048
4 changes: 4 additions & 0 deletions src/Prompt/Dashboard.php
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,10 @@ public function handleResize(): false

protected function showDashboard(): void
{
$oneFrame = $this->currentCommand()->scrollPaneHeight() - 1;
$pageUp = "\e[5~";
$pageDown = "\e[6~";

$listener = KeyPressListener::for($this)
->on('D', fn() => $this->currentCommand()->dd())
// Logs
Expand Down