clarity-visualize 0.8.60 → 0.8.62

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.
@@ -1544,14 +1544,13 @@ class LayoutHelper {
1544
1544
  node.attributes = {};
1545
1545
  }
1546
1546
  this.setAttributes(linkElement, node);
1547
+ // Strip SRI: recorded hashes won't match proxied/redeployed bytes during replay. See microsoft/clarity#418.
1548
+ linkElement.removeAttribute("integrity");
1547
1549
  if ("rel" in node.attributes) {
1548
1550
  if (node.attributes["rel"] === "stylesheet" /* Constant.StyleSheet */) {
1549
1551
  this.stylesheets.push(new Promise((resolve) => {
1550
1552
  const proxy = useproxy !== null && useproxy !== void 0 ? useproxy : this.state.options.useproxy;
1551
1553
  if (proxy) {
1552
- if (linkElement.integrity) {
1553
- linkElement.removeAttribute('integrity');
1554
- }
1555
1554
  linkElement.href = proxy(linkElement.href, linkElement.id, "stylesheet" /* Constant.StyleSheet */);
1556
1555
  }
1557
1556
  linkElement.onload = linkElement.onerror = this.style.bind(this, linkElement, resolve);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clarity-visualize",
3
- "version": "0.8.60",
3
+ "version": "0.8.62",
4
4
  "description": "An analytics library that uses web page interactions to generate aggregated insights",
5
5
  "author": "Microsoft Corp.",
6
6
  "license": "MIT",
@@ -27,7 +27,7 @@
27
27
  "url": "https://github.com/Microsoft/clarity/issues"
28
28
  },
29
29
  "dependencies": {
30
- "clarity-decode": "^0.8.60"
30
+ "clarity-decode": "^0.8.62"
31
31
  },
32
32
  "devDependencies": {
33
33
  "@rollup/plugin-commonjs": "^24.0.0",
package/src/layout.ts CHANGED
@@ -411,15 +411,13 @@ export class LayoutHelper {
411
411
  linkElement = linkElement ? linkElement : this.createElement(doc, node.tag) as HTMLLinkElement;
412
412
  if (!node.attributes) { node.attributes = {}; }
413
413
  this.setAttributes(linkElement, node);
414
+ // Strip SRI: recorded hashes won't match proxied/redeployed bytes during replay. See microsoft/clarity#418.
415
+ linkElement.removeAttribute("integrity");
414
416
  if ("rel" in node.attributes) {
415
417
  if (node.attributes["rel"] === Constant.StyleSheet) {
416
418
  this.stylesheets.push(new Promise((resolve: () => void): void => {
417
419
  const proxy = useproxy ?? this.state.options.useproxy;
418
420
  if (proxy) {
419
- if (linkElement.integrity) {
420
- linkElement.removeAttribute('integrity');
421
- }
422
-
423
421
  linkElement.href = proxy(linkElement.href, linkElement.id, Constant.StyleSheet);
424
422
  }
425
423
  linkElement.onload = linkElement.onerror = this.style.bind(this, linkElement, resolve);