Topic on Extension talk:TemplateStyles/Q&A

Edit protection, and MCR

6
Izno (talkcontribs)

My opinion is that styles and scripting related to specific templates should live on separate pages. This enables MCR integration later (to some small degree--I would guess a script will have an easier time migrating CSS/JS from subpages to slots than from embedded information to slots).

Separate pages also enable separate protection mechanisms to be applied to style pages. Given the recognized potential for misuse of CSS (and especially JS, though JS is probably less relevant right now), there should be a separate protection mechanism available for the styling pages, and even enabled and "on" by default. With the current system of protection (prior to MCR), that's simply not available.

Anomie (talkcontribs)

The primary difficulty with migrating embedded styles to a MCR slot, as I see it, is that the embedded styles might be being generated using {{#tag:templatestyle|...}} or by calling frame:preprocess() from a Scribunto module. Moving to an MCR slot would not want to be trying to parse the slot as some sort of wikitext.

Regarding potential misuse, the opportunity for such will be somewhat greater than for the existing inline styles but much less than for existing mechanisms such as MediaWiki:Common.css. There is nothing in this proposal about allowing JS at all.

This post was hidden by Izno (history)
This post was hidden by Anomie (history)
Jdforrester (WMF) (talkcontribs)

I would very strongly suggest that both {{#tag:templatestyle|...}} and frame:preprocess() would be blocked from working for precisely this reason.

Anomie (talkcontribs)

That's one of the reasons why I support separate-page storage. Making it possible for the tag function to detect that it's being used in one of these ways seems like it could be difficult.

Reply to "Edit protection, and MCR"