You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Do not use the issues tracker for help or support, try Stack Overflow.
For bugs, do a quick search and make sure the bug has not yet been reported
If you found a security bug, do not report it through GitHub. Please send an e-mail to heartcombo@googlegroups.com instead.
Finally, be nice and have fun!
Environment
Ruby 3.1.2
Rails 7.0.4
Simple Form 5.1.0
Current behavior
If I want to customize the search input, e.g. f.input(:search, as: :search), I can't do so in a comfortable way.
I can do f.input(:search, as: :custom_search) and build a CustomSearchInput < SimpleForm::Inputs::StringInput, but this doesn't feel very natural.
I can also do SimpleForm::FormBuilder.mappings[:search] = CustomSearchInput, but this doesn't use a public interface.
Expected behavior
To be able to tweak the default SimpleForm::FormBuilder.mappings[:search] via a config option.
e.g.
The text was updated successfully, but these errors were encountered:
klondikemarlen
changed the title
Feature Request: Add Support to Cusomize Input Mappings
Feature Request: Add Support to Customize Input Mappings
Dec 2, 2022
Precheck
Environment
Current behavior
If I want to customize the search input, e.g.
f.input(:search, as: :search)
, I can't do so in a comfortable way.I can do
f.input(:search, as: :custom_search)
and build aCustomSearchInput < SimpleForm::Inputs::StringInput
, but this doesn't feel very natural.I can also do
SimpleForm::FormBuilder.mappings[:search] = CustomSearchInput
, but this doesn't use a public interface.Expected behavior
To be able to tweak the default
SimpleForm::FormBuilder.mappings[:search]
via a config option.e.g.
The text was updated successfully, but these errors were encountered: