diff --git a/src/dotnet/APIView/APIViewWeb/Client/css/site.scss b/src/dotnet/APIView/APIViewWeb/Client/css/site.scss index d1e9cee92b1..422f90e9374 100644 --- a/src/dotnet/APIView/APIViewWeb/Client/css/site.scss +++ b/src/dotnet/APIView/APIViewWeb/Client/css/site.scss @@ -192,13 +192,18 @@ input[type="search"]::-webkit-search-cancel-button { #review-left { max-width: none; min-width: 10px; + height: auto; + overflow: auto; + max-height: 100vh; } #review-right { max-width: 100%; min-width: 100px; - overflow-x: auto; + height: auto; + overflow: auto; padding: 0px; + max-height: 100vh } /*---------------------------------------------------------------------*/ @@ -802,7 +807,7 @@ code { .icon-comments { cursor: pointer; position: absolute; - right: 30px; + right: -25px; } .icon-chevron-right { @@ -870,6 +875,9 @@ code { background: url(/icons/swagger-original.svg) center center no-repeat; } /*---------------------------------------------------------------------*/ +.invisible { + visibility: hidden; +} .info-text { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; @@ -908,12 +916,24 @@ code { } .line-toggle-documentation-button { - display: inline-block; + display: block; width: 100%; height: 100%; text-align: center; cursor: pointer; user-select: none; + position: relative; +} + +.line-toggle-documentation-button svg { + top: 0px; + left: 0px; +} + +.line-toggle-documentation-button i { + position: absolute; + top: 25%; + left: 25%; } .line-details-button-cell { @@ -921,10 +941,10 @@ code { height: 22px; min-width: 22px; min-height: 22px; + padding: 0px; } .line-details { - border-right: 1px solid; border-right: 1px solid var(--border-color); background-color: var(--background-color); color: darkcyan; diff --git a/src/dotnet/APIView/APIViewWeb/Client/src/comments.ts b/src/dotnet/APIView/APIViewWeb/Client/src/comments.ts index 248f68d963d..e3796020dbf 100644 --- a/src/dotnet/APIView/APIViewWeb/Client/src/comments.ts +++ b/src/dotnet/APIView/APIViewWeb/Client/src/comments.ts @@ -417,7 +417,7 @@ function ensureMessageIconInDOM() { if (!MessageIconAddedToDom) { - $(".line-comment-button-cell").append(``); + $(".comment-icon-cell").append(``); MessageIconAddedToDom = true; } } diff --git a/src/dotnet/APIView/APIViewWeb/Client/src/review.ts b/src/dotnet/APIView/APIViewWeb/Client/src/review.ts index 1424afe88cd..d17f4e10038 100644 --- a/src/dotnet/APIView/APIViewWeb/Client/src/review.ts +++ b/src/dotnet/APIView/APIViewWeb/Client/src/review.ts @@ -299,11 +299,15 @@ $(() => { $(".code-line-documentation").removeClass('hidden-row'); $(TOGGLE_DOCUMENTATION).children('i').removeClass("fa-square-plus"); $(TOGGLE_DOCUMENTATION).children('i').addClass("fa-square-minus"); + $(TOGGLE_DOCUMENTATION).children('i').css("color", "darkorange"); + $(TOGGLE_DOCUMENTATION).children('svg').removeClass("invisible"); } else { // hide all documentation $(".code-line-documentation").addClass("hidden-row"); $(TOGGLE_DOCUMENTATION).children('i').removeClass("fa-square-minus"); $(TOGGLE_DOCUMENTATION).children('i').addClass("fa-square-plus"); + $(TOGGLE_DOCUMENTATION).children('i').css("color", "darkcyan"); + $(TOGGLE_DOCUMENTATION).children('svg').addClass("invisible"); } }); @@ -355,6 +359,14 @@ $(() => { $(this).children('i').toggleClass('fa-square-minus'); $(this).children('i').toggleClass('fa-square-plus'); + if ($(this).children('i').hasClass('fa-square-plus')) { + $(this).children('i').css("color", "darkcyan"); + $(this).children('svg').addClass("invisible"); + } + else { + $(this).children('i').css("color", "darkorange"); + $(this).children('svg').removeClass("invisible"); + } // scroll button to center of screen, so that the line is visible after toggling folding $(this).get(0).scrollIntoView({ block: "center"}); diff --git a/src/dotnet/APIView/APIViewWeb/Pages/Assemblies/_CodeLine.cshtml b/src/dotnet/APIView/APIViewWeb/Pages/Assemblies/_CodeLine.cshtml index 4eec0660605..c1e588df3cb 100644 --- a/src/dotnet/APIView/APIViewWeb/Pages/Assemblies/_CodeLine.cshtml +++ b/src/dotnet/APIView/APIViewWeb/Pages/Assemblies/_CodeLine.cshtml @@ -71,15 +71,22 @@ - @if(userPreference.HideLineNumbers == true || Model.CodeLine.IsDocumentation) + @if(userPreference.HideLineNumbers == true) { - var lineNumberClass = RemoveMultipleSpaces($"line-number {lineClass}"); - + var lineNumberClass = RemoveMultipleSpaces($"line-number d-none {lineClass}"); + } else { var lineNumberClass = RemoveMultipleSpaces($"line-number {lineClass}"); - + if (Model.CodeLine.IsDocumentation) + { + + } + else + { + + } }
@Model.LineNumber@Model.LineNumber@Model.LineNumber @if (!isRemoved && Model.CodeLine.ElementId != null) @@ -88,13 +95,16 @@ } else { - // Added for visual consistency + // Added for visual consistency } @if(Model.DocumentedByLines?.Length > 0) { + } @@ -102,7 +112,7 @@ { - + } diff --git a/src/dotnet/APIView/APIViewWeb/Pages/Shared/_CommentThreadInnerPartial.cshtml b/src/dotnet/APIView/APIViewWeb/Pages/Shared/_CommentThreadInnerPartial.cshtml index 76d243d041f..6860666e4aa 100644 --- a/src/dotnet/APIView/APIViewWeb/Pages/Shared/_CommentThreadInnerPartial.cshtml +++ b/src/dotnet/APIView/APIViewWeb/Pages/Shared/_CommentThreadInnerPartial.cshtml @@ -42,7 +42,7 @@ }