Skip to content
This repository was archived by the owner on Jun 21, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
234 commits
Select commit Hold shift + click to select a range
2fa267a
Restoring Annotations
StanleyGoldman Aug 15, 2018
182a9a9
Moving more FromGraphQl functions
StanleyGoldman Aug 15, 2018
4383c27
Merge branch 'features/check-suites' into features/check-suite-annota…
StanleyGoldman Aug 15, 2018
1f324a7
Functionality to indicate Check Run annotation counts
StanleyGoldman Aug 15, 2018
d9b6fe5
Attempting to display an icon for PullRequestCheckViewModels that hav…
StanleyGoldman Aug 16, 2018
fafc68f
Merge branch 'features/check-suites' into features/check-suite-annota…
StanleyGoldman Aug 16, 2018
10aee41
Merge branch 'features/check-suites' into features/check-suite-annota…
StanleyGoldman Aug 16, 2018
220a3e9
Displaying an icon next to check runs with annotations
StanleyGoldman Aug 16, 2018
3409360
Tweaking min width
StanleyGoldman Aug 16, 2018
47bc9f1
Merge branch 'features/check-suites' into features/check-suite-annota…
StanleyGoldman Aug 16, 2018
68a1d12
Adding a display for PullRequest Annotations
StanleyGoldman Aug 16, 2018
317c4ae
Functionality to display annotations in a dedicated view
StanleyGoldman Aug 17, 2018
86feafd
Fixing error
StanleyGoldman Aug 17, 2018
cc4219a
Fixing formatting
StanleyGoldman Aug 17, 2018
8fb18b4
Adding different types of inline tags
StanleyGoldman Aug 17, 2018
95d0079
Merge branch 'features/check-suites' into features/check-suite-annota…
StanleyGoldman Aug 20, 2018
42be1cd
Merge branch 'features/check-suites' into features/check-suite-annota…
StanleyGoldman Aug 21, 2018
966c955
Merge branch 'features/check-suites' into features/check-suite-annota…
StanleyGoldman Aug 21, 2018
7ee9e5a
Displaying inline glyphs
StanleyGoldman Aug 22, 2018
9ae3a85
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Aug 22, 2018
662f21e
Merge remote-tracking branch 'origin/master' into features/check-suit…
StanleyGoldman Aug 31, 2018
a069d8d
Fix needed after merge
StanleyGoldman Aug 31, 2018
cbc46a7
Fixing reference
StanleyGoldman Sep 4, 2018
fb8f7c3
Fixes needed after merge
StanleyGoldman Sep 4, 2018
6caf940
Ignoring tests i broke
StanleyGoldman Sep 4, 2018
16dbc03
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Sep 4, 2018
5362e1f
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Sep 5, 2018
34ac1d2
Reverting Inline Reviews
StanleyGoldman Sep 5, 2018
66181de
Changing InlineCommentTag to InlineTag
StanleyGoldman Sep 5, 2018
db3f01a
Cleaning up more code
StanleyGoldman Sep 5, 2018
8cd11fd
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Sep 5, 2018
7ca9195
Working InlineTagger changes
StanleyGoldman Sep 5, 2018
b39c5a4
Fixing test
StanleyGoldman Sep 6, 2018
2dfcf5d
Merge branch 'master' into features/check-suite-annotations
Sep 6, 2018
5174ee3
Adding another test
StanleyGoldman Sep 6, 2018
db07173
Rename class
StanleyGoldman Sep 6, 2018
bb30e4d
Adding functionality to create a tag object for a comment thread and …
StanleyGoldman Sep 6, 2018
85b060c
Adding different glyph types
StanleyGoldman Sep 7, 2018
6b564b0
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Sep 7, 2018
a9d69db
Merge remote-tracking branch 'remotes/origin/features/check-suite-ann…
StanleyGoldman Sep 7, 2018
657292e
Renaming models and adding InlineAnnotationViewModel
StanleyGoldman Sep 7, 2018
7cf4eba
Displaing inline annotations
StanleyGoldman Sep 7, 2018
3eddd4c
More renaming
StanleyGoldman Sep 7, 2018
321d51e
Adding CheckRunName
StanleyGoldman Sep 7, 2018
ecfd974
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Sep 10, 2018
3b8945d
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Sep 10, 2018
cf37806
Fixing project file
StanleyGoldman Sep 10, 2018
28a74ce
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Sep 10, 2018
219a823
Fixing the build
StanleyGoldman Sep 10, 2018
4f0f721
Rename DatabaseId to CheckRunId
StanleyGoldman Sep 10, 2018
ea3c850
Functionality to open an annotation tag from the file list
StanleyGoldman Sep 10, 2018
214e1a5
Renaming more InlineComment things
StanleyGoldman Sep 10, 2018
18dc78d
Link to inline review from file
StanleyGoldman Sep 10, 2018
b24f8a2
Restoring names of a lot of things
StanleyGoldman Sep 10, 2018
c1c229f
Undoing a lot of renaming
StanleyGoldman Sep 10, 2018
0db9892
Backporting some fixes
StanleyGoldman Sep 10, 2018
726de83
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Sep 10, 2018
2a9e4dd
Using a desiger to better control properties
StanleyGoldman Sep 11, 2018
9c8a4d8
Code cleanup
StanleyGoldman Sep 11, 2018
c3c03dd
More code cleanup
StanleyGoldman Sep 11, 2018
2865433
More backporting and cleaning
StanleyGoldman Sep 11, 2018
af51110
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Sep 11, 2018
7f8a0f5
Final code cleanup
StanleyGoldman Sep 11, 2018
df89a29
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Sep 11, 2018
58e1797
More code cleanup
StanleyGoldman Sep 11, 2018
2e21ae9
Final code cleanup
StanleyGoldman Sep 11, 2018
5c8e649
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Sep 11, 2018
b5dc961
Merge remote-tracking branch 'remotes/origin/features/check-suite-ann…
StanleyGoldman Sep 11, 2018
35f80ec
Fixes for code analysis
StanleyGoldman Sep 11, 2018
bb87286
Functionality to add CheckSuite Name to annotations view
StanleyGoldman Sep 13, 2018
9dcae6e
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Sep 13, 2018
1e3f839
Displaying the check suite name in inline reviews
StanleyGoldman Sep 13, 2018
24882ab
Functionality to display status icons
StanleyGoldman Sep 27, 2018
0463518
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Sep 27, 2018
86ef79a
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Sep 27, 2018
8802d49
Merge branch 'features/check-suite-annotations-inline' into checks-an…
StanleyGoldman Sep 27, 2018
388f47c
Fixing code after merge
StanleyGoldman Sep 27, 2018
f82a023
Updating nuget package
StanleyGoldman Sep 27, 2018
f2354ab
Other fixes after merge
StanleyGoldman Sep 27, 2018
a57985e
Adding image to check suitesa
StanleyGoldman Sep 27, 2018
aac507c
Merge remote-tracking branch 'remotes/origin/master' into features/ch…
StanleyGoldman Oct 23, 2018
041ea59
Lots of changes needed after merge
StanleyGoldman Oct 23, 2018
e86bde3
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Oct 24, 2018
7183891
Fixing more issues after merge
StanleyGoldman Oct 24, 2018
a785da4
Additional changes
StanleyGoldman Oct 24, 2018
5596f3f
Last fix
StanleyGoldman Oct 24, 2018
84c6b3d
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Oct 24, 2018
80d5b9a
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Oct 24, 2018
d4c96b8
Merge branch 'features/check-suite-annotations-inline' into features/…
StanleyGoldman Oct 24, 2018
0af2495
Addressing some feedback
StanleyGoldman Oct 24, 2018
8a7454f
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Oct 24, 2018
2bbdbf8
Restoring session field
StanleyGoldman Oct 24, 2018
b494b6e
Fixing merge error
StanleyGoldman Oct 24, 2018
f89c55b
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Oct 29, 2018
8d2323a
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Oct 29, 2018
88fd1ee
Start basic layout for inline annotations
donokuda Oct 29, 2018
507125e
Application may be null
StanleyGoldman Oct 29, 2018
f8a02f9
Little bit of text formatting
donokuda Oct 29, 2018
d7da753
Update colors and other formatting
donokuda Oct 30, 2018
68c7b34
Fix content not wrapping / stretching correctly
donokuda Oct 30, 2018
089d6c7
Marking Apps private
StanleyGoldman Oct 30, 2018
8fcb9b5
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Oct 30, 2018
a94917d
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Oct 30, 2018
d25bf7d
Fixing loading logic
StanleyGoldman Oct 30, 2018
49703ed
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Oct 30, 2018
9921f72
Use VS images for status icons
donokuda Oct 30, 2018
a55182e
Make text work in Dark Theme
donokuda Oct 30, 2018
284b3b5
Dynamic colors
donokuda Oct 30, 2018
d6329c4
Merge branch 'features/check-suite-annotations-inline' into donokuda/…
donokuda Oct 30, 2018
05ed235
Fix build error
StanleyGoldman Oct 30, 2018
92903eb
Merge branch 'features/check-suite-annotations-inline' into donokuda/…
StanleyGoldman Oct 30, 2018
cbbb54b
Fixing compilation error
StanleyGoldman Oct 31, 2018
65bb008
Merge branch 'features/check-suite-annotations-inline' into donokuda/…
StanleyGoldman Oct 31, 2018
06ad642
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Nov 2, 2018
7d65ffe
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 2, 2018
add8e9d
Switch to CheckRunId
StanleyGoldman Nov 5, 2018
72fa350
Fixing regular expression; - should be escaped
StanleyGoldman Nov 5, 2018
6877792
Merge branch 'features/check-suite-annotations-images' into features/…
StanleyGoldman Nov 5, 2018
3ae3c1b
Removing IInlineAnnotationModel
StanleyGoldman Nov 5, 2018
2b0970a
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 5, 2018
e705559
Merge remote-tracking branch 'remotes/origin/master' into features/ch…
StanleyGoldman Nov 5, 2018
df93480
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 5, 2018
e2e4b6c
Cleanup from removing interface
StanleyGoldman Nov 6, 2018
6c22912
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 6, 2018
d7ebeca
More interface removing
StanleyGoldman Nov 6, 2018
55f4f8a
Missing comma
StanleyGoldman Nov 6, 2018
9cbc9ff
Temporarily disabling the loading of images
StanleyGoldman Nov 6, 2018
4e38c00
Move things into a border component
donokuda Nov 6, 2018
b2810aa
Begin implementing comment styles
donokuda Nov 6, 2018
a327209
Tidy up margins
donokuda Nov 6, 2018
6e9bcae
Removing status and check avatars
StanleyGoldman Nov 6, 2018
5ba4d89
Fixing tests
StanleyGoldman Nov 6, 2018
6b8b712
Some more styling tweaks
donokuda Nov 6, 2018
f45b329
Switching to a dictionary based on file path
StanleyGoldman Nov 7, 2018
fd2ed5e
Merge remote-tracking branch 'origin/master' into features/check-suit…
StanleyGoldman Nov 7, 2018
480ca1a
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 7, 2018
b09aaba
Cleanup
StanleyGoldman Nov 7, 2018
a28d67c
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 7, 2018
f3ca06b
Cleanup
StanleyGoldman Nov 7, 2018
597d651
Changing to an array
StanleyGoldman Nov 7, 2018
b829ea7
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 7, 2018
d2b1532
Use a different theme color for comment borders
donokuda Nov 7, 2018
fda3134
Prefer VS Images over Octicons in file tree
donokuda Nov 7, 2018
e8a2a0a
Use info icon too
donokuda Nov 7, 2018
fc6ec4c
Merge remote-tracking branch 'origin/features/check-suite-annotations…
donokuda Nov 8, 2018
05ddfba
UpdatedAt -> CreatedAt
donokuda Nov 8, 2018
fb7fd99
Merge branch 'features/check-suite-annotations-inline' into donokuda/…
StanleyGoldman Nov 8, 2018
aaaf9ec
Merge remote-tracking branch 'remotes/origin/master' into features/ch…
StanleyGoldman Nov 8, 2018
07003b3
Removing unused interface
StanleyGoldman Nov 8, 2018
a674ec9
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 8, 2018
33b38f2
Merge branch 'features/check-suite-annotations-inline' into donokuda/…
StanleyGoldman Nov 8, 2018
494099b
Merge pull request #2045 from github/donokuda/use-vs-icons-in-treeeeee
StanleyGoldman Nov 8, 2018
c8304fe
Merge remote-tracking branch 'remotes/origin/features/check-suite-ann…
StanleyGoldman Nov 8, 2018
7cd3139
Merge branch 'donokuda/check-suite-polish' of https://github.com/gith…
donokuda Nov 8, 2018
488ed64
Removing application slug
StanleyGoldman Nov 8, 2018
5d0b1f2
Adding notice count to files view
StanleyGoldman Nov 9, 2018
573a3bc
Prefer VS Images over Octicons in file tree
donokuda Nov 7, 2018
8604670
Use info icon too
donokuda Nov 7, 2018
ab0aafd
Align icon
StanleyGoldman Nov 9, 2018
8e7ff5c
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 9, 2018
698f35b
Merge remote-tracking branch 'remotes/origin/master' into features/ch…
StanleyGoldman Nov 9, 2018
f155567
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 9, 2018
4a57e92
Merge branch 'features/check-suite-annotations-inline' into donokuda/…
StanleyGoldman Nov 9, 2018
20977f1
Cleanup references
StanleyGoldman Nov 9, 2018
2b748a7
Fixing references
StanleyGoldman Nov 9, 2018
434af69
Cleanup
StanleyGoldman Nov 9, 2018
c2c4c46
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 9, 2018
56dd609
Merge branch 'features/check-suite-annotations-inline' into donokuda/…
StanleyGoldman Nov 9, 2018
ca27920
Removing old packages
StanleyGoldman Nov 19, 2018
2c6303a
Rename CheckRunId to Id for the win
StanleyGoldman Nov 19, 2018
a6f8a46
Merge remote-tracking branch 'origin/master' into features/check-suit…
StanleyGoldman Nov 19, 2018
2030133
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 19, 2018
c06767e
Merge branch 'features/check-suite-annotations-inline' into donokuda/…
StanleyGoldman Nov 19, 2018
0708f8d
Merge pull request #2018 from github/donokuda/check-suite-polish
StanleyGoldman Nov 19, 2018
21aa934
Group things by file
donokuda Nov 14, 2018
329bd00
Polish up the annotations list view
donokuda Nov 14, 2018
4ce6b7f
This wasn't necessary
donokuda Nov 14, 2018
829de23
Negative margins and format title
donokuda Nov 14, 2018
818a4fc
Make the line description a hyperlink
donokuda Nov 15, 2018
c0cb0c2
Identifying what files are contained in the pull request
StanleyGoldman Nov 20, 2018
59d3d06
Merge branch 'features/check-suite-annotations' into donokuda/check-l…
StanleyGoldman Nov 20, 2018
d71c94d
Adding a line description for items that are not in the pull request
StanleyGoldman Nov 20, 2018
d608dac
Cleanup
StanleyGoldman Nov 20, 2018
fe4d63b
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 20, 2018
349c7c1
Fixes after merge
StanleyGoldman Nov 20, 2018
9282f78
Merge pull request #2057 from github/donokuda/check-list-polish
StanleyGoldman Nov 20, 2018
1e65e46
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 20, 2018
a9c5390
Making requested changes
StanleyGoldman Nov 20, 2018
4b91bce
Moving string to resource
StanleyGoldman Nov 20, 2018
6e994c8
Removing unused property and resource
StanleyGoldman Nov 20, 2018
cb3e082
Correct comment
StanleyGoldman Nov 20, 2018
129d863
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 20, 2018
0a757ab
:fire: unnecessary grid markup
donokuda Nov 20, 2018
a5180cd
:fire: Commented lines
donokuda Nov 20, 2018
a762e9a
Update icon to text
donokuda Nov 20, 2018
fc7a955
An attempt at keeping the width of each row consistent
donokuda Nov 20, 2018
de64ba8
Fixing references
StanleyGoldman Nov 20, 2018
5580c06
Back to the stack
donokuda Nov 20, 2018
766cae5
i-have-no-clue-what-im-doing.jpg
donokuda Nov 20, 2018
99203ff
Addressing feedback
StanleyGoldman Nov 21, 2018
e731cd5
Removing handler
StanleyGoldman Nov 21, 2018
b01e6ec
Removing xaml import
StanleyGoldman Nov 21, 2018
967a749
IReadOnlyList > IReadOnlyCollection
StanleyGoldman Nov 21, 2018
04e6fc7
Adding comments
StanleyGoldman Nov 21, 2018
24a501d
Merge branch 'features/check-suite-annotations-inline' into donokuda/…
StanleyGoldman Nov 21, 2018
a38c1cf
Add missing CommandParameter
StanleyGoldman Nov 21, 2018
c07100a
Don't use SharedSizeScope.
grokys Nov 21, 2018
d738496
Merge pull request #2074 from github/donokuda/update-check-icon
StanleyGoldman Nov 21, 2018
d6ae911
Simplify view
StanleyGoldman Nov 21, 2018
6d91d7a
Merge branch 'features/check-suite-annotations-inline' of https://git…
donokuda Nov 21, 2018
769125c
Moving Annotations out of CommentThreadViewModel
StanleyGoldman Nov 21, 2018
88d9af7
Adjusting view
StanleyGoldman Nov 21, 2018
cf78034
Adjust annotation list item's margin and make text color dynamic
donokuda Nov 21, 2018
adfada0
Merge branch 'features/check-suite-annotations-inline' of https://git…
donokuda Nov 21, 2018
e9080ab
It's a circle now!
donokuda Nov 21, 2018
747084c
Update color
donokuda Nov 21, 2018
a0e2fcd
It's a lil diamond now
donokuda Nov 21, 2018
0d81d7c
Adding additional Check Run fields
StanleyGoldman Nov 21, 2018
c67c5b4
Make everything a diamond
donokuda Nov 21, 2018
c110ad9
Fix bottom margin for reply textbox
donokuda Nov 21, 2018
271c2cd
Using only one view
StanleyGoldman Nov 21, 2018
4069376
Merge pull request #2077 from github/donokuda/polish-annotation-margin
StanleyGoldman Nov 21, 2018
c2d7d72
Merge remote-tracking branch 'remotes/origin/master' into features/ch…
StanleyGoldman Nov 21, 2018
fe6c09d
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 21, 2018
f13d354
Attempting to control the comment ability
StanleyGoldman Nov 22, 2018
f3c4548
Correcting the xaml binding
StanleyGoldman Nov 26, 2018
ce065dc
Merge pull request #2080 from github/features/check-suite-annotations…
StanleyGoldman Nov 26, 2018
9e9978f
Merge branch 'master' into features/check-suite-annotations
StanleyGoldman Nov 26, 2018
1da4ac2
Merge branch 'features/check-suite-annotations' into features/check-s…
StanleyGoldman Nov 26, 2018
fef4a16
Merge pull request #1900 from github/features/check-suite-annotations…
grokys Nov 26, 2018
e249664
Removing margin
StanleyGoldman Nov 26, 2018
a6f67e8
no margins
donokuda Nov 26, 2018
cd33156
Merge branch 'features/check-suite-annotations' of https://github.com…
donokuda Nov 26, 2018
6bbb1ae
remove border from comments
donokuda Nov 26, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file removed lib/Octokit.GraphQL.0.1.1-beta.nupkg
Binary file not shown.
2 changes: 1 addition & 1 deletion src/GitHub.Api/GitHub.Api.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,6 @@
<ItemGroup>
<PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.6.1" />
<PackageReference Include="Newtonsoft.Json" Version="9.0.1" />
<PackageReference Include="Octokit.GraphQL" Version="0.1.1-beta" />
<PackageReference Include="Octokit.GraphQL" Version="0.1.2-beta" />
</ItemGroup>
</Project>
4 changes: 2 additions & 2 deletions src/GitHub.App/GitHub.App.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,10 @@
<PackageReference Include="Microsoft.VisualStudio.SDK.EmbedInteropTypes" Version="15.0.17" />
<PackageReference Include="Microsoft.VisualStudio.Shell.14.0" Version="14.3.25407" />
<PackageReference Include="Newtonsoft.Json" Version="9.0.1" />
<PackageReference Include="Octokit.GraphQL" Version="0.1.1-beta" />
<PackageReference Include="Octokit.GraphQL" Version="0.1.2-beta" />
<PackageReference Include="Rothko" Version="0.0.3-ghfvs" />
<PackageReference Include="Serilog" Version="2.5.0" />
<PackageReference Include="SerilogAnalyzer" Version="0.12.0.0" />
<PackageReference Include="Stateless" Version="2.5.56.0" targetFramework="net45" />
</ItemGroup>
</Project>
</Project>
14 changes: 13 additions & 1 deletion src/GitHub.App/SampleData/CommentThreadViewModelDesigner.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
using System.Diagnostics.CodeAnalysis;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.Threading.Tasks;
using GitHub.Models;
using GitHub.ViewModels;
using ReactiveUI;

