Skip to content

Commit 7d3ee68

Browse files
authored
Image attachment gallery lightbox (#1345)
1 parent 433b179 commit 7d3ee68

4 files changed

Lines changed: 873 additions & 80 deletions

File tree

‎desktop/playwright.config.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ export default defineConfig({
3434
"**/active-turn-resilience.spec.ts",
3535
"**/profile-active-turn.spec.ts",
3636
"**/file-attachment.spec.ts",
37+
"**/image-attachment-gallery.spec.ts",
3738
"**/video-attachment.spec.ts",
3839
"**/spoiler.spec.ts",
3940
"**/mentions.spec.ts",

‎desktop/src/shared/styles/globals.css‎

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2159,8 +2159,7 @@
21592159
}
21602160
}
21612161

2162-
/* ── Image lightbox zoom slider (shared/ui/markdown) ───────────────────
2163-
Matches the white-on-glass media control track used by the video player. */
2162+
/* ── Image lightbox zoom slider (shared/ui/markdown) ─────────────────── */
21642163
.image-zoom-slider {
21652164
appearance: none;
21662165
background: transparent;
@@ -2169,16 +2168,16 @@
21692168
.image-zoom-slider:focus-visible {
21702169
outline: none;
21712170
border-radius: 9999px;
2172-
box-shadow: 0 0 0 2px rgb(255 255 255 / 0.7);
2171+
box-shadow: 0 0 0 2px hsl(var(--ring) / 0.7);
21732172
}
21742173

21752174
.image-zoom-slider::-webkit-slider-runnable-track {
21762175
height: 4px;
21772176
border-radius: 9999px;
21782177
background: linear-gradient(
21792178
to right,
2180-
white var(--image-zoom-fill, 0%),
2181-
rgb(255 255 255 / 0.3) var(--image-zoom-fill, 0%)
2179+
currentColor var(--image-zoom-fill, 0%),
2180+
color-mix(in srgb, currentColor 30%, transparent) var(--image-zoom-fill, 0%)
21822181
);
21832182
}
21842183

@@ -2189,40 +2188,40 @@
21892188
height: 12px;
21902189
width: 12px;
21912190
border-radius: 9999px;
2192-
background: white;
2191+
background: currentColor;
21932192
box-shadow: 0 1px 3px rgb(0 0 0 / 0.3);
21942193
}
21952194

21962195
.image-zoom-slider:focus-visible::-webkit-slider-thumb {
21972196
box-shadow:
2198-
0 0 0 3px rgb(255 255 255 / 0.25),
2197+
0 0 0 3px hsl(var(--ring) / 0.25),
21992198
0 1px 3px rgb(0 0 0 / 0.3);
22002199
}
22012200

22022201
.image-zoom-slider::-moz-range-track {
22032202
height: 4px;
22042203
border-radius: 9999px;
2205-
background: rgb(255 255 255 / 0.3);
2204+
background: color-mix(in srgb, currentColor 30%, transparent);
22062205
}
22072206

22082207
.image-zoom-slider::-moz-range-progress {
22092208
height: 4px;
22102209
border-radius: 9999px;
2211-
background: white;
2210+
background: currentColor;
22122211
}
22132212

22142213
.image-zoom-slider::-moz-range-thumb {
22152214
border: none;
22162215
height: 12px;
22172216
width: 12px;
22182217
border-radius: 9999px;
2219-
background: white;
2218+
background: currentColor;
22202219
box-shadow: 0 1px 3px rgb(0 0 0 / 0.3);
22212220
}
22222221

22232222
.image-zoom-slider:focus-visible::-moz-range-thumb {
22242223
box-shadow:
2225-
0 0 0 3px rgb(255 255 255 / 0.25),
2224+
0 0 0 3px hsl(var(--ring) / 0.25),
22262225
0 1px 3px rgb(0 0 0 / 0.3);
22272226
}
22282227

0 commit comments

Comments
 (0)