review: rename ec-error file to error

This commit is contained in:
Valere
2025-02-28 12:04:49 +01:00
parent 4701e413fd
commit f8a5de604f
6 changed files with 7 additions and 9 deletions

View File

@@ -15,7 +15,7 @@ import {
import type { ComponentType, FC, ReactNode, SVGAttributes } from "react";
import { ErrorView } from "./ErrorView";
import { type ElementCallError, ErrorCategory } from "./utils/ec-errors.ts";
import { type ElementCallError, ErrorCategory } from "./utils/errors.ts";
/**
* An error consisting of a terse message to be logged to the console and a
@@ -96,9 +96,7 @@ const GenericECError: FC<{ error: ElementCallError }> = ({
return (
<ErrorView Icon={icon} title={title}>
<p>
{error.localisedMessage ? (
error.localisedMessage
) : (
{error.localisedMessage ?? (
<Trans
i18nKey="error.unexpected_ec_error"
components={[<b />, <code />]}