mirror of
https://github.com/jxxghp/MoviePilot-Frontend.git
synced 2026-09-05 23:56:42 +08:00
fix(copy): Mobile compatibility issues.
This commit is contained in:
@@ -200,10 +200,12 @@ async function saveAdvancedSettings() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 快捷复制到剪贴板
|
// 快捷复制到剪贴板
|
||||||
function copyValue(value: string) {
|
async function copyValue(value: string) {
|
||||||
try {
|
try {
|
||||||
copyToClipboard(value)
|
let success
|
||||||
$toast.success('已复制到剪贴板')
|
success = copyToClipboard(value)
|
||||||
|
if (await success) $toast.success('已复制到剪贴板')
|
||||||
|
else $toast.error(`复制失败:可能是浏览器不支持或被用户阻止!`)
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
$toast.error('复制失败!')
|
$toast.error('复制失败!')
|
||||||
console.log(error)
|
console.log(error)
|
||||||
|
|||||||
Reference in New Issue
Block a user