How to make the left-most column fit to content in vertical table? - vmware-clarity

Is there a way to make the left most column fit to it's content in a vertical table?
Expectation:
Actual:

Here is one way to auto-fit a columns width to its content using css.
On the th element you want to fit to content, add this class:
.auto-fit {
width: 1px;
white-space: nowrap;
}
StackBlitz with running code is here: https://stackblitz.com/edit/so-52815432-auto-fit-width-to-content

.auto-fit-vertical th {
width: 1px;
white-space: nowrap;
}
.auto-fit-vertical td {
width:100%;
}
<table class="table table-compact table-vertical auto-fit-vertical">
<tbody>
<tr>
<th>Username</th>
<td style="font-weight: bold">{{user?.userName}}</td>
</tr>
<tr>
<th>Email</th>
<td>{{user?.email}}</td>
</tr>
<tr>
<th>Email Confirmed</th>
<td [ngStyle]="{ color: user?.emailConfirmed ? 'green' : 'red' }">
<clr-icon [attr.shape]="user?.emailConfirmed ? 'check' : 'times'"></clr-icon>
</td>
</tr>
<tr>
<th>Recovery Email</th>
<td>{{user?.recoveryEmail}}</td>
</tr>
<tr>
<th>Mobile Number</th>
<td>{{user?.mobileNo}}</td>
</tr>
<tr>
<th>Phone Number</th>
<td>{{user?.phoneNumber}}</td>
</tr>
<tr>
<th>Phone Number Confirmed</th>
<td [ngStyle]="{ color: user?.phoneNumberConfirmed ? 'green' : 'red' }">
<clr-icon [attr.shape]="user?.phoneNumberConfirmed ? 'check' : 'times'"></clr-icon>
</td>
</tr>
<tr>
<th>Is System Administrator</th>
<td [ngStyle]="{ color: user?.isSystemAdministrator ? 'green' : 'red' }">
<clr-icon [attr.shape]="user?.isSystemAdministrator ? 'check' : 'times'"></clr-icon>
</td>
</tr>
<tr>
<th>Is Two-Factor Enabled</th>
<td [ngStyle]="{ color: user?.twoFactorEanbled ? 'green' : 'red' }">
<clr-icon [attr.shape]="user?.twoFactorEanbled ? 'check' : 'times'"></clr-icon>
</td>
</tr>
<tr>
<th>Is Lockout Enabled</th>
<td [ngStyle]="{ color: user?.lockout ? 'green' : 'red' }">
<clr-icon [attr.shape]="user?.lockout ? 'check' : 'times'"></clr-icon>
</td>
</tr>
<tr>
<th>Is Confirmed</th>
<td [ngStyle]="{ color: user?.confirmed ? 'green' : 'red' }">
<clr-icon [attr.shape]="user?.confirmed ? 'check' : 'times'"></clr-icon>
</td>
</tr>
<tr>
<th>Is Active</th>
<td [ngStyle]="{ color: user?.active ? 'green' : 'red' }">
<clr-icon [attr.shape]="user?.active ? 'check' : 'times'"></clr-icon>
</td>
</tr>
<tr>
<th>Date Created</th>
<td>{{user?.dateCreated|date:'long'}}</td>
</tr>
</tbody>
</table>

Related

Is there anyway to reorder of row <tr> in table by css?

