@sparkdreamnft/sparkdreamjs 0.0.16 → 0.0.17

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.
@@ -1,187 +1,216 @@
1
1
  "use strict";
2
+ //@ts-nocheck
3
+ // HAND-WRITTEN OVERRIDE — overlaid by scripts/codegen.ts after telescope.
4
+ // See ../../commons/v1/tx.amino.ts for the broader rationale.
5
+ //
6
+ // Telescope emits `[]` for empty repeated fields; aminojson on the chain omits
7
+ // them. In forum the offending messages are MsgCreatePost and MsgEditPost,
8
+ // both of which have a repeated `tags` field that's commonly empty.
2
9
  Object.defineProperty(exports, "__esModule", { value: true });
3
10
  exports.AminoConverter = void 0;
4
- //@ts-nocheck
5
11
  const tx_1 = require("./tx");
6
12
  exports.AminoConverter = {
7
13
  "/sparkdream.forum.v1.MsgUpdateParams": {
8
14
  aminoType: "sparkdream/x/forum/MsgUpdateParams",
9
15
  toAmino: tx_1.MsgUpdateParams.toAmino,
10
- fromAmino: tx_1.MsgUpdateParams.fromAmino
16
+ fromAmino: tx_1.MsgUpdateParams.fromAmino,
11
17
  },
12
18
  "/sparkdream.forum.v1.MsgUpdateOperationalParams": {
13
19
  aminoType: "sparkdream/x/forum/MsgUpdateOperationalParams",
14
20
  toAmino: tx_1.MsgUpdateOperationalParams.toAmino,
15
- fromAmino: tx_1.MsgUpdateOperationalParams.fromAmino
21
+ fromAmino: tx_1.MsgUpdateOperationalParams.fromAmino,
16
22
  },
17
23
  "/sparkdream.forum.v1.MsgCreatePost": {
18
24
  aminoType: "sparkdream/x/forum/MsgCreatePost",
19
- toAmino: tx_1.MsgCreatePost.toAmino,
20
- fromAmino: tx_1.MsgCreatePost.fromAmino
25
+ toAmino(message) {
26
+ const obj = {};
27
+ obj.creator = message.creator === "" ? undefined : message.creator;
28
+ obj.category_id = message.categoryId !== BigInt(0) ? message.categoryId?.toString() : undefined;
29
+ obj.parent_id = message.parentId !== BigInt(0) ? message.parentId?.toString() : undefined;
30
+ obj.content = message.content === "" ? undefined : message.content;
31
+ obj.tags = (message.tags?.length ?? 0) > 0
32
+ ? message.tags.map((e) => e)
33
+ : undefined;
34
+ obj.content_type = message.contentType === 0 ? undefined : message.contentType;
35
+ obj.author_bond = message.authorBond === null ? undefined : message.authorBond;
36
+ obj.initiative_id = message.initiativeId !== BigInt(0) ? message.initiativeId?.toString() : undefined;
37
+ return obj;
38
+ },
39
+ fromAmino: tx_1.MsgCreatePost.fromAmino,
21
40
  },
22
41
  "/sparkdream.forum.v1.MsgEditPost": {
23
42
  aminoType: "sparkdream/x/forum/MsgEditPost",
24
- toAmino: tx_1.MsgEditPost.toAmino,
25
- fromAmino: tx_1.MsgEditPost.fromAmino
43
+ toAmino(message) {
44
+ const obj = {};
45
+ obj.creator = message.creator === "" ? undefined : message.creator;
46
+ obj.post_id = message.postId !== BigInt(0) ? message.postId?.toString() : undefined;
47
+ obj.new_content = message.newContent === "" ? undefined : message.newContent;
48
+ obj.tags = (message.tags?.length ?? 0) > 0
49
+ ? message.tags.map((e) => e)
50
+ : undefined;
51
+ obj.content_type = message.contentType === 0 ? undefined : message.contentType;
52
+ return obj;
53
+ },
54
+ fromAmino: tx_1.MsgEditPost.fromAmino,
26
55
  },
27
56
  "/sparkdream.forum.v1.MsgDeletePost": {
28
57
  aminoType: "sparkdream/x/forum/MsgDeletePost",
29
58
  toAmino: tx_1.MsgDeletePost.toAmino,
30
- fromAmino: tx_1.MsgDeletePost.fromAmino
59
+ fromAmino: tx_1.MsgDeletePost.fromAmino,
31
60
  },
32
61
  "/sparkdream.forum.v1.MsgFreezeThread": {
33
62
  aminoType: "sparkdream/x/forum/MsgFreezeThread",
34
63
  toAmino: tx_1.MsgFreezeThread.toAmino,
35
- fromAmino: tx_1.MsgFreezeThread.fromAmino
64
+ fromAmino: tx_1.MsgFreezeThread.fromAmino,
36
65
  },
37
66
  "/sparkdream.forum.v1.MsgUnarchiveThread": {
38
67
  aminoType: "sparkdream/x/forum/MsgUnarchiveThread",
39
68
  toAmino: tx_1.MsgUnarchiveThread.toAmino,
40
- fromAmino: tx_1.MsgUnarchiveThread.fromAmino
69
+ fromAmino: tx_1.MsgUnarchiveThread.fromAmino,
41
70
  },
42
71
  "/sparkdream.forum.v1.MsgPinPost": {
43
72
  aminoType: "sparkdream/x/forum/MsgPinPost",
44
73
  toAmino: tx_1.MsgPinPost.toAmino,
45
- fromAmino: tx_1.MsgPinPost.fromAmino
74
+ fromAmino: tx_1.MsgPinPost.fromAmino,
46
75
  },
47
76
  "/sparkdream.forum.v1.MsgUnpinPost": {
48
77
  aminoType: "sparkdream/x/forum/MsgUnpinPost",
49
78
  toAmino: tx_1.MsgUnpinPost.toAmino,
50
- fromAmino: tx_1.MsgUnpinPost.fromAmino
79
+ fromAmino: tx_1.MsgUnpinPost.fromAmino,
51
80
  },
52
81
  "/sparkdream.forum.v1.MsgLockThread": {
53
82
  aminoType: "sparkdream/x/forum/MsgLockThread",
54
83
  toAmino: tx_1.MsgLockThread.toAmino,
55
- fromAmino: tx_1.MsgLockThread.fromAmino
84
+ fromAmino: tx_1.MsgLockThread.fromAmino,
56
85
  },
57
86
  "/sparkdream.forum.v1.MsgUnlockThread": {
58
87
  aminoType: "sparkdream/x/forum/MsgUnlockThread",
59
88
  toAmino: tx_1.MsgUnlockThread.toAmino,
60
- fromAmino: tx_1.MsgUnlockThread.fromAmino
89
+ fromAmino: tx_1.MsgUnlockThread.fromAmino,
61
90
  },
62
91
  "/sparkdream.forum.v1.MsgMoveThread": {
63
92
  aminoType: "sparkdream/x/forum/MsgMoveThread",
64
93
  toAmino: tx_1.MsgMoveThread.toAmino,
65
- fromAmino: tx_1.MsgMoveThread.fromAmino
94
+ fromAmino: tx_1.MsgMoveThread.fromAmino,
66
95
  },
67
96
  "/sparkdream.forum.v1.MsgFollowThread": {
68
97
  aminoType: "sparkdream/x/forum/MsgFollowThread",
69
98
  toAmino: tx_1.MsgFollowThread.toAmino,
70
- fromAmino: tx_1.MsgFollowThread.fromAmino
99
+ fromAmino: tx_1.MsgFollowThread.fromAmino,
71
100
  },
72
101
  "/sparkdream.forum.v1.MsgUnfollowThread": {
73
102
  aminoType: "sparkdream/x/forum/MsgUnfollowThread",
74
103
  toAmino: tx_1.MsgUnfollowThread.toAmino,
75
- fromAmino: tx_1.MsgUnfollowThread.fromAmino
104
+ fromAmino: tx_1.MsgUnfollowThread.fromAmino,
76
105
  },
77
106
  "/sparkdream.forum.v1.MsgUpvotePost": {
78
107
  aminoType: "sparkdream/x/forum/MsgUpvotePost",
79
108
  toAmino: tx_1.MsgUpvotePost.toAmino,
80
- fromAmino: tx_1.MsgUpvotePost.fromAmino
109
+ fromAmino: tx_1.MsgUpvotePost.fromAmino,
81
110
  },
82
111
  "/sparkdream.forum.v1.MsgDownvotePost": {
83
112
  aminoType: "sparkdream/x/forum/MsgDownvotePost",
84
113
  toAmino: tx_1.MsgDownvotePost.toAmino,
85
- fromAmino: tx_1.MsgDownvotePost.fromAmino
114
+ fromAmino: tx_1.MsgDownvotePost.fromAmino,
86
115
  },
87
116
  "/sparkdream.forum.v1.MsgFlagPost": {
88
117
  aminoType: "sparkdream/x/forum/MsgFlagPost",
89
118
  toAmino: tx_1.MsgFlagPost.toAmino,
90
- fromAmino: tx_1.MsgFlagPost.fromAmino
119
+ fromAmino: tx_1.MsgFlagPost.fromAmino,
91
120
  },
92
121
  "/sparkdream.forum.v1.MsgDismissFlags": {
93
122
  aminoType: "sparkdream/x/forum/MsgDismissFlags",
94
123
  toAmino: tx_1.MsgDismissFlags.toAmino,
95
- fromAmino: tx_1.MsgDismissFlags.fromAmino
124
+ fromAmino: tx_1.MsgDismissFlags.fromAmino,
96
125
  },
97
126
  "/sparkdream.forum.v1.MsgHidePost": {
98
127
  aminoType: "sparkdream/x/forum/MsgHidePost",
99
128
  toAmino: tx_1.MsgHidePost.toAmino,
100
- fromAmino: tx_1.MsgHidePost.fromAmino
129
+ fromAmino: tx_1.MsgHidePost.fromAmino,
101
130
  },
102
131
  "/sparkdream.forum.v1.MsgUnhidePost": {
103
132
  aminoType: "sparkdream/x/forum/MsgUnhidePost",
104
133
  toAmino: tx_1.MsgUnhidePost.toAmino,
105
- fromAmino: tx_1.MsgUnhidePost.fromAmino
134
+ fromAmino: tx_1.MsgUnhidePost.fromAmino,
106
135
  },
107
136
  "/sparkdream.forum.v1.MsgAppealPost": {
108
137
  aminoType: "sparkdream/x/forum/MsgAppealPost",
109
138
  toAmino: tx_1.MsgAppealPost.toAmino,
110
- fromAmino: tx_1.MsgAppealPost.fromAmino
139
+ fromAmino: tx_1.MsgAppealPost.fromAmino,
111
140
  },
112
141
  "/sparkdream.forum.v1.MsgAppealThreadLock": {
113
142
  aminoType: "sparkdream/x/forum/MsgAppealThreadLock",
114
143
  toAmino: tx_1.MsgAppealThreadLock.toAmino,
115
- fromAmino: tx_1.MsgAppealThreadLock.fromAmino
144
+ fromAmino: tx_1.MsgAppealThreadLock.fromAmino,
116
145
  },
117
146
  "/sparkdream.forum.v1.MsgAppealThreadMove": {
118
147
  aminoType: "sparkdream/x/forum/MsgAppealThreadMove",
119
148
  toAmino: tx_1.MsgAppealThreadMove.toAmino,
120
- fromAmino: tx_1.MsgAppealThreadMove.fromAmino
149
+ fromAmino: tx_1.MsgAppealThreadMove.fromAmino,
121
150
  },
122
151
  "/sparkdream.forum.v1.MsgCreateBounty": {
123
152
  aminoType: "sparkdream/x/forum/MsgCreateBounty",
124
153
  toAmino: tx_1.MsgCreateBounty.toAmino,
125
- fromAmino: tx_1.MsgCreateBounty.fromAmino
154
+ fromAmino: tx_1.MsgCreateBounty.fromAmino,
126
155
  },
127
156
  "/sparkdream.forum.v1.MsgAwardBounty": {
128
157
  aminoType: "sparkdream/x/forum/MsgAwardBounty",
129
158
  toAmino: tx_1.MsgAwardBounty.toAmino,
130
- fromAmino: tx_1.MsgAwardBounty.fromAmino
159
+ fromAmino: tx_1.MsgAwardBounty.fromAmino,
131
160
  },
132
161
  "/sparkdream.forum.v1.MsgIncreaseBounty": {
133
162
  aminoType: "sparkdream/x/forum/MsgIncreaseBounty",
134
163
  toAmino: tx_1.MsgIncreaseBounty.toAmino,
135
- fromAmino: tx_1.MsgIncreaseBounty.fromAmino
164
+ fromAmino: tx_1.MsgIncreaseBounty.fromAmino,
136
165
  },
137
166
  "/sparkdream.forum.v1.MsgCancelBounty": {
138
167
  aminoType: "sparkdream/x/forum/MsgCancelBounty",
139
168
  toAmino: tx_1.MsgCancelBounty.toAmino,
140
- fromAmino: tx_1.MsgCancelBounty.fromAmino
169
+ fromAmino: tx_1.MsgCancelBounty.fromAmino,
141
170
  },
142
171
  "/sparkdream.forum.v1.MsgAssignBountyToReply": {
143
172
  aminoType: "sparkdream/x/forum/MsgAssignBountyToReply",
144
173
  toAmino: tx_1.MsgAssignBountyToReply.toAmino,
145
- fromAmino: tx_1.MsgAssignBountyToReply.fromAmino
174
+ fromAmino: tx_1.MsgAssignBountyToReply.fromAmino,
146
175
  },
147
176
  "/sparkdream.forum.v1.MsgPinReply": {
148
177
  aminoType: "sparkdream/x/forum/MsgPinReply",
149
178
  toAmino: tx_1.MsgPinReply.toAmino,
150
- fromAmino: tx_1.MsgPinReply.fromAmino
179
+ fromAmino: tx_1.MsgPinReply.fromAmino,
151
180
  },
152
181
  "/sparkdream.forum.v1.MsgUnpinReply": {
153
182
  aminoType: "sparkdream/x/forum/MsgUnpinReply",
154
183
  toAmino: tx_1.MsgUnpinReply.toAmino,
155
- fromAmino: tx_1.MsgUnpinReply.fromAmino
184
+ fromAmino: tx_1.MsgUnpinReply.fromAmino,
156
185
  },
157
186
  "/sparkdream.forum.v1.MsgDisputePin": {
158
187
  aminoType: "sparkdream/x/forum/MsgDisputePin",
159
188
  toAmino: tx_1.MsgDisputePin.toAmino,
160
- fromAmino: tx_1.MsgDisputePin.fromAmino
189
+ fromAmino: tx_1.MsgDisputePin.fromAmino,
161
190
  },
162
191
  "/sparkdream.forum.v1.MsgMarkAcceptedReply": {
163
192
  aminoType: "sparkdream/x/forum/MsgMarkAcceptedReply",
164
193
  toAmino: tx_1.MsgMarkAcceptedReply.toAmino,
165
- fromAmino: tx_1.MsgMarkAcceptedReply.fromAmino
194
+ fromAmino: tx_1.MsgMarkAcceptedReply.fromAmino,
166
195
  },
167
196
  "/sparkdream.forum.v1.MsgConfirmProposedReply": {
168
197
  aminoType: "sparkdream/x/forum/MsgConfirmProposedReply",
169
198
  toAmino: tx_1.MsgConfirmProposedReply.toAmino,
170
- fromAmino: tx_1.MsgConfirmProposedReply.fromAmino
199
+ fromAmino: tx_1.MsgConfirmProposedReply.fromAmino,
171
200
  },
172
201
  "/sparkdream.forum.v1.MsgRejectProposedReply": {
173
202
  aminoType: "sparkdream/x/forum/MsgRejectProposedReply",
174
203
  toAmino: tx_1.MsgRejectProposedReply.toAmino,
175
- fromAmino: tx_1.MsgRejectProposedReply.fromAmino
204
+ fromAmino: tx_1.MsgRejectProposedReply.fromAmino,
176
205
  },
177
206
  "/sparkdream.forum.v1.MsgSetForumPaused": {
178
207
  aminoType: "sparkdream/x/forum/MsgSetForumPaused",
179
208
  toAmino: tx_1.MsgSetForumPaused.toAmino,
180
- fromAmino: tx_1.MsgSetForumPaused.fromAmino
209
+ fromAmino: tx_1.MsgSetForumPaused.fromAmino,
181
210
  },
182
211
  "/sparkdream.forum.v1.MsgSetModerationPaused": {
183
212
  aminoType: "sparkdream/x/forum/MsgSetModerationPaused",
184
213
  toAmino: tx_1.MsgSetModerationPaused.toAmino,
185
- fromAmino: tx_1.MsgSetModerationPaused.fromAmino
186
- }
214
+ fromAmino: tx_1.MsgSetModerationPaused.fromAmino,
215
+ },
187
216
  };
