It seems totally reasonable that using an escape slash would make
apostrophes in words work, but the translation system works in
mysterious ways that do not include supporting that. I've used backticks
as a third quote type to escape everything in a way that both
javascript and gettext understand.
While I was there I split up some strings that have more complicated
html in them, since that can be fragile when passed through translation,
and confusing for translators.
Fixes bug on larger screens.
We need to use a function to set the anchor for tour steps when using menus and other elements that become visible or hidden responsively. Because the element is still in the DOM, we can't just rely on it disappearing completely, we have to assign a different (visible) element otherwise the step will simply disappear and the user cannot continue the tour. Previously this used a simple selector which didn't work due to the above.
- new classname for posting guide
- various improvements to wording
- use function to find responsive menu elements
- add scrollTo transitions where needed
To make it harder to accidentally mess up the tour when making changes to pages, this commit adds ids with 'tour' prefixes to (nearly) all elements used by the guided tour as anchor points. The exception is where an element already had an id that is being used by something else in Bookwyrm.
Some minor changes also made to clean up the wording of the tour.
Move cancel button function into a separate JS file.
The selector JS for this function cannot be within bookwyrm.js because the guided tour elements load after bookwyrm.js.
The first pop up in the guided tour on each page should provide a button to switch off the guided tour altogether, not simply cancel the current iteration.
If we don't do this, then the only way to turn off the guided tour is to go right to the end, which could be really irritating, especially for people who star the tour and then start exploring on their own.
This uses an embedded script tag so that we can use django templates for logic - most importantly, we need to be able to use translations within the tour text.