Comments (20)
There is a pr that's work in progress: #738.
from jqtree.
It's nice to see what people are building with the library. Thanks for sharing.
from jqtree.
Forgot to say I really appreciate this software kit and the author that wrote it, he's great! It's truly awesome. hope for a pointer to a fix. Much thanks.
from jqtree.
I'll have a look.
from jqtree.
I can reproduce the error. I'll try to find a fix.
from jqtree.
Thank you! Appreciate it. I'll give it a go here as well. Haven't verified it, but It seems to happen only with the first top level node, if that helps any.
This code is great, I created an outliner used for writing my books with it, as the kernel portion of the base. Will post a picture later on, it's pretty sweet.
Wondering, looking at the scroll/drag scroll and drag and drop code.
If you might consider something like this:
If past parent scroll-container top or parent scroll-container bottom:
if (sdirection.up > 0 || sdirection.down > 0) { setTimeout(scroll(scroll-container), 100); }
Will allow scroll to continue scrolling to top or continue scrolling to bottom smoother, when dragged past top or bottom of parent scroll-container.
Much thanks! My typescript is horrible. So working in ES5/ES6 ES2017...
from jqtree.
I will look into the 'past parent scroll-container top ..' idea.
from jqtree.
Only if it helps, basically it would be a change from the current cursor movement-based scroll. So it may not be as helpful.
The vertical scroll code seems to check if the previousTop is different and if it's < 20px from the scroll container's top or bottom. The target zone for scrolling. Then moves 20px on each cursor move.
The change would mean possibly reversing those, checking when in the 20px target zone then requesting tree scroll until the user moves the dragged item out of the 20px container's top/bottom target zone or until the tree has scrolled to it's natural top or bottom in the container.
And also using a setTimeout call wrapper to check if the above conditions and to slow the 20px scroll requests down smoothly. And of course removing the setTimeout when not needed.
from jqtree.
The hoveredArea.top is set to -1 when initially dragging the first top-level node over the items under it. I think this is what causes the test results.
from jqtree.
The pr works on my machine.
from jqtree.
Cool! thanks! I grabbed a quick copy of the tree.jquery.debug.js build. And did a WinMerge with it and the current release to check the diff. Lots of changes.
I'll give it a test.
I'm stuck working on a tight schedule project for the next few days, so I might not report back for a bit.
Are there any breaking changes? Thanks.
from jqtree.
There are no breaking changes. The only thing that has changed is the automatic scrolling.
from jqtree.
The pr is merged in master.
from jqtree.
Cool! Sorry haven't been around much, had too many software product deadlines and publishing my first scifi books.
Thanks, will give it a whirl. Will the example site get an update? Not much time, so thought I'd give it a quick look in the examples. Thanks again!
Best, -C
from jqtree.
I can't update the example site yet. That can only be done for a new release.
from jqtree.
Appreciate the note back. I'll roll with it here, and the copy I have, and send you a note back if needed. I think we can close this for now and I'll reopen later or post a specific.
from jqtree.
A while back, I created a proof of concept with my own code using jqtree as a kernel that works similarly to how https://workflowy.com does.
It works great! Then I added the ability to edit documents, add extra notes, add images, add checkboxes, add line/area complete, added storage etc... Mostly written in jquery/javascript.
Hopefully the images show up:
Does quite a bit more than the above, but just shared a couple of images here.
I didn't really ever release it, but use it myself for personal stuff, workflow, notes, writing novels, work projects organization, to do lists, etc...
I just wanted to show you, so you know how far this great set of code can be applied with other code. Appreciate you.
If you want the code base you can have a copy, drop me a note. Best, -C
from jqtree.
Oh, one more. =)
from jqtree.
I can also add you as a user if you want to try it out. It's a web app. Best, -C
from jqtree.
The fix is included in version 1.7.5
from jqtree.
Related Issues (20)
- Feature: ES6 support HOT 9
- Behavior changed with 1.7.0 HOT 3
- Set jQuery as a peer dependency
- Fix eslint import error
- Is documentation page dead? HOT 4
- Inconsistent/incorrect drag & drop node highlighting HOT 9
- New root node missing icon HOT 3
- AddToSelection doesn't seem to use "mustSetFocus" HOT 4
- How to use jqTree with jQuery latest version 3.7.1 in ASP.NET HOT 4
- getPreviousNode() behaves differently HOT 4
- changed documentation? HOT 2
- function onCanMoveTo can't be override HOT 2
- Drag & Drop multiple nodes HOT 4
- Injection vulnerability because of lodash.template HOT 3
- The tree is not rendered, nothing happens.
- ContextMenuEvent HOT 3
- Partial node reload HOT 4
- Move nodes between two trees HOT 1
- tree.select HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jqtree.