Merge branch 'feature/use-wallet-api-for-contract-origination' into 'dev'

Update Ligo IDE to use new Wallet API

See merge request ligolang/ligo!654
This commit is contained in:
Jev Björsell 2020-06-03 14:31:01 +00:00
commit 2032485b60
3 changed files with 81 additions and 13 deletions

View File

@ -6,8 +6,9 @@
"@fortawesome/fontawesome-svg-core": "^1.2.25", "@fortawesome/fontawesome-svg-core": "^1.2.25",
"@fortawesome/free-solid-svg-icons": "^5.11.2", "@fortawesome/free-solid-svg-icons": "^5.11.2",
"@fortawesome/react-fontawesome": "^0.1.6", "@fortawesome/react-fontawesome": "^0.1.6",
"@taquito/taquito": "^6.1.0-beta.0", "@taquito/taquito": "^6.3.0-wallet.4",
"@taquito/tezbridge-signer": "^6.1.0-beta.0", "@taquito/tezbridge-signer": "^6.3.0-wallet.4",
"@taquito/tezbridge-wallet": "^6.3.0-wallet.4",
"@types/jest": "24.0.18", "@types/jest": "24.0.18",
"@types/node": "12.7.12", "@types/node": "12.7.12",
"@types/react": "16.9.5", "@types/react": "16.9.5",

View File

@ -1,5 +1,5 @@
import { Tezos } from '@taquito/taquito'; import { Tezos } from '@taquito/taquito';
import { TezBridgeSigner } from '@taquito/tezbridge-signer'; import { TezBridgeWallet } from '@taquito/tezbridge-wallet';
import { Dispatch } from 'redux'; import { Dispatch } from 'redux';
import { compileContract, compileStorage, deploy, getErrorMessage } from '../../services/api'; import { compileContract, compileStorage, deploy, getErrorMessage } from '../../services/api';
@ -12,7 +12,7 @@ import { CancellableAction } from './cancellable';
Tezos.setProvider({ Tezos.setProvider({
rpc: 'https://api.tez.ie/rpc/carthagenet', rpc: 'https://api.tez.ie/rpc/carthagenet',
signer: new TezBridgeSigner() wallet: new TezBridgeWallet()
}); });
export class DeployAction extends CancellableAction { export class DeployAction extends CancellableAction {
@ -45,12 +45,12 @@ export class DeployAction extends CancellableAction {
return; return;
} }
dispatch({ ...new UpdateLoadingAction('Waiting for TezBridge signer...') }); dispatch({ ...new UpdateLoadingAction('Waiting for TezBridge wallet...') });
const op = await Tezos.contract.originate({ const op = await Tezos.wallet.originate({
code: JSON.parse(michelsonCode.result), code: JSON.parse(michelsonCode.result),
init: JSON.parse(michelsonStorage.result) init: JSON.parse(michelsonStorage.result)
}); }).send();
if (this.isCancelled()) { if (this.isCancelled()) {
return; return;
@ -61,7 +61,7 @@ export class DeployAction extends CancellableAction {
}); });
return { return {
address: (await op.contract()).address, address: (await op.contract()).address,
storage: michelsonStorage storage: michelsonStorage.result
}; };
} }

View File

