Skip to content

Commit

Permalink
feat(runsTable): Add support for auto reload of runs table
Browse files Browse the repository at this point in the history
Fixes #57
  • Loading branch information
vivekratnavel committed Mar 13, 2019
1 parent 279001f commit 0a06c08
Show file tree
Hide file tree
Showing 5 changed files with 357 additions and 7 deletions.
2 changes: 2 additions & 0 deletions web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
"html-webpack-plugin": "2.29.0",
"ify-loader": "^1.1.0",
"jest": "^24.1.0",
"moment": "^2.24.0",
"ms": "^2.1.1",
"object-assign": "4.1.1",
"plotly.js": "^1.33.1",
Expand All @@ -66,6 +67,7 @@
"react-router": "^4.2.0",
"react-router-dom": "^4.2.2",
"react-select": "^2.0.0",
"react-switch": "^4.1.0",
"react-syntax-highlighter": "^9.0.0",
"react-table": "^6.7.6",
"react-toastify": "^4.2.0",
Expand Down
264 changes: 264 additions & 0 deletions web/src/components/RunsTable/__snapshots__/runsTable.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -7692,6 +7692,270 @@ exports[`RunsTable should render 1`] = `
</div>
</div>
</div>
<div
className="status-bar pull-right"
>
<label>
<span
className="label-text"
>
Auto Reload
</span>

<ReactSwitch
activeBoxShadow="0 0 2px 3px #3bf"
boxShadow={null}
checked={true}
checkedIcon={
<svg
height="100%"
style={
Object {
"position": "absolute",
"top": 0,
}
}
viewBox="-2 -5 17 21"
width="100%"
>
<path
d="M11.264 0L5.26 6.004 2.103 2.847 0 4.95l5.26 5.26 8.108-8.107L11.264 0"
fill="#fff"
fillRule="evenodd"
/>
</svg>
}
className="switch-container"
disabled={false}
height={16}
offColor="#888"
offHandleColor="#fff"
onChange={[Function]}
onColor="#33bd33"
onHandleColor="#fff"
uncheckedIcon={
<svg
height="100%"
style={
Object {
"position": "absolute",
"top": 0,
}
}
viewBox="-2 -5 14 20"
width="100%"
>
<path
d="M9.9 2.12L7.78 0 4.95 2.828 2.12 0 0 2.12l2.83 2.83L0 7.776 2.123 9.9 4.95 7.07 7.78 9.9 9.9 7.776 7.072 4.95 9.9 2.12"
fill="#fff"
fillRule="evenodd"
/>
</svg>
}
width={32}
>
<div
className="switch-container"
style={
Object {
"MozTransition": "opacity 0.25s",
"MozUserSelect": "none",
"WebkitTapHighlightColor": "rgba(0, 0, 0, 0)",
"WebkitTransition": "opacity 0.25s",
"WebkitUserSelect": "none",
"borderRadius": 8,
"display": "inline-block",
"msUserSelect": "none",
"opacity": 1,
"position": "relative",
"textAlign": "left",
"touchAction": "none",
"transition": "opacity 0.25s",
"userSelect": "none",
}
}
>
<div
className="react-switch-bg"
onClick={[Function]}
onMouseDown={[Function]}
style={
Object {
"MozTransition": "background 0.25s",
"WebkitTransition": "background 0.25s",
"background": "#33bd33",
"borderRadius": 8,
"cursor": "pointer",
"height": 16,
"margin": 0,
"position": "relative",
"transition": "background 0.25s",
"width": 32,
}
}
>
<div
style={
Object {
"MozTransition": "opacity 0.25s",
"WebkitTransition": "opacity 0.25s",
"height": 16,
"opacity": 1,
"pointerEvents": "none",
"position": "relative",
"transition": "opacity 0.25s",
"width": 18,
}
}
>
<svg
height="100%"
style={
Object {
"position": "absolute",
"top": 0,
}
}
viewBox="-2 -5 17 21"
width="100%"
>
<path
d="M11.264 0L5.26 6.004 2.103 2.847 0 4.95l5.26 5.26 8.108-8.107L11.264 0"
fill="#fff"
fillRule="evenodd"
/>
</svg>
</div>
<div
style={
Object {
"MozTransition": "opacity 0.25s",
"WebkitTransition": "opacity 0.25s",
"height": 16,
"opacity": 0,
"pointerEvents": "none",
"position": "absolute",
"right": 0,
"top": 0,
"transition": "opacity 0.25s",
"width": 18,
}
}
>
<svg
height="100%"
style={
Object {
"position": "absolute",
"top": 0,
}
}
viewBox="-2 -5 14 20"
width="100%"
>
<path
d="M9.9 2.12L7.78 0 4.95 2.828 2.12 0 0 2.12l2.83 2.83L0 7.776 2.123 9.9 4.95 7.07 7.78 9.9 9.9 7.776 7.072 4.95 9.9 2.12"
fill="#fff"
fillRule="evenodd"
/>
</svg>
</div>
</div>
<div
className="react-switch-handle"
onClick={[Function]}
onMouseDown={[Function]}
onTouchCancel={[Function]}
onTouchEnd={[Function]}
onTouchMove={[Function]}
onTouchStart={[Function]}
style={
Object {
"MozTransition": "background-color 0.25s, transform 0.25s, box-shadow 0.15s",
"WebkitTransition": "background-color 0.25s, transform 0.25s, box-shadow 0.15s",
"background": "#ffffff",
"border": 0,
"borderRadius": "50%",
"boxShadow": null,
"cursor": "pointer",
"display": "inline-block",
"height": 14,
"outline": 0,
"position": "absolute",
"top": 1,
"transform": "translateX(17px)",
"transition": "background-color 0.25s, transform 0.25s, box-shadow 0.15s",
"width": 14,
}
}
/>
<input
checked={true}
disabled={false}
onBlur={[Function]}
onChange={[Function]}
onFocus={[Function]}
onKeyUp={[Function]}
role="switch"
style={
Object {
"border": 0,
"clip": "rect(0 0 0 0)",
"height": 1,
"margin": -1,
"overflow": "hidden",
"padding": 0,
"position": "absolute",
"width": 1,
}
}
type="checkbox"
/>
</div>
</ReactSwitch>

</label>
<span>
Last Update:
<span
className="date-text"
>

December 31st, 07:00:02 PM
</span>
</span>

<Button
active={false}
block={false}
bsClass="btn"
bsStyle="success"
className="reload-button"
disabled={false}
onClick={[Function]}
>
<button
className="reload-button btn btn-success"
disabled={false}
onClick={[Function]}
type="button"
>
<Glyphicon
bsClass="glyphicon"
glyph="repeat"
>
<span
className="glyphicon glyphicon-repeat"
/>
</Glyphicon>
<span
className="reload-text"
>
Reload
</span>
</button>
</Button>
</div>
<div
className="table-wrapper"
>
Expand Down

0 comments on commit 0a06c08

Please sign in to comment.