Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

web: Tufte-style sidenotes and justified text #338

Merged
merged 9 commits into from
Jan 26, 2024
Merged

Conversation

plt-amy
Copy link
Member

@plt-amy plt-amy commented Jan 8, 2024

Not much to say here, just gotta wait for the preview to render, I suppose.

@Lavenza
Copy link
Member

Lavenza commented Jan 8, 2024

Pull request preview

@ncfavier
Copy link
Member

The sidebar is gone for me in the preview :(

@SquidDev
Copy link
Collaborator

Is that another instance of #147, just now more visible as the breakpoints have changed again?

SquidDev
SquidDev previously approved these changes Jan 18, 2024
Copy link
Collaborator

@SquidDev SquidDev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is really nice! It's depressing we need to rely on JS at all here, I'm amazed how well it works!

The only problem I've noticed is that footnotes aren't visible when JS is disabled. We could fix it by adding a CSS class to the body from Javascript to enable the footnotes, but I'm not sure either of us can face wrangling the CSS for that, so inclined to say ship it as is :D.

support/web/js/lib/settings.tsx Show resolved Hide resolved
support/web/css/vars.scss Outdated Show resolved Hide resolved
@ncfavier
Copy link
Member

The targets of footnote links (like #fn1) are now missing, so clicking them doesn't do anything. Is that intended?

@plt-amy
Copy link
Member Author

plt-amy commented Jan 18, 2024

@ncfavier Yeah, it's intentional. Since browsers won't move you to a hash that's not painted, clicking the footnote references on the desktop layout does nothing. But when the screen is narrow and the footnotes render again, the footnote references just work, without us having to shuffle the DOM, or override click for the anchors, etc.

@plt-amy plt-amy force-pushed the aliao/sidenotes branch 3 times, most recently from ba092e4 to fb5b0cd Compare January 19, 2024 10:08
@plt-amy plt-amy enabled auto-merge (squash) January 26, 2024 16:00
@plt-amy plt-amy merged commit 7914463 into main Jan 26, 2024
5 checks passed
@plt-amy plt-amy deleted the aliao/sidenotes branch January 26, 2024 16:27
@ncfavier ncfavier mentioned this pull request Jan 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants