Page components/about

Revision as of 20:56, 3 December 2025 by Admin (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

For a long time I've wanted to be able to package the "scaffolding" required to author beautiful pages in MediaWiki so that the first thing you do (as an author) is create content rather than to setup scaffolding. By scaffolding, I'm referring to all the things missing from MediaWiki like "help" namespace content, Templates (with a capital T), images or icons used in interface elements or general-purpose templates and other things that would be like a "Starter Kit" to make editing the first page easy.

Disclaimer: I'm not an active editor in any wiki community so I'm sure I am lacking in the knowledge of how its done across various wiki communities.


Beginner experience in a new wiki edit

The out of the box experience is that you need to first create (a lot) of templates and come up with your own system for authors to follow. - especially if you want new authors to take advantage of the stuff MediaWiki has under the covers. Simple built-in facilities like 'collapsible' sections, or 'sortable' tables require knowledge since they are not immediately visible in some "quick reference" editor's handbook but rather "buried" in the enormous reference that is mediawiki.org's Help[1]. It is obviously great that the enormous reference exists, but the goal here is to find good ways to surface the most common editor tools in a way that doesn't require a deep dive or training on wiki syntax, Template syntax, parser functions, Vue.js, CSS, Lua scripting, or other technologies.

Goals edit

Create something like the HarvardSites Design System (HarvardSites is their Drupal CMS offering to the university community for building digital products.)

Stretch Goals edit

Create a re-usable Style Guide that is easy to tweak or re-write in an enterprise setting to make it easier to follow the best practice of having this content earlier rather than later.


Current Solutions edit

As an administrator of a wiki or wiki farm, how can we provide a good editing experience? Here are some of the current solutions available.

Codex edit

Codex is the design system in MediaWiki. Actually it is available to any project, and MediaWiki is the primary use case. Codex has components like accordion that can be used by Skin or Extension developers; and also in Javascript. The components are for building usable, accessible, translatable applications.

Templates edit

Templates are one fundamental building block in MediaWiki that allows for consistently presenting information. The prime example is the 'infobox' ubiquitous to Wikipedia articles. There are many "problems" with templates. The polished result found on Wikipedia is dependent on a huge number of interconnected templates, CSS style pages, and Lua modules - all of which are not available in a "starter pack" that would be suitable or easily customizable for a 3rd-party wiki.

The Wikipedia infoboxes use CSS pages and Lua modules for the presentation and functionality.

On a page like WWE Championship there are over 100 templates and modules in use such as:

  • Template:Infobox
  • Template:Infobox pro wrestling championship
  • Template:Infobox professional wrestling championship
  • Module:Infobox
  • Module:Infobox/styles.css
  • Module:InfoboxImage
  • Module:InfoboxImage/data

Gadgets edit

Lua Modules edit

SemanticMediaWiki edit

SemanticResultFormats takes structured data and presents it in a multitude of compelling ways. SRF sits between structured data, and presentation. At the highest level, Page Components could allow for composability of SRF into a final page layout and visual presentation.

Page Forms edit

say something

Page Exchange edit

Page Exchange is a mechanism for publishing and syndicating wiki content plus the scaffolding that puts it all together - with an emphasis on the templates and functionality. Page Exchange uses the term packages. An example is the SkillsMatrix package.

Past Efforts edit

Central repository for gadgets, templates and Lua modules is tracked in the mega ticket phab:T121470 from 2015 which further relies on major efforts like "shadow namespaces" phab:T91162 and Global gadgets phab:T153332

  1. https://www.mediawiki.org/wiki/Help:Contents is the main page for Help and is actually quite good. Many wikis simply link to that page as their local wiki's "help".