@opentabs-dev/opentabs-plugin-linear 0.0.74 → 0.0.75
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/adapter.iife.js +20 -30
- package/dist/adapter.iife.js.map +3 -3
- package/dist/tools/set-api-key.d.ts +8 -0
- package/dist/tools/set-api-key.d.ts.map +1 -0
- package/dist/tools/set-api-key.js +28 -0
- package/dist/tools/set-api-key.js.map +1 -0
- package/dist/tools.json +4 -4
- package/package.json +3 -3
package/dist/adapter.iife.js
CHANGED
|
@@ -245,18 +245,18 @@
|
|
|
245
245
|
|
|
246
246
|
// node_modules/@opentabs-dev/plugin-sdk/dist/storage.js
|
|
247
247
|
var getLocalStorage = (key) => {
|
|
248
|
+
try {
|
|
249
|
+
return localStorage.getItem(key);
|
|
250
|
+
} catch {
|
|
251
|
+
}
|
|
248
252
|
let storage;
|
|
249
253
|
try {
|
|
250
|
-
storage =
|
|
254
|
+
storage = localStorage;
|
|
251
255
|
} catch {
|
|
252
256
|
return null;
|
|
253
257
|
}
|
|
254
|
-
if (storage) {
|
|
255
|
-
|
|
256
|
-
return storage.getItem(key);
|
|
257
|
-
} catch {
|
|
258
|
-
return null;
|
|
259
|
-
}
|
|
258
|
+
if (storage !== void 0) {
|
|
259
|
+
return null;
|
|
260
260
|
}
|
|
261
261
|
try {
|
|
262
262
|
const iframe = document.createElement("iframe");
|
|
@@ -15362,21 +15362,21 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15362
15362
|
};
|
|
15363
15363
|
var src_default = new LinearPlugin();
|
|
15364
15364
|
|
|
15365
|
-
// dist/
|
|
15365
|
+
// dist/_adapter_entry_e9556c9b-35c2-47a1-b36a-85025ecca7ba.ts
|
|
15366
15366
|
if (!globalThis.__openTabs) {
|
|
15367
15367
|
globalThis.__openTabs = {};
|
|
15368
15368
|
} else {
|
|
15369
15369
|
const desc = Object.getOwnPropertyDescriptor(globalThis.__openTabs, "adapters");
|
|
15370
15370
|
if (desc && !desc.writable) {
|
|
15371
|
-
const
|
|
15371
|
+
const ot2 = globalThis.__openTabs;
|
|
15372
15372
|
const newAdaptersObj = {};
|
|
15373
|
-
if (
|
|
15374
|
-
for (const key of Object.keys(
|
|
15375
|
-
const d = Object.getOwnPropertyDescriptor(
|
|
15373
|
+
if (ot2.adapters) {
|
|
15374
|
+
for (const key of Object.keys(ot2.adapters)) {
|
|
15375
|
+
const d = Object.getOwnPropertyDescriptor(ot2.adapters, key);
|
|
15376
15376
|
if (d) Object.defineProperty(newAdaptersObj, key, d);
|
|
15377
15377
|
}
|
|
15378
15378
|
}
|
|
15379
|
-
globalThis.__openTabs = Object.assign({},
|
|
15379
|
+
globalThis.__openTabs = Object.assign({}, ot2, { adapters: newAdaptersObj });
|
|
15380
15380
|
}
|
|
15381
15381
|
}
|
|
15382
15382
|
if (!globalThis.__openTabs.adapters) {
|
|
@@ -15414,16 +15414,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15414
15414
|
}
|
|
15415
15415
|
};
|
|
15416
15416
|
var restoreTransport = setLogTransport ? setLogTransport(logTransport) : void 0;
|
|
15417
|
-
var ot2 = globalThis.__openTabs;
|
|
15418
|
-
ot2._notifyReadinessChanged = () => {
|
|
15419
|
-
try {
|
|
15420
|
-
const nonce = globalThis.__openTabs?._readinessNonce;
|
|
15421
|
-
if (nonce) {
|
|
15422
|
-
window.postMessage({ type: "opentabs:readiness-changed", plugin: "linear", nonce }, "*");
|
|
15423
|
-
}
|
|
15424
|
-
} catch {
|
|
15425
|
-
}
|
|
15426
|
-
};
|
|
15427
15417
|
var existing = adapters["linear"];
|
|
15428
15418
|
if (existing) {
|
|
15429
15419
|
if (typeof existing.teardown === "function") {
|
|
@@ -15435,7 +15425,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15435
15425
|
}
|
|
15436
15426
|
}
|
|
15437
15427
|
if (!Reflect.deleteProperty(adapters, "linear")) {
|
|
15438
|
-
const
|
|
15428
|
+
const ot2 = globalThis.__openTabs;
|
|
15439
15429
|
const newAdapters = {};
|
|
15440
15430
|
for (const key of Object.keys(adapters)) {
|
|
15441
15431
|
if (key !== "linear") {
|
|
@@ -15443,7 +15433,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15443
15433
|
if (desc) Object.defineProperty(newAdapters, key, desc);
|
|
15444
15434
|
}
|
|
15445
15435
|
}
|
|
15446
|
-
globalThis.__openTabs = Object.assign({},
|
|
15436
|
+
globalThis.__openTabs = Object.assign({}, ot2, { adapters: newAdapters });
|
|
15447
15437
|
}
|
|
15448
15438
|
var hasLifecycleHooks = typeof src_default.onToolInvocationStart === "function" || typeof src_default.onToolInvocationEnd === "function";
|
|
15449
15439
|
for (const tool of src_default.tools) {
|
|
@@ -15504,12 +15494,12 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15504
15494
|
}
|
|
15505
15495
|
}
|
|
15506
15496
|
};
|
|
15507
|
-
const
|
|
15508
|
-
if (!
|
|
15497
|
+
const ot2 = globalThis.__openTabs;
|
|
15498
|
+
if (!ot2._navigationInterceptor) {
|
|
15509
15499
|
const origPushState = history.pushState.bind(history);
|
|
15510
15500
|
const origReplaceState = history.replaceState.bind(history);
|
|
15511
15501
|
const callbacks = /* @__PURE__ */ new Map();
|
|
15512
|
-
|
|
15502
|
+
ot2._navigationInterceptor = { callbacks, origPushState, origReplaceState };
|
|
15513
15503
|
history.pushState = function(...args) {
|
|
15514
15504
|
origPushState(...args);
|
|
15515
15505
|
for (const cb of callbacks.values()) {
|
|
@@ -15523,7 +15513,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15523
15513
|
}
|
|
15524
15514
|
};
|
|
15525
15515
|
}
|
|
15526
|
-
const interceptor =
|
|
15516
|
+
const interceptor = ot2._navigationInterceptor;
|
|
15527
15517
|
interceptor.callbacks.set("linear", checkUrl);
|
|
15528
15518
|
window.addEventListener("popstate", checkUrl);
|
|
15529
15519
|
window.addEventListener("hashchange", checkUrl);
|
|
@@ -15578,5 +15568,5 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15578
15568
|
};
|
|
15579
15569
|
delete src_default.onDeactivate;
|
|
15580
15570
|
}
|
|
15581
|
-
})();(function(){var o=(globalThis).__openTabs;if(o&&o.adapters&&o.adapters["linear"]){var a=o.adapters["linear"];a.__adapterHash="
|
|
15571
|
+
})();(function(){var o=(globalThis).__openTabs;if(o&&o.adapters&&o.adapters["linear"]){var a=o.adapters["linear"];a.__adapterHash="50ed331b2cae64de6370a0c7b78af84923ed5b1ba78be6975e526afcdf5a55e4";if(a.tools&&Array.isArray(a.tools)){for(var i=0;i<a.tools.length;i++){Object.freeze(a.tools[i]);}Object.freeze(a.tools);}Object.freeze(a);Object.defineProperty(o.adapters,"linear",{value:a,writable:false,configurable:false,enumerable:true});Object.defineProperty(o,"adapters",{value:o.adapters,writable:false,configurable:false});}})();
|
|
15582
15572
|
//# sourceMappingURL=adapter.iife.js.map
|