refactor(docs): Remove unnecessary jsx includes
This commit is contained in:
parent
4faeb365b1
commit
96cd3a1ce2
8 changed files with 18 additions and 58 deletions
8
docs/docs/codes/_keyboard-consumer.md
Normal file
8
docs/docs/codes/_keyboard-consumer.md
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
:::info[Keyboard vs. Consumer keycodes]
|
||||||
|
In the below tables, there are keycode pairs with similar names where one variant has a `K_` prefix and another `C_`.
|
||||||
|
These variants correspond to similarly named usages from different [HID usage pages](https://usb.org/sites/default/files/hut1_2.pdf#page=16),
|
||||||
|
namely the "keyboard/keypad" and "consumer" ones respectively.
|
||||||
|
|
||||||
|
In practice, some OS and applications might listen to only one of the variants.
|
||||||
|
You can use the values in the compatibility columns below to assist you in selecting which one to use.
|
||||||
|
:::
|
|
@ -6,8 +6,8 @@ hide_title: true
|
||||||
|
|
||||||
import OsLegend from "@site/src/components/codes/OsLegend";
|
import OsLegend from "@site/src/components/codes/OsLegend";
|
||||||
import ToastyContainer from "@site/src/components/codes/ToastyContainer";
|
import ToastyContainer from "@site/src/components/codes/ToastyContainer";
|
||||||
import KeyboardConsumer from "@site/src/components/codes/KeyboardConsumer";
|
|
||||||
import Content, { toc as contentToc } from "./_applications.mdx";
|
import Content, { toc as contentToc } from "./_applications.mdx";
|
||||||
|
import KeyboardConsumer from "./_keyboard-consumer.md";
|
||||||
|
|
||||||
export const toc = contentToc;
|
export const toc = contentToc;
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@ hide_title: true
|
||||||
import OsLegend from "@site/src/components/codes/OsLegend";
|
import OsLegend from "@site/src/components/codes/OsLegend";
|
||||||
import ToastyContainer from "@site/src/components/codes/ToastyContainer";
|
import ToastyContainer from "@site/src/components/codes/ToastyContainer";
|
||||||
import Content, { toc as contentToc } from "./_editing.mdx";
|
import Content, { toc as contentToc } from "./_editing.mdx";
|
||||||
import KeyboardConsumer from "@site/src/components/codes/KeyboardConsumer";
|
import KeyboardConsumer from "./_keyboard-consumer.md";
|
||||||
|
|
||||||
export const toc = contentToc;
|
export const toc = contentToc;
|
||||||
|
|
||||||
|
|
|
@ -5,8 +5,6 @@ hide_title: true
|
||||||
slug: ./
|
slug: ./
|
||||||
---
|
---
|
||||||
|
|
||||||
import SpellingCaution from "@site/src/components/codes/SpellingCaution";
|
|
||||||
import KeyboardConsumer from "@site/src/components/codes/KeyboardConsumer";
|
|
||||||
import OsLegend from "@site/src/components/codes/OsLegend";
|
import OsLegend from "@site/src/components/codes/OsLegend";
|
||||||
import ToastyContainer from "@site/src/components/codes/ToastyContainer";
|
import ToastyContainer from "@site/src/components/codes/ToastyContainer";
|
||||||
import Key, { toc as keyToc } from "./_keyboard-keypad.mdx";
|
import Key, { toc as keyToc } from "./_keyboard-keypad.mdx";
|
||||||
|
@ -15,6 +13,7 @@ import Media, { toc as mediaToc } from "./_media.mdx";
|
||||||
import Applications, { toc as applicationsToc } from "./_applications.mdx";
|
import Applications, { toc as applicationsToc } from "./_applications.mdx";
|
||||||
import InputAssist, { toc as inputAssistToc } from "./_input-assist.mdx";
|
import InputAssist, { toc as inputAssistToc } from "./_input-assist.mdx";
|
||||||
import Power, { toc as powerToc } from "./_power.mdx";
|
import Power, { toc as powerToc } from "./_power.mdx";
|
||||||
|
import KeyboardConsumer from "./_keyboard-consumer.md";
|
||||||
|
|
||||||
export const toc = [
|
export const toc = [
|
||||||
...keyToc,
|
...keyToc,
|
||||||
|
@ -25,7 +24,11 @@ export const toc = [
|
||||||
...powerToc,
|
...powerToc,
|
||||||
];
|
];
|
||||||
|
|
||||||
<SpellingCaution />
|
:::warning
|
||||||
|
Take extra notice of the spelling of the keycodes, especially the shorthand spelling.
|
||||||
|
Otherwise, it will result in an elusive parsing error!
|
||||||
|
:::
|
||||||
|
|
||||||
<KeyboardConsumer />
|
<KeyboardConsumer />
|
||||||
<OsLegend />
|
<OsLegend />
|
||||||
<ToastyContainer />
|
<ToastyContainer />
|
||||||
|
|
|
@ -7,7 +7,7 @@ hide_title: true
|
||||||
import OsLegend from "@site/src/components/codes/OsLegend";
|
import OsLegend from "@site/src/components/codes/OsLegend";
|
||||||
import ToastyContainer from "@site/src/components/codes/ToastyContainer";
|
import ToastyContainer from "@site/src/components/codes/ToastyContainer";
|
||||||
import Content, { toc as contentToc } from "./_media.mdx";
|
import Content, { toc as contentToc } from "./_media.mdx";
|
||||||
import KeyboardConsumer from "@site/src/components/codes/KeyboardConsumer";
|
import KeyboardConsumer from "./_keyboard-consumer.md";
|
||||||
|
|
||||||
export const toc = contentToc;
|
export const toc = contentToc;
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@ hide_title: true
|
||||||
import OsLegend from "@site/src/components/codes/OsLegend";
|
import OsLegend from "@site/src/components/codes/OsLegend";
|
||||||
import ToastyContainer from "@site/src/components/codes/ToastyContainer";
|
import ToastyContainer from "@site/src/components/codes/ToastyContainer";
|
||||||
import Content, { toc as contentToc } from "./_power.mdx";
|
import Content, { toc as contentToc } from "./_power.mdx";
|
||||||
import KeyboardConsumer from "@site/src/components/codes/KeyboardConsumer";
|
import KeyboardConsumer from "./_keyboard-consumer.md";
|
||||||
|
|
||||||
export const toc = contentToc;
|
export const toc = contentToc;
|
||||||
|
|
||||||
|
|
|
@ -1,30 +0,0 @@
|
||||||
/*
|
|
||||||
* Copyright (c) 2024 The ZMK Contributors
|
|
||||||
*
|
|
||||||
* SPDX-License-Identifier: CC-BY-NC-SA-4.0
|
|
||||||
*/
|
|
||||||
|
|
||||||
import Admonition from "@theme/Admonition";
|
|
||||||
|
|
||||||
export default function KeyboardConsumer() {
|
|
||||||
return (
|
|
||||||
<Admonition type="info" title="Keyboard vs. Consumer keycodes">
|
|
||||||
<p>
|
|
||||||
In the below tables, there are keycode pairs with similar names where
|
|
||||||
one variant has a <code>K_</code> prefix and another <code>C_</code>.
|
|
||||||
These variants correspond to similarly named usages from different{" "}
|
|
||||||
<a href="https://usb.org/sites/default/files/hut1_2.pdf#page=16">
|
|
||||||
HID usage pages
|
|
||||||
</a>
|
|
||||||
, namely the "keyboard/keypad" and "consumer" ones respectively.
|
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
In practice, some OS and applications might listen to only one of the
|
|
||||||
variants. You can use the values in the compatibility columns below to
|
|
||||||
assist you in selecting which one to use.
|
|
||||||
</p>
|
|
||||||
</Admonition>
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
KeyboardConsumer.propTypes = {};
|
|
|
@ -1,21 +0,0 @@
|
||||||
/*
|
|
||||||
* Copyright (c) 2020 The ZMK Contributors
|
|
||||||
*
|
|
||||||
* SPDX-License-Identifier: CC-BY-NC-SA-4.0
|
|
||||||
*/
|
|
||||||
|
|
||||||
import Admonition from "@theme/Admonition";
|
|
||||||
|
|
||||||
export default function SpellingCaution() {
|
|
||||||
return (
|
|
||||||
<Admonition type="warning">
|
|
||||||
<p>
|
|
||||||
Take extra notice of the spelling of the keycodes, especially the
|
|
||||||
shorthand spelling. Otherwise, it will result in an elusive parsing
|
|
||||||
error!
|
|
||||||
</p>
|
|
||||||
</Admonition>
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
SpellingCaution.propTypes = {};
|
|
Loading…
Add table
Reference in a new issue