diff --git a/js/src/dapps/signaturereg/Header/header.js b/js/src/dapps/signaturereg/Header/header.js index 667e99778..8ced00b9a 100644 --- a/js/src/dapps/signaturereg/Header/header.js +++ b/js/src/dapps/signaturereg/Header/header.js @@ -17,7 +17,7 @@ import React, { Component, PropTypes } from 'react'; import styles from './header.css'; -import blocks from '../../../../assets/images/dapps/blocks-350.jpg'; +import blocks from '~/../assets/images/dapps/blocks-350.jpg'; export default class Header extends Component { static propTypes = { diff --git a/js/src/redux/actions.js b/js/src/redux/actions.js index 4d854f794..1f3c68f28 100644 --- a/js/src/redux/actions.js +++ b/js/src/redux/actions.js @@ -16,14 +16,12 @@ import { newError } from '~/ui/Errors/actions'; -import { setAddressImage } from './providers/imagesActions'; import { openSnackbar, showSnackbar } from './providers/snackbarActions'; import { toggleStatusRefresh } from './providers/statusActions'; import { toggleView } from './providers/settings/actions'; export { newError, - setAddressImage, openSnackbar, showSnackbar, toggleStatusRefresh, diff --git a/js/src/redux/providers/index.js b/js/src/redux/providers/index.js index 437e4fcc8..db71763b4 100644 --- a/js/src/redux/providers/index.js +++ b/js/src/redux/providers/index.js @@ -22,7 +22,6 @@ export Status from './status'; export apiReducer from './apiReducer'; export balancesReducer from './balancesReducer'; export workerReducer from './workerReducer'; -export imagesReducer from './imagesReducer'; export personalReducer from './personalReducer'; export requestsReducer from './requestsReducer'; export settingsReducer from './settings/reducers'; diff --git a/js/src/redux/providers/tokensActions.js b/js/src/redux/providers/tokensActions.js index e20b98832..16b536e71 100644 --- a/js/src/redux/providers/tokensActions.js +++ b/js/src/redux/providers/tokensActions.js @@ -18,10 +18,10 @@ import { uniq } from 'lodash'; import Contracts from '~/contracts'; import { LOG_KEYS, getLogger } from '~/config'; +import { IconCache } from '~/ui'; import { fetchTokenIds, fetchTokenInfo } from '~/util/tokens'; import { updateTokensFilter } from './balancesActions'; -import { setAddressImage } from './imagesActions'; const log = getLogger(LOG_KEYS.Balances); @@ -54,8 +54,9 @@ export function fetchTokens (_tokenIndexes, options = {}) { const tokenIndexes = uniq(_tokenIndexes || []); return (dispatch, getState) => { - const { api, images } = getState(); + const { api } = getState(); const { tokenReg } = Contracts.get(api); + const iconCache = IconCache.get(); return tokenReg.getInstance() .then((tokenRegInstance) => { @@ -69,8 +70,8 @@ export function fetchTokens (_tokenIndexes, options = {}) { const { id, image, address } = token; // dispatch only the changed images - if (images[address] !== image) { - dispatch(setAddressImage(address, image, true)); + if (iconCache.images[address] !== image) { + iconCache.add(address, image, true); } tokens[id] = token; diff --git a/js/src/redux/reducers.js b/js/src/redux/reducers.js index d1878ec66..50d9e84c9 100644 --- a/js/src/redux/reducers.js +++ b/js/src/redux/reducers.js @@ -19,7 +19,7 @@ import { routerReducer } from 'react-router-redux'; import { apiReducer, balancesReducer, - workerReducer, imagesReducer, personalReducer, requestsReducer, + workerReducer, personalReducer, requestsReducer, settingsReducer, signerReducer, statusReducer as nodeStatusReducer, snackbarReducer, tokensReducer, walletReducer } from './providers'; @@ -39,7 +39,6 @@ export default function () { balances: balancesReducer, certifications: certificationsReducer, - images: imagesReducer, nodeStatus: nodeStatusReducer, personal: personalReducer, registry: registryReducer, diff --git a/js/src/redux/util.js b/js/src/redux/util.js index 51dae9bc1..d794c020e 100644 --- a/js/src/redux/util.js +++ b/js/src/redux/util.js @@ -14,10 +14,8 @@ // You should have received a copy of the GNU General Public License // along with Parity. If not, see . -import { hashToImageUrl } from './providers/imagesReducer'; import { withError } from '~/ui/Errors/middleware'; export { - hashToImageUrl, withError }; diff --git a/js/src/shell/Application/Requests/requests.css b/js/src/shell/Application/Requests/requests.css index a5f33c07a..169fdb258 100644 --- a/js/src/shell/Application/Requests/requests.css +++ b/js/src/shell/Application/Requests/requests.css @@ -15,9 +15,9 @@ /* along with Parity. If not, see . */ -$baseColor: 18; +$baseColor: 255; $baseOpacity: 0.95; -$borderColor: rgba($baseColor, $baseColor, $baseColor, 0.25); +$borderColor: rgba(0, 0, 0, 0.15); .requests { align-items: flex-end; diff --git a/js/src/shell/FirstRun/Completed/completed.js b/js/src/shell/FirstRun/Completed/completed.js index 34c48a5cf..0fc5c66e2 100644 --- a/js/src/shell/FirstRun/Completed/completed.js +++ b/js/src/shell/FirstRun/Completed/completed.js @@ -14,28 +14,26 @@ // You should have received a copy of the GNU General Public License // along with Parity. If not, see . -import React, { Component } from 'react'; +import React from 'react'; import { FormattedMessage } from 'react-intl'; import styles from '../firstRun.css'; -export default class Completed extends Component { - render () { - return ( -
-

- -

-

- -

-
- ); - } +export default function Completed () { + return ( +
+

+ +

+

+ +

+
+ ); } diff --git a/js/src/shell/FirstRun/TnC/tnc.js b/js/src/shell/FirstRun/TnC/tnc.js index 51b70f8dc..9b81a8d53 100644 --- a/js/src/shell/FirstRun/TnC/tnc.js +++ b/js/src/shell/FirstRun/TnC/tnc.js @@ -14,168 +14,164 @@ // You should have received a copy of the GNU General Public License // along with Parity. If not, see . -import React, { Component, PropTypes } from 'react'; +import React, { PropTypes } from 'react'; import { FormattedMessage } from 'react-intl'; import { Checkbox } from 'material-ui'; import styles from '../firstRun.css'; -export default class TnC extends Component { - static propTypes = { - hasAccepted: PropTypes.bool.isRequired, - onAccept: PropTypes.func.isRequired - } +export default function TnC ({ hasAccepted, onAccept }) { + return ( +
+

SECURITY WARNINGS

+
    +
  • You are responsible for your own computer security. If your machine is compromised you will lose your ether, access to any contracts and maybe more.
  • +
  • You are responsible for your own actions. If you mess something up or break any laws while using this software, it is your fault, and your fault only.
  • +
- render () { - const { hasAccepted, onAccept } = this.props; +

LEGAL WARNING

+

SHORT VERSION

+

Disclaimer of Liability and Warranties

+
    +
  • The user expressly knows and agrees that the user is using Parity at the user’s sole risk.
  • +
  • The user represents that the user has an adequate understanding of the risks, usage and intricacies of cryptographic tokens and blockchain-based open source software, eth platform and eth.
  • +
  • The user acknowledges and agrees that, to the fullest extent permitted by any applicable law, the disclaimers of liability contained herein apply to any and all damages or injury whatsoever caused by or related to risks of, use of, or inability to use, Parity under any cause or action whatsoever of any kind in any jurisdiction, including, without limitation, actions for breach of warranty, breach of contract or tort (including negligence) and that Eth Core Limited shall be not liable for any indirect, incidental, special, exemplary or consequential damages, including for loss of profits, goodwill or data.
  • +
  • Some jurisdictions do not allow the exclusion of certain warranties or the limitation or exclusion of liability for certain types of damages. Therefore, some of the above limitations in this section may not apply to a user. In particular, nothing in these terms shall affect the statutory rights of any user or exclude injury arising from any wilful misconduct or fraud of Eth Core Limited.
  • +
  • All rights reserved by Ethcore. Licensed to the public under the GPL v3 https://www.gnu.org/licenses/gpl-3.0.txt
  • +
- return ( -
-

SECURITY WARNINGS

-
    -
  • You are responsible for your own computer security. If your machine is compromised you will lose your ether, access to any contracts and maybe more.
  • -
  • You are responsible for your own actions. If you mess something up or break any laws while using this software, it is your fault, and your fault only.
  • -
+

LONG VERSION

+

The following Terms and Conditions (“Terms”) govern the use of Parity Technologies Limited’s open source software product (“Parity”). Prior to any use of the Parity or any of Parity Technologies Limited’s products (“EthCore’s Products”), the user or anyone on whose behalf the software is used for directly or indirectly (“User”) confirms that they understand and expressly agree to all of the Terms. All capitalized terms in this agreement will be given the same effect and meaning as in the Terms. The group of developers and other personnel that is now, or will be, employed by, or contracted with, or affiliated with, Parity Technologies Limited (“EthCore”) is termed the “EthCore Team”.

-

LEGAL WARNING

-

SHORT VERSION

-

Disclaimer of Liability and Warranties

-
    -
  • The user expressly knows and agrees that the user is using Parity at the user’s sole risk.
  • -
  • The user represents that the user has an adequate understanding of the risks, usage and intricacies of cryptographic tokens and blockchain-based open source software, eth platform and eth.
  • -
  • The user acknowledges and agrees that, to the fullest extent permitted by any applicable law, the disclaimers of liability contained herein apply to any and all damages or injury whatsoever caused by or related to risks of, use of, or inability to use, Parity under any cause or action whatsoever of any kind in any jurisdiction, including, without limitation, actions for breach of warranty, breach of contract or tort (including negligence) and that Eth Core Limited shall be not liable for any indirect, incidental, special, exemplary or consequential damages, including for loss of profits, goodwill or data.
  • -
  • Some jurisdictions do not allow the exclusion of certain warranties or the limitation or exclusion of liability for certain types of damages. Therefore, some of the above limitations in this section may not apply to a user. In particular, nothing in these terms shall affect the statutory rights of any user or exclude injury arising from any wilful misconduct or fraud of Eth Core Limited.
  • -
  • All rights reserved by Ethcore. Licensed to the public under the GPL v3 https://www.gnu.org/licenses/gpl-3.0.txt
  • -
+

Acknowledgement of Risks

+

The user acknowledges the following serious risks to any use Parity and expressly agrees not to hold liable EthCore or the EthCore Team should any of these risks occur:

-

LONG VERSION

-

The following Terms and Conditions (“Terms”) govern the use of Parity Technologies Limited’s open source software product (“Parity”). Prior to any use of the Parity or any of Parity Technologies Limited’s products (“EthCore’s Products”), the user or anyone on whose behalf the software is used for directly or indirectly (“User”) confirms that they understand and expressly agree to all of the Terms. All capitalized terms in this agreement will be given the same effect and meaning as in the Terms. The group of developers and other personnel that is now, or will be, employed by, or contracted with, or affiliated with, Parity Technologies Limited (“EthCore”) is termed the “EthCore Team”.

+

Risk of Security Weaknesses in the Parity Core Infrastructure Software

+

Parity rests on open-source software, and although it is professionally developed in line with industry standards (which include external audits of the code base), there is a risk that Ethcore or the Ethcore Team, may have introduce unintentional weaknesses or bugs into the core infrastructural elements of Parity causing the system to lose ETH stored in one or more User accounts or other accounts or lose sums of other valued tokens.

-

Acknowledgement of Risks

-

The user acknowledges the following serious risks to any use Parity and expressly agrees not to hold liable EthCore or the EthCore Team should any of these risks occur:

+

Risk of Weaknesses or Exploitable Breakthroughs in the Field of Cryptography

+

Cryptography is an art, not a science. And the state of the art can advance over time Advances in code cracking, or technical advances such as the development of quantum computers, could present risks to cryptocurrencies and Parity, which could result in the theft or loss of ETH. To the extent possible, EthCore intends to update the protocol underlying Parity to account for any advances in cryptography and to incorporate additional security measures, but it cannot predict the future of cryptography or guaranty that any security updates will be made, timely or successful.

-

Risk of Security Weaknesses in the Parity Core Infrastructure Software

-

Parity rests on open-source software, and although it is professionally developed in line with industry standards (which include external audits of the code base), there is a risk that Ethcore or the Ethcore Team, may have introduce unintentional weaknesses or bugs into the core infrastructural elements of Parity causing the system to lose ETH stored in one or more User accounts or other accounts or lose sums of other valued tokens.

+

Risk of Ether Mining Attacks

+

As with other cryptocurrencies, the blockchain used by Parity is susceptible to mining attacks, including but not limited to double-spend attacks, majority mining power attacks, “selfish-mining” attacks, and race condition attacks. Any successful attacks present a risk to the Ethereum ecosystem, expected proper execution and sequencing of ETH transactions, and expected proper execution and sequencing of contract computations. Despite the efforts of the EthCore and the EthCore Team, known or novel mining attacks may be successful.

-

Risk of Weaknesses or Exploitable Breakthroughs in the Field of Cryptography

-

Cryptography is an art, not a science. And the state of the art can advance over time Advances in code cracking, or technical advances such as the development of quantum computers, could present risks to cryptocurrencies and Parity, which could result in the theft or loss of ETH. To the extent possible, EthCore intends to update the protocol underlying Parity to account for any advances in cryptography and to incorporate additional security measures, but it cannot predict the future of cryptography or guaranty that any security updates will be made, timely or successful.

+

Risk of Rapid Adoption and Insufficiency of Computational Application Processing Power on the Ethereum Network

+

If Parity is rapidly adopted, the demand for transaction processing and distributed application computations could rise dramatically and at a pace that exceeds the rate with which ETH miners can bring online additional mining power. Under such a scenario, the entire Ethereum ecosystem could become destabilized, due to the increased cost of running distributed applications. In turn, this could dampen interest in the Ethereum ecosystem and ETH. Insufficiency of computational resources and an associated rise in the price of ETH could result in businesses being unable to acquire scarce computational resources to run their distributed applications. This would represent revenue losses to businesses or worst case, cause businesses to cease operations because such operations have become uneconomical due to distortions in the crypto-economy.

-

Risk of Ether Mining Attacks

-

As with other cryptocurrencies, the blockchain used by Parity is susceptible to mining attacks, including but not limited to double-spend attacks, majority mining power attacks, “selfish-mining” attacks, and race condition attacks. Any successful attacks present a risk to the Ethereum ecosystem, expected proper execution and sequencing of ETH transactions, and expected proper execution and sequencing of contract computations. Despite the efforts of the EthCore and the EthCore Team, known or novel mining attacks may be successful.

+

Risk of temporary network incoherence

+

We recommend any groups handling large or important transactions to maintain a voluntary 24 hour waiting period on any ether deposited. In case the integrity of the network is at risk due to issues in the clients, we will endeavour to publish patches in a timely fashion to address the issues. We will endeavour to provide solutions within the voluntary 24 hour waiting period.

-

Risk of Rapid Adoption and Insufficiency of Computational Application Processing Power on the Ethereum Network

-

If Parity is rapidly adopted, the demand for transaction processing and distributed application computations could rise dramatically and at a pace that exceeds the rate with which ETH miners can bring online additional mining power. Under such a scenario, the entire Ethereum ecosystem could become destabilized, due to the increased cost of running distributed applications. In turn, this could dampen interest in the Ethereum ecosystem and ETH. Insufficiency of computational resources and an associated rise in the price of ETH could result in businesses being unable to acquire scarce computational resources to run their distributed applications. This would represent revenue losses to businesses or worst case, cause businesses to cease operations because such operations have become uneconomical due to distortions in the crypto-economy.

+

Use of Parity by you

+

You agree to use Party only for purposes that are permitted by (a) these Terms and (b) any applicable law, regulation or generally accepted practices or guidelines in the relevant jurisdictions (including any laws regarding the export of data or software to and from the United Kingdom or other relevant countries).

+

You agree that you will not engage in any activity that interferes with or disrupts Parity’s or EthCore’s Products’ functioning (or the networks which are connected to Parity).

+

Unless you have been specifically permitted to do so in a separate agreement with EthCore, you agree that you will not reproduce, duplicate, copy, sell, trade or resell the EthCore’s Products for any purpose unless than in accordance to the terms of the software licence terms available here: https://www.gnu.org/licenses/gpl-3.0.txt (“Software Licence Terms”).

+

You agree that you are solely responsible for (and that EthCore has no responsibility to you or to any third party for) any breach of your obligations under these terms and for the consequences (including any loss or damage which EthCore may suffer) of any such breach.

-

Risk of temporary network incoherence

-

We recommend any groups handling large or important transactions to maintain a voluntary 24 hour waiting period on any ether deposited. In case the integrity of the network is at risk due to issues in the clients, we will endeavour to publish patches in a timely fashion to address the issues. We will endeavour to provide solutions within the voluntary 24 hour waiting period.

+

Privacy and your personal information

+

You agree to the use of your data (if any is gathered) in accordance with EthCore’s privacy policies: https://parity.io/legal.html. This policy explains how EthCore treats your personal information (if any is gathered), and protects your privacy, when you use EthCore’s Products.

-

Use of Parity by you

-

You agree to use Party only for purposes that are permitted by (a) these Terms and (b) any applicable law, regulation or generally accepted practices or guidelines in the relevant jurisdictions (including any laws regarding the export of data or software to and from the United Kingdom or other relevant countries).

-

You agree that you will not engage in any activity that interferes with or disrupts Parity’s or EthCore’s Products’ functioning (or the networks which are connected to Parity).

-

Unless you have been specifically permitted to do so in a separate agreement with EthCore, you agree that you will not reproduce, duplicate, copy, sell, trade or resell the EthCore’s Products for any purpose unless than in accordance to the terms of the software licence terms available here: https://www.gnu.org/licenses/gpl-3.0.txt (“Software Licence Terms”).

-

You agree that you are solely responsible for (and that EthCore has no responsibility to you or to any third party for) any breach of your obligations under these terms and for the consequences (including any loss or damage which EthCore may suffer) of any such breach.

+

Content in Parity

+

You understand that all information and data (such as smart contracts, data files, written text, computer software, music, audio files or other sounds, photographs, videos or other images) which you may have access to as part of, or through your use of, EthCore’s Product are the sole responsibility of the person from which such content originated. All such information is referred to below as the “Content”.

+

You should be aware that Content presented to you through Parity or EthCore’s Product may be protected by intellectual property rights which are owned by thisrd parties who may provide that Content to EthCore (or by other persons or companies on their behalf). You may not modify, rent, lease, loan, sell, distribute or create derivative works based on this Content (either in whole or in part) unless you have been specifically told that you may do so by Ethcore or by the owners of that Content, in a separate agreement.

+

You understand that by using Parity or EthCore’s Products you may be exposed to Content that you may find offensive, indecent or objectionable and that, in this respect, you use Parity or EthCore’s Products at your own risk.

+

You agree that you are solely responsible for (and that EthCore has no responsibility to you or to any third party for) any Content that you create, transmit or display while using Parity or EthCore’s Products and for the consequences of your actions (including any loss or damage which EthCore may suffer) by doing so.

-

Privacy and your personal information

-

You agree to the use of your data (if any is gathered) in accordance with EthCore’s privacy policies: https://parity.io/legal.html. This policy explains how EthCore treats your personal information (if any is gathered), and protects your privacy, when you use EthCore’s Products.

+

Proprietary rights

+

You acknowledge and agree that EthCore own all legal right, title and interest in and to the Parity and EthCore’s Products, including any intellectual property rights which subsist in Parity and EthCore’s Products (whether those rights happen to be registered or not, and wherever in the world those rights may exist).

+

Unless you have agreed otherwise in writing with EthCore, nothing in the Terms gives you a right to use any of EthCore’s trade names, trade marks, service marks, logos, domain names, and other distinctive brand features.

+

If you have been given an explicit right to use any of these brand features in a separate written agreement with EthCore, then you agree that your use of such features shall be in compliance with that agreement, any applicable provisions of these terms, and EthCore’s brand feature use guidelines as updated from time to time. These guidelines can be viewed online at https://parity.io/press.html.

+

EthCore acknowledges and agrees that it obtains no right, title or interest from you (or your licensors) under these terms in or to any content that you submit, post, transmit or display on, or through, Parity, including any intellectual property rights which subsist in that content (whether those rights happen to be registered or not, and wherever in the world those rights may exist). Unless you have agreed otherwise in writing with EthCore, you agree that you are responsible for protecting and enforcing those rights and that EthCore has no obligation to do so on your behalf.

+

You agree that you shall not remove, obscure, or alter any proprietary rights notices (including copyright and trade mark notices) which may be affixed to or contained within Parity or EthCore’s Products.

+

Unless you have been expressly authorized to do so in writing by EthCore, you agree that in using Parity, you will not use any trade mark, service mark, trade name, logo of any company or organization in a way that is likely or intended to cause confusion about the owner or authorized user of such marks, names or logos.

-

Content in Parity

-

You understand that all information and data (such as smart contracts, data files, written text, computer software, music, audio files or other sounds, photographs, videos or other images) which you may have access to as part of, or through your use of, EthCore’s Product are the sole responsibility of the person from which such content originated. All such information is referred to below as the “Content”.

-

You should be aware that Content presented to you through Parity or EthCore’s Product may be protected by intellectual property rights which are owned by thisrd parties who may provide that Content to EthCore (or by other persons or companies on their behalf). You may not modify, rent, lease, loan, sell, distribute or create derivative works based on this Content (either in whole or in part) unless you have been specifically told that you may do so by Ethcore or by the owners of that Content, in a separate agreement.

-

You understand that by using Parity or EthCore’s Products you may be exposed to Content that you may find offensive, indecent or objectionable and that, in this respect, you use Parity or EthCore’s Products at your own risk.

-

You agree that you are solely responsible for (and that EthCore has no responsibility to you or to any third party for) any Content that you create, transmit or display while using Parity or EthCore’s Products and for the consequences of your actions (including any loss or damage which EthCore may suffer) by doing so.

+

License Restrictions from EthCore

+

You may not (and you may not permit anyone else to) copy, modify, create a derivative work of, reverse engineer, decompile or otherwise attempt to extract the source code of the Parity, EthCore’s Products or any part thereof, unless this is expressly permitted by our Software Licence Terms or required by law, or unless you have been specifically told that you may do so by EthCore, in writing.

+

Unless EthCore has given you specific written permission to do so, you may not assign (or grant a sub-licence of) your rights to use EthCore’s Products, grant a security interest in or over your rights to use the EthCore’s Products, or otherwise transfer any part of your rights to use the EthCore’s Products.

-

Proprietary rights

-

You acknowledge and agree that EthCore own all legal right, title and interest in and to the Parity and EthCore’s Products, including any intellectual property rights which subsist in Parity and EthCore’s Products (whether those rights happen to be registered or not, and wherever in the world those rights may exist).

-

Unless you have agreed otherwise in writing with EthCore, nothing in the Terms gives you a right to use any of EthCore’s trade names, trade marks, service marks, logos, domain names, and other distinctive brand features.

-

If you have been given an explicit right to use any of these brand features in a separate written agreement with EthCore, then you agree that your use of such features shall be in compliance with that agreement, any applicable provisions of these terms, and EthCore’s brand feature use guidelines as updated from time to time. These guidelines can be viewed online at https://parity.io/press.html.

-

EthCore acknowledges and agrees that it obtains no right, title or interest from you (or your licensors) under these terms in or to any content that you submit, post, transmit or display on, or through, Parity, including any intellectual property rights which subsist in that content (whether those rights happen to be registered or not, and wherever in the world those rights may exist). Unless you have agreed otherwise in writing with EthCore, you agree that you are responsible for protecting and enforcing those rights and that EthCore has no obligation to do so on your behalf.

-

You agree that you shall not remove, obscure, or alter any proprietary rights notices (including copyright and trade mark notices) which may be affixed to or contained within Parity or EthCore’s Products.

-

Unless you have been expressly authorized to do so in writing by EthCore, you agree that in using Parity, you will not use any trade mark, service mark, trade name, logo of any company or organization in a way that is likely or intended to cause confusion about the owner or authorized user of such marks, names or logos.

+

Content licence from you

+

You retain copyright and any other rights you already hold in content which you submit, post or display on or through, Parity.

-

License Restrictions from EthCore

-

You may not (and you may not permit anyone else to) copy, modify, create a derivative work of, reverse engineer, decompile or otherwise attempt to extract the source code of the Parity, EthCore’s Products or any part thereof, unless this is expressly permitted by our Software Licence Terms or required by law, or unless you have been specifically told that you may do so by EthCore, in writing.

-

Unless EthCore has given you specific written permission to do so, you may not assign (or grant a sub-licence of) your rights to use EthCore’s Products, grant a security interest in or over your rights to use the EthCore’s Products, or otherwise transfer any part of your rights to use the EthCore’s Products.

+

Ending your relationship with EthCore

+

The Terms will continue to apply until terminated by either you or EthCore as set out below.

+

EthCore may at any time, terminate its legal agreement with you if:

+
    +
  1. you have breached any provision of these Terms (or have acted in manner which clearly shows that you do not intend to, or are unable to comply with the provisions of these terms); or
  2. +
  3. EthCore is required to do so by law (for example, where the provision of EthCore’s Product to you is, or becomes, unlawful); or
  4. +
  5. the partner with whom EthCore offered products or services to you has terminated its relationship with EthCore or ceased to offer products or services to you; or
  6. +
  7. EthCore is transitioning to no longer providing products or services to users in the country in which you are resident or from which you use the service; or
  8. +
  9. the provision of products or services to you by EthCore is, in EthCore’s opinion, no longer commercially viable.
  10. +
  11. When these Terms come to an end, all of the legal rights, obligations and liabilities that you and EthCore have benefited from, been subject to (or which have accrued over time whilst the Terms have been in force) or which are expressed to continue indefinitely, shall be unaffected by this cessation, and the England and Wales jurisdiction choice shall continue to apply to such rights, obligations and liabilities indefinitely.
  12. +
-

Content licence from you

-

You retain copyright and any other rights you already hold in content which you submit, post or display on or through, Parity.

+

ACKNOWLEDGEMENT AND ACCEPTANCE OF ALL RISKS, EXCLUSION OF WARRANTIES

+

THE USER EXPRESSLY KNOWS AND AGREES THAT THE USER IS USING PARITY OR ETHCORE’S PRODUCTS AT THE USER’S SOLE RISK. THE USER REPRESENTS THAT THE USER HAS AN ADEQUATE UNDERSTANDING OF THE RISKS, USAGE AND INTRICACIES OF CRYPTOGRAPHIC TOKENS AND BLOCKCHAIN-BASED OPEN SOURCE SOFTWARE, PARITY.

+

YOU EXPRESSLY UNDERSTAND AND AGREE THAT YOUR USE OF ETHCORE’S PRODUCTS IS AT YOUR SOLE RISK AND THAT ETHCORE’S PRODUCTS ARE PROVIDED "AS IS" AND “AS AVAILABLE.”

+

IN PARTICULAR, ETHCORE, ITS SUBSIDIARIES AND AFFILIATES, AND ITS LICENSORS DO NOT REPRESENT OR WARRANT TO YOU THAT:

+

(A) YOUR USE OF PARITY OR ETHCORE’S PRODUCTS WILL MEET YOUR REQUIREMENTS,

+

(B) YOUR USE OF PARITY OR ETHCORE’S PRODUCTS WILL BE UNINTERRUPTED, TIMELY, SECURE OR FREE FROM ERROR,

+

(C) ANY INFORMATION OBTAINED BY YOU AS A RESULT OF YOUR USE OF PARITY OR ETHCORE’S PRODUCTS WILL BE ACCURATE OR RELIABLE, AND

+

(D) THAT DEFECTS IN THE OPERATION OR FUNCTIONALITY OF ANY SOFTWARE PROVIDED TO YOU AS PART OF ETHCORE’S PRODUCTS WILL BE CORRECTED.

+

ANY MATERIAL DOWNLOADED OR OTHERWISE OBTAINED THROUGH THE USE OF PARITY OR ETHCORE’S PRODUCTS IS DONE AT YOUR OWN DISCRETION AND RISK AND THAT YOU WILL BE SOLELY RESPONSIBLE FOR ANY DAMAGE TO YOUR COMPUTER SYSTEM OR OTHER DEVICE OR LOSS OF DATA OR ECONOMIC LOSS THAT RESULTS FROM THE DOWNLOAD OF ANY SUCH MATERIAL.

+

NO ADVICE OR INFORMATION, WHETHER ORAL OR WRITTEN, OBTAINED BY YOU FROM ETHCORE OR THROUGH OR FROM ETHCORE’S PRODUCTS SHALL CREATE ANY WARRANTY NOT EXPRESSLY STATED IN THE TERMS.

+

ETHCORE FURTHER EXPRESSLY DISCLAIMS ALL WARRANTIES AND CONDITIONS OF ANY KIND, WHETHER EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO THE IMPLIED WARRANTIES AND CONDITIONS OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.

-

Ending your relationship with EthCore

-

The Terms will continue to apply until terminated by either you or EthCore as set out below.

-

EthCore may at any time, terminate its legal agreement with you if:

-
    -
  1. you have breached any provision of these Terms (or have acted in manner which clearly shows that you do not intend to, or are unable to comply with the provisions of these terms); or
  2. -
  3. EthCore is required to do so by law (for example, where the provision of EthCore’s Product to you is, or becomes, unlawful); or
  4. -
  5. the partner with whom EthCore offered products or services to you has terminated its relationship with EthCore or ceased to offer products or services to you; or
  6. -
  7. EthCore is transitioning to no longer providing products or services to users in the country in which you are resident or from which you use the service; or
  8. -
  9. the provision of products or services to you by EthCore is, in EthCore’s opinion, no longer commercially viable.
  10. -
  11. When these Terms come to an end, all of the legal rights, obligations and liabilities that you and EthCore have benefited from, been subject to (or which have accrued over time whilst the Terms have been in force) or which are expressed to continue indefinitely, shall be unaffected by this cessation, and the England and Wales jurisdiction choice shall continue to apply to such rights, obligations and liabilities indefinitely.
  12. -
+

EXCLUSION AND LIMITATION OF LIABILITY

+

THE USER ACKNOWLEDGES AND AGREES THAT, TO THE FULLEST EXTENT PERMITTED BY ANY APPLICABLE LAW, THE DISCLAIMERS AND EXCLUSION OF LIABILITY CONTAINED HEREIN APPLY TO ANY AND ALL DAMAGES OR INJURY WHATSOEVER CAUSED BY OR RELATED TO RISKS OF, USE OF, OR INABILITY TO USE, PARITY UNDER ANY CAUSE OF ACTION WHATSOEVER OF ANY KIND IN ANY JURISDICTION, INCLUDING, WITHOUT LIMITATION, ACTIONS FOR BREACH OF WARRANTY, BREACH OF CONTRACT OR TORT (INCLUDING NEGLIGENCE) AND THAT NEITHER ETHCORE NOR THE ETHCORE TEAM SHALL BE LIABLE FOR ANY INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES, INCLUDING FOR LOSS OF PROFITS, GOODWILL OR DATA.

+

SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OF CERTAIN WARRANTIES OR THE LIMITATION OR EXCLUSION OF LIABILITY FOR CERTAIN TYPES OF DAMAGES. THEREFORE, SOME OF THE ABOVE LIMITATIONS IN THIS SECTION MAY NOT APPLY TO A USER. IN PARTICULAR, NOTHING IN THESE TERMS SHALL AFFECT THE STATUTORY RIGHTS OF ANY USER OR EXCLUDE INJURY ARISING FROM ANY WILLFUL MISCONDUCT OR FRAUD OF ETHCORE.

+

SUBJECT TO ANY LIABILITY WHICH MAY NOT BE EXCLUDED, YOU EXPRESSLY UNDERSTAND AND AGREE THAT ETHCORE, ITS SUBSIDIARIES AND AFFILIATES, AND ITS LICENSORS SHALL NOT BE LIABLE TO YOU FOR:

+

(A) ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL CONSEQUENTIAL OR EXEMPLARY DAMAGES WHICH MAY BE INCURRED BY YOU, HOWEVER CAUSED AND UNDER ANY THEORY OF LIABILITY. THIS SHALL INCLUDE, BUT NOT BE LIMITED TO, ANY LOSS OF PROFIT (WHETHER INCURRED DIRECTLY OR INDIRECTLY), ANY LOSS OF GOODWILL OR BUSINESS REPUTATION, ANY LOSS OF DATA SUFFERED, COST OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR OTHER INTANGIBLE LOSS;

+

(B) ANY LOSS OR DAMAGE WHICH MAY BE INCURRED BY YOU, INCLUDING BUT NOT LIMITED TO LOSS OR DAMAGE AS A RESULT OF:

+

(I) ANY RELIANCE PLACED BY YOU ON THE COMPLETENESS, ACCURACY OR EXISTENCE OF ANY ADVERTISING, OR AS A RESULT OF ANY RELATIONSHIP OR TRANSACTION BETWEEN YOU AND ANY ADVERTISER OR SPONSOR WHOSE ADVERTISING APPEARS ON ETHCORE’S PRODUCTS;

+

(II) ANY CHANGES WHICH ETHCORE MAY MAKE TO ETHCORE’S PRODUCTS, OR FOR ANY PERMANENT OR TEMPORARY CESSATION IN THE PROVISION OF ETHCORE’S PRODUCTS (OR ANY FEATURES WITHIN ETHCORE’S PRODUCTS);

+

(III) THE DELETION OF, CORRUPTION OF, OR FAILURE TO STORE, ANY CONTENT AND OTHER COMMUNICATIONS DATA MAINTAINED OR TRANSMITTED BY OR THROUGH YOUR USE OF ETHCORE’S PRODUCTS;

+

(IV) YOUR FAILURE TO PROVIDE ETHCORE WITH ACCURATE ACCOUNT INFORMATION (IF THIS IS REQUIRED);

+

(V) YOUR FAILURE TO KEEP YOUR PASSWORD OR ACCOUNT DETAILS SECURE AND CONFIDENTIAL;

+

THE LIMITATIONS ON ETHCORE’S LIABILITY TO YOU SHALL APPLY WHETHER OR NOT ETHCORE HAS BEEN ADVISED OF OR SHOULD HAVE BEEN AWARE OF THE POSSIBILITY OF ANY SUCH LOSSES ARISING.

-

ACKNOWLEDGEMENT AND ACCEPTANCE OF ALL RISKS, EXCLUSION OF WARRANTIES

-

THE USER EXPRESSLY KNOWS AND AGREES THAT THE USER IS USING PARITY OR ETHCORE’S PRODUCTS AT THE USER’S SOLE RISK. THE USER REPRESENTS THAT THE USER HAS AN ADEQUATE UNDERSTANDING OF THE RISKS, USAGE AND INTRICACIES OF CRYPTOGRAPHIC TOKENS AND BLOCKCHAIN-BASED OPEN SOURCE SOFTWARE, PARITY.

-

YOU EXPRESSLY UNDERSTAND AND AGREE THAT YOUR USE OF ETHCORE’S PRODUCTS IS AT YOUR SOLE RISK AND THAT ETHCORE’S PRODUCTS ARE PROVIDED "AS IS" AND “AS AVAILABLE.”

-

IN PARTICULAR, ETHCORE, ITS SUBSIDIARIES AND AFFILIATES, AND ITS LICENSORS DO NOT REPRESENT OR WARRANT TO YOU THAT:

-

(A) YOUR USE OF PARITY OR ETHCORE’S PRODUCTS WILL MEET YOUR REQUIREMENTS,

-

(B) YOUR USE OF PARITY OR ETHCORE’S PRODUCTS WILL BE UNINTERRUPTED, TIMELY, SECURE OR FREE FROM ERROR,

-

(C) ANY INFORMATION OBTAINED BY YOU AS A RESULT OF YOUR USE OF PARITY OR ETHCORE’S PRODUCTS WILL BE ACCURATE OR RELIABLE, AND

-

(D) THAT DEFECTS IN THE OPERATION OR FUNCTIONALITY OF ANY SOFTWARE PROVIDED TO YOU AS PART OF ETHCORE’S PRODUCTS WILL BE CORRECTED.

-

ANY MATERIAL DOWNLOADED OR OTHERWISE OBTAINED THROUGH THE USE OF PARITY OR ETHCORE’S PRODUCTS IS DONE AT YOUR OWN DISCRETION AND RISK AND THAT YOU WILL BE SOLELY RESPONSIBLE FOR ANY DAMAGE TO YOUR COMPUTER SYSTEM OR OTHER DEVICE OR LOSS OF DATA OR ECONOMIC LOSS THAT RESULTS FROM THE DOWNLOAD OF ANY SUCH MATERIAL.

-

NO ADVICE OR INFORMATION, WHETHER ORAL OR WRITTEN, OBTAINED BY YOU FROM ETHCORE OR THROUGH OR FROM ETHCORE’S PRODUCTS SHALL CREATE ANY WARRANTY NOT EXPRESSLY STATED IN THE TERMS.

-

ETHCORE FURTHER EXPRESSLY DISCLAIMS ALL WARRANTIES AND CONDITIONS OF ANY KIND, WHETHER EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO THE IMPLIED WARRANTIES AND CONDITIONS OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.

+

Copyright and trade mark policies

+

It is EthCore’s policy to respond to notices of alleged copyright infringement that comply with applicable international intellectual property law (including, in the United States, the Digital Millennium Copyright Act) and if EthCore is put on notice and it is under EthCore’s control and terminating the accounts of repeat infringers.

-

EXCLUSION AND LIMITATION OF LIABILITY

-

THE USER ACKNOWLEDGES AND AGREES THAT, TO THE FULLEST EXTENT PERMITTED BY ANY APPLICABLE LAW, THE DISCLAIMERS AND EXCLUSION OF LIABILITY CONTAINED HEREIN APPLY TO ANY AND ALL DAMAGES OR INJURY WHATSOEVER CAUSED BY OR RELATED TO RISKS OF, USE OF, OR INABILITY TO USE, PARITY UNDER ANY CAUSE OF ACTION WHATSOEVER OF ANY KIND IN ANY JURISDICTION, INCLUDING, WITHOUT LIMITATION, ACTIONS FOR BREACH OF WARRANTY, BREACH OF CONTRACT OR TORT (INCLUDING NEGLIGENCE) AND THAT NEITHER ETHCORE NOR THE ETHCORE TEAM SHALL BE LIABLE FOR ANY INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES, INCLUDING FOR LOSS OF PROFITS, GOODWILL OR DATA.

-

SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OF CERTAIN WARRANTIES OR THE LIMITATION OR EXCLUSION OF LIABILITY FOR CERTAIN TYPES OF DAMAGES. THEREFORE, SOME OF THE ABOVE LIMITATIONS IN THIS SECTION MAY NOT APPLY TO A USER. IN PARTICULAR, NOTHING IN THESE TERMS SHALL AFFECT THE STATUTORY RIGHTS OF ANY USER OR EXCLUDE INJURY ARISING FROM ANY WILLFUL MISCONDUCT OR FRAUD OF ETHCORE.

-

SUBJECT TO ANY LIABILITY WHICH MAY NOT BE EXCLUDED, YOU EXPRESSLY UNDERSTAND AND AGREE THAT ETHCORE, ITS SUBSIDIARIES AND AFFILIATES, AND ITS LICENSORS SHALL NOT BE LIABLE TO YOU FOR:

-

(A) ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL CONSEQUENTIAL OR EXEMPLARY DAMAGES WHICH MAY BE INCURRED BY YOU, HOWEVER CAUSED AND UNDER ANY THEORY OF LIABILITY. THIS SHALL INCLUDE, BUT NOT BE LIMITED TO, ANY LOSS OF PROFIT (WHETHER INCURRED DIRECTLY OR INDIRECTLY), ANY LOSS OF GOODWILL OR BUSINESS REPUTATION, ANY LOSS OF DATA SUFFERED, COST OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR OTHER INTANGIBLE LOSS;

-

(B) ANY LOSS OR DAMAGE WHICH MAY BE INCURRED BY YOU, INCLUDING BUT NOT LIMITED TO LOSS OR DAMAGE AS A RESULT OF:

-

(I) ANY RELIANCE PLACED BY YOU ON THE COMPLETENESS, ACCURACY OR EXISTENCE OF ANY ADVERTISING, OR AS A RESULT OF ANY RELATIONSHIP OR TRANSACTION BETWEEN YOU AND ANY ADVERTISER OR SPONSOR WHOSE ADVERTISING APPEARS ON ETHCORE’S PRODUCTS;

-

(II) ANY CHANGES WHICH ETHCORE MAY MAKE TO ETHCORE’S PRODUCTS, OR FOR ANY PERMANENT OR TEMPORARY CESSATION IN THE PROVISION OF ETHCORE’S PRODUCTS (OR ANY FEATURES WITHIN ETHCORE’S PRODUCTS);

-

(III) THE DELETION OF, CORRUPTION OF, OR FAILURE TO STORE, ANY CONTENT AND OTHER COMMUNICATIONS DATA MAINTAINED OR TRANSMITTED BY OR THROUGH YOUR USE OF ETHCORE’S PRODUCTS;

-

(IV) YOUR FAILURE TO PROVIDE ETHCORE WITH ACCURATE ACCOUNT INFORMATION (IF THIS IS REQUIRED);

-

(V) YOUR FAILURE TO KEEP YOUR PASSWORD OR ACCOUNT DETAILS SECURE AND CONFIDENTIAL;

-

THE LIMITATIONS ON ETHCORE’S LIABILITY TO YOU SHALL APPLY WHETHER OR NOT ETHCORE HAS BEEN ADVISED OF OR SHOULD HAVE BEEN AWARE OF THE POSSIBILITY OF ANY SUCH LOSSES ARISING.

+

Other content

+

Services provided may include hyperlinks to other web sites, smart contracts or content or resources. EthCore may have no control over any web sites or resources which are provided by companies or persons other than EthCore.

+

You acknowledge and agree that EthCore is not responsible for the availability of any such external sites or resources, and does not endorse any advertising, products or other materials on or available from such web sites or resources.

+

You acknowledge and agree that EthCore is not liable for any loss or damage which may be incurred by you as a result of the availability of those external sites or resources, or as a result of any reliance placed by you on the completeness, accuracy or existence of any advertising, products or other materials on, or available from, such web sites or resources.

-

Copyright and trade mark policies

-

It is EthCore’s policy to respond to notices of alleged copyright infringement that comply with applicable international intellectual property law (including, in the United States, the Digital Millennium Copyright Act) and if EthCore is put on notice and it is under EthCore’s control and terminating the accounts of repeat infringers.

+

Changes to the Terms

+

EthCore may make changes to these from time to time. When these changes are made, EthCore will make a new copy of these terms available at https://parity.io/legal.html and any new terms will be made available to you from within, or through, the affected EthCore’s Product.

+

You understand and agree that if you use Parity or EthCore’s Products after the date on which the Terms have changed, EthCore will treat your use as acceptance of the updated terms.

-

Other content

-

Services provided may include hyperlinks to other web sites, smart contracts or content or resources. EthCore may have no control over any web sites or resources which are provided by companies or persons other than EthCore.

-

You acknowledge and agree that EthCore is not responsible for the availability of any such external sites or resources, and does not endorse any advertising, products or other materials on or available from such web sites or resources.

-

You acknowledge and agree that EthCore is not liable for any loss or damage which may be incurred by you as a result of the availability of those external sites or resources, or as a result of any reliance placed by you on the completeness, accuracy or existence of any advertising, products or other materials on, or available from, such web sites or resources.

+

General legal terms

+

Sometimes when you use Parity or EthCore’s Products, you may (as a result of, or in connection with your use of these products) use a service or download a piece of software, or smart contract, or purchase goods, which are provided by another person or company. Your use of these other services, software, smart contract or goods may be subject to separate terms between you and the company or person concerned. If so, these Terms do not affect your legal relationship with these other companies or individuals.

+

These Terms constitute the whole legal agreement between you and EthCore and govern your use of Parity and EthCore’s Products (but excluding any products or services which EthCore may provide to you under a separate written agreement), and completely replace any prior agreements between you and EthCore in relation to Parity and EthCore’s Products.

+

You agree that EthCore may provide you with notices, including those regarding changes to the Terms, by postings on the affected EthCore’s Product.

+

You agree that if EthCore does not exercise or enforce any legal right or remedy which is contained in these Terms (or which EthCore has the benefit of under any applicable law), this will not be taken to be a formal waiver of EthCore’s rights and that those rights or remedies will still be available to EthCore.

+

If any court of law, having the jurisdiction to decide on this matter, rules that any provision of these Terms is invalid, then that provision will be removed from the Terms without affecting the rest of the Terms. The remaining provisions of the Terms will continue to be valid and enforceable.

+

You acknowledge and agree that each member of the group of companies of which EthCore is the parent shall be third party beneficiaries to these Terms and that such other companies shall be entitled to directly enforce, and rely upon, any provision of the Terms which confers a benefit on (or rights in favor of) them. Other than this, no other person or company shall be third party beneficiaries to these Terms.

+

These Terms, and your relationship with EthCore under these Terms, shall be governed by the laws of England and Wales, United Kingdom without regard to its conflict of laws provisions. You and EthCore agree to submit to the exclusive jurisdiction of the courts located within England, United Kingdom to resolve any legal matter arising from these Terms (subject to the Dispute Resolution clause below). Notwithstanding this, you agree that EthCore shall still be allowed to apply for injunctive remedies (or an equivalent type of urgent legal relief) in any jurisdiction.

-

Changes to the Terms

-

EthCore may make changes to these from time to time. When these changes are made, EthCore will make a new copy of these terms available at https://parity.io/legal.html and any new terms will be made available to you from within, or through, the affected EthCore’s Product.

-

You understand and agree that if you use Parity or EthCore’s Products after the date on which the Terms have changed, EthCore will treat your use as acceptance of the updated terms.

+

Dispute Resolution

+

All disputes or claims arising out of, relating to, or in connection with the Terms, the breach thereof, or use of Parity shall be finally settled under the Rules of Arbitration of the International Chamber of Commerce by one or more arbitrators appointed in accordance with said Rules. All claims between the parties relating to these Terms that are capable of being resolved by arbitration, whether sounding in contract, tort, or otherwise, shall be submitted to ICC arbitration. Prior to commencing arbitration, the parties have a duty to negotiate in good faith and attempt to resolve their dispute in a manner other than by submission to ICC arbitration. The arbitration panel shall consist of one arbitrator only, unless the ICC Court of Arbitration determines that the dispute is such as to warrant three arbitrators. If the Court determines that one arbitrator is sufficient, then such arbitrator shall be a UK resident. If the Court determines that three arbitrators are necessary, then each party shall have 30 days to nominate an arbitrator of its choice - in the case of the Claimant, measured from receipt of notification of the ICC Court’s decision to have three arbitrators; in the case of Respondent, measured from receipt of notification of Claimant’s nomination. All nominations must be UK residents. If a party fails to nominate an arbitrator, the Court will do so. The Court shall also appoint the chairman. All arbitrators shall be and remain “independent” of the parties involved in the arbitration. The place of arbitration shall be England, United Kingdom. The language of the arbitration shall be English. In deciding the merits of the dispute, the tribunal shall apply the laws of England and Wales and any discovery shall be limited and shall not involve any depositions or any other examinations outside of a formal hearing. The tribunal shall not assume the powers of amiable compositeur or decide the case ex aequo et bono. In the final award, the tribunal shall fix the costs of the arbitration and decide which of the parties shall bear such costs in what proportion. Every award shall be binding on the parties. The parties undertake to carry out the award without delay and waive their right to any form of recourse against the award in so far as such waiver can validly be made.

-

General legal terms

-

Sometimes when you use Parity or EthCore’s Products, you may (as a result of, or in connection with your use of these products) use a service or download a piece of software, or smart contract, or purchase goods, which are provided by another person or company. Your use of these other services, software, smart contract or goods may be subject to separate terms between you and the company or person concerned. If so, these Terms do not affect your legal relationship with these other companies or individuals.

-

These Terms constitute the whole legal agreement between you and EthCore and govern your use of Parity and EthCore’s Products (but excluding any products or services which EthCore may provide to you under a separate written agreement), and completely replace any prior agreements between you and EthCore in relation to Parity and EthCore’s Products.

-

You agree that EthCore may provide you with notices, including those regarding changes to the Terms, by postings on the affected EthCore’s Product.

-

You agree that if EthCore does not exercise or enforce any legal right or remedy which is contained in these Terms (or which EthCore has the benefit of under any applicable law), this will not be taken to be a formal waiver of EthCore’s rights and that those rights or remedies will still be available to EthCore.

-

If any court of law, having the jurisdiction to decide on this matter, rules that any provision of these Terms is invalid, then that provision will be removed from the Terms without affecting the rest of the Terms. The remaining provisions of the Terms will continue to be valid and enforceable.

-

You acknowledge and agree that each member of the group of companies of which EthCore is the parent shall be third party beneficiaries to these Terms and that such other companies shall be entitled to directly enforce, and rely upon, any provision of the Terms which confers a benefit on (or rights in favor of) them. Other than this, no other person or company shall be third party beneficiaries to these Terms.

-

These Terms, and your relationship with EthCore under these Terms, shall be governed by the laws of England and Wales, United Kingdom without regard to its conflict of laws provisions. You and EthCore agree to submit to the exclusive jurisdiction of the courts located within England, United Kingdom to resolve any legal matter arising from these Terms (subject to the Dispute Resolution clause below). Notwithstanding this, you agree that EthCore shall still be allowed to apply for injunctive remedies (or an equivalent type of urgent legal relief) in any jurisdiction.

+

Additional Terms for Enterprise Use

+

If you are a business entity, then the individual accepting on behalf of the entity (for the avoidance of doubt, for business entities, in these Terms, "you" means the entity) represents and warrants that he or she has the authority to act on your behalf, that you represent that you are duly authorized to do business in the country or countries where you operate, and that your employees, officers, representatives, and other agents accessing EthCore’s Products are duly authorized to access Parity and to legally bind you to these Terms.

+

Subject to these Terms and subject to the Software Licence Terms, EthCore grants you a non-exclusive, non-transferable licence to install and use Parity solely on machines intended for use by your employees, officers, representatives, and agents in connection with your business entity, and provided that their use of EthCore will be subject to these Terms and EthCore’s Products software licence terms.

-

Dispute Resolution

-

All disputes or claims arising out of, relating to, or in connection with the Terms, the breach thereof, or use of Parity shall be finally settled under the Rules of Arbitration of the International Chamber of Commerce by one or more arbitrators appointed in accordance with said Rules. All claims between the parties relating to these Terms that are capable of being resolved by arbitration, whether sounding in contract, tort, or otherwise, shall be submitted to ICC arbitration. Prior to commencing arbitration, the parties have a duty to negotiate in good faith and attempt to resolve their dispute in a manner other than by submission to ICC arbitration. The arbitration panel shall consist of one arbitrator only, unless the ICC Court of Arbitration determines that the dispute is such as to warrant three arbitrators. If the Court determines that one arbitrator is sufficient, then such arbitrator shall be a UK resident. If the Court determines that three arbitrators are necessary, then each party shall have 30 days to nominate an arbitrator of its choice - in the case of the Claimant, measured from receipt of notification of the ICC Court’s decision to have three arbitrators; in the case of Respondent, measured from receipt of notification of Claimant’s nomination. All nominations must be UK residents. If a party fails to nominate an arbitrator, the Court will do so. The Court shall also appoint the chairman. All arbitrators shall be and remain “independent” of the parties involved in the arbitration. The place of arbitration shall be England, United Kingdom. The language of the arbitration shall be English. In deciding the merits of the dispute, the tribunal shall apply the laws of England and Wales and any discovery shall be limited and shall not involve any depositions or any other examinations outside of a formal hearing. The tribunal shall not assume the powers of amiable compositeur or decide the case ex aequo et bono. In the final award, the tribunal shall fix the costs of the arbitration and decide which of the parties shall bear such costs in what proportion. Every award shall be binding on the parties. The parties undertake to carry out the award without delay and waive their right to any form of recourse against the award in so far as such waiver can validly be made.

- -

Additional Terms for Enterprise Use

-

If you are a business entity, then the individual accepting on behalf of the entity (for the avoidance of doubt, for business entities, in these Terms, "you" means the entity) represents and warrants that he or she has the authority to act on your behalf, that you represent that you are duly authorized to do business in the country or countries where you operate, and that your employees, officers, representatives, and other agents accessing EthCore’s Products are duly authorized to access Parity and to legally bind you to these Terms.

-

Subject to these Terms and subject to the Software Licence Terms, EthCore grants you a non-exclusive, non-transferable licence to install and use Parity solely on machines intended for use by your employees, officers, representatives, and agents in connection with your business entity, and provided that their use of EthCore will be subject to these Terms and EthCore’s Products software licence terms.

- - - } - checked={ hasAccepted } - onCheck={ onAccept } - /> -
- ); - } + + } + checked={ hasAccepted } + onCheck={ onAccept } + /> +
+ ); } + +TnC.propTypes = { + hasAccepted: PropTypes.bool.isRequired, + onAccept: PropTypes.func.isRequired +}; diff --git a/js/src/shell/FirstRun/Welcome/welcome.js b/js/src/shell/FirstRun/Welcome/welcome.js index df438d112..e7e1c9f85 100644 --- a/js/src/shell/FirstRun/Welcome/welcome.js +++ b/js/src/shell/FirstRun/Welcome/welcome.js @@ -14,7 +14,7 @@ // You should have received a copy of the GNU General Public License // along with Parity. If not, see . -import React, { Component } from 'react'; +import React from 'react'; import { FormattedMessage } from 'react-intl'; import imagesEthcore from '~/../assets/images/parity-logo-white.svg'; @@ -28,56 +28,54 @@ const LOGO_STYLE = { margin: '0 1.5em' }; -export default class FirstRun extends Component { - render () { - return ( -
- Ethcore Ltd. + Ethcore Ltd. +

+ -

- -

-

- -

-
-
    -
  • - -
  • -
  • - -
  • -
  • - -
  • -
-
-

- -

+

+

+ +

+
+
    +
  • + +
  • +
  • + +
  • +
  • + +
  • +
- ); - } +

