Skip to content

Commit

Permalink
refactor: Simplify JSON preview styling in workflow execution attachm…
Browse files Browse the repository at this point in the history
…ents
  • Loading branch information
joshsadam committed Feb 28, 2025
1 parent 3d6881f commit 71f84da
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions app/views/workflow_executions/attachments/_json_preview.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,12 @@
<%= contents %>
</div>
<div
class="
p-0 pt-6 pb-6 m-0 overflow-x-auto rounded-lg bg-slate-50 dark:bg-slate-900
dark:text-slate-300
"
class="p-0 pt-6 pb-6 m-0 overflow-x-auto text-sm rounded-lg bg-slate-50 dark:bg-slate-900 dark:text-slate-300"
>
<% JSON.pretty_generate(JSON.parse(contents)).lines.each_with_index do |line, index| %>
<pre class="flex dark:text-slate-400">
<span
class="
w-12 pr-2 text-right border-r select-none min-w-12 text-slate-400
dark:text-slate-600 border-slate-200 dark:border-slate-700
"
class="w-12 pr-2 text-right border-r select-none min-w-12 text-slate-400 dark:text-slate-600 border-slate-200 dark:border-slate-700"
><%= index + 1 %></span>
<span class="pl-4 text-wrap"><%= line %></span>
</pre>
Expand Down

0 comments on commit 71f84da

Please sign in to comment.