buildSeoEditorialWorkflowNodes function

List<SeoNode> buildSeoEditorialWorkflowNodes({
  1. required List<SeoEditorialWorkflowStageEntry> stages,
  2. required SeoEditorialWorkflowState initialState,
  3. required SeoEditorialWorkflowViewProjection project,
  4. String? interactionId,
  5. int headingLevel = 2,
  6. String heading = 'Editorial workflow',
  7. String interactionLabel = 'Editorial approval workflow',
  8. String statusLabel = 'Status',
  9. String progressLabel = 'Progress',
  10. String historyLabel = 'History',
  11. String submitLabel = 'Submit for review',
  12. String approveLabel = 'Approve',
  13. String rejectLabel = 'Reject',
  14. String publishLabel = 'Publish',
})

Implementation

List<SeoNode> buildSeoEditorialWorkflowNodes({
  required List<SeoEditorialWorkflowStageEntry> stages,
  required SeoEditorialWorkflowState initialState,
  required SeoEditorialWorkflowViewProjection project,
  String? interactionId,
  int headingLevel = 2,
  String heading = 'Editorial workflow',
  String interactionLabel = 'Editorial approval workflow',
  String statusLabel = 'Status',
  String progressLabel = 'Progress',
  String historyLabel = 'History',
  String submitLabel = 'Submit for review',
  String approveLabel = 'Approve',
  String rejectLabel = 'Reject',
  String publishLabel = 'Publish',
}) {
  final plan = prepareSeoEditorialWorkflowComponent(
    stages: stages,
    initialState: initialState,
    project: project,
    interactionId: interactionId,
    headingLevel: headingLevel,
    heading: heading,
    interactionLabel: interactionLabel,
    statusLabel: statusLabel,
    progressLabel: progressLabel,
    historyLabel: historyLabel,
    submitLabel: submitLabel,
    approveLabel: approveLabel,
    rejectLabel: rejectLabel,
    publishLabel: publishLabel,
  );
  return plan == null ? const [] : buildSeoEditorialWorkflowPlanNodes(plan);
}