-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcomponent---src-templates-docs-js-4f1b62d3e1f69d60d823.js
2 lines (2 loc) · 20 KB
/
component---src-templates-docs-js-4f1b62d3e1f69d60d823.js
1
2
(window.webpackJsonp=window.webpackJsonp||[]).push([[6],{196:function(e,t,n){"use strict";n.r(t),function(e){n.d(t,"pageQuery",function(){return u});var i=n(218),a=n(2),r=n.n(a),o=(n(0),n(204)),c=n(260),s=n(217),l=function(t){var n=t.data,a=t.location;return e.createElement(o.a,{location:a},e.createElement(i.a,{createLink:c.a,location:a,markdownRemark:n.markdownRemark,sectionList:s.a,titlePostfix:" – Packem"}))};l.propTypes={data:r.a.object.isRequired};var u="2154263559";t.default=l}.call(this,n(62))},205:function(e,t,n){"use strict";var i=n(232),a=n.n(i);t.a=function(e,t){var n=a()(e)+".html";return t?"/"+t+"/"+n:n}},206:function(e,t,n){"use strict";n(43);var i=n(207);t.a=function(e){return null==e?null:i.a+"/"+e.replace(/^\//,"")}},213:function(e,t,n){"use strict";(function(e){n(30),n(43);var i=n(9),a=n.n(i),r=n(0),o=n.n(r),c=n(42),s=n(231),l=n(214),u=n(215),d=function(t){function n(){for(var e,n=arguments.length,i=new Array(n),a=0;a<n;a++)i[a]=arguments[a];return(e=t.call.apply(t,[this].concat(i))||this).state={uid:(""+Math.random()).replace(/\D/g,"")},e}return a()(n,t),n.prototype.render=function(){var t,n,i,a=this.props,r=a.activeItemId,o=a.createLink,d=a.isActive,m=a.isScrollSync,f=a.location,h=a.onLinkClick,p=a.onSectionTitleClick,g=a.section,v="section_"+this.state.uid;return e.createElement("div",null,e.createElement("button",{"aria-expanded":d,"aria-controls":v,css:{cursor:"pointer",backgroundColor:"transparent",border:0,marginTop:10},onClick:p},e.createElement(l.a,{cssProps:(t={},t[c.c.greaterThan("small")]={color:d?c.a.text:c.a.subtle,":hover":{color:c.a.text}},t)},g.title,e.createElement(u.a,{cssProps:(n={marginLeft:7,transform:d?"rotateX(180deg)":"rotateX(0deg)",transition:"transform 0.2s ease"},n[c.c.lessThan("small")]={display:"none"},n)}))),e.createElement("ul",{id:v,css:(i={fontFeatureSettings:"'tnum'",marginBottom:10},i[c.c.greaterThan("small")]={display:d?"block":"none"},i)},g.items.map(function(t,n){return e.createElement("li",{key:t.id,css:{marginTop:5}},o({isActive:m?r===t.id:Object(s.a)(f,t),item:g.isOrdered?Object.assign({},t,{title:n+1+". "+t.title}):t,location:f,onLinkClick:h,section:g}),t.subitems&&e.createElement("ul",{css:{marginLeft:20}},t.subitems.map(function(t){return e.createElement("li",{key:t.id},o({isActive:m?r===t.id:Object(s.a)(f,t),item:t,location:f,onLinkClick:h,section:g}))})))})))},n}(o.a.Component);t.a=d}).call(this,n(62))},215:function(e,t,n){"use strict";(function(e){n(0);t.a=function(t){var n=t.size,i=void 0===n?10:n,a=t.cssProps,r=void 0===a?{}:a;return e.createElement("svg",{css:r,viewBox:"0 0 926.23699 573.74994",version:"1.1",x:"0px",y:"0px",width:i,height:i},e.createElement("g",{transform:"translate(904.92214,-879.1482)"},e.createElement("path",{d:"\n m -673.67664,1221.6502 -231.2455,-231.24803 55.6165,\n -55.627 c 30.5891,-30.59485 56.1806,-55.627 56.8701,-55.627 0.6894,\n 0 79.8637,78.60862 175.9427,174.68583 l 174.6892,174.6858 174.6892,\n -174.6858 c 96.079,-96.07721 175.253196,-174.68583 175.942696,\n -174.68583 0.6895,0 26.281,25.03215 56.8701,\n 55.627 l 55.6165,55.627 -231.245496,231.24803 c -127.185,127.1864\n -231.5279,231.248 -231.873,231.248 -0.3451,0 -104.688,\n -104.0616 -231.873,-231.248 z\n ",fill:"currentColor"})))}}).call(this,n(62))},218:function(e,t,n){"use strict";var i=n(219);t.a=i.a},219:function(e,t,n){"use strict";(function(e){n(220),n(221),n(90),n(43);var i=n(201),a=n(202),r=n(223),o=n(225),c=(n(0),n(227)),s=n(203),l=n(243),u=n(244),d=n(42),m=n(206),f=function(e,t){if(!t)return null;var n=e.map(function(e){return e.items}),i=[].concat.apply([],n),a=t.replace(".html","");return i.find(function(e){return e.id===a})};t.a=function(t){var n=t.authors,h=void 0===n?[]:n,p=t.createLink,g=t.date,v=t.enableScrollSync,b=t.ogDescription,E=t.location,y=t.markdownRemark,k=t.sectionList,w=t.titlePostfix,x=void 0===w?"":w,S=h.length>0,T=y.frontmatter.title||"",O=f(k,y.frontmatter.prev),L=f(k,y.frontmatter.next);return e.createElement(a.a,{direction:"column",grow:"1",shrink:"0",halign:"stretch",css:{width:"100%",flex:"1 0 auto",position:"relative",zIndex:0}},e.createElement(s.a,{ogDescription:b,ogUrl:Object(m.a)(y.fields.slug),title:""+T+x}),e.createElement("div",{css:{flex:"1 0 auto"}},e.createElement(i.a,null,e.createElement("div",{css:d.d.articleLayout.container},e.createElement(a.a,{type:"article",direction:"column",grow:"1",halign:"stretch"},e.createElement(r.a,{title:T}),(g||S)&&e.createElement("div",{css:{marginTop:15}},g," ",S&&e.createElement("span",null,"by"," ",Object(u.a)(h,function(t){return e.createElement("a",{css:d.d.link,href:t.frontmatter.url,key:t.frontmatter.name},t.frontmatter.name)}))),e.createElement("div",{css:d.d.articleLayout.content},e.createElement("div",{css:[d.d.markdown],dangerouslySetInnerHTML:{__html:y.html}}),y.fields.path&&e.createElement("div",{css:{marginTop:80}},e.createElement("a",{css:d.d.articleLayout.editLink,href:"https://github.com/packem/packem.github.io/tree/dev/"+y.fields.path},"Edit this page")))),e.createElement("div",{css:d.d.articleLayout.sidebar},e.createElement(c.a,{enableScrollSync:v,createLink:p,defaultActiveSection:Object(l.a)(E.pathname,k),location:E,sectionList:k}))))),(L||O)&&e.createElement(o.a,{location:E,next:L,prev:O}))}}).call(this,n(62))},220:function(e,t,n){var i=n(31).f,a=Function.prototype,r=/^\s*function ([^ (]*)/;"name"in a||n(21)&&i(a,"name",{configurable:!0,get:function(){try{return(""+this).match(r)[1]}catch(e){return""}}})},221:function(e,t,n){"use strict";n(211)("link",function(e){return function(t){return e(this,"a","href",t)}})},223:function(e,t,n){"use strict";var i=n(224);t.a=i.a},224:function(e,t,n){"use strict";(function(e){n(30);var i=n(202),a=(n(0),n(42));t.a=function(t){var n,r=t.title;return e.createElement(i.a,{type:"header",halign:"space-between",valign:"baseline"},e.createElement("h1",{css:Object.assign({color:a.a.dark,marginBottom:0,marginTop:40},a.b.header,(n={},n[a.c.size("medium")]={marginTop:60},n[a.c.greaterThan("large")]={marginTop:80},n))},r))}}).call(this,n(62))},225:function(e,t,n){"use strict";var i=n(226);t.a=i.a},226:function(e,t,n){"use strict";(function(e){n(212),n(30),n(43);var i=n(201),a=n(202),r=n(63),o=n(2),c=n.n(o),s=(n(0),n(42)),l=function(t){var n,r=t.next,o=t.prev,c=t.location;return e.createElement("div",{css:{background:s.a.dark,color:s.a.white,paddingTop:50,paddingBottom:50}},e.createElement(i.a,null,e.createElement(a.a,{type:"ul",halign:"space-between",css:(n={},n[s.c.between("small","medium")]={paddingRight:240},n[s.c.between("large","largerSidebar")]={paddingRight:280},n[s.c.between("largerSidebar","sidebarFixed",!0)]={paddingRight:380},n)},e.createElement(a.a,{basis:"50%",type:"li"},o&&e.createElement("div",null,e.createElement(d,null,"Previous article"),e.createElement("div",{css:{paddingTop:10}},e.createElement(u,{location:c,to:o.id+".html"},o.title)))),r&&e.createElement(a.a,{halign:"flex-end",basis:"50%",type:"li",css:{textAlign:"right"}},e.createElement("div",null,e.createElement(d,null,"Next article"),e.createElement("div",{css:{paddingTop:10}},e.createElement(u,{location:c,to:r.id+".html"},r.title)))))))};l.propTypes={next:c.a.shape({id:c.a.string.isRequired,title:c.a.string.isRequired}),prev:c.a.shape({id:c.a.string.isRequired,title:c.a.string.isRequired})},t.a=l;var u=function(t){var n,i=t.children,a=t.to,o=t.location,c=o&&o.pathname.replace(/\/[^\/]+\.html/,"/"+a)||a;return e.createElement(r.Link,{css:(n={display:"inline",borderColor:s.a.subtle,transition:"border-color 0.2s ease",fontSize:30,borderBottomWidth:1,borderBottomStyle:"solid"},n[s.c.lessThan("large")]={fontSize:24},n[s.c.size("xsmall")]={fontSize:16},n[":hover"]={borderColor:s.a.white},n),to:c},i)},d=function(t){var n=t.children;return e.createElement("div",{css:Object.assign({color:s.a.brand},s.b.small)},n)}}).call(this,n(62))},227:function(e,t,n){"use strict";var i=n(228);t.a=i.a},228:function(e,t,n){"use strict";(function(e){n(30);var i=n(9),a=n.n(i),r=n(201),o=n(0),c=n(229),s=n(42),l=n(215),u=function(t){function n(e){var n;return(n=t.call(this,e)||this)._openNavMenu=function(){n.setState({open:!n.state.open})},n._closeNavMenu=function(){n.setState({open:!1})},n.state={open:!1},n}return a()(n,t),n.prototype.render=function(){var t,n,i,a,o=this.state.open,u={top:0,left:0,bottom:0,right:0,position:"fixed",backgroundColor:s.a.white,zIndex:2,height:"100vh",overflowY:"auto",WebkitOverflowScrolling:"touch",pointerEvents:o?"auto":"none"},d=o?8:-4,m=o?1:0,f=o?0:40;return e.createElement("div",null,e.createElement("div",{style:{opacity:m,transition:"opacity 0.5s ease"},css:(t={},t[s.c.lessThan("small")]=u,t[s.c.greaterThan("medium")]={marginRight:-999,paddingRight:999,backgroundColor:"#f7f7f7"},t[s.c.between("medium","sidebarFixed",!0)]={position:"fixed",zIndex:2,height:"100%"},t[s.c.greaterThan("small")]={position:"fixed",zIndex:2,height:"calc(100vh - 60px)",overflowY:"auto",WebkitOverflowScrolling:"touch",marginRight:-999,paddingRight:999,backgroundColor:"#f7f7f7",opacity:"1 !important"},t[s.c.size("small")]={height:"calc(100vh - 40px)"},t[s.c.between("medium","large")]={height:"calc(100vh - 50px)"},t[s.c.greaterThan("sidebarFixed")]={borderLeft:"1px solid #ececec"},t)},e.createElement("div",{style:{transform:"translate(0px, "+f+"px)",transition:"transform 0.5s ease"},css:(n={marginTop:60},n[s.c.size("xsmall")]={marginTop:40},n[s.c.between("small","medium")]={marginTop:0},n[s.c.between("medium","large")]={marginTop:50},n[s.c.greaterThan("small")]={transform:"none !important"},n)},e.createElement(c.a,Object.assign({closeParentMenu:this._closeNavMenu},this.props)))),e.createElement("div",{css:(i={backgroundColor:s.a.darker,bottom:44,color:s.a.brand,display:"none",cursor:"pointer",position:"fixed",right:20,zIndex:3,borderRadius:"50%",border:"1px solid rgba(255, 255, 255, 0.1)",boxShadow:"0 0 20px rgba(0, 0, 0, 0.3)"},i[s.c.lessThan("small")]={display:"inline-block"},i),onClick:this._openNavMenu,role:"button",tabIndex:0},e.createElement(r.a,null,e.createElement("div",{css:(a={display:"flex",flexDirection:"row",alignItems:"center",height:60},a[s.c.between("medium","large")]={height:50},a[s.c.lessThan("small")]={height:60,overflow:"hidden",alignItems:"flex-start"},a)},e.createElement("div",{css:{width:20,height:20,alignSelf:"center",display:"flex",flexDirection:"column",color:s.a.brand}},e.createElement(l.a,{size:15,cssProps:{transform:"translate(2px, "+d+"px) rotate(180deg)",transition:"transform 0.2s ease"}}),e.createElement(l.a,{size:15,cssProps:{transform:"translate(2px, "+(0-d)+"px)",transition:"transform 0.2s ease"}}))))))},n}(o.Component);t.a=u}).call(this,n(62))},229:function(e,t,n){"use strict";var i=n(230);t.a=i.a},230:function(e,t,n){"use strict";(function(e){var i=n(9),a=n.n(i),r=n(0),o=n(202),c=n(213),s=n(233),l=n(42),u=function(t){function n(e,n){var i;return(i=t.call(this,e,n)||this).state={activeSection:e.defaultActiveSection},i}a()(n,t);var i=n.prototype;return i.render=function(){var t,n=this,i=this.props,a=i.closeParentMenu,r=i.createLink,u=i.enableScrollSync,d=i.location,m=i.sectionList,f=this.state.activeSection,h=u?s.a:c.a;return e.createElement(o.a,{type:"nav",direction:"column",halign:"stretch",css:(t={width:"100%",paddingLeft:20,position:"relative"},t[l.c.greaterThan("largerSidebar")]={paddingLeft:40},t[l.c.lessThan("small")]={paddingBottom:100},t)},m.map(function(t,i){return e.createElement(h,{createLink:r,isActive:f===t||1===m.length,key:i,location:d,onLinkClick:a,onSectionTitleClick:function(){return n._toggleSection(t)},section:t})}))},i._toggleSection=function(e){this.setState(function(t){return{activeSection:t.activeSection===e?null:e}})},n}(r.Component);t.a=u}).call(this,n(62))},231:function(e,t,n){"use strict";n(91),n(88),n(89);var i=n(205);t.a=function(e,t){if(e.hash){if(t.href)return e.hash===function(e){void 0===e&&(e="");var t=e.indexOf("#");return t>=0?e.substr(t):""}(t.href)}else if(t.id.includes("html"))return e.pathname.includes(t.id);return e.pathname.split("/").slice(-1)[0]===Object(i.a)(t.id)}},232:function(e,t,n){var i;i=function(){var e=JSON.parse('{"$":"dollar","%":"percent","&":"and","<":"less",">":"greater","|":"or","¢":"cent","£":"pound","¤":"currency","¥":"yen","©":"(c)","ª":"a","®":"(r)","º":"o","À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","Æ":"AE","Ç":"C","È":"E","É":"E","Ê":"E","Ë":"E","Ì":"I","Í":"I","Î":"I","Ï":"I","Ð":"D","Ñ":"N","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","Ù":"U","Ú":"U","Û":"U","Ü":"U","Ý":"Y","Þ":"TH","ß":"ss","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","æ":"ae","ç":"c","è":"e","é":"e","ê":"e","ë":"e","ì":"i","í":"i","î":"i","ï":"i","ð":"d","ñ":"n","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","ù":"u","ú":"u","û":"u","ü":"u","ý":"y","þ":"th","ÿ":"y","Ā":"A","ā":"a","Ă":"A","ă":"a","Ą":"A","ą":"a","Ć":"C","ć":"c","Č":"C","č":"c","Ď":"D","ď":"d","Đ":"DJ","đ":"dj","Ē":"E","ē":"e","Ė":"E","ė":"e","Ę":"e","ę":"e","Ě":"E","ě":"e","Ğ":"G","ğ":"g","Ģ":"G","ģ":"g","Ĩ":"I","ĩ":"i","Ī":"i","ī":"i","Į":"I","į":"i","İ":"I","ı":"i","Ķ":"k","ķ":"k","Ļ":"L","ļ":"l","Ľ":"L","ľ":"l","Ł":"L","ł":"l","Ń":"N","ń":"n","Ņ":"N","ņ":"n","Ň":"N","ň":"n","Ő":"O","ő":"o","Œ":"OE","œ":"oe","Ŕ":"R","ŕ":"r","Ř":"R","ř":"r","Ś":"S","ś":"s","Ş":"S","ş":"s","Š":"S","š":"s","Ţ":"T","ţ":"t","Ť":"T","ť":"t","Ũ":"U","ũ":"u","Ū":"u","ū":"u","Ů":"U","ů":"u","Ű":"U","ű":"u","Ų":"U","ų":"u","Ź":"Z","ź":"z","Ż":"Z","ż":"z","Ž":"Z","ž":"z","ƒ":"f","Ơ":"O","ơ":"o","Ư":"U","ư":"u","Lj":"LJ","lj":"lj","Nj":"NJ","nj":"nj","Ș":"S","ș":"s","Ț":"T","ț":"t","˚":"o","Ά":"A","Έ":"E","Ή":"H","Ί":"I","Ό":"O","Ύ":"Y","Ώ":"W","ΐ":"i","Α":"A","Β":"B","Γ":"G","Δ":"D","Ε":"E","Ζ":"Z","Η":"H","Θ":"8","Ι":"I","Κ":"K","Λ":"L","Μ":"M","Ν":"N","Ξ":"3","Ο":"O","Π":"P","Ρ":"R","Σ":"S","Τ":"T","Υ":"Y","Φ":"F","Χ":"X","Ψ":"PS","Ω":"W","Ϊ":"I","Ϋ":"Y","ά":"a","έ":"e","ή":"h","ί":"i","ΰ":"y","α":"a","β":"b","γ":"g","δ":"d","ε":"e","ζ":"z","η":"h","θ":"8","ι":"i","κ":"k","λ":"l","μ":"m","ν":"n","ξ":"3","ο":"o","π":"p","ρ":"r","ς":"s","σ":"s","τ":"t","υ":"y","φ":"f","χ":"x","ψ":"ps","ω":"w","ϊ":"i","ϋ":"y","ό":"o","ύ":"y","ώ":"w","Ё":"Yo","Ђ":"DJ","Є":"Ye","І":"I","Ї":"Yi","Ј":"J","Љ":"LJ","Њ":"NJ","Ћ":"C","Џ":"DZ","А":"A","Б":"B","В":"V","Г":"G","Д":"D","Е":"E","Ж":"Zh","З":"Z","И":"I","Й":"J","К":"K","Л":"L","М":"M","Н":"N","О":"O","П":"P","Р":"R","С":"S","Т":"T","У":"U","Ф":"F","Х":"H","Ц":"C","Ч":"Ch","Ш":"Sh","Щ":"Sh","Ъ":"U","Ы":"Y","Ь":"","Э":"E","Ю":"Yu","Я":"Ya","а":"a","б":"b","в":"v","г":"g","д":"d","е":"e","ж":"zh","з":"z","и":"i","й":"j","к":"k","л":"l","м":"m","н":"n","о":"o","п":"p","р":"r","с":"s","т":"t","у":"u","ф":"f","х":"h","ц":"c","ч":"ch","ш":"sh","щ":"sh","ъ":"u","ы":"y","ь":"","э":"e","ю":"yu","я":"ya","ё":"yo","ђ":"dj","є":"ye","і":"i","ї":"yi","ј":"j","љ":"lj","њ":"nj","ћ":"c","џ":"dz","Ґ":"G","ґ":"g","฿":"baht","ა":"a","ბ":"b","გ":"g","დ":"d","ე":"e","ვ":"v","ზ":"z","თ":"t","ი":"i","კ":"k","ლ":"l","მ":"m","ნ":"n","ო":"o","პ":"p","ჟ":"zh","რ":"r","ს":"s","ტ":"t","უ":"u","ფ":"f","ქ":"k","ღ":"gh","ყ":"q","შ":"sh","ჩ":"ch","ც":"ts","ძ":"dz","წ":"ts","ჭ":"ch","ხ":"kh","ჯ":"j","ჰ":"h","ẞ":"SS","Ạ":"A","ạ":"a","Ả":"A","ả":"a","Ấ":"A","ấ":"a","Ầ":"A","ầ":"a","Ẩ":"A","ẩ":"a","Ẫ":"A","ẫ":"a","Ậ":"A","ậ":"a","Ắ":"A","ắ":"a","Ằ":"A","ằ":"a","Ẳ":"A","ẳ":"a","Ẵ":"A","ẵ":"a","Ặ":"A","ặ":"a","Ẹ":"E","ẹ":"e","Ẻ":"E","ẻ":"e","Ẽ":"E","ẽ":"e","Ế":"E","ế":"e","Ề":"E","ề":"e","Ể":"E","ể":"e","Ễ":"E","ễ":"e","Ệ":"E","ệ":"e","Ỉ":"I","ỉ":"i","Ị":"I","ị":"i","Ọ":"O","ọ":"o","Ỏ":"O","ỏ":"o","Ố":"O","ố":"o","Ồ":"O","ồ":"o","Ổ":"O","ổ":"o","Ỗ":"O","ỗ":"o","Ộ":"O","ộ":"o","Ớ":"O","ớ":"o","Ờ":"O","ờ":"o","Ở":"O","ở":"o","Ỡ":"O","ỡ":"o","Ợ":"O","ợ":"o","Ụ":"U","ụ":"u","Ủ":"U","ủ":"u","Ứ":"U","ứ":"u","Ừ":"U","ừ":"u","Ử":"U","ử":"u","Ữ":"U","ữ":"u","Ự":"U","ự":"u","Ỳ":"Y","ỳ":"y","Ỵ":"Y","ỵ":"y","Ỷ":"Y","ỷ":"y","Ỹ":"Y","ỹ":"y","‘":"\'","’":"\'","“":"\\"","”":"\\"","†":"+","•":"*","…":"...","₠":"ecu","₢":"cruzeiro","₣":"french franc","₤":"lira","₥":"mill","₦":"naira","₧":"peseta","₨":"rupee","₩":"won","₪":"new shequel","₫":"dong","€":"euro","₭":"kip","₮":"tugrik","₯":"drachma","₰":"penny","₱":"peso","₲":"guarani","₳":"austral","₴":"hryvnia","₵":"cedi","₹":"indian rupee","₽":"russian ruble","₿":"bitcoin","℠":"sm","™":"tm","∂":"d","∆":"delta","∑":"sum","∞":"infinity","♥":"love","元":"yuan","円":"yen","﷼":"rial"}');function t(t,n){if("string"!=typeof t)throw new Error("slugify: string argument expected");n="string"==typeof n?{replacement:n}:n||{};var i=t.split("").reduce(function(t,i){return t+(e[i]||i).replace(n.remove||/[^\w\s$*_+~.()'"!\-:@]/g,"")},"").trim().replace(/[-\s]+/g,n.replacement||"-");return n.lower?i.toLowerCase():i}return t.extend=function(t){for(var n in t)e[n]=t[n]},t},e.exports=i(),e.exports.default=i()},233:function(e,t,n){"use strict";(function(e){n(30),n(90);var i=n(44),a=n.n(i),r=n(9),o=n.n(r),c=n(0),s=n(213),l=function(t){function n(e,n){var i;return(i=t.call(this,e,n)||this).state={activeItemId:"",itemTopOffsets:[]},i.calculateItemTopOffsets=i.calculateItemTopOffsets.bind(a()(i)),i.handleResize=i.handleResize.bind(a()(i)),i.handleScroll=i.handleScroll.bind(a()(i)),i}o()(n,t);var i=n.prototype;return i.componentDidMount=function(){this.calculateItemTopOffsets(),window.addEventListener("resize",this.handleResize),window.addEventListener("scroll",this.handleScroll)},i.componentWillUnmount=function(){window.removeEventListener("resize",this.handleResize),window.removeEventListener("scroll",this.handleScroll)},i.calculateItemTopOffsets=function(){var e=this.props.section,t=u(e.items);this.setState({itemTopOffsets:d(t)})},i.handleResize=function(){this.calculateItemTopOffsets(),this.handleScroll()},i.handleScroll=function(){var e=this.state.itemTopOffsets,t=e.find(function(t,n){var i=e[n+1];return i?window.scrollY>=t.offsetTop&&window.scrollY<i.offsetTop:window.scrollY>=t.offsetTop});this.setState({activeItemId:t?t.id:""})},i.render=function(){var t=this.state.activeItemId;return e.createElement(s.a,Object.assign({isScrollSync:!0,activeItemId:t},this.props))},n}(c.Component),u=function(e){return e.map(function(e){var t=[];return e.subitems&&(t=e.subitems.map(function(e){return e.id})),[e.id].concat(t)}).reduce(function(e,t){return e.concat(t)})},d=function(e){return e.map(function(e){var t=document.getElementById(e);return t?{id:e,offsetTop:t.offsetTop}:null}).filter(function(e){return e})};t.a=l}).call(this,n(62))},243:function(e,t,n){"use strict";n(91);var i=n(205);t.a=function(e,t){var n,a=e.split("/").slice(-1)[0];return t.forEach(function(e){e.items.some(function(e){return a===Object(i.a)(e.id)||e.subitems&&e.subitems.some(function(e){return a===Object(i.a)(e.id)})})&&(n=e)}),n}},244:function(e,t,n){"use strict";(function(e){n(0);var i=function(t,n){return t.push(e.createElement("span",{key:t.length+"-"+n},n))};t.a=function(e,t){if(e.length<=1)return e.map(t);var n=[];return e.forEach(function(a,r){r===e.length-1?(i(n,2===e.length?" and ":", and "),n.push(t(a,r))):r>0?(i(n,", "),n.push(t(a,r))):n.push(t(a,r))}),n}}).call(this,n(62))},260:function(e,t,n){"use strict";(function(e){n.d(t,"a",function(){return c});var i,a=n(63),r=(n(0),n(208),n(205)),o=n(42),c=function(t){var n=t.isActive,i=t.item,o=t.section;return e.createElement(a.Link,{css:[u,n&&s],to:Object(r.a)(i.id,o.directory)},n&&e.createElement("span",{css:l}),i.title)},s={fontWeight:700},l=((i={width:4,height:25,borderLeft:"4px solid "+o.a.brand,paddingLeft:16,position:"absolute",left:0,marginTop:-3})[o.c.greaterThan("largerSidebar")]={left:15},i),u={color:o.a.text,display:"inline-block",borderBottom:"1px solid transparent",transition:"border 0.2s ease",marginTop:5,"&:hover":{color:o.a.subtle}}}).call(this,n(62))}}]);
//# sourceMappingURL=component---src-templates-docs-js-4f1b62d3e1f69d60d823.js.map