TYPO3-Documentation / render-guides

Render the docs with phpdocumentor/guides
GNU General Public License v3.0
3 stars 6 forks source link

[TASK]: Add all-documentations-menu WebComponent #742

Closed mouflondarko closed 1 month ago

mouflondarko commented 2 months ago

Closes #566

For presentation purposes, all data is mocked as a static JS object

linawolf commented 1 month ago

@mouflondarko thanks a lot for this solution! We like it very much.

I rendered a JSON containting all the manuals here: https://docs.typo3.org/h/typo3/docs-homepage/main/en-us/mainmenu.json

Is it possible to use the result of that JSON to render the menu?

mouflondarko commented 1 month ago

@linawolf sure, the structure looks good and should work as expected. Should the WebComponent fetch this JSON client-side?

mouflondarko commented 1 month ago

@linawolf I've introduced the change in fetching data for the menu, now it should pull current configuration from the url you provided I noticed a CORS-related issue was already encountered in this project (for version switcher), so I did basically the same (tried to modify the original file to make "universal" proxy, but it wasn't working properly, probably due to special characters in URLs – because of limited time I just copied the existing proxy file and slightly modified it, so for local preview a file menu-proxy.php needs to be copied to Documentation-GENERATED-temp/

With the current configuration menu looks like this: obraz Not sure about this long column for System Extensions - I could try splitting long columns

linawolf commented 1 month ago

I can also split the output of the System extensions in two for the JSON. that is probably faster then a CSS / JavaScript solution

linawolf commented 1 month ago

See https://github.com/TYPO3-Documentation/DocsTypo3Org-Homepage/pull/259, the columns should look better now

mouflondarko commented 1 month ago

@linawolf I think it looks good 👍 obraz

linawolf commented 1 month ago

I think so too, what else is needed to make it ready for review?

mouflondarko commented 1 month ago

@linawolf I think it's ready, would appreciate a feedback

linawolf commented 1 month ago

Looks good, I will merge, make a release and try it out in the wild