Fire Emblem Heroes Wiki:Widget:FEHUpdateHelper/PagesFromLZList/doc

About
Given a list of .bin.lz that have differed in an update separated by newlines, this widget creates pages for that list using the corresponding files in HertzDevil's feh-assets-json repo. This widget grabs the corresponding JSON files from the repo and passes them as arguments to a lua module on the wiki that anyone can edit, and the output of that module is used by this widget to create pages.

In order to be compatible with this widget, a lua module must have a function that can be invoked from wikitext and returns a JSON representing a list of pages to create in the format of.

To simplify interactions, Module:FEH lang exists so that the language JSONs do not need to be passed into the modules.

There possible types of automation are: "Types.json" means that new types of automation can be added by editing the Types.json file and creating the corresponding modules without needing to edit the widget code. In contrast, "New widget code" means that the interaction is too complex and support can only be added by editing the widget code.

The Types.json file is located at Project:Widget:FEHUpdateHelper/PagesFromLZList/Types.json. The widget reads from that page, so any edits to that page will take effect.

The current Types.json is transcluded below:

Types.json definition

 * id: Unused, but may provide a descriptor for human readers
 * module: The page name of the lua module to use.
 * module_function: The function name from the lua module to invoke.
 * module_arg: The argument name to use for single arg automation types.
 * dirs: An array of strings each representing a directory. If a listed lz file is part of one of these directories, it will be used in this type of automation.
 * singleJSON: The module only needs information from one JSON file to create a page.
 * singleArg: The module only has one argument based on information from the JSON files.

Current progress
Currently supports: Not done yet but possible: Not possible yet (No support in feh-assets-json):
 * Skill pages
 * Coliseum season pages.
 * List of Aether Raids bonuses.
 * Voting Gauntlet pages.
 * Hall of Forms pages.
 * Accessory pages (with empty "Obtained from" section).
 * Some map pages (Story, Paralogues, Tactics Drills, Chain Challenges, Squad Assault).
 * Heroic Grail Heroes (only if "List of available Heroes" section was moved to a template)
 * Grand Conquests pages (because of no  JSON, which contains event availability and rewards).
 * Forging Bonds pages.
 * Røkkr Sieges pages.
 * Mjölnir's Strike pages.