Disable uncommit button for parentless commits (#25983)

Closes #25976

There's a couple states that this covers:
- upon `git init`, no footer is shown at all
- after 1 commit (or when on any parentless commit), the uncommit button
is ~disabled~ hidden
- otherwise commit button is shown

Also updated the button with "meta" tooltip showing human readable
description and git command.

Release Notes:

- N/A

---------

Co-authored-by: Nate Butler <iamnbutler@gmail.com>
This commit is contained in:
Julia Ryan 2025-03-05 15:23:05 -08:00 committed by GitHub
parent 4db9ab15a7
commit 0200dda83d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 31 additions and 15 deletions

View file

@ -382,6 +382,7 @@ pub fn proto_to_branch(proto: &proto::Branch) -> git::repository::Branch {
sha: commit.sha.to_string().into(),
subject: commit.subject.to_string().into(),
commit_timestamp: commit.commit_timestamp,
has_parent: true,
}
}),
}