added "auto book" displayed on the empty text pages as a replacement for children overview

This commit is contained in:
zadam
2019-10-05 20:27:30 +02:00
parent cbc7710d81
commit 516277a478
6 changed files with 55 additions and 21 deletions

View File

@@ -201,6 +201,10 @@ function closeActiveDialog() {
}
}
function isHtmlEmpty(html) {
return $(html).text().trim().length === 0 && !html.toLowerCase().includes('<img');
}
export default {
reloadApp,
parseDate,
@@ -231,5 +235,6 @@ export default {
getCookie,
getNoteTypeClass,
getMimeTypeClass,
closeActiveDialog
closeActiveDialog,
isHtmlEmpty
};