resource-two-image.vue 1.23 KB
<template>
    <resource class="resource-ti-image">
        <div class="resource-ti-image-item">
            <a-link :href="value.data.list[0].url" :yas="value" :yas-f="index" :yas-i="0">
                <img-format :lazy="lazy" :src="value.data.list[0].src" :w="value.data.imageWidth"
                            :h="value.data.imageHeight"></img-format>
            </a-link>
        </div>
        <div class="split"></div>
        <div class="resource-ti-image-item">
            <a-link :href="value.data.list[1].url" :yas="value" :yas-f="index" :yas-i="1">
                <img-format :lazy="lazy" :src="value.data.list[1].src" :w="value.data.imageWidth"
                            :h="value.data.imageHeight"></img-format>
            </a-link>
        </div>
    </resource>
</template>

<script>
import Resource from './resource';

export default {
    name: 'ResourceTwoImage',
    props: {
        value: Object,
        lazy: Boolean,
        index: Number
    },
    components: {Resource}
};
</script>

<style lang="scss">
.resource-ti-image {
    display: flex;
    .split {
        width: 20px;
    }
    .resource-ti-image-item {
        width: 50%;

        img {
            width: 100%;
            display: block;
        }
    }
}
</style>