From 3edf87362ae0f23108e4e555d15ab3df435538ec Mon Sep 17 00:00:00 2001 From: Jelle Gerbrandy Date: Wed, 18 Sep 2019 15:18:15 +0200 Subject: [PATCH] markdown docs --- .gitignore | 1 - README.md | 5 + docs/README.md | 48 ++ docs/classes/arc.md | 804 ++++++++++++++++++ docs/classes/dao.md | 366 ++++++++ docs/classes/graphnodeobserver.md | 249 ++++++ docs/classes/member.md | 263 ++++++ docs/classes/proposal.md | 471 ++++++++++ docs/classes/queue.md | 108 +++ docs/classes/reputation.md | 153 ++++ docs/classes/reputationfromtokenscheme.md | 89 ++ docs/classes/reward.md | 98 +++ docs/classes/scheme.md | 190 +++++ docs/classes/stake.md | 135 +++ docs/classes/token.md | 213 +++++ docs/classes/vote.md | 135 +++ docs/enums/iexecutionstate.md | 62 ++ docs/enums/iproposaloutcome.md | 35 + docs/enums/iproposalstage.md | 62 ++ docs/enums/itransactionstate.md | 35 + docs/enums/proposalquerysortoptions.md | 26 + docs/globals.md | 689 +++++++++++++++ docs/interfaces/iallowance.md | 48 ++ docs/interfaces/iapolloqueryoptions.md | 39 + docs/interfaces/iapproval.md | 66 ++ docs/interfaces/icommonqueryoptions.md | 79 ++ docs/interfaces/icontractaddresses.md | 11 + docs/interfaces/icontractinfo.md | 48 ++ docs/interfaces/icontributionreward.md | 120 +++ docs/interfaces/idaoqueryoptions.md | 69 ++ docs/interfaces/idaostate.md | 127 +++ docs/interfaces/idaostaticstate.md | 77 ++ docs/interfaces/igenericscheme.md | 57 ++ docs/interfaces/igenericschemeinfo.md | 39 + docs/interfaces/igenesisprotocolparams.md | 120 +++ docs/interfaces/imemberqueryoptions.md | 69 ++ docs/interfaces/imemberstate.md | 67 ++ docs/interfaces/imemberstaticstate.md | 50 ++ docs/interfaces/iobservable.md | 760 +++++++++++++++++ docs/interfaces/ioperationobservable.md | 762 +++++++++++++++++ docs/interfaces/iproposalbasecreateoptions.md | 66 ++ docs/interfaces/iproposalcreateoptionscr.md | 84 ++ docs/interfaces/iproposalcreateoptionsgs.md | 30 + docs/interfaces/iproposalcreateoptionssr.md | 39 + docs/interfaces/iproposalqueryoptions.md | 69 ++ docs/interfaces/iproposalstate.md | 382 +++++++++ docs/interfaces/iproposalstaticstate.md | 50 ++ docs/interfaces/iqueuequeryoptions.md | 69 ++ docs/interfaces/iqueuestate.md | 74 ++ docs/interfaces/iqueuestaticstate.md | 41 + docs/interfaces/ireputationqueryoptions.md | 91 ++ docs/interfaces/ireputationstate.md | 39 + docs/interfaces/irewardqueryoptions.md | 69 ++ docs/interfaces/irewardstate.md | 129 +++ docs/interfaces/ischemequeryoptions.md | 81 ++ docs/interfaces/ischemeregistrar.md | 84 ++ docs/interfaces/ischemestate.md | 132 +++ docs/interfaces/ischemestaticstate.md | 59 ++ docs/interfaces/istakequeryoptions.md | 69 ++ docs/interfaces/istakestate.md | 80 ++ docs/interfaces/istakestaticstate.md | 68 ++ docs/interfaces/istateful.md | 42 + docs/interfaces/itokenqueryoptions.md | 69 ++ docs/interfaces/itokenstate.md | 57 ++ docs/interfaces/itransactionupdate.md | 68 ++ docs/interfaces/ivotequeryoptions.md | 69 ++ docs/interfaces/ivotestate.md | 91 ++ docs/interfaces/ivotestaticstate.md | 77 ++ package-lock.json | 40 + package.json | 7 +- 70 files changed, 9166 insertions(+), 4 deletions(-) create mode 100644 docs/README.md create mode 100644 docs/classes/arc.md create mode 100644 docs/classes/dao.md create mode 100644 docs/classes/graphnodeobserver.md create mode 100644 docs/classes/member.md create mode 100644 docs/classes/proposal.md create mode 100644 docs/classes/queue.md create mode 100644 docs/classes/reputation.md create mode 100644 docs/classes/reputationfromtokenscheme.md create mode 100644 docs/classes/reward.md create mode 100644 docs/classes/scheme.md create mode 100644 docs/classes/stake.md create mode 100644 docs/classes/token.md create mode 100644 docs/classes/vote.md create mode 100644 docs/enums/iexecutionstate.md create mode 100644 docs/enums/iproposaloutcome.md create mode 100644 docs/enums/iproposalstage.md create mode 100644 docs/enums/itransactionstate.md create mode 100644 docs/enums/proposalquerysortoptions.md create mode 100644 docs/globals.md create mode 100644 docs/interfaces/iallowance.md create mode 100644 docs/interfaces/iapolloqueryoptions.md create mode 100644 docs/interfaces/iapproval.md create mode 100644 docs/interfaces/icommonqueryoptions.md create mode 100644 docs/interfaces/icontractaddresses.md create mode 100644 docs/interfaces/icontractinfo.md create mode 100644 docs/interfaces/icontributionreward.md create mode 100644 docs/interfaces/idaoqueryoptions.md create mode 100644 docs/interfaces/idaostate.md create mode 100644 docs/interfaces/idaostaticstate.md create mode 100644 docs/interfaces/igenericscheme.md create mode 100644 docs/interfaces/igenericschemeinfo.md create mode 100644 docs/interfaces/igenesisprotocolparams.md create mode 100644 docs/interfaces/imemberqueryoptions.md create mode 100644 docs/interfaces/imemberstate.md create mode 100644 docs/interfaces/imemberstaticstate.md create mode 100644 docs/interfaces/iobservable.md create mode 100644 docs/interfaces/ioperationobservable.md create mode 100644 docs/interfaces/iproposalbasecreateoptions.md create mode 100644 docs/interfaces/iproposalcreateoptionscr.md create mode 100644 docs/interfaces/iproposalcreateoptionsgs.md create mode 100644 docs/interfaces/iproposalcreateoptionssr.md create mode 100644 docs/interfaces/iproposalqueryoptions.md create mode 100644 docs/interfaces/iproposalstate.md create mode 100644 docs/interfaces/iproposalstaticstate.md create mode 100644 docs/interfaces/iqueuequeryoptions.md create mode 100644 docs/interfaces/iqueuestate.md create mode 100644 docs/interfaces/iqueuestaticstate.md create mode 100644 docs/interfaces/ireputationqueryoptions.md create mode 100644 docs/interfaces/ireputationstate.md create mode 100644 docs/interfaces/irewardqueryoptions.md create mode 100644 docs/interfaces/irewardstate.md create mode 100644 docs/interfaces/ischemequeryoptions.md create mode 100644 docs/interfaces/ischemeregistrar.md create mode 100644 docs/interfaces/ischemestate.md create mode 100644 docs/interfaces/ischemestaticstate.md create mode 100644 docs/interfaces/istakequeryoptions.md create mode 100644 docs/interfaces/istakestate.md create mode 100644 docs/interfaces/istakestaticstate.md create mode 100644 docs/interfaces/istateful.md create mode 100644 docs/interfaces/itokenqueryoptions.md create mode 100644 docs/interfaces/itokenstate.md create mode 100644 docs/interfaces/itransactionupdate.md create mode 100644 docs/interfaces/ivotequeryoptions.md create mode 100644 docs/interfaces/ivotestate.md create mode 100644 docs/interfaces/ivotestaticstate.md diff --git a/.gitignore b/.gitignore index 99ea06c4..16143beb 100644 --- a/.gitignore +++ b/.gitignore @@ -9,7 +9,6 @@ dist compiled .awcache .rpt2_cache -docs abis/ schema.graphql subgraph.yaml diff --git a/README.md b/README.md index c6000d06..af79b272 100644 --- a/README.md +++ b/README.md @@ -30,6 +30,7 @@ arc.daos() * [overview](./documentation/overview.md) * [development](./documentation/development.md) +<<<<<<< Updated upstream * [example](./documentation/example-session.md) * [troubleshooting](./documentation/troubleshooting.md) @@ -61,3 +62,7 @@ docker-compose down - `npm run build`: Generate bundles and typings, create docs - `npm run lint`: Lints code - `npm run test`: run all tests +======= +* [small demo](./documentation/demo.js) +* [Generated documentation](./docs/globals.md) +>>>>>>> Stashed changes diff --git a/docs/README.md b/docs/README.md new file mode 100644 index 00000000..ebb158e9 --- /dev/null +++ b/docs/README.md @@ -0,0 +1,48 @@ +[@daostack/client](README.md) › [Globals](globals.md) + +# @daostack/client + +[![Build Status](https://travis-ci.com/daostack/client.svg?token=aXt9zApRNkfx8zDMypWx&branch=master)](https://travis-ci.com/daostack/client) + +# DAOstack Client + +The DAOStack Client is a nodejs library to work with the DAOstack ecosystem +* Convenience functions to interact with the [DAOstack contracts](https://github.com/daostack/arc): create proposals, and vote and stake on them +* A client library for the [DAOstack subgraph](https://github.com/daostack/subgraph) - search for daos, proposals + +## Usage + +In your nodejs project run + +``` +npm install --save @daostack/client +``` +now you can do: +``` +import { Arc } from '@daostack/client' + +// create an Arc instance +const arc = new Arc({ + graphqlHttpProvider: "https://subgraph.daostack.io/subgraphs/name/v23", + graphqlWsProvider: "wss://ws.subgraph.daostack.io/subgraphs/name/v23", + web3Provider: `wss://mainnet.infura.io/ws/v3/${YOUR_TOKEN_HERE}`, + ipfsProvider: { + "host": "subgraph.daostack.io", + "port": "443", + "protocol": "https", + "api-path": "/ipfs/api/v0/" + } +}) + +// get a list of DAOs +arc.daos().subscribe( + (daos) => console.log(`Here are your DAOS: ${daos}`) +) +``` + +## More information + +* [overview](./documentation/overview.md) +* [development](./documentation/development.md) +* [small demo](./documentation/demo.js) +* Generated documentation [TODO!] diff --git a/docs/classes/arc.md b/docs/classes/arc.md new file mode 100644 index 00000000..fc015f00 --- /dev/null +++ b/docs/classes/arc.md @@ -0,0 +1,804 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [Arc](arc.md) + +# Class: Arc + +The Arc class holds all configuration. +Any useage of the library typically will start with instantiating a new Arc instance + +**`returns`** an instance of Arc + +## Hierarchy + +* [GraphNodeObserver](graphnodeobserver.md) + + ↳ **Arc** + +## Index + +### Constructors + +* [constructor](arc.md#constructor) + +### Properties + +* [Logger](arc.md#logger) +* [apolloClient](arc.md#optional-apolloclient) +* [blockHeaderSubscription](arc.md#blockheadersubscription) +* [contractInfos](arc.md#contractinfos) +* [contracts](arc.md#contracts) +* [contractsR](arc.md#contractsr) +* [graphqlHttpProvider](arc.md#optional-graphqlhttpprovider) +* [graphqlWsProvider](arc.md#optional-graphqlwsprovider) +* [ipfs](arc.md#ipfs) +* [ipfsProvider](arc.md#ipfsprovider) +* [observedAccounts](arc.md#observedaccounts) +* [pendingOperations](arc.md#pendingoperations) +* [web3](arc.md#web3) +* [web3Provider](arc.md#web3provider) +* [web3ProviderRead](arc.md#web3providerread) +* [web3Read](arc.md#web3read) + +### Methods + +* [GENToken](arc.md#gentoken) +* [allowance](arc.md#allowance) +* [approveForStaking](arc.md#approveforstaking) +* [dao](arc.md#dao) +* [daos](arc.md#daos) +* [ethBalance](arc.md#ethbalance) +* [fetchContractInfos](arc.md#fetchcontractinfos) +* [getABI](arc.md#getabi) +* [getAccount](arc.md#getaccount) +* [getContract](arc.md#getcontract) +* [getContractInfo](arc.md#getcontractinfo) +* [getContractInfoByName](arc.md#getcontractinfobyname) +* [getObservable](arc.md#getobservable) +* [getObservableList](arc.md#getobservablelist) +* [getObservableListWithFilter](arc.md#getobservablelistwithfilter) +* [getObservableObject](arc.md#getobservableobject) +* [proposal](arc.md#proposal) +* [proposals](arc.md#proposals) +* [saveIPFSData](arc.md#saveipfsdata) +* [scheme](arc.md#scheme) +* [schemes](arc.md#schemes) +* [sendQuery](arc.md#sendquery) +* [sendTransaction](arc.md#sendtransaction) +* [setAccount](arc.md#setaccount) +* [setContractInfos](arc.md#setcontractinfos) + +## Constructors + +### constructor + +\+ **new Arc**(`options`: object): *[Arc](arc.md)* + +*Overrides [GraphNodeObserver](graphnodeobserver.md).[constructor](graphnodeobserver.md#constructor)* + +*Defined in [arc.ts:50](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L50)* + +**Parameters:** + +▪ **options**: *object* + +Name | Type | +------ | ------ | +`contractInfos?` | [IContractInfo](../interfaces/icontractinfo.md)[] | +`graphqlHttpProvider?` | undefined | string | +`graphqlWsProvider?` | undefined | string | +`ipfsProvider?` | [IPFSProvider](../globals.md#ipfsprovider) | +`web3Provider?` | undefined | string | +`web3ProviderRead?` | undefined | string | + +**Returns:** *[Arc](arc.md)* + +## Properties + +### Logger + +• **Logger**: *GlobalLogger* = Logger + +*Inherited from [GraphNodeObserver](graphnodeobserver.md).[Logger](graphnodeobserver.md#logger)* + +*Defined in [graphnode.ts:139](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L139)* + +___ + +### `Optional` apolloClient + +• **apolloClient**? : *ApolloClient‹object›* + +*Inherited from [GraphNodeObserver](graphnodeobserver.md).[apolloClient](graphnodeobserver.md#optional-apolloclient)* + +*Defined in [graphnode.ts:140](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L140)* + +___ + +### blockHeaderSubscription + +• **blockHeaderSubscription**: *Subscription | undefined* = undefined + +*Defined in [arc.ts:42](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L42)* + +___ + +### contractInfos + +• **contractInfos**: *[IContractInfo](../interfaces/icontractinfo.md)[]* + +*Defined in [arc.ts:37](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L37)* + +a mapping of contrct names to contract addresses + +___ + +### contracts + +• **contracts**: *object* + +*Defined in [arc.ts:38](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L38)* + +#### Type declaration: + +* \[ **key**: *string*\]: any + +___ + +### contractsR + +• **contractsR**: *object* + +*Defined in [arc.ts:39](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L39)* + +#### Type declaration: + +* \[ **key**: *string*\]: any + +___ + +### `Optional` graphqlHttpProvider + +• **graphqlHttpProvider**? : *undefined | string* + +*Inherited from [GraphNodeObserver](graphnodeobserver.md).[graphqlHttpProvider](graphnodeobserver.md#optional-graphqlhttpprovider)* + +*Defined in [graphnode.ts:137](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L137)* + +___ + +### `Optional` graphqlWsProvider + +• **graphqlWsProvider**? : *undefined | string* + +*Inherited from [GraphNodeObserver](graphnodeobserver.md).[graphqlWsProvider](graphnodeobserver.md#optional-graphqlwsprovider)* + +*Defined in [graphnode.ts:138](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L138)* + +___ + +### ipfs + +• **ipfs**: *any* + +*Defined in [arc.ts:31](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L31)* + +___ + +### ipfsProvider + +• **ipfsProvider**: *[IPFSProvider](../globals.md#ipfsprovider)* + +*Defined in [arc.ts:27](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L27)* + +___ + +### observedAccounts + +• **observedAccounts**: *object* + +*Defined in [arc.ts:44](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L44)* + +#### Type declaration: + +* \[ **address**: *string*\]: object + +* **lastBalance**? : *undefined | number* + +* **observable**? : *Observable‹any›* + +* **observer**? : *Observer‹any›* + +* **subscriptionsCount**: *number* + +___ + +### pendingOperations + +• **pendingOperations**: *Observable‹Array‹[Operation](../globals.md#operation)‹any›››* = of() + +*Defined in [arc.ts:29](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L29)* + +___ + +### web3 + +• **web3**: *any* + +*Defined in [arc.ts:32](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L32)* + +___ + +### web3Provider + +• **web3Provider**: *[Web3Provider](../globals.md#web3provider)* = "" + +*Defined in [arc.ts:25](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L25)* + +___ + +### web3ProviderRead + +• **web3ProviderRead**: *[Web3Provider](../globals.md#web3provider)* = "" + +*Defined in [arc.ts:26](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L26)* + +___ + +### web3Read + +• **web3Read**: *any* + +*Defined in [arc.ts:33](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L33)* + +## Methods + +### GENToken + +▸ **GENToken**(): *[Token](token.md)* + +*Defined in [arc.ts:309](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L309)* + +get the GEN Token + +**Returns:** *[Token](token.md)* + +a Token instance + +___ + +### allowance + +▸ **allowance**(`owner`: [Address](../globals.md#address), `spender`: [Address](../globals.md#address)): *Observable‹any›* + +*Defined in [arc.ts:380](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L380)* + +How much GEN spender may spend on behalve of the owner + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`owner` | [Address](../globals.md#address) | Address of the owner of the tokens | +`spender` | [Address](../globals.md#address) | Address of the spender | + +**Returns:** *Observable‹any›* + +___ + +### approveForStaking + +▸ **approveForStaking**(`spender`: [Address](../globals.md#address), `amount`: any): *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹any››* + +*Defined in [arc.ts:370](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L370)* + +**Parameters:** + +Name | Type | +------ | ------ | +`spender` | [Address](../globals.md#address) | +`amount` | any | + +**Returns:** *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹any››* + +___ + +### dao + +▸ **dao**(`address`: [Address](../globals.md#address)): *[DAO](dao.md)* + +*Defined in [arc.ts:123](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L123)* + +get a DAO instance from an address + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`address` | [Address](../globals.md#address) | address of the dao Avatar | + +**Returns:** *[DAO](dao.md)* + +an instance of a DAO + +___ + +### daos + +▸ **daos**(`options`: [IDAOQueryOptions](../interfaces/idaoqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[DAO](dao.md)[]›* + +*Defined in [arc.ts:133](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L133)* + +return an observable of the list of DAOs + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`options` | [IDAOQueryOptions](../interfaces/idaoqueryoptions.md) | {} | options to pass on to the query | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | - | + +**Returns:** *Observable‹[DAO](dao.md)[]›* + +___ + +### ethBalance + +▸ **ethBalance**(`owner`: [Address](../globals.md#address)): *Observable‹any›* + +*Defined in [arc.ts:159](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L159)* + +**Parameters:** + +Name | Type | +------ | ------ | +`owner` | [Address](../globals.md#address) | + +**Returns:** *Observable‹any›* + +___ + +### fetchContractInfos + +▸ **fetchContractInfos**(`apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Promise‹[IContractInfo](../interfaces/icontractinfo.md)[]›* + +*Defined in [arc.ts:101](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L101)* + +fetch contractInfos from the subgraph + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Promise‹[IContractInfo](../interfaces/icontractinfo.md)[]›* + +a list of IContractInfo instances + +___ + +### getABI + +▸ **getABI**(`address`: [Address](../globals.md#address), `abiName?`: undefined | string, `version?`: undefined | string): *any* + +*Defined in [arc.ts:260](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L260)* + +**Parameters:** + +Name | Type | +------ | ------ | +`address` | [Address](../globals.md#address) | +`abiName?` | undefined | string | +`version?` | undefined | string | + +**Returns:** *any* + +___ + +### getAccount + +▸ **getAccount**(): *Observable‹[Address](../globals.md#address)›* + +*Defined in [arc.ts:332](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L332)* + +**Returns:** *Observable‹[Address](../globals.md#address)›* + +___ + +### getContract + +▸ **getContract**(`address`: [Address](../globals.md#address), `abi?`: any, `mode?`: undefined | "readonly"): *any* + +*Defined in [arc.ts:281](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L281)* + +return a web3 Contract instance. + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`address` | [Address](../globals.md#address) | address of the contract to look up in self.contractInfos | +`abi?` | any | - | +`mode?` | undefined | "readonly" | - | + +**Returns:** *any* + +a web3 contract instance + +___ + +### getContractInfo + +▸ **getContractInfo**(`address`: [Address](../globals.md#address)): *[IContractInfo](../interfaces/icontractinfo.md)* + +*Defined in [arc.ts:235](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L235)* + +return information about the contract + +**Parameters:** + +Name | Type | +------ | ------ | +`address` | [Address](../globals.md#address) | + +**Returns:** *[IContractInfo](../interfaces/icontractinfo.md)* + +an IContractInfo instance + +___ + +### getContractInfoByName + +▸ **getContractInfoByName**(`name`: string, `version`: string): *[IContractInfo](../interfaces/icontractinfo.md)* + +*Defined in [arc.ts:248](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L248)* + +**Parameters:** + +Name | Type | +------ | ------ | +`name` | string | +`version` | string | + +**Returns:** *[IContractInfo](../interfaces/icontractinfo.md)* + +___ + +### getObservable + +▸ **getObservable**(`query`: any, `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *any* + +*Inherited from [GraphNodeObserver](graphnodeobserver.md).[getObservable](graphnodeobserver.md#getobservable)* + +*Defined in [graphnode.ts:162](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L162)* + +Given a gql query, will return an observable of query results + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`query` | any | - | a gql query object to execute | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | options to pass on to Apollo, cf .. | + +**Returns:** *any* + +an Observable that will first yield the current result, and yields updates every time the data changes + +___ + +### getObservableList + +▸ **getObservableList**(`query`: any, `itemMap`: function, `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *any* + +*Inherited from [GraphNodeObserver](graphnodeobserver.md).[getObservableList](graphnodeobserver.md#getobservablelist)* + +*Defined in [graphnode.ts:257](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L257)* + +Returns an observable that: +- sends a query over http and returns the current list of results +- subscribes over a websocket to changes, and returns the updated list. + +**`example:`** +``` + const query = gql` + { + daos { + id + address + } + }` + getObservableList(query, (r:any) => new DAO(r.address)) +``` + +**Parameters:** + +▪ **query**: *any* + +The query to be run + +▪`Default value` **itemMap**: *function*= (o) => o + +(optional) a function that takes elements of the list and creates new objects + +▸ (`o`: object): *object | null* + +**Parameters:** + +Name | Type | +------ | ------ | +`o` | object | + +▪`Default value` **apolloQueryOptions**: *[IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)*= {} + +**Returns:** *any* + +an Observable + +___ + +### getObservableListWithFilter + +▸ **getObservableListWithFilter**(`query`: any, `itemMap`: function, `filterFunc`: function, `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *any* + +*Inherited from [GraphNodeObserver](graphnodeobserver.md).[getObservableListWithFilter](graphnodeobserver.md#getobservablelistwithfilter)* + +*Defined in [graphnode.ts:296](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L296)* + +Returns an observable that: +- sends a query over http and returns the current list of results +- subscribes over a websocket to changes, and returns the updated list +example: + const query = gql` + { + daos { + id + address + } + }` + getObservableList(query, (r:any) => new DAO(r.address), filter((r:any) => r.address === "0x1234...")) + +**Parameters:** + +▪ **query**: *any* + +The query to be run + +▪`Default value` **itemMap**: *function*= (o) => o + +(optional) a function that takes elements of the list and creates new objects + +▸ (`o`: object): *object | null* + +**Parameters:** + +Name | Type | +------ | ------ | +`o` | object | + +▪ **filterFunc**: *function* + +▸ (`o`: object): *boolean* + +**Parameters:** + +Name | Type | +------ | ------ | +`o` | object | + +▪`Default value` **apolloQueryOptions**: *[IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)*= {} + +**Returns:** *any* + +___ + +### getObservableObject + +▸ **getObservableObject**(`query`: any, `itemMap`: function, `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *any* + +*Inherited from [GraphNodeObserver](graphnodeobserver.md).[getObservableObject](graphnodeobserver.md#getobservableobject)* + +*Defined in [graphnode.ts:313](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L313)* + +**Parameters:** + +▪ **query**: *any* + +▪`Default value` **itemMap**: *function*= (o) => o + +▸ (`o`: object): *object | null* + +**Parameters:** + +Name | Type | +------ | ------ | +`o` | object | + +▪`Default value` **apolloQueryOptions**: *[IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)*= {} + +**Returns:** *any* + +___ + +### proposal + +▸ **proposal**(`id`: string): *[Proposal](proposal.md)* + +*Defined in [arc.ts:148](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L148)* + +**Parameters:** + +Name | Type | +------ | ------ | +`id` | string | + +**Returns:** *[Proposal](proposal.md)* + +___ + +### proposals + +▸ **proposals**(`options`: [IProposalQueryOptions](../interfaces/iproposalqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Proposal](proposal.md)[]›* + +*Defined in [arc.ts:152](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L152)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IProposalQueryOptions](../interfaces/iproposalqueryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Proposal](proposal.md)[]›* + +___ + +### saveIPFSData + +▸ **saveIPFSData**(`options`: object): *Promise‹string›* + +*Defined in [arc.ts:404](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L404)* + +save data of a proposal to IPFS, return the IPFS hash + +**Parameters:** + +▪ **options**: *object* + +an Object to save. This object must have title, url and desction defined + +Name | Type | +------ | ------ | +`description` | string | +`title` | string | +`url` | string | + +**Returns:** *Promise‹string›* + +a Promise that resolves in the IPFS Hash where the file is saved + +___ + +### scheme + +▸ **scheme**(`id`: string): *[Scheme](scheme.md)* + +*Defined in [arc.ts:137](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L137)* + +**Parameters:** + +Name | Type | +------ | ------ | +`id` | string | + +**Returns:** *[Scheme](scheme.md)* + +___ + +### schemes + +▸ **schemes**(`options`: [ISchemeQueryOptions](../interfaces/ischemequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Scheme](scheme.md)[]›* + +*Defined in [arc.ts:141](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L141)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [ISchemeQueryOptions](../interfaces/ischemequeryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Scheme](scheme.md)[]›* + +___ + +### sendQuery + +▸ **sendQuery**(`query`: any): *Promise‹object›* + +*Inherited from [GraphNodeObserver](graphnodeobserver.md).[sendQuery](graphnodeobserver.md#sendquery)* + +*Defined in [graphnode.ts:333](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L333)* + +**Parameters:** + +Name | Type | +------ | ------ | +`query` | any | + +**Returns:** *Promise‹object›* + +___ + +### sendTransaction + +▸ **sendTransaction**<**T**>(`transaction`: any, `mapToObject`: function, `errorHandler`: function): *[Operation](../globals.md#operation)‹T›* + +*Defined in [arc.ts:391](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L391)* + +send an Ethereum transaction + +**Type parameters:** + +▪ **T** + +**Parameters:** + +▪ **transaction**: *any* + +▪ **mapToObject**: *function* + +▸ (`receipt`: [web3receipt](../globals.md#web3receipt)): *T* + +**Parameters:** + +Name | Type | +------ | ------ | +`receipt` | [web3receipt](../globals.md#web3receipt) | + +▪`Default value` **errorHandler**: *function*= (error) => error + +▸ (`error`: Error): *Promise‹Error› | Error* + +**Parameters:** + +Name | Type | +------ | ------ | +`error` | Error | + +**Returns:** *[Operation](../globals.md#operation)‹T›* + +An observable of + +___ + +### setAccount + +▸ **setAccount**(`address`: [Address](../globals.md#address)): *void* + +*Defined in [arc.ts:366](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L366)* + +**Parameters:** + +Name | Type | +------ | ------ | +`address` | [Address](../globals.md#address) | + +**Returns:** *void* + +___ + +### setContractInfos + +▸ **setContractInfos**(`contractInfos`: [IContractInfo](../interfaces/icontractinfo.md)[]): *Promise‹void›* + +*Defined in [arc.ts:90](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L90)* + +set the contract addresses + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`contractInfos` | [IContractInfo](../interfaces/icontractinfo.md)[] | a list of IContractInfo objects | + +**Returns:** *Promise‹void›* diff --git a/docs/classes/dao.md b/docs/classes/dao.md new file mode 100644 index 00000000..7b0ae87c --- /dev/null +++ b/docs/classes/dao.md @@ -0,0 +1,366 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [DAO](dao.md) + +# Class: DAO + +## Hierarchy + +* **DAO** + +## Implements + +* [IStateful](../interfaces/istateful.md)‹[IDAOState](../interfaces/idaostate.md)› + +## Index + +### Constructors + +* [constructor](dao.md#constructor) + +### Properties + +* [context](dao.md#context) +* [id](dao.md#id) +* [staticState](dao.md#staticstate) + +### Methods + +* [createProposal](dao.md#createproposal) +* [ethBalance](dao.md#ethbalance) +* [fetchStaticState](dao.md#fetchstaticstate) +* [member](dao.md#member) +* [members](dao.md#members) +* [nativeReputation](dao.md#nativereputation) +* [proposal](dao.md#proposal) +* [proposals](dao.md#proposals) +* [rewards](dao.md#rewards) +* [scheme](dao.md#scheme) +* [schemes](dao.md#schemes) +* [setStaticState](dao.md#setstaticstate) +* [stakes](dao.md#stakes) +* [state](dao.md#state) +* [votes](dao.md#votes) +* [search](dao.md#static-search) + +### Object literals + +* [fragments](dao.md#static-fragments) + +## Constructors + +### constructor + +\+ **new DAO**(`idOrOpts`: [Address](../globals.md#address) | [IDAOStaticState](../interfaces/idaostaticstate.md), `context`: [Arc](arc.md)): *[DAO](dao.md)* + +*Defined in [dao.ts:125](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L125)* + +**Parameters:** + +Name | Type | +------ | ------ | +`idOrOpts` | [Address](../globals.md#address) | [IDAOStaticState](../interfaces/idaostaticstate.md) | +`context` | [Arc](arc.md) | + +**Returns:** *[DAO](dao.md)* + +## Properties + +### context + +• **context**: *[Arc](arc.md)* + +*Defined in [dao.ts:127](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L127)* + +___ + +### id + +• **id**: *[Address](../globals.md#address)* + +*Defined in [dao.ts:124](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L124)* + +___ + +### staticState + +• **staticState**: *[IDAOStaticState](../interfaces/idaostaticstate.md) | undefined* + +*Defined in [dao.ts:125](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L125)* + +## Methods + +### createProposal + +▸ **createProposal**(`options`: [IProposalCreateOptions](../globals.md#iproposalcreateoptions)): *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹[Proposal](proposal.md)››* + +*Defined in [dao.ts:253](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L253)* + +create a new proposal in this DAO + +**Parameters:** + +Name | Type | +------ | ------ | +`options` | [IProposalCreateOptions](../globals.md#iproposalcreateoptions) | + +**Returns:** *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹[Proposal](proposal.md)››* + +a Proposal instance + +___ + +### ethBalance + +▸ **ethBalance**(): *Observable‹any›* + +*Defined in [dao.ts:300](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L300)* + +**Returns:** *Observable‹any›* + +___ + +### fetchStaticState + +▸ **fetchStaticState**(): *Promise‹[IDAOStaticState](../interfaces/idaostaticstate.md)›* + +*Defined in [dao.ts:140](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L140)* + +**Returns:** *Promise‹[IDAOStaticState](../interfaces/idaostaticstate.md)›* + +___ + +### member + +▸ **member**(`address`: [Address](../globals.md#address)): *[Member](member.md)* + +*Defined in [dao.ts:238](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L238)* + +**Parameters:** + +Name | Type | +------ | ------ | +`address` | [Address](../globals.md#address) | + +**Returns:** *[Member](member.md)* + +___ + +### members + +▸ **members**(`options`: [IMemberQueryOptions](../interfaces/imemberqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Member](member.md)[]›* + +*Defined in [dao.ts:229](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L229)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IMemberQueryOptions](../interfaces/imemberqueryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Member](member.md)[]›* + +___ + +### nativeReputation + +▸ **nativeReputation**(): *Observable‹[Reputation](reputation.md)›* + +*Defined in [dao.ts:208](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L208)* + +**Returns:** *Observable‹[Reputation](reputation.md)›* + +___ + +### proposal + +▸ **proposal**(`proposalId`: string): *[Proposal](proposal.md)* + +*Defined in [dao.ts:269](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L269)* + +**Parameters:** + +Name | Type | +------ | ------ | +`proposalId` | string | + +**Returns:** *[Proposal](proposal.md)* + +___ + +### proposals + +▸ **proposals**(`options`: [IProposalQueryOptions](../interfaces/iproposalqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Proposal](proposal.md)[]›* + +*Defined in [dao.ts:258](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L258)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IProposalQueryOptions](../interfaces/iproposalqueryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Proposal](proposal.md)[]›* + +___ + +### rewards + +▸ **rewards**(`options`: [IRewardQueryOptions](../interfaces/irewardqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Reward](reward.md)[]›* + +*Defined in [dao.ts:273](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L273)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IRewardQueryOptions](../interfaces/irewardqueryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Reward](reward.md)[]›* + +___ + +### scheme + +▸ **scheme**(`options`: [ISchemeQueryOptions](../interfaces/ischemequeryoptions.md)): *Promise‹[Scheme](scheme.md)›* + +*Defined in [dao.ts:221](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L221)* + +**Parameters:** + +Name | Type | +------ | ------ | +`options` | [ISchemeQueryOptions](../interfaces/ischemequeryoptions.md) | + +**Returns:** *Promise‹[Scheme](scheme.md)›* + +___ + +### schemes + +▸ **schemes**(`options`: [ISchemeQueryOptions](../interfaces/ischemequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Scheme](scheme.md)[]›* + +*Defined in [dao.ts:212](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L212)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [ISchemeQueryOptions](../interfaces/ischemequeryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Scheme](scheme.md)[]›* + +___ + +### setStaticState + +▸ **setStaticState**(`opts`: [IDAOStaticState](../interfaces/idaostaticstate.md)): *void* + +*Defined in [dao.ts:136](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L136)* + +**Parameters:** + +Name | Type | +------ | ------ | +`opts` | [IDAOStaticState](../interfaces/idaostaticstate.md) | + +**Returns:** *void* + +___ + +### stakes + +▸ **stakes**(`options`: [IStakeQueryOptions](../interfaces/istakequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Stake](stake.md)[]›* + +*Defined in [dao.ts:291](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L291)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IStakeQueryOptions](../interfaces/istakequeryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Stake](stake.md)[]›* + +___ + +### state + +▸ **state**(`apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[IDAOState](../interfaces/idaostate.md)›* + +*Defined in [dao.ts:163](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L163)* + +get the current state of the DAO + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[IDAOState](../interfaces/idaostate.md)›* + +an Observable of IDAOState + +___ + +### votes + +▸ **votes**(`options`: [IVoteQueryOptions](../interfaces/ivotequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Vote](vote.md)[]›* + +*Defined in [dao.ts:282](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L282)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IVoteQueryOptions](../interfaces/ivotequeryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Vote](vote.md)[]›* + +___ + +### `Static` search + +▸ **search**(`context`: [Arc](arc.md), `options`: [IDAOQueryOptions](../interfaces/idaoqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[DAO](dao.md)[]›* + +*Defined in [dao.ts:61](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L61)* + +DAO.search(context, options) searches for DAO entities + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`context` | [Arc](arc.md) | - | an Arc instance that provides connection information | +`options` | [IDAOQueryOptions](../interfaces/idaoqueryoptions.md) | {} | the query options, cf. IDAOQueryOptions | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | - | + +**Returns:** *Observable‹[DAO](dao.md)[]›* + +an observable of DAO objects + +## Object literals + +### `Static` fragments + +### ▪ **fragments**: *object* + +*Defined in [dao.ts:44](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L44)* + +### DAOFields + +• **DAOFields**: *any* = gql` + fragment DAOFields on DAO { + id + name + nativeReputation { id, totalSupply } + nativeToken { id, name, symbol, totalSupply } + reputationHoldersCount + }` + +*Defined in [dao.ts:45](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L45)* diff --git a/docs/classes/graphnodeobserver.md b/docs/classes/graphnodeobserver.md new file mode 100644 index 00000000..70218572 --- /dev/null +++ b/docs/classes/graphnodeobserver.md @@ -0,0 +1,249 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [GraphNodeObserver](graphnodeobserver.md) + +# Class: GraphNodeObserver + +handles connections with the Graph + +**`param`** + +## Hierarchy + +* **GraphNodeObserver** + + ↳ [Arc](arc.md) + +## Index + +### Constructors + +* [constructor](graphnodeobserver.md#constructor) + +### Properties + +* [Logger](graphnodeobserver.md#logger) +* [apolloClient](graphnodeobserver.md#optional-apolloclient) +* [graphqlHttpProvider](graphnodeobserver.md#optional-graphqlhttpprovider) +* [graphqlWsProvider](graphnodeobserver.md#optional-graphqlwsprovider) + +### Methods + +* [getObservable](graphnodeobserver.md#getobservable) +* [getObservableList](graphnodeobserver.md#getobservablelist) +* [getObservableListWithFilter](graphnodeobserver.md#getobservablelistwithfilter) +* [getObservableObject](graphnodeobserver.md#getobservableobject) +* [sendQuery](graphnodeobserver.md#sendquery) + +## Constructors + +### constructor + +\+ **new GraphNodeObserver**(`options`: object): *[GraphNodeObserver](graphnodeobserver.md)* + +*Defined in [graphnode.ts:140](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L140)* + +**Parameters:** + +▪ **options**: *object* + +Name | Type | +------ | ------ | +`graphqlHttpProvider?` | undefined | string | +`graphqlWsProvider?` | undefined | string | + +**Returns:** *[GraphNodeObserver](graphnodeobserver.md)* + +## Properties + +### Logger + +• **Logger**: *GlobalLogger* = Logger + +*Defined in [graphnode.ts:139](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L139)* + +___ + +### `Optional` apolloClient + +• **apolloClient**? : *ApolloClient‹object›* + +*Defined in [graphnode.ts:140](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L140)* + +___ + +### `Optional` graphqlHttpProvider + +• **graphqlHttpProvider**? : *undefined | string* + +*Defined in [graphnode.ts:137](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L137)* + +___ + +### `Optional` graphqlWsProvider + +• **graphqlWsProvider**? : *undefined | string* + +*Defined in [graphnode.ts:138](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L138)* + +## Methods + +### getObservable + +▸ **getObservable**(`query`: any, `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *any* + +*Defined in [graphnode.ts:162](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L162)* + +Given a gql query, will return an observable of query results + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`query` | any | - | a gql query object to execute | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | options to pass on to Apollo, cf .. | + +**Returns:** *any* + +an Observable that will first yield the current result, and yields updates every time the data changes + +___ + +### getObservableList + +▸ **getObservableList**(`query`: any, `itemMap`: function, `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *any* + +*Defined in [graphnode.ts:257](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L257)* + +Returns an observable that: +- sends a query over http and returns the current list of results +- subscribes over a websocket to changes, and returns the updated list. + +**`example:`** +``` + const query = gql` + { + daos { + id + address + } + }` + getObservableList(query, (r:any) => new DAO(r.address)) +``` + +**Parameters:** + +▪ **query**: *any* + +The query to be run + +▪`Default value` **itemMap**: *function*= (o) => o + +(optional) a function that takes elements of the list and creates new objects + +▸ (`o`: object): *object | null* + +**Parameters:** + +Name | Type | +------ | ------ | +`o` | object | + +▪`Default value` **apolloQueryOptions**: *[IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)*= {} + +**Returns:** *any* + +an Observable + +___ + +### getObservableListWithFilter + +▸ **getObservableListWithFilter**(`query`: any, `itemMap`: function, `filterFunc`: function, `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *any* + +*Defined in [graphnode.ts:296](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L296)* + +Returns an observable that: +- sends a query over http and returns the current list of results +- subscribes over a websocket to changes, and returns the updated list +example: + const query = gql` + { + daos { + id + address + } + }` + getObservableList(query, (r:any) => new DAO(r.address), filter((r:any) => r.address === "0x1234...")) + +**Parameters:** + +▪ **query**: *any* + +The query to be run + +▪`Default value` **itemMap**: *function*= (o) => o + +(optional) a function that takes elements of the list and creates new objects + +▸ (`o`: object): *object | null* + +**Parameters:** + +Name | Type | +------ | ------ | +`o` | object | + +▪ **filterFunc**: *function* + +▸ (`o`: object): *boolean* + +**Parameters:** + +Name | Type | +------ | ------ | +`o` | object | + +▪`Default value` **apolloQueryOptions**: *[IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)*= {} + +**Returns:** *any* + +___ + +### getObservableObject + +▸ **getObservableObject**(`query`: any, `itemMap`: function, `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *any* + +*Defined in [graphnode.ts:313](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L313)* + +**Parameters:** + +▪ **query**: *any* + +▪`Default value` **itemMap**: *function*= (o) => o + +▸ (`o`: object): *object | null* + +**Parameters:** + +Name | Type | +------ | ------ | +`o` | object | + +▪`Default value` **apolloQueryOptions**: *[IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)*= {} + +**Returns:** *any* + +___ + +### sendQuery + +▸ **sendQuery**(`query`: any): *Promise‹object›* + +*Defined in [graphnode.ts:333](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L333)* + +**Parameters:** + +Name | Type | +------ | ------ | +`query` | any | + +**Returns:** *Promise‹object›* diff --git a/docs/classes/member.md b/docs/classes/member.md new file mode 100644 index 00000000..de2fac08 --- /dev/null +++ b/docs/classes/member.md @@ -0,0 +1,263 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [Member](member.md) + +# Class: Member + +Represents an account that holds reputaion in a specific DAO + +## Hierarchy + +* **Member** + +## Implements + +* [IStateful](../interfaces/istateful.md)‹[IMemberState](../interfaces/imemberstate.md)› + +## Index + +### Constructors + +* [constructor](member.md#constructor) + +### Properties + +* [context](member.md#context) +* [id](member.md#id) +* [staticState](member.md#staticstate) + +### Methods + +* [calculateId](member.md#calculateid) +* [dao](member.md#dao) +* [fetchStaticState](member.md#fetchstaticstate) +* [proposals](member.md#proposals) +* [rewards](member.md#rewards) +* [setStaticState](member.md#setstaticstate) +* [stakes](member.md#stakes) +* [state](member.md#state) +* [votes](member.md#votes) +* [search](member.md#static-search) + +### Object literals + +* [fragments](member.md#static-fragments) + +## Constructors + +### constructor + +\+ **new Member**(`idOrOpts`: string | [IMemberStaticState](../interfaces/imemberstaticstate.md), `context`: [Arc](arc.md)): *[Member](member.md)* + +*Defined in [member.ts:107](https://github.com/daostack/client/blob/18967ff/src/member.ts#L107)* + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`idOrOpts` | string | [IMemberStaticState](../interfaces/imemberstaticstate.md) | - | +`context` | [Arc](arc.md) | an instance of Arc | + +**Returns:** *[Member](member.md)* + +## Properties + +### context + +• **context**: *[Arc](arc.md)* + +*Defined in [member.ts:114](https://github.com/daostack/client/blob/18967ff/src/member.ts#L114)* + +an instance of Arc + +___ + +### id + +• **id**: *string | undefined* + +*Defined in [member.ts:106](https://github.com/daostack/client/blob/18967ff/src/member.ts#L106)* + +___ + +### staticState + +• **staticState**: *[IMemberStaticState](../interfaces/imemberstaticstate.md) | undefined* + +*Defined in [member.ts:107](https://github.com/daostack/client/blob/18967ff/src/member.ts#L107)* + +## Methods + +### calculateId + +▸ **calculateId**(`opts`: object): *string* + +*Defined in [member.ts:136](https://github.com/daostack/client/blob/18967ff/src/member.ts#L136)* + +**Parameters:** + +▪ **opts**: *object* + +Name | Type | +------ | ------ | +`address` | [Address](../globals.md#address) | +`contract` | [Address](../globals.md#address) | + +**Returns:** *string* + +___ + +### dao + +▸ **dao**(): *Promise‹[DAO](dao.md)›* + +*Defined in [member.ts:231](https://github.com/daostack/client/blob/18967ff/src/member.ts#L231)* + +**Returns:** *Promise‹[DAO](dao.md)›* + +___ + +### fetchStaticState + +▸ **fetchStaticState**(): *Promise‹[IMemberStaticState](../interfaces/imemberstaticstate.md)›* + +*Defined in [member.ts:123](https://github.com/daostack/client/blob/18967ff/src/member.ts#L123)* + +**Returns:** *Promise‹[IMemberStaticState](../interfaces/imemberstaticstate.md)›* + +___ + +### proposals + +▸ **proposals**(`options`: [IProposalQueryOptions](../interfaces/iproposalqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Proposal](proposal.md)[]›* + +*Defined in [member.ts:240](https://github.com/daostack/client/blob/18967ff/src/member.ts#L240)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IProposalQueryOptions](../interfaces/iproposalqueryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Proposal](proposal.md)[]›* + +___ + +### rewards + +▸ **rewards**(): *Observable‹[Reward](reward.md)[]›* + +*Defined in [member.ts:236](https://github.com/daostack/client/blob/18967ff/src/member.ts#L236)* + +**Returns:** *Observable‹[Reward](reward.md)[]›* + +___ + +### setStaticState + +▸ **setStaticState**(`opts`: [IMemberStaticState](../interfaces/imemberstaticstate.md)): *[IMemberStaticState](../interfaces/imemberstaticstate.md)* + +*Defined in [member.ts:143](https://github.com/daostack/client/blob/18967ff/src/member.ts#L143)* + +**Parameters:** + +Name | Type | +------ | ------ | +`opts` | [IMemberStaticState](../interfaces/imemberstaticstate.md) | + +**Returns:** *[IMemberStaticState](../interfaces/imemberstaticstate.md)* + +___ + +### stakes + +▸ **stakes**(`options`: [IStakeQueryOptions](../interfaces/istakequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Stake](stake.md)[]›* + +*Defined in [member.ts:256](https://github.com/daostack/client/blob/18967ff/src/member.ts#L256)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IStakeQueryOptions](../interfaces/istakequeryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Stake](stake.md)[]›* + +___ + +### state + +▸ **state**(`apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[IMemberState](../interfaces/imemberstate.md)›* + +*Defined in [member.ts:158](https://github.com/daostack/client/blob/18967ff/src/member.ts#L158)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[IMemberState](../interfaces/imemberstate.md)›* + +___ + +### votes + +▸ **votes**(`options`: [IVoteQueryOptions](../interfaces/ivotequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Vote](vote.md)[]›* + +*Defined in [member.ts:269](https://github.com/daostack/client/blob/18967ff/src/member.ts#L269)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IVoteQueryOptions](../interfaces/ivotequeryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Vote](vote.md)[]›* + +___ + +### `Static` search + +▸ **search**(`context`: [Arc](arc.md), `options`: [IMemberQueryOptions](../interfaces/imemberqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Member](member.md)[]›* + +*Defined in [member.ts:64](https://github.com/daostack/client/blob/18967ff/src/member.ts#L64)* + +Member.search(context, options) searches for member entities + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`context` | [Arc](arc.md) | - | an Arc instance that provides connection information | +`options` | [IMemberQueryOptions](../interfaces/imemberqueryoptions.md) | {} | the query options, cf. IMemberQueryOptions | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | - | + +**Returns:** *Observable‹[Member](member.md)[]›* + +an observable of IRewardState objects + +## Object literals + +### `Static` fragments + +### ▪ **fragments**: *object* + +*Defined in [member.ts:44](https://github.com/daostack/client/blob/18967ff/src/member.ts#L44)* + +### ReputationHolderFields + +• **ReputationHolderFields**: *any* = gql` + fragment ReputationHolderFields on ReputationHolder { + id + address + contract + dao { + id + } + balance + } + ` + +*Defined in [member.ts:45](https://github.com/daostack/client/blob/18967ff/src/member.ts#L45)* diff --git a/docs/classes/proposal.md b/docs/classes/proposal.md new file mode 100644 index 00000000..e9f26658 --- /dev/null +++ b/docs/classes/proposal.md @@ -0,0 +1,471 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [Proposal](proposal.md) + +# Class: Proposal + +## Hierarchy + +* **Proposal** + +## Implements + +* [IStateful](../interfaces/istateful.md)‹[IProposalState](../interfaces/iproposalstate.md)› + +## Index + +### Constructors + +* [constructor](proposal.md#constructor) + +### Properties + +* [context](proposal.md#context) +* [id](proposal.md#id) +* [staticState](proposal.md#staticstate) + +### Methods + +* [claimRewards](proposal.md#claimrewards) +* [execute](proposal.md#execute) +* [fetchStaticState](proposal.md#fetchstaticstate) +* [redeemerContract](proposal.md#redeemercontract) +* [rewards](proposal.md#rewards) +* [scheme](proposal.md#scheme) +* [setStaticState](proposal.md#setstaticstate) +* [stake](proposal.md#stake) +* [stakes](proposal.md#stakes) +* [stakingToken](proposal.md#stakingtoken) +* [state](proposal.md#state) +* [vote](proposal.md#vote) +* [votes](proposal.md#votes) +* [votingMachine](proposal.md#votingmachine) +* [create](proposal.md#static-create) +* [search](proposal.md#static-search) + +### Object literals + +* [fragments](proposal.md#static-fragments) + +## Constructors + +### constructor + +\+ **new Proposal**(`idOrOpts`: string | [IProposalStaticState](../interfaces/iproposalstaticstate.md), `context`: [Arc](arc.md)): *[Proposal](proposal.md)* + +*Defined in [proposal.ts:341](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L341)* + +**Parameters:** + +Name | Type | +------ | ------ | +`idOrOpts` | string | [IProposalStaticState](../interfaces/iproposalstaticstate.md) | +`context` | [Arc](arc.md) | + +**Returns:** *[Proposal](proposal.md)* + +## Properties + +### context + +• **context**: *[Arc](arc.md)* + +*Defined in [proposal.ts:339](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L339)* + +___ + +### id + +• **id**: *string* + +*Defined in [proposal.ts:340](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L340)* + +___ + +### staticState + +• **staticState**: *[IProposalStaticState](../interfaces/iproposalstaticstate.md) | undefined* + +*Defined in [proposal.ts:341](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L341)* + +## Methods + +### claimRewards + +▸ **claimRewards**(`beneficiary?`: [Address](../globals.md#address)): *[Operation](../globals.md#operation)‹boolean›* + +*Defined in [proposal.ts:737](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L737)* + +[claimRewards description] Execute the proposal and distribute the rewards +to the beneficiary. +This uses the Redeemer.sol helper contract + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`beneficiary?` | [Address](../globals.md#address) | Addresss of the beneficiary, optional, if undefined will only redeem the ContributionReward rewards | + +**Returns:** *[Operation](../globals.md#operation)‹boolean›* + +an Operation + +___ + +### execute + +▸ **execute**(): *[Operation](../globals.md#operation)‹any›* + +*Defined in [proposal.ts:771](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L771)* + +calll the 'execute()' function on the votingMachine. +the main purpose of this function is to set the stage of the proposals +this call may (or may not) "execute" the proposal itself (i.e. do what the proposal proposes) + +**Returns:** *[Operation](../globals.md#operation)‹any›* + +an Operation that, when sucessful, will contain the receipt of the transaction + +___ + +### fetchStaticState + +▸ **fetchStaticState**(): *Promise‹[IProposalStaticState](../interfaces/iproposalstaticstate.md)›* + +*Defined in [proposal.ts:359](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L359)* + +**Returns:** *Promise‹[IProposalStaticState](../interfaces/iproposalstaticstate.md)›* + +___ + +### redeemerContract + +▸ **redeemerContract**(): *any* + +*Defined in [proposal.ts:570](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L570)* + +[redeemerContract description] + +**Returns:** *any* + +a web3 Contract instance + +___ + +### rewards + +▸ **rewards**(`options`: [IRewardQueryOptions](../interfaces/irewardqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Reward](reward.md)[]›* + +*Defined in [proposal.ts:720](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L720)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IRewardQueryOptions](../interfaces/irewardqueryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Reward](reward.md)[]›* + +___ + +### scheme + +▸ **scheme**(): *Promise‹any›* + +*Defined in [proposal.ts:554](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L554)* + +**Returns:** *Promise‹any›* + +___ + +### setStaticState + +▸ **setStaticState**(`opts`: [IProposalStaticState](../interfaces/iproposalstaticstate.md)): *void* + +*Defined in [proposal.ts:355](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L355)* + +**Parameters:** + +Name | Type | +------ | ------ | +`opts` | [IProposalStaticState](../interfaces/iproposalstaticstate.md) | + +**Returns:** *void* + +___ + +### stake + +▸ **stake**(`outcome`: [IProposalOutcome](../enums/iproposaloutcome.md), `amount`: any): *[Operation](../globals.md#operation)‹[Stake](stake.md)›* + +*Defined in [proposal.ts:654](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L654)* + +**Parameters:** + +Name | Type | +------ | ------ | +`outcome` | [IProposalOutcome](../enums/iproposaloutcome.md) | +`amount` | any | + +**Returns:** *[Operation](../globals.md#operation)‹[Stake](stake.md)›* + +___ + +### stakes + +▸ **stakes**(`options`: [IStakeQueryOptions](../interfaces/istakequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Stake](stake.md)[]›* + +*Defined in [proposal.ts:648](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L648)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IStakeQueryOptions](../interfaces/istakequeryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Stake](stake.md)[]›* + +___ + +### stakingToken + +▸ **stakingToken**(): *[Token](token.md)* + +*Defined in [proposal.ts:644](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L644)* + +**Returns:** *[Token](token.md)* + +___ + +### state + +▸ **state**(`apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[IProposalState](../interfaces/iproposalstate.md)›* + +*Defined in [proposal.ts:381](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L381)* + +`state` is an observable of the proposal state + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[IProposalState](../interfaces/iproposalstate.md)›* + +___ + +### vote + +▸ **vote**(`outcome`: [IProposalOutcome](../enums/iproposaloutcome.md), `amount`: number): *[Operation](../globals.md#operation)‹[Vote](vote.md) | null›* + +*Defined in [proposal.ts:592](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L592)* + +Vote for this proposal + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`outcome` | [IProposalOutcome](../enums/iproposaloutcome.md) | - | one of IProposalOutcome.Pass (0) or IProposalOutcome.FAIL (1) | +`amount` | number | 0 | the amount of reputation to vote with. Defaults to 0 - in that case, all the sender's rep will be used | + +**Returns:** *[Operation](../globals.md#operation)‹[Vote](vote.md) | null›* + +an observable Operation + +___ + +### votes + +▸ **votes**(`options`: [IVoteQueryOptions](../interfaces/ivotequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Vote](vote.md)[]›* + +*Defined in [proposal.ts:579](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L579)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IVoteQueryOptions](../interfaces/ivotequeryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Vote](vote.md)[]›* + +___ + +### votingMachine + +▸ **votingMachine**(): *Promise‹any›* + +*Defined in [proposal.ts:562](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L562)* + +[votingMachine description] + +**Returns:** *Promise‹any›* + +a web3 Contract instance + +___ + +### `Static` create + +▸ **create**(`options`: [IProposalCreateOptions](../globals.md#iproposalcreateoptions), `context`: [Arc](arc.md)): *[Operation](../globals.md#operation)‹[Proposal](proposal.md)›* + +*Defined in [proposal.ts:221](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L221)* + +Proposal.create() creates a new proposal + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`options` | [IProposalCreateOptions](../globals.md#iproposalcreateoptions) | cf. IProposalCreateOptions | +`context` | [Arc](arc.md) | - | + +**Returns:** *[Operation](../globals.md#operation)‹[Proposal](proposal.md)›* + +an observable that streams the various states + +___ + +### `Static` search + +▸ **search**(`context`: [Arc](arc.md), `options`: [IProposalQueryOptions](../interfaces/iproposalqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Proposal](proposal.md)[]›* + +*Defined in [proposal.ts:260](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L260)* + +Search for proposals + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`context` | [Arc](arc.md) | - | An instance of Arc | +`options` | [IProposalQueryOptions](../interfaces/iproposalqueryoptions.md) | {} | Search options, must implemeent IProposalQueryOptions | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | - | + +**Returns:** *Observable‹[Proposal](proposal.md)[]›* + +An observable of lists of results + +For example: + Proposal.search({ stage: IProposalStage.Queued}) + +## Object literals + +### `Static` fragments + +### ▪ **fragments**: *object* + +*Defined in [proposal.ts:106](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L106)* + +### ProposalFields + +• **ProposalFields**: *any* = gql`fragment ProposalFields on Proposal { + id + accountsWithUnclaimedRewards + boostedAt + confidenceThreshold + contributionReward { + id + beneficiary + ethReward + externalToken + externalTokenReward + externalToken + nativeTokenReward + periods + periodLength + reputationReward + alreadyRedeemedReputationPeriods + alreadyRedeemedExternalTokenPeriods + alreadyRedeemedNativeTokenPeriods + alreadyRedeemedEthPeriods + } + createdAt + dao { + id + schemes { + id + address + } + } + description + descriptionHash + executedAt + executionState + expiresInQueueAt + genericScheme { + id + contractToCall + callData + executed + returnValue + } + genesisProtocolParams { + activationTime + boostedVotePeriodLimit + daoBountyConst + limitExponentValue + minimumDaoBounty + preBoostedVotePeriodLimit + proposingRepReward + queuedVotePeriodLimit + queuedVoteRequiredPercentage + quietEndingPeriod + thresholdConst + votersReputationLossRatio + } + gpRewards { + id + } + scheme { + id + paramsHash + name + address + canDelegateCall + canManageGlobalConstraints + canRegisterSchemes + canUpgradeController + name + } + gpQueue { + id + threshold + votingMachine + } + organizationId + preBoostedAt + proposer + quietEndingPeriodBeganAt + schemeRegistrar { + id + schemeToRegister + schemeToRegisterParamsHash + schemeToRegisterPermission + schemeToRemove + decision + schemeRegistered + schemeRemoved + } + stage + stakes { + id + } + stakesFor + stakesAgainst + totalRepWhenCreated + totalRepWhenExecuted + title + url + votes { + id + } + votesAgainst + votesFor + votingMachine + winningOutcome + }` + +*Defined in [proposal.ts:107](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L107)* diff --git a/docs/classes/queue.md b/docs/classes/queue.md new file mode 100644 index 00000000..1949f011 --- /dev/null +++ b/docs/classes/queue.md @@ -0,0 +1,108 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [Queue](queue.md) + +# Class: Queue + +## Hierarchy + +* **Queue** + +## Implements + +* [IStateful](../interfaces/istateful.md)‹[IQueueState](../interfaces/iqueuestate.md)› + +## Index + +### Constructors + +* [constructor](queue.md#constructor) + +### Properties + +* [context](queue.md#context) +* [dao](queue.md#dao) +* [id](queue.md#id) + +### Methods + +* [state](queue.md#state) +* [search](queue.md#static-search) + +## Constructors + +### constructor + +\+ **new Queue**(`id`: string, `dao`: [DAO](dao.md), `context`: [Arc](arc.md)): *[Queue](queue.md)* + +*Defined in [queue.ts:86](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L86)* + +**Parameters:** + +Name | Type | +------ | ------ | +`id` | string | +`dao` | [DAO](dao.md) | +`context` | [Arc](arc.md) | + +**Returns:** *[Queue](queue.md)* + +## Properties + +### context + +• **context**: *[Arc](arc.md)* + +*Defined in [queue.ts:91](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L91)* + +___ + +### dao + +• **dao**: *[DAO](dao.md)* + +*Defined in [queue.ts:90](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L90)* + +___ + +### id + +• **id**: *string* + +*Defined in [queue.ts:89](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L89)* + +## Methods + +### state + +▸ **state**(`apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[IQueueState](../interfaces/iqueuestate.md)›* + +*Defined in [queue.ts:96](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L96)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[IQueueState](../interfaces/iqueuestate.md)›* + +___ + +### `Static` search + +▸ **search**(`context`: [Arc](arc.md), `options`: [IQueueQueryOptions](../interfaces/iqueuequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Queue](queue.md)[]›* + +*Defined in [queue.ts:38](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L38)* + +Queue.search(context, options) searches for queue entities + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`context` | [Arc](arc.md) | - | an Arc instance that provides connection information | +`options` | [IQueueQueryOptions](../interfaces/iqueuequeryoptions.md) | {} | the query options, cf. IQueueQueryOptions | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | - | + +**Returns:** *Observable‹[Queue](queue.md)[]›* + +an observable of Queue objects diff --git a/docs/classes/reputation.md b/docs/classes/reputation.md new file mode 100644 index 00000000..ffcec74a --- /dev/null +++ b/docs/classes/reputation.md @@ -0,0 +1,153 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [Reputation](reputation.md) + +# Class: Reputation + +## Hierarchy + +* **Reputation** + +## Implements + +* [IStateful](../interfaces/istateful.md)‹[IReputationState](../interfaces/ireputationstate.md)› + +## Index + +### Constructors + +* [constructor](reputation.md#constructor) + +### Properties + +* [address](reputation.md#address) +* [context](reputation.md#context) +* [id](reputation.md#id) + +### Methods + +* [contract](reputation.md#contract) +* [mint](reputation.md#mint) +* [reputationOf](reputation.md#reputationof) +* [state](reputation.md#state) +* [search](reputation.md#static-search) + +## Constructors + +### constructor + +\+ **new Reputation**(`id`: [Address](../globals.md#address), `context`: [Arc](arc.md)): *[Reputation](reputation.md)* + +*Defined in [reputation.ts:66](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L66)* + +**Parameters:** + +Name | Type | +------ | ------ | +`id` | [Address](../globals.md#address) | +`context` | [Arc](arc.md) | + +**Returns:** *[Reputation](reputation.md)* + +## Properties + +### address + +• **address**: *[Address](../globals.md#address)* + +*Defined in [reputation.ts:66](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L66)* + +___ + +### context + +• **context**: *[Arc](arc.md)* + +*Defined in [reputation.ts:67](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L67)* + +___ + +### id + +• **id**: *[Address](../globals.md#address)* + +*Defined in [reputation.ts:67](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L67)* + +## Methods + +### contract + +▸ **contract**(): *any* + +*Defined in [reputation.ts:118](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L118)* + +**Returns:** *any* + +___ + +### mint + +▸ **mint**(`beneficiary`: [Address](../globals.md#address), `amount`: any): *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹any››* + +*Defined in [reputation.ts:123](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L123)* + +**Parameters:** + +Name | Type | +------ | ------ | +`beneficiary` | [Address](../globals.md#address) | +`amount` | any | + +**Returns:** *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹any››* + +___ + +### reputationOf + +▸ **reputationOf**(`address`: [Address](../globals.md#address)): *Observable‹any›* + +*Defined in [reputation.ts:94](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L94)* + +**Parameters:** + +Name | Type | +------ | ------ | +`address` | [Address](../globals.md#address) | + +**Returns:** *Observable‹any›* + +___ + +### state + +▸ **state**(`apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[IReputationState](../interfaces/ireputationstate.md)›* + +*Defined in [reputation.ts:71](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L71)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[IReputationState](../interfaces/ireputationstate.md)›* + +___ + +### `Static` search + +▸ **search**(`context`: [Arc](arc.md), `options`: [IReputationQueryOptions](../interfaces/ireputationqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Reputation](reputation.md)[]›* + +*Defined in [reputation.ts:30](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L30)* + +Reputation.search(context, options) searches for reputation entities + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`context` | [Arc](arc.md) | - | an Arc instance that provides connection information | +`options` | [IReputationQueryOptions](../interfaces/ireputationqueryoptions.md) | {} | the query options, cf. IReputationQueryOptions | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | - | + +**Returns:** *Observable‹[Reputation](reputation.md)[]›* + +an observable of Reputation objects diff --git a/docs/classes/reputationfromtokenscheme.md b/docs/classes/reputationfromtokenscheme.md new file mode 100644 index 00000000..f2985bab --- /dev/null +++ b/docs/classes/reputationfromtokenscheme.md @@ -0,0 +1,89 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [ReputationFromTokenScheme](reputationfromtokenscheme.md) + +# Class: ReputationFromTokenScheme + +## Hierarchy + +* **ReputationFromTokenScheme** + +## Index + +### Constructors + +* [constructor](reputationfromtokenscheme.md#constructor) + +### Properties + +* [scheme](reputationfromtokenscheme.md#scheme) + +### Methods + +* [getContract](reputationfromtokenscheme.md#private-getcontract) +* [redeem](reputationfromtokenscheme.md#redeem) +* [redemptionAmount](reputationfromtokenscheme.md#redemptionamount) + +## Constructors + +### constructor + +\+ **new ReputationFromTokenScheme**(`scheme`: [Scheme](scheme.md)): *[ReputationFromTokenScheme](reputationfromtokenscheme.md)* + +*Defined in [schemes/reputationFromToken.ts:13](https://github.com/daostack/client/blob/18967ff/src/schemes/reputationFromToken.ts#L13)* + +**Parameters:** + +Name | Type | +------ | ------ | +`scheme` | [Scheme](scheme.md) | + +**Returns:** *[ReputationFromTokenScheme](reputationfromtokenscheme.md)* + +## Properties + +### scheme + +• **scheme**: *[Scheme](scheme.md)* + +*Defined in [schemes/reputationFromToken.ts:15](https://github.com/daostack/client/blob/18967ff/src/schemes/reputationFromToken.ts#L15)* + +## Methods + +### `Private` getContract + +▸ **getContract**(): *Promise‹any›* + +*Defined in [schemes/reputationFromToken.ts:47](https://github.com/daostack/client/blob/18967ff/src/schemes/reputationFromToken.ts#L47)* + +**Returns:** *Promise‹any›* + +___ + +### redeem + +▸ **redeem**(`beneficiary`: [Address](../globals.md#address)): *[Operation](../globals.md#operation)‹any›* + +*Defined in [schemes/reputationFromToken.ts:19](https://github.com/daostack/client/blob/18967ff/src/schemes/reputationFromToken.ts#L19)* + +**Parameters:** + +Name | Type | +------ | ------ | +`beneficiary` | [Address](../globals.md#address) | + +**Returns:** *[Operation](../globals.md#operation)‹any›* + +___ + +### redemptionAmount + +▸ **redemptionAmount**(`beneficiary`: [Address](../globals.md#address)): *Promise‹number›* + +*Defined in [schemes/reputationFromToken.ts:41](https://github.com/daostack/client/blob/18967ff/src/schemes/reputationFromToken.ts#L41)* + +**Parameters:** + +Name | Type | +------ | ------ | +`beneficiary` | [Address](../globals.md#address) | + +**Returns:** *Promise‹number›* diff --git a/docs/classes/reward.md b/docs/classes/reward.md new file mode 100644 index 00000000..a32b2196 --- /dev/null +++ b/docs/classes/reward.md @@ -0,0 +1,98 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [Reward](reward.md) + +# Class: Reward + +## Hierarchy + +* **Reward** + +## Implements + +* [IStateful](../interfaces/istateful.md)‹[IRewardState](../interfaces/irewardstate.md)› + +## Index + +### Constructors + +* [constructor](reward.md#constructor) + +### Properties + +* [context](reward.md#context) +* [id](reward.md#id) + +### Methods + +* [state](reward.md#state) +* [search](reward.md#static-search) + +## Constructors + +### constructor + +\+ **new Reward**(`id`: string, `context`: [Arc](arc.md)): *[Reward](reward.md)* + +*Defined in [reward.ts:76](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L76)* + +**Parameters:** + +Name | Type | +------ | ------ | +`id` | string | +`context` | [Arc](arc.md) | + +**Returns:** *[Reward](reward.md)* + +## Properties + +### context + +• **context**: *[Arc](arc.md)* + +*Defined in [reward.ts:78](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L78)* + +___ + +### id + +• **id**: *string* + +*Defined in [reward.ts:78](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L78)* + +## Methods + +### state + +▸ **state**(`apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[IRewardState](../interfaces/irewardstate.md)›* + +*Defined in [reward.ts:83](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L83)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[IRewardState](../interfaces/irewardstate.md)›* + +___ + +### `Static` search + +▸ **search**(`context`: [Arc](arc.md), `options`: [IRewardQueryOptions](../interfaces/irewardqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Reward](reward.md)[]›* + +*Defined in [reward.ts:44](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L44)* + +Reward.search(context, options) searches for reward entities + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`context` | [Arc](arc.md) | - | an Arc instance that provides connection information | +`options` | [IRewardQueryOptions](../interfaces/irewardqueryoptions.md) | {} | the query options, cf. IRewardQueryOptions | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | - | + +**Returns:** *Observable‹[Reward](reward.md)[]›* + +an observable of Reward objects diff --git a/docs/classes/scheme.md b/docs/classes/scheme.md new file mode 100644 index 00000000..c587e687 --- /dev/null +++ b/docs/classes/scheme.md @@ -0,0 +1,190 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [Scheme](scheme.md) + +# Class: Scheme + +A Scheme represents a scheme instance that is registered at a DAO + +## Hierarchy + +* **Scheme** + +## Implements + +* [IStateful](../interfaces/istateful.md)‹[ISchemeState](../interfaces/ischemestate.md)› + +## Index + +### Constructors + +* [constructor](scheme.md#constructor) + +### Properties + +* [ReputationFromToken](scheme.md#reputationfromtoken) +* [context](scheme.md#context) +* [id](scheme.md#id) +* [staticState](scheme.md#staticstate) + +### Methods + +* [createProposal](scheme.md#createproposal) +* [fetchStaticState](scheme.md#fetchstaticstate) +* [proposals](scheme.md#proposals) +* [setStaticState](scheme.md#setstaticstate) +* [state](scheme.md#state) +* [search](scheme.md#static-search) + +## Constructors + +### constructor + +\+ **new Scheme**(`idOrOpts`: [Address](../globals.md#address) | [ISchemeStaticState](../interfaces/ischemestaticstate.md), `context`: [Arc](arc.md)): *[Scheme](scheme.md)* + +*Defined in [scheme.ts:144](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L144)* + +**Parameters:** + +Name | Type | +------ | ------ | +`idOrOpts` | [Address](../globals.md#address) | [ISchemeStaticState](../interfaces/ischemestaticstate.md) | +`context` | [Arc](arc.md) | + +**Returns:** *[Scheme](scheme.md)* + +## Properties + +### ReputationFromToken + +• **ReputationFromToken**: *[ReputationFromTokenScheme](reputationfromtokenscheme.md) | null* = null + +*Defined in [scheme.ts:144](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L144)* + +___ + +### context + +• **context**: *[Arc](arc.md)* + +*Defined in [scheme.ts:146](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L146)* + +___ + +### id + +• **id**: *[Address](../globals.md#address)* + +*Defined in [scheme.ts:142](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L142)* + +___ + +### staticState + +• **staticState**: *[ISchemeStaticState](../interfaces/ischemestaticstate.md) | null* = null + +*Defined in [scheme.ts:143](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L143)* + +## Methods + +### createProposal + +▸ **createProposal**(`options`: [IProposalCreateOptions](../globals.md#iproposalcreateoptions)): *[Operation](../globals.md#operation)‹[Proposal](proposal.md)›* + +*Defined in [scheme.ts:314](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L314)* + +create a new proposal in this DAO +TODO: move this to the schemes - we should call proposal.scheme.createProposal + +**Parameters:** + +Name | Type | +------ | ------ | +`options` | [IProposalCreateOptions](../globals.md#iproposalcreateoptions) | + +**Returns:** *[Operation](../globals.md#operation)‹[Proposal](proposal.md)›* + +a Proposal instance + +___ + +### fetchStaticState + +▸ **fetchStaticState**(): *Promise‹[ISchemeStaticState](../interfaces/ischemestaticstate.md)›* + +*Defined in [scheme.ts:165](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L165)* + +fetch the static state from the subgraph + +**Returns:** *Promise‹[ISchemeStaticState](../interfaces/ischemestaticstate.md)›* + +the statatic state + +___ + +### proposals + +▸ **proposals**(`options`: [IProposalQueryOptions](../interfaces/iproposalqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Proposal](proposal.md)[]›* + +*Defined in [scheme.ts:352](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L352)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [IProposalQueryOptions](../interfaces/iproposalqueryoptions.md) | {} | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[Proposal](proposal.md)[]›* + +___ + +### setStaticState + +▸ **setStaticState**(`opts`: [ISchemeStaticState](../interfaces/ischemestaticstate.md)): *void* + +*Defined in [scheme.ts:157](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L157)* + +**Parameters:** + +Name | Type | +------ | ------ | +`opts` | [ISchemeStaticState](../interfaces/ischemestaticstate.md) | + +**Returns:** *void* + +___ + +### state + +▸ **state**(`apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[ISchemeState](../interfaces/ischemestate.md)›* + +*Defined in [scheme.ts:187](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L187)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[ISchemeState](../interfaces/ischemestate.md)›* + +___ + +### `Static` search + +▸ **search**(`context`: [Arc](arc.md), `options`: [ISchemeQueryOptions](../interfaces/ischemequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Scheme](scheme.md)[]›* + +*Defined in [scheme.ts:86](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L86)* + +Scheme.search(context, options) searches for scheme entities + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`context` | [Arc](arc.md) | - | an Arc instance that provides connection information | +`options` | [ISchemeQueryOptions](../interfaces/ischemequeryoptions.md) | {} | the query options, cf. ISchemeQueryOptions | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | - | + +**Returns:** *Observable‹[Scheme](scheme.md)[]›* + +an observable of Scheme objects diff --git a/docs/classes/stake.md b/docs/classes/stake.md new file mode 100644 index 00000000..a2dc9eb1 --- /dev/null +++ b/docs/classes/stake.md @@ -0,0 +1,135 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [Stake](stake.md) + +# Class: Stake + +## Hierarchy + +* **Stake** + +## Implements + +* [IStateful](../interfaces/istateful.md)‹[IStakeState](../interfaces/istakestate.md)› + +## Index + +### Constructors + +* [constructor](stake.md#constructor) + +### Properties + +* [context](stake.md#context) +* [id](stake.md#id) +* [staticState](stake.md#staticstate) + +### Methods + +* [fetchStaticState](stake.md#fetchstaticstate) +* [setStaticState](stake.md#setstaticstate) +* [state](stake.md#state) +* [search](stake.md#static-search) + +## Constructors + +### constructor + +\+ **new Stake**(`idOrOpts`: string | [IStakeStaticState](../interfaces/istakestaticstate.md), `context`: [Arc](arc.md)): *[Stake](stake.md)* + +*Defined in [stake.ts:102](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L102)* + +**Parameters:** + +Name | Type | +------ | ------ | +`idOrOpts` | string | [IStakeStaticState](../interfaces/istakestaticstate.md) | +`context` | [Arc](arc.md) | + +**Returns:** *[Stake](stake.md)* + +## Properties + +### context + +• **context**: *[Arc](arc.md)* + +*Defined in [stake.ts:106](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L106)* + +___ + +### id + +• **id**: *string | undefined* + +*Defined in [stake.ts:101](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L101)* + +___ + +### staticState + +• **staticState**: *[IStakeStaticState](../interfaces/istakestaticstate.md) | undefined* + +*Defined in [stake.ts:102](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L102)* + +## Methods + +### fetchStaticState + +▸ **fetchStaticState**(): *Promise‹[IStakeStaticState](../interfaces/istakestaticstate.md)›* + +*Defined in [stake.ts:152](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L152)* + +**Returns:** *Promise‹[IStakeStaticState](../interfaces/istakestaticstate.md)›* + +___ + +### setStaticState + +▸ **setStaticState**(`opts`: [IStakeStaticState](../interfaces/istakestaticstate.md)): *void* + +*Defined in [stake.ts:148](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L148)* + +**Parameters:** + +Name | Type | +------ | ------ | +`opts` | [IStakeStaticState](../interfaces/istakestaticstate.md) | + +**Returns:** *void* + +___ + +### state + +▸ **state**(`apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[IStakeState](../interfaces/istakestate.md)›* + +*Defined in [stake.ts:116](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L116)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[IStakeState](../interfaces/istakestate.md)›* + +___ + +### `Static` search + +▸ **search**(`context`: [Arc](arc.md), `options`: [IStakeQueryOptions](../interfaces/istakequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Stake](stake.md)[]›* + +*Defined in [stake.ts:41](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L41)* + +Stake.search(context, options) searches for stake entities + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`context` | [Arc](arc.md) | - | an Arc instance that provides connection information | +`options` | [IStakeQueryOptions](../interfaces/istakequeryoptions.md) | {} | the query options, cf. IStakeQueryOptions | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | - | + +**Returns:** *Observable‹[Stake](stake.md)[]›* + +an observable of Stake objects diff --git a/docs/classes/token.md b/docs/classes/token.md new file mode 100644 index 00000000..919d4704 --- /dev/null +++ b/docs/classes/token.md @@ -0,0 +1,213 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [Token](token.md) + +# Class: Token + +## Hierarchy + +* **Token** + +## Implements + +* [IStateful](../interfaces/istateful.md)‹[ITokenState](../interfaces/itokenstate.md)› + +## Index + +### Constructors + +* [constructor](token.md#constructor) + +### Properties + +* [address](token.md#address) +* [context](token.md#context) +* [id](token.md#id) + +### Methods + +* [allowance](token.md#allowance) +* [approveForStaking](token.md#approveforstaking) +* [balanceOf](token.md#balanceof) +* [contract](token.md#contract) +* [mint](token.md#mint) +* [state](token.md#state) +* [transfer](token.md#transfer) +* [search](token.md#static-search) + +## Constructors + +### constructor + +\+ **new Token**(`id`: [Address](../globals.md#address), `context`: [Arc](arc.md)): *[Token](token.md)* + +*Defined in [token.ts:86](https://github.com/daostack/client/blob/18967ff/src/token.ts#L86)* + +**Parameters:** + +Name | Type | +------ | ------ | +`id` | [Address](../globals.md#address) | +`context` | [Arc](arc.md) | + +**Returns:** *[Token](token.md)* + +## Properties + +### address + +• **address**: *string* + +*Defined in [token.ts:86](https://github.com/daostack/client/blob/18967ff/src/token.ts#L86)* + +___ + +### context + +• **context**: *[Arc](arc.md)* + +*Defined in [token.ts:88](https://github.com/daostack/client/blob/18967ff/src/token.ts#L88)* + +___ + +### id + +• **id**: *[Address](../globals.md#address)* + +*Defined in [token.ts:88](https://github.com/daostack/client/blob/18967ff/src/token.ts#L88)* + +## Methods + +### allowance + +▸ **allowance**(`owner`: [Address](../globals.md#address), `spender`: [Address](../globals.md#address)): *Observable‹any›* + +*Defined in [token.ts:179](https://github.com/daostack/client/blob/18967ff/src/token.ts#L179)* + +**Parameters:** + +Name | Type | +------ | ------ | +`owner` | [Address](../globals.md#address) | +`spender` | [Address](../globals.md#address) | + +**Returns:** *Observable‹any›* + +___ + +### approveForStaking + +▸ **approveForStaking**(`spender`: [Address](../globals.md#address), `amount`: any): *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹any››* + +*Defined in [token.ts:220](https://github.com/daostack/client/blob/18967ff/src/token.ts#L220)* + +**Parameters:** + +Name | Type | +------ | ------ | +`spender` | [Address](../globals.md#address) | +`amount` | any | + +**Returns:** *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹any››* + +___ + +### balanceOf + +▸ **balanceOf**(`owner`: string): *Observable‹any›* + +*Defined in [token.ts:132](https://github.com/daostack/client/blob/18967ff/src/token.ts#L132)* + +**Parameters:** + +Name | Type | +------ | ------ | +`owner` | string | + +**Returns:** *Observable‹any›* + +___ + +### contract + +▸ **contract**(`mode?`: undefined | "readonly"): *any* + +*Defined in [token.ts:127](https://github.com/daostack/client/blob/18967ff/src/token.ts#L127)* + +**Parameters:** + +Name | Type | +------ | ------ | +`mode?` | undefined | "readonly" | + +**Returns:** *any* + +___ + +### mint + +▸ **mint**(`beneficiary`: [Address](../globals.md#address), `amount`: any): *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹any››* + +*Defined in [token.ts:206](https://github.com/daostack/client/blob/18967ff/src/token.ts#L206)* + +**Parameters:** + +Name | Type | +------ | ------ | +`beneficiary` | [Address](../globals.md#address) | +`amount` | any | + +**Returns:** *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹any››* + +___ + +### state + +▸ **state**(`apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[ITokenState](../interfaces/itokenstate.md)›* + +*Defined in [token.ts:96](https://github.com/daostack/client/blob/18967ff/src/token.ts#L96)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[ITokenState](../interfaces/itokenstate.md)›* + +___ + +### transfer + +▸ **transfer**(`beneficiary`: [Address](../globals.md#address), `amount`: any): *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹any››* + +*Defined in [token.ts:213](https://github.com/daostack/client/blob/18967ff/src/token.ts#L213)* + +**Parameters:** + +Name | Type | +------ | ------ | +`beneficiary` | [Address](../globals.md#address) | +`amount` | any | + +**Returns:** *[IOperationObservable](../interfaces/ioperationobservable.md)‹[ITransactionUpdate](../interfaces/itransactionupdate.md)‹any››* + +___ + +### `Static` search + +▸ **search**(`context`: [Arc](arc.md), `options`: [ITokenQueryOptions](../interfaces/itokenqueryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Token](token.md)[]›* + +*Defined in [token.ts:52](https://github.com/daostack/client/blob/18967ff/src/token.ts#L52)* + +Token.search(context, options) searches for token entities + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`context` | [Arc](arc.md) | - | an Arc instance that provides connection information | +`options` | [ITokenQueryOptions](../interfaces/itokenqueryoptions.md) | {} | the query options, cf. ITokenQueryOptions | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | - | + +**Returns:** *Observable‹[Token](token.md)[]›* + +an observable of Token objects diff --git a/docs/classes/vote.md b/docs/classes/vote.md new file mode 100644 index 00000000..f8c88d60 --- /dev/null +++ b/docs/classes/vote.md @@ -0,0 +1,135 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [Vote](vote.md) + +# Class: Vote + +## Hierarchy + +* **Vote** + +## Implements + +* [IStateful](../interfaces/istateful.md)‹[IVoteState](../interfaces/ivotestate.md)› + +## Index + +### Constructors + +* [constructor](vote.md#constructor) + +### Properties + +* [context](vote.md#context) +* [id](vote.md#id) +* [staticState](vote.md#staticstate) + +### Methods + +* [fetchStaticState](vote.md#fetchstaticstate) +* [setStaticState](vote.md#setstaticstate) +* [state](vote.md#state) +* [search](vote.md#static-search) + +## Constructors + +### constructor + +\+ **new Vote**(`idOrOpts`: string | [IVoteStaticState](../interfaces/ivotestaticstate.md), `context`: [Arc](arc.md)): *[Vote](vote.md)* + +*Defined in [vote.ts:113](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L113)* + +**Parameters:** + +Name | Type | +------ | ------ | +`idOrOpts` | string | [IVoteStaticState](../interfaces/ivotestaticstate.md) | +`context` | [Arc](arc.md) | + +**Returns:** *[Vote](vote.md)* + +## Properties + +### context + +• **context**: *[Arc](arc.md)* + +*Defined in [vote.ts:115](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L115)* + +___ + +### id + +• **id**: *string | undefined* + +*Defined in [vote.ts:112](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L112)* + +___ + +### staticState + +• **staticState**: *[IVoteStaticState](../interfaces/ivotestaticstate.md) | undefined* + +*Defined in [vote.ts:113](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L113)* + +## Methods + +### fetchStaticState + +▸ **fetchStaticState**(): *Promise‹[IVoteStaticState](../interfaces/ivotestaticstate.md)›* + +*Defined in [vote.ts:163](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L163)* + +**Returns:** *Promise‹[IVoteStaticState](../interfaces/ivotestaticstate.md)›* + +___ + +### setStaticState + +▸ **setStaticState**(`opts`: [IVoteStaticState](../interfaces/ivotestaticstate.md)): *void* + +*Defined in [vote.ts:159](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L159)* + +**Parameters:** + +Name | Type | +------ | ------ | +`opts` | [IVoteStaticState](../interfaces/ivotestaticstate.md) | + +**Returns:** *void* + +___ + +### state + +▸ **state**(`apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[IVoteState](../interfaces/ivotestate.md)›* + +*Defined in [vote.ts:125](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L125)* + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | + +**Returns:** *Observable‹[IVoteState](../interfaces/ivotestate.md)›* + +___ + +### `Static` search + +▸ **search**(`context`: [Arc](arc.md), `options`: [IVoteQueryOptions](../interfaces/ivotequeryoptions.md), `apolloQueryOptions`: [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md)): *Observable‹[Vote](vote.md)[]›* + +*Defined in [vote.ts:42](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L42)* + +Vote.search(context, options) searches for vote entities + +**Parameters:** + +Name | Type | Default | Description | +------ | ------ | ------ | ------ | +`context` | [Arc](arc.md) | - | an Arc instance that provides connection information | +`options` | [IVoteQueryOptions](../interfaces/ivotequeryoptions.md) | {} | the query options, cf. IVoteQueryOptions | +`apolloQueryOptions` | [IApolloQueryOptions](../interfaces/iapolloqueryoptions.md) | {} | - | + +**Returns:** *Observable‹[Vote](vote.md)[]›* + +an observable of Vote objects diff --git a/docs/enums/iexecutionstate.md b/docs/enums/iexecutionstate.md new file mode 100644 index 00000000..198510c9 --- /dev/null +++ b/docs/enums/iexecutionstate.md @@ -0,0 +1,62 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IExecutionState](iexecutionstate.md) + +# Enumeration: IExecutionState + +## Index + +### Enumeration members + +* [BoostedBarCrossed](iexecutionstate.md#boostedbarcrossed) +* [BoostedTimeOut](iexecutionstate.md#boostedtimeout) +* [None](iexecutionstate.md#none) +* [PreBoostedBarCrossed](iexecutionstate.md#preboostedbarcrossed) +* [QueueBarCrossed](iexecutionstate.md#queuebarcrossed) +* [QueueTimeOut](iexecutionstate.md#queuetimeout) + +## Enumeration members + +### BoostedBarCrossed + +• **BoostedBarCrossed**: + +*Defined in [proposal.ts:56](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L56)* + +___ + +### BoostedTimeOut + +• **BoostedTimeOut**: + +*Defined in [proposal.ts:55](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L55)* + +___ + +### None + +• **None**: + +*Defined in [proposal.ts:51](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L51)* + +___ + +### PreBoostedBarCrossed + +• **PreBoostedBarCrossed**: + +*Defined in [proposal.ts:54](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L54)* + +___ + +### QueueBarCrossed + +• **QueueBarCrossed**: + +*Defined in [proposal.ts:52](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L52)* + +___ + +### QueueTimeOut + +• **QueueTimeOut**: + +*Defined in [proposal.ts:53](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L53)* diff --git a/docs/enums/iproposaloutcome.md b/docs/enums/iproposaloutcome.md new file mode 100644 index 00000000..9ad947dd --- /dev/null +++ b/docs/enums/iproposaloutcome.md @@ -0,0 +1,35 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IProposalOutcome](iproposaloutcome.md) + +# Enumeration: IProposalOutcome + +## Index + +### Enumeration members + +* [Fail](iproposaloutcome.md#fail) +* [None](iproposaloutcome.md#none) +* [Pass](iproposaloutcome.md#pass) + +## Enumeration members + +### Fail + +• **Fail**: + +*Defined in [proposal.ts:38](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L38)* + +___ + +### None + +• **None**: + +*Defined in [proposal.ts:36](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L36)* + +___ + +### Pass + +• **Pass**: + +*Defined in [proposal.ts:37](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L37)* diff --git a/docs/enums/iproposalstage.md b/docs/enums/iproposalstage.md new file mode 100644 index 00000000..2417bab2 --- /dev/null +++ b/docs/enums/iproposalstage.md @@ -0,0 +1,62 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IProposalStage](iproposalstage.md) + +# Enumeration: IProposalStage + +## Index + +### Enumeration members + +* [Boosted](iproposalstage.md#boosted) +* [Executed](iproposalstage.md#executed) +* [ExpiredInQueue](iproposalstage.md#expiredinqueue) +* [PreBoosted](iproposalstage.md#preboosted) +* [Queued](iproposalstage.md#queued) +* [QuietEndingPeriod](iproposalstage.md#quietendingperiod) + +## Enumeration members + +### Boosted + +• **Boosted**: + +*Defined in [proposal.ts:46](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L46)* + +___ + +### Executed + +• **Executed**: + +*Defined in [proposal.ts:43](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L43)* + +___ + +### ExpiredInQueue + +• **ExpiredInQueue**: + +*Defined in [proposal.ts:42](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L42)* + +___ + +### PreBoosted + +• **PreBoosted**: + +*Defined in [proposal.ts:45](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L45)* + +___ + +### Queued + +• **Queued**: + +*Defined in [proposal.ts:44](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L44)* + +___ + +### QuietEndingPeriod + +• **QuietEndingPeriod**: + +*Defined in [proposal.ts:47](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L47)* diff --git a/docs/enums/itransactionstate.md b/docs/enums/itransactionstate.md new file mode 100644 index 00000000..297aa809 --- /dev/null +++ b/docs/enums/itransactionstate.md @@ -0,0 +1,35 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [ITransactionState](itransactionstate.md) + +# Enumeration: ITransactionState + +## Index + +### Enumeration members + +* [Mined](itransactionstate.md#mined) +* [Sending](itransactionstate.md#sending) +* [Sent](itransactionstate.md#sent) + +## Enumeration members + +### Mined + +• **Mined**: + +*Defined in [operation.ts:11](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L11)* + +___ + +### Sending + +• **Sending**: + +*Defined in [operation.ts:9](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L9)* + +___ + +### Sent + +• **Sent**: + +*Defined in [operation.ts:10](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L10)* diff --git a/docs/enums/proposalquerysortoptions.md b/docs/enums/proposalquerysortoptions.md new file mode 100644 index 00000000..36cc2f6f --- /dev/null +++ b/docs/enums/proposalquerysortoptions.md @@ -0,0 +1,26 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [ProposalQuerySortOptions](proposalquerysortoptions.md) + +# Enumeration: ProposalQuerySortOptions + +## Index + +### Enumeration members + +* [preBoostedAt](proposalquerysortoptions.md#preboostedat) +* [resolvesAt](proposalquerysortoptions.md#resolvesat) + +## Enumeration members + +### preBoostedAt + +• **preBoostedAt**: = "preBoostedAt" + +*Defined in [proposal.ts:804](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L804)* + +___ + +### resolvesAt + +• **resolvesAt**: = "resolvesAt" + +*Defined in [proposal.ts:803](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L803)* diff --git a/docs/globals.md b/docs/globals.md new file mode 100644 index 00000000..a3237d33 --- /dev/null +++ b/docs/globals.md @@ -0,0 +1,689 @@ +[@daostack/client](README.md) › [Globals](globals.md) + +# @daostack/client + +## Index + +### Enumerations + +* [IExecutionState](enums/iexecutionstate.md) +* [IProposalOutcome](enums/iproposaloutcome.md) +* [IProposalStage](enums/iproposalstage.md) +* [ITransactionState](enums/itransactionstate.md) +* [ProposalQuerySortOptions](enums/proposalquerysortoptions.md) + +### Classes + +* [Arc](classes/arc.md) +* [DAO](classes/dao.md) +* [GraphNodeObserver](classes/graphnodeobserver.md) +* [Member](classes/member.md) +* [Proposal](classes/proposal.md) +* [Queue](classes/queue.md) +* [Reputation](classes/reputation.md) +* [ReputationFromTokenScheme](classes/reputationfromtokenscheme.md) +* [Reward](classes/reward.md) +* [Scheme](classes/scheme.md) +* [Stake](classes/stake.md) +* [Token](classes/token.md) +* [Vote](classes/vote.md) + +### Interfaces + +* [IAllowance](interfaces/iallowance.md) +* [IApolloQueryOptions](interfaces/iapolloqueryoptions.md) +* [IApproval](interfaces/iapproval.md) +* [ICommonQueryOptions](interfaces/icommonqueryoptions.md) +* [IContractAddresses](interfaces/icontractaddresses.md) +* [IContractInfo](interfaces/icontractinfo.md) +* [IContributionReward](interfaces/icontributionreward.md) +* [IDAOQueryOptions](interfaces/idaoqueryoptions.md) +* [IDAOState](interfaces/idaostate.md) +* [IDAOStaticState](interfaces/idaostaticstate.md) +* [IGenericScheme](interfaces/igenericscheme.md) +* [IGenericSchemeInfo](interfaces/igenericschemeinfo.md) +* [IGenesisProtocolParams](interfaces/igenesisprotocolparams.md) +* [IMemberQueryOptions](interfaces/imemberqueryoptions.md) +* [IMemberState](interfaces/imemberstate.md) +* [IMemberStaticState](interfaces/imemberstaticstate.md) +* [IObservable](interfaces/iobservable.md) +* [IOperationObservable](interfaces/ioperationobservable.md) +* [IProposalBaseCreateOptions](interfaces/iproposalbasecreateoptions.md) +* [IProposalCreateOptionsCR](interfaces/iproposalcreateoptionscr.md) +* [IProposalCreateOptionsGS](interfaces/iproposalcreateoptionsgs.md) +* [IProposalCreateOptionsSR](interfaces/iproposalcreateoptionssr.md) +* [IProposalQueryOptions](interfaces/iproposalqueryoptions.md) +* [IProposalState](interfaces/iproposalstate.md) +* [IProposalStaticState](interfaces/iproposalstaticstate.md) +* [IQueueQueryOptions](interfaces/iqueuequeryoptions.md) +* [IQueueState](interfaces/iqueuestate.md) +* [IQueueStaticState](interfaces/iqueuestaticstate.md) +* [IReputationQueryOptions](interfaces/ireputationqueryoptions.md) +* [IReputationState](interfaces/ireputationstate.md) +* [IRewardQueryOptions](interfaces/irewardqueryoptions.md) +* [IRewardState](interfaces/irewardstate.md) +* [ISchemeQueryOptions](interfaces/ischemequeryoptions.md) +* [ISchemeRegistrar](interfaces/ischemeregistrar.md) +* [ISchemeState](interfaces/ischemestate.md) +* [ISchemeStaticState](interfaces/ischemestaticstate.md) +* [IStakeQueryOptions](interfaces/istakequeryoptions.md) +* [IStakeState](interfaces/istakestate.md) +* [IStakeStaticState](interfaces/istakestaticstate.md) +* [IStateful](interfaces/istateful.md) +* [ITokenQueryOptions](interfaces/itokenqueryoptions.md) +* [ITokenState](interfaces/itokenstate.md) +* [ITransactionUpdate](interfaces/itransactionupdate.md) +* [IVoteQueryOptions](interfaces/ivotequeryoptions.md) +* [IVoteState](interfaces/ivotestate.md) +* [IVoteStaticState](interfaces/ivotestaticstate.md) + +### Type aliases + +* [Address](globals.md#address) +* [Date](globals.md#date) +* [EthereumEvent](globals.md#ethereumevent) +* [Hash](globals.md#hash) +* [IPFSProvider](globals.md#ipfsprovider) +* [IProposalCreateOptions](globals.md#iproposalcreateoptions) +* [Operation](globals.md#operation) +* [Web3Provider](globals.md#web3provider) +* [Web3Receipt](globals.md#web3receipt) +* [web3receipt](globals.md#web3receipt) + +### Variables + +* [BN](globals.md#const-bn) +* [DAOTOKEN_CONTRACT_VERSION](globals.md#const-daotoken_contract_version) +* [IPFSClient](globals.md#const-ipfsclient) +* [LATEST_ARC_VERSION](globals.md#const-latest_arc_version) +* [NULL_ADDRESS](globals.md#const-null_address) +* [REDEEMER_CONTRACT_VERSION](globals.md#const-redeemer_contract_version) +* [REPUTATION_CONTRACT_VERSION](globals.md#const-reputation_contract_version) +* [Web3](globals.md#const-web3) + +### Functions + +* [checkWebsocket](globals.md#checkwebsocket) +* [concat](globals.md#concat) +* [createApolloClient](globals.md#createapolloclient) +* [createGraphQlQuery](globals.md#creategraphqlquery) +* [createTransaction](globals.md#createtransaction) +* [createTransactionMap](globals.md#createtransactionmap) +* [eventId](globals.md#eventid) +* [fromWei](globals.md#fromwei) +* [getContractAddressesFromMigration](globals.md#getcontractaddressesfrommigration) +* [hexStringToUint8Array](globals.md#hexstringtouint8array) +* [isAddress](globals.md#isaddress) +* [mapGenesisProtocolParams](globals.md#mapgenesisprotocolparams) +* [realMathToNumber](globals.md#realmathtonumber) +* [sendTransaction](globals.md#sendtransaction) +* [toIOperationObservable](globals.md#toioperationobservable) +* [toWei](globals.md#towei) +* [zenToRxjsObservable](globals.md#zentorxjsobservable) + +### Object literals + +* [IProposalType](globals.md#const-iproposaltype) + +## Type aliases + +### Address + +Ƭ **Address**: *string* + +*Defined in [types.ts:3](https://github.com/daostack/client/blob/18967ff/src/types.ts#L3)* + +___ + +### Date + +Ƭ **Date**: *number* + +*Defined in [types.ts:4](https://github.com/daostack/client/blob/18967ff/src/types.ts#L4)* + +___ + +### EthereumEvent + +Ƭ **EthereumEvent**: *any* + +*Defined in [utils.ts:60](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L60)* + +___ + +### Hash + +Ƭ **Hash**: *string* + +*Defined in [types.ts:5](https://github.com/daostack/client/blob/18967ff/src/types.ts#L5)* + +___ + +### IPFSProvider + +Ƭ **IPFSProvider**: *string | object* + +*Defined in [types.ts:21](https://github.com/daostack/client/blob/18967ff/src/types.ts#L21)* + +___ + +### IProposalCreateOptions + +Ƭ **IProposalCreateOptions**: *[IProposalBaseCreateOptions](interfaces/iproposalbasecreateoptions.md) & [IProposalCreateOptionsGS](interfaces/iproposalcreateoptionsgs.md) | [IProposalBaseCreateOptions](interfaces/iproposalbasecreateoptions.md) & [IProposalCreateOptionsSR](interfaces/iproposalcreateoptionssr.md) | [IProposalBaseCreateOptions](interfaces/iproposalbasecreateoptions.md) & [IProposalCreateOptionsCR](interfaces/iproposalcreateoptionscr.md)* + +*Defined in [proposal.ts:840](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L840)* + +___ + +### Operation + +Ƭ **Operation**: *[IOperationObservable](interfaces/ioperationobservable.md)‹[ITransactionUpdate](interfaces/itransactionupdate.md)‹T››* + +*Defined in [operation.ts:39](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L39)* + +___ + +### Web3Provider + +Ƭ **Web3Provider**: *string | object* + +*Defined in [types.ts:7](https://github.com/daostack/client/blob/18967ff/src/types.ts#L7)* + +___ + +### Web3Receipt + +Ƭ **Web3Receipt**: *any* + +*Defined in [types.ts:6](https://github.com/daostack/client/blob/18967ff/src/types.ts#L6)* + +___ + +### web3receipt + +Ƭ **web3receipt**: *object* + +*Defined in [operation.ts:41](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L41)* + +## Variables + +### `Const` BN + +• **BN**: *any* = require('bn.js') + +*Defined in [utils.ts:7](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L7)* + +___ + +### `Const` DAOTOKEN_CONTRACT_VERSION + +• **DAOTOKEN_CONTRACT_VERSION**: *"0.0.1-rc.19"* = "0.0.1-rc.19" + +*Defined in [settings.ts:5](https://github.com/daostack/client/blob/18967ff/src/settings.ts#L5)* + +___ + +### `Const` IPFSClient + +• **IPFSClient**: *any* = require('ipfs-http-client') + +*Defined in [arc.ts:16](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L16)* + +___ + +### `Const` LATEST_ARC_VERSION + +• **LATEST_ARC_VERSION**: *"0.0.1-rc.19"* = "0.0.1-rc.19" + +*Defined in [settings.ts:6](https://github.com/daostack/client/blob/18967ff/src/settings.ts#L6)* + +___ + +### `Const` NULL_ADDRESS + +• **NULL_ADDRESS**: *"0x0000000000000000000000000000000000000000"* = "0x0000000000000000000000000000000000000000" + +*Defined in [utils.ts:158](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L158)* + +___ + +### `Const` REDEEMER_CONTRACT_VERSION + +• **REDEEMER_CONTRACT_VERSION**: *"0.0.1-rc.22"* = "0.0.1-rc.22" + +*Defined in [settings.ts:2](https://github.com/daostack/client/blob/18967ff/src/settings.ts#L2)* + +___ + +### `Const` REPUTATION_CONTRACT_VERSION + +• **REPUTATION_CONTRACT_VERSION**: *"0.0.1-rc.19"* = "0.0.1-rc.19" + +*Defined in [settings.ts:4](https://github.com/daostack/client/blob/18967ff/src/settings.ts#L4)* + +___ + +### `Const` Web3 + +• **Web3**: *any* = require('web3') + +*Defined in [utils.ts:6](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L6)* + +*Defined in [arc.ts:17](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L17)* + +## Functions + +### checkWebsocket + +▸ **checkWebsocket**(`options`: object): *void* + +*Defined in [utils.ts:17](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L17)* + +**Parameters:** + +▪ **options**: *object* + +Name | Type | +------ | ------ | +`url` | string | + +**Returns:** *void* + +___ + +### concat + +▸ **concat**(`a`: Uint8Array, `b`: Uint8Array): *Uint8Array* + +*Defined in [utils.ts:48](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L48)* + +**Parameters:** + +Name | Type | +------ | ------ | +`a` | Uint8Array | +`b` | Uint8Array | + +**Returns:** *Uint8Array* + +___ + +### createApolloClient + +▸ **createApolloClient**(`options`: object): *ApolloClient‹NormalizedCacheObject›* + +*Defined in [graphnode.ts:26](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L26)* + +**Parameters:** + +▪ **options**: *object* + +Name | Type | +------ | ------ | +`graphqlHttpProvider` | string | +`graphqlWsProvider` | string | +`prefetchHook?` | any | + +**Returns:** *ApolloClient‹NormalizedCacheObject›* + +___ + +### createGraphQlQuery + +▸ **createGraphQlQuery**(`options`: [ICommonQueryOptions](interfaces/icommonqueryoptions.md), `where`: string): *string* + +*Defined in [utils.ts:187](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L187)* + +creates a string to be plugsging into a graphql query + +**`example`** +`{ proposals ${createGraphQlQuery({ skip: 2}, 'id: "2"')} + { id } +}` + +**Parameters:** + +Name | Type | Default | +------ | ------ | ------ | +`options` | [ICommonQueryOptions](interfaces/icommonqueryoptions.md) | - | +`where` | string | "" | + +**Returns:** *string* + +___ + +### createTransaction + +▸ **createTransaction**(`options`: any, `context`: [Arc](classes/arc.md)): *(Anonymous function)* + +*Defined in [schemes/contributionReward.ts:37](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L37)* + +**Parameters:** + +Name | Type | +------ | ------ | +`options` | any | +`context` | [Arc](classes/arc.md) | + +**Returns:** *(Anonymous function)* + +___ + +### createTransactionMap + +▸ **createTransactionMap**(`options`: any, `context`: [Arc](classes/arc.md)): *map* + +*Defined in [schemes/contributionReward.ts:61](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L61)* + +map the transaction receipt of the createTransaction call to a nice result + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`options` | any | the options passed to the createProposal call | +`context` | [Arc](classes/arc.md) | an Arc instance | + +**Returns:** *map* + +___ + +### eventId + +▸ **eventId**(`event`: [EthereumEvent](globals.md#ethereumevent)): *string* + +*Defined in [utils.ts:62](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L62)* + +**Parameters:** + +Name | Type | +------ | ------ | +`event` | [EthereumEvent](globals.md#ethereumevent) | + +**Returns:** *string* + +___ + +### fromWei + +▸ **fromWei**(`amount`: any): *string* + +*Defined in [utils.ts:9](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L9)* + +**Parameters:** + +Name | Type | +------ | ------ | +`amount` | any | + +**Returns:** *string* + +___ + +### getContractAddressesFromMigration + +▸ **getContractAddressesFromMigration**(`environment`: "private" | "rinkeby" | "mainnet"): *[IContractInfo](interfaces/icontractinfo.md)[]* + +*Defined in [utils.ts:160](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L160)* + +**Parameters:** + +Name | Type | +------ | ------ | +`environment` | "private" | "rinkeby" | "mainnet" | + +**Returns:** *[IContractInfo](interfaces/icontractinfo.md)[]* + +___ + +### hexStringToUint8Array + +▸ **hexStringToUint8Array**(`hexString`: string): *Uint8Array* + +*Defined in [utils.ts:39](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L39)* + +**Parameters:** + +Name | Type | +------ | ------ | +`hexString` | string | + +**Returns:** *Uint8Array* + +___ + +### isAddress + +▸ **isAddress**(`address`: [Address](globals.md#address)): *void* + +*Defined in [utils.ts:67](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L67)* + +**Parameters:** + +Name | Type | +------ | ------ | +`address` | [Address](globals.md#address) | + +**Returns:** *void* + +___ + +### mapGenesisProtocolParams + +▸ **mapGenesisProtocolParams**(`params`: [IGenesisProtocolParams](interfaces/igenesisprotocolparams.md)): *object* + +*Defined in [genesisProtocol.ts:18](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L18)* + +**Parameters:** + +Name | Type | +------ | ------ | +`params` | [IGenesisProtocolParams](interfaces/igenesisprotocolparams.md) | + +**Returns:** *object* + +* **activationTime**: *number* = Number(params.activationTime) + +* **boostedVotePeriodLimit**: *number* = Number(params.boostedVotePeriodLimit) + +* **daoBountyConst**: *number* = Number(params.daoBountyConst) + +* **limitExponentValue**: *number* = Number(params.limitExponentValue) + +* **minimumDaoBounty**: *any* = new BN(params.minimumDaoBounty) + +* **preBoostedVotePeriodLimit**: *number* = Number(params.preBoostedVotePeriodLimit) + +* **proposingRepReward**: *any* = new BN(params.proposingRepReward) + +* **queuedVotePeriodLimit**: *number* = Number(params.queuedVotePeriodLimit) + +* **queuedVoteRequiredPercentage**: *number* = Number(params.queuedVoteRequiredPercentage) + +* **quietEndingPeriod**: *number* = Number(params.quietEndingPeriod) + +* **thresholdConst**: *number* = realMathToNumber(new BN(params.thresholdConst)) + +* **votersReputationLossRatio**: *number* = Number(params.votersReputationLossRatio) + +___ + +### realMathToNumber + +▸ **realMathToNumber**(`t`: any): *number* + +*Defined in [utils.ts:152](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L152)* + +convert the number representation of RealMath.sol representations to real real numbers + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`t` | any | a BN instance of a real number in the RealMath representation | + +**Returns:** *number* + +a BN + +___ + +### sendTransaction + +▸ **sendTransaction**<**T**>(`transaction`: any, `mapReceipt`: function, `errorHandler`: function, `context`: [Arc](classes/arc.md)): *[Operation](globals.md#operation)‹T›* + +*Defined in [operation.ts:60](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L60)* + +send a transaction to the ethereumblockchain, and return a observable of ITransactionUpdatessend +for example: + sendTransaction(.....).subscribe((txUpdate) => { + if (txUpdate.state === 'sent' ) { notify("your transaction has been sent, waitin'for it to be mnied") } + if (txUpdate.state === 'mined'} { + notify("your transaction has been mined! It was confirmed ${txUpdate.confirmations} times"} + // and we also ahve the txUpdate.receipt and the txUpdate.result to do stuff with + } + }) + +**`parameter`** transaction A web3 transaction, or an (async) function that returns a transaction + +**`parameter`** map A function that takes the receipt of the transaction and returns an object + +**`parameter`** errorHandler A function that takes an error, and either returns or throws a more informative Error + +**`parameter`** context An instance of Arc + +**Type parameters:** + +▪ **T** + +**Parameters:** + +▪ **transaction**: *any* + +▪ **mapReceipt**: *function* + +▸ (`receipt`: [web3receipt](globals.md#web3receipt)): *T | Promise‹T›* + +**Parameters:** + +Name | Type | +------ | ------ | +`receipt` | [web3receipt](globals.md#web3receipt) | + +▪`Default value` **errorHandler**: *function*= (error) => error + +▸ (`error`: Error): *Promise‹Error› | Error* + +**Parameters:** + +Name | Type | +------ | ------ | +`error` | Error | + +▪ **context**: *[Arc](classes/arc.md)* + +**Returns:** *[Operation](globals.md#operation)‹T›* + +An observable with ITransactionUpdate instnces + +___ + +### toIOperationObservable + +▸ **toIOperationObservable**<**T**>(`observable`: Observable‹T›): *[IOperationObservable](interfaces/ioperationobservable.md)‹T›* + +*Defined in [operation.ts:168](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L168)* + +**Type parameters:** + +▪ **T** + +**Parameters:** + +Name | Type | +------ | ------ | +`observable` | Observable‹T› | + +**Returns:** *[IOperationObservable](interfaces/ioperationobservable.md)‹T›* + +___ + +### toWei + +▸ **toWei**(`amount`: string | number): *any* + +*Defined in [utils.ts:13](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L13)* + +**Parameters:** + +Name | Type | +------ | ------ | +`amount` | string | number | + +**Returns:** *any* + +___ + +### zenToRxjsObservable + +▸ **zenToRxjsObservable**(`zenObservable`: ZenObservable‹any›): *any* + +*Defined in [utils.ts:81](https://github.com/daostack/client/blob/18967ff/src/utils.ts#L81)* + +convert a ZenObservable to an rxjs.Observable + +**Parameters:** + +Name | Type | +------ | ------ | +`zenObservable` | ZenObservable‹any› | + +**Returns:** *any* + +an Observable instance + +## Object literals + +### `Const` IProposalType + +### ▪ **IProposalType**: *[ContributionReward](globals.md#contributionreward) | [GenericScheme](globals.md#genericscheme) | [SchemeRegistrarAdd](globals.md#schemeregistraradd) | [SchemeRegistrarEdit](globals.md#schemeregistraredit) | [SchemeRegistrarRemove](globals.md#schemeregistrarremove)* + +*Defined in [schemes/contributionReward.ts:33](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L33)* + +*Defined in [schemes/genericScheme.ts:23](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L23)* + +*Defined in [schemes/schemeRegistrar.ts:22](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L22)* + +*Defined in [proposal.ts:23](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L23)* + +*Defined in [proposal.ts:29](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L29)* + +### ContributionReward + +• **ContributionReward**: = "ContributionReward" + +*Defined in [schemes/contributionReward.ts:34](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L34)* + +### GenericScheme + +• **GenericScheme**: = "GenericScheme" + +*Defined in [schemes/genericScheme.ts:24](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L24)* + +### SchemeRegistrarAdd + +• **SchemeRegistrarAdd**: = "SchemeRegistrarAdd" + +*Defined in [schemes/schemeRegistrar.ts:23](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L23)* + +### SchemeRegistrarEdit + +• **SchemeRegistrarEdit**: = "SchemeRegistrarEdit" + +*Defined in [schemes/schemeRegistrar.ts:24](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L24)* + +### SchemeRegistrarRemove + +• **SchemeRegistrarRemove**: = "SchemeRegistrarRemove" + +*Defined in [schemes/schemeRegistrar.ts:25](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L25)* diff --git a/docs/interfaces/iallowance.md b/docs/interfaces/iallowance.md new file mode 100644 index 00000000..f547a9e6 --- /dev/null +++ b/docs/interfaces/iallowance.md @@ -0,0 +1,48 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IAllowance](iallowance.md) + +# Interface: IAllowance + +## Hierarchy + +* **IAllowance** + +## Index + +### Properties + +* [amount](iallowance.md#amount) +* [owner](iallowance.md#owner) +* [spender](iallowance.md#spender) +* [token](iallowance.md#token) + +## Properties + +### amount + +• **amount**: *any* + +*Defined in [token.ts:41](https://github.com/daostack/client/blob/18967ff/src/token.ts#L41)* + +___ + +### owner + +• **owner**: *[Address](../globals.md#address)* + +*Defined in [token.ts:39](https://github.com/daostack/client/blob/18967ff/src/token.ts#L39)* + +___ + +### spender + +• **spender**: *[Address](../globals.md#address)* + +*Defined in [token.ts:40](https://github.com/daostack/client/blob/18967ff/src/token.ts#L40)* + +___ + +### token + +• **token**: *[Address](../globals.md#address)* + +*Defined in [token.ts:38](https://github.com/daostack/client/blob/18967ff/src/token.ts#L38)* diff --git a/docs/interfaces/iapolloqueryoptions.md b/docs/interfaces/iapolloqueryoptions.md new file mode 100644 index 00000000..910af768 --- /dev/null +++ b/docs/interfaces/iapolloqueryoptions.md @@ -0,0 +1,39 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IApolloQueryOptions](iapolloqueryoptions.md) + +# Interface: IApolloQueryOptions + +## Hierarchy + +* **IApolloQueryOptions** + +## Index + +### Properties + +* [fetchAllData](iapolloqueryoptions.md#optional-fetchalldata) +* [fetchPolicy](iapolloqueryoptions.md#optional-fetchpolicy) +* [subscribe](iapolloqueryoptions.md#optional-subscribe) + +## Properties + +### `Optional` fetchAllData + +• **fetchAllData**? : *true | false* + +*Defined in [graphnode.ts:19](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L19)* + +___ + +### `Optional` fetchPolicy + +• **fetchPolicy**? : *"cache-first" | "cache-and-network" | "network-only" | "cache-only" | "no-cache" | "standby"* + +*Defined in [graphnode.ts:17](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L17)* + +___ + +### `Optional` subscribe + +• **subscribe**? : *true | false* + +*Defined in [graphnode.ts:18](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L18)* diff --git a/docs/interfaces/iapproval.md b/docs/interfaces/iapproval.md new file mode 100644 index 00000000..628ef205 --- /dev/null +++ b/docs/interfaces/iapproval.md @@ -0,0 +1,66 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IApproval](iapproval.md) + +# Interface: IApproval + +## Hierarchy + +* **IApproval** + +## Index + +### Properties + +* [contract](iapproval.md#contract) +* [id](iapproval.md#id) +* [owner](iapproval.md#owner) +* [spender](iapproval.md#spender) +* [txHash](iapproval.md#txhash) +* [value](iapproval.md#value) + +## Properties + +### contract + +• **contract**: *[Address](../globals.md#address)* + +*Defined in [token.ts:31](https://github.com/daostack/client/blob/18967ff/src/token.ts#L31)* + +___ + +### id + +• **id**: *[Hash](../globals.md#hash)* + +*Defined in [token.ts:29](https://github.com/daostack/client/blob/18967ff/src/token.ts#L29)* + +___ + +### owner + +• **owner**: *[Address](../globals.md#address)* + +*Defined in [token.ts:32](https://github.com/daostack/client/blob/18967ff/src/token.ts#L32)* + +___ + +### spender + +• **spender**: *[Address](../globals.md#address)* + +*Defined in [token.ts:33](https://github.com/daostack/client/blob/18967ff/src/token.ts#L33)* + +___ + +### txHash + +• **txHash**: *[Hash](../globals.md#hash)* + +*Defined in [token.ts:30](https://github.com/daostack/client/blob/18967ff/src/token.ts#L30)* + +___ + +### value + +• **value**: *any* + +*Defined in [token.ts:34](https://github.com/daostack/client/blob/18967ff/src/token.ts#L34)* diff --git a/docs/interfaces/icommonqueryoptions.md b/docs/interfaces/icommonqueryoptions.md new file mode 100644 index 00000000..434f756f --- /dev/null +++ b/docs/interfaces/icommonqueryoptions.md @@ -0,0 +1,79 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [ICommonQueryOptions](icommonqueryoptions.md) + +# Interface: ICommonQueryOptions + +## Hierarchy + +* **ICommonQueryOptions** + + ↳ [ISchemeQueryOptions](ischemequeryoptions.md) + + ↳ [ISchemeQueryOptions](ischemequeryoptions.md) + + ↳ [IQueueQueryOptions](iqueuequeryoptions.md) + + ↳ [IRewardQueryOptions](irewardqueryoptions.md) + + ↳ [IStakeQueryOptions](istakequeryoptions.md) + + ↳ [IVoteQueryOptions](ivotequeryoptions.md) + + ↳ [IProposalQueryOptions](iproposalqueryoptions.md) + + ↳ [IMemberQueryOptions](imemberqueryoptions.md) + + ↳ [IReputationQueryOptions](ireputationqueryoptions.md) + + ↳ [ITokenQueryOptions](itokenqueryoptions.md) + + ↳ [IDAOQueryOptions](idaoqueryoptions.md) + +## Index + +### Properties + +* [first](icommonqueryoptions.md#optional-first) +* [orderBy](icommonqueryoptions.md#optional-orderby) +* [orderDirection](icommonqueryoptions.md#optional-orderdirection) +* [skip](icommonqueryoptions.md#optional-skip) +* [where](icommonqueryoptions.md#optional-where) + +## Properties + +### `Optional` first + +• **first**? : *undefined | number* + +*Defined in [types.ts:15](https://github.com/daostack/client/blob/18967ff/src/types.ts#L15)* + +___ + +### `Optional` orderBy + +• **orderBy**? : *undefined | string* + +*Defined in [types.ts:16](https://github.com/daostack/client/blob/18967ff/src/types.ts#L16)* + +___ + +### `Optional` orderDirection + +• **orderDirection**? : *"asc" | "desc"* + +*Defined in [types.ts:17](https://github.com/daostack/client/blob/18967ff/src/types.ts#L17)* + +___ + +### `Optional` skip + +• **skip**? : *undefined | number* + +*Defined in [types.ts:14](https://github.com/daostack/client/blob/18967ff/src/types.ts#L14)* + +___ + +### `Optional` where + +• **where**? : *any* + +*Defined in [types.ts:18](https://github.com/daostack/client/blob/18967ff/src/types.ts#L18)* diff --git a/docs/interfaces/icontractaddresses.md b/docs/interfaces/icontractaddresses.md new file mode 100644 index 00000000..0643d9c3 --- /dev/null +++ b/docs/interfaces/icontractaddresses.md @@ -0,0 +1,11 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IContractAddresses](icontractaddresses.md) + +# Interface: IContractAddresses + +## Hierarchy + +* **IContractAddresses** + +## Indexable + +* \[ **key**: *string*\]: [Address](../globals.md#address) diff --git a/docs/interfaces/icontractinfo.md b/docs/interfaces/icontractinfo.md new file mode 100644 index 00000000..47ca2312 --- /dev/null +++ b/docs/interfaces/icontractinfo.md @@ -0,0 +1,48 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IContractInfo](icontractinfo.md) + +# Interface: IContractInfo + +## Hierarchy + +* **IContractInfo** + +## Index + +### Properties + +* [address](icontractinfo.md#address) +* [id](icontractinfo.md#id) +* [name](icontractinfo.md#name) +* [version](icontractinfo.md#version) + +## Properties + +### address + +• **address**: *[Address](../globals.md#address)* + +*Defined in [arc.ts:438](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L438)* + +___ + +### id + +• **id**: *string* + +*Defined in [arc.ts:436](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L436)* + +___ + +### name + +• **name**: *string* + +*Defined in [arc.ts:439](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L439)* + +___ + +### version + +• **version**: *string* + +*Defined in [arc.ts:437](https://github.com/daostack/client/blob/18967ff/src/arc.ts#L437)* diff --git a/docs/interfaces/icontributionreward.md b/docs/interfaces/icontributionreward.md new file mode 100644 index 00000000..fc15e992 --- /dev/null +++ b/docs/interfaces/icontributionreward.md @@ -0,0 +1,120 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IContributionReward](icontributionreward.md) + +# Interface: IContributionReward + +## Hierarchy + +* **IContributionReward** + +## Index + +### Properties + +* [alreadyRedeemedEthPeriods](icontributionreward.md#alreadyredeemedethperiods) +* [alreadyRedeemedExternalTokenPeriods](icontributionreward.md#alreadyredeemedexternaltokenperiods) +* [alreadyRedeemedNativeTokenPeriods](icontributionreward.md#alreadyredeemednativetokenperiods) +* [alreadyRedeemedReputationPeriods](icontributionreward.md#alreadyredeemedreputationperiods) +* [beneficiary](icontributionreward.md#beneficiary) +* [ethReward](icontributionreward.md#ethreward) +* [externalToken](icontributionreward.md#externaltoken) +* [externalTokenReward](icontributionreward.md#externaltokenreward) +* [nativeTokenReward](icontributionreward.md#nativetokenreward) +* [periodLength](icontributionreward.md#periodlength) +* [periods](icontributionreward.md#periods) +* [reputationReward](icontributionreward.md#reputationreward) + +## Properties + +### alreadyRedeemedEthPeriods + +• **alreadyRedeemedEthPeriods**: *number* + +*Defined in [schemes/contributionReward.ts:19](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L19)* + +___ + +### alreadyRedeemedExternalTokenPeriods + +• **alreadyRedeemedExternalTokenPeriods**: *number* + +*Defined in [schemes/contributionReward.ts:18](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L18)* + +___ + +### alreadyRedeemedNativeTokenPeriods + +• **alreadyRedeemedNativeTokenPeriods**: *number* + +*Defined in [schemes/contributionReward.ts:16](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L16)* + +___ + +### alreadyRedeemedReputationPeriods + +• **alreadyRedeemedReputationPeriods**: *number* + +*Defined in [schemes/contributionReward.ts:17](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L17)* + +___ + +### beneficiary + +• **beneficiary**: *[Address](../globals.md#address)* + +*Defined in [schemes/contributionReward.ts:8](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L8)* + +___ + +### ethReward + +• **ethReward**: *BN* + +*Defined in [schemes/contributionReward.ts:11](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L11)* + +___ + +### externalToken + +• **externalToken**: *[Address](../globals.md#address)* + +*Defined in [schemes/contributionReward.ts:10](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L10)* + +___ + +### externalTokenReward + +• **externalTokenReward**: *BN* + +*Defined in [schemes/contributionReward.ts:9](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L9)* + +___ + +### nativeTokenReward + +• **nativeTokenReward**: *BN* + +*Defined in [schemes/contributionReward.ts:12](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L12)* + +___ + +### periodLength + +• **periodLength**: *number* + +*Defined in [schemes/contributionReward.ts:14](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L14)* + +___ + +### periods + +• **periods**: *number* + +*Defined in [schemes/contributionReward.ts:13](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L13)* + +___ + +### reputationReward + +• **reputationReward**: *BN* + +*Defined in [schemes/contributionReward.ts:15](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L15)* diff --git a/docs/interfaces/idaoqueryoptions.md b/docs/interfaces/idaoqueryoptions.md new file mode 100644 index 00000000..94362bac --- /dev/null +++ b/docs/interfaces/idaoqueryoptions.md @@ -0,0 +1,69 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IDAOQueryOptions](idaoqueryoptions.md) + +# Interface: IDAOQueryOptions + +## Hierarchy + +* [ICommonQueryOptions](icommonqueryoptions.md) + + ↳ **IDAOQueryOptions** + +## Index + +### Properties + +* [first](idaoqueryoptions.md#optional-first) +* [orderBy](idaoqueryoptions.md#optional-orderby) +* [orderDirection](idaoqueryoptions.md#optional-orderdirection) +* [skip](idaoqueryoptions.md#optional-skip) +* [where](idaoqueryoptions.md#optional-where) + +## Properties + +### `Optional` first + +• **first**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[first](icommonqueryoptions.md#optional-first)* + +*Defined in [types.ts:15](https://github.com/daostack/client/blob/18967ff/src/types.ts#L15)* + +___ + +### `Optional` orderBy + +• **orderBy**? : *undefined | string* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderBy](icommonqueryoptions.md#optional-orderby)* + +*Defined in [types.ts:16](https://github.com/daostack/client/blob/18967ff/src/types.ts#L16)* + +___ + +### `Optional` orderDirection + +• **orderDirection**? : *"asc" | "desc"* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderDirection](icommonqueryoptions.md#optional-orderdirection)* + +*Defined in [types.ts:17](https://github.com/daostack/client/blob/18967ff/src/types.ts#L17)* + +___ + +### `Optional` skip + +• **skip**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[skip](icommonqueryoptions.md#optional-skip)* + +*Defined in [types.ts:14](https://github.com/daostack/client/blob/18967ff/src/types.ts#L14)* + +___ + +### `Optional` where + +• **where**? : *undefined | object* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[where](icommonqueryoptions.md#optional-where)* + +*Defined in [dao.ts:35](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L35)* diff --git a/docs/interfaces/idaostate.md b/docs/interfaces/idaostate.md new file mode 100644 index 00000000..e2ec4e51 --- /dev/null +++ b/docs/interfaces/idaostate.md @@ -0,0 +1,127 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IDAOState](idaostate.md) + +# Interface: IDAOState + +## Hierarchy + +* [IDAOStaticState](idaostaticstate.md) + + ↳ **IDAOState** + +## Index + +### Properties + +* [address](idaostate.md#address) +* [dao](idaostate.md#dao) +* [id](idaostate.md#id) +* [memberCount](idaostate.md#membercount) +* [name](idaostate.md#name) +* [reputation](idaostate.md#reputation) +* [reputationTotalSupply](idaostate.md#reputationtotalsupply) +* [token](idaostate.md#token) +* [tokenName](idaostate.md#tokenname) +* [tokenSymbol](idaostate.md#tokensymbol) +* [tokenTotalSupply](idaostate.md#tokentotalsupply) + +## Properties + +### address + +• **address**: *[Address](../globals.md#address)* + +*Inherited from [IDAOStaticState](idaostaticstate.md).[address](idaostaticstate.md#address)* + +*Defined in [dao.ts:19](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L19)* + +___ + +### dao + +• **dao**: *[DAO](../classes/dao.md)* + +*Defined in [dao.ts:31](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L31)* + +___ + +### id + +• **id**: *[Address](../globals.md#address)* + +*Inherited from [IDAOStaticState](idaostaticstate.md).[id](idaostaticstate.md#id)* + +*Defined in [dao.ts:18](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L18)* + +___ + +### memberCount + +• **memberCount**: *number* + +*Defined in [dao.ts:28](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L28)* + +___ + +### name + +• **name**: *string* + +*Inherited from [IDAOStaticState](idaostaticstate.md).[name](idaostaticstate.md#name)* + +*Defined in [dao.ts:20](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L20)* + +___ + +### reputation + +• **reputation**: *[Reputation](../classes/reputation.md)* + +*Inherited from [IDAOStaticState](idaostaticstate.md).[reputation](idaostaticstate.md#reputation)* + +*Defined in [dao.ts:21](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L21)* + +___ + +### reputationTotalSupply + +• **reputationTotalSupply**: *any* + +*Defined in [dao.ts:29](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L29)* + +___ + +### token + +• **token**: *[Token](../classes/token.md)* + +*Inherited from [IDAOStaticState](idaostaticstate.md).[token](idaostaticstate.md#token)* + +*Defined in [dao.ts:22](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L22)* + +___ + +### tokenName + +• **tokenName**: *string* + +*Inherited from [IDAOStaticState](idaostaticstate.md).[tokenName](idaostaticstate.md#tokenname)* + +*Defined in [dao.ts:23](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L23)* + +___ + +### tokenSymbol + +• **tokenSymbol**: *string* + +*Inherited from [IDAOStaticState](idaostaticstate.md).[tokenSymbol](idaostaticstate.md#tokensymbol)* + +*Defined in [dao.ts:24](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L24)* + +___ + +### tokenTotalSupply + +• **tokenTotalSupply**: *any* + +*Defined in [dao.ts:30](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L30)* diff --git a/docs/interfaces/idaostaticstate.md b/docs/interfaces/idaostaticstate.md new file mode 100644 index 00000000..f7dd2b32 --- /dev/null +++ b/docs/interfaces/idaostaticstate.md @@ -0,0 +1,77 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IDAOStaticState](idaostaticstate.md) + +# Interface: IDAOStaticState + +## Hierarchy + +* **IDAOStaticState** + + ↳ [IDAOState](idaostate.md) + +## Index + +### Properties + +* [address](idaostaticstate.md#address) +* [id](idaostaticstate.md#id) +* [name](idaostaticstate.md#name) +* [reputation](idaostaticstate.md#reputation) +* [token](idaostaticstate.md#token) +* [tokenName](idaostaticstate.md#tokenname) +* [tokenSymbol](idaostaticstate.md#tokensymbol) + +## Properties + +### address + +• **address**: *[Address](../globals.md#address)* + +*Defined in [dao.ts:19](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L19)* + +___ + +### id + +• **id**: *[Address](../globals.md#address)* + +*Defined in [dao.ts:18](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L18)* + +___ + +### name + +• **name**: *string* + +*Defined in [dao.ts:20](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L20)* + +___ + +### reputation + +• **reputation**: *[Reputation](../classes/reputation.md)* + +*Defined in [dao.ts:21](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L21)* + +___ + +### token + +• **token**: *[Token](../classes/token.md)* + +*Defined in [dao.ts:22](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L22)* + +___ + +### tokenName + +• **tokenName**: *string* + +*Defined in [dao.ts:23](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L23)* + +___ + +### tokenSymbol + +• **tokenSymbol**: *string* + +*Defined in [dao.ts:24](https://github.com/daostack/client/blob/18967ff/src/dao.ts#L24)* diff --git a/docs/interfaces/igenericscheme.md b/docs/interfaces/igenericscheme.md new file mode 100644 index 00000000..62982c06 --- /dev/null +++ b/docs/interfaces/igenericscheme.md @@ -0,0 +1,57 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IGenericScheme](igenericscheme.md) + +# Interface: IGenericScheme + +## Hierarchy + +* **IGenericScheme** + +## Index + +### Properties + +* [callData](igenericscheme.md#calldata) +* [contractToCall](igenericscheme.md#contracttocall) +* [executed](igenericscheme.md#executed) +* [id](igenericscheme.md#id) +* [returnValue](igenericscheme.md#returnvalue) + +## Properties + +### callData + +• **callData**: *string* + +*Defined in [schemes/genericScheme.ts:14](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L14)* + +___ + +### contractToCall + +• **contractToCall**: *[Address](../globals.md#address)* + +*Defined in [schemes/genericScheme.ts:13](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L13)* + +___ + +### executed + +• **executed**: *boolean* + +*Defined in [schemes/genericScheme.ts:15](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L15)* + +___ + +### id + +• **id**: *string* + +*Defined in [schemes/genericScheme.ts:12](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L12)* + +___ + +### returnValue + +• **returnValue**: *string* + +*Defined in [schemes/genericScheme.ts:16](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L16)* diff --git a/docs/interfaces/igenericschemeinfo.md b/docs/interfaces/igenericschemeinfo.md new file mode 100644 index 00000000..63bd88a0 --- /dev/null +++ b/docs/interfaces/igenericschemeinfo.md @@ -0,0 +1,39 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IGenericSchemeInfo](igenericschemeinfo.md) + +# Interface: IGenericSchemeInfo + +## Hierarchy + +* **IGenericSchemeInfo** + +## Index + +### Properties + +* [contractToCall](igenericschemeinfo.md#contracttocall) +* [id](igenericschemeinfo.md#id) +* [votingMachine](igenericschemeinfo.md#votingmachine) + +## Properties + +### contractToCall + +• **contractToCall**: *[Address](../globals.md#address)* + +*Defined in [schemes/genericScheme.ts:7](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L7)* + +___ + +### id + +• **id**: *string* + +*Defined in [schemes/genericScheme.ts:6](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L6)* + +___ + +### votingMachine + +• **votingMachine**: *[Address](../globals.md#address)* + +*Defined in [schemes/genericScheme.ts:8](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L8)* diff --git a/docs/interfaces/igenesisprotocolparams.md b/docs/interfaces/igenesisprotocolparams.md new file mode 100644 index 00000000..24b9e920 --- /dev/null +++ b/docs/interfaces/igenesisprotocolparams.md @@ -0,0 +1,120 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IGenesisProtocolParams](igenesisprotocolparams.md) + +# Interface: IGenesisProtocolParams + +## Hierarchy + +* **IGenesisProtocolParams** + +## Index + +### Properties + +* [activationTime](igenesisprotocolparams.md#activationtime) +* [boostedVotePeriodLimit](igenesisprotocolparams.md#boostedvoteperiodlimit) +* [daoBountyConst](igenesisprotocolparams.md#daobountyconst) +* [limitExponentValue](igenesisprotocolparams.md#limitexponentvalue) +* [minimumDaoBounty](igenesisprotocolparams.md#minimumdaobounty) +* [preBoostedVotePeriodLimit](igenesisprotocolparams.md#preboostedvoteperiodlimit) +* [proposingRepReward](igenesisprotocolparams.md#proposingrepreward) +* [queuedVotePeriodLimit](igenesisprotocolparams.md#queuedvoteperiodlimit) +* [queuedVoteRequiredPercentage](igenesisprotocolparams.md#queuedvoterequiredpercentage) +* [quietEndingPeriod](igenesisprotocolparams.md#quietendingperiod) +* [thresholdConst](igenesisprotocolparams.md#thresholdconst) +* [votersReputationLossRatio](igenesisprotocolparams.md#votersreputationlossratio) + +## Properties + +### activationTime + +• **activationTime**: *number* + +*Defined in [genesisProtocol.ts:4](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L4)* + +___ + +### boostedVotePeriodLimit + +• **boostedVotePeriodLimit**: *number* + +*Defined in [genesisProtocol.ts:5](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L5)* + +___ + +### daoBountyConst + +• **daoBountyConst**: *number* + +*Defined in [genesisProtocol.ts:6](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L6)* + +___ + +### limitExponentValue + +• **limitExponentValue**: *number* + +*Defined in [genesisProtocol.ts:7](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L7)* + +___ + +### minimumDaoBounty + +• **minimumDaoBounty**: *any* + +*Defined in [genesisProtocol.ts:8](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L8)* + +___ + +### preBoostedVotePeriodLimit + +• **preBoostedVotePeriodLimit**: *number* + +*Defined in [genesisProtocol.ts:9](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L9)* + +___ + +### proposingRepReward + +• **proposingRepReward**: *any* + +*Defined in [genesisProtocol.ts:10](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L10)* + +___ + +### queuedVotePeriodLimit + +• **queuedVotePeriodLimit**: *number* + +*Defined in [genesisProtocol.ts:12](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L12)* + +___ + +### queuedVoteRequiredPercentage + +• **queuedVoteRequiredPercentage**: *number* + +*Defined in [genesisProtocol.ts:11](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L11)* + +___ + +### quietEndingPeriod + +• **quietEndingPeriod**: *number* + +*Defined in [genesisProtocol.ts:13](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L13)* + +___ + +### thresholdConst + +• **thresholdConst**: *number* + +*Defined in [genesisProtocol.ts:14](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L14)* + +___ + +### votersReputationLossRatio + +• **votersReputationLossRatio**: *number* + +*Defined in [genesisProtocol.ts:15](https://github.com/daostack/client/blob/18967ff/src/genesisProtocol.ts#L15)* diff --git a/docs/interfaces/imemberqueryoptions.md b/docs/interfaces/imemberqueryoptions.md new file mode 100644 index 00000000..a57f6f86 --- /dev/null +++ b/docs/interfaces/imemberqueryoptions.md @@ -0,0 +1,69 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IMemberQueryOptions](imemberqueryoptions.md) + +# Interface: IMemberQueryOptions + +## Hierarchy + +* [ICommonQueryOptions](icommonqueryoptions.md) + + ↳ **IMemberQueryOptions** + +## Index + +### Properties + +* [first](imemberqueryoptions.md#optional-first) +* [orderBy](imemberqueryoptions.md#optional-orderby) +* [orderDirection](imemberqueryoptions.md#optional-orderdirection) +* [skip](imemberqueryoptions.md#optional-skip) +* [where](imemberqueryoptions.md#optional-where) + +## Properties + +### `Optional` first + +• **first**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[first](icommonqueryoptions.md#optional-first)* + +*Defined in [types.ts:15](https://github.com/daostack/client/blob/18967ff/src/types.ts#L15)* + +___ + +### `Optional` orderBy + +• **orderBy**? : *undefined | string* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderBy](icommonqueryoptions.md#optional-orderby)* + +*Defined in [types.ts:16](https://github.com/daostack/client/blob/18967ff/src/types.ts#L16)* + +___ + +### `Optional` orderDirection + +• **orderDirection**? : *"asc" | "desc"* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderDirection](icommonqueryoptions.md#optional-orderdirection)* + +*Defined in [types.ts:17](https://github.com/daostack/client/blob/18967ff/src/types.ts#L17)* + +___ + +### `Optional` skip + +• **skip**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[skip](icommonqueryoptions.md#optional-skip)* + +*Defined in [types.ts:14](https://github.com/daostack/client/blob/18967ff/src/types.ts#L14)* + +___ + +### `Optional` where + +• **where**? : *undefined | object* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[where](icommonqueryoptions.md#optional-where)* + +*Defined in [member.ts:31](https://github.com/daostack/client/blob/18967ff/src/member.ts#L31)* diff --git a/docs/interfaces/imemberstate.md b/docs/interfaces/imemberstate.md new file mode 100644 index 00000000..12c3e480 --- /dev/null +++ b/docs/interfaces/imemberstate.md @@ -0,0 +1,67 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IMemberState](imemberstate.md) + +# Interface: IMemberState + +## Hierarchy + +* [IMemberStaticState](imemberstaticstate.md) + + ↳ **IMemberState** + +## Index + +### Properties + +* [address](imemberstate.md#address) +* [contract](imemberstate.md#contract) +* [dao](imemberstate.md#optional-dao) +* [id](imemberstate.md#id) +* [reputation](imemberstate.md#reputation) + +## Properties + +### address + +• **address**: *[Address](../globals.md#address)* + +*Inherited from [IMemberStaticState](imemberstaticstate.md).[address](imemberstaticstate.md#address)* + +*Defined in [member.ts:20](https://github.com/daostack/client/blob/18967ff/src/member.ts#L20)* + +___ + +### contract + +• **contract**: *[Address](../globals.md#address)* + +*Overrides [IMemberStaticState](imemberstaticstate.md).[contract](imemberstaticstate.md#optional-contract)* + +*Defined in [member.ts:25](https://github.com/daostack/client/blob/18967ff/src/member.ts#L25)* + +___ + +### `Optional` dao + +• **dao**? : *[Address](../globals.md#address)* + +*Inherited from [IMemberStaticState](imemberstaticstate.md).[dao](imemberstaticstate.md#optional-dao)* + +*Defined in [member.ts:22](https://github.com/daostack/client/blob/18967ff/src/member.ts#L22)* + +___ + +### id + +• **id**: *string* + +*Overrides [IMemberStaticState](imemberstaticstate.md).[id](imemberstaticstate.md#optional-id)* + +*Defined in [member.ts:26](https://github.com/daostack/client/blob/18967ff/src/member.ts#L26)* + +___ + +### reputation + +• **reputation**: *any* + +*Defined in [member.ts:27](https://github.com/daostack/client/blob/18967ff/src/member.ts#L27)* diff --git a/docs/interfaces/imemberstaticstate.md b/docs/interfaces/imemberstaticstate.md new file mode 100644 index 00000000..74548589 --- /dev/null +++ b/docs/interfaces/imemberstaticstate.md @@ -0,0 +1,50 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IMemberStaticState](imemberstaticstate.md) + +# Interface: IMemberStaticState + +## Hierarchy + +* **IMemberStaticState** + + ↳ [IMemberState](imemberstate.md) + +## Index + +### Properties + +* [address](imemberstaticstate.md#address) +* [contract](imemberstaticstate.md#optional-contract) +* [dao](imemberstaticstate.md#optional-dao) +* [id](imemberstaticstate.md#optional-id) + +## Properties + +### address + +• **address**: *[Address](../globals.md#address)* + +*Defined in [member.ts:20](https://github.com/daostack/client/blob/18967ff/src/member.ts#L20)* + +___ + +### `Optional` contract + +• **contract**? : *[Address](../globals.md#address)* + +*Defined in [member.ts:21](https://github.com/daostack/client/blob/18967ff/src/member.ts#L21)* + +___ + +### `Optional` dao + +• **dao**? : *[Address](../globals.md#address)* + +*Defined in [member.ts:22](https://github.com/daostack/client/blob/18967ff/src/member.ts#L22)* + +___ + +### `Optional` id + +• **id**? : *undefined | string* + +*Defined in [member.ts:19](https://github.com/daostack/client/blob/18967ff/src/member.ts#L19)* diff --git a/docs/interfaces/iobservable.md b/docs/interfaces/iobservable.md new file mode 100644 index 00000000..f63a411a --- /dev/null +++ b/docs/interfaces/iobservable.md @@ -0,0 +1,760 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IObservable](iobservable.md) + +# Interface: IObservable <**T**> + +## Type parameters + +▪ **T** + +## Hierarchy + +* Observable‹T› + + ↳ **IObservable** + +## Implements + +* Subscribable‹T› + +## Index + +### Constructors + +* [constructor](iobservable.md#constructor) + +### Properties + +* [_isScalar](iobservable.md#_isscalar) +* [first](iobservable.md#first) +* [operator](iobservable.md#operator) +* [source](iobservable.md#source) +* [create](iobservable.md#static-create) +* [if](iobservable.md#static-if) +* [throw](iobservable.md#static-throw) + +### Methods + +* [_subscribe](iobservable.md#_subscribe) +* [_trySubscribe](iobservable.md#_trysubscribe) +* [forEach](iobservable.md#foreach) +* [lift](iobservable.md#lift) +* [pipe](iobservable.md#pipe) +* [subscribe](iobservable.md#subscribe) +* [toPromise](iobservable.md#topromise) + +## Constructors + +### constructor + +\+ **new IObservable**(`subscribe?`: undefined | function): *[IObservable](iobservable.md)* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:19 + +**`constructor`** + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`subscribe?` | undefined | function | the function that is called when the Observable is initially subscribed to. This function is given a Subscriber, to which new values can be `next`ed, or an `error` method can be called to raise an error, or `complete` can be called to notify of a successful completion. | + +**Returns:** *[IObservable](iobservable.md)* + +## Properties + +### _isScalar + +• **_isScalar**: *boolean* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:15 + +Internal implementation detail, do not use directly. + +___ + +### first + +• **first**: *function* + +*Defined in [graphnode.ts:23](https://github.com/daostack/client/blob/18967ff/src/graphnode.ts#L23)* + +#### Type declaration: + +▸ (): *T* + +___ + +### operator + +• **operator**: *Operator‹any, T›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:19 + +**`deprecated`** This is an internal implementation detail, do not use. + +___ + +### source + +• **source**: *Observable‹any›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:17 + +**`deprecated`** This is an internal implementation detail, do not use. + +___ + +### `Static` create + +▪ **create**: *Function* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:38 + +Creates a new cold Observable by calling the Observable constructor + +**`static`** true + +**`owner`** Observable + +**`method`** create + +**`param`** the subscriber function to be passed to the Observable constructor + +**`returns`** a new cold observable + +**`nocollapse`** + +**`deprecated`** use new Observable() instead + +___ + +### `Static` if + +▪ **if**: *iif* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:71 + +**`nocollapse`** + +**`deprecated`** In favor of iif creation function: import { iif } from 'rxjs'; + +___ + +### `Static` throw + +▪ **throw**: *throwError* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:76 + +**`nocollapse`** + +**`deprecated`** In favor of throwError creation function: import { throwError } from 'rxjs'; + +## Methods + +### _subscribe + +▸ **_subscribe**(`subscriber`: Subscriber‹any›): *TeardownLogic* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:66 + +**`internal`** This is an internal implementation detail, do not use. + +**Parameters:** + +Name | Type | +------ | ------ | +`subscriber` | Subscriber‹any› | + +**Returns:** *TeardownLogic* + +___ + +### _trySubscribe + +▸ **_trySubscribe**(`sink`: Subscriber‹T›): *TeardownLogic* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:56 + +**`deprecated`** This is an internal implementation detail, do not use. + +**Parameters:** + +Name | Type | +------ | ------ | +`sink` | Subscriber‹T› | + +**Returns:** *TeardownLogic* + +___ + +### forEach + +▸ **forEach**(`next`: function, `promiseCtor?`: PromiseConstructorLike): *Promise‹void›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:64 + +**`method`** forEach + +**Parameters:** + +▪ **next**: *function* + +a handler for each value emitted by the observable + +▸ (`value`: T): *void* + +**Parameters:** + +Name | Type | +------ | ------ | +`value` | T | + +▪`Optional` **promiseCtor**: *PromiseConstructorLike* + +**Returns:** *Promise‹void›* + +a promise that either resolves on observable completion or + rejects with the handled error + +___ + +### lift + +▸ **lift**<**R**>(`operator`: Operator‹T, R›): *Observable‹R›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:46 + +Creates a new Observable, with this Observable as the source, and the passed +operator defined as the new observable's operator. + +**`method`** lift + +**Type parameters:** + +▪ **R** + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`operator` | Operator‹T, R› | the operator defining the operation to take on the observable | + +**Returns:** *Observable‹R›* + +a new observable with the Operator applied + +___ + +### pipe + +▸ **pipe**(): *Observable‹T›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:77 + +**Returns:** *Observable‹T›* + +▸ **pipe**<**A**>(`op1`: OperatorFunction‹T, A›): *Observable‹A›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:78 + +**Type parameters:** + +▪ **A** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | + +**Returns:** *Observable‹A›* + +▸ **pipe**<**A**, **B**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›): *Observable‹B›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:79 + +**Type parameters:** + +▪ **A** + +▪ **B** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | + +**Returns:** *Observable‹B›* + +▸ **pipe**<**A**, **B**, **C**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›): *Observable‹C›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:80 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | + +**Returns:** *Observable‹C›* + +▸ **pipe**<**A**, **B**, **C**, **D**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›): *Observable‹D›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:81 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | + +**Returns:** *Observable‹D›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›): *Observable‹E›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:82 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | + +**Returns:** *Observable‹E›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**, **F**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›, `op6`: OperatorFunction‹E, F›): *Observable‹F›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:83 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +▪ **F** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | +`op6` | OperatorFunction‹E, F› | + +**Returns:** *Observable‹F›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**, **F**, **G**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›, `op6`: OperatorFunction‹E, F›, `op7`: OperatorFunction‹F, G›): *Observable‹G›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:84 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +▪ **F** + +▪ **G** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | +`op6` | OperatorFunction‹E, F› | +`op7` | OperatorFunction‹F, G› | + +**Returns:** *Observable‹G›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**, **F**, **G**, **H**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›, `op6`: OperatorFunction‹E, F›, `op7`: OperatorFunction‹F, G›, `op8`: OperatorFunction‹G, H›): *Observable‹H›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:85 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +▪ **F** + +▪ **G** + +▪ **H** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | +`op6` | OperatorFunction‹E, F› | +`op7` | OperatorFunction‹F, G› | +`op8` | OperatorFunction‹G, H› | + +**Returns:** *Observable‹H›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**, **F**, **G**, **H**, **I**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›, `op6`: OperatorFunction‹E, F›, `op7`: OperatorFunction‹F, G›, `op8`: OperatorFunction‹G, H›, `op9`: OperatorFunction‹H, I›): *Observable‹I›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:86 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +▪ **F** + +▪ **G** + +▪ **H** + +▪ **I** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | +`op6` | OperatorFunction‹E, F› | +`op7` | OperatorFunction‹F, G› | +`op8` | OperatorFunction‹G, H› | +`op9` | OperatorFunction‹H, I› | + +**Returns:** *Observable‹I›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**, **F**, **G**, **H**, **I**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›, `op6`: OperatorFunction‹E, F›, `op7`: OperatorFunction‹F, G›, `op8`: OperatorFunction‹G, H›, `op9`: OperatorFunction‹H, I›, ...`operations`: OperatorFunction‹any, any›[]): *Observable‹__type›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:87 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +▪ **F** + +▪ **G** + +▪ **H** + +▪ **I** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | +`op6` | OperatorFunction‹E, F› | +`op7` | OperatorFunction‹F, G› | +`op8` | OperatorFunction‹G, H› | +`op9` | OperatorFunction‹H, I› | +`...operations` | OperatorFunction‹any, any›[] | + +**Returns:** *Observable‹__type›* + +___ + +### subscribe + +▸ **subscribe**(`observer?`: PartialObserver‹T›): *Subscription* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:47 + +**Parameters:** + +Name | Type | +------ | ------ | +`observer?` | PartialObserver‹T› | + +**Returns:** *Subscription* + +▸ **subscribe**(`next`: null | undefined, `error`: null | undefined, `complete`: function): *Subscription* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:49 + +**`deprecated`** Use an observer instead of a complete callback + +**Parameters:** + +▪ **next**: *null | undefined* + +▪ **error**: *null | undefined* + +▪ **complete**: *function* + +▸ (): *void* + +**Returns:** *Subscription* + +▸ **subscribe**(`next`: null | undefined, `error`: function, `complete?`: undefined | function): *Subscription* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:51 + +**`deprecated`** Use an observer instead of an error callback + +**Parameters:** + +▪ **next**: *null | undefined* + +▪ **error**: *function* + +▸ (`error`: any): *void* + +**Parameters:** + +Name | Type | +------ | ------ | +`error` | any | + +▪`Optional` **complete**: *undefined | function* + +**Returns:** *Subscription* + +▸ **subscribe**(`next`: function, `error`: null | undefined, `complete`: function): *Subscription* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:53 + +**`deprecated`** Use an observer instead of a complete callback + +**Parameters:** + +▪ **next**: *function* + +▸ (`value`: T): *void* + +**Parameters:** + +Name | Type | +------ | ------ | +`value` | T | + +▪ **error**: *null | undefined* + +▪ **complete**: *function* + +▸ (): *void* + +**Returns:** *Subscription* + +▸ **subscribe**(`next?`: undefined | function, `error?`: undefined | function, `complete?`: undefined | function): *Subscription* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:54 + +**Parameters:** + +Name | Type | +------ | ------ | +`next?` | undefined | function | +`error?` | undefined | function | +`complete?` | undefined | function | + +**Returns:** *Subscription* + +___ + +### toPromise + +▸ **toPromise**<**T**>(`this`: Observable‹T›): *Promise‹T›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:88 + +**Type parameters:** + +▪ **T** + +**Parameters:** + +Name | Type | +------ | ------ | +`this` | Observable‹T› | + +**Returns:** *Promise‹T›* + +▸ **toPromise**<**T**>(`this`: Observable‹T›, `PromiseCtor`: PromiseConstructor): *Promise‹T›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:89 + +**Type parameters:** + +▪ **T** + +**Parameters:** + +Name | Type | +------ | ------ | +`this` | Observable‹T› | +`PromiseCtor` | PromiseConstructor | + +**Returns:** *Promise‹T›* + +▸ **toPromise**<**T**>(`this`: Observable‹T›, `PromiseCtor`: PromiseConstructorLike): *Promise‹T›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:90 + +**Type parameters:** + +▪ **T** + +**Parameters:** + +Name | Type | +------ | ------ | +`this` | Observable‹T› | +`PromiseCtor` | PromiseConstructorLike | + +**Returns:** *Promise‹T›* diff --git a/docs/interfaces/ioperationobservable.md b/docs/interfaces/ioperationobservable.md new file mode 100644 index 00000000..782464f6 --- /dev/null +++ b/docs/interfaces/ioperationobservable.md @@ -0,0 +1,762 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IOperationObservable](ioperationobservable.md) + +# Interface: IOperationObservable <**T**> + +An operation is a stream of transaction updates + +## Type parameters + +▪ **T** + +## Hierarchy + +* Observable‹T› + + ↳ **IOperationObservable** + +## Implements + +* Subscribable‹T› + +## Index + +### Constructors + +* [constructor](ioperationobservable.md#constructor) + +### Properties + +* [_isScalar](ioperationobservable.md#_isscalar) +* [operator](ioperationobservable.md#operator) +* [send](ioperationobservable.md#send) +* [source](ioperationobservable.md#source) +* [create](ioperationobservable.md#static-create) +* [if](ioperationobservable.md#static-if) +* [throw](ioperationobservable.md#static-throw) + +### Methods + +* [_subscribe](ioperationobservable.md#_subscribe) +* [_trySubscribe](ioperationobservable.md#_trysubscribe) +* [forEach](ioperationobservable.md#foreach) +* [lift](ioperationobservable.md#lift) +* [pipe](ioperationobservable.md#pipe) +* [subscribe](ioperationobservable.md#subscribe) +* [toPromise](ioperationobservable.md#topromise) + +## Constructors + +### constructor + +\+ **new IOperationObservable**(`subscribe?`: undefined | function): *[IOperationObservable](ioperationobservable.md)* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:19 + +**`constructor`** + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`subscribe?` | undefined | function | the function that is called when the Observable is initially subscribed to. This function is given a Subscriber, to which new values can be `next`ed, or an `error` method can be called to raise an error, or `complete` can be called to notify of a successful completion. | + +**Returns:** *[IOperationObservable](ioperationobservable.md)* + +## Properties + +### _isScalar + +• **_isScalar**: *boolean* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:15 + +Internal implementation detail, do not use directly. + +___ + +### operator + +• **operator**: *Operator‹any, T›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:19 + +**`deprecated`** This is an internal implementation detail, do not use. + +___ + +### send + +• **send**: *function* + +*Defined in [operation.ts:36](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L36)* + +#### Type declaration: + +▸ (): *Promise‹[Web3Receipt](../globals.md#web3receipt)›* + +___ + +### source + +• **source**: *Observable‹any›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:17 + +**`deprecated`** This is an internal implementation detail, do not use. + +___ + +### `Static` create + +▪ **create**: *Function* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:38 + +Creates a new cold Observable by calling the Observable constructor + +**`static`** true + +**`owner`** Observable + +**`method`** create + +**`param`** the subscriber function to be passed to the Observable constructor + +**`returns`** a new cold observable + +**`nocollapse`** + +**`deprecated`** use new Observable() instead + +___ + +### `Static` if + +▪ **if**: *iif* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:71 + +**`nocollapse`** + +**`deprecated`** In favor of iif creation function: import { iif } from 'rxjs'; + +___ + +### `Static` throw + +▪ **throw**: *throwError* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:76 + +**`nocollapse`** + +**`deprecated`** In favor of throwError creation function: import { throwError } from 'rxjs'; + +## Methods + +### _subscribe + +▸ **_subscribe**(`subscriber`: Subscriber‹any›): *TeardownLogic* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:66 + +**`internal`** This is an internal implementation detail, do not use. + +**Parameters:** + +Name | Type | +------ | ------ | +`subscriber` | Subscriber‹any› | + +**Returns:** *TeardownLogic* + +___ + +### _trySubscribe + +▸ **_trySubscribe**(`sink`: Subscriber‹T›): *TeardownLogic* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:56 + +**`deprecated`** This is an internal implementation detail, do not use. + +**Parameters:** + +Name | Type | +------ | ------ | +`sink` | Subscriber‹T› | + +**Returns:** *TeardownLogic* + +___ + +### forEach + +▸ **forEach**(`next`: function, `promiseCtor?`: PromiseConstructorLike): *Promise‹void›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:64 + +**`method`** forEach + +**Parameters:** + +▪ **next**: *function* + +a handler for each value emitted by the observable + +▸ (`value`: T): *void* + +**Parameters:** + +Name | Type | +------ | ------ | +`value` | T | + +▪`Optional` **promiseCtor**: *PromiseConstructorLike* + +**Returns:** *Promise‹void›* + +a promise that either resolves on observable completion or + rejects with the handled error + +___ + +### lift + +▸ **lift**<**R**>(`operator`: Operator‹T, R›): *Observable‹R›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:46 + +Creates a new Observable, with this Observable as the source, and the passed +operator defined as the new observable's operator. + +**`method`** lift + +**Type parameters:** + +▪ **R** + +**Parameters:** + +Name | Type | Description | +------ | ------ | ------ | +`operator` | Operator‹T, R› | the operator defining the operation to take on the observable | + +**Returns:** *Observable‹R›* + +a new observable with the Operator applied + +___ + +### pipe + +▸ **pipe**(): *Observable‹T›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:77 + +**Returns:** *Observable‹T›* + +▸ **pipe**<**A**>(`op1`: OperatorFunction‹T, A›): *Observable‹A›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:78 + +**Type parameters:** + +▪ **A** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | + +**Returns:** *Observable‹A›* + +▸ **pipe**<**A**, **B**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›): *Observable‹B›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:79 + +**Type parameters:** + +▪ **A** + +▪ **B** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | + +**Returns:** *Observable‹B›* + +▸ **pipe**<**A**, **B**, **C**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›): *Observable‹C›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:80 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | + +**Returns:** *Observable‹C›* + +▸ **pipe**<**A**, **B**, **C**, **D**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›): *Observable‹D›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:81 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | + +**Returns:** *Observable‹D›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›): *Observable‹E›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:82 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | + +**Returns:** *Observable‹E›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**, **F**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›, `op6`: OperatorFunction‹E, F›): *Observable‹F›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:83 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +▪ **F** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | +`op6` | OperatorFunction‹E, F› | + +**Returns:** *Observable‹F›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**, **F**, **G**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›, `op6`: OperatorFunction‹E, F›, `op7`: OperatorFunction‹F, G›): *Observable‹G›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:84 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +▪ **F** + +▪ **G** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | +`op6` | OperatorFunction‹E, F› | +`op7` | OperatorFunction‹F, G› | + +**Returns:** *Observable‹G›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**, **F**, **G**, **H**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›, `op6`: OperatorFunction‹E, F›, `op7`: OperatorFunction‹F, G›, `op8`: OperatorFunction‹G, H›): *Observable‹H›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:85 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +▪ **F** + +▪ **G** + +▪ **H** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | +`op6` | OperatorFunction‹E, F› | +`op7` | OperatorFunction‹F, G› | +`op8` | OperatorFunction‹G, H› | + +**Returns:** *Observable‹H›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**, **F**, **G**, **H**, **I**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›, `op6`: OperatorFunction‹E, F›, `op7`: OperatorFunction‹F, G›, `op8`: OperatorFunction‹G, H›, `op9`: OperatorFunction‹H, I›): *Observable‹I›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:86 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +▪ **F** + +▪ **G** + +▪ **H** + +▪ **I** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | +`op6` | OperatorFunction‹E, F› | +`op7` | OperatorFunction‹F, G› | +`op8` | OperatorFunction‹G, H› | +`op9` | OperatorFunction‹H, I› | + +**Returns:** *Observable‹I›* + +▸ **pipe**<**A**, **B**, **C**, **D**, **E**, **F**, **G**, **H**, **I**>(`op1`: OperatorFunction‹T, A›, `op2`: OperatorFunction‹A, B›, `op3`: OperatorFunction‹B, C›, `op4`: OperatorFunction‹C, D›, `op5`: OperatorFunction‹D, E›, `op6`: OperatorFunction‹E, F›, `op7`: OperatorFunction‹F, G›, `op8`: OperatorFunction‹G, H›, `op9`: OperatorFunction‹H, I›, ...`operations`: OperatorFunction‹any, any›[]): *Observable‹__type›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:87 + +**Type parameters:** + +▪ **A** + +▪ **B** + +▪ **C** + +▪ **D** + +▪ **E** + +▪ **F** + +▪ **G** + +▪ **H** + +▪ **I** + +**Parameters:** + +Name | Type | +------ | ------ | +`op1` | OperatorFunction‹T, A› | +`op2` | OperatorFunction‹A, B› | +`op3` | OperatorFunction‹B, C› | +`op4` | OperatorFunction‹C, D› | +`op5` | OperatorFunction‹D, E› | +`op6` | OperatorFunction‹E, F› | +`op7` | OperatorFunction‹F, G› | +`op8` | OperatorFunction‹G, H› | +`op9` | OperatorFunction‹H, I› | +`...operations` | OperatorFunction‹any, any›[] | + +**Returns:** *Observable‹__type›* + +___ + +### subscribe + +▸ **subscribe**(`observer?`: PartialObserver‹T›): *Subscription* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:47 + +**Parameters:** + +Name | Type | +------ | ------ | +`observer?` | PartialObserver‹T› | + +**Returns:** *Subscription* + +▸ **subscribe**(`next`: null | undefined, `error`: null | undefined, `complete`: function): *Subscription* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:49 + +**`deprecated`** Use an observer instead of a complete callback + +**Parameters:** + +▪ **next**: *null | undefined* + +▪ **error**: *null | undefined* + +▪ **complete**: *function* + +▸ (): *void* + +**Returns:** *Subscription* + +▸ **subscribe**(`next`: null | undefined, `error`: function, `complete?`: undefined | function): *Subscription* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:51 + +**`deprecated`** Use an observer instead of an error callback + +**Parameters:** + +▪ **next**: *null | undefined* + +▪ **error**: *function* + +▸ (`error`: any): *void* + +**Parameters:** + +Name | Type | +------ | ------ | +`error` | any | + +▪`Optional` **complete**: *undefined | function* + +**Returns:** *Subscription* + +▸ **subscribe**(`next`: function, `error`: null | undefined, `complete`: function): *Subscription* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:53 + +**`deprecated`** Use an observer instead of a complete callback + +**Parameters:** + +▪ **next**: *function* + +▸ (`value`: T): *void* + +**Parameters:** + +Name | Type | +------ | ------ | +`value` | T | + +▪ **error**: *null | undefined* + +▪ **complete**: *function* + +▸ (): *void* + +**Returns:** *Subscription* + +▸ **subscribe**(`next?`: undefined | function, `error?`: undefined | function, `complete?`: undefined | function): *Subscription* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:54 + +**Parameters:** + +Name | Type | +------ | ------ | +`next?` | undefined | function | +`error?` | undefined | function | +`complete?` | undefined | function | + +**Returns:** *Subscription* + +___ + +### toPromise + +▸ **toPromise**<**T**>(`this`: Observable‹T›): *Promise‹T›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:88 + +**Type parameters:** + +▪ **T** + +**Parameters:** + +Name | Type | +------ | ------ | +`this` | Observable‹T› | + +**Returns:** *Promise‹T›* + +▸ **toPromise**<**T**>(`this`: Observable‹T›, `PromiseCtor`: PromiseConstructor): *Promise‹T›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:89 + +**Type parameters:** + +▪ **T** + +**Parameters:** + +Name | Type | +------ | ------ | +`this` | Observable‹T› | +`PromiseCtor` | PromiseConstructor | + +**Returns:** *Promise‹T›* + +▸ **toPromise**<**T**>(`this`: Observable‹T›, `PromiseCtor`: PromiseConstructorLike): *Promise‹T›* + +*Inherited from void* + +Defined in /media/data2/projects/daostack/client/node_modules/rxjs/internal/Observable.d.ts:90 + +**Type parameters:** + +▪ **T** + +**Parameters:** + +Name | Type | +------ | ------ | +`this` | Observable‹T› | +`PromiseCtor` | PromiseConstructorLike | + +**Returns:** *Promise‹T›* diff --git a/docs/interfaces/iproposalbasecreateoptions.md b/docs/interfaces/iproposalbasecreateoptions.md new file mode 100644 index 00000000..710d33dd --- /dev/null +++ b/docs/interfaces/iproposalbasecreateoptions.md @@ -0,0 +1,66 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IProposalBaseCreateOptions](iproposalbasecreateoptions.md) + +# Interface: IProposalBaseCreateOptions + +## Hierarchy + +* **IProposalBaseCreateOptions** + +## Index + +### Properties + +* [dao](iproposalbasecreateoptions.md#dao) +* [description](iproposalbasecreateoptions.md#optional-description) +* [descriptionHash](iproposalbasecreateoptions.md#optional-descriptionhash) +* [scheme](iproposalbasecreateoptions.md#scheme) +* [title](iproposalbasecreateoptions.md#optional-title) +* [url](iproposalbasecreateoptions.md#optional-url) + +## Properties + +### dao + +• **dao**: *[Address](../globals.md#address)* + +*Defined in [proposal.ts:832](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L832)* + +___ + +### `Optional` description + +• **description**? : *undefined | string* + +*Defined in [proposal.ts:833](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L833)* + +___ + +### `Optional` descriptionHash + +• **descriptionHash**? : *undefined | string* + +*Defined in [proposal.ts:834](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L834)* + +___ + +### scheme + +• **scheme**: *[Address](../globals.md#address)* + +*Defined in [proposal.ts:836](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L836)* + +___ + +### `Optional` title + +• **title**? : *undefined | string* + +*Defined in [proposal.ts:835](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L835)* + +___ + +### `Optional` url + +• **url**? : *undefined | string* + +*Defined in [proposal.ts:837](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L837)* diff --git a/docs/interfaces/iproposalcreateoptionscr.md b/docs/interfaces/iproposalcreateoptionscr.md new file mode 100644 index 00000000..76e89aea --- /dev/null +++ b/docs/interfaces/iproposalcreateoptionscr.md @@ -0,0 +1,84 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IProposalCreateOptionsCR](iproposalcreateoptionscr.md) + +# Interface: IProposalCreateOptionsCR + +## Hierarchy + +* **IProposalCreateOptionsCR** + +## Index + +### Properties + +* [beneficiary](iproposalcreateoptionscr.md#beneficiary) +* [ethReward](iproposalcreateoptionscr.md#optional-ethreward) +* [externalTokenAddress](iproposalcreateoptionscr.md#optional-externaltokenaddress) +* [externalTokenReward](iproposalcreateoptionscr.md#optional-externaltokenreward) +* [nativeTokenReward](iproposalcreateoptionscr.md#optional-nativetokenreward) +* [periodLength](iproposalcreateoptionscr.md#optional-periodlength) +* [periods](iproposalcreateoptionscr.md#optional-periods) +* [reputationReward](iproposalcreateoptionscr.md#optional-reputationreward) + +## Properties + +### beneficiary + +• **beneficiary**: *[Address](../globals.md#address)* + +*Defined in [schemes/contributionReward.ts:23](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L23)* + +___ + +### `Optional` ethReward + +• **ethReward**? : *[BN](../globals.md#const-bn)* + +*Defined in [schemes/contributionReward.ts:26](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L26)* + +___ + +### `Optional` externalTokenAddress + +• **externalTokenAddress**? : *[Address](../globals.md#address)* + +*Defined in [schemes/contributionReward.ts:28](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L28)* + +___ + +### `Optional` externalTokenReward + +• **externalTokenReward**? : *[BN](../globals.md#const-bn)* + +*Defined in [schemes/contributionReward.ts:27](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L27)* + +___ + +### `Optional` nativeTokenReward + +• **nativeTokenReward**? : *[BN](../globals.md#const-bn)* + +*Defined in [schemes/contributionReward.ts:24](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L24)* + +___ + +### `Optional` periodLength + +• **periodLength**? : *undefined | number* + +*Defined in [schemes/contributionReward.ts:29](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L29)* + +___ + +### `Optional` periods + +• **periods**? : *any* + +*Defined in [schemes/contributionReward.ts:30](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L30)* + +___ + +### `Optional` reputationReward + +• **reputationReward**? : *[BN](../globals.md#const-bn)* + +*Defined in [schemes/contributionReward.ts:25](https://github.com/daostack/client/blob/18967ff/src/schemes/contributionReward.ts#L25)* diff --git a/docs/interfaces/iproposalcreateoptionsgs.md b/docs/interfaces/iproposalcreateoptionsgs.md new file mode 100644 index 00000000..b5b51127 --- /dev/null +++ b/docs/interfaces/iproposalcreateoptionsgs.md @@ -0,0 +1,30 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IProposalCreateOptionsGS](iproposalcreateoptionsgs.md) + +# Interface: IProposalCreateOptionsGS + +## Hierarchy + +* **IProposalCreateOptionsGS** + +## Index + +### Properties + +* [callData](iproposalcreateoptionsgs.md#optional-calldata) +* [value](iproposalcreateoptionsgs.md#optional-value) + +## Properties + +### `Optional` callData + +• **callData**? : *undefined | string* + +*Defined in [schemes/genericScheme.ts:20](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L20)* + +___ + +### `Optional` value + +• **value**? : *undefined | number* + +*Defined in [schemes/genericScheme.ts:21](https://github.com/daostack/client/blob/18967ff/src/schemes/genericScheme.ts#L21)* diff --git a/docs/interfaces/iproposalcreateoptionssr.md b/docs/interfaces/iproposalcreateoptionssr.md new file mode 100644 index 00000000..e529e980 --- /dev/null +++ b/docs/interfaces/iproposalcreateoptionssr.md @@ -0,0 +1,39 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IProposalCreateOptionsSR](iproposalcreateoptionssr.md) + +# Interface: IProposalCreateOptionsSR + +## Hierarchy + +* **IProposalCreateOptionsSR** + +## Index + +### Properties + +* [parametersHash](iproposalcreateoptionssr.md#optional-parametershash) +* [permissions](iproposalcreateoptionssr.md#optional-permissions) +* [schemeToRegister](iproposalcreateoptionssr.md#optional-schemetoregister) + +## Properties + +### `Optional` parametersHash + +• **parametersHash**? : *undefined | string* + +*Defined in [schemes/schemeRegistrar.ts:17](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L17)* + +___ + +### `Optional` permissions + +• **permissions**? : *undefined | string* + +*Defined in [schemes/schemeRegistrar.ts:18](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L18)* + +___ + +### `Optional` schemeToRegister + +• **schemeToRegister**? : *[Address](../globals.md#address)* + +*Defined in [schemes/schemeRegistrar.ts:19](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L19)* diff --git a/docs/interfaces/iproposalqueryoptions.md b/docs/interfaces/iproposalqueryoptions.md new file mode 100644 index 00000000..ade0b158 --- /dev/null +++ b/docs/interfaces/iproposalqueryoptions.md @@ -0,0 +1,69 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IProposalQueryOptions](iproposalqueryoptions.md) + +# Interface: IProposalQueryOptions + +## Hierarchy + +* [ICommonQueryOptions](icommonqueryoptions.md) + + ↳ **IProposalQueryOptions** + +## Index + +### Properties + +* [first](iproposalqueryoptions.md#optional-first) +* [orderBy](iproposalqueryoptions.md#optional-orderby) +* [orderDirection](iproposalqueryoptions.md#optional-orderdirection) +* [skip](iproposalqueryoptions.md#optional-skip) +* [where](iproposalqueryoptions.md#optional-where) + +## Properties + +### `Optional` first + +• **first**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[first](icommonqueryoptions.md#optional-first)* + +*Defined in [types.ts:15](https://github.com/daostack/client/blob/18967ff/src/types.ts#L15)* + +___ + +### `Optional` orderBy + +• **orderBy**? : *undefined | string* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderBy](icommonqueryoptions.md#optional-orderby)* + +*Defined in [types.ts:16](https://github.com/daostack/client/blob/18967ff/src/types.ts#L16)* + +___ + +### `Optional` orderDirection + +• **orderDirection**? : *"asc" | "desc"* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderDirection](icommonqueryoptions.md#optional-orderdirection)* + +*Defined in [types.ts:17](https://github.com/daostack/client/blob/18967ff/src/types.ts#L17)* + +___ + +### `Optional` skip + +• **skip**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[skip](icommonqueryoptions.md#optional-skip)* + +*Defined in [types.ts:14](https://github.com/daostack/client/blob/18967ff/src/types.ts#L14)* + +___ + +### `Optional` where + +• **where**? : *undefined | object* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[where](icommonqueryoptions.md#optional-where)* + +*Defined in [proposal.ts:808](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L808)* diff --git a/docs/interfaces/iproposalstate.md b/docs/interfaces/iproposalstate.md new file mode 100644 index 00000000..aa5de2ed --- /dev/null +++ b/docs/interfaces/iproposalstate.md @@ -0,0 +1,382 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IProposalState](iproposalstate.md) + +# Interface: IProposalState + +## Hierarchy + +* [IProposalStaticState](iproposalstaticstate.md) + + ↳ **IProposalState** + +## Index + +### Properties + +* [accountsWithUnclaimedRewards](iproposalstate.md#accountswithunclaimedrewards) +* [boostedAt](iproposalstate.md#boostedat) +* [confidenceThreshold](iproposalstate.md#confidencethreshold) +* [contributionReward](iproposalstate.md#contributionreward) +* [createdAt](iproposalstate.md#createdat) +* [dao](iproposalstate.md#dao) +* [description](iproposalstate.md#optional-description) +* [descriptionHash](iproposalstate.md#optional-descriptionhash) +* [downStakeNeededToQueue](iproposalstate.md#downstakeneededtoqueue) +* [executedAt](iproposalstate.md#executedat) +* [executionState](iproposalstate.md#executionstate) +* [expiresInQueueAt](iproposalstate.md#expiresinqueueat) +* [genericScheme](iproposalstate.md#genericscheme) +* [genesisProtocolParams](iproposalstate.md#genesisprotocolparams) +* [id](iproposalstate.md#id) +* [organizationId](iproposalstate.md#organizationid) +* [paramsHash](iproposalstate.md#paramshash) +* [preBoostedAt](iproposalstate.md#preboostedat) +* [proposal](iproposalstate.md#proposal) +* [proposer](iproposalstate.md#proposer) +* [queue](iproposalstate.md#queue) +* [quietEndingPeriodBeganAt](iproposalstate.md#quietendingperiodbeganat) +* [resolvedAt](iproposalstate.md#resolvedat) +* [scheme](iproposalstate.md#scheme) +* [schemeRegistrar](iproposalstate.md#schemeregistrar) +* [stage](iproposalstate.md#stage) +* [stakesAgainst](iproposalstate.md#stakesagainst) +* [stakesFor](iproposalstate.md#stakesfor) +* [title](iproposalstate.md#optional-title) +* [totalRepWhenCreated](iproposalstate.md#totalrepwhencreated) +* [totalRepWhenExecuted](iproposalstate.md#totalrepwhenexecuted) +* [type](iproposalstate.md#type) +* [upstakeNeededToPreBoost](iproposalstate.md#upstakeneededtopreboost) +* [url](iproposalstate.md#optional-url) +* [voteOnBehalf](iproposalstate.md#voteonbehalf) +* [votesAgainst](iproposalstate.md#votesagainst) +* [votesCount](iproposalstate.md#votescount) +* [votesFor](iproposalstate.md#votesfor) +* [votingMachine](iproposalstate.md#votingmachine) +* [winningOutcome](iproposalstate.md#winningoutcome) + +## Properties + +### accountsWithUnclaimedRewards + +• **accountsWithUnclaimedRewards**: *[Address](../globals.md#address)[]* + +*Defined in [proposal.ts:67](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L67)* + +___ + +### boostedAt + +• **boostedAt**: *[Date](../globals.md#date)* + +*Defined in [proposal.ts:68](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L68)* + +___ + +### confidenceThreshold + +• **confidenceThreshold**: *number* + +*Defined in [proposal.ts:70](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L70)* + +___ + +### contributionReward + +• **contributionReward**: *[IContributionReward](icontributionreward.md) | null* + +*Defined in [proposal.ts:69](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L69)* + +___ + +### createdAt + +• **createdAt**: *[Date](../globals.md#date)* + +*Defined in [proposal.ts:71](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L71)* + +___ + +### dao + +• **dao**: *[DAO](../classes/dao.md)* + +*Inherited from [IProposalStaticState](iproposalstaticstate.md).[dao](iproposalstaticstate.md#dao)* + +*Defined in [proposal.ts:61](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L61)* + +___ + +### `Optional` description + +• **description**? : *undefined | string* + +*Defined in [proposal.ts:73](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L73)* + +___ + +### `Optional` descriptionHash + +• **descriptionHash**? : *undefined | string* + +*Defined in [proposal.ts:72](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L72)* + +___ + +### downStakeNeededToQueue + +• **downStakeNeededToQueue**: *any* + +*Defined in [proposal.ts:74](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L74)* + +___ + +### executedAt + +• **executedAt**: *[Date](../globals.md#date)* + +*Defined in [proposal.ts:75](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L75)* + +___ + +### executionState + +• **executionState**: *[IExecutionState](../enums/iexecutionstate.md)* + +*Defined in [proposal.ts:76](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L76)* + +___ + +### expiresInQueueAt + +• **expiresInQueueAt**: *[Date](../globals.md#date)* + +*Defined in [proposal.ts:77](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L77)* + +___ + +### genericScheme + +• **genericScheme**: *[IGenericScheme](igenericscheme.md) | null* + +*Defined in [proposal.ts:78](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L78)* + +___ + +### genesisProtocolParams + +• **genesisProtocolParams**: *[IGenesisProtocolParams](igenesisprotocolparams.md)* + +*Defined in [proposal.ts:79](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L79)* + +___ + +### id + +• **id**: *string* + +*Inherited from [IProposalStaticState](iproposalstaticstate.md).[id](iproposalstaticstate.md#id)* + +*Defined in [proposal.ts:60](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L60)* + +___ + +### organizationId + +• **organizationId**: *string* + +*Defined in [proposal.ts:80](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L80)* + +___ + +### paramsHash + +• **paramsHash**: *string* + +*Defined in [proposal.ts:81](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L81)* + +___ + +### preBoostedAt + +• **preBoostedAt**: *[Date](../globals.md#date)* + +*Defined in [proposal.ts:82](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L82)* + +___ + +### proposal + +• **proposal**: *[Proposal](../classes/proposal.md)* + +*Defined in [proposal.ts:83](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L83)* + +___ + +### proposer + +• **proposer**: *[Address](../globals.md#address)* + +*Defined in [proposal.ts:84](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L84)* + +___ + +### queue + +• **queue**: *[IQueueState](iqueuestate.md)* + +*Defined in [proposal.ts:85](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L85)* + +___ + +### quietEndingPeriodBeganAt + +• **quietEndingPeriodBeganAt**: *[Date](../globals.md#date)* + +*Defined in [proposal.ts:86](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L86)* + +___ + +### resolvedAt + +• **resolvedAt**: *[Date](../globals.md#date)* + +*Defined in [proposal.ts:88](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L88)* + +___ + +### scheme + +• **scheme**: *[ISchemeState](ischemestate.md)* + +*Inherited from [IProposalStaticState](iproposalstaticstate.md).[scheme](iproposalstaticstate.md#scheme)* + +*Defined in [proposal.ts:62](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L62)* + +___ + +### schemeRegistrar + +• **schemeRegistrar**: *[ISchemeRegistrar](ischemeregistrar.md) | null* + +*Defined in [proposal.ts:87](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L87)* + +___ + +### stage + +• **stage**: *[IProposalStage](../enums/iproposalstage.md)* + +*Defined in [proposal.ts:89](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L89)* + +___ + +### stakesAgainst + +• **stakesAgainst**: *any* + +*Defined in [proposal.ts:91](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L91)* + +___ + +### stakesFor + +• **stakesFor**: *any* + +*Defined in [proposal.ts:90](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L90)* + +___ + +### `Optional` title + +• **title**? : *undefined | string* + +*Defined in [proposal.ts:92](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L92)* + +___ + +### totalRepWhenCreated + +• **totalRepWhenCreated**: *any* + +*Defined in [proposal.ts:93](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L93)* + +___ + +### totalRepWhenExecuted + +• **totalRepWhenExecuted**: *any* + +*Defined in [proposal.ts:94](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L94)* + +___ + +### type + +• **type**: *[IProposalType](../globals.md#const-iproposaltype)* + +*Defined in [proposal.ts:95](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L95)* + +___ + +### upstakeNeededToPreBoost + +• **upstakeNeededToPreBoost**: *any* + +*Defined in [proposal.ts:96](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L96)* + +___ + +### `Optional` url + +• **url**? : *undefined | string* + +*Defined in [proposal.ts:97](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L97)* + +___ + +### voteOnBehalf + +• **voteOnBehalf**: *[Address](../globals.md#address)* + +*Defined in [proposal.ts:101](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L101)* + +___ + +### votesAgainst + +• **votesAgainst**: *any* + +*Defined in [proposal.ts:99](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L99)* + +___ + +### votesCount + +• **votesCount**: *number* + +*Defined in [proposal.ts:100](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L100)* + +___ + +### votesFor + +• **votesFor**: *any* + +*Defined in [proposal.ts:98](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L98)* + +___ + +### votingMachine + +• **votingMachine**: *[Address](../globals.md#address)* + +*Inherited from [IProposalStaticState](iproposalstaticstate.md).[votingMachine](iproposalstaticstate.md#votingmachine)* + +*Defined in [proposal.ts:63](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L63)* + +___ + +### winningOutcome + +• **winningOutcome**: *[IProposalOutcome](../enums/iproposaloutcome.md)* + +*Defined in [proposal.ts:102](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L102)* diff --git a/docs/interfaces/iproposalstaticstate.md b/docs/interfaces/iproposalstaticstate.md new file mode 100644 index 00000000..a64ab6a1 --- /dev/null +++ b/docs/interfaces/iproposalstaticstate.md @@ -0,0 +1,50 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IProposalStaticState](iproposalstaticstate.md) + +# Interface: IProposalStaticState + +## Hierarchy + +* **IProposalStaticState** + + ↳ [IProposalState](iproposalstate.md) + +## Index + +### Properties + +* [dao](iproposalstaticstate.md#dao) +* [id](iproposalstaticstate.md#id) +* [scheme](iproposalstaticstate.md#scheme) +* [votingMachine](iproposalstaticstate.md#votingmachine) + +## Properties + +### dao + +• **dao**: *[DAO](../classes/dao.md)* + +*Defined in [proposal.ts:61](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L61)* + +___ + +### id + +• **id**: *string* + +*Defined in [proposal.ts:60](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L60)* + +___ + +### scheme + +• **scheme**: *[ISchemeState](ischemestate.md)* + +*Defined in [proposal.ts:62](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L62)* + +___ + +### votingMachine + +• **votingMachine**: *[Address](../globals.md#address)* + +*Defined in [proposal.ts:63](https://github.com/daostack/client/blob/18967ff/src/proposal.ts#L63)* diff --git a/docs/interfaces/iqueuequeryoptions.md b/docs/interfaces/iqueuequeryoptions.md new file mode 100644 index 00000000..fa922d8b --- /dev/null +++ b/docs/interfaces/iqueuequeryoptions.md @@ -0,0 +1,69 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IQueueQueryOptions](iqueuequeryoptions.md) + +# Interface: IQueueQueryOptions + +## Hierarchy + +* [ICommonQueryOptions](icommonqueryoptions.md) + + ↳ **IQueueQueryOptions** + +## Index + +### Properties + +* [first](iqueuequeryoptions.md#optional-first) +* [orderBy](iqueuequeryoptions.md#optional-orderby) +* [orderDirection](iqueuequeryoptions.md#optional-orderdirection) +* [skip](iqueuequeryoptions.md#optional-skip) +* [where](iqueuequeryoptions.md#optional-where) + +## Properties + +### `Optional` first + +• **first**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[first](icommonqueryoptions.md#optional-first)* + +*Defined in [types.ts:15](https://github.com/daostack/client/blob/18967ff/src/types.ts#L15)* + +___ + +### `Optional` orderBy + +• **orderBy**? : *undefined | string* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderBy](icommonqueryoptions.md#optional-orderby)* + +*Defined in [types.ts:16](https://github.com/daostack/client/blob/18967ff/src/types.ts#L16)* + +___ + +### `Optional` orderDirection + +• **orderDirection**? : *"asc" | "desc"* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderDirection](icommonqueryoptions.md#optional-orderdirection)* + +*Defined in [types.ts:17](https://github.com/daostack/client/blob/18967ff/src/types.ts#L17)* + +___ + +### `Optional` skip + +• **skip**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[skip](icommonqueryoptions.md#optional-skip)* + +*Defined in [types.ts:14](https://github.com/daostack/client/blob/18967ff/src/types.ts#L14)* + +___ + +### `Optional` where + +• **where**? : *undefined | object* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[where](icommonqueryoptions.md#optional-where)* + +*Defined in [queue.ts:22](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L22)* diff --git a/docs/interfaces/iqueuestate.md b/docs/interfaces/iqueuestate.md new file mode 100644 index 00000000..eaef4d8b --- /dev/null +++ b/docs/interfaces/iqueuestate.md @@ -0,0 +1,74 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IQueueState](iqueuestate.md) + +# Interface: IQueueState + +## Hierarchy + +* [IQueueStaticState](iqueuestaticstate.md) + + ↳ **IQueueState** + +## Index + +### Properties + +* [dao](iqueuestate.md#dao) +* [id](iqueuestate.md#id) +* [name](iqueuestate.md#name) +* [scheme](iqueuestate.md#scheme) +* [threshold](iqueuestate.md#threshold) +* [votingMachine](iqueuestate.md#votingmachine) + +## Properties + +### dao + +• **dao**: *[DAO](../classes/dao.md)* + +*Inherited from [IQueueStaticState](iqueuestaticstate.md).[dao](iqueuestaticstate.md#dao)* + +*Defined in [queue.ts:10](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L10)* + +___ + +### id + +• **id**: *string* + +*Inherited from [IQueueStaticState](iqueuestaticstate.md).[id](iqueuestaticstate.md#id)* + +*Defined in [queue.ts:11](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L11)* + +___ + +### name + +• **name**: *string* + +*Inherited from [IQueueStaticState](iqueuestaticstate.md).[name](iqueuestaticstate.md#name)* + +*Defined in [queue.ts:12](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L12)* + +___ + +### scheme + +• **scheme**: *[ISchemeState](ischemestate.md)* + +*Defined in [queue.ts:16](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L16)* + +___ + +### threshold + +• **threshold**: *number* + +*Defined in [queue.ts:17](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L17)* + +___ + +### votingMachine + +• **votingMachine**: *[Address](../globals.md#address)* + +*Defined in [queue.ts:18](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L18)* diff --git a/docs/interfaces/iqueuestaticstate.md b/docs/interfaces/iqueuestaticstate.md new file mode 100644 index 00000000..38b4c642 --- /dev/null +++ b/docs/interfaces/iqueuestaticstate.md @@ -0,0 +1,41 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IQueueStaticState](iqueuestaticstate.md) + +# Interface: IQueueStaticState + +## Hierarchy + +* **IQueueStaticState** + + ↳ [IQueueState](iqueuestate.md) + +## Index + +### Properties + +* [dao](iqueuestaticstate.md#dao) +* [id](iqueuestaticstate.md#id) +* [name](iqueuestaticstate.md#name) + +## Properties + +### dao + +• **dao**: *[DAO](../classes/dao.md)* + +*Defined in [queue.ts:10](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L10)* + +___ + +### id + +• **id**: *string* + +*Defined in [queue.ts:11](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L11)* + +___ + +### name + +• **name**: *string* + +*Defined in [queue.ts:12](https://github.com/daostack/client/blob/18967ff/src/queue.ts#L12)* diff --git a/docs/interfaces/ireputationqueryoptions.md b/docs/interfaces/ireputationqueryoptions.md new file mode 100644 index 00000000..873151a2 --- /dev/null +++ b/docs/interfaces/ireputationqueryoptions.md @@ -0,0 +1,91 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IReputationQueryOptions](ireputationqueryoptions.md) + +# Interface: IReputationQueryOptions + +## Hierarchy + +* [ICommonQueryOptions](icommonqueryoptions.md) + + ↳ **IReputationQueryOptions** + +## Indexable + +* \[ **key**: *string*\]: any + +## Index + +### Properties + +* [dao](ireputationqueryoptions.md#optional-dao) +* [first](ireputationqueryoptions.md#optional-first) +* [id](ireputationqueryoptions.md#optional-id) +* [orderBy](ireputationqueryoptions.md#optional-orderby) +* [orderDirection](ireputationqueryoptions.md#optional-orderdirection) +* [skip](ireputationqueryoptions.md#optional-skip) +* [where](ireputationqueryoptions.md#optional-where) + +## Properties + +### `Optional` dao + +• **dao**? : *[Address](../globals.md#address)* + +*Defined in [reputation.ts:18](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L18)* + +___ + +### `Optional` first + +• **first**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[first](icommonqueryoptions.md#optional-first)* + +*Defined in [types.ts:15](https://github.com/daostack/client/blob/18967ff/src/types.ts#L15)* + +___ + +### `Optional` id + +• **id**? : *undefined | string* + +*Defined in [reputation.ts:17](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L17)* + +___ + +### `Optional` orderBy + +• **orderBy**? : *undefined | string* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderBy](icommonqueryoptions.md#optional-orderby)* + +*Defined in [types.ts:16](https://github.com/daostack/client/blob/18967ff/src/types.ts#L16)* + +___ + +### `Optional` orderDirection + +• **orderDirection**? : *"asc" | "desc"* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderDirection](icommonqueryoptions.md#optional-orderdirection)* + +*Defined in [types.ts:17](https://github.com/daostack/client/blob/18967ff/src/types.ts#L17)* + +___ + +### `Optional` skip + +• **skip**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[skip](icommonqueryoptions.md#optional-skip)* + +*Defined in [types.ts:14](https://github.com/daostack/client/blob/18967ff/src/types.ts#L14)* + +___ + +### `Optional` where + +• **where**? : *any* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[where](icommonqueryoptions.md#optional-where)* + +*Defined in [types.ts:18](https://github.com/daostack/client/blob/18967ff/src/types.ts#L18)* diff --git a/docs/interfaces/ireputationstate.md b/docs/interfaces/ireputationstate.md new file mode 100644 index 00000000..46abda03 --- /dev/null +++ b/docs/interfaces/ireputationstate.md @@ -0,0 +1,39 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IReputationState](ireputationstate.md) + +# Interface: IReputationState + +## Hierarchy + +* **IReputationState** + +## Index + +### Properties + +* [address](ireputationstate.md#address) +* [dao](ireputationstate.md#dao) +* [totalSupply](ireputationstate.md#totalsupply) + +## Properties + +### address + +• **address**: *[Address](../globals.md#address)* + +*Defined in [reputation.ts:11](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L11)* + +___ + +### dao + +• **dao**: *[Address](../globals.md#address)* + +*Defined in [reputation.ts:13](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L13)* + +___ + +### totalSupply + +• **totalSupply**: *number* + +*Defined in [reputation.ts:12](https://github.com/daostack/client/blob/18967ff/src/reputation.ts#L12)* diff --git a/docs/interfaces/irewardqueryoptions.md b/docs/interfaces/irewardqueryoptions.md new file mode 100644 index 00000000..2213e9f0 --- /dev/null +++ b/docs/interfaces/irewardqueryoptions.md @@ -0,0 +1,69 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IRewardQueryOptions](irewardqueryoptions.md) + +# Interface: IRewardQueryOptions + +## Hierarchy + +* [ICommonQueryOptions](icommonqueryoptions.md) + + ↳ **IRewardQueryOptions** + +## Index + +### Properties + +* [first](irewardqueryoptions.md#optional-first) +* [orderBy](irewardqueryoptions.md#optional-orderby) +* [orderDirection](irewardqueryoptions.md#optional-orderdirection) +* [skip](irewardqueryoptions.md#optional-skip) +* [where](irewardqueryoptions.md#optional-where) + +## Properties + +### `Optional` first + +• **first**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[first](icommonqueryoptions.md#optional-first)* + +*Defined in [types.ts:15](https://github.com/daostack/client/blob/18967ff/src/types.ts#L15)* + +___ + +### `Optional` orderBy + +• **orderBy**? : *undefined | string* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderBy](icommonqueryoptions.md#optional-orderby)* + +*Defined in [types.ts:16](https://github.com/daostack/client/blob/18967ff/src/types.ts#L16)* + +___ + +### `Optional` orderDirection + +• **orderDirection**? : *"asc" | "desc"* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderDirection](icommonqueryoptions.md#optional-orderdirection)* + +*Defined in [types.ts:17](https://github.com/daostack/client/blob/18967ff/src/types.ts#L17)* + +___ + +### `Optional` skip + +• **skip**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[skip](icommonqueryoptions.md#optional-skip)* + +*Defined in [types.ts:14](https://github.com/daostack/client/blob/18967ff/src/types.ts#L14)* + +___ + +### `Optional` where + +• **where**? : *undefined | object* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[where](icommonqueryoptions.md#optional-where)* + +*Defined in [reward.ts:25](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L25)* diff --git a/docs/interfaces/irewardstate.md b/docs/interfaces/irewardstate.md new file mode 100644 index 00000000..a9989684 --- /dev/null +++ b/docs/interfaces/irewardstate.md @@ -0,0 +1,129 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IRewardState](irewardstate.md) + +# Interface: IRewardState + +## Hierarchy + +* **IRewardState** + +## Index + +### Properties + +* [beneficiary](irewardstate.md#beneficiary) +* [createdAt](irewardstate.md#createdat) +* [daoBountyForStaker](irewardstate.md#daobountyforstaker) +* [daoBountyForStakerRedeemedAt](irewardstate.md#daobountyforstakerredeemedat) +* [id](irewardstate.md#id) +* [proposalId](irewardstate.md#proposalid) +* [reputationForProposer](irewardstate.md#reputationforproposer) +* [reputationForProposerRedeemedAt](irewardstate.md#reputationforproposerredeemedat) +* [reputationForVoter](irewardstate.md#reputationforvoter) +* [reputationForVoterRedeemedAt](irewardstate.md#reputationforvoterredeemedat) +* [tokenAddress](irewardstate.md#tokenaddress) +* [tokensForStaker](irewardstate.md#tokensforstaker) +* [tokensForStakerRedeemedAt](irewardstate.md#tokensforstakerredeemedat) + +## Properties + +### beneficiary + +• **beneficiary**: *[Address](../globals.md#address)* + +*Defined in [reward.ts:10](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L10)* + +___ + +### createdAt + +• **createdAt**: *Date* + +*Defined in [reward.ts:11](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L11)* + +___ + +### daoBountyForStaker + +• **daoBountyForStaker**: *any* + +*Defined in [reward.ts:15](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L15)* + +___ + +### daoBountyForStakerRedeemedAt + +• **daoBountyForStakerRedeemedAt**: *number* + +*Defined in [reward.ts:21](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L21)* + +___ + +### id + +• **id**: *string* + +*Defined in [reward.ts:9](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L9)* + +___ + +### proposalId + +• **proposalId**: *string* + +*Defined in [reward.ts:12](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L12)* + +___ + +### reputationForProposer + +• **reputationForProposer**: *any* + +*Defined in [reward.ts:16](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L16)* + +___ + +### reputationForProposerRedeemedAt + +• **reputationForProposerRedeemedAt**: *number* + +*Defined in [reward.ts:20](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L20)* + +___ + +### reputationForVoter + +• **reputationForVoter**: *any* + +*Defined in [reward.ts:13](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L13)* + +___ + +### reputationForVoterRedeemedAt + +• **reputationForVoterRedeemedAt**: *number* + +*Defined in [reward.ts:18](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L18)* + +___ + +### tokenAddress + +• **tokenAddress**: *[Address](../globals.md#address)* + +*Defined in [reward.ts:17](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L17)* + +___ + +### tokensForStaker + +• **tokensForStaker**: *any* + +*Defined in [reward.ts:14](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L14)* + +___ + +### tokensForStakerRedeemedAt + +• **tokensForStakerRedeemedAt**: *number* + +*Defined in [reward.ts:19](https://github.com/daostack/client/blob/18967ff/src/reward.ts#L19)* diff --git a/docs/interfaces/ischemequeryoptions.md b/docs/interfaces/ischemequeryoptions.md new file mode 100644 index 00000000..73585a5f --- /dev/null +++ b/docs/interfaces/ischemequeryoptions.md @@ -0,0 +1,81 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [ISchemeQueryOptions](ischemequeryoptions.md) + +# Interface: ISchemeQueryOptions + +## Hierarchy + +* [ICommonQueryOptions](icommonqueryoptions.md) + +* [ICommonQueryOptions](icommonqueryoptions.md) + + ↳ **ISchemeQueryOptions** + +## Index + +### Properties + +* [first](ischemequeryoptions.md#optional-first) +* [orderBy](ischemequeryoptions.md#optional-orderby) +* [orderDirection](ischemequeryoptions.md#optional-orderdirection) +* [skip](ischemequeryoptions.md#optional-skip) +* [where](ischemequeryoptions.md#optional-where) + +## Properties + +### `Optional` first + +• **first**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[first](icommonqueryoptions.md#optional-first)* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[first](icommonqueryoptions.md#optional-first)* + +*Defined in [types.ts:15](https://github.com/daostack/client/blob/18967ff/src/types.ts#L15)* + +___ + +### `Optional` orderBy + +• **orderBy**? : *undefined | string* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderBy](icommonqueryoptions.md#optional-orderby)* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[orderBy](icommonqueryoptions.md#optional-orderby)* + +*Defined in [types.ts:16](https://github.com/daostack/client/blob/18967ff/src/types.ts#L16)* + +___ + +### `Optional` orderDirection + +• **orderDirection**? : *"asc" | "desc"* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderDirection](icommonqueryoptions.md#optional-orderdirection)* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[orderDirection](icommonqueryoptions.md#optional-orderdirection)* + +*Defined in [types.ts:17](https://github.com/daostack/client/blob/18967ff/src/types.ts#L17)* + +___ + +### `Optional` skip + +• **skip**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[skip](icommonqueryoptions.md#optional-skip)* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[skip](icommonqueryoptions.md#optional-skip)* + +*Defined in [types.ts:14](https://github.com/daostack/client/blob/18967ff/src/types.ts#L14)* + +___ + +### `Optional` where + +• **where**? : *undefined | object* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[where](icommonqueryoptions.md#optional-where)* + +*Defined in [scheme.ts:47](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L47)* + +*Defined in [scheme.ts:62](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L62)* diff --git a/docs/interfaces/ischemeregistrar.md b/docs/interfaces/ischemeregistrar.md new file mode 100644 index 00000000..bd918c93 --- /dev/null +++ b/docs/interfaces/ischemeregistrar.md @@ -0,0 +1,84 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [ISchemeRegistrar](ischemeregistrar.md) + +# Interface: ISchemeRegistrar + +## Hierarchy + +* **ISchemeRegistrar** + +## Index + +### Properties + +* [decision](ischemeregistrar.md#decision) +* [id](ischemeregistrar.md#id) +* [schemeRegistered](ischemeregistrar.md#schemeregistered) +* [schemeRemoved](ischemeregistrar.md#schemeremoved) +* [schemeToRegister](ischemeregistrar.md#schemetoregister) +* [schemeToRegisterParamsHash](ischemeregistrar.md#schemetoregisterparamshash) +* [schemeToRegisterPermission](ischemeregistrar.md#schemetoregisterpermission) +* [schemeToRemove](ischemeregistrar.md#schemetoremove) + +## Properties + +### decision + +• **decision**: *number* + +*Defined in [schemes/schemeRegistrar.ts:11](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L11)* + +___ + +### id + +• **id**: *string* + +*Defined in [schemes/schemeRegistrar.ts:6](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L6)* + +___ + +### schemeRegistered + +• **schemeRegistered**: *boolean* + +*Defined in [schemes/schemeRegistrar.ts:12](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L12)* + +___ + +### schemeRemoved + +• **schemeRemoved**: *boolean* + +*Defined in [schemes/schemeRegistrar.ts:13](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L13)* + +___ + +### schemeToRegister + +• **schemeToRegister**: *[Address](../globals.md#address)* + +*Defined in [schemes/schemeRegistrar.ts:7](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L7)* + +___ + +### schemeToRegisterParamsHash + +• **schemeToRegisterParamsHash**: *string* + +*Defined in [schemes/schemeRegistrar.ts:8](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L8)* + +___ + +### schemeToRegisterPermission + +• **schemeToRegisterPermission**: *string* + +*Defined in [schemes/schemeRegistrar.ts:9](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L9)* + +___ + +### schemeToRemove + +• **schemeToRemove**: *string* + +*Defined in [schemes/schemeRegistrar.ts:10](https://github.com/daostack/client/blob/18967ff/src/schemes/schemeRegistrar.ts#L10)* diff --git a/docs/interfaces/ischemestate.md b/docs/interfaces/ischemestate.md new file mode 100644 index 00000000..df799918 --- /dev/null +++ b/docs/interfaces/ischemestate.md @@ -0,0 +1,132 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [ISchemeState](ischemestate.md) + +# Interface: ISchemeState + +## Hierarchy + +* [ISchemeStaticState](ischemestaticstate.md) + + ↳ **ISchemeState** + +## Index + +### Properties + +* [address](ischemestate.md#address) +* [canDelegateCall](ischemestate.md#candelegatecall) +* [canManageGlobalConstraints](ischemestate.md#canmanageglobalconstraints) +* [canRegisterSchemes](ischemestate.md#canregisterschemes) +* [canUpgradeController](ischemestate.md#canupgradecontroller) +* [contributionRewardParams](ischemestate.md#optional-contributionrewardparams) +* [dao](ischemestate.md#dao) +* [genericSchemeParams](ischemestate.md#optional-genericschemeparams) +* [id](ischemestate.md#id) +* [name](ischemestate.md#name) +* [paramsHash](ischemestate.md#paramshash) +* [schemeRegistrarParams](ischemestate.md#optional-schemeregistrarparams) + +## Properties + +### address + +• **address**: *[Address](../globals.md#address)* + +*Inherited from [ISchemeStaticState](ischemestaticstate.md).[address](ischemestaticstate.md#address)* + +*Defined in [scheme.ts:17](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L17)* + +___ + +### canDelegateCall + +• **canDelegateCall**: *boolean* + +*Defined in [scheme.ts:24](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L24)* + +___ + +### canManageGlobalConstraints + +• **canManageGlobalConstraints**: *boolean* + +*Defined in [scheme.ts:27](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L27)* + +___ + +### canRegisterSchemes + +• **canRegisterSchemes**: *boolean* + +*Defined in [scheme.ts:25](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L25)* + +___ + +### canUpgradeController + +• **canUpgradeController**: *boolean* + +*Defined in [scheme.ts:26](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L26)* + +___ + +### `Optional` contributionRewardParams + +• **contributionRewardParams**? : *object | null* + +*Defined in [scheme.ts:30](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L30)* + +___ + +### dao + +• **dao**: *[Address](../globals.md#address)* + +*Overrides [ISchemeStaticState](ischemestaticstate.md).[dao](ischemestaticstate.md#dao)* + +*Defined in [scheme.ts:28](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L28)* + +___ + +### `Optional` genericSchemeParams + +• **genericSchemeParams**? : *object | null* + +*Defined in [scheme.ts:34](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L34)* + +___ + +### id + +• **id**: *string* + +*Inherited from [ISchemeStaticState](ischemestaticstate.md).[id](ischemestaticstate.md#id)* + +*Defined in [scheme.ts:16](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L16)* + +___ + +### name + +• **name**: *string* + +*Inherited from [ISchemeStaticState](ischemestaticstate.md).[name](ischemestaticstate.md#name)* + +*Defined in [scheme.ts:19](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L19)* + +___ + +### paramsHash + +• **paramsHash**: *string* + +*Overrides [ISchemeStaticState](ischemestaticstate.md).[paramsHash](ischemestaticstate.md#paramshash)* + +*Defined in [scheme.ts:29](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L29)* + +___ + +### `Optional` schemeRegistrarParams + +• **schemeRegistrarParams**? : *object | null* + +*Defined in [scheme.ts:39](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L39)* diff --git a/docs/interfaces/ischemestaticstate.md b/docs/interfaces/ischemestaticstate.md new file mode 100644 index 00000000..c5fa82cc --- /dev/null +++ b/docs/interfaces/ischemestaticstate.md @@ -0,0 +1,59 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [ISchemeStaticState](ischemestaticstate.md) + +# Interface: ISchemeStaticState + +## Hierarchy + +* **ISchemeStaticState** + + ↳ [ISchemeState](ischemestate.md) + +## Index + +### Properties + +* [address](ischemestaticstate.md#address) +* [dao](ischemestaticstate.md#dao) +* [id](ischemestaticstate.md#id) +* [name](ischemestaticstate.md#name) +* [paramsHash](ischemestaticstate.md#paramshash) + +## Properties + +### address + +• **address**: *[Address](../globals.md#address)* + +*Defined in [scheme.ts:17](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L17)* + +___ + +### dao + +• **dao**: *[Address](../globals.md#address)* + +*Defined in [scheme.ts:18](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L18)* + +___ + +### id + +• **id**: *string* + +*Defined in [scheme.ts:16](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L16)* + +___ + +### name + +• **name**: *string* + +*Defined in [scheme.ts:19](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L19)* + +___ + +### paramsHash + +• **paramsHash**: *string* + +*Defined in [scheme.ts:20](https://github.com/daostack/client/blob/18967ff/src/scheme.ts#L20)* diff --git a/docs/interfaces/istakequeryoptions.md b/docs/interfaces/istakequeryoptions.md new file mode 100644 index 00000000..3aca5dc5 --- /dev/null +++ b/docs/interfaces/istakequeryoptions.md @@ -0,0 +1,69 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IStakeQueryOptions](istakequeryoptions.md) + +# Interface: IStakeQueryOptions + +## Hierarchy + +* [ICommonQueryOptions](icommonqueryoptions.md) + + ↳ **IStakeQueryOptions** + +## Index + +### Properties + +* [first](istakequeryoptions.md#optional-first) +* [orderBy](istakequeryoptions.md#optional-orderby) +* [orderDirection](istakequeryoptions.md#optional-orderdirection) +* [skip](istakequeryoptions.md#optional-skip) +* [where](istakequeryoptions.md#optional-where) + +## Properties + +### `Optional` first + +• **first**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[first](icommonqueryoptions.md#optional-first)* + +*Defined in [types.ts:15](https://github.com/daostack/client/blob/18967ff/src/types.ts#L15)* + +___ + +### `Optional` orderBy + +• **orderBy**? : *undefined | string* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderBy](icommonqueryoptions.md#optional-orderby)* + +*Defined in [types.ts:16](https://github.com/daostack/client/blob/18967ff/src/types.ts#L16)* + +___ + +### `Optional` orderDirection + +• **orderDirection**? : *"asc" | "desc"* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderDirection](icommonqueryoptions.md#optional-orderdirection)* + +*Defined in [types.ts:17](https://github.com/daostack/client/blob/18967ff/src/types.ts#L17)* + +___ + +### `Optional` skip + +• **skip**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[skip](icommonqueryoptions.md#optional-skip)* + +*Defined in [types.ts:14](https://github.com/daostack/client/blob/18967ff/src/types.ts#L14)* + +___ + +### `Optional` where + +• **where**? : *undefined | object* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[where](icommonqueryoptions.md#optional-where)* + +*Defined in [stake.ts:23](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L23)* diff --git a/docs/interfaces/istakestate.md b/docs/interfaces/istakestate.md new file mode 100644 index 00000000..e93d775f --- /dev/null +++ b/docs/interfaces/istakestate.md @@ -0,0 +1,80 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IStakeState](istakestate.md) + +# Interface: IStakeState + +## Hierarchy + +* [IStakeStaticState](istakestaticstate.md) + + ↳ **IStakeState** + +## Index + +### Properties + +* [amount](istakestate.md#amount) +* [createdAt](istakestate.md#createdat) +* [id](istakestate.md#id) +* [outcome](istakestate.md#outcome) +* [proposal](istakestate.md#proposal) +* [staker](istakestate.md#staker) + +## Properties + +### amount + +• **amount**: *any* + +*Inherited from [IStakeStaticState](istakestaticstate.md).[amount](istakestaticstate.md#amount)* + +*Defined in [stake.ts:14](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L14)* + +___ + +### createdAt + +• **createdAt**: *Date | undefined* + +*Inherited from [IStakeStaticState](istakestaticstate.md).[createdAt](istakestaticstate.md#createdat)* + +*Defined in [stake.ts:12](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L12)* + +___ + +### id + +• **id**: *string* + +*Overrides [IStakeStaticState](istakestaticstate.md).[id](istakestaticstate.md#optional-id)* + +*Defined in [stake.ts:19](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L19)* + +___ + +### outcome + +• **outcome**: *[IProposalOutcome](../enums/iproposaloutcome.md)* + +*Inherited from [IStakeStaticState](istakestaticstate.md).[outcome](istakestaticstate.md#outcome)* + +*Defined in [stake.ts:13](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L13)* + +___ + +### proposal + +• **proposal**: *string* + +*Inherited from [IStakeStaticState](istakestaticstate.md).[proposal](istakestaticstate.md#proposal)* + +*Defined in [stake.ts:15](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L15)* + +___ + +### staker + +• **staker**: *[Address](../globals.md#address)* + +*Inherited from [IStakeStaticState](istakestaticstate.md).[staker](istakestaticstate.md#staker)* + +*Defined in [stake.ts:11](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L11)* diff --git a/docs/interfaces/istakestaticstate.md b/docs/interfaces/istakestaticstate.md new file mode 100644 index 00000000..0e090d0a --- /dev/null +++ b/docs/interfaces/istakestaticstate.md @@ -0,0 +1,68 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IStakeStaticState](istakestaticstate.md) + +# Interface: IStakeStaticState + +## Hierarchy + +* **IStakeStaticState** + + ↳ [IStakeState](istakestate.md) + +## Index + +### Properties + +* [amount](istakestaticstate.md#amount) +* [createdAt](istakestaticstate.md#createdat) +* [id](istakestaticstate.md#optional-id) +* [outcome](istakestaticstate.md#outcome) +* [proposal](istakestaticstate.md#proposal) +* [staker](istakestaticstate.md#staker) + +## Properties + +### amount + +• **amount**: *any* + +*Defined in [stake.ts:14](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L14)* + +___ + +### createdAt + +• **createdAt**: *Date | undefined* + +*Defined in [stake.ts:12](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L12)* + +___ + +### `Optional` id + +• **id**? : *undefined | string* + +*Defined in [stake.ts:10](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L10)* + +___ + +### outcome + +• **outcome**: *[IProposalOutcome](../enums/iproposaloutcome.md)* + +*Defined in [stake.ts:13](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L13)* + +___ + +### proposal + +• **proposal**: *string* + +*Defined in [stake.ts:15](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L15)* + +___ + +### staker + +• **staker**: *[Address](../globals.md#address)* + +*Defined in [stake.ts:11](https://github.com/daostack/client/blob/18967ff/src/stake.ts#L11)* diff --git a/docs/interfaces/istateful.md b/docs/interfaces/istateful.md new file mode 100644 index 00000000..1f494ccb --- /dev/null +++ b/docs/interfaces/istateful.md @@ -0,0 +1,42 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IStateful](istateful.md) + +# Interface: IStateful <**T**> + +## Type parameters + +▪ **T** + +## Hierarchy + +* **IStateful** + +## Implemented by + +* [DAO](../classes/dao.md) +* [Member](../classes/member.md) +* [Proposal](../classes/proposal.md) +* [Queue](../classes/queue.md) +* [Reputation](../classes/reputation.md) +* [Reward](../classes/reward.md) +* [Scheme](../classes/scheme.md) +* [Stake](../classes/stake.md) +* [Token](../classes/token.md) +* [Vote](../classes/vote.md) + +## Index + +### Properties + +* [state](istateful.md#state) + +## Properties + +### state + +• **state**: *function* + +*Defined in [types.ts:10](https://github.com/daostack/client/blob/18967ff/src/types.ts#L10)* + +#### Type declaration: + +▸ (): *Observable‹T›* diff --git a/docs/interfaces/itokenqueryoptions.md b/docs/interfaces/itokenqueryoptions.md new file mode 100644 index 00000000..5a1aa4d3 --- /dev/null +++ b/docs/interfaces/itokenqueryoptions.md @@ -0,0 +1,69 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [ITokenQueryOptions](itokenqueryoptions.md) + +# Interface: ITokenQueryOptions + +## Hierarchy + +* [ICommonQueryOptions](icommonqueryoptions.md) + + ↳ **ITokenQueryOptions** + +## Index + +### Properties + +* [first](itokenqueryoptions.md#optional-first) +* [orderBy](itokenqueryoptions.md#optional-orderby) +* [orderDirection](itokenqueryoptions.md#optional-orderdirection) +* [skip](itokenqueryoptions.md#optional-skip) +* [where](itokenqueryoptions.md#optional-where) + +## Properties + +### `Optional` first + +• **first**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[first](icommonqueryoptions.md#optional-first)* + +*Defined in [types.ts:15](https://github.com/daostack/client/blob/18967ff/src/types.ts#L15)* + +___ + +### `Optional` orderBy + +• **orderBy**? : *undefined | string* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderBy](icommonqueryoptions.md#optional-orderby)* + +*Defined in [types.ts:16](https://github.com/daostack/client/blob/18967ff/src/types.ts#L16)* + +___ + +### `Optional` orderDirection + +• **orderDirection**? : *"asc" | "desc"* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderDirection](icommonqueryoptions.md#optional-orderdirection)* + +*Defined in [types.ts:17](https://github.com/daostack/client/blob/18967ff/src/types.ts#L17)* + +___ + +### `Optional` skip + +• **skip**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[skip](icommonqueryoptions.md#optional-skip)* + +*Defined in [types.ts:14](https://github.com/daostack/client/blob/18967ff/src/types.ts#L14)* + +___ + +### `Optional` where + +• **where**? : *undefined | object* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[where](icommonqueryoptions.md#optional-where)* + +*Defined in [token.ts:19](https://github.com/daostack/client/blob/18967ff/src/token.ts#L19)* diff --git a/docs/interfaces/itokenstate.md b/docs/interfaces/itokenstate.md new file mode 100644 index 00000000..a5ef411e --- /dev/null +++ b/docs/interfaces/itokenstate.md @@ -0,0 +1,57 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [ITokenState](itokenstate.md) + +# Interface: ITokenState + +## Hierarchy + +* **ITokenState** + +## Index + +### Properties + +* [address](itokenstate.md#address) +* [name](itokenstate.md#name) +* [owner](itokenstate.md#owner) +* [symbol](itokenstate.md#symbol) +* [totalSupply](itokenstate.md#totalsupply) + +## Properties + +### address + +• **address**: *[Address](../globals.md#address)* + +*Defined in [token.ts:11](https://github.com/daostack/client/blob/18967ff/src/token.ts#L11)* + +___ + +### name + +• **name**: *string* + +*Defined in [token.ts:12](https://github.com/daostack/client/blob/18967ff/src/token.ts#L12)* + +___ + +### owner + +• **owner**: *[Address](../globals.md#address)* + +*Defined in [token.ts:13](https://github.com/daostack/client/blob/18967ff/src/token.ts#L13)* + +___ + +### symbol + +• **symbol**: *string* + +*Defined in [token.ts:14](https://github.com/daostack/client/blob/18967ff/src/token.ts#L14)* + +___ + +### totalSupply + +• **totalSupply**: *any* + +*Defined in [token.ts:15](https://github.com/daostack/client/blob/18967ff/src/token.ts#L15)* diff --git a/docs/interfaces/itransactionupdate.md b/docs/interfaces/itransactionupdate.md new file mode 100644 index 00000000..3d532e67 --- /dev/null +++ b/docs/interfaces/itransactionupdate.md @@ -0,0 +1,68 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [ITransactionUpdate](itransactionupdate.md) + +# Interface: ITransactionUpdate <**T**> + +A transaction update is a snapshot of the state of a transaction at a particular time. + +## Type parameters + +▪ **T** + +## Hierarchy + +* **ITransactionUpdate** + +## Index + +### Properties + +* [confirmations](itransactionupdate.md#optional-confirmations) +* [receipt](itransactionupdate.md#optional-receipt) +* [result](itransactionupdate.md#optional-result) +* [state](itransactionupdate.md#state) +* [transactionHash](itransactionupdate.md#optional-transactionhash) + +## Properties + +### `Optional` confirmations + +• **confirmations**? : *undefined | number* + +*Defined in [operation.ts:24](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L24)* + + number of confirmations + +___ + +### `Optional` receipt + +• **receipt**? : *undefined | object* + +*Defined in [operation.ts:20](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L20)* + +___ + +### `Optional` result + +• **result**? : *[T](undefined)* + +*Defined in [operation.ts:29](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L29)* + +Parsed return value from the method call +or contract address in the case of contract creation tx. + +___ + +### state + +• **state**: *[ITransactionState](../enums/itransactionstate.md)* + +*Defined in [operation.ts:18](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L18)* + +___ + +### `Optional` transactionHash + +• **transactionHash**? : *undefined | string* + +*Defined in [operation.ts:19](https://github.com/daostack/client/blob/18967ff/src/operation.ts#L19)* diff --git a/docs/interfaces/ivotequeryoptions.md b/docs/interfaces/ivotequeryoptions.md new file mode 100644 index 00000000..dbd02050 --- /dev/null +++ b/docs/interfaces/ivotequeryoptions.md @@ -0,0 +1,69 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IVoteQueryOptions](ivotequeryoptions.md) + +# Interface: IVoteQueryOptions + +## Hierarchy + +* [ICommonQueryOptions](icommonqueryoptions.md) + + ↳ **IVoteQueryOptions** + +## Index + +### Properties + +* [first](ivotequeryoptions.md#optional-first) +* [orderBy](ivotequeryoptions.md#optional-orderby) +* [orderDirection](ivotequeryoptions.md#optional-orderdirection) +* [skip](ivotequeryoptions.md#optional-skip) +* [where](ivotequeryoptions.md#optional-where) + +## Properties + +### `Optional` first + +• **first**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[first](icommonqueryoptions.md#optional-first)* + +*Defined in [types.ts:15](https://github.com/daostack/client/blob/18967ff/src/types.ts#L15)* + +___ + +### `Optional` orderBy + +• **orderBy**? : *undefined | string* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderBy](icommonqueryoptions.md#optional-orderby)* + +*Defined in [types.ts:16](https://github.com/daostack/client/blob/18967ff/src/types.ts#L16)* + +___ + +### `Optional` orderDirection + +• **orderDirection**? : *"asc" | "desc"* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[orderDirection](icommonqueryoptions.md#optional-orderdirection)* + +*Defined in [types.ts:17](https://github.com/daostack/client/blob/18967ff/src/types.ts#L17)* + +___ + +### `Optional` skip + +• **skip**? : *undefined | number* + +*Inherited from [ICommonQueryOptions](icommonqueryoptions.md).[skip](icommonqueryoptions.md#optional-skip)* + +*Defined in [types.ts:14](https://github.com/daostack/client/blob/18967ff/src/types.ts#L14)* + +___ + +### `Optional` where + +• **where**? : *undefined | object* + +*Overrides [ICommonQueryOptions](icommonqueryoptions.md).[where](icommonqueryoptions.md#optional-where)* + +*Defined in [vote.ts:24](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L24)* diff --git a/docs/interfaces/ivotestate.md b/docs/interfaces/ivotestate.md new file mode 100644 index 00000000..c6636cf8 --- /dev/null +++ b/docs/interfaces/ivotestate.md @@ -0,0 +1,91 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IVoteState](ivotestate.md) + +# Interface: IVoteState + +## Hierarchy + +* [IVoteStaticState](ivotestaticstate.md) + + ↳ **IVoteState** + +## Index + +### Properties + +* [amount](ivotestate.md#amount) +* [createdAt](ivotestate.md#createdat) +* [dao](ivotestate.md#optional-dao) +* [id](ivotestate.md#id) +* [outcome](ivotestate.md#outcome) +* [proposal](ivotestate.md#proposal) +* [voter](ivotestate.md#voter) + +## Properties + +### amount + +• **amount**: *any* + +*Inherited from [IVoteStaticState](ivotestaticstate.md).[amount](ivotestaticstate.md#amount)* + +*Defined in [vote.ts:14](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L14)* + +___ + +### createdAt + +• **createdAt**: *[Date](../globals.md#date) | undefined* + +*Inherited from [IVoteStaticState](ivotestaticstate.md).[createdAt](ivotestaticstate.md#createdat)* + +*Defined in [vote.ts:12](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L12)* + +___ + +### `Optional` dao + +• **dao**? : *[Address](../globals.md#address)* + +*Inherited from [IVoteStaticState](ivotestaticstate.md).[dao](ivotestaticstate.md#optional-dao)* + +*Defined in [vote.ts:16](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L16)* + +___ + +### id + +• **id**: *string* + +*Overrides [IVoteStaticState](ivotestaticstate.md).[id](ivotestaticstate.md#optional-id)* + +*Defined in [vote.ts:20](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L20)* + +___ + +### outcome + +• **outcome**: *[IProposalOutcome](../enums/iproposaloutcome.md)* + +*Inherited from [IVoteStaticState](ivotestaticstate.md).[outcome](ivotestaticstate.md#outcome)* + +*Defined in [vote.ts:13](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L13)* + +___ + +### proposal + +• **proposal**: *string* + +*Inherited from [IVoteStaticState](ivotestaticstate.md).[proposal](ivotestaticstate.md#proposal)* + +*Defined in [vote.ts:15](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L15)* + +___ + +### voter + +• **voter**: *[Address](../globals.md#address)* + +*Inherited from [IVoteStaticState](ivotestaticstate.md).[voter](ivotestaticstate.md#voter)* + +*Defined in [vote.ts:11](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L11)* diff --git a/docs/interfaces/ivotestaticstate.md b/docs/interfaces/ivotestaticstate.md new file mode 100644 index 00000000..a292c1d1 --- /dev/null +++ b/docs/interfaces/ivotestaticstate.md @@ -0,0 +1,77 @@ +[@daostack/client](../README.md) › [Globals](../globals.md) › [IVoteStaticState](ivotestaticstate.md) + +# Interface: IVoteStaticState + +## Hierarchy + +* **IVoteStaticState** + + ↳ [IVoteState](ivotestate.md) + +## Index + +### Properties + +* [amount](ivotestaticstate.md#amount) +* [createdAt](ivotestaticstate.md#createdat) +* [dao](ivotestaticstate.md#optional-dao) +* [id](ivotestaticstate.md#optional-id) +* [outcome](ivotestaticstate.md#outcome) +* [proposal](ivotestaticstate.md#proposal) +* [voter](ivotestaticstate.md#voter) + +## Properties + +### amount + +• **amount**: *any* + +*Defined in [vote.ts:14](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L14)* + +___ + +### createdAt + +• **createdAt**: *[Date](../globals.md#date) | undefined* + +*Defined in [vote.ts:12](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L12)* + +___ + +### `Optional` dao + +• **dao**? : *[Address](../globals.md#address)* + +*Defined in [vote.ts:16](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L16)* + +___ + +### `Optional` id + +• **id**? : *undefined | string* + +*Defined in [vote.ts:10](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L10)* + +___ + +### outcome + +• **outcome**: *[IProposalOutcome](../enums/iproposaloutcome.md)* + +*Defined in [vote.ts:13](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L13)* + +___ + +### proposal + +• **proposal**: *string* + +*Defined in [vote.ts:15](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L15)* + +___ + +### voter + +• **voter**: *[Address](../globals.md#address)* + +*Defined in [vote.ts:11](https://github.com/daostack/client/blob/18967ff/src/vote.ts#L11)* diff --git a/package-lock.json b/package-lock.json index bce30fc2..3462a0be 100644 --- a/package-lock.json +++ b/package-lock.json @@ -669,9 +669,15 @@ "dev": true }, "@types/lodash": { +<<<<<<< Updated upstream "version": "4.14.121", "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.121.tgz", "integrity": "sha512-ORj7IBWj13iYufXt/VXrCNMbUuCTJfhzme5kx9U/UtcIPdJYuvPDUAlHlbNhz/8lKCLy9XGIZnGrqXOtQbPGoQ==", +======= + "version": "4.14.138", + "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.138.tgz", + "integrity": "sha512-A4uJgHz4hakwNBdHNPdxOTkYmXNgmUAKLbXZ7PKGslgeV0Mb8P3BlbYfPovExek1qnod4pDfRbxuzcVs3dlFLg==", +>>>>>>> Stashed changes "dev": true }, "@types/marked": { @@ -4894,9 +4900,15 @@ } }, "highlight.js": { +<<<<<<< Updated upstream "version": "9.14.2", "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-9.14.2.tgz", "integrity": "sha512-Nc6YNECYpxyJABGYJAyw7dBAYbXEuIzwzkqoJnwbc1nIpCiN+3ioYf0XrBnLiyyG0JLuJhpPtt2iTSbXiKLoyA==", +======= + "version": "9.15.10", + "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-9.15.10.tgz", + "integrity": "sha512-RoV7OkQm0T3os3Dd2VHLNMoaoDVx77Wygln3n9l5YV172XonWG6rgQD3XnF/BuFFZw9A0TJgmMSO8FEWQgvcXw==", +>>>>>>> Stashed changes "dev": true }, "hmac-drbg": { @@ -10834,6 +10846,34 @@ "integrity": "sha1-bcJDPnjti+qOiHo6zeLzF4W9Yic=", "dev": true }, + "typedoc-plugin-markdown": { + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/typedoc-plugin-markdown/-/typedoc-plugin-markdown-2.2.4.tgz", + "integrity": "sha512-nx/4dAczc7J7hxCGT1gNn78NeuTpx1QPxjv9VvJvPiArDbZcz3ZEykNHN1gmgbyPh2NoEkdEFuuDFsiR9vdrhg==", + "dev": true, + "requires": { + "fs-extra": "^8.1.0" + }, + "dependencies": { + "fs-extra": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", + "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", + "dev": true, + "requires": { + "graceful-fs": "^4.2.0", + "jsonfile": "^4.0.0", + "universalify": "^0.1.0" + } + }, + "graceful-fs": { + "version": "4.2.2", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.2.tgz", + "integrity": "sha512-IItsdsea19BoLC7ELy13q1iJFNmd7ofZH5+X/pJr90/nRoPEX0DJo1dHDbgtYWOhJhcCgMDTOw84RZ72q6lB+Q==", + "dev": true + } + } + }, "typescript": { "version": "3.3.3333", "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.3.3333.tgz", diff --git a/package.json b/package.json index e6bbbbec..7899a518 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,7 @@ "node": ">=6.0.0" }, "scripts": { - "build": "tsc && typedoc --out docs --target commonjs --theme minimal --mode file src", + "build": "tsc && typedoc --out docs --target commonjs --theme markdown --mode file --plugin typedoc-plugin-markdown src", "build:watch": "tsc --watch", "bundle": "rollup -c rollup.config.ts -w", "deploy-docs": "ts-node tools/gh-pages-publish", @@ -94,8 +94,9 @@ "ts-node": "^7.0.1", "tslint": "^5.14.0", "tslint-config-standard": "^8.0.1", - "typedoc": "^0.12.0", - "typescript": "^3.3.3333", + "typedoc": "^0.14.2", + "typedoc-plugin-markdown": "^2.2.4", + "typescript": "^3.5.3", "u": "^0.1.0" }, "dependencies": {