Comments (5)
@jdittrich zooming to mouse cursor must be solved now in AlaaSarhan@571f965
you were correct about using setScrollArea
but another thing was missing.. the canvas container needed to be absolute
displayed too.
from quickmockup.
In current version (commit AlaaSarhan@a6e9c0c), I tried to implement a first version of quickMockup approach, in which an element would belong to the container it is dropped inside.
It works basically, but it seems to suffer from performance issues sometimes as well as some odd behavior in combination with toFront
.
Gotta give it a third try, probably with Raft-like approach of calculating contained elements on relevant events only, but unlike Raft, it would add them as children and remove them eventually when event is over.
from quickmockup.
first iteration of adding elements by drag&drop AlaaSarhan#1
from quickmockup.
Some open questions around raft:
- What quickmockup is that elements that are visually within a rectangle are also children of that rectangle. The children are not prevented in moving. As long as you drag the parent/child structure remains the same. As soon as you drop, it is evaluated where you dropped and the element is assigned to a new (or the old) parent.
- It seems not to actually attach children, rather in calculates what is "onboard" and then moves these along.
- We might want to write to or own raft method, since mostly we want the onboard elements to behave like children.
- Currently we have a overwrite to raft
- We could make elements that are entirely enclosed children of the innermost, enclosing element
- We could have an anchor point. If it is enclosed by other elements the element with the ancor point becomes child of the most innermost ("top") element that encloses the point. Which would allow for some comprehensible overlapping things, e.g. desktop-menus having the anchor on top so they can be grouped with a menu bar and overlap the rest.
from quickmockup.
Or we basically only have rectangles that are duplicated and then "decorated" with special types like "window", "button", "layouting rectangle" (e.g. by having an on-context button that offers "decorations" on click)…
I'm starting to like this idea a lot, at least in concept.. thinking about it technically for now, perhaps I'll attempt to implement it soon
from quickmockup.
Related Issues (20)
- official Docker image HOT 2
- v2: Add strokes to elements HOT 1
- v2: Add slight outline on elements that currently dragged elements would be grouped with HOT 5
- v2: extend inplace label editing with save/cancel buttons
- v2: Constraints/principle we should consider when creating functionality HOT 2
- v2: Duplicate elements easily via ctrl+D HOT 1
- v2: Have in-place toolbar HOT 1
- v2: Duplicated elements should be grouped with the container of the original elements parent
- Additional Widgets suggestion: charts HOT 1
- v2 visual representations of element in item collection bar. HOT 2
- v2 increase front size in on-canvas elements to 14px
- v2 keep element-cursor offset consistent when drop-adding elements to canvas HOT 1
- v2: Ease grouping elements HOT 4
- v2 code quality: Event initialization is messy, needs lots of files to be touched
- v2: represent element as soon as drag enters canvas HOT 3
- Cloning Window element is broken HOT 2
- Moving multiple selections into Container
- Elements being newly added are not grouped HOT 1
- Support images HOT 2
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 quickmockup.