mirror of
https://github.com/getpaseo/paseo.git
synced 2026-10-28 20:22:45 +00:00
* feat(app): add persistent workspace side panes Keep the common review and file-browsing workflow beside the active agent without tearing down pane contents. Workspace tabs now share one compact chip language, assistant file links route into the retained right pane, and diff/file trees share stable geometry. * fix(app): localize pull request empty state * test(app): update explorer pane coverage * fix(app): preserve explorer pane workflows * test(app): make explorer tab selection idempotent * fix(app): persist workspace review pins * fix(app): preserve sidebar scrim drag hook * fix(app): restore companion pane interactions * test(app): follow selected sidebar surface
23 lines
635 B
TypeScript
23 lines
635 B
TypeScript
import { usePullRequestData } from "@/panels/pull-request";
|
|
|
|
export function usePullRequestPanelAvailability(input: {
|
|
serverId: string;
|
|
cwd: string;
|
|
isGit: boolean;
|
|
requested: boolean;
|
|
enabled: boolean;
|
|
timelineEnabled?: boolean;
|
|
}) {
|
|
const canQuery = input.isGit && Boolean(input.cwd);
|
|
const prPane = usePullRequestData({
|
|
serverId: input.serverId,
|
|
cwd: input.cwd,
|
|
enabled: canQuery && input.enabled,
|
|
timelineEnabled: canQuery && input.enabled && Boolean(input.timelineEnabled),
|
|
});
|
|
return {
|
|
prPane,
|
|
showPullRequest: prPane.prNumber !== null || (input.requested && prPane.isLoading),
|
|
};
|
|
}
|