-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcomponent---src-pages-stories-components-stories-jsx-1bda64f2dabee5fb6120.js.map
1 lines (1 loc) · 3.72 KB
/
component---src-pages-stories-components-stories-jsx-1bda64f2dabee5fb6120.js.map
1
{"version":3,"sources":["webpack:///./src/pages/stories/components/stories.jsx","webpack:///./src/pages/stories/components/quote.jsx"],"names":["Stories","props","state","currentQuote","renderImages","quoteIndexes","map","index","bottom","key","style","width","className","src","Quotes","imgSrc","alt","attribution","onClick","setState","render","this","quote","React","Component","Quote","id","quoteId","content","role","defaultProps","hasBtn"],"mappings":"6uFAKMA,E,oBACJ,WAAYC,GAAQ,IAAD,SACjB,cAAMA,IAAN,MACKC,MAAQ,CACXC,aAAc,GAHC,E,kHAOnBC,aAAA,SAAaC,GAAe,IAAD,OACzB,OAAOA,EAAaC,KAAI,SAAAC,GACtB,IAAIC,EAAS,EAIb,OAHc,IAAVD,IAAaC,EAAS,QACZ,IAAVD,IAAaC,EAAS,SAGxB,yBAAKC,IAAG,WAAaF,EAASG,MAAO,CAAEC,MAAO,MAAOH,OAAQA,IAC3D,yBACEI,WACG,EAAKV,MAAMC,eAAiBI,EACzB,2CACA,IAAM,yCAGZ,yBACEK,UAAU,uBACVC,IAAKC,EAAOP,GAAOQ,OACnBC,IAAKF,EAAOP,GAAOU,YACnBC,QAAS,WACP,EAAKC,SAAS,CAAEhB,aAAcI,a,EAS5Ca,OAAA,WACE,OACE,yBAAKR,UAAU,mBACb,yBAAKA,UAAU,wBACZS,KAAKjB,aAAa,CAAC,EAAG,EAAG,KAE5B,kBAAC,UAAD,CAAOkB,MAAOR,EAAOO,KAAKnB,MAAMC,gBAChC,yBAAKS,UAAU,2BACZS,KAAKjB,aAAa,CAAC,EAAG,EAAG,O,GA7CdmB,IAAMC,WAoDbxB,a,kCCzDf,gCAEMyB,EAAQ,SAAAxB,GAAK,OACjB,kBAAC,WAAD,KACKA,EAAMqB,MACP,yBAAKV,UAAU,SACb,yBAAKA,UAAU,YAAYc,GAAIzB,EAAM0B,SACnC,kCAAQ1B,EAAMqB,MAAMM,QAApB,MAEF,wBAAIhB,UAAU,8BACXX,EAAMqB,MAAML,YADf,IAC6B,IAC3B,0BAAML,UAAU,uBAAuBX,EAAMqB,MAAMO,QAGrD,OAIRJ,EAAMK,aAAe,CACnBR,MAAO,KACPS,QAAQ,GAGKN","file":"component---src-pages-stories-components-stories-jsx-1bda64f2dabee5fb6120.js","sourcesContent":["import React from 'react';\r\nimport Quote from 'pages/stories/components/quote';\r\n\r\nimport Quotes from 'data/quotes.json';\r\n\r\nclass Stories extends React.Component {\r\n constructor(props) {\r\n super(props);\r\n this.state = {\r\n currentQuote: 0\r\n };\r\n }\r\n\r\n renderImages(quoteIndexes) {\r\n return quoteIndexes.map(index => {\r\n let bottom = 0;\r\n if (index === 1) bottom = '75px';\r\n if (index === 4) bottom = '-75px';\r\n\r\n return (\r\n <div key={`stories-${index}`} style={{ width: '33%', bottom: bottom }}>\r\n <div\r\n className={\r\n (this.state.currentQuote === index\r\n ? 'stories-circles__img-container selected '\r\n : '') + 'stories-circles__img-container center'\r\n }\r\n >\r\n <img\r\n className=\"stories-circles__img\"\r\n src={Quotes[index].imgSrc}\r\n alt={Quotes[index].attribution}\r\n onClick={() => {\r\n this.setState({ currentQuote: index });\r\n }}\r\n />\r\n </div>\r\n </div>\r\n );\r\n });\r\n }\r\n\r\n render() {\r\n return (\r\n <div className=\"stories-circles\">\r\n <div className=\"stories-circles__top\">\r\n {this.renderImages([0, 1, 2])}\r\n </div>\r\n <Quote quote={Quotes[this.state.currentQuote]} />\r\n <div className=\"stories-circles__bottom\">\r\n {this.renderImages([3, 4, 5])}\r\n </div>\r\n </div>\r\n );\r\n }\r\n}\r\n\r\nexport default Stories;\r\n","import React, { Fragment } from 'react';\r\n\r\nconst Quote = props => (\r\n <Fragment>\r\n {!!props.quote ? (\r\n <div className=\"quote\">\r\n <div className=\"quote-box\" id={props.quoteId}>\r\n <span>\"{props.quote.content}\"</span>\r\n </div>\r\n <h6 className=\"quote__attribution noClick\">\r\n {props.quote.attribution},{' '}\r\n <span className=\"quote__role noClick\">{props.quote.role}</span>\r\n </h6>\r\n </div>\r\n ) : null}\r\n </Fragment>\r\n);\r\n\r\nQuote.defaultProps = {\r\n quote: null,\r\n hasBtn: false\r\n};\r\n\r\nexport default Quote;\r\n"],"sourceRoot":""}