BlueSpice MediaWiki REL1_27
 All Classes Namespaces Files Functions Variables Groups Pages
SkinMinerva Class Reference
Inheritance diagram for SkinMinerva:
Collaboration diagram for SkinMinerva:

Public Member Functions

 getMFConfig ()
 
 doEditSectionLink (Title $nt, $section, $tooltip=null, $lang=false)
 
 getPageClasses ($title)
 
 __construct ()
 
 initPage (OutputPage $out)
 
 getLoginUrl ($query)
 
 getSkinConfigVariables ()
 
 getContextSpecificModules ()
 
 getDefaultModules ()
 
 addToBodyAttributes ($out, &$bodyAttrs)
 
 setupSkinUserCss (OutputPage $out)
 
- Public Member Functions inherited from SkinTemplate
 setupSkinUserCss (OutputPage $out)
 
 getLanguages ()
 
 outputPage (OutputPage $out=null)
 
 getPersonalToolsList ()
 
 useCombinedLoginLink ()
 
 tabAction ($title, $message, $selected, $query= '', $checkEdit=false)
 
 makeTalkUrlDetails ($name, $urlaction= '')
 
 makeArticleUrlDetails ($name, $urlaction= '')
 
- Public Member Functions inherited from Skin
 getSkinName ()
 
 initPage (OutputPage $out)
 
 getDefaultModules ()
 
 preloadExistence ()
 
 getRevisionId ()
 
 isRevisionCurrent ()
 
 setRelevantTitle ($t)
 
 getRelevantTitle ()
 
 setRelevantUser ($u)
 
 getRelevantUser ()
 
 outputPage (OutputPage $out=null)
 
 setupSkinUserCss (OutputPage $out)
 
 getPageClasses ($title)
 
 getHtmlElementAttributes ()
 
 addToBodyAttributes ($out, &$bodyAttrs)
 
 getLogo ()
 
 getCategoryLinks ()
 
 drawCategoryBrowser ($tree)
 
 getCategories ()
 
 bottomScripts ()
 
 printSource ()
 
 getUndeleteLink ()
 
 subPageSubtitle ()
 
 showIPinHeader ()
 
 getSearchLink ()
 
 escapeSearchLink ()
 
 getCopyright ($type= 'detect')
 
 getCopyrightIcon ()
 
 getPoweredBy ()
 
 logoText ($align= '')
 
 makeFooterIcon ($icon, $withImage= 'withImage')
 
 mainPageLink ()
 
 footerLink ($desc, $page)
 
 privacyLink ()
 
 aboutLink ()
 
 disclaimerLink ()
 
 showEmailUser ($id)
 
 getSkinStylePath ($name)
 
 buildSidebar ()
 
 addToSidebar (&$bar, $message)
 
 addToSidebarPlain (&$bar, $text)
 
 getNewtalks ()
 
 getSiteNotice ()
 
 doEditSectionLink (Title $nt, $section, $tooltip=null, $lang=false)
 
 commentBlock ($comment, $title=null, $local=false, $wikiId=null)
 
 generateRollback ($rev, IContextSource $context=null, $options=[ 'verify'])
 
 link ($target, $html=null, $customAttribs=[], $query=[], $options=[])
 
 linkKnown ($target, $html=null, $customAttribs=[], $query=[], $options=[ 'known', 'noclasses'])
 
 userLink ($userId, $userName, $altUserName=false)
 
 userToolLinks ($userId, $userText, $redContribsWhenNoEdits=false, $flags=0, $edits=null)
 
- Public Member Functions inherited from ContextSource
 getContext ()
 
 setContext (IContextSource $context)
 
 getConfig ()
 
 getRequest ()
 
 getTitle ()
 
 canUseWikiPage ()
 
 getWikiPage ()
 
 getOutput ()
 
 getUser ()
 
 getLanguage ()
 
 getSkin ()
 
 getTiming ()
 
 getStats ()
 
 msg ()
 
 exportSession ()
 

Public Attributes

 $skinname = 'minerva'
 
 $template = 'MinervaTemplate'
 
 $useHeadElement = true
 
 $isUserPage = false
 
- Public Attributes inherited from SkinTemplate
 $skinname = 'monobook'
 
 $template = 'QuickTemplate'
 
 $thispage
 
 $titletxt
 
 $userpage
 
 $thisquery
 
 $loggedin
 
 $username
 
 $userpageUrlDetails
 
- Public Attributes inherited from Skin
 $stylename = null
 

