Logo white

other / mew-iview

Sign in
  • Sign in
  • Project
  • Files
  • Commits
  • Network
  • Graphs
  • Milestones
  • Issues 0
  • Merge Requests 0
  • Labels
  • Wiki
  • mew-iview
  • src
  • components
  • carousel
  • carousel-item.vue
  • updated autoplay and wrote tests
    bfc11079
    Rijn authored
    2017-01-16 04:28:34 -0600  
    Browse Code ยป
carousel-item.vue 579 Bytes
Edit Raw Blame History
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
<template>
    <div :class="prefixCls" v-bind:style="styles"><slot></slot></div>
</template>
<script>
    const prefixCls = 'ivu-carousel-item';

    export default {
        componentName: 'carousel-item',

        data () {
            return {
                prefixCls: prefixCls,
                width: 0,
                left: 0
            };
        },
        computed: {
            styles () {
                return {
                    width: `${this.width}px`,
                    left: `${this.left}px`
                }
            }
        },
    };
</script>