diff options
author | Sam Bigelow <sbigelow@gitlab.com> | 2019-03-28 17:37:06 -0400 |
---|---|---|
committer | Sam Bigelow <sbigelow@gitlab.com> | 2019-04-05 08:05:29 -0400 |
commit | 1d01e164ec7bbf0b30ba21753604227eaa469216 (patch) | |
tree | a9630346063afe46d90af60707e9532814dfbb1b /app/assets/stylesheets/pages/diff.scss | |
parent | cde8456cd433c258e9100fe33f10f62a3b32ee4e (diff) | |
download | gitlab-ce-57364-improve-diff-nav-header.tar.gz |
Improve diff navigation header57364-improve-diff-nav-header
- Compare versions header is full width except in the unified diff mode
with no tree sidebar
- Bar is always full width, but the content within stays centered when
unified and no tree sidebar
- File header is the same height as the "Compare versions header"
- aligns with the design system grid guidelines => 56px
- Diff file headers use a button group, switch icon order to open file
externally being the last option, all buttons will become icon buttons
(icon delivery by @dimitrieh)
- If a file header becomes sticky no rounded corner/double border
problem is visible anymore
Diffstat (limited to 'app/assets/stylesheets/pages/diff.scss')
-rw-r--r-- | app/assets/stylesheets/pages/diff.scss | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/app/assets/stylesheets/pages/diff.scss b/app/assets/stylesheets/pages/diff.scss index 1fedbd8bddb..08e045239e0 100644 --- a/app/assets/stylesheets/pages/diff.scss +++ b/app/assets/stylesheets/pages/diff.scss @@ -7,12 +7,15 @@ cursor: pointer; @media (min-width: map-get($grid-breakpoints, md)) { - $mr-file-header-top: $mr-version-controls-height + $header-height + $mr-tabs-height; + // The `-1` below is to prevent two borders from clashing up against eachother - + // the bottom of the compare-versions header and the top of the file header + $mr-file-header-top: $mr-version-controls-height + $header-height + $mr-tabs-height - 1; position: -webkit-sticky; position: sticky; top: $mr-file-header-top; z-index: 102; + height: $mr-version-controls-height; &::before { content: ''; @@ -54,7 +57,8 @@ background-color: $gray-normal; } - a { + a, + button { color: $gray-700; } |