[SOLVED] Change table's CSS to allow alignment override
Posted: Thu Oct 31, 2024 3:52 am
EDIT: See the second post, it was an initial mistake in table formatting.
https://en.wikipedia.org/wiki/Wikipedia ... formatting shows how you can specify custom CSS for tables.
On Recycler's page its' outputs are hard to read because they are centered. I have attempted a custom style and it turned out to not work: https://wiki.factorio.com/index.php?tit ... did=203961 ... I only submitted the change because I fooled myself by getting it to work after I modified the page styles in DevTools.
The following would preserve the old styling by default and allow such overrides to work:
https://wiki.factorio.com/load.php?lang ... vectordark
Add:
When you carry out these modifications in DevTools, my "text-align: left" begins to work (!important isn't needed) yet headings remain centered as expected.
It's possible I'm doing something wrong or such level of detail is not desired
https://en.wikipedia.org/wiki/Wikipedia ... formatting shows how you can specify custom CSS for tables.
On Recycler's page its' outputs are hard to read because they are centered. I have attempted a custom style and it turned out to not work: https://wiki.factorio.com/index.php?tit ... did=203961 ... I only submitted the change because I fooled myself by getting it to work after I modified the page styles in DevTools.
The following would preserve the old styling by default and allow such overrides to work:
https://wiki.factorio.com/load.php?lang ... vectordark
Code: Select all
.wikitable > tr > th, .wikitable > * > tr > th {
background-color: #eaecf0;
text-align: inherit; /* --> changed from center to be controlled by .wikitable or in-page user style */
}
Code: Select all
.wikitable {
/* makes sure table headings remain centered; and to have an effect on inherit IF not overriden by in-page user style */
text-align: center;
}
It's possible I'm doing something wrong or such level of detail is not desired