feat: log bytes

This commit is contained in:
TrèsAbhi committed 2025-06-12 20:41:56 -05:00
1 parent 02df1e59d8
commit 1249877a8c
1 file changed
+14 -1
@@ -1,7 +1,11 @@
import type { MessageFns } from '@protos/blitz_static_profile_avatar_component'; import type { MessageFns } from '@protos/blitz_static_profile_avatar_component';
import type { Any } from '@protos/google/protobuf/any'; import type { Any } from '@protos/google/protobuf/any';
import * as protos from '@protos/index'; import * as protos from '@protos/index';
import { ArrowBottomRightIcon, CommitIcon } from '@radix-ui/react-icons'; import {
ArrowBottomRightIcon,
CommitIcon,
DiscIcon,
} from '@radix-ui/react-icons';
import { import {
Badge, Badge,
Box, Box,
@@ -60,6 +64,7 @@ export function Page({ servers }: { servers: DiscoveryServer[] }) {
try { try {
const diff = await diffServers(serverA!.addr, serverB!.addr); const diff = await diffServers(serverA!.addr, serverB!.addr);
setDiff(diff); setDiff(diff);
setIsError(false);
} catch (error) { } catch (error) {
console.error(error); console.error(error);
setIsError(true); setIsError(true);
@@ -239,6 +244,14 @@ function ComponentDisplay({
<Badge color="gray" variant="outline"> <Badge color="gray" variant="outline">
{value.value.length.toLocaleString()}B {value.value.length.toLocaleString()}B
</Badge> </Badge>
<IconButton
size="1"
variant="ghost"
onClick={() => console.log(value.value)}
>
<DiscIcon />
</IconButton>
</Flex> </Flex>
{code !== null && ( {code !== null && (