Represents an Iconify icon set (collection of icons with a common prefix).
Summary
Functions
Returns the number of icons in the set (excluding aliases).
Decodes a JSON string into this struct.
Decodes a JSON string into this struct, raising on failure.
Dumps this struct into JSON-shaped data, respecting JSON field names.
Builds this struct from a decoded JSON map.
Builds this struct from a decoded JSON map, raising on failure.
Gets an icon from the set by name, resolving aliases and alias transformations.
Gets an icon from the set by name, raising if not found.
Checks if an icon exists in the set.
Lists all icon names in the set (excluding aliases).
Lists all icon names including aliases.
Loads an icon set from a JSON file.
Loads an icon set from a JSON file, raising on error.
Parses an icon set from a JSON string (IconifyJSON format).
Parses an icon set from decoded IconifyJSON data.
Returns a JSON Schema-compatible schema map.
Types
@type t() :: %Iconify.Set{ aliases: %{required(String.t()) => map()}, categories: map() | nil, chars: map() | nil, height: pos_integer(), icons: %{required(String.t()) => Iconify.Icon.t()}, info: map() | nil, last_modified: integer() | nil, left: integer(), not_found: [String.t()], prefix: String.t(), prefixes: map() | nil, provider: String.t() | nil, suffixes: map() | nil, themes: map() | nil, top: integer(), width: pos_integer() }
Functions
@spec count(t()) :: non_neg_integer()
Returns the number of icons in the set (excluding aliases).
Decodes a JSON string into this struct.
Decodes a JSON string into this struct, raising on failure.
Dumps this struct into JSON-shaped data, respecting JSON field names.
Builds this struct from a decoded JSON map.
Builds this struct from a decoded JSON map, raising on failure.
@spec get(t(), String.t()) :: {:ok, Iconify.Icon.t()} | :error
Gets an icon from the set by name, resolving aliases and alias transformations.
@spec get!(t(), String.t()) :: Iconify.Icon.t()
Gets an icon from the set by name, raising if not found.
Checks if an icon exists in the set.
Lists all icon names in the set (excluding aliases).
Lists all icon names including aliases.
Loads an icon set from a JSON file.
Loads an icon set from a JSON file, raising on error.
Parses an icon set from a JSON string (IconifyJSON format).
Parses an icon set from decoded IconifyJSON data.
Returns a JSON Schema-compatible schema map.