-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #13 from phantom/napas/update-sdk-with-more-settings
feat: Add more settings and documentation
- Loading branch information
Showing
6 changed files
with
67 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@phantom/wallet-sdk": patch | ||
--- | ||
|
||
Add more settings and documentation to the SDK |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,33 @@ | ||
@phantom/wallet-sdk | ||
# @phantom/wallet-sdk | ||
|
||
### Integrating the Embedded Wallet: Getting Started | ||
|
||
1. Install the Phantom SDK (https://github.com/phantom/wallet-sdk) | ||
|
||
```bash | ||
yarn | npm | pnpm add @phantom/wallet-sdk | ||
``` | ||
|
||
1. Load the embedded wallet and the launcher | ||
|
||
```tsx | ||
import { createPhantom } from "@phantom/wallet-sdk" | ||
|
||
const opts: CreatePhantomConfig = { | ||
zIndex: 10_000, | ||
hideLauncherBeforeOnboarded: true, | ||
} | ||
|
||
const App = () => { | ||
useEffect(() => { | ||
createPhantom(opts); | ||
}, []); | ||
... | ||
} | ||
``` | ||
|
||
### Options | ||
|
||
- hideLauncherBeforeOnboarded: Set to true to avoid showing the launcher button until a user has onboarded to the Phantom Wallet. | ||
- zIndex: Pass a custom zIndex to the Phantom Wallet iframe | ||
- colorScheme: If the Phantom Wallet iframe has an opaque background on your site. You should set this color scheme to match the color scheme of your site. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,9 +8,6 @@ | |
"skipLibCheck": true, | ||
"declaration": true, | ||
"outDir": "dist" | ||
|
||
}, | ||
"include": [ | ||
"src" | ||
] | ||
} | ||
"include": ["src"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters