Merge pull request #176 from status-im/packaging_improvements

Packaging improvements
This commit is contained in:
Iuri Matias 2018-10-29 12:05:52 +01:00 committed by GitHub
commit 896debefbd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
43 changed files with 411 additions and 21273 deletions

View File

@ -1,44 +0,0 @@
engines:
eslint:
enabled: true
checks:
no-eval:
enabled: false
no-process-exit:
enabled: false
global-require:
enabled: false
guard-for-in:
enabled: false
for-direction:
enabled: false
getter-return:
enabled: false
no-buffer-constructor:
enabled: false
padding-line-between-statements:
enabled: false
semi-style:
enabled: false
switch-colon-spacing:
enabled: false
array-bracket-newline:
enabled: false
ratings:
paths:
- "lib/**/*"
exclude_paths:
- "test/"
- "old_test/"
- "templates/boilerplate/"
- "templates/demo/"
- "js/"
- "test_apps/test_app/"
- "test_apps/contracts_app/"
- "docs/"
checks:
similar-code:
enabled: false
method-lines:
config:
threshold: 35

View File

@ -1 +0,0 @@
lib/modules/webserver/backend/assets/*

42
.gitignore vendored
View File

@ -1,34 +1,12 @@
node_modules
TODO
NOTES
.node-xmlhttprequest-sync-*
templates/demo/dist/
templates/demo/.embark/development/
templates/demo/config/production/password
templates/demo/node_modules/
templates/boilerplate/dist/
docs/_build
docs/utils/__pycache_
test/cli_shim/.cid
test_apps/test_app/dist/
test_apps/test_app/.embark/development/
test_apps/test_app/config/production/password
test_apps/test_app/node_modules/
test_apps/test_app/chains.json
test_apps/contracts_app/build/
test_apps/contracts_app/.embark/development/
test_apps/contracts_app/config/production/password
test_apps/contracts_app/node_modules/
test_apps/contracts_app/chains.json
test_apps/embark_demo/dist/
test_apps/embark_demo/.embark/development/
test_apps/embark_demo/config/production/password
test_apps/embark_demo/node_modules/
test_apps/embark_demo/chains.json
.idea
.vscode
.eslintrc.json
.embark/
NOTES
npm-debug.log
.node-xmlhttprequest-sync-*
.tern-port
.vscode
NOTES
TODO
dist
embark-*.tgz
node_modules
npm-debug.log
package
src/test/cli_shim/.cid

View File

@ -1,2 +1,11 @@
test_apps/
test/
.editorconfig
.eslintrc.json
.github
.travis.yml
.vscode
CONTRIBUTING.md
appveyor.yml
header.png
logo.png
test
test_apps

9
.nycrc
View File

@ -1,9 +0,0 @@
{
"reporter": [
"lcov",
"text-summary"
],
"include": [
"lib/**/*.js"
]
}

View File

@ -0,0 +1 @@
GENERATE_SOURCEMAP=false

7
embark-ui/.npmignore Normal file
View File

@ -0,0 +1,7 @@
.env
.env.*
config
node_modules
public
scripts
src

View File

