mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-26 08:51:20 -08:00
add i18n
This commit is contained in:
1 parent
1b3b2de8d4
commit
0c6a297ee7
12 files changed
+374
-308
No files matched your search
+2
-2
@@ -4,7 +4,7 @@ export default class Notice {
|
||||
this.timer = null;
|
||||
}
|
||||
|
||||
show(msg, autoHide) {
|
||||
show(msg, autoHide = true, time = 1000) {
|
||||
const { $notice } = this.art.refs;
|
||||
$notice.style.display = 'block';
|
||||
$notice.innerHTML = msg instanceof Error ? msg.message.trim() : msg;
|
||||
@@ -12,7 +12,7 @@ export default class Notice {
|
||||
clearTimeout(this.timer);
|
||||
this.timer = setTimeout(() => {
|
||||
this.hide();
|
||||
}, 1000);
|
||||
}, time);
|
||||
}
|
||||
this.art.emit('notice:show', $notice);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user