Перейти к содержимому страницы
Переключить меню
Переключить меню настроек
Переключить персональное меню
Вы не представились системе
Ваш IP-адрес будет виден всем, если вы внесёте какие-либо изменения.
Сообщество «Повелителя Тайн»Telegram — новости, дунхуа, игры и мерчDiscord — обсуждение книг и теорий, вопросы по вики

Шаблон:Suplink

Материал из проекта «Повелитель Тайн Вики»
Документация шаблона (для шаблона выше, иногда скрытого или невидимого)
Примечание: части шаблона или весь шаблон могут быть не видны без заданных значений.
Шаблон Документация Использование
Этот шаблон использует Module:Cite (править|история), скрипт на языке Lua.

This template generates chapter tooltips. It's designed for linking books and chapters with a tooltip for additional information.

Usage

{{Suplink|<book>|<chapter>|<format (Optional)>|<class (Optional)>|<parens (Optional)>}}

Parameters

book (required)

  • Specifies the book number (e.g., 1 for Lord of Mysteries).
  • Maps to predefined data in the Lua module.
  • Example: 1, 2.

chapter (optional)

  • Specifies the chapter number within the book.
  • If omitted, the tooltip will display only the book information.
  • Example: 23.

format (optional)

  • Determines how the chapter is displayed:
    • ch: Adds the text "Ch." before the chapter number.
    • Empty or omitted: Displays just the chapter number.

class (optional)

  • CSS class for additional styling.

parens (optional)

  • true to adding parentheses () around the text.

Examples

Basic Usage (Book Only)

Displays the tooltip for book with no chapter.

{{suplink|1}}

yields: Книга 1


Book and Chapter

{{suplink|1|122}}

yields: 122Книга 1


Full Format with Chapter Text

{{suplink|1|122|ch}}

yields: гл. 122Книга 1


Custom Styling with a Class

Displays the tooltip with the CSS class in wiki's stylesheet (e.g., MediaWiki:CommonStyles.css)

{{suplink|1|122|class=caption}}

yields: 122Книга 1


Add parentheses

To add parentheses around the tooltip text

{{suplink|1|122|parens=true}}

yields: (122Книга 1)


Combine all parameters

{{suplink|1|122|ch|class=caption|parens=true}}

yields: (гл. 122Книга 1)


Чтобы изменить этот текст, перейдите на Template:Suplink/doc (как это работает?)