addComponentRow method
- ComponentRowBuilder componentRowBuilder
Allows to add
Implementation
void addComponentRow(ComponentRowBuilder componentRowBuilder) {
componentRows ??= [];
if (componentRowBuilder._components.length > 5 || componentRowBuilder._components.isEmpty) {
throw ArgumentError("Component row cannot be empty or have more than 5 components");
}
if (componentRows!.length == 5) {
throw ArgumentError("Maximum number of component rows is 5");
}
componentRows!.add(componentRowBuilder);
}