<script setup lang="ts">
    defineProps({
        minmaxData: {
            type: Array,
            default: () => [
                { label: '最大', value: '0' },
                { label: '最小', value: '0' },
            ],
        },
    })
</script>

<template>
    <view class="tipgridwrap">
        <view v-for="(item, index) in minmaxData" :key="index" class="tipwrap" style="flex-basis: 50%">
            <view class="tipflex tiptitle">{{ item.label }}</view>
            <view class="tipflex tipcontent">{{ item.value }}</view>
        </view>
    </view>
</template>

<style lang="less" scoped>
    .tipgridwrap {
        padding: 5px 10px;
        display: grid;
        grid-template-columns: 49% 49%;
        grid-column-gap: 10px;

        .tipwrap {
            display: flex;
            justify-content: center;
            align-items: center;
            height: 30px;
            margin-top: 5px;
            border: 1px solid rgb(24 144 255 / 20%);
            border-radius: 5px;
            overflow: hidden;

            .tipflex {
                flex-basis: 50%;
                display: flex;
                justify-content: center;
                align-items: center;
                font-size: 26rpx;
            }

            .tiptitle {
                height: 100%;
                background: #1890ff;
                color: #fff;
            }

            .tipcontent {
                height: 100%;
                background: #fff;
            }
        }
    }
</style>