@ -540,7 +540,7 @@
},
"axios": {
"version": "0.18.0",
"resolved": "http://registry.npmjs.org/axios/-/axios-0.18.0.tgz",
"resolved": "https://registry.npmjs.org/axios/-/axios-0.18.0.tgz",
"integrity": "sha1-MtU+SFHv3AoRmTts0AB4nXDAUQI=",
"requires": {
"follow-redirects": "^1.3.0",
@ -821,7 +821,7 @@
},
"babel-plugin-istanbul": {
"version": "4.1.6",
"resolved": "http://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-4.1.6.tgz",
"resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-4.1.6.tgz",
"integrity": "sha512-PWP9FQ1AhZhS01T/4qLSKoHGY/xvkZdVBGlKM/HuxxS3+sC66HhTNR7+MpbO/so/cz/wY94MeSWJuP1hXIPfwQ==",
"requires": {
"babel-plugin-syntax-object-rest-spread": "^6.13.0",
@ -867,7 +867,7 @@
},
"babel-plugin-syntax-object-rest-spread": {
"version": "6.13.0",
"resolved": "http://registry.npmjs.org/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz",
"resolved": "https://registry.npmjs.org/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz",
"integrity": "sha1-/WU28rzhODb/o6VFjEkDpZe7O/U="
},
"babel-plugin-syntax-trailing-function-commas": {
@ -1463,7 +1463,7 @@
},
"bl": {
"version": "1.2.2",
"resolved": "http://registry.npmjs.org/bl/-/bl-1.2.2.tgz",
"resolved": "https://registry.npmjs.org/bl/-/bl-1.2.2.tgz",
"integrity": "sha512-e8tQYnZodmebYDWGH7KMRvtzKXaJHx3BbilrgZCfvyLUYdKpK1t5PSPmpkny/SgiTSCnjfLW7v5rlONXVFkQEA==",
"requires": {
"readable-stream": "^2.3.5",
@ -1634,7 +1634,7 @@
},
"browserify-aes": {
"version": "1.2.0",
"resolved": "http://registry.npmjs.org/browserify-aes/-/browserify-aes-1.2.0.tgz",
"resolved": "https://registry.npmjs.org/browserify-aes/-/browserify-aes-1.2.0.tgz",
"integrity": "sha512-+7CHXqGuspUn/Sl5aO7Ea0xWGAtETPXNSAjHo48JfLdPWcMng33Xe4znFvQweqc/uzk5zSOI3H52CYnjCfb5hA==",
"requires": {
"buffer-xor": "^1.0.3",
@ -1668,7 +1668,7 @@
},
"browserify-rsa": {
"version": "4.0.1",
"resolved": "http://registry.npmjs.org/browserify-rsa/-/browserify-rsa-4.0.1.tgz",
"resolved": "https://registry.npmjs.org/browserify-rsa/-/browserify-rsa-4.0.1.tgz",
"integrity": "sha1-IeCr+vbyApzy+vsTNWenAdQTVSQ=",
"requires": {
"bn.js": "^4.1.0",
@ -1724,7 +1724,7 @@
},
"buffer": {
"version": "4.9.1",
"resolved": "http://registry.npmjs.org/buffer/-/buffer-4.9.1.tgz",
"resolved": "https://registry.npmjs.org/buffer/-/buffer-4.9.1.tgz",
"integrity": "sha1-bRu2AbB6TvztlwlBMgkwJ8lbwpg=",
"requires": {
"base64-js": "^1.0.2",
@ -2438,7 +2438,7 @@
},
"create-hash": {
"version": "1.2.0",
"resolved": "http://registry.npmjs.org/create-hash/-/create-hash-1.2.0.tgz",
"resolved": "https://registry.npmjs.org/create-hash/-/create-hash-1.2.0.tgz",
"integrity": "sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg==",
"requires": {
"cipher-base": "^1.0.1",
@ -2450,7 +2450,7 @@
},
"create-hmac": {
"version": "1.1.7",
"resolved": "http://registry.npmjs.org/create-hmac/-/create-hmac-1.1.7.tgz",
"resolved": "https://registry.npmjs.org/create-hmac/-/create-hmac-1.1.7.tgz",
"integrity": "sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg==",
"requires": {
"cipher-base": "^1.0.3",
@ -2851,12 +2851,12 @@
"dependencies": {
"file-type": {
"version": "3.9.0",
"resolved": "http://registry.npmjs.org/file-type/-/file-type-3.9.0.tgz",
"resolved": "https://registry.npmjs.org/file-type/-/file-type-3.9.0.tgz",
"integrity": "sha1-JXoHg4TR24CHvESdEH1SpSZyuek="
},
"get-stream": {
"version": "2.3.1",
"resolved": "http://registry.npmjs.org/get-stream/-/get-stream-2.3.1.tgz",
"resolved": "https://registry.npmjs.org/get-stream/-/get-stream-2.3.1.tgz",
"integrity": "sha1-Xzj5PzRgCWZu4BUKBUFn+Rvdld4=",
"requires": {
"object-assign": "^4.0.1",
@ -3018,7 +3018,7 @@
},
"diffie-hellman": {
"version": "5.0.3",
"resolved": "http://registry.npmjs.org/diffie-hellman/-/diffie-hellman-5.0.3.tgz",
"resolved": "https://registry.npmjs.org/diffie-hellman/-/diffie-hellman-5.0.3.tgz",
"integrity": "sha512-kqag/Nl+f3GwyK25fhUMYj81BUOrZ9IuJsjIcDE5icNM9FJHAVm3VcUDxdLPoQtTuUylWm6ZIknYJwwaPxsUzg==",
"requires": {
"bn.js": "^4.1.0",
@ -3152,7 +3152,7 @@
},
"duplexer": {
"version": "0.1.1",
"resolved": "http://registry.npmjs.org/duplexer/-/duplexer-0.1.1.tgz",
"resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.1.tgz",
"integrity": "sha1-rOb/gIwc5mtX0ev5eXessCM0z8E="
},
"duplexer3": {
@ -3588,7 +3588,7 @@
},
"load-json-file": {
"version": "2.0.0",
"resolved": "http://registry.npmjs.org/load-json-file/-/load-json-file-2.0.0.tgz",
"resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-2.0.0.tgz",
"integrity": "sha1-eUfkIUmvgNaWy/eXvKq8/h/inKg=",
"requires": {
"graceful-fs": "^4.1.2",
@ -3814,7 +3814,7 @@
},
"uuid": {
"version": "2.0.1",
"resolved": "http://registry.npmjs.org/uuid/-/uuid-2.0.1.tgz",
"resolved": "https://registry.npmjs.org/uuid/-/uuid-2.0.1.tgz",
"integrity": "sha1-wqMN7bPlNdcsz4LjQ5QaULqFM6w="
}
}
@ -3866,7 +3866,7 @@
},
"events": {
"version": "1.1.1",
"resolved": "http://registry.npmjs.org/events/-/events-1.1.1.tgz",
"resolved": "https://registry.npmjs.org/events/-/events-1.1.1.tgz",
"integrity": "sha1-nr23Y1rQmccNzEwqH1AEKI6L2SQ="
},
"eventsource": {
@ -4001,7 +4001,7 @@
},
"express": {
"version": "4.16.3",
"resolved": "http://registry.npmjs.org/express/-/express-4.16.3.tgz",
"resolved": "https://registry.npmjs.org/express/-/express-4.16.3.tgz",
"integrity": "sha1-avilAjUNsyRuzEvs9rWjTSL37VM=",
"requires": {
"accepts": "~1.3.5",
@ -4316,7 +4316,7 @@
},
"finalhandler": {
"version": "1.1.1",
"resolved": "http://registry.npmjs.org/finalhandler/-/finalhandler-1.1.1.tgz",
"resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.1.tgz",
"integrity": "sha512-Y1GUDo39ez4aHAw7MysnUD5JzYX+WaIj8I57kO3aEPT1fFRL4sr7mjei97FgnwhAyyzRYmQZaTHb2+9uZ1dPtg==",
"requires": {
"debug": "2.6.9",
@ -4500,7 +4500,7 @@
},
"jsonfile": {
"version": "2.4.0",
"resolved": "http://registry.npmjs.org/jsonfile/-/jsonfile-2.4.0.tgz",
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-2.4.0.tgz",
"integrity": "sha1-NzaitCi4e72gzIO1P6PWM6NcKug=",
"requires": {
"graceful-fs": "^4.1.6"
@ -4548,11 +4548,13 @@
},
"balanced-match": {
"version": "1.0.0",
"bundled": true
"bundled": true,
"optional": true
},
"brace-expansion": {
"version": "1.1.11",
"bundled": true,
"optional": true,
"requires": {
"balanced-match": "^1.0.0",
"concat-map": "0.0.1"
@ -4569,7 +4571,8 @@
},
"concat-map": {
"version": "0.0.1",
"bundled": true
"bundled": true,
"optional": true
},
"console-control-strings": {
"version": "1.1.0",
@ -4698,6 +4701,7 @@
"minimatch": {
"version": "3.0.4",
"bundled": true,
"optional": true,
"requires": {
"brace-expansion": "^1.1.7"
}
@ -5051,7 +5055,7 @@
},
"get-stream": {
"version": "3.0.0",
"resolved": "http://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz",
"resolved": "https://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz",
"integrity": "sha1-jpQ9E1jcN1VQVOy+LtsFqhdO3hQ="
},
"get-value": {
@ -5561,7 +5565,7 @@
},
"http-errors": {
"version": "1.6.3",
"resolved": "http://registry.npmjs.org/http-errors/-/http-errors-1.6.3.tgz",
"resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.6.3.tgz",
"integrity": "sha1-i1VoC7S+KDoLW/TqLjhYC+HZMg0=",
"requires": {
"depd": "~1.1.2",
@ -5844,7 +5848,7 @@
},
"inline-style-prefixer": {
"version": "2.0.5",
"resolved": "http://registry.npmjs.org/inline-style-prefixer/-/inline-style-prefixer-2.0.5.tgz",
"resolved": "https://registry.npmjs.org/inline-style-prefixer/-/inline-style-prefixer-2.0.5.tgz",
"integrity": "sha1-wVPH6I/YT+9cYC6VqBaLJ3BnH+c=",
"requires": {
"bowser": "^1.0.0",
@ -5976,7 +5980,7 @@
},
"is-builtin-module": {
"version": "1.0.0",
"resolved": "http://registry.npmjs.org/is-builtin-module/-/is-builtin-module-1.0.0.tgz",
"resolved": "https://registry.npmjs.org/is-builtin-module/-/is-builtin-module-1.0.0.tgz",
"integrity": "sha1-VAVy0096wxGfj3bDDLwbHgN6/74=",
"requires": {
"builtin-modules": "^1.0.0"
@ -6133,7 +6137,7 @@
},
"is-obj": {
"version": "1.0.1",
"resolved": "http://registry.npmjs.org/is-obj/-/is-obj-1.0.1.tgz",
"resolved": "https://registry.npmjs.org/is-obj/-/is-obj-1.0.1.tgz",
"integrity": "sha1-PkcprB9f3gJc19g6iW2rn09n2w8="
},
"is-object": {
@ -7076,7 +7080,7 @@
},
"json5": {
"version": "0.5.1",
"resolved": "http://registry.npmjs.org/json5/-/json5-0.5.1.tgz",
"resolved": "https://registry.npmjs.org/json5/-/json5-0.5.1.tgz",
"integrity": "sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE="
},
"jsonfile": {
@ -7172,7 +7176,7 @@
},
"load-json-file": {
"version": "1.1.0",
"resolved": "http://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz",
"resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz",
"integrity": "sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA=",
"requires": {
"graceful-fs": "^4.1.2",
@ -7641,7 +7645,7 @@
},
"minimist": {
"version": "0.0.8",
"resolved": "http://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz",
"resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz",
"integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0="
},
"mixin-deep": {
@ -7665,7 +7669,7 @@
},
"mkdirp": {
"version": "0.5.1",
"resolved": "http://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz",
"resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz",
"integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=",
"requires": {
"minimist": "0.0.8"
@ -7829,7 +7833,7 @@
"dependencies": {
"semver": {
"version": "5.3.0",
"resolved": "http://registry.npmjs.org/semver/-/semver-5.3.0.tgz",
"resolved": "https://registry.npmjs.org/semver/-/semver-5.3.0.tgz",
"integrity": "sha1-myzl094C0XxgEq0yaqa00M9U+U8="
}
}
@ -8423,7 +8427,7 @@
},
"parse-asn1": {
"version": "5.1.1",
"resolved": "http://registry.npmjs.org/parse-asn1/-/parse-asn1-5.1.1.tgz",
"resolved": "https://registry.npmjs.org/parse-asn1/-/parse-asn1-5.1.1.tgz",
"integrity": "sha512-KPx7flKXg775zZpnp9SxJlz00gTd4BmJ2yJufSc44gMCRrRQ7NSzAcSJQfifuOLgW6bEi+ftrALtsgALeB2Adw==",
"requires": {
"asn1.js": "^4.0.0",
@ -8543,7 +8547,7 @@
},
"pause-stream": {
"version": "0.0.11",
"resolved": "http://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz",
"resolved": "https://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz",
"integrity": "sha1-/lo0sMvOErWqaitAPuLnO2AvFEU=",
"requires": {
"through": "~2.3"
@ -8624,7 +8628,7 @@
"dependencies": {
"async": {
"version": "1.5.2",
"resolved": "http://registry.npmjs.org/async/-/async-1.5.2.tgz",
"resolved": "https://registry.npmjs.org/async/-/async-1.5.2.tgz",
"integrity": "sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo="
}
}
@ -9978,7 +9982,7 @@
},
"query-string": {
"version": "5.1.1",
"resolved": "http://registry.npmjs.org/query-string/-/query-string-5.1.1.tgz",
"resolved": "https://registry.npmjs.org/query-string/-/query-string-5.1.1.tgz",
"integrity": "sha512-gjWOsm2SoGlgLEdAGt7a6slVOk9mGiXmPFMqrEhLQ68rhQuBnpfs3+EmlvqKyxnCo9/PPlF+9MtY02S1aFg+Jw==",
"requires": {
"decode-uri-component": "^0.2.0",
@ -10316,7 +10320,7 @@
},
"react-redux": {
"version": "5.0.7",
"resolved": "http://registry.npmjs.org/react-redux/-/react-redux-5.0.7.tgz",
"resolved": "https://registry.npmjs.org/react-redux/-/react-redux-5.0.7.tgz",
"integrity": "sha512-5VI8EV5hdgNgyjfmWzBbdrqUkrVRKlyTKk1sGH3jzM2M2Mhj/seQgPXaz6gVAj2lz/nz688AdTqMO18Lr24Zhg==",
"requires": {
"hoist-non-react-statics": "^2.5.0",
@ -10364,7 +10368,7 @@
},
"react-textarea-autosize": {
"version": "6.1.0",
"resolved": "http://registry.npmjs.org/react-textarea-autosize/-/react-textarea-autosize-6.1.0.tgz",
"resolved": "https://registry.npmjs.org/react-textarea-autosize/-/react-textarea-autosize-6.1.0.tgz",
"integrity": "sha512-F6bI1dgib6fSvG8so1HuArPUv+iVEfPliuLWusLF+gAKz0FbB4jLrWUrTAeq1afnPT2c9toEZYUdz/y1uKMy4A==",
"requires": {
"prop-types": "^15.6.0"
@ -10915,7 +10919,7 @@
},
"minimist": {
"version": "1.2.0",
"resolved": "http://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz",
"resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz",
"integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ="
}
}
@ -10963,7 +10967,7 @@
},
"scrypt-js": {
"version": "2.0.3",
"resolved": "http://registry.npmjs.org/scrypt-js/-/scrypt-js-2.0.3.tgz",
"resolved": "https://registry.npmjs.org/scrypt-js/-/scrypt-js-2.0.3.tgz",
"integrity": "sha1-uwBAvgMEPamgEqLOqfyfhSz8h9Q="
},
"scrypt.js": {
@ -11012,7 +11016,7 @@
"dependencies": {
"commander": {
"version": "2.8.1",
"resolved": "http://registry.npmjs.org/commander/-/commander-2.8.1.tgz",
"resolved": "https://registry.npmjs.org/commander/-/commander-2.8.1.tgz",
"integrity": "sha1-Br42f+v9oMMwqh4qBy09yXYkJdQ=",
"requires": {
"graceful-readlink": ">= 1.0.0"
@ -11158,7 +11162,7 @@
},
"sha.js": {
"version": "2.4.11",
"resolved": "http://registry.npmjs.org/sha.js/-/sha.js-2.4.11.tgz",
"resolved": "https://registry.npmjs.org/sha.js/-/sha.js-2.4.11.tgz",
"integrity": "sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ==",
"requires": {
"inherits": "^2.0.1",
@ -11572,7 +11576,7 @@
},
"stream-combiner": {
"version": "0.2.2",
"resolved": "http://registry.npmjs.org/stream-combiner/-/stream-combiner-0.2.2.tgz",
"resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.2.2.tgz",
"integrity": "sha1-rsjLrBd7Vrb0+kec7YwZEs7lKFg=",
"requires": {
"duplexer": "~0.1.1",
@ -11648,7 +11652,7 @@
},
"strip-ansi": {
"version": "3.0.1",
"resolved": "http://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz",
"resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz",
"integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=",
"requires": {
"ansi-regex": "^2.0.0"
@ -11824,7 +11828,7 @@
},
"jsonfile": {
"version": "2.4.0",
"resolved": "http://registry.npmjs.org/jsonfile/-/jsonfile-2.4.0.tgz",
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-2.4.0.tgz",
"integrity": "sha1-NzaitCi4e72gzIO1P6PWM6NcKug=",
"requires": {
"graceful-fs": "^4.1.6"
@ -11844,7 +11848,7 @@
},
"table": {
"version": "4.0.3",
"resolved": "http://registry.npmjs.org/table/-/table-4.0.3.tgz",
"resolved": "https://registry.npmjs.org/table/-/table-4.0.3.tgz",
"integrity": "sha512-S7rnFITmBH1EnyKcvxBh1LjYeQMmnZtCXSEbHcH6S0NoKit24ZuFO/T1vDcLdYsLQkM188PVVhQmzKIuThNkKg==",
"requires": {
"ajv": "^6.0.1",
@ -11931,7 +11935,7 @@
"dependencies": {
"bluebird": {
"version": "2.11.0",
"resolved": "http://registry.npmjs.org/bluebird/-/bluebird-2.11.0.tgz",
"resolved": "https://registry.npmjs.org/bluebird/-/bluebird-2.11.0.tgz",
"integrity": "sha1-U0uQM8AiyVecVro7Plpcqvu2UOE="
}
}
@ -11984,7 +11988,7 @@
},
"through": {
"version": "2.3.8",
"resolved": "http://registry.npmjs.org/through/-/through-2.3.8.tgz",
"resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz",
"integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU="
},
"thunky": {
@ -12281,7 +12285,7 @@
},
"buffer": {
"version": "3.6.0",
"resolved": "http://registry.npmjs.org/buffer/-/buffer-3.6.0.tgz",
"resolved": "https://registry.npmjs.org/buffer/-/buffer-3.6.0.tgz",
"integrity": "sha1-pyyTb3e5a/UvX357RnGAYoVR3vs=",
"requires": {
"base64-js": "0.0.8",
@ -12834,7 +12838,7 @@
},
"uuid": {
"version": "2.0.1",
"resolved": "http://registry.npmjs.org/uuid/-/uuid-2.0.1.tgz",
"resolved": "https://registry.npmjs.org/uuid/-/uuid-2.0.1.tgz",
"integrity": "sha1-wqMN7bPlNdcsz4LjQ5QaULqFM6w="
}
}
@ -13485,7 +13489,7 @@
},
"wrap-ansi": {
"version": "2.1.0",
"resolved": "http://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz",
"resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz",
"integrity": "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=",
"requires": {
"string-width": "^1.0.1",

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

Before

Width:  |  Height:  |  Size: 163 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 714 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 49 KiB

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,82 +0,0 @@
import React from 'react';
import ContractContext from './contract-context';
import CardAlert from './card-alert';
class AccountList extends React.Component {
constructor(props) {
super(props);
this.state = {
error: false,
errorMessage: "",
accounts: []
};
this.handleClick = this.handleClick.bind(this);
this.handleCopyClick = this.handleCopyClick.bind(this);
}
handleClick(e, updateAccountsCallback) {
e.preventDefault();
try {
updateAccountsCallback();
} catch (err) {
this.setState({
error: true,
errorMessage: e.name + ': ' + e.message
});
}
}
handleCopyClick(e) {
e.preventDefault();
var dummy = document.createElement("input");
document.body.appendChild(dummy);
dummy.setAttribute('value', "await web3.eth.getAccounts();");
dummy.select();
document.execCommand("copy");
document.body.removeChild(dummy);
}
render() {
return <ContractContext.Consumer>
{(context) => (
<div className="card function">
<div className="card-header">
<h3 className="card-title">Get Accounts</h3>
<div className="card-options">
<a href="#" onClick={this.handleCopyClick} title="Copy to clipboard"><i className="fe fe-copy"></i></a>
</div>
</div>
<CardAlert show={this.state.error} message={this.state.errorMessage}/>
<div className="card-body row">
<div className="col-md-11">
<code>
await web3.eth.getAccounts();
<input type="text" id="accountsTxt"/>
</code>
</div>
<div className="col-md-1">
<button className="btn btn-primary ml-auto"
onClick={event => this.handleClick(event, context.updateAccounts)}>&#9166;</button>
</div>
</div>
<div className="card-footer">
<p><tt>accounts</tt> variable is available in the console</p>
<ul>
{
context.accounts.map((account, i) => <li key={i}>{account}</li>)
}
</ul>
</div>
</div>
)}
</ContractContext.Consumer>;
}
}
export default AccountList;

View File

@ -1,15 +0,0 @@
import React from 'react';
import PropTypes from 'prop-types';
class CardAlert extends React.Component {
render() {
return this.props.show ? <div className="card-alert alert alert-danger mb-0">{this.props.message}</div> : '';
}
}
CardAlert.propTypes = {
show: PropTypes.bool,
message: PropTypes.string
};
export default CardAlert;

View File

@ -1,12 +0,0 @@
import React from 'react';
const ContractContext = React.createContext({
accounts: [],
instances: [],
updateAccounts: () => {
},
updateInstances: (_instance) => {
}
});
export default ContractContext;

View File

@ -1,141 +0,0 @@
/*global web3*/
import React from 'react';
import ContractContext from './contract-context';
import MenuItem from './menu-item';
import AccountList from './account-list';
import FunctionArea from './function-area';
import Tab from './tab';
import InstanceSelector from './instance-selector';
import SourceArea from './source-area';
import PropTypes from 'prop-types';
class ContractUI extends React.Component {
constructor(props) {
super(props);
this.updateInstances = this.updateInstances.bind(this);
this.updateAccounts = this.updateAccounts.bind(this);
this.handleInstanceSelection = this.handleInstanceSelection.bind(this);
this.handleMenuClick = this.handleMenuClick.bind(this);
this.state = {
accounts: [],
instances: [],
selectedInstance: null,
updateAccounts: this.updateAccounts,
updateInstances: this.updateInstances,
selectedTab: 'deploy'
};
if (props.contract.options.address !== null) {
this.state.instances = [props.contract.options.address];
this.state.selectedInstance = props.contract.options.address;
}
}
componentDidMount() {
this.updateAccounts();
}
handleMenuClick(e) {
e.preventDefault();
this.setState({
selectedTab: e.target.getAttribute('data-target')
});
}
async updateAccounts() {
let accounts = await web3.eth.getAccounts();
window.accounts = accounts;
console.log("%cawait web3.eth.getAccounts()", 'font-weight: bold');
console.log(accounts);
this.setState({accounts: accounts});
}
updateInstances(_instance) {
this.state.instances.push(_instance);
this.setState({
instances: this.state.instances
});
}
handleInstanceSelection(_instance) {
this.props.contract.options.address = _instance;
this.setState({
selectedInstance: _instance
});
}
render() {
return (
<ContractContext.Provider value={this.state}>
<div className="row">
<div className="col-md-3">
<h3 className="page-title mb-5">{this.props.name}</h3>
<div>
<div className="list-group list-group-transparent mb-0">
<MenuItem icon="fe-file-plus" click={this.handleMenuClick} selectedTab={this.state.selectedTab}
target="deploy" text="Deployment / Utils"/>
<MenuItem icon="fe-list" click={this.handleMenuClick} selectedTab={this.state.selectedTab}
target="functions" text="Functions"/>
<MenuItem icon="fe-file-text" click={this.handleMenuClick} selectedTab={this.state.selectedTab}
target="contract" text="Source Code"/>
</div>
</div>
</div>
<div className="col-md-9">
<Tab id="deploy" selectedTab={this.state.selectedTab}>
<h4 className="mb-5">Deployment Utils</h4>
<div className="card">
<div className="card-body">
<ul>
<li>Open your browser&apos;s console: <code>Tools &gt; Developer Tools</code></li>
<li>Remix: <a href="https://remix.ethereum.org" target="_blank" rel="noopener noreferrer">http://remix.ethereum.org</a></li>
</ul>
</div>
</div>
<AccountList accountUpdate={this.updateAccounts}/>
<h5>Deploy</h5>
{
this.props.definition.code === "" ? <p>Interface or set to not deploy</p> : ""
}
<FunctionArea definition={this.props.definition} contractName={this.props.name}
contract={this.props.contract} type="constructor"/>
</Tab>
<Tab id="functions" selectedTab={this.state.selectedTab}>
<h4 className="mb-5">Functions</h4>
{(this.props.definition.code !== "") && <InstanceSelector selectedInstance={this.state.selectedInstance}
instanceUpdate={this.handleInstanceSelection}/>
}
<FunctionArea definition={this.props.definition} contractName={this.props.name}
contract={this.props.contract} type="function"/>
<FunctionArea definition={this.props.definition} contractName={this.props.name}
contract={this.props.contract} type="fallback"/>
</Tab>
<Tab id="contract" selectedTab={this.state.selectedTab}>
<h4 className="mb-5">Source Code</h4>
<SourceArea definition={this.props.definition} source={this.props.source}/>
</Tab>
</div>
</div>
,
</ContractContext.Provider>
);
}
}
ContractUI.propTypes = {
definition: PropTypes.object,
source: PropTypes.string,
contract: PropTypes.object,
name: PropTypes.string
};
export default ContractUI;

View File

@ -1,36 +0,0 @@
import React from 'react';
import FunctionForm from './function-form';
import PropTypes from 'prop-types';
class FunctionArea extends React.Component {
constructor(props) {
super(props);
this.state = {};
}
render() {
const type = this.props.type;
const contract = this.props.contract;
const contractName = this.props.contractName;
return <React.Fragment>
{
this.props.contract.options.jsonInterface
.filter(item => item.type === type)
.map((item, i) => <FunctionForm definition={this.props.definition} key={i} contract={contract}
contractName={contractName} abi={item}
instanceUpdate={this.props.instanceUpdate}/>)
}
</React.Fragment>;
}
}
FunctionArea.propTypes = {
type: PropTypes.string,
contract: PropTypes.object,
contractName: PropTypes.string,
definition: PropTypes.object,
instanceUpdate: PropTypes.func
};
export default FunctionArea;

View File

@ -1,159 +0,0 @@
import React from 'react';
import CardAlert from './card-alert';
import Function from './function';
import PropTypes from 'prop-types';
class FunctionForm extends React.Component {
constructor(props) {
super(props);
this.state = {
fields: {},
error: false,
message: null,
receipt: null
};
this.child = React.createRef();
this.showResults = this.showResults.bind(this);
this.handleCopyClick = this.handleCopyClick.bind(this);
}
handleCopyClick(e) {
this.child.current.copyCommand(e);
}
_getFunctionParamFields(_elem) {
if (this.props.abi.type === 'fallback') return '';
return '(' + this.props.abi.inputs
.map((input, i) => <input type="text" data-var-type={input.type} data-type="inputParam" data-name={input.name}
placeholder={input.name} title={input.type + ' ' + input.name}
size={input.name.length}
key={'input' + i}/>)
.join(', ') + ')';
}
_getMethodType(_elem) {
return (this.props.abi.constant === true || this.props.abi.stateMutability === 'view' || this.props.abi.stateMutability === 'pure') ? 'call' : 'send';
}
renderContent(receipt, contract) {
if (receipt === null && (this.state.error || this.state.message === null)) {
return '';
}
let messagesList;
if (this.props.abi.outputs.filter(x => x.name !== "").length > 0) {
messagesList = Object.keys(this.state.message).map((key, index) => {
if (isNaN(key)) {
return <li key={index}>{key}: {this.state.message[key]}</li>;
} else {
return '';
}
});
} else {
messagesList = Object.keys(this.state.message).map((key, index) => {
return <li key={index}>{key}: {this.state.message[key]}</li>;
});
}
let message;
if (this.state.message !== null && typeof this.state.message === 'object') {
message = <ul>
{messagesList}
</ul>;
} else if (typeof this.state.message === "boolean") {
message = (this.state.message ? 'true' : 'false');
} else {
message = this.state.message;
}
return (<div className="card-footer">
{receipt && <ul>
<li>Status: {receipt.status}</li>
<li>Transaction Hash: {receipt.transactionHash}</li>
{
receipt.events && <li>Events:
<ul>
{
Object.keys(receipt.events).map(function(ev, index) {
if (!isNaN(ev)) return null;
const eventAbi = contract.options.jsonInterface.filter(x => x.name === ev)[0];
let props = [];
for (let prop in receipt.events[ev].returnValues) {
if (isNaN(prop)) {
let input = eventAbi.inputs.filter(x => x.name === prop)[0];
props.push(prop + ': ' +
(input.type.indexOf('int') === -1 ? '"' : '') +
receipt.events[ev].returnValues[prop] +
(input.type.indexOf('int') === -1 ? '"' : ''));
}
}
return <li key={index}>{ev}({props.join(', ')})</li>;
})
}
</ul>
</li>
}
</ul>
}
{
!this.state.error && this.state.message && <React.Fragment>
{message}
</React.Fragment>}
</div>);
}
render() {
const functionName = this.props.abi.name;
const isDuplicated = this.props.contract.options.jsonInterface.filter(x => x.name === functionName).length > 1;
const contract = this.props.contract;
const receipt = this.state.receipt;
let title;
if (this.props.abi.type === 'function') {
title = this.props.abi.name;
} else if (this.props.abi.type === 'fallback') {
title = '(fallback)';
} else {
title = this.props.abi.name;
}
return <div className="card function">
<div className="card-header">
<h3
className="card-title">{title}</h3>
<div className="card-options">
<a href="#" onClick={this.handleCopyClick} title="Copy to clipboard"><i className="fe fe-copy"></i></a>
</div>
</div>
<CardAlert show={this.state.error} message={this.state.message}/>
<div className="card-body row">
<Function ref={this.child} definition={this.props.definition} contract={this.props.contract}
contractName={this.props.contractName} duplicated={isDuplicated} abi={this.props.abi}
resultHandler={this.showResults}/>
</div>
{this.renderContent(receipt, contract)}
</div>;
}
showResults(_error, _message, _receipt) {
this.setState({
error: _error,
message: _message,
receipt: _receipt
});
}
}
FunctionForm.propTypes = {
abi: PropTypes.object,
contract: PropTypes.object,
definition: PropTypes.object,
contractName: PropTypes.string
};
export default FunctionForm;

View File

@ -1,271 +0,0 @@
/*global web3*/
import React from 'react';
import ContractContext from './contract-context';
import PropTypes from 'prop-types';
class Function extends React.Component {
constructor(props) {
super(props);
this.state = {
onRequest: false,
fields: {},
methodFields: {
from: '',
to: '',
value: 0,
data: '',
gasLimit: '7000000'
},
receipt: null
};
this.handleParameterChange = this.handleParameterChange.bind(this);
this.handleMethodFieldChange = this.handleMethodFieldChange.bind(this);
this.handleClick = this.handleClick.bind(this);
}
copyCommand(e) {
e.preventDefault();
let functionLabel = this._getFunctionLabel();
let functionParams = this._getFunctionParamString();
let methodParams = this._getMethodString();
if (this.props.abi.type === "constructor") functionParams = `{arguments: [${functionParams}]}`;
const command = `await ${functionLabel}(${functionParams})${this.props.abi.type !== 'fallback' ? '.' + this._getMethodType() : ''}${methodParams}`;
var dummy = document.createElement("input");
document.body.appendChild(dummy);
dummy.setAttribute('value', command);
dummy.select();
document.execCommand("copy");
document.body.removeChild(dummy);
}
async handleClick(e, instanceUpdateCallback) {
e.preventDefault();
this.setState({onRequest: true, receipt: null});
this.props.resultHandler(false, null, null);
let executionParams = {
from: this.state.methodFields.from,
gasLimit: this.state.methodFields.gasLimit
};
if (this.props.abi.payable) executionParams.value = this.state.methodFields.value;
if (this.props.abi.type === 'fallback') {
executionParams.data = this.state.methodFields.data;
executionParams.to = this.props.contract.options.address;
}
let fields = this.state.fields;
let functionLabel = this._getFunctionLabel();
let functionParams = this._getFunctionParamString();
let methodParams = this._getMethodString();
if (this.props.abi.type === "constructor") functionParams = `{arguments: [${functionParams}]}`;
console.log(`%cawait ${functionLabel}(${functionParams})${this.props.abi.type !== 'fallback' ? '.' + this._getMethodType() : ''}${methodParams}`, 'font-weight: bold');
let _receipt;
try {
if (this.props.abi.type === 'constructor') {
let contractInstance = await this.props.contract.deploy({arguments: Object.keys(fields).map(val => fields[val])}).send(executionParams);
instanceUpdateCallback(contractInstance.options.address);
this.setState({onRequest: false});
console.log(contractInstance.options.address);
this.props.resultHandler(false, 'New instance: ' + contractInstance.options.address);
} else {
if (this.props.abi.type === 'fallback') _receipt = await web3.eth.sendTransaction(executionParams);
else _receipt = await this.props.contract
.methods[this.props.abi.name + '(' + this.props.abi.inputs.map(input => input.type).join(',') + ')']
.apply(null, Object.keys(fields).map(val => {
let input = this.props.abi.inputs.filter(x => x.name === val)[0];
return input.type.indexOf('bool') === -1 ? fields[val] : (fields[val].toLowerCase() === 'true');
}))[this._getMethodType()](executionParams);
if (this._getMethodType() === 'call') {
this.props.resultHandler(false, _receipt, null);
} else {
this.props.resultHandler(false, null, _receipt);
}
this.setState({onRequest: false, receipt: _receipt});
console.log(_receipt);
}
} catch (err) {
console.error('%s: %s', err.name, err.message);
this.setState({onRequest: false});
this.props.resultHandler(true, err.name + ": " + err.message, _receipt);
}
}
handleParameterChange(e) {
let newState = this.state;
newState.fields[e.target.getAttribute('data-name')] = e.target.value;
this.setState(newState);
}
handleMethodFieldChange(e) {
let newState = this.state;
newState.methodFields[e.target.getAttribute('data-param')] = e.target.value;
if (e.target.getAttribute('data-param') === 'from') {
newState.selectedAccount = e.target.options[e.target.selectedIndex].text;
}
this.setState(newState);
}
_getFunctionLabel() {
if (this.props.abi.type === 'function') if (!this.props.duplicated) return `${this.props.contractName}.methods.${this.props.abi.name}`;
else {
return `${this.props.contractName}.methods['${this.props.abi.name + '(' + (this.props.abi.inputs !== null ? this.props.abi.inputs.map(input => input.type).join(',') : '') + ')'}']`;
}
else if (this.props.abi.type === 'fallback') {
return `web3.eth.sendTransaction`;
}
else return `${this.props.contractName}.deploy`;
}
_getMethodType() {
return (this.props.abi.constant === true || this.props.abi.stateMutability === 'view' || this.props.abi.stateMutability === 'pure') ? 'call' : 'send';
}
_getMethodFields(accounts) {
return <React.Fragment>
from: <select data-param="from" disabled={accounts.length === 0} value={this.state.from}
onChange={this.handleMethodFieldChange}>
<option>-</option>
{
accounts.map(function(item, i) {
return <option key={i} value={item}>{`accounts[${i}]`}</option>;
})
}
</select>
{this.props.abi.payable &&
<span>, value:
<input type="text" data-param="value" value={this.state.methodFields.value} size="6"
onChange={this.handleMethodFieldChange}/>
</span>
}
{this._getMethodType() === 'send' &&
<span>, gasLimit:
<input type="text" data-param="gasLimit" value={this.state.methodFields.gasLimit} size="6"
onChange={this.handleMethodFieldChange}/>
</span>}
{this._getMethodType() === 'send' && this.props.abi.type === 'fallback' &&
<span>, data:
<input type="text" data-param="data" value={this.state.methodFields.data} size="6"
onChange={this.handleMethodFieldChange}/>
</span>}
</React.Fragment>;
}
_getFunctionParamFields() {
return <React.Fragment>
{
this.props.abi.inputs
.map((input, i) => <input key={i} type="text" data-var-type={input.type} data-type="inputParam"
data-name={input.name} placeholder={input.name}
title={input.type + ' ' + input.name} size={input.name.length}
value={this.state.fields[input.name] || ''} onChange={this.handleParameterChange}/>)
.reduce((accu, elem) => {
return accu === null ? [elem] : [...accu, ', ', elem];
}, null)
}
</React.Fragment>;
}
_getFunctionParamString() {
if (this.props.abi.type === 'fallback') return '';
return this.props.abi.inputs
.map((input, _i) => (input.type.indexOf('int') === -1 && input.type.indexOf('bool') === -1 ? '"' : '') + (this.state.fields[input.name] || (input.type.indexOf('int') === -1 ? '' : '0')) + (input.type.indexOf('int') === -1 ? '"' : ''))
.join(', ');
}
_getMethodString(_elem) {
let methodParams = "({";
methodParams += `from: ` + (this.state.selectedAccount || '"0x00"');
if (this._getMethodType() === 'send') {
methodParams += ', gasLimit: ' + (this.state.methodFields.gasLimit || 0);
if (this.props.abi.payable) {
methodParams += ', value: ' + (this.state.methodFields.value || 0);
}
if (this.props.abi.type === 'fallback') {
methodParams += ', data: "' + (this.state.methodFields.data || '"0x00"') + '", to: "' + (this.state.methodFields.to || '"0x00"') + '"';
}
}
return methodParams + "})";
}
render() {
let btnClass = "btn ml-auto ";
let disabled = false;
if (this.state.onRequest) {
disabled = true;
}
if (this.props.definition.code === "") {
btnClass += "btn-secondary";
disabled = true;
} else {
btnClass += "btn-primary";
}
let requestResult;
if (this.state.onRequest) {
requestResult = <img src="../assets/images/loading.gif" className="loading" alt=""/>;
} else {
requestResult = this.props.definition.code === "" ? <React.Fragment>_</React.Fragment>: <React.Fragment>&#9166;</React.Fragment>;
}
return <ContractContext.Consumer>
{(context) => (
<React.Fragment>
<div className="col-md-11">
<code>
await {this._getFunctionLabel()}
{this.props.abi.type !== 'fallback' ? '(' : ''}
{this.props.abi.type !== 'fallback' ? this._getFunctionParamFields() : ''}
{this.props.abi.type !== 'fallback' ? ')' : ''}
{this.props.abi.type !== 'fallback' ? '.' + this._getMethodType() : ''}
({this._getMethodFields(context.accounts)})
</code>
</div>
<div className="col-md-1">
<button className={btnClass}
title={this.props.definition.code === "" ? "Can't execute function" : "Execute function"}
onClick={event => this.handleClick(event, context.updateInstances)} disabled={disabled}>
{requestResult}
</button>
</div>
</React.Fragment>
)}
</ContractContext.Consumer>;
}
}
Function.propTypes = {
definition: PropTypes.object,
abi: PropTypes.object,
contract: PropTypes.object,
resultHandler: PropTypes.func,
duplicated: PropTypes.bool,
contractName: PropTypes.string
};
export default Function;

View File

@ -1,131 +0,0 @@
import React from 'react';
import ContractContext from './contract-context';
import PropTypes from 'prop-types';
class InstanceSelector extends React.Component {
constructor(props) {
super(props);
this.state = {
showInstances: false,
showCustomAddressField: false,
selectedInstance: props.selectedInstance,
customInstance: "",
error: false,
errorMessage: ""
};
this.handleShowInstances = this.handleShowInstances.bind(this);
this.handleChange = this.handleChange.bind(this);
this.handleClick = this.handleClick.bind(this);
this.handleTextChange = this.handleTextChange.bind(this);
}
handleTextChange(e) {
this.setState({customInstance: e.target.value});
}
handleShowInstances(e) {
e.preventDefault();
this.setState({
showInstances: !this.state.showInstances
});
}
handleClick(e) {
e.preventDefault();
let instance;
if (this.state.selectedInstance === "custom") {
instance = this.state.customInstance;
} else {
instance = this.state.selectedInstance;
}
if (!(/^0x[0-9a-f]{40}$/i).test(instance)) {
this.setState({error: true, errorMessage: 'Not a valid Ethereum address.'});
console.log(this.state.errorMessage);
return;
} else {
this.setState({error: false});
}
this.props.instanceUpdate(instance);
this.setState({
showInstances: false,
showCustomAddressField: false,
selectedInstance: instance,
customInstance: this.state.selectedInstance === "custom" ? this.state.customInstance : ""
});
}
handleChange(e) {
this.setState({
showCustomAddressField: e.target.value === "custom",
selectedInstance: e.target.value
});
}
render() {
let showInstance;
if (!this.state.showInstances) {
showInstance = <a href="#" className="btn btn-primary btn-sm" onClick={this.handleShowInstances}>Change</a>;
} else {
showInstance = <a href="#" className="btn btn-secondary btn-sm" onClick={this.handleShowInstances}>Cancel</a>;
}
return <ContractContext.Consumer>
{(context) => (<div className="contractSelection">
<div className="card">
<div className="card-header">
<h3 className="card-title">
Instance Selected: <b>{this.props.selectedInstance !== null ? this.props.selectedInstance : 'none'}</b>
</h3>
<div className="card-options">
{showInstance}
</div>
</div>
{
this.state.showInstances && <React.Fragment>
{
this.state.error && <div className="card-alert alert alert-danger mb-0">
{this.state.errorMessage}
</div>
}
<div className="card-body">
<div className="form-group control-group error">
<select className="form-control" id="contracts" value={this.state.selectedInstance}
onChange={this.handleChange}>
<option value="custom">Specific contract address</option>
{
context.instances.map(function(item, i) {
return <option key={i} value={item}>{item}</option>;
})
}
</select>
{
this.state.showCustomAddressField &&
<input type="text" className="form-control" id="specificAddress"
onChange={this.handleTextChange} placeholder="0x"/>
}
</div>
</div>
<div className="card-footer text-right">
<button className="btn btn-primary" onClick={this.handleClick}>Change</button>
</div>
</React.Fragment>
}
</div>
</div>
)}
</ContractContext.Consumer>;
}
}
InstanceSelector.propTypes = {
instanceUpdate: PropTypes.func,
selectedInstance: PropTypes.string
};
export default InstanceSelector;

View File

@ -1,27 +0,0 @@
import React from 'react';
import PropTypes from 'prop-types';
class MenuItem extends React.Component {
render() {
let classNames = "list-group-item list-group-item-action d-flex align-items-center ";
let icon = "fe " + this.props.icon;
if (this.props.target === this.props.selectedTab) {
classNames += "active";
}
return <a href="#" onClick={this.props.click} data-target={this.props.target} className={classNames}>
<span className="icon mr-3"><i className={icon}></i></span>{this.props.text}
</a>;
}
}
MenuItem.propTypes = {
icon: PropTypes.string,
target: PropTypes.string,
selectedTab: PropTypes.string,
text: PropTypes.string,
click: PropTypes.func
};
export default MenuItem;

View File

@ -1,38 +0,0 @@
/*global hljs*/
import React from 'react';
import PropTypes from 'prop-types';
class SourceArea extends React.Component {
constructor(props) {
super(props);
this.state = {
sourceCode: ""
};
}
componentDidMount() {
let colorCodedText = hljs.highlight('javascript', this.props.source, true).value;
this.setState({sourceCode: colorCodedText});
}
render() {
return <div className="card">
<div className="card-header">
<h3 className="card-title">{this.props.definition.className}</h3>
<div className="card-options">
<small>{this.props.definition.filename}</small>
</div>
</div>
<div className="card-body">
<pre dangerouslySetInnerHTML={{__html: this.state.sourceCode}}></pre>
</div>
</div>;
}
}
SourceArea.propTypes = {
definition: PropTypes.object,
source: PropTypes.string
};
export default SourceArea;

View File

@ -1,20 +0,0 @@
import React from 'react';
import PropTypes from 'prop-types';
class Tab extends React.Component {
render() {
return (
this.props.selectedTab === this.props.id && <div id={this.props.id}>
{this.props.children}
</div>
);
}
}
Tab.propTypes = {
selectedTab: PropTypes.string,
id: PropTypes.string,
children: PropTypes.element
};
export default Tab;

View File

@ -1,37 +0,0 @@
code {
width: 100%;
overflow: auto;
display: block;
white-space: nowrap;
padding-top: 5px;
padding-bottom: 5px;
}
code input, code select {
padding: 0.375rem 0.75rem;
font-size: 0.9375rem;
line-height: 1.6;
color: #495057;
background-color: #fff;
background-clip: padding-box;
border: 1px solid rgba(0, 40, 100, 0.12);
border-radius: 3px;
transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}
.function button {
margin-top: .6em;
}
#accountsTxt {
visibility: hidden;
}
.card-options a.btn-primary {
color: #fff;
}
.card-options a.btn-primary:hover {
background-color: #ccc;
}

View File

@ -1,209 +0,0 @@
<!doctype html>
<html lang="en" dir="ltr">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<meta http-equiv="Content-Language" content="en" />
<meta name="msapplication-TileColor" content="#2d89ef">
<meta name="theme-color" content="#4188c9">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent"/>
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="mobile-web-app-capable" content="yes">
<meta name="HandheldFriendly" content="True">
<meta name="MobileOptimized" content="320">
<link rel="icon" href="./favicon.ico" type="image/x-icon"/>
<link rel="shortcut icon" type="image/x-icon" href="./favicon.ico" />
<!-- Generated: 2018-04-04 13:48:30 +0200 -->
<title>Embark</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,300i,400,400i,500,500i,600,600i,700,700i&amp;subset=latin-ext">
<!--
<script src="./assets/js/require.min.js"></script>
<script>
requirejs.config({
baseUrl: '.'
});
</script>
-->
<!-- Dashboard Core -->
<link href="../assets/css/dashboard.css" rel="stylesheet" />
<script src="https://unpkg.com/react@16/umd/react.development.js"></script>
<script src="https://unpkg.com/react-dom@16/umd/react-dom.development.js"></script>
<script src="https://unpkg.com/babel-standalone@6.15.0/babel.min.js"></script>
<script src="../assets/js/jquery-3.3.1.min.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/default.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/highlight.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.4.0/languages/javascript.min.js"></script>
<!-- Import this with a bundler -->
<link rel="stylesheet" href="./contracts.css">
<script src="../assets/js/web3-1.0.min.js" type="text/javascript"></script>
<script src="./components/account-list.js" type="text/babel"></script>
<script src="./components/contract-context.js" type="text/babel"></script>
<script src="./components/contract-ui.js" type="text/babel"></script>
<script src="./components/function-area.js" type="text/babel"></script>
<script src="./components/function-form.js" type="text/babel"></script>
<script src="./components/function.js" type="text/babel"></script>
<script src="./components/instance-selector.js" type="text/babel"></script>
<script src="./components/source-area.js" type="text/babel"></script>
<script src="./components/tab.js" type="text/babel"></script>
<script src="./components/menu-item.js" type="text/babel"></script>
<script src="./components/card-alert.js" type="text/babel"></script>
<script src="./view.js" type="text/babel"></script>
<!--
<script src="./assets/js/dashboard.js"></script>
<link href="./assets/plugins/charts-c3/plugin.css" rel="stylesheet" />
<script src="./assets/plugins/charts-c3/plugin.js"></script>
<link href="./assets/plugins/maps-google/plugin.css" rel="stylesheet" />
<script src="./assets/plugins/maps-google/plugin.js"></script>
<script src="./assets/plugins/input-mask/plugin.js"></script>
-->
</head>
<body class="">
<div class="page">
<div class="page-main">
<div class="header">
<div class="container">
<div class="d-flex">
<a class="navbar-brand" href="/embark/index.html">
<img src="../assets/images/logo.png" class="navbar-brand-img" alt="Embark">
</a>
<div class="ml-auto d-flex order-lg-2">
<div class="dropdown d-none d-md-flex">
<a class="nav-link icon" data-toggle="dropdown">
<i class="fe fe-bell"></i>
<span class="nav-unread"></span>
</a>
<div class="dropdown-menu dropdown-menu-right dropdown-menu-arrow">
<a href="#" class="dropdown-item d-flex">
<span class="avatar mr-3 align-self-center" style="background-image: url(demo/faces/male/41.jpg)"></span>
<div>
<strong>Nathan</strong> pushed new commit: Fix page load performance issue.
<div class="small text-muted">10 minutes ago</div>
</div>
</a>
<a href="#" class="dropdown-item d-flex">
<span class="avatar mr-3 align-self-center" style="background-image: url(demo/faces/female/1.jpg)"></span>
<div>
<strong>Alice</strong> started new task: Tabler UI design.
<div class="small text-muted">1 hour ago</div>
</div>
</a>
<a href="#" class="dropdown-item d-flex">
<span class="avatar mr-3 align-self-center" style="background-image: url(demo/faces/female/18.jpg)"></span>
<div>
<strong>Rose</strong> deployed new version of NodeJS REST Api V3
<div class="small text-muted">2 hours ago</div>
</div>
</a>
<div class="dropdown-divider"></div>
<a href="#" class="dropdown-item text-center text-muted-dark">Mark all as read</a>
</div>
</div>
<div class="dropdown">
<a href="#" class="nav-link pr-0" data-toggle="dropdown">
<span class="avatar" style="background-image: url(./demo/faces/female/25.jpg)"></span>
<span class="ml-2 d-none d-lg-block">
<span class="text-default">Dade Murphy</span>
</span>
</a>
<div class="dropdown-menu dropdown-menu-right dropdown-menu-arrow">
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-user"></i> Profile
</a>
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-settings"></i> Settings
</a>
<a class="dropdown-item" href="#">
<span class="float-right"><span class="badge badge-primary">6</span></span>
<i class="dropdown-icon fe fe-mail"></i> Inbox
</a>
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-send"></i> Message
</a>
<div class="dropdown-divider"></div>
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-help-circle"></i> Need help?
</a>
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-log-out"></i> Sign out
</a>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="header-nav d-none d-lg-flex">
<div class="container">
<div class="row align-items-center">
<div class="col">
<ul class="nav nav-tabs">
<li class="nav-item">
<a href="/embark/index.html" class="nav-link"><i class="fe fe-home"></i> Home</a>
</li>
<li class="nav-item">
<a href="javascript:void(0)" class="nav-link active"><i class="fe fe-box"></i> Contracts</a>
</li>
<li class="nav-item">
<a href="./docs/index.html" class="nav-link"><i class="fe fe-file-text"></i> Documentation</a>
</li>
</ul>
</div>
<div class="col-3 ml-auto">
<form class="input-icon">
<input type="search" class="form-control header-search" placeholder="Search&hellip;" tabindex="1">
<div class="input-icon-addon">
<i class="fe fe-search"></i>
</div>
</form>
</div>
</div>
</div>
</div>
<div class="page-content">
<div class="container">
<div id="contracts-area"></div>
</div>
</div>
</div>
</div>
<footer class="footer">
<div class="container">
<div class="row align-items-center flex-row-reverse">
<div class="col-auto ml-auto">
<div class="row align-items-center">
<div class="col-auto">
<ul class="list-inline list-inline-dots mb-0">
<li class="list-inline-item"><a href="./docs/index.html">Documentation</a></li>
<li class="list-inline-item"><a href="./faq.html">FAQ</a></li>
</ul>
</div>
<div class="col-auto">
<a href="https://github.com/tabler/tabler" class="btn btn-outline-primary btn-sm">Source code</a>
</div>
</div>
</div>
<div class="col-12 col-lg-auto mt-3 mt-lg-0 text-center">
Copyright © 2018 <a href=".">Status Embark</a>.
</div>
</div>
</div>
</footer>
</div>
</body>
</html>

View File

@ -1,57 +0,0 @@
/*global Web3*/
import React from 'react';
import ReactDOM from 'react-dom';
import ContractUI from './components/contract-ui';
const contractName = location.search.replace(/\?/, '');
let contractDefinition;
let host;
fetch("/embark/console", {
method: "POST",
headers: {'content-type': 'application/x-www-form-urlencoded; charset=UTF-8'},
body: "cmd=web3.currentProvider.host"
})
.then(response => response.text())
.then(text => {
host = text;
return fetch("/embark/contract/" + contractName);
})
.then(response => response.json())
.then(_contractDefinition => {
contractDefinition = _contractDefinition;
return fetch("/embark/files/contracts?filename=" + contractDefinition.originalFilename);
})
.then(response => response.text())
.then(contractSource => {
const web3 = new Web3(host);
window.web3 = web3;
let contractObj = new web3.eth.Contract(contractDefinition.abiDefinition);
contractObj.options.data = "0x" + contractDefinition.code;
contractObj.options.address = contractDefinition.deployedAddress;
window[contractDefinition.className] = contractObj;
ReactDOM.render(
<ContractUI name={contractDefinition.className} definition={contractDefinition} contract={contractObj}
source={contractSource}/>,
document.getElementById('contracts-area')
);
})
.catch(function(err) {
console.log('%cError while rendering UI', 'font-weight: bold');
console.error(err);
ReactDOM.render(
<div>
<h1 className="h2 mb-3">Error rendering the UI</h1>
<p className="h4 text-muted font-weight-normal mb-7">UI for &quot;&lbrace;contractName&rbrace;&quot; cannot be
generated</p>
</div>,
document.getElementById('contracts-area')
);
});

View File

@ -1,348 +0,0 @@
<!doctype html>
<html lang="en" dir="ltr">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<meta http-equiv="Content-Language" content="en" />
<meta name="msapplication-TileColor" content="#2d89ef">
<meta name="theme-color" content="#4188c9">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent"/>
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="mobile-web-app-capable" content="yes">
<meta name="HandheldFriendly" content="True">
<meta name="MobileOptimized" content="320">
<link rel="icon" href="./favicon.ico" type="image/x-icon"/>
<link rel="shortcut icon" type="image/x-icon" href="./favicon.ico" />
<!-- Generated: 2018-04-04 13:48:30 +0200 -->
<title>Embark</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,300i,400,400i,500,500i,600,600i,700,700i&amp;subset=latin-ext">
<!--
<script src="./assets/js/require.min.js"></script>
<script>
requirejs.config({
baseUrl: '.'
});
</script>
-->
<!-- Dashboard Core -->
<link href="./assets/css/dashboard.css" rel="stylesheet" />
<script src="./assets/js/jquery-3.3.1.min.js"></script>
<!--
<script src="./assets/js/dashboard.js"></script>
<link href="./assets/plugins/charts-c3/plugin.css" rel="stylesheet" />
<script src="./assets/plugins/charts-c3/plugin.js"></script>
<link href="./assets/plugins/maps-google/plugin.css" rel="stylesheet" />
<script src="./assets/plugins/maps-google/plugin.js"></script>
<script src="./assets/plugins/input-mask/plugin.js"></script>
-->
</head>
<body class="">
<div class="page">
<div class="page-main">
<div class="header">
<div class="container">
<div class="d-flex">
<a class="navbar-brand" href="./index.html">
<img src="./assets/images/logo.png" class="navbar-brand-img" alt="Embark">
</a>
<div class="ml-auto d-flex order-lg-2">
<div class="dropdown d-none d-md-flex">
<a class="nav-link icon" data-toggle="dropdown">
<i class="fe fe-bell"></i>
<span class="nav-unread"></span>
</a>
<div class="dropdown-menu dropdown-menu-right dropdown-menu-arrow">
<a href="#" class="dropdown-item d-flex">
<span class="avatar mr-3 align-self-center" style="background-image: url(demo/faces/male/41.jpg)"></span>
<div>
<strong>Nathan</strong> pushed new commit: Fix page load performance issue.
<div class="small text-muted">10 minutes ago</div>
</div>
</a>
<a href="#" class="dropdown-item d-flex">
<span class="avatar mr-3 align-self-center" style="background-image: url(demo/faces/female/1.jpg)"></span>
<div>
<strong>Alice</strong> started new task: Tabler UI design.
<div class="small text-muted">1 hour ago</div>
</div>
</a>
<a href="#" class="dropdown-item d-flex">
<span class="avatar mr-3 align-self-center" style="background-image: url(demo/faces/female/18.jpg)"></span>
<div>
<strong>Rose</strong> deployed new version of NodeJS REST Api V3
<div class="small text-muted">2 hours ago</div>
</div>
</a>
<div class="dropdown-divider"></div>
<a href="#" class="dropdown-item text-center text-muted-dark">Mark all as read</a>
</div>
</div>
<div class="dropdown">
<a href="#" class="nav-link pr-0" data-toggle="dropdown">
<span class="avatar" style="background-image: url(./demo/faces/female/25.jpg)"></span>
<span class="ml-2 d-none d-lg-block">
<span class="text-default">Dade Murphy</span>
</span>
</a>
<div class="dropdown-menu dropdown-menu-right dropdown-menu-arrow">
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-user"></i> Profile
</a>
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-settings"></i> Settings
</a>
<a class="dropdown-item" href="#">
<span class="float-right"><span class="badge badge-primary">6</span></span>
<i class="dropdown-icon fe fe-mail"></i> Inbox
</a>
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-send"></i> Message
</a>
<div class="dropdown-divider"></div>
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-help-circle"></i> Need help?
</a>
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-log-out"></i> Sign out
</a>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="header-nav d-none d-lg-flex">
<div class="container">
<div class="row align-items-center">
<div class="col">
<ul class="nav nav-tabs">
<li class="nav-item">
<a href="./index.html" class="nav-link active"><i class="fe fe-home"></i> Home</a>
</li>
<li class="nav-item">
<a href="javascript:void(0)" class="nav-link"><i class="fe fe-box"></i> Contracts</a>
</li>
<li class="nav-item">
<a href="./docs/index.html" class="nav-link"><i class="fe fe-file-text"></i> Documentation</a>
</li>
</ul>
</div>
<div class="col-3 ml-auto">
<form class="input-icon">
<input type="search" class="form-control header-search" placeholder="Search&hellip;" tabindex="1">
<div class="input-icon-addon">
<i class="fe fe-search"></i>
</div>
</form>
</div>
</div>
</div>
</div>
<div class="page-content">
<div class="container">
<div class="page-header">
<h1 class="page-title">
Dashboard
</h1>
</div>
<div class="row row-cards">
<div class="col-sm-6 col-lg-3">
<div class="card p-3">
<div class="d-flex align-items-center">
<span class="stamp stamp-md bg-blue mr-3">
<i class="fe fa-cube"></i>
</span>
<div>
<h4 class="m-0"><a href="javascript:void(0)">IPFS</a></h4>
<small class="text-muted">version 2.5</small>
</div>
</div>
</div>
</div>
<div class="col-sm-6 col-lg-3">
<div class="card p-3">
<div class="d-flex align-items-center">
<span class="stamp stamp-md bg-green mr-3">
<i class="fe fe-check"></i>
</span>
<div>
<h4 class="m-0"><a href="javascript:void(0)">Ethereum</a></h4>
<small class="text-muted">Geth 1.6.7-stable</small>
</div>
</div>
</div>
</div>
<div class="col-sm-6 col-lg-3">
<div class="card p-3">
<div class="d-flex align-items-center">
<span class="stamp stamp-md bg-red mr-3">
<i class="fe fe-message-square"></i>
</span>
<div>
<h4 class="m-0"><a href="javascript:void(0)">Whisper</a></h4>
<small class="text-muted">V5</small>
</div>
</div>
</div>
</div>
<div class="col-sm-6 col-lg-3">
<div class="card p-3">
<div class="d-flex align-items-center">
<span class="stamp stamp-md bg-yellow mr-3">
<i class="fe fe-server"></i>
</span>
<div>
<h4 class="m-0"><a href="javascript:void(0)">Webserver</a></h4>
<small class="text-muted">http://localhost:8000</small>
</div>
</div>
</div>
</div>
</div>
<div class="row row-cards row-deck">
<div class="col-12">
<div class="card">
<div class="card-header">
<h3 class="card-title">Contracts</h3>
</div>
<div class="table-responsive">
<table class="table card-table table-vcenter text-nowrap">
<thead>
<tr>
<th>Contract Name</th>
<th>Address</th>
<th>Status</th>
<th></th>
<th></th>
</tr>
</thead>
<tbody id="contractsTable">
</tbody>
</table>
</div>
</div>
</div>
</div>
<div class="row row-cards row-deck">
<div class="col-12">
<div class="card">
<div class="card-header">
<h3 class="card-title">Console</h3>
</div>
<div class="card-body">
<div class="log">
<p>Welcome!</p>
</div>
<div class="command-line">
<div class="form-group">
<input type="text" class="form-control" name="example-text-input" placeholder="type a command (e.g help)" data-com.agilebits.onepassword.user-edited="yes">
</div>
</div>
</div>
</div>
</div>
</div>
<script>
$.get( "/embark/contracts").done(function( data ) {
$.each(data, function(i, contract) {
let $tr = $('<tr>');
if (contract.deploy === false) {
$tr.append(
$(`<td><a href="contracts/view.html?${contract.name}">${contract.name}</a>`),
$('<td>').text('Interface or set to not deploy'),
$('<td>').text('n/a'),
);
} else if (contract.error) {
$tr.append(
$(`<td><a href="contracts/view.html?${contract.name}">${contract.name}</a>`),
$('<td>').text((contract.error).split("\n")[0].replace(/Error: /g, '').substring(0, 32)),
$('<td>').text('Error'),
);
} else {
$tr.append(
$(`<td><a href="contracts/view.html?${contract.name}">${contract.name}</a>`),
$('<td>').text(contract.address || '...'),
$('<td>').text(contract.address !== undefined ? 'Deployed' : 'Pending')
);
}
$tr.append(
$('<td class="text-right"><a href="javascript:void(0)" class="btn btn-secondary btn-sm">Manage</a><div class="dropdown"><button class="btn btn-secondary btn-sm dropdown-toggle" data-toggle="dropdown">Actions</button></div></td>'),
$('<td><a class="icon" href="javascript:void(0)"><i class="fe fe-edit"></i></a></td>')
);
$tr.appendTo('#contractsTable');
});
});
var ws = new WebSocket("ws://localhost:8000/embark/logs");
ws.onopen = function() {
};
ws.onmessage = function (evt) {
var received_msg = evt.data;
var log = JSON.parse(received_msg);
console.log(log);
$(".log").append('<br>[' + log.logLevel + '] ' + log.msg_clear);
};
ws.onclose = function() {
console.log("Connection is closed...");
};
window.onbeforeunload = function(event) {
ws.close();
};
$(".command-line input").keypress(function(e) {
if (e.which == 13) {
let value = $(".command-line input").val();
$.post( "/embark/console", { cmd: value }).done(function( data ) {
$(".log").append('<br>' + data.replace(/\n/g, '<br>'));
});
$(".command-line input").val('');
}
});
</script>
</div>
</div>
</div>
<footer class="footer">
<div class="container">
<div class="row align-items-center flex-row-reverse">
<div class="col-auto ml-auto">
<div class="row align-items-center">
<div class="col-auto">
<ul class="list-inline list-inline-dots mb-0">
<li class="list-inline-item"><a href="./docs/index.html">Documentation</a></li>
<li class="list-inline-item"><a href="./faq.html">FAQ</a></li>
</ul>
</div>
<div class="col-auto">
<a href="https://github.com/tabler/tabler" class="btn btn-outline-primary btn-sm">Source code</a>
</div>
</div>
</div>
<div class="col-12 col-lg-auto mt-3 mt-lg-0 text-center">
Copyright © 2018 <a href=".">Status Embark</a>.
</div>
</div>
</div>
</footer>
</div>
</body>
</html>

View File

@ -107,10 +107,8 @@ class TemplateGenerator {
utils.sed('package.json', '%APP_NAME%', name);
if (fs.existsSync('dot.gitignore')) {
fs.moveSync('dot.gitignore', '.gitignore');
}
if (fs.existsSync('dot.gitignore')) {
fs.moveSync('dot.gitignore', '.gitignore');
} else if (!fs.existsSync('.gitignore')) {
fs.copySync(fs.embarkPath('templates/dot.gitignore'), '.gitignore');
}
if (installPackages) {

306
npm-shrinkwrap.json generated
View File

@ -16617,6 +16617,312 @@
"standard": "^10.0.3",
"web3": "1.0.0-beta.34",
"winston": "^3.0.0"
},
"dependencies": {
"bn.js": {
"version": "4.11.6",
"resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.11.6.tgz",
"integrity": "sha1-UzRK2xRhehP26N0s4okF0cC6MhU="
},
"debug": {
"version": "2.6.9",
"resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz",
"integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==",
"requires": {
"ms": "2.0.0"
}
},
"eth-lib": {
"version": "0.1.27",
"resolved": "https://registry.npmjs.org/eth-lib/-/eth-lib-0.1.27.tgz",
"integrity": "sha512-B8czsfkJYzn2UIEMwjc7Mbj+Cy72V+/OXH/tb44LV8jhrjizQJJ325xMOMyk3+ETa6r6oi0jsUY14+om8mQMWA==",
"requires": {
"bn.js": "^4.11.6",
"elliptic": "^6.4.0",
"keccakjs": "^0.2.1",
"nano-json-stream-parser": "^0.1.2",
"servify": "^0.1.12",
"ws": "^3.0.0",
"xhr-request-promise": "^0.1.2"
}
},
"eventemitter3": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-1.1.1.tgz",
"integrity": "sha1-R3hr2qCHyvext15zq8XH1UAVjNA="
},
"underscore": {
"version": "1.8.3",
"resolved": "https://registry.npmjs.org/underscore/-/underscore-1.8.3.tgz",
"integrity": "sha1-Tz+1OxBuYJf8+ctBCfKl6b36UCI="
},
"utf8": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/utf8/-/utf8-2.1.1.tgz",
"integrity": "sha1-LgHbAvfY0JRPdxBPFgnrDDBM92g="
},
"uuid": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/uuid/-/uuid-2.0.1.tgz",
"integrity": "sha1-wqMN7bPlNdcsz4LjQ5QaULqFM6w="
},
"web3": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3/-/web3-1.0.0-beta.34.tgz",
"integrity": "sha1-NH5WG3hAmMtVYzFfSQR5odkfKrE=",
"requires": {
"web3-bzz": "1.0.0-beta.34",
"web3-core": "1.0.0-beta.34",
"web3-eth": "1.0.0-beta.34",
"web3-eth-personal": "1.0.0-beta.34",
"web3-net": "1.0.0-beta.34",
"web3-shh": "1.0.0-beta.34",
"web3-utils": "1.0.0-beta.34"
}
},
"web3-bzz": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-bzz/-/web3-bzz-1.0.0-beta.34.tgz",
"integrity": "sha1-Bo03d3q2Xlxg+OyLmlDP5FJ3kpw=",
"requires": {
"got": "7.1.0",
"swarm-js": "0.1.37",
"underscore": "1.8.3"
}
},
"web3-core": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-core/-/web3-core-1.0.0-beta.34.tgz",
"integrity": "sha1-EhvoVV6fsA0sXQXd0zgdDJ5GmH4=",
"requires": {
"web3-core-helpers": "1.0.0-beta.34",
"web3-core-method": "1.0.0-beta.34",
"web3-core-requestmanager": "1.0.0-beta.34",
"web3-utils": "1.0.0-beta.34"
}
},
"web3-core-helpers": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-core-helpers/-/web3-core-helpers-1.0.0-beta.34.tgz",
"integrity": "sha1-sWjaANPhnhVrwVriAyA91N/uLQM=",
"requires": {
"underscore": "1.8.3",
"web3-eth-iban": "1.0.0-beta.34",
"web3-utils": "1.0.0-beta.34"
}
},
"web3-core-method": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-core-method/-/web3-core-method-1.0.0-beta.34.tgz",
"integrity": "sha1-7BY8iixJD6AqfsFVWfpzB/x8xt0=",
"requires": {
"underscore": "1.8.3",
"web3-core-helpers": "1.0.0-beta.34",
"web3-core-promievent": "1.0.0-beta.34",
"web3-core-subscriptions": "1.0.0-beta.34",
"web3-utils": "1.0.0-beta.34"
}
},
"web3-core-promievent": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-core-promievent/-/web3-core-promievent-1.0.0-beta.34.tgz",
"integrity": "sha1-pPT6Z4S7KT6CxglgrltWqUzQPtw=",
"requires": {
"any-promise": "1.3.0",
"eventemitter3": "1.1.1"
}
},
"web3-core-requestmanager": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-core-requestmanager/-/web3-core-requestmanager-1.0.0-beta.34.tgz",
"integrity": "sha1-Afj2zyrmtvC3DDi64e90G1urIVw=",
"requires": {
"underscore": "1.8.3",
"web3-core-helpers": "1.0.0-beta.34",
"web3-providers-http": "1.0.0-beta.34",
"web3-providers-ipc": "1.0.0-beta.34",
"web3-providers-ws": "1.0.0-beta.34"
}
},
"web3-core-subscriptions": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-core-subscriptions/-/web3-core-subscriptions-1.0.0-beta.34.tgz",
"integrity": "sha1-n+0UQDPyIcPPIQYDAv/a9e8t4t4=",
"requires": {
"eventemitter3": "1.1.1",
"underscore": "1.8.3",
"web3-core-helpers": "1.0.0-beta.34"
}
},
"web3-eth": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-eth/-/web3-eth-1.0.0-beta.34.tgz",
"integrity": "sha1-dAhgAIUMb+b1Ne9Jg31tS7YRMmg=",
"requires": {
"underscore": "1.8.3",
"web3-core": "1.0.0-beta.34",
"web3-core-helpers": "1.0.0-beta.34",
"web3-core-method": "1.0.0-beta.34",
"web3-core-subscriptions": "1.0.0-beta.34",
"web3-eth-abi": "1.0.0-beta.34",
"web3-eth-accounts": "1.0.0-beta.34",
"web3-eth-contract": "1.0.0-beta.34",
"web3-eth-iban": "1.0.0-beta.34",
"web3-eth-personal": "1.0.0-beta.34",
"web3-net": "1.0.0-beta.34",
"web3-utils": "1.0.0-beta.34"
}
},
"web3-eth-abi": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-eth-abi/-/web3-eth-abi-1.0.0-beta.34.tgz",
"integrity": "sha1-A0Uz46ovfln/MXk+rqaFwO1a9no=",
"requires": {
"bn.js": "4.11.6",
"underscore": "1.8.3",
"web3-core-helpers": "1.0.0-beta.34",
"web3-utils": "1.0.0-beta.34"
}
},
"web3-eth-accounts": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-eth-accounts/-/web3-eth-accounts-1.0.0-beta.34.tgz",
"integrity": "sha1-4JFC7uzHl6w0WbdemyOUbTaV8zM=",
"requires": {
"any-promise": "1.3.0",
"crypto-browserify": "3.12.0",
"eth-lib": "0.2.7",
"scrypt.js": "0.2.0",
"underscore": "1.8.3",
"uuid": "2.0.1",
"web3-core": "1.0.0-beta.34",
"web3-core-helpers": "1.0.0-beta.34",
"web3-core-method": "1.0.0-beta.34",
"web3-utils": "1.0.0-beta.34"
},
"dependencies": {
"eth-lib": {
"version": "0.2.7",
"resolved": "https://registry.npmjs.org/eth-lib/-/eth-lib-0.2.7.tgz",
"integrity": "sha1-L5Pxex4jrsN1nNSj/iDBKGo/wco=",
"requires": {
"bn.js": "^4.11.6",
"elliptic": "^6.4.0",
"xhr-request-promise": "^0.1.2"
}
}
}
},
"web3-eth-contract": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-eth-contract/-/web3-eth-contract-1.0.0-beta.34.tgz",
"integrity": "sha1-nbs4+udkOoCEJ6IBgEcOx0FckeY=",
"requires": {
"underscore": "1.8.3",
"web3-core": "1.0.0-beta.34",
"web3-core-helpers": "1.0.0-beta.34",
"web3-core-method": "1.0.0-beta.34",
"web3-core-promievent": "1.0.0-beta.34",
"web3-core-subscriptions": "1.0.0-beta.34",
"web3-eth-abi": "1.0.0-beta.34",
"web3-utils": "1.0.0-beta.34"
}
},
"web3-eth-iban": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-eth-iban/-/web3-eth-iban-1.0.0-beta.34.tgz",
"integrity": "sha1-mvRYYFhnzPdOqXmq8yazi6alugw=",
"requires": {
"bn.js": "4.11.6",
"web3-utils": "1.0.0-beta.34"
}
},
"web3-eth-personal": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-eth-personal/-/web3-eth-personal-1.0.0-beta.34.tgz",
"integrity": "sha1-mvuhZzQuveVCC81YlcP2w0OI8gU=",
"requires": {
"web3-core": "1.0.0-beta.34",
"web3-core-helpers": "1.0.0-beta.34",
"web3-core-method": "1.0.0-beta.34",
"web3-net": "1.0.0-beta.34",
"web3-utils": "1.0.0-beta.34"
}
},
"web3-net": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-net/-/web3-net-1.0.0-beta.34.tgz",
"integrity": "sha1-QnzqL0MYgUScjjjVIykPFz+f9j0=",
"requires": {
"web3-core": "1.0.0-beta.34",
"web3-core-method": "1.0.0-beta.34",
"web3-utils": "1.0.0-beta.34"
}
},
"web3-providers-http": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-providers-http/-/web3-providers-http-1.0.0-beta.34.tgz",
"integrity": "sha1-5WG1K7tDdmKCAH1AKFv+NVDCfno=",
"requires": {
"web3-core-helpers": "1.0.0-beta.34",
"xhr2": "0.1.4"
}
},
"web3-providers-ipc": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-providers-ipc/-/web3-providers-ipc-1.0.0-beta.34.tgz",
"integrity": "sha1-obd/GjBtc2SanAOQUuQMtxMo0Ao=",
"requires": {
"oboe": "2.1.3",
"underscore": "1.8.3",
"web3-core-helpers": "1.0.0-beta.34"
}
},
"web3-providers-ws": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-providers-ws/-/web3-providers-ws-1.0.0-beta.34.tgz",
"integrity": "sha1-fecPG4Py3jZHZ3IVa+z+9uNRbrM=",
"requires": {
"underscore": "1.8.3",
"web3-core-helpers": "1.0.0-beta.34",
"websocket": "git://github.com/frozeman/WebSocket-Node.git#6c72925e3f8aaaea8dc8450f97627e85263999f2"
}
},
"web3-shh": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-shh/-/web3-shh-1.0.0-beta.34.tgz",
"integrity": "sha1-l1Bh1x6uxCzO5Xb3vY9w8DhEr+A=",
"requires": {
"web3-core": "1.0.0-beta.34",
"web3-core-method": "1.0.0-beta.34",
"web3-core-subscriptions": "1.0.0-beta.34",
"web3-net": "1.0.0-beta.34"
}
},
"web3-utils": {
"version": "1.0.0-beta.34",
"resolved": "https://registry.npmjs.org/web3-utils/-/web3-utils-1.0.0-beta.34.tgz",
"integrity": "sha1-lBH8OarvOcpOBhafdiKX2f8CCXA=",
"requires": {
"bn.js": "4.11.6",
"eth-lib": "0.1.27",
"ethjs-unit": "0.1.6",
"number-to-bn": "1.7.0",
"randomhex": "0.1.5",
"underscore": "1.8.3",
"utf8": "2.1.1"
}
},
"websocket": {
"version": "git://github.com/frozeman/WebSocket-Node.git#6c72925e3f8aaaea8dc8450f97627e85263999f2",
"from": "git://github.com/frozeman/WebSocket-Node.git#browserifyCompatible",
"requires": {
"debug": "^2.2.0",
"nan": "^2.3.3",
"typedarray-to-buffer": "^3.1.2",
"yaeti": "^0.0.6"
}
}
}
},
"remove-trailing-separator": {

8
templates/.gitignore vendored Normal file
View File

@ -0,0 +1,8 @@
**/.embark
**/chains.json
**/config/production/password
**/config/livenet/password
**/coverage
**/dist
**/package-lock.json
**/node_modules

View File

@ -1,5 +0,0 @@
.embark/
node_modules/
dist/
config/production/password
config/livenet/password

View File

@ -1,5 +0,0 @@
.embark/
node_modules/
dist/
config/production/password
config/livenet/password

View File

@ -1,7 +1,7 @@
.embark/
node_modules/
dist/
.embark
chains.json
config/production/password
config/livenet/password
coverage/
chains.json
coverage
dist
node_modules

View File

@ -1,5 +0,0 @@
.embark/
node_modules/
dist/
config/production/password
config/livenet/password

7
test_apps/.gitignore vendored Normal file
View File

@ -0,0 +1,7 @@
**/.embark
**/chains.json
**/config/production/password
**/config/livenet/password
**/coverage
**/dist
**/node_modules

View File

@ -1,6 +0,0 @@
.embark/
node_modules/
dist/
config/production/password
config/livenet/password
build/

View File

@ -1,5 +0,0 @@
.embark/
node_modules/
dist/
config/production/password
config/livenet/password

View File

@ -1,6 +0,0 @@
.embark/
node_modules/
dist/
config/production/password
config/livenet/password
coverage/