Closed UCyborg closed 1 year ago
If I heard correctly, we're getting real structuredClone soon.
Serpent 52.9.0 (32-bit) (2023-04-13) has a fully functioning implementation of the structuredClone() global function 👍 ; the [Chr]Edge download portal (redirects to
https://www.microsoft.com/el-gr/edge/download?form=MA13FJ
in my location) works OK without the structuredClone() polyfill you posted in the MSFN forums... For posterity, I was using a "userscript" implementation of it (in Violentmonkey):
// ==UserScript==
// @name Add structuredClone() support
// @version 0.1
// @description Polyfills 'structuredClone()', first implemented in Firefox 94
// @author UCyborg
// @namespace UCyborg
// @homepageURL https://msfn.org/board/topic/184051-my-browser-builds-part-4/?do=findComment&comment=1241405
// @icon https://developer.mozilla.org/favicon-48x48.cbbd161b.png
// @include https://www.microsoft.com/*
// @run-at document-start
// @grant none
// ==/UserScript==
if (typeof self.structuredClone !== "function") {
self.structuredClone = function (value) {
if (Array.isArray(value)) {
const count = value.length;
let arr = new Array(count);
for (let i = 0; i < count; i++) {
arr[i] = self.structuredClone(value[i]);
}
return arr;
} else if (typeof value === "object") {
let obj = {};
for (const prop in value) {
obj[prop] = self.structuredClone(value[prop]);
}
return obj;
} else {
return value;
}
}
}
minor changes to class definitions to get images loading inside articles on this site, eg. How to Disable Full Row Select in Explorer in Windows 7? Edit: Seems Winhelponline was recently updated, that script dealing with images (cmbv2.js) no longer contains those incompatible classes.
On my previous, 2-week old, Serpent 52.9.0 build (buildID=20230330030628), the images on the linked WHO article would NOT display :disappointed:; they still don't now, after having updated to the latest St52 (32-bit) build ((buildID=20230413085738) 😢 ...
I'm sorry, I'm not going to start diffing packaged versions.
If any of this is still relevant on 32.2, please create a PR.
If you find few moments, take a look at builtin-rules.s inside my palefill 1.26.2 (sorry, lost track, no history on my GitHub, so posting here).
Focus only on rules targeting these:
Edit: Seems Winhelponline was recently updated, that script dealing with images (cmbv2.js) no longer contains those incompatible classes.
Edit2: Maybe not...same issue and scripts on https://text-compare.com/, updated the extension.