-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
max-w cloning issue #2354
Labels
Comments
good catch. yeah we don't write gs-max-w to dom as it's not used for rendering (only creation initial value). actually don't need to delete. inserting second one looses. |
adumesny
added a commit
to adumesny/gridstack.js
that referenced
this issue
Jun 12, 2023
* fix gridstack#2354 * external items (like toolbar) might have grid-item attr we want to clone, so don't clear them
3 tasks
fixed in next release. don't forget to doinate if you find this lib useful! |
adumesny
added a commit
to adumesny/gridstack.js
that referenced
this issue
Oct 13, 2024
* fix gridstack#2231 gridstack#1840 gridstack#2354 * big overall to how we do sidepanel drag&drop helper * `clone()` helper is now passed full HTML element dragged, not an event * use any class/structure you want for side panel items * `GridStack.setupDragIn()` now support associating a `GridStackWidget` for each sidepanel that will be used to define what to create on drop! * if no `GridStackWidget` is defined, the helper will now be inserted as is, and NOT original sidepanel item. Updated two.html to showcase all use cases and more. TODO: simplify other demos...
3 tasks
better fix in v11 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello. It seems that I have found a bug in the object cloning area from a template to the grid. Following the example from the documentation, it is possible to observe that an element containing the attribute gs-max-w or gs-max-h, when cloned to the grid and then deleted from the grid using .trash or another class, any elements cloned by the same grid lose the gs-max-w or gs-max-h attribute. This can be observed even in the example documentation for two grids.
Bring the element to the grid and confirm that it has the max3 attr(on the dom the element lose this attr, but seems to work fine without it)
Removes the element from the dom dropping over a .trash class
Bring the same element to the grid again , and its lose the max-w.
The text was updated successfully, but these errors were encountered: