Skip to content
Original file line number Diff line number Diff line change
Expand Up @@ -143,8 +143,49 @@
.rd-scope .p2-drift b{color:var(--rd-text-1);font-weight:600;}
</style>

@if (! $hasLM)
<div class="p2-wrap"><div class="rd-empty">{{ __('stakeholder.lm.no_canvas') }}</div></div>
@php
// Empty-state trigger is keyed on ITEM COUNT, not just board existence.
// A blank Logic Model board (0 items) makes $hasLM true but leaves the
// read-out hollow; the reverse flow itself creates a board on start, so
// gating only on board-existence would strand users in an empty skeleton.
// Treat "no board" and "board with no items" identically — both land on
// the populate-from-your-work empty-state below.
$lmStages = $hasLM ? ($logicModel['coverageMatrix']['stages'] ?? []) : [];
$lmHasContent = false;
foreach ($lmStages as $lmStage) {
if (count($lmStage['items'] ?? []) > 0) {
$lmHasContent = true;
break;
}
}
@endphp

@if (! $lmHasContent)
<style>
.rd-scope .p2-lm-empty{max-width:560px;margin:24px auto;text-align:center;padding:38px 28px;background:var(--rd-panel);border:1px solid var(--rd-line);border-radius:var(--rd-r-sm);box-shadow:var(--rd-sh-sm);}
.rd-scope .p2-lm-empty .ic{width:54px;height:54px;border-radius:15px;background:linear-gradient(135deg,var(--rd-s3,#3F72B0),var(--rd-s4,#3E937A));display:inline-flex;align-items:center;justify-content:center;margin-bottom:16px;}
.rd-scope .p2-lm-empty .ic i{color:#fff;font-size:23px;}
.rd-scope .p2-lm-empty .t{font-size:18px;font-weight:600;color:var(--rd-text-1);margin-bottom:9px;}
.rd-scope .p2-lm-empty .b{font-size:13.5px;line-height:1.6;color:var(--rd-text-3);margin:0 auto 22px;max-width:440px;}
.rd-scope .p2-lm-empty .cta{display:inline-flex;align-items:center;gap:9px;font-size:14px;font-weight:600;color:#fff;background:var(--rd-accent);border-radius:24px;padding:11px 22px;text-decoration:none;box-shadow:var(--rd-sh-sm);transition:filter .15s;}
.rd-scope .p2-lm-empty .cta:hover{filter:brightness(1.09);text-decoration:none;color:#fff;}
.rd-scope .p2-lm-empty .cta:focus-visible{outline:2px solid var(--rd-accent);outline-offset:3px;}
.rd-scope .p2-lm-empty .cta i{font-size:13px;}
.rd-scope .p2-lm-empty .hint{font-size:12px;color:var(--rd-text-4);margin-top:14px;line-height:1.5;max-width:400px;margin-left:auto;margin-right:auto;}
</style>
<div class="p2-wrap">
<div class="p2-lm-empty">
<span class="ic"><i class="fa fa-diagram-project"></i></span>
<div class="t">{{ __('stakeholder.lm.empty_title') }}</div>
<div class="b">{{ __('stakeholder.lm.empty_body') }}</div>
@if (($scope ?? '') === 'strategy')
<a href="{{ BASE_URL }}/logicmodelcanvas/showCanvas" class="cta">
<i class="fa fa-wand-magic-sparkles"></i> {{ __('stakeholder.lm.empty_cta') }}
Comment thread
Copilot marked this conversation as resolved.
Outdated
</a>
<div class="hint">{{ __('stakeholder.lm.empty_hint') }}</div>
@endif
</div>
</div>
@else
@php
$stages = $logicModel['coverageMatrix']['stages'] ?? [];
Expand Down
4 changes: 4 additions & 0 deletions app/Language/en-US.ini
Original file line number Diff line number Diff line change
Expand Up @@ -3002,6 +3002,10 @@ stakeholder.kpi.this_period = "this period"
stakeholder.overview.coming_title = "Peak this period · Needs attention · ToC narrative · Theory-health strip"
stakeholder.overview.coming_hint = "The recommend-and-override hero, execution-lens needs-attention block, Theory-of-Change sentence, and theory-health strip land next."
stakeholder.lm.no_canvas = "No Logic Model canvas authored yet. Build one on the Board to see it read out here."
stakeholder.lm.empty_title = "Build your Logic Model"
stakeholder.lm.empty_body = "A Logic Model connects your programs, goals, and milestones into one story — what you do, what changes, and why it matters. It powers this page and the coverage read-out."
stakeholder.lm.empty_cta = "Build a Logic Model"
stakeholder.lm.empty_hint = "We'll scan the work already in this strategy and suggest what maps to each stage — you pick what fits."
Comment thread
Copilot marked this conversation as resolved.
Outdated
stakeholder.lm.coming_title = "5-stage read-out with task-card standard + connection-health badges"
stakeholder.lm.coming_hint = "Cards per stage with assumption/hypothesis, linked projects, and a fold-out \"this period\" read-out. Connection badges between stages from zp_logicmodel_health."
stakeholder.rc.coming_title = "Resource summary + resource-backed coverage matrix"
Expand Down
Loading