Extension:RenderTheFück

MediaWiki extensions manual
RenderTheFuck
Release status: unmaintained
Implementation Tag
Description Render WTF json you'd like to do.
Author(s) Raymond Wu (小璋丸talk)
Latest version 0.1.1 (2017-01-17)
MediaWiki
Database changes No
License Apache License 2.0
Download
‎<thefuck>

The fuck is a tag hook to help you render json data by D3.js. It can render timeline currently. The character u has two dot on the top, because [sf]uck are not allowed naming as topic.

How to edit

Just input a simple tag hook.

<thefuck example="timeline" />

Then appear this SVG, and it's downloadable. Each text in the bar has a link to Wikipedia.

 

Your own data edit

<thefuck width="1000" height="400">
{
  "wtf": "timeline",
  "settings": {
    "title": "Timeline example",
    "unit": "year"
  },
  "lines": [
    {
      "title": "Roman Empire",
      "from": -27,
      "to": 476,
      "wiki": "Roman Empire"
    },
    {
      "title": "Byzantine Empire",
      "from": 330,
      "to": 1453,
      "wiki": "Byzantine Empire"
    },
    {
      "title": "Holy Roman Empire",
      "from": 962,
      "to": 1806,
      "wiki": "Holy Roman Empire"
    },
    {
      "title": "First French Empire",
      "from": 1804,
      "to": 1814,
      "wiki": "First French Empire"
    },
    {
      "title": "Austrian Empire",
      "from": 1867,
      "to": 1918,
      "wiki": "Austrian Empire"
    }
  ]
}
</thefuck>

Installation edit

  • Download it from GitHub.
  • Extract this into extension dir.
  • In LocalSettings.php add this extension.
# End of automatically generated settings.
# Add more configuration options below.
wfLoadExtension( 'RenderTheFuck' );