safe-global / safe-wallet-web

Safe{Wallet} – multisig EVM wallet
https://app.safe.global
GNU General Public License v3.0
344 stars 409 forks source link

Feat: visually group transactions executed in bulk in the transaction history #3772

Closed jmealy closed 3 months ago

jmealy commented 4 months ago

What it solves

Resolves #3443

How this PR fixes it

How to test it

Screenshots

image

Checklist

github-actions[bot] commented 4 months ago

Branch preview

✅ Deploy successful!

Website: https://feat_bulk_groups--walletweb.review.5afe.dev/home?safe=eth:0xA77DE01e157f9f57C7c4A326eeE9C4874D0598b6

Storybook: https://feat_bulk_groups--walletweb.review.5afe.dev/storybook/

github-actions[bot] commented 4 months ago

ESLint Summary View Full Report

Annotations are provided inline on the Files Changed tab. You can also see all annotations that were generated on the annotations page.

Type Occurrences Fixable
Errors 0 0
Warnings 0 0
Ignored 0 N/A

Report generated by eslint-plus-action

github-actions[bot] commented 4 months ago

Coverage report

St.:grey_question:
Category Percentage Covered / Total
🟡 Statements
79.41% (+0.26% 🔼)
11547/14541
🔴 Branches
58.51% (+0.2% 🔼)
2799/4784
🟡 Functions
66.7% (+0.58% 🔼)
1851/2775
🟢 Lines
80.74% (+0.27% 🔼)
10411/12894
Show new covered files 🐣
|
St.:grey_question:
| File | Statements | Branches | Functions | Lines | | :-: | :- | :- | :- | :- | :- | | 🟡 |
`...` / index.tsx
| 58.82% | 0% | 0% | 66.67% |
Show files with reduced coverage 🔻
|
St.:grey_question:
| File | Statements | Branches | Functions | Lines | | :-: | :- | :- | :- | :- | :- | | 🟡 |
`...` / safeContracts.ts
|
78.26% (-1.74% 🔻)
|
50% (-50% 🔻)
|
60% (+1.67% 🔼)
| 75% | | 🔴 |
`...` / dispatch.ts
|
38.54% (-0.2% 🔻)
| 34.48% | 26.09% |
37.43% (-0.21% 🔻)
| | 🟢 |
`...` / recovery-state.ts
|
95.16% (-0.08% 🔻)
|
86.67% (+2.46% 🔼)
| 85.71% |
96.49% (-0.06% 🔻)
| | 🟡 |
`...` / index.tsx
|
73.08% (-21.04% 🔻)
|
25% (+25% 🔼)
|
66.67% (-33.33% 🔻)
|
72.73% (-20.13% 🔻)
|

Test suite run success

1438 tests passing in 199 suites.

Report generated by 🧪jest coverage report action from f20be5d728a08e726d74a28acbeb1fde79e20db0

github-actions[bot] commented 4 months ago

📦 Next.js Bundle Analysis for safe-wallet-web

This analysis was generated by the Next.js Bundle Analysis action. 🤖

⚠️ Global Bundle Size Increased

Page Size (compressed)
global 1003.82 KB (🟡 +78 B)
Details

The global bundle is the javascript bundle that loads alongside every page. It is in its own category because its impact is much higher - an increase to its size means that every page on your website loads slower, and a decrease means every page loads faster.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

If you want further insight into what is behind the changes, give @next/bundle-analyzer a try!

Eleven Pages Changed Size

The following pages changed size from the code in this PR compared to its base branch:

Page Size (compressed) First Load
/apps 46.56 KB (🟢 -3.56 KB) 1.03 MB
/apps/custom 38.18 KB (🟢 -3.56 KB) 1.02 MB
/apps/open 48.69 KB (🟢 -2.85 KB) 1.03 MB
/home 56.57 KB (🟢 -3.47 KB) 1.04 MB
/settings/safe-apps 22.39 KB (🟢 -3.56 KB) 1 MB
/swap 26.35 KB (🟢 -3.56 KB) 1.01 MB
/transactions 74.63 KB (🟡 +723 B) 1.05 MB
/transactions/history 74.6 KB (🟡 +724 B) 1.05 MB
/transactions/messages 35.58 KB (🟡 +725 B) 1.02 MB
/transactions/queue 29.87 KB (🟡 +721 B) 1.01 MB
/transactions/tx 19.63 KB (🟡 +736 B) 1023.45 KB
Details

Only the gzipped size is provided here based on an expert tip.

First Load is the size of the global bundle plus the bundle for the individual page. If a user were to show up to your website and land on a given page, the first load size represents the amount of javascript that user would need to download. If next/link is used, subsequent page loads would only need to download that page's bundle (the number in the "Size" column), since the global bundle has already been downloaded.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

Next to the size is how much the size has increased or decreased compared with the base branch of this PR. If this percentage has increased by 20% or more, there will be a red status indicator applied, indicating that special attention should be given to this.

github-actions[bot] commented 4 months ago

ESLint Summary View Full Report

Annotations are provided inline on the Files Changed tab. You can also see all annotations that were generated on the annotations page.

Type Occurrences Fixable
Errors 0 0
Warnings 0 0
Ignored 0 N/A

Report generated by eslint-plus-action

jmealy commented 4 months ago

@iamacook gave some feedback that it is confusing to have the txHash displayed in the actions column @TanyaEfremova what do you think?

TanyaEfremova commented 4 months ago

Sure, that does make sense! How about we show the amount of transactions batched instead, and show a button separately? A couple ideas:

cc @katspaugh could you also provide feedback here please?

katspaugh commented 4 months ago

@TanyaEfremova I like this version:

Screenshot 2024-06-07 at 16 40 00

It also has a much bigger clickable are on the explorer link, so it's better overall.

Showing a single transaction hash was an important detail, because that's the confusing part about these transactions. They all have the same tx hash, so the user might be going in circles when debugging transactions. So I would keep the hash where it was but also add this View on explorer button instead of the tiny arrow icon next to the hash.

TanyaEfremova commented 4 months ago

Perfect, this exact layout can work well for grouping swap transactions (with limitations) in hitory.

github-actions[bot] commented 3 months ago

ESLint Summary View Full Report

Annotations are provided inline on the Files Changed tab. You can also see all annotations that were generated on the annotations page.

Type Occurrences Fixable
Errors 0 0
Warnings 0 0
Ignored 0 N/A

Report generated by eslint-plus-action

github-actions[bot] commented 3 months ago

ESLint Summary View Full Report

Annotations are provided inline on the Files Changed tab. You can also see all annotations that were generated on the annotations page.

Type Occurrences Fixable
Errors 0 0
Warnings 0 0
Ignored 0 N/A

Report generated by eslint-plus-action

github-actions[bot] commented 3 months ago

ESLint Summary View Full Report

Annotations are provided inline on the Files Changed tab. You can also see all annotations that were generated on the annotations page.

Type Occurrences Fixable
Errors 0 0
Warnings 0 0
Ignored 0 N/A

Report generated by eslint-plus-action

TanyaEfremova commented 3 months ago

The last thing, that I just noticed, but minor. The number of transactions displayed in the 2nd column should use label-secondary color style.