-
-
Notifications
You must be signed in to change notification settings - Fork 8.7k
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
Document Infima variables #3955
Comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
updating the command to include numbers
I came up with this "order" container/content
colorbase colors
primary
secondary
background
content colors
emphasis
tabs
toc
fontcolor
family
size
navbar
RAW CONTENT
|
Hi @wibed We should definitively improve our Infima docs. Can you please open an issue on Infima repo, as it's now open-sourced? |
aware about the close relationships between infima and Docusaurus, I deem the poor documentation on infimas side a this issue was meant to gather knowledge about all the variables used not the ones available. |
I don't think the list of colors in @wibed's message from above is up-to-date anymore. There are other variables now, such as Beside looking at the source code, is there another way to find out all the overridable colors in Infima? |
@PaulRBerg for now you can only look at source code or through browser DevTools. In fact I don't even think a lot of the non-global colors are stable. |
Any way to change this variables using sass? |
It is intended for the user to override these colours by creating a custom CSS file with something like:
If so, how does one know which variables to change and which are stable? |
It's hard for us to document and guarantee all these variables will remain stable, as well as it's hard to guarantee your custom CSS selectors will keep working forever. We need to be able to do changes. Whatever is not documented can change someday, and whatever is documented can change in major releases. |
Chiming in here. In my opinion, this topic needs more clarity and I think it would be very beneficial to have a better plan on how to further customize Docusaurus websites. For now, it feels like I have to do quite a bit of reverse engineering whenever I want to adjust styling. Or maybe I'm just missing something? |
To be clear, we know it's a problem for users and acknowledge it. It doesn't mean we can do something in the short term, we are not a huge team and there are other priorities to work on. In the meantime, please consider that all undocumented Infima CSS vars are implementation details. You can retro-engineer those to apply customizations, but it's your responsibility to do so. We can't document every single impl detail and make it a public API, otherwise we can't move fast anymore. S imilarly, we don't publicly document all the DOM structures we use and all the classNames, and your custom CSS selectors can break unless we document them as stable. |
Thank you so much for the work you're doing. Am really loving Docusaurus and have used it already for 3 projects. 🚀 |
We should add the infima variables we know so far to https://docusaurus.community |
Not all env variables have to be documented. Some are internal implementation details. If your document them the doc might become stale over time and it's also confusing for users. Internal implementation details are hard to customize on purpose. |
I quickly fetched all infima declared variables from the Infima folder and same for Docusaurus Theme Classic. Here is the list (there are some duplicates I noticed) Infima
Docusaurus
|
it might not be practical to document static values. |
📚 Documentation
there are infima variables, which are neither documented, nor in the global css fileDoes the project follow theming guidelines? If so which are these?
example:
--ifm-font-color-base
defines the font color in relation to the theme, not to be found in the documentation nor in the global css file
yet used in default components.
EDIT:
after sorting few of these css variables, it quickly shows that there is not a clear guideline on how
these configurations relate to each other or the project in general.
which entry has the most prevalence?
is it footer | background | color?
related issues:
#3522
#2961
Have you read the Contributing Guidelines on issues?
yes
The text was updated successfully, but these errors were encountered: