diff --git a/resources/skins.vector.es6/tableOfContents.js b/resources/skins.vector.es6/tableOfContents.js index a8568762f..c47e515d9 100644 --- a/resources/skins.vector.es6/tableOfContents.js +++ b/resources/skins.vector.es6/tableOfContents.js @@ -5,6 +5,8 @@ */ const templateBody = require( /** @type {string} */ ( './templates/TableOfContents.mustache' ) ); const templateTocLine = require( /** @type {string} */ ( './templates/TableOfContents__line.mustache' ) ); +const templatePinnableElementOpen = require( /** @type {string} */ ( './templates/PinnableElement/Open.mustache' ) ); +const templatePinnableElementClose = require( /** @type {string} */ ( './templates/PinnableElement/Close.mustache' ) ); /** * TableOfContents Config object for filling mustache templates */ @@ -462,12 +464,14 @@ module.exports = function tableOfContents( props ) { // @ts-ignore const mustacheCompiler = mw.template.getCompiler( 'mustache' ); const compiledTemplateBody = mustacheCompiler.compile( templateBody ); - const compiledTemplateTocLine = mustacheCompiler.compile( templateTocLine ); // Identifier 'TableOfContents__line' is not in camel case // (template name is 'TableOfContents__line') const partials = { - TableOfContents__line: compiledTemplateTocLine // eslint-disable-line camelcase + // eslint-disable-next-line camelcase + TableOfContents__line: mustacheCompiler.compile( templateTocLine ), + 'PinnableElement/Open': mustacheCompiler.compile( templatePinnableElementOpen ), + 'PinnableElement/Close': mustacheCompiler.compile( templatePinnableElementClose ) }; return compiledTemplateBody.render( data, partials ).html(); diff --git a/skin.json b/skin.json index 78e52a354..541b2b099 100644 --- a/skin.json +++ b/skin.json @@ -365,6 +365,16 @@ "VectorTableOfContentsBeginning" ] }, + { + "name": "resources/skins.vector.es6/templates/PinnableElement/Open.mustache", + "file": "includes/templates/PinnableElement/Open.mustache", + "type": "text" + }, + { + "name": "resources/skins.vector.es6/templates/PinnableElement/Close.mustache", + "file": "includes/templates/PinnableElement/Close.mustache", + "type": "text" + }, { "name": "resources/skins.vector.es6/templates/TableOfContents.mustache", "file": "includes/templates/TableOfContents.mustache",