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

[Clone] Remove extra nodes when sorting the images in Slider with drag-and-drop. #1832

Merged
merged 1 commit into from
Aug 28, 2023

Conversation

Soare-Robert-Daniel
Copy link
Contributor

@Soare-Robert-Daniel Soare-Robert-Daniel commented Aug 28, 2023

Closes #1820

Summary

🔴 I could not find how to fix this by tweaking the props of the HOC component.

🔧 The working solution was a manual cleaning of the extra nodes. It is a little hack, but it works.

Screenshots

2023-08-28.15-41-47.mp4

UPDATE: I accidentally press Merge on this 🤦


Test instructions

  1. Create a Slider Block
  2. Add images.
  3. Sort the images using the Drag and Drop feature like in the video above.

Checklist before the final review

  • Included E2E or unit tests for the changes in this PR.
  • Visual elements are not affected by independent changes.
  • It is at least compatible with the minimum WordPress version.
  • It loads additional script in frontend only if it is required.
  • Does not impact the Core Web Vitals.
  • In case of deprecation, old blocks are safely migrated.
  • It is usable in Widgets and FSE.
  • Copy/Paste is working if the attributes are modified.
  • PR is following the best practices

@Soare-Robert-Daniel Soare-Robert-Daniel added the pr-checklist-skip Allow this Pull Request to skip checklist. label Aug 28, 2023
@Soare-Robert-Daniel Soare-Robert-Daniel self-assigned this Aug 28, 2023
@Soare-Robert-Daniel Soare-Robert-Daniel linked an issue Aug 28, 2023 that may be closed by this pull request
@Soare-Robert-Daniel Soare-Robert-Daniel changed the title fix: add cleanup after sorting Remove extra nodes when sorting the images in Slider with drag-and-drop. Aug 28, 2023
@Soare-Robert-Daniel Soare-Robert-Daniel marked this pull request as ready for review August 28, 2023 12:46
@Soare-Robert-Daniel Soare-Robert-Daniel merged commit 20c16cd into development Aug 28, 2023
29 checks passed
@Soare-Robert-Daniel Soare-Robert-Daniel deleted the fix/slider-images-inspector branch August 28, 2023 12:46
@pirate-bot
Copy link
Contributor

Bundle Size Diff

Package Old Size New Size Diff
Animations 270.78 KB 270.78 KB 0 B (0.00%)
Blocks 1.42 MB 1.42 MB 212 B (0.01%)
CSS 85.28 KB 85.28 KB 0 B (0.00%)
Dashboard 122.49 KB 122.49 KB 0 B (0.00%)
Export Import 83.17 KB 83.17 KB 0 B (0.00%)
Pro 303.27 KB 303.29 KB 12 B (0.00%)

@pirate-bot
Copy link
Contributor

Plugin build for 31a9972 is ready 🛎️!

@Soare-Robert-Daniel Soare-Robert-Daniel restored the fix/slider-images-inspector branch August 28, 2023 12:50
Soare-Robert-Daniel added a commit that referenced this pull request Aug 28, 2023
…ector"

This reverts commit 20c16cd, reversing
changes made to 8a878de.
@pirate-bot
Copy link
Contributor

E2E Summary

Typing

Test Average Time (ms) Standard Deviation (ms) Median Time (ms) Quantile for soft limit (%) Quantile for hard limit (%)
Typing 67.63 3.83 68 0 (60ms) 100 (80ms)
Values above 60ms "0 - 65.14, 1 - 63.22, 2 - 64.45, 3 - 61.79, 4 - 69.59, 5 - 67.52, 6 - 69.35, 7 - 68.92, 8 - 65.66, 9 - 67.60, 10 - 71.09, 11 - 69.72, 12 - 69.00, 13 - 69.61, 14 - 68.00, 15 - 71.94, 16 - 77.64, 17 - 62.14, 18 - 62.55"

@Soare-Robert-Daniel Soare-Robert-Daniel changed the title Remove extra nodes when sorting the images in Slider with drag-and-drop. [Clone] Remove extra nodes when sorting the images in Slider with drag-and-drop. Aug 28, 2023
@pirate-bot pirate-bot added the pr-checklist-complete The Pull Request checklist is complete. (automatic label) label Aug 28, 2023
@pirate-bot
Copy link
Contributor

🎉 This PR is included in version 2.4.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@pirate-bot pirate-bot added the released Indicate that an issue has been resolved and released in a particular version of the product. label Sep 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr-checklist-complete The Pull Request checklist is complete. (automatic label) pr-checklist-skip Allow this Pull Request to skip checklist. released Indicate that an issue has been resolved and released in a particular version of the product.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants