Skip to content

Add project: show more yaml examples #368

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

Merged
merged 6 commits into from
Jun 10, 2024

Conversation

humitos
Copy link
Member

@humitos humitos commented Jun 6, 2024

I used tabs to show different examples of YAML files, as suggested in #184. It looks great for an initial interactive approach.

I like the tabs over the dropdown because it gives the user a clear idea there are more than Sphinx and MkDocs tools supported, which is a good marketing strategy, in my opinion.

It also adds an "Others" option that's more generic and shows how to use build.commands in a generic way: install dependencies, build, copy assets under $READTHDOCS_OUTPUT directory.

Peek 2024-06-06 13-33

I used tabs to show different examples of YAML files, as suggested in #184.
It looks great for an initial interactive approach.

I like the tabs over the dropdown because it gives the user a clear idea there
are more than Sphinx and MkDocs tools supported, which is a good marketing
strategy, in my opinion.

It also adds an "Others" option that's more generic and shows how to use
`build.commands` in a generic way: install dependencies, build, copy assets
under `$READTHDOCS_OUTPUT` directory.
@humitos humitos requested a review from a team as a code owner June 6, 2024 12:06
@humitos humitos requested a review from agjohnson June 6, 2024 12:06
humitos added a commit that referenced this pull request Jun 6, 2024
I used `highlight.js` to highlight the examples when importing a project.
It requires importing a CSS file that I'm not sure where to put it yet.

https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.9.0/styles/dark.min.css

Besides, I need to know where to place the small chunk of JS code that I added
to make this work.

Based on #368
Copy link
Contributor

@agjohnson agjohnson 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 looking good! I think I might want to retain the dropdown over tabs if possible, the length of tabs and count of tabs will cause this to wrap in awkward ways. The dropdown was used to avoid these two issues.

@humitos
Copy link
Member Author

humitos commented Jun 10, 2024

Final version 🚀

Peek 2024-06-10 13-52

@humitos humitos requested a review from agjohnson June 10, 2024 11:52
Copy link
Contributor

@agjohnson agjohnson left a comment

Choose a reason for hiding this comment

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

This looks great. I think we can tune these examples quite a bit once we have more examples, but they are good for now.

@humitos humitos merged commit 228f122 into main Jun 10, 2024
@humitos humitos deleted the humitos/yaml-examples-import-project branch June 10, 2024 21:24
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.

Add JS for swapping examples on project creation form Projects: project creation form configuration file example/templates
2 participants