Files
sure/app/views/doorkeeper/applications/show.html.erb
Guillem Arias Fauste c429f20a77 chore(design-system): replace dead Bootstrap classes with Sure tokens (#1621)
Sure uses Tailwind v4 with the design system tokens but several views
still carried Bootstrap-style class names that don't render anything
because no Bootstrap stylesheet is loaded. They're effectively dead
markup.

Replacements:
- text-muted, text-muted-foreground -> text-subdued
- bg-light -> bg-surface
- font-italic -> italic
- text-uppercase -> uppercase
- font-weight-bold -> font-bold

Touched files:
- app/views/doorkeeper/applications/_form.html.erb
- app/views/doorkeeper/applications/show.html.erb
- app/views/pages/privacy.html.erb
- app/views/pages/terms.html.erb
- app/views/pages/redis_configuration_error.html.erb
- app/views/settings/providers/_mercury_panel.html.erb

Also tightening application.css:
- The .hw-combobox__label rule used raw text-gray-500 / text-gray-400
  via @apply. Now uses the text-secondary / text-subdued tokens so the
  combobox label responds to the theme.
- Custom scrollbar thumbs in .windows and .scrollbar used hardcoded
  #d6d6d6 / #a6a6a6 hex values. Now reference var(--color-gray-300) /
  var(--color-gray-400). Slight color shift (the hex values were close
  to but not identical to those tokens), so this needs a quick visual
  check.

And reports/print.html.erb had four <span style="color: #666"> elements
on the metric cards. Replaced with class="text-secondary" merged into
the existing tufte-metric-card-change class, so print uses the same
secondary-text color the rest of the app uses.
2026-05-01 22:10:46 +02:00

64 lines
2.2 KiB
Plaintext

<div class="border-bottom mb-4">
<h1><%= t(".title", name: @application.name) %></h1>
</div>
<div class="row">
<div class="col-md-8">
<h4><%= t(".application_id") %>:</h4>
<p><code class="bg-surface" id="application_id"><%= @application.uid %></code></p>
<h4><%= t(".secret") %>:</h4>
<p>
<code class="bg-surface" id="secret">
<% secret = flash[:application_secret].presence || @application.plaintext_secret %>
<% if secret.blank? && Doorkeeper.config.application_secret_hashed? %>
<span class="bg-surface italic uppercase text-subdued"><%= t(".secret_hashed") %></span>
<% else %>
<%= secret %>
<% end %>
</code>
</p>
<h4><%= t(".scopes") %>:</h4>
<p>
<code class="bg-surface" id="scopes">
<% if @application.scopes.present? %>
<%= @application.scopes %>
<% else %>
<span class="bg-surface italic uppercase text-subdued"><%= t(".not_defined") %></span>
<% end %>
</code>
</p>
<h4><%= t(".confidential") %>:</h4>
<p><code class="bg-surface" id="confidential"><%= @application.confidential? %></code></p>
<h4><%= t(".callback_urls") %>:</h4>
<% if @application.redirect_uri.present? %>
<table>
<% @application.redirect_uri.split.each do |uri| %>
<tr>
<td>
<code class="bg-surface"><%= uri %></code>
</td>
<td>
<%= link_to t("doorkeeper.applications.buttons.authorize"), oauth_authorization_path(client_id: @application.uid, redirect_uri: uri, response_type: "code", scope: @application.scopes), class: "btn btn-success", target: "_blank" %>
</td>
</tr>
<% end %>
</table>
<% else %>
<span class="bg-surface italic uppercase text-subdued"><%= t(".not_defined") %></span>
<% end %>
</div>
<div class="col-md-4">
<h3><%= t(".actions") %></h3>
<p><%= link_to t("doorkeeper.applications.buttons.edit"), edit_oauth_application_path(@application), class: "btn btn-primary" %></p>
<p><%= render "delete_form", application: @application, submit_btn_css: "btn btn-danger" %></p>
</div>
</div>