From fabb54c34d77bd0c2437472082384ea2e50666a8 Mon Sep 17 00:00:00 2001 From: Eric Amodio <eamodio@gmail.com> Date: Thu, 20 Oct 2022 00:21:38 -0400 Subject: [PATCH] Updates graph settings and highlights GL+ features --- CHANGELOG.md | 4 ++ package.json | 62 +++++++++++----------- .../apps/settings/partials/commit-graph.html | 62 +++++++++++++--------- .../apps/settings/partials/views.worktrees.html | 2 +- src/webviews/apps/settings/settings.html | 4 +- src/webviews/apps/shared/base.scss | 1 + 6 files changed, 75 insertions(+), 60 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2abd9df..d76a630 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,10 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this p - Adds a banner to the _Commit Details_ view to let users know they can move the view to the Secondary Side Bar +### Updated + +- Updates the _Commit Graph_ settings clarity and ordering + ### Fixed - Fixes [#2271](https://github.com/gitkraken/vscode-gitlens/issues/2271) - Terminal commands should wrap path with quote to deal with path contains space diff --git a/package.json b/package.json index ae00067..05be00b 100644 --- a/package.json +++ b/package.json @@ -2094,20 +2094,27 @@ "title": "Commit Graph", "order": 105, "properties": { - "gitlens.graph.avatars": { - "type": "boolean", - "default": true, - "markdownDescription": "Specifies whether to show avatar images instead of author initials and remote icons in the _Commit Graph_", + "gitlens.graph.defaultItemLimit": { + "type": "number", + "default": 500, + "markdownDescription": "Specifies the default number of items to show in the _Commit Graph_. Use 0 to specify no limit", "scope": "window", "order": 10 }, - "gitlens.graph.highlightRowsOnRefHover": { - "type": "boolean", - "default": true, - "markdownDescription": "Specifies whether to highlight rows associated with the ref when hovering over it in the _Commit Graph_", + "gitlens.graph.pageItemLimit": { + "type": "number", + "default": 200, + "markdownDescription": "Specifies the number of additional items to fetch when paginating in the _Commit Graph_. Use 0 to specify no limit", "scope": "window", "order": 11 }, + "gitlens.graph.searchItemLimit": { + "type": "number", + "default": 100, + "markdownDescription": "Specifies the number of results to gather when searching in the _Commit Graph_. Use 0 to specify no limit", + "scope": "window", + "order": 12 + }, "gitlens.graph.showDetailsView": { "type": [ "boolean", @@ -2126,42 +2133,35 @@ ], "markdownDescription": "Specifies when to show the _Commit Details_ view for the selected row in the _Commit Graph_", "scope": "window", - "order": 12 + "order": 20 }, "gitlens.graph.showGhostRefsOnRowHover": { "type": "boolean", "default": true, - "markdownDescription": "Specifies whether to show a ghost ref for the hovered/selected row in the _Commit Graph_", + "markdownDescription": "Specifies whether to show a ghost branch / tag when hovering over or selecting a row in the _Commit Graph_", + "scope": "window", + "order": 21 + }, + "gitlens.graph.highlightRowsOnRefHover": { + "type": "boolean", + "default": true, + "markdownDescription": "Specifies whether to highlight rows associated with the branch / tag when hovering over it in the _Commit Graph_", "scope": "window", - "order": 13 + "order": 22 }, "gitlens.graph.showRemoteNames": { "type": "boolean", "default": false, "markdownDescription": "Specifies whether to show remote names on remote branches in the _Commit Graph_", "scope": "window", - "order": 14 - }, - "gitlens.graph.defaultItemLimit": { - "type": "number", - "default": 500, - "markdownDescription": "Specifies the default number of items to show in the _Commit Graph_. Use 0 to specify no limit", - "scope": "window", - "order": 20 + "order": 23 }, - "gitlens.graph.pageItemLimit": { - "type": "number", - "default": 200, - "markdownDescription": "Specifies the number of additional items to fetch when paginating in the _Commit Graph_. Use 0 to specify no limit", - "scope": "window", - "order": 21 - }, - "gitlens.graph.searchItemLimit": { - "type": "number", - "default": 100, - "markdownDescription": "Specifies the number of results to gather when searching in the _Commit Graph_. Use 0 to specify no limit", + "gitlens.graph.avatars": { + "type": "boolean", + "default": true, + "markdownDescription": "Specifies whether to show avatar images instead of author initials and remote icons in the _Commit Graph_", "scope": "window", - "order": 22 + "order": 24 }, "gitlens.graph.commitOrdering": { "type": "string", diff --git a/src/webviews/apps/settings/partials/commit-graph.html b/src/webviews/apps/settings/partials/commit-graph.html index 1c6cafc..fb25dc1 100644 --- a/src/webviews/apps/settings/partials/commit-graph.html +++ b/src/webviews/apps/settings/partials/commit-graph.html @@ -1,7 +1,7 @@ <section id="commit-graph" class="section--settings section--collapsible"> <div class="section__header"> <h2> - Commit Graph + <span title="GitLens+ feature">✨</span> Commit Graph <a class="link__learn-more" title="Learn more" @@ -16,7 +16,7 @@ <a class="command command--show-view" title="Show Commit Graph" href="command:gitlens.showGraphPage" >Commit Graph</a > - to visualize, explore, and manage a Git repository ✨ + to visualize, explore, and manage a Git repository </p> </div> @@ -35,43 +35,32 @@ data-setting data-default-value="500" /> - <label for="graph.defaultItemLimit"> rows initially</label> - </div> - </div> - - <div class="setting"> - <div class="setting__input"> - <label for="graph.pageItemLimit">Show an additional </label> + <label for="graph.defaultItemLimit"> rows at first and</label> + <label for="graph.pageItemLimit"> then page in </label> <input id="graph.pageItemLimit" name="graph.pageItemLimit" type="number" - placeholder="90" + placeholder="200" data-setting - data-default-value="90" + data-default-value="200" /> - <label for="graph.pageItemLimit"> rows when scrolling</label> - </div> - </div> - - <div class="setting"> - <div class="setting__input"> - <input id="graph.avatars" name="graph.avatars" type="checkbox" data-setting /> - <label for="graph.avatars">Use author and remote avatars</label> + <label for="graph.pageItemLimit"> more rows when scrolling</label> </div> </div> <div class="setting"> <div class="setting__input"> + <label for="graph.searchItemLimit">Show </label> <input - id="graph.highlightRowsOnRefHover" - name="graph.highlightRowsOnRefHover" - type="checkbox" + id="graph.searchItemLimit" + name="graph.searchItemLimit" + type="number" + placeholder="100" data-setting + data-default-value="100" /> - <label for="graph.highlightRowsOnRefHover" - >Highlight associated rows when hovering on a branch</label - > + <label for="graph.searchItemLimit"> search results at first and when paging</label> </div> </div> @@ -108,7 +97,21 @@ data-setting /> <label for="graph.showGhostRefsOnRowHover" - >Show a ghost ref when hovering/selecting on a commit</label + >Show ghost branch / tag when hovering over or selecting a commit</label + > + </div> + </div> + + <div class="setting"> + <div class="setting__input"> + <input + id="graph.highlightRowsOnRefHover" + name="graph.highlightRowsOnRefHover" + type="checkbox" + data-setting + /> + <label for="graph.highlightRowsOnRefHover" + >Highlight associated rows when hovering over a branch</label > </div> </div> @@ -127,6 +130,13 @@ <div class="setting"> <div class="setting__input"> + <input id="graph.avatars" name="graph.avatars" type="checkbox" data-setting /> + <label for="graph.avatars">Use author and remote avatars</label> + </div> + </div> + + <div class="setting"> + <div class="setting__input"> <input id="graph.dateStyle" name="graph.dateStyle" diff --git a/src/webviews/apps/settings/partials/views.worktrees.html b/src/webviews/apps/settings/partials/views.worktrees.html index c66ce4e..87de03f 100644 --- a/src/webviews/apps/settings/partials/views.worktrees.html +++ b/src/webviews/apps/settings/partials/views.worktrees.html @@ -1,7 +1,7 @@ <section id="worktrees-view" class="section--settings section--collapsible"> <div class="section__header"> <h2> - Worktrees view + <span title="GitLens+ feature">✨</span> Worktrees view <a class="link__learn-more" title="Learn more" diff --git a/src/webviews/apps/settings/settings.html b/src/webviews/apps/settings/settings.html index b61bbe6..50b4a22 100644 --- a/src/webviews/apps/settings/settings.html +++ b/src/webviews/apps/settings/settings.html @@ -218,7 +218,7 @@ data-action="jump" href="#worktrees-view" title="Jump to Worktrees view settings" - >Worktrees view</a + >✨ Worktrees view</a > </li> <li> @@ -274,7 +274,7 @@ data-action="jump" href="#commit-graph" title="Jump to Commit Graph settings" - >Commit Graph</a + >✨ Commit Graph</a > </li> <li> diff --git a/src/webviews/apps/shared/base.scss b/src/webviews/apps/shared/base.scss index b59cbb0..3dbc914 100644 --- a/src/webviews/apps/shared/base.scss +++ b/src/webviews/apps/shared/base.scss @@ -144,6 +144,7 @@ textarea { input[type='number'] { max-width: 100px; + text-align: center; } kbd {