on master help sign in
Fix flashing of single point in family view.

Change loading indicator to show if the redirect has not been run yet. Return early from the component to do this, because we may have a loaded point that we do not want to display

commitf8bccab3229341a2a6657edd71b108bb38e7f6c0 authorLiam Fitzgerald <hastuc-dibtux@gmail.com> dateTue 29 Oct 2019, 07:20 (7 years ago) parent722f6c2
1 file changed+17−6
src/views/Points.js+17−6
src/views/Points.js+17−6
@@ -206,6 +206,23 @@ export default function Points() {
206206 push,
207207 ]);
208208
209+ if (
210+ loading ||
211+ (allPoints.length === 1 &&
212+ ownedPoints.length === 1 &&
213+ outgoingPoints.length === 0)
214+ ) {
215+ return (
216+ <View inset pop={pop}>
217+ <Grid>
218+ <Grid.Item full as={HelpText} className="mt8 t-center">
219+ <Blinky /> Loading...
220+ </Grid.Item>
221+ </Grid>
222+ </View>
223+ );
224+ }
225+
209226 return (
210227 <View pop={pop} inset>
211228 <Grid>
@@ -215,12 +232,6 @@ export default function Points() {
215232 </CopiableAddress>
216233 </Grid.Item>
217234
218− {loading && (
219− <Grid.Item full as={HelpText} className="mt8 t-center">
220− <Blinky /> Loading...
221− </Grid.Item>
222− )}
223−
224235 {displayEmptyState && (
225236 <Grid.Item full as={HelpText} className="mt8 t-center">
226237 No points to display. This wallet is not the owner or proxy for any