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

Safe communication #761

Draft
wants to merge 57 commits into
base: dev
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
ff758da
Merge branch 'zingolabs:dev' into dev_safe_communication
juanky201271 Dec 6, 2024
2ca49d7
fix: shrinking header
juanky201271 Dec 8, 2024
73e0637
Merge branch 'zingolabs:dev' into dev_safe_communication
juanky201271 Dec 9, 2024
6cc5ad6
fix: header fixes
juanky201271 Dec 10, 2024
d7ba169
fix: $ amount format fixed
juanky201271 Dec 10, 2024
360b8b4
fix: close screen arrow in header
juanky201271 Dec 10, 2024
4e13deb
Merge branch 'zingolabs:dev' into dev_safe_communication
juanky201271 Dec 11, 2024
d6dc7ce
fix: removing close & cancel buttons -> replaced them by the left arr…
juanky201271 Dec 11, 2024
5561abd
fix: removing close & cancel button if needed
juanky201271 Dec 11, 2024
428a90f
fix: adjusting header close icon
juanky201271 Dec 11, 2024
347e22d
fix: remove primary button border
juanky201271 Dec 11, 2024
0571b65
fix: buttons width enlarged
juanky201271 Dec 11, 2024
cbbdeb6
fix: make all texts selectable
juanky201271 Dec 11, 2024
bdd61b4
fix: swipe icons with background
juanky201271 Dec 12, 2024
d58b0bb
fix: text selectable adjustments
juanky201271 Dec 12, 2024
d6be30d
fix: remove Reply to + UA in messages
juanky201271 Dec 12, 2024
3f3ff46
fix: new components contact list & line
juanky201271 Dec 14, 2024
463f926
fix: adding two initials to contact icon
juanky201271 Dec 14, 2024
56e2ceb
fix: first approach to create Chats
juanky201271 Dec 17, 2024
0e2dddc
fix: working on it
juanky201271 Dec 18, 2024
0b2e7e9
fix: links to All & Anonymous Messages added
juanky201271 Dec 18, 2024
f35660a
fix: header title fixed
juanky201271 Dec 18, 2024
e7b388b
fix: a few adjustments
juanky201271 Dec 19, 2024
91e4903
fix: all screen reviewed about buttons
juanky201271 Dec 19, 2024
d93dcd5
fix: formatting code
juanky201271 Dec 19, 2024
866fb39
fix: send header with keyboard fixed
juanky201271 Dec 19, 2024
32f193a
fix: title chats added
juanky201271 Dec 19, 2024
1c72a1b
fix: resizing messages field w/wo keyboard
juanky201271 Dec 20, 2024
486090b
fix: horizontal scroll fixed
juanky201271 Dec 20, 2024
768a1c8
fix: keyboard hidding issue fixed
juanky201271 Dec 21, 2024
d260e65
fix: paper plane icon unified & bittons horizontal scroll fixed
juanky201271 Dec 22, 2024
b8388c7
fix: selectable prop changed
juanky201271 Dec 22, 2024
b42ff39
fix: selectable prop only for memos/messages
juanky201271 Dec 22, 2024
812c83d
fix: a couple of adjustments
juanky201271 Dec 22, 2024
42580fe
fix: New test version 1.11.0 (206) - Communicator
juanky201271 Dec 23, 2024
3aabca0
fix: component renamed for coherence
juanky201271 Dec 23, 2024
2221c0a
fix: android messages/memo fixes
juanky201271 Dec 23, 2024
344e37a
fix: snapshots updated
juanky201271 Dec 23, 2024
0090474
fix: IOS adjustments
juanky201271 Dec 23, 2024
0ee936b
fix: Android adjustments
juanky201271 Dec 23, 2024
93c7d74
fix: send anim header issue fixed
juanky201271 Dec 24, 2024
e1fc5ef
fix: spinner fixed for IOS
juanky201271 Dec 24, 2024
540ae9a
fix: code formatting
juanky201271 Dec 24, 2024
0104de6
fix: IOS fixes
juanky201271 Dec 24, 2024
045bffa
fix: New test version 1.11.0 (207) - Communicator
juanky201271 Dec 24, 2024
b72dcb4
fix: code formatted
juanky201271 Dec 24, 2024
b07bd00
fix: no messaging with no spendable funds
juanky201271 Dec 26, 2024
d7aa5dc
fix: new test version 1.11.0 (208) - Communicator
juanky201271 Dec 26, 2024
231a36f
fix: messages item address fixed
juanky201271 Dec 27, 2024
dd44721
Merge branch 'dev_safe_communication' of https://github.com/juanky201…
juanky201271 Dec 27, 2024
3f5bb7b
fix: sync pause icon removed - too confusing
juanky201271 Jan 13, 2025
627d13d
fix: app status text added in the header
juanky201271 Jan 13, 2025
138467e
fix: adding all the contacts in chats
juanky201271 Jan 13, 2025
649447e
fix: exclude chats from contacts with t addrs
juanky201271 Jan 14, 2025
a33fb2d
fix: textinput adjustments IOS
juanky201271 Jan 14, 2025
79a943c
fix: snapshots updated
juanky201271 Jan 14, 2025
c7bd70e
fix: translations fix
juanky201271 Jan 15, 2025
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
19 changes: 6 additions & 13 deletions __tests__/Components.unit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,48 +32,42 @@ describe('Component Components - test', () => {
<CurrencyAmount price={2.9826} amtZec={1.00098} style={{}} currency={CurrencyEnum.USDCurrency} privacy={true} />,
).toJSON();
expect(text.type).toBe('View');
expect(text.children[0].children[0].children[0].children[0]).toBe('$');
expect(text.children[0].children[0].children[1].children[0]).toBe(' -.--');
expect(text.children[0].children[0].children[0].children[0]).toBe('$ -.--');
});
test('CurrencyAmount - price undefined result $ -- USD', () => {
const text: any = render(<CurrencyAmount amtZec={1} style={{}} currency={CurrencyEnum.USDCurrency} />).toJSON();
expect(text.type).toBe('View');
expect(text.children[0].children[0].children[0].children[0]).toBe('$');
expect(text.children[0].children[0].children[1].children[0]).toBe(' -.--');
expect(text.children[0].children[0].children[0].children[0]).toBe('$ -.--');
});

