-
Notifications
You must be signed in to change notification settings - Fork 563
[Dashboard] Abstract code for CSV upload form #5324
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
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
|
Your org has enabled the Graphite merge queue for merging into mainAdd the label “merge-queue” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “hotfix” to add to the merge queue as a hot fix. You must have a Graphite account and log in to Graphite in order to use the merge queue. Sign up using this link. |
This stack of pull requests is managed by Graphite. Learn more about stacking. |
size-limit report 📦
|
...rc/app/(dashboard)/(chain)/[chain_id]/[contractAddress]/tokens/components/airdrop-upload.tsx
Outdated
Show resolved
Hide resolved
...board)/(chain)/[chain_id]/[contractAddress]/_components/claim-conditions/snapshot-upload.tsx
Outdated
Show resolved
Hide resolved
previousPage, | ||
setPageSize, | ||
state: { pageIndex, pageSize }, | ||
} = useTable( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if we're updating this component lets please update this to tanstack table while we're at it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure. I'll stack up the PRs
9df1a71
to
888a5cf
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #5324 +/- ##
=======================================
Coverage 45.76% 45.76%
=======================================
Files 1069 1069
Lines 55606 55606
Branches 4073 4073
=======================================
Hits 25448 25448
Misses 29469 29469
Partials 689 689
*This pull request uses carry forward flags. Click here to find out more. |
888a5cf
to
884d513
Compare
Merge activity
|
DASH-372 <!-- start pr-codex --> --- ## PR-Codex overview This PR focuses on enhancing the CSV upload functionality by refactoring components to use a new `useCsvUpload` hook, which centralizes CSV processing logic. It introduces a `CsvDataTable` component for displaying data and improves address validation in the airdrop and snapshot upload processes. ### Detailed summary - Introduced `CsvDataTable` component for displaying CSV data. - Refactored `AirdropUpload` and `SnapshotUpload` to use `useCsvUpload` hook. - Centralized CSV parsing logic in `csvParser` functions. - Improved address validation and error handling in CSV uploads. - Removed redundant address checking functions from `AirdropUpload` and `SnapshotUpload`. - Enhanced pagination and UI updates in CSV data tables. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex -->
884d513
to
039d39a
Compare
DASH-372 <!-- start pr-codex --> --- ## PR-Codex overview This PR focuses on enhancing the CSV upload functionality by refactoring components to use a new `useCsvUpload` hook, which centralizes CSV processing logic. It introduces a `CsvDataTable` component for displaying data and improves address validation in the airdrop and snapshot upload processes. ### Detailed summary - Introduced `CsvDataTable` component for displaying CSV data. - Refactored `AirdropUpload` and `SnapshotUpload` to use `useCsvUpload` hook. - Centralized CSV parsing logic in `csvParser` functions. - Improved address validation and error handling in CSV uploads. - Removed redundant address checking functions from `AirdropUpload` and `SnapshotUpload`. - Enhanced pagination and UI updates in CSV data tables. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex -->
039d39a
to
5216bef
Compare
DASH-372
PR-Codex overview
This PR focuses on refactoring the
AirdropUpload
andSnapshotUpload
components to utilize a newuseCsvUpload
hook for handling CSV uploads and data processing. It also introduces a newCsvDataTable
component for displaying data in a tabular format.Detailed summary
useCsvUpload
hook for handling CSV uploads.CsvDataTable
for rendering tabular data.AirdropUpload
to useuseCsvUpload
andCsvDataTable
.SnapshotUpload
similarly toAirdropUpload
.