generated from thzxcx/vue3
feat: 卡片等组件
This commit is contained in:
45
packages/card-text/index.vue
Normal file
45
packages/card-text/index.vue
Normal file
@ -0,0 +1,45 @@
|
||||
<!--
|
||||
* @Author: peerless_hero peerless_hero@outlook.com
|
||||
* @Date: 2023-07-08 01:44:46
|
||||
* @LastEditors: zhaojinfeng 121016171@qq.com
|
||||
* @LastEditTime: 2023-07-10 19:07:56
|
||||
* @FilePath: \uni\packages\card-text\index.vue
|
||||
* @Description:
|
||||
*
|
||||
-->
|
||||
<template>
|
||||
<View mx-24rpx break-all mt-16rpx flex>
|
||||
<View color="#909399" shrink-0>
|
||||
<slot name="label">
|
||||
{{ label }}
|
||||
<template v-if="label">
|
||||
:
|
||||
</template>
|
||||
</slot>
|
||||
</View>
|
||||
<View color="#3a3a3a" flex-grow>
|
||||
<slot name="text">
|
||||
<Text>
|
||||
{{ text }}
|
||||
</Text>
|
||||
</slot>
|
||||
</View>
|
||||
<View>
|
||||
<View h-48rpx w-128rpx rounded-8rpx border-solid color="#f3a73f" border="#f6ddb8" bg="#fff6e8" border-2rpx fs-24 leh-48 text-center>
|
||||
试试
|
||||
</View>
|
||||
</View>
|
||||
</View>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup name="CardText">
|
||||
withDefaults(defineProps<{
|
||||
/** 标签文字,可用插槽 */
|
||||
label?: string
|
||||
/** 文字,可用插槽 */
|
||||
text?: string
|
||||
}>(), {
|
||||
label: '',
|
||||
text: '',
|
||||
})
|
||||
</script>
|
Reference in New Issue
Block a user