@chat21/chat21-web-widget 5.1.0-rc12 → 5.1.0-rc13

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.
package/CHANGELOG.md CHANGED
@@ -6,6 +6,9 @@
6
6
  ### **Copyrigth**:
7
7
  *Tiledesk SRL*
8
8
 
9
+ # 5.1.0-rc13
10
+ - **added**: ability to manage embedded chatbot-panel.html page into an iframe and hide some elements
11
+
9
12
  # 5.1.0-rc12
10
13
  - **added**: ability to get all my request from Tiledesk API
11
14
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@chat21/chat21-web-widget",
3
3
  "author": "Tiledesk SRL",
4
- "version": "5.1.0-rc12",
4
+ "version": "5.1.0-rc13",
5
5
  "license": "MIT",
6
6
  "homepage": "https://www.tiledesk.com",
7
7
  "repository": {
@@ -108,6 +108,27 @@
108
108
  }
109
109
  }
110
110
 
111
+ .loading-text {
112
+ position: absolute;
113
+ top: 60%;
114
+ left: 50%;
115
+ transform: translateX(-50%);
116
+ font-family: sans-serif;
117
+ font-size: 18px;
118
+ color: rgb(224, 106, 88);;
119
+ animation: blinkText 1.5s infinite ease-in-out;
120
+ }
121
+
122
+ /* Animazione lampeggiante */
123
+ @keyframes blinkText {
124
+ 0%, 100% {
125
+ opacity: 1;
126
+ }
127
+ 50% {
128
+ opacity: 0;
129
+ }
130
+ }
131
+
111
132
  #deferred-styles {
112
133
  display: none;
113
134
  }
@@ -458,6 +479,23 @@
458
479
  }(document, 'script', 'tiledesk-jssdk'));
459
480
 
460
481
  </script> -->
482
+
483
+
484
+ <script type="application/javascript" id="check_embed">
485
+ document.addEventListener('DOMContentLoaded', function () {
486
+ const isEmbedded = window.self !== window.top;
487
+
488
+ if (isEmbedded) {
489
+ //HIDE header and footer elements
490
+ const header = document.querySelector('header');
491
+ const footer = document.querySelector('footer');
492
+ if (header) header.style.display = 'none';
493
+ if (footer) footer.style.display = 'none';
494
+ }
495
+ });
496
+ </script>
497
+
498
+
461
499
  <script type="application/javascript">
462
500
  window.tiledeskSettings = {
463
501
  marginX: "100px",
@@ -654,6 +692,7 @@
654
692
 
655
693
  <div id="preloader">
656
694
  <div class="loader"></div>
695
+ <!-- <div class="loading-text">Loading . . .</div> -->
657
696
  </div>
658
697
 
659
698
  <header id="header">