@d-i-t-a/reader 2.3.7 → 2.3.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/esm/index.js CHANGED
@@ -56120,9 +56120,6 @@ var SearchModule = class {
56120
56120
  self2.currentChapterSearchResult = [];
56121
56121
  self2.currentSearchHighlights = [];
56122
56122
  var localSearchResultChapter = [];
56123
- if (this.navigator.rights.enableContentProtection) {
56124
- this.navigator.contentProtectionModule?.deactivate();
56125
- }
56126
56123
  await this.searchAndPaintChapter(searchVal, index2, async (result) => {
56127
56124
  localSearchResultChapter = result;
56128
56125
  goToResultPage(1);
@@ -56210,6 +56207,9 @@ var SearchModule = class {
56210
56207
  }
56211
56208
  }
56212
56209
  async searchAndPaintChapter(term, index2 = 0, callback) {
56210
+ if (this.navigator.rights.enableContentProtection) {
56211
+ this.navigator.contentProtectionModule?.deactivate();
56212
+ }
56213
56213
  const linkHref = this.publication.getAbsoluteHref(this.publication.readingOrder[this.navigator.currentResource() ?? 0].Href);
56214
56214
  let tocItem = this.publication.getTOCItem(linkHref);
56215
56215
  if (tocItem === null) {
@@ -56289,6 +56289,9 @@ var SearchModule = class {
56289
56289
  this.bookSearchResult = [];
56290
56290
  reset();
56291
56291
  await this.searchAndPaintChapter(term, 0, async () => {
56292
+ if (this.navigator.rights.enableContentProtection) {
56293
+ this.navigator.contentProtectionModule?.recalculate(200);
56294
+ }
56292
56295
  });
56293
56296
  if (current) {
56294
56297
  await this.searchBook(term);
@@ -56326,6 +56329,9 @@ var SearchModule = class {
56326
56329
  this.navigator.navigate(position);
56327
56330
  setTimeout(() => {
56328
56331
  this.searchAndPaintChapter(item.textMatch, filteredIndex, async () => {
56332
+ if (this.navigator.rights.enableContentProtection) {
56333
+ this.navigator.contentProtectionModule?.recalculate(200);
56334
+ }
56329
56335
  });
56330
56336
  }, 300);
56331
56337
  }
@@ -56357,6 +56363,9 @@ var SearchModule = class {
56357
56363
  this.navigator.navigate(position);
56358
56364
  setTimeout(() => {
56359
56365
  this.searchAndPaintChapter(item.textMatch, filteredIndex, async () => {
56366
+ if (this.navigator.rights.enableContentProtection) {
56367
+ this.navigator.contentProtectionModule?.recalculate(200);
56368
+ }
56360
56369
  });
56361
56370
  }, 300);
56362
56371
  }