@internetarchive/bookreader 5.0.0-84 → 5.0.0-85
Sign up to get free protection for your applications and to get access to all the features.
- package/BookReader/BookReader.js +1 -1
- package/BookReader/plugins/plugin.chapters.js +1 -1
- package/BookReader/plugins/plugin.chapters.js.map +1 -1
- package/BookReader/plugins/plugin.search.js +1 -1
- package/BookReader/plugins/plugin.search.js.map +1 -1
- package/BookReader/plugins/plugin.tts.js +1 -1
- package/BookReader/plugins/plugin.tts.js.map +1 -1
- package/CHANGELOG.md +3 -0
- package/package.json +1 -1
- package/src/plugins/plugin.chapters.js +2 -2
- package/src/plugins/search/plugin.search.js +0 -1
- package/src/plugins/tts/PageChunk.js +1 -1
package/CHANGELOG.md
CHANGED
package/package.json
CHANGED
@@ -163,11 +163,11 @@ BookReader.prototype.getOpenLibraryRecord = async function (olHost, ocaid) {
|
|
163
163
|
const baseURL = `${olHost}/query.json?type=/type/edition&*=`;
|
164
164
|
const fetchUrlByBookId = `${baseURL}&ocaid=${ocaid}`;
|
165
165
|
|
166
|
-
let data = await $.ajax({ url: fetchUrlByBookId
|
166
|
+
let data = await $.ajax({ url: fetchUrlByBookId });
|
167
167
|
|
168
168
|
if (!data || !data.length) {
|
169
169
|
// try sourceid
|
170
|
-
data = await $.ajax({ url: `${baseURL}&source_records=ia:${ocaid}
|
170
|
+
data = await $.ajax({ url: `${baseURL}&source_records=ia:${ocaid}` });
|
171
171
|
}
|
172
172
|
|
173
173
|
return data?.[0];
|
@@ -222,7 +222,6 @@ BookReader.prototype.search = async function(term = '', overrides = {}) {
|
|
222
222
|
this.trigger('SearchStarted', { term: this.searchTerm, instance: this });
|
223
223
|
callSearchResultsCallback(await $.ajax({
|
224
224
|
url: url,
|
225
|
-
dataType: 'jsonp',
|
226
225
|
cache: true,
|
227
226
|
beforeSend: xhr => { this.searchXHR = xhr; },
|
228
227
|
}));
|
@@ -25,11 +25,11 @@ export default class PageChunk {
|
|
25
25
|
const chunks = await $.ajax({
|
26
26
|
type: 'GET',
|
27
27
|
url: `https://${server}/BookReader/BookReaderGetTextWrapper.php`,
|
28
|
-
dataType:'jsonp',
|
29
28
|
cache: true,
|
30
29
|
data: {
|
31
30
|
path: `${bookPath}_djvu.xml`,
|
32
31
|
page: leafIndex,
|
32
|
+
callback: 'false',
|
33
33
|
},
|
34
34
|
});
|
35
35
|
return PageChunk._fromTextWrapperResponse(leafIndex, chunks);
|