{"version":3,"sources":["webpack:///./src/components/Scroll.js","webpack:///./node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js","webpack:///./src/components/Footer.js","webpack:///./src/assets/images/appstore.svg","webpack:///./src/components/Header.js","webpack:///./src/components/Social.js","webpack:///./src/pages/index.js","webpack:///./src/assets/images/app-store-badge.svg","webpack:///./node_modules/smoothscroll-polyfill/dist/smoothscroll.js","webpack:///./src/assets/images/demo-screen-1.jpg","webpack:///./config.js","webpack:///./src/assets/images/google-play-badge.svg","webpack:///./src/assets/images/demo-screen-2.png","webpack:///./src/assets/images/google-play-badge.png"],"names":["Element","props","children","Scroll","handleClick","bind","self","ReferenceError","componentDidMount","smoothscroll","polyfill","e","preventDefault","this","onClick","elem","scroll","type","element","offset","timeout","document","getElementsByClassName","getElementById","scrollTo","console","log","offSet","elemPos","getBoundingClientRect","top","window","pageYOffset","setTimeout","left","behavior","render","React","cloneElement","Component","kenmofm","className","href","target","rel","kenmoportal","kenmo","Footer","to","module","exports","Header","toggleMenu","value","setState","openMenu","handleScroll","visibilityClass","state","addEventListener","componentWillUnmount","removeEventListener","id","config","siteTitle","_","aria-controls","aria-expanded","aria-label","Social","socialLinks","map","social","icon","url","key","IndexPage","Layout","src","demo2","alt","gplaypng","astorejp","demo1","w","d","documentElement","style","__forceSmoothScrollPolyfill__","userAgent","HTMLElement","original","scrollBy","elementScroll","prototype","scrollElement","scrollIntoView","now","performance","Date","ROUNDING_TOLERANCE","navigator","RegExp","join","test","undefined","arguments","shouldBailOut","smoothScroll","call","body","scrollX","pageXOffset","scrollY","scrollLeft","scrollTop","SyntaxError","scrollableParent","findScrollableParent","parentRects","clientRects","getComputedStyle","position","x","y","firstArg","TypeError","hasScrollableSpace","el","axis","clientHeight","scrollHeight","clientWidth","scrollWidth","canOverflow","overflowValue","isScrollable","isScrollableY","isScrollableX","parentNode","host","step","context","currentX","currentY","k","elapsed","startTime","Math","cos","PI","startX","startY","method","scrollable","requestAnimationFrame","manifestName","manifestShortName","manifestSt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C,EAAUA,EAAU,EAAI,EAAIA,EAE5B7F,EAtGO,IAAO,EAAI+F,KAAKC,IAAID,KAAKE,GAAKL,IAuGrCF,EAAWD,EAAQS,QAAUT,EAAQnB,EAAImB,EAAQS,QAAUlG,EAC3D2F,EAAWF,EAAQU,QAAUV,EAAQlB,EAAIkB,EAAQU,QAAUnG,EAC3DyF,EAAQW,OAAO5C,KAAKiC,EAAQY,WAAYX,EAAUC,GAE9CD,IAAaD,EAAQnB,GAAKqB,IAAaF,EAAQlB,GACjDxC,EAAEuE,sBAAsBd,EAAKxI,KAAK+E,EAAG0D,IAazC,SAASlC,EAAaoB,EAAIL,EAAGC,GAC3B,IAAI8B,EACAH,EACAC,EACAC,EACAN,EAAYlD,IAEZ+B,IAAO3C,EAAEyB,MACX4C,EAAatE,EACbmE,EAASnE,EAAE2B,SAAW3B,EAAE4B,YACxBwC,EAASpE,EAAE6B,SAAW7B,EAAEpD,YACxByH,EAAS9D,EAAS3E,SAElB0I,EAAa1B,EACbuB,EAASvB,EAAGd,WACZsC,EAASxB,EAAGb,UACZsC,EAAS1D,GAIX8C,EAAK,CACHa,WAAYA,EACZD,OAAQA,EACRN,UAAWA,EACXI,OAAQA,EACRC,OAAQA,EACR7B,EAAGA,EACHC,EAAGA,OApNX,I,qBCDA3E,EAAOC,QAAU,IAA0B,6D,mBCA3CD,EAAOC,QAAU,CACfc,UAAW,eACX4F,aAAc,eACdC,kBAAmB,eACnBC,iBAAkB,IAClBC,wBAAyB,UACzBC,mBAAoB,UACpBC,gBAAiB,aACjBC,aAAc,kCACdC,WAAW,0BAEX7F,YAAa,CACX,CACEG,KAAM,YACN2F,KAAM,SACN1F,IAAK,mCAEP,CACED,KAAM,aACN2F,KAAM,UACN1F,IAAK,uC,mBCpBXzB,EAAOC,QAAU,8uS,qBCAjBD,EAAOC,QAAU,IAA0B,6D,qBCA3CD,EAAOC,QAAU,IAA0B","file":"component---src-pages-index-js-b7d4de06ced56195359e.js","sourcesContent":["import smoothscroll from 'smoothscroll-polyfill';\nimport React from 'react';\nimport PropTypes from 'prop-types';\n\nconst Element = props => {\n return props.children;\n};\n\nclass Scroll extends React.Component {\n static propTypes = {\n type: PropTypes.string,\n element: PropTypes.string,\n offset: PropTypes.number,\n timeout: PropTypes.number,\n children: PropTypes.node.isRequired,\n onClick: PropTypes.func,\n };\n constructor() {\n super();\n this.handleClick = this.handleClick.bind(this);\n }\n componentDidMount() {\n smoothscroll.polyfill();\n }\n handleClick(e) {\n e.preventDefault();\n const { onClick = () => {} } = this.props;\n let elem = 0;\n let scroll = true;\n const { type, element, offset, timeout } = this.props;\n if (type && element) {\n switch (type) {\n case 'class':\n elem = document.getElementsByClassName(element)[0];\n scroll = elem ? true : false;\n break;\n case 'id':\n elem = document.getElementById(element);\n scroll = elem ? true : false;\n break;\n default:\n }\n }\n scroll\n ? this.scrollTo(elem, offset, timeout)\n : console.log(`Element not found: ${element}`); // eslint-disable-line\n\n onClick(e);\n }\n scrollTo(element, offSet = 0, timeout = null) {\n const elemPos = element\n ? element.getBoundingClientRect().top + window.pageYOffset\n : 0;\n if (timeout) {\n setTimeout(() => {\n window.scroll({ top: elemPos + offSet, left: 0, behavior: 'smooth' });\n }, timeout);\n } else {\n window.scroll({ top: elemPos + offSet, left: 0, behavior: 'smooth' });\n }\n }\n render() {\n return (\n
\n kenmo readerを紹介します\n
\n\n 派手な装飾を排除して記事を表示\n
\n\n 様々なニュースやまとめサイトに対応しています\n
\n\n あなたの快適な情報収集を妨げる広告は表示されません\n
\n\n ニュースソースの追加リクエストはいつでも受け付けています\n
\n