This commit is contained in:
Pig Fang 2020-03-29 10:16:06 +08:00
parent 1c97734bf6
commit 6c4f5d61f4

View File

@ -85,15 +85,22 @@ const Translations: React.FC = () => {
</tr>
</thead>
<tbody>
{lines.length === 0 ? (
{isLoading ? (
<tr>
<td className="text-center" colSpan={4}>
{isLoading ? <Loading /> : 'Nothing here.'}
<Loading />
</td>
</tr>
) : lines.length === 0 ? (
<tr>
<td className="text-center" colSpan={4}>
Nothing here.
</td>
</tr>
) : (
lines.map((line, i) => (
<Row
key={line.id}
line={line}
onEdit={(line) => handleEdit(line, i)}
onRemove={handleRemove}