react-magic-card 2.0.2 → 2.0.3
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 +11 -11
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -13,23 +13,23 @@ npm install react-magic-card framer-motion
|
|
|
13
13
|
## Usage Guide
|
|
14
14
|
|
|
15
15
|
```tsx
|
|
16
|
-
import { StraightInfinity } from
|
|
16
|
+
import { StraightInfinity } from 'react-magic-card'
|
|
17
17
|
|
|
18
18
|
function MyComponent() {
|
|
19
19
|
const images = [
|
|
20
20
|
{
|
|
21
|
-
src:
|
|
22
|
-
alt:
|
|
21
|
+
src: '/cat.jpeg',
|
|
22
|
+
alt: 'alt'
|
|
23
23
|
},
|
|
24
24
|
{
|
|
25
|
-
src:
|
|
26
|
-
alt:
|
|
25
|
+
src: '/dog.jpeg',
|
|
26
|
+
alt: 'alt'
|
|
27
27
|
},
|
|
28
28
|
{
|
|
29
|
-
src:
|
|
30
|
-
alt:
|
|
31
|
-
}
|
|
32
|
-
]
|
|
29
|
+
src: '/bird.jpeg',
|
|
30
|
+
alt: 'alt'
|
|
31
|
+
}
|
|
32
|
+
]
|
|
33
33
|
|
|
34
34
|
return (
|
|
35
35
|
<StraightInfinity
|
|
@@ -37,9 +37,9 @@ function MyComponent() {
|
|
|
37
37
|
width={100}
|
|
38
38
|
height={100}
|
|
39
39
|
controller={100}
|
|
40
|
-
start={Math.ceil(images.length / 2)}
|
|
40
|
+
start={Math.ceil(images.length / 2 - 1)}
|
|
41
41
|
/>
|
|
42
|
-
)
|
|
42
|
+
)
|
|
43
43
|
}
|
|
44
44
|
```
|
|
45
45
|
|