ember-osf-web icon indicating copy to clipboard operation
ember-osf-web copied to clipboard

Rendering of markdown files in Viewer

Open DTP587 opened this issue 1 year ago • 3 comments

Hello, apologies if I have this wrong as this is my first time opening an issue!

I have a repository with the OSF where inside we have linked out each of the project modules to separate GitHub repositories with markdown files containing a list of instructions (example).

Unfortunately, when these files are viewed though the OSF website, it renders incorrectly with the images missing.

I understand that as these modules are not directly hosted on the OSF it may be difficult/impossible to render these markdown files correctly. Is there any possibility to get this fixed?

Thank you 😊

DTP587 avatar Dec 04 '23 11:12 DTP587

Hello. On first look, it seems like the problem is that your image tags are referencing relative paths for your images (ex. image.jpg). If you replace those with absolute paths (ex. https://domain.com/files/image.jpg), it should work properly.

brianjgeiger avatar Dec 04 '23 13:12 brianjgeiger

Thanks 😊 I see that would fix the images; but other structures in the markdown files seem to be incorrectly displaying too:

Table Incorrect

Code Block Incorrect

Correct display on GitHub:

Table GitHub

Code Block GitHub

DTP587 avatar Dec 04 '23 14:12 DTP587

Thanks 😊 I see that would fix the images; but other structures in the markdown files seem to be incorrectly displaying too:

![Table Incorrect](https://github.com/CenterForOpenScience/ember-osf-web/assets/42982107/636fbd71-568a-4ecc-b0db-a9f03444196c)

![Code Block Incorrect](https://github.com/CenterForOpenScience/ember-osf-web/assets/42982107/9b97392d-9369-4e5d-8d61-8b869a85c6f9)

Correct display on GitHub:

![Table GitHub](https://github.com/CenterForOpenScience/ember-osf-web/assets/42982107/7e771a67-4b08-4db0-9763-197861976a42)

![Code Block GitHub](https://github.com/CenterForOpenScience/ember-osf-web/assets/42982107/3dff0633-0907-4a32-8f76-670d9d14b861)



--
Reply to this email directly or view it on GitHub:
https://github.com/CenterForOpenScience/ember-osf-web/issues/2073#issuecomment-1838711259
You are receiving this because you commented.

Message ID: ***@***.***>

brianjgeiger avatar Dec 04 '23 14:12 brianjgeiger