Add a tooltip to the gr-image-viewer toggle button.
Right now it has no accessibility support outside of the "role=button".
Adding a title argument will add a tooltip with the explanation.
Google-Bug-Id: b/299853582
Release-Notes: skip
Change-Id: I2eb736afb2c1ba75862a4aaa36fda8ab6add511c
diff --git a/polygerrit-ui/app/embed/diff/gr-diff-image-viewer/gr-image-viewer.ts b/polygerrit-ui/app/embed/diff/gr-diff-image-viewer/gr-image-viewer.ts
index 4f05cca..e0febdc 100644
--- a/polygerrit-ui/app/embed/diff/gr-diff-image-viewer/gr-image-viewer.ts
+++ b/polygerrit-ui/app/embed/diff/gr-diff-image-viewer/gr-image-viewer.ts
@@ -457,7 +457,14 @@
<paper-button class=${classMap(leftClasses)} @click=${this.selectBase}>
Base
</paper-button>
- <paper-fab mini icon="gr-icons:swapHoriz" @click=${this.manualBlink}>
+ <paper-fab
+ mini
+ icon="gr-icons:swapHoriz"
+ title=${this.baseSelected
+ ? 'switch to Revision version'
+ : 'switch to Base version'}
+ @click=${this.manualBlink}
+ >
</paper-fab>
<paper-button
class=${classMap(rightClasses)}