Skip to content

Commit 5be19bb

Browse files
committed
Merge branch 'bundle-file-path' of github.com:Zetazzz/ts-codegen into bundle-file-path
2 parents 01c9c9d + 5760791 commit 5be19bb

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+2603
-144
lines changed

.yarnrc.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
enableGlobalCache: true
2+
3+
nodeLinker: node-modules
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
/**
2+
* This file was automatically generated by @cosmwasm/ts-codegen@latest.
3+
* DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,
4+
* and run the @cosmwasm/ts-codegen generate command to regenerate this file.
5+
*/
6+
7+
import { ExecuteMsg, Binary, InstantiateMsg, QueryMsg } from "./CwAdminFactory.types";
8+
import { CamelCasedProperties } from "type-fest";
9+
export abstract class CwAdminFactoryExecuteMsgBuilder {
10+
static instantiateContractWithSelfAdmin = ({
11+
codeId,
12+
instantiateMsg,
13+
label
14+
}: CamelCasedProperties<Extract<ExecuteMsg, {
15+
instantiate_contract_with_self_admin: unknown;
16+
}>["instantiate_contract_with_self_admin"]>): ExecuteMsg => {
17+
return {
18+
instantiate_contract_with_self_admin: ({
19+
code_id: codeId,
20+
instantiate_msg: instantiateMsg,
21+
label
22+
} as const)
23+
};
24+
};
25+
}
Lines changed: 133 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,133 @@
1+
/**
2+
* This file was automatically generated by @cosmwasm/ts-codegen@latest.
3+
* DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,
4+
* and run the @cosmwasm/ts-codegen generate command to regenerate this file.
5+
*/
6+
7+
import { Addr, PaymentInfo, Uint128, ConfigResponse, ExecuteMsg, Binary, Cw20ReceiveMsg, GetRegistrationResponse, Registration, InfoForCodeIdResponse, InstantiateMsg, ListRegistrationsResponse, QueryMsg, ReceiveMsg } from "./CwCodeIdRegistry.types";
8+
import { CamelCasedProperties } from "type-fest";
9+
export abstract class CwCodeIdRegistryExecuteMsgBuilder {
10+
static receive = ({
11+
amount,
12+
msg,
13+
sender
14+
}: CamelCasedProperties<Extract<ExecuteMsg, {
15+
receive: unknown;
16+
}>["receive"]>): ExecuteMsg => {
17+
return {
18+
receive: ({
19+
amount,
20+
msg,
21+
sender
22+
} as const)
23+
};
24+
};
25+
static register = ({
26+
chainId,
27+
checksum,
28+
codeId,
29+
name,
30+
version
31+
}: CamelCasedProperties<Extract<ExecuteMsg, {
32+
register: unknown;
33+
}>["register"]>): ExecuteMsg => {
34+
return {
35+
register: ({
36+
chain_id: chainId,
37+
checksum,
38+
code_id: codeId,
39+
name,
40+
version
41+
} as const)
42+
};
43+
};
44+
static setOwner = ({
45+
chainId,
46+
name,
47+
owner
48+
}: CamelCasedProperties<Extract<ExecuteMsg, {
49+
set_owner: unknown;
50+
}>["set_owner"]>): ExecuteMsg => {
51+
return {
52+
set_owner: ({
53+
chain_id: chainId,
54+
name,
55+
owner
56+
} as const)
57+
};
58+
};
59+
static unregister = ({
60+
chainId,
61+
codeId
62+
}: CamelCasedProperties<Extract<ExecuteMsg, {
63+
unregister: unknown;
64+
}>["unregister"]>): ExecuteMsg => {
65+
return {
66+
unregister: ({
67+
chain_id: chainId,
68+
code_id: codeId
69+
} as const)
70+
};
71+
};
72+
static updateConfig = ({
73+
admin,
74+
paymentInfo
75+
}: CamelCasedProperties<Extract<ExecuteMsg, {
76+
update_config: unknown;
77+
}>["update_config"]>): ExecuteMsg => {
78+
return {
79+
update_config: ({
80+
admin,
81+
payment_info: paymentInfo
82+
} as const)
83+
};
84+
};
85+
}
86+
export abstract class CwCodeIdRegistryQueryMsgBuilder {
87+
static config = (): QueryMsg => {
88+
return {
89+
config: ({} as const)
90+
};
91+
};
92+
static getRegistration = ({
93+
chainId,
94+
name,
95+
version
96+
}: CamelCasedProperties<Extract<QueryMsg, {
97+
get_registration: unknown;
98+
}>["get_registration"]>): QueryMsg => {
99+
return {
100+
get_registration: ({
101+
chain_id: chainId,
102+
name,
103+
version
104+
} as const)
105+
};
106+
};
107+
static infoForCodeId = ({
108+
chainId,
109+
codeId
110+
}: CamelCasedProperties<Extract<QueryMsg, {
111+
info_for_code_id: unknown;
112+
}>["info_for_code_id"]>): QueryMsg => {
113+
return {
114+
info_for_code_id: ({
115+
chain_id: chainId,
116+
code_id: codeId
117+
} as const)
118+
};
119+
};
120+
static listRegistrations = ({
121+
chainId,
122+
name
123+
}: CamelCasedProperties<Extract<QueryMsg, {
124+
list_registrations: unknown;
125+
}>["list_registrations"]>): QueryMsg => {
126+
return {
127+
list_registrations: ({
128+
chain_id: chainId,
129+
name
130+
} as const)
131+
};
132+
};
133+
}
Lines changed: 219 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,219 @@
1+
/**
2+
* This file was automatically generated by @cosmwasm/ts-codegen@latest.
3+
* DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,
4+
* and run the @cosmwasm/ts-codegen generate command to regenerate this file.
5+
*/
6+
7+
import { Addr, Uint128, Duration, Threshold, PercentageThreshold, Decimal, ConfigResponse, CheckedDepositInfo, ExecuteMsg, CosmosMsgForEmpty, BankMsg, StakingMsg, DistributionMsg, Binary, IbcMsg, Timestamp, Uint64, WasmMsg, GovMsg, VoteOption, Vote, DepositToken, Coin, Empty, IbcTimeout, IbcTimeoutBlock, DepositInfo, GovernanceModulesResponse, InfoResponse, ContractVersion, InstantiateMsg, Expiration, Status, ListProposalsResponse, ProposalResponse, Proposal, Votes, ListVotesResponse, VoteInfo, MigrateMsg, ProposalCountResponse, ProposalHooksResponse, QueryMsg, ReverseProposalsResponse, VoteHooksResponse, VoteResponse } from "./CwSingle.types";
8+
import { CamelCasedProperties } from "type-fest";
9+
export abstract class CwSingleExecuteMsgBuilder {
10+
static propose = ({
11+
description,
12+
msgs,
13+
title
14+
}: CamelCasedProperties<Extract<ExecuteMsg, {
15+
propose: unknown;
16+
}>["propose"]>): ExecuteMsg => {
17+
return {
18+
propose: ({
19+
description,
20+
msgs,
21+
title
22+
} as const)
23+
};
24+
};
25+
static vote = ({
26+
proposalId,
27+
vote
28+
}: CamelCasedProperties<Extract<ExecuteMsg, {
29+
vote: unknown;
30+
}>["vote"]>): ExecuteMsg => {
31+
return {
32+
vote: ({
33+
proposal_id: proposalId,
34+
vote
35+
} as const)
36+
};
37+
};
38+
static execute = ({
39+
proposalId
40+
}: CamelCasedProperties<Extract<ExecuteMsg, {
41+
execute: unknown;
42+
}>["execute"]>): ExecuteMsg => {
43+
return {
44+
execute: ({
45+
proposal_id: proposalId
46+
} as const)
47+
};
48+
};
49+
static close = ({
50+
proposalId
51+
}: CamelCasedProperties<Extract<ExecuteMsg, {
52+
close: unknown;
53+
}>["close"]>): ExecuteMsg => {
54+
return {
55+
close: ({
56+
proposal_id: proposalId
57+
} as const)
58+
};
59+
};
60+
static updateConfig = ({
61+
allowRevoting,
62+
dao,
63+
depositInfo,
64+
maxVotingPeriod,
65+
minVotingPeriod,
66+
onlyMembersExecute,
67+
threshold
68+
}: CamelCasedProperties<Extract<ExecuteMsg, {
69+
update_config: unknown;
70+
}>["update_config"]>): ExecuteMsg => {
71+
return {
72+
update_config: ({
73+
allow_revoting: allowRevoting,
74+
dao,
75+
deposit_info: depositInfo,
76+
max_voting_period: maxVotingPeriod,
77+
min_voting_period: minVotingPeriod,
78+
only_members_execute: onlyMembersExecute,
79+
threshold
80+
} as const)
81+
};
82+
};
83+
static addProposalHook = ({
84+
address
85+
}: CamelCasedProperties<Extract<ExecuteMsg, {
86+
add_proposal_hook: unknown;
87+
}>["add_proposal_hook"]>): ExecuteMsg => {
88+
return {
89+
add_proposal_hook: ({
90+
address
91+
} as const)
92+
};
93+
};
94+
static removeProposalHook = ({
95+
address
96+
}: CamelCasedProperties<Extract<ExecuteMsg, {
97+
remove_proposal_hook: unknown;
98+
}>["remove_proposal_hook"]>): ExecuteMsg => {
99+
return {
100+
remove_proposal_hook: ({
101+
address
102+
} as const)
103+
};
104+
};
105+
static addVoteHook = ({
106+
address
107+
}: CamelCasedProperties<Extract<ExecuteMsg, {
108+
add_vote_hook: unknown;
109+
}>["add_vote_hook"]>): ExecuteMsg => {
110+
return {
111+
add_vote_hook: ({
112+
address
113+
} as const)
114+
};
115+
};
116+
static removeVoteHook = ({
117+
address
118+
}: CamelCasedProperties<Extract<ExecuteMsg, {
119+
remove_vote_hook: unknown;
120+
}>["remove_vote_hook"]>): ExecuteMsg => {
121+
return {
122+
remove_vote_hook: ({
123+
address
124+
} as const)
125+
};
126+
};
127+
}
128+
export abstract class CwSingleQueryMsgBuilder {
129+
static config = (): QueryMsg => {
130+
return {
131+
config: ({} as const)
132+
};
133+
};
134+
static proposal = ({
135+
proposalId
136+
}: CamelCasedProperties<Extract<QueryMsg, {
137+
proposal: unknown;
138+
}>["proposal"]>): QueryMsg => {
139+
return {
140+
proposal: ({
141+
proposal_id: proposalId
142+
} as const)
143+
};
144+
};
145+
static listProposals = ({
146+
limit,
147+
startAfter
148+
}: CamelCasedProperties<Extract<QueryMsg, {
149+
list_proposals: unknown;
150+
}>["list_proposals"]>): QueryMsg => {
151+
return {
152+
list_proposals: ({
153+
limit,
154+
start_after: startAfter
155+
} as const)
156+
};
157+
};
158+
static reverseProposals = ({
159+
limit,
160+
startBefore
161+
}: CamelCasedProperties<Extract<QueryMsg, {
162+
reverse_proposals: unknown;
163+
}>["reverse_proposals"]>): QueryMsg => {
164+
return {
165+
reverse_proposals: ({
166+
limit,
167+
start_before: startBefore
168+
} as const)
169+
};
170+
};
171+
static proposalCount = (): QueryMsg => {
172+
return {
173+
proposal_count: ({} as const)
174+
};
175+
};
176+
static vote = ({
177+
proposalId,
178+
voter
179+
}: CamelCasedProperties<Extract<QueryMsg, {
180+
vote: unknown;
181+
}>["vote"]>): QueryMsg => {
182+
return {
183+
vote: ({
184+
proposal_id: proposalId,
185+
voter
186+
} as const)
187+
};
188+
};
189+
static listVotes = ({
190+
limit,
191+
proposalId,
192+
startAfter
193+
}: CamelCasedProperties<Extract<QueryMsg, {
194+
list_votes: unknown;
195+
}>["list_votes"]>): QueryMsg => {
196+
return {
197+
list_votes: ({
198+
limit,
199+
proposal_id: proposalId,
200+
start_after: startAfter
201+
} as const)
202+
};
203+
};
204+
static proposalHooks = (): QueryMsg => {
205+
return {
206+
proposal_hooks: ({} as const)
207+
};
208+
};
209+
static voteHooks = (): QueryMsg => {
210+
return {
211+
vote_hooks: ({} as const)
212+
};
213+
};
214+
static info = (): QueryMsg => {
215+
return {
216+
info: ({} as const)
217+
};
218+
};
219+
}

0 commit comments

Comments
 (0)