2017-02-26 23:15:00 +00:00
|
|
|
- content_for :page_title do
|
|
|
|
= t('doorkeeper.authorized_applications.index.title')
|
|
|
|
|
2022-03-01 15:48:58 +00:00
|
|
|
%p= t('doorkeeper.authorized_applications.index.description_html')
|
|
|
|
|
|
|
|
%hr.spacer/
|
|
|
|
|
2022-03-02 19:28:25 +00:00
|
|
|
.applications-list
|
2022-03-01 15:48:58 +00:00
|
|
|
- @applications.each do |application|
|
2022-03-02 19:28:25 +00:00
|
|
|
.applications-list__item
|
2022-03-01 15:48:58 +00:00
|
|
|
- if application.website.present?
|
|
|
|
= link_to application.name, application.website, target: '_blank', rel: 'noopener noreferrer', class: 'announcements-list__item__title'
|
|
|
|
- else
|
|
|
|
%strong.announcements-list__item__title
|
|
|
|
= application.name
|
|
|
|
- if application.superapp?
|
2023-07-27 14:05:24 +00:00
|
|
|
%span.information-badge.superapp= t('doorkeeper.authorized_applications.index.superapp')
|
2022-03-01 15:48:58 +00:00
|
|
|
|
|
|
|
.announcements-list__item__action-bar
|
|
|
|
.announcements-list__item__meta
|
2023-05-22 12:03:38 +00:00
|
|
|
- if @last_used_at_by_app[application.id]
|
|
|
|
= t('doorkeeper.authorized_applications.index.last_used_at', date: l(@last_used_at_by_app[application.id].to_date))
|
2022-03-01 15:48:58 +00:00
|
|
|
- else
|
|
|
|
= t('doorkeeper.authorized_applications.index.never_used')
|
|
|
|
|
2023-06-02 17:58:18 +00:00
|
|
|
·
|
2022-03-01 15:48:58 +00:00
|
|
|
|
|
|
|
= t('doorkeeper.authorized_applications.index.authorized_at', date: l(application.created_at.to_date))
|
|
|
|
|
2023-11-30 15:43:26 +00:00
|
|
|
- unless application.superapp? || current_account.unavailable?
|
2022-03-01 15:48:58 +00:00
|
|
|
%div
|
2024-08-20 11:48:15 +00:00
|
|
|
= table_link_to 'close', t('doorkeeper.authorized_applications.buttons.revoke'), oauth_authorized_application_path(application), method: :delete, data: { confirm: t('doorkeeper.authorized_applications.confirmations.revoke') }
|
2022-03-01 15:48:58 +00:00
|
|
|
|
|
|
|
.announcements-list__item__permissions
|
|
|
|
%ul.permissions-list
|
|
|
|
- grouped_scopes(application.scopes).each do |scope|
|
|
|
|
%li.permissions-list__item
|
|
|
|
.permissions-list__item__icon
|
2024-08-20 11:52:45 +00:00
|
|
|
= material_symbol('check')
|
2022-03-01 15:48:58 +00:00
|
|
|
.permissions-list__item__text
|
|
|
|
.permissions-list__item__text__title
|
|
|
|
= t(scope.key, scope: [:doorkeeper, :grouped_scopes, :title])
|
|
|
|
.permissions-list__item__text__type
|
|
|
|
= t(scope.access, scope: [:doorkeeper, :grouped_scopes, :access])
|