lucide-static 0.95.0 → 0.97.0
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/README.md +32 -32
- package/font/lucide-preview.html +1802 -1517
- package/font/lucide.css +796 -758
- package/font/lucide.eot +0 -0
- package/font/lucide.svg +1124 -767
- package/font/lucide.ttf +0 -0
- package/font/lucide.woff +0 -0
- package/font/lucide.woff2 +0 -0
- package/icon-nodes.json +742 -20
- package/icons/bean-off.svg +16 -0
- package/icons/bean.svg +14 -0
- package/icons/candy-off.svg +20 -0
- package/icons/candy.svg +17 -0
- package/icons/check-check.svg +14 -0
- package/icons/dna-off.svg +23 -0
- package/icons/dna.svg +23 -0
- package/icons/egg-off.svg +15 -0
- package/icons/flask-conical-off.svg +18 -0
- package/icons/flask-conical.svg +1 -1
- package/icons/hop-off.svg +20 -0
- package/icons/hop.svg +20 -0
- package/icons/milk-off.svg +16 -0
- package/icons/milk.svg +15 -0
- package/icons/nut-off.svg +17 -0
- package/icons/nut.svg +15 -0
- package/icons/vegan.svg +15 -0
- package/icons/wheat-off.svg +22 -0
- package/icons/wheat.svg +20 -0
- package/icons/wine-off.svg +17 -0
- package/lib/icons/bean-off.js +17 -0
- package/lib/icons/bean.js +15 -0
- package/lib/icons/candy-off.js +21 -0
- package/lib/icons/candy.js +18 -0
- package/lib/icons/check-check.js +15 -0
- package/lib/icons/dna-off.js +24 -0
- package/lib/icons/dna.js +24 -0
- package/lib/icons/egg-off.js +16 -0
- package/lib/icons/flask-conical-off.js +19 -0
- package/lib/icons/flask-conical.js +1 -1
- package/lib/icons/hop-off.js +21 -0
- package/lib/icons/hop.js +21 -0
- package/lib/icons/milk-off.js +17 -0
- package/lib/icons/milk.js +16 -0
- package/lib/icons/nut-off.js +18 -0
- package/lib/icons/nut.js +16 -0
- package/lib/icons/vegan.js +16 -0
- package/lib/icons/wheat-off.js +23 -0
- package/lib/icons/wheat.js +21 -0
- package/lib/icons/wine-off.js +18 -0
- package/lib/index.js +19 -0
- package/package.json +1 -1
- package/sprite.svg +148 -1
- package/tags.json +146 -6
package/README.md
CHANGED
|
@@ -21,23 +21,25 @@ This package is suitable for very specific use cases for example if you want to
|
|
|
21
21
|
|
|
22
22
|
```sh
|
|
23
23
|
yarn add lucide-static
|
|
24
|
+
```
|
|
24
25
|
|
|
25
|
-
|
|
26
|
+
or
|
|
26
27
|
|
|
28
|
+
```sh
|
|
27
29
|
npm install lucide-static
|
|
28
30
|
```
|
|
29
31
|
|
|
30
32
|
### CDN
|
|
31
33
|
|
|
32
|
-
```
|
|
34
|
+
```html
|
|
33
35
|
<!-- Svg File -->
|
|
34
|
-
<img src="https://unpkg.com/lucide-static@latest/icons/home.svg"
|
|
36
|
+
<img src="https://unpkg.com/lucide-static@latest/icons/home.svg" />
|
|
35
37
|
|
|
36
38
|
<!-- Icon Font -->
|
|
37
39
|
<style>
|
|
38
40
|
@font-face {
|
|
39
|
-
font-family:
|
|
40
|
-
src: url(https://unpkg.com/lucide-static@latest/font/Lucide.ttf) format(
|
|
41
|
+
font-family: 'LucideIcons';
|
|
42
|
+
src: url(https://unpkg.com/lucide-static@latest/font/Lucide.ttf) format('truetype');
|
|
41
43
|
}
|
|
42
44
|
</style>
|
|
43
45
|
```
|
|
@@ -52,16 +54,17 @@ Checkout the [codesandbox examples](https://codesandbox.io/s/using-the-svg-sprit
|
|
|
52
54
|
|
|
53
55
|
To use it in for example html:
|
|
54
56
|
|
|
55
|
-
```
|
|
57
|
+
```html
|
|
56
58
|
<!-- Svg File -->
|
|
57
|
-
<img src="~lucide-static/icons/home.svg"
|
|
59
|
+
<img src="~lucide-static/icons/home.svg" />
|
|
58
60
|
```
|
|
59
61
|
|
|
60
|
-
```
|
|
62
|
+
```css
|
|
61
63
|
.home-icon {
|
|
62
|
-
background-image: url(~lucide-static/icons/home.svg)
|
|
64
|
+
background-image: url(~lucide-static/icons/home.svg);
|
|
63
65
|
}
|
|
64
66
|
```
|
|
67
|
+
|
|
65
68
|
Make sure you have the correct webpack loaders to make this work. [url-loader](https://v4.webpack.js.org/loaders/url-loader/)
|
|
66
69
|
|
|
67
70
|
#### Svg file Inline
|
|
@@ -70,7 +73,7 @@ You can simply import each svg by targeting `lucide-static/icons/{icon-name}.svg
|
|
|
70
73
|
To use svgs in your project you can for example use a [svg loader](https://v4.webpack.js.org/loaders/svg-inline-loader/).
|
|
71
74
|
|
|
72
75
|
```js
|
|
73
|
-
import arrowRightIcon from 'lucide-static/icons/arrow-right'
|
|
76
|
+
import arrowRightIcon from 'lucide-static/icons/arrow-right';
|
|
74
77
|
|
|
75
78
|
// return string of a svg
|
|
76
79
|
```
|
|
@@ -81,7 +84,7 @@ You may need additional loader for this.
|
|
|
81
84
|
|
|
82
85
|
```html
|
|
83
86
|
<!-- Icon Sprite, not recommended for production! -->
|
|
84
|
-
<img src="lucide-static/sprite.svg#home"
|
|
87
|
+
<img src="lucide-static/sprite.svg#home" />
|
|
85
88
|
|
|
86
89
|
<!-- or -->
|
|
87
90
|
<svg
|
|
@@ -96,22 +99,20 @@ You may need additional loader for this.
|
|
|
96
99
|
<use href="#alert-triangle" />
|
|
97
100
|
</svg>
|
|
98
101
|
|
|
99
|
-
<svg>
|
|
100
|
-
...sprite svg
|
|
101
|
-
</svg>
|
|
102
|
+
<svg>...sprite svg</svg>
|
|
102
103
|
```
|
|
103
104
|
|
|
104
105
|
If you'd prefer, you can use CSS to hold your base SVG properties
|
|
105
106
|
|
|
106
107
|
```css
|
|
107
108
|
.lucide-icon {
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
109
|
+
width: 24px;
|
|
110
|
+
height: 24px;
|
|
111
|
+
stroke: currentColor;
|
|
112
|
+
fill: none;
|
|
113
|
+
stroke-width: 2;
|
|
114
|
+
stroke-linecap: round;
|
|
115
|
+
stroke-linejoin: round;
|
|
115
116
|
}
|
|
116
117
|
```
|
|
117
118
|
|
|
@@ -134,20 +135,19 @@ and update the svg as follows
|
|
|
134
135
|
### Icon Font
|
|
135
136
|
|
|
136
137
|
```css
|
|
137
|
-
@import(
|
|
138
|
+
@import ('~lucide-static/font/Lucide.css');
|
|
138
139
|
```
|
|
139
140
|
|
|
140
141
|
```html
|
|
141
142
|
<div class="icon-home"></div>
|
|
142
143
|
```
|
|
143
144
|
|
|
144
|
-
|
|
145
145
|
### Node.js
|
|
146
146
|
|
|
147
147
|
To use lucide icons in your Nodejs project you can import each icon as:
|
|
148
148
|
|
|
149
149
|
```js
|
|
150
|
-
const { messageSquare } = require('lucide-static/lib')
|
|
150
|
+
const { messageSquare } = require('lucide-static/lib');
|
|
151
151
|
```
|
|
152
152
|
|
|
153
153
|
> Note: Each icon name is in camelCase.
|
|
@@ -155,10 +155,10 @@ const { messageSquare } = require('lucide-static/lib')
|
|
|
155
155
|
#### Example in node.js project
|
|
156
156
|
|
|
157
157
|
```js
|
|
158
|
-
const express = require('express')
|
|
159
|
-
const { messageSquare } = require('lucide-static/lib')
|
|
160
|
-
const app = express()
|
|
161
|
-
const port = 3000
|
|
158
|
+
const express = require('express');
|
|
159
|
+
const { messageSquare } = require('lucide-static/lib');
|
|
160
|
+
const app = express();
|
|
161
|
+
const port = 3000;
|
|
162
162
|
|
|
163
163
|
app.get('/', (req, res) => {
|
|
164
164
|
res.send(`
|
|
@@ -173,12 +173,12 @@ app.get('/', (req, res) => {
|
|
|
173
173
|
|
|
174
174
|
</body>
|
|
175
175
|
</html>
|
|
176
|
-
`)
|
|
177
|
-
})
|
|
176
|
+
`);
|
|
177
|
+
});
|
|
178
178
|
|
|
179
179
|
app.listen(port, () => {
|
|
180
|
-
console.log(`Example app listening at http://localhost:${port}`)
|
|
181
|
-
})
|
|
180
|
+
console.log(`Example app listening at http://localhost:${port}`);
|
|
181
|
+
});
|
|
182
182
|
```
|
|
183
183
|
|
|
184
184
|
## Contributing
|