@@ -12,7 +12,7 @@ export declare const AminoConverter: {
12
12
  };
13
13
  "/sparkdream.rep.v1.MsgInviteMember": {
14
14
  aminoType: string;
15
- toAmino: (message: MsgInviteMember) => import("./tx").MsgInviteMemberAmino;
15
+ toAmino(message: any): any;
16
16
  fromAmino: (object: import("./tx").MsgInviteMemberAmino) => MsgInviteMember;
17
17
  };
18
18
  "/sparkdream.rep.v1.MsgAcceptInvitation": {
@@ -57,7 +57,7 @@ export declare const AminoConverter: {
57
57
  };
58
58
  "/sparkdream.rep.v1.MsgProposeProject": {
59
59
  aminoType: string;
60
- toAmino: (message: MsgProposeProject) => import("./tx").MsgProposeProjectAmino;
60
+ toAmino(message: any): any;
61
61
  fromAmino: (object: import("./tx").MsgProposeProjectAmino) => MsgProposeProject;
62
62
  };
63
63
  "/sparkdream.rep.v1.MsgApproveProjectBudget": {
@@ -72,7 +72,7 @@ export declare const AminoConverter: {
72
72
  };
73
73
  "/sparkdream.rep.v1.MsgCreateInitiative": {
74
74
  aminoType: string;
75
- toAmino: (message: MsgCreateInitiative) => import("./tx").MsgCreateInitiativeAmino;
75
+ toAmino(message: any): any;
76
76
  fromAmino: (object: import("./tx").MsgCreateInitiativeAmino) => MsgCreateInitiative;
77
77
  };
78
78
  "/sparkdream.rep.v1.MsgAssignInitiative": {
@@ -87,7 +87,7 @@ export declare const AminoConverter: {
87
87
  };
88
88
  "/sparkdream.rep.v1.MsgApproveInitiative": {
89
89
  aminoType: string;
90
- toAmino: (message: MsgApproveInitiative) => import("./tx").MsgApproveInitiativeAmino;
90
+ toAmino(message: any): any;
91
91
  fromAmino: (object: import("./tx").MsgApproveInitiativeAmino) => MsgApproveInitiative;
92
92
  };
93
93
  "/sparkdream.rep.v1.MsgAbandonInitiative": {
@@ -122,17 +122,17 @@ export declare const AminoConverter: {
122
122
  };
123
123
  "/sparkdream.rep.v1.MsgCreateChallenge": {
124
124
  aminoType: string;
125
- toAmino: (message: MsgCreateChallenge) => import("./tx").MsgCreateChallengeAmino;
125
+ toAmino(message: any): any;
126
126
  fromAmino: (object: import("./tx").MsgCreateChallengeAmino) => MsgCreateChallenge;
127
127
  };
128
128
  "/sparkdream.rep.v1.MsgRespondToChallenge": {
129
129
  aminoType: string;
130
- toAmino: (message: MsgRespondToChallenge) => import("./tx").MsgRespondToChallengeAmino;
130
+ toAmino(message: any): any;
131
131
  fromAmino: (object: import("./tx").MsgRespondToChallengeAmino) => MsgRespondToChallenge;
132
132
  };
133
133
  "/sparkdream.rep.v1.MsgSubmitJurorVote": {
134
134
  aminoType: string;
135
- toAmino: (message: MsgSubmitJurorVote) => import("./tx").MsgSubmitJurorVoteAmino;
135
+ toAmino(message: any): any;
136
136
  fromAmino: (object: import("./tx").MsgSubmitJurorVoteAmino) => MsgSubmitJurorVote;
137
137
  };
138
138
  "/sparkdream.rep.v1.MsgSubmitExpertTestimony": {
@@ -142,12 +142,12 @@ export declare const AminoConverter: {
142
142
  };
143
143
  "/sparkdream.rep.v1.MsgChallengeContent": {
144
144
  aminoType: string;
145
- toAmino: (message: MsgChallengeContent) => import("./tx").MsgChallengeContentAmino;
145
+ toAmino(message: any): any;
146
146
  fromAmino: (object: import("./tx").MsgChallengeContentAmino) => MsgChallengeContent;
147
147
  };
148
148
  "/sparkdream.rep.v1.MsgRespondToContentChallenge": {
149
149
  aminoType: string;
150
- toAmino: (message: MsgRespondToContentChallenge) => import("./tx").MsgRespondToContentChallengeAmino;
150
+ toAmino(message: any): any;
151
151
  fromAmino: (object: import("./tx").MsgRespondToContentChallengeAmino) => MsgRespondToContentChallenge;
152
152
  };
153
153
  "/sparkdream.rep.v1.MsgRegisterZkPublicKey": {