-
-
Notifications
You must be signed in to change notification settings - Fork 373
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
Restyle Docs Site #3935
Restyle Docs Site #3935
Conversation
- Completely new styling to SkriptLang official documentation website. - Fixed some docs contains missing entries returning empty in the website instead of returning the default return. - Added favicon to the website. - Added Tutorials page (Will have a PR for it soon) - Merged SkriptLang#3889 PR with this PR. - Added quick made logos in the Assets folder in case someone needed it. - Added idScroll.js to automatically highlight current element in the side-navigation - Added copyrights section to the home page. - Added Github page to the menu. Fixed some old Skript github links. **TODO:** - Fix some patterns have HTML codes but due to cleanPattern method they are not parsed.
Added Active Tab JS code to make current page tabs highlighted Fixed some pages should have no-left-panel Fixed some pages have some clipped content such as Text page the copyrights at the end was clipped Fixed images in assets folder were corrupted due being copied as String in the Java Code Fixed multiple styling Fixed responsiveness Added Skript Version to nav-bar Fixed a typo Github -> GitHub Packed all JS codes into main.js
…into feature/docs-site-styling
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.
I very much like this new design, but I do have some comments.
If anyone wants to preview it, extract this zip and open index.html: docs.zip (it doesn't have any region or economy related stuff, but it's good enough for a preview)
…into feature/docs-site-styling
SkriptDocs2.6.zip |
a9201b4
to
cef7eb3
Compare
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.
(if anyone wants to see this online: https://tpgames.tk/docs/index.html)
I did notice that going to https://tpgames.tk/docs/, instead of https://tpgames.tk/docs/index.html will cause some issues:
(grey line appears and Home
is no longer selected)
Correct version:
(btw, sorry: GitHub messed up the review a bit and split it up into two parts)
- Fix indentation using spaces not tabs (Caused some elements to looks like it has padding) - Replaced `fit-content` with `max-content` for Firefox compatibility. - Fix active tab in default home page when not having `index.html` in the link - Fix left-panel scrollbar appearing in default home page.
- Fix indentation using spaces not tabs (Caused some elements to look like it has padding) - Replaced `fit-content` with `max-content` for Firefox compatibility. - Fix active tab in default home page when not having `index.html` in the link - Fix left-panel scrollbar appearing in default home page.
…into feature/docs-site-styling
Editing the commit message due to a typo caused the commits to duplicate, sorry. |
Second commit message is wrong. This is the correct issue related #2705 |
b041db4
to
5a1a8be
Compare
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.
Just a minor change that I don't think was needed. Everything else looks ok.
@AyhamAl-Ali Can you edit the PR message to include all related issues? |
Done 👍 |
Can you modify docs/README.md to tell how to generate docs? |
Part of the bottom of the screen doesn't contain content: Also, I'm not marking #4072 as completed / PR available when there's the scenario of The link icon looks weird in size/position now: |
Okay, I will look into this as soon as I can and regarding the cleanPattern yes there is still a remaining scenario as you said so it is not fully fixed yet. |
- Fixed `cleanPattern` method not fully handling optional brackets (Thanks to @TPGamesNL for helping me with this) - Fixed `classes (types)` having unneeded <code> tags in the patterns - Fixed `classes (types)` patterns not parsing HTML well - Fixed `classes (types)` patterns not parsing links - Improved `HTMLGenerator.class` to use StringBuilder in some cases - Fixed `CommandSender` type example
d75b1e8
to
25e442d
Compare
Few things left for this PR and it will be ready to merge
|
Keeping up.. Big update is coming :) |
- I introduce to you "The Search Bar" which will search the patterns and the syntax name for matches + it has a filter for versions (v:X.Y[.Z][+] - Ex. v: 2.5.3 will filter searches that only match the current search value and the version 2.5.3) (if '+' is added to the end it will also match all versions above the requested version Ex. v:2.5.3+ will match 2.6 and up as well) + added auto focus to the search bar for quicker search. - HighlightJs - This is a nice little addition to the website that will make all the codes look much nicer with colors (even tho not made for Skript but later I will have an update for Skript Syntax highlighting using my own Sk-VSC extension) This has 1 issue though, it made the docs pages take 1-2 seconds to load because it will highlight all the code blocks in the page which are so many. - Improved the homepage + Added a quick overview code to the homepage as a quick Skript example for the users to have an idea what Skript code looks like + download links and contributors size - Improved some styling and changed some old colors + fixed some responsivity - Added jQuery, HighlightJS to the libraries - Fixed DocumentationID annotation, field and method not being used at all in docs generation. - Fixed duplicated IDs - This was due to [wrong]? registration of syntaxes by registering the same class for multiple patterns which caused the docs to have multiple elements with the same ID which broke the search-bar but it has been fixed. - Fixed some typos. - Added multiple placeholders to the docs such as: ${latest-version} ${contributors-size} ${{skript.build.date}. - Fixed code example that uses html list were not working
Adding to the latest commit..
Also, this update contains syntax highlighting for the code blocks which is very nice and cool but it has 1 little issue about loading the doc pages (will take about 1-2 seconds to load the page) which if it is very annoying for most of the users I can enable it only in the homepage which doesn't take long time but other pages will not have any syntax highlighting so I would like to hear your opinion here or on discord |
- Keep in mind that any syntax documentation annotation support HTML codes so if you are using any character that might be treated as HTML tag must be escaped. - Add open-graph meta tags
✅ This PR is now ready to 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.
LGTM.
As per our discussion, you can make a follow-up PR with any speed + SH improvements. :)
- Added a quick fix for the newlines being removed due to minifyHtml which fixes the code example syntax highlighting.
The new design is perfect |
I like this idea. Could probably do something with the |
Indeed. The base of this feature has already been implemented in the search feature, feature already in process + ability to choose new stuff in specific versions :) |
Description
Completely new styling to SkriptLang official documentation website.
Fixed some docs contains missing entries returning empty in the website instead of returning the default return.
Added favicon to the website.
Added Tutorials page (Will have a PR for it soon)
Merged Fix hex codes documentation #3889 PR with this PR.
Added quick made logos in the Assets folder in case someone needed it.
Added idScroll.js to automatically highlight current element in the side-navigation
Added copyrights section to the home page.
Added Github page to the menu.
Added code blocks syntax highlighting
Added
Advanced Live Search Bar
Improved homepage, download links and contributors
Fixed HTML tags not working in the patterns of
/classes/
Many issues fixed (check the related issues section)
Fixed some old Skript github links.
TODO:
✔️
- Fix some patterns have HTML codes but due to cleanPattern method they are not parsed.LIVE VIEW: https://opg4mers.com/skdocs
How it looks (not updated)
Target Minecraft Versions: Any
Requirements: None
Related Issues: #3889 (Merged PR) (#1598 CSS and overall styling improvements) (#611 Related to tutorial and later will have a PR for that as well) (#4072 #4011 Fixed patterns) (#1184 fix a wrong example) (CSS and responsivity improvements) #2705 (#1338 Adding more description as requested in the comment) #2425 #1253