Remove top highlight from Add/Manage integration icons

This commit is contained in:
raucao committed 2026-10-05 12:18:30 +02:00
1 parent 41bfb7ebbb
commit a093064bf0
3 files changed
+11 -5

No files matched your search

@@ -31,7 +31,7 @@ export default class SettingsIntegrationsAvatar extends Component {
<template>
{{#if this.siteIcon}}
<span
class="icon-edge flex size-10 flex-none items-center justify-center overflow-hidden rounded-lg bg-gray-100"
class="icon-edge icon-edge-no-highlight flex size-10 flex-none items-center justify-center overflow-hidden rounded-lg bg-gray-100"
{{setStyle "background-color" this.themeColor}}
>
<img
@@ -43,7 +43,7 @@ export default class SettingsIntegrationsAvatar extends Component {
</span>
{{else if @integration.iconUrl}}
<span
class="icon-edge flex size-10 flex-none items-center justify-center overflow-hidden rounded-lg"
class="icon-edge icon-edge-no-highlight flex size-10 flex-none items-center justify-center overflow-hidden rounded-lg"
{{setStyle "background-color" this.iconUrlThemeColor}}
>
<img
@@ -55,7 +55,7 @@ export default class SettingsIntegrationsAvatar extends Component {
</span>
{{else}}
<span
class="icon-edge flex size-10 flex-none items-center justify-center rounded-lg
class="icon-edge icon-edge-no-highlight flex size-10 flex-none items-center justify-center rounded-lg
{{@integration.colorClass}}"
>
<svg
+7 -2
View File
@@ -7,7 +7,8 @@
/* Soft edge instead of a solid border: a light highlight along the top, a
shade along the bottom, and a hairline all around. Painted as an overlay so
it sits on top of full-bleed (maskable) icons, and semi-transparent so it
reads regardless of the icon's colors. */
reads regardless of the icon's colors. The `icon-edge-no-highlight`
modifier drops the top highlight for icons where it reads as a stray gleam. */
.icon-edge {
position: relative;
}
@@ -17,9 +18,13 @@
inset: 0;
border-radius: inherit;
box-shadow:
inset 0 1px 0 rgb(255 255 255 / 40%),
inset 0 1px 0 var(--icon-edge-top, rgb(255 255 255 / 40%)),
inset 0 -1px 0 rgb(0 0 0 / 30%),
inset 0 0 0 1px rgb(255 255 255 / 10%);
content: '';
pointer-events: none;
}
.icon-edge-no-highlight::after {
--icon-edge-top: transparent;
}
@@ -22,6 +22,7 @@ module(
.exists()
.hasAttribute('src', 'data:image/png;base64,abc');
assert.dom('img').hasClass('object-cover');
assert.dom('span').hasClass('icon-edge-no-highlight');
assert.dom('svg').doesNotExist();
});