raster pushed a commit to branch master.

http://git.enlightenment.org/website/www.git/commit/?id=3914bc34d0d45cfdcbe4ead4e3b722073b394a87

commit 3914bc34d0d45cfdcbe4ead4e3b722073b394a87
Author: Carsten Haitzler (Rasterman) <ras...@rasterman.com>
Date:   Thu Jul 25 19:04:22 2019 +0100

    footer - make chat with us on click on demand
---
 public_html/lib/tpl/e/footer.html | 86 +++++++++++++++++++++------------------
 1 file changed, 47 insertions(+), 39 deletions(-)

diff --git a/public_html/lib/tpl/e/footer.html 
b/public_html/lib/tpl/e/footer.html
index fdd3c7db..6d9a3574 100644
--- a/public_html/lib/tpl/e/footer.html
+++ b/public_html/lib/tpl/e/footer.html
@@ -1,37 +1,7 @@
 <!-- footer content goes here -->
-<div id="ircbubble" style="display: none"></div>
-
-<div id="ircbutton"
-  onmousedown="this.style.background='#3399ff'"
-  ontouchstart="this.style.background='#3399ff'"
-  onmouseup="this.style.background='#181818'"
-  ontouchend="this.style.background='#181818'"
-  onclick="{
-    var d = document.getElementById('ircbubble');
-    if (!(d.style.display === 'none')) {
-      d.style.display = 'none';
-    } else {
-      d.style.display = 'block';
-    }
-  }"
->
-<svg width="120" height="60" version="1.1" viewBox="0 0 31.75 15.875" 
xmlns="http://www.w3.org/2000/svg";>
- <g transform="matrix(1.01308 0 0 1.0135 15.8868 -283.774)">
-   <path transform="matrix(.26 0 0 .26 0 280)" d="m10 30c-0.043494 5.71319 
2.35848 11.1722 6.6 15-1.1 2.8-3.3 4.9-6.6 5.2h20c11.0457 0 20-8.9543 
20-20s-8.9543-20.2-20-20.2-20 8.9543-20 20zm12-2c1.10457 0 2 0.895431 2 
2s-0.895431 2-2 2-2-0.895431-2-2 0.895431-2 2-2zm8 0c1.10457 0 2 0.895431 2 
2s-0.895431 2-2 2-2-0.895431-2-2 0.895431-2 2-2zm8 0c1.10457 0 2 0.895431 2 
2s-0.895431 2-2 2-2-0.895431-2-2 0.895431-2 2-2z" fill="#fff"/>
- </g>
-  <g transform="matrix(.264583 0 0 .264583 0 .18576)" fill="#fff" 
stroke-width="1px" aria-label="TALK WITH US">
-  <path d="m16.4714 
10.6102h8.95833v1.89453h-3.22266v7.82552h-2.50651v-7.82552h-3.22917z"/>
-  <path d="m31.5755 18.5594h-3.91927l-0.618489 
1.77083h-2.51953l3.60026-9.72005h2.98828l3.60026 
9.72005h-2.51953zm-3.29427-1.80338h2.66276l-1.32812-3.86719z"/>
-  <path d="m35.9896 10.6102h2.50651v7.82552h4.40104v1.89453h-6.90755z"/>
-    <path d="m44.4792 10.6102h2.50651v3.54818l3.61328-3.54818h2.91016l-4.68099 
4.60286 5.16276 5.11719h-3.13802l-3.86719-3.82813v3.82813h-2.50651z"/>
-  <path d="m15.4232 24.3435h2.40234l1.67969 7.0638 
1.66667-7.0638h2.41536l1.66667 7.0638 1.67969-7.0638h2.38281l-2.29167 
9.72005h-2.89062l-1.76432-7.38932-1.74479 7.38932h-2.89062z"/>
-  <path d="m30.9635 24.3435h2.50651v9.72005h-2.50651z"/>
-    <path d="m34.7786 
24.3435h8.95833v1.89453h-3.22266v7.82552h-2.50651v-7.82552h-3.22917z"/>
-  <path d="m45.026 
24.3435h2.50651v3.70443h3.69792v-3.70443h2.50651v9.72005h-2.50651v-4.12109h-3.69792v4.12109h-2.50651z"/>
-  <path d="m26.0026 38.0768h2.50651v5.82682q0 1.20443 0.390625 1.72526  
0.397136 0.514323 1.28906 0.514323 0.898437 0 1.28906-0.514323 
0.397136-0.520833 0.397136-1.72526v-5.82682h2.50651v5.82682q0 2.0638-1.03516 
3.07292-1.03516 1.00912-3.15755 1.00912-2.11589 
0-3.15104-1.00912-1.03516-1.00911-1.03516-3.07292z"/>
-  <path d="m43.6003 
38.3828v2.05729q-0.800781-0.358073-1.5625-0.540365t-1.4388-0.182292q-0.898438 
0-1.32812 0.247396-0.429688 0.247396-0.429688 0.768229 0 0.390625 0.286458 
0.61198 0.292969 0.214843 1.05469 0.371093l1.06771 0.214844q1.62109 0.325521 
2.30469 0.989583 0.683594 0.664063 0.683594 1.88802 0 1.60807-0.957031 
2.39583-0.950521 0.78125-2.91016 0.78125-0.924479 
0-1.85547-0.175781-0.930989-0.175782-1.86198-0.520834v-2.11588q0.93099 0.494791 
1.79688 0.748698 0.872396 0.247396 1.6796 [...]
- </g>
-</svg>
+<div id="ircbubble" style="display: none;">
+ <div id="ircbubble2"style="background:url(/_media/loading.svg) center center 
no-repeat;">
+ </div>
 </div>
 
 <script>
