Design show view
This commit is contained in:
committed by
Stanko K.R.
parent
983a19fd8a
commit
fa2eb06992
@@ -2,14 +2,25 @@
|
||||
|
||||
<% content_for :header do %>
|
||||
<div class="header__actions header__actions--start">
|
||||
<%= back_link_to "tokens", my_access_tokens_path, "keydown.left@document->hotkey#click keydown.esc@document->hotkey#click" %>
|
||||
<%= back_link_to "Tokens", my_access_tokens_path, "keydown.left@document->hotkey#click keydown.esc@document->hotkey#click" %>
|
||||
</div>
|
||||
|
||||
<h1 class="header__title"><%= @page_title %></h1>
|
||||
<% end %>
|
||||
|
||||
<article class="panel panel--wide shadow center txt-align-start" style="view-transition-name: <%= dom_id(@access_token) %>">
|
||||
<h1><%= @access_token.token %></h1>
|
||||
<div class="flex flex-column gap">
|
||||
<label class="flex flex-column gap-half txt-align-start">
|
||||
<strong><%= @access_token.description %> (<%= @access_token.permission == "write" ? "Read + Write" : "Read" %>)</strong>
|
||||
<input type="text" value="<%= @access_token.token %>" class="input" readonly>
|
||||
</label>
|
||||
<p class="margin-none txt-small">Be sure to save this access token now because you won’t be able to see it again.</p>
|
||||
|
||||
<%= link_to "Cancel and go back", my_access_tokens_path, data: { form_target: "cancel" }, hidden: true %>
|
||||
<%= tag.button class: "btn btn--link center", data: {
|
||||
controller: "copy-to-clipboard", action: "copy-to-clipboard#copy",
|
||||
copy_to_clipboard_success_class: "btn--success", copy_to_clipboard_content_value: @access_token.token } do %>
|
||||
<%= icon_tag "copy-paste" %>
|
||||
<span>Copy access token</span>
|
||||
<% end %>
|
||||
</div>
|
||||
</article>
|
||||
|
||||
Reference in New Issue
Block a user