Commit 38c3f9a3 by yancanhua

fix: 输入框自适应

1 parent 24548856
Pipeline #156 for 38c3f9a3 failed in 0 seconds
......@@ -292,10 +292,10 @@ defineExpose({
<!-- 文本输入框 -->
<div v-if="item.interactionType == 'text_input'">
<van-field v-model="item.value" clearable :label="item.nodeName"
<van-field type="textarea" rows="1" v-model="item.value" clearable :label="item.nodeName"
:maxlength="getValidationRules(item).maxLength || 120" :placeholder="item.placeholder"
:required="item.required === 1" :disabled="item.editPermission == '0'" input-align="right"
label-width="120px" />
label-width="120px" autosize />
</div>
<!-- 长文本输入框 -->
......@@ -314,7 +314,7 @@ defineExpose({
:min="getValidationRules(item).min || 0" :placeholder="item.placeholder"
:required="item.required === 1" step="0.01" type="number"
@input="(e) => { item.value = parseFloat(item.value)?.toFixed(getValidationRules(item).decimalDigits || 2) || '' }"
input-align="right" label-width="120px">
input-align="right" label-width="120px" autosize >
<template v-if="item.suffix" #right-icon>
<span>{{ item.suffix }}</span>
</template>
......
......@@ -122,8 +122,8 @@ function previewVideo(url: string) {
<!-- 视频预览 -->
<van-image-preview v-model:show="videoShow" :images="sourceUrl" :close-on-click-image="false">
<template #image="{ src }">
<video style="width: 100%;" :src="src" controls>
您的浏览器不支持 video 标签。
<video style="width: 100%;" controls>
<source :src="src" />
</video>
</template>
</van-image-preview>
......@@ -149,6 +149,7 @@ function previewVideo(url: string) {
</div>
</div>
<div v-for="(url, index) in pickerValue" :key="index" class="uploadBox">
<!-- 删除按钮 -->
<div class="deleteBox" @click="handleDelete(url)">
<van-icon color="#999999" name="clear" size="20" />
</div>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!