How to add a new language, a new arrangement of a language (such as a phonetic layout) or a new region. For what a layout contains, see layout format. Use packages/saccade-en as the reference, and packages/saccade-fr for a language with regions of its own.
- Find the official layout, or a photo of a real keyboard, for every layer: normal, Shift, AltGr and symbols. Copy it key by key.
- Ask a native speaker to check the result. Write down who checked it in the pull request.
- Open the New language or Region-specific layout issue form first if you want to agree on the scope.
- Create
packages/saccade-<code>, copying the files of an existing language package. The package is named@coldsofttech/saccade-<code>and starts at version0.1.0. - Write the layouts in
src/index.js. Exportlayout(the default) andcreateLayout(arrangement, region), and list any font the script needs infonts.saccade-keyboardsis a peer dependency, imported from@coldsofttech/saccade-keyboards/core. - Add
src/index.test.js. It runsvalidateLayouton every arrangement and region, and checks the keys that are easy to get wrong. - Add a
README.mdfor the package: what it provides, its arrangements, regions and digits, and how to register it. - Add the package to
.size-limit.json, to the demo inexamples/demo/src/main.jsx(its layout, regions and arrangements) and toexamples/demo/package.json. - Add it to the language table in the root
README.md, to the bug report, feature request and layout fix forms in.github/ISSUE_TEMPLATE, and to the package list in architecture. - Add an
[Unreleased]entry inCHANGELOG.md. - Run
npm run build, thennpm run check:packages, thennpx vitest run packages/saccade-<code>.
After the first release, register the package as a trusted publisher on npm (see repository setup).
- Add it to the language's
createLayout, reusing the shared helpers instead of repeating keys that do not change. - Add the region or arrangement to the test, so it is checked by
validateLayout. - Add it to the demo, the language's README and the root README table.
- Add an
[Unreleased]entry inCHANGELOG.md.
- Open the demo (
npm run build, thennpm run dev) and press every key on every layer. - Look at the keyboard at 430 px and at 801 px or wider. At 800 px or less the Shift and AltGr characters are hidden until those keys are pressed.
- Check with the number pad and the currency pad on, and in the dark theme.
- Check a script that has signs sitting on a letter: they should show a dotted circle.