This commit is contained in:
王一嘉
2025-07-22 17:10:03 +08:00
parent 38538db468
commit d4b90b09f8
4 changed files with 34 additions and 7 deletions

View File

@@ -2,6 +2,7 @@
import {ref, computed} from "vue";
import XSquareCarouselImage from "../../../components/XSquareCarouselImage.vue";
import {toWXMiniApp} from "../../../utils/uils.js";
import XImage from "../../../components/XImage.vue";
const {data, home} = defineProps({
data: {
@@ -82,8 +83,16 @@ const list = computed(() => data.children.material[current.value].comment?.flatM
{{ v.intro }}
</view>
<view class="!flex gap-[20rpx] flex-wrap !my-[10rpx]">
<image v-for="k in v.image_arr" class="!w-[96rpx] !h-[96rpx] !aspect-square" mode="aspectFill"
:src="k"></image>
<view class="!w-[96rpx] !h-[96rpx] !aspect-square" v-for="k in v.image_arr">
<x-image
:style="{
width: '96rpx',
height: '96rpx',
}"
:src="k"
:list="v.image_arr">
</x-image>
</view>
</view>
</view>
</view>

View File

@@ -7,6 +7,7 @@ import {showToast, uploadFile} from "../../../utils/uils.js";
import Api from "../../../api/index.js";
import {debounce} from "lodash";
import useUploadLength from "../../../hooks/useUploadLength.js";
import XImage from "../../../components/XImage.vue";
const emits = defineEmits(['success']);
const {data, backId, intervention, pattern, logId} = defineProps({
@@ -81,15 +82,32 @@ const success = debounce(async () => {
</view>
<view class="!flex gap-[20rpx] flex-wrap !mt-[20rpx]">
<view class="!size-[100rpx] image-box relative" v-for="(v, index) in form.images">
<image :src="v" class="!size-full" mode="aspectFit"></image>
<view class="!size-[100rpx] relative" v-for="(v, index) in form.images">
<x-image
:cur="index"
:style="{
width: '100rpx',
height: '100rpx',
}"
:src="v"
:list="form.images">
</x-image>
<view
@click="form.images.splice(index, 1)"
class="!size-[48rpx] bg-[#1D2129] rounded-[50%] absolute right-0 top-0 !flex justify-center items-center">
<tui-icon name="plus" color="#ffffff" :size="18" style="transform: rotate(45deg)"></tui-icon>
</view>
</view>
<!-- <view class="!size-[100rpx] image-box relative" v-for="(v, index) in form.images">-->
<!-- <image :src="v" class="!size-full" mode="aspectFit"></image>-->
<!-- <view-->
<!-- @click="form.images.splice(index, 1)"-->
<!-- class="!size-[48rpx] bg-[#1D2129] rounded-[50%] absolute right-0 top-0 !flex justify-center items-center">-->
<!-- <tui-icon name="plus" color="#ffffff" :size="18" style="transform: rotate(45deg)"></tui-icon>-->
<!-- </view>-->
<!-- </view>-->
</view>
<view class="!mt-[20rpx] bg-[#F2F3F5] rounded-[4rpx] py-[16rpx] px-[30rpx] w-full">