Code Guide/Story Format

=Overview= A guide to convert old story format (tabview) to the new format. Sub/idol stories have a slightly different format compared to main/event/gacha stories.

Main/Event/Gacha Stories
These are the overall steps:
 * 1) Create the chapter list
 * 2) Copy content of the story's cover page to the story's main page
 * 3) Add navigation bar and chapter list on main page
 * 4) Add navigation bars on each chapter page

You can find code/examples for each step below. Sakura Festival is already fully converted, you can use it as reference.

Sub/Idol Stories
These are the overall steps:
 * 1) Create the story list
 * 2) Replace the main page's content with the sub story cover template
 * 3) Add navigation bars on each chapter page

You can find code/examples for each step below. Chiaki's sub story page is already fully converted, you can use it as reference for sub story pages. Eichi's idol story page can act as a reference for idol story pages.

=Chapter List Page= Create a subpage (Story Title/Chapters) with the chapters as a grouped list. Add this code to the end of the page to set the category for this page:

Main/Event/Gacha Stories
List criteria:
 * group by chapter title
 * chapter links are "Ch x" with x being the number
 * separate the chapters with one hyphen
 * a group with one single chapter should be a link

Example: Subpage: Sakura Festival/Chapters
 * Prologue
 * Cherry Blossom Flowers: Ch 1 - Ch 2
 * Cherry Blossom Tree: Ch 1 - Ch 2 - Ch 3
 * Cherry Blossom Banquet: Ch 1 - Ch 2
 * Epilogue

If the chapters don't have titles, create the chapter list like this: Ch 1 - Ch 2 - Ch 3 - Ch 4 - Ch 5 - Ch 6 - Ch 7 - Ch 8

Sub/Idol Stories
The grouped list for sub stories is created with this template: Template:SubStoryList See the documentation on the template's page on how to use it.

=Cover Page=

Main/Event/Gacha Stories
Copy the content of the cover page and replace the story's main page content with it. Pleas don't copy the category at the end of the cover page and don't remove the categories on the main page. Cover page has "/Cover" after the story title, e.g. Fortune Banquet/Cover. Main page is Fortune Banquet, which currently contains the tabview.

=Main Page=

Main/Event/Gacha Stories
After copying over the contents of the cover page: 1. Change the template from "StoryCover" to "StoryCover2". From: {{StoryCover To: {{StoryCover2

2. Then find the "Translation Notes" parameter and add "First Chapter" above. ... ...
 * First Chapter =
 * Translation Notes =

3. Add the name of the first chapter.
 * First Chapter = Prologue

Sub/Idol Stories
Replace the content with this template: Template:SubStoryCover For ! sub stories, use following image: "{character's full name} Anime Chibi" For !! idol stories, use following image: "{character's full name} Work Unit Outfit chibi"

Example:

=Chapter Pages= On the top and bottom of each chapter page, add the StoryNavBar template (the page also has a user doc). The template at the bottom will contain the chapter list for main/event/gacha stories and the story list for sub/idol stories. Please don't put any empty lines between the nav bar and the story. There are two ways to set the link for previous and next chapter depending on the chapter naming format.

Simple Numbering
If the chapter naming format is "Chapter 1", "Chapter 2", etc., putting the number suffices. E.g. on Chapter 2, you would put this code:

If the separator is a different character, e.g. hyphen, you can tell the template by setting the "delim" parameter. E.g. for naming format "Chapter-1", "Chapter-2" etc., the code would look like this:

Chapter Titles
If the chapter naming format doesn't follow simple numbering, you need to put the part of the page title after the slash. E.g. the page title is "Sakura Festival/Cherry Blossom Tree - 1", then you need to put "Cherry Blossom Tree - 1" as value.

Both Numbering and Titles
Both ways to link chapters can be used in the same template as well. E.g. if you are on Chapter 1 and the previous chapter is titled "Prologue" and the next is titled "Chapter 2", it would look like this:

First and Last Chapter
First chapters don't have a previous chapter, so you can leave out the "prev" parameter:

Similarly for last chapters, you can leave out the "next" parameter.

Bottom Navigation Bar
The navigation template at the bottom of a chapter page should display the chapter/story list. The list is added by setting the chapter page to the "chapter list" parameter for main/event/gacha stories and to the "story list" parameter for sub/idol stories:

Example for main/event/gacha story:

Example for sub/idol story: