Skip to content

Commit 56916a0

Browse files
committed
Adds sizes to img tags for smooth scrolling
1 parent 26e69fc commit 56916a0

23 files changed

+324
-17
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this p
1414
- Fixes [#1925](https://github.com/gitkraken/vscode-gitlens/issues/1925) - Branches from remotes outside the repo aren't showing associated pull requests (for connected remotes)
1515
- Fixes [#1920](https://github.com/gitkraken/vscode-gitlens/issues/1920) - Can't view tags on torvalds/linux
1616
- Fixes [#1923](https://github.com/gitkraken/vscode-gitlens/issues/1923) - View titles fail to update properly when number of "opened" repos changes
17+
- Fixes smooth scrolling and TOC jumping issues on the GitLens Interactive Settings
1718

1819
## [12.0.5] - 2022-03-17
1920

src/webviews/apps/settings/partials/blame.html

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -187,48 +187,64 @@ <h2>
187187
src="#{webroot}/media/blame.webp"
188188
data-visibility="blame.compact =false"
189189
loading="lazy"
190+
width="600"
191+
height="206"
190192
/>
191193
<img
192194
class="image__preview--overlay hidden"
193195
src="#{webroot}/media/blame-highlight.webp"
194196
data-visibility="blame.compact =false &amp; blame.highlight.enabled &amp; blame.highlight.locations +line"
195197
loading="lazy"
198+
width="600"
199+
height="206"
196200
/>
197201
<img
198202
class="image__preview hidden"
199203
src="#{webroot}/media/blame-compact.webp"
200204
data-visibility="blame.compact"
201205
loading="lazy"
206+
width="600"
207+
height="206"
202208
/>
203209
<img
204210
class="image__preview--overlay hidden"
205211
src="#{webroot}/media/blame-compact-highlight.webp"
206212
data-visibility="blame.compact &amp; blame.highlight.enabled &amp; blame.highlight.locations +line"
207213
loading="lazy"
214+
width="600"
215+
height="206"
208216
/>
209217
<img
210218
class="image__preview--overlay hidden"
211219
src="#{webroot}/media/blame-highlight-gutter.webp"
212220
data-visibility="blame.highlight.enabled &amp; blame.highlight.locations +gutter"
213221
loading="lazy"
222+
width="600"
223+
height="206"
214224
/>
215225
<img
216226
class="image__preview--overlay hidden"
217227
src="#{webroot}/media/blame-highlight-scrollbar.webp"
218228
data-visibility="blame.highlight.enabled &amp; blame.highlight.locations +overview"
219229
loading="lazy"
230+
width="600"
231+
height="206"
220232
/>
221233
<img
222234
class="image__preview--overlay hidden"
223235
src="#{webroot}/media/blame-heatmap-left.webp"
224236
data-visibility="blame.heatmap.enabled &amp; blame.heatmap.location =left"
225237
loading="lazy"
238+
width="600"
239+
height="206"
226240
/>
227241
<img
228242
class="image__preview--overlay hidden"
229243
src="#{webroot}/media/blame-heatmap-right.webp"
230244
data-visibility="blame.heatmap.enabled &amp; blame.heatmap.location =right"
231245
loading="lazy"
246+
width="600px"
247+
height="206px"
232248
/>
233249
</div>
234250
</div>

src/webviews/apps/settings/partials/changes.html

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,18 +85,28 @@ <h2>
8585
</div>
8686

8787
<div class="section__preview">
88-
<img class="image__preview" src="#{webroot}/media/changes.webp" loading="lazy" />
88+
<img
89+
class="image__preview"
90+
src="#{webroot}/media/changes.webp"
91+
loading="lazy"
92+
width="600"
93+
height="206"
94+
/>
8995
<img
9096
class="image__preview--overlay hidden"
9197
src="#{webroot}/media/changes-highlight-gutter.webp"
9298
data-visibility="changes.locations +gutter"
9399
loading="lazy"
100+
width="600"
101+
height="206"
94102
/>
95103
<img
96104
class="image__preview--overlay hidden"
97105
src="#{webroot}/media/changes-highlight-scrollbar.webp"
98106
data-visibility="changes.locations +overview"
99107
loading="lazy"
108+
width="600"
109+
height="206"
100110
/>
101111
</div>
102112
</div>

src/webviews/apps/settings/partials/code-lens.html

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,62 +252,86 @@
252252
</div>
253253

254254
<div class="section__preview">
255-
<img class="image__preview" src="#{webroot}/media/code-lens.webp" loading="lazy" />
255+
<img
256+
class="image__preview"
257+
src="#{webroot}/media/code-lens.webp"
258+
loading="lazy"
259+
width="600"
260+
height="206"
261+
/>
256262
<img
257263
class="image__preview--overlay hidden"
258264
src="#{webroot}/media/code-lens-file-recent+authors.webp"
259265
data-visibility="codeLens.enabled &amp; codeLens.recentChange.enabled &amp; codeLens.authors.enabled &amp; codeLens.scopes +document"
260266
loading="lazy"
267+
width="600"
268+
height="206"
261269
/>
262270
<img
263271
class="image__preview--overlay hidden"
264272
src="#{webroot}/media/code-lens-file-recent.webp"
265273
data-visibility="codeLens.enabled &amp; codeLens.recentChange.enabled &amp; codeLens.authors.enabled =false &amp; codeLens.scopes +document"
266274
loading="lazy"
275+
width="600"
276+
height="206"
267277
/>
268278
<img
269279
class="image__preview--overlay hidden"
270280
src="#{webroot}/media/code-lens-file-authors.webp"
271281
data-visibility="codeLens.enabled &amp; codeLens.recentChange.enabled =false &amp; codeLens.authors.enabled &amp; codeLens.scopes +document"
272282
loading="lazy"
283+
width="600"
284+
height="206"
273285
/>
274286

275287
<img
276288
class="image__preview--overlay hidden"
277289
src="#{webroot}/media/code-lens-containers-recent+authors.webp"
278290
data-visibility="codeLens.enabled &amp; codeLens.recentChange.enabled &amp; codeLens.authors.enabled &amp; codeLens.scopes +containers"
279291
loading="lazy"
292+
width="600"
293+
height="206"
280294
/>
281295
<img
282296
class="image__preview--overlay hidden"
283297
src="#{webroot}/media/code-lens-containers-recent.webp"
284298
data-visibility="codeLens.enabled &amp; codeLens.recentChange.enabled &amp; codeLens.authors.enabled =false &amp; codeLens.scopes +containers"
285299
loading="lazy"
300+
width="600"
301+
height="206"
286302
/>
287303
<img
288304
class="image__preview--overlay hidden"
289305
src="#{webroot}/media/code-lens-containers-authors.webp"
290306
data-visibility="codeLens.enabled &amp; codeLens.recentChange.enabled =false &amp; codeLens.authors.enabled &amp; codeLens.scopes +containers"
291307
loading="lazy"
308+
width="600"
309+
height="206"
292310
/>
293311

294312
<img
295313
class="image__preview--overlay hidden"
296314
src="#{webroot}/media/code-lens-blocks-recent+authors.webp"
297315
data-visibility="codeLens.enabled &amp; codeLens.recentChange.enabled &amp; codeLens.authors.enabled &amp; codeLens.scopes +blocks"
298316
loading="lazy"
317+
width="600"
318+
height="206"
299319
/>
300320
<img
301321
class="image__preview--overlay hidden"
302322
src="#{webroot}/media/code-lens-blocks-recent.webp"
303323
data-visibility="codeLens.enabled &amp; codeLens.recentChange.enabled &amp; codeLens.authors.enabled =false &amp; codeLens.scopes +blocks"
304324
loading="lazy"
325+
width="600"
326+
height="206"
305327
/>
306328
<img
307329
class="image__preview--overlay hidden"
308330
src="#{webroot}/media/code-lens-blocks-authors.webp"
309331
data-visibility="codeLens.enabled &amp; codeLens.recentChange.enabled =false &amp; codeLens.authors.enabled &amp; codeLens.scopes +blocks"
310332
loading="lazy"
333+
width="600"
334+
height="206"
311335
/>
312336
</div>
313337
</div>

src/webviews/apps/settings/partials/current-line.html

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,24 +116,36 @@
116116
</div>
117117

118118
<div class="section__preview">
119-
<img class="image__preview" src="#{webroot}/media/current-line-blame.webp" loading="lazy" />
119+
<img
120+
class="image__preview"
121+
src="#{webroot}/media/current-line-blame.webp"
122+
loading="lazy"
123+
width="600"
124+
height="206"
125+
/>
120126
<img
121127
class="image__preview--overlay hidden"
122128
src="#{webroot}/media/current-line-blame-on.webp"
123129
data-visibility="currentLine.enabled &amp; currentLine.pullRequests.enabled =false"
124130
loading="lazy"
131+
width="600"
132+
height="206"
125133
/>
126134
<img
127135
class="image__preview--overlay hidden"
128136
src="#{webroot}/media/current-line-blame-on+pr.webp"
129137
data-visibility="currentLine.enabled &amp; currentLine.pullRequests.enabled"
130138
loading="lazy"
139+
width="600"
140+
height="206"
131141
/>
132142
<img
133143
class="image__preview--overlay hidden"
134144
src="#{webroot}/media/current-line-blame-on-scrollable.webp"
135145
data-visibility="currentLine.enabled &amp; currentLine.scrollable"
136146
loading="lazy"
147+
width="600"
148+
height="206"
137149
/>
138150
</div>
139151
</div>

src/webviews/apps/settings/partials/heatmap.html

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,18 +105,28 @@ <h2>
105105
</div>
106106

107107
<div class="section__preview">
108-
<img class="image__preview" src="#{webroot}/media/heatmap.webp" loading="lazy" />
108+
<img
109+
class="image__preview"
110+
src="#{webroot}/media/heatmap.webp"
111+
loading="lazy"
112+
width="600"
113+
height="206"
114+
/>
109115
<img
110116
class="image__preview--overlay hidden"
111117
src="#{webroot}/media/heatmap-gutter.webp"
112118
data-visibility="heatmap.locations +gutter"
113119
loading="lazy"
120+
width="600"
121+
height="206"
114122
/>
115123
<img
116124
class="image__preview--overlay hidden"
117125
src="#{webroot}/media/heatmap-scrollbar.webp"
118126
data-visibility="heatmap.locations +overview"
119127
loading="lazy"
128+
width="600"
129+
height="206"
120130
/>
121131
</div>
122132
</div>

src/webviews/apps/settings/partials/hovers.html

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,48 +152,68 @@
152152
</div>
153153

154154
<div class="section__preview" data-visibility="hovers.enabled">
155-
<img class="image__preview" src="#{webroot}/media/hovers-currentLine.webp" loading="lazy" />
155+
<img
156+
class="image__preview"
157+
src="#{webroot}/media/hovers-currentLine.webp"
158+
loading="lazy"
159+
width="600"
160+
height="206"
161+
/>
156162
<img
157163
class="image__preview--overlay hidden"
158164
src="#{webroot}/media/hovers-currentLine-on.webp"
159165
data-visibility="currentLine.enabled &amp; currentLine.pullRequests.enabled =false"
160166
loading="lazy"
167+
width="600"
168+
height="206"
161169
/>
162170
<img
163171
class="image__preview--overlay hidden"
164172
src="#{webroot}/media/hovers-currentLine-on+pr.webp"
165173
data-visibility="currentLine.enabled &amp; currentLine.pullRequests.enabled"
166174
loading="lazy"
175+
width="600"
176+
height="206"
167177
/>
168178
<img
169179
class="image__preview--overlay hidden"
170180
src="#{webroot}/media/hovers-details+pr+changes.webp"
171181
data-visibility="hovers.enabled &amp; hovers.currentLine.enabled &amp; hovers.currentLine.details &amp; hovers.currentLine.changes &amp; hovers.pullRequests.enabled"
172182
loading="lazy"
183+
width="600"
184+
height="206"
173185
/>
174186
<img
175187
class="image__preview--overlay hidden"
176188
src="#{webroot}/media/hovers-details+changes.webp"
177189
data-visibility="hovers.enabled &amp; hovers.currentLine.enabled &amp; hovers.currentLine.details &amp; hovers.currentLine.changes &amp; hovers.pullRequests.enabled =false"
178190
loading="lazy"
191+
width="600"
192+
height="206"
179193
/>
180194
<img
181195
class="image__preview--overlay hidden"
182196
src="#{webroot}/media/hovers-details+pr.webp"
183197
data-visibility="hovers.enabled &amp; hovers.currentLine.enabled &amp; hovers.currentLine.details &amp; hovers.currentLine.changes =false &amp; hovers.pullRequests.enabled"
184198
loading="lazy"
199+
width="600"
200+
height="206"
185201
/>
186202
<img
187203
class="image__preview--overlay hidden"
188204
src="#{webroot}/media/hovers-details.webp"
189205
data-visibility="hovers.enabled &amp; hovers.currentLine.enabled &amp; hovers.currentLine.details &amp; hovers.currentLine.changes =false &amp; hovers.pullRequests.enabled =false"
190206
loading="lazy"
207+
width="600"
208+
height="206"
191209
/>
192210
<img
193211
class="image__preview--overlay hidden"
194212
src="#{webroot}/media/hovers-changes.webp"
195213
data-visibility="hovers.enabled &amp; hovers.currentLine.enabled &amp; hovers.currentLine.details =false &amp; hovers.currentLine.changes"
196214
loading="lazy"
215+
width="600"
216+
height="206"
197217
/>
198218
</div>
199219
</div>
@@ -269,48 +289,64 @@
269289
src="#{webroot}/media/hovers-annotations.webp"
270290
data-visibility="blame.compact =false"
271291
loading="lazy"
292+
width="600"
293+
height="206"
272294
/>
273295
<img
274296
class="image__preview hidden"
275297
src="#{webroot}/media/hovers-annotations-compact.webp"
276298
data-visibility="blame.compact"
277299
loading="lazy"
300+
width="600"
301+
height="206"
278302
/>
279303
<img
280304
class="image__preview--overlay hidden"
281305
src="#{webroot}/media/hovers-annotations-currentLine-on.webp"
282306
data-visibility="currentLine.enabled"
283307
loading="lazy"
308+
width="600"
309+
height="206"
284310
/>
285311
<img
286312
class="image__preview--overlay hidden"
287313
src="#{webroot}/media/hovers-details+pr+changes.webp"
288314
data-visibility="hovers.enabled &amp; hovers.annotations.enabled &amp; hovers.annotations.details &amp; hovers.annotations.changes &amp; hovers.pullRequests.enabled"
289315
loading="lazy"
316+
width="600"
317+
height="206"
290318
/>
291319
<img
292320
class="image__preview--overlay hidden"
293321
src="#{webroot}/media/hovers-details+changes.webp"
294322
data-visibility="hovers.enabled &amp; hovers.annotations.enabled &amp; hovers.annotations.details &amp; hovers.annotations.changes &amp; hovers.pullRequests.enabled =false"
295323
loading="lazy"
324+
width="600"
325+
height="206"
296326
/>
297327
<img
298328
class="image__preview--overlay hidden"
299329
src="#{webroot}/media/hovers-details+pr.webp"
300330
data-visibility="hovers.enabled &amp; hovers.annotations.enabled &amp; hovers.annotations.details &amp; hovers.annotations.changes =false &amp; hovers.pullRequests.enabled"
301331
loading="lazy"
332+
width="600"
333+
height="206"
302334
/>
303335
<img
304336
class="image__preview--overlay hidden"
305337
src="#{webroot}/media/hovers-details.webp"
306338
data-visibility="hovers.enabled &amp; hovers.annotations.enabled &amp; hovers.annotations.details &amp; hovers.annotations.changes =false &amp; hovers.pullRequests.enabled =false"
307339
loading="lazy"
340+
width="600"
341+
height="206"
308342
/>
309343
<img
310344
class="image__preview--overlay hidden"
311345
src="#{webroot}/media/hovers-changes.webp"
312346
data-visibility="hovers.enabled &amp; hovers.annotations.enabled &amp; hovers.annotations.details =false &amp; hovers.annotations.changes"
313347
loading="lazy"
348+
width="600"
349+
height="206"
314350
/>
315351
</div>
316352
</div>

0 commit comments

Comments
 (0)