Adaptable - Category headers (CSS)

Adaptable - Category headers (CSS)

by barbara nance -
Number of replies: 4

Hi

I have come across the category headers option in Adaptable and see I can customise the header with a title and CSS. Not being a css expert; can I change here the default H1 to a H2 using css and if so could some one advise the code (sorry!). Recognise that it is possible that I can not!

I am on Moodle 3.8.1 amd Adaptable 2.2.2

Many thanks


Average of ratings: -
In reply to barbara nance

Re: Adaptable - Category headers (CSS)

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

H1 and H2 are HTML tags, so you can't change them with CSS.  CSS only styles things (Cascading Style Sheet), it does not change the markup (Hypertext Markup Language).

In reply to Gareth J Barnard

Re: Adaptable - Category headers (CSS)

by barbara nance -
Gareth many thanks and for being so patient with my questions.
In reply to Gareth J Barnard

Re: Adaptable - Category headers (CSS)

by barbara nance -
Moodle 3.8.1 and Adaptable 2.2.2
Hi Gareth
I eventually got it! Sorry I was being so dense it all new to me but have been reading and watching videos!

I have been playing with changing the size/colour of H3 in the custom CSS area on Adaptable (I don't have access to the php files etc). I have been able to top change the size of H3 but ideally just want it in one area - not throughout the Moodle. I would ideally like the section name to be smaller; and have used the following (from inspecting) but if I add the font-size: 1.17rem; in the { } for the section head nothing changes. It does if I have it as shown but changes Moodle wide. I am missing something but not sure what I am sure it is most likely something obvious!

sectionname {
background-color: #fff!important;
color: #000!important;
margin-bottom: 20px;
padding: 3px 10px;
border-bottom: none #048deb 0;
border-radius: 20px;
border-bottom-right-radius: 0;
border-bottom-left-radius: 0;

}

h3, .h3 {
font-size: 1.17rem;
}
In reply to barbara nance

Re: Adaptable - Category headers (CSS)

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

'sectionname' should have a dot in front of it as its a class.