I have a table with 3 row like below. How can I change the order of row by CSS?
Example:
Name: A B C
Age: 1 2 3
Country: US CA CN
And I want it become:
Country: US CA CN
Name: A B C
AGE: 1 2 3
<table class="details">
<tbody>
<tr class="name">
<td class="label"><label for="name">Fullname</label></td>
<td class="value name-wrapper">name</td>
</tr>
<tr class="Age">
<td class="label"><label for="age">Age</label></td>
<td class="value age-wrapper">26</td></tr>
<tr class="Country">
<td class="label"><label for="country">Country</label></td>
<td class="value country-wrapper">US</td></tr>
</tbody>
</table>
You can use flex-direction: column-reverse on parent elements to reverse the order of their children. Use flex-direction: row-reverse for rows.
tbody { display: flex; flex-direction: column-reverse; }
<table class="details">
<tbody>
<tr class="name">
<td class="label"><label for="name">Fullname</label></td>
<td class="value name-wrapper"></td>
</tr>
<tr class="Age">
<td class="label"><label for="age">Age</label></td>
<td class="value age-wrapper"></td>
</tr>
<tr class="Country">
<td class="label"><label for="country">Country</label></td>
<td class="value country-wrapper"></td>
</tr>
</tbody>
</table>
I think the only way to do this is to consider some visual hack by using transform. Make sure border-spacing is set to 0 to avoid complex calculation and be aware that this work fine if all the tr have the same height.
tr {
/*we move all the tr down by one row*/
transform:translateY(100%);
}
tr.country {
/*we move the country tr up by two rows*/
transform:translateY(-200%);
}
table {
border-spacing:0;
}
td {
padding:5px;
}
<table class="details">
<tbody>
<tr class="name">
<td class="label"><label for="name">Fullname</label></td>
<td class="value name-wrapper">name</td>
</tr>
<tr class="age">
<td class="label"><label for="age">Age</label></td>
<td class="value age-wrapper">26</td></tr>
<tr class="country">
<td class="label"><label for="country">Country</label></td>
<td class="value country-wrapper">US</td></tr>
</tbody>
</table>
You can do this with flex and order and position them however you want. Disclaimer, with this solution tr won't have display: table-row-group so you'll have to write additional css for positioning your cells:
tbody {
display:flex;
flex-direction: column;
}
tr:nth-child(2) {
order: -1;
}
tr:nth-child(1) {
order: 1;
}
<table class="details">
<tbody>
<tr class="name">
<td class="label"><label for="name">Fullname</label></td>
<td class="value name-wrapper">name</td>
</tr>
<tr class="Age">
<td class="label"><label for="age">Age</label></td>
<td class="value age-wrapper">26</td></tr>
<tr class="Country">
<td class="label"><label for="country">Country</label></td>
<td class="value country-wrapper">US</td></tr>
</tbody>
</table>
Updated added updated HTML.

CSS vertical-align, how can I remove the little spacing below the text?

