lucide-preact 0.94.0 → 0.96.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 +16 -14
- package/dist/cjs/lucide-preact.js +55 -1
- package/dist/cjs/lucide-preact.js.map +1 -1
- package/dist/esm/icons/cat.js +21 -0
- package/dist/esm/icons/check-check.js +9 -0
- package/dist/esm/icons/dog.js +21 -0
- package/dist/esm/icons/index.js +3 -0
- package/dist/lucide-preact.d.ts +3 -0
- package/dist/umd/lucide-preact.js +55 -1
- package/dist/umd/lucide-preact.js.map +1 -1
- package/dist/umd/lucide-preact.min.js +2 -2
- package/dist/umd/lucide-preact.min.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -8,9 +8,11 @@ Implementation of the lucide icon library for preact applications.
|
|
|
8
8
|
|
|
9
9
|
```sh
|
|
10
10
|
yarn add lucide-preact
|
|
11
|
+
```
|
|
11
12
|
|
|
12
|
-
|
|
13
|
+
or
|
|
13
14
|
|
|
15
|
+
```sh
|
|
14
16
|
npm install lucide-preact
|
|
15
17
|
```
|
|
16
18
|
|
|
@@ -23,13 +25,13 @@ Each icon can be imported as a preact component.
|
|
|
23
25
|
|
|
24
26
|
You can pass additional props to adjust the icon.
|
|
25
27
|
|
|
26
|
-
```
|
|
28
|
+
```js
|
|
27
29
|
import { Camera } from 'lucide-preact';
|
|
28
30
|
// Returns PreactComponent
|
|
29
31
|
|
|
30
32
|
// Usage
|
|
31
33
|
const App = () => {
|
|
32
|
-
return <Camera color="red" size={48}
|
|
34
|
+
return <Camera color="red" size={48} />;
|
|
33
35
|
};
|
|
34
36
|
|
|
35
37
|
export default App;
|
|
@@ -37,20 +39,20 @@ export default App;
|
|
|
37
39
|
|
|
38
40
|
### Props
|
|
39
41
|
|
|
40
|
-
|
|
|
41
|
-
|
|
|
42
|
-
| `size`
|
|
43
|
-
| `color`
|
|
44
|
-
| `strokeWidth
|
|
42
|
+
| name | type | default |
|
|
43
|
+
| ------------- | -------- | ------------ |
|
|
44
|
+
| `size` | _Number_ | 24 |
|
|
45
|
+
| `color` | _String_ | currentColor |
|
|
46
|
+
| `strokeWidth` | _Number_ | 2 |
|
|
45
47
|
|
|
46
48
|
### Custom props / svg attributes
|
|
47
49
|
|
|
48
50
|
You can also pass custom props that will be added in the as attributes. With that you can modify the icons look by passing svg attributes.
|
|
49
51
|
|
|
50
|
-
```
|
|
52
|
+
```js
|
|
51
53
|
// Usage
|
|
52
54
|
const App = () => {
|
|
53
|
-
return <Camera fill="red" stroke-linejoin="bevel"
|
|
55
|
+
return <Camera fill="red" stroke-linejoin="bevel" />;
|
|
54
56
|
};
|
|
55
57
|
```
|
|
56
58
|
|
|
@@ -60,17 +62,17 @@ const App = () => {
|
|
|
60
62
|
|
|
61
63
|
It is possible to create one generic icon component to load icons.
|
|
62
64
|
|
|
63
|
-
> :warning: Example below importing all EsModules, caution
|
|
65
|
+
> :warning: Example below importing all EsModules, caution using this example, not recommended when you using bundlers, your application build size will grow strongly.
|
|
64
66
|
|
|
65
67
|
#### Icon Component Example
|
|
66
68
|
|
|
67
|
-
```
|
|
69
|
+
```js
|
|
68
70
|
import * as icons from 'lucide-preact';
|
|
69
71
|
|
|
70
|
-
const Icon = ({name, color, size}) => {
|
|
72
|
+
const Icon = ({ name, color, size }) => {
|
|
71
73
|
const LucideIcon = icons[name];
|
|
72
74
|
|
|
73
|
-
return <LucideIcon color={color} size={size}
|
|
75
|
+
return <LucideIcon color={color} size={size} />;
|
|
74
76
|
};
|
|
75
77
|
|
|
76
78
|
export default Icon;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* lucide-preact v0.
|
|
2
|
+
* lucide-preact v0.96.0 - ISC
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
5
|
'use strict';
|
|
@@ -2758,6 +2758,36 @@ const Cast = createPreactComponent('Cast', [['path', {
|
|
|
2758
2758
|
}]]);
|
|
2759
2759
|
var Cast$1 = Cast;
|
|
2760
2760
|
|
|
2761
|
+
const Cat = createPreactComponent('Cat', [['path', {
|
|
2762
|
+
d: 'M14 5.256A8.148 8.148 0 0 0 12 5a9.04 9.04 0 0 0-2 .227M20.098 10c.572 1.068.902 2.24.902 3.444C21 17.89 16.97 21 12 21s-9-3-9-7.556c0-1.251.288-2.41.792-3.444',
|
|
2763
|
+
key: '11yako'
|
|
2764
|
+
}], ['path', {
|
|
2765
|
+
d: 'M3.75 10S2.11 3.58 3.5 3C4.89 2.42 8 3 9.781 5',
|
|
2766
|
+
key: 'h9cbyw'
|
|
2767
|
+
}], ['path', {
|
|
2768
|
+
d: 'M20.172 10.002s1.64-6.42.25-7c-1.39-.58-4.5 0-6.282 2',
|
|
2769
|
+
key: '12ilpl'
|
|
2770
|
+
}], ['path', {
|
|
2771
|
+
d: 'M8 14v.5',
|
|
2772
|
+
key: '1nzgdb'
|
|
2773
|
+
}], ['path', {
|
|
2774
|
+
d: 'M16 14v.5',
|
|
2775
|
+
key: '1lajdz'
|
|
2776
|
+
}], ['path', {
|
|
2777
|
+
d: 'M11.25 16.25h1.5L12 17l-.75-.75Z',
|
|
2778
|
+
key: '12kq1m'
|
|
2779
|
+
}]]);
|
|
2780
|
+
var Cat$1 = Cat;
|
|
2781
|
+
|
|
2782
|
+
const CheckCheck = createPreactComponent('CheckCheck', [['path', {
|
|
2783
|
+
d: 'M18 6 7 17l-5-5',
|
|
2784
|
+
key: '116fxf'
|
|
2785
|
+
}], ['path', {
|
|
2786
|
+
d: 'm22 10-7.5 7.5L13 16',
|
|
2787
|
+
key: 'ke71qq'
|
|
2788
|
+
}]]);
|
|
2789
|
+
var CheckCheck$1 = CheckCheck;
|
|
2790
|
+
|
|
2761
2791
|
const CheckCircle2 = createPreactComponent('CheckCircle2', [['path', {
|
|
2762
2792
|
d: 'M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10z',
|
|
2763
2793
|
key: '14v8dr'
|
|
@@ -4572,6 +4602,27 @@ const Divide = createPreactComponent('Divide', [['circle', {
|
|
|
4572
4602
|
}]]);
|
|
4573
4603
|
var Divide$1 = Divide;
|
|
4574
4604
|
|
|
4605
|
+
const Dog = createPreactComponent('Dog', [['path', {
|
|
4606
|
+
d: 'M10 5.172C10 3.782 8.423 2.679 6.5 3c-2.823.47-4.113 6.006-4 7 .08.703 1.725 1.722 3.656 1 1.261-.472 1.96-1.45 2.344-2.5',
|
|
4607
|
+
key: '19br0u'
|
|
4608
|
+
}], ['path', {
|
|
4609
|
+
d: 'M14.267 5.172c0-1.39 1.577-2.493 3.5-2.172 2.823.47 4.113 6.006 4 7-.08.703-1.725 1.722-3.656 1-1.261-.472-1.855-1.45-2.239-2.5',
|
|
4610
|
+
key: '11n1an'
|
|
4611
|
+
}], ['path', {
|
|
4612
|
+
d: 'M8 14v.5',
|
|
4613
|
+
key: '1nzgdb'
|
|
4614
|
+
}], ['path', {
|
|
4615
|
+
d: 'M16 14v.5',
|
|
4616
|
+
key: '1lajdz'
|
|
4617
|
+
}], ['path', {
|
|
4618
|
+
d: 'M11.25 16.25h1.5L12 17l-.75-.75Z',
|
|
4619
|
+
key: '12kq1m'
|
|
4620
|
+
}], ['path', {
|
|
4621
|
+
d: 'M4.42 11.247A13.152 13.152 0 0 0 4 14.556C4 18.728 7.582 21 12 21s8-2.272 8-6.444c0-1.061-.162-2.2-.493-3.309m-9.243-6.082A8.801 8.801 0 0 1 12 5c.78 0 1.5.108 2.161.306',
|
|
4622
|
+
key: 'wsu29d'
|
|
4623
|
+
}]]);
|
|
4624
|
+
var Dog$1 = Dog;
|
|
4625
|
+
|
|
4575
4626
|
const DollarSign = createPreactComponent('DollarSign', [['line', {
|
|
4576
4627
|
x1: '12',
|
|
4577
4628
|
y1: '2',
|
|
@@ -14529,7 +14580,9 @@ exports.CameraOff = CameraOff$1;
|
|
|
14529
14580
|
exports.Car = Car$1;
|
|
14530
14581
|
exports.Carrot = Carrot$1;
|
|
14531
14582
|
exports.Cast = Cast$1;
|
|
14583
|
+
exports.Cat = Cat$1;
|
|
14532
14584
|
exports.Check = Check$1;
|
|
14585
|
+
exports.CheckCheck = CheckCheck$1;
|
|
14533
14586
|
exports.CheckCircle = CheckCircle$1;
|
|
14534
14587
|
exports.CheckCircle2 = CheckCircle2$1;
|
|
14535
14588
|
exports.CheckSquare = CheckSquare$1;
|
|
@@ -14646,6 +14699,7 @@ exports.Disc = Disc$1;
|
|
|
14646
14699
|
exports.Divide = Divide$1;
|
|
14647
14700
|
exports.DivideCircle = DivideCircle$1;
|
|
14648
14701
|
exports.DivideSquare = DivideSquare$1;
|
|
14702
|
+
exports.Dog = Dog$1;
|
|
14649
14703
|
exports.DollarSign = DollarSign$1;
|
|
14650
14704
|
exports.Download = Download$1;
|
|
14651
14705
|
exports.DownloadCloud = DownloadCloud$1;
|