-
-
Notifications
You must be signed in to change notification settings - Fork 602
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
FancyTree Drag/Drop Marker in Webcomponents #1012
Labels
Comments
could you add a setting, to specify the root component wich should be used? |
jogibear9988
added a commit
to jogibear9988/fancytree
that referenced
this issue
Jun 23, 2020
i will look into the PR later (needs some docuemntation and style adjustments), but this may be a workaround for you. $dropMarker = $("#fancytree-drop-marker");
if (!$dropMarker.length) {
$dropMarker = $("<div id='fancytree-drop-marker'></div>")
.hide()
.css({
"z-index": 1000,
// Drop marker should not steal dragenter/dragover events:
"pointer-events": "none",
})
.prependTo("body");
if (glyph) {
FT.setSpanIcon(
$dropMarker[0],
glyph.map._addClass,
glyph.map.dropMarker
);
}
} |
nope. this will not work.
does not search in the shadowDom |
I think it should also be possible to hand over a existing dropMarker as element. |
# for free
to join this conversation on GitHub.
Already have an account?
# to comment
Problem:
I use Fancy Tree in a Webcomponent, wich include the styles for it in it's shadowdom. So the css is not loaded into the main document.
Problem is, the drag/drop marker is always added to the body of the main page.
Maybe there should be a way, so the marker could be added to the shadow dom?
You could see a example of it here: https://node-projects.github.io/web-component-designer-demo/index.html
The text was updated successfully, but these errors were encountered: