removing unused function because @linaria fails with unrelated error: TextEncoder is not defined in taler-util/lib/whatwg-url.js

This commit is contained in:
Sebastian 2023-09-08 18:12:34 -03:00
parent b784144edf
commit df7ab5b5dc
No known key found for this signature in database
GPG Key ID: 173909D1A5F66069

View File

@ -1073,126 +1073,126 @@ export function MerchantDetails({
); );
} }
function DeliveryDetails({ // function DeliveryDetails({
date, // date,
location, // location,
}: { // }: {
date: TalerProtocolTimestamp | undefined; // date: TalerProtocolTimestamp | undefined;
location: Location | undefined; // location: Location | undefined;
}): VNode { // }): VNode {
const { i18n } = useTranslationContext(); // const { i18n } = useTranslationContext();
return ( // return (
<PurchaseDetailsTable> // <PurchaseDetailsTable>
{location && ( // {location && (
<Fragment> // <Fragment>
{location.country && ( // {location.country && (
<tr> // <tr>
<td> // <td>
<i18n.Translate>Country</i18n.Translate> // <i18n.Translate>Country</i18n.Translate>
</td> // </td>
<td>{location.country}</td> // <td>{location.country}</td>
</tr> // </tr>
)} // )}
{location.address_lines && ( // {location.address_lines && (
<tr> // <tr>
<td> // <td>
<i18n.Translate>Address lines</i18n.Translate> // <i18n.Translate>Address lines</i18n.Translate>
</td> // </td>
<td>{location.address_lines}</td> // <td>{location.address_lines}</td>
</tr> // </tr>
)} // )}
{location.building_number && ( // {location.building_number && (
<tr> // <tr>
<td> // <td>
<i18n.Translate>Building number</i18n.Translate> // <i18n.Translate>Building number</i18n.Translate>
</td> // </td>
<td>{location.building_number}</td> // <td>{location.building_number}</td>
</tr> // </tr>
)} // )}
{location.building_name && ( // {location.building_name && (
<tr> // <tr>
<td> // <td>
<i18n.Translate>Building name</i18n.Translate> // <i18n.Translate>Building name</i18n.Translate>
</td> // </td>
<td>{location.building_name}</td> // <td>{location.building_name}</td>
</tr> // </tr>
)} // )}
{location.street && ( // {location.street && (
<tr> // <tr>
<td> // <td>
<i18n.Translate>Street</i18n.Translate> // <i18n.Translate>Street</i18n.Translate>
</td> // </td>
<td>{location.street}</td> // <td>{location.street}</td>
</tr> // </tr>
)} // )}
{location.post_code && ( // {location.post_code && (
<tr> // <tr>
<td> // <td>
<i18n.Translate>Post code</i18n.Translate> // <i18n.Translate>Post code</i18n.Translate>
</td> // </td>
<td>{location.post_code}</td> // <td>{location.post_code}</td>
</tr> // </tr>
)} // )}
{location.town_location && ( // {location.town_location && (
<tr> // <tr>
<td> // <td>
<i18n.Translate>Town location</i18n.Translate> // <i18n.Translate>Town location</i18n.Translate>
</td> // </td>
<td>{location.town_location}</td> // <td>{location.town_location}</td>
</tr> // </tr>
)} // )}
{location.town && ( // {location.town && (
<tr> // <tr>
<td> // <td>
<i18n.Translate>Town</i18n.Translate> // <i18n.Translate>Town</i18n.Translate>
</td> // </td>
<td>{location.town}</td> // <td>{location.town}</td>
</tr> // </tr>
)} // )}
{location.district && ( // {location.district && (
<tr> // <tr>
<td> // <td>
<i18n.Translate>District</i18n.Translate> // <i18n.Translate>District</i18n.Translate>
</td> // </td>
<td>{location.district}</td> // <td>{location.district}</td>
</tr> // </tr>
)} // )}
{location.country_subdivision && ( // {location.country_subdivision && (
<tr> // <tr>
<td> // <td>
<i18n.Translate>Country subdivision</i18n.Translate> // <i18n.Translate>Country subdivision</i18n.Translate>
</td> // </td>
<td>{location.country_subdivision}</td> // <td>{location.country_subdivision}</td>
</tr> // </tr>
)} // )}
</Fragment> // </Fragment>
)} // )}
{!location || !date ? undefined : ( // {!location || !date ? undefined : (
<tr> // <tr>
<td colSpan={2}> // <td colSpan={2}>
<hr /> // <hr />
</td> // </td>
</tr> // </tr>
)} // )}
{date && ( // {date && (
<Fragment> // <Fragment>
<tr> // <tr>
<td> // <td>
<i18n.Translate>Date</i18n.Translate> // <i18n.Translate>Date</i18n.Translate>
</td> // </td>
<td> // <td>
<Time // <Time
timestamp={AbsoluteTime.fromProtocolTimestamp(date)} // timestamp={AbsoluteTime.fromProtocolTimestamp(date)}
format="dd MMMM yyyy, HH:mm" // format="dd MMMM yyyy, HH:mm"
/> // />
</td> // </td>
</tr> // </tr>
</Fragment> // </Fragment>
)} // )}
</PurchaseDetailsTable> // </PurchaseDetailsTable>
); // );
} // }
export function ExchangeDetails({ exchange }: { exchange: string }): VNode { export function ExchangeDetails({ exchange }: { exchange: string }): VNode {
return ( return (