Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions assets/icons/tokens/NFT.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
52 changes: 52 additions & 0 deletions components/cards/challenge/Overview.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
<template>
<div
class="border-solid border border-gray-200 rounded-3xl mb-5 group text-gray-700 p-6"
>
<div class="text-gray-900 text-lg leading-normal">
<span class="text-default font-medium"
>Already ready to complete the challenge?</span
>
<span class="ml-1.5">Build a Celo dApp</span>
</div>

<div class="md:flex md:flex-row flex-col rounded-full max-w-max text-sm mt-6 md:space-x-8 md:space-y-0 space-y-8">
<div class="flex items-center">
<Coin size="medium-min" token="NFT" class="p-0"/>
<div class="text-sm md:pl-2 max-w-max">
<div class="flex text-gray-700 font-medium">
<span class="block pr-1">150</span>
<span class="block ">cUSD Rewards</span>
</div>
<div class="text-gray-400 text-xs font-normal">
Upon successful completion
</div>
</div>
</div>
<div class="flex items-center">
<Coin size="medium-min" token="cUSD" />
<div class="text-sm md:pl-2 max-w-max">
<div class="flex text-gray-700 font-medium">
<span class="block pr-1">150</span>
<span class="block ">cUSD Rewards</span>
</div>
<div class="text-gray-400 text-xs font-normal">
Upon successful completion
</div>
</div>
</div>
</div>
<div class="text-gray-400 sm:w-3/5 lg:w-2/3 text-sm font-normal pt-6">
<span>Deadline</span>
<span class="font-medium">March 12th, 2022</span>
</div>
</div>
</template>
<script>
import Coin from '@/components/ui/Coin'
export default {
name: 'ChallengeOverviewCard',
components: {
Coin,
},
}
</script>
11 changes: 10 additions & 1 deletion components/ui/Coin.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import TEZIcon from '~/assets/icons/tokens/Tezos.svg?inline'
import DAIIcon from '~/assets/icons/tokens/DAI.svg?inline'
import NEARIcon from '~/assets/icons/tokens/NEAR.svg?inline'
import USDCIcon from '~/assets/icons/tokens/USDC.svg?inline'
import NFTIcon from '~/assets/icons/tokens/NFT.svg?inline'
export default {
name: 'Coin',
components: {
Expand All @@ -34,6 +35,7 @@ export default {
TEZIcon,
DAIIcon,
NEARIcon,
NFTIcon
},
props: {
bgColor: {
Expand Down Expand Up @@ -70,7 +72,7 @@ export default {
token: 'cUSD',
icon: CUSDIcon,
bgColor: '#FCFF52',
textColor: '#010101',
textColor: '#000000',
},
{
token: 'ETH',
Expand Down Expand Up @@ -108,12 +110,19 @@ export default {
bgColor: '#2775ca',
textColor: '#FFFFFF',
},
{
token: 'NFT',
icon: NFTIcon,
textColor: '#FFFFFF',
},
],
}
},
computed: {
sizeClasses() {
switch (this.size) {
case 'medium-min':
return 'w-15 h-15 text-xl sm:text-2xl'
case 'medium':
return 'w-10 h-10 sm:w-15 sm:h-15 text-xl p-1 sm:text-2xl sm:p-2'
case 'normal':
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
<template>
<Wrapper>
<div
class="py-8 flex flex-col divide-y divide-solid divide-gray-200 space-y-8 text-gray-700"
class="py-8 flex flex-col space-y-8 text-gray-700"
>
<Header />
<div class="w-full divide-y divide-solid divide-gray-200">
<div class="w-full">
<ChallengeOverviewCard/>
<MaterialSection
v-for="(material, i) in materials"
:key="i"
Expand All @@ -27,6 +28,7 @@
import { mapGetters } from 'vuex'
import PageNavigation from '@/components/sections/courses/PageNavigation.vue'
import Header from '@/components/sections/learning-modules/Header'
import ChallengeOverviewCard from '@/components/cards/challenge/Overview.vue'
import InteractiveModule from '@/components/sections/learning-modules/InteractiveModule'
import MaterialSection from '@/components/sections/learning-modules/Material'
import AdditionalMaterialsSection from '@/components/sections/learning-modules/AdditionalMaterials'
Expand All @@ -41,6 +43,7 @@ export default {
PageNavigation,
AdditionalMaterialsSection,
InteractiveModule,
ChallengeOverviewCard
},
scrollToTop: true,
fetch({ store, params, error }) {
Expand Down