mirror of
https://github.com/beak-insights/felicity-lims.git
synced 2025-02-23 16:33:11 +08:00
30 lines
No EOL
978 B
Vue
30 lines
No EOL
978 B
Vue
<script setup lang="ts">
|
|
import { useLocationStore } from '@/stores';
|
|
|
|
const props = defineProps({
|
|
title: String,
|
|
path: String,
|
|
icon: String,
|
|
})
|
|
|
|
const locationStore = useLocationStore();
|
|
const select = (val?: string) => locationStore.updateConfRoute(val!);
|
|
</script>
|
|
|
|
<template>
|
|
<li class="col-span-4 border-gray-400" @click="select(props.title)">
|
|
<router-link :to="path ?? ''" class="no-underline">
|
|
<div
|
|
class="shadow border select-none cursor-pointer bg-white dark:bg-gray-800 rounded-sm flex flex-1 items-center p-4">
|
|
<div class="mr-4">
|
|
<font-awesome-icon :icon="icon" />
|
|
</div>
|
|
<div class="flex-1 pl-1 md:mr-16">
|
|
<div class="font-medium dark:text-white">
|
|
{{ title }}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</router-link>
|
|
</li>
|
|
</template> |