Skip to content

Commit

Permalink
Merge pull request #2196 from myxmaster/harmonize-back-icons
Browse files Browse the repository at this point in the history
Harmonize back icons
  • Loading branch information
kaloudis authored May 22, 2024
2 parents 6416503 + 81760c4 commit d286c2c
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 19 deletions.
22 changes: 14 additions & 8 deletions views/POS/ProductCategoryDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import ProductCategory from '../../models/ProductCategory';
import InventoryStore from '../../stores/InventoryStore';
import { inject, observer } from 'mobx-react';
import { v4 as uuidv4 } from 'uuid';
import { Divider, Icon } from 'react-native-elements';
import { Divider } from 'react-native-elements';
import { Route } from '@react-navigation/native';
import { StackNavigationProp } from '@react-navigation/stack';

Expand All @@ -24,9 +24,11 @@ import TextInput from '../../components/TextInput';
import { themeColor } from '../../utils/ThemeUtils';
import { localeString } from '../../utils/LocaleUtils';

import DeleteIcon from '../../assets/images/SVG/Delete.svg';
import PosStore from '../../stores/PosStore';

import ArrowLeft from '../../assets/images/SVG/Arrow_left.svg';
import DeleteIcon from '../../assets/images/SVG/Delete.svg';

interface ProductCategoryProps {
navigation: StackNavigationProp<any, any>;
InventoryStore: InventoryStore;
Expand Down Expand Up @@ -157,13 +159,17 @@ export default class ProductCategoryDetails extends React.Component<
const { navigation } = this.props;

const BackButton = () => (
<Icon
name="arrow-back"
<TouchableOpacity
onPress={() => navigation.goBack()}
color={themeColor('text')}
underlayColor="transparent"
size={35}
/>
accessibilityLabel={localeString('general.goBack')}
>
<ArrowLeft
fill={themeColor('text')}
width="30"
height="30"
style={{ alignSelf: 'center' }}
/>
</TouchableOpacity>
);

const Delete = () => (
Expand Down
30 changes: 19 additions & 11 deletions views/Settings/LightningAddress/NostrRelays.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import * as React from 'react';
import { FlatList, ScrollView, View } from 'react-native';
import { Icon } from 'react-native-elements';
import { FlatList, ScrollView, TouchableOpacity, View } from 'react-native';
import { inject, observer } from 'mobx-react';
import { schnorr } from '@noble/curves/secp256k1';
import { bytesToHex } from '@noble/hashes/utils';
Expand All @@ -24,6 +23,8 @@ import LightningAddressStore from '../../../stores/LightningAddressStore';
import { localeString } from '../../../utils/LocaleUtils';
import { themeColor } from '../../../utils/ThemeUtils';

import ArrowLeft from '../../../assets/images/SVG/Arrow_left.svg';

interface NostrRelaysProps {
navigation: StackNavigationProp<any, any>;
SettingsStore: SettingsStore;
Expand Down Expand Up @@ -91,17 +92,23 @@ export default class NostrRelays extends React.Component<
<Header
leftComponent={
setup ? (
<Icon
name="arrow-back"
onPress={() => {
<TouchableOpacity
onPress={() =>
navigation.popTo('LightningAddress', {
relays
});
}}
color={themeColor('text')}
underlayColor="transparent"
size={35}
/>
})
}
accessibilityLabel={localeString(
'general.goBack'
)}
>
<ArrowLeft
fill={themeColor('text')}
width="30"
height="30"
style={{ alignSelf: 'center' }}
/>
</TouchableOpacity>
) : (
'Back'
)
Expand Down Expand Up @@ -314,6 +321,7 @@ export default class NostrRelays extends React.Component<
`${item.txid}-${index}`
}
onEndReachedThreshold={50}
scrollEnabled={false}
/>
) : (
<Text
Expand Down

0 comments on commit d286c2c

Please sign in to comment.