forked from sashaastiadi/www_mycelium_net
feat: update app screens with Mycelium connector, peers and settings UI
This commit is contained in:
BIN
connector.png
Normal file
BIN
connector.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 53 KiB |
BIN
setting.png
Normal file
BIN
setting.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 50 KiB |
@@ -10,7 +10,7 @@ export function PhoneFrame({
|
|||||||
return (
|
return (
|
||||||
<div className={clsx('relative aspect-[366/729]', className)} {...props}>
|
<div className={clsx('relative aspect-[366/729]', className)} {...props}>
|
||||||
<Image
|
<Image
|
||||||
src="/images/phoneframe.png"
|
src="/images/phone-frame.svg"
|
||||||
alt=""
|
alt=""
|
||||||
className="pointer-events-none absolute inset-0"
|
className="pointer-events-none absolute inset-0"
|
||||||
fill
|
fill
|
||||||
|
@@ -15,6 +15,7 @@ import { useDebouncedCallback } from 'use-debounce'
|
|||||||
import { AppScreen } from '@/components/AppScreen'
|
import { AppScreen } from '@/components/AppScreen'
|
||||||
import { CircleBackground } from '@/components/CircleBackground'
|
import { CircleBackground } from '@/components/CircleBackground'
|
||||||
import { Container } from '@/components/Container'
|
import { Container } from '@/components/Container'
|
||||||
|
import Image from 'next/image'
|
||||||
import { PhoneFrame } from '@/components/PhoneFrame'
|
import { PhoneFrame } from '@/components/PhoneFrame'
|
||||||
import {
|
import {
|
||||||
DiageoLogo,
|
DiageoLogo,
|
||||||
@@ -37,23 +38,23 @@ interface CustomAnimationProps {
|
|||||||
|
|
||||||
const features = [
|
const features = [
|
||||||
{
|
{
|
||||||
name: 'Decentralized Nodes',
|
name: 'Mycelium Connector',
|
||||||
description:
|
description:
|
||||||
"Mycelium operates through a network of decentralized nodes, similar to how nature's mycelium forms a decentralized network of threads. Each node acts as a connection point in the overall digital ecosystem.",
|
"Start (and stop) your Mycelium connector to gain access to sites, apps, and workloads available exclusively on the Mycelium Network. View statistics around peers and traffic.",
|
||||||
icon: DeviceUserIcon,
|
icon: DeviceUserIcon,
|
||||||
screen: InviteScreen,
|
screen: InviteScreen,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'Efficient Data Routing',
|
name: 'Mycelium Peers',
|
||||||
description:
|
description:
|
||||||
'Mycelium optimizes data routing by choosing the most efficient path for communication. Data travels along the shortest path in terms of latency, ensuring that information reaches its destination swiftly.',
|
'Search and discover active peers on the Mycelium Network, or add your own.',
|
||||||
icon: DeviceNotificationIcon,
|
icon: DeviceNotificationIcon,
|
||||||
screen: StocksScreen,
|
screen: StocksScreen,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'End-to-End Encryption',
|
name: 'Network Setting',
|
||||||
description:
|
description:
|
||||||
'Each node in the system is identified by a unique key pair. Data between nodes is encrypted using secret keys derived from these pairs. This ensures that data remains confidential, enhancing the privacy of the network.',
|
'Find version and network information and trigger light or dark mode.',
|
||||||
icon: DeviceTouchIcon,
|
icon: DeviceTouchIcon,
|
||||||
screen: InvestScreen,
|
screen: InvestScreen,
|
||||||
},
|
},
|
||||||
@@ -193,35 +194,7 @@ type ScreenProps =
|
|||||||
function InviteScreen(props: ScreenProps) {
|
function InviteScreen(props: ScreenProps) {
|
||||||
return (
|
return (
|
||||||
<AppScreen className="w-full">
|
<AppScreen className="w-full">
|
||||||
<MotionAppScreenHeader {...(props.animated ? headerAnimation : {})}>
|
<Image src="/images/connector.png" alt="Mycelium Connector" width={366} height={732} />
|
||||||
<AppScreen.Title>Invite people</AppScreen.Title>
|
|
||||||
<AppScreen.Subtitle>
|
|
||||||
Get tips <span className="text-white">5s sooner</span> for every
|
|
||||||
invite.
|
|
||||||
</AppScreen.Subtitle>
|
|
||||||
</MotionAppScreenHeader>
|
|
||||||
<MotionAppScreenBody
|
|
||||||
{...(props.animated ? { ...bodyAnimation, custom: props.custom } : {})}
|
|
||||||
>
|
|
||||||
<div className="px-4 py-6">
|
|
||||||
<div className="space-y-6">
|
|
||||||
{[
|
|
||||||
{ label: 'Full name', value: 'Albert H. Wiggin' },
|
|
||||||
{ label: 'Email address', value: 'awiggin@chase.com' },
|
|
||||||
].map((field) => (
|
|
||||||
<div key={field.label}>
|
|
||||||
<div className="text-sm text-gray-500">{field.label}</div>
|
|
||||||
<div className="mt-2 border-b border-gray-200 pb-2 text-sm text-gray-900">
|
|
||||||
{field.value}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
))}
|
|
||||||
</div>
|
|
||||||
<div className="mt-6 rounded-lg bg-cyan-500 px-3 py-2 text-center text-sm font-semibold text-white">
|
|
||||||
Invite person
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</MotionAppScreenBody>
|
|
||||||
</AppScreen>
|
</AppScreen>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@@ -229,101 +202,7 @@ function InviteScreen(props: ScreenProps) {
|
|||||||
function StocksScreen(props: ScreenProps) {
|
function StocksScreen(props: ScreenProps) {
|
||||||
return (
|
return (
|
||||||
<AppScreen className="w-full">
|
<AppScreen className="w-full">
|
||||||
<MotionAppScreenHeader {...(props.animated ? headerAnimation : {})}>
|
<Image src="/images/peers.png" alt="Mycelium Peers" width={366} height={732} />
|
||||||
<AppScreen.Title>Stocks</AppScreen.Title>
|
|
||||||
<AppScreen.Subtitle>March 9, 2022</AppScreen.Subtitle>
|
|
||||||
</MotionAppScreenHeader>
|
|
||||||
<MotionAppScreenBody
|
|
||||||
{...(props.animated ? { ...bodyAnimation, custom: props.custom } : {})}
|
|
||||||
>
|
|
||||||
<div className="divide-y divide-gray-100">
|
|
||||||
{[
|
|
||||||
{
|
|
||||||
name: 'Laravel',
|
|
||||||
price: '4,098.01',
|
|
||||||
change: '+4.98%',
|
|
||||||
color: '#F9322C',
|
|
||||||
logo: LaravelLogo,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'Tuple',
|
|
||||||
price: '5,451.10',
|
|
||||||
change: '-3.38%',
|
|
||||||
color: '#5A67D8',
|
|
||||||
logo: TupleLogo,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'Transistor',
|
|
||||||
price: '4,098.41',
|
|
||||||
change: '+6.25%',
|
|
||||||
color: '#2A5B94',
|
|
||||||
logo: TransistorLogo,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'Diageo',
|
|
||||||
price: '250.65',
|
|
||||||
change: '+1.25%',
|
|
||||||
color: '#3320A7',
|
|
||||||
logo: DiageoLogo,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'StaticKit',
|
|
||||||
price: '250.65',
|
|
||||||
change: '-3.38%',
|
|
||||||
color: '#2A3034',
|
|
||||||
logo: StaticKitLogo,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'Statamic',
|
|
||||||
price: '5,040.85',
|
|
||||||
change: '-3.11%',
|
|
||||||
color: '#0EA5E9',
|
|
||||||
logo: StatamicLogo,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'Mirage',
|
|
||||||
price: '140.44',
|
|
||||||
change: '+9.09%',
|
|
||||||
color: '#16A34A',
|
|
||||||
logo: MirageLogo,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'Reversable',
|
|
||||||
price: '550.60',
|
|
||||||
change: '-1.25%',
|
|
||||||
color: '#8D8D8D',
|
|
||||||
logo: ReversableLogo,
|
|
||||||
},
|
|
||||||
].map((stock) => (
|
|
||||||
<div key={stock.name} className="flex items-center gap-4 px-4 py-3">
|
|
||||||
<div
|
|
||||||
className="flex-none rounded-full"
|
|
||||||
style={{ backgroundColor: stock.color }}
|
|
||||||
>
|
|
||||||
<stock.logo className="h-10 w-10" />
|
|
||||||
</div>
|
|
||||||
<div className="flex-auto text-sm text-gray-900">
|
|
||||||
{stock.name}
|
|
||||||
</div>
|
|
||||||
<div className="flex-none text-right">
|
|
||||||
<div className="text-sm font-medium text-gray-900">
|
|
||||||
{stock.price}
|
|
||||||
</div>
|
|
||||||
<div
|
|
||||||
className={clsx(
|
|
||||||
'text-xs/5',
|
|
||||||
stock.change.startsWith('+')
|
|
||||||
? 'text-cyan-500'
|
|
||||||
: 'text-gray-500',
|
|
||||||
)}
|
|
||||||
>
|
|
||||||
{stock.change}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
))}
|
|
||||||
</div>
|
|
||||||
</MotionAppScreenBody>
|
|
||||||
</AppScreen>
|
</AppScreen>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@@ -331,54 +210,7 @@ function StocksScreen(props: ScreenProps) {
|
|||||||
function InvestScreen(props: ScreenProps) {
|
function InvestScreen(props: ScreenProps) {
|
||||||
return (
|
return (
|
||||||
<AppScreen className="w-full">
|
<AppScreen className="w-full">
|
||||||
<MotionAppScreenHeader {...(props.animated ? headerAnimation : {})}>
|
<Image src="/images/setting.png" alt="Mycelium Settings" width={366} height={732} />
|
||||||
<AppScreen.Title>Buy $LA</AppScreen.Title>
|
|
||||||
<AppScreen.Subtitle>
|
|
||||||
<span className="text-white">$34.28</span> per share
|
|
||||||
</AppScreen.Subtitle>
|
|
||||||
</MotionAppScreenHeader>
|
|
||||||
<MotionAppScreenBody
|
|
||||||
{...(props.animated ? { ...bodyAnimation, custom: props.custom } : {})}
|
|
||||||
>
|
|
||||||
<div className="px-4 py-6">
|
|
||||||
<div className="space-y-4">
|
|
||||||
{[
|
|
||||||
{ label: 'Number of shares', value: '100' },
|
|
||||||
{
|
|
||||||
label: 'Current market price',
|
|
||||||
value: (
|
|
||||||
<div className="flex">
|
|
||||||
$34.28
|
|
||||||
<svg viewBox="0 0 24 24" fill="none" className="h-6 w-6">
|
|
||||||
<path
|
|
||||||
d="M17 15V7H9M17 7 7 17"
|
|
||||||
stroke="#06B6D4"
|
|
||||||
strokeWidth="2"
|
|
||||||
strokeLinecap="round"
|
|
||||||
strokeLinejoin="round"
|
|
||||||
/>
|
|
||||||
</svg>
|
|
||||||
</div>
|
|
||||||
),
|
|
||||||
},
|
|
||||||
{ label: 'Estimated cost', value: '$3,428.00' },
|
|
||||||
].map((item) => (
|
|
||||||
<div
|
|
||||||
key={item.label}
|
|
||||||
className="flex justify-between border-b border-gray-100 pb-4"
|
|
||||||
>
|
|
||||||
<div className="text-sm text-gray-500">{item.label}</div>
|
|
||||||
<div className="text-sm font-semibold text-gray-900">
|
|
||||||
{item.value}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
))}
|
|
||||||
<div className="rounded-lg bg-cyan-500 px-3 py-2 text-center text-sm font-semibold text-white">
|
|
||||||
Buy shares
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</MotionAppScreenBody>
|
|
||||||
</AppScreen>
|
</AppScreen>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
BIN
src/images/connector.png
Normal file
BIN
src/images/connector.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 112 KiB |
BIN
src/images/peers.png
Normal file
BIN
src/images/peers.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 118 KiB |
BIN
src/images/phoneframe.png
Normal file
BIN
src/images/phoneframe.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 537 KiB |
BIN
src/images/setting.png
Normal file
BIN
src/images/setting.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 107 KiB |
Reference in New Issue
Block a user