I want to keep my header/footer hidden in some introductory passages (maybe 20) until the variables they contain need to be seen by players. How can I do this?
Add a tag like no-sidebar to all the Passages you don't want the sidebar to appear in and then use CSS like the following to hide the sidebar in those passages.
The CSS goes in your Story Stylesheet area.
html.no-sidebar tw-sidebar {
display: none;
}
note: You can name the tag whatever you like, just remember to replace the no-sidebar part of the CSS with the tag name you use.
The header tagged passage areas are destroy and recreated each time the Reader navigates from one passage to another, so any updates you do to the current headers via Revision macros like (replace:) will be lost. You could change the header to display the current values of your variables like so:
Paro: $paro
... but header tagged passages are processed before the current passage being shown so any changes to those variables in the current passage will not effect the header unless you update it yourself.
Comments
Add a tag like no-sidebar to all the Passages you don't want the sidebar to appear in and then use CSS like the following to hide the sidebar in those passages.
The CSS goes in your Story Stylesheet area. note: You can name the tag whatever you like, just remember to replace the no-sidebar part of the CSS with the tag name you use.
I tried:
But the header still shows (this is the passage tagged Header whose content I'm trying to hide.)
Sidenote: If my header is hidden, the variables in there that are being tracked e.g. will continue to track the score until the header is visible again right?
The header tagged passage areas are destroy and recreated each time the Reader navigates from one passage to another, so any updates you do to the current headers via Revision macros like (replace:) will be lost. You could change the header to display the current values of your variables like so: ... but header tagged passages are processed before the current passage being shown so any changes to those variables in the current passage will not effect the header unless you update it yourself.