Skip to content

Commit ceb1580

Browse files
committed
fix(ui): use :global() for mb-link CSS to silence build warnings
Svelte's scoped CSS never reached {@html}-injected anchors anyway, so the selectors both triggered the css_unused_selector warning and silently failed to style the linkified URLs at runtime.
1 parent f760436 commit ceb1580

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

src/lib/components/Reader.svelte

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -372,7 +372,7 @@
372372
display: block;
373373
}
374374
375-
.mb-link {
375+
:global(.mb-link) {
376376
color: var(--mb-accent, #6366f1);
377377
text-decoration: underline;
378378
cursor: pointer;
@@ -381,14 +381,14 @@
381381
gap: 2px;
382382
word-break: break-all;
383383
}
384-
.mb-link:visited {
384+
:global(.mb-link:visited) {
385385
color: color-mix(in srgb, var(--mb-accent, #6366f1) 60%, #666);
386386
}
387-
.mb-link:hover {
387+
:global(.mb-link:hover) {
388388
color: color-mix(in srgb, var(--mb-accent, #6366f1) 80%, #000);
389389
text-decoration: underline dotted;
390390
}
391-
.mb-link-icon {
391+
:global(.mb-link-icon) {
392392
display: inline-block;
393393
font-size: 0.75em;
394394
opacity: 0.7;

0 commit comments

Comments
 (0)