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

Question: disable dropping between subcomponents in DDCssLayout #6

Open
Charrey opened this issue Mar 7, 2022 · 1 comment
Open

Comments

@Charrey
Copy link

Charrey commented Mar 7, 2022

Hello,
I have a question about the previewing of eligable drop locations. When I have a target layout with some items already present, I expect a preview between those items when I hover over the drop location while holding a draggable item. This works find when the items already present are leaf components (e.g. buttons). However, when they are composite components (e.g. a vbox or hbox) I find some unusual behaviour: the previewer also previews drop locations between subcomponents of those items.

For example, provided the following descriptor:

<dnd:dndCssLayout id="dashboard"
    dragMode="CLONE"
    height="AUTO"
    width="100%"
    stylename="min-height">
    <vbox>
        <button caption="1"/>
        <button caption="2"/>
    </vbox>
    <vbox>
        <button caption="3"/>
        <button caption="4"/>
    </vbox>
</dnd:dndCssLayout>

...I can still drag items between the subcomponents of the vbox.

bug

In my application, the items in my drop target are highly composite with many nested subcomponents. The current preview behaviour results in a very glitchy UI. How can I make sure that only locations are previewed between root elements of the target layout?

@Charrey
Copy link
Author

Charrey commented Mar 7, 2022

It seems to be related to this issue.

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

No branches or pull requests

1 participant