feat: optgroup dividers in unit dropdown, matching group order and visibility

This commit is contained in:
Falkan
2026-03-18 23:00:07 -04:00
parent a44551d4bc
commit 1dd2f0c5d3
3 changed files with 67 additions and 16 deletions

View File

@@ -98,13 +98,14 @@
"hidden": false
},
{
"id": "asdf",
"label": "asdf",
"labelPlural": "asdf",
"symbol": "asdf",
"group": "another-group",
"id": "mm",
"label": "millimeter",
"labelPlural": "millimeters",
"symbol": "mm",
"group": "lengths-and-distance",
"toBase": 1,
"hidden": true
"hidden": false,
"description": "It's so tiny and kawaii (♡‿♡)."
},
{
"id": "pound",
@@ -138,6 +139,14 @@
"symbol": "t",
"group": "dickloads",
"toBase": 76
},
{
"id": "cm",
"label": "centimeter",
"labelPlural": "centimeters",
"symbol": "cm",
"group": "lengths-and-distance",
"toBase": 10
}
],
"groups": [
@@ -151,12 +160,12 @@
"alwaysShowLabel": true
},
{
"id": "another-group",
"label": "Another Group",
"baseUnitId": "",
"id": "lengths-and-distance",
"label": "Lengths and Distance",
"baseUnitId": "mm",
"toUniversal": 1,
"alwaysShowLabel": false,
"hidden": true
"hidden": false
}
]
}