-
Notifications
You must be signed in to change notification settings - Fork 330
JS config
scambra edited this page May 29, 2012
·
3 revisions
You can configure some JS options. For it, set them in ActiveScaffold.js_config
hash, in an initializer or application controller:
ActiveScaffold.js_config = {...}
You can change options for highlight effect.
# For jquery highlight effect
ActiveScaffold.js_config[:highlight] = {:color => "#ffff99"}
When a form is closed, the row can be out of viewport, so you can enable scrolling to the row, either always or when is out of viewport.
# Scroll element to top when is out of viewport
ActiveScaffold.js_config = {:scroll_on_close => :checkInViewport}
# Scroll element to top always
ActiveScaffold.js_config = {:scroll_on_close => true}
By default checkInViewport is set.