feat(web/context): allow manually sorting the options

In order to have the options in the same order as defined, you need to not use keys, instead a normal index table and define the title for the option
This commit is contained in:
Luke
2022-05-08 13:00:19 +02:00
parent 1080efb0cf
commit 62d4812f24
3 changed files with 21 additions and 24 deletions

View File

@@ -68,7 +68,7 @@ const Item: React.FC<{
<Box>
<Box paddingBottom={option[1].description ? 1 : 0}>
<Text w="100%" fontWeight="medium">
{option[0]}
{option[1].title ? option[1].title : option[0]}
</Text>
</Box>
{option[1].description && (