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

Default to latest stable semver2 on package details page #3930

Merged
merged 1 commit into from
May 10, 2017
Merged
Changes from all commits
Commits
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
8 changes: 4 additions & 4 deletions src/NuGetGallery/Views/Packages/DisplayPackage.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@
<p>
<code>
Install-Package @Model.Id
@if (!Model.LatestVersion || !Model.Listed)
@if (!Model.LatestVersionSemVer2 || !Model.Listed)
{
<text> -Version @Model.Version</text>
}
Expand Down Expand Up @@ -354,8 +354,8 @@
<tbody>
@foreach (var packageVersion in Model.PackageVersions)
{
var rowClass = packageVersion.LatestStableVersion ? "recommended" : null;
var cellTitle = packageVersion.LatestStableVersion ? "Latest Stable Version" : null;
var rowClass = packageVersion.LatestStableVersionSemVer2 ? "recommended" : null;
var cellTitle = packageVersion.LatestStableVersionSemVer2 ? "Latest Stable Version" : null;
if (!packageVersion.Deleted && (packageVersion.Listed || (Model.IsOwner(User) || User.IsAdministrator())))
{
<tr class="versionTableRow @rowClass">
Expand All @@ -365,7 +365,7 @@
<a title="@packageVersion.Title @packageVersion.FullVersion" href="@Url.Package(packageVersion) ">
@packageVersion.Title.Abbreviate(20)
@packageVersion.Version
@if (packageVersion.LatestStableVersion)
@if (packageVersion.LatestStableVersionSemVer2)
{
@:(latest stable)
}
Expand Down