@gbosetti/access-keys-activators
v0.1.0
Published
jQuery plugin to retrieve the keys that activate the access key of the HTML elements which have it defined.
Downloads
1
Readme
Browser's Access Key Activators detector (jQuery plugin)
Description
This jQuery plugin retrieves the keys that activate the access-key of the HTML elements which have it defined.
It currently supports Linux, Mac and Windows OS and Chrome, Firefox, Opera and IE. It uses some of the mapping info from https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/accesskey
Dependencies
Requires jQuery >=1.5 and https://github.com/bestiejs/platform.js/blob/master/platform.js
Usage
Include jQuery & platform.js:
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/platform/1.3.5/platform.min.js"></script> <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.0.0/jquery.min.js"></script>
Include plugin's code:
<script type="text/javascript" src="../Jquery.accessKeysActivators.js"></script>
Call the plugin:
$(function() { var keys = $.getAccessKeyActivators(); console.log(keys); $("div").html(keys.toString()); });
Updating the plugin
Follow the instructions in https://github.com/jquery-boilerplate/jquery-boilerplate/wiki/How-to-publish-a-plugin-in-jQuery-Plugin-Registry