Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 15 additions & 2 deletions resources/style/content.scss
Original file line number Diff line number Diff line change
Expand Up @@ -49,14 +49,24 @@
background-color: var(--background-color-alt);
border: 0.0625rem solid var(--border-color);
border-radius: var(--thumbnail-radius);
overflow: hidden;

transition: background-color 0ms, transform 200ms cubic-bezier(0, 0.5, 0, 1);

transition: background-color 0.2s $pt-transition-cubic2;
:not([aria-selected=true]) > &:active {
transform: scale(0.98);
transition: 0ms;
}

// This acts as the border-radius, but also for child elements
:first-child {
clip-path: inset(0 round var(--thumbnail-radius));
transition: clip-path 0.2s $pt-transition-cubic2;
pointer-events: none;
&:not(.image-loading) {
border-radius: var(--thumbnail-radius);
transition: 200ms cubic-bezier(0, 0.5, 0, 1);
}
}

> :is(img, video) {
Expand All @@ -73,9 +83,12 @@
background-color: var(--accent-color-yellow);

:is(img, video) {
clip-path: inset(0.25rem round calc(var(--thumbnail-radius) - 0.25rem));
clip-path: inset(0.175rem round calc(var(--thumbnail-radius) - 0.175rem));
}
}
[aria-selected=true] > & > :is(img, video, .image-error){
clip-path: inset(0.175rem round calc(var(--thumbnail-radius) - 0.175rem));
}
}

[aria-selected='true'] > .thumbnail {
Expand Down
2 changes: 1 addition & 1 deletion resources/style/themes.scss
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
color: var(--text-color);
background: var(--background-color);

--thumbnail-radius: 0.25rem;
--thumbnail-radius: 0.5rem;
}

// Scrollbar themes
Expand Down
Loading