Skip to content

Commit

Permalink
Ready for test build
Browse files Browse the repository at this point in the history
  • Loading branch information
comountainclimber committed Aug 19, 2021
1 parent c2acdb4 commit 82c64d9
Show file tree
Hide file tree
Showing 5 changed files with 53 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ exports[`ConfirmModal should render without crashing 1`] = `
style={
Object {
"content": Object {
"height": "200px",
"height": "250px",
"width": "500px",
},
}
Expand All @@ -44,7 +44,7 @@ exports[`ConfirmModal should render without crashing 1`] = `
style={
Object {
"content": Object {
"height": "200px",
"height": "250px",
"width": "500px",
},
}
Expand Down Expand Up @@ -201,7 +201,7 @@ exports[`ConfirmModal should render without crashing 1`] = `
"color": "var(--base-text)",
"display": "flex",
"flexDirection": "column",
"height": "200px",
"height": "250px",
"margin": "auto",
"padding": 0,
"width": "500px",
Expand Down Expand Up @@ -352,7 +352,7 @@ exports[`ConfirmModal should render without crashing 1`] = `
>
<div
class="ReactModal__Content ReactModal__Content--after-open"
style="position: absolute; top: 40px; left: 40px; right: 40px; bottom: 40px; overflow: auto; border-radius: 4px; outline: none; padding: 0px; width: 500px; height: 200px; margin: auto; box-shadow: rgba(0, 0, 0, 0.1) 0px 0px 4px; display: flex; flex-direction: column; z-index: 5000;"
style="position: absolute; top: 40px; left: 40px; right: 40px; bottom: 40px; overflow: auto; border-radius: 4px; outline: none; padding: 0px; width: 500px; height: 250px; margin: auto; box-shadow: rgba(0, 0, 0, 0.1) 0px 0px 4px; display: flex; flex-direction: column; z-index: 5000;"
tabindex="-1"
>
<div
Expand Down Expand Up @@ -573,7 +573,7 @@ exports[`ConfirmModal should render without crashing 1`] = `
"color": "var(--base-text)",
"display": "flex",
"flexDirection": "column",
"height": "200px",
"height": "250px",
"margin": "auto",
"padding": 0,
"width": "500px",
Expand Down Expand Up @@ -1000,7 +1000,7 @@ exports[`ConfirmModal should render without crashing 1`] = `
"color": "var(--base-text)",
"display": "flex",
"flexDirection": "column",
"height": "200px",
"height": "250px",
"left": "40px",
"margin": "auto",
"outline": "none",
Expand Down
34 changes: 34 additions & 0 deletions __tests__/components/__snapshots__/Sidebar.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -1110,6 +1110,40 @@ exports[`Sidebar renders without crashing 1`] = `
</Link>
</Route>
</NavLink>
<NavLink
activeClassName="active"
aria-current="page"
className="navItem migration"
id="migration"
to="/migration"
>
<Route
path="\\\\/migration"
>
<Link
aria-current={null}
className="navItem migration"
id="migration"
replace={false}
to="/migration"
>
<a
aria-current={null}
className="navItem migration"
href="/migration"
id="migration"
onClick={[Function]}
>
<Component>
<svg />
</Component>
<div>
Migration
</div>
</a>
</Link>
</Route>
</NavLink>
</div>
<Connect(withActions(Connect(withActions(Logout))))
className="group logoutToolTipGroup navItem"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ export default class MigrationTransaction extends React.Component<Props> {

render = () => {
const { tx } = this.props

return (
<React.Fragment>
<div className={styles.migrationTxWrapper}>
Expand Down
2 changes: 1 addition & 1 deletion app/components/Migration/History/History.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export default class History extends React.Component<Props, State> {
<div className={styles.container} onScroll={this.handleScroll}>
<div className={styles.header}>
<h3> Migration Summary </h3>
{net === '2' && (
{net === 'TestNet' && (
<code onClick={() => this.props.fetchAdditonalData(true)}>
DEMO
</code>
Expand Down
12 changes: 11 additions & 1 deletion app/modules/migration.js
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,14 @@ export const performMigration = ({
)
}

if (symbol === 'nNEO' && Number(amount) < 1) {
return dispatch(
showErrorNotification({
message: 'Oops... you cannot migrate less than 1 nNEO.',
}),
)
}

const hexRemark = N2.u.str2hexstring(TO_ACCOUNT.address)

const hasBalanceForRequiredFee = (MIN_FEE = 1) => {
Expand Down Expand Up @@ -216,7 +224,9 @@ export const performMigration = ({
} catch (e) {
dispatch(
showErrorNotification({
message: `Oops something went wrong please try again... ${e.message}`,
message: `Oops... Something went wrong please try again. ${
e.message
}`,
}),
)
return reject(e)
Expand Down

0 comments on commit 82c64d9

Please sign in to comment.