fix(ds): replace invalid bg-surface-default with bg-surface (#2244)

`bg-surface-default` is not a defined design-system token — Tailwind emits
no rule for it, so these surfaces render with no background at all. Five
call sites were affected:

- rules/index.html.erb — recent-runs table header
- settings/llm_usages/show.html.erb — usage table header
- settings/ai_prompts/show.html.erb — three prompt-preview boxes

Replace with the canonical `bg-surface` token — the same fill the
admin/users and settings/debugs table headers already use. Clears a
Rule 2 (non-functional token) finding from the weekly DS drift scan.
This commit is contained in:
Guillem Arias Fauste
2026-06-11 15:20:01 +02:00
committed by GitHub
parent 034a12f1d8
commit 4dbfbf0bc8
3 changed files with 5 additions and 5 deletions

View File

@@ -109,7 +109,7 @@
<div class="overflow-x-auto">
<table class="w-full">
<thead class="bg-surface-default border-b border-primary">
<thead class="bg-surface border-b border-primary">
<tr>
<th class="px-4 py-3 text-left text-xs font-medium text-secondary uppercase tracking-wider">
<%= t("rules.recent_runs.columns.date_time") %>

View File

@@ -40,7 +40,7 @@
<%= icon "chevron-right", class: "group-open:transform group-open:rotate-90" %>
</summary>
<pre class="whitespace-pre-wrap text-xs font-mono text-primary">[<%= Provider::Openai::DEFAULT_MODEL %>]</pre>
<div class="mt-2 px-3 py-2 bg-surface-default border border-primary rounded-lg">
<div class="mt-2 px-3 py-2 bg-surface border border-primary rounded-lg">
<pre class="whitespace-pre-wrap text-xs font-mono text-primary"><%= @assistant_config[:instructions] %></pre>
</div>
</details>
@@ -68,7 +68,7 @@
<%= icon "chevron-right", class: "group-open:transform group-open:rotate-90" %>
</summary>
<pre class="whitespace-pre-wrap text-xs font-mono text-primary">[<%= Provider::Openai::DEFAULT_MODEL %>]</pre>
<div class="mt-2 px-3 py-2 bg-surface-default border border-primary rounded-lg">
<div class="mt-2 px-3 py-2 bg-surface border border-primary rounded-lg">
<pre class="whitespace-pre-wrap text-xs font-mono text-primary"><%= @assistant_config[:auto_categorizer]&.instructions || Provider::Openai::AutoCategorizer.new(nil).instructions %></pre>
</div>
</details>
@@ -96,7 +96,7 @@
<%= icon "chevron-right", class: "group-open:transform group-open:rotate-90" %>
</summary>
<pre class="whitespace-pre-wrap text-xs font-mono text-primary">[<%= Provider::Openai::DEFAULT_MODEL %>]</pre>
<div class="mt-2 px-3 py-2 bg-surface-default border border-primary rounded-lg">
<div class="mt-2 px-3 py-2 bg-surface border border-primary rounded-lg">
<pre class="whitespace-pre-wrap text-xs font-mono text-primary"><%= @assistant_config[:auto_merchant]&.instructions || Provider::Openai::AutoMerchantDetector.new(nil, model: "", transactions: [], user_merchants: []).instructions %></pre>
</div>
</details>

View File

@@ -106,7 +106,7 @@
<div class="table-scroll rounded-lg" tabindex="0" role="region" aria-label="<%= t(".recent_usage") %>">
<% if @llm_usages.any? %>
<table class="w-full">
<thead class="bg-surface-default border-b border-primary">
<thead class="bg-surface border-b border-primary">
<tr>
<th class="px-4 py-3 text-left text-xs font-medium text-secondary uppercase"><%= t(".col_date") %></th>
<th class="px-4 py-3 text-left text-xs font-medium text-secondary uppercase"><%= t(".col_operation") %></th>