2021-06-25 05:48:53 +02:00
|
|
|
{
|
|
|
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
|
|
"$id": "qmk.definitions.v1",
|
|
|
|
"title": "Common definitions used across QMK's jsonschemas.",
|
|
|
|
"type": "object",
|
|
|
|
"boolean_array": {
|
|
|
|
"type": "object",
|
|
|
|
"additionalProperties": {"type": "boolean"}
|
|
|
|
},
|
|
|
|
"filename": {
|
|
|
|
"type": "string",
|
|
|
|
"minLength": 1,
|
|
|
|
"pattern": "^[0-9a-z_]*$"
|
|
|
|
},
|
|
|
|
"hex_number_2d": {
|
|
|
|
"type": "string",
|
|
|
|
"pattern": "^0x[0-9A-F]{2}$"
|
|
|
|
},
|
|
|
|
"hex_number_4d": {
|
|
|
|
"type": "string",
|
|
|
|
"pattern": "^0x[0-9A-F]{4}$"
|
|
|
|
},
|
2022-01-16 22:44:34 +01:00
|
|
|
"bcd_version": {
|
|
|
|
"type": "string",
|
|
|
|
"pattern": "^[0-9]{1,2}\\.[0-9]\\.[0-9]$"
|
|
|
|
},
|
2021-06-25 05:48:53 +02:00
|
|
|
"text_identifier": {
|
|
|
|
"type": "string",
|
|
|
|
"minLength": 1,
|
|
|
|
"maxLength": 250
|
|
|
|
},
|
|
|
|
"layout_macro": {
|
|
|
|
"oneOf": [
|
|
|
|
{
|
|
|
|
"type": "string",
|
2022-03-04 18:06:15 +01:00
|
|
|
"enum": [
|
|
|
|
"LAYOUT",
|
|
|
|
"LAYOUT_1x2uC",
|
|
|
|
"LAYOUT_1x2uL",
|
|
|
|
"LAYOUT_1x2uR",
|
|
|
|
"LAYOUT_2x2uC",
|
|
|
|
"LAYOUT_2x3uC",
|
|
|
|
"LAYOUT_625uC",
|
|
|
|
"LAYOUT_ANSI_DEFAULT",
|
|
|
|
"LAYOUT_JP",
|
|
|
|
"LAYOUT_ortho_3x12_1x2uC",
|
|
|
|
"LAYOUT_ortho_4x12_1x2uC",
|
|
|
|
"LAYOUT_ortho_4x12_1x2uL",
|
|
|
|
"LAYOUT_ortho_4x12_1x2uR",
|
|
|
|
"LAYOUT_ortho_5x12_1x2uC",
|
|
|
|
"LAYOUT_ortho_5x12_2x2uC",
|
|
|
|
"LAYOUT_ortho_5x14_1x2uC",
|
|
|
|
"LAYOUT_ortho_5x14_1x2uL",
|
|
|
|
"LAYOUT_ortho_5x14_1x2uR",
|
|
|
|
"LAYOUT_planck_1x2uC",
|
|
|
|
"LAYOUT_planck_1x2uL",
|
|
|
|
"LAYOUT_planck_1x2uR",
|
|
|
|
"LAYOUT_preonic_1x2uC",
|
|
|
|
"LAYOUT_preonic_1x2uL",
|
|
|
|
"LAYOUT_preonic_1x2uR",
|
|
|
|
"LAYOUT_reviung34_2uL"
|
|
|
|
]
|
2021-06-25 05:48:53 +02:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"type": "string",
|
|
|
|
"pattern": "^LAYOUT_[0-9a-z_]*$"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"key_unit": {
|
|
|
|
"type": "number",
|
|
|
|
"min": 0.25
|
|
|
|
},
|
2022-04-01 11:25:43 +02:00
|
|
|
"keyboard": {
|
|
|
|
"oneOf": [
|
|
|
|
{
|
|
|
|
"type": "string",
|
|
|
|
"enum": [
|
|
|
|
"converter/numeric_keypad_IIe",
|
|
|
|
"emptystring/NQG",
|
|
|
|
"maple_computing/christmas_tree/V2017"
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"type": "string",
|
|
|
|
"pattern": "^[0-9a-z][0-9a-z_/]*$"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2021-06-25 05:48:53 +02:00
|
|
|
"mcu_pin_array": {
|
|
|
|
"type": "array",
|
|
|
|
"items": {"$ref": "#/mcu_pin"}
|
|
|
|
},
|
|
|
|
"mcu_pin": {
|
|
|
|
"oneOf": [
|
2022-02-15 05:41:16 +01:00
|
|
|
{
|
|
|
|
"type": "string",
|
|
|
|
"enum": ["NO_PIN"]
|
|
|
|
},
|
2021-06-25 05:48:53 +02:00
|
|
|
{
|
|
|
|
"type": "string",
|
|
|
|
"pattern": "^[A-K]\\d{1,2}$"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"type": "string",
|
|
|
|
"pattern": "^LINE_PIN\\d{1,2}$"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"type": "number",
|
|
|
|
"multipleOf": 1
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"type": "null"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"signed_decimal": {
|
|
|
|
"type": "number"
|
|
|
|
},
|
|
|
|
"signed_int": {
|
|
|
|
"type": "number",
|
|
|
|
"multipleOf": 1
|
2022-01-16 22:44:34 +01:00
|
|
|
},
|
2021-06-25 05:48:53 +02:00
|
|
|
"signed_int_8": {
|
|
|
|
"type": "number",
|
|
|
|
"min": -127,
|
|
|
|
"max": 127,
|
|
|
|
"multipleOf": 1
|
2022-01-16 22:44:34 +01:00
|
|
|
},
|
2021-06-25 05:48:53 +02:00
|
|
|
"string_array": {
|
|
|
|
"type": "array",
|
|
|
|
"items": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"string_object": {
|
|
|
|
"type": "object",
|
|
|
|
"additionalProperties": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"unsigned_decimal": {
|
|
|
|
"type": "number",
|
|
|
|
"min": 0
|
|
|
|
},
|
|
|
|
"unsigned_int": {
|
|
|
|
"type": "number",
|
|
|
|
"min": 0,
|
|
|
|
"multipleOf": 1
|
2022-01-16 22:44:34 +01:00
|
|
|
},
|
2021-06-25 05:48:53 +02:00
|
|
|
"unsigned_int_8": {
|
|
|
|
"type": "number",
|
|
|
|
"min": 0,
|
|
|
|
"max": 255,
|
|
|
|
"multipleOf": 1
|
|
|
|
}
|
|
|
|
}
|