Skip to content

Commit

Permalink
Merge pull request #1 from polymerdao/zfeng/fix-spec
Browse files Browse the repository at this point in the history
fix deployment spec
  • Loading branch information
zhengyangfeng00 authored Jul 19, 2024
2 parents 800f2cd + d6a20ca commit da6ea17
Show file tree
Hide file tree
Showing 46 changed files with 24,422 additions and 1,066 deletions.
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
node_modules/
dist/
node_modules/
4 changes: 4 additions & 0 deletions .projectile
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-GeneralisedIncentives/lib/
-GeneralisedIncentives/out/
-node_modules/
-dist/
3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ forge-build:

CONTRACT_JSON_FILES = \
./GeneralisedIncentives/out/vIBCEscrow.sol/IncentivizedPolymerEscrow.json \
./GeneralisedIncentives/out/SimpleApplication.sol/SimpleApplication.json \

.PHONY: bindings-gen-ts
bindings-gen-ts: forge-build
Expand All @@ -15,5 +16,5 @@ bindings-gen-ts: forge-build
npx typechain --target ethers-v6 --out-dir ./src/evm/contracts $(CONTRACT_JSON_FILES); \
echo "Done."

dist:
dist: bindings-gen-ts
bun run build
19 changes: 19 additions & 0 deletions dist/SimpleApplication.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __copyProps = (to, from, except, desc) => {
if (from && typeof from === "object" || typeof from === "function") {
for (let key of __getOwnPropNames(from))
if (!__hasOwnProp.call(to, key) && key !== except)
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
}
return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);

// src/evm/contracts/SimpleApplication.ts
var SimpleApplication_exports = {};
module.exports = __toCommonJS(SimpleApplication_exports);
//# sourceMappingURL=SimpleApplication.cjs.map
1 change: 1 addition & 0 deletions dist/SimpleApplication.cjs.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

145 changes: 145 additions & 0 deletions dist/SimpleApplication.d.cts
Original file line number Diff line number Diff line change
@@ -0,0 +1,145 @@
import { BigNumberish, AddressLike, Interface, FunctionFragment, EventFragment, BytesLike, Result, BaseContract, ContractRunner, Listener, ContractMethod } from 'ethers';
import { TypedContractEvent, TypedDeferredTopicFilter, TypedEventLog, TypedLogDescription, TypedListener, TypedContractMethod } from './common.cjs';

