@iconify-icon/react 1.0.7 → 1.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/iconify.d.ts +1 -1
- package/dist/iconify.js +4 -0
- package/license.txt +1 -1
- package/package.json +9 -9
- package/readme.md +10 -16
- package/tsconfig.common.json +0 -1
package/dist/iconify.d.ts
CHANGED
|
@@ -11,6 +11,6 @@ interface IconifyIconProps extends React.HTMLProps<HTMLElement>, IconifyIconProp
|
|
|
11
11
|
/**
|
|
12
12
|
* React component
|
|
13
13
|
*/
|
|
14
|
-
declare const Icon: React.ForwardRefExoticComponent<
|
|
14
|
+
declare const Icon: React.ForwardRefExoticComponent<Omit<IconifyIconProps, "ref"> & React.RefAttributes<IconifyIconHTMLElement>>;
|
|
15
15
|
|
|
16
16
|
export { Icon, IconifyIconProps };
|
package/dist/iconify.js
CHANGED
|
@@ -18,6 +18,10 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
18
18
|
return to;
|
|
19
19
|
};
|
|
20
20
|
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
21
25
|
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
26
|
mod
|
|
23
27
|
));
|
package/license.txt
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
MIT License
|
|
2
2
|
|
|
3
|
-
Copyright (c) 2022 Vjacheslav Trushkin
|
|
3
|
+
Copyright (c) 2022-PRESENT Vjacheslav Trushkin
|
|
4
4
|
|
|
5
5
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
6
|
of this software and associated documentation files (the "Software"), to deal
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@iconify-icon/react",
|
|
3
3
|
"description": "React wrapper for Iconify Icon web component",
|
|
4
4
|
"author": "Vjacheslav Trushkin",
|
|
5
|
-
"version": "1.0.
|
|
5
|
+
"version": "1.0.8",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"bugs": "https://github.com/iconify/iconify/issues",
|
|
8
8
|
"homepage": "https://iconify.design/",
|
|
@@ -29,19 +29,19 @@
|
|
|
29
29
|
}
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"iconify-icon": "^1.0.
|
|
32
|
+
"iconify-icon": "^1.0.8"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
|
-
"@types/react": "^18.
|
|
35
|
+
"@types/react": "^18.2.8",
|
|
36
36
|
"@types/react-test-renderer": "^18.0.0",
|
|
37
|
-
"@vitejs/plugin-react": "^3.
|
|
38
|
-
"jest": "^29.
|
|
37
|
+
"@vitejs/plugin-react": "^3.1.0",
|
|
38
|
+
"jest": "^29.5.0",
|
|
39
39
|
"react": "^18.2.0",
|
|
40
40
|
"react-test-renderer": "^18.2.0",
|
|
41
|
-
"rimraf": "^
|
|
42
|
-
"tsup": "^6.
|
|
43
|
-
"typescript": "^
|
|
44
|
-
"vitest": "^0.
|
|
41
|
+
"rimraf": "^4.4.1",
|
|
42
|
+
"tsup": "^6.7.0",
|
|
43
|
+
"typescript": "^5.1.3",
|
|
44
|
+
"vitest": "^0.29.8"
|
|
45
45
|
},
|
|
46
46
|
"peerDependencies": {
|
|
47
47
|
"react": ">=16"
|
package/readme.md
CHANGED
|
@@ -4,7 +4,7 @@ Iconify Icon web component is a wrapper for `iconify-icon` package, which provid
|
|
|
4
4
|
|
|
5
5
|
For more information about Iconify project visit [https://iconify.design/](https://iconify.design/).
|
|
6
6
|
|
|
7
|
-
For documentation visit [Iconify Icon web component documentation](https://
|
|
7
|
+
For documentation visit [Iconify Icon web component documentation](https://iconify.design/docs/iconify-icon/).
|
|
8
8
|
|
|
9
9
|
## Installation
|
|
10
10
|
|
|
@@ -36,17 +36,11 @@ Then use `Icon` component with icon name or data as "icon" parameter:
|
|
|
36
36
|
|
|
37
37
|
Component will automatically retrieve data for "mdi-light:home" from Iconify API and render it. There are over 150,000 icons available on Iconify API from various free and open source icon sets, including all the most popular icon sets.
|
|
38
38
|
|
|
39
|
-
## Offline
|
|
39
|
+
## Offline usage
|
|
40
40
|
|
|
41
|
-
|
|
41
|
+
Iconify Icon web component is designed to be used with Iconify API, loading icon data on demand instead of bundling it..
|
|
42
42
|
|
|
43
|
-
If you want to use
|
|
44
|
-
|
|
45
|
-
1. You can import icon data from Iconify Icons packages.
|
|
46
|
-
2. You can create custom icon bundles (more efficient, but requires more coding).
|
|
47
|
-
3. You can host your own Iconify API instead of relying on third party service.
|
|
48
|
-
|
|
49
|
-
See [offline use documentation](https://docs.iconify.design/iconify-icon/without-api.html) or [Iconify API documentation](https://docs.iconify.design/sources/api/).
|
|
43
|
+
If you want to use icons without Iconify API, [there are many other options available](https://iconify.design/docs/usage/).
|
|
50
44
|
|
|
51
45
|
## Icon Names
|
|
52
46
|
|
|
@@ -61,7 +55,7 @@ It has 3 parts, separated by ":":
|
|
|
61
55
|
- prefix is name of icon set.
|
|
62
56
|
- name is name of icon.
|
|
63
57
|
|
|
64
|
-
See [icon names documentation](https://
|
|
58
|
+
See [icon names documentation](https://iconify.design/docs/iconify-icon/icon-name.html) for more detailed explanation.
|
|
65
59
|
|
|
66
60
|
## Using icon data
|
|
67
61
|
|
|
@@ -76,7 +70,7 @@ function renderHomeIcon() {
|
|
|
76
70
|
}
|
|
77
71
|
```
|
|
78
72
|
|
|
79
|
-
See [icon packages documentation](https://
|
|
73
|
+
See [icon packages documentation](https://iconify.design/docs/icons/) for more details.
|
|
80
74
|
|
|
81
75
|
### Next.js notice
|
|
82
76
|
|
|
@@ -96,7 +90,7 @@ import home from '@iconify/icons-mdi-light/home';
|
|
|
96
90
|
|
|
97
91
|
All icons are available as ES modules for modern bundler and as CommonJS modules for outdated bundlers. ES modules use format `@iconify-icons/{prefix}`, CommonJS modules use `@iconify/icons-{prefix}`.
|
|
98
92
|
|
|
99
|
-
For more details, see [icon packages documentation](https://
|
|
93
|
+
For more details, see [icon packages documentation](https://iconify.design/docs/icons/).
|
|
100
94
|
|
|
101
95
|
## Icon component properties
|
|
102
96
|
|
|
@@ -228,7 +222,7 @@ Rotating 16x24 icon by 90 degrees results in:
|
|
|
228
222
|
- CSS transformation keeps 16x24 bounding box, which might cause the icon to overlap text around it.
|
|
229
223
|
- Icon transformation changes bounding box to 24x16, rotating content inside an icon.
|
|
230
224
|
|
|
231
|
-
See [icon transformations documentation](https://
|
|
225
|
+
See [icon transformations documentation](https://iconify.design/docs/iconify-icon/transform.html) for more details.
|
|
232
226
|
|
|
233
227
|
#### Flipping an icon
|
|
234
228
|
|
|
@@ -272,12 +266,12 @@ Examples of 90 degrees rotation:
|
|
|
272
266
|
|
|
273
267
|
## Full documentation
|
|
274
268
|
|
|
275
|
-
For extended documentation visit [Iconify Icon web component documentation](https://
|
|
269
|
+
For extended documentation visit [Iconify Icon web component documentation](https://iconify.design/docs/iconify-icon/).
|
|
276
270
|
|
|
277
271
|
## License
|
|
278
272
|
|
|
279
273
|
React component is released with MIT license.
|
|
280
274
|
|
|
281
|
-
© 2022 Vjacheslav Trushkin
|
|
275
|
+
© 2022-PRESENT Vjacheslav Trushkin
|
|
282
276
|
|
|
283
277
|
See [Iconify icon sets page](https://icon-sets.iconify.design/) for list of icon sets and their licenses.
|