@miden-sdk/miden-wallet-adapter 0.13.0 → 0.13.2
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 -16
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Miden Wallet Adapter
|
|
2
2
|
|
|
3
|
-
[](https://badge.fury.io/js/@miden-sdk%2Fmiden-wallet-adapter)
|
|
4
4
|
|
|
5
5
|
The **Miden Wallet Adapter** package provides everything you need to integrate the Miden Wallet into your decentralized application (dApp) using React. This package bundles all the core functionality, React integration, UI components, and adapter implementation in a single convenient package.
|
|
6
6
|
|
|
@@ -8,13 +8,13 @@ The **Miden Wallet Adapter** package provides everything you need to integrate t
|
|
|
8
8
|
|
|
9
9
|
```bash
|
|
10
10
|
# npm
|
|
11
|
-
npm install @
|
|
11
|
+
npm install @miden-sdk/miden-wallet-adapter
|
|
12
12
|
|
|
13
13
|
# yarn
|
|
14
|
-
yarn add @
|
|
14
|
+
yarn add @miden-sdk/miden-wallet-adapter
|
|
15
15
|
|
|
16
16
|
# pnpm
|
|
17
|
-
pnpm add @
|
|
17
|
+
pnpm add @miden-sdk/miden-wallet-adapter
|
|
18
18
|
```
|
|
19
19
|
|
|
20
20
|
### Peer Dependencies
|
|
@@ -37,9 +37,9 @@ import {
|
|
|
37
37
|
WalletProvider,
|
|
38
38
|
WalletModalProvider,
|
|
39
39
|
MidenWalletAdapter,
|
|
40
|
-
} from '@
|
|
40
|
+
} from '@miden-sdk/miden-wallet-adapter';
|
|
41
41
|
|
|
42
|
-
import '@
|
|
42
|
+
import '@miden-sdk/miden-wallet-adapter/styles.css';
|
|
43
43
|
|
|
44
44
|
const wallets = [
|
|
45
45
|
new MidenWalletAdapter({ appName: 'Your Miden App' }),
|
|
@@ -62,7 +62,7 @@ function App() {
|
|
|
62
62
|
Use the `WalletMultiButton` for a complete wallet connection experience:
|
|
63
63
|
|
|
64
64
|
```tsx
|
|
65
|
-
import { WalletMultiButton } from '@
|
|
65
|
+
import { WalletMultiButton } from '@miden-sdk/miden-wallet-adapter';
|
|
66
66
|
|
|
67
67
|
function Header() {
|
|
68
68
|
return (
|
|
@@ -81,7 +81,7 @@ Access wallet state and functionality with the `useWallet` hook:
|
|
|
81
81
|
#### Send Transaction
|
|
82
82
|
|
|
83
83
|
```tsx
|
|
84
|
-
import { useWallet, SendTransaction } from '@
|
|
84
|
+
import { useWallet, SendTransaction } from '@miden-sdk/miden-wallet-adapter';
|
|
85
85
|
|
|
86
86
|
function SendComponent() {
|
|
87
87
|
const { wallet, address, connected } = useWallet();
|
|
@@ -121,7 +121,7 @@ function SendComponent() {
|
|
|
121
121
|
#### Custom Transaction
|
|
122
122
|
|
|
123
123
|
```tsx
|
|
124
|
-
import { useWallet, CustomTransaction } from '@
|
|
124
|
+
import { useWallet, CustomTransaction } from '@miden-sdk/miden-wallet-adapter';
|
|
125
125
|
|
|
126
126
|
function CustomTransactionComponent() {
|
|
127
127
|
const { wallet, address, requestTransaction } = useWallet();
|
|
@@ -144,7 +144,7 @@ function CustomTransactionComponent() {
|
|
|
144
144
|
#### Requesting assets and private notes
|
|
145
145
|
|
|
146
146
|
```tsx
|
|
147
|
-
import { useWallet } from '@
|
|
147
|
+
import { useWallet } from '@miden-sdk/miden-wallet-adapter';
|
|
148
148
|
|
|
149
149
|
function AssetsAndNotesComponent() {
|
|
150
150
|
const { wallet, address, requestAssets, requestPrivateNotes } = useWallet();
|
|
@@ -203,16 +203,16 @@ If you prefer more granular control, you can install individual packages:
|
|
|
203
203
|
|
|
204
204
|
```bash
|
|
205
205
|
# Core infrastructure only
|
|
206
|
-
npm install @
|
|
206
|
+
npm install @miden-sdk/miden-wallet-adapter-base
|
|
207
207
|
|
|
208
208
|
# React integration
|
|
209
|
-
npm install @
|
|
209
|
+
npm install @miden-sdk/miden-wallet-adapter-react
|
|
210
210
|
|
|
211
211
|
# UI components
|
|
212
|
-
npm install @
|
|
212
|
+
npm install @miden-sdk/miden-wallet-adapter-reactui
|
|
213
213
|
|
|
214
214
|
# Miden wallet adapter
|
|
215
|
-
npm install @
|
|
215
|
+
npm install @miden-sdk/miden-wallet-adapter-miden
|
|
216
216
|
```
|
|
217
217
|
|
|
218
218
|
## Development
|
|
@@ -238,5 +238,5 @@ MIT
|
|
|
238
238
|
|
|
239
239
|
## Support
|
|
240
240
|
|
|
241
|
-
- [GitHub Issues](https://github.com/
|
|
242
|
-
- [Documentation](https://github.com/
|
|
241
|
+
- [GitHub Issues](https://github.com/0xMiden/miden-wallet-adapter/issues)
|
|
242
|
+
- [Documentation](https://github.com/0xMiden/miden-wallet-adapter)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@miden-sdk/miden-wallet-adapter",
|
|
3
|
-
"version": "0.13.
|
|
3
|
+
"version": "0.13.2",
|
|
4
4
|
"description": "Modular TypeScript wallet adapters and React components for Miden applications.",
|
|
5
5
|
"module": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -13,10 +13,10 @@
|
|
|
13
13
|
"doc": "echo \"(no docs)\""
|
|
14
14
|
},
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"@miden-sdk/miden-wallet-adapter-base": "
|
|
17
|
-
"@miden-sdk/miden-wallet-adapter-miden": "
|
|
18
|
-
"@miden-sdk/miden-wallet-adapter-react": "
|
|
19
|
-
"@miden-sdk/miden-wallet-adapter-reactui": "
|
|
16
|
+
"@miden-sdk/miden-wallet-adapter-base": "^0.13.2",
|
|
17
|
+
"@miden-sdk/miden-wallet-adapter-miden": "^0.13.2",
|
|
18
|
+
"@miden-sdk/miden-wallet-adapter-react": "^0.13.2",
|
|
19
|
+
"@miden-sdk/miden-wallet-adapter-reactui": "^0.13.2"
|
|
20
20
|
},
|
|
21
21
|
"devDependencies": {
|
|
22
22
|
"@types/react-dom": "^19.0.4",
|