dialog_about

This file contains functions related to the 'About IITC' dialog.

Methods

inner convertPluginInfo(info, index) → {Object}

Converts plugin information into a structured object for easier processing.

Parameters:
Name Type Description
info Object

The plugin information object.

index number

The index of the plugin in the array.

Returns:
Object -

Structured plugin information.

inner createChangelog(plugin) → {string}

Creates a changelog section for a given plugin.

Parameters:
Name Type Description
plugin Object

The plugin for which to create the changelog.

Returns:
string -

HTML string representing the changelog.

inner createDialogContent() → {string}

Creates the content for the 'About IITC' dialog.

Returns:
string -

HTML content for the about dialog.

inner formatVerInfo(p, extraopt) → {string}

Formats version information for plugins and the main script. If an 'extra' parameter is provided and matches the end of the version string, it is removed. This is used to cut off a common timestamp appended to versions. The function also prepares a tooltip showing the build number and date, if available.

Parameters:
Name Type Attributes Description
p Object

The plugin or script object containing version information.

extra string <optional>

An optional extra string to be removed from the version information.

Returns:
string -

Formatted version string with optional HTML tooltip.

inner getIITCVersion() → {string}

Retrieves the IITC version string.

Returns:
string -

The IITC version string.

inner getIITCVersionAddition() → {string}

Extracts the additional version information from the IITC script version.

Returns:
string -

The additional version information, if any.

inner getPlugins() → {string}

Retrieves a list of plugins currently loaded in IITC. The list includes plugin names, versions, and descriptions.

Returns:
string -

Formatted list of plugins in HTML.

inner isShortOnLocalStorage() → {boolean}

Checks if the browser's local storage is running short on available space. This function tries to write a specific amount of data to the local storage and captures any errors. If an error occurs, it is an indication that the local storage has limited free space left.

Returns:
boolean -

Returns true if the local storage is running short on space, otherwise false.

inner isStandardPlugin(plugin) → {boolean}

Checks if a given plugin is a standard plugin based on the build name and date. Standard plugins are those that match the build and date of the main IITC script.

Parameters:
Name Type Description
plugin Object

The plugin object to check.

Returns:
boolean -

True if the plugin is standard, false otherwise.

inner pluginInfoToString(p, extra) → {string}

Converts plugin information into a string format suitable for display in the 'About IITC' dialog.

Parameters:
Name Type Description
p Object

The plugin information object.

extra string

Additional version information.

Returns:
string -

Formatted plugin information string.