diff --git a/app/assets/stylesheets/access-tokens.css b/app/assets/stylesheets/access-tokens.css index a0f54f91c..1fcecb52e 100644 --- a/app/assets/stylesheets/access-tokens.css +++ b/app/assets/stylesheets/access-tokens.css @@ -1,19 +1,33 @@ -.access_tokens_table { +.access-tokens { border-collapse: collapse; + font-size: var(--text-small); inline-size: 100%; + margin-block-end: 2lh; td, th { - border-block-end: 1px solid var(--color-ink-light); - padding-inline: var(--inline-space); + border-block-end: 1px solid var(--color-ink-lighter); text-align: start; + + &:first-child { + inline-size: 100%; + } + + &:not(:first-child) { + padding-inline-start: var(--inline-space); + } + + &:not(:last-child) { + padding-inline-end: var(--inline-space); + } } th { + color: var(--color-ink-dark); font-size: var(--text-x-small); text-transform: uppercase; } - tr:nth-of-type(even) { - background-color: var(--color-ink-lightest); + td { + padding-block: 8px; } -} \ No newline at end of file +} diff --git a/app/views/users/credentials/_credential.html.erb b/app/views/users/credentials/_credential.html.erb index 27c2d199f..f532552c3 100644 --- a/app/views/users/credentials/_credential.html.erb +++ b/app/views/users/credentials/_credential.html.erb @@ -1,9 +1,9 @@ <%= credential.name.presence || "Passkey" %> - <%= local_datetime_tag credential.created_at, style: :datetime %> + <%= local_datetime_tag credential.created_at, style: :datetime %> <%= button_to user_credential_path(@user, credential), method: :delete, - class: "btn txt-negative btn--circle txt-x-small borderless fill-transparent", + class: "btn btn--circle txt-negative txt-xx-small borderless", data: { turbo_confirm: "Are you sure you want to remove this passkey?" } do %> <%= icon_tag "trash" %> Remove this passkey diff --git a/app/views/users/credentials/index.html.erb b/app/views/users/credentials/index.html.erb index a5521f617..28febe77f 100644 --- a/app/views/users/credentials/index.html.erb +++ b/app/views/users/credentials/index.html.erb @@ -8,10 +8,11 @@

<%= @page_title %>

<% end %> -
+
+

Passkeys let you sign in using your device’s biometrics, PIN, or security key—no email code needed.

+ <% if @credentials.any? %> -

Passkeys let you sign in without email codes. They use your device's biometrics, PIN, or security key.

- +
@@ -23,8 +24,6 @@ <%= render partial: "users/credentials/credential", collection: @credentials %>
Passkey
- <% else %> -

Passkeys let you sign in without email codes. They use your device's biometrics, PIN, or security key.

<% end %> <%= link_to new_user_credential_path(@user), class: "btn btn--link" do %> diff --git a/app/views/users/credentials/new.html.erb b/app/views/users/credentials/new.html.erb index 3e5e7abc0..722a6f612 100644 --- a/app/views/users/credentials/new.html.erb +++ b/app/views/users/credentials/new.html.erb @@ -8,11 +8,10 @@

<%= @page_title %>

<% end %> -
+
<%= form_with url: user_credentials_path(@user), data: { controller: "credential", credential_public_key_value: @creation_options.as_json }, html: { class: "flex flex-column gap" } do |form| %> -

A passkey lets you sign in using your device's biometrics, PIN, or security key — no email code needed.

@@ -29,4 +28,4 @@ <% end %> <%= link_to "Cancel and go back", user_credentials_path(@user), hidden: true %> -
+