mutiny-web icon indicating copy to clipboard operation
mutiny-web copied to clipboard

Truncation underline bridge

Open benalleng opened this issue 1 year ago • 7 comments

Closes #789

Before: image

After: image

benalleng avatar Jan 08 '24 23:01 benalleng

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: 3667cfb
Status: ✅  Deploy successful!
Preview URL: https://104c4886.mutiny-web.pages.dev
Branch Preview URL: https://tx-underline.mutiny-web.pages.dev

View logs

doesn't look quite right on mac chrome. I haven't messed with this in a while but is there a reason we don't just use a <span>…</span> here?

Screenshot 2024-01-10 at 12 20 27 PM

futurepaul avatar Jan 10 '24 12:01 futurepaul

So a normal span doesn't work exactly as I want because the behavior of an overflow is to clip instead of delete characters so we end up with something like below when using <span>…</span> curious if you think you prefer this over trying to adjust the <hr/> for all browsers

image

benalleng avatar Jan 10 '24 17:01 benalleng

I tried setting a default underline offset as it seems like there is a difference between those defaults on firefox and chrome, I tested it myself on a few browsers but I haven't gotten a chance to test on mac

benalleng avatar Jan 10 '24 21:01 benalleng

it's worse on safari for some reason:

Screenshot 2024-01-10 at 9 47 05 PM

So a normal span doesn't work exactly as I want because the behavior of an overflow is to clip instead of delete

ah, the pain is coming back to me lol

futurepaul avatar Jan 10 '24 21:01 futurepaul

image

yeah maybe this can be fudged a bit with some margins or negative margins?

futurepaul avatar Jan 10 '24 21:01 futurepaul

Ok i tried again with some adjustments, I ended up not using relative with positioning and instead opted for a browser based negative margin, also tested on my girlfriend's iPhone and it looks like it worked! Let me know if you're cool with the browser based styling

benalleng avatar Jan 12 '24 18:01 benalleng