test('CurrencyAmount - price 0 result $ -- USD', () => {
const text: any = render(
<CurrencyAmount price={0} amtZec={1} style={{}} currency={CurrencyEnum.USDCurrency} />,
).toJSON();
expect(text.type).toBe('View');
expect(text.children[0].children[0].children[0].children[0]).toBe('$');
expect(text.children[0].children[0].children[1].children[0]).toBe(' -.--');
expect(text.children[0].children[0].children[0].children[0]).toBe('$ -.--');
});

test('CurrencyAmount - amtZec undefined result $ -- USD', () => {
const text: any = render(<CurrencyAmount price={1} style={{}} currency={CurrencyEnum.USDCurrency} />).toJSON();
expect(text.type).toBe('View');
expect(text.children[0].children[0].children[0].children[0]).toBe('$');
expect(text.children[0].children[0].children[1].children[0]).toBe(' -.--');
expect(text.children[0].children[0].children[0].children[0]).toBe('$ -.--');
});

test('CurrencyAmount - price * amtZec really tiny result $ < 0.01 USD', () => {
const text: any = render(
<CurrencyAmount price={0.001} amtZec={1} style={{}} currency={CurrencyEnum.USDCurrency} />,
).toJSON();
expect(text.type).toBe('View');
expect(text.children[0].children[0].children[0].children[0]).toBe('$');
expect(text.children[0].children[0].children[1].children[0]).toBe(' < 0.01');
expect(text.children[0].children[0].children[0].children[0]).toBe('$ < 0.01');
});

test('CurrencyAmount - price=2.9826 and amtZec=1.00098 result $ 2.99 USD', () => {
const text: any = render(
<CurrencyAmount price={2.9826} amtZec={1.00098} style={{}} currency={CurrencyEnum.USDCurrency} />,
).toJSON();
expect(text.type).toBe('View');
expect(text.children[0].children[0].children[0].children[0]).toBe('$');
expect(text.children[0].children[0].children[1].children[0]).toBe(' 2.99');
expect(text.children[0].children[0].children[0].children[0]).toBe('$ 2.99');
});

