Repository URL to install this package:
|
Version:
0.0.7 ▾
|
import * as tslib_1 from "tslib";
import * as React from 'react';
import Helmet from 'react-helmet';
import { observer } from 'xmobx/mobx-react';
import { Main } from '@skava/packages/ui';
import { StatusContainer } from './StatusContainer';
/**
* @alias IsItDown
*/
let StatusPage = class StatusPage extends React.Component {
/**
* @alias IsItDown
*/
constructor() {
super(...arguments);
this.state = new StatusContainer();
}
render() {
const isJavaCached = String(this.state.isJavaCached);
const isJavaDown = String(this.state.isJavaDown);
const status = String(this.state.isItDown);
const cached = String(this.state.isItCached);
const { stability, version, date, sprint, release, semantic } = this.state.version;
const styles = { padding: '2rem' };
const versionStyles = { fontSize: '2rem' };
/**
* @todo - use table?
* @todo - render outside of SSR always, also render the current ENV config from server (for AGAIN re-configuring feature branch, or verifying if devops did the required update from MacDonald)
*/
return (React.createElement(Main, { className: "status" },
React.createElement(Helmet, null,
React.createElement("title", null, version)),
React.createElement("article", { style: styles },
React.createElement("button", { onClick: this.state.handleClearCache }, "clear cache"),
React.createElement("h2", { style: versionStyles },
"version: ",
version),
React.createElement("h4", null,
"stability: ",
stability),
React.createElement("h4", null,
"release-date: ",
date),
React.createElement("h4", null,
"release-version: ",
release),
React.createElement("h4", null,
"semantic-version: ",
semantic),
React.createElement("section", null,
React.createElement("details", null,
React.createElement("summary", null,
React.createElement("span", { style: versionStyles }, "extra")),
React.createElement("section", null,
React.createElement("h4", null,
"GIT_HASH: ",
process.env.GIT_HASH),
React.createElement("h4", null,
"BUSINESS_RELATIONSHIP: ",
process.env.BUSINESS_RELATIONSHIP),
React.createElement("h4", null,
"API_LAYER: ",
process.env.API_LAYER),
React.createElement("h4", null,
"NODE_ENV: ",
process.env.NODE_ENV),
React.createElement("h4", null,
"sprint-version: ",
sprint),
React.createElement("h4", null,
"is it down? ",
status),
React.createElement("h4", null,
"is it cached? ",
cached),
React.createElement("h4", null,
"is java down? ",
isJavaDown),
React.createElement("h4", null,
"is java cached? ",
isJavaCached)))))));
}
};
StatusPage = tslib_1.__decorate([
observer
], StatusPage);
export default StatusPage;
//# sourceMappingURL=StatusPage.js.map