Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
lidangzzz committed Feb 10, 2024
1 parent 9eda121 commit 620c5b3
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 5 deletions.
16 changes: 16 additions & 0 deletions darc-js/src/DARC/DARC.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,22 @@ export type InitParam = {
provider?: ethers.providers.Provider;
}


export type TokenInfo = {
votingWeight: BigInt,
dividendWeight: BigInt,
tokenInfo: string,
totalSupply: BigInt,
}

export type MemberInfo = {
bIsInitialized: boolean,
bIsSuspened: boolean,
name: string,
role: bigint
}


/**
* The DARC class is used to interact with the DARC contract.
*/
Expand Down
4 changes: 3 additions & 1 deletion darc-js/src/sdk.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
// import everything from includes.ts
/**
* Below are all necessary functions for the SDK.
*/
import * as instructions from "./SDK/includes";
import { OperationStruct, OperationStructOutput, ProgramStruct, VotingRuleStruct, PluginStruct, PluginStructWithNode } from "./types/basicTypes";
import {ethers} from "ethers";
Expand Down
4 changes: 2 additions & 2 deletions darc-js/tests/runtime-test/transpileAndRun.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import {executeOperationList} from "../../src/SDK/sdk";
import {executeOperationList} from "../../src/sdk";
import {run, deployDARC, DARC_VERSION} from '../../src/darcjs';
import { ethers, BigNumber } from 'ethers';
import * as DARC from '../../src/DARC/DARC';
import 'mocha';
import { expect } from 'chai';
import { batch_add_and_enable_plugins, batch_mint_tokens, batch_create_token_classes } from "../../src/SDK/sdk";
import { batch_add_and_enable_plugins, batch_mint_tokens, batch_create_token_classes } from "../../src/sdk";
import {or, node, and, expression} from "../../src/SDK/Node";
import { transpileAndRun } from "../../src/SDK/runtime";
import { transpiler } from "../../src/darcjs";
Expand Down
4 changes: 2 additions & 2 deletions darc-js/tests/sdk-test/sdk-node-generation-test.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import {executeOperationList} from "../../src/SDK/sdk";
import {executeOperationList} from "../../src/sdk";
import {run, deployDARC, DARC_VERSION} from '../../src/darcjs';
import { ethers, BigNumber } from 'ethers';
import * as DARC from '../../src/DARC/DARC';
import 'mocha';
import { expect } from 'chai';
import { batch_add_and_enable_plugins, batch_mint_tokens, batch_create_token_classes } from "../../src/SDK/sdk";
import { batch_add_and_enable_plugins, batch_mint_tokens, batch_create_token_classes } from "../../src/sdk";
import {or, node, and, expression} from "../../src/SDK/Node";


Expand Down

0 comments on commit 620c5b3

Please sign in to comment.