scinote-web/app/javascript/vue/protocols/renderers/keywords.vue

24 lines
559 B
Vue
Raw Normal View History

2023-12-28 03:09:36 +08:00
<template>
<div class="flex items-center gap-2 truncate h-full">
<div v-for="keyword in params.data.keywords" :key="keyword.id"
@click="params.dtComponent.setSearchValue(keyword)"
class="px-2 py-1 rounded-sm bg-sn-super-light-grey gap-1 leading-5 cursor-pointer hover:bg-sn-light-grey">
{{ keyword }}
</div>
<div v-if="params.data.keywords.length === 0">
</div>
</div>
</template>
<script>
export default {
name: 'KeywordsRenderer',
props: {
params: {
required: true
}
}
};
</script>