UserStylesheet

Nearby › Ideas

Bikini 1.x uses a custom user.css file as a way to include CSS styles into a page. This approach has a number of disadvantages:

  • Editing a style rule requires to change an external CSS file and perhaps to upload it to the publication server
  • This feature is pretty hidden to casual users

A solution

We could improve this by allowing a special page, say MyUserCss, to be included on page <head> via a <link rel="stylesheet"...> element. To activate this in the configuration file we’ll write:

USER_STYLESHEET = 'MyUserCss'

Drawbacks

  • At each page load Bikini will load two pages: the requested page and the user stylesheet page. This obviously need to be addressed, perhaps with some sort of caching.
  • The mime-type of the stylesheet needs to be specified: rendered pages in Bikini are sent to the browser using the canonical text/html, while WikiWord/source view is sent out with text/plain. An idea could be to detect known MIME types from page names suffix, in this case “Css”. Also, a stylesheet page should not run through the Creole processor before saving.
Last edited on Jul 06, 2021 by AnonymousCoward · Source · Diff