All checks were successful
Build pull request / Build pull request (pull_request) Successful in 3m54s
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
22 lines
732 B
TypeScript
22 lines
732 B
TypeScript
import React from 'react';
|
|
import { Text } from 'folds';
|
|
import { uploadFailureText } from '../../utils/uploadReason';
|
|
|
|
/** A failed upload as the card shows it: the reason and what to do, the diagnostic text one tap away. */
|
|
export function UploadFailureNote({ error }: { error: Error }) {
|
|
return (
|
|
<>
|
|
<Text size="T200">{uploadFailureText(error)}</Text>
|
|
<details style={{ flex: 1, minWidth: 0 }}>
|
|
<summary style={{ minHeight: 44, display: 'flex', alignItems: 'center' }}>
|
|
<Text as="span" size="T200">
|
|
Details
|
|
</Text>
|
|
</summary>
|
|
<Text size="T200" style={{ wordBreak: 'break-word' }}>
|
|
{error.message}
|
|
</Text>
|
|
</details>
|
|
</>
|
|
);
|
|
}
|