ydshieh HF staff commited on
Commit
62f33d2
1 Parent(s): 9562792

Update split.js

Browse files
Files changed (1) hide show
  1. split.js +1 -11
split.js CHANGED
@@ -24,14 +24,11 @@ function fixDragBtn() {
24
  var gradio_container = document.getElementsByClassName("gradio-container")[0];
25
  var pb = w3_getStyleValue(gradio_container, "padding-bottom");
26
  pb = Number(pb.replace("px", ""));
27
- console.log(pb);
28
-
29
 
30
  var show_api = document.getElementsByClassName("show-api")[0];
31
  var api = w3_getStyleValue(show_api, "height");
32
  apih = Number(api.replace("px", ""));
33
- console.log(apih);
34
-
35
  // This is the actual value of the already updated document!
36
  var doc = document.documentElement.getBoundingClientRect();
37
 
@@ -39,16 +36,9 @@ function fixDragBtn() {
39
  if (hello == null) return;
40
  var rect = hello.getBoundingClientRect();
41
 
42
-
43
-
44
  var h = window.visualViewport.height - (rect.top - doc.top) - pb - apih;
45
  hello.style.height = `${h}px`;
46
 
47
- console.log(window.visualViewport.height);
48
- console.log(rect.top);
49
- console.log(doc.top);
50
- console.log("-------------")
51
-
52
  var wrapper = document.getElementById("right-area-wrapper");
53
  // var transcript = document.querySelector(`[data-tt-transcript="0"]`);
54
  var transcript = document.getElementById("transcript");
 
24
  var gradio_container = document.getElementsByClassName("gradio-container")[0];
25
  var pb = w3_getStyleValue(gradio_container, "padding-bottom");
26
  pb = Number(pb.replace("px", ""));
 
 
27
 
28
  var show_api = document.getElementsByClassName("show-api")[0];
29
  var api = w3_getStyleValue(show_api, "height");
30
  apih = Number(api.replace("px", ""));
31
+
 
32
  // This is the actual value of the already updated document!
33
  var doc = document.documentElement.getBoundingClientRect();
34
 
 
36
  if (hello == null) return;
37
  var rect = hello.getBoundingClientRect();
38
 
 
 
39
  var h = window.visualViewport.height - (rect.top - doc.top) - pb - apih;
40
  hello.style.height = `${h}px`;
41
 
 
 
 
 
 
42
  var wrapper = document.getElementById("right-area-wrapper");
43
  // var transcript = document.querySelector(`[data-tt-transcript="0"]`);
44
  var transcript = document.getElementById("transcript");