Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/dcgtc/dgrants
/ functions
Functions
196 in github.com/dcgtc/dgrants
⨍
Functions
196
◇
Types & classes
17
↓ 1 callers
Function
getEtherscanUrl
(hash: string, group: EtherscanGroup = 'tx')
app/src/utils/utils.ts:188
↓ 1 callers
Function
getGrantRoundDonations
( grantRoundAddress: string, latestBlockNumber: number, forceRefresh = false )
app/src/utils/data/grantRounds.ts:261
↓ 1 callers
Method
getHexProof
(el: Buffer)
utils/src/merkle-distributor/merkle-tree.ts:92
↓ 1 callers
Method
getHexRoot
()
utils/src/merkle-distributor/balance-tree.ts:38
↓ 1 callers
Method
getLayers
(elements: Buffer[])
utils/src/merkle-distributor/merkle-tree.ts:26
↓ 1 callers
Function
getMerkleRoot
(merkleDistributorInfo: MerkleDistributorInfo | undefined)
dcurve/src/internal/merkle.ts:76
↓ 1 callers
Function
getMulticallData
( calls: { target: string; contract: Contract; fns: (string | { fn: string; args: (string | BigN
app/src/utils/utils.ts:285
↓ 1 callers
Method
getNextLayer
(elements: Buffer[])
utils/src/merkle-distributor/merkle-tree.ts:42
↓ 1 callers
Method
getPairElement
(idx: number, layer: Buffer[])
utils/src/merkle-distributor/merkle-tree.ts:98
↓ 1 callers
Function
getPoolInstance
(token0: SupportedToken, token1: SupportedToken)
contracts/test/utils.ts:132
↓ 1 callers
Function
getPredictedMatchingForAmount
(clrPredictions: GrantPrediction, amount: number)
dcurve/src/internal/utils.ts:68
↓ 1 callers
Method
getProof
(index: number | BigNumber, account: string, amount: BigNumber)
utils/src/merkle-distributor/balance-tree.ts:43
↓ 1 callers
Method
getRoot
()
utils/src/merkle-distributor/merkle-tree.ts:64
↓ 1 callers
Function
getRoute
(tokens: SupportedToken[])
contracts/test/utils.ts:110
↓ 1 callers
Function
getStorage
(config: LocalForageConfig)
app/src/utils/data/utils.ts:60
↓ 1 callers
Function
getTrustBonusScores
( blockNumber: number, contributions: Record<string, Contribution>, forceRefresh = false )
app/src/utils/data/contributions.ts:173
↓ 1 callers
Function
grantDonationListener
( args: { grantPayees: Record<string, string>; donationToken: TokenInfo; grantIds: number[];
app/src/utils/data/contributions.ts:268
↓ 1 callers
Function
grantRoundCreatedListener
( args: { listeners: { off: () => Contract }[]; grantIds: number[]; trustBonus: Record<string, n
app/src/utils/data/grantRounds.ts:614
↓ 1 callers
Function
init
* @notice Throttle calls to rawInit() and catch any errors
app/src/store/data.ts:361
↓ 1 callers
Function
initializeOnboard
* @notice Initialize the onboard.js module
app/src/store/wallet.ts:70
↓ 1 callers
Function
isValidUrl
(val: string)
app/src/utils/utils.ts:112
↓ 1 callers
Function
lerp
(xLower: number, xUpper: number, yLower: number, yUpper: number, x: number)
dcurve/src/internal/utils.ts:58
↓ 1 callers
Function
main
()
contracts/scripts/app.ts:124
↓ 1 callers
Function
parseBalanceMap
(balances: OldFormat | NewFormat[])
utils/src/merkle-distributor/parse-balance-map.ts:35
↓ 1 callers
Method
predict
* Calculates the matching amount based on current distribution and predicts * the match based on predictionPoints * @param GrantPredictionArgs
dcurve/src/internal/clr.ts:99
↓ 1 callers
Function
rawInit
* @notice Called on init and network change - but can also be called on demand
app/src/store/data.ts:112
↓ 1 callers
Function
removeAllListeners
* @notice Called each block to poll for data, but can also be called on-demand, e.g. after user submits a transaction
app/src/store/data.ts:78
↓ 1 callers
Function
sanitizeHTML
(str: string)
app/src/utils/utils.ts:423
↓ 1 callers
Function
setLastWallet
(walletName: string)
app/src/store/settings.ts:27
↓ 1 callers
Function
setProvider
(p: any)
app/src/store/wallet.ts:149
↓ 1 callers
Method
sortAndConcat
(...args: Buffer[])
utils/src/merkle-distributor/merkle-tree.ts:122
↓ 1 callers
Function
startPolling
* @notice Call this method to poll now, then poll on each new block
app/src/store/data.ts:373
↓ 1 callers
Function
to32ByteHex
(x: BigNumberish)
contracts/test/utils.ts:200
↓ 1 callers
Function
uploadTrustBonusScores
(trustBonusScores: TrustBonusScore[])
utils/src/trustBonus.ts:57
↓ 1 callers
Function
useSettingsStore
()
app/src/store/settings.ts:21
↓ 1 callers
Function
waitForInput
(query: string)
contracts/scripts/ScriptLogger.ts:4
↓ 1 callers
Function
waitForInput
(query: string)
contracts/tasks/execute-payouts.ts:138
↓ 1 callers
Function
watchTransaction
( call: () => Promise<ContractTransaction>, stateRef?: Ref )
app/src/utils/utils.ts:247
Function
Home
()
doc/docs-web/src/pages/index.js:28
Function
HomepageHeader
()
doc/docs-web/src/pages/index.js:9
Function
addToCart
* @notice Adds an item to the cart * @param grantId Grant ID to add to the cart
app/src/store/cart.ts:179
Function
changeWallet
* @notice Change wallet
app/src/store/wallet.ts:127
Function
checkAllowance
(token: Contract, ownerAddress: string | undefined, spenderAddress: string)
app/src/utils/utils.ts:164
Function
checkout
* @notice Executes donations
app/src/store/cart.ts:226
Function
cleanTwitterUrl
(url: string | undefined)
app/src/utils/utils.ts:83
Function
clearCartState
* @notice Resets cart store state
app/src/store/cart.ts:218
Function
connectWallet
* @notice Prompt user to connect wallet, or attempt to connect to wallet specified by `name` * @param name Wallet name to connect, or undefined to
app/src/store/wallet.ts:97
Method
constructor
(elements: Buffer[])
utils/src/merkle-distributor/merkle-tree.ts:9
Method
constructor
(balances: { account: string; amount: BigNumber }[])
utils/src/merkle-distributor/balance-tree.ts:7
Method
constructor
(readonly options: InitArgs)
dcurve/src/internal/clr.ts:23
Method
constructor
(readonly deployName: string, readonly network: string, readonly folder: string = './deploy-history')
contracts/scripts/ScriptLogger.ts:26
Function
daysAgo
(val = 0)
app/src/utils/utils.ts:55
Function
fetchQuotes
* @notice Fetches quotes based on the users cart * @dev For max accuracy, this should be run each time the user edits their cart with the actual ca
app/src/store/cart.ts:334
Function
filterContributionGrantData
( userAddress: string, contributions: Contribution[], grants: Grant[], grantRounds: GrantRound[], gr
app/src/utils/data/contributions.ts:458
Function
filterMatchingPoolContributions
( grantRound: GrantRound, roundDonations: Record<string, GrantRoundDonation[]>, roundName: string | unde
app/src/utils/data/contributions.ts:419
Function
formatDate
(dateStr: BigNumber)
app/src/utils/utils.ts:66
Function
formatMetaPtr
(cid: string)
app/src/utils/data/ipfs.ts:56
Function
generateMerkleProof
( address: string, distribution: PayoutMatch[], matchingTokenDecimals: number )
dcurve/src/internal/merkle.ts:58
Function
generateMerkleRoot
(distribution: PayoutMatch[], matchingTokenDecimals: number)
dcurve/src/internal/merkle.ts:42
Function
getApproval
(token: Contract, address: string, amount: BigNumberish)
app/src/utils/utils.ts:170
Function
getGrantsGrantRoundDetails
( grantId: number, rounds: GrantRound[], roundsMetadata: Record<string, GrantRoundMetadataResolution>,
app/src/utils/data/grantRounds.ts:499
Function
getMerkleProof
(address: string, merkleDistributorInfo: MerkleDistributorInfo | undefined)
dcurve/src/internal/merkle.ts:93
Function
handle
(clrArgs: CLRArgs)
dcurve/src/internal/calc/linear.ts:16
Function
hasStatus
(status: string)
app/src/utils/utils.ts:177
Function
initializeCart
* @notice Initialize the store based on localStorage * @dev MUST be called on app load
app/src/store/cart.ts:85
Function
initializeSettings
()
app/src/store/settings.ts:22
Function
isDefined
(val: unknown)
app/src/utils/utils.ts:31
Function
isInCart
* @notice Returns true if the provided grantId is in the cart, false otherwise * @param grantId Grant ID to check
app/src/store/cart.ts:353
Function
isValidAddress
(val: string | undefined)
app/src/utils/utils.ts:118
Function
isValidAmount
(val: number | undefined)
app/src/utils/utils.ts:158
Function
isValidGithub
(val: string | undefined)
app/src/utils/utils.ts:128
Function
isValidLogo
(file: File | undefined)
app/src/utils/utils.ts:140
Function
isValidTwitter
(val: string | undefined)
app/src/utils/utils.ts:133
Function
isValidWebsite
(val: string | undefined)
app/src/utils/utils.ts:123
Function
listener
( grantId: BigNumberish, owner: string, payee: string, metaPtr: MetaPtr, time: BigNumberis
app/src/utils/data/grants.ts:149
Function
listener
( grantId: BigNumberish, tokenIn: string, donationAmount: BigNumberish, grantRounds: string[],
app/src/utils/data/contributions.ts:277
Function
listener
(grantRoundAddress: string)
app/src/utils/data/grantRounds.ts:623
Function
onclick
()
app/src/utils/alerts.ts:85
Function
pushRoute
(to: RouteLocationRaw)
app/src/utils/utils.ts:183
Function
removeFromCart
* @notice Removes a grant from the cart based on it's `grantId` * @param grantId Grant ID to remove from the cart
app/src/store/cart.ts:203
Function
scrollBehavior
(_to, _from, savedPosition)
app/src/router/index.ts:47
Function
setup
()
contracts/test/GrantRound.test.ts:75
Function
setup
()
contracts/test/gas.test.ts:34
Function
shuffle
(unshuffled: Grant[] | GrantRound[])
app/src/utils/utils.ts:434
Function
sortByStartTime
(a: GrantRound, b: GrantRound)
app/src/utils/utils.ts:402
Function
sortContributionsByAmount
(contributions: ContributionsDetail[])
app/src/utils/utils.ts:414
Function
switchNetwork
* @notice Prompts user to switch networks to this applications required network
app/src/store/wallet.ts:192
Function
txNotify
(txHash: string, provider: JsonRpcProvider)
app/src/utils/alerts.ts:83
Function
unixToLocaleString
(time: BigNumberish)
app/src/utils/utils.ts:72
Function
updateCart
* @notice Updates the amount or token of an item in the cart * @dev Used to keep localStorage in sync with store when the `cart` ref is modified di
app/src/store/cart.ts:157
Function
uploadFile
(file: File)
app/src/utils/data/ipfs.ts:23
Function
uploadGrantMetadata
({ name, description, logoPtr, properties }: GrantMetadata)
app/src/utils/data/ipfs.ts:35
Function
urlFromTwitterHandle
(handle: string)
app/src/utils/utils.ts:77
Function
useCartStore
()
app/src/store/cart.ts:79
Method
verify
* Verifies hash based on distribution & the trust bonus score * * @param grantRoundContributions * @param trustBonusMetaPtr * @param hash
dcurve/src/internal/clr.ts:163
Method
verifyProof
( index: number | BigNumber, account: string, amount: BigNumber, proof: Buffer[], root: Bu
utils/src/merkle-distributor/balance-tree.ts:15
← previous
101–196 of 196, ranked by callers