@gitmyabi/slop 0.0.0-stage → 1.0.0

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.
@@ -0,0 +1,1267 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Slop_json = exports.Slop_jsonAbi = void 0;
4
+ const viem_1 = require("viem");
5
+ /**
6
+ * Slop_json ABI
7
+ *
8
+ * This ABI is typed using viem's type system for full type safety.
9
+ */
10
+ exports.Slop_jsonAbi = [
11
+ {
12
+ "inputs": [
13
+ {
14
+ "internalType": "address",
15
+ "name": "owner_",
16
+ "type": "address"
17
+ }
18
+ ],
19
+ "stateMutability": "nonpayable",
20
+ "type": "constructor"
21
+ },
22
+ {
23
+ "inputs": [],
24
+ "name": "AllowanceOverflow",
25
+ "type": "error"
26
+ },
27
+ {
28
+ "inputs": [],
29
+ "name": "AllowanceUnderflow",
30
+ "type": "error"
31
+ },
32
+ {
33
+ "inputs": [],
34
+ "name": "AlreadyInitialized",
35
+ "type": "error"
36
+ },
37
+ {
38
+ "inputs": [],
39
+ "name": "InsufficientAllowance",
40
+ "type": "error"
41
+ },
42
+ {
43
+ "inputs": [],
44
+ "name": "InsufficientBalance",
45
+ "type": "error"
46
+ },
47
+ {
48
+ "inputs": [],
49
+ "name": "InvalidPermit",
50
+ "type": "error"
51
+ },
52
+ {
53
+ "inputs": [],
54
+ "name": "LaunchInventoryAlreadyMinted",
55
+ "type": "error"
56
+ },
57
+ {
58
+ "inputs": [
59
+ {
60
+ "internalType": "uint256",
61
+ "name": "attemptedSupply",
62
+ "type": "uint256"
63
+ }
64
+ ],
65
+ "name": "MaxSupplyExceeded",
66
+ "type": "error"
67
+ },
68
+ {
69
+ "inputs": [],
70
+ "name": "NewOwnerIsZeroAddress",
71
+ "type": "error"
72
+ },
73
+ {
74
+ "inputs": [],
75
+ "name": "NoHandoverRequest",
76
+ "type": "error"
77
+ },
78
+ {
79
+ "inputs": [
80
+ {
81
+ "internalType": "address",
82
+ "name": "caller",
83
+ "type": "address"
84
+ }
85
+ ],
86
+ "name": "NotMinter",
87
+ "type": "error"
88
+ },
89
+ {
90
+ "inputs": [],
91
+ "name": "Permit2AllowanceIsFixedAtInfinity",
92
+ "type": "error"
93
+ },
94
+ {
95
+ "inputs": [],
96
+ "name": "PermitExpired",
97
+ "type": "error"
98
+ },
99
+ {
100
+ "inputs": [],
101
+ "name": "TotalSupplyOverflow",
102
+ "type": "error"
103
+ },
104
+ {
105
+ "inputs": [],
106
+ "name": "Unauthorized",
107
+ "type": "error"
108
+ },
109
+ {
110
+ "inputs": [],
111
+ "name": "ZeroAddress",
112
+ "type": "error"
113
+ },
114
+ {
115
+ "anonymous": false,
116
+ "inputs": [
117
+ {
118
+ "indexed": true,
119
+ "internalType": "address",
120
+ "name": "owner",
121
+ "type": "address"
122
+ },
123
+ {
124
+ "indexed": true,
125
+ "internalType": "address",
126
+ "name": "spender",
127
+ "type": "address"
128
+ },
129
+ {
130
+ "indexed": false,
131
+ "internalType": "uint256",
132
+ "name": "amount",
133
+ "type": "uint256"
134
+ }
135
+ ],
136
+ "name": "Approval",
137
+ "type": "event"
138
+ },
139
+ {
140
+ "anonymous": false,
141
+ "inputs": [
142
+ {
143
+ "indexed": true,
144
+ "internalType": "address",
145
+ "name": "to",
146
+ "type": "address"
147
+ },
148
+ {
149
+ "indexed": false,
150
+ "internalType": "uint256",
151
+ "name": "amount",
152
+ "type": "uint256"
153
+ }
154
+ ],
155
+ "name": "LaunchInventoryMinted",
156
+ "type": "event"
157
+ },
158
+ {
159
+ "anonymous": false,
160
+ "inputs": [
161
+ {
162
+ "indexed": true,
163
+ "internalType": "address",
164
+ "name": "minter",
165
+ "type": "address"
166
+ },
167
+ {
168
+ "indexed": false,
169
+ "internalType": "bool",
170
+ "name": "allowed",
171
+ "type": "bool"
172
+ }
173
+ ],
174
+ "name": "MinterUpdated",
175
+ "type": "event"
176
+ },
177
+ {
178
+ "anonymous": false,
179
+ "inputs": [
180
+ {
181
+ "indexed": true,
182
+ "internalType": "address",
183
+ "name": "pendingOwner",
184
+ "type": "address"
185
+ }
186
+ ],
187
+ "name": "OwnershipHandoverCanceled",
188
+ "type": "event"
189
+ },
190
+ {
191
+ "anonymous": false,
192
+ "inputs": [
193
+ {
194
+ "indexed": true,
195
+ "internalType": "address",
196
+ "name": "pendingOwner",
197
+ "type": "address"
198
+ }
199
+ ],
200
+ "name": "OwnershipHandoverRequested",
201
+ "type": "event"
202
+ },
203
+ {
204
+ "anonymous": false,
205
+ "inputs": [
206
+ {
207
+ "indexed": true,
208
+ "internalType": "address",
209
+ "name": "oldOwner",
210
+ "type": "address"
211
+ },
212
+ {
213
+ "indexed": true,
214
+ "internalType": "address",
215
+ "name": "newOwner",
216
+ "type": "address"
217
+ }
218
+ ],
219
+ "name": "OwnershipTransferred",
220
+ "type": "event"
221
+ },
222
+ {
223
+ "anonymous": false,
224
+ "inputs": [
225
+ {
226
+ "indexed": true,
227
+ "internalType": "address",
228
+ "name": "from",
229
+ "type": "address"
230
+ },
231
+ {
232
+ "indexed": true,
233
+ "internalType": "address",
234
+ "name": "to",
235
+ "type": "address"
236
+ },
237
+ {
238
+ "indexed": false,
239
+ "internalType": "uint256",
240
+ "name": "amount",
241
+ "type": "uint256"
242
+ }
243
+ ],
244
+ "name": "Transfer",
245
+ "type": "event"
246
+ },
247
+ {
248
+ "inputs": [],
249
+ "name": "DOMAIN_SEPARATOR",
250
+ "outputs": [
251
+ {
252
+ "internalType": "bytes32",
253
+ "name": "result",
254
+ "type": "bytes32"
255
+ }
256
+ ],
257
+ "stateMutability": "view",
258
+ "type": "function"
259
+ },
260
+ {
261
+ "inputs": [],
262
+ "name": "LAUNCH_SUPPLY",
263
+ "outputs": [
264
+ {
265
+ "internalType": "uint256",
266
+ "name": "",
267
+ "type": "uint256"
268
+ }
269
+ ],
270
+ "stateMutability": "view",
271
+ "type": "function"
272
+ },
273
+ {
274
+ "inputs": [],
275
+ "name": "MAX_SUPPLY",
276
+ "outputs": [
277
+ {
278
+ "internalType": "uint256",
279
+ "name": "",
280
+ "type": "uint256"
281
+ }
282
+ ],
283
+ "stateMutability": "view",
284
+ "type": "function"
285
+ },
286
+ {
287
+ "inputs": [
288
+ {
289
+ "internalType": "address",
290
+ "name": "owner",
291
+ "type": "address"
292
+ },
293
+ {
294
+ "internalType": "address",
295
+ "name": "spender",
296
+ "type": "address"
297
+ }
298
+ ],
299
+ "name": "allowance",
300
+ "outputs": [
301
+ {
302
+ "internalType": "uint256",
303
+ "name": "result",
304
+ "type": "uint256"
305
+ }
306
+ ],
307
+ "stateMutability": "view",
308
+ "type": "function"
309
+ },
310
+ {
311
+ "inputs": [
312
+ {
313
+ "internalType": "address",
314
+ "name": "spender",
315
+ "type": "address"
316
+ },
317
+ {
318
+ "internalType": "uint256",
319
+ "name": "amount",
320
+ "type": "uint256"
321
+ }
322
+ ],
323
+ "name": "approve",
324
+ "outputs": [
325
+ {
326
+ "internalType": "bool",
327
+ "name": "",
328
+ "type": "bool"
329
+ }
330
+ ],
331
+ "stateMutability": "nonpayable",
332
+ "type": "function"
333
+ },
334
+ {
335
+ "inputs": [
336
+ {
337
+ "internalType": "address",
338
+ "name": "owner",
339
+ "type": "address"
340
+ }
341
+ ],
342
+ "name": "balanceOf",
343
+ "outputs": [
344
+ {
345
+ "internalType": "uint256",
346
+ "name": "result",
347
+ "type": "uint256"
348
+ }
349
+ ],
350
+ "stateMutability": "view",
351
+ "type": "function"
352
+ },
353
+ {
354
+ "inputs": [
355
+ {
356
+ "internalType": "address",
357
+ "name": "from",
358
+ "type": "address"
359
+ },
360
+ {
361
+ "internalType": "uint256",
362
+ "name": "amount",
363
+ "type": "uint256"
364
+ }
365
+ ],
366
+ "name": "burn",
367
+ "outputs": [],
368
+ "stateMutability": "nonpayable",
369
+ "type": "function"
370
+ },
371
+ {
372
+ "inputs": [],
373
+ "name": "cancelOwnershipHandover",
374
+ "outputs": [],
375
+ "stateMutability": "payable",
376
+ "type": "function"
377
+ },
378
+ {
379
+ "inputs": [
380
+ {
381
+ "internalType": "address",
382
+ "name": "pendingOwner",
383
+ "type": "address"
384
+ }
385
+ ],
386
+ "name": "completeOwnershipHandover",
387
+ "outputs": [],
388
+ "stateMutability": "payable",
389
+ "type": "function"
390
+ },
391
+ {
392
+ "inputs": [],
393
+ "name": "decimals",
394
+ "outputs": [
395
+ {
396
+ "internalType": "uint8",
397
+ "name": "",
398
+ "type": "uint8"
399
+ }
400
+ ],
401
+ "stateMutability": "view",
402
+ "type": "function"
403
+ },
404
+ {
405
+ "inputs": [],
406
+ "name": "launchInventoryMinted",
407
+ "outputs": [
408
+ {
409
+ "internalType": "bool",
410
+ "name": "",
411
+ "type": "bool"
412
+ }
413
+ ],
414
+ "stateMutability": "view",
415
+ "type": "function"
416
+ },
417
+ {
418
+ "inputs": [
419
+ {
420
+ "internalType": "address",
421
+ "name": "to",
422
+ "type": "address"
423
+ },
424
+ {
425
+ "internalType": "uint256",
426
+ "name": "amount",
427
+ "type": "uint256"
428
+ }
429
+ ],
430
+ "name": "mint",
431
+ "outputs": [],
432
+ "stateMutability": "nonpayable",
433
+ "type": "function"
434
+ },
435
+ {
436
+ "inputs": [
437
+ {
438
+ "internalType": "address",
439
+ "name": "to",
440
+ "type": "address"
441
+ }
442
+ ],
443
+ "name": "mintLaunchInventory",
444
+ "outputs": [],
445
+ "stateMutability": "nonpayable",
446
+ "type": "function"
447
+ },
448
+ {
449
+ "inputs": [
450
+ {
451
+ "internalType": "address",
452
+ "name": "",
453
+ "type": "address"
454
+ }
455
+ ],
456
+ "name": "minters",
457
+ "outputs": [
458
+ {
459
+ "internalType": "bool",
460
+ "name": "",
461
+ "type": "bool"
462
+ }
463
+ ],
464
+ "stateMutability": "view",
465
+ "type": "function"
466
+ },
467
+ {
468
+ "inputs": [],
469
+ "name": "name",
470
+ "outputs": [
471
+ {
472
+ "internalType": "string",
473
+ "name": "",
474
+ "type": "string"
475
+ }
476
+ ],
477
+ "stateMutability": "pure",
478
+ "type": "function"
479
+ },
480
+ {
481
+ "inputs": [
482
+ {
483
+ "internalType": "address",
484
+ "name": "owner",
485
+ "type": "address"
486
+ }
487
+ ],
488
+ "name": "nonces",
489
+ "outputs": [
490
+ {
491
+ "internalType": "uint256",
492
+ "name": "result",
493
+ "type": "uint256"
494
+ }
495
+ ],
496
+ "stateMutability": "view",
497
+ "type": "function"
498
+ },
499
+ {
500
+ "inputs": [],
501
+ "name": "owner",
502
+ "outputs": [
503
+ {
504
+ "internalType": "address",
505
+ "name": "result",
506
+ "type": "address"
507
+ }
508
+ ],
509
+ "stateMutability": "view",
510
+ "type": "function"
511
+ },
512
+ {
513
+ "inputs": [
514
+ {
515
+ "internalType": "address",
516
+ "name": "pendingOwner",
517
+ "type": "address"
518
+ }
519
+ ],
520
+ "name": "ownershipHandoverExpiresAt",
521
+ "outputs": [
522
+ {
523
+ "internalType": "uint256",
524
+ "name": "result",
525
+ "type": "uint256"
526
+ }
527
+ ],
528
+ "stateMutability": "view",
529
+ "type": "function"
530
+ },
531
+ {
532
+ "inputs": [
533
+ {
534
+ "internalType": "address",
535
+ "name": "owner",
536
+ "type": "address"
537
+ },
538
+ {
539
+ "internalType": "address",
540
+ "name": "spender",
541
+ "type": "address"
542
+ },
543
+ {
544
+ "internalType": "uint256",
545
+ "name": "value",
546
+ "type": "uint256"
547
+ },
548
+ {
549
+ "internalType": "uint256",
550
+ "name": "deadline",
551
+ "type": "uint256"
552
+ },
553
+ {
554
+ "internalType": "uint8",
555
+ "name": "v",
556
+ "type": "uint8"
557
+ },
558
+ {
559
+ "internalType": "bytes32",
560
+ "name": "r",
561
+ "type": "bytes32"
562
+ },
563
+ {
564
+ "internalType": "bytes32",
565
+ "name": "s",
566
+ "type": "bytes32"
567
+ }
568
+ ],
569
+ "name": "permit",
570
+ "outputs": [],
571
+ "stateMutability": "nonpayable",
572
+ "type": "function"
573
+ },
574
+ {
575
+ "inputs": [],
576
+ "name": "renounceOwnership",
577
+ "outputs": [],
578
+ "stateMutability": "payable",
579
+ "type": "function"
580
+ },
581
+ {
582
+ "inputs": [],
583
+ "name": "requestOwnershipHandover",
584
+ "outputs": [],
585
+ "stateMutability": "payable",
586
+ "type": "function"
587
+ },
588
+ {
589
+ "inputs": [
590
+ {
591
+ "internalType": "address",
592
+ "name": "minter",
593
+ "type": "address"
594
+ },
595
+ {
596
+ "internalType": "bool",
597
+ "name": "allowed",
598
+ "type": "bool"
599
+ }
600
+ ],
601
+ "name": "setMinter",
602
+ "outputs": [],
603
+ "stateMutability": "nonpayable",
604
+ "type": "function"
605
+ },
606
+ {
607
+ "inputs": [],
608
+ "name": "symbol",
609
+ "outputs": [
610
+ {
611
+ "internalType": "string",
612
+ "name": "",
613
+ "type": "string"
614
+ }
615
+ ],
616
+ "stateMutability": "pure",
617
+ "type": "function"
618
+ },
619
+ {
620
+ "inputs": [],
621
+ "name": "totalSupply",
622
+ "outputs": [
623
+ {
624
+ "internalType": "uint256",
625
+ "name": "result",
626
+ "type": "uint256"
627
+ }
628
+ ],
629
+ "stateMutability": "view",
630
+ "type": "function"
631
+ },
632
+ {
633
+ "inputs": [
634
+ {
635
+ "internalType": "address",
636
+ "name": "to",
637
+ "type": "address"
638
+ },
639
+ {
640
+ "internalType": "uint256",
641
+ "name": "amount",
642
+ "type": "uint256"
643
+ }
644
+ ],
645
+ "name": "transfer",
646
+ "outputs": [
647
+ {
648
+ "internalType": "bool",
649
+ "name": "",
650
+ "type": "bool"
651
+ }
652
+ ],
653
+ "stateMutability": "nonpayable",
654
+ "type": "function"
655
+ },
656
+ {
657
+ "inputs": [
658
+ {
659
+ "internalType": "address",
660
+ "name": "from",
661
+ "type": "address"
662
+ },
663
+ {
664
+ "internalType": "address",
665
+ "name": "to",
666
+ "type": "address"
667
+ },
668
+ {
669
+ "internalType": "uint256",
670
+ "name": "amount",
671
+ "type": "uint256"
672
+ }
673
+ ],
674
+ "name": "transferFrom",
675
+ "outputs": [
676
+ {
677
+ "internalType": "bool",
678
+ "name": "",
679
+ "type": "bool"
680
+ }
681
+ ],
682
+ "stateMutability": "nonpayable",
683
+ "type": "function"
684
+ },
685
+ {
686
+ "inputs": [
687
+ {
688
+ "internalType": "address",
689
+ "name": "newOwner",
690
+ "type": "address"
691
+ }
692
+ ],
693
+ "name": "transferOwnership",
694
+ "outputs": [],
695
+ "stateMutability": "payable",
696
+ "type": "function"
697
+ }
698
+ ];
699
+ /**
700
+ * Slop_json Contract Class
701
+ *
702
+ * Provides a class-based API similar to TypeChain for interacting with the contract.
703
+ *
704
+ * @example
705
+ * ```typescript
706
+ * import { createPublicClient, createWalletClient, http } from 'viem';
707
+ * import { mainnet } from 'viem/chains';
708
+ * import { Slop_json } from 'Slop_json';
709
+ *
710
+ * const publicClient = createPublicClient({ chain: mainnet, transport: http() });
711
+ * const walletClient = createWalletClient({ chain: mainnet, transport: http() });
712
+ *
713
+ * const contract = new Slop_json('0x...', { publicClient, walletClient });
714
+ *
715
+ * // Read functions
716
+ * const result = await contract.balanceOf('0x...');
717
+ *
718
+ * // Write functions
719
+ * const hash = await contract.transfer('0x...', 1000n);
720
+ *
721
+ * // Simulate transactions (dry-run)
722
+ * const simulation = await contract.simulate.transfer('0x...', 1000n);
723
+ * console.log('Gas estimate:', simulation.request.gas);
724
+ *
725
+ * // Watch events
726
+ * const unwatch = contract.watch.Transfer((event) => {
727
+ * console.log('Transfer event:', event);
728
+ * });
729
+ * ```
730
+ */
731
+ class Slop_json {
732
+ constructor(address, clients) {
733
+ this.contractAddress = address;
734
+ this.publicClient = clients.publicClient;
735
+ this.contract = (0, viem_1.getContract)({
736
+ address,
737
+ abi: exports.Slop_jsonAbi,
738
+ client: {
739
+ public: clients.publicClient,
740
+ wallet: clients.walletClient,
741
+ },
742
+ });
743
+ }
744
+ /**
745
+ * Get the contract address
746
+ */
747
+ get address() {
748
+ return this.contractAddress;
749
+ }
750
+ /**
751
+ * Get the underlying viem contract instance
752
+ */
753
+ getContract() {
754
+ return this.contract;
755
+ }
756
+ /**
757
+ * DOMAIN_SEPARATOR
758
+ * view
759
+ */
760
+ async DOMAIN_SEPARATOR() {
761
+ return this.contract.read.DOMAIN_SEPARATOR();
762
+ }
763
+ /**
764
+ * LAUNCH_SUPPLY
765
+ * view
766
+ */
767
+ async LAUNCH_SUPPLY() {
768
+ return this.contract.read.LAUNCH_SUPPLY();
769
+ }
770
+ /**
771
+ * MAX_SUPPLY
772
+ * view
773
+ */
774
+ async MAX_SUPPLY() {
775
+ return this.contract.read.MAX_SUPPLY();
776
+ }
777
+ /**
778
+ * allowance
779
+ * view
780
+ */
781
+ async allowance(owner, spender) {
782
+ return this.contract.read.allowance([owner, spender]);
783
+ }
784
+ /**
785
+ * balanceOf
786
+ * view
787
+ */
788
+ async balanceOf(owner) {
789
+ return this.contract.read.balanceOf([owner]);
790
+ }
791
+ /**
792
+ * decimals
793
+ * view
794
+ */
795
+ async decimals() {
796
+ return this.contract.read.decimals();
797
+ }
798
+ /**
799
+ * launchInventoryMinted
800
+ * view
801
+ */
802
+ async launchInventoryMinted() {
803
+ return this.contract.read.launchInventoryMinted();
804
+ }
805
+ /**
806
+ * minters
807
+ * view
808
+ */
809
+ async minters(arg0) {
810
+ return this.contract.read.minters([arg0]);
811
+ }
812
+ /**
813
+ * name
814
+ * pure
815
+ */
816
+ async name() {
817
+ return this.contract.read.name();
818
+ }
819
+ /**
820
+ * nonces
821
+ * view
822
+ */
823
+ async nonces(owner) {
824
+ return this.contract.read.nonces([owner]);
825
+ }
826
+ /**
827
+ * owner
828
+ * view
829
+ */
830
+ async owner() {
831
+ return this.contract.read.owner();
832
+ }
833
+ /**
834
+ * ownershipHandoverExpiresAt
835
+ * view
836
+ */
837
+ async ownershipHandoverExpiresAt(pendingOwner) {
838
+ return this.contract.read.ownershipHandoverExpiresAt([pendingOwner]);
839
+ }
840
+ /**
841
+ * symbol
842
+ * pure
843
+ */
844
+ async symbol() {
845
+ return this.contract.read.symbol();
846
+ }
847
+ /**
848
+ * totalSupply
849
+ * view
850
+ */
851
+ async totalSupply() {
852
+ return this.contract.read.totalSupply();
853
+ }
854
+ /**
855
+ * approve
856
+ * nonpayable
857
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
858
+ */
859
+ async approve(spender, amount, options) {
860
+ if (!this.contract.write) {
861
+ throw new Error('Wallet client is required for write operations');
862
+ }
863
+ return this.contract.write.approve([spender, amount], options);
864
+ }
865
+ /**
866
+ * burn
867
+ * nonpayable
868
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
869
+ */
870
+ async burn(from, amount, options) {
871
+ if (!this.contract.write) {
872
+ throw new Error('Wallet client is required for write operations');
873
+ }
874
+ return this.contract.write.burn([from, amount], options);
875
+ }
876
+ /**
877
+ * cancelOwnershipHandover
878
+ * payable
879
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
880
+ */
881
+ async cancelOwnershipHandover(options) {
882
+ if (!this.contract.write) {
883
+ throw new Error('Wallet client is required for write operations');
884
+ }
885
+ return this.contract.write.cancelOwnershipHandover(options);
886
+ }
887
+ /**
888
+ * completeOwnershipHandover
889
+ * payable
890
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
891
+ */
892
+ async completeOwnershipHandover(pendingOwner, options) {
893
+ if (!this.contract.write) {
894
+ throw new Error('Wallet client is required for write operations');
895
+ }
896
+ return this.contract.write.completeOwnershipHandover([pendingOwner], options);
897
+ }
898
+ /**
899
+ * mint
900
+ * nonpayable
901
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
902
+ */
903
+ async mint(to, amount, options) {
904
+ if (!this.contract.write) {
905
+ throw new Error('Wallet client is required for write operations');
906
+ }
907
+ return this.contract.write.mint([to, amount], options);
908
+ }
909
+ /**
910
+ * mintLaunchInventory
911
+ * nonpayable
912
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
913
+ */
914
+ async mintLaunchInventory(to, options) {
915
+ if (!this.contract.write) {
916
+ throw new Error('Wallet client is required for write operations');
917
+ }
918
+ return this.contract.write.mintLaunchInventory([to], options);
919
+ }
920
+ /**
921
+ * permit
922
+ * nonpayable
923
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
924
+ */
925
+ async permit(owner, spender, value, deadline, v, r, s, options) {
926
+ if (!this.contract.write) {
927
+ throw new Error('Wallet client is required for write operations');
928
+ }
929
+ return this.contract.write.permit([owner, spender, value, deadline, v, r, s], options);
930
+ }
931
+ /**
932
+ * renounceOwnership
933
+ * payable
934
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
935
+ */
936
+ async renounceOwnership(options) {
937
+ if (!this.contract.write) {
938
+ throw new Error('Wallet client is required for write operations');
939
+ }
940
+ return this.contract.write.renounceOwnership(options);
941
+ }
942
+ /**
943
+ * requestOwnershipHandover
944
+ * payable
945
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
946
+ */
947
+ async requestOwnershipHandover(options) {
948
+ if (!this.contract.write) {
949
+ throw new Error('Wallet client is required for write operations');
950
+ }
951
+ return this.contract.write.requestOwnershipHandover(options);
952
+ }
953
+ /**
954
+ * setMinter
955
+ * nonpayable
956
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
957
+ */
958
+ async setMinter(minter, allowed, options) {
959
+ if (!this.contract.write) {
960
+ throw new Error('Wallet client is required for write operations');
961
+ }
962
+ return this.contract.write.setMinter([minter, allowed], options);
963
+ }
964
+ /**
965
+ * transfer
966
+ * nonpayable
967
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
968
+ */
969
+ async transfer(to, amount, options) {
970
+ if (!this.contract.write) {
971
+ throw new Error('Wallet client is required for write operations');
972
+ }
973
+ return this.contract.write.transfer([to, amount], options);
974
+ }
975
+ /**
976
+ * transferFrom
977
+ * nonpayable
978
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
979
+ */
980
+ async transferFrom(from, to, amount, options) {
981
+ if (!this.contract.write) {
982
+ throw new Error('Wallet client is required for write operations');
983
+ }
984
+ return this.contract.write.transferFrom([from, to, amount], options);
985
+ }
986
+ /**
987
+ * transferOwnership
988
+ * payable
989
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
990
+ */
991
+ async transferOwnership(newOwner, options) {
992
+ if (!this.contract.write) {
993
+ throw new Error('Wallet client is required for write operations');
994
+ }
995
+ return this.contract.write.transferOwnership([newOwner], options);
996
+ }
997
+ /**
998
+ * Simulate contract write operations (dry-run without sending transaction)
999
+ *
1000
+ * @example
1001
+ * const result = await contract.simulate.transfer('0x...', 1000n);
1002
+ * console.log('Gas estimate:', result.request.gas);
1003
+ * console.log('Would succeed:', result.result);
1004
+ */
1005
+ get simulate() {
1006
+ const contract = this.contract;
1007
+ if (!contract.simulate) {
1008
+ throw new Error('Public client is required for simulation');
1009
+ }
1010
+ return {
1011
+ /**
1012
+ * Simulate approve
1013
+ * Returns gas estimate and result without sending transaction
1014
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1015
+ */
1016
+ async approve(spender, amount, options) {
1017
+ return contract.simulate.approve([spender, amount], options);
1018
+ },
1019
+ /**
1020
+ * Simulate burn
1021
+ * Returns gas estimate and result without sending transaction
1022
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1023
+ */
1024
+ async burn(from, amount, options) {
1025
+ return contract.simulate.burn([from, amount], options);
1026
+ },
1027
+ /**
1028
+ * Simulate cancelOwnershipHandover
1029
+ * Returns gas estimate and result without sending transaction
1030
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1031
+ */
1032
+ async cancelOwnershipHandover(options) {
1033
+ return contract.simulate.cancelOwnershipHandover(options);
1034
+ },
1035
+ /**
1036
+ * Simulate completeOwnershipHandover
1037
+ * Returns gas estimate and result without sending transaction
1038
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1039
+ */
1040
+ async completeOwnershipHandover(pendingOwner, options) {
1041
+ return contract.simulate.completeOwnershipHandover([pendingOwner], options);
1042
+ },
1043
+ /**
1044
+ * Simulate mint
1045
+ * Returns gas estimate and result without sending transaction
1046
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1047
+ */
1048
+ async mint(to, amount, options) {
1049
+ return contract.simulate.mint([to, amount], options);
1050
+ },
1051
+ /**
1052
+ * Simulate mintLaunchInventory
1053
+ * Returns gas estimate and result without sending transaction
1054
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1055
+ */
1056
+ async mintLaunchInventory(to, options) {
1057
+ return contract.simulate.mintLaunchInventory([to], options);
1058
+ },
1059
+ /**
1060
+ * Simulate permit
1061
+ * Returns gas estimate and result without sending transaction
1062
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1063
+ */
1064
+ async permit(owner, spender, value, deadline, v, r, s, options) {
1065
+ return contract.simulate.permit([owner, spender, value, deadline, v, r, s], options);
1066
+ },
1067
+ /**
1068
+ * Simulate renounceOwnership
1069
+ * Returns gas estimate and result without sending transaction
1070
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1071
+ */
1072
+ async renounceOwnership(options) {
1073
+ return contract.simulate.renounceOwnership(options);
1074
+ },
1075
+ /**
1076
+ * Simulate requestOwnershipHandover
1077
+ * Returns gas estimate and result without sending transaction
1078
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1079
+ */
1080
+ async requestOwnershipHandover(options) {
1081
+ return contract.simulate.requestOwnershipHandover(options);
1082
+ },
1083
+ /**
1084
+ * Simulate setMinter
1085
+ * Returns gas estimate and result without sending transaction
1086
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1087
+ */
1088
+ async setMinter(minter, allowed, options) {
1089
+ return contract.simulate.setMinter([minter, allowed], options);
1090
+ },
1091
+ /**
1092
+ * Simulate transfer
1093
+ * Returns gas estimate and result without sending transaction
1094
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1095
+ */
1096
+ async transfer(to, amount, options) {
1097
+ return contract.simulate.transfer([to, amount], options);
1098
+ },
1099
+ /**
1100
+ * Simulate transferFrom
1101
+ * Returns gas estimate and result without sending transaction
1102
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1103
+ */
1104
+ async transferFrom(from, to, amount, options) {
1105
+ return contract.simulate.transferFrom([from, to, amount], options);
1106
+ },
1107
+ /**
1108
+ * Simulate transferOwnership
1109
+ * Returns gas estimate and result without sending transaction
1110
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1111
+ */
1112
+ async transferOwnership(newOwner, options) {
1113
+ return contract.simulate.transferOwnership([newOwner], options);
1114
+ }
1115
+ };
1116
+ }
1117
+ /**
1118
+ * Watch contract events
1119
+ *
1120
+ * @example
1121
+ * // Watch all Transfer events
1122
+ * const unwatch = contract.watch.Transfer((event) => {
1123
+ * console.log('Transfer:', event);
1124
+ * });
1125
+ *
1126
+ * // Stop watching
1127
+ * unwatch();
1128
+ */
1129
+ get watch() {
1130
+ return {
1131
+ /**
1132
+ * Watch Approval events
1133
+ * @param callback Function to call when event is emitted
1134
+ * @param filter Optional filter for indexed parameters
1135
+ * @returns Unwatch function to stop listening
1136
+ */
1137
+ Approval: (callback, filter) => {
1138
+ return this.publicClient.watchContractEvent({
1139
+ address: this.contractAddress,
1140
+ abi: exports.Slop_jsonAbi,
1141
+ eventName: 'Approval',
1142
+ args: filter,
1143
+ onLogs: (logs) => {
1144
+ logs.forEach((log) => {
1145
+ callback(log.args);
1146
+ });
1147
+ },
1148
+ });
1149
+ },
1150
+ /**
1151
+ * Watch LaunchInventoryMinted events
1152
+ * @param callback Function to call when event is emitted
1153
+ * @param filter Optional filter for indexed parameters
1154
+ * @returns Unwatch function to stop listening
1155
+ */
1156
+ LaunchInventoryMinted: (callback, filter) => {
1157
+ return this.publicClient.watchContractEvent({
1158
+ address: this.contractAddress,
1159
+ abi: exports.Slop_jsonAbi,
1160
+ eventName: 'LaunchInventoryMinted',
1161
+ args: filter,
1162
+ onLogs: (logs) => {
1163
+ logs.forEach((log) => {
1164
+ callback(log.args);
1165
+ });
1166
+ },
1167
+ });
1168
+ },
1169
+ /**
1170
+ * Watch MinterUpdated events
1171
+ * @param callback Function to call when event is emitted
1172
+ * @param filter Optional filter for indexed parameters
1173
+ * @returns Unwatch function to stop listening
1174
+ */
1175
+ MinterUpdated: (callback, filter) => {
1176
+ return this.publicClient.watchContractEvent({
1177
+ address: this.contractAddress,
1178
+ abi: exports.Slop_jsonAbi,
1179
+ eventName: 'MinterUpdated',
1180
+ args: filter,
1181
+ onLogs: (logs) => {
1182
+ logs.forEach((log) => {
1183
+ callback(log.args);
1184
+ });
1185
+ },
1186
+ });
1187
+ },
1188
+ /**
1189
+ * Watch OwnershipHandoverCanceled events
1190
+ * @param callback Function to call when event is emitted
1191
+ * @param filter Optional filter for indexed parameters
1192
+ * @returns Unwatch function to stop listening
1193
+ */
1194
+ OwnershipHandoverCanceled: (callback, filter) => {
1195
+ return this.publicClient.watchContractEvent({
1196
+ address: this.contractAddress,
1197
+ abi: exports.Slop_jsonAbi,
1198
+ eventName: 'OwnershipHandoverCanceled',
1199
+ args: filter,
1200
+ onLogs: (logs) => {
1201
+ logs.forEach((log) => {
1202
+ callback(log.args);
1203
+ });
1204
+ },
1205
+ });
1206
+ },
1207
+ /**
1208
+ * Watch OwnershipHandoverRequested events
1209
+ * @param callback Function to call when event is emitted
1210
+ * @param filter Optional filter for indexed parameters
1211
+ * @returns Unwatch function to stop listening
1212
+ */
1213
+ OwnershipHandoverRequested: (callback, filter) => {
1214
+ return this.publicClient.watchContractEvent({
1215
+ address: this.contractAddress,
1216
+ abi: exports.Slop_jsonAbi,
1217
+ eventName: 'OwnershipHandoverRequested',
1218
+ args: filter,
1219
+ onLogs: (logs) => {
1220
+ logs.forEach((log) => {
1221
+ callback(log.args);
1222
+ });
1223
+ },
1224
+ });
1225
+ },
1226
+ /**
1227
+ * Watch OwnershipTransferred events
1228
+ * @param callback Function to call when event is emitted
1229
+ * @param filter Optional filter for indexed parameters
1230
+ * @returns Unwatch function to stop listening
1231
+ */
1232
+ OwnershipTransferred: (callback, filter) => {
1233
+ return this.publicClient.watchContractEvent({
1234
+ address: this.contractAddress,
1235
+ abi: exports.Slop_jsonAbi,
1236
+ eventName: 'OwnershipTransferred',
1237
+ args: filter,
1238
+ onLogs: (logs) => {
1239
+ logs.forEach((log) => {
1240
+ callback(log.args);
1241
+ });
1242
+ },
1243
+ });
1244
+ },
1245
+ /**
1246
+ * Watch Transfer events
1247
+ * @param callback Function to call when event is emitted
1248
+ * @param filter Optional filter for indexed parameters
1249
+ * @returns Unwatch function to stop listening
1250
+ */
1251
+ Transfer: (callback, filter) => {
1252
+ return this.publicClient.watchContractEvent({
1253
+ address: this.contractAddress,
1254
+ abi: exports.Slop_jsonAbi,
1255
+ eventName: 'Transfer',
1256
+ args: filter,
1257
+ onLogs: (logs) => {
1258
+ logs.forEach((log) => {
1259
+ callback(log.args);
1260
+ });
1261
+ },
1262
+ });
1263
+ }
1264
+ };
1265
+ }
1266
+ }
1267
+ exports.Slop_json = Slop_json;