getSquarePanels method

List<KnowledgePanel> getSquarePanels(
  1. Product product
)

Implementation

List<KnowledgePanel> getSquarePanels(Product product) {
  if ((halfWidthOnMobile ?? false) || (evaluation != null)) {
    return <KnowledgePanel>[this];
  }

  return elements
          ?.map((KnowledgePanelElement e) => e.lookForSquarePanels(product))
          .expand((List<KnowledgePanel> e) => e)
          .toList() ??
      <KnowledgePanel>[];
}