-
Notifications
You must be signed in to change notification settings - Fork 0
/
component---src-templates-post-template-js-4cf76e6bfa5ca851a812.js
2 lines (2 loc) · 13.2 KB
/
component---src-templates-post-template-js-4cf76e6bfa5ca851a812.js
1
2
(window.webpackJsonp=window.webpackJsonp||[]).push([[13],{"00gE":function(e,t,a){e.exports={meta:"Meta-module--meta--2dV6L",meta__emoji:"Meta-module--meta__emoji--cAG9a",meta__date:"Meta-module--meta__date--Hp5XM",meta__category:"Meta-module--meta__category--136ch","meta__category-link":"Meta-module--meta__category-link--1Cn8b",meta__tags:"Meta-module--meta__tags--9RjqZ","meta__tags-item":"Meta-module--meta__tags-item--1bitk","meta__tags-item-link":"Meta-module--meta__tags-item-link--1BpYT"}},"628t":function(e,t,a){e.exports={tags:"RelatedPosts-module--tags--3My0U","tags__list-item":"RelatedPosts-module--tags__list-item--nndoT","tags__list-item-link":"RelatedPosts-module--tags__list-item-link--2UCav"}},J4bc:function(e,t,a){"use strict";a.r(t),a.d(t,"query",(function(){return Q}));var n=a("q1tI"),o=a.n(n),r=a("Zttt"),i=a("/d1K"),l=a("Wbzz"),s=a("YwZP"),c=a("7Qib"),u=a("d+ly"),m=a.n(u),_=a("gGy4"),d=a("c1Oi"),g=a("Ys8a"),p=function(e){var t=e.language,a=Object(_.d)().author;return o.a.createElement(s.Location,null,(function(e){var n=e.location;return o.a.createElement("div",{className:m.a.author},o.a.createElement("div",{className:m.a.author__title},o.a.createElement("strong",null,a.name[t]),["github"].map((function(e){return a.contacts[e]?o.a.createElement("span",{className:m.a["author__title__contacts-item"],key:e},o.a.createElement("a",{className:m.a["author__title__contacts-item-link"],href:Object(c.a)(e,a.contacts[e][t]),rel:"noopener noreferrer",target:"_blank"},o.a.createElement(g.a,{icon:Object(c.b)(e)}))):null}))),o.a.createElement("div",{className:m.a.author__bio},a.bio[Object(d.a)(n.pathname)]))}))},f=a("RPjP"),v=a.n(f),h=function(e){var t=e.postTitle,a=e.postSlug,n=Object(_.d)(),r=n.url,i=n.disqusShortname;return i?o.a.createElement(v.a,{shortname:i,identifier:t,title:t,url:r+a}):null},y=a("wd/R"),b=a.n(y),k=a("i6OX"),E=a("00gE"),N=a.n(E),M=function(e){var t=e.language,a=e.fields,n=e.frontmatter,r=a.tagSlugs,i=a.categorySlug,s=n.tags,u=n.date,m=n.category;return o.a.createElement("div",null,o.a.createElement("div",{className:N.a.meta},o.a.createElement("div",{className:N.a.meta__date},b()(u).format("en"===t?"MMMM D, YYYY":"YYYY/MM/DD")),o.a.createElement("div",{className:N.a.meta__category},o.a.createElement("span",{className:N.a.meta__emoji}," ",o.a.createElement(k.a,{icon:Object(c.b)("category")})),o.a.createElement(l.Link,{to:i+("en"===t?"":"/ko"),className:N.a["meta__category-link"]},m)),s?o.a.createElement("div",{className:N.a.meta__tags},o.a.createElement("span",{className:N.a.meta__emoji}," ",o.a.createElement(k.a,{icon:Object(c.b)("tag")})),r&&r.map((function(e,a){return o.a.createElement("span",{className:N.a["meta__tags-item"],key:s[a]},o.a.createElement(l.Link,{to:e+("ko"===t?"/ko":""),className:N.a["meta__tags-item-link"]},s[a]))}))):null))},w=a("Mvws"),O=a.n(w),P=function(e){var t=e.body,a=e.title,n=e.language,r=e.fields,i=e.frontmatter;return o.a.createElement("div",{className:O.a.content},o.a.createElement("h1",{className:O.a.content__title},a),o.a.createElement(M,{language:n,fields:r,frontmatter:i}),o.a.createElement("div",{className:O.a.content__body,dangerouslySetInnerHTML:{__html:t}}))},j=a("myfg"),Y=a.n(j),x=function(e){var t=e.date,a=e.language;return o.a.createElement("div",{className:Y.a.meta},o.a.createElement("p",{className:Y.a.meta__date},("en"===a?"Published: ":"발행일: ")+" ",b()(t).format("en"===a?"MMMM D, YYYY":"YYYY년 M월 D일")))},S=a("WXWR"),D=a.n(S),T=function(e){var t=e.tags,a=e.tagSlugs,n=e.language;return o.a.createElement("div",{className:D.a.tags},"en"===n?t.length>1?"Tags: ":"Tag: ":"태그: ",o.a.createElement(o.a.Fragment,null,a&&a.map((function(e,a){return o.a.createElement("span",{className:D.a["tags__list-item"],key:t[a]},o.a.createElement(l.Link,{to:"en"===n?e:e+"/ko",className:D.a["tags__list-item-link"]},t[a]))}))))},C=a("cGOO"),R=a.n(C),q=function(e){var t=e.language,a=e.prev,n=e.next;return o.a.createElement("div",{className:R.a.pagination},function(e){return e&&e.slug?o.a.createElement("div",{className:R.a.pagination__prev},o.a.createElement(l.Link,{className:R.a.pagination__prev__link,to:e.slug},o.a.createElement("div",{className:R.a["pagination__prev__link-date"]},b()(e.date).format("en"===t?"MMMM D, YYYY":"YYYY-MM-DD")),o.a.createElement("div",{className:R.a["pagination__prev__link-title"]},o.a.createElement("span",null,"←")," ",e.title))):null}(a),function(e){return e&&e.slug?o.a.createElement("div",{className:R.a.pagination__next},o.a.createElement(l.Link,{className:R.a.pagination__next__link,to:e.slug},o.a.createElement("div",{className:R.a["pagination__next__link-date"]},b()(e.date).format("en"===t?"MMMM D, YYYY":"YYYY-MM-DD")),o.a.createElement("div",{className:R.a["pagination__next__link-title"]},e.title," ",o.a.createElement("span",null,"→")))):null}(n))},L=a("628t"),A=a.n(L),I=function(e){var t=e.language,a=e.posts;return o.a.createElement("div",{className:A.a["related-posts"]},o.a.createElement("h3",null,"en"===t?"Related "+(1===a.length?"post":"posts"):"관련 포스트"),o.a.createElement("ul",null,a.map((function(e){return o.a.createElement("li",{key:e},o.a.createElement(l.Link,{to:e},Object(_.a)(e)))}))))},W=a("gt/k"),U=a.n(W),B=function(e){var t=e.post,a=e.language,n=e.prev,r=e.next,i=e.backLink,s=e.stateForSearchPage,c=t.html,u=t.fields,m=u.categorySlug,_=u.tagSlugs,d=u.slug,g=t.frontmatter,f=g.category,v=g.tags,y=g.title,b=g.date;return o.a.createElement("div",{className:U.a.post},o.a.createElement("div",{className:U.a.post__inner},o.a.createElement("div",{className:U.a.post__content},o.a.createElement(P,{body:c,title:y,language:a,fields:t.fields,frontmatter:t.frontmatter})),o.a.createElement("div",{className:U.a.post__footer},o.a.createElement(x,{date:b,language:a}),o.a.createElement("div",{className:U.a["post__footer-category"]},"en"===a?"Category: ":"카테고리: ",o.a.createElement(l.Link,{to:m+("en"===a?"":"/ko")},f)),v&&_&&o.a.createElement(T,{tags:v,tagSlugs:_,language:a}),t.frontmatter.related?o.a.createElement(I,{language:a,posts:t.frontmatter.related}):null,o.a.createElement(l.Link,{className:U.a["post__home-button"],to:i||("en"===a?"/":"/ko"),state:i?s:null},"en"===a?"← Back":"← 뒤로"),o.a.createElement(q,{language:a,prev:n,next:r}),o.a.createElement(p,{language:a})),o.a.createElement("div",{className:U.a.post__comments},o.a.createElement(h,{postSlug:d,postTitle:t.frontmatter.title}))))};function G(e,t){var a;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(a=function(e,t){if(!e)return;if("string"==typeof e)return K(e,t);var a=Object.prototype.toString.call(e).slice(8,-1);"Object"===a&&e.constructor&&(a=e.constructor.name);if("Map"===a||"Set"===a)return Array.from(e);if("Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a))return K(e,t)}(e))||t&&e&&"number"==typeof e.length){a&&(e=a);var n=0;return function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(a=e[Symbol.iterator]()).next.bind(a)}function K(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,n=new Array(t);a<t;a++)n[a]=e[a];return n}var Q="578916560";t.default=function(e){var t=e.data,a=e.pageContext,n=e.location,l=a.language,s=a.prev,c=a.next,u="en"===l?Object(_.d)().title:Object(_.d)().titleKo,m="en"===l?Object(_.d)().subtitle:Object(_.d)().subtitleKo,d=t.markdownRemark.frontmatter,g=d.title,p=d.description,f=null!==p?p:m,v={exist:function(e,t){if(!e)return!1;for(var a,n=G(t);!(a=n()).done;){if(a.value.path===e)return!0}return!1}(t.markdownRemark.frontmatter.link,Object(_.g)()),path:t.markdownRemark.frontmatter.link};return o.a.createElement(r.a,{title:g+" - "+u,description:f},o.a.createElement(i.a,{link:v}),o.a.createElement(B,{post:t.markdownRemark,language:a.language,prev:s,next:c,backLink:n.state?n.state.from:null,stateForSearchPage:n.state&&("/search"===n.state.from||"/search/ko"===n.state.from)?{year:n.state.year,month:n.state.month,selectedCategory:n.state.selectedCategory,selectedTags:n.state.selectedTags}:null}))}},Mvws:function(e,t,a){e.exports={content:"Content-module--content--3p512",content__title:"Content-module--content__title--2BDW9",content__body:"Content-module--content__body--2TrQ-"}},RPjP:function(e,t,a){"use strict";e.exports=a("SLms")},SLms:function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var a=arguments[t];for(var n in a)Object.prototype.hasOwnProperty.call(a,n)&&(e[n]=a[n])}return e},o=function(){function e(e,t){for(var a=0;a<t.length;a++){var n=t[a];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,a,n){return a&&e(t.prototype,a),n&&e(t,n),t}}(),r=l(a("q1tI")),i=l(a("17x9"));function l(e){return e&&e.__esModule?e:{default:e}}function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var u=["shortname","identifier","title","url","category_id","onNewComment","language"],m=!1;function _(e,t){var a=t.onNewComment,n=t.language,o=function(e,t){var a={};for(var n in e)t.indexOf(n)>=0||Object.prototype.hasOwnProperty.call(e,n)&&(a[n]=e[n]);return a}(t,["onNewComment","language"]);for(var r in o)e.page[r]=o[r];e.language=n,a&&(e.callbacks={onNewComment:[a]})}var d=function(e){function t(){return s(this,t),c(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),o(t,[{key:"componentDidMount",value:function(){this.loadDisqus()}},{key:"componentDidUpdate",value:function(){this.loadDisqus()}},{key:"shouldComponentUpdate",value:function(e,t){return e.identifier!==this.props.identifier}},{key:"render",value:function(){var e=this,t=Object.keys(this.props).reduce((function(t,a){return u.some((function(e){return e===a}))?t:n({},t,function(e,t,a){return t in e?Object.defineProperty(e,t,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[t]=a,e}({},a,e.props[a]))}),{});return r.default.createElement("div",t,r.default.createElement("div",{id:"disqus_thread"}))}},{key:"addDisqusScript",value:function(){if(!m){var e=this.disqus=document.createElement("script"),t=document.getElementsByTagName("head")[0]||document.getElementsByTagName("body")[0];e.async=!0,e.type="text/javascript",e.src="//"+this.props.shortname+".disqus.com/embed.js",t.appendChild(e),m=!0}}},{key:"loadDisqus",value:function(){var e=this,t={};u.forEach((function(a){"shortname"!==a&&e.props[a]&&(t[a]=e.props[a])})),"undefined"!=typeof DISQUS?DISQUS.reset({reload:!0,config:function(){_(this,t),this.page.url=this.page.url.replace(/#/,"")+"#!newthread"}}):(window.disqus_config=function(){_(this,t)},this.addDisqusScript())}}]),t}(r.default.Component);d.displayName="DisqusThread",d.propTypes={id:i.default.string,shortname:i.default.string.isRequired,identifier:i.default.string,title:i.default.string,url:i.default.string,category_id:i.default.string,onNewComment:i.default.func,language:i.default.string},d.defaultProps={url:"undefined"==typeof window?null:window.location.href},t.default=d},WXWR:function(e,t,a){e.exports={tags:"Tags-module--tags--1L_ct","tags__list-item":"Tags-module--tags__list-item--1M30P","tags__list-item-link":"Tags-module--tags__list-item-link--3SL_8"}},cGOO:function(e,t,a){e.exports={pagination:"Pagination-module--pagination--2p25G",pagination__prev:"Pagination-module--pagination__prev--2u54y",pagination__next:"Pagination-module--pagination__next--3WnBi","pagination__next__link-title":"Pagination-module--pagination__next__link-title--1mciV","pagination__prev__link-title":"Pagination-module--pagination__prev__link-title--36DcZ",pagination__next__link:"Pagination-module--pagination__next__link--3KB9f",pagination__prev__link:"Pagination-module--pagination__prev__link--23yXn","pagination__next__link-date":"Pagination-module--pagination__next__link-date--124rR","pagination__prev__link-date":"Pagination-module--pagination__prev__link-date--2EyJT"}},"d+ly":function(e,t,a){e.exports={author:"Author-module--author--2Yefr",author__title:"Author-module--author__title--1xndt","author__title__contacts-item":"Author-module--author__title__contacts-item--33cP0","author__title__contacts-item-link":"Author-module--author__title__contacts-item-link--22rmG",author__bio:"Author-module--author__bio--1Rnp-","author__bio-portfolio":"Author-module--author__bio-portfolio--2vTbp"}},"gt/k":function(e,t,a){e.exports={post:"Post-module--post--2ySQi",post__inner:"Post-module--post__inner--3n3q_",post__footer:"Post-module--post__footer--3WzWU","post__footer-category":"Post-module--post__footer-category--28_k5",post__comments:"Post-module--post__comments--25y6I","post__home-button":"Post-module--post__home-button--16Kl0",post__container:"Post-module--post__container--Sa8Vw"}},myfg:function(e,t,a){e.exports={meta__date:"Meta-module--meta__date--29eD7"}}}]);
//# sourceMappingURL=component---src-templates-post-template-js-4cf76e6bfa5ca851a812.js.map