The groups.expanded() method returns an array of expanded concurrent event groups for the Scheduler row.
DayPilot.Row.groups.expanded()This method has no parameters.
Returns an array of group objects representing the concurrent event groups that are currently expanded in the row.
Each group object provides the following methods:
expand() - expands the group
collapse() - collapses the group
const expandedGroups = dp.rows.find("A1").groups.expanded();DayPilot.Row.groups.expandAll()
DayPilot.Row.groups.collapseAll()
DayPilot.Row.groups.collapsed()
Concurrent Event Groups [doc.daypilot.org]