@inboxsdk/core 2.2.10 → 2.2.11
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/inboxsdk.js
CHANGED
|
@@ -371,7 +371,7 @@ function isNotNil(value) {
|
|
|
371
371
|
|
|
372
372
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment -- SDK_VERSION is injected by webpack
|
|
373
373
|
///@ts-ignore
|
|
374
|
-
const BUILD_VERSION = "2.2.
|
|
374
|
+
const BUILD_VERSION = "2.2.11-1764118012397-e51ed7952926d731";
|
|
375
375
|
if (false) {}
|
|
376
376
|
|
|
377
377
|
/***/ }),
|
|
@@ -2665,7 +2665,7 @@ options.insert = htmlElement => {
|
|
|
2665
2665
|
htmlElement.setAttribute('data-inboxsdk-version',
|
|
2666
2666
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment -- this is injected by webpack
|
|
2667
2667
|
///@ts-ignore
|
|
2668
|
-
"2.2.
|
|
2668
|
+
"2.2.11-1764118012397-e51ed7952926d731");
|
|
2669
2669
|
document.head.append(htmlElement);
|
|
2670
2670
|
};
|
|
2671
2671
|
options.domAPI = (styleDomAPI_default());
|
|
@@ -10313,7 +10313,7 @@ options.insert = htmlElement => {
|
|
|
10313
10313
|
htmlElement.setAttribute('data-inboxsdk-version',
|
|
10314
10314
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment -- this is injected by webpack
|
|
10315
10315
|
///@ts-ignore
|
|
10316
|
-
"2.2.
|
|
10316
|
+
"2.2.11-1764118012397-e51ed7952926d731");
|
|
10317
10317
|
document.head.append(htmlElement);
|
|
10318
10318
|
};
|
|
10319
10319
|
options.domAPI = (styleDomAPI_default());
|
|
@@ -14409,14 +14409,15 @@ class GmailThreadView {
|
|
|
14409
14409
|
// Follows a similar structure to getThreadIDAsync, but gives up if async work is needed
|
|
14410
14410
|
getThreadID() {
|
|
14411
14411
|
if (this.#threadID) return this.#threadID;
|
|
14412
|
-
|
|
14413
|
-
const idElement = this.#element.querySelector('[data-thread-perm-id]');
|
|
14412
|
+
const idElement = this.#element.querySelector('[data-legacy-thread-id]');
|
|
14414
14413
|
if (!idElement) throw new Error('threadID element not found');
|
|
14415
14414
|
|
|
14416
14415
|
// the string value can be 'undefined'
|
|
14417
|
-
const
|
|
14418
|
-
this.#syncThreadID
|
|
14419
|
-
|
|
14416
|
+
const syncAttributeValue = idElement.getAttribute('data-thread-perm-id');
|
|
14417
|
+
if (!this.#syncThreadID && syncAttributeValue && syncAttributeValue !== 'undefined') {
|
|
14418
|
+
this.#syncThreadID = syncAttributeValue;
|
|
14419
|
+
}
|
|
14420
|
+
let threadID = idElement.getAttribute('data-legacy-thread-id');
|
|
14420
14421
|
if (!threadID) {
|
|
14421
14422
|
const err = new Error('Failed to get id for thread: data-legacy-thread-id attribute missing');
|
|
14422
14423
|
this.#driver.getLogger().error(err); // throw err;
|
|
@@ -14430,7 +14431,7 @@ class GmailThreadView {
|
|
|
14430
14431
|
threadID = this.#driver.getPageCommunicator().getCurrentThreadID(this.#element, true);
|
|
14431
14432
|
} else {
|
|
14432
14433
|
const params = this.#routeViewDriver ? this.#routeViewDriver.getParams() : null;
|
|
14433
|
-
if (params && params.threadID) {
|
|
14434
|
+
if (params && typeof params.threadID === 'string') {
|
|
14434
14435
|
threadID = params.threadID;
|
|
14435
14436
|
} else {
|
|
14436
14437
|
const err = new Error('Failed to get id for thread');
|
|
@@ -14443,16 +14444,18 @@ class GmailThreadView {
|
|
|
14443
14444
|
return threadID;
|
|
14444
14445
|
}
|
|
14445
14446
|
async getThreadIDAsync() {
|
|
14446
|
-
|
|
14447
|
-
const idElement = this.#element.querySelector('[data-thread-
|
|
14447
|
+
if (this.#threadID) return this.#threadID;
|
|
14448
|
+
const idElement = this.#element.querySelector('[data-legacy-thread-id]');
|
|
14448
14449
|
if (!idElement) throw new Error('threadID element not found');
|
|
14449
14450
|
|
|
14450
14451
|
// the string value can be 'undefined'
|
|
14451
|
-
const
|
|
14452
|
-
|
|
14453
|
-
|
|
14454
|
-
|
|
14455
|
-
|
|
14452
|
+
const syncAttributeValue = idElement.getAttribute('data-thread-perm-id');
|
|
14453
|
+
if (!this.#syncThreadID && syncAttributeValue && syncAttributeValue !== 'undefined') {
|
|
14454
|
+
this.#syncThreadID = syncAttributeValue;
|
|
14455
|
+
}
|
|
14456
|
+
this.#threadID = idElement.getAttribute('data-legacy-thread-id');
|
|
14457
|
+
if (!this.#threadID && this.#syncThreadID) {
|
|
14458
|
+
this.#threadID = await this.#driver.getOldGmailThreadIdFromSyncThreadId(this.#syncThreadID);
|
|
14456
14459
|
}
|
|
14457
14460
|
if (this.#threadID) return this.#threadID;else throw new Error('Failed to get id for thread');
|
|
14458
14461
|
}
|
|
@@ -15070,7 +15073,7 @@ options.insert = htmlElement => {
|
|
|
15070
15073
|
htmlElement.setAttribute('data-inboxsdk-version',
|
|
15071
15074
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment -- this is injected by webpack
|
|
15072
15075
|
///@ts-ignore
|
|
15073
|
-
"2.2.
|
|
15076
|
+
"2.2.11-1764118012397-e51ed7952926d731");
|
|
15074
15077
|
document.head.append(htmlElement);
|
|
15075
15078
|
};
|
|
15076
15079
|
options.domAPI = (styleDomAPI_default());
|
|
@@ -19830,7 +19833,7 @@ mole_view_module_options.insert = htmlElement => {
|
|
|
19830
19833
|
htmlElement.setAttribute('data-inboxsdk-version',
|
|
19831
19834
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment -- this is injected by webpack
|
|
19832
19835
|
///@ts-ignore
|
|
19833
|
-
"2.2.
|
|
19836
|
+
"2.2.11-1764118012397-e51ed7952926d731");
|
|
19834
19837
|
document.head.append(htmlElement);
|
|
19835
19838
|
};
|
|
19836
19839
|
mole_view_module_options.domAPI = (styleDomAPI_default());
|