{"version":3,"sources":["Subscribe/index.jsx","Subscribe/assets/mail.svg","Subscribe/assets/phone.svg","Header/assets/external-link.svg","WhiteBoxHeader/assets/maintenance.svg","WhiteBoxHeader/assets/ok-status-icon.svg","WhiteBoxHeader/assets/red-check.svg","Incidents/assets/red-check.svg","Incidents/assets/incident.svg","Incidents/assets/maintenance.svg","TopLevelStatus/assets/ok-status-icon.jsx","TopLevelStatus/assets/red-check.jsx","TopLevelStatus/assets/incident.jsx","TopLevelStatus/assets/maintenance.jsx","TopLevelStatus/index.jsx","WhiteBoxHeader/index.js","Uptime/index.js","WhiteBoxStats/index.js","TimelineSelector/index.js","Incidents/index.jsx","ProtectedPage/index.jsx","PoweredBy/index.jsx","App.js","IncidentsPage.js","IncidentPage.js","ConfirmSubscriptionPage.js","UnsubscribePage.js","registerServiceWorker.js","index.js","Header/index.js","Notification/index.jsx","utils/index.js"],"names":["baseUrl","getBaseUrl","Subscribe","props","handleClick","event","dropdownRef","buttonRef","contains","target","setState","isOpened","escFunction","keyCode","isSelected","type","state","selectedType","selectType","submit","isLoading","isEmailValid","phoneNumber","countryCode","length","parsePhoneNumberFromString","phone","toUpperCase","number","fetch","headers","method","body","JSON","stringify","email","statuspageId","hostname","then","response","json","notificationMessage","message","includes","showNotification","notificationType","toggle","test","isPhoneValid","onChangeEmail","value","toLowerCase","onChangePhone","closeNotification","isOriginalCoverColor","coverColor","window","location","document","addEventListener","this","removeEventListener","USAIndex","countries","findIndex","country","hasSubscriberPhoneFeature","className","ref","onClick","style","color","backgroundColor","src","mailSvg","phoneSvg","statuspageName","placeholder","name","onChange","autoFocus","classNamePrefix","options","defaultValue","option","styles","marginTop","Component","module","exports","_extends","Object","assign","i","arguments","source","key","prototype","hasOwnProperty","call","apply","_objectWithoutProperties","excluded","sourceKeys","keys","indexOf","_objectWithoutPropertiesLoose","getOwnPropertySymbols","sourceSymbolKeys","propertyIsEnumerable","_ref2","createElement","d","_ref3","points","_ref4","x1","y1","x2","y2","SvgExternalLink","_ref","svgRef","title","width","height","viewBox","fill","stroke","strokeWidth","strokeLinecap","strokeLinejoin","ForwardRef","forwardRef","SvgComponent","fillRule","getTopLevelContent","incidents","priorizedIncident","sort","a","b","key1","Date","date","key2","outage","find","incident","ongoingMaintenance","getMaintenanceStatus","endDate","upcomingMaintenance","getPriorizedIncident","filter","updates","maintenanceStatus","allOngoingIncidents","text","incidentId","mostRecentUpdate","Icon","DownIcon","IncidentIcon","MaintenanceIcon","UpIcon","uuid","postedAt","UTCTime","TopLevelStatus","pathname","indicator","topLevelStatus","topLevelContent","hasOngoingIncident","status","hasIncidents","TopLevelIcon","minWidth","dangerouslySetInnerHTML","__html","formatText","formatDateAndTime","isIncidentView","href","Link","to","statuspage","mostRecentIncident","getTimeAgo","getMostRecentIncidentDate","withRouter","WhiteBoxHeader","services","index","service","alias","domain","map","getIndex","id","getAlias","isUnderMaintenance","maintenanceImg","alt","isDown","up","down","getServices","getTimeLabel","months","getHumanDate","today","year","getFullYear","month","getMonth","day","getDate","Uptime","CustomTooltip","payload","hour","ts","valueFormat","valueName","labels","data","dataset","row","skeleton","uptime","elapsedTime","time","getHourAndMinute","margin","bottom","top","dataKey","tick","fontSize","tickFormatter","label","toFixed","offset","stopColor","stopOpacity","dot","fillOpacity","isAnimationActive","content","getLabelDate","compUptime","rows","pings","reduce","acc","compElapsedTime","WhiteBoxStats","todayOrYesterday","serviceId","s","moment","toDate","subtract","todayPings","ping","isSame","Number","nbRows","graphs","servicesWithGraphs","isResponseTimeSelected","isUptimeSelected","every","snapshots","forEach","meanUptime","meanElapsedTime","filledDays","slice","reverse","yesterday","push","addHourlyPingsToDailyRows","shift","hasUptime","hasResponseTime","responseTime","selectedTimeline","getGraphs","graph","getStats","TimelineSelector","items","selected","hasSnapshots","item","GetSpan","children","Incidents","getBackLink","isPreview","isIncidentPage","statusPageId","history","str","charAt","incidentImg","outageImg","isHomePage","isWithin24Hours","isUpcoming","Tag","getDateRange","getIcon","capitalize","getEstimatedDuration","update","React","ProtectedPage","onChangePassword","e","password","preventDefault","credentials","reload","wrongPassword","image","setFavicon","setTabName","favicon","querySelector","onSubmit","Notification","PoweredBy","getHostname","rel","App","handleTimelineSelector","parseInt","hasAtLeastOneMetric","search","environment","loading","timelineItems","protected","protectedPageData","split","fetchStatusPage","n","hasFavicon","serv","fetchSnapshots","catch","err","fetchPreview","Header","hasSnapshotsLoaded","features","fetchStatuspage","console","log","match","params","Incident","fetchIncident","ConfirmSubscription","confirmSusbcription","token","isConfirmed","redirect","renderRedirect","pathnameDestination","Redirect","Unsubscribe","isUnsubscribed","Boolean","routing","Switch","Route","exact","path","component","ReactDOM","render","getElementById","navigator","serviceWorker","ready","registration","unregister","EmptyState","hasSubscriberFeature","subscribers","subscribersPhone","process","REACT_APP_STAGE","homepage","setTimeout","rawDate","format","fromNow","join","latest","oldest","aresameMonth","latestDateRaw","oldestDateRaw","latestDate","oldestDate","areDatesOnSameMonth","latestDay","oldestDay","areDatesOnSameDay","formatDate","dateRaw","now","Math","abs","isAfter","getMinuteGrammar","minute","maintenance","hasMinutes","minutes","hasHours","hours","duration","startDate","startHumanDate","endHumanDate","timezone","guess","isBetween","isBefore","protocol"],"mappings":"0RAUMA,EAAUC,cAEVC,E,YACJ,WAAYC,GAAQ,IAAD,uBACjB,4CAAMA,KA4BRC,YAAc,SAACC,GACP,EAAKC,aACJ,EAAKC,YACN,EAAKD,YAAYE,SAASH,EAAMI,SAAW,EAAKF,UAAUC,SAASH,EAAMI,UAI/E,EAAKC,SAAS,CAAEC,UAAU,KApCT,EAuCnBC,YAAc,SAACP,GACS,KAAlBA,EAAMQ,SACR,EAAKH,SAAS,CAAEC,UAAU,KAzCX,EA6CnBG,WAAa,SAACC,GACZ,GAAIA,IAAS,EAAKC,MAAMC,aACtB,MAAO,YA/CQ,EAmDnBC,WAAa,SAACD,GACZ,EAAKP,SAAS,CAAEO,kBApDC,EAuDnBE,OAAS,WACP,IAAI,EAAKH,MAAMI,YAIiB,SAA5B,EAAKJ,MAAMC,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EAAYI,MACzBC,EAAQ,UAAMF,EAAYH,EAAYI,OAAuBJ,EAAYI,MAlBlE,EACF,SAEA,SAe8E,IACnFD,GAAYF,EACdI,GAAQ,eAAYL,EAAYE,QAAxB,YAAmCJ,EAAiBE,EAAYE,UAC/DD,IACTI,GAAQ,UAAOL,EAAYE,QAAnB,YAA8BJ,EAAiBE,EAAYE,WAGrE,IAAMI,EAAY,IAAI9R,KAAKwR,EAAYvR,MACjC8R,EAAiBxK,EAAOuK,GAAW5B,OAAO,iBAC1C1P,EAAU,IAAIR,KAAKwR,EAAYhR,SAC/BwR,EAAezK,EAAO/G,GAAS0P,OAAO,iBAEtC+B,EAjCkB1K,KAAUA,KAAU2K,SAAShC,OAAO,KAmC5D,OACE,4BACE,mDAA2B2B,GAAgB,2BACjD,wBAAMzW,UAAU,kBAAkB2W,EAAlC,IAAmDE,EAAnD,MAAgED,EAAhE,IAA+EC,KAKlE1R,EAAuB,SAACuR,EAAWtR,EAAS2C,GACvD,GAAc,IAAVA,EAAJ,CAIA,IAAMlD,EAAO,IAAID,KACjB,OAAIuH,EAAOtH,GAAMkS,UAAUL,EAAWtR,GAC7B,cACE+G,EAAOtH,GAAMmS,SAASN,GACxB,WACEvK,EAAOtH,GAAMoR,QAAQ7Q,GACvB,iBADF,I,EAKsB/F,OAAOC,SAA9BpB,E,EAAAA,SAAU+Y,E,EAAAA,SAcLnb,EAAa,kBAAQ2Y,GAAaA,+CAA+C,QAAhCA,8CAAYC,gBACtE,4BAD4B,UAT1BxW,EAASM,SAAS,kBAAiC,UAAbyY,EACjC,WAEHxC,GAAaA,+CAA+C,QAAhCA,8CAAYC,gBACrC,UAEF,WAGuB,uB","file":"static/js/main.7904ae7d.chunk.js","sourcesContent":["import React, { Component } from 'react';\nimport Notification from '../Notification';\nimport mailSvg from './assets/mail.svg';\nimport phoneSvg from './assets/phone.svg';\nimport Select from 'react-select';\nimport './styles.scss';\nimport countries from './countries.json';\nimport { parsePhoneNumberFromString } from 'libphonenumber-js';\nimport { getBaseUrl } from '../utils';\n\nconst baseUrl = getBaseUrl();\n\nclass Subscribe extends Component {\n constructor(props) {\n super(props);\n\n const { hostname } = window.location;\n\n this.state = {\n isOpened: false,\n countryCode: 'us',\n email: '',\n phone: '',\n showNotification: false,\n notificationType: '',\n notificationMessage: '',\n isLoading: false,\n hostname,\n selectedType: 'mail'\n };\n }\n\n componentWillMount() {\n document.addEventListener('mousedown', this.handleClick, false);\n document.addEventListener('keydown', this.escFunction, false);\n }\n\n componentWillUnmount() {\n document.removeEventListener('mousedown', this.handleClick, false);\n document.removeEventListener('keydown', this.escFunction, false);\n }\n\n handleClick = (event) => {\n if (!!this.dropdownRef\n && !!this.buttonRef\n && (this.dropdownRef.contains(event.target) || this.buttonRef.contains(event.target))) {\n return;\n }\n\n this.setState({ isOpened: false });\n }\n\n escFunction = (event) => {\n if (event.keyCode === 27) {\n this.setState({ isOpened: false });\n }\n }\n\n isSelected = (type) => {\n if (type === this.state.selectedType) {\n return 'selected';\n }\n }\n\n selectType = (selectedType) => {\n this.setState({ selectedType });\n }\n\n submit = () => {\n if (this.state.isLoading) {\n return;\n }\n\n if (this.state.selectedType === 'mail' && !this.isEmailValid()) {\n return;\n }\n\n let phoneNumber = '';\n if (this.state.selectedType === 'phone') {\n if (this.state.countryCode.length !== 2) {\n return;\n }\n\n const formattedPhoneNumber = parsePhoneNumberFromString(this.state.phone, this.state.countryCode.toUpperCase());\n phoneNumber = formattedPhoneNumber.number;\n }\n\n this.setState({ isLoading: true });\n fetch(`${baseUrl}/api/v1/statuspage/subscribers`, {\n headers: {\n 'Accept': 'application/json',\n 'Content-Type': 'application/json'\n },\n method: 'POST',\n body: JSON.stringify({\n email: this.state.email,\n phone: phoneNumber,\n type: this.state.selectedType,\n statuspageId: this.props.statuspageId,\n hostname: this.state.hostname\n })\n })\n .then((response) => response.json())\n .then((response) => {\n let notificationMessage = '';\n if (this.state.selectedType === 'mail') {\n notificationMessage = 'Your email is now subscribed to updates! An email has been sent to confirm the subscription';\n } else if (this.state.selectedType === 'phone') {\n notificationMessage = 'Your phone number is now subscribed to updates!';\n }\n\n if (response.message.includes('success')) {\n this.setState({\n showNotification: true,\n notificationMessage,\n notificationType: 'success',\n email: '',\n phone: '',\n countryCode: 'us',\n selectedType: 'mail',\n isOpened: false,\n isLoading: false\n });\n } else {\n this.setState({\n showNotification: true,\n notificationMessage: response.message,\n notificationType: 'danger',\n isLoading: false\n });\n }\n });\n }\n\n toggle = () => {\n this.setState({ isOpened: !this.state.isOpened });\n }\n\n isEmailValid = () => {\n const re = /^(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|\"(?:[\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x21\\x23-\\x5b\\x5d-\\x7f]|\\\\[\\x01-\\x09\\x0b\\x0c\\x0e-\\x7f])*\")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x21-\\x5a\\x53-\\x7f]|\\\\[\\x01-\\x09\\x0b\\x0c\\x0e-\\x7f])+)\\])$/\n return re.test(this.state.email);\n }\n\n isPhoneValid = () => {\n if (this.state.countryCode.length !== 2) {\n return false;\n }\n\n if (this.state.phone.length <= 6) {\n return false;\n }\n\n return true;\n }\n\n onChangeEmail = (event) => {\n this.setState({ email: event.target.value.toLowerCase() });\n }\n \n onChangePhone = (event) => {\n this.setState({ phone: event.target.value });\n }\n\n closeNotification = () => {\n this.setState({ showNotification: false });\n }\n\n isOriginalCoverColor = () => this.props.coverColor.toLowerCase().includes('fafbfc');\n\n render() {\n const { isOpened } = this.state;\n const USAIndex = countries.findIndex(country => country.value === 'us');\n const { hasSubscriberPhoneFeature } = this.props;\n\n return(\n \n {this.state.showNotification &&\n \n }\n
\n this.buttonRef = buttonRef}\n onClick={this.toggle}\n className=\"subscribe\"\n style={{\n color: this.isOriginalCoverColor() ? null : this.props.coverColor,\n backgroundColor: this.isOriginalCoverColor() ? null : \"#FFF\",\n }}\n >Subscribe to updates\n {isOpened &&
this.dropdownRef = dropdownRef}>\n {hasSubscriberPhoneFeature &&
\n
this.selectType('mail')}>\n \n
\n
this.selectType('phone')}>\n \n
\n
}\n Subscribe to receive {this.isSelected('mail') ? 'emails' : 'SMS'} everytime {this.props.statuspageName} publishes an update.\n {this.isSelected('mail') && }\n {this.isSelected('phone') && this.setState({ countryCode: option.value })}\n styles={{\n marginTop: '5em'\n }}\n />}\n {this.isSelected('phone') && }\n {this.isSelected('mail') && Submit}\n {this.isSelected('phone') && Submit}\n
}\n
\n
\n )\n }\n}\n\nexport default Subscribe;\n","module.exports = __webpack_public_path__ + \"static/media/mail.20e8982e.svg\";","module.exports = __webpack_public_path__ + \"static/media/phone.2b23e08a.svg\";","function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport React from \"react\";\n\nvar _ref2 =\n/*#__PURE__*/\nReact.createElement(\"path\", {\n d: \"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6\"\n});\n\nvar _ref3 =\n/*#__PURE__*/\nReact.createElement(\"polyline\", {\n points: \"15 3 21 3 21 9\"\n});\n\nvar _ref4 =\n/*#__PURE__*/\nReact.createElement(\"line\", {\n x1: 10,\n y1: 14,\n x2: 21,\n y2: 3\n});\n\nvar SvgExternalLink = function SvgExternalLink(_ref) {\n var svgRef = _ref.svgRef,\n title = _ref.title,\n props = _objectWithoutProperties(_ref, [\"svgRef\", \"title\"]);\n\n return React.createElement(\"svg\", _extends({\n width: 24,\n height: 24,\n viewBox: \"0 0 24 24\",\n fill: \"none\",\n stroke: \"currentColor\",\n strokeWidth: 2,\n strokeLinecap: \"round\",\n strokeLinejoin: \"round\",\n className: \"feather feather-external-link\",\n ref: svgRef\n }, props), title ? React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4);\n};\n\nvar ForwardRef = React.forwardRef(function (props, ref) {\n return React.createElement(SvgExternalLink, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/external-link.ac05cd4f.svg\";\nexport { ForwardRef as ReactComponent };","module.exports = __webpack_public_path__ + \"static/media/maintenance.9277df8f.svg\";","module.exports = __webpack_public_path__ + \"static/media/ok-status-icon.a40ffb2d.svg\";","module.exports = __webpack_public_path__ + \"static/media/red-check.de170854.svg\";","module.exports = __webpack_public_path__ + \"static/media/red-check.de170854.svg\";","module.exports = __webpack_public_path__ + \"static/media/incident.797fb251.svg\";","module.exports = __webpack_public_path__ + \"static/media/maintenance.867b322e.svg\";","import * as React from \"react\"\n\nfunction SvgComponent(props) {\n return (\n \n {\"Artboard\"}\n \n \n )\n}\n\nexport default SvgComponent\n","import * as React from \"react\"\n\nfunction SvgComponent(props) {\n return (\n \n {\"Artboard\"}\n \n \n )\n}\n\nexport default SvgComponent\n","import * as React from \"react\"\n\nfunction SvgComponent(props) {\n return (\n \n {\"Artboard\"}\n \n \n )\n}\n\nexport default SvgComponent\n","import * as React from \"react\"\n\nfunction SvgComponent(props) {\n return (\n \n {\"Artboard\"}\n \n \n \n \n \n )\n}\n\nexport default SvgComponent\n","import React, { Component } from 'react';\nimport UpIcon from './assets/ok-status-icon.jsx';\nimport DownIcon from './assets/red-check.jsx';\nimport IncidentIcon from './assets/incident.jsx';\nimport MaintenanceIcon from './assets/maintenance.jsx';\nimport { Link, withRouter } from 'react-router-dom';\nimport './styles.scss';\nimport {\n formatText,\n formatDateAndTime,\n getMaintenanceStatus,\n getTimeAgo\n} from '../utils/index';\n\nconst allOngoingIncidents = (incidents) => {\n const ongoingIncidents = incidents.filter((incident) => {\n if (incident.type === 'incident' || incident.type === 'outage') {\n if (!!incident.updates[0] && incident.updates[0].type.toLowerCase() !== 'resolved') {\n return true;\n }\n }\n\n if (incident.type === 'maintenance') {\n const maintenanceStatus = getMaintenanceStatus(incident.date, incident.endDate, 0);\n if (maintenanceStatus === 'In Progress' || maintenanceStatus === 'Upcoming') {\n return true;\n }\n }\n });\n\n return ongoingIncidents;\n}\n\nconst getPriorizedIncident = (incidents) => {\n incidents.sort((a, b) => {\n const key1 = new Date(a.date);\n const key2 = new Date(b.date);\n\n if (key1 < key2) {\n return -1;\n } else if (key1 == key2) {\n return 0;\n } else {\n return 1;\n }\n});\n const outage = incidents.find(incident => incident.type === 'outage');\n if (!!outage) {\n return outage;\n }\n\n const incident = incidents.find(incident => incident.type === 'incident');\n if (!!incident) {\n return incident;\n }\n \n const ongoingMaintenance = incidents.find(incident => (incident.type === 'maintenance') && getMaintenanceStatus(incident.date, incident.endDate, 0) === 'In Progress');\n if (!!ongoingMaintenance) {\n return ongoingMaintenance;\n }\n \n const upcomingMaintenance = incidents.find(incident => (incident.type === 'maintenance') && getMaintenanceStatus(incident.date, incident.endDate, 0) === 'Upcoming');\n if (!!upcomingMaintenance) {\n return upcomingMaintenance;\n }\n}\n\nconst getTopLevelIcon = (incident) => {\n if (incident.type === 'outage') {\n return DownIcon;\n }\n \n if (incident.type === 'incident') {\n return IncidentIcon;\n }\n \n if (incident.type === 'maintenance') {\n return MaintenanceIcon;\n }\n\n return UpIcon;\n}\n\nconst getTopLevelContent = (incidents) => {\n const ongoingIncidents = allOngoingIncidents(incidents);\n const priorizedIncident = getPriorizedIncident(ongoingIncidents);\n if (!priorizedIncident) {\n return { title: '', text: '', incidentId: '' };\n }\n\n const mostRecentUpdate = priorizedIncident.updates[0];\n const title = priorizedIncident.title;\n const text = mostRecentUpdate.text;\n\n const Icon = getTopLevelIcon(priorizedIncident);\n\n return {\n title,\n text,\n incidentId: priorizedIncident.uuid,\n postedAt: mostRecentUpdate.UTCTime,\n Icon\n };\n}\n\nconst getIcon = (indicator) => {\n if (indicator === 'up') {\n return UpIcon;\n }\n \n if (indicator === 'down') {\n return DownIcon;\n }\n \n if (indicator === 'maintenance') {\n return MaintenanceIcon;\n }\n \n if (indicator === 'partialoutage') {\n return IncidentIcon;\n }\n}\n\nconst getMostRecentIncidentDate = (incidents) => {\n const mostRecentIncident = incidents[0];\n return getTimeAgo(mostRecentIncident.updates[0].UTCTime);\n}\n\n\nclass TopLevelStatus extends Component {\n isIncidentView() {\n const { pathname } = window.location;\n if (pathname.includes('/history/')) {\n return true;\n }\n return false;\n }\n\n render() {\n const { incidents, topLevelStatus } = this.props;\n\n const topLevelContent = getTopLevelContent(incidents, topLevelStatus);\n\n const hasOngoingIncident = !!topLevelContent && !!topLevelContent.title && topLevelContent.title.length > 0;\n if (!hasOngoingIncident) {\n topLevelContent.title = topLevelStatus.status;\n topLevelContent.Icon = getIcon(topLevelStatus.indicator);\n }\n const hasIncidents = incidents.length > 0;\n\n const TopLevelIcon = topLevelContent.Icon;\n\n return(\n
\n
\n {/* */}\n
\n \n
\n
\n {topLevelContent.title}\n {!!topLevelContent.text && \n \n \n
Last update: {formatDateAndTime(topLevelContent.postedAt)}
\n
\n
}\n {!this.isIncidentView() && hasOngoingIncident && Read more }\n {!hasOngoingIncident && hasIncidents && Last incident {getMostRecentIncidentDate(incidents)} }\n {!hasOngoingIncident && !hasIncidents && No recent incident}\n
\n
\n
\n );\n }\n}\n\nexport default withRouter(TopLevelStatus);\n","import React, { Component } from 'react';\nimport maintenanceImg from './assets/maintenance.svg';\nimport up from './assets/ok-status-icon.svg';\nimport down from './assets/red-check.svg';\n\nclass WhiteBoxHeader extends Component {\n getIndex(services, index) {\n if (index === 0 && services.length > 1) {\n return 'first';\n } else if ((index + 1) === services.length) {\n return 'last';\n } else {\n return '';\n }\n }\n\n getAlias(service) {\n return (!!service.alias && !!service.alias.length) ? service.alias : service.domain;\n }\n\n getServices() {\n const services = this.props.services;\n\n return services.map((service, index) => (\n
\n
{this.getAlias(service)}
\n
\n {(service.isUnderMaintenance === 1)\n ? \"Service \n : ((service.isDown === 0)\n ? \"Service\n : \"Service)\n }\n
\n
\n ))\n }\n\n render() {\n return(\n
\n {this.getServices()}\n
\n );\n }\n}\n\nexport default WhiteBoxHeader;\n","import React, { Component } from 'react'; \nimport './uptime.scss';\nimport { Area, defs, AreaChart, ResponsiveContainer, Tooltip, XAxis, YAxis } from 'recharts';\nimport { formatDateAndTime, getHourAndMinute} from '../utils';\n\nconst getTimeLabel = date => formatDateAndTime(date);\n\nconst months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'June', 'July', 'Aug', 'Sept', 'Oct', 'Nov', 'Dec'];\nconst getHumanDate = value => {\n const today = new Date(value)\n const year = today.getFullYear();\n const month = months[today.getMonth()];\n const day = today.getDate();\n return `${month} ${day > 9 ? '' + day: '0' + day}, ${year}`;\n}\n\nclass Uptime extends Component {\n constructor(props) {\n super(props);\n\n this.state = {\n data: props.data,\n color: props.color\n };\n }\n\n CustomTooltip = (payload) => {\n let hour\n let name\n let date\n if (!!payload.payload.length) {\n name = payload.payload[0].name;\n hour = payload.payload[0].payload.hour;\n date = payload.payload[0].payload.ts;\n } else {\n return null;\n }\n\n const valueFormat = name === 'uptime' ? '%' : 'ms';\n const valueName = name === 'uptime' ? 'Uptime:' : 'Reponse time:';\n\n return (\n
\n
{(this.props.labels === 'hours') ? getTimeLabel(date) : getHumanDate(hour)}
\n {!!payload.payload.length &&
{valueName} {payload.payload[0].value}{valueFormat}
}\n
\n )\n }\n\n render() {\n const { data, labels } = this.props;\n const dataset = data.map((row, index) => {\n if (data.length === index + 1) {\n if (labels === 'day' && row.skeleton === true) {\n row.uptime = data[index - 1].uptime;\n row.elapsedTime = data[index - 1].elapsedTime;\n }\n }\n if (labels === 'hours') {\n row.time = getHourAndMinute(row.date);\n }\n return row;\n });\n\n return(\n \n \n `${name}${labels === 'hours' ? ':00' : ''}`}\n />\n {\n if (label >= 1000) {\n if (label % 1000 === 0) {\n return `${(label / 1000).toFixed(0)}s`\n } else {\n return `${(label / 1000).toFixed(1)}s`\n }\n }\n return label;\n }} width={30} tick={{ fill: '#999', fontSize: 11 }} stroke=\"#efefef\" />\n \n \n \n \n \n \n \n \n \n \n );\n }\n}\n\nexport default Uptime;\n","import React, { Component } from 'react';\nimport Uptime from '../Uptime';\nimport * as moment from 'moment-timezone';\n\nconst months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'June', 'July', 'Aug', 'Sept', 'Oct', 'Nov', 'Dec'];\nconst getLabelDate = (date) => {\n const day = date.getDate();\n const month = months[date.getMonth()];\n return `${month} ${day}`;\n}\n\nconst compUptime = (rows) => {\n const pings = rows.filter(row => row.uptime !== null && row.elapsedTime !== null);\n const uptime = (pings.reduce((acc, day) => acc + day.uptime, 0) / pings.length).toFixed(3);\n return uptime;\n}\n\nconst compElapsedTime = (rows) => {\n const pings = rows.filter(row => row.uptime !== null && row.elapsedTime !== null);\n const elapsedTime = (pings.reduce((acc, day) => acc + day.elapsedTime, 0) / pings.length).toFixed(0);\n return elapsedTime;\n}\n\nclass WhiteBoxStats extends Component {\n constructor(props) {\n super(props);\n\n let color = props.color;\n\n if (!color.length) {\n color = '#5fead7';\n } else if (color[0] !== '#') {\n color = '#' + color;\n }\n\n this.state = {\n color\n };\n }\n\n addHourlyPingsToDailyRows(todayOrYesterday, serviceId) {\n const { services } = this.props;\n const service = services.find(s => s.id === serviceId);\n const pings = service.pings;\n const day = todayOrYesterday === 'today' ? moment().toDate() : moment().subtract(1, 'days').toDate();\n const todayPings = pings.filter(ping => moment(ping.date).isSame(day, 'day'));\n const uptime = compUptime(todayPings);\n const elapsedTime = compElapsedTime(todayPings);\n\n const snapshot = {\n date: day,\n hour: day,\n day: getLabelDate(day),\n uptime: Number(uptime),\n elapsedTime: Number(elapsedTime),\n skeleton: false,\n value: day\n }\n return snapshot;\n }\n \n getGraphs(labels, nbRows) {\n const { services } = this.props;\n const graphs = [];\n\n const servicesWithGraphs = services.filter(service => service.isResponseTimeSelected || service.isUptimeSelected);\n\n if (labels === 'days' && !servicesWithGraphs.every(service => !!service.snapshots)) {\n return [];\n }\n\n services.forEach((service) => {\n let data;\n if (labels === 'hours') {\n data = service.pings;\n } else if (labels === 'days') {\n if (!!service.snapshots) {\n data = service.snapshots;\n } else {\n return;\n }\n }\n \n let meanUptime = null;\n let meanElapsedTime = null;\n let realData = [];\n let filledDays = [];\n if (labels === 'hours') {\n filledDays = data;\n realData = data.filter(ping => !!ping.ts);\n } else if (labels === 'days') {\n filledDays = data.slice(0, nbRows - 1);\n filledDays.forEach((row) => {\n row.skeleton = false;\n row.day = getLabelDate(new Date(row.date));\n row.value = new Date(row.date);\n row.hour = new Date(row.date);\n row.date = new Date(row.date);\n });\n filledDays.reverse();\n const yesterday = moment().subtract(1, 'days');\n const hasYesterday = filledDays.find(day => moment(day.date).isSame(yesterday, 'day'));\n if (!hasYesterday) {\n filledDays.push(this.addHourlyPingsToDailyRows('yesterday', service.id));\n filledDays.shift();\n }\n const today = moment().toDate();\n const hasToday = filledDays.find(day => moment(day.date).isSame(today, 'day'));\n if (!hasToday) {\n filledDays.push(this.addHourlyPingsToDailyRows('today', service.id));\n filledDays.shift();\n }\n }\n\n meanUptime = compUptime(filledDays);\n meanElapsedTime = compElapsedTime(filledDays);\n\n const payload = {\n name: service.alias || service.domain,\n id: service.id,\n data: filledDays,\n hasUptime: service.isUptimeSelected,\n hasResponseTime: service.isResponseTimeSelected,\n uptime: meanUptime,\n responseTime: meanElapsedTime\n };\n\n graphs.push(payload);\n });\n\n return graphs;\n }\n\n getStats(selectedTimeline) {\n const labels = selectedTimeline > 1 ? 'days' : 'hours';\n const nbRows = selectedTimeline === 1 ? 289 : selectedTimeline;\n const graphsList = this.getGraphs(labels, nbRows);\n \n const graphs = graphsList.filter(graph => graph.hasUptime || graph.hasResponseTime);\n return graphs.map((graph, index) =>\n
\n {graph.hasUptime && (
\n
\n
{graph.name} Uptime
\n
{graph.uptime}%
\n
\n \n {graph.hasResponseTime &&
}\n
)\n }\n\n {graph.hasResponseTime && (
\n
\n
{graph.name} Response time
\n
{graph.responseTime}ms
\n
\n \n
)\n }\n
\n );\n }\n\n render() {\n const { selectedTimeline } = this.props;\n\n return(\n !!this.state.color.length && this.getStats(selectedTimeline)\n );\n }\n}\n\nexport default WhiteBoxStats;\n","import React, { Component } from 'react';\n\nclass TimelineSelector extends Component {\n constructor(props) {\n super(props);\n\n const items = props.items;\n items.reverse();\n\n this.state = {\n items\n }\n }\n render() {\n const { selected, onClick, hasSnapshots } = this.props;\n\n return(\n
\n {this.state.items.map(item => {\n if (!hasSnapshots && item.value > 1) {\n return null;\n }\n return(\n onClick(item.value)}\n >\n {item.name}\n )\n }\n )}\n
\n )\n }\n}\n\nexport default TimelineSelector;\n","import React from 'react';\nimport { Link, withRouter } from 'react-router-dom';\n\nimport {\n getHourAndMinute,\n getEstimatedDuration,\n getMaintenanceStatus,\n getTimeAgo,\n formatText,\n getDateRange,\n isWithin24Hours,\n isUpcoming } from '../utils/index.js';\n\nimport './styles.scss';\nimport outageImg from './assets/red-check.svg';\nimport incidentImg from './assets/incident.svg';\nimport maintenanceImg from './assets/maintenance.svg';\n\nconst GetSpan = ({ children }) => {\n return (\n {children}\n )\n};\n\nconst capitalize = (s) => {\n if (typeof s !== 'string') return '';\n return s.charAt(0).toUpperCase() + s.slice(1);\n}\n\nclass Incidents extends React.Component {\n constructor(props) {\n super(props);\n\n const { pathname } = window.location;\n this.state = {\n isPreview: pathname.includes('/public/')\n }\n }\n\n getBackLink = () => {\n const { isPreview } = this.state;\n const { isIncidentPage, statusPageId } = this.props;\n\n let backlink = '/';\n\n if (isPreview) {\n backlink = isIncidentPage ? `/public/${statusPageId}/history` : `/public/${statusPageId}`;\n } else {\n backlink = isIncidentPage ? `/history` : '/';\n }\n\n return backlink;\n }\n\n goToIncidentPage(incidentId) {\n if (this.props.isIncidentPage) {\n return;\n }\n\n const { pathname } = this.props.location;\n\n if (pathname.includes('/history')) {\n this.props.history.push(`${pathname}/${incidentId}`)\n }\n }\n\n capitalize(str) {\n return str.charAt(0).toUpperCase() + str.slice(1);\n }\n\n getIcon(type) {\n if (type === 'maintenance') {\n return maintenanceImg;\n } else if (type === 'incident') {\n return incidentImg;\n } else if (type === 'outage') {\n return outageImg;\n }\n }\n\n render() {\n let { incidents } = this.props;\n const { isHomePage, isIncidentPage, statusPageId, statuspage } = this.props;\n const { isPreview } = this.state;\n if (isHomePage) {\n incidents = incidents.filter((incident) => {\n if (incident.type !== 'maintenance') {\n return isWithin24Hours(new Date(incident.date));\n } else {\n const endDate = new Date(incident.endDate);\n return isWithin24Hours(endDate) || isUpcoming(endDate);\n }\n });\n }\n\n const Tag = isIncidentPage ? GetSpan : Link;\n\n return(\n
\n {isHomePage === false && !isIncidentPage && History}\n {isHomePage === false && isIncidentPage === true && Updates}\n {isHomePage === true && (incidents.length > 0) && Recent updates}\n {incidents.length <= 0 && isHomePage && No update reported today.}\n {!isHomePage &&\n \n Back\n \n }\n
\n\n \n\n {incidents.length <= 0 && !isHomePage &&
No incidents reported.
}\n {incidents.map((incident, index) => (\n \n
\n
{getDateRange(incident)}
\n
\n {!!incident.type && }\n {!!incident.type &&{this.capitalize(incident.type)}}\n
{incident.title}\n {(incident.type === 'maintenance') &&
{getEstimatedDuration(incident)}
}\n
\n {incident.updates.map((update, index) => (\n
\n
{getHourAndMinute(update.UTCTime)}
{incident.type === 'maintenance' ? getMaintenanceStatus(incident.date, incident.endDate, index) : capitalize(update.type)}
Posted {getTimeAgo(update.UTCTime)}
\n {!!update.text &&
}\n
\n ))}\n
\n
\n \n ))}\n\n {isHomePage &&
}\n {isHomePage &&\n \n See history\n \n }\n
\n );\n }\n}\n\nexport default withRouter(Incidents);\n","import React, { Component } from 'react';\nimport './styles.scss';\nimport Notification from '../Notification';\nimport { getBaseUrl } from '../utils';\n\nconst baseUrl = getBaseUrl();\n\nclass ProtectedPage extends Component {\n constructor(props) {\n super(props);\n this.state = {\n password: '',\n wrongPassword: false,\n image: '',\n showNotification: false,\n isLoading: false\n }\n }\n\n componentDidMount() {\n this.setFavicon();\n this.setTabName();\n }\n\n setFavicon() {\n const { favicon } = this.props.data;\n\n if (!!favicon) {\n document.querySelector(\"link[rel='shortcut icon']\").href = favicon;\n }\n }\n\n setTabName() {\n document.title = (this.props.data.name || 'System') + ' Status';\n }\n\n onChangePassword = (e) => {\n this.setState({ password: e.target.value });\n }\n\n submit = (e) => {\n e.preventDefault();\n this.setState({ isLoading: true });\n fetch(`${baseUrl}/api/v1/public/statuspage/authenticate`, {\n method: 'POST',\n headers: {\n 'Accept': 'application/json',\n 'Content-Type': 'application/json'\n },\n credentials: 'include',\n body: JSON.stringify({\n password: this.state.password,\n hostname: window.location.hostname\n })\n }).then(response => response.json())\n .then(response => {\n this.setState({ isLoading: false });\n if (response.message === 'Wrong password') {\n this.setState({ showNotification: true });\n } else {\n window.location.reload();\n }\n });\n }\n \n closeNotification = () => {\n this.setState({ showNotification: false });\n }\n\n render() {\n const { password, isLoading } = this.state;\n const { image, name } = this.props.data;\n\n return(\n
\n
\n
\n {!!image &&\n
\"Logo\"
\n }\n
{name} Service Status
\n
\n \n
\n \n \n {this.state.showNotification &&\n \n }\n
\n );\n }\n}\n\nexport default ProtectedPage;\n","import React, { Component } from 'react';\n\nclass PoweredBy extends Component {\n getHostname() {\n const { hostname } = window.location;\n return hostname;\n }\n\n render() {\n const hostname = this.getHostname();\n\n return (\n
\n Powered by Hyperping\n
\n )\n }\n}\n\nexport default PoweredBy;","import React, { Component } from 'react';\nimport Header from './Header';\nimport WhiteBoxHeader from './WhiteBoxHeader';\nimport WhiteBoxStats from './WhiteBoxStats';\nimport TimelineSelector from './TimelineSelector';\nimport Notification from './Notification';\nimport Incidents from './Incidents';\nimport ProtectedPage from './ProtectedPage';\nimport './App.scss';\nimport { getBaseUrl } from './utils';\nimport { withRouter } from 'react-router-dom';\nimport PoweredBy from './PoweredBy';\n\nconst baseUrl = getBaseUrl();\n \nclass App extends Component {\n constructor(props) {\n super(props);\n\n let showNotification = false;\n let notificationMessage = '';\n if (!!this.props.location.search) {\n const { search } = this.props.location;\n showNotification = search.includes('confirm=true') || search.includes('unsubscribe=true');\n \n if (search.includes('confirm=true')) {\n notificationMessage = 'You successfully confirmed your subscription to this status page';\n } else if (search.includes('unsubscribe=true')) {\n notificationMessage = 'You successfully unsubscribed to this status page';\n }\n }\n\n this.state = {\n statusPageId: null,\n environment: '',\n loading: false,\n services: [],\n statuspage: props.history.location.statuspage,\n timelineItems: [\n { value: 1, name: '24 hours'},\n { value: 8, name: '1 week'},\n { value: 31, name: '1 month'},\n { value: 91, name: '3 months'},\n { value: 365, name: '12 months'},\n ],\n selectedTimeline: 1,\n baseUrl,\n color: '',\n showNotification,\n notificationMessage,\n protected: false,\n protectedPageData: {},\n incidents: []\n };\n }\n\n componentDidMount() {\n const { pathname, hostname } = window.location;\n const statusPageId = pathname.split('/public/')[1];\n\n if (pathname.includes('/public/')) {\n this.setState({\n environment: 'preview',\n statusPageId\n }, () => this.fetchStatusPage());\n } else {\n this.setState({\n environment: 'live',\n statusPageId: hostname\n }, () => this.fetchStatusPage());\n }\n }\n\n isNumber(n) {\n return /^-?[\\d.]+(?:e-?\\d+)?$/.test(n);\n } \n\n hasFavicon() {\n return !!this.state.statuspage.favicon && this.state.statuspage.favicon.length\n }\n\n setFavicon() {\n let favicon = ''\n\n if (this.hasFavicon()) {\n favicon = this.state.statuspage.favicon \n } else {\n const service = this.state.services.find((serv) => !!serv.favicon && serv.favicon.length)\n if (!!service && !!service.favicon) {\n favicon = service.favicon\n }\n }\n\n if (!!favicon && favicon.length) {\n document.querySelector(\"link[rel='shortcut icon']\").href = favicon;\n }\n }\n\n setTabName() {\n document.title = (this.state.statuspage.name || 'System') + ' Status';\n }\n\n fetchSnapshots(services) {\n const ids = services.map(service => {\n if (service.isResponseTimeSelected || service.isUptimeSelected) {\n return service.id;\n }\n });\n\n ids.forEach((id) => {\n fetch(`${this.state.baseUrl}/api/v1/public/snapshots/${id}?limit=365`)\n .then((response) => response.json())\n .then((response) => response.data)\n .then((snapshots) => {\n const services = this.state.services.map((serv) => {\n if (serv.id === id) {\n serv.snapshots = snapshots;\n }\n return serv;\n });\n\n this.setState({ services });\n })\n });\n }\n\n fetchPreview() {\n const { statuspage } = this.state;\n if (!!statuspage) {\n this.setState({\n loading: false,\n services: [...statuspage.services],\n statuspage: statuspage,\n incidents: statuspage.incidents || []\n });\n this.fetchSnapshots(statuspage.services);\n this.setFavicon();\n this.setTabName();\n return;\n }\n\n // let tokenSession = localStorage.getItem('ngStorage-tokenSession')\n // if (!!tokenSession) {\n // tokenSession = tokenSession.replace(/\"/, '').replace(/\"/, '');\n // }\n // const userId = localStorage.getItem('ngStorage-userId');\n\n fetch(`${this.state.baseUrl}/api/v1/public/services/${this.state.statusPageId}`, {\n method: 'GET',\n headers: {\n 'Accept': 'application/json',\n 'Content-Type': 'application/json',\n },\n credentials: 'include'\n })\n .then((response) => response.json())\n .then((response) => {\n if (response.message === 'Unauthorized') {\n this.setState({ protected: true, protectedPageData: response.data });\n }\n return response;\n })\n .then((response) => response.data)\n .then((statuspage) => {\n this.setState({\n loading: false,\n services: [...statuspage.services],\n statuspage: statuspage,\n incidents: statuspage.incidents || []\n });\n\n this.fetchSnapshots(statuspage.services);\n this.setFavicon();\n this.setTabName();\n }).catch((err) => {\n });\n }\n\n fetchStatusPage() {\n this.setState({ loading: true });\n this.fetchPreview();\n }\n\n handleTimelineSelector = (value) => {\n const selectedTimeline = parseInt(value, 10);\n this.setState({ selectedTimeline });\n }\n\n hasSnapshotsLoaded() {\n const services = this.state.services;\n const servicesWithGraphs = services.filter(service => service.isResponseTimeSelected || service.isUptimeSelected);\n const hasSnapshots = servicesWithGraphs.every(service => !!service.snapshots);\n if (!hasSnapshots) {\n return false;\n }\n const hasLoaded = servicesWithGraphs.every(service => !!service.snapshots.length);\n return hasLoaded;\n }\n\n closeNotification = () => {\n this.setState({ showNotification: false });\n }\n\n hasAtLeastOneMetric = () => {\n if (!!this.state.services && this.state.services.length) {\n const hasAtLeastOne = this.state.services.find((service) => (service.isResponseTimeSelected || service.isUptimeSelected));\n return !!hasAtLeastOne;\n }\n\n return false;\n }\n\n render() {\n if (this.state.protected) {\n return (\n \n )\n }\n\n return (\n
\n {this.state.showNotification && }\n
\n\n {!!this.state.services.length &&\n \n }\n\n {!!this.state.services.length && this.hasAtLeastOneMetric() &&\n this.handleTimelineSelector(event)}\n selected={this.state.selectedTimeline}\n hasSnapshots={this.hasSnapshotsLoaded()}\n />\n }\n\n {!!this.state.services.length && !!this.state.statuspage &&\n \n }\n\n {!!this.state.statuspage && this.state.statuspage.features && this.state.statuspage.features.incidents &&\n \n }\n\n {!!this.state.services.length &&\n
\n \n
\n }\n
\n );\n }\n}\n\nexport default withRouter(App);\n","import React from 'react';\nimport IncidentsComponent from './Incidents/index.jsx';\nimport { getBaseUrl } from './utils';\nimport ProtectedPage from './ProtectedPage';\nimport { withRouter } from 'react-router-dom';\nimport Header from './Header';\nimport PoweredBy from './PoweredBy';\nimport './App.scss';\n\nconst baseUrl = getBaseUrl();\n\nclass Incidents extends React.Component {\n constructor(props) {\n super(props);\n\n this.state = {\n incidents: [],\n statuspage: props.history.location.statuspage,\n protected: false,\n protectedPageData: {}\n }\n }\n\n componentDidMount() {\n if (!!this.props.match && !!this.props.match.params && !!this.props.match.params.id) {\n const { id } = this.props.match.params;\n this.setState({ statusPageId: id }, () => {\n this.fetchStatuspage();\n });\n } else {\n const { hostname } = window.location;\n\n this.setState({ statusPageId: hostname }, () => {\n this.fetchStatuspage();\n });\n }\n }\n\n fetchStatuspage = () => {\n if (!!this.state.statuspage) {\n this.setTabName();\n this.setFavicon();\n return null;\n }\n // let tokenSession = localStorage.getItem('ngStorage-tokenSession');\n // if (!!tokenSession) {\n // tokenSession = tokenSession.replace(/\"/, '').replace(/\"/, '');\n // }\n // const userId = localStorage.getItem('ngStorage-userId');\n\n fetch(`${baseUrl}/api/v1/public/services/${this.state.statusPageId}`, {\n method: 'GET',\n headers: {\n 'Accept': 'application/json',\n 'Content-Type': 'application/json',\n },\n credentials: 'include'\n })\n .then((response) => response.json())\n .then((response) => {\n if (response.message === 'Unauthorized') {\n this.setState({ protected: true, protectedPageData: response.data });\n }\n return response;\n })\n .then((response) => response.data)\n .then((statuspage) => {\n this.setState({ statuspage }, () => {\n this.setTabName();\n this.setFavicon();\n });\n }).catch((err) => {\n console.log(err);\n });\n }\n\n setTabName() {\n document.title = (this.state.statuspage.name || 'System') + ' Incidents';\n }\n\n hasFavicon() {\n return !!this.state.statuspage.favicon && this.state.statuspage.favicon.length\n }\n\n setFavicon() {\n let favicon = '';\n\n if (this.hasFavicon()) {\n favicon = this.state.statuspage.favicon;\n document.querySelector(\"link[rel='shortcut icon']\").href = favicon;\n }\n }\n\n render() {\n if (this.state.protected) {\n return (\n \n )\n }\n\n const { statuspage } = this.state;\n if (!statuspage) {\n return null;\n }\n const incidents = statuspage.incidents;\n return(\n
\n {
}\n\n {!!incidents && }\n
\n \n
\n
\n );\n }\n}\n\nexport default withRouter(Incidents);\n","import React from 'react';\nimport IncidentsComponent from './Incidents/index.jsx';\nimport Header from './Header';\nimport './App.scss';\nimport ProtectedPage from './ProtectedPage';\nimport { getBaseUrl } from './utils';\nimport { withRouter } from 'react-router-dom';\nimport PoweredBy from './PoweredBy';\n\nconst baseUrl = getBaseUrl();\n\nclass Incident extends React.Component {\n constructor(props) {\n super(props);\n\n this.state = {\n incident: props.history.location.incident,\n statuspage: props.history.location.statuspage,\n incidentId: null,\n protected: false,\n protectedPageData: {}\n }\n }\n\n componentDidMount() {\n const { incidentId } = this.props.match.params;\n\n if (!!this.props.match && !!this.props.match.params && !!this.props.match.params.id) {\n const { id } = this.props.match.params;\n\n this.setState({ statusPageId: id, incidentId }, () => {\n this.fetchIncident();\n });\n } else {\n const { hostname } = window.location;\n\n this.setState({ statusPageId: hostname, incidentId }, () => {\n this.fetchIncident();\n });\n }\n }\n\n fetchStatuspage = () => {\n if (!!this.state.statuspage) {\n this.setTabName();\n this.setFavicon();\n return null;\n }\n\n fetch(`${baseUrl}/api/v1/public/services/${this.state.statusPageId}`, {\n method: 'GET',\n headers: {\n 'Accept': 'application/json',\n 'Content-Type': 'application/json',\n },\n credentials: 'include'\n })\n .then((response) => response.json())\n .then((response) => {\n if (response.message === 'Unauthorized') {\n this.setState({ protected: true, protectedPageData: response.data });\n }\n return response;\n })\n .then((response) => response.data)\n .then((statuspage) => {\n this.setState({ statuspage }, () => {\n this.setTabName();\n this.setFavicon();\n });\n });\n }\n\n\n fetchIncident() {\n if (!!this.state.incident) {\n return;\n }\n const { incidentId } = this.state;\n const { hostname } = window.location;\n\n fetch(`${baseUrl}/api/v1/incident/${hostname}/${incidentId}`, {\n method: 'GET',\n headers: {\n 'Accept': 'application/json',\n 'Content-Type': 'application/json'\n },\n credentials: 'include'\n })\n .then(response => response.json())\n .then((response) => {\n this.setState({ incident: response.data });\n });\n\n if (!this.state.statuspage) {\n this.fetchStatuspage();\n } else {\n this.setTabName();\n }\n }\n\n setTabName() {\n document.title = this.state.statuspage.name + ' Incidents';\n }\n\n hasFavicon() {\n return !!this.state.statuspage.favicon && this.state.statuspage.favicon.length\n }\n\n setFavicon() {\n let favicon = ''\n\n if (this.hasFavicon()) {\n favicon = this.state.statuspage.favicon \n document.querySelector(\"link[rel='shortcut icon']\").href = favicon;\n }\n }\n\n render() {\n if (this.state.protected) {\n return (\n \n )\n }\n\n const { incident, statuspage } = this.state;\n if (!statuspage) {\n return null;\n }\n\n return (\n
\n {
}\n\n {!!incident\n && \n }\n
\n \n
\n
\n );\n }\n}\n\nexport default withRouter(Incident);\n","import React from 'react';\nimport { Redirect } from 'react-router-dom';\nimport { getBaseUrl } from './utils';\nimport './App.scss';\n\nconst baseUrl = getBaseUrl();\n\nclass ConfirmSubscription extends React.Component {\n constructor(props) {\n super(props);\n\n this.state = {\n token: null,\n isConfirmed: false,\n redirect: false\n }\n }\n\n componentDidMount() {\n const { token } = this.props.match.params;\n\n this.setState({ token }, () => {\n this.confirmSusbcription();\n });\n }\n\n confirmSusbcription = () => {\n fetch(`${baseUrl}/api/v1/confirm-subscription?token=${this.state.token}`, {\n method: 'GET',\n headers: {\n 'Accept': 'application/json',\n 'Content-Type': 'application/json'\n },\n credentials: 'include'\n })\n .then(response => response.json())\n .then((response) => {\n this.setState({ isConfirmed: true, redirect: true });\n });\n }\n\n renderRedirect = () => {\n const { pathname } = this.props.location;\n let pathnameDestination = '/';\n if (pathname.includes('/public/')) {\n pathnameDestination = pathname.split('/confirm/')[0];\n }\n if (this.state.redirect) {\n return \n }\n }\n\n render() {\n return(\n
\n {this.renderRedirect()}\n {!this.isConfirmed && Confirming your subscription}\n
\n );\n }\n}\n\nexport default ConfirmSubscription;\n","import React from 'react';\nimport { Redirect } from 'react-router-dom';\nimport { getBaseUrl } from './utils';\nimport './App.scss';\n\nconst baseUrl = getBaseUrl();\n\nclass Unsubscribe extends React.Component {\n constructor(props) {\n super(props);\n\n this.state = {\n token: null,\n isUnsubscribed: false,\n redirect: false\n }\n }\n\n componentDidMount() {\n const { token } = this.props.match.params;\n\n this.setState({ token }, () => {\n this.confirmSusbcription();\n });\n }\n\n confirmSusbcription = () => {\n fetch(`${baseUrl}/api/v1/unsubscribe?token=${this.state.token}`)\n .then(response => response.json())\n .then((response) => {\n this.setState({ isUnsubscribed: true, redirect: true });\n });\n }\n\n renderRedirect = () => {\n const { pathname } = this.props.location;\n let pathnameDestination = '/';\n if (pathname.includes('/public/')) {\n pathnameDestination = pathname.split('/unsubscribe/')[0];\n }\n if (this.state.redirect) {\n return \n }\n }\n\n render() {\n return(\n
\n {this.renderRedirect()}\n {!this.isUnsubscribed && Unsubscribing}\n
\n );\n }\n}\n\nexport default Unsubscribe;\n","// In production, we register a service worker to serve assets from local cache.\n\n// This lets the app load faster on subsequent visits in production, and gives\n// it offline capabilities. However, it also means that developers (and users)\n// will only see deployed updates on the \"N+1\" visit to a page, since previously\n// cached resources are updated in the background.\n\n// To learn more about the benefits of this model, read https://goo.gl/KwvDNy.\n// This link also includes instructions on opting out of this behavior.\n\nconst isLocalhost = Boolean(\n window.location.hostname === 'localhost' ||\n // [::1] is the IPv6 localhost address.\n window.location.hostname === '[::1]' ||\n // 127.0.0.1/8 is considered localhost for IPv4.\n window.location.hostname.match(\n /^127(?:\\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/\n )\n);\n\nexport default function register() {\n if (process.env.NODE_ENV === 'production' && 'serviceWorker' in navigator) {\n // The URL constructor is available in all browsers that support SW.\n const publicUrl = new URL(process.env.PUBLIC_URL, window.location);\n if (publicUrl.origin !== window.location.origin) {\n // Our service worker won't work if PUBLIC_URL is on a different origin\n // from what our page is served on. This might happen if a CDN is used to\n // serve assets; see https://github.com/facebookincubator/create-react-app/issues/2374\n return;\n }\n\n window.addEventListener('load', () => {\n const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`;\n\n if (isLocalhost) {\n // This is running on localhost. Lets check if a service worker still exists or not.\n checkValidServiceWorker(swUrl);\n\n // Add some additional logging to localhost, pointing developers to the\n // service worker/PWA documentation.\n navigator.serviceWorker.ready.then(() => {\n console.log(\n 'This web app is being served cache-first by a service ' +\n 'worker. To learn more, visit https://goo.gl/SC7cgQ'\n );\n });\n } else {\n // Is not local host. Just register service worker\n registerValidSW(swUrl);\n }\n });\n }\n}\n\nfunction registerValidSW(swUrl) {\n navigator.serviceWorker\n .register(swUrl)\n .then(registration => {\n registration.onupdatefound = () => {\n const installingWorker = registration.installing;\n installingWorker.onstatechange = () => {\n if (installingWorker.state === 'installed') {\n if (navigator.serviceWorker.controller) {\n // At this point, the old content will have been purged and\n // the fresh content will have been added to the cache.\n // It's the perfect time to display a \"New content is\n // available; please refresh.\" message in your web app.\n console.log('New content is available; please refresh.');\n } else {\n // At this point, everything has been precached.\n // It's the perfect time to display a\n // \"Content is cached for offline use.\" message.\n console.log('Content is cached for offline use.');\n }\n }\n };\n };\n })\n .catch(error => {\n console.error('Error during service worker registration:', error);\n });\n}\n\nfunction checkValidServiceWorker(swUrl) {\n // Check if the service worker can be found. If it can't reload the page.\n fetch(swUrl)\n .then(response => {\n // Ensure service worker exists, and that we really are getting a JS file.\n if (\n response.status === 404 ||\n response.headers.get('content-type').indexOf('javascript') === -1\n ) {\n // No service worker found. Probably a different app. Reload the page.\n navigator.serviceWorker.ready.then(registration => {\n registration.unregister().then(() => {\n window.location.reload();\n });\n });\n } else {\n // Service worker found. Proceed as normal.\n registerValidSW(swUrl);\n }\n })\n .catch(() => {\n console.log(\n 'No internet connection found. App is running in offline mode.'\n );\n });\n}\n\nexport function unregister() {\n if ('serviceWorker' in navigator) {\n navigator.serviceWorker.ready.then(registration => {\n registration.unregister();\n });\n }\n}\n","import React from 'react';\nimport ReactDOM from 'react-dom';\nimport { Route, BrowserRouter as Router, Switch } from 'react-router-dom';\nimport './index.scss';\nimport App from './App';\nimport Incidents from './IncidentsPage';\nimport Incident from './IncidentPage';\nimport ConfirmSubscription from './ConfirmSubscriptionPage';\nimport Unsubscribe from './UnsubscribePage';\nimport { unregister } from './registerServiceWorker';\n\nconst routing = (\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n);\n\nReactDOM.render(routing, document.getElementById('root'));\nunregister();\n","import React, { Component } from 'react';\nimport Subscribe from '../Subscribe';\nimport TopLevelStatus from '../TopLevelStatus';\nimport './header.scss';\nimport { ReactComponent as ExternalLink } from './assets/external-link.svg';\n\nconst EmptyState = () => (\n
\n
\n
\n
\n
\n);\n\nclass Header extends Component {\n constructor(props) {\n super(props);\n\n const baseUrl = !!process && !!process.env && process.env.REACT_APP_STAGE === 'dev'\n ? 'http://localhost:3200'\n : 'https://app.hyperping.io';\n this.state = {\n baseUrl,\n }\n }\n\n hasSubscriberFeature = () => {\n const { statuspage } = this.props;\n\n return !!statuspage.features\n && !!statuspage.features.subscribers\n && statuspage.features.subscribers === true;\n }\n \n hasSubscriberPhoneFeature = () => {\n const { statuspage } = this.props;\n\n return !!statuspage.features\n && !!statuspage.features.subscribersPhone\n && statuspage.features.subscribersPhone === true;\n }\n\n isOriginalCoverColor = () => this.props.statuspage.coverColor.toLowerCase().includes('fafbfc');\n\n render() {\n const { statuspage } = this.props;\n if (!statuspage) {\n return ;\n }\n\n return(\n
\n
\n \n {!!statuspage.image && !!statuspage.image.length &&\n \"Logo\"\n }\n \n \n {!!statuspage.homepage && \n Go to {statuspage.name}\n }\n {this.hasSubscriberFeature() && }\n \n
\n \n
\n )\n }\n}\n\nexport default Header;\n","import React from 'react';\n\nimport './styles.scss';\n\nclass Notification extends React.Component {\n componentDidMount() {\n setTimeout(() => {\n this.props.closeNotification();\n }, 4500);\n }\n\n render() {\n return(\n
{this.props.message}
\n );\n }\n}\n\nexport default Notification;\n","import * as React from 'react';\nimport * as moment from 'moment-timezone';\n\nexport const formatDate = (rawDate) => {\n const date = new Date(rawDate);\n const formatted = moment(date).format('DD MMM YYYY');\n return formatted;\n}\n\nexport const formatDateAndTime = (rawDate) => {\n const date = new Date(rawDate);\n const formatted = moment(date).format('D MMM YYYY H:mm A');\n return formatted;\n}\n\nexport const getHourAndMinute = (rawDate) => {\n // 20:50\n\n const date = new Date(rawDate);\n const formatted = moment(date).format('HH:mm');\n return formatted;\n}\n\nexport const getTimeAgo = rawDate => moment(new Date(rawDate), 'YYYYMMDD').fromNow();\n\nexport const formatText = text => text.split('\\n').join('
');\n\nconst areDatesOnSameMonth = (latestDateRaw, oldestDateRaw) => {\n const latestDate = new Date(latestDateRaw);\n const oldestDate = new Date(oldestDateRaw);\n\n const formattedLatestDate = moment(latestDate).format('MMM');\n const formattedOldestDate = moment(oldestDate).format('MMM');\n return formattedLatestDate === formattedOldestDate;\n}\n\nconst areDatesOnSameDay = (latestDateRaw, oldestDateRaw) => {\n const latestDate = new Date(latestDateRaw);\n const oldestDate = new Date(oldestDateRaw);\n\n const latestDay = moment(latestDate).format('DD');\n const oldestDay = moment(oldestDate).format('DD');\n return { latestDay, oldestDay };\n}\n\nexport const getDateRange = (incident) => {\n const { updates } = incident;\n\n const latest = updates[0];\n if (!latest) {\n return moment(incident.date).format('DD MMM YYYY');\n }\n const oldest = updates[updates.length - 1];\n const aresameMonth = areDatesOnSameMonth(latest.UTCTime, oldest.UTCTime);\n const { latestDay, oldestDay } = areDatesOnSameDay(latest.UTCTime, oldest.UTCTime);\n if (aresameMonth && (latestDay === oldestDay)) {\n return formatDate(latest.UTCTime);\n }\n\n if (aresameMonth && (latestDay !== oldestDay)) {\n return `${oldestDay} - ${latestDay} ${moment(latest.UTCTime).format('MMM YYYY')}`;\n }\n\n if (!aresameMonth) {\n return `${oldestDay} ${moment(new Date(oldest.UTCTime)).format('MMM')} - ${latestDay} ${moment(new Date(latest.UTCTime)).format('MMM YYYY')}`;\n }\n}\n\nexport const isWithin24Hours = (dateRaw) => {\n const now = new Date();\n const hours = Math.abs(dateRaw - now) / 36e5;\n return hours <= 24;\n}\n\nexport const isUpcoming = (dateRaw) => {\n const now = new Date();\n return moment(dateRaw).isAfter(now);\n}\n\nconst getTimezone = () => moment.tz(moment.tz.guess()).format('z');\n\nconst getHourGrammar = (hour) => {\n if (hour > 1) {\n return ' hours';\n } else {\n return ' hour'\n }\n}\n\nconst getMinuteGrammar = (minute) => {\n if (minute > 1) {\n return 'minutes';\n } else {\n return 'minute'\n }\n}\n\nexport const getEstimatedDuration = (maintenance) => {\n const hasMinutes = maintenance.minutes !== 0;\n const hasHours = maintenance.hours !== 0;\n let duration = `${hasHours ? (maintenance.hours + getHourGrammar(maintenance.hours)) : ''}`;\n if (hasHours && hasMinutes) {\n duration += ` and ${maintenance.minutes} ${getMinuteGrammar(maintenance.minutes)}`\n } else if (hasMinutes) {\n duration += `${maintenance.minutes} ${getMinuteGrammar(maintenance.minutes)}`\n }\n\n const startDate = new Date(maintenance.date);\n const startHumanDate = moment(startDate).format('DD MMM h:mm A');\n const endDate = new Date(maintenance.endDate);\n const endHumanDate = moment(endDate).format('DD MMM h:mm A');\n\n const timezone = getTimezone();\n \n return (\n \n Estimated duration: {duration}
\n{startHumanDate} {timezone} - {endHumanDate} {timezone}\n
\n );\n}\n\nexport const getMaintenanceStatus = (startDate, endDate, index) => {\n if (index !== 0) {\n return;\n }\n\n const date = new Date();\n if (moment(date).isBetween(startDate, endDate)) {\n return 'In Progress';\n } else if (moment(date).isBefore(startDate)) {\n return 'Upcoming';\n } else if (moment(date).isAfter(endDate)) {\n return 'Completed'\n }\n}\n\nconst { hostname, protocol } = window.location;\n\nconst getProtocol = () => {\n // Only *.hyperping.io domains can be accessible without https\n // status.* domains are being redirected to https\n if (hostname.includes('.hyperping.io') && protocol === 'http:') {\n return 'https://';\n }\n if (!!process && !!process.env && process.env.REACT_APP_STAGE === 'dev') {\n return 'http://';\n }\n return 'https://';\n}\n\nexport const getBaseUrl = () => !!process && !!process.env && process.env.REACT_APP_STAGE === 'dev'\n ? 'http://status.dev.io:3000'\n : `${getProtocol()}app.hyperping.io` "],"sourceRoot":""}