Monorepo for Tangled tangled.org

fix unexpected background color for content lines in dark mode #21

closed
opened by zzstoatzz.io targeting master

first and last line of any page with file content get this unexpected background color that obscures the text (on dark mode at least)

the empty bg: setting seemed to conflict w Tailwind background coloring in the template

<div class="whitespace-pre peer-target:bg-yellow-200 dark:peer-target:bg-yellow-900">

for example, run this in the console on any such page

document.querySelectorAll('code[style*="background-color:#fff"]').forEach(el => {
    el.style.backgroundColor = '';
});

not so familiar w this stack, preemptive sorry if I missed something!

0
by zzstoatzz.io 4 comments

ope! not sure how I got a merge conflict. any pointers on fixing that appreciated if this change is correct

Hey good catch! I spent all day trying to nail this down yesterday, haha.

And the β€œmerge conflict” just seems to be a weird spacing issue. Can you try git diff | pbcopy (or xclip/wl-clip etc.)?

This is actually fixed on master: https://tangled.sh/@tangled.sh/core/commit/ac3555a1dd5fbf5c49707f00f0982e92f1c6b0e0

It was because of how our template was splitting chroma HTML into lines instead of processing it as is. Should be good now!

closed without merging
sign up or login to add to the discussion
Labels

None yet.

assignee

None yet.

Participants 2
AT URI
at://did:plc:xbtmt2zjwlrfegqvch7fboei/sh.tangled.repo.pull/3llddv6kiwf22