@widergy/utilitygo-smart-bill-mobile 3.6.1 → 3.7.0
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,15 @@
|
|
|
1
|
+
# [3.7.0](https://github.com/widergy/UtilityGO-Smart-Bill-Mobile/compare/v3.6.1...v3.7.0) (2026-01-27)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* dependency ([#62](https://github.com/widergy/UtilityGO-Smart-Bill-Mobile/issues/62)) ([c853ee6](https://github.com/widergy/UtilityGO-Smart-Bill-Mobile/commit/c853ee66679e805f45f31082adc12ce61fe87b94))
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* [EVEP-356] new button in ratecard ([#61](https://github.com/widergy/UtilityGO-Smart-Bill-Mobile/issues/61)) ([8802ecc](https://github.com/widergy/UtilityGO-Smart-Bill-Mobile/commit/8802ecc5ed5cd49a24fea8c2fb229c6e975a717b))
|
|
12
|
+
|
|
1
13
|
## [3.6.1](https://github.com/widergy/UtilityGO-Smart-Bill-Mobile/compare/v3.6.0...v3.6.1) (2026-01-14)
|
|
2
14
|
|
|
3
15
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@widergy/utilitygo-smart-bill-mobile",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.7.0",
|
|
4
4
|
"description": "UtilityGO SmartBill Mobile",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"main": "src/lib/index.js",
|
|
@@ -83,6 +83,7 @@
|
|
|
83
83
|
"extends": "@widergy/semantic-release-package-config"
|
|
84
84
|
},
|
|
85
85
|
"resolutions": {
|
|
86
|
-
"minimatch": "^9.0.3"
|
|
86
|
+
"minimatch": "^9.0.3",
|
|
87
|
+
"mixpanel-browser": "2.50.0"
|
|
87
88
|
}
|
|
88
89
|
}
|
|
@@ -24,6 +24,7 @@ const RateCard = ({
|
|
|
24
24
|
normalizedRate = '',
|
|
25
25
|
rateCardTranslations = {},
|
|
26
26
|
ratesTableLink,
|
|
27
|
+
seeBillLink,
|
|
27
28
|
smartBill = {},
|
|
28
29
|
subsidy = '',
|
|
29
30
|
subsidyLevels,
|
|
@@ -35,6 +36,7 @@ const RateCard = ({
|
|
|
35
36
|
helpText,
|
|
36
37
|
limitRateValueLabel,
|
|
37
38
|
seeRatesTable,
|
|
39
|
+
seeBill,
|
|
38
40
|
startRateValueLabel,
|
|
39
41
|
title,
|
|
40
42
|
tooltipContent,
|
|
@@ -64,10 +66,17 @@ const RateCard = ({
|
|
|
64
66
|
const noLevels = isEmpty(consumptionLevels);
|
|
65
67
|
const showRateLabel = !isT1 || startRateValue === false || limitRateValue === false;
|
|
66
68
|
|
|
69
|
+
const externalLinks = [
|
|
70
|
+
{ link: ratesTableLink, label: seeRatesTable },
|
|
71
|
+
{ link: seeBillLink, label: seeBill }
|
|
72
|
+
].filter(({ link, label }) => link && label);
|
|
73
|
+
|
|
67
74
|
const debouncedTrackRedirection = useMemo(
|
|
68
75
|
() =>
|
|
69
76
|
debounce(link => {
|
|
70
|
-
trackRedirectionToExternalLink
|
|
77
|
+
if (trackRedirectionToExternalLink && typeof trackRedirectionToExternalLink === 'function') {
|
|
78
|
+
trackRedirectionToExternalLink(link);
|
|
79
|
+
}
|
|
71
80
|
}, 300),
|
|
72
81
|
[trackRedirectionToExternalLink]
|
|
73
82
|
);
|
|
@@ -78,9 +87,9 @@ const RateCard = ({
|
|
|
78
87
|
};
|
|
79
88
|
}, [debouncedTrackRedirection]);
|
|
80
89
|
|
|
81
|
-
const openExternalLink =
|
|
82
|
-
debouncedTrackRedirection(
|
|
83
|
-
|
|
90
|
+
const openExternalLink = link => {
|
|
91
|
+
debouncedTrackRedirection(link);
|
|
92
|
+
Linking.openURL(link);
|
|
84
93
|
};
|
|
85
94
|
|
|
86
95
|
return (
|
|
@@ -143,21 +152,26 @@ const RateCard = ({
|
|
|
143
152
|
))}
|
|
144
153
|
|
|
145
154
|
<View style={styles.footerAction}>
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
155
|
+
{externalLinks.map(({ link, label }, index) => (
|
|
156
|
+
<React.Fragment key={link}>
|
|
157
|
+
<UTButton
|
|
158
|
+
colorTheme="secondary"
|
|
159
|
+
Icon="IconChevronRight"
|
|
160
|
+
iconPlacement="right"
|
|
161
|
+
onPress={() => openExternalLink(link)}
|
|
162
|
+
style={{
|
|
163
|
+
root: styles.footerActionRoot,
|
|
164
|
+
childrenContainer: styles.footerActionChildren,
|
|
165
|
+
icon: styles.icon
|
|
166
|
+
}}
|
|
167
|
+
variant="text">
|
|
168
|
+
<UTLabel colorTheme="neutral" weight="medium">
|
|
169
|
+
{label}
|
|
170
|
+
</UTLabel>
|
|
171
|
+
</UTButton>
|
|
172
|
+
{index < externalLinks.length - 1 && <View style={styles.divider} />}
|
|
173
|
+
</React.Fragment>
|
|
174
|
+
))}
|
|
161
175
|
</View>
|
|
162
176
|
</View>
|
|
163
177
|
</Surface>
|
|
@@ -172,6 +186,7 @@ RateCard.propTypes = {
|
|
|
172
186
|
normalizedRate: string,
|
|
173
187
|
rateCardTranslations: object,
|
|
174
188
|
ratesTableLink: string,
|
|
189
|
+
seeBillLink: string,
|
|
175
190
|
smartBill: object,
|
|
176
191
|
subsidy: string,
|
|
177
192
|
subsidyLevels: objectOf(string),
|
|
@@ -36,9 +36,8 @@ export const createStyles = colors =>
|
|
|
36
36
|
backgroundColor: 'transparent',
|
|
37
37
|
borderTopWidth: 1,
|
|
38
38
|
borderTopColor: colors.light04,
|
|
39
|
-
flexDirection: '
|
|
40
|
-
justifyContent: 'space-between'
|
|
41
|
-
gap: 8
|
|
39
|
+
flexDirection: 'column',
|
|
40
|
+
justifyContent: 'space-between'
|
|
42
41
|
},
|
|
43
42
|
detail: {
|
|
44
43
|
alignItems: 'center',
|
|
@@ -61,5 +60,10 @@ export const createStyles = colors =>
|
|
|
61
60
|
alignItems: 'center',
|
|
62
61
|
justifyContent: 'space-between',
|
|
63
62
|
paddingVertical: 8
|
|
63
|
+
},
|
|
64
|
+
divider: {
|
|
65
|
+
backgroundColor: colors.light04,
|
|
66
|
+
width: '100%',
|
|
67
|
+
height: 1
|
|
64
68
|
}
|
|
65
69
|
});
|