-
-
Notifications
You must be signed in to change notification settings - Fork 21
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
Implement togglable GitLab content & add GitLab intro #186
Conversation
The Intro isn't complete yet but feedback is welcome on how the content is displayed. I ended up going for something different from the tabbed sections we discussed. The current approach makes alternating between Git[La|Hu]b content unnoticeable. I'm currently using a CSS debug feature to visually distinguish the two. |
26f16e0
to
c687842
Compare
4fa3b25
to
90612e9
Compare
62d76f8
to
dce83c5
Compare
This is rebased on #247 to avoid some merge conflicts. Marking this feature beta and providing beta GitLab content for Introduction and alpha for "Authoring Markdown" |
This code does 2 things: 1. Toggles <articles> with ids that start with github- and gitlab- to hide/show either of the two. 2. Stores and reads a parameter from the URL to override and persist the GitHub/GitLab widget selection across pages (without client-side data)
If set to false, only GitHub or GitLab content can be displayed. If set to true, both contents will be displayed one after the other. Additionally, if true, GitHub and GitLab specific content will have a distinctive background taint for easy visual inspection.
This variable is already built into the system and distinguishes a GitHub Pages build from a local build. When built on GitHub Pages, only one of GitHub or GitLab content will be displayed at a time. There will also not be any distinctive background color. When building locally, both GitHub and GitLab content can be displayed side-by-side and will use different background colors.
Also fixes the case when both are selected
b549235
to
01a8d38
Compare
With the move to the new template system happening from May 2023 I'm not sure if this issue still makes sense. I guess the crux is if we want to keep GitLab as an alternative in the same lesson or if instead we make it into a separate lesson. Any strong opinions about either? |
I am not sure if toggable content will be possible in the new Workbench @unode from May 2023. If people have time, maybe they can look into and contributing this feature to the Workbench (unless it is already there). |
There is an argument for keeping this lesson in the Jekyll template, so that it can continue to serve as a "living example" of he tooling and skills it aims to teach. However, there are also myriad reasons to migrate to the Workbench. Perhaps we should have a maintainers meeting some time soon? It's been a while and there are things to discuss. |
We have our next maintainers meeting scheduled for Monday, February 6, 13:30 – 14:30 GMT (UTC+0). Would be good to meet if people are up for is - we have not had one in ages. |
I'm at the moment available to meet on that time slot and would totally be up for it. |
In light of GitHub actions and GitLab no longer being so centered on Jekyll we decided to abandon this direction. |
This pull request adds the HTML/CSS/JS bits to allow
toggling between GitHub and GitLab content.
Currently only the introduction has (some) dual content.
I'll include the GitLab introduction in this pull request.
Will be adding the equivalent steps from GitHub and a GitLab specific section referencing how to configure GitLab for Jekyll.
When building locally the GitHub/GitLab selector will allow selecting both simultaneously for easier editing.
In GitHub Pages builds only one will be shown at a time.
On local builds GitHub and GitLab content will have a light blue or light orange background, respectively.
No background will be set on GitHub Pages builds.