iteration_detail

Single-iteration detail view composing title, phase count, and task status breakdown.

const LABEL_PAD

source

const LABEL_PAD: usize = 8;

Fixed padding width for field labels.

struct Component

source

pub struct Component

Renders the full detail view for a single iteration, including title, phase count, and task breakdown.

Field Type Description
counts TaskCounts Task totals shown in the tasks row.
id String Full iteration ID; the header shows its first 8 characters.
phase_count usize Number of phases, shown in the phases row.
prefix_len usize Number of highlighted characters in the ID header; 2 by default.
title String Iteration title for the title row.

Implements Display.

Component::new

source

pub fn new(
    id: impl Into<String>,
    title: impl Into<String>,
    phase_count: usize,
    counts: TaskCounts,
) -> Self

Create a detail view for the iteration with its title, phase count, and task status totals.

Parameter Type Description
id impl Into<String> the full iteration ID
title impl Into<String> the iteration title
phase_count usize the number of phases
counts TaskCounts the task totals by status
returns Self The view, with a 2-character ID prefix.

Component::prefix_len

source

pub fn prefix_len(self, len: usize) -> Self

Sets the highlighted prefix length passed to the rendered ID.

Parameter Type Description
len usize the prefix length
returns Self The view with the new prefix length.

Component::task_counts_line

source

fn task_counts_line(&self) -> String

Build the tasks row value: the total, then the done, in-progress, open and blocked counts.

Parameter Type Description
returns String The counts joined by muted · separators, each painted in its status style.

struct TaskCounts

source

pub struct TaskCounts

Aggregated task status counts for an iteration summary.

Field Type Description
blocked usize Number of tasks currently blocked by another task.
done usize Number of tasks marked as done.
in_progress usize Number of tasks currently in progress.
open usize Number of tasks still open and not yet started.
total usize Total number of tasks across all statuses.