Closed erral closed 7 months ago
@erral I am not part of kitconcept so my answer is based solely on my experience, but I have used volto-light-theme in a project and I did some pull requests to improve some of the hardcodes found in the scss theme trying to make it more generic.
One thing that I wanted to change was the fixed line-height and you can see the things that were tried which in the end was deemed as bringing too much complexity without any real benefit for a carefully curated design https://github.com/kitconcept/volto-light-theme/pull/296#issuecomment-1862428020
This package is a core base theme package for kitconcept that tries to implement as pixel-perfect as possible a figma design file. Due to this aspect the theme is using a bunch of fixed dimensions for several css properties, from widths, to colors, to font sizes. In the font-size the idea is that browsers nowadays are good at making the text enlarge even if the font-size is fixed in pixels and that rem values again introduce extra complexity but you can probably change the font-size value mapping to add your own values if this is what you want to use. I prefer rem values as well but I can use my own font-size mappings to set my values.
The reality is that some efforts to make the theme more modular will bring increased maintenance burden and might conflict with the philosophy of having this theme follow the figma design system as pixel-perfect as possible.
As long as you are aware of this fact and you understand that you will perhaps need to have your own _themes.scss and import only what is useful in your theme or be prepared to make overrides this package will be good for your project.
After all this package is part of kitconcept organisation, not collective or plone so I don't fault them for the direction or code that follows their needs, instead I take it as a this is released out in the open, no guarantees given and use it as you seem fit kind of deal :) This doesn't mean they won't improve things and take community feedback or pull requests into consideration but again I think we need to have the proper context into consideration and when needed to accept that in your projects you might need to customize also source code and not just variables.
We don't want to question the decisions taken when developing the theme, we just wanted to know the reasoning to understand the implementation, that's all :)
Thanks!
@erral I think it's a fair question and I'm curious what @sneridagh thinks. No need to close the issue.
This is not an issue by itself it is just a question:
Our designers are asking why this theme is using fixed pixels. Lately we have been developing using
rem
s or other relative values, specially when working where a11y is very important.So, is there any reason for using
px
instead of any relative values?@zetxaniz @libargutxi