I am trying to make a custom list cell’s text smaller (the below isn’t working), anyone have idea how can this be achieved?
Help much appreciated!
I am trying to make a custom list cell’s text smaller (the below isn’t working), anyone have idea how can this be achieved?
Help much appreciated!
Hi @trader47,
You can use Bootstrap 5 classes for styling. To adjust the font size, you can use the fs-*
class.
For example:
'referrer_id' => [
'label' => 'Referrer',
'type' => 'partial',
...
'cssClass' => 'fs-3'
]
Alternatively, you can define your own custom classes and apply them in the same way.
OK, this will only work to make font sizes larger, since the smallest one (fs-6) is same as base font size (Text · Bootstrap v5.0 determines the fs-* sizes).
I managed to make it small by using in my column template:
<span style="font-size: 0.75rem">
<?php
// output stuff
?>
</span>
@daft what might be good is a ‘style’ column property here? List Columns - October CMS - 3.x
You could have created a class with “font-size: 0.75rem” and assign it to the column in cssClass
True but that involves creating whole new custom css for my backend. I just wanted to do it quickly