I have a table in html page, it can contain some or many records, I want to apply specific css to the table, only when there is a scroll on the table, when there are some records and there is no scroll I don't want this css definition to affect the table. How can I do it?
table **here I need the selector** thead {
width: calc( 100% - .5em )/* scrollbar is average 1em/16px width,
remove it from thead width */
}