| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566 |
- <template>
- <div class="conversation-agent-item">
- <div class="agent-item-icon" @click="handleClick"></div>
- <div class="agent-item-intro" @click="handleClick">
- <div class="agent-item-intro-title">{{ title }}</div>
- <div class="agent-item-intro-desc">{{ desc }}</div>
- </div>
- </div>
- </template>
- <script setup>
- const props = defineProps({
- title: String,
- desc: String,
- id: String
- });
- const emit = defineEmits(['active']);
- const handleClick = () => {
- emit('active', props.id);
- };
- </script>
- <style lang="css" scoped>
- .conversation-agent-item {
- background-color: var(--color-bg-1);
- padding: 30px 40px 30px 40px;
- border-radius: 20px;
- display: flex;
- color: var(--color-text-1);
- }
- .agent-item-icon {
- width: 36px;
- height: 36px;
- background-color: #ccc;
- border-radius: 18px;
- margin-right: 5px;
- flex-shrink: 0;
- cursor: pointer;
- }
- .agent-item-intro {
- cursor: pointer;
- }
- .agent-item-intro-title {
- font-size: 18px;
- font-weight: bold;
- margin-bottom: 8px;
- }
- .agent-item-intro-desc {
- /* white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis; */
- }
- </style>
|