Skip to content

Commit

Permalink
ux: bug fix: mobile app crashing when opening Connections
Browse files Browse the repository at this point in the history
  • Loading branch information
achou11 authored and staltz committed Oct 6, 2023
1 parent ae7367f commit 2b26f1b
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/frontend/components/FloatingActionButton.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ const FIXED_PROPS: IFloatingActionProps = {
iconHeight: Dimensions.iconSizeNormal,
iconWidth: Dimensions.iconSizeNormal,
overlayColor: Palette.transparencyDark,
overrideWithAction: true,
};

export interface Props
Expand Down
1 change: 1 addition & 0 deletions src/frontend/screens/central/connections-tab/fab.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ export default function floatingAction(): Stream<FabProps> {
color: Palette.backgroundCTA,
visible: false,
actions: [],
overrideWithAction: false,
title: t('connections.floating_action_button.add_connection'),
distanceToEdge: {
vertical: FAB_VERTICAL_DISTANCE_TO_EDGE,
Expand Down
1 change: 1 addition & 0 deletions src/frontend/screens/central/private-tab/fab.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ export default function floatingAction(
text: t('private.floating_action_button.compose'),
},
],
overrideWithAction: true,
title: t('private.floating_action_button.compose'),
distanceToEdge: {
vertical: FAB_VERTICAL_DISTANCE_TO_EDGE,
Expand Down
1 change: 1 addition & 0 deletions src/frontend/screens/central/public-tab/fab.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ export default function floatingAction(
text: t('public.floating_action_button.compose'),
},
],
overrideWithAction: true,
title: t('profile.floating_action_button.compose'),
distanceToEdge: {
vertical: FAB_VERTICAL_DISTANCE_TO_EDGE,
Expand Down
6 changes: 6 additions & 0 deletions src/frontend/screens/connections-panel/view/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import dropRepeatsByKeys from 'xstream-drop-repeats-by-keys';
import {h} from '@cycle/react';
import {Platform, ScrollView, View} from 'react-native';
import {t} from '~frontend/drivers/localization';
import {Dimensions} from '~frontend/global-styles/dimens';
import {Palette} from '~frontend/global-styles/palette';
import {Images} from '~frontend/global-styles/images';
import TopBar from '~frontend/components/TopBar';
Expand Down Expand Up @@ -37,6 +38,11 @@ function getFABProps(state: State): FabProps {
text: t('connections.floating_action_button.paste_invite'),
},
],
overrideWithAction: true,
distanceToEdge: {
vertical: Dimensions.verticalSpaceLarge,
horizontal: Dimensions.horizontalSpaceBig,
},
title: t('connections.floating_action_button.add_connection'),
floatingIcon: Images.plusNetwork,
};
Expand Down
1 change: 1 addition & 0 deletions src/frontend/screens/profile/view/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ export default function view(state$: Stream<State>, ssbSource: SSBSource) {
text: t('profile.floating_action_button.compose'),
},
],
overrideWithAction: true,
distanceToEdge:
Platform.OS === 'web'
? {
Expand Down
1 change: 1 addition & 0 deletions src/frontend/screens/search/fab.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ export function floatingAction(state$: Stream<State>): Stream<FabProps> {
text: t('public.floating_action_button.compose'),
},
],
overrideWithAction: true,
title: t('profile.floating_action_button.compose'),
}),
);
Expand Down

0 comments on commit 2b26f1b

Please sign in to comment.