bootprint / bootprint-openapi

Bootprint-module to render OpenAPI specifications, this repository has moved to https://github.com/bootprint/bootprint-monorepo/tree/master/packages/bootprint-openapi
MIT License
357 stars 48 forks source link

Stronger color scheme #89

Closed celsom3 closed 7 years ago

celsom3 commented 7 years ago

This is a suggestion. I noticed that the resulting HTML could be improved by using a stronger color scheme, just to make it a bit more intuitive to follow.

The current colors used are a bit washed out, hardly noticeable.

It seems the change is simple enough. I simply added more saturation to the colors in the theme.less file and I got this result:

screen shot 2017-02-13 at 1 41 20 pm

I would be glad to submit a PR is this is useful.

Another way to go about would be allow passing in options for colors.

nknapp commented 7 years ago

Hi. On the first glance this looks good. Maybe it is slighty too dark for the blue font-color of the tags. I'm not an accessibility expert, but the tags should be well-readable, but maybe the font-color of the tags can be changed as well. That is my only concern, but if you can make sure that there is enough contrast in the tags, I would accept a PR.

As for the "passing options": You can always override the styles with your own less files (see this documentation about configuration files and this CLI reference on how to use them (it's the -f option. Also have a look at the examples: here and here

But for general enhancements I always like to see pull-requests, even though you can probably adapt everything with a config file.

celsom3 commented 7 years ago

Thanks! That actually resolves the issue. If I can override the using my own less files, that works for me. I should have read more of the documentation.

And yes, the legibility would be an issue. In my solution, I simply doubled down on the color and made it more intense/dark, and then changed the color of the content inside .panel-title and tags to be white.

I can submit a PR and leave it up to you. It's more of a matter preference on this, really.

screen shot 2017-02-13 at 3 48 52 pm

Thanks for the help!

nknapp commented 7 years ago

Yeah, overriding styles was one of the main reasons for starting the project in the first place. Maybe I'll just play around the styles some more. I actually like the stronger background, but your last screenshot is a bit exhausting for my eyes as well. This is a difficult topic...