feat: ask user to send Discord message on error
This commit is contained in:
parent
6d93907df0
commit
9adba49de1
11
src/btn.ts
11
src/btn.ts
|
@ -273,6 +273,17 @@ export namespace BtnAction {
|
||||||
setText(name)
|
setText(name)
|
||||||
} else {
|
} else {
|
||||||
setText(i18n('BTN_ERROR')())
|
setText(i18n('BTN_ERROR')())
|
||||||
|
// ask user to send Discord message
|
||||||
|
alert(
|
||||||
|
'❌Download Failed!\n\n' +
|
||||||
|
'Send your URL to the #dataset-bugs channel \n ' +
|
||||||
|
'in the LibreScore Community Discord server: https://discord.gg/kTyx6nUjMv',
|
||||||
|
)
|
||||||
|
// open Discord on 'OK'
|
||||||
|
const a = document.createElement('a')
|
||||||
|
a.href = 'https://discord.gg/kTyx6nUjMv'
|
||||||
|
a.target = '_blank'
|
||||||
|
a.dispatchEvent(new MouseEvent('click'))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue