-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Progress Modal UI (#1058) * Open progress modal * Move to progress modal * Add checklist * Add challenge items * Clean up design --------- Co-authored-by: Chase Fleming <[email protected]> * Add blank profile modal (#1066) * Add blank profile modal * Rename * Rename * Rename --------- Co-authored-by: Chase Fleming <[email protected]> * Add field and input components (#1068) * Setup input component * Change style * Add field component * Add field and input components --------- Co-authored-by: Chase Fleming <[email protected]> * [GS] Add Cadence Scripts & TS Bindings * Add radio group for how did you find (#1069) * Add radio group for how did you find * Add more options --------- Co-authored-by: Chase Fleming <[email protected]> * Add tags section (#1070) Co-authored-by: Chase Fleming <[email protected]> * Add functionality to edit or create profile (#1071) * Add challenge section (#1072) Co-authored-by: Chase Fleming <[email protected]> * Hook up progress percentage (#1073) * Add scoll to modal (#1076) Co-authored-by: Chase Fleming <[email protected]> * add class for mobile fix * Hook up first challenge progress (#1075) * More changes from main (#1079) * Bring more changes from main * Remove --------- Co-authored-by: Chase Fleming <[email protected]> * Challenge modal ui (#1080) * Add challenge modal * Add icon and text * Add complete button --------- Co-authored-by: Chase Fleming <[email protected]> * Hook up NoopChallenge button (#1081) * Hook up challenge badges with on-chain data (#1083) * Add transaction status tracking (#1086) * Add Form Validation & Fix GitHub Input (#1089) * Fix contract identifier field (#1098) * Add GitHub picture to profile (#1100) * Cache GitHub Profile (#1103) * Misc UI improvements (#1104) * Improve text * Improve look on checklist * Improve unselected radio group state * Fixes * Fix dark mode * Change button color --------- Co-authored-by: Chase Fleming <[email protected]> * Add ability to include EVM contracts in Gold Star profile (#1099) * Input improvements (#1106) * Input improvements * Fix * Remove * Remove --------- Co-authored-by: Chase Fleming <[email protected]> * Fix referral validation (#1105) * Add close button to modal (#1107) * Disallow challenges with no profile (#1109) * Fix deployed contracts progress (#1110) * Change to select (#1111) Co-authored-by: Chase Fleming <[email protected]> * Fix dark mode ghost button shadow (#1113) * Fix challenge disabled (#1112) * Misc UI improvements (#1115) * Use avatar and progress (#1114) Co-authored-by: Chase Fleming <[email protected]> * Add user addr to profile and fix select color (#1116) * Add user addr to profile * Fix styling --------- Co-authored-by: Chase Fleming <[email protected]> * Update to latest Gold Star contracts & deploy mainnet (#1118) * Use GitHub Avatar for Dropdown (#1117) --------- Co-authored-by: Chase Fleming <[email protected]> Co-authored-by: Chase Fleming <[email protected]>
- Loading branch information
Showing
52 changed files
with
3,301 additions
and
1,003 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -39,3 +39,6 @@ docs/.obsidian | |
|
||
# flow | ||
imports | ||
|
||
goldstar-testnet.pkey | ||
goldstar-mainnet.pkey |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,130 @@ | ||
{ | ||
"networks": { | ||
"emulator": "127.0.0.1:3569", | ||
"mainnet": "access.mainnet.nodes.onflow.org:9000", | ||
"testing": "127.0.0.1:3569", | ||
"testnet": "access.devnet.nodes.onflow.org:9000" | ||
}, | ||
"accounts": { | ||
"emulator-account": { | ||
"address": "f8d6e0586b0a20c7", | ||
"key": { | ||
"type": "file", | ||
"location": "emulator-account.pkey" | ||
} | ||
} | ||
} | ||
} | ||
"contracts": { | ||
"DeployedContractChallenge": { | ||
"source": "./src/cadence/contracts/DeployedContractChallenge.cdc", | ||
"aliases": { | ||
"testing": "0000000000000007" | ||
} | ||
}, | ||
"GoldStar": { | ||
"source": "./src/cadence/contracts/GoldStar.cdc", | ||
"aliases": { | ||
"testing": "0000000000000007" | ||
} | ||
}, | ||
"LearnFlowChallenge": { | ||
"source": "./src/cadence/contracts/LearnFlowChallenge.cdc", | ||
"aliases": { | ||
"testing": "0000000000000007" | ||
} | ||
}, | ||
"ManualChallenge": { | ||
"source": "./src/cadence/contracts/ManualChallenge.cdc", | ||
"aliases": { | ||
"testing": "0000000000000007" | ||
} | ||
} | ||
}, | ||
"dependencies": { | ||
"Burner": { | ||
"source": "mainnet://f233dcee88fe0abe.Burner", | ||
"hash": "71af18e227984cd434a3ad00bb2f3618b76482842bae920ee55662c37c8bf331", | ||
"aliases": { | ||
"emulator": "f8d6e0586b0a20c7", | ||
"mainnet": "f233dcee88fe0abe", | ||
"testnet": "9a0766d93b6608b7" | ||
} | ||
}, | ||
"FlowToken": { | ||
"source": "mainnet://1654653399040a61.FlowToken", | ||
"hash": "cefb25fd19d9fc80ce02896267eb6157a6b0df7b1935caa8641421fe34c0e67a", | ||
"aliases": { | ||
"emulator": "0ae53cb6e3f42a79", | ||
"mainnet": "1654653399040a61", | ||
"testnet": "7e60df042a9c0868" | ||
} | ||
}, | ||
"FungibleToken": { | ||
"source": "mainnet://f233dcee88fe0abe.FungibleToken", | ||
"hash": "050328d01c6cde307fbe14960632666848d9b7ea4fef03ca8c0bbfb0f2884068", | ||
"aliases": { | ||
"emulator": "ee82856bf20e2aa6", | ||
"mainnet": "f233dcee88fe0abe", | ||
"testnet": "9a0766d93b6608b7" | ||
} | ||
}, | ||
"FungibleTokenMetadataViews": { | ||
"source": "mainnet://f233dcee88fe0abe.FungibleTokenMetadataViews", | ||
"hash": "dff704a6e3da83997ed48bcd244aaa3eac0733156759a37c76a58ab08863016a", | ||
"aliases": { | ||
"emulator": "ee82856bf20e2aa6", | ||
"mainnet": "f233dcee88fe0abe", | ||
"testnet": "9a0766d93b6608b7" | ||
} | ||
}, | ||
"MetadataViews": { | ||
"source": "mainnet://1d7e57aa55817448.MetadataViews", | ||
"hash": "10a239cc26e825077de6c8b424409ae173e78e8391df62750b6ba19ffd048f51", | ||
"aliases": { | ||
"emulator": "f8d6e0586b0a20c7", | ||
"mainnet": "1d7e57aa55817448", | ||
"testnet": "631e88ae7f1d7c20" | ||
} | ||
}, | ||
"NonFungibleToken": { | ||
"source": "mainnet://1d7e57aa55817448.NonFungibleToken", | ||
"hash": "b63f10e00d1a814492822652dac7c0574428a200e4c26cb3c832c4829e2778f0", | ||
"aliases": { | ||
"emulator": "f8d6e0586b0a20c7", | ||
"mainnet": "1d7e57aa55817448", | ||
"testnet": "631e88ae7f1d7c20" | ||
} | ||
}, | ||
"ViewResolver": { | ||
"source": "mainnet://1d7e57aa55817448.ViewResolver", | ||
"hash": "374a1994046bac9f6228b4843cb32393ef40554df9bd9907a702d098a2987bde", | ||
"aliases": { | ||
"emulator": "f8d6e0586b0a20c7", | ||
"mainnet": "1d7e57aa55817448", | ||
"testnet": "631e88ae7f1d7c20" | ||
} | ||
} | ||
}, | ||
"networks": { | ||
"emulator": "127.0.0.1:3569", | ||
"mainnet": "access.mainnet.nodes.onflow.org:9000", | ||
"testing": "127.0.0.1:3569", | ||
"testnet": "access.devnet.nodes.onflow.org:9000" | ||
}, | ||
"accounts": { | ||
"emulator-account": { | ||
"address": "f8d6e0586b0a20c7", | ||
"key": { | ||
"type": "file", | ||
"location": "emulator-account.pkey" | ||
} | ||
}, | ||
"goldstar-mainnet": { | ||
"address": "e99f9883203ff565", | ||
"key": { | ||
"type": "file", | ||
"location": "goldstar-mainnet.pkey" | ||
} | ||
}, | ||
"goldstar-testnet": { | ||
"address": "032b0464e2e8fccc", | ||
"key": { | ||
"type": "file", | ||
"location": "goldstar-testnet.pkey" | ||
} | ||
} | ||
}, | ||
"deployments": { | ||
"mainnet": { | ||
"goldstar-mainnet": ["GoldStar", "LearnFlowChallenge"] | ||
}, | ||
"testnet": { | ||
"goldstar-testnet": ["GoldStar", "LearnFlowChallenge"] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
import "GoldStar" | ||
|
||
access(all) | ||
contract DeployedContractChallenge { | ||
|
||
access(all) | ||
resource Challenge: GoldStar.Challenge { | ||
|
||
access(all) | ||
let name: String | ||
|
||
access(all) | ||
let description: String | ||
|
||
init() { | ||
self.name = "Deployed a contract" | ||
self.description = "Deploy a contract to Flow" | ||
} | ||
|
||
access(all) | ||
fun evaluate(submission: &{GoldStar.Submission}) { | ||
let submission = submission as? &Submission | ||
?? panic("invalid submission type") | ||
|
||
let owner = submission.owner | ||
?? panic("submission must be stored in an account") | ||
|
||
let name = submission.contractName | ||
if owner.contracts.borrow<&AnyStruct>(name: name) == nil { | ||
panic("contract not found") | ||
} | ||
|
||
submission.accept() | ||
} | ||
} | ||
|
||
access(all) | ||
resource Submission: GoldStar.Submission { | ||
|
||
access(all) | ||
let contractName: String | ||
|
||
access(self) | ||
var accepted: Bool | ||
|
||
init(contractName: String) { | ||
self.contractName = contractName | ||
self.accepted = false | ||
} | ||
|
||
access(all) | ||
fun isAccepted(): Bool { | ||
return self.accepted | ||
} | ||
|
||
access(contract) | ||
fun accept() { | ||
self.accepted = true | ||
} | ||
} | ||
|
||
access(all) | ||
fun createChallenge(): @Challenge { | ||
return <- create Challenge() | ||
} | ||
|
||
access(all) | ||
fun createSubmission(contractName: String): @Submission { | ||
return <- create Submission( | ||
contractName: contractName | ||
) | ||
} | ||
} |
Oops, something went wrong.