declare namespace IMessageEscrowStructs {
type IncentiveDescriptionStruct = {
maxGasDelivery: BigNumberish;
maxGasAck: BigNumberish;
refundGasTo: AddressLike;
priceOfDeliveryGas: BigNumberish;
priceOfAckGas: BigNumberish;
targetDelta: BigNumberish;
};
type IncentiveDescriptionStructOutput = [
maxGasDelivery: bigint,
maxGasAck: bigint,
refundGasTo: string,
priceOfDeliveryGas: bigint,
priceOfAckGas: bigint,
targetDelta: bigint
] & {
maxGasDelivery: bigint;
maxGasAck: bigint;
refundGasTo: string;
priceOfDeliveryGas: bigint;
priceOfAckGas: bigint;
targetDelta: bigint;
};
}
interface SimpleApplicationInterface extends Interface {
getFunction(nameOrSignature: "receiveAck" | "receiveMessage" | "setRemoteImplementation" | "submitMessage"): FunctionFragment;
getEvent(nameOrSignatureOrTopic: "Event"): EventFragment;
encodeFunctionData(functionFragment: "receiveAck", values: [BytesLike, BytesLike, BytesLike]): string;
encodeFunctionData(functionFragment: "receiveMessage", values: [BytesLike, BytesLike, BytesLike, BytesLike]): string;
encodeFunctionData(functionFragment: "setRemoteImplementation", values: [BytesLike, BytesLike]): string;
encodeFunctionData(functionFragment: "submitMessage", values: [
BytesLike,
BytesLike,
BytesLike,
IMessageEscrowStructs.IncentiveDescriptionStruct,
BigNumberish
]): string;
decodeFunctionResult(functionFragment: "receiveAck", data: BytesLike): Result;
decodeFunctionResult(functionFragment: "receiveMessage", data: BytesLike): Result;
decodeFunctionResult(functionFragment: "setRemoteImplementation", data: BytesLike): Result;
decodeFunctionResult(functionFragment: "submitMessage", data: BytesLike): Result;
}
declare namespace EventEvent {
type InputTuple = [message: BytesLike];
type OutputTuple = [message: string];
interface OutputObject {
message: string;
}
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
type Filter = TypedDeferredTopicFilter<Event>;
type Log = TypedEventLog<Event>;
type LogDescription = TypedLogDescription<Event>;
}
interface SimpleApplication extends BaseContract {
connect(runner?: ContractRunner | null): SimpleApplication;
waitForDeployment(): Promise<this>;
interface: SimpleApplicationInterface;
queryFilter<TCEvent extends TypedContractEvent>(event: TCEvent, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined): Promise<Array<TypedEventLog<TCEvent>>>;
queryFilter<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined): Promise<Array<TypedEventLog<TCEvent>>>;
on<TCEvent extends TypedContractEvent>(event: TCEvent, listener: TypedListener<TCEvent>): Promise<this>;
on<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, listener: TypedListener<TCEvent>): Promise<this>;
once<TCEvent extends TypedContractEvent>(event: TCEvent, listener: TypedListener<TCEvent>): Promise<this>;
once<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, listener: TypedListener<TCEvent>): Promise<this>;
listeners<TCEvent extends TypedContractEvent>(event: TCEvent): Promise<Array<TypedListener<TCEvent>>>;
listeners(eventName?: string): Promise<Array<Listener>>;
removeAllListeners<TCEvent extends TypedContractEvent>(event?: TCEvent): Promise<this>;
receiveAck: TypedContractMethod<[
arg0: BytesLike,
arg1: BytesLike,
acknowledgement: BytesLike
], [
void
], "nonpayable">;
receiveMessage: TypedContractMethod<[
arg0: BytesLike,
arg1: BytesLike,
arg2: BytesLike,
message: BytesLike
], [
string
], "nonpayable">;
setRemoteImplementation: TypedContractMethod<[
destinationIdentifier: BytesLike,
implementation: BytesLike
], [
void
], "nonpayable">;
submitMessage: TypedContractMethod<[
destinationIdentifier: BytesLike,
destinationAddress: BytesLike,
message: BytesLike,
incentive: IMessageEscrowStructs.IncentiveDescriptionStruct,
deadline: BigNumberish
], [
[bigint, string] & {
gasRefund: bigint;
messageIdentifier: string;
}
], "payable">;
getFunction<T extends ContractMethod = ContractMethod>(key: string | FunctionFragment): T;
getFunction(nameOrSignature: "receiveAck"): TypedContractMethod<[
arg0: BytesLike,
arg1: BytesLike,
acknowledgement: BytesLike
], [
void
], "nonpayable">;
getFunction(nameOrSignature: "receiveMessage"): TypedContractMethod<[
arg0: BytesLike,
arg1: BytesLike,
arg2: BytesLike,
message: BytesLike
], [
string
], "nonpayable">;
getFunction(nameOrSignature: "setRemoteImplementation"): TypedContractMethod<[
destinationIdentifier: BytesLike,
implementation: BytesLike
], [
void
], "nonpayable">;
getFunction(nameOrSignature: "submitMessage"): TypedContractMethod<[
destinationIdentifier: BytesLike,
destinationAddress: BytesLike,
message: BytesLike,
incentive: IMessageEscrowStructs.IncentiveDescriptionStruct,
deadline: BigNumberish
], [
[bigint, string] & {
gasRefund: bigint;
messageIdentifier: string;
}
], "payable">;
getEvent(key: "Event"): TypedContractEvent<EventEvent.InputTuple, EventEvent.OutputTuple, EventEvent.OutputObject>;
filters: {
"Event(bytes)": TypedContractEvent<EventEvent.InputTuple, EventEvent.OutputTuple, EventEvent.OutputObject>;
Event: TypedContractEvent<EventEvent.InputTuple, EventEvent.OutputTuple, EventEvent.OutputObject>;
};
}

export { EventEvent, IMessageEscrowStructs, type SimpleApplication, type SimpleApplicationInterface };
Loading

0 comments on commit da6ea17

Please sign in to comment.