# Selectively disable keyboard shortcuts in custom interface?

**URL:** https://support.prodi.gy/t/selectively-disable-keyboard-shortcuts-in-custom-interface/3853
**Category:** Uncategorized
**Tags:** front-end, usage
**Created:** [February 5, 2021, 2:40pm UTC](https://support.prodi.gy/t/selectively-disable-keyboard-shortcuts-in-custom-interface/3853 "2021-02-05T14:40:34Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![AK\_Fischer](https://avatars.discourse-cdn.com/v4/letter/a/8c91f0/32.png) [@AK\_Fischer](https://support.prodi.gy/u/AK_Fischer)
#### Post date: [February 5, 2021, 2:40pm UTC](https://support.prodi.gy/t/selectively-disable-keyboard-shortcuts-in-custom-interface/3853/1 "2021-02-05T14:40:34Z")

</div>

Hi all,

I have a blocks interface that contains several elements which usually respond to hotkeys (e.g. a `choice` element plus a `ner_manual` element). I'd like to disable hotkeys for all but one of the elements (e.g. stop the `choice` element from responding, meaning the number hotkeys will be used to select `ner_manual` labels without triggering `choice` selections).

How would I best do that?

Thanks and all the best,  
Andrea

---

<div class="post-metadata">

### Author: ![ines](https://sea2.discourse-cdn.com/flex020/user_avatar/support.prodi.gy/ines/32/3_2.png) [@ines](https://support.prodi.gy/u/ines)
#### Post date: [February 5, 2021, 2:48pm UTC](https://support.prodi.gy/t/selectively-disable-keyboard-shortcuts-in-custom-interface/3853/2 "2021-02-05T14:48:20Z")

</div>

Hi! That's a good question and it's definitely inconvenient if the choice shortcuts interfere with the label shortcuts, or vice versa.

One option would be to just re-map the choice keys to something else – you can do that by defining custom shortcuts for `"1"`, `"2"` and so on, corresponding to the option index: [https://prodi.gy/docs/api-web-app#actions-custom-labels](https://prodi.gy/docs/api-web-app#actions-custom-labels) So you could make the choice key `1` something like `"shift+alt+1"`. Alternatively, you could also define custom shortcuts for the individual labels in `ner_manual`, like `P` for `PERSON` etc. This can be helful if you're mostly working with the same label set and there's an obvious mapping that's easy to learn for the annotator and maybe even more intuitive than the numbers 🙂

---

<div class="post-metadata">

### Author: ![AK\_Fischer](https://avatars.discourse-cdn.com/v4/letter/a/8c91f0/32.png) [@AK\_Fischer](https://support.prodi.gy/u/AK_Fischer)
#### Post date: [February 5, 2021, 2:52pm UTC](https://support.prodi.gy/t/selectively-disable-keyboard-shortcuts-in-custom-interface/3853/3 "2021-02-05T14:52:39Z")

</div>

Hi Ines! Thanks a lot for your super quick and helpful reply 😻

So I'll just give the `keymap_by_label` option to each of the different elements? That makes a lot of sense. Thanks a bunch!
