Skip to content

Sign_in form fix#40

Open
jroers wants to merge 3 commits into
sf-wdi-25:masterfrom
jroers:login_woes
Open

Sign_in form fix#40
jroers wants to merge 3 commits into
sf-wdi-25:masterfrom
jroers:login_woes

Conversation

@jroers

@jroers jroers commented Feb 5, 2016

Copy link
Copy Markdown

Fixes #7
Changed the placeholder values to be strings, No need for clownhats for 'Remember Me'

@tgaff

tgaff commented Feb 5, 2016

Copy link
Copy Markdown
Member

That might work, but we support several different languages in publify. We need to continue to support them. Please use the translations.

@tgaff

tgaff commented Feb 6, 2016

Copy link
Copy Markdown
Member

I think we already have strings in the locales.

@jroers

jroers commented Feb 6, 2016

Copy link
Copy Markdown
Author

Fixes #7
About this line:
<%= f.check_box :remember_me %> <%= "#{t('admin.users.remember_me', :default => "Remember Me")}" %>

There is not a field for remember_me that could I could find in any of the language files. Instead, I opted to stick with the same format that the other fields were using. I WOULD have used t('accounts.confirm.login') and t('accounts.confirm.password'); however, some (but not all) of the language files were looking to render additional information like %{login}.

For the sake of consistency across languages, I opted for the path admin.users.INSERT_THING_HERE

@nathanallen

Copy link
Copy Markdown
Contributor

Are there .yml file changes that you forgot to push?

@jroers

jroers commented Feb 6, 2016

Copy link
Copy Markdown
Author

I'm about 99% sure I didn't change any .yml files.

I just searched through them to find translations that corresponded to "Login" and "Password", then compared them with a few other languages to get a handle of whether they were being used consistently. Since they were, I didn't see the need to add new fields, or modify any of them as I was concerned that this could break the consistency.

@nathanallen

Copy link
Copy Markdown
Contributor

Nice work! I'd say we're two-thirds of the way there, and as far as we're going to get in this simulation without additional translations. You've uncovered two existing translations, and made a good argument for where the third one should go. As your code stops unsighly raw-html from displaying in the form, I am willing to merge this code -- but we'll need to follow up and create a new PR for "remember me" to be translated into other languages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants