From d79cf0c1ed1aef47ca4e23d5e37c70d14347beb5 Mon Sep 17 00:00:00 2001 From: neverland Date: Fri, 29 Dec 2017 10:35:30 +0800 Subject: [PATCH] [Doc] update site UI (#490) --- README.md | 1 + README.zh-CN.md | 44 ++++++++++++++++++++---------------- docs/markdown/en-US/intro.md | 2 ++ docs/markdown/zh-CN/intro.md | 3 +++ docs/src/doc.config.js | 24 ++------------------ package.json | 2 +- yarn.lock | 6 ++--- 7 files changed, 36 insertions(+), 46 deletions(-) diff --git a/README.md b/README.md index 60f725bf3..9ea8ae4b4 100644 --- a/README.md +++ b/README.md @@ -101,6 +101,7 @@ Modern browsers and Android 4.0+, iOS 6+. * [Documentation](https://www.youzanyun.com/zanui/vant) * [Changelog](https://www.youzanyun.com/zanui/vant#/en-US/component/changelog) +* [React UI](https://www.youzanyun.com/zanui/zent) * [Weapp UI](https://github.com/youzan/zanui-weapp) * [Vant Demo](https://github.com/youzan/vant-demo) * [vue-cli-template-vant](https://github.com/youzan/vue-cli-template-vant) diff --git a/README.zh-CN.md b/README.zh-CN.md index 755bdb760..90ab78423 100644 --- a/README.zh-CN.md +++ b/README.zh-CN.md @@ -7,20 +7,20 @@

A Vue.js 2.0 Mobile UI at YouZan

-[![Build Status](https://travis-ci.org/youzan/vant.svg?branch=master)](https://travis-ci.org/youzan/vant) -[![downloads](https://img.shields.io/npm/dt/vant.svg)](https://www.npmjs.com/package/vant) +[![Build Status](https://travis-ci.org/youzan/vant.svg?branch=master)](https://travis-ci.org/youzan/vant) +[![downloads](https://img.shields.io/npm/dt/vant.svg)](https://www.npmjs.com/package/vant) [![Coverage Status](https://img.shields.io/codecov/c/github/youzan/vant/dev.svg)](https://codecov.io/github/youzan/vant?branch=dev) -[![npm version](https://img.shields.io/npm/v/vant.svg?style=flat)](https://www.npmjs.com/package/vant) +[![npm version](https://img.shields.io/npm/v/vant.svg?style=flat)](https://www.npmjs.com/package/vant) [![license](https://img.shields.io/npm/l/vant.svg)](https://www.npmjs.com/package/vant) - + ## 特性 -- 48+ 个经过有赞线上业务检验的组件 -- 单元测试覆盖率超过90% -- 完善的文档和示例 -- 支持 [babel-plugin-import](https://github.com/ant-design/babel-plugin-import) -- 支持 TypeScript -- 支持 SSR +* 48+ 个经过有赞线上业务检验的组件 +* 单元测试覆盖率超过 90% +* 完善的文档和示例 +* 支持 [babel-plugin-import](https://github.com/ant-design/babel-plugin-import) +* 支持 TypeScript +* 支持 SSR

components preview @@ -31,10 +31,11 @@ ```shell npm i -S vant ``` - + ## 快速上手 -#### 方式一. 使用 [babel-plugin-import](https://github.com/ant-design/babel-plugin-import) (推荐) +#### 方式一. 使用  [babel-plugin-import](https://github.com/ant-design/babel-plugin-import) (推荐) + ```bash # 安装 babel-plugin-import 插件 npm i babel-plugin-import -D @@ -62,7 +63,7 @@ import { Button } from 'vant/lib/button'; import 'vant/lib/vant-css/base.css'; import 'vant/lib/vant-css/button.css'; ``` - + #### 方式三. 导入所有组件 ```js @@ -92,21 +93,24 @@ Vue.use(Vant); 使用过程中发现任何问题都可以提 [Issue](https://github.com/youzan/vant/issues) 给我们,当然,我们也非常欢迎你给我们发 [PR](https://github.com/youzan/vant/pulls)。 ## 浏览器支持 + 现代浏览器以及 Android 4.0+, iOS 6+. ## 手机预览 -可以手机扫码以下二维码访问手机端demo: +可以手机扫码以下二维码访问手机端 demo: ![qrcode](https://img.yzcdn.cn/v2/image/youzanyun/zanui/pc/zanui_vue_mobile_preview_03.png) ## 链接 -- [详细文档](https://www.youzanyun.com/zanui/vant) -- [更新日志](https://www.youzanyun.com/zanui/vant#/zh-CN/component/changelog) -- [微信小程序组件库](https://github.com/youzan/zanui-weapp) -- [vant-demo](https://github.com/youzan/vant-demo) -- [vue-cli-template-vant](https://github.com/youzan/vue-cli-template-vant) - + +* [详细文档](https://www.youzanyun.com/zanui/vant) +* [更新日志](https://www.youzanyun.com/zanui/vant#/zh-CN/component/changelog) +* [React 组件库](https://www.youzanyun.com/zanui/zent) +* [微信小程序组件库](https://github.com/youzan/zanui-weapp) +* [vant-demo](https://github.com/youzan/vant-demo) +* [vue-cli-template-vant](https://github.com/youzan/vue-cli-template-vant) + ## 开源协议 本项目基于 [MIT](https://zh.wikipedia.org/wiki/MIT%E8%A8%B1%E5%8F%AF%E8%AD%89) 协议,请自由地享受和参与开源。 diff --git a/docs/markdown/en-US/intro.md b/docs/markdown/en-US/intro.md index c9dd2ebe3..b0dab9129 100644 --- a/docs/markdown/en-US/intro.md +++ b/docs/markdown/en-US/intro.md @@ -28,8 +28,10 @@ Modern browsers and Android 4.0+, iOS 6+. ### Links +* [Feedback](https://github.com/youzan/vant/issues) * [Changelog](https://www.youzanyun.com/zanui/vant#/en-US/component/changelog) * [Weapp UI](https://github.com/youzan/zanui-weapp) +* [React UI](https://www.youzanyun.com/zanui/zent) * [Vant Demo](https://github.com/youzan/vant-demo) * [vue-cli-template-vant](https://github.com/youzan/vue-cli-template-vant) diff --git a/docs/markdown/zh-CN/intro.md b/docs/markdown/zh-CN/intro.md index c8bbe639f..7f30e4ebd 100644 --- a/docs/markdown/zh-CN/intro.md +++ b/docs/markdown/zh-CN/intro.md @@ -30,7 +30,10 @@ ### 链接 +* [意见反馈](https://github.com/youzan/vant/issues) +* [加入我们](https://job.youzan.com) * [更新日志](https://www.youzanyun.com/zanui/vant#/zh-CN/component/changelog) +* [React 组件库](https://www.youzanyun.com/zanui/zent) * [微信小程序组件库](https://github.com/youzan/zanui-weapp) * [vant-demo](https://github.com/youzan/vant-demo) * [vue-cli-template-vant](https://github.com/youzan/vue-cli-template-vant) diff --git a/docs/src/doc.config.js b/docs/src/doc.config.js index 65985511a..5bc357917 100644 --- a/docs/src/doc.config.js +++ b/docs/src/doc.config.js @@ -4,7 +4,7 @@ module.exports = { header: { logo: { image: 'https://img.yzcdn.cn/public_files/2017/12/18/fd78cf6bb5d12e2a119d0576bedfd230.png', - title: 'ZanUI', + title: 'Zan UI', href: 'http://www.youzanyun.com/zanui' }, nav: { @@ -16,16 +16,6 @@ module.exports = { github: 'https://github.com/youzan/vant' } }, - footer: { - github: 'https://github.com/youzan/vant', - nav: { - 'React 组件库': 'https://www.youzanyun.com/zanui/zent', - 小程序组件库: 'https://github.com/youzan/zanui-weapp', - 意见反馈: 'https://github.com/youzan/vant/issues', - 开发指南: 'https://github.com/youzan/vant/blob/dev/.github/CONTRIBUTING.zh-CN.md', - 加入我们: 'https://job.youzan.com' - } - }, nav: [ { name: '开发指南', @@ -292,7 +282,7 @@ module.exports = { header: { logo: { image: 'https://img.yzcdn.cn/public_files/2017/12/18/fd78cf6bb5d12e2a119d0576bedfd230.png', - title: 'ZanUI', + title: 'Zan UI', href: 'http://www.youzanyun.com/zanui' }, nav: { @@ -304,16 +294,6 @@ module.exports = { github: 'https://github.com/youzan/vant' } }, - footer: { - github: 'https://github.com/youzan/vant', - nav: { - 'React UI': 'https://www.youzanyun.com/zanui/zent', - 'Weapp UI': 'https://github.com/youzan/zanui-weapp', - Feedback: 'https://github.com/youzan/vant/issues', - Contribute: - 'https://github.com/youzan/vant/blob/dev/.github/CONTRIBUTING.md' - } - }, nav: [ { name: 'Essentials', diff --git a/package.json b/package.json index ae66f2b78..fdc03a505 100644 --- a/package.json +++ b/package.json @@ -95,7 +95,7 @@ "style-loader": "^0.19.1", "uppercamelcase": "^3.0.0", "url-loader": "^0.6.2", - "vant-doc": "0.3.20", + "vant-doc": "1.0.0", "vue": "^2.5.13", "vue-loader": "^13.6.1", "vue-router": "^3.0.1", diff --git a/yarn.lock b/yarn.lock index 69e70312e..0a8550532 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6574,9 +6574,9 @@ validate-npm-package-license@^3.0.1: spdx-correct "~1.0.0" spdx-expression-parse "~1.0.0" -vant-doc@0.3.20: - version "0.3.20" - resolved "https://registry.yarnpkg.com/vant-doc/-/vant-doc-0.3.20.tgz#3bed2e978c85634e09547b5a61b0620f95428142" +vant-doc@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/vant-doc/-/vant-doc-1.0.0.tgz#bb8707830670cc16e28dd7da89513416486639a0" dependencies: cheerio "0.22.0" decamelize "^1.2.0"