闭社主体 forked from https://github.com/tootsuite/mastodon
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

31 lines
1.2 KiB

  1. %h3= t 'sessions.title'
  2. %p.muted-hint= t 'sessions.explanation'
  3. %hr.spacer/
  4. .table-wrapper
  5. %table.table.inline-table
  6. %thead
  7. %tr
  8. %th= t 'sessions.browser'
  9. %th= t 'sessions.ip'
  10. %th= t 'sessions.activity'
  11. %th
  12. %tbody
  13. - @sessions.each do |session|
  14. %tr
  15. %td
  16. %span{ title: session.user_agent }<
  17. = fa_icon "#{session_device_icon(session)} fw", 'aria-label' => session_device_icon(session)
  18. = ' '
  19. = t 'sessions.description', browser: t("sessions.browsers.#{session.browser}", default: "#{session.browser}"), platform: t("sessions.platforms.#{session.platform}", default: "#{session.platform}")
  20. %td
  21. %samp= session.ip
  22. %td
  23. - if current_session.session_id == session.session_id
  24. = t 'sessions.current_session'
  25. - else
  26. %time.time-ago{ datetime: session.updated_at.iso8601, title: l(session.updated_at) }= l(session.updated_at)
  27. %td
  28. - if current_session.session_id != session.session_id
  29. = table_link_to 'times', t('sessions.revoke'), settings_session_path(session), method: :delete