Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some minor fixes for the next release #614

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
d67b8dd
fix: texts details en & es
juanky201271 Mar 12, 2024
6c5875a
fix: the checkbox text needs a margin right
juanky201271 Mar 12, 2024
25c9fe1
fix: BS task only for Oreo 8.0 (SDK 26)
juanky201271 Mar 12, 2024
fafad6e
fix: stable zingolib updated & new yarn command for cargo update...
juanky201271 Mar 12, 2024
4d791bf
fix: snapshots updated
juanky201271 Mar 12, 2024
87ac6b3
fix: including support for portuguese
juanky201271 Mar 12, 2024
7baf008
fix: sync report block height until 10M
juanky201271 Mar 12, 2024
16c56d1
fix: basic mode disable color slightly bright
juanky201271 Mar 12, 2024
52d8e0f
fix: alert for new wallet when a wallet file exists - added
juanky201271 Dec 23, 2023
b7d4ee4
fix: reply to with the wallet's address - No red icon/warning
juanky201271 Mar 13, 2024
eb3d032
fix: menu items vertical margin bigger
juanky201271 Mar 13, 2024
50bcb5b
fix: Adding support for long Memos - Icon. Issue: #612
juanky201271 Mar 13, 2024
3093a57
fix: Android solution when the icon do nothing Applied
juanky201271 Mar 13, 2024
7b998db
fix: send fast-error controled & spendable is 0 -> can't send
juanky201271 Mar 13, 2024
d9eb6e5
fix: spendable is 0 -> can't send - a fix
juanky201271 Mar 13, 2024
f258e4e
fix: portugues translates added.
juanky201271 Mar 14, 2024
cc3b38f
fix: portugues adjustments
juanky201271 Mar 14, 2024
ca5916c
fix: new translation adjustments
juanky201271 Mar 14, 2024
9b49b29
fix: avaoid re-renders in send screen
juanky201271 Mar 14, 2024
ccbf0d9
fix: adjusting Memo new screen to IOS
juanky201271 Mar 14, 2024
d44f856
fix: more translations changes
juanky201271 Mar 14, 2024
bd918ec
fix: Android & IOS Test version 1.3.5 (154)
juanky201271 Mar 14, 2024
d492dec
fix: Android & IOS Test version 1.3.5 (155) & moment locale pt fixed
juanky201271 Mar 15, 2024
e430237
fix: pt version fixed
juanky201271 Mar 15, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const basicTheme: ThemeType = {
card: '#011401',
border: '#ffffff',
primary: '#0ef8f8', // new tron color
primaryDisabled: '#addcdc', // new tron color disable
primaryDisabled: '#a0dcdc', // new tron color disable
secondaryDisabled: '#233623',
text: '#c3c3c3',
zingo: '#888888',
Expand Down
4 changes: 4 additions & 0 deletions __tests__/History.TxDetail.unit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,10 @@ jest.mock('moment', () => {
jest.mock('moment/locale/es', () => () => ({
defineLocale: jest.fn(),
}));
jest.mock('moment/locale/pt', () => () => ({
defineLocale: jest.fn(),
}));

jest.mock('react-native-gesture-handler', () => {
const View = require('react-native').View;
return {
Expand Down
4 changes: 4 additions & 0 deletions __tests__/History.snapshot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ jest.mock('moment', () => {
jest.mock('moment/locale/es', () => () => ({
defineLocale: jest.fn(),
}));
jest.mock('moment/locale/pt', () => () => ({
defineLocale: jest.fn(),
}));

jest.mock('react-native-gesture-handler', () => {
const View = require('react-native').View;
return {
Expand Down
69 changes: 69 additions & 0 deletions __tests__/Memo.snapshot.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
/**
* @format
*/

import 'react-native';
import React from 'react';

import { render } from '@testing-library/react-native';
import Memo from '../components/Memo';
import { defaultAppStateLoaded, ContextAppLoadedProvider } from '../app/context';

jest.useFakeTimers();
jest.mock('@fortawesome/react-native-fontawesome', () => ({
FontAwesomeIcon: '',
}));
jest.mock('react-native-localize', () => ({
getNumberFormatSettings: () => {
return {
decimalSeparator: '.',
groupingSeparator: ',',
};
},
}));
jest.mock('react-native/Libraries/Animated/NativeAnimatedHelper');
jest.mock('react-native-reanimated', () => {
return class Reanimated {
public static Value() {
return jest.fn(() => {});
}
public static View() {
return '';
}
};
});
jest.mock('@react-native-community/netinfo', () => {
const RN = jest.requireActual('react-native');

RN.NativeModules.RNCNetInfo = {
execute: jest.fn(() => '{}'),
};

return RN;
});
jest.mock('react-native', () => {
const RN = jest.requireActual('react-native');

RN.NativeModules.RPCModule = {
execute: jest.fn(() => '{}'),
};

return RN;
});

// test suite
describe('Component Memo - test', () => {
//snapshot test
test('Memo - snapshot', () => {
const state = defaultAppStateLoaded;
state.translate = () => 'translated text';
state.sendPageState.toaddr.memo = 'memo1\nmemo2\nmemo3\nmemo4\nmemo5\nmemo6\nmemo7\nmemo8\nmemo9\nmemo10';
const onClose = jest.fn();
const memo = render(
<ContextAppLoadedProvider value={state}>
<Memo closeModal={onClose} updateToField={onClose} />
</ContextAppLoadedProvider>,
);
expect(memo.toJSON()).toMatchSnapshot();
});
});
4 changes: 4 additions & 0 deletions __tests__/Settings.snapshot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,10 @@ describe('Component Settings - test', () => {
value: 'es',
text: 'text es',
},
{
value: 'pt',
text: 'text pt',
},
];
}
if (p === 'settings.sendalls') {
Expand Down
1 change: 1 addition & 0 deletions __tests__/__snapshots__/ImportUfvk.snapshot.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ exports[`Component ImportUfvk - test ImportUfvk - snapshot 1`] = `
"fontWeight": "600",
"marginHorizontal": 5,
"minHeight": 100,
"textAlignVertical": "top",
}
}
value=""
Expand Down
209 changes: 209 additions & 0 deletions __tests__/__snapshots__/Memo.snapshot.tsx.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,209 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`Component Memo - test Memo - snapshot 1`] = `
<RCTSafeAreaView
style={
{
"alignItems": "stretch",
"backgroundColor": "rgb(242, 242, 242)",
"display": "flex",
"height": "100%",
"justifyContent": "flex-start",
}
}
>
<RCTScrollView
contentContainerStyle={
{
"alignItems": "stretch",
"flexDirection": "column",
"justifyContent": "flex-start",
"padding": 20,
}
}
style={
{
"maxHeight": "70%",
"minHeight": "70%",
}
}
>
<View>
<View
accessibilityLabel="translated text"
accessible={true}
style={
{
"borderColor": "rgb(28, 28, 30)",
"borderRadius": 5,
"borderWidth": 1,
"flexGrow": 1,
"maxHeight": 667,
"minHeight": 667,
"minWidth": 48,
}
}
>
<TextInput
editable={true}
multiline={true}
onChangeText={[Function]}
style={
{
"backgroundColor": "transparent",
"color": "rgb(28, 28, 30)",
"flex": 1,
"fontSize": 14,
"fontWeight": "600",
"margin": 5,
"minHeight": 48,
"minWidth": 48,
"textAlignVertical": "top",
}
}
testID="send.memo-field"
value="memo1
memo2
memo3
memo4
memo5
memo6
memo7
memo8
memo9
memo10"
/>
</View>
</View>
</RCTScrollView>
<View
style={
{
"alignItems": "center",
"flexDirection": "row",
"flexGrow": 1,
"justifyContent": "center",
"marginVertical": 5,
}
}
>
<View
accessible={true}
collapsable={false}
focusable={true}
onClick={[Function]}
onResponderGrant={[Function]}
onResponderMove={[Function]}
onResponderRelease={[Function]}
onResponderTerminate={[Function]}
onResponderTerminationRequest={[Function]}
onStartShouldSetResponder={[Function]}
style={
{
"alignItems": "center",
"backgroundColor": "rgb(0, 122, 255)",
"borderColor": "rgb(28, 28, 30)",
"borderRadius": 10,
"borderWidth": 2,
"justifyContent": "center",
"maxWidth": "90%",
"minHeight": 48,
"minWidth": "30%",
"opacity": 1,
"padding": 0,
"paddingLeft": 20,
"paddingRight": 20,
}
}
>
<View
style={
{
"alignItems": "center",
"display": "flex",
"flexDirection": "row",
"justifyContent": "center",
"margin": 0,
"minHeight": 48,
"minWidth": 48,
"padding": 0,
}
}
>
<Text
style={
{
"color": "rgb(242, 242, 242)",
"fontSize": 16,
"fontWeight": "bold",
"textAlign": "center",
"textTransform": "uppercase",
}
}
>
translated text
</Text>
</View>
</View>
<View
accessible={true}
collapsable={false}
focusable={true}
onClick={[Function]}
onResponderGrant={[Function]}
onResponderMove={[Function]}
onResponderRelease={[Function]}
onResponderTerminate={[Function]}
onResponderTerminationRequest={[Function]}
onStartShouldSetResponder={[Function]}
style={
{
"alignItems": "center",
"backgroundColor": "rgb(242, 242, 242)",
"borderColor": "rgb(0, 122, 255)",
"borderRadius": 10,
"borderWidth": 2,
"justifyContent": "center",
"marginLeft": 10,
"maxWidth": "90%",
"minHeight": 48,
"minWidth": "30%",
"opacity": 1,
"padding": 0,
"paddingLeft": 20,
"paddingRight": 20,
}
}
>
<View
style={
{
"alignItems": "center",
"display": "flex",
"flexDirection": "row",
"justifyContent": "center",
"margin": 0,
"minHeight": 48,
"minWidth": 48,
"padding": 0,
}
}
>
<Text
style={
{
"color": "rgb(0, 122, 255)",
"fontSize": 16,
"fontWeight": "bold",
"textAlign": "center",
"textTransform": "uppercase",
}
}
>
translated text
</Text>
</View>
</View>
</View>
</RCTSafeAreaView>
`;
1 change: 1 addition & 0 deletions __tests__/__snapshots__/Seed.snapshot.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -1017,6 +1017,7 @@ exports[`Component Seed - test Seed Restore - snapshot 1`] = `
"marginLeft": 5,
"minHeight": 100,
"minWidth": "95%",
"textAlignVertical": "top",
}
}
testID="seed.seedinput"
Expand Down
14 changes: 14 additions & 0 deletions __tests__/__snapshots__/Send.snapshot.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,13 @@ exports[`Component Send - test Send currency USD, privacy high & mode advanced -
transparent={false}
visible={false}
/>
<Modal
animationType="slide"
hardwareAccelerated={false}
onRequestClose={[Function]}
transparent={false}
visible={false}
/>
<RCTScrollView
contentContainerStyle={{}}
keyboardShouldPersistTaps="handled"
Expand Down Expand Up @@ -967,6 +974,13 @@ exports[`Component Send - test Send no currency, privacy normal & mode basic - s
transparent={false}
visible={false}
/>
<Modal
animationType="slide"
hardwareAccelerated={false}
onRequestClose={[Function]}
transparent={false}
visible={false}
/>
<RCTScrollView
contentContainerStyle={{}}
keyboardShouldPersistTaps="handled"
Expand Down
Loading
Loading