-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Completed basic POS test application
- Loading branch information
Ben Damman
committed
Jul 19, 2017
1 parent
215725f
commit 5b1bce1
Showing
43 changed files
with
1,400 additions
and
928 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,7 +15,7 @@ | |
}()); | ||
</script> | ||
</head> | ||
<body> | ||
<body class="app"> | ||
<div id="root"></div> | ||
<script> | ||
{ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,7 +13,7 @@ | |
|
||
.btnGroup { | ||
position: relative; | ||
top: 500px; | ||
top: 400px; | ||
width: 480px; | ||
margin: 0 auto; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
.container { | ||
text-align: center; | ||
} | ||
|
||
.logo { | ||
width: 200px; | ||
} | ||
|
||
.container h2 { | ||
font-size: 3rem; | ||
} | ||
|
||
.container a { | ||
font-size: 1.4rem; | ||
} | ||
|
||
textarea { | ||
font-size: 4em; | ||
padding: 3px; | ||
width: 50rem; | ||
} | ||
|
||
button { | ||
margin: 2em; | ||
} | ||
|
||
.correct { | ||
font-size: 3em; | ||
background-color: #4CAF50; | ||
} | ||
.incorrect { | ||
font-size: 3em; | ||
background-color: #f44336; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
// @flow | ||
import React, { Component } from 'react'; | ||
import { Link } from 'react-router-dom'; | ||
import styles from './CustomerWindow.css'; | ||
import { ipcRenderer } from 'electron'; | ||
|
||
export default class customerWindow extends Component { | ||
render() { | ||
const confirm = (e) => { | ||
ipcRenderer.send('hide-customer-window'); | ||
}; | ||
return ( | ||
<div> | ||
<div className={styles.container} data-tid="container"> | ||
<img className={styles.logo} src="../resources/images/dmvlogo.png" /> | ||
<h2>Please confirm your address</h2> | ||
<div> | ||
<textarea> | ||
505 Rhode Island Ave NW | ||
Washington, DC 20001 | ||
</textarea> | ||
<p> | ||
<button className={styles.correct} onClick={confirm}>Correct</button> | ||
<button className={styles.incorrect} onClick={confirm}>Incorrect</button> | ||
</p> | ||
</div> | ||
<small> | ||
We are using node {process.versions.node}, | ||
Chromium {process.versions.chrome}, | ||
and Electron {process.versions.electron}. | ||
</small> | ||
</div> | ||
</div> | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
.container { | ||
text-align: center; | ||
} | ||
|
||
.logo { | ||
width: 200px; | ||
} | ||
|
||
.container h2 { | ||
font-size: 3rem; | ||
} | ||
|
||
.container a { | ||
font-size: 1.4rem; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
// @flow | ||
import React, { Component } from 'react'; | ||
import { Link } from 'react-router-dom'; | ||
import styles from './WindowTest.css'; | ||
import { ipcRenderer } from 'electron'; | ||
|
||
export default class WindowTest extends Component { | ||
render() { | ||
const showCustomerWindow = (e) => { | ||
ipcRenderer.send('show-customer-window'); | ||
}; | ||
return ( | ||
<div> | ||
<div className={styles.backButton} data-tid="backButton"> | ||
<Link to="/"> | ||
<i className="fa fa-arrow-left fa-3x" /> | ||
</Link> | ||
</div> | ||
<div className={styles.container} data-tid="container"> | ||
<img className={styles.logo} src="../resources/images/dmvlogo.png" /> | ||
<h2>Technician Window</h2> | ||
<p><button onClick={showCustomerWindow}>Confirm Address</button></p> | ||
</div> | ||
</div> | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { bindActionCreators } from 'redux'; | ||
import { connect } from 'react-redux'; | ||
import Counter from '../components/Counter'; | ||
import * as CounterActions from '../actions/counter'; | ||
import CustomerWindow from '../components/CustomerWindow'; | ||
|
||
function mapStateToProps(state) { | ||
return { | ||
counter: state.counter | ||
}; | ||
} | ||
|
||
function mapDispatchToProps(dispatch) { | ||
return bindActionCreators(CounterActions, dispatch); | ||
} | ||
|
||
export default connect(mapStateToProps, mapDispatchToProps)(CustomerWindow); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { bindActionCreators } from 'redux'; | ||
import { connect } from 'react-redux'; | ||
import Counter from '../components/Counter'; | ||
import * as CounterActions from '../actions/counter'; | ||
import WindowTest from '../components/WindowTest'; | ||
|
||
function mapStateToProps(state) { | ||
return { | ||
counter: state.counter | ||
}; | ||
} | ||
|
||
function mapDispatchToProps(dispatch) { | ||
return bindActionCreators(CounterActions, dispatch); | ||
} | ||
|
||
export default connect(mapStateToProps, mapDispatchToProps)(WindowTest); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.