CenterForOpenScience / osf.io

Facilitating Open Science
https://osf.io
Apache License 2.0
675 stars 331 forks source link

Allow image size markup in wiki #7164

Closed hafen closed 3 years ago

hafen commented 7 years ago

It would be really useful to be able to specify image size for images embedded in a wiki. Often we have no control over the size of the image we are linking to and don't want it to overwhelm the wiki page.

There is a markdown-it plugin that easily allows this with commonly-used markdown syntax for this scenario, e.g.

![test](image.png =100x200)

Here are some of my attempts showing it's not currently possible to specify image size.

screen shot 2017-04-27 at 5 37 22 pm
saradbowman commented 7 years ago

Hi @hafen, Thanks for the feedback! I'll pass this along to our Product team for triage and will keep you posted if/when this feature becomes available. Don't hesitate to reach out in the future with more feedback/feature requests! (here or email support AT osf DOT io)

saradbowman commented 7 years ago

Hi @hafen, this feature is now in production. Try it out!

serbinsh commented 4 years ago

Hello. I am trying to follow the wiki instructions https://help.osf.io/hc/en-us/articles/360019737474-Edit-the-Wiki#embed-images-from-osf-storage and resize an embedded OSF image. However it doesnt seem, at least from my experimentation, that its possible to resize an osf image like you can with an external, is this accurate?

This works

@[osf](uvr57)

This doesnt

@[osf](uvr57 =50x50)

I was hoping to embed images from my storage space into the wiki but only have them load a small image not full res. Is this possible?

brianjgeiger commented 4 years ago

Hi, @serbinsh,

You might have to use a full URL for this. Have you tried ![osf](https://osf.io/uvr57/download =50x50)?

serbinsh commented 4 years ago

Bingo! thanks!

If that isnt in the readme on the wiki, I would suggest adding. I didn't immediately find that, hence the question, but thats pretty useful