% content_for :title, t(".off_site_backup") %>
<%= t(".every_night_after_the_verified_html", offsite_backups_kept: (Setting.integer("offsite_backups_kept")), link: (link_to t(".settings"), edit_admin_settings_path, class: "link")) %>
<%= t(".connected") %> <%= t(".by_on_html", account_email: @connection.account_email, display_name: @connection.connected_by&.display_name, to_date: (fmt_date(@connection.connected_at&.to_date))) %> <%= t(".folder_html", folder: (OffsiteConnection::ROOT_FOLDER)) %>
<%= t(".uploaded_files_copied_of_html", files_copied: @files_copied, files_total: @files_total) %>
<%= t(".the_oauth_client_is_saved") %>
<%= link_to t(".connect_google_drive"), connect_admin_offsite_backup_path, class: "btn-primary self-start", data: { turbo: false } %> <% else %><%= t(".not_set_up_follow_the") %>
<% end %> <%= form_with model: @connection, url: admin_offsite_backup_path, method: :patch, class: "space-y-3 border-t border-slate-100 pt-3" do |f| %> <%= f.field :client_id, label: t(".oauth_client_id"), placeholder: "1234567890-abc.apps.googleusercontent.com" %> <%= f.field :client_secret, as: :password, label: t(".oauth_client_secret"), value: nil, placeholder: (@connection.client_secret.present? ? t(".saved_leave_blank_to_keep") : nil), autocomplete: "off" %> <%= f.submit t(".save_client"), class: "btn-secondary" %> <% end %><%= @connection.redirect_uri %>
<%= t(".it_must_be_the_address_html") %><%= t(".restoring_see_html", link: (link_to t(".help_administration"), help_page_path("administration", anchor: "restoring-from-google-drive"), class: "link")) %>