keymanapp / keymanapp/keyman

feat(developer): Display CSS Key ID in Keycap Properties Panel

Open
#8,921 4 comments 0 reactions 1 assignee Claimed by @mcdurdin View on GitHub
developer/ developer/ide/ feat m:osk
Dominant language
Pascal
Stars
534
Forks
143
Avg merge
2d 10h
Merged PRs (30d)
113

Description

### Is your feature request related to a problem? Please describe.

It is often difficult to determine the CSS ID (with path, I think this might be called the "selector") of a keycap. My standard approach is to start with the web-based tester and use the Chrome "Inspect" feature and drill down the document tree to find the key, then try to determine the path. It may take a few attempts to get it right. This is particularly challenging with the popup keys which may disappear as you try to "Inpsect" their CSS code.

### Describe the solution you'd like

Since the key ID is deterministic, and applies the keyboard name, layer name, and key ID, plus some built-in CSS classes, couldn't KMD do the hard work for us? In the keymap properties for a key (regular, longpress or other) could KMD add the selector string in a read-only field? What I am thinking of are the selectors like:

```
.phone.ios .kmw-keyboard-gff_amharic #punctuation-2-K_1\+shift
```
and

```
.tablet.ios div.kmw-key.kmw-key-default[id='punctuaion-extra-U_1225']
```

These strings can get pretty long and may not fit comfortably into the properties panel. Displaying them in the status bar would be OK also -if we could copy & paste them from there.

### Describe alternatives you've considered

_No response_

### Related issues

_No response_

### Keyman apps

- [ ] Keyman for Android
- [ ] Keyman for iPhone and iPad
- [ ] Keyman for Linux
- [ ] Keyman for macOS
- [ ] Keyman for Windows
- [X] Keyman Developer
- [ ] KeymanWeb
- [ ] Other - give details at bottom of form

### Keyman version

_No response_

### Operating system

_No response_

### Device

_No response_

### Target application

_No response_

### Browser

_No response_

### Keyboard name

_No response_

### Keyboard version

_No response_

### Language name

_No response_

### Additional context

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.