mirror of
https://github.com/luxfi/explore.git
synced 2026-09-24 00:28:18 +00:00
The addresses list endpoint returns a projection of an address — no tags, no name, no implementations. AddressesListItem guarded with `public_tags !== null`, which is true of an absent field, so every visit to /accounts read `.length` off undefined and the whole page fell to the error boundary. The type said the field was always present, so nothing caught it. Partial<AddressParam> states what the endpoint sends, and both read sites reach for the tags the same optional way. The error screen it fell to had its own defect: the status glyph is an inline-block div and gui's H1 renders inline, so the two shared a line box and "500" ran into "Oops! Something went wrong". The screen is a stack; it now says so. The heading's own top margin was being outranked by gui's atomic reset.
17 lines
473 B
TypeScript
17 lines
473 B
TypeScript
import React from 'react';
|
|
|
|
import { Heading } from '@luxfi/ui/heading';
|
|
|
|
interface Props {
|
|
title: string;
|
|
}
|
|
|
|
// gui's H1 emits its own atomic margin reset (`_marginTop-0px`), so a plain
|
|
// `mt-8` here rendered as zero and the heading sat flush against the status
|
|
// glyph above it. The modifier is what outranks the reset.
|
|
const AppErrorTitle = ({ title }: Props) => {
|
|
return <Heading className="!mt-8" level="1">{ title }</Heading>;
|
|
};
|
|
|
|
export default AppErrorTitle;
|