aboutsummaryrefslogtreecommitdiff
path: root/ext/mixed/js/api.js
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2020-09-13 18:43:44 -0400
committerGitHub <noreply@github.com>2020-09-13 18:43:44 -0400
commit5ec5d0c91c0726ed74b0cb8772d992ae478625b8 (patch)
tree65c5c17c0b8c8cea2def98a79801568ea55fd12d /ext/mixed/js/api.js
parent8b033a1650ff9425963c164aba1a744aada93f20 (diff)
Database change event (#826)
* Add api.triggerDatabaseUpdated and yomichan.on('databaseUpdated') * Update databaseUpdated event usage
Diffstat (limited to 'ext/mixed/js/api.js')
-rw-r--r--ext/mixed/js/api.js4
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/mixed/js/api.js b/ext/mixed/js/api.js
index fce8fbee..ad5846fa 100644
--- a/ext/mixed/js/api.js
+++ b/ext/mixed/js/api.js
@@ -197,6 +197,10 @@ const api = (() => {
return this._invoke('getDefinitionAudio', {sources, expression, reading, details});
}
+ triggerDatabaseUpdated(type, cause) {
+ return this._invoke('triggerDatabaseUpdated', {type, cause});
+ }
+
// Invoke functions with progress
deleteDictionary(dictionaryName, onProgress) {