aboutsummaryrefslogtreecommitdiffstats
path: root/actionview/lib/action_view/helpers/tags/select.rb
Commit message (Collapse)AuthorAgeFilesLines
* Enable `Layout/EmptyLinesAroundAccessModifier` copRyuta Kamizono2019-06-131-1/+0
| | | | | | | | | | | We sometimes say "✂️ newline after `private`" in a code review (e.g. https://github.com/rails/rails/pull/18546#discussion_r23188776, https://github.com/rails/rails/pull/34832#discussion_r244847195). Now `Layout/EmptyLinesAroundAccessModifier` cop have new enforced style `EnforcedStyle: only_before` (https://github.com/rubocop-hq/rubocop/pull/7059). That cop and enforced style will reduce the our code review cost.
* Fix leaking special form_with attributes into html attributesYurii Cherniavskyi2018-07-201-1/+1
| | | | | Special form_with attributes `skip_default_ids` and `allow_method_names_outside_object` attributes are leaking into html attributes of option select tag helpers.
* Make sure that form_with_generates_ids only affects form_withRafael Mendonça França2017-11-251-1/+1
|
* Change `form_with` to generates ids by defaultnpezza932017-11-251-1/+1
| | | | | | | | | | When `form_with` was introduced we disabled the automatic generation of ids that was enabled in `form_for`. This usually is not an good idea since labels don't work when the input doesn't have an id and it made harder to test with Capybara. You can still disable the automatic generation of ids setting `config.action_view.form_with_generates_ids` to `false.`
* Merge pull request #29791 from yui-knk/at_objectRyuta Kamizono2017-09-051-1/+1
|\ | | | | Do not pass an instance variable to a private method
| * Do not pass an instance variable to a private methodyui-knk2017-09-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | `ActionView::Helpers::Tags::Base` has `@object` and all passed arguments for * `#value` * `#value_before_type_cast` * `#value_came_from_user?` are `@object`, so we do not need to pass arguments in this case.
* | Use frozen string literal in actionview/Kir Shatrov2017-07-241-0/+2
|/
* Revert "Merge pull request #29540 from kirs/rubocop-frozen-string"Matthew Draper2017-07-021-1/+0
| | | | | This reverts commit 3420a14590c0e6915d8b6c242887f74adb4120f9, reversing changes made to afb66a5a598ce4ac74ad84b125a5abf046dcf5aa.
* Enforce frozen string in RubocopKir Shatrov2017-07-011-0/+1
|
* Move slicing to initializer.Kasper Timm Hansen2017-06-071-1/+1
| | | | | | Forgot all about https://github.com/rails/rails/pull/28844/files#r113780934 cc @rafaelfranca
* Fix select tag helper used with Enumerable choicesSam Pohlenz2017-05-171-1/+1
| | | | | | Allows a custom object implementing Enumerable to be used as the choices parameter for a select tag, which previously wasn't possible due to the call to `empty?` on the choices (which isn't implemented on Enumerable).
* Fix broken comments indentation caused by rubocop auto-correct [ci skip]Ryuta Kamizono2016-09-141-4/+4
| | | | | | All indentation was normalized by rubocop auto-correct at 80e66cc4d90bf8c15d1a5f6e3152e90147f00772. But comments was still kept absolute position. This commit aligns comments with method definitions for consistency.
* normalizes indentation and whitespace across the projectXavier Noria2016-08-061-3/+3
|
* modernizes hash syntax in actionviewXavier Noria2016-08-061-2/+2
|
* Fixed #select form builder helper to support block with html outputBogdan Gusiev2014-08-051-1/+1
|
* Ability to pass block to AV#select helperBogdan Gusiev2013-09-231-1/+2
| | | | | | | | Example: = select(report, "campaign_ids") do - available_campaigns.each do |c| %option{:data => {:tags => c.tags.to_json}, :value => c.id}= c.name
* Move actionpack/lib/action_view* into actionview/libPiotr Sarnacki2013-06-201-0/+40