Update descriptions, protobufs & bugfixes

This commit is contained in:
Sacha Weatherstone
2022-10-03 20:35:03 +10:30
parent 26dbe0c032
commit a884fe28b3
21 changed files with 744 additions and 205 deletions
+2 -2
View File
@@ -17,7 +17,7 @@ export const BatteryWidget = ({
}: BatteryWidgetProps): JSX.Element => {
return (
<Card className="flex-col">
<Dropdown title="Position" icon={<BoltIcon className="h-4" />}>
<Dropdown title="Battery" icon={<BoltIcon className="h-4" />}>
<div className="flex">
<div className="flex w-20 bg-slate-700 p-3">
<Battery100Icon className="m-auto h-12 text-white" />
@@ -27,7 +27,7 @@ export const BatteryWidget = ({
<Mono>%</Mono>
</span>
<span className="m-auto text-lg">
{voltage}
{voltage.toPrecision(2)}
<Mono>v</Mono>
</span>
</div>
+1 -1
View File
@@ -22,7 +22,7 @@ export const DeviceWidget = ({
reconnect,
}: DeviceWidgetProps): JSX.Element => {
return (
<Card className="relative flex-col">
<Card className="relative shrink-0 flex-col">
<div className="absolute bottom-20 h-full w-full">
<Hashicon size={350} value={nodeNum} />
</div>
+9 -2
View File
@@ -21,8 +21,12 @@ export interface PeersWidgetProps {
export const PeersWidget = ({ peers }: PeersWidgetProps): JSX.Element => {
return (
<Card className="flex-col">
<Dropdown title="Peers" icon={<UserGroupIcon className="h-4" />}>
<div className="p-3">
<Dropdown
title="Peers"
stat={peers.length}
icon={<UserGroupIcon className="h-4" />}
>
<div className="flex flex-col p-3">
{peers.map((peer) => (
<div
className="flex gap-2 rounded-md p-2 hover:bg-slate-100"
@@ -49,6 +53,9 @@ export const PeersWidget = ({ peers }: PeersWidgetProps): JSX.Element => {
</div>
</div>
))}
{peers.length === 0 && (
<Mono className="m-auto">No devices discovered yet.</Mono>
)}
</div>
</Dropdown>
</Card>