123456789101112 |
- import handleClipboard from '@/utils/clipboard'
- import { isWeChat } from '@/utils/validator'
- import { downloadUrlLink } from '@/utils/index'
- // 通过链接下载
- export default function downloadLink(link, $event) {
- if (isWeChat()) {
- return handleClipboard(link, $event, '下载链接已复制到剪切板')
- } else {
- downloadUrlLink(link)
- }
- }
|