Template:VersionTimeline

  • Revision slug: Template:VersionTimeline
  • Revision title: Template:VersionTimeline
  • Revision id: 28999
  • Created:
  • Creator: Sheppy
  • Is current revision? No
  • Comment 7 words added, 1 words removed

Revision Content

/* parameters: version created, version last changed, version deprecated (optional), version obsoleted (optional) */
/* get page language first */

var u = uri.parts(Page.uri);
var lang = string.tolower(u.path[0]);
if (string.contains(lang, "project") || string.contains(lang, "Project")) {
  lang = string.substr(lang, 8);
}
/* fall back to page.language on a user page */
else if (string.StartsWith(lang, "user:")) {
 lang = page.language;
}

var introStyle = '';

var introduced = "Introduced:
Gecko " + $0 + "
" + template.geckoRelease($0);
(web.html(introStyle + introduced + ""));

Revision Source

<pre class="script">
/* parameters: version created, version last changed, version deprecated (optional), version obsoleted (optional) */
/* get page language first */

var u = uri.parts(Page.uri);
var lang = string.tolower(u.path[0]);
if (string.contains(lang, "project") || string.contains(lang, "Project")) {
  lang = string.substr(lang, 8);
}
/* fall back to page.language on a user page */
else if (string.StartsWith(lang, "user:")) {
 lang = page.language;
}

var introStyle = '<span style="font-size:x-small; color:white; text-align:center;">';

var introduced = "Introduced:<br>Gecko " + $0 + "<br>" + template.geckoRelease($0);

<div style="height:24px; background:#222222;">
(web.html(introStyle + introduced + "</span>"));
</div> 
</pre>
Revert to this revision