Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature[profile]: add profile page #1953

Merged
merged 6 commits into from Apr 25, 2019
Merged
Changes from 1 commit
Commits
File filter...
Filter file types
Jump to…
Jump to file or symbol
Failed to load files and symbols.

Always

Just for now

Next

Implement mockup for profile page

  • Loading branch information...
tuandm committed Apr 22, 2019
commit cde663ab152c016058784d6c783d91de882869a1
@@ -58,3 +58,11 @@ export function numberFormatter(num, digits) {
export function toThousandFilter(num) {
return (+num || 0).toString().replace(/^-?\d+/g, m => m.replace(/(?=(?!\b)(\d{3})+$)/g, ','))
}

/**
* Upper case first char
* @param {String} string
*/
export function uppercaseFirst(string) {
return string.charAt(0).toUpperCase() + string.slice(1)
}
@@ -0,0 +1 @@
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1555641167698" class="icon" style="" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="977" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><defs><style type="text/css"></style></defs><path d="M702.784 879.008c-55.84 0-148.992 16.48-163.552 54.496l0 0.832c-32.448 0.864-40.032 0-54.496 0-14.528-38.048-107.68-54.528-163.552-54.528l-299.84 0 0-790.496 326.016 0c70.368 0 131.168 36.128 164.608 89.504 33.408-53.344 94.304-89.504 164.704-89.504l326.016 0 0 789.728-299.872-0.032zM484.736 252.864c0-63.744-68.832-109.024-136.288-109.024l-272.608 0 0 681.44 245.344 0c54.08-0.928 139.36 0.544 163.552 40.416l0-30.56c-1.024-37.792-0.032-89.312 0-91.36l0-473.408 0.032-17.536zM948.128 143.776l-272.544 0c-67.488 0-136.32 45.28-136.32 108.928l0 490.464c0.032 2.112 1.056 53.6 0 91.232l0 30.56c24.192-39.776 109.472-41.344 163.552-40.384l245.344 0 0-680.768z" p-id="978"></path></svg>
@@ -0,0 +1 @@
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1555640763920" class="icon" style="" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="1499" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><defs><style type="text/css"></style></defs><path d="M264.032 719.136l256.064 0c11.04 17.088 23.584 32.96 37.792 47.296l-293.856 0 0-47.296zM264.032 644.32l221.664 0c-4.48-15.264-7.712-31.04-9.696-47.264l-211.968 0 0 47.264zM264.032 522.272l212.64 0c2.208-16.16 5.472-32.032 10.272-47.264l-222.944 0 0 47.264zM677.344 839.168l0 41.344c0 19.776-16.064 35.872-35.776 35.872l-537.184 0c-19.744 0-35.744-16.096-35.744-35.872l0-599.168 178.016-148.128 0 157.248-93.728 0 0 47.264 140.992 0 0-230.048 347.648 0c19.744 0 35.776 16.096 35.776 35.808l0 141.408c15.232-4.768 31.072-7.968 47.296-10.208l0-131.168c0.032-45.792-37.248-83.104-83.04-83.104l-381.408 0-238.816 198.72 0 621.344c0 45.792 37.248 83.104 83.04 83.104l537.184 0c45.792 0 83.072-37.248 83.072-83.104l0-31.168c-16.224-2.208-32.064-5.408-47.296-10.144l0 0zM199.84 475.04l-61.024 0 0 47.264 61.024 0 0-47.264zM138.848 766.432l61.024 0 0-47.296-61.024 0 0 47.296zM199.84 597.088l-61.024 0 0 47.264 61.024 0 0-47.264zM887.648 490.784l-37.536-28.768-95.424 124.48-85.792-65.76-28.832 37.536 123.36 94.56 124.224-162.048zM1002.656 562.048c0-131.68-107.104-238.752-238.784-238.752-131.616 0-238.688 107.104-238.688 238.752s107.104 238.752 238.688 238.752c131.648 0 238.752-107.072 238.752-238.752l0 0zM955.36 562.048c0 105.536-85.888 191.52-191.52 191.52-105.568 0-191.552-85.92-191.552-191.52s85.824-191.52 191.552-191.52c105.632 0 191.52 85.92 191.52 191.52l0 0z" p-id="1500"></path></svg>
@@ -61,12 +61,14 @@ export default {
theme: 'Theme',
clipboardDemo: 'Clipboard',
i18n: 'I18n',
externalLink: 'External Link'
externalLink: 'External Link',
profile: 'Profile'
},
navbar: {
logOut: 'Log Out',
dashboard: 'Dashboard',
github: 'Github',
logOut: 'Log Out',
profile: 'Profile',
theme: 'Theme',
size: 'Global Size'
},
@@ -61,12 +61,14 @@ export default {
theme: '换肤',
clipboardDemo: 'Clipboard',
i18n: '国际化',
externalLink: '外链'
externalLink: '外链',
profile: '个人资料页'
},
navbar: {
logOut: '退出登录',
dashboard: '首页',
github: '项目地址',
logOut: '退出登录',
profile: '个人资料页',
theme: '换肤',
size: '布局大小'
},
@@ -26,6 +26,11 @@
<i class="el-icon-caret-bottom" />
</div>
<el-dropdown-menu slot="dropdown">
<router-link to="'/profile/index">
<el-dropdown-item>
{{ $t('navbar.profile') }}
</el-dropdown-item>
</router-link>
<router-link to="/">
<el-dropdown-item>
{{ $t('navbar.dashboard') }}
@@ -107,6 +107,20 @@ export const constantRoutes = [
meta: { title: 'guide', icon: 'guide', noCache: true }
}
]
},
{
path: '/profile',
component: Layout,
redirect: '/profile/index',
hidden: true,
children: [
{
path: 'index',
component: () => import('@/views/profile/index'),
name: 'Profile',
meta: { title: 'profile', icon: 'user', noCache: true }
}
]
}
]

ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.