diff --git a/index.html b/index.html
index 7780672..d7c05be 100644
--- a/index.html
+++ b/index.html
@@ -16,7 +16,7 @@
-
@@ -235,11 +236,21 @@
Python Profiler Viewer
Compare
-
-
-
-
-
+
+
+
+
+
@@ -248,7 +259,7 @@ Python Profiler Viewer
const workerCode = `
self.addEventListener("message", async function(e) {
const file = e.data.file;
- const CHUNK_SIZE = 1024 * 1024;
+ const CHUNK_SIZE = 2024 * 2024 ;
let offset = 0;
const decoder = new TextDecoder();
let leftover = '';
@@ -385,10 +396,31 @@ Python Profiler Viewer
if (tab.dataset.tab === "timelineTab") {
setTimeout(() => Plotly.Plots.resize(document.getElementById('timeline')), 50);
}
+
+ if (tab.dataset.tab === "flamegraphTab") {
+ flamegraphActive = true;
+ renderFlamegraph(flamegraphRoot);
+ } else {
+ flamegraphActive = false;
+ }
});
});
+
+
+
+
+
+
+ resizeObserver = new ResizeObserver(() => {
+ if (flamegraphActive) {
+ renderFlamegraph(flamegraphRoot);
+ }
+ });
+ resizeObserver.observe(document.getElementById("flamegraphView"));
+
+