@opentabs-dev/opentabs-plugin-meticulous 0.0.82 → 0.0.84
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 -16
- package/dist/adapter.iife.js.map +2 -2
- package/dist/tools.json +1 -1
- package/package.json +11 -4
package/dist/adapter.iife.js
CHANGED
|
@@ -341,10 +341,26 @@
|
|
|
341
341
|
ot.log = log;
|
|
342
342
|
|
|
343
343
|
// node_modules/@opentabs-dev/plugin-sdk/dist/storage.js
|
|
344
|
+
var withIframeFallback = (fn) => {
|
|
345
|
+
try {
|
|
346
|
+
const iframe = document.createElement("iframe");
|
|
347
|
+
iframe.style.display = "none";
|
|
348
|
+
document.body.appendChild(iframe);
|
|
349
|
+
try {
|
|
350
|
+
const iframeStorage = iframe.contentWindow?.localStorage;
|
|
351
|
+
return iframeStorage ? fn(iframeStorage) : null;
|
|
352
|
+
} finally {
|
|
353
|
+
document.body.removeChild(iframe);
|
|
354
|
+
}
|
|
355
|
+
} catch {
|
|
356
|
+
return null;
|
|
357
|
+
}
|
|
358
|
+
};
|
|
359
|
+
var getWindowLocalStorage = () => window.localStorage;
|
|
344
360
|
var getLocalStorage = (key) => {
|
|
345
361
|
let storage;
|
|
346
362
|
try {
|
|
347
|
-
storage =
|
|
363
|
+
storage = getWindowLocalStorage();
|
|
348
364
|
} catch {
|
|
349
365
|
return null;
|
|
350
366
|
}
|
|
@@ -355,19 +371,7 @@
|
|
|
355
371
|
return null;
|
|
356
372
|
}
|
|
357
373
|
}
|
|
358
|
-
|
|
359
|
-
const iframe = document.createElement("iframe");
|
|
360
|
-
iframe.style.display = "none";
|
|
361
|
-
document.body.appendChild(iframe);
|
|
362
|
-
try {
|
|
363
|
-
const iframeStorage = iframe.contentWindow?.localStorage;
|
|
364
|
-
return iframeStorage ? iframeStorage.getItem(key) : null;
|
|
365
|
-
} finally {
|
|
366
|
-
document.body.removeChild(iframe);
|
|
367
|
-
}
|
|
368
|
-
} catch {
|
|
369
|
-
return null;
|
|
370
|
-
}
|
|
374
|
+
return withIframeFallback((s) => s.getItem(key));
|
|
371
375
|
};
|
|
372
376
|
|
|
373
377
|
// node_modules/@opentabs-dev/plugin-sdk/dist/index.js
|
|
@@ -15727,7 +15731,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15727
15731
|
};
|
|
15728
15732
|
var src_default = new MeticulousPlugin();
|
|
15729
15733
|
|
|
15730
|
-
// dist/
|
|
15734
|
+
// dist/_adapter_entry_704afc1d-3ad2-4a72-b838-5ad7d7ccc964.ts
|
|
15731
15735
|
if (!globalThis.__openTabs) {
|
|
15732
15736
|
globalThis.__openTabs = {};
|
|
15733
15737
|
} else {
|
|
@@ -15943,5 +15947,5 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15943
15947
|
};
|
|
15944
15948
|
delete src_default.onDeactivate;
|
|
15945
15949
|
}
|
|
15946
|
-
})();(function(){var o=(globalThis).__openTabs;if(o&&o.adapters&&o.adapters["meticulous"]){var a=o.adapters["meticulous"];a.__adapterHash="
|
|
15950
|
+
})();(function(){var o=(globalThis).__openTabs;if(o&&o.adapters&&o.adapters["meticulous"]){var a=o.adapters["meticulous"];a.__adapterHash="f98ffb9bbfaa7b87f436e4fdff79f2bbd3b3d70c79e3b3d4958b00a70e04ed2a";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,"meticulous",{value:a,writable:false,configurable:false,enumerable:true});Object.defineProperty(o,"adapters",{value:o.adapters,writable:false,configurable:false});}})();
|
|
15947
15951
|
//# sourceMappingURL=adapter.iife.js.map
|