@omnisat/lasereyes 0.0.3 β†’ 0.0.5

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 CHANGED
@@ -1,84 +1,58 @@
1
- # @omnisat/lasereyes
2
- ![Laser Eyes](./lasereyes.png)
1
+ <p align="center">
2
+ <a href="https://lasereyesdocs.vercel.app/">
3
+ <picture>
4
+ <source media="(prefers-color-scheme: dark)" srcset="./lasereyes.png">
5
+ <img alt="Laser Eyes" src="./lasereyes.png" width="auto" height="60">
6
+ </picture>
7
+ </a>
8
+ </p>
3
9
 
4
- # Laser Eyes
5
- ## React Hooks for Bitcoin
10
+ <p align="center">
11
+ <a href="https://www.npmjs.com/package/@omnisat/lasereyes">
12
+ <picture>
13
+ <source media="(prefers-color-scheme: dark)" srcset="https://img.shields.io/npm/v/@omnisat/lasereyes?colorA=21262d&colorB=21262d">
14
+ <img src="https://img.shields.io/npm/v/@omnisat/lasereyes?colorA=f6f8fa&colorB=f6f8fa" alt="Version">
15
+ </picture>
16
+ </a>
17
+ </p>
6
18
 
7
- Laser Eyes is a collection of React Hooks containing everything you need to start working with Bitcoin.
8
- Laser Eyes makes it easy to "Connect" interface with Bitcoin, Inscriptions, balance information, interact with BRC-20s, and more.
19
+ ---
9
20
 
10
- ### Install
21
+ ## Documentation
11
22
 