I have this code. Despite of being inside a td, and having specified this CSS:
.day {
text-align: right;
padding: 5px;
vertical-align: middle;
border: 1px solid black;
}
.day--hole {
color: lightgray;
}
.day--today {
background: pink;
}
<table>
<tbody>
<tr>
<td class="day day--hole">30</td>
<td class="day day--hole">31</td>
<td class="day">1</td>
<td class="day">2</td>
<td class="day">3</td>
<td class="day">4</td>
<td class="day">5</td>
</tr>
<tr>
<td class="day">6</td>
<td class="day">7</td>
<td class="day">8</td>
<td class="day">9</td>
<td class="day">10</td>
<td class="day">11</td>
<td class="day">12</td>
</tr>
<tr>
<td class="day">13</td>
<td class="day">14</td>
<td class="day">15</td>
<td class="day">16</td>
<td class="day">17</td>
<td class="day">18</td>
<td class="day">19</td>
</tr>
<tr>
<td class="day">20</td>
<td class="day day--today">21</td>
<td class="day">22</td>
<td class="day">23</td>
<td class="day">24</td>
<td class="day">25</td>
<td class="day">26</td>
</tr>
<tr>
<td class="day">27</td>
<td class="day">28</td>
<td class="day">29</td>
<td class="day">30</td>
<td class="day">31</td>
<td class="day day--hole">1</td>
<td class="day day--hole">2</td>
</tr>
</tbody>
</table>
There's a visible gap between the position where the text should be centered and the current position of the text. It looks "upper" than it should and not totally centered. Why does this happen and how can I solve it without recurring to change the HTML or use flexbox?
That's because these numbers technically are text, and text - when using letters - has letters like g, j, p etc. which extend below the baseline. That's part of the line-height, and the vertical centering centers that line-height, regardless if there are letters like g, j, p in the text or not. So it looks a bit vertically offset as you describe it.
To compensate that, you could apply a vertical offset, as I did it in the first and last row of this snippet, using a wrapper for the numbers and applying position: relative and transform: translateY(1px); (or any value you like) to it:
.day {
text-align: right;
padding: 5px;
vertical-align: middle;
border: 1px solid black;
}
.day--hole {
color: lightgray;
}
.day--today {
background: pink;
}
.offset {
position: relative;
transform: translateY(1px);
}
<table>
<tbody>
<tr>
<td class="day day--hole"><div class="offset">30</div></td>
<td class="day day--hole"><div class="offset">31</div></td>
<td class="day"><div class="offset">1</div></td>
<td class="day"><div class="offset">2</div></td>
<td class="day"><div class="offset">3</div></td>
<td class="day"><div class="offset">4</div></td>
<td class="day"><div class="offset">5</div></td>
</tr>
<tr>
<td class="day">6</td>
<td class="day">7</td>
<td class="day">8</td>
<td class="day">9</td>
<td class="day">10</td>
<td class="day">11</td>
<td class="day">12</td>
</tr>
<tr>
<td class="day">13</td>
<td class="day">14</td>
<td class="day">15</td>
<td class="day">16</td>
<td class="day">17</td>
<td class="day">18</td>
<td class="day">19</td>
</tr>
<tr>
<td class="day">20</td>
<td class="day day--today">21</td>
<td class="day">22</td>
<td class="day">23</td>
<td class="day">24</td>
<td class="day">25</td>
<td class="day">26</td>
</tr>
<tr>
<td class="day"><div class="offset">27</div></td>
<td class="day"><div class="offset">28</div></td>
<td class="day"><div class="offset">29</div></td>
<td class="day"><div class="offset">30</div></td>
<td class="day"><div class="offset">31</div></td>
<td class="day day--hole"><div class="offset">1</div></td>
<td class="day day--hole"><div class="offset">2</div></td>
</tr>
</tbody>
</table>
As an example I made the height higher than needed. But give the example below a try. The height and line-height should be equal to center the text.
let height = document.getElementById('height');
let days = Array.from( document.querySelectorAll('.day') );
height.addEventListener('input', () => {
days.forEach( day => {
day.style.setProperty( '--height', `${height.value}px` );
});
});
.day {
text-align: right;
padding: 5px;
height: var(--height);
line-height: var(--height);
border: 1px solid black;
}
.day--hole {
color: lightgray;
}
.day--today {
background: pink;
}
:root {
--height: 40px;
}
<form>
<label for="height">Height (play with it to say that the text remains centered)</label>
<input type="number" id="height" min="1" value="40">
</form>
<table>
<tbody>
<tr>
<td class="day day--hole">30</td>
<td class="day day--hole">31</td>
<td class="day">1</td>
<td class="day">2</td>
<td class="day">3</td>
<td class="day">4</td>
<td class="day">5</td>
</tr>
<tr>
<td class="day">6</td>
<td class="day">7</td>
<td class="day">8</td>
<td class="day">9</td>
<td class="day">10</td>
<td class="day">11</td>
<td class="day">12</td>
</tr>
<tr>
<td class="day">13</td>
<td class="day">14</td>
<td class="day">15</td>
<td class="day">16</td>
<td class="day">17</td>
<td class="day">18</td>
<td class="day">19</td>
</tr>
<tr>
<td class="day">20</td>
<td class="day day--today">21</td>
<td class="day">22</td>
<td class="day">23</td>
<td class="day">24</td>
<td class="day">25</td>
<td class="day">26</td>
</tr>
<tr>
<td class="day">27</td>
<td class="day">28</td>
<td class="day">29</td>
<td class="day">30</td>
<td class="day">31</td>
<td class="day day--hole">1</td>
<td class="day day--hole">2</td>
</tr>
</tbody>
</table>
.day has text-align: right; on it. Set that to text-align: center;

Reposonsive table with headers and Y scroll [duplicate]

