The highlight of this release is automatic physical layout detection for most ZMK keyboards, as determined by the keymap filename. For instance parsing `corne.keymap` [will add](https://github.com/caksoylar/keymap-drawer/blob/a02814e/resources/zmk_keyboard_layouts.yaml#L27) a `layout: {qmk_keyboard: crkbd/rev1, qmk_layout: LAYOUT_split_3x6_3}` field to the output keymap YAML, so you won't have to manually specify it during `keymap draw`. (There is no support yet for determining the correct `qmk_layout` via the chosen matrix transform.)
To support more ZMK (and custom QMK) keyboards, I also started maintaining some extra physical layout definitions under the [`resources` folder](https://github.com/caksoylar/keymap-drawer/tree/main/resources/qmk_layouts). If a `qmk_keyboard` name matches one of the files here then that will be used rather than checking QMK keyboards API. For example, if you use `keymap draw -k corne_rotated` instead of `crkbd/rev1` you will get a [Corne layout with nicely rotated thumb keys](https://caksoylar.github.io/keymap-drawer?keymap_yaml=H4sIAAAAAAAC_2WPS0-DQBSF9_0VJ2zcXHXRuGFHC62PPlRolTaGUDoK6VhwmCYSw38vA1NCcDU55zv33Ds8LNKTNAfAz_chOLBil4ZibyJKxZEFIpWhZHtNeZPFzPKXKy_IM57IYPh7FwwHFWIiVzW2M1EPcI3tC-GN4BBeCR7BJ6wID4Ql4fnjEvqLTYyl4ISq2ioJypieklq7Wltc1trW2o2Tz8aZVM6UcN_3H3uTT73mmdbtauPKKNujNoR3wpiwJowIC8KcYJBBuCHcXmJtH1SBF-6qoiJjJr7iNJdlJ9VsUSknj7pgYa31-MjNwoh1mevPNfuP2n86R8lEF9UfrqdsxplkvZvORV3F4vEBAAA%3D).
See the newly updated [`layout` section in the keymap spec](https://github.com/caksoylar/keymap-drawer/blob/main/KEYMAP_SPEC.md#layout) for details.
Features
- Automatically determine physical layouts for most ZMK keyboards during parsing
- Mapped from keymap filename using [the mapping file](https://github.com/caksoylar/keymap-drawer/blob/main/resources/zmk_keyboard_layouts.yaml)
- Contributions welcome to add mappings for custom ZMK keyboards/shields!
- Add custom physical layout definitions for non-QMK-upstream keyboards
- Maintained under [`resources/qmk_layouts`](https://github.com/caksoylar/keymap-drawer/tree/main/resources/qmk_layouts)
- Contributions welcome to support more keyboards! See [Keymap Layout Helper](https://nickcoutsos.github.io/keymap-layout-tools/) and [other resources](https://github.com/caksoylar/keymap-drawer/blob/main/KEYMAP_SPEC.md#layout) to help generate new layouts.
- Make `qmk_keycode_map`/`zmk_keycode_map` support key spec dicts (e.g. including `hold` or `shifted` fields), e.g. `SLASH: {t: '/', shifted: '?'}`
- Assign CSS class `layer-<layer_name>` to each layer so they can be styled individually through [`svg_style`](https://github.com/caksoylar/keymap-drawer/blob/main/keymap_drawer/config.py#L54) (thanks manna-harbour!)
**Full Changelog**: https://github.com/caksoylar/keymap-drawer/compare/v0.4.0...v0.5.0