refactor: sensor configuration fields
Automatically round decimal values for sensor.x and .y to an integer. Make fields optional which are not used in every sensor.
This commit is contained in:
@@ -25,41 +25,30 @@ The background image and sensor definitions are taken from the default system pa
|
||||
"sensor": [
|
||||
{
|
||||
"mode": 3,
|
||||
"type": 2,
|
||||
"name": "SSD 4 usage",
|
||||
"label": "storage_ssd4_usage",
|
||||
"x": 400,
|
||||
"y": 45,
|
||||
"direction": 1,
|
||||
"value": "35",
|
||||
"fontFamily": "HarmonyOS_Sans_SC_Bold",
|
||||
"fontSize": 24,
|
||||
"fontColor": -1,
|
||||
"textAlign": "center",
|
||||
"minValue": 0,
|
||||
"maxValue": 100,
|
||||
"pic": "progress.png"
|
||||
},
|
||||
{
|
||||
"mode": 3,
|
||||
"type": 2,
|
||||
"name": "SSD 5 usage",
|
||||
"label": "storage_ssd5_usage",
|
||||
"x": 400,
|
||||
"y": 106,
|
||||
"direction": 1,
|
||||
"value": "80",
|
||||
"fontFamily": "HarmonyOS_Sans_SC_Bold",
|
||||
"fontSize": 24,
|
||||
"fontColor": -1,
|
||||
"textAlign": "center",
|
||||
"minValue": 0,
|
||||
"maxValue": 100,
|
||||
"pic": "progress.png"
|
||||
},
|
||||
{
|
||||
"mode": 1,
|
||||
"type": 2,
|
||||
"name": "SSD 4 temp",
|
||||
"label": "storage_ssd4_temperature",
|
||||
"x": 580,
|
||||
@@ -68,7 +57,6 @@ The background image and sensor definitions are taken from the default system pa
|
||||
"value": "34",
|
||||
"fontFamily": "HarmonyOS_Sans_SC_Bold",
|
||||
"fontSize": 24,
|
||||
"fontColor": -1,
|
||||
"textAlign": "center",
|
||||
"integerDigits": -1,
|
||||
"decimalDigits": 0,
|
||||
@@ -76,7 +64,6 @@ The background image and sensor definitions are taken from the default system pa
|
||||
},
|
||||
{
|
||||
"mode": 1,
|
||||
"type": 2,
|
||||
"name": "SSD 5 temp",
|
||||
"label": "storage_ssd5_temperature",
|
||||
"x": 580,
|
||||
@@ -85,7 +72,6 @@ The background image and sensor definitions are taken from the default system pa
|
||||
"value": "35",
|
||||
"fontFamily": "HarmonyOS_Sans_SC_Bold",
|
||||
"fontSize": 24,
|
||||
"fontColor": -1,
|
||||
"textAlign": "center",
|
||||
"integerDigits": -1,
|
||||
"decimalDigits": 0,
|
||||
|
||||
Reference in New Issue
Block a user