Overlay QuiverPRO - Coneccta

Interface overlay

目前為 2023-06-05 提交的版本,檢視 最新版本

此腳本不應該直接安裝,它是一個供其他腳本使用的函式庫。欲使用本函式庫,請在腳本 metadata 寫上: // @require https://update.gf.qytechs.cn/scripts/467601/1200402/Overlay%20QuiverPRO%20-%20Coneccta.js

  1. function aguardarElemento(seletorReferencia, callback, FrequenciaMs, timeoutMs) {
  2. var InicioMs = Date.now();
  3.  
  4. function loopPesquisa() {
  5.  
  6. if (document.querySelector(seletorReferencia) !== null) {
  7. console.log(document.querySelector(seletorReferencia));
  8. callback();
  9. return;
  10. } else {
  11. setTimeout(function() {
  12. if (timeoutMs && Date.now() - InicioMs > timeoutMs) {
  13. return;
  14. }
  15. loopPesquisa();
  16. }, FrequenciaMs);
  17. }
  18. }
  19.  
  20. loopPesquisa();
  21. }
  22.  
  23. (function() {
  24. 'use strict';
  25.  
  26. // Function to insert the first overlay element
  27. function inserirElemento(divReferencia, divClassName, labelClassName, styleName, labelText) {
  28. var referencia = document.getElementById(divReferencia);
  29. let div = document.createElement('div')
  30. div.className = divClassName
  31. let label = document.createElement('label');
  32. label.className = labelClassName
  33. label.textContent = labelText;
  34. label.style.cssText = styleName;
  35. referencia.appendChild(div);
  36. div.appendChild(label)
  37. console.log("Inseriu elemento " + referencia);
  38. }
  39.  
  40. // Define the styles for the first overlay element
  41. const labelStyle = `
  42. position: static;
  43. font-family: inherit;
  44. font-size: 2em;
  45. letter-spacing: 0px;
  46. text-transform: uppercase;
  47. width: 100%;
  48. text-align: center;
  49. font-color: #fff;
  50. line-height: 2em;
  51. outline: none;
  52. animation: animate 10s linear infinite;
  53. border: 1px solid black;
  54. border-radius: 5px;
  55. animation: blinkingC 1s infinite;
  56. `;
  57.  
  58. // Define the styles for the second overlay element
  59. const labelStyle2 = `
  60. position: static;
  61. font-family: inherit;
  62. font-size: 2em;
  63. letter-spacing: 0px;
  64. text-transform: uppercase;
  65. width: 100%;
  66. text-align: center;
  67. font-color: #fff;
  68. line-height: 2em;
  69. outline: none;
  70. animation: animate 10s linear infinite;
  71. border: 1px solid black;
  72. border-radius: 5px;
  73. animation: blinkingC2 1s infinite;
  74. `;
  75.  
  76. // Define the blinking animation for the label element
  77. const blinkAnimation = `
  78. @keyframes blinkingC {
  79. 0% {
  80. color: white;
  81. background: #03a600;
  82. }
  83. 100% {
  84. color: lightcyan;
  85. background: #bfbf10;
  86. }
  87. }
  88. `;
  89.  
  90. // Define the blinking animation for the label element
  91. const blinkAnimation2 = `
  92. @keyframes blinkingC2 {
  93. 0% {
  94. color: white;
  95. background: #bfbf10;
  96. }
  97. 100% {
  98. color: lightcyan;
  99. background: #03a600;
  100. }
  101. }
  102. `;
  103.  
  104. // Add the blinking animation to the page
  105. const style = document.createElement('style');
  106. style.appendChild(document.createTextNode(blinkAnimation));
  107. style.appendChild(document.createTextNode(blinkAnimation2));
  108. document.head.appendChild(style);
  109.  
  110.  
  111. // AUTOMÓVEL
  112.  
  113. aguardarElemento("#DIVPadrao2000_Observacoes", function() {
  114. inserirElemento("DIVPadrao2000_Observacoes", "card-Overlay", "label-Overlay", labelStyle, "Informe que a ligação está sendo gravada");
  115. }, 1000, 900000);
  116.  
  117. aguardarElemento("#BoxDadosSegurado", function() {
  118. inserirElemento("BoxDadosSegurado", "card-Overlay", "label-Overlay", labelStyle2, "Verificar grupo de afinidade");
  119. }, 1000, 900000);
  120.  
  121. aguardarElemento("#DIVPadrao2000_Cobertura190 > div", function() {
  122. inserirElemento("DIVPadrao2000_Cobertura190", "card-Overlay", "label-Overlay-tipo-uso", labelStyle, "Esclarecer que uso particular implica em não utilizar o veículo para atividade comercial");
  123. var elementoInserido = document.getElementsByClassName("label-Overlay-tipo-uso")[0]
  124. document.querySelector("#BoxInforLoc > div > div:nth-child(1)").appendChild(elementoInserido)
  125.  
  126. }, 1000, 900000);
  127.  
  128. aguardarElemento("#BoxCobsBasicas", function() {
  129. inserirElemento("BoxCobsBasicas", "card-Overlay", "label-Overlay", labelStyle2, "Verificar se as coberturas atendem o segurado");
  130. }, 1000, 900000);
  131.  
  132. aguardarElemento("#BoxBoxRenovacao", function() {
  133. inserirElemento("BoxBoxRenovacao", "card-Overlay", "label-Overlay", labelStyle, "Verificar se o segurado acionou o seguro na última vigência");
  134. }, 1000, 900000);
  135.  
  136. aguardarElemento("#DIVDadosCondutor", function() {
  137. inserirElemento("BoxInforCond", "card-Overlay", "label-Overlay-dados-condutor", labelStyle2, "Deve ser informado o condutor mais jovem de uso frequente");
  138. var valorSlider = document.querySelector("#Padrao2000_Cobertura199909").value
  139. var slider = document.getElementsByClassName("slider round")[0]
  140. var elementoInserido = document.getElementsByClassName("label-Overlay-dados-condutor")[0]
  141. if(valorSlider === "True") { elementoInserido.style.display = "none"; elementoInserido.id = "label-slider-inativo"; } else { elementoInserido.style.display = ""; elementoInserido.id = "label-slider-ativo";};
  142. slider.addEventListener("click", () => { switch(elementoInserido.id) {
  143. case 'label-slider-inativo':
  144. elementoInserido.style.display = "";
  145. elementoInserido.id = "label-slider-ativo";
  146. break;
  147. case 'label-slider-ativo':
  148. elementoInserido.style.display = "none";
  149. elementoInserido.id = "label-slider-inativo";
  150. break
  151. }})
  152. }, 1000, 9000000);
  153.  
  154. aguardarElemento("#gview_GridAcomp > div:nth-child(2)", function() {
  155. var coberturasValoresDiv = document.querySelector("#gbox_GridAcomp")
  156. coberturasValoresDiv.id = "coberturas-valores"
  157. inserirElemento("coberturas-valores", "card-Overlay", "label-Overlay-cobertura-Valores", labelStyle, "Confirmar coberturas (inclusive teto solar e carro reserva)");
  158. var elementoInserido = document.getElementsByClassName("label-Overlay-cobertura-Valores")[0]
  159. coberturasValoresDiv.prepend(elementoInserido)
  160. }, 1000, 900000);
  161.  
  162. aguardarElemento("#BoxgrpFormaPgto > div:nth-child(12)", function() {
  163. inserirElemento("BoxgrpFormaPgto", "card-Overlay", "label-Overlay-forma-pagamento", labelStyle, "Confirmar se o segurado é o titular da conta. Caso não seja, entrar em contato com o titular.");
  164. var elementoInserido = document.getElementsByClassName("label-Overlay-forma-pagamento")[0]
  165. document.getElementById("BoxgrpFormaPgto").prepend(elementoInserido)
  166. }, 1000, 900000);
  167.  
  168. // RESIDENCIAL
  169.  
  170. aguardarElemento("#BoxDadosSeg", function() {
  171. inserirElemento("BoxDadosSeg", "card-Overlay", "label-Overlay", labelStyle, "Informe que a ligação está sendo gravada");
  172. }, 1000, 900000);
  173.  
  174. aguardarElemento("#BoxGrupo1", function() {
  175. inserirElemento("BoxGrupo1", "card-Overlay", "label-Overlay", labelStyle2, "Confirmar nome, proprietário e grupo de afinidade");
  176. }, 1000, 900000);
  177.  
  178. aguardarElemento("#BoxInforLoc > div:nth-child(3)", function() {
  179. document.querySelector("#BoxInforLoc > div:nth-child(3)").id = "BoxInforLoc - div(3)"
  180. inserirElemento("BoxInforLoc - div(3)", "card-Overlay", "label-Overlay-tipo-imovel", labelStyle, "Confirmar endereço e demais informações");
  181. var elementoInserido = document.getElementsByClassName("label-Overlay-tipo-imovel")[0];
  182. document.querySelector("#BoxInforLoc > div:nth-child(3)").appendChild(elementoInserido);
  183. }, 1000, 900000);
  184.  
  185. aguardarElemento("#DIVDemaisCarac", function() {
  186. inserirElemento("DIVDemaisCarac", "card-Overlay", "label-Overlay", labelStyle2, "Confirmar se há protecionais e placa solar no local de risco");
  187. }, 1000, 900000);
  188.  
  189. // Allianz
  190. aguardarElemento("#DIVGridResultado > div > div:nth-child(4) > div > div.col-sm-12.text-center.border-cia > div > div:nth-child(1) > img", function() {
  191. var xpathFilter = "//img[@src='../img/logo_30015.gif']";
  192. var xpathResult = document.evaluate(xpathFilter, document, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null);
  193. for (var i = 0; i < xpathResult.snapshotLength; i++) {
  194. if ( i == 2 ) { var element = xpathResult.snapshotItem(i) }
  195. }
  196. var div = element.parentNode.parentNode.parentNode.parentNode.parentNode
  197. var divCriada = document.createElement('div')
  198. var labelCriado = document.createElement('label')
  199. labelCriado.textContent = 'Allianz indenisa por metragem original no registro de imóveis';
  200. labelCriado.style.cssText = labelStyle;
  201. labelCriado.style.fontSize = "1.2em";
  202. divCriada.appendChild(labelCriado);
  203. div.appendChild(divCriada)
  204. }, 1000, 900000);
  205.  
  206. })();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址