Commit 9cdfb2e20606df0071cc9aa7aacd76b8815053df

Authored by 梁灏
1 parent 07201151

fix #5135

examples/routers/divider.vue
... ... @@ -25,6 +25,25 @@
25 25 iView is a set of UI components and widgets built on Vue.js.
26 26 </p>
27 27  
  28 + <Divider dashed>iView Developer</Divider>
  29 + <p>
  30 + iView is a set of UI components and widgets built on Vue.js.
  31 + iView is a set of UI components and widgets built on Vue.js.
  32 + iView is a set of UI components and widgets built on Vue.js.
  33 + </p>
  34 + <Divider dashed orientation="left">iView Developer</Divider>
  35 + <p>
  36 + iView is a set of UI components and widgets built on Vue.js.
  37 + iView is a set of UI components and widgets built on Vue.js.
  38 + iView is a set of UI components and widgets built on Vue.js.
  39 + </p>
  40 + <Divider dashed orientation="right">iView Developer</Divider>
  41 + <p>
  42 + iView is a set of UI components and widgets built on Vue.js.
  43 + iView is a set of UI components and widgets built on Vue.js.
  44 + iView is a set of UI components and widgets built on Vue.js.
  45 + </p>
  46 +
28 47 <Divider dashed/>
29 48  
30 49 <p>
... ... @@ -60,6 +79,8 @@
60 79 <a href="#">Components</a>
61 80 <Divider type="vertical" />
62 81 <a href="#">Divider</a>
  82 + <Divider type="vertical" dashed />
  83 + <a href="#">ABCDE</a>
63 84 </div>
64 85 </Card>
65 86 </i-col>
... ...
src/components/divider/divider.vue
... ... @@ -42,6 +42,7 @@
42 42 `${prefixCls}`,
43 43 `${prefixCls}-${this.type}`,
44 44 {
  45 + [`${prefixCls}-with-text`]: this.hasSlot && this.orientation === 'center',
45 46 [`${prefixCls}-with-text-${this.orientation}`]: this.hasSlot,
46 47 [`${prefixCls}-dashed`]: !!this.dashed
47 48 }
... ...
src/styles/components/divider.less
... ... @@ -18,6 +18,7 @@
18 18 display: block;
19 19 height: 1px;
20 20 width: 100%;
  21 + min-width: 100%;
21 22 margin: 24px 0;
22 23 clear: both;
23 24 }
... ...