Commit 7fdad3a3cae95658f0f5e0e998a51c9d301d2f59

Authored by 梁灏
1 parent a6bb1d90

update $Spin and release 2.4.0-beta.2

examples/routers/spin.vue
@@ -159,7 +159,7 @@ @@ -159,7 +159,7 @@
159 font-style: normal; 159 font-style: normal;
160 font-size: 14px; 160 font-size: 14px;
161 } 161 }
162 - .demo-spin-article p{ 162 + .demo-spin-article p {
163 font-size: 16px; 163 font-size: 16px;
164 } 164 }
165 </style> 165 </style>
@@ -194,19 +194,7 @@ @@ -194,19 +194,7 @@
194 }, 194 },
195 methods: { 195 methods: {
196 show () { 196 show () {
197 - this.$Spin.show({  
198 - render: (h) => {  
199 - return h('div', [  
200 - h('Icon', {  
201 - props: {  
202 - type: 'load-c',  
203 - size: 24  
204 - }  
205 - }),  
206 - h('div', 'Loading')  
207 - ])  
208 - }  
209 - }); 197 + this.$Spin.show();
210 setTimeout(() => { 198 setTimeout(() => {
211 this.$Spin.hide(); 199 this.$Spin.hide();
212 }, 3000) 200 }, 3000)
1 { 1 {
2 "name": "iview", 2 "name": "iview",
3 - "version": "2.4.0-beta.1", 3 + "version": "2.4.0-beta.2",
4 "title": "iView", 4 "title": "iView",
5 "description": "A high quality UI components Library with Vue.js", 5 "description": "A high quality UI components Library with Vue.js",
6 "homepage": "http://www.iviewui.com", 6 "homepage": "http://www.iviewui.com",
src/components/spin/spin.js
@@ -27,7 +27,7 @@ Spin.newInstance = properties =&gt; { @@ -27,7 +27,7 @@ Spin.newInstance = properties =&gt; {
27 }); 27 });
28 } 28 }
29 return h('div', { 29 return h('div', {
30 - 'class': 'ivu-spin-fullscreen' 30 + 'class': 'ivu-spin-fullscreen ivu-spin-fullscreen-wrapper'
31 }, [vnode]); 31 }, [vnode]);
32 } 32 }
33 }); 33 });
src/styles/components/spin.less
@@ -35,6 +35,13 @@ @@ -35,6 +35,13 @@
35 } 35 }
36 &-fullscreen{ 36 &-fullscreen{
37 z-index: @zindex-spin-fullscreen; 37 z-index: @zindex-spin-fullscreen;
  38 + &-wrapper{
  39 + position: fixed;
  40 + top: 0;
  41 + right: 0;
  42 + bottom: 0;
  43 + left: 0;
  44 + }
38 } 45 }
39 46
40 &-fix &-main { 47 &-fix &-main {