@devskin/browser-sdk 1.0.22 → 1.0.23

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.
@@ -1 +1 @@
1
- {"version":3,"file":"screenshot.d.ts","sourceRoot":"","sources":["../../src/collectors/screenshot.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEzC,qBAAa,mBAAmB;IAI5B,OAAO,CAAC,MAAM;IACd,OAAO,CAAC,SAAS;IAJnB,OAAO,CAAC,QAAQ,CAAS;gBAGf,MAAM,EAAE,aAAa,EACrB,SAAS,EAAE,SAAS;IAG9B;;OAEG;IACG,cAAc,CAAC,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;CA4CxE"}
1
+ {"version":3,"file":"screenshot.d.ts","sourceRoot":"","sources":["../../src/collectors/screenshot.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEzC,qBAAa,mBAAmB;IAI5B,OAAO,CAAC,MAAM;IACd,OAAO,CAAC,SAAS;IAJnB,OAAO,CAAC,QAAQ,CAAS;gBAGf,MAAM,EAAE,aAAa,EACrB,SAAS,EAAE,SAAS;IAG9B;;OAEG;IACG,cAAc,CAAC,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;CAmExE"}
@@ -8933,13 +8933,20 @@ class ScreenshotCollector {
8933
8933
  if (this.config.debug) {
8934
8934
  console.log('[DevSkin] Capturing page screenshot...');
8935
8935
  }
8936
+ // Get full page dimensions
8937
+ const fullWidth = Math.max(document.body.scrollWidth, document.documentElement.scrollWidth, document.body.offsetWidth, document.documentElement.offsetWidth, document.body.clientWidth, document.documentElement.clientWidth);
8938
+ const fullHeight = Math.max(document.body.scrollHeight, document.documentElement.scrollHeight, document.body.offsetHeight, document.documentElement.offsetHeight, document.body.clientHeight, document.documentElement.clientHeight);
8936
8939
  const canvas = yield html2canvas(document.body, {
8937
8940
  allowTaint: true,
8938
8941
  useCORS: true,
8939
8942
  logging: false,
8940
8943
  scale: 0.5, // Reduce size
8941
- width: window.innerWidth,
8942
- height: Math.min(document.documentElement.scrollHeight, 3000), // Max 3000px height
8944
+ width: fullWidth,
8945
+ height: fullHeight, // Capture ENTIRE page
8946
+ windowWidth: fullWidth,
8947
+ windowHeight: fullHeight,
8948
+ x: 0,
8949
+ y: 0,
8943
8950
  });
8944
8951
  // Convert to base64 JPEG (smaller than PNG)
8945
8952
  const screenshot = canvas.toDataURL('image/jpeg', 0.6);