From a991aea5817ae72941d820eda77b2ad4ea820916 Mon Sep 17 00:00:00 2001 From: cookfront Date: Fri, 24 Mar 2017 22:02:38 +0800 Subject: [PATCH] fix docs --- docs/assets/docs.css | 6 +-- docs/components/demo-block.vue | 8 ++-- docs/components/side-nav.vue | 3 +- docs/examples-docs/actionsheet.md | 2 +- docs/examples-docs/badge.md | 2 +- docs/examples-docs/button.md | 16 ++------ docs/examples-docs/cell.md | 2 +- docs/examples-docs/checkbox.md | 2 +- docs/examples-docs/datetime-picker.md | 2 +- docs/examples-docs/dialog.md | 2 +- docs/examples-docs/field.md | 2 +- docs/examples-docs/icon.md | 6 ++- docs/examples-docs/loading.md | 2 +- docs/examples-docs/picker.md | 4 +- docs/examples-docs/popup.md | 2 +- docs/examples-docs/progress.md | 2 +- docs/examples-docs/quantity.md | 2 +- docs/examples-docs/radio.md | 2 +- docs/examples-docs/search.md | 4 +- docs/examples-docs/swipe.md | 2 +- docs/examples-docs/switch.md | 2 +- docs/examples-docs/tab.md | 2 +- docs/examples-docs/tag.md | 2 +- docs/examples-docs/toast.md | 2 +- docs/examples-docs/uploader.md | 2 +- docs/nav.config.json | 54 ++++++++++++------------- packages/zanui-css/src/button_group.css | 33 --------------- 27 files changed, 65 insertions(+), 105 deletions(-) delete mode 100644 packages/zanui-css/src/button_group.css diff --git a/docs/assets/docs.css b/docs/assets/docs.css index 3ab54888d..461e2b1db 100644 --- a/docs/assets/docs.css +++ b/docs/assets/docs.css @@ -78,15 +78,15 @@ ul, ol { .page-container { background-color: #fff; position: relative; - display: table; + display: flex; width: 100%; + overflow: hidden; } .page-content { box-sizing: border-box; - margin-left: 220px; padding: 0 40px; - display: table-cell; + flex: 1; section { > h1, diff --git a/docs/components/demo-block.vue b/docs/components/demo-block.vue index f0291eebf..d9e9dc495 100644 --- a/docs/components/demo-block.vue +++ b/docs/components/demo-block.vue @@ -23,25 +23,27 @@ export default { code { font-family: Menlo, Monaco, Consolas, Courier, monospace; + overflow: auto; + white-space: pre-wrap; } .examples { width: 320px; - float: right; box-sizing: border-box; padding: 10px 0 0; min-height: 200px; - max-height: 600px; + max-height: 500px; overflow: auto; background-color: #F8F8F8; border: 1px solid #E5E5E5; + float: right; } .highlight { - margin-right: 345px; box-sizing: border-box; border: 1px solid #E5E5E5; border-radius: 4px; + margin-right: 345px; pre { margin: 0; diff --git a/docs/components/side-nav.vue b/docs/components/side-nav.vue index fe786fbbf..2d790aa2f 100644 --- a/docs/components/side-nav.vue +++ b/docs/components/side-nav.vue @@ -56,10 +56,9 @@ export default { -## Icon +## Icon 图标 -### 所有Icon +### 基础用法 + +设置`name`属性为对应的图标名称即可。 :::demo 所有Icon ```html diff --git a/docs/examples-docs/loading.md b/docs/examples-docs/loading.md index a57cd0636..5691d8fb8 100644 --- a/docs/examples-docs/loading.md +++ b/docs/examples-docs/loading.md @@ -17,7 +17,7 @@ } -## Loading 加载中 +## Loading 加载 ### 基础用法 diff --git a/docs/examples-docs/picker.md b/docs/examples-docs/picker.md index 6da630fc5..0c6810cf9 100644 --- a/docs/examples-docs/picker.md +++ b/docs/examples-docs/picker.md @@ -35,9 +35,7 @@ export default { }; -## Picker组件 - -模仿iOS中的`UIPickerView`。 +## Picker 选择器 ### 基础用法 diff --git a/docs/examples-docs/popup.md b/docs/examples-docs/popup.md index ea5ed0cef..9cd94610f 100644 --- a/docs/examples-docs/popup.md +++ b/docs/examples-docs/popup.md @@ -76,7 +76,7 @@ export default { }; -## Popup组件 +## Popup 弹出菜单 ### 基础用法 diff --git a/docs/examples-docs/progress.md b/docs/examples-docs/progress.md index 7261278ed..0d4291867 100644 --- a/docs/examples-docs/progress.md +++ b/docs/examples-docs/progress.md @@ -10,7 +10,7 @@ -## Progress +## Progress 进度条 ### 基础用法 diff --git a/docs/examples-docs/quantity.md b/docs/examples-docs/quantity.md index 1368f62cd..f3f81f98a 100644 --- a/docs/examples-docs/quantity.md +++ b/docs/examples-docs/quantity.md @@ -23,7 +23,7 @@ export default { }; -## Quantity +## Quantity 数量选择 ### 基础用法 diff --git a/docs/examples-docs/radio.md b/docs/examples-docs/radio.md index ca2b84f98..826379134 100644 --- a/docs/examples-docs/radio.md +++ b/docs/examples-docs/radio.md @@ -25,7 +25,7 @@ export default { }; -## Radio组件 +## Radio 单选框 ### 基础用法 diff --git a/docs/examples-docs/search.md b/docs/examples-docs/search.md index cf9f051df..13b9bd05e 100644 --- a/docs/examples-docs/search.md +++ b/docs/examples-docs/search.md @@ -8,7 +8,7 @@ export default { }; -## Search 组件 +## Search 搜索 ### 基础用法 @@ -31,4 +31,4 @@ export default { | 参数 | 说明 | 类型 | 默认值 | 必须 | |-----------|-----------|-----------|-------------|-------------| -| placeholder | `input`的`placeholder`文案 | `string` | | | \ No newline at end of file +| placeholder | `input`的`placeholder`文案 | `string` | | | diff --git a/docs/examples-docs/swipe.md b/docs/examples-docs/swipe.md index 8449eb4e7..0fd446e17 100644 --- a/docs/examples-docs/swipe.md +++ b/docs/examples-docs/swipe.md @@ -12,7 +12,7 @@ } -## Swipe +## Swipe 轮播 ### 基础用法 diff --git a/docs/examples-docs/switch.md b/docs/examples-docs/switch.md index b9a0e332d..d9b948cef 100644 --- a/docs/examples-docs/switch.md +++ b/docs/examples-docs/switch.md @@ -36,7 +36,7 @@ export default { }; -## Switch组件 +## Switch 开关 ### 基础用法 diff --git a/docs/examples-docs/tab.md b/docs/examples-docs/tab.md index 9aad91c35..78e835f64 100644 --- a/docs/examples-docs/tab.md +++ b/docs/examples-docs/tab.md @@ -29,7 +29,7 @@ export default { }; -## Tab 组件 +## Tab 标签 ### 基础用法 diff --git a/docs/examples-docs/tag.md b/docs/examples-docs/tag.md index 126ba5c38..a1a2b89c8 100644 --- a/docs/examples-docs/tag.md +++ b/docs/examples-docs/tag.md @@ -8,7 +8,7 @@ } -## Tag 组件 +## Tag 标记 ### 基础用法 diff --git a/docs/examples-docs/toast.md b/docs/examples-docs/toast.md index a828742e4..731b57245 100644 --- a/docs/examples-docs/toast.md +++ b/docs/examples-docs/toast.md @@ -63,7 +63,7 @@ export default { }; -## Toast +## Toast 轻提示 ### 基础用法 diff --git a/docs/examples-docs/uploader.md b/docs/examples-docs/uploader.md index 7193978d5..37d503191 100644 --- a/docs/examples-docs/uploader.md +++ b/docs/examples-docs/uploader.md @@ -12,7 +12,7 @@ export default { } }; -## Uploader 组件 +## Uploader 图片上传 ### 基础用法 diff --git a/docs/nav.config.json b/docs/nav.config.json index ddeb1800b..7d1959e5a 100644 --- a/docs/nav.config.json +++ b/docs/nav.config.json @@ -26,71 +26,71 @@ "list": [ { "path": "/button", - "title": "Button" + "title": "Button 按钮" }, { "path": "/icon", - "title": "Icon" + "title": "Icon 图标" }, { "path": "/cell", - "title": "Cell" + "title": "Cell 单元格" }, { "path": "/progress", - "title": "Progress" + "title": "Progress 进度条" }, { "path": "/panel", - "title": "Panel" + "title": "Panel 面板" }, { "path": "/card", - "title": "Card" + "title": "Card 图文组件" }, { "path": "/loading", - "title": "Loading" + "title": "Loading 加载" }, { "path": "/steps", - "title": "Steps" + "title": "Steps 步骤条" }, { "path": "/tag", - "title": "Tag" + "title": "Tag 标记" }, { "path": "/badge", - "title": "Badge" + "title": "Badge 徽章" }, { "path": "/tab", - "title": "Tab" + "title": "Tab 标签" }, { "path": "/popup", - "title": "Popup" + "title": "Popup 弹出菜单" }, { "path": "/swipe", - "title": "Swipe" + "title": "Swipe 轮播" }, { "path": "/search", - "title": "Search" + "title": "Search 搜索" }, { "path": "/quantity", - "title": "Quantity" + "title": "Quantity 数量选择" }, { "path": "/waterfall", - "title": "Waterfall" + "title": "Waterfall 瀑布流" }, { "path": "/image-preview", - "title": "ImagePreview" + "title": "ImagePreview 图片预览" } ] }, @@ -99,23 +99,23 @@ "list": [ { "path": "/switch", - "title": "Switch" + "title": "Switch 开关" }, { "path": "/field", - "title": "Field" + "title": "Field 输入框" }, { "path": "/radio", - "title": "Radio" + "title": "Radio 单选框" }, { "path": "/checkbox", - "title": "Checkbox" + "title": "Checkbox 复选框" }, { "path": "/uploader", - "title": "Uploader" + "title": "Uploader 图片上传" } ] }, @@ -124,23 +124,23 @@ "list": [ { "path": "/actionsheet", - "title": "ActionSheet" + "title": "ActionSheet 行动按钮" }, { "path": "/toast", - "title": "Toast" + "title": "Toast 轻提示" }, { "path": "/picker", - "title": "Picker" + "title": "Picker 选择器" }, { "path": "/datetime-picker", - "title": "Datetime Picker" + "title": "Datetime Picker 时间选择" }, { "path": "/dialog", - "title": "Dialog" + "title": "Dialog 弹出框" } ] } diff --git a/packages/zanui-css/src/button_group.css b/packages/zanui-css/src/button_group.css deleted file mode 100644 index 5321eb204..000000000 --- a/packages/zanui-css/src/button_group.css +++ /dev/null @@ -1,33 +0,0 @@ -@define-mixin button-wrap { - display: inline-block; - box-sizing: border-box; - padding-right: 10px; - vertical-align: middle; - &:last-child { - padding-right: 0; - } - .zan-button { - width: 100%; - } -} - -@component-namespace zan { - @b button-group { - font-size: 0; - - - } - @b button-1 { - @mixin button-wrap; - padding-right: 0; - width: 100%; - } - @b button-2 { - @mixin button-wrap; - width: 50%; - } - @b button-3 { - @mixin button-wrap; - width: 33.33%; - } -}