mirror of
https://github.com/Retrospring/retrospring.git
synced 2025-03-21 10:17:48 +01:00
Add translations for profile settings
This commit is contained in:
parent
800958e88f
commit
3ee847258a
4 changed files with 48 additions and 28 deletions
|
@ -6,25 +6,25 @@
|
||||||
.pull-left
|
.pull-left
|
||||||
%img.avatar-lg.mr-3{ src: current_user.profile_picture.url(:medium) }
|
%img.avatar-lg.mr-3{ src: current_user.profile_picture.url(:medium) }
|
||||||
.media-body
|
.media-body
|
||||||
= f.file_field :profile_picture, label: t('views.settings.profile.avatar'), accept: APP_CONFIG[:accepted_image_formats].join(',')
|
= f.file_field :profile_picture, accept: APP_CONFIG[:accepted_image_formats].join(',')
|
||||||
|
|
||||||
.row.d-none#profile-picture-crop-controls
|
.row.d-none#profile-picture-crop-controls
|
||||||
.col-sm-10.col-md-8
|
.col-sm-10.col-md-8
|
||||||
%strong= t('views.settings.profile.avatar_adjust')
|
%strong= t('.adjust.profile_picture')
|
||||||
%img#profile-picture-cropper{ src: current_user.profile_picture.url(:medium) }
|
%img#profile-picture-cropper{ src: current_user.profile_picture.url(:medium) }
|
||||||
|
|
||||||
.row.mb-2#profile-header-media
|
.row.mb-2#profile-header-media
|
||||||
.col
|
.col
|
||||||
%img.mw-100.mr-3{ src: current_user.profile_header.url(:mobile) }
|
%img.mw-100.mr-3{ src: current_user.profile_header.url(:mobile) }
|
||||||
.col-xs-12.mt-3.mt-sm-0.pl-3.pr-3
|
.col-xs-12.mt-3.mt-sm-0.pl-3.pr-3
|
||||||
= f.file_field :profile_header, label: t('views.settings.profile.header'), accept: APP_CONFIG[:accepted_image_formats].join(',')
|
= f.file_field :profile_header, accept: APP_CONFIG[:accepted_image_formats].join(',')
|
||||||
|
|
||||||
.row.d-none#profile-header-crop-controls
|
.row.d-none#profile-header-crop-controls
|
||||||
.col-sm-10.col-md-8
|
.col-sm-10.col-md-8
|
||||||
%strong= t('views.settings.profile.header_adjust')
|
%strong= t('.adjust.profile_header')
|
||||||
%img#profile-header-cropper{ src: current_user.profile_header.url(:web) }
|
%img#profile-header-cropper{ src: current_user.profile_header.url(:web) }
|
||||||
|
|
||||||
= f.check_box :show_foreign_themes, label: 'Render other user themes when visiting their profile'
|
= f.check_box :show_foreign_themes
|
||||||
|
|
||||||
- %i[profile_picture_x profile_picture_y profile_picture_w profile_picture_h].each do |attrib|
|
- %i[profile_picture_x profile_picture_y profile_picture_w profile_picture_h].each do |attrib|
|
||||||
= f.hidden_field attrib, id: attrib
|
= f.hidden_field attrib, id: attrib
|
||||||
|
@ -32,20 +32,19 @@
|
||||||
- %i[profile_header_x profile_header_y profile_header_w profile_header_h].each do |attrib|
|
- %i[profile_header_x profile_header_y profile_header_w profile_header_h].each do |attrib|
|
||||||
= f.hidden_field attrib, id: attrib
|
= f.hidden_field attrib, id: attrib
|
||||||
|
|
||||||
= f.submit t('views.actions.save'), class: 'btn btn-primary'
|
= f.primary
|
||||||
|
|
||||||
.card
|
.card
|
||||||
.card-body
|
.card-body
|
||||||
= bootstrap_form_for(current_user.profile, url: { action: :update_profile }, html: { multipart: true }, method: :patch) do |f|
|
= bootstrap_form_for(current_user.profile, url: { action: :update_profile }, html: { multipart: true }, method: :patch) do |f|
|
||||||
|
|
||||||
= f.text_field :display_name, label: t('views.settings.profile.displayname')
|
= f.text_field :display_name
|
||||||
|
|
||||||
= f.text_field :motivation_header, label: t('views.settings.profile.motivation'), placeholder: t('views.settings.profile.placeholder.motivation')
|
= f.text_field :motivation_header
|
||||||
|
|
||||||
= f.text_field :website, label: t('views.settings.profile.website'), placeholder: 'https://example.com'
|
= f.text_field :website
|
||||||
|
|
||||||
= f.text_field :location, label: t('views.settings.profile.location'), placeholder: t('views.settings.profile.placeholder.location')
|
= f.text_field :location
|
||||||
|
|
||||||
= f.text_area :description, label: t('views.settings.profile.bio'), placeholder: t('views.settings.profile.placeholder.bio')
|
= f.text_area :description
|
||||||
|
|
||||||
= f.submit t('views.actions.save'), class: 'btn btn-primary'
|
= f.primary
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
= render 'settings/profile'
|
= render 'settings/profile'
|
||||||
|
|
||||||
- provide(:title, generate_title('Profile Settings'))
|
- provide(:title, generate_title(t(".title")))
|
||||||
- parent_layout 'user/settings'
|
- parent_layout 'user/settings'
|
||||||
|
|
|
@ -11,8 +11,26 @@ en:
|
||||||
link_text: "Link text"
|
link_text: "Link text"
|
||||||
starts_at: "Start time"
|
starts_at: "Start time"
|
||||||
ends_at: "End time"
|
ends_at: "End time"
|
||||||
|
profile:
|
||||||
|
description: "Biography"
|
||||||
|
display_name: "Your name"
|
||||||
|
location: "Location"
|
||||||
|
motivation_header: "Motivation header"
|
||||||
|
website: "Website"
|
||||||
service:
|
service:
|
||||||
post_tag: "Tag"
|
post_tag: "Tag"
|
||||||
|
user:
|
||||||
|
profile_picture: "Profile picture"
|
||||||
|
profile_header: "Profile header"
|
||||||
|
show_foreign_themes: "Render other user themes when visiting their profile"
|
||||||
help:
|
help:
|
||||||
|
profile:
|
||||||
|
motivation_header: "Shown in the header of the question box on your profile. Motivate users to ask you questions!"
|
||||||
services/twitter:
|
services/twitter:
|
||||||
post_tag: "Automatically append a tag to your shared answers. A # symbol is not automatically prepended."
|
post_tag: "Automatically append a tag to your shared answers. A # symbol is not automatically prepended."
|
||||||
|
helpers:
|
||||||
|
submit:
|
||||||
|
user:
|
||||||
|
update: :voc.save
|
||||||
|
profile:
|
||||||
|
update: :voc.save
|
|
@ -387,20 +387,6 @@ en:
|
||||||
delete: "Delete my account"
|
delete: "Delete my account"
|
||||||
unsatisfied: "Unsatisfied?"
|
unsatisfied: "Unsatisfied?"
|
||||||
back: "Back"
|
back: "Back"
|
||||||
profile:
|
|
||||||
displayname: "Your name"
|
|
||||||
avatar: "Profile picture"
|
|
||||||
avatar_adjust: "Adjust your new avatar"
|
|
||||||
header: "Profile header"
|
|
||||||
header_adjust: "Adjust your new header"
|
|
||||||
motivation: "Motivation header"
|
|
||||||
website: "Website"
|
|
||||||
location: "Location"
|
|
||||||
bio: "Bio"
|
|
||||||
placeholder:
|
|
||||||
motivation: "Ask me anything!"
|
|
||||||
location: "Where are you?"
|
|
||||||
bio: "Tell us something nice about you!"
|
|
||||||
privacy:
|
privacy:
|
||||||
anonymous: "Allow anonymous questions"
|
anonymous: "Allow anonymous questions"
|
||||||
public: "Show your answers in the public timeline"
|
public: "Show your answers in the public timeline"
|
||||||
|
@ -464,6 +450,10 @@ en:
|
||||||
success: "Announcement has been deleted successfully."
|
success: "Announcement has been deleted successfully."
|
||||||
error: "Unable to delete announcement."
|
error: "Unable to delete announcement."
|
||||||
settings:
|
settings:
|
||||||
|
profile:
|
||||||
|
adjust:
|
||||||
|
profile_picture: "Adjust your new profile picture"
|
||||||
|
profile_header: "Adjust your new profile header"
|
||||||
services:
|
services:
|
||||||
services:
|
services:
|
||||||
one: "Sharing is enabled for the following service:"
|
one: "Sharing is enabled for the following service:"
|
||||||
|
@ -486,9 +476,22 @@ en:
|
||||||
error: :errors.base
|
error: :errors.base
|
||||||
destroy:
|
destroy:
|
||||||
success: "Service removed successfully."
|
success: "Service removed successfully."
|
||||||
|
user:
|
||||||
|
edit:
|
||||||
|
title: "Profile Settings"
|
||||||
|
update:
|
||||||
|
success: "Profile updated successfully."
|
||||||
|
error: "Unable to update profile."
|
||||||
|
notice:
|
||||||
|
profile_picture: " It might take a few minutes until your new profile picture is shown everywhere."
|
||||||
|
profile_header: " It might take a few minutes until your new profile header is shown everywhere."
|
||||||
|
update_profile:
|
||||||
|
success: :user.update.success
|
||||||
|
error: :user.update.error
|
||||||
voc:
|
voc:
|
||||||
delete: "Delete"
|
delete: "Delete"
|
||||||
edit: "Edit"
|
edit: "Edit"
|
||||||
|
save: "Save changes"
|
||||||
update: "Update"
|
update: "Update"
|
||||||
errors:
|
errors:
|
||||||
base: "An error occurred"
|
base: "An error occurred"
|
||||||
|
|
Loading…
Reference in a new issue