12
- ```yarn add @omnisat/lasereyes```
23
+ For documentation and guides, visit [Laser Eyes Docs](https://lasereyes.vercel.app/).
13
24
 
14
- ### Usage Overview
15
- ```javascript
25
+ ## Community
16
26
 
17
- import { LaserEyesProvider, createConfig } from '@omnisat/lasereyes'
27
+ For help, discussion about best practices, or any other conversation that would benefit from being searchable:
18
28
 
19
- const config = createConfig({
20
- ...
21
- })
22
-
23
- function App() {
24
- return (
25
- <LaserEyesProvider config={config}>
26
- <Profile />
27
- </LaserEyesProvider>
28
- )
29
- }
30
- ```
29
+ [Discuss Laser Eyes on GitHub](https://github.com/omnisat/lasereyes/discussions)
31
30
 
32
- # Usage
33
- ## how to
31
+ ## Contributing
34
32
 
35
- The following hooks support typed inference:
33
+ Contributions to Wagmi are greatly appreciated! If you're interested in contributing to Wagmi, please read the [Contributing Guide](https://wagmi.sh/dev/contributing) **before submitting a pull request**.
36
34
 
37
- ### Read Methods
35
+ ## Sponsors
38
36
 
39
- connect
40
- ```lasereyes.connect()```
37
+ If you find Laser Eyes useful or use it for work, please consider [sponsoring Laser Eyes](https://github.com/sponsors/omnisat). Thank you πŸ™
41
38
 
42
- Get addresses of current account
43
- ```lasereyes.requestAccounts()```
39
+ <p>
40
+ <a href="https://www.utxo.management/" style="margin-right: 40px;">
41
+ <picture>
42
+ <source media="(prefers-color-scheme: dark)" srcset="./github/main/content/sponsors/utxo-dark-mode.svg">
43
+ <img alt="UTXO Management" src="./github/main/content/sponsors/utxo-dark-mode.svg" width="auto" height="70">
44
+ </picture>
45
+ </a>
46
+ <a href="https://satsventures.com/">
47
+ <picture>
48
+ <source media="(prefers-color-scheme: dark)" srcset="./github/main/content/sponsors/sat-ventures-dark-mode.svg">
49
+ <img alt="Sats Ventures" src="./github/main/content/sponsors/sat-ventures-dark-mode.svg" width="auto" height="70">
50
+ </picture>
51
+ </a>
52
+ </p>
53
+ <br>
44
54
 
45
- Returns testnet or mainnet
46
- ```lasereyes.getNetwork()```
47
-
48
- Get public key of account
49
- ```lasereyes.getPublicKey()```
50
-
51
- Get Balance of current account
52
- ```lasereyes.getBalance()```
53
-
54
- Get All inscriptions
55
- ```lasereyes.getInscriptions()```
56
-
57
- Get All Tokens
58
- ```lasereyes.getAllBRC20Tokens()```
59
-
60
- ### Write Methods
61
-
62
- Send Bitcoin
63
- ```lasereyes.sendBTC(toPK, btc_in_sats, ...)```
64
-
65
- Transferable: The amount has been inscribed into one or more TRANSFER inscriptions (can be transferred immediately).
66
- Available: The amount that is available as a part of a balance (including both minted and received) but not transferable yet.
67
- To spend an available amount, you must first inscribe a certain amount into a TRANSFER inscription.
68
-
69
- The transfer Amount can be calculated by the sum of the chosen amounts of TRANSFER inscriptions.
70
- If you don’t have enough transferable inscriptions, you will need to inscribe them first.
71
-
72
- Once a number of TRANSFER inscriptions are chosen, proceed to send them by asserting an address
73
-
74
- sign the tx to send.
75
-
76
- Sign a message
77
- ```lasereyes.signMessage(...)```
78
-
79
- Sign a single PSBT
80
- ```lasereyes.signPsbt(...)```
81
-
82
- Sign an array of PSBT
83
- ```lasereyes.signPsbts(...)```
55
+ [Sponsor Laser Eyes](https://github.com/sponsors/omnisat)
84
56
 
57
+ <br />
58
+ <br />
package/dist/index.d.ts CHANGED
@@ -79,15 +79,10 @@ type LaserEyesContextType = {
79
79
  disconnect: () => void;
80
80
  requestAccounts: () => Promise<string[]>;
81
81
  getNetwork: () => Promise<string | undefined>;
82
- switchNetwork: (network: 'mainnet' | 'testnet') => Promise<string | undefined>;
82
+ switchNetwork: (network: "mainnet" | "testnet") => Promise<string | undefined>;
83
83
  getPublicKey: () => Promise<string>;
84
84
  getBalance: () => Promise<string>;
85
- getInscriptions: () => Promise<any>;
86
- getAllBRC20Tokens: () => Promise<any>;
87
85
  sendBTC: (to: string, amount: number) => Promise<string>;
88
- payInscribe: () => Promise<void>;
89
- deploy: () => Promise<void>;
90
- mint: () => Promise<void>;
91
86
  signMessage: (message: string) => Promise<string>;
92
87
  signPsbt: (tx: string, finalize?: boolean, broadcast?: boolean) => Promise<string | {
93
88
  signedPsbtHex: string;
@@ -97,15 +92,15 @@ type LaserEyesContextType = {
97
92
  };
98
93
  type Config = {
99
94
  network: string;
100
- provider: string;
101
- chainId: number;
102
95
  };
103
96
 
104
97
  declare const createConfig: (config: Config) => Config;
105
98
 
106
99
  declare const useLaserEyes: () => LaserEyesContextType;
107
- declare const LaserEyesProvider: ({ children }: {
100
+ declare const LaserEyesProvider: ({ children, config, }: {
108
101
  children: ReactNode;
102
+ config: Config;
109
103
  }) => react_jsx_runtime.JSX.Element;
104
+ //# sourceMappingURL=LaserEyesProvider.d.ts.map
110
105
 
111
106
  export { LEATHER, LEATHER_MAINNET, LEATHER_TESTNET, LaserEyesProvider, MAINNET, OYL, P2PKH, P2SH, P2TR, P2WPKH, P2WSH, PHANTOM, TESTNET, UNISAT, UNISAT_MAINNET, UNISAT_TESTNET, WALLETS, XVERSE, XVERSE_MAINNET, XVERSE_NETWORK, XVERSE_TESTNET, createConfig, getLeatherNetwork, getNetworkForLeather, getNetworkForUnisat, getNetworkForXverse, getUnisatNetwork, getXverseNetwork, useLaserEyes };