Merge pull request #419 from NebulousLabs/dependabot/npm_and_yarn/packages/webapp/skynet-js-2.0.4

This commit is contained in:
dependabot[bot] 2020-09-24 11:14:48 +00:00 committed by GitHub
commit 98782f8f56
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 69 additions and 48 deletions

View File

@ -32,7 +32,7 @@
"react-mailchimp-subscribe": "2.1.0",
"react-syntax-highlighter": "13.5.3",
"react-visibility-sensor": "5.1.1",
"skynet-js": "0.0.8",
"skynet-js": "2.0.4",
"typeface-metropolis": "0.0.74"
},
"devDependencies": {

View File

@ -8,7 +8,7 @@ import { Button, UploadFile } from "../";
import { Deco3, Deco4, Deco5, Folder, DownArrow } from "../../svg";
import "./HomeUpload.scss";
import AppContext from "../../AppContext";
import SkynetClient, { parseSkylink } from "skynet-js";
import { SkynetClient, parseSkylink } from "skynet-js";
const isValidSkylink = (skylink) => {
try {
@ -127,10 +127,10 @@ export default function HomeUpload() {
response = await client.uploadDirectory(directory, encodeURIComponent(file.name), { onUploadProgress });
} else {
response = await client.upload(file, { onUploadProgress });
response = await client.uploadFile(file, { onUploadProgress });
}
onFileStateChange(file, { status: "complete", url: client.getUrl(response.skylink) });
onFileStateChange(file, { status: "complete", url: client.getSkylinkUrl(response) });
} catch (error) {
if (error.response && error.response.status === StatusCodes.TOO_MANY_REQUESTS) {
onFileStateChange(file, { progress: -1 });
@ -153,7 +153,7 @@ export default function HomeUpload() {
// only try to open a valid skylink
if (isValidSkylink(skylink)) {
client.open(skylink);
client.openFile(skylink);
}
};

107
yarn.lock
View File

@ -948,7 +948,7 @@
core-js-pure "^3.0.0"
regenerator-runtime "^0.13.4"
"@babel/runtime@^7.0.0", "@babel/runtime@^7.10.0", "@babel/runtime@^7.10.2", "@babel/runtime@^7.10.3", "@babel/runtime@^7.3.1", "@babel/runtime@^7.5.5", "@babel/runtime@^7.7.2", "@babel/runtime@^7.8.4":
"@babel/runtime@^7.0.0", "@babel/runtime@^7.10.0", "@babel/runtime@^7.10.2", "@babel/runtime@^7.10.3", "@babel/runtime@^7.11.2", "@babel/runtime@^7.3.1", "@babel/runtime@^7.5.5", "@babel/runtime@^7.7.2", "@babel/runtime@^7.8.4":
version "7.11.2"
resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.11.2.tgz#f549c13c754cc40b87644b9fa9f09a6a95fe0736"
integrity sha512-TeWkU52so0mPtDcaCTxNBI/IHiz0pZgr8VEFqXFtZWpYD08ZB6FaSwVAS8MKRQAP3bYKiVjwysOJgMFY28o6Tw==
@ -2833,7 +2833,7 @@ axe-core@^3.5.4:
resolved "https://registry.yarnpkg.com/axe-core/-/axe-core-3.5.5.tgz#84315073b53fa3c0c51676c588d59da09a192227"
integrity sha512-5P0QZ6J5xGikH780pghEdbEKijCTrruK9KxtPZCFWUpef0f6GipO+xEZ5GKCb020mmqgbiNO6TcA55CriL784Q==
axios@0.20.0:
axios@0.20.0, axios@^0.20.0:
version "0.20.0"
resolved "https://registry.yarnpkg.com/axios/-/axios-0.20.0.tgz#057ba30f04884694993a8cd07fa394cff11c50bd"
integrity sha512-ANA4rr2BDcmmAQLOKft2fufrtuvlqR+cXNNinUmvfeSNCOF98PZL+7M/v1zIdGo7OLjEA9J2gXJL+j4zGsl0bA==
@ -6733,6 +6733,19 @@ gatsby-core-utils@^1.3.19:
tmp "^0.2.1"
xdg-basedir "^4.0.0"
gatsby-core-utils@^1.3.20:
version "1.3.20"
resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-1.3.20.tgz#3fee11634ec457f01d1327da885a9f8fe50c6823"
integrity sha512-tTry2Iz7QKfMEkYiqXOEbMhR96hpttkKeUCQAj7syC9tQwFGd1nkGlpbD4n8lBa22cXKLlL9J2edhDo1xwnfGQ==
dependencies:
ci-info "2.0.0"
configstore "^5.0.1"
fs-extra "^8.1.0"
node-object-hash "^2.0.0"
proper-lockfile "^4.1.1"
tmp "^0.2.1"
xdg-basedir "^4.0.0"
gatsby-design-tokens@^2.0.2:
version "2.0.10"
resolved "https://registry.yarnpkg.com/gatsby-design-tokens/-/gatsby-design-tokens-2.0.10.tgz#cade197f538f93196b4e2253e48f09b9cac6cf68"
@ -6747,12 +6760,12 @@ gatsby-graphiql-explorer@^0.4.13:
dependencies:
"@babel/runtime" "^7.10.3"
gatsby-image@2.4.17:
version "2.4.17"
resolved "https://registry.yarnpkg.com/gatsby-image/-/gatsby-image-2.4.17.tgz#8eeb49f6a0fbc367f88b66f7f9a56c5c9ec4c430"
integrity sha512-DPt5fNzTwBx7k5RQAsbU30O8mGtw9lDDYF0xrD1N/++B4dT5ZfUb10sfxwyBv2GRaSjClFkqED6aDihwkHOOfg==
gatsby-image@2.4.19:
version "2.4.19"
resolved "https://registry.yarnpkg.com/gatsby-image/-/gatsby-image-2.4.19.tgz#c501439ce7973bfb7c17217bc9e26aa6f90c6072"
integrity sha512-LThyQk3ylD8MrK/6TY46Cl8ihvWqIGf15gB6X4UphOxaU+3ZVy6mJUumFIt5ZxFEBhGoHI8lmymBItwMwcsqcg==
dependencies:
"@babel/runtime" "^7.10.3"
"@babel/runtime" "^7.11.2"
object-fit-images "^3.2.4"
prop-types "^15.7.2"
@ -6806,13 +6819,13 @@ gatsby-page-utils@^0.2.24:
lodash "^4.17.20"
micromatch "^3.1.10"
gatsby-plugin-manifest@2.4.28:
version "2.4.28"
resolved "https://registry.yarnpkg.com/gatsby-plugin-manifest/-/gatsby-plugin-manifest-2.4.28.tgz#f65a0f60e15112829981607df54b46faa09a3257"
integrity sha512-/8huYUzf0L8N5g3FlVlpCkV+nycBajU8nrbEfJTH/VecxGPlDJrHJ/WRM8lG+/XwpPnEwddFiZ6BBgHdIQEn3Q==
gatsby-plugin-manifest@2.4.30:
version "2.4.30"
resolved "https://registry.yarnpkg.com/gatsby-plugin-manifest/-/gatsby-plugin-manifest-2.4.30.tgz#a5edca7bdf898a6f06e33969ab4e21f7438438aa"
integrity sha512-ZcQcQRH/VNomRKlOPH/HkwzzJM0XmXw5egYYsVjf8TMtZka3/FDZucIGTeTLv7FZwdMSF2sGJrHU+nx3PrhCUQ==
dependencies:
"@babel/runtime" "^7.10.3"
gatsby-core-utils "^1.3.19"
"@babel/runtime" "^7.11.2"
gatsby-core-utils "^1.3.20"
semver "^7.3.2"
sharp "^0.25.4"
@ -6835,12 +6848,12 @@ gatsby-plugin-page-creator@^2.3.27:
graphql "^14.6.0"
lodash "^4.17.20"
gatsby-plugin-react-helmet@3.3.10:
version "3.3.10"
resolved "https://registry.yarnpkg.com/gatsby-plugin-react-helmet/-/gatsby-plugin-react-helmet-3.3.10.tgz#ba2f84715cc2471606b90327c7c3ba11c5287bc7"
integrity sha512-AcXYwmS3r298JWs6iQ3OLNxIe8L8i5a2iSdLr/SDMpHqumYm7q/vB9kCX0et5wM7DIuZ7aPXDrdi5yDCAvU5lg==
gatsby-plugin-react-helmet@3.3.11:
version "3.3.11"
resolved "https://registry.yarnpkg.com/gatsby-plugin-react-helmet/-/gatsby-plugin-react-helmet-3.3.11.tgz#f49d31abfc5e4b31e81226d82b7b5e9c1b71f797"
integrity sha512-O9CBmxSAE/ODCKj5fGITP5zAVguD83+fIWQPgEzur+lwnvRyXoJBfMjKQezMECvWVv5UOfTwTL1/dcU87+UNkA==
dependencies:
"@babel/runtime" "^7.10.3"
"@babel/runtime" "^7.11.2"
gatsby-plugin-remove-serviceworker@1.0.0:
version "1.0.0"
@ -6855,24 +6868,24 @@ gatsby-plugin-robots-txt@1.5.1:
"@babel/runtime" "^7.10.0"
generate-robotstxt "^8.0.3"
gatsby-plugin-sass@2.3.12:
version "2.3.12"
resolved "https://registry.yarnpkg.com/gatsby-plugin-sass/-/gatsby-plugin-sass-2.3.12.tgz#4ebdf2d541004e60a5d108eb1302a43b16ceeeaf"
integrity sha512-cQHp4bvK3a0xId4Q9K9/1ejGVMMOm/1I28ry7quVoHVomSB4SwNJpMTGSgSYAKn3gjsveUyL+ceCRWeiIavkPA==
gatsby-plugin-sass@2.3.13:
version "2.3.13"
resolved "https://registry.yarnpkg.com/gatsby-plugin-sass/-/gatsby-plugin-sass-2.3.13.tgz#8cefc3b32a0b1dba54ab63f95a84ae5b73c8f802"
integrity sha512-lxxJjW0bNGidjS0NA1QedoJUwr889OTDQllDxGP65A2XK/CdR5AencijfXr3CD9aDGREGF5GkL+TS9oYKSqegQ==
dependencies:
"@babel/runtime" "^7.10.3"
"@babel/runtime" "^7.11.2"
sass-loader "^7.3.1"
gatsby-plugin-sharp@2.6.35:
version "2.6.35"
resolved "https://registry.yarnpkg.com/gatsby-plugin-sharp/-/gatsby-plugin-sharp-2.6.35.tgz#d37e08f453784e39d7b1c2a759b801fdd4e633c4"
integrity sha512-5y2ut8TGg5iIfDMnVm/WRy37vjSlHzMdJVugvB4lp4NH69FIq75JpaivshtjQYEi3cc5UonXOQWZJ6aSsM54pQ==
gatsby-plugin-sharp@2.6.36:
version "2.6.36"
resolved "https://registry.yarnpkg.com/gatsby-plugin-sharp/-/gatsby-plugin-sharp-2.6.36.tgz#1b2489d76078dc371ec5808915c58dcd360d202b"
integrity sha512-iOm9nQiDyLSA2ol8Xde4XSj+lJJ5bdlilkNCr3rTbvSoPV8qJ8Zj4RxLZ48Rgy9cVNbgibSZQzitM9bIfVijkA==
dependencies:
"@babel/runtime" "^7.10.3"
"@babel/runtime" "^7.11.2"
async "^3.2.0"
bluebird "^3.7.2"
fs-extra "^9.0.1"
gatsby-core-utils "^1.3.19"
gatsby-core-utils "^1.3.20"
got "^10.7.0"
imagemin "^7.0.1"
imagemin-mozjpeg "^9.0.0"
@ -9326,10 +9339,10 @@ lines-and-columns@^1.1.6:
resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.1.6.tgz#1c00c743b433cd0a4e80758f7b64a57440d9ff00"
integrity sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA=
lint-staged@10.3.0:
version "10.3.0"
resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-10.3.0.tgz#388c3d440590c45c339e7163f669ea69ae90b1e0"
integrity sha512-an3VgjHqmJk0TORB/sdQl0CTkRg4E5ybYCXTTCSJ5h9jFwZbcgKIx5oVma5e7wp/uKt17s1QYFmYqT9MGVosGw==
lint-staged@10.4.0:
version "10.4.0"
resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-10.4.0.tgz#d18628f737328e0bbbf87d183f4020930e9a984e"
integrity sha512-uaiX4U5yERUSiIEQc329vhCTDDwUcSvKdRLsNomkYLRzijk3v8V9GWm2Nz0RMVB87VcuzLvtgy6OsjoH++QHIg==
dependencies:
chalk "^4.1.0"
cli-truncate "^2.1.0"
@ -11237,7 +11250,7 @@ path-browserify@0.0.1:
resolved "https://registry.yarnpkg.com/path-browserify/-/path-browserify-0.0.1.tgz#e6c4ddd7ed3aa27c68a20cc4e50e1a4ee83bbc4a"
integrity sha512-BapA40NHICOS+USX9SN4tyhq+A2RrN/Ws5F0Z5aMHDp98Fl86lX8Oti8B7uN93L4Ifv4fHOEA+pQw87gmMO/lQ==
path-browserify@1.0.1:
path-browserify@1.0.1, path-browserify@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/path-browserify/-/path-browserify-1.0.1.tgz#d98454a9c3753d5790860f16f68867b9e46be1fd"
integrity sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==
@ -11853,10 +11866,10 @@ prepend-http@^2.0.0:
resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-2.0.0.tgz#e92434bfa5ea8c19f41cdfd401d741a3c819d897"
integrity sha1-6SQ0v6XqjBn0HN/UAddBo8gZ2Jc=
prettier@2.1.1:
version "2.1.1"
resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.1.1.tgz#d9485dd5e499daa6cb547023b87a6cf51bee37d6"
integrity sha512-9bY+5ZWCfqj3ghYBLxApy2zf6m+NJo5GzmLTpr9FsApsfjriNnS2dahWReHMi7qNPhhHl9SYHJs2cHZLgexNIw==
prettier@2.1.2:
version "2.1.2"
resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.1.2.tgz#3050700dae2e4c8b67c4c3f666cdb8af405e1ce5"
integrity sha512-16c7K+x4qVlJg9rEbXl7HEGmQyZlG4R9AgP+oHKRMsMsuk8s+ATStlf1NpDqyBI1HpVyfjLOeMhH2LvuNvV5Vg==
prettier@^2.0.5:
version "2.0.5"
@ -13437,12 +13450,15 @@ sisteransi@^1.0.4:
resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-1.0.5.tgz#134d681297756437cc05ca01370d3a7a571075ed"
integrity sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==
skynet-js@0.0.8:
version "0.0.8"
resolved "https://registry.yarnpkg.com/skynet-js/-/skynet-js-0.0.8.tgz#e7c7b17d382b1e626fa4b547876cb1f7b7ed3130"
integrity sha512-rKYEPzw8P1zwsMvWOWdaPK8J9Wf6FgnKM8qEFHLnBVUk4n5ImnXlfWHKSz8sAniOAaZS8cBuHdZD0U43rldMzw==
skynet-js@2.0.4:
version "2.0.4"
resolved "https://registry.yarnpkg.com/skynet-js/-/skynet-js-2.0.4.tgz#4dd1dc83867faf00ace2e6564ed0e3d9def244ff"
integrity sha512-3J0/E6YfEzZfDR/BRaHslMgu3uRjULu/FaShvHHhOUBOma0a6I5pLOh1TMcqNlBYs358RewRPZP7ZocNRukSnw==
dependencies:
axios "^0.19.2"
"@babel/runtime" "^7.11.2"
axios "^0.20.0"
path-browserify "^1.0.1"
url-join "^4.0.1"
url-parse "^1.4.7"
slash@^3.0.0:
@ -14984,6 +15000,11 @@ urix@^0.1.0:
resolved "https://registry.yarnpkg.com/urix/-/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72"
integrity sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI=
url-join@^4.0.1:
version "4.0.1"
resolved "https://registry.yarnpkg.com/url-join/-/url-join-4.0.1.tgz#b642e21a2646808ffa178c4c5fda39844e12cde7"
integrity sha512-jk1+QP6ZJqyOiuEI9AEWQfju/nB2Pw466kbA0LEZljHwKeMgd9WrAEgEGxjPDD2+TNbbb37rTyhEfrCXfuKXnA==
url-loader@^1.1.2:
version "1.1.2"
resolved "https://registry.yarnpkg.com/url-loader/-/url-loader-1.1.2.tgz#b971d191b83af693c5e3fea4064be9e1f2d7f8d8"