<!--label标签组件-->

<template>
    <div>
        <div v-for="item in labelJson"
               :style="{
                 position:'absolute',
                 left:item.Left*bigScale+'px',
                 top:item.Top*bigScale+'px',
                 fontSize:item.FontSize*bigScale + 'px',
                 fontWeight:600,
                 width:item.Width*bigScale + 'px',
                 height:item.Height*bigScale + 'px',
                 zIndex:item.ZIndex,
                 display:item.IsVisibility ? 'block' : 'none',
                 color:`#${item.ForegroundStr.slice(3)}`,
                 textAlign:'center',
                 lineHeight:item.Height*bigScale + 'px',
                 whiteSpace:'nowrap'
            }">
            {{item.Text}}
        </div>
    </div>
</template>

<script>
    import {mapState} from 'vuex'

    export default {
        computed: {
            ...mapState(['bigScale','labelJson']),
        }
    }
</script>