@ -1503,6 +1503,13 @@
dependencies: dependencies:
xhr2-cookies "^1.1.0" xhr2-cookies "^1.1.0"
"@taquito/http-utils@^6.3.0-wallet.4":
version "6.3.0-wallet.4"
resolved "https://registry.yarnpkg.com/@taquito/http-utils/-/http-utils-6.3.0-wallet.4.tgz#3b6ffd2794feaea9d5c9010af5574661d7fb5139"
integrity sha512-dLZZyqFK7ohp02BJ9dxQO5Wih7ifRET658hshhi9GWNg9bEYmDNuBG1qL4e2FUyJPblllZQPOoEA9ayZ66HOlg==
dependencies:
xhr2-cookies "^1.1.0"
"@taquito/michelson-encoder@^6.1.0-beta.0": "@taquito/michelson-encoder@^6.1.0-beta.0":
version "6.1.0-beta.0" version "6.1.0-beta.0"
resolved "https://registry.yarnpkg.com/@taquito/michelson-encoder/-/michelson-encoder-6.1.0-beta.0.tgz#8f8d143a69814723550776dfe9c024a2196cbb57" resolved "https://registry.yarnpkg.com/@taquito/michelson-encoder/-/michelson-encoder-6.1.0-beta.0.tgz#8f8d143a69814723550776dfe9c024a2196cbb57"
@ -1512,6 +1519,15 @@
bignumber.js "^9.0.0" bignumber.js "^9.0.0"
fast-json-stable-stringify "^2.1.0" fast-json-stable-stringify "^2.1.0"
"@taquito/michelson-encoder@^6.3.0-wallet.4":
version "6.3.0-wallet.4"
resolved "https://registry.yarnpkg.com/@taquito/michelson-encoder/-/michelson-encoder-6.3.0-wallet.4.tgz#c0480ada4f6a52783d9cdbb41f07a490c7ac1586"
integrity sha512-JwLBmtDiwof3hAWOeCe0O84lNl4W8ufUnYH1it178F17q/gKKAxKefTv0lQ3P2a0oVYtv1j6OIOHUIHmgjX3Ew==
dependencies:
"@taquito/utils" "^6.3.0-wallet.4"
bignumber.js "^9.0.0"
fast-json-stable-stringify "^2.1.0"
"@taquito/rpc@^6.1.0-beta.0": "@taquito/rpc@^6.1.0-beta.0":
version "6.1.0-beta.0" version "6.1.0-beta.0"
resolved "https://registry.yarnpkg.com/@taquito/rpc/-/rpc-6.1.0-beta.0.tgz#e3247607a578f778f5168a356567dc86c0a3b809" resolved "https://registry.yarnpkg.com/@taquito/rpc/-/rpc-6.1.0-beta.0.tgz#e3247607a578f778f5168a356567dc86c0a3b809"
@ -1521,6 +1537,15 @@
bignumber.js "^9.0.0" bignumber.js "^9.0.0"
lodash "^4.17.15" lodash "^4.17.15"
"@taquito/rpc@^6.3.0-wallet.4":
version "6.3.0-wallet.4"
resolved "https://registry.yarnpkg.com/@taquito/rpc/-/rpc-6.3.0-wallet.4.tgz#98c5ce98146eeddb982ce0596ff49c43a18e24ba"
integrity sha512-OYVxOeRE8q1zeY8IKbXeUk8B+SL9wMY7xsHLNkUJOMXC7BA9isSLvkCzily3s+iw1kF2j6pDRurD7VtD/KdAcA==
dependencies:
"@taquito/http-utils" "^6.3.0-wallet.4"
bignumber.js "^9.0.0"
lodash "^4.17.15"
"@taquito/signer@^6.1.0-beta.0": "@taquito/signer@^6.1.0-beta.0":
version "6.1.0-beta.0" version "6.1.0-beta.0"
resolved "https://registry.yarnpkg.com/@taquito/signer/-/signer-6.1.0-beta.0.tgz#05d3994347de460f0f1722a99ac0bdc95528d3cf" resolved "https://registry.yarnpkg.com/@taquito/signer/-/signer-6.1.0-beta.0.tgz#05d3994347de460f0f1722a99ac0bdc95528d3cf"
@ -1534,6 +1559,19 @@
pbkdf2 "^3.0.17" pbkdf2 "^3.0.17"
typedarray-to-buffer "^3.1.5" typedarray-to-buffer "^3.1.5"
"@taquito/signer@^6.3.0-wallet.4":
version "6.3.0-wallet.4"
resolved "https://registry.yarnpkg.com/@taquito/signer/-/signer-6.3.0-wallet.4.tgz#da4c7c8fed82aa09698abd5f37af68cf600e3ef3"
integrity sha512-r8nMhm0ORjc3nu0KKd8wieeCqBd/sJATj7BbSueAMyTMqeahB5ce4Cmr/J48x0EuwuUdkqP3q05mWeklcoyoRw==
dependencies:
"@taquito/utils" "^6.3.0-wallet.4"
bignumber.js "^9.0.0"
bip39 "^3.0.2"
elliptic "^6.5.1"
libsodium-wrappers "^0.7.5"
pbkdf2 "^3.0.17"
typedarray-to-buffer "^3.1.5"
"@taquito/taquito@^6.1.0-beta.0": "@taquito/taquito@^6.1.0-beta.0":
version "6.1.0-beta.0" version "6.1.0-beta.0"
resolved "https://registry.yarnpkg.com/@taquito/taquito/-/taquito-6.1.0-beta.0.tgz#f7497979170019f888b32f290012ce1005cd0c7a" resolved "https://registry.yarnpkg.com/@taquito/taquito/-/taquito-6.1.0-beta.0.tgz#f7497979170019f888b32f290012ce1005cd0c7a"
@ -1546,14 +1584,34 @@
bignumber.js "^9.0.0" bignumber.js "^9.0.0"
rxjs "^6.5.3" rxjs "^6.5.3"
"@taquito/tezbridge-signer@^6.1.0-beta.0": "@taquito/taquito@^6.3.0-wallet.4":
version "6.1.0-beta.0" version "6.3.0-wallet.4"
resolved "https://registry.yarnpkg.com/@taquito/tezbridge-signer/-/tezbridge-signer-6.1.0-beta.0.tgz#adaad917091e946d6284ce4fd74f314b9c52c8d3" resolved "https://registry.yarnpkg.com/@taquito/taquito/-/taquito-6.3.0-wallet.4.tgz#6673b5784ed80abbfde9c1b93bbf9b030eecc86c"
integrity sha512-diVlbdJTqrw23xZ86E3NqfKDLrJSdg6sNQ1tZkQUvinEwYUGCUTTu7+kDM9vOM/loEH0vfyUUBE+cf27uJ7j1w== integrity sha512-mYHML0R41hq0iIAHTTUylEUbew0dman9vNxBa3hIfwbsPkBuW2G9EdMQWbZta1hJU9w3IHuBsmM7QHFyl+FTIA==
dependencies: dependencies:
"@taquito/utils" "^6.1.0-beta.0" "@taquito/http-utils" "^6.3.0-wallet.4"
"@taquito/michelson-encoder" "^6.3.0-wallet.4"
"@taquito/rpc" "^6.3.0-wallet.4"
"@taquito/signer" "^6.3.0-wallet.4"
"@taquito/utils" "^6.3.0-wallet.4"
bignumber.js "^9.0.0"
rxjs "^6.5.3"
"@taquito/tezbridge-signer@^6.3.0-wallet.4":
version "6.3.0-wallet.4"
resolved "https://registry.yarnpkg.com/@taquito/tezbridge-signer/-/tezbridge-signer-6.3.0-wallet.4.tgz#6c4adfbaa4261c7dc8f9e128cde0a408ce97ed11"
integrity sha512-PBEwEwv9mBDSSnlw2qHQj44ZJIyRAmqgusVVv6wAlkIDk2Nqbh1MWBNesUdmpJ0lXKLa0D3ii2+28jSVEBqbfQ==
dependencies:
"@taquito/utils" "^6.3.0-wallet.4"
typedarray-to-buffer "^3.1.5" typedarray-to-buffer "^3.1.5"
"@taquito/tezbridge-wallet@^6.3.0-wallet.4":
version "6.3.0-wallet.4"
resolved "https://registry.yarnpkg.com/@taquito/tezbridge-wallet/-/tezbridge-wallet-6.3.0-wallet.4.tgz#826effe66f09bd7844ed36ce792eb7e2805f9a23"
integrity sha512-73uvCv21EDrCMPXKK2sMh9Olor/HYff7UtVs0kGyrEC0Gc+jMVPqGrUMSQytsAS5Q8h1hovpRSG6Pe/mBKF9dg==
dependencies:
"@taquito/taquito" "^6.3.0-wallet.4"
"@taquito/utils@^6.1.0-beta.0": "@taquito/utils@^6.1.0-beta.0":
version "6.1.0-beta.0" version "6.1.0-beta.0"
resolved "https://registry.yarnpkg.com/@taquito/utils/-/utils-6.1.0-beta.0.tgz#11e8887379738cae10d7a696c7b6cc0cec9eeab0" resolved "https://registry.yarnpkg.com/@taquito/utils/-/utils-6.1.0-beta.0.tgz#11e8887379738cae10d7a696c7b6cc0cec9eeab0"
@ -1563,6 +1621,15 @@
bs58check "^2.1.2" bs58check "^2.1.2"
buffer "^5.2.1" buffer "^5.2.1"
"@taquito/utils@^6.3.0-wallet.4":
version "6.3.0-wallet.4"
resolved "https://registry.yarnpkg.com/@taquito/utils/-/utils-6.3.0-wallet.4.tgz#3aba5b1c287dafb56cfc787782d881714a381c24"
integrity sha512-EcczTwWsVdAQxdOkrzWq9YnOxFdeLxIrN/qCIDTLbj+dw48hGT44gLBFMX2Ru9EAQrLJzNPAFsnE4V1LRF7VbQ==
dependencies:
blakejs "^1.1.0"
bs58check "^2.1.2"
buffer "^5.2.1"
"@tootallnate/once@1": "@tootallnate/once@1":
version "1.1.2" version "1.1.2"
resolved "https://registry.yarnpkg.com/@tootallnate/once/-/once-1.1.2.tgz#ccb91445360179a04e7fe6aff78c00ffc1eeaf82" resolved "https://registry.yarnpkg.com/@tootallnate/once/-/once-1.1.2.tgz#ccb91445360179a04e7fe6aff78c00ffc1eeaf82"