@agot/card-preview 1.0.0 → 1.0.1
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 +25 -10
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,16 +1,31 @@
|
|
|
1
|
-
# @
|
|
1
|
+
# @agot/card-preview
|
|
2
2
|
|
|
3
|
-
A
|
|
4
|
-
|
|
5
|
-
This library is installed directly from GitHub.
|
|
3
|
+
A React component library for rendering **A Game of Thrones LCG 2nd Edition** cards. It requires data in an `IRenderCard` format.
|
|
6
4
|
|
|
7
5
|
## 📦 Installation
|
|
8
6
|
|
|
9
|
-
To add this package to your project, run the following command:
|
|
10
|
-
|
|
11
7
|
```bash
|
|
12
|
-
|
|
13
|
-
|
|
8
|
+
npm install @agot/card-preview
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
### Peer Dependencies
|
|
12
|
+
Ensure your host project has the following installed:
|
|
13
|
+
* **react** (^19.1.0)
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## 🛠 Usage
|
|
18
|
+
|
|
19
|
+
Import the `CardPreview` component and provide an `IRenderCard` to display the corresponding card image and data.
|
|
20
|
+
|
|
21
|
+
```tsx
|
|
22
|
+
import { CardPreview } from '@agot/card-preview';
|
|
14
23
|
|
|
15
|
-
|
|
16
|
-
|
|
24
|
+
const App = () => {
|
|
25
|
+
return (
|
|
26
|
+
<CardPreview
|
|
27
|
+
card={{ ... }}
|
|
28
|
+
/>
|
|
29
|
+
);
|
|
30
|
+
};
|
|
31
|
+
```
|