Color change on header (Help)

My code for changing color on header when mouseIn

(does not work)

 export function header1_mouseIn(event) {
    $w("#header1").html = `<h1 style = "color:red">
 ${$w("#header1").text}</h1>`;
}

i get this error “property ‘text’ does not exist on type ‘header’.”
and “property ‘html’ does not exist on type ‘header’.”

Any Ideas? :hugs:

The header element has a style property you can use to update the background color like in this example in the documentation . Additionally, headers are just container objects, so if you want to access the text inside of a header, you’ll need to look at any Text elements inside the Header container.