Welcome, <%= @user.email_address %>

<% if @user.admin? %> Administrator <% else %> User <% end %>

Active Sessions
<%= @user.sessions.active.count %>
<%= link_to "View all sessions", profile_path, class: "text-sm font-medium text-blue-600 hover:text-blue-500" %>
<% if @user.totp_enabled? %>
Two-Factor Authentication
Enabled
<%= link_to "Manage 2FA", profile_path, class: "text-sm font-medium text-blue-600 hover:text-blue-500" %>
<% else %>
Two-Factor Authentication
Not Enabled
<%= link_to "Enable 2FA", profile_path, class: "text-sm font-medium text-blue-600 hover:text-blue-500" %>
<% end %>

Your Applications

<% if @applications.any? %>
<% @applications.each do |app| %>

<%= app.name %>

<%= app.app_type.humanize %>

<% if app.oidc? %> OIDC Application <% else %> ForwardAuth Protected Application <% end %>

<% if app.landing_url.present? %> <%= link_to "Open Application", app.landing_url, target: "_blank", rel: "noopener noreferrer", class: "w-full flex justify-center items-center px-4 py-2 border border-transparent text-sm font-medium rounded-md text-white bg-blue-600 hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500 transition" %> <% else %>
No landing URL configured
<% end %>
<% end %>
<% else %>

No applications available

You don't have access to any applications yet. Contact your administrator if you think this is an error.

<% end %>
<% if @user.admin? %>

Admin Quick Actions

<%= link_to admin_users_path, class: "block p-6 bg-white rounded-lg border border-gray-200 shadow-sm hover:bg-gray-50 hover:shadow-md transition" do %>

Manage Users

View, edit, and invite users

<% end %> <%= link_to admin_applications_path, class: "block p-6 bg-white rounded-lg border border-gray-200 shadow-sm hover:bg-gray-50 hover:shadow-md transition" do %>

Manage Applications

Register and configure applications

<% end %> <%= link_to admin_groups_path, class: "block p-6 bg-white rounded-lg border border-gray-200 shadow-sm hover:bg-gray-50 hover:shadow-md transition" do %>

Manage Groups

Create and organize user groups

<% end %>
<% end %>