-
-
Notifications
You must be signed in to change notification settings - Fork 59
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
I would like to add a templateParam to inject custom css. #253
Comments
This proposal would function much like a similar feature in https://github.com/scottie1984/swagger-ui-express#custom-css-styles |
@btimby Hello! Thanks for the issue. The custom css for html-template will be added when we will resolve these issues in the react-component, which renders the html under the hood:
For your case with hiding the sidebar, we already support it in the react-component, but currently we have hardcoded config for it in the template - https://github.com/asyncapi/html-template/blob/master/filters/all.js#L12. Hide/show appropriate section should be done by config, because then template won't render appropriate section and template will less weight. Using css, you only "hide" elements, but they are still in the DOM ...so what about ag ./schema.yaml @asyncapi/html-template -p config='{ "showSidebar": false }' What do you think? |
@magicmatatjahu That sounds like a much better idea. Not knowing how the HTML is generated or what libraries were used, I was happy with simply hiding the sidebar. However, if there are mechanisms for disabling the rendering of it, so much the better. I will investigate how to do this instead of custom css. |
This issue has been automatically marked as stale because it has not had recent activity 😴 It will be closed in 120 days if no further activity occurs. To unstale this issue, add a comment with a detailed explanation. There can be many reasons why some specific issue has no activity. The most probable cause is lack of time, not lack of interest. AsyncAPI Initiative is a Linux Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model. Let us figure out together how to push this issue forward. Connect with us through one of many communication channels we established here. Thank you for your patience ❤️ |
@magicmatatjahu where are we with this one? |
@magicmatatjahu I should have a chance to address your review tomorrow. I am sorry but I missed the notifications (until today). |
This issue has been automatically marked as stale because it has not had recent activity 😴 It will be closed in 120 days if no further activity occurs. To unstale this issue, add a comment with a detailed explanation. There can be many reasons why some specific issue has no activity. The most probable cause is lack of time, not lack of interest. AsyncAPI Initiative is a Linux Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model. Let us figure out together how to push this issue forward. Connect with us through one of many communication channels we established here. Thank you for your patience ❤️ |
ping pong anybody out there 😄 |
This issue has been automatically marked as stale because it has not had recent activity 😴 It will be closed in 120 days if no further activity occurs. To unstale this issue, add a comment with a detailed explanation. There can be many reasons why some specific issue has no activity. The most probable cause is lack of time, not lack of interest. AsyncAPI Initiative is a Linux Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model. Let us figure out together how to push this issue forward. Connect with us through one of many communication channels we established here. Thank you for your patience ❤️ |
This issue has been automatically marked as stale because it has not had recent activity 😴 It will be closed in 120 days if no further activity occurs. To unstale this issue, add a comment with a detailed explanation. There can be many reasons why some specific issue has no activity. The most probable cause is lack of time, not lack of interest. AsyncAPI Initiative is a Linux Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model. Let us figure out together how to push this issue forward. Connect with us through one of many communication channels we established here. Thank you for your patience ❤️ |
Reason/Context
Please try answering few of those questions
This improvement will allow customization of the generated HTML styles. I want this feature to hide the sidebar. In my project, the sidebar is useless as I have but a single channel (thus navigation makes no sense) and the sidebar takes up space. I can use this change for my ends, others could use it for myriad other purposes.
Description
Please try answering few of those questions
I will add a
templateParam
to thepackage.json
file as well as handling for said parameter in the HTML template. When defined, this option will inject a new<style>
tag with the given css. I will add documentation for this new parameter.This will not be a breaking change. No real design is necessary.
The text was updated successfully, but these errors were encountered: