Help:Extension:ProofreadPage/Index-specific CSS/pl

From mediawiki.org
This page is a translated version of the page Help:Extension:ProofreadPage/Index-specific CSS and the translation is 14% complete.

Every Index page can have a CSS stylesheet added (as long as Extension:TemplateStyles is installed). This CSS stylesheet is applied to every page in the Page namespace, and also to Page pages that are transcluded with the <pages/> tag.

Creating the stylesheet

To create an Index stylesheet, all you need to do is add a styles.css subpage. For example, create Index:Foobar.djvu/styles.css. This will be automatically applied to all Page-namespace page in that Index.

Targeting elements

The ability to target specific element on a page depends on the wiki, as these are usually added in templates. Generally, elements are targeted by classes:

.wst-red {
    color: red;
}

It is suggested that classes added by templates use a common prefix (e.g. English Wikisource uses wst-) to make it obvious that a certain class originates in a template.

Using an underscore as a prefix for work-specific classes also makes is less likely that this Index-specific CSS will collide with built-in MediaWiki CSS.

CSS

The CSS used is a subset of CSS called sanitized-css. Some features are not used, for example data URLs and some browser-prefixed or non-standard CSS properties.

Zobacz też