Expand All @@ -8,6 +10,16 @@ namespace GitHub.SampleData
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
public class CommentThreadViewModelDesigner : ViewModelBase, ICommentThreadViewModel
{
public CommentThreadViewModelDesigner()
{
Comments = new ReactiveList<ICommentViewModel>(){new CommentViewModelDesigner()
{
Author = new ActorViewModel{ Login = "shana"},
Body = "You can use a `CompositeDisposable` type here, it's designed to handle disposables in an optimal way (you can just call `Dispose()` on it and it will handle disposing everything it holds)."
}};

}

public IReadOnlyReactiveList<ICommentViewModel> Comments { get; }
= new ReactiveList<ICommentViewModel>();

Expand Down
40 changes: 40 additions & 0 deletions src/GitHub.App/SampleData/InlineAnnotationViewModelDesigner.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
using System.Collections.Generic;
using GitHub.Models;
using GitHub.ViewModels;

namespace GitHub.SampleData
{
public class InlineAnnotationViewModelDesigner : IInlineAnnotationViewModel
{
public InlineAnnotationViewModelDesigner()
{
var checkRunAnnotationModel = new CheckRunAnnotationModel
{
AnnotationLevel = CheckAnnotationLevel.Failure,
Path = "SomeFile.cs",
EndLine = 12,
StartLine = 12,
Message = "Some Error Message",
Title = "CS12345"
};

var checkRunModel =
new CheckRunModel
{
Annotations = new List<CheckRunAnnotationModel> {checkRunAnnotationModel},
Name = "Fake Check Run"
};

var checkSuiteModel = new CheckSuiteModel()
{
ApplicationName = "Fake Check Suite",
HeadSha = "ed6198c37b13638e902716252b0a17d54bd59e4a",
CheckRuns = new List<CheckRunModel> { checkRunModel}
};

Model= new InlineAnnotationModel(checkSuiteModel, checkRunModel, checkRunAnnotationModel);
}

public InlineAnnotationModel Model { get; }
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
using System.Diagnostics.CodeAnalysis;
using System.Reactive;
using GitHub.Models;
using GitHub.ViewModels.GitHubPane;
using ReactiveUI;

namespace GitHub.SampleData
{
[ExcludeFromCodeCoverage]
public sealed class PullRequestAnnotationItemViewModelDesigner : IPullRequestAnnotationItemViewModel
{
public CheckRunAnnotationModel Annotation { get; set; }
public bool IsExpanded { get; set; }
public string LineDescription => $"{Annotation.StartLine}:{Annotation.EndLine}";
public bool IsFileInPullRequest { get; set; }
public ReactiveCommand<Unit, Unit> OpenAnnotation { get; }
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.Reactive;
using System.Threading.Tasks;
using GitHub.Models;
using GitHub.ViewModels.GitHubPane;
using ReactiveUI;

namespace GitHub.SampleData
{
[ExcludeFromCodeCoverage]
public sealed class PullRequestAnnotationsViewModelDesigner : PanePageViewModelBase, IPullRequestAnnotationsViewModel
{
public LocalRepositoryModel LocalRepository { get; set; }
public string RemoteRepositoryOwner { get; set; }
public int PullRequestNumber { get; set; } = 123;
public string CheckRunId { get; set; }
public ReactiveCommand<Unit, Unit> NavigateToPullRequest { get; }
public string PullRequestTitle { get; } = "Fixing stuff in this PR";
public string CheckSuiteName { get; } = "Awesome Check Suite";
public string CheckRunSummary { get; } = "Awesome Check Run Summary";
public string CheckRunText { get; } = "Awesome Check Run Text";

public IReadOnlyDictionary<string, IPullRequestAnnotationItemViewModel[]> AnnotationsDictionary { get; }
= new Dictionary<string, IPullRequestAnnotationItemViewModel[]>
{
{
"asdf/asdf.cs",
new IPullRequestAnnotationItemViewModel[]
{
new PullRequestAnnotationItemViewModelDesigner
{
Annotation = new CheckRunAnnotationModel
{
AnnotationLevel = CheckAnnotationLevel.Warning,
StartLine = 3,
EndLine = 4,
Path = "asdf/asdf.cs",
Message = "; is expected",
Title = "CS 12345"
},
IsExpanded = true,
IsFileInPullRequest = true
},
new PullRequestAnnotationItemViewModelDesigner
{
Annotation = new CheckRunAnnotationModel
{
AnnotationLevel = CheckAnnotationLevel.Failure,
StartLine = 3,
EndLine = 4,
Path = "asdf/asdf.cs",
Message = "; is expected",
Title = "CS 12345"
},
IsExpanded = true,
IsFileInPullRequest = true
},
}
},
{
"blah.cs",
new IPullRequestAnnotationItemViewModel[]
{
new PullRequestAnnotationItemViewModelDesigner
{
Annotation = new CheckRunAnnotationModel
{
AnnotationLevel = CheckAnnotationLevel.Notice,
StartLine = 3,
EndLine = 4,
Path = "blah.cs",
Message = "; is expected",
Title = "CS 12345"
},
IsExpanded = true,
}
}
},
};

public string CheckRunName { get; } = "Psuedo Check Run";

public Task InitializeAsync(LocalRepositoryModel localRepository, IConnection connection, string owner,
string repo,
int pullRequestNumber, string checkRunId)
{
return Task.CompletedTask;
}
}
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using System;
using System.Reactive;
using System.Windows.Media.Imaging;
using GitHub.Models;
using GitHub.ViewModels;
using GitHub.ViewModels.GitHubPane;
using ReactiveUI;
Expand All @@ -18,5 +18,11 @@ public sealed class PullRequestCheckViewModelDesigner : ViewModelBase, IPullRequ
public Uri DetailsUrl { get; set; } = new Uri("http://github.com");

public ReactiveCommand<Unit, Unit> OpenDetailsUrl { get; set; } = null;

public PullRequestCheckType CheckType { get; set; } = PullRequestCheckType.ChecksApi;

public string CheckRunId { get; set; }

public bool HasAnnotations { get; } = true;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
using System.Reactive;
using System.Threading.Tasks;
using GitHub.SampleData;
using ReactiveUI.Legacy;

namespace GitHub.SampleData
{
Expand Down Expand Up @@ -122,8 +123,10 @@ public PullRequestDetailViewModelDesigner()
public ReactiveCommand<Unit, Unit> Checkout { get; }
public ReactiveCommand<Unit, Unit> Pull { get; }
public ReactiveCommand<Unit, Unit> Push { get; }
public ReactiveCommand<Unit, Unit> SyncSubmodules { get; }
public ReactiveCommand<Unit, Unit> OpenOnGitHub { get; }
public ReactiveCommand<IPullRequestReviewSummaryViewModel, Unit> ShowReview { get; }
public ReactiveCommand<IPullRequestCheckViewModel, Unit> ShowAnnotations { get; }

public IReadOnlyList<IPullRequestCheckViewModel> Checks { get; }

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ public PullRequestFilesViewModelDesigner()
public ReactiveCommand<IPullRequestFileNode, Unit> DiffFileWithWorkingDirectory { get; }
public ReactiveCommand<IPullRequestFileNode, Unit> OpenFileInWorkingDirectory { get; }
public ReactiveCommand<IPullRequestFileNode, Unit> OpenFirstComment { get; }
public ReactiveCommand<IPullRequestFileNode, Unit> OpenFirstAnnotationNotice { get; }
public ReactiveCommand<IPullRequestFileNode, Unit> OpenFirstAnnotationWarning { get; }
public ReactiveCommand<IPullRequestFileNode, Unit> OpenFirstAnnotationFailure { get; }

public Task InitializeAsync(
IPullRequestSession session,
Expand Down
18 changes: 17 additions & 1 deletion src/GitHub.App/Services/FromGraphQlExtensions.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using System;
using GitHub.Models;
using Octokit.GraphQL.Model;
using CheckAnnotationLevel = GitHub.Models.CheckAnnotationLevel;
using CheckConclusionState = GitHub.Models.CheckConclusionState;
using CheckStatusState = GitHub.Models.CheckStatusState;
using PullRequestReviewState = GitHub.Models.PullRequestReviewState;
Expand Down Expand Up @@ -84,7 +85,7 @@ public static CheckStatusState FromGraphQl(this Octokit.GraphQL.Model.CheckStatu
}
}

public static GitHub.Models.PullRequestReviewState FromGraphQl(this Octokit.GraphQL.Model.PullRequestReviewState value)
public static PullRequestReviewState FromGraphQl(this Octokit.GraphQL.Model.PullRequestReviewState value)
{
switch (value) {
case Octokit.GraphQL.Model.PullRequestReviewState.Pending:
Expand All @@ -101,5 +102,20 @@ public static GitHub.Models.PullRequestReviewState FromGraphQl(this Octokit.Grap
throw new ArgumentOutOfRangeException(nameof(value), value, null);
}
}

public static CheckAnnotationLevel FromGraphQl(this Octokit.GraphQL.Model.CheckAnnotationLevel value)
{
switch (value)
{
case Octokit.GraphQL.Model.CheckAnnotationLevel.Failure:
return CheckAnnotationLevel.Failure;
case Octokit.GraphQL.Model.CheckAnnotationLevel.Notice:
return CheckAnnotationLevel.Notice;
case Octokit.GraphQL.Model.CheckAnnotationLevel.Warning:
return CheckAnnotationLevel.Warning;
default:
throw new ArgumentOutOfRangeException(nameof(value), value, null);
}
}
}
}
14 changes: 10 additions & 4 deletions src/GitHub.App/Services/PullRequestEditorService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ await pullRequestService.ExtractToTempFile(
}

/// <inheritdoc/>
public async Task<IDifferenceViewer> OpenDiff(
public Task<IDifferenceViewer> OpenDiff(
IPullRequestSession session,
string relativePath,
IInlineCommentThreadModel thread)
Expand All @@ -294,11 +294,17 @@ public async Task<IDifferenceViewer> OpenDiff(
Guard.ArgumentNotEmptyString(relativePath, nameof(relativePath));
Guard.ArgumentNotNull(thread, nameof(thread));

var diffViewer = await OpenDiff(session, relativePath, thread.CommitSha, scrollToFirstDraftOrDiff: false);
return OpenDiff(session, relativePath, thread.CommitSha, thread.LineNumber - 1);
}

/// <inheritdoc/>
public async Task<IDifferenceViewer> OpenDiff(IPullRequestSession session, string relativePath, string headSha, int fromLine)
{
var diffViewer = await OpenDiff(session, relativePath, headSha, scrollToFirstDraftOrDiff: false);

var param = (object)new InlineCommentNavigationParams
var param = (object) new InlineCommentNavigationParams
{
FromLine = thread.LineNumber - 1,
FromLine = fromLine,
};

// HACK: We need to wait here for the inline comment tags to initialize so we can find the next inline comment.
Expand Down
2 changes: 1 addition & 1 deletion src/GitHub.App/Services/PullRequestService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ public async Task<Page<PullRequestListItemModel>> ReadPullRequests(
{
Conclusion = run.Conclusion.FromGraphQl(),
Status = run.Status.FromGraphQl()
}).ToList()
}).ToList(),
}).ToList(),
Statuses = commit.Commit.Status
.Select(context =>
Expand Down
28 changes: 26 additions & 2 deletions src/GitHub.App/ViewModels/GitHubPane/GitHubPaneViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ public sealed class GitHubPaneViewModel : ViewModelBase, IGitHubPaneViewModel, I
static readonly Regex pullUri = CreateRoute("/:owner/:repo/pull/:number");
static readonly Regex pullNewReviewUri = CreateRoute("/:owner/:repo/pull/:number/review/new");
static readonly Regex pullUserReviewsUri = CreateRoute("/:owner/:repo/pull/:number/reviews/:login");
static readonly Regex pullCheckRunsUri = CreateRoute("/:owner/:repo/pull/:number/checkruns/:id");

readonly IViewViewModelFactory viewModelFactory;
readonly ISimpleApiClientFactory apiClientFactory;
Expand Down Expand Up @@ -266,6 +267,15 @@ public async Task NavigateTo(Uri uri)
var login = match.Groups["login"].Value;
await ShowPullRequestReviews(owner, repo, number, login);
}
else if ((match = pullCheckRunsUri.Match(uri.AbsolutePath))?.Success == true)
{
var owner = match.Groups["owner"].Value;
var repo = match.Groups["repo"].Value;
var number = int.Parse(match.Groups["number"].Value);
var id = match.Groups["id"].Value;

await ShowPullRequestCheckRun(owner, repo, number, id);
}
else
{
throw new NotSupportedException("Unrecognised GitHub pane URL: " + uri.AbsolutePath);
Expand Down Expand Up @@ -319,6 +329,20 @@ public Task ShowPullRequestReviews(string owner, string repo, int number, string
x.User.Login == login);
}

/// <inheritdoc/>
public Task ShowPullRequestCheckRun(string owner, string repo, int number, string checkRunId)
{
Guard.ArgumentNotNull(owner, nameof(owner));
Guard.ArgumentNotNull(repo, nameof(repo));

return NavigateTo<IPullRequestAnnotationsViewModel>(
x => x.InitializeAsync(LocalRepository, Connection, owner, repo, number, checkRunId),
x => x.RemoteRepositoryOwner == owner &&
x.LocalRepository.Name == repo &&
x.PullRequestNumber == number &&
x.CheckRunId == checkRunId);
}

/// <inheritdoc/>
public Task ShowPullRequestReviewAuthoring(string owner, string repo, int number)
{
Expand Down Expand Up @@ -489,8 +513,8 @@ static async Task<bool> IsValidRepository(ISimpleApiClient client)

static Regex CreateRoute(string route)
{
// Build RegEx from route (:foo to named group (?<foo>[\w_.-]+)).
var routeFormat = "^" + new Regex("(:([a-z]+))\\b").Replace(route, @"(?<$2>[\w_.-]+)") + "$";
// Build RegEx from route (:foo to named group (?<foo>[\w_.\-=]+)).
var routeFormat = "^" + new Regex("(:([a-z]+))\\b").Replace(route, @"(?<$2>[\w_.\-=]+)") + "$";
return new Regex(routeFormat, RegexOptions.ExplicitCapture | RegexOptions.IgnoreCase);
}
}
Expand Down
Loading