fix(frontend): readable links and file chips on own bubbles
This commit is contained in:
1 parent
6ae28cb321
commit
995322b17a
6 files changed
+55
-8
No files matched your search
@@ -69,13 +69,14 @@
|
||||
{:else if type === "url" || type === "text_link" || type === "email" || type === "phone_number"}
|
||||
<a
|
||||
class="link"
|
||||
class:own
|
||||
href={linkHref(node)}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
>{@render tree(node.children)}</a
|
||||
>
|
||||
{:else if type === "mention" || type === "text_mention" || type === "hashtag" || type === "cashtag" || type === "bot_command"}
|
||||
<span class="link">{@render tree(node.children)}</span>
|
||||
<span class="link" class:own>{@render tree(node.children)}</span>
|
||||
{:else}
|
||||
{@render tree(node.children)}
|
||||
{/if}
|
||||
@@ -108,6 +109,24 @@
|
||||
&:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
&.own {
|
||||
color: var(--color-own-links);
|
||||
}
|
||||
}
|
||||
|
||||
a.link.own {
|
||||
text-decoration: underline;
|
||||
text-decoration-color: color-mix(
|
||||
in srgb,
|
||||
var(--color-own-links) 45%,
|
||||
transparent
|
||||
);
|
||||
text-underline-offset: 0.15em;
|
||||
|
||||
&:hover {
|
||||
text-decoration-color: currentcolor;
|
||||
}
|
||||
}
|
||||
|
||||
.code,
|
||||
|
||||
Reference in new issue
Block a user