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

want to be able to insert images into the middle of a note. #4300

Open
Comoscaten opened this issue Jan 16, 2025 · 5 comments
Open

want to be able to insert images into the middle of a note. #4300

Comoscaten opened this issue Jan 16, 2025 · 5 comments
Labels
enhancement New feature or request

Comments

@Comoscaten
Copy link

Describe the solution you'd like

I want to be able to insert images into the middle of a note. Currently, when adding images or other attachments to a note, they are always appended to the bottom of the note. My current workaround is to create a separate note for the attachment or image, and then reference this note in the new one so that the image can be inserted in the middle. However, this process is a bit cumbersome. I hope native support for this feature can be added. Thank you very much!
image

Type of feature

User Experience (UX)

Additional context

No response

@Comoscaten Comoscaten added the enhancement New feature or request label Jan 16, 2025
@itbeg
Copy link

itbeg commented Jan 21, 2025

I really appreciate the effort and contribution. I believe this would be a valuable addition. I’m looking forward to seeing this feature included in the next release.
Is there an estimated timeline for this feature to be merged and released?

@fernandoonrails
Copy link

I really appreciate the effort and contribution. I believe this would be a valuable addition. I’m looking forward to seeing this feature included in the next release. Is there an estimated timeline for this feature to be merged and released?

Seems like a nice feature indeed, will try implementing it.

@itbeg
Copy link

itbeg commented Jan 22, 2025 via email

@RoccoSmit
Copy link
Contributor

Seems like a nice feature indeed, will try implementing it.

Just to note, this feature has been requested a couple of times e.g. #4194, #4130, https://github.com/orgs/usememos/discussions/3850. People have asked questions about workarounds they use to simulate the behavior you are after e.g. #4218, #4217

None of these issues have received indications that PRs are welcome so I would suggest finding out from @boojack and @johnnyjoygh first if this is a feature they are open to before you spend too much time building something.

I'd imaging there would be a fair bit of discussion around how the feature would work as well, e.g. can you have inline and attached images, is the feature managed via a setting, do you use the existing image syntax and if you do should inline resources be removed when you delete a memo the same way attachments do, how do you identify which images were resources saved on the server vs images from the web, etc.

@fernandoonrails
Copy link

fernandoonrails commented Jan 23, 2025

@RoccoSmit I've tested, and for now, you can have a work arround by using the markdown image syntax ![<text to display if image not found>](<image path or url>), but it really isn't that good if you want to have a self contained solution where everything is contained into your own self hosted application, instead of just putting the link of someone's elses image URL, I was tinkering arround in the codebase to trying to find a solution for that problem (#4305 was actually me diverging while working in this issue lol)

I thought of some solutions:

SQL data store

I thought of storing said file as a BLOB in the database

Local File System (LFS)

just save the file using a timestamp based naming to prevent duplicate names

S3

I dunno if LFS solution could be the similar for S3

The big thing I'm having the biggest trouble rn to think tho, is how to reference the image on the file, I was looking into the tests and I saw some things like '.epub', I thought the files were saved as markdown, could you give me a light?

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

4 participants