<template>
	<view>
		<view class="uni__number" :style="{ color: color, 'font-size': size+'px' }"> {{currentValue}} </view>
	</view>
</template>

<script>
	export default {
		name: "LEDFont",
		props: {
			size: {
				type: Number,
				value: '24'
			},
			color: {
				type: String,
				default: '#000000'
			},
			showValue: {
				type: Number,
				default: 0
			}
		},
		watch: {
			showValue(val) {
				this.currentValue = val;
			},
		},
		created: function(e) {
			this.currentValue = this.showValue;
		},
		data() {
			return {
				currentValut:0
			};
		}
	}
</script>

<style scoped>
	@font-face {
		font-family: 'UnidreamLED';
		src: url('~@/static/font/UnidreamLED.ttf');
	}

	.uni__number {
		/* #ifndef APP-NVUE */
		display: flex;
		/* #endif */
		justify-content: center;
		align-items: center;
		width: 56rpx;
		height: 56rpx;
		line-height: 56rpx;
		margin: 5rpx;
		text-align: center;
		font-size: 23px;
		font-family: UnidreamLED;
		border-radius: 3px;
	}
</style>
