|
1 | 1 | import React, {useMemo} from 'react'; |
2 | 2 | import {View} from 'react-native'; |
3 | 3 | import InteractiveStepSubHeader from '@components/InteractiveStepSubHeader'; |
4 | | -import SelectionList from '@components/SelectionListWithSections'; |
5 | | -import RadioListItem from '@components/SelectionListWithSections/RadioListItem'; |
| 4 | +import SelectionList from '@components/SelectionList'; |
| 5 | +import RadioListItem from '@components/SelectionList/ListItem/RadioListItem'; |
6 | 6 | import Text from '@components/Text'; |
7 | 7 | import useLocalize from '@hooks/useLocalize'; |
8 | 8 | import useThemeStyles from '@hooks/useThemeStyles'; |
@@ -46,11 +46,11 @@ function ReviewFields<K extends keyof ReviewDuplicates>({stepNames, label, optio |
46 | 46 | return falsyCount <= 1; |
47 | 47 | }); |
48 | 48 |
|
49 | | - const sections = useMemo( |
| 49 | + const optionRows = useMemo( |
50 | 50 | () => |
51 | | - filteredOptions?.map((option) => ({ |
| 51 | + filteredOptions?.map((option, idx) => ({ |
52 | 52 | text: option.text, |
53 | | - keyForList: option.text, |
| 53 | + keyForList: `${option.text}-${idx}`, |
54 | 54 | value: option.value, |
55 | 55 | })), |
56 | 56 | [filteredOptions], |
@@ -78,7 +78,7 @@ function ReviewFields<K extends keyof ReviewDuplicates>({stepNames, label, optio |
78 | 78 | {label} |
79 | 79 | </Text> |
80 | 80 | <SelectionList |
81 | | - sections={[{data: sections ?? []}]} |
| 81 | + data={optionRows ?? []} |
82 | 82 | ListItem={RadioListItem} |
83 | 83 | onSelectRow={onSelectRow} |
84 | 84 | /> |
|
0 commit comments