mirror of
https://github.com/git-touch/git-touch
synced 2025-01-28 22:59:24 +01:00
fix: commit history count
This commit is contained in:
parent
fadb053b95
commit
50cfd48e51
@ -1055,6 +1055,12 @@ class GithubRepositoryQuery
|
||||
arguments: [],
|
||||
directives: [],
|
||||
selectionSet: SelectionSetNode(selections: [
|
||||
FieldNode(
|
||||
name: NameNode(value: '__typename'),
|
||||
alias: null,
|
||||
arguments: [],
|
||||
directives: [],
|
||||
selectionSet: null),
|
||||
InlineFragmentNode(
|
||||
typeCondition: TypeConditionNode(
|
||||
on: NamedTypeNode(
|
||||
@ -1110,6 +1116,12 @@ class GithubRepositoryQuery
|
||||
arguments: [],
|
||||
directives: [],
|
||||
selectionSet: SelectionSetNode(selections: [
|
||||
FieldNode(
|
||||
name: NameNode(value: '__typename'),
|
||||
alias: null,
|
||||
arguments: [],
|
||||
directives: [],
|
||||
selectionSet: null),
|
||||
InlineFragmentNode(
|
||||
typeCondition: TypeConditionNode(
|
||||
on: NamedTypeNode(
|
||||
|
@ -59,6 +59,7 @@ query(
|
||||
defaultBranchRef @skip(if: $branchSpecified) {
|
||||
name
|
||||
target {
|
||||
__typename
|
||||
... on Commit {
|
||||
history {
|
||||
totalCount
|
||||
@ -69,6 +70,7 @@ query(
|
||||
ref(qualifiedName: $branch) @include(if: $branchSpecified) {
|
||||
name
|
||||
target {
|
||||
__typename
|
||||
... on Commit {
|
||||
history {
|
||||
totalCount
|
||||
|
@ -230,8 +230,13 @@ class RepositoryScreen extends StatelessWidget {
|
||||
TableViewItem(
|
||||
leftIconData: Octicons.history,
|
||||
text: Text('Commits'),
|
||||
// rightWidget: Text(numberFormat
|
||||
// .format(ref['target']['history']['totalCount'])),
|
||||
rightWidget: Text(
|
||||
numberFormat.format(
|
||||
(ref.target as GithubRepositoryCommit)
|
||||
.history
|
||||
?.totalCount,
|
||||
),
|
||||
),
|
||||
screenBuilder: (_) =>
|
||||
CommitsScreen(owner, name, branch: branch),
|
||||
),
|
||||
|
Loading…
x
Reference in New Issue
Block a user