blib/lib/Mojolicious/Plugin/Fondation/Workflow/UI/Bootstrap.pm

filter: Statementstmt 2.9% 5 / 167 Branchbran 0.0% 0 / 80 Conditioncond 0.0% 0 / 82 MC/DCmcdc 0.0% 0 / 47 Subroutinesub 10.0% 1 / 10 Podpod 50.0% 1 / 2 totaltotal 1.8% 7 / 388 CC 90 SCAR 61.4
CC
90
Cov
2%
__ANON__
930.0
__ANON__
420.0
__ANON__
342.0
CRAP 462.5
↑ Summary
1 package Mojolicious::Plugin::Fondation::Workflow::UI::Bootstrap;
2 1 $Mojolicious::Plugin::Fondation::Workflow::UI::Bootstrap::VERSION = '0.02';
3 # ABSTRACT: Bootstrap 5 UI components for Fondation::Workflow
4 #
5 # Provides template helpers for rendering workflow state badges,
6 # action buttons, history timelines, progress bars, and Mermaid.js graphs.
7  
8 1 ▶use Mojo::Base 'Mojolicious::Plugin', -signatures;
Subroutine BEGIN: called CC=1 SCAR=0.0
9  
10 0 ▶sub fondation_meta {
Subroutine fondation_meta: not called CC=1 SCAR=6.9
Pod undocumented
11 return {
12 0 dependencies => [
13 'Fondation::Layout::Bootstrap',
14 'Fondation::Workflow',
15 ],
16 };
17 }
18  
19 0 ▶sub register ($self, $app, $conf) {
Subroutine register: not called CC=1 SCAR=6.9
Pod documented
20  
21 # ── workflow_state($wf) — state badge ──────────────────────────────
22  
23 0 ▶ $app->helper(workflow_state => sub ($c, $wf, %attrs) {
Subroutine __ANON__: not called CC=5 SCAR=34.0
24 0 ▶ return '' unless $wf && ref $wf;
Branch: 1 branch
BranchTrueFalseTotal
unless $wf and ref $wf 0 0 0
Condition0%0/3
$wf and ref $wf
!ll&&!rl&&r
000
MC/DC0%0/2
$wf and ref $wf
$wf ref $wf
Truth table0%0/3
A and B
A= $wfB= ref $wf
ABresult
0X0
100
111
25 0 my $state = $wf->state;
26 0 my $label = $wf->state_label;
27 0 my $color = $wf->state_color;
28 0 my $icon = $wf->state_icon;
29  
30 0 ▶ my $icon_html = $icon ? qq{<i class="bi bi-$icon me-1"></i>} : '';
Branch: 1 branch
BranchTrueFalseTotal
$icon ? : 0 0 0
31 0 ▶ my $class = join ' ', 'badge', "bg-$color", ($attrs{class} // '');
Condition0%0/2
$attrs{"class"} // ""
l!l
00
MC/DC0%0/1
$attrs{"class"} // ""
$attrs{"class"}
Truth table0%0/2
A
A= $attrs{"class"}
Aresult
11
00
32 0 return qq{<span class="$class">$icon_html$label</span>};
33 0 });
34  
35 # ── workflow_actions($wf) — action buttons ────────────────────────
36  
37 0 ▶ $app->helper(workflow_actions => sub ($c, $wf, %attrs) {
Subroutine __ANON__: not called CC=9 SCAR=45.0
38 0 ▶ return '' unless $wf && ref $wf;
Branch: 1 branch
BranchTrueFalseTotal
unless $wf and ref $wf 0 0 0
Condition0%0/3
$wf and ref $wf
!ll&&!rl&&r
000
MC/DC0%0/2
$wf and ref $wf
$wf ref $wf
Truth table0%0/3
A and B
A= $wfB= ref $wf
ABresult
0X0
100
111
39 0 my $actions = $wf->actions;
40 0 ▶ return '' unless $actions && @$actions;
Branch: 1 branch
BranchTrueFalseTotal
unless $actions and @$actions 0 0 0
Condition0%0/3
$actions and @$actions
!ll&&!rl&&r
000
MC/DC0%0/2
$actions and @$actions
$actions @$actions
Truth table0%0/3
A and B
A= $actionsB= @$actions
ABresult
0X0
100
111
41  
42 0 my $html = '';
43 0 for my $a (@$actions) {
44 0 my $color = "btn-$a->{color}";
45 0 ▶ my $icon = $a->{icon} ? qq{<i class="bi bi-$a->{icon} me-1"></i>} : '';
Branch: 1 branch
BranchTrueFalseTotal
$a->{'icon'} ? : 0 0 0
46 0 ▶ my $confirm = $a->{confirm} ? qq{ data-confirm="$a->{confirm}"} : '';
Branch: 1 branch
BranchTrueFalseTotal
$a->{'confirm'} ? : 0 0 0
47 0 $html .= qq{<button class="btn btn-sm $color workflow-action"$confirm data-action="$a->{name}">$icon$a->{label}</button>\n};
48 }
49 0 ▶ my $class = join ' ', 'btn-group', ($attrs{class} // '');
Condition0%0/2
$attrs{"class"} // ""
l!l
00
MC/DC0%0/1
$attrs{"class"} // ""
$attrs{"class"}
Truth table0%0/2
A
A= $attrs{"class"}
Aresult
11
00
50 0 return qq{<div class="$class" role="group">$html</div>};
51 0 });
52  
53 # ── workflow_progress($wf) — state graph/tree ────────────────────
54  
55 0 ▶ $app->helper(workflow_progress => sub ($c, $wf, %attrs) {
Subroutine __ANON__: not called CC=18 SCAR=58.3
56 0 ▶ return '' unless $wf;
Branch: 1 branch
BranchTrueFalseTotal
unless $wf 0 0 0
57 0 my $current = $wf->state;
58  
59 0 my $config = $wf->_workflow_config;
60 0 ▶ my $states = $config->{state} // [];
Condition0%0/2
$config->{"state"} // []
l!l
00
MC/DC0%0/1
$config->{"state"} // []
$config->{"state"}
Truth table0%0/2
A
A= $config->{"state"}
Aresult
11
00
61 0 ▶ return '' unless @$states;
Branch: 1 branch
BranchTrueFalseTotal
unless @$states 0 0 0
62  
63 # Build adjacency map: state_name => [next_state_names...]
64 # and metadata map: state_name => { label, color, icon }
65 0 my (%next, %meta);
66 0 for my $s (@$states) {
67 0 my $name = $s->{name};
68 0 ▶ my $fd = $s->{fondation} // {};
Condition0%0/2
$s->{"fondation"} // {}
l!l
00
MC/DC0%0/1
$s->{"fondation"} // {}
$s->{"fondation"}
Truth table0%0/2
A
A= $s->{"fondation"}
Aresult
11
00
69 $meta{$name} = {
70 label => $c->l($fd->{label} // $name),
71 color => $fd->{color} // 'secondary',
72 icon => $fd->{icon},
73 0 ▶ };
Condition0%0/5
$fd->{"label"} // $name
l!l&&r!l&&!r
000
$fd->{"color"} // "secondary"
l!l
00
MC/DC0%0/2
$fd->{"label"} // $name
$fd->{"label"} $name
MC/DC0%0/1
$fd->{"color"} // "secondary"
$fd->{"color"}
Truth table0%0/3
A // B
A= $fd->{"label"}B= $name
ABresult
1X1
011
000
Truth table0%0/2
A
A= $fd->{"color"}
Aresult
11
00
74 0 ▶ my $actions = $s->{action} // [];
Condition0%0/2
$s->{"action"} // []
l!l
00
MC/DC0%0/1
$s->{"action"} // []
$s->{"action"}
Truth table0%0/2
A
A= $s->{"action"}
Aresult
11
00
75 0 $next{$name} = [ map { $_->{resulting_state} } @$actions ];
76 }
77  
78 # Reconstruct the effective path from history (eliminate backtracks).
79 # When the user goes block→unblock (back to in_progress) and then
80 # resolve→resolved, "blocked" is a dead-end branch — it should not
81 # appear as visited on the current path.
82 0 ▶ my @history = @{ $wf->history // [] };
Condition0%0/2
$wf->history // []
l!l
00
MC/DC0%0/1
$wf->history // []
$wf->history
Truth table0%0/2
A
A= $wf->history
Aresult
11
00
83 0 my @path; # ordered chain of states on the current path
84 my %path_set; # fast lookup
85 0 for my $h (@history) {
86 0 ▶ my $s = $h->{state} // '';
Condition0%0/2
$h->{"state"} // ""
l!l
00
MC/DC0%0/1
$h->{"state"} // ""
$h->{"state"}
Truth table0%0/2
A
A= $h->{"state"}
Aresult
11
00
87 0 ▶ next unless $s;
Branch: 1 branch
BranchTrueFalseTotal
unless $s 0 0 0
88 # Backtracking: if we reach a state already in the path,
89 # truncate everything after it.
90 0 ▶ if ($path_set{$s}) {
Branch: 1 branch
BranchTrueFalseTotal
if ($path_set{$s}) 0 0 0
91 0 ▶ while (@path && $path[-1] ne $s) {
Branch: 1 branch
BranchTrueFalseTotal
if (@path and $path[-1] ne $s) 0 0 0
Condition0%0/3
@path and $path[-1] ne $s
!ll&&!rl&&r
000
MC/DC0%0/2
@path and $path[-1] ne $s
@path $path[-1] ne $s
Truth table0%0/3
A and B
A= @pathB= $path[-1] ne $s
ABresult
0X0
100
111
92 0 delete $path_set{pop @path};
93 }
94 0 next;
95 }
96 0 push @path, $s;
97 0 $path_set{$s} = 1;
98 }
99 # Always mark current state as on-path
100 0 ▶ $path_set{$current} = 1 unless $path_set{$current};
Branch: 1 branch
BranchTrueFalseTotal
unless $path_set{$current} 0 0 0
101 0 my %visited = %path_set;
102  
103 # Recursive tree builder (tracks path to avoid cycles)
104 0 my $render;
105 0 ▶ $render = sub ($state_name, $prefix = '', $is_last = 0, $depth = 0, $seen = {}) {
Subroutine __ANON__: not called CC=20 SCAR=60.4
106 0 ▶ return '' unless exists $meta{$state_name};
Branch: 1 branch
BranchTrueFalseTotal
unless exists $meta{$state_name} 0 0 0
107 return qq{<div class="wf-node"><span class="wf-prefix text-muted small">$prefix</span>}
108 . qq{<span class="badge bg-light text-muted border">↩ $meta{$state_name}{label} (cycle)</span></div>\n}
109 0 ▶ if $seen->{$state_name};
Branch: 1 branch
BranchTrueFalseTotal
if $seen->{$state_name} 0 0 0
110  
111 0 my $m = $meta{$state_name};
112 0 my $label = $m->{label};
113 0 my $color = $m->{color};
114 0 ▶ my $icon = $m->{icon} ? qq{<i class="bi bi-$m->{icon} me-1"></i>} : '';
Branch: 1 branch
BranchTrueFalseTotal
$m->{'icon'} ? : 0 0 0
115  
116 0 my $is_current = $state_name eq $current;
117 0 ▶ my $is_visited = $visited{$state_name} && !$is_current;
Condition0%0/3
$visited{$state_name} && !$is_current
!ll&&!rl&&r
000
MC/DC0%0/2
$visited{$state_name} && !$is_current
$visited{$state_name} !$is_current
Truth table0%0/3
A && not(B)
A= $visited{$state_name}B= !$is_current
ABresult
0X0
100
111
118  
119 0 ▶ my $badge_class = $is_current ? "bg-$color"
Branch: 2 branches
BranchTrueFalseTotal
$is_current ? : 0 0 0
$is_visited ? : 0 0 0
120 : $is_visited ? 'bg-success'
121 : 'bg-light text-muted border';
122 0 ▶ my $marker = $is_current ? '●'
Branch: 2 branches
BranchTrueFalseTotal
$is_current ? : 0 0 0
$is_visited ? : 0 0 0
123 : $is_visited ? '✓'
124 : '○';
125  
126 0 ▶ my $connector = $depth > 0 ? ($is_last ? ' └─ ' : ' ├─ ') : '';
Branch: 2 branches
BranchTrueFalseTotal
$depth > 0 ? : 0 0 0
$is_last ? : 0 0 0
127 0 my $html = qq{<div class="wf-node">};
128 0 $html .= qq{<span class="wf-prefix text-muted small">$prefix$connector</span>};
129 0 $html .= qq{<span class="badge $badge_class">$icon$marker $label</span>};
130 0 $html .= qq{</div>\n};
131  
132 0 ▶ my @children = @{ $next{$state_name} // [] };
Condition0%0/2
$next{$state_name} // []
l!l
00
MC/DC0%0/1
$next{$state_name} // []
$next{$state_name}
Truth table0%0/2
A
A= $next{$state_name}
Aresult
11
00
133 0 ▶ return $html unless @children;
Branch: 1 branch
BranchTrueFalseTotal
unless @children 0 0 0
134  
135 0 ▶ my $child_prefix = $depth > 0
Branch: 2 branches
BranchTrueFalseTotal
$depth > 0 ? : 0 0 0
$is_last ? : 0 0 0
136 ? ($is_last ? ' ' : ' │ ')
137 : '';
138 0 my $full_prefix = $prefix . $child_prefix;
139  
140 0 my %child_seen = (%$seen, $state_name => 1);
141 0 for my $i (0 .. $#children) {
142 0 my $child = $children[$i];
143 0 my $child_last = $i == $#children;
144 0 $html .= $render->($child, $full_prefix, $child_last, $depth + 1, \%child_seen);
145 }
146 0 return $html;
147 0 };
148  
149 0 ▶ my $initial = $config->{initial_state} // $states->[0]{name};
Condition0%0/3
$config->{"initial_state"} // $states->[0]{"name"}
l!l&&r!l&&!r
000
MC/DC0%0/2
$config->{"initial_state"} // $states->[0]{"name"}
$config->{"initial_state"} $states->[0]{"name"}
Truth table0%0/3
A // B
A= $config->{"initial_state"}B= $states->[0]{"name"}
ABresult
1X1
011
000
150 0 return qq{<div class="workflow-progress font-monospace small">\n}
151 . $render->($initial)
152 . qq{</div>};
153 0 });
154  
155 # ── workflow_history($wf) — history timeline ──────────────────────
156  
157 0 ▶ $app->helper(workflow_history => sub ($c, $wf, %attrs) {
Subroutine __ANON__: not called CC=13 SCAR=52.0
158 0 ▶ return '' unless $wf && ref $wf;
Branch: 1 branch
BranchTrueFalseTotal
unless $wf and ref $wf 0 0 0
Condition0%0/3
$wf and ref $wf
!ll&&!rl&&r
000
MC/DC0%0/2
$wf and ref $wf
$wf ref $wf
Truth table0%0/3
A and B
A= $wfB= ref $wf
ABresult
0X0
100
111
159 0 my $entries = $wf->history;
160 0 ▶ return '' unless $entries && @$entries;
Branch: 1 branch
BranchTrueFalseTotal
unless $entries and @$entries 0 0 0
Condition0%0/3
$entries and @$entries
!ll&&!rl&&r
000
MC/DC0%0/2
$entries and @$entries
$entries @$entries
Truth table0%0/3
A and B
A= $entriesB= @$entries
ABresult
0X0
100
111
161  
162 0 my $html = qq{<div class="workflow-history">};
163 0 for my $e (@$entries) {
164 0 ▶ my $action = $e->{action} // '';
Condition0%0/2
$e->{"action"} // ""
l!l
00
MC/DC0%0/1
$e->{"action"} // ""
$e->{"action"}
Truth table0%0/2
A
A= $e->{"action"}
Aresult
11
00
165 0 ▶ my $state = $e->{state} // '';
Condition0%0/2
$e->{"state"} // ""
l!l
00
MC/DC0%0/1
$e->{"state"} // ""
$e->{"state"}
Truth table0%0/2
A
A= $e->{"state"}
Aresult
11
00
166 0 ▶ my $user = $e->{user} // '';
Condition0%0/2
$e->{"user"} // ""
l!l
00
MC/DC0%0/1
$e->{"user"} // ""
$e->{"user"}
Truth table0%0/2
A
A= $e->{"user"}
Aresult
11
00
167 0 ▶ my $date = $e->{date} // '';
Condition0%0/2
$e->{"date"} // ""
l!l
00
MC/DC0%0/1
$e->{"date"} // ""
$e->{"date"}
Truth table0%0/2
A
A= $e->{"date"}
Aresult
11
00
168 0 ▶ my $desc = $e->{description} // '';
Condition0%0/2
$e->{"description"} // ""
l!l
00
MC/DC0%0/1
$e->{"description"} // ""
$e->{"description"}
Truth table0%0/2
A
A= $e->{"description"}
Aresult
11
00
169 0 $html .= qq{<div class="d-flex align-items-start mb-2">};
170 0 $html .= qq{<div class="me-2 text-primary">●</div>};
171 0 $html .= qq{<div>};
172 0 $html .= qq{<strong>$action</strong>};
173 0 ▶ $html .= qq{ <span class="text-muted small">$date</span>} if $date;
Branch: 1 branch
BranchTrueFalseTotal
if $date 0 0 0
174 0 ▶ $html .= qq{<br><small class="text-muted">$desc</small>} if $desc;
Branch: 1 branch
BranchTrueFalseTotal
if $desc 0 0 0
175 0 $html .= qq{</div></div>};
176 }
177 0 $html .= '</div>';
178 0 return $html;
179 0 });
180  
181 # ── workflow_graph($wf) — Mermaid.js state diagram ────────────────
182  
183 0 ▶ $app->helper(workflow_graph => sub ($c, $wf, %attrs) {
Subroutine __ANON__: not called CC=30 SCAR=68.4
184 0 ▶ return '' unless $wf && ref $wf;
Branch: 1 branch
BranchTrueFalseTotal
unless $wf and ref $wf 0 0 0
Condition0%0/3
$wf and ref $wf
!ll&&!rl&&r
000
MC/DC0%0/2
$wf and ref $wf
$wf ref $wf
Truth table0%0/3
A and B
A= $wfB= ref $wf
ABresult
0X0
100
111
185  
186 0 my $config = $wf->_workflow_config;
187 0 ▶ my $states = $config->{state} // [];
Condition0%0/2
$config->{"state"} // []
l!l
00
MC/DC0%0/1
$config->{"state"} // []
$config->{"state"}
Truth table0%0/2
A
A= $config->{"state"}
Aresult
11
00
188 0 ▶ return '' unless @$states;
Branch: 1 branch
BranchTrueFalseTotal
unless @$states 0 0 0
189  
190 0 my $current = $wf->state;
191  
192 # Build adjacency + metadata
193 0 my (%next, %meta);
194 0 for my $s (@$states) {
195 0 my $name = $s->{name};
196 0 ▶ my $fd = $s->{fondation} // {};
Condition0%0/2
$s->{"fondation"} // {}
l!l
00
MC/DC0%0/1
$s->{"fondation"} // {}
$s->{"fondation"}
Truth table0%0/2
A
A= $s->{"fondation"}
Aresult
11
00
197 $meta{$name} = {
198 name => $name,
199 label => $c->l($fd->{label} // $name),
200 0 ▶ color => $fd->{color} // 'secondary',
Condition0%0/5
$fd->{"label"} // $name
l!l&&r!l&&!r
000
$fd->{"color"} // "secondary"
l!l
00
MC/DC0%0/2
$fd->{"label"} // $name
$fd->{"label"} $name
MC/DC0%0/1
$fd->{"color"} // "secondary"
$fd->{"color"}
Truth table0%0/3
A // B
A= $fd->{"label"}B= $name
ABresult
1X1
011
000
Truth table0%0/2
A
A= $fd->{"color"}
Aresult
11
00
201 };
202 0 ▶ my $actions = $s->{action} // [];
Condition0%0/2
$s->{"action"} // []
l!l
00
MC/DC0%0/1
$s->{"action"} // []
$s->{"action"}
Truth table0%0/2
A
A= $s->{"action"}
Aresult
11
00
203 0 $next{$name} = $actions;
204 }
205  
206 # Determine path set (same backtracking logic as progress)
207 0 ▶ my @history = @{ $wf->history // [] };
Condition0%0/2
$wf->history // []
l!l
00
MC/DC0%0/1
$wf->history // []
$wf->history
Truth table0%0/2
A
A= $wf->history
Aresult
11
00
208 0 my (@path, %path_set);
209 0 for my $h (@history) {
210 0 ▶ my $s = $h->{state} // '';
Condition0%0/2
$h->{"state"} // ""
l!l
00
MC/DC0%0/1
$h->{"state"} // ""
$h->{"state"}
Truth table0%0/2
A
A= $h->{"state"}
Aresult
11
00
211 0 ▶ next unless $s;
Branch: 1 branch
BranchTrueFalseTotal
unless $s 0 0 0
212 0 ▶ if ($path_set{$s}) {
Branch: 1 branch
BranchTrueFalseTotal
if ($path_set{$s}) 0 0 0
213 0 ▶ while (@path && $path[-1] ne $s) { delete $path_set{pop @path} }
Branch: 1 branch
BranchTrueFalseTotal
if (@path and $path[-1] ne $s) 0 0 0
Condition0%0/3
@path and $path[-1] ne $s
!ll&&!rl&&r
000
MC/DC0%0/2
@path and $path[-1] ne $s
@path $path[-1] ne $s
Truth table0%0/3
A and B
A= @pathB= $path[-1] ne $s
ABresult
0X0
100
111
214 0 next;
215 }
216 0 push @path, $s; $path_set{$s} = 1;
217 }
218 0 ▶ $path_set{$current} = 1 unless $path_set{$current};
Branch: 1 branch
BranchTrueFalseTotal
unless $path_set{$current} 0 0 0
219  
220 # Short safe IDs for Mermaid
221 0 ▶ my $sid = sub ($name) { 'S_' . ($name =~ s/[^a-zA-Z0-9]/_/gr) };
Subroutine __ANON__: not called CC=1 SCAR=6.9
222 0 my @visited_nodes;
223 my @future_nodes;
224 0 my $current_node = '';
225  
226 # Classify nodes
227 0 for my $s_name (sort keys %meta) {
228 0 my $id = $sid->($s_name);
229 0 ▶ if ($s_name eq $current) {
Branch: 2 branches
BranchTrueFalseTotal
if ($s_name eq $current) { } 0 0 0
elsif ($path_set{$s_name}) { } 0 0 0
230 0 $current_node = $id;
231 } elsif ($path_set{$s_name}) {
232 0 push @visited_nodes, $id;
233 } else {
234 0 push @future_nodes, $id;
235 }
236 }
237  
238 # Generate edges with action labels
239 0 my @lines;
240 0 my @sorted = sort { $a->{name} cmp $b->{name} } values %meta;
241 0 for my $s (@sorted) {
242 0 my $s_name = $s->{name};
243 0 my $from_id = $sid->($s_name);
244 0 ▶ for my $action (@{ $next{$s_name} // [] }) {
Condition0%0/2
$next{$s_name} // []
l!l
00
MC/DC0%0/1
$next{$s_name} // []
$next{$s_name}
Truth table0%0/2
A
A= $next{$s_name}
Aresult
11
00
245 0 my $to_name = $action->{resulting_state};
246 0 my $to_id = $sid->($to_name);
247 0 ▶ my $label = $action->{name} // '';
Condition0%0/2
$action->{"name"} // ""
l!l
00
MC/DC0%0/1
$action->{"name"} // ""
$action->{"name"}
Truth table0%0/2
A
A= $action->{"name"}
Aresult
11
00
248 0 ▶ my $fd = $action->{fondation} // {};
Condition0%0/2
$action->{"fondation"} // {}
l!l
00
MC/DC0%0/1
$action->{"fondation"} // {}
$action->{"fondation"}
Truth table0%0/2
A
A= $action->{"fondation"}
Aresult
11
00
249 0 ▶ $label = $fd->{label} if $fd->{label};
Branch: 1 branch
BranchTrueFalseTotal
if $fd->{"label"} 0 0 0
250 0 my $from_label = $meta{$s_name}{label};
251 0 my $to_label = $meta{$to_name}{label};
252 0 push @lines, qq{ ${from_id}["$from_label"] -->|"$label"| ${to_id}["$to_label"]};
253 }
254 }
255  
256 0 my $mermaid = "flowchart TD\n"
257 . join("\n", @lines) . "\n"
258 . "\n"
259 . " classDef visited fill:#198754,color:#fff,stroke:#198754\n"
260 . " classDef current fill:#0d6efd,color:#fff,stroke:#0d6efd,stroke-width:3px\n"
261 . " classDef future fill:#e9ecef,color:#6c757d,stroke:#dee2e6\n";
262  
263 0 ▶ $mermaid .= " class $current_node current\n" if $current_node;
Branch: 1 branch
BranchTrueFalseTotal
if $current_node 0 0 0
264 0 ▶ $mermaid .= " class " . join(',', @visited_nodes) . " visited\n" if @visited_nodes;
Branch: 1 branch
BranchTrueFalseTotal
if @visited_nodes 0 0 0
265 0 ▶ $mermaid .= " class " . join(',', @future_nodes) . " future\n" if @future_nodes;
Branch: 1 branch
BranchTrueFalseTotal
if @future_nodes 0 0 0
266  
267 0 return $mermaid;
268 0 });
269  
270 0 return $self;
271 }
272  
273 1 1;
274  
275 __END__
↑ Summary