So I've been wondering if it's possible to remove the sidebar for the few first passages, and then automatically make it appear as the player moves on. Something like, during the first few passages (choosing character and such) the sidebar isn't there, and then once the story itself begins, the sidebar is there with all the information I want.
Is this a thing? Can it happen?
keep in mind I'm really new at this, please... thanks
Oh, an I'm using twine 2 with Sugarcube 2.18
1. Stow the side-bar.
2. Totally hide the side-bar including the stow-bar.
This is a little harder because you need to:
a. Have some way to indicate when to hide the side bar, which you can do by marking each passage you want it hidden for with the same Passage Tag. The tag name you use is not important, this example will use no-side-bar
b. hide the side-bar and then move the story area over slightly to the left, both of which can be done using CSS withing your story's Story Stylesheet area.
The following CSS uses selectors based on the no-side-bar passage tag, if you use a different passage tag name then you will need to modify the selectors likewise.
And into the passage you want the Sidebar to appear you enter:
If you want to also move the story area, you can do the same by manipulating margin-left of #story.
1. It does not allow for the extra width added to the story left margin into which the side-bar is shown.
Seems to work without any problem on my end.
Which like I said seems to work fine for me, unless I am overlooking something.
note: I am not trying to put down the excellent solutions you supply, I am just trying to make those solutions more complete so that all the people who read a thread looking for a similar solution will be able to understand it.
A few notes.
For the first rule. If you're setting the UI bar to not display at all, then you don't need to alter its left property at all since it will be removed from the layout completely.
For the second. You shouldn't need to use the general sibling selector in this case. Also, the default left margin for the story element is 2.5em—a stowed UI bar alters that to 4.5em to reserve space for itself, which you don't need it you're hiding/removing it.
Altogether, the changes would look like: