Merge "Cleanup skin.json and ToC template"

This commit is contained in:
jenkins-bot 2023-05-21 10:04:36 +00:00 committed by Gerrit Code Review
commit ef47d485d7
3 changed files with 7 additions and 4 deletions

View file

@ -1,6 +1,6 @@
<li id="toc-{{anchor}}"
class="vector-toc-list-item vector-toc-level-{{toclevel}}{{#is-top-level-section}}{{^vector-is-collapse-sections-enabled}} vector-toc-list-item-expanded{{/vector-is-collapse-sections-enabled}}{{/is-top-level-section}}">
<a class="vector-toc-link" href="#{{linkAnchor}}{{^linkAnchor}}{{anchor}}{{/linkAnchor}}">
<a class="vector-toc-link" href="#{{linkAnchor}}">
<div class="vector-toc-text">
<span class="vector-toc-numb">{{number}}</span>{{{line}}}</div>
</a>

View file

@ -162,9 +162,6 @@
"MediaWiki\\Skins\\Vector\\": "includes/",
"MediaWiki\\Skins\\Vector\\Tests\\": "tests/phpunit/"
},
"ConfigRegistry": {
"vector": "GlobalVarConfig::newInstance"
},
"DefaultUserOptions": {
"vector-limited-width": 1,
"vector-page-tools-pinned": 1,

View file

@ -25,6 +25,7 @@ const SECTIONS = [
number: '1',
line: 'foo',
anchor: 'foo',
linkAnchor: 'foo',
'is-top-level-section': true,
'is-parent-section': false,
'array-sections': null
@ -33,6 +34,7 @@ const SECTIONS = [
number: '2',
line: 'bar',
anchor: 'bar',
linkAnchor: 'bar',
'is-top-level-section': true,
'is-parent-section': true,
'vector-button-label': 'Toggle bar subsection',
@ -41,6 +43,7 @@ const SECTIONS = [
number: '2.1',
line: 'baz',
anchor: 'baz',
linkAnchor: 'baz',
'is-top-level-section': false,
'is-parent-section': true,
'array-sections': [ {
@ -48,6 +51,7 @@ const SECTIONS = [
number: '2.1.1',
line: 'qux',
anchor: 'qux',
linkAnchor: 'qux',
'is-top-level-section': false,
'is-parent-section': false,
'array-sections': null
@ -58,6 +62,7 @@ const SECTIONS = [
number: '3',
line: 'quux',
anchor: 'quux',
linkAnchor: 'quux',
'is-top-level-section': true,
'is-parent-section': false,
'array-sections': null
@ -371,6 +376,7 @@ describe( 'Table of contents', () => {
number: '4',
line: 'bat',
anchor: 'bat',
linkAnchor: 'bat',
'is-top-level-section': true,
'is-parent-section': false,
'array-sections': null