containsAnyClass method
Returns true
if attribute class
has any of classes
.
Implementation
bool containsAnyClass(Iterable<String>? classes) {
var attribute = getAttribute('class');
if (attribute == null) return false;
if (classes == null || classes.isEmpty) return false;
for (var c in classes) {
if (attribute.containsValue(c)) {
return true;
}
}
return false;
}