Protected Member Functions

 prepareQuickTemplate ()
 
 preparePageContent (QuickTemplate $tpl)
 
 isAllowedPageAction ($action)
 
 getMode ()
 
 isAuthenticatedUser ()
 
 useEcho ()
 
 createSecondaryButton ($title, $url, $spanLabel, $spanClass)
 
 prepareUserButton (QuickTemplate $tpl)
 
 getPersonalUrl (Title $title, $warning, array $query=array())
 
 getPersonalTools ()
 
 prepareLanguages ($tpl)
 
 getDiscoveryTools ()
 
 insertLogInOutLink (MenuBuilder $menu)
 
 getHistoryLink (Title $title)
 
 getHeaderHtml ()
 
 prepareHeaderAndFooter (BaseTemplate $tpl)
 
 prepareMenuButton (BaseTemplate $tpl)
 
 prepareBanners (BaseTemplate $tpl)
 
 getSiteLinks ()
 
 getOldRevisionHtml ()
 
 prepareWarnings (BaseTemplate $tpl)
 
 getLanguageButton ()
 
 getTalkButton ($talkTitle, $talkButton)
 
 getSecondaryActions (BaseTemplate $tpl)
 
 preparePageActions (BaseTemplate $tpl)
 
 isCurrentPageEditable ()
 
 getMenuData ()
 
 isTalkAllowed ()
 
 isWikiTextTalkPage ()
 
 getSkinStyles ()
 
- Protected Member Functions inherited from SkinTemplate
 setupTemplateForOutput ()
 
 wrapHTML ($title, $html)
 
 prepareQuickTemplate ()
 
 buildPersonalUrls ()
 
 buildContentNavigationUrls ()
 
 buildNavUrls ()
 
 getNameSpaceKey ()
 
- Protected Member Functions inherited from Skin
 afterContentHook ()
 
 generateDebugHTML ()
 
 lastModified ()
 

Protected Attributes

 $isMobileMode = false
 
 $mode = 'stable'
 
 $mobileContext
 
 $shouldSecondaryActionsIncludeLanguageBtn = true
 
 $doesPageHaveLanguages = false
 
- Protected Attributes inherited from Skin
 $skinname = null
 
 $mRelevantTitle = null
 
 $mRelevantUser = null
 

Additional Inherited Members

- Static Public Member Functions inherited from Skin
static getSkinNames ()
 
static getSkinNameMessages ()
 
static getAllowedSkins ()
 
static normalizeKey ($key)
 
static makeVariablesScript ($data)
 
static getDynamicStylesheetQuery ()
 
static makeMainPageUrl ($urlaction= '')
 
static makeSpecialUrl ($name, $urlaction= '', $proto=null)
 
static makeSpecialUrlSubpage ($name, $subpage, $urlaction= '')
 
static makeI18nUrl ($name, $urlaction= '')
 
static makeUrl ($name, $urlaction= '')
 
static makeInternalOrExternalUrl ($name)
 
static makeNSUrl ($name, $urlaction= '', $namespace=NS_MAIN)
 
static makeUrlDetails ($name, $urlaction= '')
 
static makeKnownUrlDetails ($name, $urlaction= '')
 
static checkTitle (&$title, $name)
 

Detailed Description

Minerva: Born from the godhead of Jupiter with weapons! A skin that works on both desktop and mobile

Constructor & Destructor Documentation

SkinMinerva::__construct ( )

Initiate class

Member Function Documentation

SkinMinerva::addToBodyAttributes (   $out,
$bodyAttrs 
)

This will be called by OutputPage::headElement when it is creating the "<body>" tag, - adds output property bodyClassName to the existing classes

Parameters
OutputPage$out
array$bodyAttrs
SkinMinerva::createSecondaryButton (   $title,
  $url,
  $spanLabel,
  $spanClass 
)
protected

Creates element relating to secondary button

Parameters
string$titleTitle attribute value of secondary button
string$urlof secondary button
string$spanLabeltext of span associated with secondary button.
string$spanClassthe class of the secondary button
Returns
string html relating to button
SkinMinerva::doEditSectionLink ( Title  $nt,
  $section,
  $tooltip = null,
  $lang = false 
)

Overrides Skin::doEditSectionLink

Parameters
Title$nt
string$section
string | null$tooltip
string | bool$lang
Returns
string
SkinMinerva::getContextSpecificModules ( )

Returns an array of modules related to the current context of the page.

Returns
array
SkinMinerva::getDefaultModules ( )

Returns the javascript entry modules to load. Only modules that need to be overriden or added conditionally should be placed here.

Returns
array
SkinMinerva::getDiscoveryTools ( )
protected

Prepares a list of links that have the purpose of discovery in the main navigation menu

Returns
array
SkinMinerva::getHeaderHtml ( )
protected

Returns the HTML representing the header.

Returns
{String} html for header
SkinMinerva::getHistoryLink ( Title  $title)
protected

Prepare the content for the 'last edited' message, e.g. 'Last edited on 30 August 2013, at 23:31'. This message is different for the main page since main page content is typically transcuded rather than edited directly.

Parameters
Title$titleThe Title object of the page being viewed
Returns
array
SkinMinerva::getLanguageButton ( )
protected

Returns an array with details for a language button.

Returns
array
SkinMinerva::getLoginUrl (   $query)

