diff --git a/demo/documentation/components/tabs/enUS/card.md b/demo/documentation/components/tabs/enUS/card.md index eb4ff0959..5d6459728 100644 --- a/demo/documentation/components/tabs/enUS/card.md +++ b/demo/documentation/components/tabs/enUS/card.md @@ -1,4 +1,5 @@ # Card +A example to use with card. (demo is the card) ```html + + + Wonderwall + + + Hey Jude + + + 七里香 + + + + + + + + + + + + + + + 登陆 + + + + + + + + + + + + + + 注册 + + + +``` + +```js +export default { + data () { + return { + name: 'oasis', + func: 'signin' + } + } +} +``` + +```css +.n-button { + margin-top: 12px; +} +``` \ No newline at end of file diff --git a/demo/documentation/components/tabs/zhCN/card.md b/demo/documentation/components/tabs/zhCN/card.md new file mode 100644 index 000000000..7ede1b952 --- /dev/null +++ b/demo/documentation/components/tabs/zhCN/card.md @@ -0,0 +1,48 @@ +# 和卡片一起使用 +一个和卡片一起使用的例子(例子本身是卡片)。 +```html + + + {{ panel }} + + +``` +```js +export default { + data () { + return { + panels: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15], + name: '1', + tabNavScrollable: false + } + }, + methods: { + handleScrollableChange (value) { + this.tabNavScrollable = value + }, + handleClose (name) { + this.$NMessage.info('Close ' + name) + const index = this.panels.findIndex(v => name === v.toString()) + if (~index) { + this.panels.splice(index, 1) + } + } + } +} +``` \ No newline at end of file diff --git a/demo/documentation/components/tabs/zhCN/flexLabel.md b/demo/documentation/components/tabs/zhCN/flexLabel.md new file mode 100644 index 000000000..a8654d0c3 --- /dev/null +++ b/demo/documentation/components/tabs/zhCN/flexLabel.md @@ -0,0 +1,83 @@ +# Flex 布局的标签 +```html + + + + Wonderwall + + + Hey Jude + + + 七里香 + + + + + + + + + + + + + + + 登陆 + + + + + + + + + + + + + + 注册 + + + +``` + +```js +export default { + data () { + return { + name: 'oasis', + func: 'signin' + } + } +} +``` + +```css +.n-button { + margin-top: 12px; +} +``` \ No newline at end of file diff --git a/demo/documentation/components/tabs/zhCN/index.md b/demo/documentation/components/tabs/zhCN/index.md index e69de29bb..6f4d513ab 100644 --- a/demo/documentation/components/tabs/zhCN/index.md +++ b/demo/documentation/components/tabs/zhCN/index.md @@ -0,0 +1,31 @@ +# 标签页 Tabs +在同一块区域切换内容。 +## 演示 +```demo +basic +flex-label +card +``` +## V-model +V-model 暂时不对外暴露,名字没起好。 + +## Props +### Tabs Props +|名称|类型|默认值|介绍| +|-|-|-|-| +|type|`'line' \| 'card'`|`'line'`|| +|closable|`boolean`|`false`|| +|justify-content|`'space-between' \| 'space-around' \| 'space-evenly'`|`null`|| + +### Tab Panel Props +|名称|类型|默认值|介绍| +|-|-|-|-| +|label|`string`|`null`|| +|name|`string \| number`|`null`|**required**| +|disabled|`boolean`|`false`|| + +## Slots +### Tabs, Tab Panel Slots +|名称|类型|介绍| +|-|-|-| +|default|`()`|| \ No newline at end of file diff --git a/demo/header.vue b/demo/header.vue index b0d76fa70..5e7f15266 100644 --- a/demo/header.vue +++ b/demo/header.vue @@ -2,11 +2,13 @@ { "zh-CN": { "dark": "深色", - "light": "浅色" + "light": "浅色", + "searchPlaceholder": "搜索组件" }, "en-US": { "dark": "Dark", - "light": "Light" + "light": "Light", + "searchPlaceholder": "Search Components" } } @@ -20,7 +22,7 @@
diff --git a/packages/common/Tabs/src/Tabs.vue b/packages/common/Tabs/src/Tabs.vue index 878babbc1..834a6a445 100644 --- a/packages/common/Tabs/src/Tabs.vue +++ b/packages/common/Tabs/src/Tabs.vue @@ -127,10 +127,6 @@ export default { }, default: null }, - bodered: { - type: Boolean, - default: false - }, size: { type: String, default: 'medium' diff --git a/think.md b/think.md index 3288be930..2ee0891b8 100644 --- a/think.md +++ b/think.md @@ -126,6 +126,7 @@ anchor 还是有点问题 bound 不够的时候切换 modal transform scale form async validation table filter +tabs 尺寸变化 // pref hollowout, cache next bg color // issue fix, add delay prop