Files
amiibo-service/docs/js/tutorials-overview.d6f9deb1.js
javier 2b01ec14bf Overall improvements and data update (#22)
This PR contains the work done to update the live tests to the latest data plus lots of QoL improvements to the library, including:

* added test cases to test the ``AmiiboService` locally;
* conformed the models to the `Hashable` protocol;
* documented the use of caching with the `AmiiboService` service;
* updated the reference to the new AmiiboAPI url;
* updated the year on the copyrights and header files;
* updated the overall documentation of the source code and the package.

Reviewed-on: #22
Co-authored-by: Javier Cicchelli <javier@rock-n-code.com>
Co-committed-by: Javier Cicchelli <javier@rock-n-code.com>
2026-03-22 23:39:48 +00:00

10 lines
22 KiB
JavaScript
Raw Permalink Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/*!
* This source file is part of the Swift.org open source project
*
* Copyright (c) 2021 Apple Inc. and the Swift project authors
* Licensed under Apache License v2.0 with Runtime Library Exception
*
* See https://swift.org/LICENSE.txt for license information
* See https://swift.org/CONTRIBUTORS.txt for Swift project authors
*/
"use strict";(self["webpackChunkswift_docc_render"]=self["webpackChunkswift_docc_render"]||[]).push([[36],{734:function(t,e,n){n.d(e,{A:function(){return c}});var i=function(){var t=this,e=t._self._c;return e("router-link",{staticClass:"nav-title-content",attrs:{to:t.to}},[e("span",{staticClass:"title"},[t._t("default")],2),e("span",{staticClass:"subhead"},[t._v(" "),t._t("subhead")],2)])},s=[],o={name:"NavTitleContainer",props:{to:{type:[String,Object],required:!0}}},a=o,r=n(1656),l=(0,r.A)(a,i,s,!1,null,"854b4dd6",null),c=l.exports},1168:function(t,e,n){n.d(e,{A:function(){return u}});var i=function(){var t=this,e=t._self._c;return e("SVGIcon",{staticClass:"download-icon",attrs:{viewBox:"0 0 14 14",themeId:"download"}},[e("path",{attrs:{d:"M7 0.5c3.59 0 6.5 2.91 6.5 6.5s-2.91 6.5-6.5 6.5c-3.59 0-6.5-2.91-6.5-6.5s2.91-6.5 6.5-6.5zM7 1.5c-3.038 0-5.5 2.462-5.5 5.5s2.462 5.5 5.5 5.5c3.038 0 5.5-2.462 5.5-5.5s-2.462-5.5-5.5-5.5z"}}),e("path",{attrs:{d:"M7.51 2.964l-0.001 5.431 1.308-2.041 0.842 0.539-2.664 4.162-2.633-4.164 0.845-0.534 1.303 2.059 0.001-5.452z"}})])},s=[],o=n(6515),a={name:"DownloadIcon",components:{SVGIcon:o.A}},r=a,l=n(1656),c=(0,l.A)(r,i,s,!1,null,null,null),u=c.exports},2223:function(t,e,n){n.d(e,{A:function(){return u}});var i=function(){var t=this,e=t._self._c;return e("SVGIcon",{staticClass:"inline-close-icon",attrs:{viewBox:"0 0 14 14",themeId:"inline-close"}},[e("path",{attrs:{d:"M11.91 1l1.090 1.090-4.917 4.915 4.906 4.905-1.090 1.090-4.906-4.905-4.892 4.894-1.090-1.090 4.892-4.894-4.903-4.904 1.090-1.090 4.903 4.904z"}})])},s=[],o=n(6515),a={name:"InlineCloseIcon",components:{SVGIcon:o.A}},r=a,l=n(1656),c=(0,l.A)(r,i,s,!1,null,null,null),u=c.exports},3111:function(t,e,n){n.r(e),n.d(e,{default:function(){return Ue}});var i=function(){var t=this,e=t._self._c;return t.topicData?e("Overview",t._b({key:t.topicKey},"Overview",t.overviewProps,!1)):t._e()},s=[],o=n(8213),a=n(1836),r=n(7470),l=function(){var t=this,e=t._self._c;return e("div",{staticClass:"tutorials-overview"},[t.isTargetIDE?t._e():e("Nav",{staticClass:"theme-dark",attrs:{sections:t.otherSections}},[t._v(" "+t._s(t.title)+" ")]),e("main",{staticClass:"main",attrs:{id:"app-main",tabindex:"0"}},[e("div",{staticClass:"radial-gradient"},[t._t("above-hero"),t.heroSection?e("Hero",{attrs:{action:t.heroSection.action,content:t.heroSection.content,estimatedTime:t.metadata.estimatedTime,image:t.heroSection.image,title:t.heroSection.title}}):t._e()],2),t.otherSections.length>0?e("LearningPath",{attrs:{sections:t.otherSections}}):t._e()],1)],1)},c=[],u=(n(8111),n(1148),n(8237),n(8964)),m={state:{activeTutorialLink:null,activeVolume:null,references:{}},reset(){this.state.activeTutorialLink=null,this.state.activeVolume=null,this.state.references={}},setActiveSidebarLink(t){this.state.activeTutorialLink=t},setActiveVolume(t){this.state.activeVolume=t},setReferences(t){this.state.references=t}},d=function(){var t=this,e=t._self._c;return e("NavBase",{scopedSlots:t._u([{key:"menu-items",fn:function(){return[e("NavMenuItemBase",{staticClass:"in-page-navigation"},[e("TutorialsNavigation",{attrs:{sections:t.sections}})],1),t._t("menu-items")]},proxy:!0}],null,!0)},[e("NavTitleContainer",{attrs:{to:t.buildUrl(t.$route.path,t.$route.query)},scopedSlots:t._u([{key:"default",fn:function(){return[t._t("default")]},proxy:!0},{key:"subhead",fn:function(){return[t._v(t._s(t.$tc("tutorials.title",2)))]},proxy:!0}],null,!0)})],1)},p=[],h=n(9065),v=function(){var t=this,e=t._self._c;return e("nav",{staticClass:"tutorials-navigation"},[e("TutorialsNavigationList",t._l(t.sections,function(n,i){return e("li",{key:`${n.name}_${i}`,class:t.sectionClasses(n)},[t.isVolume(n)?e(t.componentForVolume(n),t._b({tag:"component",on:{"select-menu":t.onSelectMenu,"deselect-menu":t.onDeselectMenu}},"component",t.propsForVolume(n),!1),t._l(n.chapters,function(n){return e("li",{key:n.name},[e("TutorialsNavigationLink",[t._v(" "+t._s(n.name)+" ")])],1)}),0):t.isResources(n)?e("TutorialsNavigationLink",[t._v(" "+t._s(t.$t("sections.resources"))+" ")]):t._e()],1)}),0)],1)},f=[],_=(n(116),function(){var t=this,e=t._self._c;return e("router-link",{staticClass:"tutorials-navigation-link",class:{active:t.active},attrs:{to:t.fragment},nativeOn:{click:function(e){return t.handleFocusAndScroll(t.fragment.hash)}}},[t._t("default")],2)}),g=[],C=n(6043),y=n(9514),A={name:"TutorialsNavigationLink",mixins:[y.A],inject:{store:{default:()=>({state:{}})}},data(){return{state:this.store.state}},computed:{active:({state:{activeTutorialLink:t},text:e})=>e===t,fragment:({text:t,$route:e})=>({hash:(0,C.ql)(t),query:e.query}),text:({$slots:{default:[{text:t}]}})=>t.trim()}},b=A,T=n(1656),S=(0,T.A)(b,_,g,!1,null,"e9f9b59c",null),k=S.exports,V=function(){var t=this,e=t._self._c;return e("ol",{staticClass:"tutorials-navigation-list"},[t._t("default")],2)},x=[],I={name:"TutorialsNavigationList"},N=I,w=(0,T.A)(N,V,x,!1,null,"4e0180fa",null),q=w.exports,L=function(){var t=this,e=t._self._c;return e("div",{staticClass:"tutorials-navigation-menu",class:{collapsed:t.collapsed}},[e("button",{staticClass:"toggle",attrs:{"aria-expanded":t.collapsed?"false":"true",type:"button"},on:{click:function(e){return e.stopPropagation(),t.onClick.apply(null,arguments)}}},[e("span",{staticClass:"text"},[t._v(t._s(t.title))]),e("InlineCloseIcon",{staticClass:"toggle-icon icon-inline"})],1),e("transition-expand",[t.collapsed?t._e():e("div",{staticClass:"tutorials-navigation-menu-content"},[e("TutorialsNavigationList",{attrs:{"aria-label":t.$t("tutorials.nav.chapters")}},[t._t("default")],2)],1)])],1)},$=[],D=n(2223),M=n(6088),F={name:"TutorialsNavigationMenu",components:{InlineCloseIcon:D.A,TransitionExpand:M.A,TutorialsNavigationList:q},props:{collapsed:{type:Boolean,default:!0},title:{type:String,required:!0}},methods:{onClick(){this.collapsed?this.$emit("select-menu",this.title):this.$emit("deselect-menu")}}},R=F,O=(0,T.A)(R,L,$,!1,null,"489416f8",null),j=O.exports;const B={resources:"resources",volume:"volume"};var G={name:"TutorialsNavigation",components:{TutorialsNavigationLink:k,TutorialsNavigationList:q,TutorialsNavigationMenu:j},constants:{SectionKind:B},inject:{store:{default:()=>({setActiveVolume(){}})}},data(){return{state:this.store.state}},props:{sections:{type:Array,required:!0}},computed:{activeVolume:({state:t})=>t.activeVolume},methods:{sectionClasses(t){return{volume:this.isVolume(t),"volume--named":this.isNamedVolume(t),resource:this.isResources(t)}},componentForVolume:({name:t})=>t?j:q,isResources:({kind:t})=>t===B.resources,isVolume:({kind:t})=>t===B.volume,activateFirstNamedVolume(){const{isNamedVolume:t,sections:e}=this,n=e.find(t);n&&this.store.setActiveVolume(n.name)},isNamedVolume(t){return this.isVolume(t)&&t.name},onDeselectMenu(){this.store.setActiveVolume(null)},onSelectMenu(t){this.store.setActiveVolume(t)},propsForVolume({name:t}){const{activeVolume:e}=this;return t?{collapsed:t!==e,title:t}:{"aria-label":"Chapters"}}},created(){this.activateFirstNamedVolume()}},z=G,P=(0,T.A)(z,v,f,!1,null,"79093ed6",null),H=P.exports,E=n(734),K=n(1074),U=n(5273);const Z={resources:"resources",volume:"volume"};var J={name:"Nav",constants:{SectionKind:Z},components:{NavMenuItemBase:U.A,NavTitleContainer:E.A,TutorialsNavigation:H,NavBase:h.A},props:{sections:{type:Array,require:!0}},methods:{buildUrl:K.c$}},Q=J,W=(0,T.A)(Q,d,p,!1,null,"54bcce6d",null),X=W.exports,Y=n(1897),tt=function(){var t=this,e=t._self._c;return e("section",{staticClass:"hero"},[e("div",{staticClass:"copy-container"},[e("h1",{staticClass:"title"},[t._v(t._s(t.title))]),t.content?e("ContentNode",{attrs:{content:t.content}}):t._e(),t.estimatedTime?e("p",{staticClass:"meta"},[e("TimerIcon"),e("span",{staticClass:"meta-content"},[e("strong",{staticClass:"time"},[t._v(t._s(t.estimatedTime))]),e("span",[t._v(" "+t._s(t.$t("tutorials.estimated-time")))])])],1):t._e(),t.action?e("CallToActionButton",{attrs:{action:t.action,"aria-label":t.$t("tutorials.overriding-title",{newTitle:t.action.overridingTitle,title:t.title}),isDark:""}}):t._e()],1),t.image?e("Asset",{attrs:{identifier:t.image}}):t._e()],1)},et=[],nt=n(8486),it=n(1290),st=n(3213),ot=function(){var t=this,e=t._self._c;return e("SVGIcon",{staticClass:"timer-icon",attrs:{viewBox:"0 0 14 14",themeId:"timer"}},[e("path",{attrs:{d:"M7 0.5c3.59 0 6.5 2.91 6.5 6.5s-2.91 6.5-6.5 6.5c-3.59 0-6.5-2.91-6.5-6.5v0c0-3.59 2.91-6.5 6.5-6.5v0zM7 2c-2.761 0-5 2.239-5 5s2.239 5 5 5c2.761 0 5-2.239 5-5v0c0-2.761-2.239-5-5-5v0z"}}),e("path",{attrs:{d:"M6.51 3.51h1.5v3.5h-1.5v-3.5z"}}),e("path",{attrs:{d:"M6.51 7.010h4v1.5h-4v-1.5z"}})])},at=[],rt=n(6515),lt={name:"TimerIcon",components:{SVGIcon:rt.A}},ct=lt,ut=(0,T.A)(ct,ot,at,!1,null,null,null),mt=ut.exports,dt={name:"Hero",components:{Asset:nt.A,CallToActionButton:it.A,ContentNode:st["default"],TimerIcon:mt},props:{action:{type:Object,required:!1},content:{type:Array,required:!1},estimatedTime:{type:String,required:!1},image:{type:String,required:!1},title:{type:String,required:!0}}},pt=dt,ht=(0,T.A)(pt,tt,et,!1,null,"400ffab5",null),vt=ht.exports,ft=function(){var t=this,e=t._self._c;return e("div",{staticClass:"learning-path",class:t.classes},[e("div",{staticClass:"main-container"},[t.isTargetIDE?t._e():e("div",{staticClass:"secondary-content-container"},[e("TutorialsNavigation",{attrs:{sections:t.sections,"aria-label":t.$t("sections.on-this-page")}})],1),e("div",{staticClass:"primary-content-container"},[e("div",{staticClass:"content-sections-container"},[t._l(t.volumes,function(n,i){return e("Volume",t._b({key:`volume_${i}`,staticClass:"content-section"},"Volume",t.propsFor(n),!1))}),t._l(t.otherSections,function(n,i){return e(t.componentFor(n),t._b({key:`resource_${i}`,tag:"component",staticClass:"content-section"},"component",t.propsFor(n),!1))})],2)])])])},_t=[],gt=function(){var t=this,e=t._self._c;return e("section",{staticClass:"resources",attrs:{id:"resources",tabindex:"-1"}},[e("VolumeName",{attrs:{name:t.$t("sections.resources"),content:t.content}}),e("TileGroup",{attrs:{tiles:t.tiles}})],1)},Ct=[],yt=n(8284);const At={topOneThird:"-30% 0% -70% 0%",center:"-50% 0% -50% 0%"};var bt={mixins:[yt.A],computed:{intersectionRoot(){return null},intersectionRootMargin(){return At.center}},methods:{onIntersect(t){if(!t.isIntersecting)return;const e=this.onIntersectViewport;e?e():console.warn("onIntersectViewportCenter not implemented")}}},Tt=function(){var t=this,e=t._self._c;return e("div",{staticClass:"volume-name"},[t.image?e("Asset",{staticClass:"image",attrs:{identifier:t.image,"aria-hidden":"true"}}):t._e(),e("h2",{staticClass:"name"},[t._v(" "+t._s(t.name)+" ")]),t.content?e("ContentNode",{attrs:{content:t.content}}):t._e()],1)},St=[],kt={name:"VolumeName",components:{ContentNode:st["default"],Asset:nt.A},props:{image:{type:String,required:!1},content:{type:Array,required:!1},name:{type:String,required:!1}}},Vt=kt,xt=(0,T.A)(Vt,Tt,St,!1,null,"569db166",null),It=xt.exports,Nt=function(){var t=this,e=t._self._c;return e("div",{staticClass:"tile-group",class:t.countClass},t._l(t.tiles,function(n){return e("Tile",t._b({key:n.title},"Tile",t.propsFor(n),!1))}),1)},wt=[],qt=function(){var t=this,e=t._self._c;return e("div",{staticClass:"tile"},[t.identifier?e("div",{staticClass:"icon"},[e(t.iconComponent,{tag:"component"})],1):t._e(),e("div",{staticClass:"title"},[t._v(t._s(t.title))]),e("ContentNode",{attrs:{content:t.content}}),t.action?e("DestinationDataProvider",{attrs:{destination:t.action},scopedSlots:t._u([{key:"default",fn:function({url:n,title:i}){return[e("Reference",{staticClass:"link",attrs:{url:n}},[t._v(" "+t._s(i)+" "),e("InlineChevronRightIcon",{staticClass:"link-icon icon-inline"})],1)]}}],null,!1,2081312588)}):t._e()],1)},Lt=[],$t=n(5060),Dt=function(){var t=this,e=t._self._c;return e("SVGIcon",{staticClass:"document-icon",attrs:{viewBox:"0 0 14 14",themeId:"document"}},[e("path",{attrs:{d:"M11.2,5.3,8,2l-.1-.1H2.8V12.1h8.5V6.3l-.1-1ZM8,3.2l2,2.1H8Zm2.4,8H3.6V2.8H7V6.3h3.4Z"}})])},Mt=[],Ft={name:"DocumentIcon",components:{SVGIcon:rt.A}},Rt=Ft,Ot=(0,T.A)(Rt,Dt,Mt,!1,null,"3a80772b",null),jt=Ot.exports,Bt=n(1168),Gt=function(){var t=this,e=t._self._c;return e("SVGIcon",{staticClass:"forum-icon",attrs:{viewBox:"0 0 14 14",themeId:"forum"}},[e("path",{attrs:{d:"M13 1v9h-7l-1.5 3-1.5-3h-2v-9zM12 2h-10v7h1.616l0.884 1.763 0.88-1.763h6.62z"}}),e("path",{attrs:{d:"M3 4h8.001v1h-8.001v-1z"}}),e("path",{attrs:{d:"M3 6h8.001v1h-8.001v-1z"}})])},zt=[],Pt={name:"ForumIcon",components:{SVGIcon:rt.A}},Ht=Pt,Et=(0,T.A)(Ht,Gt,zt,!1,null,null,null),Kt=Et.exports,Ut=n(4769),Zt=n(1754),Jt=n(6e3),Qt=n(5411);const Wt={documentation:"documentation",downloads:"downloads",featured:"featured",forums:"forums",sampleCode:"sampleCode",videos:"videos"};var Xt={name:"Tile",constants:{Identifier:Wt},components:{DestinationDataProvider:Qt.A,InlineChevronRightIcon:Jt.A,ContentNode:st["default"],CurlyBracketsIcon:$t.A,DocumentIcon:jt,DownloadIcon:Bt.A,ForumIcon:Kt,PlayIcon:Ut.A,Reference:Zt.A},props:{action:{type:Object,required:!1},content:{type:Array,required:!0},identifier:{type:String,required:!1},title:{type:String,require:!0}},computed:{iconComponent:({identifier:t})=>({[Wt.documentation]:jt,[Wt.downloads]:Bt.A,[Wt.forums]:Kt,[Wt.sampleCode]:$t.A,[Wt.videos]:Ut.A}[t])}},Yt=Xt,te=(0,T.A)(Yt,qt,Lt,!1,null,"74dbeb68",null),ee=te.exports,ne={name:"TileGroup",components:{Tile:ee},props:{tiles:{type:Array,required:!0}},computed:{countClass:({tiles:t})=>`count-${t.length}`},methods:{propsFor:({action:t,content:e,identifier:n,title:i})=>({action:t,content:e,identifier:n,title:i})}},ie=ne,se=(0,T.A)(ie,Nt,wt,!1,null,"4cacce0a",null),oe=se.exports,ae={name:"Resources",mixins:[bt],inject:{store:{default:()=>({setActiveSidebarLink(){},setActiveVolume(){}})}},components:{VolumeName:It,TileGroup:oe},computed:{intersectionRootMargin:()=>At.topOneThird},props:{content:{type:Array,required:!1},tiles:{type:Array,required:!0}},methods:{onIntersectViewport(){this.store.setActiveSidebarLink("Resources"),this.store.setActiveVolume(null)}}},re=ae,le=(0,T.A)(re,gt,Ct,!1,null,"7f8022c1",null),ce=le.exports,ue=function(){var t=this,e=t._self._c;return e("section",{staticClass:"volume"},[t.name?e("VolumeName",t._b({},"VolumeName",{name:t.name,image:t.image,content:t.content},!1)):t._e(),t._l(t.chapters,function(n,i){return e("Chapter",{key:n.name,staticClass:"tile",attrs:{content:n.content,image:n.image,name:n.name,number:i+1,topics:t.lookupTopics(n.tutorials),volumeHasName:!!t.name}})})],2)},me=[],de=function(){var t=this,e=t._self._c;return e("section",{staticClass:"chapter",attrs:{id:t.anchor,tabindex:"-1"}},[e("div",{staticClass:"info"},[e("Asset",{attrs:{identifier:t.image,"aria-hidden":"true"}}),e("div",{staticClass:"intro"},[e(t.volumeHasName?"h3":"h2",{tag:"component",staticClass:"name",attrs:{"aria-label":`${t.name} - ${t.$tc("tutorials.sections.chapter",{number:t.number})}`}},[e("span",{staticClass:"eyebrow",attrs:{"aria-hidden":"true"}},[t._v(" "+t._s(t.$t("tutorials.sections.chapter",{number:t.number}))+" ")]),e("span",{staticClass:"name-text",attrs:{"aria-hidden":"true"}},[t._v(t._s(t.name))])]),t.content?e("ContentNode",{attrs:{content:t.content}}):t._e()],1)],1),e("TopicList",{attrs:{topics:t.topics}})],1)},pe=[],he=function(){var t=this,e=t._self._c;return e("ol",{staticClass:"topic-list"},t._l(t.topics,function(n){return e("li",{key:n.url,staticClass:"topic",class:[t.kindClassFor(n),{"no-time-estimate":!n.estimatedTime}]},[e("div",{staticClass:"topic-icon"},[e(t.iconComponent(n),{tag:"component"})],1),e("router-link",{staticClass:"container",attrs:{to:t.buildUrl(n.url,t.$route.query),"aria-label":t.ariaLabelFor(n)}},[e("div",{staticClass:"link"},[t._v(t._s(n.title))]),n.estimatedTime?e("div",{staticClass:"time"},[e("TimerIcon"),e("span",{staticClass:"time-label"},[t._v(t._s(n.estimatedTime))])],1):t._e()])],1)}),0)},ve=[],fe=(n(4114),n(1789)),_e=n(3818);const ge={article:"article",tutorial:"project"},Ce={article:"article",tutorial:"tutorial"},ye={[ge.article]:"Article",[ge.tutorial]:"Tutorial"};var Ae={name:"ChapterTopicList",components:{TimerIcon:mt},constants:{TopicKind:ge,TopicKindClass:Ce,TopicKindIconLabel:ye},props:{topics:{type:Array,required:!0}},methods:{buildUrl:K.c$,iconComponent:({kind:t})=>({[ge.article]:fe.A,[ge.tutorial]:_e.A}[t]),kindClassFor:({kind:t})=>({[ge.article]:Ce.article,[ge.tutorial]:Ce.tutorial}[t]),formatTime(t){return t.replace("min",` ${this.$t("tutorials.time.minutes.full")}`).replace("hrs",` ${this.$t("tutorials.time.hours.full")}`)},ariaLabelFor(t){const{title:e,estimatedTime:n,kind:i}=t,s=[e,ye[i]];return n&&s.push(`${this.formatTime(n)} ${this.$t("tutorials.estimated-time")}`),s.join(" - ")}}},be=Ae,Te=(0,T.A)(be,he,ve,!1,null,"0589dc3b",null),Se=Te.exports,ke={name:"Chapter",mixins:[bt],inject:{store:{default:()=>({setActiveSidebarLink(){},setActiveVolume(){}})}},components:{Asset:nt.A,ContentNode:st["default"],TopicList:Se},props:{content:{type:Array,required:!1},image:{type:String,required:!0},name:{type:String,required:!0},number:{type:Number,required:!0},topics:{type:Array,required:!0},volumeHasName:{type:Boolean,default:!1}},computed:{anchor:({name:t})=>(0,C.ql)(t),intersectionRootMargin:()=>At.topOneThird},methods:{onIntersectViewport(){this.store.setActiveSidebarLink(this.name),this.volumeHasName||this.store.setActiveVolume(null)}}},Ve=ke,xe=(0,T.A)(Ve,de,pe,!1,null,"7468bc5e",null),Ie=xe.exports,Ne={name:"Volume",mixins:[bt],components:{VolumeName:It,Chapter:Ie},computed:{references:({store:t})=>t.state.references,intersectionRootMargin:()=>At.topOneThird},inject:{store:{default:()=>({setActiveVolume(){},state:{references:{}}})}},props:{chapters:{type:Array,required:!0},content:{type:Array,required:!1},image:{type:String,required:!1},name:{type:String,required:!1}},methods:{lookupTopics(t){return t.reduce((t,e)=>t.concat(this.references[e]||[]),[])},onIntersectViewport(){this.name&&this.store.setActiveVolume(this.name)}}},we=Ne,qe=(0,T.A)(we,ue,me,!1,null,"540dbf10",null),Le=qe.exports;const $e={resources:"resources",volume:"volume"};var De={name:"LearningPath",components:{Resources:ce,TutorialsNavigation:H,Volume:Le},constants:{SectionKind:$e},inject:{isTargetIDE:{default:!1}},props:{sections:{type:Array,required:!0,validator:t=>t.every(t=>Object.prototype.hasOwnProperty.call($e,t.kind))}},computed:{classes:({isTargetIDE:t})=>({ide:t}),partitionedSections:({sections:t})=>t.reduce(([t,e],n)=>n.kind===$e.volume?[t.concat(n),e]:[t,e.concat(n)],[[],[]]),volumes:({partitionedSections:t})=>t[0],otherSections:({partitionedSections:t})=>t[1]},methods:{componentFor:({kind:t})=>({[$e.resources]:ce,[$e.volume]:Le}[t]),propsFor:({chapters:t,content:e,image:n,kind:i,name:s,tiles:o})=>({[$e.resources]:{content:e,tiles:o},[$e.volume]:{chapters:t,content:e,image:n,name:s}}[i])}},Me=De,Fe=(0,T.A)(Me,ft,_t,!1,null,"69a72bbc",null),Re=Fe.exports;const Oe={hero:"hero",resources:"resources",volume:"volume"};var je={name:"TutorialsOverview",components:{Hero:vt,LearningPath:Re,Nav:X},mixins:[Y.A],constants:{SectionKind:Oe},inject:{isTargetIDE:{default:!1}},props:{metadata:{type:Object,default:()=>({})},references:{type:Object,default:()=>({})},sections:{type:Array,default:()=>[],validator:t=>t.every(t=>Object.prototype.hasOwnProperty.call(Oe,t.kind))}},computed:{pageTitle:({title:t})=>[t,"Tutorials"].filter(Boolean).join(" "),pageDescription:({heroSection:t,extractFirstParagraphText:e})=>t?e(t.content):null,partitionedSections:({sections:t})=>t.reduce(([t,e],n)=>n.kind===Oe.hero?[t.concat(n),e]:[t,e.concat(n)],[[],[]]),heroSections:({partitionedSections:t})=>t[0],otherSections:({partitionedSections:t})=>t[1],heroSection:({heroSections:t})=>t[0],store:()=>m,title:({metadata:{category:t=""}})=>t},provide(){return{store:this.store}},created(){u.A.setAvailableLocales(this.metadata.availableLanguages??this.metadata.availableLocales),this.store.reset(),this.store.setReferences(this.references)},watch:{references(t){this.store.setReferences(t)},"metadata.availableLocales":function(t){u.A.setAvailableLocales(this.metadata?.availableLanguages??t)},"metadata.availableLanguages":function(t){u.A.setAvailableLocales(t)}}},Be=je,Ge=(0,T.A)(Be,l,c,!1,null,"5a621b2e",null),ze=Ge.exports,Pe=n(4602),He={name:"TutorialsOverview",components:{Overview:ze},mixins:[r.A,Pe.A],data(){return{topicData:null}},computed:{overviewProps:({topicData:{metadata:t,references:e,sections:n}})=>({metadata:t,references:e,sections:n}),topicKey:({$route:t,topicData:e})=>[t.path,e.identifier.interfaceLanguage].join()},beforeRouteEnter(t,e,n){t.meta.skipFetchingData?n(t=>t.newContentMounted()):(0,a.Dk)(t,e,n).then(e=>n(n=>{(0,o.cu)(t.params.locale,n),n.topicData=e})).catch(n)},beforeRouteUpdate(t,e,n){(0,a.JR)(t,e)?(0,a.Dk)(t,e,n).then(e=>{this.topicData=e,(0,o.cu)(t.params.locale,this),n()}).catch(n):n()},mounted(){this.$bridge.on("contentUpdate",this.handleContentUpdateFromBridge)},beforeDestroy(){this.$bridge.off("contentUpdate",this.handleContentUpdateFromBridge)},watch:{topicData(){this.$nextTick(()=>{this.newContentMounted()})}}},Ee=He,Ke=(0,T.A)(Ee,i,s,!1,null,null,null),Ue=Ke.exports},6088:function(t,e,n){n.d(e,{A:function(){return c}});var i,s,o={name:"TransitionExpand",functional:!0,render(t,e){const n={props:{name:"expand"},on:{afterEnter(t){t.style.height="auto"},enter(t){const{width:e}=getComputedStyle(t);t.style.width=e,t.style.position="absolute",t.style.visibility="hidden",t.style.height="auto";const{height:n}=getComputedStyle(t);t.style.width=null,t.style.position=null,t.style.visibility=null,t.style.height=0,getComputedStyle(t).height,requestAnimationFrame(()=>{t.style.height=n})},leave(t){const{height:e}=getComputedStyle(t);t.style.height=e,getComputedStyle(t).height,requestAnimationFrame(()=>{t.style.height=0})}}};return t("transition",n,e.children)}},a=o,r=n(1656),l=(0,r.A)(a,i,s,!1,null,null,null),c=l.exports}}]);