1 CSS file for multiple hype document exports

Hi guys,

First of all, thank you for your help recently! This forum’s really great!

But I’m kinda stuck again.
I have another question concerning linked CSS that I wasn’t able to find a solution for…

Let’s say, I have a project that should run offline. In this project I have 10 Hype documents containing 1 Scene each. I would now like those Hype files to share one CSS-file that is stored locally and needs to be linked relatively, as the project should run on different computers. How would I attach this file to all Hype document exports and then be able to change the styles of all exports by changing the one CSS file?

Right now, when I export the files to HTML5, their styles refer to the copy of the CSS file that is stored in each of the 10 hyperesources-folders, which makes it difficult for me to edit the CSS for all exported files at once without opening all Hype documents and exporting them again…

I’m pretty sure there is a way, I simply can’t find it. :worried:
Thank you, guys!

Following solution:
Link it from a server. Maybe even the final destination of your Project.
If you need only local development run a local server

Hi Max, Thanks again.

Okay, so a structure like on the screenshot attached is not possible? The thing is that the final destination of the project is the local desktop of many clients synced by a cloud solution.

40

This should not be a problem… just link the CSS in head manually. With a relative path…

<link rel="stylesheet" type="text/css" href="style.css" />

Downside is that the style only get applied properly when the file has been exported to the folder. In preview Hype creates a temp local server and only copies files in the resources into it using the hyperesource folder. Meaning that for a preview in hype I was suggesting to use a local server but in your case … as it’s not one final destination relative path is the way to go. In my opinion. Slightly more effort for previews…

1 Like