@@ -189,11 +159,49 @@ var nick =
   n1[Math.floor(Math.random() * n1.length)] +
   '-' +
   n2[Math.floor(Math.random() * n2.length)];
+var iframe;
 
-var iframe = document.createElement('iframe');
-
-iframe.setAttribute('src',
-  'https://kiwiirc.com/client/irc.freenode.net/?nick=' + nick + 
'&theme=cli#e');
-iframe.setAttribute('style', 'border:0; width:360px; height:500px;');
-document.getElementById('ircbubble').appendChild(iframe);
+  function initFrame() {
+    if (!iframe) {
+      iframe = document.createElement('iframe');
+      iframe.setAttribute('src',
+        'https://kiwiirc.com/client/irc.freenode.net/?nick=' + nick + 
'&theme=cli#e');
+      iframe.setAttribute('sandbox', 'allow-forms allow-scripts 
allow-same-origin');
+      iframe.setAttribute('style', 'border:0; width:360px; height:500px;');
+      document.getElementById('ircbubble2').appendChild(iframe);
+    }
+  }
 </script>
+<div id="ircbutton"
+  onmousedown="this.style.background='#3399ff'"
+  ontouchstart="this.style.background='#3399ff'"
+  onmouseup="this.style.background='#181818'"
+  ontouchend="this.style.background='#181818'"
+  onclick="{
+    var d = document.getElementById('ircbubble');
+    if (!(d.style.display === 'none')) {
+      d.style.display = 'none';
+    } else {
+      d.style.display = 'block';
+    }
+    initFrame();
+  }"
+>
+<svg width="120" height="60" version="1.1" viewBox="0 0 31.75 15.875" 
xmlns="http://www.w3.org/2000/svg";>
+ <g transform="matrix(1.01308 0 0 1.0135 15.8868 -283.774)">
+   <path transform="matrix(.26 0 0 .26 0 280)" d="m10 30c-0.043494 5.71319 
2.35848 11.1722 6.6 15-1.1 2.8-3.3 4.9-6.6 5.2h20c11.0457 0 20-8.9543 
20-20s-8.9543-20.2-20-20.2-20 8.9543-20 20zm12-2c1.10457 0 2 0.895431 2 
2s-0.895431 2-2 2-2-0.895431-2-2 0.895431-2 2-2zm8 0c1.10457 0 2 0.895431 2 
2s-0.895431 2-2 2-2-0.895431-2-2 0.895431-2 2-2zm8 0c1.10457 0 2 0.895431 2 
2s-0.895431 2-2 2-2-0.895431-2-2 0.895431-2 2-2z" fill="#fff"/>
+ </g>
+  <g transform="matrix(.264583 0 0 .264583 0 .18576)" fill="#fff" 
stroke-width="1px" aria-label="TALK WITH US">
+  <path d="m16.4714 
10.6102h8.95833v1.89453h-3.22266v7.82552h-2.50651v-7.82552h-3.22917z"/>
+  <path d="m31.5755 18.5594h-3.91927l-0.618489 
1.77083h-2.51953l3.60026-9.72005h2.98828l3.60026 
9.72005h-2.51953zm-3.29427-1.80338h2.66276l-1.32812-3.86719z"/>
+  <path d="m35.9896 10.6102h2.50651v7.82552h4.40104v1.89453h-6.90755z"/>
+    <path d="m44.4792 10.6102h2.50651v3.54818l3.61328-3.54818h2.91016l-4.68099 
4.60286 5.16276 5.11719h-3.13802l-3.86719-3.82813v3.82813h-2.50651z"/>
+  <path d="m15.4232 24.3435h2.40234l1.67969 7.0638 
1.66667-7.0638h2.41536l1.66667 7.0638 1.67969-7.0638h2.38281l-2.29167 
9.72005h-2.89062l-1.76432-7.38932-1.74479 7.38932h-2.89062z"/>
+  <path d="m30.9635 24.3435h2.50651v9.72005h-2.50651z"/>
+    <path d="m34.7786 
24.3435h8.95833v1.89453h-3.22266v7.82552h-2.50651v-7.82552h-3.22917z"/>
+  <path d="m45.026 
24.3435h2.50651v3.70443h3.69792v-3.70443h2.50651v9.72005h-2.50651v-4.12109h-3.69792v4.12109h-2.50651z"/>
+  <path d="m26.0026 38.0768h2.50651v5.82682q0 1.20443 0.390625 1.72526  
0.397136 0.514323 1.28906 0.514323 0.898437 0 1.28906-0.514323 
0.397136-0.520833 0.397136-1.72526v-5.82682h2.50651v5.82682q0 2.0638-1.03516 
3.07292-1.03516 1.00912-3.15755 1.00912-2.11589 
0-3.15104-1.00912-1.03516-1.00911-1.03516-3.07292z"/>
+  <path d="m43.6003 
38.3828v2.05729q-0.800781-0.358073-1.5625-0.540365t-1.4388-0.182292q-0.898438 
0-1.32812 0.247396-0.429688 0.247396-0.429688 0.768229 0 0.390625 0.286458 
0.61198 0.292969 0.214843 1.05469 0.371093l1.06771 0.214844q1.62109 0.325521 
2.30469 0.989583 0.683594 0.664063 0.683594 1.88802 0 1.60807-0.957031 
2.39583-0.950521 0.78125-2.91016 0.78125-0.924479 
0-1.85547-0.175781-0.930989-0.175782-1.86198-0.520834v-2.11588q0.93099 0.494791 
1.79688 0.748698 0.872396 0.247396 1.6796 [...]
+ </g>
+</svg>
+</div>

-- 


Reply via email to