Prepares a url to the Special:UserLogin with query parameters, taking into account $wgSecureLogin

Parameters
array$query
Returns
string
SkinMinerva::getMenuData ( )
protected

Returns a data representation of the main menus

Returns
array
SkinMinerva::getMFConfig ( )
SkinMinerva::getMode ( )
protected

Get the current mode of the skin [stable|beta] that is running

Returns
string
SkinMinerva::getOldRevisionHtml ( )
protected
Returns
html for a message to display at top of old revisions
SkinMinerva::getPageClasses (   $title)

Takes a title and returns classes to apply to the body tag

Parameters
Title$title
Returns
string
SkinMinerva::getPersonalTools ( )
protected

Prepares and returns urls and links personal to the given user

Returns
array
SkinMinerva::getPersonalUrl ( Title  $title,
  $warning,
array  $query = array() 
)
protected

Return a url to a resource or to a login screen that redirects to that resource.

Parameters
Title$title
string$warningKey of message to display on login page (optional)
array$queryrepresentation of query string parameters (optional)
Returns
string url
SkinMinerva::getSecondaryActions ( BaseTemplate  $tpl)
protected

Returns an array of links for page secondary actions

Parameters
BaseTemplate$tpl
Returns
string[]
SkinMinerva::getSiteLinks ( )
protected

Returns an array of sitelinks to add into the main menu footer.

Returns
Array array of site links
SkinMinerva::getSkinConfigVariables ( )

Returns array of config variables that should be added only to this skin for use in JavaScript.

Returns
array
SkinMinerva::getSkinStyles ( )
protected

Get the needed styles for this skin

Returns
array
SkinMinerva::getTalkButton (   $talkTitle,
  $talkButton 
)
protected

Returns an array with details for a talk button.

Parameters
Title$talkTitleTitle object of the talk page
array$talkButtonArray with data of desktop talk button
Returns
array
SkinMinerva::initPage ( OutputPage  $out)

Initializes output page and sets up skin-specific parameters

Parameters
OutputPage$outobject to initialize
SkinMinerva::insertLogInOutLink ( MenuBuilder  $menu)
protected

Creates a login or logout button

Parameters
MenuBuilder$menu
SkinMinerva::isAllowedPageAction (   $action)
protected

Returns true, if the pageaction is configured to be displayed.

Parameters
string$action
Returns
boolean
SkinMinerva::isAuthenticatedUser ( )
protected

Check whether the current user is authenticated or not.

Todo:
This helper function is only truly needed whilst SkinMobileApp does not support login
Returns
bool
SkinMinerva::isCurrentPageEditable ( )
protected

Checks to see if the current page is (probably) editable.

This is the same check that sets wgIsProbablyEditable later in the page output process.

Returns
boolean
SkinMinerva::isTalkAllowed ( )
protected

Returns true, if the page can have a talk page and user is logged in.

Returns
boolean
SkinMinerva::prepareBanners ( BaseTemplate  $tpl)
protected

Load internal banner content to show in pre content in template Beware of HTML caching when using this function. Content set as "internalbanner"

Parameters
BaseTemplate$tpl
SkinMinerva::prepareHeaderAndFooter ( BaseTemplate  $tpl)
protected

Create and prepare header and footer content

Parameters
BaseTemplate$tpl
SkinMinerva::prepareLanguages (   $tpl)
protected

Rewrites the language list so that it cannot be contaminated by other extensions with things other than languages See bug 57094.

Todo:
Remove when Special:Languages link goes stable
Parameters
QuickTemplate$tpl
SkinMinerva::prepareMenuButton ( BaseTemplate  $tpl)
protected

Prepare the button opens the main side menu

Parameters
BaseTemplate$tpl
SkinMinerva::preparePageActions ( BaseTemplate  $tpl)
protected

Prepare configured and available page actions

When adding new page actions make sure each menu item has is_js_only key set to true or false. The key will be used to decide whether to display the page actions wrapper on the front end. The key will be considered false if not set.

Parameters
BaseTemplate$tpl
SkinMinerva::preparePageContent ( QuickTemplate  $tpl)
protected

Prepares the header and the content of a page Stores in QuickTemplate prebodytext, postbodytext keys

Parameters
QuickTemplate$tpl
SkinMinerva::prepareQuickTemplate ( )
protected

initialize various variables and generate the template

Returns
QuickTemplate
SkinMinerva::prepareUserButton ( QuickTemplate  $tpl)
protected

Prepares the user button.

Parameters
QuickTemplate$tpl
SkinMinerva::prepareWarnings ( BaseTemplate  $tpl)
protected

Prepare warnings for mobile output

Parameters
BaseTemplate$tpl
SkinMinerva::setupSkinUserCss ( OutputPage  $out)

Add skin-specific stylesheets

Parameters
OutputPage$out
SkinMinerva::useEcho ( )
protected

Returns, if Extension:Echo should be used. return boolean


The documentation for this class was generated from the following file: