<template>
	  <view style="height:90rpx;" class="cu-nav">
	  	<scroll-view style="position: fixed;width: 100%;" scroll-x class="bg-white nav" scroll-with-animation :scroll-left="active | change">
	  	 <view class="flex text-center">
	  		 <view :class="index==active ? 'cu-item flex-sub text-orange cur':'cu-item flex-sub'" v-for="(item,index) of value" :key="index" @click="$emit('onChange',index)" >
	  		   {{item.name}}
	  		 </view>
	  	 </view>
	  	</scroll-view>
	  </view>
</template>

<script>
	export default {
		props:{
			active:{
				type:Number,default:()=>0
			},
			value:{
				type:Array,default:()=>[]
			}
		},
		filters:{
			change(value){
				return (value-1)*60;
			}
		}
	}
</script>

<style>
</style>
