-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Give freedom to set default_locale and available_locales instead of forcing #10
Conversation
@@ -5,12 +5,14 @@ module FormBuilderExtension | |||
|
|||
def translated_inputs(name = "Translations", options = {}, &block) | |||
options.symbolize_keys! | |||
available_locales = options.fetch(:available_locales, I18n.available_locales.sort) | |||
switch_locale = options.fetch(:switch_locale, false) | |||
auto_sort = options.fetch(:auto_sort, true) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since you gave user the option to choose locales to show (and implicitly the option to sort them), I'd remove the auto_sort
option. Can you do that and write a note in readme?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay I will do that
@fabn |
Give freedom to set default_locale and available_locales instead of forcing
Thank you. |
You are welcome :) |
Made jsoneditor.css to scss for asset pipeline
@fabn It will be flexible and useful if you allow to set default_locale and available_locales
A usecase: I want to show English translation fields without tab, and want to show other languages within tabs.