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
feat: add sugar, links, css & content to /everything page #55
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you so much! I was worrying about how I was going to get this looking good.
I've left one note inline, but other than that I think it's perfect!
I think I managed a similar look using some CSS wizardry 🧙🏼♂️ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you revert the changes to the existing pages please? And remove the use of !important
.
We could use the same code background colour and style as the website does today. What do you think? https://gleam.run/news/gleam-version-1/
Are you referring to the changes made to
Agreed! I would be able to style the code block itself but I'd like to leave the code's syntax highlighting to you if possible. |
I tweaked, fixed, polished a few things and implemented your feedback. I replicated the code blocks' style, though I'm not 100% convinced by how they look in light mode. What do you think? In the meantime I managed to find a way to allow for the table of contents to be accessed on mobile! Cheers |
Hi, thanks for working on this!
Maybe you could copy the style from the docs website? Although it looks a bit strange with such dramatic drop shadow in this case |
toggle between light & dark variants
Thank you for the feedback ! I tried a bit harder and I think I made it work, using both of your ideas as inspiration. I then got sidetracked with adding syntax highlighting for the code snippets (using highlight.js core) while preserving the current CodeFlask implementation and ended up overhauling most of the codebase 😖! I'll stop myself from adding onto this already huge pull request and wait for your feedback. I think I definitely went too far, hopefully it still suits your needs ! |
Regarding syntax highlighting, I started to collect some thoughts in #59 |
I agree. That's the reason I made the following changes:
I personally am not too keen on Atom One Dark being the default and would like to replace it with something else (Catppuccin perhaps ?) but kept it for now as I did not want to drastically impact the editor's look in this PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you both! Once the note below is resolved let's merge this in and work out what we want to do with syntax highlighting etc later.
@lpil Done ! I've kept the original |
Any news on when / if this can be merged ? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wow! Absolutely incredible work! Thank you so much!
And terribly sorry that I took so long to review this. I appreciate your patience @blksnk !!
Oh! I've just noticed that you've added a bunch of non-brand colours. Please don't do that. |
Hello Gleam team !
While stumbling upon @lpil's stream this evening, I thought I could help out with some CSS and content for the tour.
Context
This PR is aimed at the
single-page
branch since I am not familiar enough with the language / codebase to finish the whole feature mentioned in #36 by myself.This is my first time actually using the language for something other than learning purposes, so feel free to flood this PR with change requests 😄
Code / logic changes
src/tour.gleam
, focusing on theeverything_html
functionstatic/common.css
muted-indigo
color, used as a dim background color for the dark themeoff-white
a tiny bit to improve contrast withwhite
static/style.css
--gap
unit frompx
torem
for better responsiveness--gap-<factor>
variables (quarter, half, double)--color-text-secondary
for both light & dark themes/everything
pageUI / UX Changes
Responsive (kinda for now)
Renders at various screen sizes
Mobile table of contents
Tested in browser down to iPhone SE (320x667 px)
Screen recording on device (Pixel 7)
screen-20240315-003829.2.mp4
Double-scroll layout
More space between elements
Chapter titles in between lessons
Sticky chapter / lesson titles
Revised styling
Light / Dark mode support
Side nav links work as expected
Subtle separators between lessons / chapters
Code previews now feature a
Run
button that links to the corresponding lesson's interactive tour pageTested with
gleam run
+live-server