Commit 6bfdf8f8929c3516dbbcc02e91b7ae41869b63b6

Authored by 梁灏
1 parent e5ac7925

release 0.9.16

release 0.9.16
package.json
1 1 {
2 2 "name": "iview",
3   - "version": "0.9.15",
  3 + "version": "0.9.16",
4 4 "title": "iView",
5 5 "description": "A high quality UI components Library with Vue.js",
6 6 "homepage": "http://www.iviewui.com",
... ...
src/components/rate/rate.vue
... ... @@ -7,7 +7,7 @@
7 7 @click="handleClick(item)">
8 8 <span :class="[prefixCls + '-star-content']" type="half"></span>
9 9 </div>
10   - <div :class="[prefixCls + '-text']" v-if="showText">
  10 + <div :class="[prefixCls + '-text']" v-if="showText" v-show="value > 0">
11 11 <slot>{{ value }} <template v-if="value <= 1">{{ t('i.rate.star') }}</template><template v-else>{{ t('i.rate.stars') }}</template></slot>
12 12 </div>
13 13 </div>
... ...
test/routers/rate.vue
1 1 <template>
2   - <div style="margin: 100px">
3   - {{value}}
4   - <br><br><br>
5   - <Rate :value.sync="value" :count="5" allow-half show-text></Rate>
6   - <br><br><br>
7   - <i-button @click="value++">add</i-button>
8   - <i-button @click="value--">remove</i-button>
9   - </div>
  2 + <Row>
  3 + <i-col span="12">
  4 + <Rate show-text :value.sync="valueText"></Rate>
  5 + </i-col>
  6 + <i-col span="12">
  7 + <Rate show-text :value.sync="valueCustomText">
  8 + <span style="color: #f5a623">{{ valueCustomText }}</span>
  9 + </Rate>
  10 + </i-col>
  11 + </Row>
10 12 </template>
11 13 <script>
12 14 export default {
13 15 props: {},
14 16 data () {
15 17 return {
16   - value: 3.8
  18 + valueText: 3,
  19 + valueCustomText: 3.8
17 20 };
18 21 },
19 22 computed: {},
... ...