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
Add Annotation Feature #1858
Add Annotation Feature #1858
Conversation
Good work @ong6 |
Ah ok, that will have to be worked on as a future milestone as well 😅. Might need to research more on popovers. Issue is that my current implementation draws the whole image initially, so the lines are part of the image as well. I'll look into alternative implementations that might fix this issue though. |
…notation-feature
Good progress @ong6! Some initial comments for the PR (since it's still a work in progress and has quite a bit of code that will probably be removed afterward:
|
Thank you @ong6 , this looks like a really challenging and interesting issue! Some other ideas/notes mostly on syntax:
More feature suggestions:
|
@ong6 given below is what I mentioned earlier today, as an alternative to arrows and text inside the image. The text can be just regular text (below) the image. Doesn't even need to be part of annotations as we can use regular MarkBind for it.
|
…notation-feature
…notation-feature
…notation-feature
…into annotation-feature
Co-authored-by: Jovyn Tan <61113575+jovyntls@users.noreply.github.com>
Co-authored-by: Jovyn Tan <61113575+jovyntls@users.noreply.github.com>
…into annotation-feature
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @ong6!
Just 3 more nits. The rest looks good :)
Co-authored-by: Jonah Tan <47470981+jonahtanjz@users.noreply.github.com>
Co-authored-by: Jonah Tan <47470981+jonahtanjz@users.noreply.github.com>
Co-authored-by: Jonah Tan <47470981+jonahtanjz@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice spot, I just pushed a fix for it |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some minor nits from my end, otherwise looking good!
Co-authored-by: Liu YongLiang <41845017+tlylt@users.noreply.github.com>
Co-authored-by: Liu YongLiang <41845017+tlylt@users.noreply.github.com>
Co-authored-by: Liu YongLiang <41845017+tlylt@users.noreply.github.com>
…into annotation-feature
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work! Looks solid and clean, kudos 👍 LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🎉 🎉 🎉 Thanks for your patience in making the changes @ong6 !
What is the purpose of this pull request?
Fixes #898
Overview of changes:
*Note that the implementation has changed completely after discussion with @damithc
Added basic annotation feature into markbind with the idea of allowing users to add popovers and text to their existing images. Now works by making use of the existing floating-vue lib to help manage popovers over the image. Users will now specify the image to annotate then add child
<a-points>
to draw circles over the image which can function as markers for annotations.Example Code:
Example Output:
The first
<a-point>
is the minimal template where an x, y and text body has to be entered. The second<a-point>
showcases some of the changes users can make to the annotation.Anything you'd like to highlight / discuss:
<annotate>
functions very similarly to<pic>
but after discussing with @damithc we decided to split up the 2 classes to enable easier extension in the future. (E.g. adding the arrow implementation etc...)Future improvements can be tracked at this issue #1911
Shoutout to @jovyntls for helping me with the reactivity of the points!
Testing instructions:
Visit the Netlify Preview and head to
annotation
under images to test out the featureor
markbind serve -d
Proposed commit message: (wrap lines at 72 characters)
Adding a new Annotation Feature
Users want to annotate over images but have no way of doing so.
Implementing a
<annotate>
and<a-point>
components to help users annotate over images.This allows users to specify the image in
<annotate>
and specify the points in<a-point>
.Refer to issue #898 for initial suggestion.
Checklist: ☑️