1
0
mirror of https://github.com/NginxProxyManager/nginx-proxy-manager.git synced 2025-11-05 15:30:37 +03:00

Wrap intl in span identifying translation

This commit is contained in:
Jamie Curnow
2025-10-02 23:06:51 +10:00
parent fcb08d3003
commit 227e818040
68 changed files with 1076 additions and 510 deletions

View File

@@ -1,6 +1,6 @@
import type { Table as ReactTable } from "@tanstack/react-table";
import { Button } from "src/components";
import { intl } from "src/locale";
import { T } from "src/locale";
interface Props {
tableInstance: ReactTable<any>;
@@ -13,13 +13,19 @@ export default function Empty({ tableInstance, onNewUser, isFiltered }: Props) {
<td colSpan={tableInstance.getVisibleFlatColumns().length}>
<div className="text-center my-4">
{isFiltered ? (
<h2>{intl.formatMessage({ id: "empty-search" })}</h2>
<h2>
<T id="empty-search" />
</h2>
) : (
<>
<h2>{intl.formatMessage({ id: "users.empty" })}</h2>
<p className="text-muted">{intl.formatMessage({ id: "empty-subtitle" })}</p>
<h2>
<T id="users.empty" />
</h2>
<p className="text-muted">
<T id="empty-subtitle" />
</p>
<Button className="btn-orange my-3" onClick={onNewUser}>
{intl.formatMessage({ id: "users.add" })}
<T id="users.add" />
</Button>
</>
)}