<template>
	<view class="select-words">
		<span v-for="item in activeWords" :class="{active: activeWord.id == item.id}">{{item.name}}</span>
	</view>
</template>

<script setup>
	const props = defineProps({
		activeWord: {
			type: Object,
		},
		activeWords: {
			type: Array
		},
	})
</script>

<style lang="scss" scoped>
	.select-words {
		display: flex;
		justify-content: space-between;
	}
	.active {
		color: red;
	}
</style>