test("CurrencyAmount - style={backgroundColor: 'red'} result same", () => {
Expand All @@ -87,7 +81,6 @@ describe('Component Components - test', () => {
).toJSON();
expect(text.type).toBe('View');
expect(text.children[0].children[0].children[0].props.style.backgroundColor).toBe('red');
expect(text.children[0].children[0].children[1].props.style.backgroundColor).toBe('red');
});

test('ZecAmount - High Privacy - amtZec -1.123456789 rounded up result -.---- ZEC', () => {
Expand Down
6 changes: 6 additions & 0 deletions __tests__/History.snapshot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,9 @@ describe('Component History - test', () => {
scrollToTop={false}
setScrollToBottom={onFunction}
scrollToBottom={false}
sendTransaction={onFunction}
clearToAddr={onFunction}
setServerOption={onFunction}
/>
</ContextAppLoadedProvider>,
);
Expand Down Expand Up @@ -175,6 +178,9 @@ describe('Component History - test', () => {
scrollToTop={false}
setScrollToBottom={onFunction}
scrollToBottom={false}
sendTransaction={onFunction}
clearToAddr={onFunction}
setServerOption={onFunction}
/>
</ContextAppLoadedProvider>,
);
Expand Down
2 changes: 1 addition & 1 deletion __tests__/Info.es.unit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,6 @@ describe('Component Info - test', () => {
<Info closeModal={onClose} setZecPrice={onSet} />
</ContextAppLoadedProvider>,
);
screen.getByText('33,33');
screen.getByText('$ 33,33');
});
});
2 changes: 1 addition & 1 deletion __tests__/Info.us.unit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,6 @@ describe('Component Info - test', () => {
<Info closeModal={onClose} setZecPrice={onSet} />
</ContextAppLoadedProvider>,
);
screen.getByText('33.33');
screen.getByText('$ 33.33');
});
});
2 changes: 1 addition & 1 deletion __tests__/Memo.snapshot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ describe('Component Memo - test', () => {
const onClose = jest.fn();
const memo = render(
<ContextAppLoadedProvider value={state}>
<Memo closeModal={onClose} updateToField={onClose} />
<Memo closeModal={onClose} memoUpdateToField={onClose} />
</ContextAppLoadedProvider>,
);
expect(memo.toJSON()).toMatchSnapshot();
Expand Down
10 changes: 10 additions & 0 deletions __tests__/Messages.snapshot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,11 @@ describe('Component Messages - test', () => {
setSendPageState={onFunction}
setScrollToBottom={onFunction}
scrollToBottom={false}
setScrollToTop={onFunction}
scrollToTop={false}
sendTransaction={onFunction}
clearToAddr={onFunction}
setServerOption={onFunction}
/>
</ContextAppLoadedProvider>,
);
Expand All @@ -142,6 +147,11 @@ describe('Component Messages - test', () => {
setSendPageState={onFunction}
setScrollToBottom={onFunction}
scrollToBottom={false}
setScrollToTop={onFunction}
scrollToTop={false}
sendTransaction={onFunction}
clearToAddr={onFunction}
setServerOption={onFunction}
/>
</ContextAppLoadedProvider>,
);
Expand Down
5 changes: 3 additions & 2 deletions __tests__/MessagesAddress.snapshot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -113,15 +113,16 @@ describe('Component Messages Address - test', () => {
<ContextAppLoadedProvider value={state}>
<MessagesAddress
doRefresh={onFunction}
toggleMenuDrawer={onFunction}
syncingStatusMoreInfoOnClick={onFunction}
setPrivacyOption={onFunction}
setSendPageState={onFunction}
setScrollToBottom={onFunction}
scrollToBottom={false}
address={mockAddresses[0].uaAddress}
closeModal={onFunction}
openModal={onFunction}
sendTransaction={onFunction}
clearToAddr={onFunction}
setServerOption={onFunction}
/>
</ContextAppLoadedProvider>,
);
Expand Down
3 changes: 1 addition & 2 deletions __tests__/Scanner.snapshot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@ describe('Component Scanner - test', () => {
//snapshot test
test('Scanner - snapshot', () => {
const onRead = jest.fn();
const doCancel = jest.fn();
const scanner = render(<Scanner onRead={onRead} doCancel={doCancel} title="title" button="button" />);
const scanner = render(<Scanner onRead={onRead} />);
expect(scanner.toJSON()).toMatchSnapshot();
});
});
6 changes: 0 additions & 6 deletions __tests__/Send.snapshot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ describe('Component Send - test', () => {
setSendPageState={onFunction}
sendTransaction={onFunction}
clearToAddr={onFunction}
setSendProgress={onFunction}
toggleMenuDrawer={onFunction}
setComputingModalVisible={onFunction}
poolsMoreInfoOnClick={onFunction}
Expand All @@ -100,8 +99,6 @@ describe('Component Send - test', () => {
setScrollToTop={onFunction}
setScrollToBottom={onFunction}
setServerOption={onFunction}
clearTimers={onFunction}
configure={onFunction}
/>
</ContextAppLoadedProvider>,
);
Expand All @@ -121,7 +118,6 @@ describe('Component Send - test', () => {
setSendPageState={onFunction}
sendTransaction={onFunction}
clearToAddr={onFunction}
setSendProgress={onFunction}
toggleMenuDrawer={onFunction}
setComputingModalVisible={onFunction}
poolsMoreInfoOnClick={onFunction}
Expand All @@ -132,8 +128,6 @@ describe('Component Send - test', () => {
setScrollToTop={onFunction}
setScrollToBottom={onFunction}
setServerOption={onFunction}
clearTimers={onFunction}
configure={onFunction}
/>
</ContextAppLoadedProvider>,
);
Expand Down
Loading