mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-12-01 14:28:07 +00:00
Custom copy clipboard notifications (#8211)
* Initial Commit * Improve plugin tests Fixes #8209 * Fix RSOE * Fix extraneous copy to clipboard at startup
This commit is contained in:
@@ -292,7 +292,9 @@ exports.copyToClipboard = function(text,options) {
|
||||
} catch (err) {
|
||||
}
|
||||
if(!options.doNotNotify) {
|
||||
$tw.notifier.display(succeeded ? "$:/language/Notifications/CopiedToClipboard/Succeeded" : "$:/language/Notifications/CopiedToClipboard/Failed");
|
||||
var successNotification = options.successNotification || "$:/language/Notifications/CopiedToClipboard/Succeeded",
|
||||
failureNotification = options.failureNotification || "$:/language/Notifications/CopiedToClipboard/Failed"
|
||||
$tw.notifier.display(succeeded ? successNotification : failureNotification);
|
||||
}
|
||||
document.body.removeChild(textArea);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user