-
Notifications
You must be signed in to change notification settings - Fork 110
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
Custom dialogs to edit links and images #40
Comments
Moved to |
@Michael-Grover any thoughts on this? From @dselman:
|
accordproject/markdown-editor#293 @dselman there is a custom dialogue for links here
if someone wants to edit an image wouldn't they just delete it and add a new one? |
Relates to #29 |
@dselman |
@K-Kumar-01 yes I think that's the right idea. |
Image modal created Updated the insertImage function Pass necessary props and state Signed-off-by: k-kumar-01 <[email protected]>
@irmerk @dselman |
Reuse the modal positioning Inserting image uses new modal Signed-off-by: k-kumar-01 <[email protected]>
@Michael-Grover so my interpretation is that this might not be a good feature for images? |
@irmerk
I'm just not clear on what the utility of this feature is. Is being able to edit the image URL the standard functionality in editors like this (built on markdown but don't let users edit the markdown directly)? It feels like adding complexity to the UI for no additional utility. @dselman since you opened this issue, what do you think? It seems simpler to just click on an image, press backspace, then add a new one. Also, when a user uses cmv+v to paste an image, what does should the URL become in the pop up? |
I guess I was influenced by the similarity between links and images in the markdown spec. I think there is some precedent for this sort of thing. E.g. in elev.io you can click on an image, select "replace" and then the "by url" button. Fairly sure I've seen it elsewhere as well, but I'll defer to you on utility/design. I'd also love to get rid of the system prompt displayed when the user presses the "insert image" toolbar button. |
@dselman what's a situation where someone might want to change the URL of an image? I don't actually understand how someone would use the existing functionality where they have to enter a URL to add an image. Where are they getting the URL from? in editors like this, I thought that people usually upload files from their computer or paste images. I just haven't seen entering a URL as a method for adding an image in editors, so I'm having trouble envisioning how users would use the existing functionality, and how it can be improved. |
I think having a pop up appear when clicking an image makes it harder to delete the image, use the keyboard to navigate past the image, and use the cursor to drag and drop an image to a different part of the editor. |
@Michael-Grover |
@dselman @Michael-Grover @irmerk |
@dselman and I discussed pop up dialogues to edit images and decided that it's not necessary, however we should allow users who extend this component to choose what they want to happen when a user clicks on the image. I think this means having an event happen upon clicking an image, @dselman is that right? Is there any additional context you can add? |
@dselman |
The toolbar allows inserting both links and images. Both would benefit from a custom dialog to insert new links or to edit existing links.
The text was updated successfully, but these errors were encountered: