-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
fix: dnd workspace list will cause page to reload #1848
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
affine-toeverythingBundle maindiff ------------------- Bundle Size Diff -------------------------
@@ EntryPoint: main @@
## master …ix/dnd-reload +/- ##
===================================================================
< Bundle 2.89 MB 2.89 MB +207 B(+0.01%)
< Initial JS 1.81 MB 1.81 MB +117 B(+0.01%)
= Initial CSS 2.51 kB 2.51 kB
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~#
= Assets 38 38
= Chunks 36 36
= Packages 142 142
= Duplicates 7 7
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Warnings ~~~~~~~~~~~~~~~~~~~~~~~~~~~#
! Deduplicate versions of libraries
! Separate mixed content assets files
! Avoid non-minified assets
! Avoid cache wasting
@@ EntryPoint: pages/_app @@
## master …ix/dnd-reload +/- ##
===================================================================
< Bundle 2.78 MB 2.78 MB +207 B(+0.01%)
< Initial JS 1.7 MB 1.7 MB +117 B(+0.01%)
= Initial CSS 2.51 kB 2.51 kB
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~#
= Assets 36 36
= Chunks 34 34
= Packages 142 142
= Duplicates 7 7
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Warnings ~~~~~~~~~~~~~~~~~~~~~~~~~~~#
! Deduplicate versions of libraries
! Separate mixed content assets files
! Avoid non-minified assets
! Avoid cache wasting
@@ EntryPoint: pages/_error @@
## master …ix/dnd-reload +/- ##
===================================================================
= Bundle 16.5 kB 16.5 kB
= Initial JS 16.5 kB 16.5 kB
= Initial CSS 0 B 0 B
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~#
= Assets 2 2
= Chunks 2 2
= Packages 5 5
= Duplicates 0 0
...and more |
Deploying with Cloudflare Pages
|
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## master #1848 +/- ##
==========================================
+ Coverage 73.70% 74.78% +1.08%
==========================================
Files 250 250
Lines 4757 4760 +3
Branches 930 924 -6
==========================================
+ Hits 3506 3560 +54
+ Misses 1052 1003 -49
+ Partials 199 197 -2
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 18 files with indirect coverage changes Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report in Codecov by Sentry. |
Use
useTransition
to get rid of reloading issue when rearranging workspaces🤖 Generated by Copilot at e07770a
Summary
🚫🔧🔄
This pull request improves the user interface and performance of the workspace list modal component. It adds a
disabled
prop and a transition effect to the modal, and refactors the workspaces data fetching logic to a separate component. It also updates theWorkspaceList
component to accept adisabled
prop.Walkthrough
disabled
prop toWorkspaceList
andWorkspaceListItem
components to disable drag and drop and opacity when transitioning (link, link, link, link, link)useTransition
hook to create a transition state and function for theWorkspaceListModal
component and pass it to theWorkspaceList
component as thedisabled
prop (link, link)setWorkspaces
function with thetransition
function to update the workspaces order after a drag and drop action without unmounting or remounting the modal component (link)WorkspaceListModal
to a separate componentWorkspacesSuspense
in./apps/web/src/layouts/index.tsx
(link, link)