diff options
author | Raphael von der GrĂ¼n <rvdg@google.com> | 2023-10-20 12:59:31 +0000 |
---|---|---|
committer | Luca Milanesio <luca.milanesio@gmail.com> | 2023-10-24 21:10:06 +0000 |
commit | d85fa3717f433b17291a949f1812f3220739532b (patch) | |
tree | d5bf28f4b5df699c596e50db5fb6ae7b35b28653 | |
parent | 353b0154627255463809411ff64a50f15a760210 (diff) |
Show diff chunk dividers with disabled context controls
Release-Notes: skip
Google-Bug-Id: b/305925197
Change-Id: Ie16a3fc9b596286aa5e0b576121f67131074425e
(cherry picked from commit 52b5d0d2ca89f2042ff074c91c8e245a9455e4e1)
-rw-r--r-- | polygerrit-ui/app/embed/diff/gr-diff/gr-diff-styles.ts | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/polygerrit-ui/app/embed/diff/gr-diff/gr-diff-styles.ts b/polygerrit-ui/app/embed/diff/gr-diff/gr-diff-styles.ts index f2f85afb0b..00a1d658a4 100644 --- a/polygerrit-ui/app/embed/diff/gr-diff/gr-diff-styles.ts +++ b/polygerrit-ui/app/embed/diff/gr-diff/gr-diff-styles.ts @@ -13,9 +13,6 @@ export const grDiffStyles = css` :host(.no-left) .sideBySide tr:not(.dividerRow) td:nth-child(-n + 4) { display: none; } - :host(.disable-context-control-buttons) { - --context-control-display: none; - } :host(.disable-context-control-buttons) .section { border-right: none; } @@ -376,7 +373,7 @@ export const grDiffStyles = css` /* Context controls */ .contextControl { - display: var(--context-control-display, table-row-group); + display: table-row-group; background-color: transparent; border: none; --divider-height: var(--spacing-s); @@ -405,6 +402,16 @@ export const grDiffStyles = css` height: calc(var(--line-height-normal) + var(--spacing-s)); } + /* Hide the actual context control buttons */ + :host(.disable-context-control-buttons) .contextControl gr-context-controls { + display: none; + } + /* Maintain a small amount of padding at the edges of diff chunks */ + :host(.disable-context-control-buttons) .contextControl .contextBackground { + height: var(--spacing-s); + border-right: none; + } + .dividerCell { vertical-align: top; } |