///
/**
* Jdenticon
* https://github.com/dmester/jdenticon
* Copyright © Daniel Mester Pirttijärvi
*/
export interface JdenticonConfig {
/**
* Limits the possible hues in generated icons. The hues are specified as an array of hues in degrees. If the
* option is omitted or an empty array is specified, all hues are allowed.
*/
hues?: number[],
/**
* Specifies the lightness of the generated icon.
*/
lightness?: {
/**
* Specifies the lightness range of colored shapes of an icon. The range is expressed as an array
* containing two numbers, representing the minimum and maximum lightness in the range [0.0, 1.0].
*/
color?: number[],
/**
* Specifies the lightness range of grayscale shapes of an icon. The range is expressed as an array
* containing two numbers, representing the minimum and maximum lightness in the range [0.0, 1.0].
*/
grayscale?: number[]
},
/**
* Specifies the saturation of the generated icon.
*
* For backward compatibility a single number can be specified instead of a `{ color, grayscale }`
* object. This single number refers to the saturation of colored shapes.
*/
saturation?: {
/**
* Specifies the saturation of originally colored shapes of an icon. The saturation is expressed as a
* number in the range [0.0, 1.0].
*/
color?: number,
/**
* Specifies the saturation of originally grayscale shapes of an icon. The saturation is expressed as a
* number in the range [0.0, 1.0].
*/
grayscale?: number
} | number,
/**
* Specifies the padding surrounding the icon in percents in the range [0.0, 0.5).
*/
padding?: number;
/**
* Specifies the background color to be rendered behind the icon.
*
* Supported syntaxes are:
* * `"#rgb"`
* * `"#rgba"`
* * `"#rrggbb"`
* * `"#rrggbbaa"`
*/
backColor?: string,
/**
* Specifies when icons will be rendered.
*
* * `"never"` – icons are never rendered automatically. You need to call `jdenticon.update()` manually to
* render identicons.
*
* * `"once"` – icons are rendered once the page has loaded. Any dynamically inserted or modified icons will
* not be rendered unless `jdenticon.update()` is manually called.
*
* * `"observe"` – icons are rendered upon page load, and the DOM is monitored for new icons using a
* `MutationObserver`. Use this if icons are inserted dynamically, e.g. by using Angular, React or
* VanillaJS. This option behaves as `"once"` in IE<11.
*
* @remarks
* This option has no effect in Node environments.
*/
replaceMode?: "never" | "once" | "observe"
}
/**
* Updates the identicon in the specified `