I have a calendar with a list of events per day. I currently display a maximum of 3 events per day and allow the user to switch to expand the list.
I hide the list with overflow: hidden and max-height: XXpx property. I am trying to detect events that are currently hidden in this list.
I looked around and could not find anything that would specifically reveal it
I tried:
if (element.offsetHeight < element.scrollHeight || element.offsetWidth < element.scrollWidth) {
} else {
}
and both element.offsetHeightand element.scrollHeightreturn the same value for any of the items on my list.
source
share