@widergy/mobile-ui 1.36.5 → 1.36.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
## [1.36.6](https://github.com/widergy/mobile-ui/compare/v1.36.5...v1.36.6) (2025-03-06)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* [UGENSA-1022] visual errors radio buttons ([#414](https://github.com/widergy/mobile-ui/issues/414)) ([5b81686](https://github.com/widergy/mobile-ui/commit/5b81686a83685a5aa817eb7e312a319c7ebac43e))
|
|
7
|
+
|
|
1
8
|
## [1.36.5](https://github.com/widergy/mobile-ui/compare/v1.36.4...v1.36.5) (2025-02-25)
|
|
2
9
|
|
|
3
10
|
|
|
@@ -28,6 +28,7 @@ class RadioButton extends Component {
|
|
|
28
28
|
sublabel,
|
|
29
29
|
theme,
|
|
30
30
|
labelComponent,
|
|
31
|
+
labelContainerStyles = { title: {}, subtitle: {} },
|
|
31
32
|
descriptionComponent,
|
|
32
33
|
showSeparatorBar,
|
|
33
34
|
disabled
|
|
@@ -52,17 +53,27 @@ class RadioButton extends Component {
|
|
|
52
53
|
name={status ? RADIO_CHECKED_ICON : RADIO_UNCHECKED_ICON}
|
|
53
54
|
color={status ? theme.colors.primary : theme.colors.disabled}
|
|
54
55
|
style={styles.iconSpacing}
|
|
56
|
+
size={20}
|
|
55
57
|
/>
|
|
56
58
|
<View style={styles.labelsContainer}>
|
|
57
59
|
<View>
|
|
58
60
|
<View style={[styles.label, labelComponent && styles.labelComponent]}>
|
|
59
|
-
<UTLabel
|
|
61
|
+
<UTLabel
|
|
62
|
+
variant="xsmall"
|
|
63
|
+
weight={status ? 'bold' : 'regular'}
|
|
64
|
+
{...labelContainerStyles.title}
|
|
65
|
+
>
|
|
60
66
|
{label}
|
|
61
67
|
</UTLabel>
|
|
62
68
|
{labelComponent}
|
|
63
69
|
</View>
|
|
64
70
|
{(sublabel || sublabel === 0) && (
|
|
65
|
-
<UTLabel
|
|
71
|
+
<UTLabel
|
|
72
|
+
colorTheme="gray"
|
|
73
|
+
variant="xsmall"
|
|
74
|
+
weight={status ? 'bold' : 'regular'}
|
|
75
|
+
{...labelContainerStyles.subtitle}
|
|
76
|
+
>
|
|
66
77
|
{sublabel}
|
|
67
78
|
</UTLabel>
|
|
68
79
|
)}
|
|
@@ -100,6 +111,10 @@ RadioButton.propTypes = {
|
|
|
100
111
|
}),
|
|
101
112
|
theme: themeType,
|
|
102
113
|
labelComponent: PropTypes.node,
|
|
114
|
+
labelContainerStyles: PropTypes.shape({
|
|
115
|
+
title: PropTypes.object,
|
|
116
|
+
subtitle: PropTypes.object
|
|
117
|
+
}),
|
|
103
118
|
descriptionComponent: PropTypes.node,
|
|
104
119
|
showSeparatorBar: PropTypes.bool,
|
|
105
120
|
disabled: PropTypes.bool
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { StyleSheet } from 'react-native';
|
|
2
2
|
|
|
3
|
-
import { verticalScale
|
|
3
|
+
import { verticalScale } from '../../../../utils/scaleUtils';
|
|
4
4
|
|
|
5
5
|
export default StyleSheet.create({
|
|
6
6
|
container: {
|
|
@@ -10,12 +10,13 @@ export default StyleSheet.create({
|
|
|
10
10
|
width: '95%'
|
|
11
11
|
},
|
|
12
12
|
iconSpacing: {
|
|
13
|
-
|
|
13
|
+
margin: 6
|
|
14
14
|
},
|
|
15
15
|
labelsContainer: {
|
|
16
16
|
flex: 1,
|
|
17
17
|
flexDirection: 'row',
|
|
18
|
-
justifyContent: 'space-between'
|
|
18
|
+
justifyContent: 'space-between',
|
|
19
|
+
marginLeft: 16
|
|
19
20
|
},
|
|
20
21
|
label: {
|
|
21
22
|
flexDirection: 'row',
|
|
@@ -40,9 +40,11 @@ class RadioGroup extends Component {
|
|
|
40
40
|
return (
|
|
41
41
|
<View style={styles.container}>
|
|
42
42
|
{title && (
|
|
43
|
-
<
|
|
44
|
-
{
|
|
45
|
-
|
|
43
|
+
<View style={styles.titleContainer}>
|
|
44
|
+
<UTLabel variant="medium" {...titleProps}>
|
|
45
|
+
{title}
|
|
46
|
+
</UTLabel>
|
|
47
|
+
</View>
|
|
46
48
|
)}
|
|
47
49
|
{options.map(this.renderOptions)}
|
|
48
50
|
<UTLabel colorTheme="error" shade="05" variant="body">
|
|
@@ -68,11 +70,15 @@ RadioGroup.propTypes = {
|
|
|
68
70
|
selectedOption: PropTypes.string,
|
|
69
71
|
radioProps: PropTypes.shape({
|
|
70
72
|
label: PropTypes.string,
|
|
71
|
-
|
|
73
|
+
labelContainerStyles: PropTypes.shape({
|
|
74
|
+
title: PropTypes.object,
|
|
75
|
+
subtitle: PropTypes.object
|
|
76
|
+
}),
|
|
77
|
+
leftButton: PropTypes.bool,
|
|
72
78
|
onPress: PropTypes.func,
|
|
73
79
|
status: PropTypes.bool,
|
|
74
80
|
style: ViewPropTypes.style,
|
|
75
|
-
|
|
81
|
+
sublabel: PropTypes.string
|
|
76
82
|
}),
|
|
77
83
|
titleProps: PropTypes.instanceOf(Object),
|
|
78
84
|
keyField: PropTypes.string,
|
package/package.json
CHANGED