feat: 标签组件封装
This commit is contained in:
BIN
components/TagsGroup/images/2025-07-13_102028.png
Normal file
BIN
components/TagsGroup/images/2025-07-13_102028.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 5.0 KiB |
19
components/TagsGroup/index.vue
Normal file
19
components/TagsGroup/index.vue
Normal file
@@ -0,0 +1,19 @@
|
||||
<template>
|
||||
<view class="tags-group">
|
||||
<view class="tag-item" v-for="(tag, index) in tags" :key="index">
|
||||
{{ tag }}
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
const tags = [
|
||||
'门票套餐',
|
||||
'民俗活动',
|
||||
'车程路况'
|
||||
];
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
@import './styles/index.scss';
|
||||
</style>
|
||||
14
components/TagsGroup/prompt.md
Normal file
14
components/TagsGroup/prompt.md
Normal file
@@ -0,0 +1,14 @@
|
||||
## 标签组件
|
||||
|
||||
组件名称:标签组件
|
||||
|
||||
## 提示词:
|
||||
|
||||
使用 uniapp + vue3 组合式 api 开发微信小程序,要求如下:
|
||||
1、按照提供的图片 100%还原交互设计
|
||||
2、要求布局样式结构简洁明了,class 命名请按照模块名称来命名,例如:.tags-group
|
||||
3、可以使用 uniapp 内置的组件
|
||||
|
||||
## 备注
|
||||
|
||||
仅供学习、交流使用,请勿用于商业用途。
|
||||
13
components/TagsGroup/styles/index.scss
Normal file
13
components/TagsGroup/styles/index.scss
Normal file
@@ -0,0 +1,13 @@
|
||||
.tags-group {
|
||||
display: flex;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.tag-item {
|
||||
background-color: #fff;
|
||||
border-radius: 10px;
|
||||
padding: 8px 16px;
|
||||
font-size: 12px;
|
||||
color: #00A6FF;
|
||||
white-space: nowrap;
|
||||
}
|
||||
Reference in New Issue
Block a user