User talk:Auldrick/Sandbox/Edition-specific CSS

Demo only: Not a finished page
This page was created as part of a demonstration of how a user could use custom CSS to hide parts of a document that don't apply to their favorite version. The demo is not fully developed: We would probably want to support users who'd like to see more than one but not all editions. That would be trivial to implement but harder to explain to novices, so I've left it off this page. We might also need to tweak the overall technique for better appearance when a whole paragraph or section needs to be suppressed.

A specially modified copy of an article is being created to demonstrate the effect of changing your Custom CSS user preference. This special page will include HTML &lt;span&gt; elements with class attributes naming classes in the CSS. The attributes assigned by the CSS classes will cause the unwanted text not to be rendered, without leaving any empty space in its place (unless it's forced by some other element at the same vertical position, such as an image, infobox, etc.). I will manually craft the page for demo purposes; if we decide to go forward with this we'll need to modify the only template (or replacements) to insert the &lt;span&gt; tags. We could do this at any time, since they'll only take effect for users who create the custom CSS; everybody else will see the same old page they've seen up to now.

Unfortunately, this method doesn't reduce the wiki server load. The entire page is still downloaded, it's just that part of it isn't rendered on the client. To reduce the page download size, we'd have to implement this with some sort of collapsing text element like we use for redstone schematics, ID tables, etc. Those would leave a visible substitute in the page, which doesn't give the smooth reading experience I was aiming for. – Auldrick (talk &middot; contribs) 21:00, 17 June 2017 (UTC)