+ +

+
+ ); } diff --git a/js/src/shell/ParityBar/parityBar.css b/js/src/shell/ParityBar/parityBar.css index 59bdd639e..4ef2ef4a2 100644 --- a/js/src/shell/ParityBar/parityBar.css +++ b/js/src/shell/ParityBar/parityBar.css @@ -51,7 +51,7 @@ $modalZ: 10001; right: 0; bottom: 0; left: 0; - background: rgba(255, 255, 255, 0.5); + background: rgba(0, 0, 0, 0.35); z-index: $overlayZ; user-select: none; } diff --git a/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormConfirm/transactionPendingFormConfirm.css b/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormConfirm/transactionPendingFormConfirm.css index f915d1274..3e5b86544 100644 --- a/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormConfirm/transactionPendingFormConfirm.css +++ b/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormConfirm/transactionPendingFormConfirm.css @@ -25,10 +25,7 @@ } .signerIcon { - width: 24px; - height: 24px; vertical-align: middle; - margin-left: 12px; } .passwordHint { diff --git a/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormConfirm/transactionPendingFormConfirm.js b/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormConfirm/transactionPendingFormConfirm.js index 8d4e4a9cc..7e2f74fe4 100644 --- a/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormConfirm/transactionPendingFormConfirm.js +++ b/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormConfirm/transactionPendingFormConfirm.js @@ -15,13 +15,12 @@ // along with Parity. If not, see . import keycode from 'keycode'; -import RaisedButton from 'material-ui/RaisedButton'; import React, { Component, PropTypes } from 'react'; import ReactDOM from 'react-dom'; import { FormattedMessage } from 'react-intl'; import ReactTooltip from 'react-tooltip'; -import { Form, Input, IdentityIcon, QrCode, QrScan } from '~/ui'; +import { Button, Form, Input, IdentityIcon, QrCode, QrScan } from '~/ui'; import { generateTxQr, generateDataQr } from '~/util/qrscan'; import styles from './transactionPendingFormConfirm.css'; @@ -131,7 +130,7 @@ export default class TransactionPendingFormConfirm extends Component { data-place='bottom' data-tip > - } label={ confirmText } - onTouchTap={ this.onConfirm } - primary + onClick={ this.onConfirm } /> ) diff --git a/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormReject/transactionPendingFormReject.js b/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormReject/transactionPendingFormReject.js index 3f5ba943f..4b04ba4e6 100644 --- a/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormReject/transactionPendingFormReject.js +++ b/js/src/shell/Signer/components/TransactionPendingForm/TransactionPendingFormReject/transactionPendingFormReject.js @@ -17,7 +17,7 @@ import React, { Component, PropTypes } from 'react'; import { FormattedMessage } from 'react-intl'; -import RaisedButton from 'material-ui/RaisedButton'; +import { Button } from '~/ui'; import styles from './transactionPendingFormReject.css'; @@ -45,8 +45,8 @@ export default class TransactionPendingFormReject extends Component { /> - diff --git a/js/src/ui/DappCard/dappCard.css b/js/src/ui/DappCard/dappCard.css index 36292011b..9b8705201 100644 --- a/js/src/ui/DappCard/dappCard.css +++ b/js/src/ui/DappCard/dappCard.css @@ -15,6 +15,8 @@ /* along with Parity. If not, see . */ +@import '../_colors.css'; + .container { height: 100%; position: relative; @@ -41,7 +43,7 @@ } .titleLink { - color: rgb(0, 151, 167); + color: $linkColor; } .author { diff --git a/js/src/ui/DappIcon/dappIcon.js b/js/src/ui/DappIcon/dappIcon.js index 891f45405..3f43a3efe 100644 --- a/js/src/ui/DappIcon/dappIcon.js +++ b/js/src/ui/DappIcon/dappIcon.js @@ -14,36 +14,33 @@ // You should have received a copy of the GNU General Public License // along with Parity. If not, see . -import React, { Component, PropTypes } from 'react'; +import React, { PropTypes } from 'react'; import styles from './dappIcon.css'; -export default class DappIcon extends Component { - static contextTypes = { - api: PropTypes.object.isRequired - }; +export default function DappIcon ({ app, className, small }, context) { + const { dappsUrl } = context.api; - static propTypes = { - app: PropTypes.object.isRequired, - className: PropTypes.string, - small: PropTypes.bool - }; - - render () { - const { dappsUrl } = this.context.api; - const { app, className, small } = this.props; - - return ( - - ); - } + return ( + + ); } + +DappIcon.contextTypes = { + api: PropTypes.object.isRequired +}; + +DappIcon.propTypes = { + app: PropTypes.object.isRequired, + className: PropTypes.string, + small: PropTypes.bool +}; diff --git a/js/src/ui/DappLink/dappLink.css b/js/src/ui/DappLink/dappLink.css index c126e7017..b6216351e 100644 --- a/js/src/ui/DappLink/dappLink.css +++ b/js/src/ui/DappLink/dappLink.css @@ -15,7 +15,9 @@ /* along with Parity. If not, see . */ +@import '../_colors.css'; + .link { - color: rgb(0, 151, 167); + color: $linkColor; cursor: pointer; } diff --git a/js/src/redux/providers/imagesReducer.js b/js/src/ui/IconCache/iconCache.js similarity index 56% rename from js/src/redux/providers/imagesReducer.js rename to js/src/ui/IconCache/iconCache.js index 9413f7be6..d1e66ff8d 100644 --- a/js/src/redux/providers/imagesReducer.js +++ b/js/src/ui/IconCache/iconCache.js @@ -14,30 +14,41 @@ // You should have received a copy of the GNU General Public License // along with Parity. If not, see . -import { handleActions } from 'redux-actions'; +import { action, observable } from 'mobx'; import { bytesToHex } from '@parity/api/util/format'; const ZERO = '0x0000000000000000000000000000000000000000000000000000000000000000'; +const API_PATH = '/api/content/'; -const initialState = { - images: {} -}; +let instance = null; -export function hashToImageUrl (hashArray) { - const hash = hashArray ? bytesToHex(hashArray) : ZERO; +export default class IconCache { + @observable images = {}; - return hash === ZERO ? null : `/api/content/${hash.substr(2)}`; -} - -export default handleActions({ - setAddressImage (state, action) { - const { address, hashArray, converted } = action; - - const image = converted ? hashArray : hashToImageUrl(hashArray); - - return Object.assign({}, state, { - [address]: image + @action add (address, imageOrHash, isImage = false) { + this.images = Object.assign({}, this.images, { + [address]: isImage + ? imageOrHash + : IconCache.hashToImage(imageOrHash) }); } -}, initialState); + + static hashToImage (_hash) { + const hash = _hash + ? bytesToHex(_hash) + : ZERO; + + return hash === ZERO + ? null + : `${API_PATH}${hash.substr(2)}`; + } + + static get (force = false) { + if (!instance || force) { + instance = new IconCache(); + } + + return instance; + } +} diff --git a/js/src/redux/providers/imagesActions.js b/js/src/ui/IconCache/index.js similarity index 81% rename from js/src/redux/providers/imagesActions.js rename to js/src/ui/IconCache/index.js index a620a31ba..342fd1768 100644 --- a/js/src/redux/providers/imagesActions.js +++ b/js/src/ui/IconCache/index.js @@ -14,11 +14,4 @@ // You should have received a copy of the GNU General Public License // along with Parity. If not, see . -export function setAddressImage (address, hashArray, converted = false) { - return { - type: 'setAddressImage', - address, - hashArray, - converted - }; -} +export default from './iconCache'; diff --git a/js/src/ui/IdentityIcon/identityIcon.css b/js/src/ui/IdentityIcon/identityIcon.css index b995b5aad..4c9a2dba9 100644 --- a/js/src/ui/IdentityIcon/identityIcon.css +++ b/js/src/ui/IdentityIcon/identityIcon.css @@ -52,7 +52,7 @@ .button { display: inline; - width: 24px; - height: 24px; - margin: 6px 0.25em 0 12px; + width: 1em; + height: 1em; + margin: 0 0.25em; } diff --git a/js/src/ui/IdentityIcon/identityIcon.js b/js/src/ui/IdentityIcon/identityIcon.js index a1843261c..2efe1d7ab 100644 --- a/js/src/ui/IdentityIcon/identityIcon.js +++ b/js/src/ui/IdentityIcon/identityIcon.js @@ -15,16 +15,18 @@ // along with Parity. If not, see . import React, { Component, PropTypes } from 'react'; -import { connect } from 'react-redux'; import { createIdentityImg } from '@parity/api/util/identity'; import { isNullAddress } from '~/util/validation'; -import { CancelIcon, ContractIcon } from '../Icons'; +import IconCache from '~/ui/IconCache'; +import { CancelIcon, ContractIcon } from '~/ui/Icons'; import styles from './identityIcon.css'; -class IdentityIcon extends Component { +const iconCache = IconCache.get(); + +export default class IdentityIcon extends Component { static contextTypes = { api: PropTypes.object.isRequired } @@ -35,7 +37,6 @@ class IdentityIcon extends Component { center: PropTypes.bool, className: PropTypes.string, disabled: PropTypes.bool, - images: PropTypes.object.isRequired, inline: PropTypes.bool, padded: PropTypes.bool, tiny: PropTypes.bool @@ -46,26 +47,23 @@ class IdentityIcon extends Component { } componentDidMount () { - this.updateIcon(this.props.address, this.props.images); + this.updateIcon(this.props.address); } componentWillReceiveProps (newProps) { - const sameAddress = newProps.address === this.props.address; - const sameImages = Object.keys(newProps.images).length === Object.keys(this.props.images).length; - - if (sameAddress && sameImages) { + if (newProps.address === this.props.address) { return; } - this.updateIcon(newProps.address, newProps.images); + this.updateIcon(newProps.address); } - updateIcon (_address, images) { + updateIcon (_address) { const { api } = this.context; const { button, inline, tiny } = this.props; - if (images[_address]) { - this.setState({ iconsrc: `${api.dappsUrl}${images[_address]}` }); + if (iconCache[_address]) { + this.setState({ iconsrc: `${api.dappsUrl}${iconCache[_address]}` }); return; } @@ -145,14 +143,3 @@ class IdentityIcon extends Component { ); } } - -function mapStateToProps (state) { - const { images } = state; - - return { images }; -} - -export default connect( - mapStateToProps, - null -)(IdentityIcon); diff --git a/js/src/ui/IdentityIcon/identityIcon.spec.js b/js/src/ui/IdentityIcon/identityIcon.spec.js index f6887d7d6..985cde26e 100644 --- a/js/src/ui/IdentityIcon/identityIcon.spec.js +++ b/js/src/ui/IdentityIcon/identityIcon.spec.js @@ -16,15 +16,16 @@ import { shallow } from 'enzyme'; import React from 'react'; -import sinon from 'sinon'; import IdentityIcon from './'; +import IconCache from '../IconCache'; const ADDRESS0 = '0x0000000000000000000000000000000000000000'; const ADDRESS1 = '0x0123456789012345678901234567890123456789'; const ADDRESS2 = '0x9876543210987654321098765432109876543210'; let component; +let iconCache; let instance; function createApi () { @@ -33,20 +34,6 @@ function createApi () { }; } -function createRedux () { - return { - dispatch: sinon.stub(), - subscribe: sinon.stub(), - getState: () => { - return { - images: { - [ADDRESS2]: 'reduxImage' - } - }; - } - }; -} - function render (props = {}) { if (props && props.address === undefined) { props.address = ADDRESS1; @@ -54,12 +41,15 @@ function render (props = {}) { component = shallow( , - { context: { store: createRedux() } } - ).find('IdentityIcon').shallow({ context: { api: createApi() } }); + { context: { api: createApi() } } + ); instance = component.instance(); instance.componentDidMount(); + iconCache = IconCache.get(true); + iconCache.add(ADDRESS2, 'cachedImage'); + return component; } @@ -76,11 +66,11 @@ describe('ui/IdentityIcon', () => { expect(img.props().src).to.equal('test-createIdentityImg'); }); - it('renders an with redux source when available', () => { + it('renders an with cache source when available', () => { const img = render({ address: ADDRESS2 }).find('img'); expect(img).to.have.length(1); - expect(img.props().src).to.equal('dappsUrl/reduxImage'); + expect(img.props().src).to.equal('dappsUrl/cachedImage'); }); it('renders an with no address specified', () => { diff --git a/js/src/ui/IdentityName/identityName.js b/js/src/ui/IdentityName/identityName.js index b9a0ba045..eccb65c61 100644 --- a/js/src/ui/IdentityName/identityName.js +++ b/js/src/ui/IdentityName/identityName.js @@ -14,7 +14,7 @@ // You should have received a copy of the GNU General Public License // along with Parity. If not, see . -import React, { Component, PropTypes } from 'react'; +import React, { PropTypes } from 'react'; import { FormattedMessage } from 'react-intl'; import { connect } from 'react-redux'; @@ -34,46 +34,42 @@ const defaultNameNull = ( /> ); -export class IdentityName extends Component { - static propTypes = { - account: PropTypes.object, - address: PropTypes.string, - className: PropTypes.string, - empty: PropTypes.bool, - name: PropTypes.string, - shorten: PropTypes.bool, - unknown: PropTypes.bool +export function IdentityName ({ account, address, className, empty, name, shorten, unknown }) { + if (!account && empty) { + return null; } - render () { - const { account, address, className, empty, name, shorten, unknown } = this.props; - - if (!account && empty) { - return null; - } - - const nullName = isNullAddress(address) ? defaultNameNull : null; - const addressFallback = nullName || (shorten ? () : address); - const fallback = unknown ? defaultName : addressFallback; - const isUuid = account && account.name === account.uuid; - const displayName = (name && name.toUpperCase().trim()) || - (account && !isUuid - ? account.name.toUpperCase().trim() - : fallback - ); - - return ( - - { - displayName && displayName.length - ? displayName - : fallback - } - + const nullName = isNullAddress(address) ? defaultNameNull : null; + const addressFallback = nullName || (shorten ? () : address); + const fallback = unknown ? defaultName : addressFallback; + const isUuid = account && account.name === account.uuid; + const displayName = (name && name.toUpperCase().trim()) || + (account && !isUuid + ? account.name.toUpperCase().trim() + : fallback ); - } + + return ( + + { + displayName && displayName.length + ? displayName + : fallback + } + + ); } +IdentityName.propTypes = { + account: PropTypes.object, + address: PropTypes.string, + className: PropTypes.string, + empty: PropTypes.bool, + name: PropTypes.string, + shorten: PropTypes.bool, + unknown: PropTypes.bool +}; + function mapStateToProps (state, props) { const { address } = props; const { personal, tokens } = state; diff --git a/js/src/ui/SelectionList/selectionList.css b/js/src/ui/SelectionList/selectionList.css index b6e6b05f9..d1e05bf37 100644 --- a/js/src/ui/SelectionList/selectionList.css +++ b/js/src/ui/SelectionList/selectionList.css @@ -15,6 +15,8 @@ /* along with Parity. If not, see . */ +@import '../_colors.css'; + .item { cursor: pointer; display: flex; @@ -69,7 +71,7 @@ filter: none; &::after { - background: rgb(0, 151, 167); + background: $linkColor; content: ''; height: 4px; left: 0; diff --git a/js/src/ui/TokenImage/tokenImage.js b/js/src/ui/TokenImage/tokenImage.js index 86142ea86..301006fb8 100644 --- a/js/src/ui/TokenImage/tokenImage.js +++ b/js/src/ui/TokenImage/tokenImage.js @@ -15,13 +15,15 @@ // along with Parity. If not, see . import React, { PropTypes } from 'react'; -import { connect } from 'react-redux'; import unknownImage from '~/../assets/images/contracts/unknown-64x64.png'; +import IconCache from '~/ui/IconCache'; -function TokenImage ({ image, token }, context) { +const iconCache = IconCache.get(); + +export default function TokenImage ({ token }, context) { const { api } = context; - const imageurl = token.image || image; + const imageurl = token.image || iconCache.images[token.address]; let imagesrc = unknownImage; if (imageurl) { @@ -45,24 +47,8 @@ TokenImage.contextTypes = { }; TokenImage.propTypes = { - image: PropTypes.string, token: PropTypes.shape({ image: PropTypes.string, address: PropTypes.string }).isRequired }; - -function mapStateToProps (iniState) { - const { images } = iniState; - - return (_, props) => { - const { token } = props; - - return { image: images[token.address] }; - }; -} - -export default connect( - mapStateToProps, - null -)(TokenImage); diff --git a/js/src/ui/_colors.css b/js/src/ui/_colors.css new file mode 100644 index 000000000..80cb3d0ab --- /dev/null +++ b/js/src/ui/_colors.css @@ -0,0 +1,18 @@ +/* Copyright 2015-2017 Parity Technologies (UK) Ltd. +/* This file is part of Parity. +/* +/* Parity is free software: you can redistribute it and/or modify +/* it under the terms of the GNU General Public License as published by +/* the Free Software Foundation, either version 3 of the License, or +/* (at your option) any later version. +/* +/* Parity is distributed in the hope that it will be useful, +/* but WITHOUT ANY WARRANTY; without even the implied warranty of +/* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +/* GNU General Public License for more details. +/* +/* You should have received a copy of the GNU General Public License +/* along with Parity. If not, see . +*/ + +$linkColor: #4183c4; diff --git a/js/src/ui/index.js b/js/src/ui/index.js index 65ffc4065..aa88d94ec 100644 --- a/js/src/ui/index.js +++ b/js/src/ui/index.js @@ -36,6 +36,7 @@ export Features, { FEATURES, FeaturesStore } from './Features'; export Form, { AddressSelect, DappUrlInput, FileSelect, FormWrap, Input, InputAddress, InputAddressSelect, InputChip, InputDate, InputInline, InputTime, Label, RadioButtons, Select, TypedInput, VaultSelect } from './Form'; export GasPriceEditor from './GasPriceEditor'; export GasPriceSelector from './GasPriceSelector'; +export IconCache from './IconCache'; export Icons from './Icons'; export IdentityIcon from './IdentityIcon'; export IdentityName from './IdentityName'; diff --git a/js/src/util/dapps.js b/js/src/util/dapps.js index d85d4d522..a89db51a7 100644 --- a/js/src/util/dapps.js +++ b/js/src/util/dapps.js @@ -20,10 +20,9 @@ import { pick, range, uniq } from 'lodash'; import { bytesToHex } from '@parity/api/util/format'; import Contracts from '~/contracts'; -import { hashToImageUrl } from '~/redux/util'; - import builtinJson from '~/config/dappsBuiltin.json'; import viewsJson from '~/config/dappsViews.json'; +import { IconCache } from '~/ui'; const builtinApps = [].concat( viewsJson.map((app) => { @@ -105,7 +104,7 @@ export function fetchBuiltinApps (api) { app.type = app.isView ? 'view' : 'builtin'; - app.image = hashToImageUrl(imageIds[index]); + app.image = IconCache.hashToImage(imageIds[index]); return app; }); }) @@ -169,7 +168,7 @@ export function fetchRegistryApp (api, dappReg, appId) { .then(([ imageId, contentId, manifestId ]) => { const app = { id: appId, - image: hashToImageUrl(imageId), + image: IconCache.hashToImage(imageId), contentHash: bytesToHex(contentId).substr(2), manifestHash: bytesToHex(manifestId).substr(2), type: 'network', diff --git a/js/src/util/tokens.js b/js/src/util/tokens.js index 737214345..70dd8dbbe 100644 --- a/js/src/util/tokens.js +++ b/js/src/util/tokens.js @@ -20,7 +20,7 @@ import BigNumber from 'bignumber.js'; import { sha3 } from '@parity/api/util/sha3'; import imagesEthereum from '~/../assets/images/contracts/ethereum-black-64x64.png'; -import { hashToImageUrl } from '~/redux/util'; +import { IconCache } from '~/ui'; const BALANCEOF_SIGNATURE = sha3('balanceOf(address)'); const ADDRESS_PADDING = range(24).map(() => '0').join(''); @@ -57,7 +57,7 @@ export function fetchTokenInfo (api, tokenregInstace, tokenIndex) { const token = { format: format.toString(), index: tokenIndex, - image: hashToImageUrl(image), + image: IconCache.hashToImage(image), id: sha3(address + tokenIndex).slice(0, 10), address, name, diff --git a/js/src/views/Account/account.test.js b/js/src/views/Account/account.test.js index c88e0e156..b341a7534 100644 --- a/js/src/views/Account/account.test.js +++ b/js/src/views/Account/account.test.js @@ -34,7 +34,6 @@ function createRedux () { [ADDRESS]: {} } }, - images: {}, nodeStatus: { netVersion: '1', traceMode: false