Fandom Developers Wiki
(Added imports for CSS.)
Tag: sourceedit
No edit summary
Tag: sourceedit
Line 7: Line 7:
 
| Code = [[MediaWiki:DiscussionsFeed.js|DiscussionsFeed.js]]
 
| Code = [[MediaWiki:DiscussionsFeed.js|DiscussionsFeed.js]]
 
| Skins = Oasis / Monobook
 
| Skins = Oasis / Monobook
  +
| Examples = [[w:c:elderscrolls:Special:DiscussionsFeed|The Elder Scrolls Wiki]]
 
}}
 
}}
'''Discussions Feed''' adds a [[Special:RecentChanges]]-like flat view of recent posts on wiki's with discussions enabled. It creates a special page that can be accessed at [[Special:DiscussionsFeed]]. Entries provide links to their corresponding posts in the discussions-module, as well as links to the user profiles and quick blocks if the viewer has blocking rights.
+
'''Discussions Feed''' adds a [[Special:RecentChanges]]-like flat view of recent posts on wiki's with discussions enabled. It creates a special page that can be accessed at '''Special:DiscussionsFeed'''. Entries provide links to their corresponding posts in the discussions-module, as well as links to the user profiles and quick blocks if the viewer has blocking rights.
   
 
== Installation ==
 
== Installation ==

Revision as of 11:53, 12 October 2016

Discussions Feed adds a Special:RecentChanges-like flat view of recent posts on wiki's with discussions enabled. It creates a special page that can be accessed at Special:DiscussionsFeed. Entries provide links to their corresponding posts in the discussions-module, as well as links to the user profiles and quick blocks if the viewer has blocking rights.

Installation

This script can be added to one's own global.js to have it enabled on any wiki. Or it can be installed per wiki, so all users can access it for that specific wiki.

Template:Script Install/ImportJS

Theme (optional)

Installing the theme is optional, by default the special page will use the theme as defined on the host wiki. Adding a theme will make the special page a bit easier to read.

It is not recommended to apply one of themes to your global CSS as you will encounter wikis with both light and dark skins. To install this theme on your wiki just add the following @import line to your Wikia.css (or Common.css if you want to support monobook) (Note that all imports go at the very top of the page). The themes will only enhance the theme of the host wiki, it will not override it. This means that installing the light theme on a dark wiki or vice versa will result in a page that is very hard to read.

Light theme:

@import url('//dev.wikia.com/load.php?mode=articles&articles=u:dev:MediaWiki:DiscussionsFeed/style-light.css&only=styles');

Dark theme: (example)

@import url('//dev.wikia.com/load.php?mode=articles&articles=u:dev:MediaWiki:DiscussionsFeed/style-dark.css&only=styles');

Styling

Each entry has its own paragraph you can style. Text elements inside this paragraph all have their own classes for styling:

  • df-entry A line in the feed.
  • df-date The time-stamp of the post.
  • df-content The plain text content of the post.
  • df-user The user that posted the message.
  • df-category The category the post is in.
  • df-block A link to the Special:Block (only visible to viewers with blocking-rights).


CSS example for a wiki with dark theme:

/* Theme for Special:DiscussionsFeed */
.df-content {
    font-weight: bold;
    color: LightGrey;
}
 
.df-user {
    color: LightSkyBlue;
}
 
.df-date {
    color: LightGrey;
}
 
.df-entry:hover {
    background-color: rgba(255,255,255,0.1);
}
 
.df-category {
    font-style: italic;
}
 
.df-block {
    color: firebrick;
}
 
.df-content:link, df-content:visited, .df-user:link, df-link:visited, .df-block:link, df-block:visited {
    text-decoration: none;
}

Changelog

Date Notes Updated by
October 10th, 2016 Created Flightmare