You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

9 lines
4.5 KiB

(function(_ds){var window=this;'use strict';var fL=function(){var a=_ds.R.call(this)||this;a.o=new _ds.Qj;a.C=new _ds.Qj;a.j=new Set;a.h=null;"IntersectionObserver"in window&&(a.h=new IntersectionObserver(function(b){b=_ds.n(b);for(var c=b.next();!c.done;c=b.next())c=c.value,c.isIntersecting&&(c=c.target,_ds.tu(new _ds.ru,c),a.j.delete(c),a.h.unobserve(c))},{rootMargin:"100%"}));return a},gL=function(a){Array.from(a.getElementsByTagName("table")).forEach(function(b){if(!b.parentNode.classList.contains("devsite-table-wrapper")){var c=
document.createElement("div");c.classList.add("devsite-table-wrapper");b.classList.contains("full-width")&&(c.classList.add("devsite-full-width-table"),b.classList.remove("full-width"));_ds.Yg(c,b);c.appendChild(b)}})},oL=function(a,b){var c,d,e,g,k,l,m;return _ds.E(function(p){if(1==p.h)return _ds.u(p,DevsiteApp.whenReady(),2);c=_ds.zi();d=DevsiteApp.getInsecureHost();e=b.Z;if(e.origin!==c.origin&&d&&e.origin!==d)return p.return();try{g=_ds.If(_ds.Kk,e.data)}catch(q){return p.return()}k=_ds.rf(g,
1,0);if(4===k)return hL(a,e),p.return();l=g.getName();if(!l)return p.return();if(m=a.querySelector('devsite-iframe iframe[name="'+l+'"]'))switch(k){case 5:iL(g,m);break;case 8:jL(e,g,c);break;case 1:kL(e,g,c);break;case 6:case 7:lL(k,c,g);break;case 9:mL(a,g);break;case 10:nL(g,c)}_ds.v(p)})},iL=function(a,b){var c,d,e,g;_ds.E(function(k){c=_ds.Pg(document).y;d=_ds.sf(a,4);e=_ds.sf(a,3);g=_ds.ih(b);d&&g.setAttribute("width",d+"px");e&&g.setAttribute("height",e+"px");window.requestAnimationFrame(function(){window.scrollTo(_ds.Pg(document).x,
c)});_ds.v(k)})},hL=function(a,b){var c,d,e;_ds.E(function(g){if(c=pL(a,b.source)){d="goog_"+_ds.Vk++;c.setAttribute("name",d);var k=_ds.Lk(3);e=_ds.Cf(k,2,d);(k=b.source)&&k.postMessage(e.La(),"*")}_ds.v(g)})},jL=function(a,b,c){var d;_ds.E(function(e){var g=_ds.Mk(_ds.Lk(8),_ds.L(b,8));d=_ds.Cf(g,6,c.toString());(g=a.source)&&g.postMessage(d.La(),"*");_ds.v(e)})},kL=function(a,b,c){var d;_ds.E(function(e){var g=_ds.Mk(_ds.Lk(2),_ds.L(b,8));d=_ds.Cf(g,7,c.search+c.hash);(g=a.source)&&g.postMessage(d.La(),
"*");_ds.v(e)})},lL=function(a,b,c){var d,e,g;_ds.E(function(k){d=c.Ba();e=new URL(c.getUrl(),b.origin);g=window.location.origin+window.location.pathname+e.search+e.hash;6===a?window.history.pushState({},d,g):window.history.replaceState({},d,g);_ds.v(k)})},mL=function(a,b){var c,d,e,g;_ds.E(function(k){c=_ds.L(b,9);d=JSON.parse(_ds.L(b,10));"cloudtrackEvent"===c&&d?(e=d,g={eventData:e},a.dispatchEvent(new CustomEvent("devsite-analytics-observation-cloudtrack",{detail:g,bubbles:!0}))):"devsite-apix"===
c&&a.dispatchEvent(new CustomEvent("devsite-apix-observation",{detail:d,bubbles:!0}));_ds.v(k)})},nL=function(a,b){var c,d;_ds.E(function(e){if(c=a.getUrl())d=new URL(c,b.origin),c.startsWith("#")||b.origin===d.origin&&b.pathname===d.pathname&&b.search===d.search?DevsiteApp.scrollToAnchor(d.hash,!0):DevsiteApp.fetchPage(d.href);_ds.v(e)})},pL=function(a,b){var c;Array.from(a.querySelectorAll("devsite-iframe iframe")).forEach(function(d){_ds.mh(d)===b&&(c=d)});return c},sL=function(a){a.m=a.querySelector(".devsite-article-body");
a.m&&qL(a);a.h&&a.h.disconnect();a.j.clear();gL(a);var b=Array.from(a.querySelectorAll(".devsite-nav-title, td > code, th > code"));a.j.clear();a.j=new Set(b);if(_ds.zi().hash){b=new _ds.ru;for(var c=_ds.n(a.j),d=c.next();!d.done;d=c.next())_ds.tu(b,d.value)}else rL(a,a.j);a.dispatchEvent(new CustomEvent("devsite-content-updated",{bubbles:!0}))},qL=function(a){"full"===document.body.getAttribute("layout")&&(a=a.m.querySelectorAll('h1[tabindex="0"],h2[tabindex="0"],h3[tabindex="0"],h4[tabindex="0"],h5[tabindex="0"],h6[tabindex="0"]'))&&
Array.from(a).forEach(function(b){b.removeAttribute("tabindex")})},rL=function(a,b){a.h&&b.forEach(function(c){a.h.observe(c)})};_ds.t(fL,_ds.R);fL.prototype.connectedCallback=function(){var a=this;this.o.listen(window,"message",function(b){return oL(a,b)});sL(this)};fL.prototype.disconnectedCallback=function(){this.h&&this.h.disconnect();this.j.clear();_ds.Wj(this.o);_ds.Wj(this.C)};
fL.prototype.updateContent=function(a){var b=this;a&&([".devsite-article","devsite-content-footer","devsite-google-survey"].forEach(function(c){_ds.Hl(b,b.querySelector(c),a.querySelector(c))}),sL(this))};fL.prototype.updateContent=fL.prototype.updateContent;fL.prototype.disconnectedCallback=fL.prototype.disconnectedCallback;fL.prototype.connectedCallback=fL.prototype.connectedCallback;try{window.customElements.define("devsite-content",fL)}catch(a){console.warn("devsite.app.customElement.DevsiteContent",a)};})(_ds_www);