fix(WP-0017/E3): Layer 3 error fixes — controllers and views

Fix compilation errors across 6 controllers and 29 views: import cleanup,
ResponseException pattern for API auth, type fixes, unused import removal.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-04-11 23:40:31 +00:00
parent 58cad31042
commit c40f11d657
35 changed files with 96 additions and 116 deletions

View File

@@ -85,10 +85,10 @@ instance View ExtensionGuideView where
</p>
<div class="bg-gray-900 rounded-lg p-4 text-sm font-mono text-green-400">
POST /api/v2/widgets<br/>
<span class="text-gray-400">{"{"} "name": "PR Review Widget",<br/>
<span class="text-gray-400">&#123; "name": "PR Review Widget",<br/>
&nbsp;&nbsp;"widgetType": "dev.code-review",<br/>
&nbsp;&nbsp;"hubId": "...",<br/>
&nbsp;&nbsp;"viewContext": "pull-request-sidebar" {"}"}</span>
&nbsp;&nbsp;"viewContext": "pull-request-sidebar" &#125;</span>
</div>
</section>

View File

@@ -115,9 +115,9 @@ instance View LandingView where
</div>
|]
where
chainLink label color = [hsx|
chainLink (label :: Text) (color :: Text) = [hsx|
<span class={"inline-block px-2 py-1 rounded text-xs bg-" <> color <> "-100 text-" <> color <> "-800 font-mono"}>
{label :: Text}
{label}
</span>
|]
arrow = [hsx|<span class="text-gray-400"></span>|]

View File

@@ -25,7 +25,7 @@ instance View TutorialView where
</p>
<div class="bg-gray-900 rounded-lg p-4 text-sm font-mono text-green-400">
<div class="text-gray-400 mb-1">-- Every rendered widget wraps its HSX in widgetEnvelope</div>
widgetEnvelope widgetId viewContext [hsx|...|]
{"widgetEnvelope widgetId viewContext [hsx|...|]" :: Text}
</div>
<p class="text-sm text-gray-500 mt-2">
The envelope injects <code>data-widget-id</code> and <code>data-view-context</code> attributes,