Jump to content

Topic on Project:Support desk

Sidebar customisation by namespace

1
Slgrandson (talkcontribs)

On my creative-venture wiki, I've had a bit of trouble getting a particular sidebar section to work on the namespaces it's supposed to be visible on. Despite following the advice at Manual:Interface/Sidebar#Parser functions in sidebar, the target section is not showing up and the affected HTML segment is no better for it.

From my site's own Sidebar message:

* {{#switch:{{NAMESPACE}}{{!}}Voablivrile{{!}}Grammar{{!}}Corpus {{!}}Entry{{!}}Morpheme{{!}}Rhymes=Tovasala}}
** {{#switch:{{NAMESPACE}}{{!}}Voablivrile{{!}}Grammar{{!}}Corpus {{!}}Entry{{!}}Morpheme{{!}}Rhymes=Portal:Tovasala Dictionary{{!}}Home page}}
** {{#switch:{{NAMESPACE}}{{!}}Voablivrile{{!}}Grammar{{!}}Corpus {{!}}Entry{{!}}Morpheme{{!}}Rhymes=Voablivrile:Grammar{{!}}Grammar}}
** {{#switch:{{NAMESPACE}}|Voablivrile|Grammar|Corpus|Entry|Morpheme|Rhymes=Special:Random/Entry{{!}}Random headword}}
** {{#switch:{{NAMESPACE}}|Voablivrile|Grammar|Corpus|Entry|Morpheme|Rhymes=Special:Random/Morpheme{{!}}Random morpheme}}
** {{#switch:{{NAMESPACE}}|Voablivrile|Grammar|Corpus|Entry|Morpheme|Rhymes=Special:RandomInCategory/Snippets{{!}}Random snippet}}
** {{#switch:{{NAMESPACE}}|Voablivrile|Grammar|Corpus|Entry|Morpheme|Rhymes=Special:Random/Rhymes{{!}}Random rhyme list}}

HTML source:

<nav id="p-{{#switch:{{NAMESPACE}}{{!}}Voablivrile{{!}}Grammar{{!}}Corpus_{{!}}Entry{{!}}Morpheme{{!}}Rhymes=Tovasala}}" class="mw-portlet mw-portlet-_switch_NAMESPACE_Voablivrile_Grammar_Corpus_Entry_Morpheme_Rhymes_Tovasala emptyPortlet vector-menu vector-menu-portal portal" aria-labelledby="p-{{#switch:{{NAMESPACE}}{{!}}Voablivrile{{!}}Grammar{{!}}Corpus_{{!}}Entry{{!}}Morpheme{{!}}Rhymes=Tovasala}}-label" role="navigation" 
	 >
	<h3 id="p-{{#switch:{{NAMESPACE}}{{!}}Voablivrile{{!}}Grammar{{!}}Corpus_{{!}}Entry{{!}}Morpheme{{!}}Rhymes=Tovasala}}-label" class="vector-menu-heading"> <span>{{#switch:{{NAMESPACE}}{{!}}Voablivrile{{!}}Grammar{{!}}Corpus {{!}}Entry{{!}}Morpheme{{!}}Rhymes=Tovasala}}</span>

Either I'll have to wait on a native fix from @Bawolff: or otherwise, or I'll provide a CSS-based solution of my own if it works later. --Slgrandson (talk) 16:42, 9 June 2022 (UTC)

Reply to "Sidebar customisation by namespace"