Commit a7962d4d authored by Thiago Broges's avatar Thiago Broges

Translate most texts to American English

parent c86c321c
......@@ -41,24 +41,24 @@ const covers = [
'https://gw.alipayobjects.com/zos/rmsportal/gLaIAoVWTtLbBWZNYEMg.png',
];
const desc = [
'那是一种内在的东西, 他们到达不了,也无法触及的',
'希望是一个好东西,也许是最好的,好东西是不会消亡的',
'生命就像一盒巧克力,结果往往出人意料',
'城镇中有那么多的酒馆,她却偏偏走进了我的酒馆',
'那时候我只会想自己想要什么,从不想自己拥有什么',
'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent bibendum condimentum cursus.',
'Praesent rhoncus mi metus. Aliquam sollicitudin felis sagittis bibendum luctus.',
'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent bibendum condimentum cursus.',
'Praesent rhoncus mi metus. Aliquam sollicitudin felis sagittis bibendum luctus.',
'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent bibendum condimentum cursus.',
];
const user = [
'付小小',
'曲丽丽',
'林东东',
'周星星',
'吴加好',
'朱偏右',
'鱼酱',
'乐哥',
'谭小仪',
'仲尼',
'Fu Xiaoxiao',
'John Doe',
'Lin Dongdong',
'Zhou Xingxing',
'Wu Jiahao',
'Zhu Zuoyou',
'Fish Sauce', //鱼酱
'Brother', //乐哥
'Tan Xiaoyi',
'Zhong Ni', //Johnny?
];
export function fakeList(count) {
......@@ -78,26 +78,26 @@ export function fakeList(count) {
createdAt: new Date(new Date().getTime() - 1000 * 60 * 60 * 2 * i),
subDescription: desc[i % 5],
description:
'在中台产品的研发过程中,会出现不同的设计规范和实现方式,但其中往往存在很多类似的页面和组件,这些类似的组件会被抽离成一套标准规范。',
'In the process of R&D of the middle stage products, there will be different design specifications and implementation methods, but often there are many similar pages and components, and these similar components will be separated into a set of standard specifications.',
activeUser: Math.ceil(Math.random() * 100000) + 100000,
newUser: Math.ceil(Math.random() * 1000) + 1000,
star: Math.ceil(Math.random() * 100) + 100,
like: Math.ceil(Math.random() * 100) + 100,
message: Math.ceil(Math.random() * 10) + 10,
content:
'段落示意:蚂蚁金服设计平台 ant.design,用最小的工作量,无缝接入蚂蚁金服生态,提供跨越设计与开发的体验解决方案。蚂蚁金服设计平台 ant.design,用最小的工作量,无缝接入蚂蚁金服生态,提供跨越设计与开发的体验解决方案。',
'In the paragraph: ant.design, Ant Financial Design Platform, seamlessly accesses the ecology of Ant Financial with minimal workload, providing experience solutions that span design and development. The ant gold design platform ant.design, with the minimal workload, seamlessly accesses the ant gold suit ecology, providing experience solutions that span design and development.',
members: [
{
avatar: 'https://gw.alipayobjects.com/zos/rmsportal/ZiESqWwCXBRQoaPONSJe.png',
name: '曲丽丽',
name: 'John Doe',
},
{
avatar: 'https://gw.alipayobjects.com/zos/rmsportal/tBOxZPlITHqwlGjsJWaF.png',
name: '王昭君',
name: 'Wang Zhaojun',
},
{
avatar: 'https://gw.alipayobjects.com/zos/rmsportal/sBxjgqiuHMGRkIjqlQCd.png',
name: '董娜娜',
name: 'Dong Nana',
},
],
});
......@@ -130,9 +130,9 @@ export const getNotice = [
id: 'xxx1',
title: titles[0],
logo: avatars[0],
description: '那是一种内在的东西,他们到达不了,也无法触及的',
description: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent bibendum condimentum cursus.',
updatedAt: new Date(),
member: '科学搬砖组',
member: 'The Scientist',
href: '',
memberLink: '',
},
......@@ -140,9 +140,9 @@ export const getNotice = [
id: 'xxx2',
title: titles[1],
logo: avatars[1],
description: '希望是一个好东西,也许是最好的,好东西是不会消亡的',
description: 'Praesent rhoncus mi metus. Aliquam sollicitudin felis sagittis bibendum luctus.',
updatedAt: new Date('2017-07-24'),
member: '全组都是吴彦祖',
member: 'Daniel Wu',
href: '',
memberLink: '',
},
......@@ -150,9 +150,9 @@ export const getNotice = [
id: 'xxx3',
title: titles[2],
logo: avatars[2],
description: '城镇中有那么多的酒馆,她却偏偏走进了我的酒馆',
description: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent bibendum condimentum cursus.',
updatedAt: new Date(),
member: '中二少女团',
member: 'Secondary Girl',
href: '',
memberLink: '',
},
......@@ -160,9 +160,9 @@ export const getNotice = [
id: 'xxx4',
title: titles[3],
logo: avatars[3],
description: '那时候我只会想自己想要什么,从不想自己拥有什么',
description: 'Praesent rhoncus mi metus. Aliquam sollicitudin felis sagittis bibendum luctus.',
updatedAt: new Date('2017-07-23'),
member: '程序员日常',
member: 'Everyday Programmer',
href: '',
memberLink: '',
},
......@@ -170,9 +170,9 @@ export const getNotice = [
id: 'xxx5',
title: titles[4],
logo: avatars[4],
description: '凛冬将至',
description: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent bibendum condimentum cursus.',
updatedAt: new Date('2017-07-23'),
member: '高逼格设计天团',
member: 'Design Missioner',
href: '',
memberLink: '',
},
......@@ -180,9 +180,9 @@ export const getNotice = [
id: 'xxx6',
title: titles[5],
logo: avatars[5],
description: '生命就像一盒巧克力,结果往往出人意料',
description: 'Praesent rhoncus mi metus. Aliquam sollicitudin felis sagittis bibendum luctus.',
updatedAt: new Date('2017-07-23'),
member: '骗你来学计算机',
member: 'Computer Learner',
href: '',
memberLink: '',
},
......@@ -193,99 +193,99 @@ export const getActivities = [
id: 'trend-1',
updatedAt: new Date(),
user: {
name: '曲丽丽',
name: 'John Doe',
avatar: avatars2[0],
},
group: {
name: '高逼格设计天团',
name: 'Design Missioner',
link: 'http://github.com/',
},
project: {
name: '六月迭代',
name: 'June Iteration',
link: 'http://github.com/',
},
template: '在 @{group} 新建项目 @{project}',
template: 'In @{group} New Project @{project}',
},
{
id: 'trend-2',
updatedAt: new Date(),
user: {
name: '付小小',
name: 'Fu Xiaoxiao',
avatar: avatars2[1],
},
group: {
name: '高逼格设计天团',
name: 'Design Missioner',
link: 'http://github.com/',
},
project: {
name: '六月迭代',
name: 'June Iteration',
link: 'http://github.com/',
},
template: '在 @{group} 新建项目 @{project}',
template: 'In @{group} New Project @{project}',
},
{
id: 'trend-3',
updatedAt: new Date(),
user: {
name: '林东东',
name: 'Lin Dongdong',
avatar: avatars2[2],
},
group: {
name: '中二少女团',
name: 'Secondary Girl',
link: 'http://github.com/',
},
project: {
name: '六月迭代',
name: 'June Iteration',
link: 'http://github.com/',
},
template: '在 @{group} 新建项目 @{project}',
template: 'In @{group} New Project @{project}',
},
{
id: 'trend-4',
updatedAt: new Date(),
user: {
name: '周星星',
name: 'Zhou Xingxing',
avatar: avatars2[4],
},
project: {
name: '5 月日常迭代',
name: '5 Daily Iteration of the Month',
link: 'http://github.com/',
},
template: '将 @{project} 更新至已发布状态',
template: 'Will @{project} Release status update',
},
{
id: 'trend-5',
updatedAt: new Date(),
user: {
name: '朱偏右',
name: 'Zhu Zuoyou',
avatar: avatars2[3],
},
project: {
name: '工程效能',
name: 'Project performance',
link: 'http://github.com/',
},
comment: {
name: '留言',
name: 'Comments',
link: 'http://github.com/',
},
template: '在 @{project} 发布了 @{comment}',
template: 'In @{project} Announced @{comment}',
},
{
id: 'trend-6',
updatedAt: new Date(),
user: {
name: '乐哥',
name: 'Brother',
avatar: avatars2[5],
},
group: {
name: '程序员日常',
name: 'Everyday Programmer',
link: 'http://github.com/',
},
project: {
name: '品牌迭代',
name: 'Brand iteration',
link: 'http://github.com/',
},
template: '在 @{group} 新建项目 @{project}',
template: 'In @{group} New Project @{project}',
},
];
......
......@@ -24,7 +24,7 @@ for (let i = 0; i < fakeY2.length; i += 1) {
const salesData = [];
for (let i = 0; i < 12; i += 1) {
salesData.push({
x: `${i + 1}`,
x: `${i + 1} Month`,
y: Math.floor(Math.random() * 1000) + 200,
});
}
......@@ -32,7 +32,7 @@ const searchData = [];
for (let i = 0; i < 50; i += 1) {
searchData.push({
index: i + 1,
keyword: `搜索关键词-${i}`,
keyword: ` Search Keyword-${i}`,
count: Math.floor(Math.random() * 1000),
range: Math.floor(Math.random() * 100),
status: Math.floor((Math.random() * 10) % 2),
......@@ -40,77 +40,77 @@ for (let i = 0; i < 50; i += 1) {
}
const salesTypeData = [
{
x: '家用电器',
x: 'Household appliances',
y: 4544,
},
{
x: '食用酒水',
x: 'Drink Wine',
y: 3321,
},
{
x: '个护健康',
x: 'Health Care',
y: 3113,
},
{
x: '服饰箱包',
x: 'Clothing Bags',
y: 2341,
},
{
x: '母婴产品',
x: 'Maternal and child products',
y: 1231,
},
{
x: '其他',
x: 'Others',
y: 1231,
},
];
const salesTypeDataOnline = [
{
x: '家用电器',
x: 'Household appliances',
y: 244,
},
{
x: '食用酒水',
x: 'Drink Wine',
y: 321,
},
{
x: '个护健康',
x: 'Health Care',
y: 311,
},
{
x: '服饰箱包',
x: 'Clothing Bags',
y: 41,
},
{
x: '母婴产品',
x: 'Maternal and child products',
y: 121,
},
{
x: '其他',
x: 'Others',
y: 111,
},
];
const salesTypeDataOffline = [
{
x: '家用电器',
x: 'Household appliances',
y: 99,
},
{
x: '个护健康',
x: 'Health Care',
y: 188,
},
{
x: '服饰箱包',
x: 'Clothing Bags',
y: 344,
},
{
x: '母婴产品',
x: 'Maternal and child products',
y: 255,
},
{
x: '其他',
x: 'Others',
y: 65,
},
];
......@@ -118,7 +118,7 @@ const salesTypeDataOffline = [
const offlineData = [];
for (let i = 0; i < 10; i += 1) {
offlineData.push({
name: `门店${i}`,
name: `Store ${i}`,
cvr: Math.ceil(Math.random() * 9) / 10,
});
}
......@@ -133,7 +133,7 @@ for (let i = 0; i < 20; i += 1) {
const radarOriginData = [
{
name: '个人',
name: 'Personal',
ref: 10,
koubei: 8,
output: 4,
......@@ -141,7 +141,7 @@ const radarOriginData = [
hot: 7,
},
{
name: '团队',
name: 'Team',
ref: 3,
koubei: 9,
output: 6,
......@@ -149,7 +149,7 @@ const radarOriginData = [
hot: 1,
},
{
name: '部门',
name: 'Department',
ref: 4,
koubei: 1,
output: 6,
......@@ -161,11 +161,11 @@ const radarOriginData = [
//
const radarData = [];
const radarTitleMap = {
ref: '引用',
koubei: '口碑',
output: '产量',
contribute: '贡献',
hot: '热度',
ref: 'Reference',
koubei: 'Opinion',
output: 'Yield',
contribute: 'Contribution',
hot: 'Heat',
};
radarOriginData.forEach(item => {
Object.keys(item).forEach(key => {
......
......@@ -3,94 +3,94 @@ export const getNotices = (req, res) => {
{
id: '000000001',
avatar: 'https://gw.alipayobjects.com/zos/rmsportal/ThXAXghbEsBCCSDihZxY.png',
title: '你收到了 14 份新周报',
title: 'You have received 14 new weekly reports',
datetime: '2017-08-09',
type: '通知',
type: 'Notice',
},
{
id: '000000002',
avatar: 'https://gw.alipayobjects.com/zos/rmsportal/OKJXDXrmkNshAMvwtvhu.png',
title: '你推荐的 曲妮妮 已通过第三轮面试',
title: 'Your recommended Mr. Doe has passed the third round of interview',
datetime: '2017-08-08',
type: '通知',
type: 'Notice',
},
{
id: '000000003',
avatar: 'https://gw.alipayobjects.com/zos/rmsportal/kISTdvpyTAhtGxpovNWd.png',
title: '这种模板可以区分多种通知类型',
title: 'This template can distinguish between multiple notification types',
datetime: '2017-08-07',
read: true,
type: '通知',
type: 'Notice',
},
{
id: '000000004',
avatar: 'https://gw.alipayobjects.com/zos/rmsportal/GvqBnKhFgObvnSGkDsje.png',
title: '左侧图标用于区分不同的类型',
title: 'The left icon is used to distinguish between different types',
datetime: '2017-08-07',
type: '通知',
type: 'Notice',
},
{
id: '000000005',
avatar: 'https://gw.alipayobjects.com/zos/rmsportal/ThXAXghbEsBCCSDihZxY.png',
title: '内容不要超过两行字,超出时自动截断',
title: 'Do not exceed two lines of text and automatically truncate when exceeded',
datetime: '2017-08-07',
type: '通知',
type: 'Notice',
},
{
id: '000000006',
avatar: 'https://gw.alipayobjects.com/zos/rmsportal/fcHMVNCjPOsbUGdEduuv.jpeg',
title: '曲丽丽 评论了你',
description: '描述信息描述信息描述信息',
title: 'John Doe commented on you',
description: 'Description Information Description Information Description Information',
datetime: '2017-08-07',
type: '消息',
type: 'News',
},
{
id: '000000007',
avatar: 'https://gw.alipayobjects.com/zos/rmsportal/fcHMVNCjPOsbUGdEduuv.jpeg',
title: '朱偏右 回复了你',
description: '这种模板用于提醒谁与你发生了互动,左侧放『谁』的头像',
title: 'Zhu right back to you',
description: 'This template is used to remind who has interacted with you.',
datetime: '2017-08-07',
type: '消息',
type: 'News',
},
{
id: '000000008',
avatar: 'https://gw.alipayobjects.com/zos/rmsportal/fcHMVNCjPOsbUGdEduuv.jpeg',
title: '标题',
description: '这种模板用于提醒谁与你发生了互动,左侧放『谁』的头像',
title: 'Title',
description: 'This template is used to remind who has interacted with you.',
datetime: '2017-08-07',
type: '消息',
type: 'News',
},
{
id: '000000009',
title: '任务名称',
description: '任务需要在 2017-01-12 20:00 前启动',
extra: '未开始',
title: 'Mission Name',
description: 'The task needs to start before 2017-01-12 20:00',
extra: 'Has Not Started',
status: 'todo',
type: '待办',
type: 'Upcoming',
},
{
id: '000000010',
title: '第三方紧急代码变更',
description: '冠霖提交于 2017-01-06,需在 2017-01-07 前完成代码变更任务',
extra: '马上到期',
title: 'Third-party emergency code changes',
description: 'Guan Lin submitted on 2017-01-06, need to complete the code change task before 2017-01-07',
extra: 'Expire Soon',
status: 'urgent',
type: '待办',
type: 'Upcoming',
},
{
id: '000000011',
title: '信息安全考试',
description: '指派竹尔于 2017-01-09 前完成更新并发布',
extra: '已耗时 8 天',
title: 'Information Security Test',
description: 'Assign Zhuer to update and publish before 2017-01-09',
extra: 'It has taken 8 days',
status: 'doing',
type: '待办',
type: 'Upcoming',
},
{
id: '000000012',
title: 'ABCD 版本发布',
description: '冠霖提交于 2017-01-06,需在 2017-01-07 前完成代码变更任务',
extra: '进行中',
title: 'ABCD Released',
description: 'Guan Lin submitted on 2017-01-06, need to complete the code change task before 2017-01-07',
extra: 'Processing',
status: 'processing',
type: '待办',
type: 'Upcoming',
},
]);
};
......
const basicGoods = [
{
id: '1234561',
name: '矿泉水 550ml',
name: 'Mineral Water 550ml',
barcode: '12421432143214321',
price: '2.00',
num: '1',
......@@ -9,7 +9,7 @@ const basicGoods = [
},
{
id: '1234562',
name: '凉茶 300ml',
name: 'Herbal Tea 300ml',
barcode: '12421432143214322',
price: '3.00',
num: '2',
......@@ -17,7 +17,7 @@ const basicGoods = [
},
{
id: '1234563',
name: '好吃的薯片',
name: 'Delicious Potato Chips',
barcode: '12421432143214323',
price: '7.00',
num: '4',
......@@ -25,7 +25,7 @@ const basicGoods = [
},
{
id: '1234564',
name: '特别好吃的蛋卷',
name: 'Especially Delicious Egg Rolls',
barcode: '12421432143214324',
price: '8.50',
num: '3',
......@@ -37,41 +37,41 @@ const basicProgress = [
{
key: '1',
time: '2017-10-01 14:10',
rate: '联系客户',
rate: 'Contact Clients',
status: 'processing',
operator: '取货员 ID1234',
operator: 'Receiver ID1234',
cost: '5mins',
},
{
key: '2',
time: '2017-10-01 14:05',
rate: '取货员出发',
rate: 'Departure from the Clark',
status: 'success',
operator: '取货员 ID1234',
operator: 'Receiver ID1234',
cost: '1h',
},
{
key: '3',
time: '2017-10-01 13:05',
rate: '取货员接单',
rate: 'Receiver Orders',
status: 'success',
operator: '取货员 ID1234',
operator: 'Receiver ID1234',
cost: '5mins',
},
{
key: '4',
time: '2017-10-01 13:00',
rate: '申请审批通过',
rate: 'Apply for Approval',
status: 'success',
operator: '系统',
operator: 'System',
cost: '1h',
},
{
key: '5',
time: '2017-10-01 12:00',
rate: '发起退货申请',
rate: 'Initiate a Return Request',
status: 'success',
operator: '用户',
operator: 'User',
cost: '5mins',
},
];
......@@ -79,40 +79,40 @@ const basicProgress = [
const advancedOperation1 = [
{
key: 'op1',
type: '订购关系生效',
name: '曲丽丽',
type: '订购关系生效', //Subscription relationship takes effect???
name: 'John Doe',
status: 'agree',
updatedAt: '2017-10-03 19:23:12',
memo: '-',
},
{
key: 'op2',
type: '财务复审',
name: '付小小',
type: 'Financial Review',
name: 'Fu Xiaoxiao',
status: 'reject',
updatedAt: '2017-10-03 19:23:12',
memo: '不通过原因',
memo: 'Do not pass the reason',
},
{
key: 'op3',
type: '部门初审',
name: '周毛毛',
type: 'Department First Review',
name: 'Zhou Maomao',
status: 'agree',
updatedAt: '2017-10-03 19:23:12',
memo: '-',
},
{
key: 'op4',
type: '提交订单',
name: '林东东',
type: 'Submit Order',
name: 'Ling Dongdong',
status: 'agree',
updatedAt: '2017-10-03 19:23:12',
memo: '很棒',
memo: 'Great',
},
{
key: 'op5',
type: '创建订单',
name: '汗牙牙',
type: 'Create Order',
name: 'Han Yaya',
status: 'agree',
updatedAt: '2017-10-03 19:23:12',
memo: '-',
......@@ -122,8 +122,8 @@ const advancedOperation1 = [
const advancedOperation2 = [
{
key: 'op1',
type: '订购关系生效',
name: '曲丽丽',
type: '订购关系生效',//Subscription relationship takes effect???
name: 'John Doe',
status: 'agree',
updatedAt: '2017-10-03 19:23:12',
memo: '-',
......@@ -133,8 +133,8 @@ const advancedOperation2 = [
const advancedOperation3 = [
{
key: 'op1',
type: '创建订单',
name: '汗牙牙',
type: 'Create Order',
name: 'Han Yaya',
status: 'agree',
updatedAt: '2017-10-03 19:23:12',
memo: '-',
......
......@@ -12,9 +12,9 @@ for (let i = 0; i < 46; i += 1) {
'https://gw.alipayobjects.com/zos/rmsportal/udxAbMEhpwthVVcjLXik.png',
][i % 2],
no: `TradeCode ${i}`,
title: `一个任务名称 ${i}`,
owner: '曲丽丽',
description: '这是一段描述',
title: `Task Name ${i}`,
owner: 'John Doe',
description: 'This is a description',
callNo: Math.floor(Math.random() * 1000),
status: Math.floor(Math.random() * 10) % 4,
updatedAt: new Date(`2017-07-${Math.floor(i / 2) + 1}`),
......
......@@ -7,15 +7,15 @@ const menuData = [
path: 'dashboard',
children: [
{
name: '分析页',
name: 'analysis',
path: 'analysis',
},
{
name: '监控页',
name: 'monitor',
path: 'monitor',
},
{
name: '工作台',
name: 'workplace',
path: 'workplace',
// hideInBreadcrumb: true,
// hideInMenu: true,
......@@ -23,56 +23,56 @@ const menuData = [
],
},
{
name: '表单页',
name: 'form',
icon: 'form',
path: 'form',
children: [
{
name: '基础表单',
name: 'basic-form',
path: 'basic-form',
},
{
name: '分步表单',
name: 'step-form',
path: 'step-form',
},
{
name: '高级表单',
name: 'advanced-form',
authority: 'admin',
path: 'advanced-form',
},
],
},
{
name: '列表页',
name: 'list',
icon: 'table',
path: 'list',
children: [
{
name: '查询表格',
name: 'table-list',
path: 'table-list',
},
{
name: '标准列表',
name: 'basic-list',
path: 'basic-list',
},
{
name: '卡片列表',
name: 'card-list',
path: 'card-list',
},
{
name: '搜索列表',
name: 'search',
path: 'search',
children: [
{
name: '搜索列表(文章)',
name: 'articles',
path: 'articles',
},
{
name: '搜索列表(项目)',
name: 'projects',
path: 'projects',
},
{
name: '搜索列表(应用)',
name: 'applications',
path: 'applications',
},
],
......@@ -80,38 +80,38 @@ const menuData = [
],
},
{
name: '详情页',
name: 'profile',
icon: 'profile',
path: 'profile',
children: [
{
name: '基础详情页',
name: 'basic',
path: 'basic',
},
{
name: '高级详情页',
name: 'advanced',
path: 'advanced',
authority: 'admin',
},
],
},
{
name: '结果页',
name: 'result',
icon: 'check-circle-o',
path: 'result',
children: [
{
name: '成功',
name: 'success',
path: 'success',
},
{
name: '失败',
name: 'fail',
path: 'fail',
},
],
},
{
name: '异常页',
name: 'exception',
icon: 'warning',
path: 'exception',
children: [
......@@ -128,28 +128,28 @@ const menuData = [
path: '500',
},
{
name: '触发异常',
name: 'tigger',
path: 'trigger',
hideInMenu: true,
},
],
},
{
name: '账户',
name: 'user',
icon: 'user',
path: 'user',
authority: 'guest',
children: [
{
name: '登录',
name: 'login',
path: 'login',
},
{
name: '注册',
name: 'register',
path: 'register',
},
{
name: '注册结果',
name: 'register-result',
path: 'register-result',
},
],
......
......@@ -42,7 +42,7 @@ export default class ActiveChart extends Component {
return (
<div className={styles.activeChart}>
<NumberInfo subTitle="目标评估" total="有望达到预期" />
<NumberInfo subTitle="Target Assessment" total="Expected to reach expectations" />
<div style={{ marginTop: 32 }}>
<MiniArea
animate={false}
......@@ -65,8 +65,8 @@ export default class ActiveChart extends Component {
</div>
{activeData && (
<div className={styles.activeChartGrid}>
<p>{[...activeData].sort()[activeData.length - 1].y + 200} 亿元</p>
<p>{[...activeData].sort()[Math.floor(activeData.length / 2)].y} 亿元</p>
<p>{[...activeData].sort()[activeData.length - 1].y + 200} Billion</p>
<p>{[...activeData].sort()[Math.floor(activeData.length / 2)].y} Billion</p>
</div>
)}
{activeData && (
......
......@@ -7,7 +7,7 @@ import styles from './index.less';
const renderTotal = total => {
let totalDom;
switch (typeof total) {
case 'undefined':
case undefined:
totalDom = null;
break;
case 'function':
......
......@@ -7,13 +7,13 @@ const { Arc, Html, Line } = Guide;
const defaultFormatter = val => {
switch (val) {
case '2':
return '';
return 'Poor';
case '4':
return '';
return 'Medium';
case '6':
return '';
return 'Good';
case '8':
return '';
return 'Excellent';
default:
return '';
}
......
......@@ -77,7 +77,7 @@ class TagCloud extends Component {
@Bind()
@Debounce(500)
renderChart(nextProps) {
renderChart = nextProps => {
// const colors = ['#1890FF', '#41D9C7', '#2FC25B', '#FACC14', '#9AE65C'];
const { data, height } = nextProps || this.props;
......@@ -129,7 +129,7 @@ class TagCloud extends Component {
} else {
onload();
}
}
};
render() {
const { className, height } = this.props;
......
......@@ -71,8 +71,8 @@ export default class TimelineChart extends React.Component {
const timeScale = {
type: 'time',
tickInterval: 60 * 60 * 1000,
mask: 'HH:mm',
tickCount: 10,
mask: 'HH:MM',
range: [0, 1],
};
......
......@@ -36,8 +36,8 @@ const salesPieData = [
ReactDOM.render(
<Pie
hasLegend
title="销售额"
subTitle="销售额"
title="Sale"
subTitle="Sale"
total={() => (
<span
dangerouslySetInnerHTML={{
......
......@@ -13,7 +13,7 @@ import WaterWave from './WaterWave';
import TagCloud from './TagCloud';
import TimelineChart from './TimelineChart';
const yuan = val => `&yen; ${numeral(val).format('0,0')}`;
const yuan = val => `$ ${numeral(val).format('0,0')}`;
export {
yuan,
......
---
order: 0
title:
zh-CN: 基本
en-US: Basic
title: Basic
---
## zh-CN
基本描述列表。
## en-US
Basic DescriptionList.
````jsx
import DescriptionList from 'ant-design-pro/lib/DescriptionList';
......
---
order: 1
title:
zh-CN: 垂直型
en-US: Vertical
title: Vertical
---
## zh-CN
垂直布局。
## en-US
Vertical layout.
````jsx
import DescriptionList from 'ant-design-pro/lib/DescriptionList';
......
---
title:
en-US: DescriptionList
zh-CN: DescriptionList
subtitle: 描述列表
cols: 1
order: 4
---
成组展示多个只读字段,常见于详情页的信息展示。
## API
### DescriptionList
| 参数 | 说明 | 类型 | 默认值 |
|----------|------------------------------------------|-------------|-------|
| layout | 布局方式 | Enum{'horizontal', 'vertical'} | 'horizontal' |
| col | 指定信息最多分几列展示,最终一行几列由 col 配置结合[响应式规则](/components/DescriptionList#响应式规则)决定 | number(0 < col <= 4) | 3 |
| title | 列表标题 | ReactNode | - |
| gutter | 列表项间距,单位为 `px` | number | 32 |
| size | 列表型号,可以设置为 `large` `small` | Enum{'large', 'small'} | - |
#### 响应式规则
| 窗口宽度 | 展示列数 |
|---------------------|---------------------------------------------|
| `≥768px` | `col` |
| `≥576px` | `col < 2 ? col : 2` |
| `<576px` | `1` |
### DescriptionList.Description
| 参数 | 说明 | 类型 | 默认值 |
|----------|------------------------------------------|-------------|-------|
| term | 列表项标题 | ReactNode | - |
......@@ -35,7 +35,7 @@ class EditableLinkGroup extends PureComponent {
)}
{
<Button size="small" type="primary" ghost onClick={onAdd} icon="plus">
添加
Add
</Button>
}
</div>
......
---
order: 1
title:
zh-CN: 按照行数省略
en-US: Truncate according to the number of rows
title: 按照行数省略
---
## zh-CN
通过设置 `lines` 属性指定最大行数,如果超过这个行数的文本会自动截取。但是在这种模式下所有 `children` 将会被转换成纯文本。
并且注意在这种模式下,外容器需要有指定的宽度(或设置自身宽度)。
## en-US
`lines` attribute specifies the maximum number of rows where the text will automatically be truncated when exceeded. In this mode, all children will be converted to plain text.
Also note that, in this mode, the outer container needs to have a specified width (or set its own width).
````jsx
import Ellipsis from 'ant-design-pro/lib/Ellipsis';
......
---
order: 0
title:
zh-CN: 按照字符数省略
en-US: Truncate according to the number of character
title: 按照字符数省略
---
## zh-CN
通过设置 `length` 属性指定文本最长长度,如果超过这个长度会自动截取。
## en-US
`length` attribute specifies the maximum length where the text will automatically be truncated when exceeded.
````jsx
import Ellipsis from 'ant-design-pro/lib/Ellipsis';
......
---
title:
en-US: Ellipsis
zh-CN: Ellipsis
subtitle: 文本自动省略号
cols: 1
order: 10
---
文本过长自动处理省略号,支持按照文本长度和最大行数两种方式截取。
## API
参数 | 说明 | 类型 | 默认值
----|------|-----|------
tooltip | 移动到文本展示完整内容的提示 | boolean | -
length | 在按照长度截取下的文本最大字符数,超过则截取省略 | number | -
lines | 在按照行数截取下最大的行数,超过则截取省略 | number | `1`
---
order: 2
title:
zh-CN: 403
en-US: 403
title: 403
---
## zh-CN
403 页面,配合自定义操作。
## en-US
403 page with custom operations.
````jsx
import Exception from 'ant-design-pro/lib/Exception';
import { Button } from 'antd';
const actions = (
<div>
<Button type="primary">Home</Button>
<Button>Detail</Button>
<Button type="primary">回到首页</Button>
<Button>查看详情</Button>
</div>
);
ReactDOM.render(
......
---
order: 0
title:
zh-CN: 404
en-US: 404
title: 404
---
## zh-CN
404 页面。
## en-US
404 page.
````jsx
import Exception from 'ant-design-pro/lib/Exception';
......
---
order: 1
title:
zh-CN: 500
en-US: 500
title: 500
---
## zh-CN
500 页面。
## en-US
500 page.
````jsx
import Exception from 'ant-design-pro/lib/Exception';
......
......@@ -26,7 +26,7 @@ export default ({ className, linkElement = 'a', type, title, desc, img, actions,
to: '/',
href: '/',
},
<Button type="primary">返回首页</Button>
<Button type="primary">Return</Button>
)}
</div>
</div>
......
---
title:
en-US: Exception
zh-CN: Exception
subtitle: 异常
cols: 1
order: 5
---
异常页用于对页面特定的异常状态进行反馈。通常,它包含对错误状态的阐述,并向用户提供建议或操作,避免用户感到迷失和困惑。
## API
| 参数 | 说明 | 类型 | 默认值 |
|-------------|------------------------------------------|-------------|-------|
| type | 页面类型,若配置,则自带对应类型默认的 `title``desc``img`,此默认设置可以被 `title``desc``img` 覆盖 | Enum {'403', '404', '500'} | - |
| title | 标题 | ReactNode | - |
| desc | 补充描述 | ReactNode | - |
| img | 背景图片地址 | string | - |
| actions | 建议操作,配置此属性时默认的『返回首页』按钮不生效 | ReactNode | - |
| linkElement | 定义链接的元素,默认为 `a` | string\|ReactElement | - |
......@@ -2,17 +2,17 @@ const config = {
403: {
img: 'https://gw.alipayobjects.com/zos/rmsportal/wZcnGqRDyhPOEYFcZDnb.svg',
title: '403',
desc: '抱歉,你无权访问该页面',
desc: 'Sorry, you do not have permission to access this page.',
},
404: {
img: 'https://gw.alipayobjects.com/zos/rmsportal/KpnpchXsobRgLElEozzI.svg',
title: '404',
desc: '抱歉,你访问的页面不存在',
desc: 'Sorry, the page you visited does not exist.',
},
500: {
img: 'https://gw.alipayobjects.com/zos/rmsportal/RVRUAYdCGeYNBWoKiIwB.svg',
title: '500',
desc: '抱歉,服务器出错了',
desc: 'Sorry, the server has gone wrong.',
},
};
......
......@@ -69,17 +69,17 @@ export default class GlobalHeader extends PureComponent {
const menu = (
<Menu className={styles.menu} selectedKeys={[]} onClick={onMenuClick}>
<Menu.Item disabled>
<Icon type="user" />个人中心
<Icon type="user" />User Information
</Menu.Item>
<Menu.Item disabled>
<Icon type="setting" />设置
<Icon type="setting" />Settings
</Menu.Item>
<Menu.Item key="triggerError">
<Icon type="close-circle" />触发报错
<Icon type="close-circle" />Errors Menu
</Menu.Item>
<Menu.Divider />
<Menu.Item key="logout">
<Icon type="logout" />退出登录
<Icon type="logout" />Logout
</Menu.Item>
</Menu>
);
......@@ -100,8 +100,8 @@ export default class GlobalHeader extends PureComponent {
<div className={styles.right}>
<HeaderSearch
className={`${styles.action} ${styles.search}`}
placeholder="站内搜索"
dataSource={['搜索提示一', '搜索提示二', '搜索提示三']}
placeholder="Search?"
dataSource={['Tip 1', 'Tip 2', 'Tip 3']}
onSearch={value => {
console.log('input', value); // eslint-disable-line
}}
......@@ -109,7 +109,7 @@ export default class GlobalHeader extends PureComponent {
console.log('enter', value); // eslint-disable-line
}}
/>
<Tooltip title="使用文档">
<Tooltip title="Documentation">
<a
target="_blank"
href="http://pro.ant.design/docs/getting-started"
......@@ -131,21 +131,21 @@ export default class GlobalHeader extends PureComponent {
popupAlign={{ offset: [20, -16] }}
>
<NoticeIcon.Tab
list={noticeData['通知']}
title="通知"
emptyText="你已查看所有通知"
list={noticeData['Notice']}
title="Notice"
emptyText="You have read all the notices"
emptyImage="https://gw.alipayobjects.com/zos/rmsportal/wAhyIChODzsoKIOBHcBk.svg"
/>
<NoticeIcon.Tab
list={noticeData['消息']}
title="消息"
emptyText="您已读完所有消息"
list={noticeData['News']}
title="News"
emptyText="You have read all the messages"
emptyImage="https://gw.alipayobjects.com/zos/rmsportal/sAuJeJzSKbUmHfBQRzmZ.svg"
/>
<NoticeIcon.Tab
list={noticeData['待办']}
title="待办"
emptyText="你已完成所有待办"
list={noticeData['Upcoming']}
title="Upcoming"
emptyText="You have completed all your to-dos"
emptyImage="https://gw.alipayobjects.com/zos/rmsportal/HsIsxMZiWKrNUavQUXqx.svg"
/>
</NoticeIcon>
......
......@@ -73,7 +73,7 @@ function generator({ defaultProps, defaultRules, type }) {
size="large"
onClick={this.onGetCaptcha}
>
{count ? `${count} s` : '获取验证码'}
{count ? `${count} s` : 'Send Code'}
</Button>
</Col>
</Row>
......
......@@ -7,6 +7,7 @@ import LoginTab from './LoginTab';
import LoginSubmit from './LoginSubmit';
import styles from './index.less';
@Form.create()
class Login extends Component {
static defaultProps = {
className: '',
......@@ -118,4 +119,4 @@ Object.keys(LoginItem).forEach(item => {
Login[item] = LoginItem[item];
});
export default Form.create()(Login);
export default Login;
......@@ -55,12 +55,12 @@ const map = {
props: {
size: 'large',
prefix: <Icon type="mail" className={styles.prefixIcon} />,
placeholder: 'captcha',
placeholder: 'Verification Code',
},
rules: [
{
required: true,
message: 'Please enter Captcha!',
message: 'Enter Verification Code',
},
],
},
......
......@@ -14,8 +14,8 @@ export default class NoticeIcon extends PureComponent {
onClear: () => {},
loading: false,
locale: {
emptyText: '暂无数据',
clear: '清空',
emptyText: 'No Data',
clear: 'Clear ',
},
emptyImage: 'https://gw.alipayobjects.com/zos/rmsportal/wAhyIChODzsoKIOBHcBk.svg',
};
......
---
order: 0
title:
zh-CN: 演示
en-US: Demo
title: 演示
---
## zh-CN
各种数据文案的展现方式。
## en-US
Used for presenting various numerical data.
````jsx
import NumberInfo from 'ant-design-pro/lib/NumberInfo';
import numeral from 'numeral';
......@@ -20,7 +12,7 @@ import numeral from 'numeral';
ReactDOM.render(
<div>
<NumberInfo
subTitle={<span>Visits this week</span>}
subTitle={<span>本周访问</span>}
total={numeral(12321).format('0,0')}
status="up"
subTotal={17.1}
......
---
title:
en-US: NumberInfo
zh-CN: NumberInfo
subtitle: 数据文本
cols: 1
order: 10
---
常用在数据卡片中,用于突出展示某个业务数据。
## API
参数 | 说明 | 类型 | 默认值
----|------|-----|------
title | 标题 | ReactNode\|string | -
subTitle | 子标题 | ReactNode\|string | -
total | 总量 | ReactNode\|string | -
subTotal | 子总量 | ReactNode\|string | -
status | 增加状态 | 'up \| down' | -
theme | 状态样式 | string | 'light'
gap | 设置数字和描述直接的间距(像素) | number | 8
......@@ -86,7 +86,7 @@ export default class PageHeader extends PureComponent {
{
[linkElement === 'a' ? 'href' : 'to']: '/',
},
'首页'
'Home'
)}
</Breadcrumb.Item>
);
......
......@@ -85,17 +85,17 @@ class StandardTable extends PureComponent {
<Alert
message={
<Fragment>
已选择 <a style={{ fontWeight: 600 }}>{selectedRowKeys.length}</a> 项&nbsp;&nbsp;
Chosen <a style={{ fontWeight: 600 }}>{selectedRowKeys.length}</a> Item&nbsp;&nbsp;
{needTotalList.map(item => (
<span style={{ marginLeft: 8 }} key={item.dataIndex}>
{item.title}总计&nbsp;
{item.title} Total&nbsp;
<span style={{ fontWeight: 600 }}>
{item.render ? item.render(item.total) : item.total}
</span>
</span>
))}
<a onClick={this.cleanSelectedKeys} style={{ marginLeft: 24 }}>
清空
Empty
</a>
</Fragment>
}
......
......@@ -91,7 +91,7 @@ class TagSelect extends Component {
return (
<div className={cls} style={style}>
<CheckableTag checked={checkedAll} key="tag-select-__all__" onChange={this.onSelectAll}>
全部
All
</CheckableTag>
{value &&
React.Children.map(children, child => {
......@@ -107,7 +107,7 @@ class TagSelect extends Component {
})}
{expandable && (
<a className={styles.trigger} onClick={this.handleExpand}>
{expand ? '收起' : '展开'} <Icon type={expand ? 'up' : 'down'} />
{expand ? 'Collapse' : 'Unfold'} <Icon type={expand ? 'up' : 'down'} />
</a>
)}
</div>
......
import '@babel/polyfill';
import 'url-polyfill';
import dva from 'dva';
import dva from 'dva'; //NERF THIS
import createHistory from 'history/createHashHistory';
// user BrowserHistory
// import createHistory from 'history/createBrowserHistory';
import createLoading from 'dva-loading';
import 'moment/locale/zh-cn';
import 'moment/locale/en-ca';
import './rollbar';
import './index.less';
......
......@@ -6,7 +6,7 @@ import { connect } from 'dva';
import { Route, Redirect, Switch, routerRedux } from 'dva/router';
import { ContainerQuery } from 'react-container-query';
import classNames from 'classnames';
import { enquireScreen, unenquireScreen } from 'enquire-js';
import { enquireScreen } from 'enquire-js';
import GlobalHeader from '../components/GlobalHeader';
import GlobalFooter from '../components/GlobalFooter';
import SiderMenu from '../components/SiderMenu';
......@@ -99,7 +99,7 @@ class BasicLayout extends React.PureComponent {
};
}
componentDidMount() {
this.enquireHandler = enquireScreen(mobile => {
enquireScreen(mobile => {
this.setState({
isMobile: mobile,
});
......@@ -108,9 +108,6 @@ class BasicLayout extends React.PureComponent {
type: 'user/fetchCurrent',
});
}
componentWillUnmount(){
unenquireScreen(this.enquireHandler);
}
getPageTitle() {
const { routerData, location } = this.props;
const { pathname } = location;
......@@ -147,7 +144,7 @@ class BasicLayout extends React.PureComponent {
});
};
handleNoticeClear = type => {
message.success(`清空了${type}`);
message.success(`Cleared ${type}`);
this.props.dispatch({
type: 'global/clearNotices',
payload: type,
......@@ -234,8 +231,8 @@ class BasicLayout extends React.PureComponent {
<GlobalFooter
links={[
{
key: 'Pro 首页',
title: 'Pro 首页',
key: 'Pro Home',
title: 'Pro Home',
href: 'http://pro.ant.design',
blankTarget: true,
},
......@@ -254,7 +251,7 @@ class BasicLayout extends React.PureComponent {
]}
copyright={
<Fragment>
Copyright <Icon type="copyright" /> 2018 蚂蚁金服体验技术部出品
Copyright <Icon type="copyright" /> 2018 Ant Financial Experience Technology Division
</Fragment>
}
/>
......
......@@ -10,24 +10,24 @@ import { getRoutes } from '../utils/utils';
const links = [
{
key: 'help',
title: '帮助',
title: 'help',
href: '',
},
{
key: 'privacy',
title: '隐私',
title: 'privacy',
href: '',
},
{
key: 'terms',
title: '条款',
title: 'terms',
href: '',
},
];
const copyright = (
<Fragment>
Copyright <Icon type="copyright" /> 2018 蚂蚁金服体验技术部出品
Copyright <Icon type="copyright" /> 2018 Ant Financial Experience Technology Division
</Fragment>
);
......@@ -54,7 +54,7 @@ class UserLayout extends React.PureComponent {
<span className={styles.title}>Ant Design</span>
</Link>
</div>
<div className={styles.desc}>Ant Design 是西湖区最具影响力的 Web 设计规范</div>
<div className={styles.desc}>Ant Design Is the most influential Web design specification in the West Lake District</div>
</div>
<Switch>
{getRoutes(match.path, routerData).map(item => (
......
......@@ -17,7 +17,7 @@ export default {
effects: {
*submitRegularForm({ payload }, { call }) {
yield call(fakeSubmitForm, payload);
message.success('提交成功');
message.success('Submitted successfully');
},
*submitStepForm({ payload }, { call, put }) {
yield call(fakeSubmitForm, payload);
......@@ -29,7 +29,7 @@ export default {
},
*submitAdvancedForm({ payload }, { call }) {
yield call(fakeSubmitForm, payload);
message.success('提交成功');
message.success('Submitted successfully');
},
},
......
import React from 'react';
import { routerRedux, Route, Switch } from 'dva/router';
import { LocaleProvider, Spin } from 'antd';
import zhCN from 'antd/lib/locale-provider/zh_CN';
import enUS from 'antd/lib/locale-provider/en_US';
import dynamic from 'dva/dynamic';
import { getRouterData } from './common/router';
import Authorized from './utils/Authorized';
......@@ -18,7 +18,7 @@ function RouterConfig({ history, app }) {
const UserLayout = routerData['/user'].component;
const BasicLayout = routerData['/'].component;
return (
<LocaleProvider locale={zhCN}>
<LocaleProvider locale={enUS}>
<ConnectedRouter history={history}>
<Switch>
<Route path="/user" component={UserLayout} />
......
This diff is collapsed.
......@@ -38,31 +38,31 @@ export default class Monitor extends PureComponent {
<Fragment>
<Row gutter={24}>
<Col xl={18} lg={24} md={24} sm={24} xs={24} style={{ marginBottom: 24 }}>
<Card title="活动实时交易情况" bordered={false}>
<Card title="Real-time tranding activity" bordered={false}>
<Row>
<Col md={6} sm={12} xs={24}>
<NumberInfo
subTitle="今日交易总额"
suffix=""
subTitle="Total transition today"
suffix="Yuan"
total={numeral(124543233).format('0,0')}
/>
</Col>
<Col md={6} sm={12} xs={24}>
<NumberInfo subTitle="销售目标完成率" total="92%" />
<NumberInfo subTitle="Sales target rate" total="92%" />
</Col>
<Col md={6} sm={12} xs={24}>
<NumberInfo subTitle="活动剩余时间" total={<CountDown target={targetTime} />} />
<NumberInfo subTitle="Activity remaining time" total={<CountDown target={targetTime} />} />
</Col>
<Col md={6} sm={12} xs={24}>
<NumberInfo
subTitle="每秒交易总额"
suffix=""
subTitle="Total transitions per second"
suffix="Yuan"
total={numeral(234).format('0,0')}
/>
</Col>
</Row>
<div className={styles.mapChart}>
<Tooltip title="等待后期实现">
<Tooltip title="Waiting for late realization">
<img
src="https://gw.alipayobjects.com/zos/rmsportal/HBWnDEUXCnGnGrRfrpKa.png"
alt="map"
......@@ -72,28 +72,28 @@ export default class Monitor extends PureComponent {
</Card>
</Col>
<Col xl={6} lg={24} md={24} sm={24} xs={24}>
<Card title="活动情况预测" style={{ marginBottom: 24 }} bordered={false}>
<Card title="Activity forecast" style={{ marginBottom: 24 }} bordered={false}>
<ActiveChart />
</Card>
<Card
title="券核效率"
title="Voucher Efficiency"
style={{ marginBottom: 24 }}
bodyStyle={{ textAlign: 'center' }}
bordered={false}
>
<Gauge title="跳出率" height={180} percent={87} />
<Gauge title="Bounce rate" height={180} percent={87} />
</Card>
</Col>
</Row>
<Row gutter={24}>
<Col xl={12} lg={24} sm={24} xs={24}>
<Card title="各品类占比" bordered={false} className={styles.pieCard}>
<Card title="Category proportion" bordered={false} className={styles.pieCard}>
<Row style={{ padding: '16px 0' }}>
<Col span={8}>
<Pie
animate={false}
percent={28}
subTitle="中式快餐"
subTitle="Chinese fast food"
total="28%"
height={128}
lineWidth={2}
......@@ -104,7 +104,7 @@ export default class Monitor extends PureComponent {
animate={false}
color="#5DDECF"
percent={22}
subTitle="西餐"
subTitle="Western food"
total="22%"
height={128}
lineWidth={2}
......@@ -115,7 +115,7 @@ export default class Monitor extends PureComponent {
animate={false}
color="#2FC25B"
percent={32}
subTitle="火锅"
subTitle="Hot pot"
total="32%"
height={128}
lineWidth={2}
......@@ -126,7 +126,7 @@ export default class Monitor extends PureComponent {
</Col>
<Col xl={6} lg={12} sm={24} xs={24}>
<Card
title="热门搜索"
title="Popular searches"
loading={loading}
bordered={false}
bodyStyle={{ overflow: 'hidden' }}
......@@ -136,11 +136,11 @@ export default class Monitor extends PureComponent {
</Col>
<Col xl={6} lg={12} sm={24} xs={24}>
<Card
title="资源剩余"
title="Resource surplus"
bodyStyle={{ textAlign: 'center', fontSize: 0 }}
bordered={false}
>
<WaterWave height={161} title="补贴资金剩余" percent={34} />
<WaterWave height={161} title="remaining subsidies" percent={34} />
</Card>
</Col>
</Row>
......
......@@ -12,27 +12,27 @@ import styles from './Workplace.less';
const links = [
{
title: '操作一',
title: 'Operação 1',
href: '',
},
{
title: '操作二',
title: 'Operação 2',
href: '',
},
{
title: '操作三',
title: 'Operação 3',
href: '',
},
{
title: '操作四',
title: 'Operação 4',
href: '',
},
{
title: '操作五',
title: 'Operação 5',
href: '',
},
{
title: '操作六',
title: 'Operação 6',
href: '',
},
];
......@@ -40,31 +40,31 @@ const links = [
const members = [
{
id: 'members-1',
title: '科学搬砖组',
title: 'The Scientist',
logo: 'https://gw.alipayobjects.com/zos/rmsportal/BiazfanxmamNRoxxVxka.png',
link: '',
},
{
id: 'members-2',
title: '程序员日常',
title: 'Everyday Programmer',
logo: 'https://gw.alipayobjects.com/zos/rmsportal/cnrhVkzwxjPwAaCfPbdc.png',
link: '',
},
{
id: 'members-3',
title: '设计天团',
title: 'Designer Missioner',
logo: 'https://gw.alipayobjects.com/zos/rmsportal/gaOngJwsRYRaVAuXXcmB.png',
link: '',
},
{
id: 'members-4',
title: '中二少女团',
title: 'Secondary girl',
logo: 'https://gw.alipayobjects.com/zos/rmsportal/ubnKSIfAJTxIgXOKlciN.png',
link: '',
},
{
id: 'members-5',
title: '骗你学计算机',
title: 'Computer Learner',
logo: 'https://gw.alipayobjects.com/zos/rmsportal/WhxKECPNujWoWEFNdnJE.png',
link: '',
},
......@@ -150,8 +150,8 @@ export default class Workplace extends PureComponent {
/>
</div>
<div className={styles.content}>
<div className={styles.contentTitle}>早安,曲丽丽,祝你开心每一天!</div>
<div>交互专家 | 蚂蚁金服-某某某事业群-某某平台部-某某技术部-UED</div>
<div className={styles.contentTitle}>Good Morning, John Doe. Have a nice day.</div>
<div>Interaction Experts | Ant Financial Services - Certain Business Group - Certain Platform Division - Technical Department - UED</div>
</div>
</div>
);
......@@ -159,17 +159,17 @@ export default class Workplace extends PureComponent {
const extraContent = (
<div className={styles.extraContent}>
<div className={styles.statItem}>
<p>项目数</p>
<p>Number of Itens</p>
<p>56</p>
</div>
<div className={styles.statItem}>
<p>团队内排名</p>
<p>Team Rank</p>
<p>
8<span> / 24</span>
</p>
</div>
<div className={styles.statItem}>
<p>项目访问</p>
<p>Projects visited</p>
<p>2,223</p>
</div>
</div>
......@@ -182,9 +182,9 @@ export default class Workplace extends PureComponent {
<Card
className={styles.projectList}
style={{ marginBottom: 24 }}
title="进行中的项目"
title="Ongoing Projects"
bordered={false}
extra={<Link to="/">全部项目</Link>}
extra={<Link to="/">All Itens</Link>}
loading={projectLoading}
bodyStyle={{ padding: 0 }}
>
......@@ -216,7 +216,7 @@ export default class Workplace extends PureComponent {
bodyStyle={{ padding: 0 }}
bordered={false}
className={styles.activeCard}
title="动态"
title="Dynamic"
loading={activitiesLoading}
>
<List loading={activitiesLoading} size="large">
......@@ -227,7 +227,7 @@ export default class Workplace extends PureComponent {
<Col xl={8} lg={24} md={24} sm={24} xs={24}>
<Card
style={{ marginBottom: 24 }}
title="快速开始 / 便捷导航"
title="Quick Start / Easy Navigation"
bordered={false}
bodyStyle={{ padding: 0 }}
>
......@@ -236,14 +236,14 @@ export default class Workplace extends PureComponent {
<Card
style={{ marginBottom: 24 }}
bordered={false}
title="XX 指数"
title="XX Index"
loading={radarData.length === 0}
>
<div className={styles.chart}>
<Radar hasLegend height={343} data={radarData} />
</div>
</Card>
<Card bodyStyle={{ paddingTop: 12, paddingBottom: 12 }} bordered={false} title="团队">
<Card bodyStyle={{ paddingTop: 12, paddingBottom: 12 }} bordered={false} title="Team">
<div className={styles.members}>
<Row gutter={48}>
{members.map(item => (
......
This diff is collapsed.
......@@ -61,65 +61,65 @@ export default class BasicForms extends PureComponent {
return (
<PageHeaderLayout
title="基础表单"
content="表单页用于向用户收集或验证信息,基础表单常见于数据项较少的表单场景。"
title="Basic Form"
content="Form pages are used to collect or verify information from users, and basic forms are often found in form scenes with fewer data items."
>
<Card bordered={false}>
<Form onSubmit={this.handleSubmit} hideRequiredMark style={{ marginTop: 8 }}>
<FormItem {...formItemLayout} label="标题">
<FormItem {...formItemLayout} label="Title">
{getFieldDecorator('title', {
rules: [
{
required: true,
message: '请输入标题',
message: 'Please enter a title',
},
],
})(<Input placeholder="给目标起个名字" />)}
})(<Input placeholder="Give a name" />)}
</FormItem>
<FormItem {...formItemLayout} label="起止日期">
<FormItem {...formItemLayout} label="Start & End Dates">
{getFieldDecorator('date', {
rules: [
{
required: true,
message: '请选择起止日期',
message: 'Please select starting and ending dates',
},
],
})(<RangePicker style={{ width: '100%' }} placeholder={['开始日期', '结束日期']} />)}
})(<RangePicker style={{ width: '100%' }} placeholder={['Start Date', 'End Date']} />)}
</FormItem>
<FormItem {...formItemLayout} label="目标描述">
<FormItem {...formItemLayout} label="Goal Description">
{getFieldDecorator('goal', {
rules: [
{
required: true,
message: '请输入目标描述',
message: 'Please enter with a description',
},
],
})(
<TextArea
style={{ minHeight: 32 }}
placeholder="请输入你的阶段性工作目标"
placeholder="Please enter with your milestone goal" //milestone goal ??
rows={4}
/>
)}
</FormItem>
<FormItem {...formItemLayout} label="衡量标准">
<FormItem {...formItemLayout} label="Metrics">
{getFieldDecorator('standard', {
rules: [
{
required: true,
message: '请输入衡量标准',
message: 'Please Enter Metrics',
},
],
})(<TextArea style={{ minHeight: 32 }} placeholder="请输入衡量标准" rows={4} />)}
})(<TextArea style={{ minHeight: 32 }} placeholder="Please Enter Metrics" rows={4} />)}
</FormItem>
<FormItem
{...formItemLayout}
label={
<span>
客户
Client
<em className={styles.optional}>
选填
<Tooltip title="目标的服务对象">
Optional
<Tooltip title="Objective Target">
<Icon type="info-circle-o" style={{ marginRight: 4 }} />
</Tooltip>
</em>
......@@ -127,56 +127,56 @@ export default class BasicForms extends PureComponent {
}
>
{getFieldDecorator('client')(
<Input placeholder="请描述你服务的客户,内部客户直接 @姓名/工号" />
<Input placeholder="Please describe the customer you serve, internal customer direct @ name / job number" />
)}
</FormItem>
<FormItem
{...formItemLayout}
label={
<span>
邀评人<em className={styles.optional}>(选填</em>
Invitees<em className={styles.optional}>Optional</em>
</span>
}
>
{getFieldDecorator('invites')(
<Input placeholder="请直接 @姓名/工号,最多可邀请 5 人" />
<Input placeholder="Please direct @ name / job number, up to 5 people can be invited" />
)}
</FormItem>
<FormItem
{...formItemLayout}
label={
<span>
权重<em className={styles.optional}>(选填</em>
Weights<em className={styles.optional}>Optional</em>
</span>
}
>
{getFieldDecorator('weight')(<InputNumber placeholder="请输入" min={0} max={100} />)}
{getFieldDecorator('weight')(<InputNumber placeholder="Please Enter" min={0} max={100} />)}
<span>%</span>
</FormItem>
<FormItem {...formItemLayout} label="目标公开" help="客户、邀评人默认被分享">
<FormItem {...formItemLayout} label="Target Public" help="Customers and appraisers are shared by default">
<div>
{getFieldDecorator('public', {
initialValue: '1',
})(
<Radio.Group>
<Radio value="1">公开</Radio>
<Radio value="2">部分公开</Radio>
<Radio value="3">不公开</Radio>
<Radio value="1">Public</Radio>
<Radio value="2">Partly Open</Radio>
<Radio value="3">Private</Radio>
</Radio.Group>
)}
<FormItem style={{ marginBottom: 0 }}>
{getFieldDecorator('publicUsers')(
<Select
mode="multiple"
placeholder="公开给"
placeholder="Open to"
style={{
margin: '8px 0',
display: getFieldValue('public') === '2' ? 'block' : 'none',
}}
>
<Option value="1">同事甲</Option>
<Option value="2">同事乙</Option>
<Option value="3">同事丙</Option>
<Option value="1">Colleague A</Option>
<Option value="2">Colleague B</Option>
<Option value="3">Colleague C</Option>
</Select>
)}
</FormItem>
......@@ -184,9 +184,9 @@ export default class BasicForms extends PureComponent {
</FormItem>
<FormItem {...submitFormLayout} style={{ marginTop: 32 }}>
<Button type="primary" htmlType="submit" loading={submitting}>
提交
Submit
</Button>
<Button style={{ marginLeft: 8 }}>保存</Button>
<Button style={{ marginLeft: 8 }}>Save</Button>
</FormItem>
</Form>
</Card>
......
......@@ -34,48 +34,48 @@ class Step1 extends React.PureComponent {
return (
<Fragment>
<Form layout="horizontal" className={styles.stepForm} hideRequiredMark>
<Form.Item {...formItemLayout} label="付款账户">
<Form.Item {...formItemLayout} label="Payment Account">
{getFieldDecorator('payAccount', {
initialValue: data.payAccount,
rules: [{ required: true, message: '请选择付款账户' }],
rules: [{ required: true, message: 'Please select a payment account' }],
})(
<Select placeholder="test@example.com">
<Option value="ant-design@alipay.com">ant-design@alipay.com</Option>
</Select>
)}
</Form.Item>
<Form.Item {...formItemLayout} label="收款账户">
<Form.Item {...formItemLayout} label="Accounts receivable">
<Input.Group compact>
<Select defaultValue="alipay" style={{ width: 100 }}>
<Option value="alipay">支付宝</Option>
<Option value="bank">银行账户</Option>
<Option value="alipay">Alipay</Option>
<Option value="bank">Bank Account</Option>
</Select>
{getFieldDecorator('receiverAccount', {
initialValue: data.receiverAccount,
rules: [
{ required: true, message: '请输入收款人账户' },
{ type: 'email', message: '账户名应为邮箱格式' },
{ required: true, message: 'Please enter payee account' },
{ type: 'email', message: 'Account name should be in email format' },
],
})(<Input style={{ width: 'calc(100% - 100px)' }} placeholder="test@example.com" />)}
</Input.Group>
</Form.Item>
<Form.Item {...formItemLayout} label="收款人姓名">
<Form.Item {...formItemLayout} label="Payee Name">
{getFieldDecorator('receiverName', {
initialValue: data.receiverName,
rules: [{ required: true, message: '请输入收款人姓名' }],
})(<Input placeholder="请输入收款人姓名" />)}
rules: [{ required: true, message: 'Please enter payee name' }],
})(<Input placeholder="Please enter payee name" />)}
</Form.Item>
<Form.Item {...formItemLayout} label="转账金额">
<Form.Item {...formItemLayout} label="Transfer Amount">
{getFieldDecorator('amount', {
initialValue: data.amount,
rules: [
{ required: true, message: '请输入转账金额' },
{ required: true, message: 'Please Enter The Transfer Amount' },
{
pattern: /^(\d+)((?:\.\d+)?)$/,
message: '请输入合法金额数字',
message: 'Please Enter The Legal Amount Number',
},
],
})(<Input prefix="¥" placeholder="请输入金额" />)}
})(<Input prefix="$" placeholder="Please Enter The Amount" />)}
</Form.Item>
<Form.Item
wrapperCol={{
......@@ -88,20 +88,20 @@ class Step1 extends React.PureComponent {
label=""
>
<Button type="primary" onClick={onValidateForm}>
下一步
Next Step
</Button>
</Form.Item>
</Form>
<Divider style={{ margin: '40px 0 24px' }} />
<div className={styles.desc}>
<h3>说明</h3>
<h4>转账到支付宝账户</h4>
<h3>Instructions</h3>
<h4>Transfer to Alipay Account</h4>
<p>
如果需要,这里可以放一些关于产品的常见问题说明。如果需要,这里可以放一些关于产品的常见问题说明。如果需要,这里可以放一些关于产品的常见问题说明。
If needed, here are some common questions about the product. If needed, here are some common questions about the product. If needed, here are some common questions about the product.
</p>
<h4>转账到银行卡</h4>
<h4>Transfer To Bank Card</h4>
<p>
如果需要,这里可以放一些关于产品的常见问题说明。如果需要,这里可以放一些关于产品的常见问题说明。如果需要,这里可以放一些关于产品的常见问题说明。
If needed, here are some common questions about the product. If needed, here are some common questions about the product. If needed, here are some common questions about the product.
</p>
</div>
</Fragment>
......
......@@ -41,30 +41,30 @@ class Step2 extends React.PureComponent {
<Alert
closable
showIcon
message="确认转账后,资金将直接打入对方账户,无法退回。"
message="After confirming the transfer, funds will be directly credited to the other party's account and cannot be returned."
style={{ marginBottom: 24 }}
/>
<Form.Item {...formItemLayout} className={styles.stepFormText} label="付款账户">
<Form.Item {...formItemLayout} className={styles.stepFormText} label="Payment Account: ">
{data.payAccount}
</Form.Item>
<Form.Item {...formItemLayout} className={styles.stepFormText} label="收款账户">
<Form.Item {...formItemLayout} className={styles.stepFormText} label="Accounts Receivable: ">
{data.receiverAccount}
</Form.Item>
<Form.Item {...formItemLayout} className={styles.stepFormText} label="收款人姓名">
<Form.Item {...formItemLayout} className={styles.stepFormText} label="Payee Name: ">
{data.receiverName}
</Form.Item>
<Form.Item {...formItemLayout} className={styles.stepFormText} label="转账金额">
<Form.Item {...formItemLayout} className={styles.stepFormText} label="Transfer Amount: ">
<span className={styles.money}>{data.amount}</span>
<span className={styles.uppercase}>{digitUppercase(data.amount)}</span>
</Form.Item>
<Divider style={{ margin: '24px 0' }} />
<Form.Item {...formItemLayout} label="支付密码" required={false}>
<Form.Item {...formItemLayout} label="Payment Password" required={false}>
{getFieldDecorator('password', {
initialValue: '123456',
rules: [
{
required: true,
message: '需要支付密码才能进行支付',
message: 'Pay Password Needed to Make Payment',
},
],
})(<Input type="password" autoComplete="off" style={{ width: '80%' }} />)}
......@@ -81,10 +81,10 @@ class Step2 extends React.PureComponent {
label=""
>
<Button type="primary" onClick={onValidateForm} loading={submitting}>
提交
Submit
</Button>
<Button onClick={onPrev} style={{ marginLeft: 8 }}>
上一步
Previous Step
</Button>
</Form.Item>
</Form>
......
......@@ -15,28 +15,28 @@ class Step3 extends React.PureComponent {
<div className={styles.information}>
<Row>
<Col span={8} className={styles.label}>
付款账户:
Payment Account:
</Col>
<Col span={16}>{data.payAccount}</Col>
</Row>
<Row>
<Col span={8} className={styles.label}>
收款账户:
Accounts Receivable:
</Col>
<Col span={16}>{data.receiverAccount}</Col>
</Row>
<Row>
<Col span={8} className={styles.label}>
收款人姓名:
Payee Name:
</Col>
<Col span={16}>{data.receiverName}</Col>
</Row>
<Row>
<Col span={8} className={styles.label}>
转账金额:
Transfer Amount:
</Col>
<Col span={16}>
<span className={styles.money}>{data.amount}</span>
<span className={styles.money}>{data.amount}</span> $
</Col>
</Row>
</div>
......@@ -44,16 +44,16 @@ class Step3 extends React.PureComponent {
const actions = (
<Fragment>
<Button type="primary" onClick={onFinish}>
再转一笔
Make Another Transfer
</Button>
<Button>查看账单</Button>
<Button>Check Bills</Button>
</Fragment>
);
return (
<Result
type="success"
title="操作成功"
description="预计两小时内到账"
title="Successful Operation"
description="It is expected to arrive within two hours"
extra={information}
actions={actions}
className={styles.result}
......
......@@ -28,15 +28,15 @@ export default class StepForm extends PureComponent {
const { match, routerData } = this.props;
return (
<PageHeaderLayout
title="分步表单"
content="将一个冗长或用户不熟悉的表单任务分成多个步骤,指导用户完成。"
title="Step-by-step form"
content="Divide a lengthy or unfamiliar form task into multiple steps to guide the user through it."
>
<Card bordered={false}>
<Fragment>
<Steps current={this.getCurrentStep()} className={styles.steps}>
<Step title="填写转账信息" />
<Step title="确认转账信息" />
<Step title="完成" />
<Step title="Fill in transfer information" />
<Step title="Confirm transfer information" />
<Step title="Complete" />
</Steps>
<Switch>
{getRoutes(match.path, routerData).map(item => (
......
......@@ -79,7 +79,7 @@ export default class TableForm extends PureComponent {
}
const target = this.getRowByKey(key) || {};
if (!target.workId || !target.name || !target.department) {
message.error('请填写完整成员信息。');
message.error('Please fill in the complete membership information.');
e.target.focus();
this.setState({
loading: false,
......@@ -110,7 +110,7 @@ export default class TableForm extends PureComponent {
render() {
const columns = [
{
title: '成员姓名',
title: 'Name of the Member',
dataIndex: 'name',
key: 'name',
width: '20%',
......@@ -122,7 +122,7 @@ export default class TableForm extends PureComponent {
autoFocus
onChange={e => this.handleFieldChange(e, 'name', record.key)}
onKeyPress={e => this.handleKeyPress(e, record.key)}
placeholder="成员姓名"
placeholder="Name of the Member"
/>
);
}
......@@ -130,7 +130,7 @@ export default class TableForm extends PureComponent {
},
},
{
title: '工号',
title: 'Job Number',
dataIndex: 'workId',
key: 'workId',
width: '20%',
......@@ -141,7 +141,7 @@ export default class TableForm extends PureComponent {
value={text}
onChange={e => this.handleFieldChange(e, 'workId', record.key)}
onKeyPress={e => this.handleKeyPress(e, record.key)}
placeholder="工号"
placeholder="Job Number"
/>
);
}
......@@ -149,7 +149,7 @@ export default class TableForm extends PureComponent {
},
},
{
title: '所属部门',
title: 'Department',
dataIndex: 'department',
key: 'department',
width: '40%',
......@@ -160,7 +160,7 @@ export default class TableForm extends PureComponent {
value={text}
onChange={e => this.handleFieldChange(e, 'department', record.key)}
onKeyPress={e => this.handleKeyPress(e, record.key)}
placeholder="所属部门"
placeholder="Department"
/>
);
}
......@@ -168,7 +168,7 @@ export default class TableForm extends PureComponent {
},
},
{
title: '操作',
title: 'Operating',
key: 'action',
render: (text, record) => {
if (!!record.editable && this.state.loading) {
......@@ -178,28 +178,28 @@ export default class TableForm extends PureComponent {
if (record.isNew) {
return (
<span>
<a onClick={e => this.saveRow(e, record.key)}>添加</a>
<a onClick={e => this.saveRow(e, record.key)}>Add to</a>
<Divider type="vertical" />
<Popconfirm title="是否要删除此行?" onConfirm={() => this.remove(record.key)}>
<a>删除</a>
<Popconfirm title="Do you want to delete this line?" onConfirm={() => this.remove(record.key)}>
<a>Delete</a>
</Popconfirm>
</span>
);
}
return (
<span>
<a onClick={e => this.saveRow(e, record.key)}>保存</a>
<a onClick={e => this.saveRow(e, record.key)}>Save</a>
<Divider type="vertical" />
<a onClick={e => this.cancel(e, record.key)}>取消</a>
<a onClick={e => this.cancel(e, record.key)}>Cancel</a>
</span>
);
}
return (
<span>
<a onClick={e => this.toggleEditable(e, record.key)}>编辑</a>
<a onClick={e => this.toggleEditable(e, record.key)}>Edit</a>
<Divider type="vertical" />
<Popconfirm title="是否要删除此行?" onConfirm={() => this.remove(record.key)}>
<a>删除</a>
<Popconfirm title="Do you want to delete this line?" onConfirm={() => this.remove(record.key)}>
<a>Delete</a>
</Popconfirm>
</span>
);
......@@ -224,7 +224,7 @@ export default class TableForm extends PureComponent {
onClick={this.newMember}
icon="plus"
>
新增成员
Add Member
</Button>
</Fragment>
);
......
......@@ -21,7 +21,7 @@ const formatWan = val => {
result = (
<span>
{result}
<em className={styles.wan}></em>
<em className={styles.wan}>0000</em>
</span>
);
}
......@@ -69,11 +69,11 @@ export default class FilterCardList extends PureComponent {
const CardInfo = ({ activeUser, newUser }) => (
<div className={styles.cardInfo}>
<div>
<p>活跃用户</p>
<p>Active User</p>
<p>{activeUser}</p>
</div>
<div>
<p>新增用户</p>
<p>New User</p>
<p>{newUser}</p>
</div>
</div>
......@@ -110,51 +110,51 @@ export default class FilterCardList extends PureComponent {
<div className={styles.filterCardList}>
<Card bordered={false}>
<Form layout="inline">
<StandardFormRow title="所属类目" block style={{ paddingBottom: 11 }}>
<StandardFormRow title="Categories" block style={{ paddingBottom: 11 }}>
<FormItem>
{getFieldDecorator('category')(
<TagSelect onChange={this.handleFormSubmit} expandable>
<TagSelect.Option value="cat1">类目一</TagSelect.Option>
<TagSelect.Option value="cat2">类目二</TagSelect.Option>
<TagSelect.Option value="cat3">类目三</TagSelect.Option>
<TagSelect.Option value="cat4">类目四</TagSelect.Option>
<TagSelect.Option value="cat5">类目五</TagSelect.Option>
<TagSelect.Option value="cat6">类目六</TagSelect.Option>
<TagSelect.Option value="cat7">类目七</TagSelect.Option>
<TagSelect.Option value="cat8">类目八</TagSelect.Option>
<TagSelect.Option value="cat9">类目九</TagSelect.Option>
<TagSelect.Option value="cat10">类目十</TagSelect.Option>
<TagSelect.Option value="cat11">类目十一</TagSelect.Option>
<TagSelect.Option value="cat12">类目十二</TagSelect.Option>
<TagSelect.Option value="cat1">Category 1</TagSelect.Option>
<TagSelect.Option value="cat2">Category 2</TagSelect.Option>
<TagSelect.Option value="cat3">Category 3</TagSelect.Option>
<TagSelect.Option value="cat4">Category 4</TagSelect.Option>
<TagSelect.Option value="cat5">Category 5</TagSelect.Option>
<TagSelect.Option value="cat6">Category 6</TagSelect.Option>
<TagSelect.Option value="cat7">Category 7</TagSelect.Option>
<TagSelect.Option value="cat8">Category 8</TagSelect.Option>
<TagSelect.Option value="cat9">Category 9</TagSelect.Option>
<TagSelect.Option value="cat10">Category 10</TagSelect.Option>
<TagSelect.Option value="cat11">Category 11</TagSelect.Option>
<TagSelect.Option value="cat12">Category 12</TagSelect.Option>
</TagSelect>
)}
</FormItem>
</StandardFormRow>
<StandardFormRow title="其它选项" grid last>
<StandardFormRow title="Other Options" grid last>
<Row gutter={16}>
<Col lg={8} md={10} sm={10} xs={24}>
<FormItem {...formItemLayout} label="作者">
<FormItem {...formItemLayout} label="The Author">
{getFieldDecorator('author', {})(
<Select
onChange={this.handleFormSubmit}
placeholder="不限"
placeholder="Any"
style={{ maxWidth: 200, width: '100%' }}
>
<Option value="lisa">王昭君</Option>
<Option value="lisa">In Progress</Option>
</Select>
)}
</FormItem>
</Col>
<Col lg={8} md={10} sm={10} xs={24}>
<FormItem {...formItemLayout} label="好评度">
<FormItem {...formItemLayout} label="Praise of">
{getFieldDecorator('rate', {})(
<Select
onChange={this.handleFormSubmit}
placeholder="不限"
placeholder="Any"
style={{ maxWidth: 200, width: '100%' }}
>
<Option value="good">优秀</Option>
<Option value="normal">普通</Option>
<Option value="good">Good</Option>
<Option value="normal">Normal</Option>
</Select>
)}
</FormItem>
......@@ -175,13 +175,13 @@ export default class FilterCardList extends PureComponent {
hoverable
bodyStyle={{ paddingBottom: 20 }}
actions={[
<Tooltip title="下载">
<Tooltip title="Download">
<Icon type="download" />
</Tooltip>,
<Tooltip title="编辑">
<Tooltip title="Edit">
<Icon type="edit" />
</Tooltip>,
<Tooltip title="分享">
<Tooltip title="Share">
<Icon type="share-alt" />
</Tooltip>,
<Dropdown overlay={itemMenu}>
......
......@@ -45,23 +45,23 @@ export default class SearchList extends Component {
const owners = [
{
id: 'wzj',
name: '我自己',
name: 'Myself', //Wo Ziji
},
{
id: 'wjh',
name: '吴家豪',
name: 'Wu Jiahao',
},
{
id: 'zxx',
name: '周星星',
name: 'Zhou Xiaoxiao',
},
{
id: 'zly',
name: '赵丽颖',
name: 'Zhao Liying',
},
{
id: 'ym',
name: '姚明',
name: 'Yao Ming',
},
];
......@@ -77,7 +77,7 @@ export default class SearchList extends Component {
<div className={styles.description}>{content}</div>
<div className={styles.extra}>
<Avatar src={avatar} size="small" />
<a href={href}>{owner}</a> 发布在 <a href={href}>{href}</a>
<a href={href}>{owner}</a> Posted In <a href={href}>{href}</a>
<em>{moment(updatedAt).format('YYYY-MM-DD HH:mm')}</em>
</div>
</div>
......@@ -97,10 +97,10 @@ export default class SearchList extends Component {
<Button onClick={this.fetchMore} style={{ paddingLeft: 48, paddingRight: 48 }}>
{loading ? (
<span>
<Icon type="loading" /> 加载中...
<Icon type="loading" /> Loading...
</span>
) : (
'加载更多'
'Load More'
)}
</Button>
</div>
......@@ -110,22 +110,22 @@ export default class SearchList extends Component {
<Fragment>
<Card bordered={false}>
<Form layout="inline">
<StandardFormRow title="所属类目" block style={{ paddingBottom: 11 }}>
<StandardFormRow title="Categories" block style={{ paddingBottom: 11 }}>
<FormItem>
{getFieldDecorator('category')(
<TagSelect onChange={this.handleFormSubmit} expandable>
<TagSelect.Option value="cat1">类目一</TagSelect.Option>
<TagSelect.Option value="cat2">类目二</TagSelect.Option>
<TagSelect.Option value="cat3">类目三</TagSelect.Option>
<TagSelect.Option value="cat4">类目四</TagSelect.Option>
<TagSelect.Option value="cat5">类目五</TagSelect.Option>
<TagSelect.Option value="cat6">类目六</TagSelect.Option>
<TagSelect.Option value="cat7">类目七</TagSelect.Option>
<TagSelect.Option value="cat8">类目八</TagSelect.Option>
<TagSelect.Option value="cat9">类目九</TagSelect.Option>
<TagSelect.Option value="cat10">类目十</TagSelect.Option>
<TagSelect.Option value="cat11">类目十一</TagSelect.Option>
<TagSelect.Option value="cat12">类目十二</TagSelect.Option>
<TagSelect.Option value="cat1">Category 1</TagSelect.Option>
<TagSelect.Option value="cat2">Category 2</TagSelect.Option>
<TagSelect.Option value="cat3">Category 3</TagSelect.Option>
<TagSelect.Option value="cat4">Category 4</TagSelect.Option>
<TagSelect.Option value="cat5">Category 5</TagSelect.Option>
<TagSelect.Option value="cat6">Category 6</TagSelect.Option>
<TagSelect.Option value="cat7">Category 7</TagSelect.Option>
<TagSelect.Option value="cat8">Category 8</TagSelect.Option>
<TagSelect.Option value="cat9">Category 9</TagSelect.Option>
<TagSelect.Option value="cat10">Category 10</TagSelect.Option>
<TagSelect.Option value="cat11">Category 11</TagSelect.Option>
<TagSelect.Option value="cat12">Category 12</TagSelect.Option>
</TagSelect>
)}
</FormItem>
......@@ -140,7 +140,7 @@ export default class SearchList extends Component {
<Select
mode="multiple"
style={{ maxWidth: 286, width: '100%' }}
placeholder="选择 owner"
placeholder="Select Owner"
>
{owners.map(owner => (
<Option key={owner.id} value={owner.id}>
......@@ -150,36 +150,36 @@ export default class SearchList extends Component {
</Select>
)}
<a className={styles.selfTrigger} onClick={this.setOwner}>
只看自己的
Your Own
</a>
</FormItem>
</Col>
</Row>
</StandardFormRow>
<StandardFormRow title="其它选项" grid last>
<StandardFormRow title="Other Options" grid last>
<Row gutter={16}>
<Col xl={8} lg={10} md={12} sm={24} xs={24}>
<FormItem {...formItemLayout} label="活跃用户">
<FormItem {...formItemLayout} label="Active User">
{getFieldDecorator('user', {})(
<Select
onChange={this.handleFormSubmit}
placeholder="不限"
placeholder="Any"
style={{ maxWidth: 200, width: '100%' }}
>
<Option value="lisa">李三</Option>
<Option value="lisa">Li San</Option>
</Select>
)}
</FormItem>
</Col>
<Col xl={8} lg={10} md={12} sm={24} xs={24}>
<FormItem {...formItemLayout} label="好评度">
<FormItem {...formItemLayout} label="Praise Of">
{getFieldDecorator('rate', {})(
<Select
onChange={this.handleFormSubmit}
placeholder="不限"
placeholder="Any"
style={{ maxWidth: 200, width: '100%' }}
>
<Option value="good">优秀</Option>
<Option value="good">Excellent</Option>
</Select>
)}
</FormItem>
......@@ -219,8 +219,8 @@ export default class SearchList extends Component {
description={
<span>
<Tag>Ant Design</Tag>
<Tag>设计语言</Tag>
<Tag>蚂蚁金服</Tag>
<Tag>Design Language</Tag>
<Tag>Ant Financial Service Group</Tag>
</span>
}
/>
......
......@@ -52,11 +52,11 @@ export default class BasicList extends PureComponent {
const extraContent = (
<div className={styles.extraContent}>
<RadioGroup defaultValue="all">
<RadioButton value="all">全部</RadioButton>
<RadioButton value="progress">进行中</RadioButton>
<RadioButton value="waiting">等待中</RadioButton>
<RadioButton value="all">All</RadioButton>
<RadioButton value="progress">In Progress</RadioButton>
<RadioButton value="waiting">Waiting</RadioButton>
</RadioGroup>
<Search className={styles.extraContentSearch} placeholder="请输入" onSearch={() => ({})} />
<Search className={styles.extraContentSearch} placeholder="Please Enter" onSearch={() => ({})} />
</div>
);
......@@ -74,7 +74,7 @@ export default class BasicList extends PureComponent {
<p>{owner}</p>
</div>
<div className={styles.listContentItem}>
<span>开始时间</span>
<span>Starting time</span>
<p>{moment(createdAt).format('YYYY-MM-DD HH:mm')}</p>
</div>
<div className={styles.listContentItem}>
......@@ -86,10 +86,10 @@ export default class BasicList extends PureComponent {
const menu = (
<Menu>
<Menu.Item>
<a>编辑</a>
<a>Edit</a>
</Menu.Item>
<Menu.Item>
<a>删除</a>
<a>Delete</a>
</Menu.Item>
</Menu>
);
......@@ -97,7 +97,7 @@ export default class BasicList extends PureComponent {
const MoreBtn = () => (
<Dropdown overlay={menu}>
<a>
更多 <Icon type="down" />
More <Icon type="down" />
</a>
</Dropdown>
);
......@@ -108,13 +108,13 @@ export default class BasicList extends PureComponent {
<Card bordered={false}>
<Row>
<Col sm={8} xs={24}>
<Info title="我的待办" value="8个任务" bordered />
<Info title="My To-do" value="8 Tasks" bordered />
</Col>
<Col sm={8} xs={24}>
<Info title="本周任务平均处理时间" value="32分钟" bordered />
<Info title="This week's average processing time" value="32 Minutes" bordered />
</Col>
<Col sm={8} xs={24}>
<Info title="本周完成任务数" value="24个任务" />
<Info title="The number of tasks completed this week" value="24 Tasks" />
</Col>
</Row>
</Card>
......@@ -122,13 +122,13 @@ export default class BasicList extends PureComponent {
<Card
className={styles.listCard}
bordered={false}
title="标准列表"
title="Standard list"
style={{ marginTop: 24 }}
bodyStyle={{ padding: '0 32px 40px 32px' }}
extra={extraContent}
>
<Button type="dashed" style={{ width: '100%', marginBottom: 8 }} icon="plus">
添加
Add to
</Button>
<List
size="large"
......@@ -137,7 +137,7 @@ export default class BasicList extends PureComponent {
pagination={paginationProps}
dataSource={list}
renderItem={item => (
<List.Item actions={[<a>编辑</a>, <MoreBtn />]}>
<List.Item actions={[<a>Edit</a>, <MoreBtn />]}>
<List.Item.Meta
avatar={<Avatar src={item.logo} shape="square" size="large" />}
title={<a href={item.href}>{item.title}</a>}
......
......@@ -27,21 +27,20 @@ export default class CardList extends PureComponent {
const content = (
<div className={styles.pageHeaderContent}>
<p>
段落示意:蚂蚁金服务设计平台 ant.design,用最小的工作量,无缝接入蚂蚁金服生态,
提供跨越设计与开发的体验解决方案。
Paragraphant.design, an Ant Financial Service Design Platform, seamlessly accesses Ant Financial with minimum workload, providing experience solutions that span design and development.
</p>
<div className={styles.contentLink}>
<a>
<img alt="" src="https://gw.alipayobjects.com/zos/rmsportal/MjEImQtenlyueSmVEfUD.svg" />{' '}
快速开始
Quick Start
</a>
<a>
<img alt="" src="https://gw.alipayobjects.com/zos/rmsportal/NbuDUAuBlIApFuDvWiND.svg" />{' '}
产品简介
Product Introduction
</a>
<a>
<img alt="" src="https://gw.alipayobjects.com/zos/rmsportal/ohOEPSYdDTNnyMbGuyLb.svg" />{' '}
产品文档
Product Documentation
</a>
</div>
</div>
......@@ -50,14 +49,14 @@ export default class CardList extends PureComponent {
const extraContent = (
<div className={styles.extraImg}>
<img
alt="这是一个标题"
alt="This is a Title"
src="https://gw.alipayobjects.com/zos/rmsportal/RzwpdLnhmvDJToTdfDPe.png"
/>
</div>
);
return (
<PageHeaderLayout title="卡片列表" content={content} extraContent={extraContent}>
<PageHeaderLayout title="Card List" content={content} extraContent={extraContent}>
<div className={styles.cardList}>
<List
rowKey="id"
......@@ -67,7 +66,7 @@ export default class CardList extends PureComponent {
renderItem={item =>
item ? (
<List.Item key={item.id}>
<Card hoverable className={styles.card} actions={[<a>操作一</a>, <a>操作二</a>]}>
<Card hoverable className={styles.card} actions={[<a>Operation 1</a>, <a>Operation 2</a>]}>
<Card.Meta
avatar={<img alt="" className={styles.cardAvatar} src={item.avatar} />}
title={<a href="#">{item.title}</a>}
......@@ -82,7 +81,7 @@ export default class CardList extends PureComponent {
) : (
<List.Item>
<Button type="dashed" className={styles.newButton}>
<Icon type="plus" /> 新增产品
<Icon type="plus" /> New Product
</Button>
</List.Item>
)
......
......@@ -28,23 +28,23 @@ export default class SearchList extends Component {
const tabList = [
{
key: 'articles',
tab: '文章',
tab: 'Articles',
},
{
key: 'applications',
tab: '应用',
tab: 'Applications',
},
{
key: 'projects',
tab: '项目',
tab: 'Projects',
},
];
const mainSearch = (
<div style={{ textAlign: 'center' }}>
<Input.Search
placeholder="请输入"
enterButton="搜索"
placeholder="Please Enter"
enterButton="Search For"
size="large"
onSearch={this.handleFormSubmit}
style={{ width: 522 }}
......@@ -57,7 +57,7 @@ export default class SearchList extends Component {
return (
<PageHeaderLayout
title="搜索列表"
title="Search List"
content={mainSearch}
tabList={tabList}
tabActiveKey={location.pathname.replace(`${match.path}/`, '')}
......
......@@ -99,51 +99,51 @@ export default class CoverCardList extends PureComponent {
<div className={styles.coverCardList}>
<Card bordered={false}>
<Form layout="inline">
<StandardFormRow title="所属类目" block style={{ paddingBottom: 11 }}>
<StandardFormRow title="Categories" block style={{ paddingBottom: 11 }}>
<FormItem>
{getFieldDecorator('category')(
<TagSelect onChange={this.handleFormSubmit} expandable>
<TagSelect.Option value="cat1">类目一</TagSelect.Option>
<TagSelect.Option value="cat2">类目二</TagSelect.Option>
<TagSelect.Option value="cat3">类目三</TagSelect.Option>
<TagSelect.Option value="cat4">类目四</TagSelect.Option>
<TagSelect.Option value="cat5">类目五</TagSelect.Option>
<TagSelect.Option value="cat6">类目六</TagSelect.Option>
<TagSelect.Option value="cat7">类目七</TagSelect.Option>
<TagSelect.Option value="cat8">类目八</TagSelect.Option>
<TagSelect.Option value="cat9">类目九</TagSelect.Option>
<TagSelect.Option value="cat10">类目十</TagSelect.Option>
<TagSelect.Option value="cat11">类目十一</TagSelect.Option>
<TagSelect.Option value="cat12">类目十二</TagSelect.Option>
<TagSelect.Option value="cat1">Category 1</TagSelect.Option>
<TagSelect.Option value="cat2">Category 2</TagSelect.Option>
<TagSelect.Option value="cat3">Category 3</TagSelect.Option>
<TagSelect.Option value="cat4">Category 4</TagSelect.Option>
<TagSelect.Option value="cat5">Category 5</TagSelect.Option>
<TagSelect.Option value="cat6">Category 6</TagSelect.Option>
<TagSelect.Option value="cat7">Category 7</TagSelect.Option>
<TagSelect.Option value="cat8">Category 8</TagSelect.Option>
<TagSelect.Option value="cat9">Category 9</TagSelect.Option>
<TagSelect.Option value="cat10">Category 10</TagSelect.Option>
<TagSelect.Option value="cat11">Category 11</TagSelect.Option>
<TagSelect.Option value="cat12">Category 12</TagSelect.Option>
</TagSelect>
)}
</FormItem>
</StandardFormRow>
<StandardFormRow title="其它选项" grid last>
<StandardFormRow title="Other Options" grid last>
<Row gutter={16}>
<Col lg={8} md={10} sm={10} xs={24}>
<FormItem {...formItemLayout} label="作者">
<FormItem {...formItemLayout} label="The Author">
{getFieldDecorator('author', {})(
<Select
onChange={this.handleFormSubmit}
placeholder="不限"
placeholder="Any"
style={{ maxWidth: 200, width: '100%' }}
>
<Option value="lisa">王昭君</Option>
<Option value="lisa">In Progress</Option>
</Select>
)}
</FormItem>
</Col>
<Col lg={8} md={10} sm={10} xs={24}>
<FormItem {...formItemLayout} label="好评度">
<FormItem {...formItemLayout} label="Praise of">
{getFieldDecorator('rate', {})(
<Select
onChange={this.handleFormSubmit}
placeholder="不限"
placeholder="Any"
style={{ maxWidth: 200, width: '100%' }}
>
<Option value="good">优秀</Option>
<Option value="normal">普通</Option>
<Option value="good">Good</Option>
<Option value="normal">Normal</Option>
</Select>
)}
</FormItem>
......
......@@ -31,7 +31,7 @@ const getValue = obj =>
.map(key => obj[key])
.join(',');
const statusMap = ['default', 'processing', 'success', 'error'];
const status = ['关闭', '运行中', '已上线', '异常'];
const status = ['Shutdown', 'Running', 'Has Been Online', 'Unusual'];
const CreateForm = Form.create()(props => {
const { modalVisible, form, handleAdd, handleModalVisible } = props;
......@@ -44,15 +44,15 @@ const CreateForm = Form.create()(props => {
};
return (
<Modal
title="新建规则"
title="New Rules"
visible={modalVisible}
onOk={okHandle}
onCancel={() => handleModalVisible()}
>
<FormItem labelCol={{ span: 5 }} wrapperCol={{ span: 15 }} label="描述">
<FormItem labelCol={{ span: 5 }} wrapperCol={{ span: 15 }} label="Description">
{form.getFieldDecorator('desc', {
rules: [{ required: true, message: 'Please input some description...' }],
})(<Input placeholder="请输入" />)}
})(<Input placeholder="Please Enter" />)}
</FormItem>
</Modal>
);
......@@ -191,7 +191,7 @@ export default class TableList extends PureComponent {
},
});
message.success('添加成功');
message.success('Added Successfully');
this.setState({
modalVisible: false,
});
......@@ -203,16 +203,16 @@ export default class TableList extends PureComponent {
<Form onSubmit={this.handleSearch} layout="inline">
<Row gutter={{ md: 8, lg: 24, xl: 48 }}>
<Col md={8} sm={24}>
<FormItem label="规则编号">
{getFieldDecorator('no')(<Input placeholder="请输入" />)}
<FormItem label="Rule Number">
{getFieldDecorator('no')(<Input placeholder="Please Enter" />)}
</FormItem>
</Col>
<Col md={8} sm={24}>
<FormItem label="使用状态">
<FormItem label="Status of Use">
{getFieldDecorator('status')(
<Select placeholder="请选择" style={{ width: '100%' }}>
<Option value="0">关闭</Option>
<Option value="1">运行中</Option>
<Select placeholder="Please Choose" style={{ width: '100%' }}>
<Option value="0">Shutdown</Option>
<Option value="1">Running</Option>
</Select>
)}
</FormItem>
......@@ -220,13 +220,13 @@ export default class TableList extends PureComponent {
<Col md={8} sm={24}>
<span className={styles.submitButtons}>
<Button type="primary" htmlType="submit">
查询
Inquire
</Button>
<Button style={{ marginLeft: 8 }} onClick={this.handleFormReset}>
重置
Reset
</Button>
<a style={{ marginLeft: 8 }} onClick={this.toggleForm}>
展开 <Icon type="down" />
Unfold <Icon type="down" />
</a>
</span>
</Col>
......@@ -241,50 +241,50 @@ export default class TableList extends PureComponent {
<Form onSubmit={this.handleSearch} layout="inline">
<Row gutter={{ md: 8, lg: 24, xl: 48 }}>
<Col md={8} sm={24}>
<FormItem label="规则编号">
{getFieldDecorator('no')(<Input placeholder="请输入" />)}
<FormItem label="Rule Number">
{getFieldDecorator('no')(<Input placeholder="Please Enter" />)}
</FormItem>
</Col>
<Col md={8} sm={24}>
<FormItem label="使用状态">
<FormItem label="Status of Use">
{getFieldDecorator('status')(
<Select placeholder="请选择" style={{ width: '100%' }}>
<Option value="0">关闭</Option>
<Option value="1">运行中</Option>
<Select placeholder="Please Choose" style={{ width: '100%' }}>
<Option value="0">Shutdown</Option>
<Option value="1">Running</Option>
</Select>
)}
</FormItem>
</Col>
<Col md={8} sm={24}>
<FormItem label="调用次数">
<FormItem label="Number of Calls">
{getFieldDecorator('number')(<InputNumber style={{ width: '100%' }} />)}
</FormItem>
</Col>
</Row>
<Row gutter={{ md: 8, lg: 24, xl: 48 }}>
<Col md={8} sm={24}>
<FormItem label="更新日期">
<FormItem label="Updated">
{getFieldDecorator('date')(
<DatePicker style={{ width: '100%' }} placeholder="请输入更新日期" />
<DatePicker style={{ width: '100%' }} placeholder="Please Enter the Update Date" />
)}
</FormItem>
</Col>
<Col md={8} sm={24}>
<FormItem label="使用状态">
<FormItem label="Status of Use">
{getFieldDecorator('status3')(
<Select placeholder="请选择" style={{ width: '100%' }}>
<Option value="0">关闭</Option>
<Option value="1">运行中</Option>
<Select placeholder="Please Choose" style={{ width: '100%' }}>
<Option value="0">Shutdown</Option>
<Option value="1">Running</Option>
</Select>
)}
</FormItem>
</Col>
<Col md={8} sm={24}>
<FormItem label="使用状态">
<FormItem label="Status of Use">
{getFieldDecorator('status4')(
<Select placeholder="请选择" style={{ width: '100%' }}>
<Option value="0">关闭</Option>
<Option value="1">运行中</Option>
<Select placeholder="Please Choose" style={{ width: '100%' }}>
<Option value="0">Shutdown</Option>
<Option value="1">Running</Option>
</Select>
)}
</FormItem>
......@@ -293,13 +293,13 @@ export default class TableList extends PureComponent {
<div style={{ overflow: 'hidden' }}>
<span style={{ float: 'right', marginBottom: 24 }}>
<Button type="primary" htmlType="submit">
查询
Inquire
</Button>
<Button style={{ marginLeft: 8 }} onClick={this.handleFormReset}>
重置
Reset
</Button>
<a style={{ marginLeft: 8 }} onClick={this.toggleForm}>
收起 <Icon type="up" />
Collapse <Icon type="up" />
</a>
</span>
</div>
......@@ -317,24 +317,24 @@ export default class TableList extends PureComponent {
const columns = [
{
title: '规则编号',
title: 'Rule Number',
dataIndex: 'no',
},
{
title: '描述',
title: 'Description',
dataIndex: 'description',
},
{
title: '服务调用次数',
title: 'Service Calls',
dataIndex: 'callNo',
sorter: true,
align: 'right',
render: val => `${val} 万`,
render: val => `${val}0000`, //Ten thousand
// mark to display a total number
needTotal: true,
},
{
title: '状态',
title: 'Status',
dataIndex: 'status',
filters: [
{
......@@ -360,18 +360,18 @@ export default class TableList extends PureComponent {
},
},
{
title: '更新时间',
title: 'Update At',
dataIndex: 'updatedAt',
sorter: true,
render: val => <span>{moment(val).format('YYYY-MM-DD HH:mm:ss')}</span>,
},
{
title: '操作',
title: 'Operating',
render: () => (
<Fragment>
<a href="">配置</a>
<a href="">Configuration</a>
<Divider type="vertical" />
<a href="">订阅警报</a>
<a href="">Subscribe to Alerts</a>
</Fragment>
),
},
......@@ -379,8 +379,8 @@ export default class TableList extends PureComponent {
const menu = (
<Menu onClick={this.handleMenuClick} selectedKeys={[]}>
<Menu.Item key="remove">删除</Menu.Item>
<Menu.Item key="approval">批量审批</Menu.Item>
<Menu.Item key="remove">Delete</Menu.Item>
<Menu.Item key="approval">Batch Approval</Menu.Item>
</Menu>
);
......@@ -390,20 +390,20 @@ export default class TableList extends PureComponent {
};
return (
<PageHeaderLayout title="查询表格">
<PageHeaderLayout title="Inquiry Form">
<Card bordered={false}>
<div className={styles.tableList}>
<div className={styles.tableListForm}>{this.renderForm()}</div>
<div className={styles.tableListOperator}>
<Button icon="plus" type="primary" onClick={() => this.handleModalVisible(true)}>
新建
New
</Button>
{selectedRows.length > 0 && (
<span>
<Button>批量操作</Button>
<Button>Batch Operation</Button>
<Dropdown overlay={menu}>
<Button>
更多操作 <Icon type="down" />
More Operations <Icon type="down" />
</Button>
</Dropdown>
</span>
......
This diff is collapsed.
......@@ -9,33 +9,33 @@ const { Description } = DescriptionList;
const progressColumns = [
{
title: '时间',
title: 'Time',
dataIndex: 'time',
key: 'time',
},
{
title: '当前进度',
title: 'Current Progress',
dataIndex: 'rate',
key: 'rate',
},
{
title: '状态',
title: 'Status',
dataIndex: 'status',
key: 'status',
render: text =>
text === 'success' ? (
<Badge status="success" text="成功" />
<Badge status="success" text="Success" />
) : (
<Badge status="processing" text="进行中" />
<Badge status="processing" text="Processing" />
),
},
{
title: '操作员ID',
title: 'Operator ID',
dataIndex: 'operator',
key: 'operator',
},
{
title: '耗时',
title: 'Time Consumption',
dataIndex: 'cost',
key: 'cost',
},
......@@ -65,7 +65,7 @@ export default class BasicProfile extends Component {
amount += Number(item.amount);
});
goodsData = basicGoods.concat({
id: '总计',
id: 'Total',
num,
amount,
});
......@@ -82,7 +82,7 @@ export default class BasicProfile extends Component {
};
const goodsColumns = [
{
title: '商品编号',
title: 'Product Number',
dataIndex: 'id',
key: 'id',
render: (text, row, index) => {
......@@ -90,7 +90,7 @@ export default class BasicProfile extends Component {
return <a href="">{text}</a>;
}
return {
children: <span style={{ fontWeight: 600 }}>总计</span>,
children: <span style={{ fontWeight: 600 }}> Total</span>,
props: {
colSpan: 4,
},
......@@ -98,26 +98,26 @@ export default class BasicProfile extends Component {
},
},
{
title: '商品名称',
title: 'Product Name',
dataIndex: 'name',
key: 'name',
render: renderContent,
},
{
title: '商品条码',
title: 'Barcode',
dataIndex: 'barcode',
key: 'barcode',
render: renderContent,
},
{
title: '单价',
title: 'Price',
dataIndex: 'price',
key: 'price',
align: 'right',
render: renderContent,
},
{
title: '数量(件)',
title: 'Quantity(Piece)',
dataIndex: 'num',
key: 'num',
align: 'right',
......@@ -129,7 +129,7 @@ export default class BasicProfile extends Component {
},
},
{
title: '金额',
title: 'Amount',
dataIndex: 'amount',
key: 'amount',
align: 'right',
......@@ -142,24 +142,24 @@ export default class BasicProfile extends Component {
},
];
return (
<PageHeaderLayout title="基础详情页">
<PageHeaderLayout title="Basic Details Page">
<Card bordered={false}>
<DescriptionList size="large" title="退款申请" style={{ marginBottom: 32 }}>
<Description term="取货单号">1000000000</Description>
<Description term="状态">已取货</Description>
<Description term="销售单号">1234123421</Description>
<Description term="子订单">3214321432</Description>
<DescriptionList size="large" title="Refund Application" style={{ marginBottom: 32 }}>
<Description term="Pickup No.">1000000000</Description>
<Description term="Status">Picked</Description>
<Description term="Sales Order Number">1234123421</Description>
<Description term="Suborders">3214321432</Description>
</DescriptionList>
<Divider style={{ marginBottom: 32 }} />
<DescriptionList size="large" title="用户信息" style={{ marginBottom: 32 }}>
<Description term="用户姓名">付小小</Description>
<Description term="联系电话">18100000000</Description>
<DescriptionList size="large" title="User Info" style={{ marginBottom: 32 }}>
<Description term="Username">Fu Xiaoxiao</Description>
<Description term="Contact Number">18100000000</Description>
<Description term="常用快递">菜鸟仓储</Description>
<Description term="取货地址">浙江省杭州市西湖区万塘路18</Description>
<Description term="备注"></Description>
<Description term="Pickup Address">No.18 Wantang Road, Xihu District, Hangzhou City, Zhejiang Province, China</Description>
<Description term="Note">No</Description>
</DescriptionList>
<Divider style={{ marginBottom: 32 }} />
<div className={styles.title}>退货商品</div>
<div className={styles.title}>Return Goods</div>
<Table
style={{ marginBottom: 24 }}
pagination={false}
......@@ -168,7 +168,7 @@ export default class BasicProfile extends Component {
columns={goodsColumns}
rowKey="id"
/>
<div className={styles.title}>退货进度</div>
<div className={styles.title}>Return Progress</div>
<Table
style={{ marginBottom: 16 }}
pagination={false}
......
......@@ -13,32 +13,32 @@ const extra = (
marginBottom: 16,
}}
>
您提交的内容有如下错误
Your Submission Has The Following Error
</div>
<div style={{ marginBottom: 16 }}>
<Icon style={{ color: '#f5222d', marginRight: 8 }} type="close-circle-o" />您的账户已被冻结
<Icon style={{ color: '#f5222d', marginRight: 8 }} type="close-circle-o" />Your account has been frozen
<a style={{ marginLeft: 16 }}>
立即解冻 <Icon type="right" />
Thaw immediately <Icon type="right" />
</a>
</div>
<div>
<Icon style={{ color: '#f5222d', marginRight: 8 }} type="close-circle-o" />您的账户还不具备申请资格
<Icon style={{ color: '#f5222d', marginRight: 8 }} type="close-circle-o" />Your account is not eligible for application
<a style={{ marginLeft: 16 }}>
立即升级 <Icon type="right" />
Upgrade immediately <Icon type="right" />
</a>
</div>
</Fragment>
);
const actions = <Button type="primary">返回修改</Button>;
const actions = <Button type="primary">Return to Edit</Button>;
export default () => (
<PageHeaderLayout>
<Card bordered={false}>
<Result
type="error"
title="提交失败"
description="请核对并修改以下信息后,再重新提交。"
title="Submission Failed"
description="Please check and modify the following information before resubmitting。"
extra={extra}
actions={actions}
style={{ marginTop: 48, marginBottom: 16 }}
......
......@@ -15,7 +15,7 @@ const desc1 = (
}}
>
<div style={{ margin: '8px 0 4px' }}>
曲丽丽<Icon style={{ marginLeft: 8 }} type="dingding-o" />
John Doe<Icon style={{ marginLeft: 8 }} type="dingding-o" />
</div>
<div>2016-12-12 12:32</div>
</div>
......@@ -24,10 +24,10 @@ const desc1 = (
const desc2 = (
<div style={{ fontSize: 12, position: 'relative', left: 42 }}>
<div style={{ margin: '8px 0 4px' }}>
周毛毛<Icon type="dingding-o" style={{ color: '#00A0E9', marginLeft: 8 }} />
Zhou Maomao<Icon type="dingding-o" style={{ color: '#00A0E9', marginLeft: 8 }} />
</div>
<div>
<a href="">催一下</a>
<a href="">Urgent</a>
</div>
</div>
);
......@@ -42,36 +42,36 @@ const extra = (
marginBottom: 20,
}}
>
项目名称
Project Name
</div>
<Row style={{ marginBottom: 16 }}>
<Col xs={24} sm={12} md={12} lg={12} xl={6}>
<span style={{ color: 'rgba(0, 0, 0, 0.85)' }}>项目 ID</span>
<span style={{ color: 'rgba(0, 0, 0, 0.85)' }}>Project ID</span>
23421
</Col>
<Col xs={24} sm={12} md={12} lg={12} xl={6}>
<span style={{ color: 'rgba(0, 0, 0, 0.85)' }}>负责人</span>
曲丽丽
<span style={{ color: 'rgba(0, 0, 0, 0.85)' }}>Principal</span>
John Doe
</Col>
<Col xs={24} sm={24} md={24} lg={24} xl={12}>
<span style={{ color: 'rgba(0, 0, 0, 0.85)' }}>生效时间</span>
<span style={{ color: 'rgba(0, 0, 0, 0.85)' }}>Effective Time</span>
2016-12-12 ~ 2017-12-12
</Col>
</Row>
<Steps style={{ marginLeft: -42, width: 'calc(100% + 84px)' }} progressDot current={1}>
<Step title={<span style={{ fontSize: 14 }}>创建项目</span>} description={desc1} />
<Step title={<span style={{ fontSize: 14 }}>部门初审</span>} description={desc2} />
<Step title={<span style={{ fontSize: 14 }}>财务复核</span>} />
<Step title={<span style={{ fontSize: 14 }}>完成</span>} />
<Step title={<span style={{ fontSize: 14 }}>Create a Project</span>} description={desc1} />
<Step title={<span style={{ fontSize: 14 }}>Department First Review</span>} description={desc2} />
<Step title={<span style={{ fontSize: 14 }}>Financial Review</span>} />
<Step title={<span style={{ fontSize: 14 }}>Carry Out</span>} />
</Steps>
</Fragment>
);
const actions = (
<Fragment>
<Button type="primary">返回列表</Button>
<Button>查看项目</Button>
<Button> </Button>
<Button type="primary">Back to List</Button>
<Button>Check Item</Button>
<Button>Print</Button>
</Fragment>
);
......@@ -80,11 +80,8 @@ export default () => (
<Card bordered={false}>
<Result
type="success"
title="提交成功"
description="提交结果页用于反馈一系列操作任务的处理结果,
如果仅是简单操作,使用 Message 全局提示反馈即可。
本文字区域可以展示简单的补充说明,如果有类似展示
“单据”的需求,下面这个灰色区域可以呈现比较复杂的内容。"
title="Submit Successfully"
description="The submission result page is used to feed back the results of a series of operations. If it is a simple operation, use the Message global feedback. This text area can show simple supplementary explanations. If there are similar requirements for displaying 'documents', the following gray area can present more complicated content."
extra={extra}
actions={actions}
style={{ marginTop: 48, marginBottom: 16 }}
......
......@@ -50,38 +50,38 @@ export default class LoginPage extends Component {
return (
<div className={styles.main}>
<Login defaultActiveKey={type} onTabChange={this.onTabChange} onSubmit={this.handleSubmit}>
<Tab key="account" tab="账户密码登录">
<Tab key="account" tab="Account">
{login.status === 'error' &&
login.type === 'account' &&
!login.submitting &&
this.renderMessage('账户或密码错误(admin/888888)')}
<UserName name="userName" placeholder="admin/user" />
<Password name="password" placeholder="888888/123456" />
this.renderMessage('Account or Password Do Not Match')}
<UserName name="userName" placeholder="Login"/>
<Password name="password" placeholder="Password" />
</Tab>
<Tab key="mobile" tab="手机号登录">
<Tab key="mobile" tab="Mobile">
{login.status === 'error' &&
login.type === 'mobile' &&
!login.submitting &&
this.renderMessage('验证码错误')}
this.renderMessage('Verification Code Error')}
<Mobile name="mobile" />
<Captcha name="captcha" />
</Tab>
<div>
<Checkbox checked={this.state.autoLogin} onChange={this.changeAutoLogin}>
自动登录
Remember me
</Checkbox>
<a style={{ float: 'right' }} href="">
忘记密码
Forgot Password?
</a>
</div>
<Submit loading={submitting}>登录</Submit>
<Submit loading={submitting}>Submit</Submit>
<div className={styles.other}>
其他登录方式
<Icon className={styles.icon} type="alipay-circle" />
<Icon className={styles.icon} type="taobao-circle" />
<Icon className={styles.icon} type="weibo-circle" />
Other ways to log in
<Icon className={styles.icon} type="facebook" />
<Icon className={styles.icon} type="google" />
<Icon className={styles.icon} type="twitter" />
<Link className={styles.register} to="/user/register">
注册账户
Register
</Link>
</div>
</Login>
......
......@@ -9,9 +9,9 @@ const { Option } = Select;
const InputGroup = Input.Group;
const passwordStatusMap = {
ok: <div className={styles.success}>强度:强</div>,
pass: <div className={styles.warning}>强度:中</div>,
poor: <div className={styles.error}>强度:太短</div>,
ok: <div className={styles.success}>Ok</div>,
pass: <div className={styles.warning}>Pass</div>,
poor: <div className={styles.error}>Poor</div>,
};
const passwordProgressMap = {
......@@ -108,7 +108,7 @@ export default class Register extends Component {
checkPassword = (rule, value, callback) => {
if (!value) {
this.setState({
help: '请输入密码!',
help: 'HELP!',
visible: !!value,
});
callback('error');
......@@ -162,21 +162,21 @@ export default class Register extends Component {
const { count, prefix } = this.state;
return (
<div className={styles.main}>
<h3>注册</h3>
<h3>Registro</h3>
<Form onSubmit={this.handleSubmit}>
<FormItem>
{getFieldDecorator('mail', {
rules: [
{
required: true,
message: '请输入邮箱地址!',
message: 'Please Input the E-mail Address!',
},
{
type: 'email',
message: '邮箱地址格式错误!',
message: 'Wrong E-mail Address Format!',
},
],
})(<Input size="large" placeholder="邮箱" />)}
})(<Input size="large" placeholder="E-mail" />)}
</FormItem>
<FormItem help={this.state.help}>
<Popover
......@@ -185,7 +185,7 @@ export default class Register extends Component {
{passwordStatusMap[this.getPasswordStatus()]}
{this.renderPasswordProgress()}
<div style={{ marginTop: 10 }}>
请至少输入 6 个字符。请不要使用容易被猜到的密码。
Please enter at least 6 characters. Please do not use passwords that are easy to guess.
</div>
</div>
}
......@@ -199,7 +199,7 @@ export default class Register extends Component {
validator: this.checkPassword,
},
],
})(<Input size="large" type="password" placeholder="至少6位密码,区分大小写" />)}
})(<Input size="large" type="password" placeholder="Insert your password" />)}
</Popover>
</FormItem>
<FormItem>
......@@ -207,13 +207,13 @@ export default class Register extends Component {
rules: [
{
required: true,
message: '请确认密码!',
message: 'Please Confirm Your Password!',
},
{
validator: this.checkConfirm,
},
],
})(<Input size="large" type="password" placeholder="确认密码" />)}
})(<Input size="large" type="password" placeholder="Confirm your password" />)}
</FormItem>
<FormItem>
<InputGroup compact>
......@@ -230,14 +230,14 @@ export default class Register extends Component {
rules: [
{
required: true,
message: '请输入手机号!',
message: 'Please Enter Phone Number',
},
{
pattern: /^1\d{10}$/,
message: '手机号格式错误!',
message: 'Malformed Phone Number!',
},
],
})(<Input size="large" style={{ width: '80%' }} placeholder="11位手机号" />)}
})(<Input size="large" style={{ width: '80%' }} placeholder="Insert Your Cellphone Number" />)}
</InputGroup>
</FormItem>
<FormItem>
......@@ -247,10 +247,10 @@ export default class Register extends Component {
rules: [
{
required: true,
message: '请输入验证码!',
message: 'Please Enter Verification Code',
},
],
})(<Input size="large" placeholder="验证码" />)}
})(<Input size="large" placeholder="Verify Code" />)}
</Col>
<Col span={8}>
<Button
......@@ -259,7 +259,7 @@ export default class Register extends Component {
className={styles.getCaptcha}
onClick={this.onGetCaptcha}
>
{count ? `${count} s` : '获取验证码'}
{count ? `${count} s` : 'Send Code'}
</Button>
</Col>
</Row>
......@@ -272,10 +272,10 @@ export default class Register extends Component {
type="primary"
htmlType="submit"
>
注册
Submit
</Button>
<Link className={styles.login} to="/user/login">
使用已有账户登录
Already Have an Account
</Link>
</FormItem>
</Form>
......
......@@ -8,11 +8,11 @@ const actions = (
<div className={styles.actions}>
<a href="">
<Button size="large" type="primary">
查看邮箱
Verificar
</Button>
</a>
<Link to="/">
<Button size="large">返回首页</Button>
<Button size="large">Voltar</Button>
</Link>
</div>
);
......@@ -23,10 +23,10 @@ export default ({ location }) => (
type="success"
title={
<div className={styles.title}>
你的账户:{location.state ? location.state.account : 'AntDesign@example.com'} 注册成功
Sua conta{location.state ? location.state.account : 'AntDesign@example.com'} foi registrada com sucesso.
</div>
}
description="激活邮件已发送到你的邮箱中,邮件有效期为24小时。请及时登录邮箱,点击邮件中的链接激活帐户。"
description="Um email foi enviado para a sua conta. Por favor, ative a sua conta clicando no link. O link será desativado em 24H."
actions={actions}
style={{ marginTop: 56 }}
/>
......
......@@ -59,6 +59,7 @@ export default function request(url, options) {
// newOptions.body is FormData
newOptions.headers = {
Accept: 'application/json',
'Content-Type': 'multipart/form-data',
...newOptions.headers,
};
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment