<template>
    <div class="uploader-unsupport" v-show="!support">
        <slot>
            <p>
                非常抱歉，您的浏览器不支持此功能，建议您下载最新的edge浏览器或者chrome浏览器。
                <a href="http://www.w3.org/TR/FileAPI/">the HTML5 File API</a> along with <a
                href="http://www.w3.org/TR/FileAPI/#normalization-of-params">file slicing</a>.
            </p>
        </slot>
    </div>
</template>

<script>
import {inject} from 'vue'

const COMPONENT_NAME = 'uploader-unsupport'

export default {
    name: COMPONENT_NAME,
    setup() {
        const uploader = inject('uploader').proxy.uploader
        const support = uploader.support
        return {
            support
        }
    }
}
</script>

<style>
.uploader-unsupport {
    position: relative;
    z-index: 10;
    overflow: hidden;
}
</style>
