Skip to main content

Result

Feedback page for operation outcomes: the status determines the icon and coloring, with optional subtitle and action area.

Basic usage​

Basic usage
Submission successful
Delivered as scheduled; important files are archived.
Submission failed
Network error: some content could not be saved.
Warning
Notice
import { LhResult, LhButton } from '@lh-ui/react'

export default function Demo() {
return (
<>
<LhResult
status="success"
title="Submission successful"
subTitle="Delivered as scheduled; important files are archived."
/>
<LhResult
status="warning"
title="Warning"
extra={<LhButton type="primary">Reload</LhButton>}
/>
</>
)
}

Result Props​

PropDescriptionTypeOptionsDefault
statusResult status (determines icon and coloring)LhResultStatus'success' | 'warning' | 'info' | 'error''info'
iconCustom icon name (overrides the status default; empty string = no icon)stringLhIcon set—
iconSizeIcon size (passed to LhIcon)string | number—64
titleTitleReactNode——
subTitleSubtitle (rendered when provided)ReactNode——
extraBottom action area (buttons etc.)ReactNode——
sxShorthand layout propsSxProps——
Invalid status fallback

An invalid status falls back to info via the core whitelist; unknown --xxx modifier classes are never emitted.

Accessibility

The root element is role="status" (gentle announcement that does not interrupt screen readers); the icon area inherits LhIcon's accessibility semantics.

Styles​

import '@lh-ui/react/style/result'