Shortcuts plugin

Plugin details

Shortcuts is a plugin that gives you easy gmail-like keyboard shortcuts for your Web applications.

Websitehttp://synaphy.com.au/2007/7/23/fancy-keyboard-shortcuts-just-like-gmail Repositorysvn://rubyforge.org/var/svn/rails-oceania/shortcuts Author Max Muermann Tags shortcut LicenseMIT

Documentation

Install the plugin:
ruby script/plugin install svn://rubyforge.org/var/svn/rails-oceania/shortcuts

To prepare your application, run script/generate shortcuts to copy the necessary javascript file to the public/javascripts directory of the application.

Make sure you include either javascript_include_tag :defaults or javascript_include_tag 'shortcuts' somewhere in your HTML header.

You can now use fancy keyboard navigation just like Google does.

A simple navigation shortcut that will open a new url:

<%= shortcut 'p', projects_url %>


To register an ajax shortcut:

<%= remote_shortcut 'd', delete_project_url(@project) %>


To register an arbitrary javascript function:

<%= shortcut_function 'a', "alert('hello world');" %>


Shortcuts depends on the Prototype javascript library that is included with Rails.

Further Documentation

There is currently no advanced documentation for this plugin.

New documentation

Edit plugin | (0 older versions) | Last edited by: hardway, about 1 year ago