feat: 删除View和Text引用

This commit is contained in:
2023-07-13 16:26:03 +08:00
parent 3d1cf71ff1
commit b6e30a9c20
6 changed files with 45 additions and 43 deletions

View File

@ -1,12 +1,21 @@
<!--
* @Author: zhaojinfeng 121016171@qq.com
* @Date: 2023-07-11 10:08:42
* @LastEditors: zhaojinfeng 121016171@qq.com
* @LastEditTime: 2023-07-13 16:18:04
* @FilePath: \uni\packages\alert\index.vue
* @Description:
*
-->
<template>
<View v-show="modelValue" h-100vh w-full w-750rpx relative bg="#818181" overflow-hidden z-1000>
<View class="th-prompt" w-400rpx text-center rounded-16rpx absolute top="1/3" left="1/2" ml="-200rpx" right-0 bg-white z-1001>
<View color="#3a3a3a" fs-32 font-400 my-48rpx>
<view v-show="modelValue" h-100vh w-full w-750rpx relative bg="#818181" overflow-hidden z-1000>
<view class="th-prompt" w-400rpx text-center rounded-16rpx absolute top="1/3" left="1/2" ml="-200rpx" right-0 bg-white z-1001>
<view color="#3a3a3a" fs-32 font-400 my-48rpx>
{{ content }}
</View>
<View fs-32>
<View bg="#f2f7ff" h-1rpx mx-32rpx />
<View
</view>
<view fs-32>
<view bg="#f2f7ff" h-1rpx mx-32rpx />
<view
active="bg-#f2f7ff"
flex-grow
color="#3b82f6"
@ -17,10 +26,10 @@
@click="confirm"
>
{{ confirmText }}
</View>
</View>
</View>
</View>
</view>
</view>
</view>
</view>
</template>
<script lang="ts" setup name="Alert">

View File

@ -8,8 +8,8 @@
*
-->
<template>
<View mx-24rpx break-all mt-16rpx flex>
<View color="#909399" shrink-0>
<view mx-24rpx break-all mt-16rpx flex>
<view color="#909399" shrink-0>
<slot name="label">
{{ label }}
<template v-if="label">
@ -24,11 +24,6 @@
</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>

View File

@ -8,7 +8,7 @@
*
-->
<template>
<View fs-30 font-500 leh-42 mx-24rpx mt-24rpx mb-12rpx color="#3A3A3A">
<view fs-30 font-500 leh-42 mx-24rpx mt-24rpx mb-12rpx color="#3A3A3A">
<slot>{{ title }}</slot>
</view>
</template>

View File

@ -8,19 +8,19 @@
*
-->
<template>
<View v-show="modelValue" h-100vh w-full w-750rpx relative bg="#818181" overflow-hidden z-1000>
<View class="th-prompt" w-400rpx text-center rounded-16rpx absolute top="1/3" left="1/2" ml="-200rpx" right-0 bg-white z-1001>
<View py-32rpx>
<View color="#3a3a3a" fs-17 font-500>
<view v-show="modelValue" h-100vh w-full w-750rpx relative bg="#818181" overflow-hidden z-1000>
<view class="th-prompt" w-400rpx text-center rounded-16rpx absolute top="1/3" left="1/2" ml="-200rpx" right-0 bg-white z-1001>
<view py-32rpx>
<view color="#3a3a3a" fs-17 font-500>
{{ title }}
</View>
<View v-if="title && content" h-16rpx />
<View color="#6a6a6a" fs-13 font-400>
</view>
<view v-if="title && content" h-16rpx />
<view color="#6a6a6a" fs-13 font-400>
{{ content }}
</View>
</View>
<View flex fs-15 border-t-1rpx border-t-solid border-t="#DCDCDC">
<View
</view>
</view>
<view flex fs-15 border-t-1rpx border-t-solid border-t="#DCDCDC">
<view
v-show="showConfirm"
class="rounded-lb-16rpx"
active="bg-#f2f7ff"
@ -35,9 +35,9 @@
@click="confirm"
>
{{ confirmText }}
</View>
<View v-show="showConfirm && showCancel" w-1rpx bg="#dcdcdc" />
<View
</view>
<view v-show="showConfirm && showCancel" w-1rpx bg="#dcdcdc" />
<view
v-show="showCancel"
class="rounded-rb-16rpx"
active="bg-#f2f7ff"
@ -52,10 +52,10 @@
@click="cancel"
>
{{ cancelText }}
</View>
</View>
</View>
</View>
</view>
</view>
</view>
</view>
</template>
<script lang="ts" setup name="Confirm">

View File

@ -8,12 +8,12 @@
*
-->
<template>
<View v-show="show" h-100vh w-750rpx relative bg="#818181" overflow-hidden z-1000 @click="cancel">
<View rounded-t-48rpx w-750rpx absolute bottom-0 bg-white z-1001>
<View mt-32rpx mb-24rpx mx-48rpx fs-30 font-400>
<view v-show="show" h-100vh w-750rpx relative bg="#818181" overflow-hidden z-1000 @click="cancel">
<view rounded-t-48rpx w-750rpx absolute bottom-0 bg-white z-1001>
<view mt-32rpx mb-24rpx mx-48rpx fs-30 font-400>
{{ title }}
</view>
<View text-center mx-48rpx>
<view text-center mx-48rpx>
<textarea
v-model="value"
w-654rpx

View File

@ -22,7 +22,6 @@ declare module 'vue' {
Prompt: typeof import('./../packages/prompt/index.vue')['default']
SearchPicker: typeof import('./../packages/search-picker/index.vue')['default']
Tag: typeof import('./../packages/tag/index.vue')['default']
Text: typeof import('./../dev/Text.vue')['default']
UniBadge: typeof import('@uni-helper/uni-ui-types')['UniBadge']
UniBreadcrumb: typeof import('@uni-helper/uni-ui-types')['UniBreadcrumb']
UniBreadcrumbItem: typeof import('@uni-helper/uni-ui-types')['UniBreadcrumbItem']
@ -82,6 +81,5 @@ declare module 'vue' {
UniTooltip: typeof import('@uni-helper/uni-ui-types')['UniTooltip']
UniTr: typeof import('@uni-helper/uni-ui-types')['UniTr']
UniTransition: typeof import('@uni-helper/uni-ui-types')['UniTransition']
View: typeof import('./../dev/View.vue')['default']
}
}