forked from Open-CT/openbrain
Improve i18n.
This commit is contained in:
parent
8ef53c3353
commit
8e436bebf5
|
@ -233,7 +233,7 @@ export function getTags(vectors) {
|
|||
vectors.forEach((vector, i) => {
|
||||
if (vector.data.length !== 0) {
|
||||
res.push(
|
||||
<Tooltip placement="top" title={JSON.stringify(vector.data)}>
|
||||
<Tooltip placement="top" title={getShortText(JSON.stringify(vector.data), 500)}>
|
||||
<Tag color={"success"}>
|
||||
{vector.name}
|
||||
</Tag>
|
||||
|
|
|
@ -2,6 +2,7 @@ import React from "react";
|
|||
import {DownOutlined, DeleteOutlined, UpOutlined} from '@ant-design/icons';
|
||||
import {Button, Col, Input, Row, Table, Tooltip} from 'antd';
|
||||
import * as Setting from "./Setting";
|
||||
import i18next from "i18next";
|
||||
|
||||
class VectorTable extends React.Component {
|
||||
constructor(props) {
|
||||
|
@ -61,16 +62,16 @@ class VectorTable extends React.Component {
|
|||
renderTable(table) {
|
||||
const columns = [
|
||||
{
|
||||
title: 'No.',
|
||||
title: i18next.t("general:No."),
|
||||
dataIndex: 'no',
|
||||
key: 'no',
|
||||
width: '30px',
|
||||
width: '60px',
|
||||
render: (text, record, index) => {
|
||||
return (index + 1);
|
||||
}
|
||||
},
|
||||
{
|
||||
title: 'Name',
|
||||
title: i18next.t("general:Name"),
|
||||
dataIndex: 'name',
|
||||
key: 'name',
|
||||
width: '200px',
|
||||
|
@ -83,7 +84,7 @@ class VectorTable extends React.Component {
|
|||
}
|
||||
},
|
||||
{
|
||||
title: 'Data',
|
||||
title: i18next.t("general:Data"),
|
||||
dataIndex: 'data',
|
||||
key: 'data',
|
||||
// width: '300px',
|
||||
|
@ -96,7 +97,7 @@ class VectorTable extends React.Component {
|
|||
}
|
||||
},
|
||||
{
|
||||
title: 'action',
|
||||
title: i18next.t("general:Action"),
|
||||
key: 'action',
|
||||
width: '100px',
|
||||
render: (text, record, index) => {
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
"general": {
|
||||
"Action": "Action",
|
||||
"Add": "Add",
|
||||
"Data": "Data",
|
||||
"Datasets": "Datasets",
|
||||
"Delete": "Delete",
|
||||
"Display name": "Display name",
|
||||
|
@ -22,6 +23,7 @@
|
|||
"Home": "Home",
|
||||
"Loading...": "Loading...",
|
||||
"Name": "Name",
|
||||
"No.": "No.",
|
||||
"Preview": "Preview",
|
||||
"Save": "Save",
|
||||
"URL": "URL",
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
"general": {
|
||||
"Action": "操作",
|
||||
"Add": "添加",
|
||||
"Data": "数据",
|
||||
"Datasets": "数据集",
|
||||
"Delete": "删除",
|
||||
"Display name": "显示名称",
|
||||
|
@ -22,9 +23,10 @@
|
|||
"Home": "首页",
|
||||
"Loading...": "加载中...",
|
||||
"Name": "名称",
|
||||
"No.": "序号",
|
||||
"Preview": "预览",
|
||||
"Save": "保存",
|
||||
"URL": "URL",
|
||||
"URL": "链接",
|
||||
"Vectorsets": "向量集"
|
||||
},
|
||||
"vectorset": {
|
||||
|
|
Loading…
Reference in New Issue