This question already has answers here:
How to set tbody height with overflow scroll
(16 answers)
Closed 5 years ago.
I'm stuck on a table design.
My headers aren't lining up with my body tds, and my scroll is throwing off alignment.
I imagine I could just use a
table-header-group
However, that loses my scroll.
If I put it an a div, then I lose my header to the scroll.
Attached is a fiddle for viewing.
Anyways, How can I:
1. Align my head with the body
2. use scroll in the Y
3. Fit the data using as a responsive table
First, Fiddle with weird CSS "display:" usage
Fiddle
Updated Fiddle height of 80px overridden:
https://jsfiddle.net/t1zss67n/4/
Your display reset could be on every tr, then adding a padding to thead of equal average width of the scrollbar should do. https://jsfiddle.net/t1zss67n/5/
actually very similar to How to set tbody height with overflow scroll
thead {
display:block;
padding-right:17px ;
}
thead tr, tbody tr {
display:table;
width:100%;
table-layout:fixed;
}
.thead {
background-clip: padding-box;
background-color: #f5f5f5;
background-image: linear-gradient(to bottom,#fafafa 0,#ededed 100%);
background-repeat: repeat-x;
font-weight: 700;
font-size: 12px;
}
table ,tr td{
border:1px solid red
}
tbody {
max-height: 800px;
}
tbody {
display:block;
overflow-y:scroll;
}
thead {
display:block;
padding-right:17px ;
}
thead tr, tbody tr {
display:table;
width:100%;
table-layout:fixed;
}
tr td:first-child {
width: 60px;
}
.table-hover>tbody>tr:hover> td{
background-color: #ffa;
border-bottom-color: #ffa;
}
.table-hover>tbody>tr>td:hover:not(:first-child) {
background-color: #fff;
border: 1px solid #aaa;
}
td {
text-overflow: ellipsis;
width: 10px;
white-space: nowrap;
overflow: hidden;
padding: 2px;
}
<table class="table table-hover table-responsive">
<thead>
<tr class="thead">
<td>Name</td>
<td>Nov16</td>
<td>Dec16</td>
<td>Jan17</td>
<td>Feb17</td>
<td>Mar17</td>
<td>Apr17</td>
<td>May17</td>
<td>Jun17</td>
<td>Jul17</td>
<td>Aug17</td>
<td>Sept17</td>
<td>Oct17</td>
<td>RTM</td>
<td >2012</td>
<td>2013</td>
<td>2014</td>
<td>2015</td>
<td>2016</td>
<td>YTD</td>
</tr>
</thead>
<tbody>
<tr role="row">
<td class="text-left">Gabe Maloney</td>
<td class="text-right">253</td>
<td class="text-right">229</td>
<td class="text-right">78</td>
<td class="text-right">36</td>
<td class="text-right">236</td>
<td class="text-right">107</td>
<td class="text-right">106</td>
<td class="text-right">246</td>
<td class="text-right">66</td>
<td class="text-right">71</td>
<td class="text-right">172</td>
<td class="text-right">235</td>
<td class="text-right ttm">1728</td>
<td class="text-right">1943</td>
<td class="text-right">1275</td>
<td class="text-right">1810</td>
<td class="text-right">225</td>
<td class="text-right">985</td>
<td class="text-right ytd">896</td>
</tr>
<tr role="row">
<td class="text-left">Adrien Johnson</td>
<td class="text-right">274</td>
<td class="text-right">291</td>
<td class="text-right">195</td>
<td class="text-right">133</td>
<td class="text-right">171</td>
<td class="text-right">19</td>
<td class="text-right">79</td>
<td class="text-right">31</td>
<td class="text-right">262</td>
<td class="text-right">208</td>
<td class="text-right">58</td>
<td class="text-right">117</td>
<td class="text-right ttm">1819</td>
<td class="text-right">1799</td>
<td class="text-right">1010</td>
<td class="text-right">336</td>
<td class="text-right">417</td>
<td class="text-right">1803</td>
<td class="text-right ytd">755</td>
</tr>
<tr role="row">
<td class="text-left">Axel Johnson</td>
<td class="text-right">275</td>
<td class="text-right">294</td>
<td class="text-right">232</td>
<td class="text-right">80</td>
<td class="text-right">128</td>
<td class="text-right">143</td>
<td class="text-right">255</td>
<td class="text-right">235</td>
<td class="text-right">186</td>
<td class="text-right">48</td>
<td class="text-right">97</td>
<td class="text-right">199</td>
<td class="text-right ttm">2029</td>
<td class="text-right">1031</td>
<td class="text-right">787</td>
<td class="text-right">333</td>
<td class="text-right">1259</td>
<td class="text-right">1261</td>
<td class="text-right ytd">1020</td>
</tr>
<tr role="row">
<td class="text-left">George Johnson</td>
<td class="text-right">39</td>
<td class="text-right">102</td>
<td class="text-right">127</td>
<td class="text-right">171</td>
<td class="text-right">128</td>
<td class="text-right">283</td>
<td class="text-right">201</td>
<td class="text-right">231</td>
<td class="text-right">34</td>
<td class="text-right">150</td>
<td class="text-right">76</td>
<td class="text-right">80</td>
<td class="text-right ttm">1339</td>
<td class="text-right">907</td>
<td class="text-right">1221</td>
<td class="text-right">1876</td>
<td class="text-right">999</td>
<td class="text-right">2012</td>
<td class="text-right ytd">772</td>
</tr>
<tr role="row">
<td class="text-left">Reek Jones</td>
<td class="text-right">224</td>
<td class="text-right">109</td>
<td class="text-right">162</td>
<td class="text-right">192</td>
<td class="text-right">226</td>
<td class="text-right">270</td>
<td class="text-right">257</td>
<td class="text-right">65</td>
<td class="text-right">137</td>
<td class="text-right">172</td>
<td class="text-right">168</td>
<td class="text-right">173</td>
<td class="text-right ttm">1885</td>
<td class="text-right">1086</td>
<td class="text-right">649</td>
<td class="text-right">447</td>
<td class="text-right">480</td>
<td class="text-right">825</td>
<td class="text-right ytd">972</td>
</tr>
<tr role="row">
<td class="text-left">JP Lefkort</td>
<td class="text-right">76</td>
<td class="text-right">82</td>
<td class="text-right">18</td>
<td class="text-right">54</td>
<td class="text-right">27</td>
<td class="text-right">240</td>
<td class="text-right">50</td>
<td class="text-right">248</td>
<td class="text-right">197</td>
<td class="text-right">294</td>
<td class="text-right">20</td>
<td class="text-right">262</td>
<td class="text-right ttm">1328</td>
<td class="text-right">2007</td>
<td class="text-right">143</td>
<td class="text-right">1126</td>
<td class="text-right">803</td>
<td class="text-right">1771</td>
<td class="text-right ytd">1071</td>
</tr>
<tr role="row">
<td class="text-left">Susan Segal</td>
<td class="text-right">101</td>
<td class="text-right">236</td>
<td class="text-right">95</td>
<td class="text-right">204</td>
<td class="text-right">213</td>
<td class="text-right">197</td>
<td class="text-right">292</td>
<td class="text-right">49</td>
<td class="text-right">44</td>
<td class="text-right">75</td>
<td class="text-right">137</td>
<td class="text-right">49</td>
<td class="text-right ttm">1495</td>
<td class="text-right">1215</td>
<td class="text-right">1667</td>
<td class="text-right">546</td>
<td class="text-right">753</td>
<td class="text-right">849</td>
<td class="text-right ytd">646</td>
</tr>
<tr role="row">
<td class="text-left">Antonio Townsend</td>
<td class="text-right">244</td>
<td class="text-right">198</td>
<td class="text-right">98</td>
<td class="text-right">262</td>
<td class="text-right">281</td>
<td class="text-right">141</td>
<td class="text-right">219</td>
<td class="text-right">273</td>
<td class="text-right">123</td>
<td class="text-right">68</td>
<td class="text-right">15</td>
<td class="text-right">114</td>
<td class="text-right ttm">1895</td>
<td class="text-right">143</td>
<td class="text-right">1612</td>
<td class="text-right">1564</td>
<td class="text-right">148</td>
<td class="text-right">1042</td>
<td class="text-right ytd">812</td>
</tr>
</tbody>
</table>
Answered: Do not scroll table headings when scrolling down a html table
See specifically:
http://www.imaputz.com/cssStuff/bigFourVersion.html
This fiddle may provide the best solution though
jsfiddle.net/deborah/Msvvr/

Change the color of buttons designed by table with CSS

Considering the following code displaying two different buttons structured by a table (<tbody class="btn btn-left"> is a button and <tbody class="btn btn-right"> is another button:
<table>
<tbody class="btn btn-left">
<tr>
<td class="btn-tl"></td>
<td class="btn-tc"></td>
<td class="btn-tr"></td>
</tr>
<tr>
<td class="btn-ml"></td>
<td class="btn-mc"></td>
<td class="btn-mr"></td>
</tr>
<tr>
<td class="btn-bl"></td>
<td class="btn-bc"></td>
<td class="btn-br"></td>
</tr>
</tbody>
</table>
<table>
<tbody class="btn btn-right">
<tr>
<td class="btn-tl"></td>
<td class="btn-tc"></td>
<td class="btn-tr"></td>
</tr>
<tr>
<td class="btn-ml"></td>
<td class="btn-mc"></td>
<td class="btn-mr"></td>
</tr>
<tr>
<td class="btn-bl"></td>
<td class="btn-bc"></td>
<td class="btn-br"></td>
</tr>
</tbody>
</table>
The css is working but doesn't target the td, which I need to
.btn-left {
background-color: red;
border-color: red;
}
.btn-right {
background-color: blue;
border-color: blue;
}
How would you set up the css so that one button displays a color and the other button displays another color ?
Thank you for your help.
at first - you must use the table tag.
Then put following classes in your Stylesheet:
.btn-left { color: blue; }
.btn-right { color: red; }
a liddle fiddle

Is it possible to fix <footer> in bootstraptable?

i found the showFooter Property. but i do not get how to customize the Content for that.
i only need to fill three of total 8 in ...
so table Looks basically like this:
<div class="table-responsive">
<table class="table table-bordered" id="tblKontoauszug">
<thead>
<tr>
<th data-sortable="#sortable" data-sorter="dateSorter">Buchungsdat.</th>
<th data-sortable="#sortable">Belegnr.</th>
<th data-sortable="#sortable">BA</th>
<th data-sortable="#sortable" data-sorter="betragSorter">Betrag</th>
<th data-sortable="#sortable">Buchungstext</th>
<th data-sortable="#sortable">Gegenkontoart</th>
<th data-sortable="#sortable">Gegenkonto</th>
<th data-sortable="#sortable">Bezeichnung</th>
</tr>
<tr class="info text-bold">
<td>
#if ( Model.Zeilen.Count() > 0 )
{
<span>#Model.Zeilen.Min(b => b.Buchungsdatum).ToShortDateString()</span>
}
</td>
<td colspan="2">Anfangsbestand</td>
<td class="text-right">#Model.Anfangsbestand.ToString("N")</td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
</thead>
<tfoot>
<tr class="info text-bold">
<td>
#if ( Model.Zeilen.Count() > 0 )
{
<span>#Model.Zeilen.Max( b => b.Buchungsdatum ).ToShortDateString()</span>
}
</td>
<td colspan="2">Endbestand</td>
<td class="text-right #( Model.Endbestand < 0 ? "negative" : "")">#Model.Endbestand.ToString( "N" )</td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
</tfoot>
<tbody>
#foreach ( var zeile in Model.Zeilen )
{
<tr>
<td>#zeile.Buchungsdatum.ToShortDateString()</td>
<td>#zeile.Belegnummer</td>
<td title="#zeile.BelegartText">#zeile.Belegart</td>
<td class="text-right #( zeile.Betrag < 0 ? "negative" : "")">#zeile.Betrag.ToString("N")</td>
<td>#zeile.Buchungstext</td>
<td>#zeile.Gegenkontoart</td>
<td>#zeile.Gegenkonto</td>
<td>#zeile.Bezeichnung</td>
</tr>
}
</tbody>
</table>
</div>
You can customize content in the footer by adding the data-footer-formatter attribute to the column you want to add the footer to and setting that attribute equal to a defined javascript function. Here's an example:
HTML:
<table data-toggle="table" data-show-footer="true" data-footer-style="footerStyle" data-show-columns="true">
<thead>
<tr>
<th data-sortable="true" data-footer-formatter="totalText">Name</th>
<th data-sortable="true" data-footer-formatter="carsSum"># Cars</th>
</tr>
</thead>
<tbody>
<tr>
<td>Johnny</td>
<td>2</td>
</tr>
<tr>
<td>Zack</td>
<td>3</td>
</tr>
<tr>
<td>Timmy</td>
<td>2</td>
</tr>
</tbody>
</table>
Javascript:
function totalText(data) {
return 'TOTAL';
}
function carsSum(data) {
return '7';
}
function footerStyle(value, row, index) {
return {
css: { "font-weight": "bold" }
};
}
Notice I'm not using <tfoot> at all here. That is because <tfoot> won't work with the show columns dropdown list but this will (if I were to use the data-show-columns="true" attribute on the <table> element as I did in the example above). You can also style the footer using the data-footer-style attribute. In my example, I'm making all text in the footer bold.
You can see the code in action here: https://jsfiddle.net/3mou92px/9/

Resources