Skip to content

Commit

Permalink
chore: reformat config.schema.json
Browse files Browse the repository at this point in the history
  • Loading branch information
karlvr authored and donavanbecker committed Jan 21, 2025
1 parent f4ca4a6 commit f2d7f9a
Showing 1 changed file with 100 additions and 43 deletions.
143 changes: 100 additions & 43 deletions config.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"pluginAlias": "Roomba2",
"pluginType": "platform",
"customUi": true,
"singular": false,
"customUiPath": "./dist/homebridge-ui",
"schema": {
"type": "array",
Expand Down Expand Up @@ -81,8 +82,18 @@
"required": true,
"default": "everywhere",
"oneOf": [
{ "title": "Clean everywhere", "enum": ["everywhere"] },
{ "title": "Clean specific rooms", "enum": ["rooms"] }
{
"title": "Clean everywhere",
"enum": [
"everywhere"
]
},
{
"title": "Clean specific rooms",
"enum": [
"rooms"
]
}
]
},
"mission": {
Expand All @@ -95,8 +106,18 @@
"default": 1,
"required": true,
"oneOf": [
{ "title": "Yes", "enum": [1] },
{ "title": "No", "enum": [0] }
{
"title": "Yes",
"enum": [
1
]
},
{
"title": "No",
"enum": [
0
]
}
],
"condition": {
"functionBody": "return model.cleanBehaviour === 'rooms';"
Expand Down Expand Up @@ -166,8 +187,18 @@
"required": true,
"default": "home",
"oneOf": [
{ "title": "Home", "enum": ["home"] },
{ "title": "Pause", "enum": ["pause"] }
{
"title": "Home",
"enum": [
"home"
]
},
{
"title": "Pause",
"enum": [
"pause"
]
}
]
}
}
Expand All @@ -185,7 +216,10 @@
"type": "section",
"title": "Display Details",
"items": [
{ "type": "help", "helpvalue": "<span class='help-block'>Details about your Roomba to be displayed in the Home app. You can make up the values you enter&nbsp;here.</span>" },
{
"type": "help",
"helpvalue": "<span class='help-block'>Details about your Roomba to be displayed in the Home app. You can make up the values you enter&nbsp;here.</span>"
},
"name",
"model",
"serialnum"
Expand All @@ -195,7 +229,10 @@
"type": "section",
"title": "Connection",
"items": [
{ "type": "help", "helpvalue": "<span class='help-block'>Please consult the <a href='https://github.com/homebridge-plugins/homebridge-roomba2#setup' target='_blank'>README</a> to obtain these connection values for your&nbsp;Roomba.</span>" },
{
"type": "help",
"helpvalue": "<span class='help-block'>Please consult the <a href='https://github.com/homebridge-plugins/homebridge-roomba2#setup' target='_blank'>README</a> to obtain these connection values for your&nbsp;Roomba.</span>"
},
"blid",
"robotpwd",
"ipaddress"
Expand All @@ -205,15 +242,21 @@
"type": "section",
"title": "Switches",
"items": [
{ "type": "help", "helpvalue": "<span class='help-block'>Switches add additional buttons in the Home app to control Roomba’s behaviour.</span>" },
{
"type": "help",
"helpvalue": "<span class='help-block'>Switches add additional buttons in the Home app to control Roomba’s behaviour.</span>"
},
"homeSwitch"
]
},
{
"type": "section",
"title": "Contact Sensors",
"items": [
{ "type": "help", "helpvalue": "<span class='help-block'>Contact sensors appear in the Home app and show what state Roomba is in.</span>" },
{
"type": "help",
"helpvalue": "<span class='help-block'>Contact sensors appear in the Home app and show what state Roomba is in.</span>"
},
"dockContactSensor",
"dockingContactSensor",
"runningContactSensor",
Expand All @@ -224,38 +267,52 @@
{
"type": "section",
"title": "Behavior",
"items": ["cleanBehaviour", "mission.pmap_id", "mission.user_pmapv_id", {
"key": "mission.regions",
"type": "array",
"notitle": true,
"items": [
{
"type": "div",
"displayFlex": true,
"flex-direction": "row",
"items": [
{
"key": "mission.regions[].region_id",
"notitle": true,
"placeholder": "Region Id"
},
{
"key": "mission.regions[].type",
"notitle": true,
"placeholder": "Type"
},
{
"key": "mission.regions[].params.noAutoPasses"
},
{
"key": "mission.regions[].params.twoPass",
"condition": "mission.regions[arrayIndex].params.noAutoPasses"
}
]
}
]
}, "mission.ordered", "stopBehaviour"]
"items": [
"cleanBehaviour",
"mission.pmap_id",
"mission.user_pmapv_id",
{
"key": "mission.regions",
"type": "array",
"notitle": true,
"items": [
{
"type": "div",
"displayFlex": true,
"flex-direction": "row",
"items": [
{
"key": "mission.regions[].region_id",
"notitle": true,
"placeholder": "Region Id"
},
{
"key": "mission.regions[].type",
"notitle": true,
"placeholder": "Type"
},
{
"key": "mission.regions[].params.noAutoPasses"
},
{
"key": "mission.regions[].params.twoPass",
"condition": "mission.regions[arrayIndex].params.noAutoPasses"
}
]
}
]
},
"mission.ordered",
"stopBehaviour"
]
},
{ "type": "section", "title": "Additional Options", "items": ["idleWatchInterval", "debug"] }
{
"type": "section",
"title": "Additional Options",
"items": [
"idleWatchInterval",
"debug"
]
}
]
}
}

0 comments on commit f2d7f9a

Please sign in to comment.