PageSourceSearch

https://www.hotely.cz/wsngo/js/common/nocowanie-migration-bridge.js?v=440064

js hotely.cz collected 2026-09-24 10:13:53 UTC 7,587 bytes, 1 lines download raw bytes

1(function(){if(window.__nopNocowanieMigrationBridge)return;window.__nopNocowanieMigrationBridge=!0;var C=".nocowanie-migration-notice-js",f="/ajax/profile/nocowanie_migration_modal",A="/ajax/profile/accept_terms",E="/ajax/profile/migration_notice",L=".nocowanie-migration-accept-js",d="nocowanie-migration-overlay",r="nocowanie-migration-doc",S=".nocowanie-migration-document-js",T="data-document-url",a="";function m(){var e=document.head.querySelector('meta[name="csrf_token"]');return e&&e.getAttribute("content")||""}function O(){return fetch(A,{method:"POST",headers:{"Content-Type":"application/json;charset=UTF-8","X-CSRF-TOKEN":m()}}).then(function(e){return e.json()})}function k(){return fetch(f,{method:"POST",headers:{"Content-Type":"application/json;charset=UTF-8","X-CSRF-TOKEN":m()}}).then(function(e){return e.json()}).then(function(e){return e&&e.html?e.html:null})}function p(e,t){var n=e.querySelector(L);n&&n.addEventListener("click",function(o){o.preventDefault(),n.classList.add("in-progress","disabled"),n.disabled=!0,O().then(function(i){if(!i||i.STATUS!=="OK")throw new Error("unexpected response");t()}).catch(function(){n.classList.remove("in-progress","disabled"),n.disabled=!1,console.error("Saving the terms acceptance failed.")})})}function l(e){h();var t=e("<div/>");t.one("loaded.bs.modal",function(n,o){p(o.$element[0],function(){t.szallasModal("hide")}),w(o.$element[0])}),t.szallasModal({remoteurl:f,show:!0,className:"nocowanie-migration-modal",hash:!1,closeTo:!1,backdrop:!0,footer:!1,disableNativeHide:!0})}var M=[".nocowanie-migration-modal-js,.nocowanie-migration-modal-js *{box-sizing:border-box;}",'.nocowanie-migration-modal-js{font-family:var(--font-sans,"Roboto",Arial,sans-serif);',"color:var(--color-text-default,#28292a);}",".nocowanie-migration-modal-js .modal-body{padding:24px;}",".nocowanie-migration-modal-js h3{margin:0 0 12px;font-size:20px;font-weight:700;","line-height:1.3;}",".nocowanie-migration-modal-js h3 strong{font-weight:inherit;}",".nocowanie-migration-modal-js p{margin:0 0 20px;font-size:14px;font-weight:400;","line-height:1.5;color:var(--color-text-muted,#4e4f51);}",".nocowanie-migration-modal-js .modal-body a{color:var(--color-text-info,#3598db);","text-decoration:underline;}",".nocowanie-migration-modal-js .nocowanie-migration-accept-js{display:block;width:100%;","padding:12px 20px;border:0;border-radius:var(--radius-interactive,4px);","background:var(--color-button-loyalty,#f60);color:var(--color-text-inverted,#fff);","font-family:inherit;font-size:14px;font-weight:700;line-height:1.2;","text-align:center;text-transform:uppercase;cursor:pointer;}",".nocowanie-migration-modal-js .nocowanie-migration-accept-js:hover{","background:var(--color-button-loyalty-hover,#f90);}",".nocowanie-migration-modal-js .nocowanie-migration-accept-js.disabled{opacity:.65;","cursor:default;pointer-events:none;}",".nocowanie-migration-modal-js p.text-muted{margin:12px 0 0;font-size:12px;","line-height:1.5;text-align:center;color:var(--color-text-muted,#4e4f51);}",".nocowanie-migration-modal .modal-dialog{width:auto;max-width:400px;}",".nocowanie-migration-modal .modal-content{border:0;","border-radius:var(--radius-xs,8px);}"].join(""),R=["#"+d+"{position:fixed;inset:0;z-index:2000;display:flex;","align-items:center;justify-content:center;padding:16px;","background:rgb(0 0 0 / 45%);overflow-y:auto;}","#"+d+" .modal-content{width:100%;max-width:400px;","background:var(--color-surface-neutral-base,#fff);","border-radius:var(--radius-xs,8px);","box-shadow:var(--shadow-dropdown,0 4px 16px rgb(0 0 0 / 16%));}"].join(""),g=!1;function h(){if(!g){g=!0;var e=document.createElement("style");e.textContent=M,document.head.appendChild(e)}}function D(e){h();var t=document.createElement("style");t.textContent=R,document.head.appendChild(t);var n=document.createElement("div");n.id=d,n.setAttribute("role","dialog"),n.setAttribute("aria-modal","true"),n.innerHTML=e,document.body.appendChild(n),p(n,function(){n.remove(),t.remove()}),w(n)}function z(e,t){var n=0;(function o(){var i=window.jQuery;if(i&&i.fn&&typeof i.fn.szallasModal=="function")return e(i);if(++n>200)return t();setTimeout(o,50)})()}function b(){k().then(function(e){e&&D(e)}).catch(function(){console.error("Loading the Nocowanie migration notice failed.")})}function N(){z(function(e){if(K(e))return P(e);l(e)},b)}function K(e){return e(".modal.in").is(":visible")}var I=5e3;function P(e){var t=setTimeout(function(){e("body").off("hidden.bs.modal.nocowanieMigration"),l(e)},I);e("body").one("hidden.bs.modal.nocowanieMigration",function(){clearTimeout(t),l(e)})}function U(e){return e==="nds"?b():N()}var F=["#"+r+"{position:fixed;inset:0;z-index:2100;display:flex;","align-items:center;justify-content:center;padding:16px;","background:rgb(0 0 0 / 45%);}
1","#"+r+" .nmd__frame{display:flex;flex-direction:column;","width:100%;max-width:760px;height:min(80vh,720px);overflow:hidden;","background:var(--color-surface-neutral-base,#fff);","border-radius:var(--radius-xs,8px);","box-shadow:var(--shadow-dropdown,0 4px 16px rgb(0 0 0 / 16%));}","#"+r+" .nmd__head{display:flex;align-items:center;","justify-content:space-between;gap:16px;padding:16px 20px;","border-bottom:1px solid var(--color-border-neutral-divider,#e4e5e6);}","#"+r+" .nmd__title{font-size:16px;font-weight:700;}","#"+r+" .nmd__close{cursor:pointer;border:0;background:none;","font:inherit;font-size:22px;line-height:1;padding:0 4px;","color:var(--color-text-muted,#4e4f51);}","#"+r+" .nmd__body{flex:1;width:100%;border:0;}"].join(""),v=!1;function H(){if(!v){v=!0;var e=document.createElement("style");e.textContent=F,document.head.appendChild(e)}}var s=!1;function Q(e,t){if(s||!e)return;s=!0,H();var n=document.activeElement,o=document.createElement("div");o.id=r,o.setAttribute("role","dialog"),o.setAttribute("aria-modal","true"),o.setAttribute("aria-label",t),o.innerHTML='<div class="nmd__frame"><div class="nmd__head"><span class="nmd__title"></span><button type="button" class="nmd__close">\xD7</button></div><iframe class="nmd__body" src="" referrerpolicy="same-origin"></iframe></div>',o.querySelector(".nmd__title").textContent=t,o.querySelector(".nmd__body").setAttribute("title",t);var i=o.querySelector(".nmd__close");a&&(i.setAttribute("aria-label",a),i.setAttribute("title",a)),o.querySelector(".nmd__body").setAttribute("src",e);function u(){document.removeEventListener("keydown",j,!0),o.remove(),s=!1,n&&typeof n.focus=="function"&&n.focus()}function j(c){(c.key==="Escape"||c.keyCode===27)&&(c.stopPropagation(),c.preventDefault(),u())}i.addEventListener("click",u),o.addEventListener("click",function(c){c.target===o&&u()}),document.addEventListener("keydown",j,!0),document.body.appendChild(o),i.focus()}function w(e){e.addEventListener("click",function(t){var n=t.target.closest&&t.target.closest(S);n&&(t.metaKey||t.ctrlKey||t.shiftKey||t.button!==0||(t.preventDefault(),Q(n.getAttribute(T)||n.getAttribute("href")||"",(n.textContent||"").trim())))})}var x=!1;function y(e){x||(x=!0,U(e))}function q(){fetch(E,{headers:{Accept:"application/json"}}).then(function(e){return e.json()}).then(function(e){e&&e.show&&(a=e.closeLabel||a,y(e.ds))}).catch(function(){})}function B(){var e=0;(function t(){if(window.jQuery&&window.jQuery.fn){window.jQuery(document).on("profile.loginSuccess.nocowanieMigration",q);return}++e>200||setTimeout(t,50)})()}function _(){B();var e=document.querySelector(C);e&&(a=e.getAttribute("data-close-label")||"",y(e.getAttribute("data-ds")))}document.readyState==="loading"?document.addEventListener("DOMContentLoaded",_):_()})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.