Skip to content
This repository was archived by the owner on Dec 19, 2024. It is now read-only.
This repository was archived by the owner on Dec 19, 2024. It is now read-only.

Dynamically add key binding in polymer #92

@sudipta1411

Description

@sudipta1411

I am using IronA11yKeysBehavior to implement keyboard shortcut handling in my project. I have a polymer element <my-element></my-element> in which I have defined the keyBindings property as follows

keyBindings : {
    'shift+a' : '_onKeyPreseed'
}

The element is working as expected. But I want to dynamically assign keyboard shortcuts (so that a user can change the shortcuts as per her requirements). Say I want to change the shortcut from shift+a to alt+a. How to do this?

I have changed the 'keyBindings' property, but that is not working, still _onKeyPreseed is called when shift+a is pressed, not when alt+ais pressed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions