mirror of
https://github.com/iconify/iconify.git
synced 2024-12-12 21:57:50 +00:00
Add IconifyJSONPackageExports type for @iconify-json/* packages
This commit is contained in:
parent
cb8b5333be
commit
9216c1b576
4
packages/types/package-lock.json
generated
4
packages/types/package-lock.json
generated
@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "@iconify/types",
|
||||
"version": "1.0.7",
|
||||
"version": "1.0.8",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "@iconify/types",
|
||||
"version": "1.0.7",
|
||||
"version": "1.0.8",
|
||||
"license": "(Apache-2.0 OR GPL-2.0)",
|
||||
"devDependencies": {
|
||||
"typescript": "^4.1.2"
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "@iconify/types",
|
||||
"description": "Types for Iconify data",
|
||||
"version": "1.0.7",
|
||||
"version": "1.0.8",
|
||||
"author": "Vjacheslav Trushkin",
|
||||
"license": "(Apache-2.0 OR GPL-2.0)",
|
||||
"main": "./index.js",
|
||||
|
@ -218,11 +218,9 @@ export interface IconifyMetaData {
|
||||
}
|
||||
|
||||
/**
|
||||
* JSON structure.
|
||||
*
|
||||
* All optional values can exist in root of JSON file, used as defaults.
|
||||
* JSON structure, contains only icon data
|
||||
*/
|
||||
export interface IconifyJSON extends IconifyOptional, IconifyMetaData {
|
||||
export interface IconifyJSONIconsData {
|
||||
// Prefix for icons in JSON file, required.
|
||||
prefix: string;
|
||||
|
||||
@ -234,7 +232,17 @@ export interface IconifyJSON extends IconifyOptional, IconifyMetaData {
|
||||
|
||||
// Optional aliases.
|
||||
aliases?: IconifyAliases;
|
||||
}
|
||||
|
||||
/**
|
||||
* JSON structure.
|
||||
*
|
||||
* All optional values can exist in root of JSON file, used as defaults.
|
||||
*/
|
||||
export interface IconifyJSON
|
||||
extends IconifyJSONIconsData,
|
||||
IconifyOptional,
|
||||
IconifyMetaData {
|
||||
// Optional list of missing icons. Returned by Iconify API when querying for icons that do not exist.
|
||||
not_found?: string[];
|
||||
|
||||
@ -242,3 +250,16 @@ export interface IconifyJSON extends IconifyOptional, IconifyMetaData {
|
||||
// If property exists in both icon and root, use value from icon.
|
||||
// This is used to reduce duplication.
|
||||
}
|
||||
|
||||
/**
|
||||
* Structure of exports '@iconify-json/*' packages.
|
||||
*
|
||||
* These are small packages, one per icon set, that split JSON structure into multiple files to reduce
|
||||
* amount of data imported from package.
|
||||
*/
|
||||
export interface IconifyJSONPackageExports {
|
||||
info: IconifyInfo;
|
||||
icons: IconifyJSON;
|
||||
metadata: IconifyMetaData;
|
||||
chars: IconifyChars;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user