Add CommunityMenu component and change MoreMenu to ContributeMenu#635
Conversation
✅ Deploy Preview for astro-docs-2 ready!Built without sensitive environment variables
To edit notification comments on pull requests, go to your Netlify site settings. |
|
Great work!
|
|
Firstly, I love these contributions @yan-thomas ! 🥳 My thoughts:
Yes, whatever is in mobile view should be behind the hamburger menu. I think only the TOC makes sense for top of the page on mobile.
Slight preference for Community first, I think? I think it's def more important on mobile, but I think placement is less important. (Maybe the stuff at the END is more noticable, easier to reach etc.) So, Community is way more important on mobile. And I'm ok with however we translate that into placement.
Agreed. It should make it clear that it's taking the user to Discord. (On mobile, will clicking the link launch the app? I feel like that's something people should be prepared for, so mentioning Discord specifically on mobile is important, I think.
It's cute! I like it! I'm also open if you find one you like better. :) |
|
Thanks for the comments, @sarah11918 and @delucis!
After a quick look at the code, I don't think it would be hard to make it part of
On mobile, at least for me, it doesn't launch the app (only after you click "accept invite"), but on desktop, it automatically launches the app and it sure is annoying. Great point!
I agree. Not sure what is the general feeling about where we should put "More", but I guess it is safe to also add it to the hamburger menu as part of this PR? |
|
On the left I wondered if we could move these into the nav.ts file. Add an optional icon property to entries in |
How much of a pain is it to have Community/Contribute be: OR b) a separate unit itself that attaches itself after RightSidebar in some cases, and after LeftSidebar in other, so as not to make it actually PART of the LeftSidebar, ever? |
|
Just an update: I did manage to make |
|
I'm loving it! We'll get some feedback whether it makes more sense to have community up top when it's on the Left or in the hamburger menu, or whether it should come after the page nav items. But, the general idea of moving like that is 🔥 ! |
|
Hi @yan-thomas sorry for only getting to this now! (But I hear you recently completed a lot of work on… something… 🤔) Are you still struggling as you mentioned above? Or is this figured out? Visually I think this looks good, but I’m not sure about the order. I think it would make sense for Community to always be last in the sidebar (either on the left or right). Not because the Astro community comes last — 😬 — but because this section is a bit different, pointing to external sites. So on the left you have Start Here, Core Concepts, Basics, etc. … Community What do you think? Also, if the switching between left and right seems overly complex, we could also consider just having this always as part of the left sidebar and keep the right sidebar page-focused (including moving “Astro Docs on GitHub” to the community section). |
I figured it out, I had to do a little hack using
Makes sense to me. I personally don't have a strong opinion on whether it should come first/last, so maybe we should gather others' opinion about this? It is pretty easy to change the order of what comes first/last in the sidebars, so I can show each possible order variation here. |
|
Thanks @yan-thomas! @sarah11918 What do you reckon? Community section to be last in the sidebars instead of first on the left / middle on the right like in the GIF above? |
|
@delucis @yan-thomas Yes, that was going to be my note: community should come AFTER any kind of table of contents (sitewide, or on this page)! I am happy to leave the particulars of the stylings up to the two of you, if you want to move more quickly on that. BUT, strongly agree that if people are looking to navigate, they're going to want CONTENT first! 💜 |
|
Nice! I’ll see if I can move that style to |
|
LGTM! 💜 |



What kind of changes does this PR include?
Description
This PR adds the new
CommunityMenucomponent as part of our sidebar (sidebar expert here, btw) and changesMoreMenutoContributeMenu.The new version looks like this:

I want to point out some of the stuff we can work on and improve here, based on our discussion earlier and my thoughts:
Note: We will need to update the other languages'
ui.tsfile because I changed some entries and added others.