(function(a){'use strict';a(function(){a('[data-toggle="tooltip"]').tooltip(),a('[data-toggle="popover"]').popover(),a('.popover-dismiss').popover({trigger:'focus'})});function b(a){return a.offset().top+a.outerHeight()}a(function(){var c=a(".js-td-cover"),e,f,d;if(!c.length)return;e=b(c),f=a('.js-navbar-scroll').offset().top,d=Math.ceil(a('.js-navbar-scroll').outerHeight()),e-f',a.href='#'+b.id,b.insertAdjacentElement('beforeend',a),b.addEventListener('mouseenter',function(){a.style.visibility='initial'}),b.addEventListener('mouseleave',function(){a.style.visibility='hidden'})}})})}(jQuery),function(a){'use strict';a(document).ready(function(){const b=a('.td-search-input');b.data('html',!0),b.data('placement','bottom'),b.data('template',''),b.on('change',c=>{e(a(c.target)),b.blur()}),b.closest('form').on('submit',()=>!1);let c=null;const d=new Map;a.ajax(b.data('offline-search-index-json-src')).then(a=>{c=lunr(function(){this.ref('ref'),this.field('title',{boost:5}),this.field('categories',{boost:3}),this.field('tags',{boost:3}),this.field('description',{boost:2}),this.field('body'),a.forEach(a=>{this.add(a),d.set(a.ref,{title:a.title,excerpt:a.excerpt})})}),b.trigger('change')});const e=e=>{if(e.popover('dispose'),c===null)return;const f=e.val();if(f==='')return;const i=c.query(a=>{const b=lunr.tokenizer(f.toLowerCase());b.forEach(c=>{const b=c.toString();a.term(b,{boost:100}),a.term(b,{wildcard:lunr.Query.wildcard.LEADING|lunr.Query.wildcard.TRAILING,boost:10}),a.term(b,{editDistance:2})})}).slice(0,e.data('offline-search-max-results')),g=a('
');g.append(a('
').css({display:'flex',justifyContent:'space-between',marginBottom:'1em'}).append(a('').text('Search results').css({fontWeight:'bold'})).append(a('').addClass('fas fa-times search-result-close-button').css({cursor:'pointer'})));const h=a('
').css({maxHeight:`calc(100vh - ${e.offset().top-a(window).scrollTop()+180}px)`,overflowY:'auto'});g.append(h),i.length===0?h.append(a('

').text(`No results found for query "${f}"`)):i.forEach(e=>{const f=d.get(e.ref),g=b.data('offline-search-base-href')+e.ref.replace(/^\//,''),c=a('

').addClass('mt-4');c.append(a('').addClass('d-block text-muted').text(e.ref)),c.append(a('').addClass('d-block').css({fontSize:'1.2rem'}).attr('href',g).text(f.title)),c.append(a('

').text(f.excerpt)),h.append(c)}),e.on('shown.bs.popover',()=>{a('.search-result-close-button').on('click',()=>{e.val(''),e.trigger('change')})});const j=a.fn.tooltip.Constructor.Default.whiteList;j['*'].push('style'),e.data('content',g[0].outerHTML).popover({whiteList:j}).popover('show')}})}(jQuery),function(){var c=function(){a=document.createElement('div'),a.classList.add('drawioframe'),b=document.createElement('iframe'),a.appendChild(b),document.body.appendChild(a)},d=function(){a&&(document.body.removeChild(a),a=void 0,b=void 0)},e=function(a,g){var h="https://embed.diagrams.net/",e,f;h+='?embed=1&ui=atlas&spin=1&modified=unsavedChanges&proto=json&saveAndEdit=1&noSaveBtn=1',e=document.createElement('div'),e.classList.add('drawio'),a.parentNode.insertBefore(e,a),e.appendChild(a),f=document.createElement('button'),f.classList.add('drawiobtn'),f.insertAdjacentHTML('beforeend',''),e.appendChild(f),f.addEventListener('click',function(f){if(b)return;c();var e=function(f){var h=b.contentWindow,c,i;if(f.data.length>0&&f.source==h){if(c=JSON.parse(f.data),c.event=='init')h.postMessage(JSON.stringify({action:'load',xml:g}),'*');else if(c.event=='save')i=g.indexOf('data:image/png')==0?'xmlpng':'xmlsvg',h.postMessage(JSON.stringify({action:'export',format:i}),'*');else if(c.event=='export'){const d=a.src.replace(/^.*?([^/]+)$/,'$1'),b=document.createElement('a');b.setAttribute('href',c.data),b.setAttribute('download',d),document.body.appendChild(b),b.click(),b.parentNode.removeChild(b)}(c.event=='exit'||c.event=='export')&&(window.removeEventListener('message',e),d())}};window.addEventListener('message',e),b.setAttribute('src',h)})},b,a;document.addEventListener('DOMContentLoaded',function(){for(const d of document.getElementsByTagName('img')){const c=d,b=c.getAttribute('src');if(!b.endsWith('.svg')&&!b.endsWith('.png'))continue;const a=new XMLHttpRequest;a.responseType='blob',a.open("GET",b),a.addEventListener("load",function(){const b=new FileReader;b.addEventListener('load',function(){if(b.result.indexOf('mxfile')!=-1){const b=new FileReader;b.addEventListener('load',function(){const a=b.result;e(c,a)}),b.readAsDataURL(a.response)}}),b.readAsBinaryString(a.response)}),a.send()}})}()