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

Feature: Background graphics #17

Open
KristofferStrube opened this issue Sep 20, 2023 · 2 comments
Open

Feature: Background graphics #17

KristofferStrube opened this issue Sep 20, 2023 · 2 comments
Labels
enhancement New feature or request

Comments

@KristofferStrube
Copy link
Owner

It seems sensible that it should be possible to add some background graphics/shapes to either serve as context for what is being edited or to give an idea of the zoom level/placement of the viewport.

This can be implemented in many ways, so I will start off by describing some simple cases and then later try to come up with an implementation that can support these cases.

  • Grid: It would be nice to have a grid layout on the whole-number coordinates so that the user can relate the size of their shapes to this and align different parts of shapes to each other more easily. A problem with this is that it can be rather heavy to render many shapes in the background that will move a lot when the viewport moves.
  • Static Shape: If the goal for using the editor is to sketch over something, then having a set of shapes that can't be selected, which are placed in the background, would be nice.

For both cases, the background shapes/grid would need to be transformed according to where the viewport is, so we can't simply place some static SVG/HTML in the background.

Before specifying any solution further, I would love to get feedback from the library users to see what concrete cases you have.

@KristofferStrube KristofferStrube added the enhancement New feature or request label Sep 20, 2023
@nedimm
Copy link

nedimm commented Sep 20, 2023

At the moment I do have an use case where Static Shape is needed, exactly as you said, to sketch over something. Regarding the "Grid" use case, it would be nice to have, but I don't have such an use case at the moment. What I could not find until now are commands to align shapes toward the "canvas" or other shapes on the page.

@czaban
Copy link

czaban commented Mar 5, 2024

It will be usefull for adding zones over security camera view - without adding the snapshot in background you have no idea where to put the polygon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants