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

Paste grid cell as sibling #6516

Merged
merged 2 commits into from
Oct 11, 2024
Merged

Paste grid cell as sibling #6516

merged 2 commits into from
Oct 11, 2024

Conversation

ruggi
Copy link
Contributor

@ruggi ruggi commented Oct 10, 2024

Problem:

Copy-pasting a grid cell ends up pasting it inside the selected element instead of next to it.

Fix:

If the copied element is a grid cell and the target is another grid cell, paste next to it.

Before After
Kapture 2024-10-10 at 16 18 06 Kapture 2024-10-10 at 16 16 49

Fixes #6515

Copy link
Contributor

github-actions bot commented Oct 10, 2024

Try me

Copy link

relativeci bot commented Oct 10, 2024

#14723 Bundle Size — 57.95MiB (+0.02%).

c170a70(current) vs 916e8b9 master#14701(baseline)

Warning

Bundle contains 70 duplicate packages – View duplicate packages

Bundle metrics  Change 4 changes Regression 1 regression
                 Current
#14723
     Baseline
#14701
Regression  Initial JS 40.95MiB(+0.03%) 40.94MiB
No change  Initial CSS 0B 0B
Change  Cache Invalidation 18.46% 17.91%
No change  Chunks 21 21
No change  Assets 23 23
Change  Modules 4147(+0.05%) 4145
No change  Duplicate Modules 213 213
Change  Duplicate Code 27.31%(-0.04%) 27.32%
No change  Packages 477 477
No change  Duplicate Packages 70 70
Bundle size by type  Change 2 changes Regression 1 regression Improvement 1 improvement
                 Current
#14723
     Baseline
#14701
Regression  JS 57.94MiB (+0.02%) 57.93MiB
Improvement  HTML 7.37KiB (-0.25%) 7.39KiB

Bundle analysis reportBranch feat/past-grid-cellProject dashboard


Generated by RelativeCIDocumentationReport issue

return null
}

const targetIsGridCell = MetadataUtils.isGridCell(metadata, selectedView)
Copy link
Contributor

@liady liady Oct 11, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just a small unrelated (non-blocking) naming nitpick - the element itself should probably be called "grid child" (since a "grid cell" is usually the actual cell and not the element being copied in this case)

Copy link
Contributor Author

@ruggi ruggi Oct 11, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

true, but we should also update the method name (isGridChild). We have a bunch of naming cleanup to do, (e.g. tracks vs dimensions). If that's ok I'll leave it to clean up in the future, but rename that constant now.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ruggi ruggi merged commit 3730db6 into master Oct 11, 2024
15 checks passed
@ruggi ruggi deleted the feat/past-grid-cell branch October 11, 2024 11:10
liady pushed a commit that referenced this pull request Dec 13, 2024
**Problem:**

Copy-pasting a grid cell ends up pasting it inside the selected element
instead of next to it.

**Fix:**

If the copied element is a grid cell and the target is another grid
cell, paste next to it.


| Before | After |
|------------|-------------|
| ![Kapture 2024-10-10 at 16 18
06](https://github.com/user-attachments/assets/ff77dac5-c62b-4a60-b4a2-2e98d2fde8b4)
| ![Kapture 2024-10-10 at 16 16
49](https://github.com/user-attachments/assets/326e63f1-3796-4592-b7de-e9b8a5a4a471)
|

Fixes #6515
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

better grid cell paste
4 participants