From 3e2f7eab3b64e6eee575b7c4c41f7f76724661f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 22 Mar 2022 13:46:04 +0100 Subject: [PATCH 001/240] fix(dashboard-v2): styling fixes for Slider component --- .../src/components/Slider/Bullets.js | 2 +- .../src/components/Slider/Slide.js | 2 +- .../src/components/Slider/Slider.js | 23 +++++++++++++++---- 3 files changed, 21 insertions(+), 6 deletions(-) diff --git a/packages/dashboard-v2/src/components/Slider/Bullets.js b/packages/dashboard-v2/src/components/Slider/Bullets.js index d7dff453..c090cef4 100644 --- a/packages/dashboard-v2/src/components/Slider/Bullets.js +++ b/packages/dashboard-v2/src/components/Slider/Bullets.js @@ -6,7 +6,7 @@ export default function Bullets({ visibleSlides, activeIndex, allSlides, changeS } return ( -
+
{Array(allSlides - visibleSlides + 1) .fill(null) .map((_, index) => ( diff --git a/packages/dashboard-v2/src/components/Slider/Slide.js b/packages/dashboard-v2/src/components/Slider/Slide.js index 4f700502..42d354ff 100644 --- a/packages/dashboard-v2/src/components/Slider/Slide.js +++ b/packages/dashboard-v2/src/components/Slider/Slide.js @@ -2,7 +2,7 @@ import styled from "styled-components"; import PropTypes from "prop-types"; const Slide = styled.div.attrs(({ isVisible }) => ({ - className: `slider-slide transition-opacity ${isVisible ? "" : "opacity-50 cursor-pointer"}`, + className: `slider-slide transition-opacity ${isVisible ? "" : "opacity-50 cursor-pointer select-none"}`, }))``; Slide.propTypes = { diff --git a/packages/dashboard-v2/src/components/Slider/Slider.js b/packages/dashboard-v2/src/components/Slider/Slider.js index ae311242..973b9941 100644 --- a/packages/dashboard-v2/src/components/Slider/Slider.js +++ b/packages/dashboard-v2/src/components/Slider/Slider.js @@ -22,12 +22,12 @@ const scrollableStyles = css` `; const Scroller = styled.div.attrs({ - className: "slider-scroller grid gap-4 transition-transform", + className: "slider-scroller grid transition-transform", })` ${({ $scrollable }) => ($scrollable ? scrollableStyles : "")} `; -const Slider = ({ slides, breakpoints }) => { +const Slider = ({ slides, breakpoints, scrollerClassName, className }) => { const { visibleSlides, scrollable } = useActiveBreakpoint(breakpoints); const [activeIndex, setActiveIndex] = React.useState(0); const changeSlide = React.useCallback( @@ -49,12 +49,13 @@ const Slider = ({ slides, breakpoints }) => { }, [slides.length, visibleSlides, activeIndex]); return ( - + {slides.map((slide, index) => { const isVisible = index >= activeIndex && index < activeIndex + visibleSlides; @@ -63,7 +64,11 @@ const Slider = ({ slides, breakpoints }) => {
changeSlide(event, index) : null} + onClickCapture={ + scrollable && !isVisible + ? (event) => changeSlide(event, index > activeIndex ? activeIndex + 1 : activeIndex - 1) + : null + } > {slide} @@ -101,6 +106,14 @@ Slider.propTypes = { * If set to false, all slides will be visible & rendered in a column. */ scrollable: PropTypes.bool.isRequired, + /** + * Additional class names to apply to the element. + */ + scrollerClassName: PropTypes.string, + /** + * Additional class names to apply to the element. + */ + className: PropTypes.string, }) ), }; @@ -123,6 +136,8 @@ Slider.defaultProps = { visibleSlides: 1, }, ], + scrollerClassName: "gap-4", + className: "", }; export default Slider; From f26822900f5392c4495c6f914cf0160436c8a3e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 22 Mar 2022 13:46:34 +0100 Subject: [PATCH 002/240] fix(dashboard-v2): styling fixes for Button component --- .../dashboard-v2/src/components/Button/Button.js | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/packages/dashboard-v2/src/components/Button/Button.js b/packages/dashboard-v2/src/components/Button/Button.js index c96276a1..1ea93926 100644 --- a/packages/dashboard-v2/src/components/Button/Button.js +++ b/packages/dashboard-v2/src/components/Button/Button.js @@ -6,9 +6,17 @@ import styled from "styled-components"; */ export const Button = styled.button.attrs(({ disabled, $primary }) => ({ type: "button", - className: `px-6 py-2.5 rounded-full font-sans uppercase text-xs tracking-wide text-palette-600 transition-[filter] - ${$primary ? "bg-primary" : "bg-white border-2 border-black"} - ${disabled ? "saturate-50 brightness-125 cursor-default text-palette-400" : "hover:brightness-90"}`, + className: `px-6 py-2.5 rounded-full font-sans uppercase text-xs tracking-wide transition-[filter] + ${ + $primary + ? `bg-primary ${disabled ? "" : "text-palette-600"}` + : `bg-white border-2 ${disabled ? "border-palette-300" : "border-black text-palette-600"}` + } + ${ + disabled + ? `${$primary ? "saturate-50 brightness-125 text-palette-400" : "text-palette-300"} cursor-default` + : "hover:brightness-90" + }`, }))``; Button.propTypes = { /** From c058270a791a8347d14a368ae7e863efef6c5061 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 22 Mar 2022 13:47:08 +0100 Subject: [PATCH 003/240] feat(dashboard-v2): make circle around checkmark icon optional --- .../{CircledCheckmarkIcon.js => CheckmarkIcon.js} | 11 +++++++++-- packages/dashboard-v2/src/components/Icons/index.js | 2 +- .../src/components/Uploader/UploaderItemIcon.js | 4 ++-- 3 files changed, 12 insertions(+), 5 deletions(-) rename packages/dashboard-v2/src/components/Icons/icons/{CircledCheckmarkIcon.js => CheckmarkIcon.js} (54%) diff --git a/packages/dashboard-v2/src/components/Icons/icons/CircledCheckmarkIcon.js b/packages/dashboard-v2/src/components/Icons/icons/CheckmarkIcon.js similarity index 54% rename from packages/dashboard-v2/src/components/Icons/icons/CircledCheckmarkIcon.js rename to packages/dashboard-v2/src/components/Icons/icons/CheckmarkIcon.js index 5f0cfc31..b42915de 100644 --- a/packages/dashboard-v2/src/components/Icons/icons/CircledCheckmarkIcon.js +++ b/packages/dashboard-v2/src/components/Icons/icons/CheckmarkIcon.js @@ -1,6 +1,8 @@ +import PropTypes from "prop-types"; + import { withIconProps } from "../withIconProps"; -export const CircledCheckmarkIcon = withIconProps(({ size, ...props }) => ( +export const CheckmarkIcon = withIconProps(({ size, circled, ...props }) => ( ( shapeRendering="geometricPrecision" {...props} > - + {circled && } )); + +CheckmarkIcon.propTypes = { + ...CheckmarkIcon.propTypes, + circled: PropTypes.bool, +}; diff --git a/packages/dashboard-v2/src/components/Icons/index.js b/packages/dashboard-v2/src/components/Icons/index.js index beaf1789..e2af85e9 100644 --- a/packages/dashboard-v2/src/components/Icons/index.js +++ b/packages/dashboard-v2/src/components/Icons/index.js @@ -4,7 +4,7 @@ export * from "./icons/LockClosedIcon"; export * from "./icons/SkynetLogoIcon"; export * from "./icons/ArrowRightIcon"; export * from "./icons/InfoIcon"; -export * from "./icons/CircledCheckmarkIcon"; +export * from "./icons/CheckmarkIcon"; export * from "./icons/CircledErrorIcon"; export * from "./icons/CircledProgressIcon"; export * from "./icons/CircledArrowUpIcon"; diff --git a/packages/dashboard-v2/src/components/Uploader/UploaderItemIcon.js b/packages/dashboard-v2/src/components/Uploader/UploaderItemIcon.js index c0d6a766..ab681b61 100644 --- a/packages/dashboard-v2/src/components/Uploader/UploaderItemIcon.js +++ b/packages/dashboard-v2/src/components/Uploader/UploaderItemIcon.js @@ -1,6 +1,6 @@ import cn from "classnames"; -import { CircledCheckmarkIcon, CircledErrorIcon, CircledProgressIcon, CircledArrowUpIcon } from "../Icons"; +import { CheckmarkIcon, CircledErrorIcon, CircledProgressIcon, CircledArrowUpIcon } from "../Icons"; export default function UploaderItemIcon({ status }) { switch (status) { @@ -11,7 +11,7 @@ export default function UploaderItemIcon({ status }) { case "processing": return ; case "complete": - return ; + return ; case "error": return ; default: From bdf70e76e09471c70f95f42be75d6d0f352289c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 22 Mar 2022 13:47:29 +0100 Subject: [PATCH 004/240] feat(dashboard-v2): expose loading flag from useActivePlan hook --- packages/dashboard-v2/src/hooks/useActivePlan.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/dashboard-v2/src/hooks/useActivePlan.js b/packages/dashboard-v2/src/hooks/useActivePlan.js index 53e28b63..de71a036 100644 --- a/packages/dashboard-v2/src/hooks/useActivePlan.js +++ b/packages/dashboard-v2/src/hooks/useActivePlan.js @@ -4,7 +4,7 @@ import freeTier from "../lib/tiers"; import { usePlans } from "../contexts/plans"; export default function useActivePlan(user) { - const { plans, error } = usePlans(); + const { plans, loading, error } = usePlans(); const [activePlan, setActivePlan] = useState(freeTier); @@ -17,6 +17,7 @@ export default function useActivePlan(user) { return { error, plans, + loading, activePlan, }; } From fc4864996a40d8c015a22110504414edb14879b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 22 Mar 2022 13:48:52 +0100 Subject: [PATCH 005/240] feat(dashboard-v2): add /upgrade page --- packages/dashboard-v2/src/pages/upgrade.js | 132 +++++++++++++++++++++ 1 file changed, 132 insertions(+) create mode 100644 packages/dashboard-v2/src/pages/upgrade.js diff --git a/packages/dashboard-v2/src/pages/upgrade.js b/packages/dashboard-v2/src/pages/upgrade.js new file mode 100644 index 00000000..4fd52b74 --- /dev/null +++ b/packages/dashboard-v2/src/pages/upgrade.js @@ -0,0 +1,132 @@ +import * as React from "react"; +import bytes from "pretty-bytes"; +import styled from "styled-components"; + +import { useUser } from "../contexts/user"; +import { PlansProvider } from "../contexts/plans/PlansProvider"; +import useActivePlan from "../hooks/useActivePlan"; +import DashboardLayout from "../layouts/DashboardLayout"; +import { Panel } from "../components/Panel"; +import Slider from "../components/Slider/Slider"; +import { CheckmarkIcon } from "../components/Icons"; +import { Button } from "../components/Button"; + +const SLIDER_BREAKPOINTS = [ + { + name: "xl", + scrollable: true, + visibleSlides: 4, + }, + { + name: "lg", + scrollable: true, + visibleSlides: 3, + }, + { + name: "sm", + scrollable: true, + visibleSlides: 2, + }, + { + scrollable: true, + visibleSlides: 1, + }, +]; + +const PlanSummaryItem = ({ children }) => ( +
  • + +
    {children}
    +
  • +); + +const Description = styled.div` + display: -webkit-box; + -webkit-line-clamp: 4; + -webkit-box-orient: vertical; + overflow: hidden; + flex-shrink: 0; + height: 6rem; +`; + +const Price = ({ price }) => ( +
    +

    + $ + {price} +

    +

    per month

    +
    +); + +const bandwidth = (value) => parseFloat(bytes(value, { bits: true, binary: true })); + +const storage = (value) => bytes(value, { binary: true }); + +const localizedNumber = (value) => value.toLocaleString(); + +const PlansSlider = () => { + const { user, error: userError } = useUser(); + const { plans, loading, activePlan, error: plansError } = useActivePlan(user); + + if (userError || plansError) { + return ( +
    +

    Oooops!

    +

    Something went wrong, please try again later.

    +
    + ); + } + + return ( +
    + {!loading && ( + { + const isHigherThanCurrent = p.tier > activePlan?.tier; + const isCurrent = p.tier === activePlan?.tier; + + return ( + +

    {p.name}

    + {p.description} + + +
    + +
    +
      + + Pin up to {storage(p.limits.storageLimit)} of censorship-resistant storage + + + Support for up to {localizedNumber(p.limits.maxNumberUploads)} files + + {bandwidth(p.limits.uploadBandwidth)} mbps upload bandwidth + {bandwidth(p.limits.downloadBandwidth)} mbps download bandwidth +
    +
    + ); + })} + breakpoints={SLIDER_BREAKPOINTS} + scrollerClassName="gap-4 xl:gap-8" + className="px-8 sm:px-4 md:px-0 lg:px-0" + /> + )} +
    + ); +}; + +const UpgradePage = () => ( + + + +); + +UpgradePage.Layout = DashboardLayout; + +export default UpgradePage; From fde93869beccb2f467b1158e40aa67024856b60f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20Wypch=C5=82o?= Date: Tue, 22 Mar 2022 21:07:42 +0100 Subject: [PATCH 006/240] remove Marissa --- setup-scripts/support/authorized_keys | 1 - 1 file changed, 1 deletion(-) diff --git a/setup-scripts/support/authorized_keys b/setup-scripts/support/authorized_keys index 43698a94..6ee7b264 100644 --- a/setup-scripts/support/authorized_keys +++ b/setup-scripts/support/authorized_keys @@ -8,4 +8,3 @@ ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPM43lzbKjFLChe5rKETxDpWpNlqXCGTBPiWlDN2vlLD ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIN6Kcx8yetova4/ALUQHigo/PBMJO33ZTKOsg2jxSO2a user@deploy.siasky.dev ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDcenWnMQ6q/OEC4ZmQgjLDV2obWlR3fENV0zRGFvJF+ marcins@siasky.net ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIB7prtVOTwtcSN9HkXum107RwcW5H8Vggx6Qv7T57ItT daniel@siasky.net -ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAII85HxoIRbPyr+xUjpuFUlQNW7smCNdIcmx2XgpmXnB0 marissa@skynetlabs.com From 18600533eb860d307c0b9dc2c7cd4ad2d7d69d45 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 23 Mar 2022 10:28:26 +0100 Subject: [PATCH 007/240] style(dashboard-v2): make Button's code more readable --- .../src/components/Button/Button.js | 18 +++++++---------- packages/dashboard-v2/src/pages/upgrade.js | 20 +++++++++---------- 2 files changed, 17 insertions(+), 21 deletions(-) diff --git a/packages/dashboard-v2/src/components/Button/Button.js b/packages/dashboard-v2/src/components/Button/Button.js index 1ea93926..48cedb15 100644 --- a/packages/dashboard-v2/src/components/Button/Button.js +++ b/packages/dashboard-v2/src/components/Button/Button.js @@ -1,3 +1,4 @@ +import cn from "classnames"; import PropTypes from "prop-types"; import styled from "styled-components"; @@ -6,17 +7,12 @@ import styled from "styled-components"; */ export const Button = styled.button.attrs(({ disabled, $primary }) => ({ type: "button", - className: `px-6 py-2.5 rounded-full font-sans uppercase text-xs tracking-wide transition-[filter] - ${ - $primary - ? `bg-primary ${disabled ? "" : "text-palette-600"}` - : `bg-white border-2 ${disabled ? "border-palette-300" : "border-black text-palette-600"}` - } - ${ - disabled - ? `${$primary ? "saturate-50 brightness-125 text-palette-400" : "text-palette-300"} cursor-default` - : "hover:brightness-90" - }`, + className: cn("px-6 py-2.5 rounded-full font-sans uppercase text-xs tracking-wide transition-[opacity_filter]", { + "bg-primary text-palette-600": $primary, + "bg-white border-2 border-black text-palette-600": !$primary, + "cursor-not-allowed opacity-60": disabled, + "hover:brightness-90": !disabled, + }), }))``; Button.propTypes = { /** diff --git a/packages/dashboard-v2/src/pages/upgrade.js b/packages/dashboard-v2/src/pages/upgrade.js index 4fd52b74..49dac826 100644 --- a/packages/dashboard-v2/src/pages/upgrade.js +++ b/packages/dashboard-v2/src/pages/upgrade.js @@ -82,15 +82,15 @@ const PlansSlider = () => {
    {!loading && ( { - const isHigherThanCurrent = p.tier > activePlan?.tier; - const isCurrent = p.tier === activePlan?.tier; + slides={plans.map((plan) => { + const isHigherThanCurrent = plan.tier > activePlan?.tier; + const isCurrent = plan.tier === activePlan?.tier; return ( -

    {p.name}

    - {p.description} - +

    {plan.name}

    + {plan.description} +
      - Pin up to {storage(p.limits.storageLimit)} of censorship-resistant storage + Pin up to {storage(plan.limits.storageLimit)} of censorship-resistant storage - Support for up to {localizedNumber(p.limits.maxNumberUploads)} files + Support for up to {localizedNumber(plan.limits.maxNumberUploads)} files - {bandwidth(p.limits.uploadBandwidth)} mbps upload bandwidth - {bandwidth(p.limits.downloadBandwidth)} mbps download bandwidth + {bandwidth(plan.limits.uploadBandwidth)} mbps upload bandwidth + {bandwidth(plan.limits.downloadBandwidth)} mbps download bandwidth
    ); From c964086f7b5de9350be17f37062fda5e1bfc6629 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 24 Mar 2022 09:38:17 +0100 Subject: [PATCH 008/240] feat(dashboard-v2): use true reported bandwidth values --- packages/dashboard-v2/src/pages/upgrade.js | 26 ++++++++++++---------- 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/packages/dashboard-v2/src/pages/upgrade.js b/packages/dashboard-v2/src/pages/upgrade.js index 49dac826..894c8273 100644 --- a/packages/dashboard-v2/src/pages/upgrade.js +++ b/packages/dashboard-v2/src/pages/upgrade.js @@ -59,7 +59,7 @@ const Price = ({ price }) => (
    ); -const bandwidth = (value) => parseFloat(bytes(value, { bits: true, binary: true })); +const bandwidth = (value) => `${bytes(value, { bits: true })}/s`; const storage = (value) => bytes(value, { binary: true }); @@ -71,7 +71,7 @@ const PlansSlider = () => { if (userError || plansError) { return ( -
    +

    Oooops!

    Something went wrong, please try again later.

    @@ -99,16 +99,18 @@ const PlansSlider = () => { {!isHigherThanCurrent && !isCurrent && "Choose"}
    -
      - - Pin up to {storage(plan.limits.storageLimit)} of censorship-resistant storage - - - Support for up to {localizedNumber(plan.limits.maxNumberUploads)} files - - {bandwidth(plan.limits.uploadBandwidth)} mbps upload bandwidth - {bandwidth(plan.limits.downloadBandwidth)} mbps download bandwidth -
    + {plan.limits && ( +
      + + Pin up to {storage(plan.limits.storageLimit)} of censorship-resistant storage + + + Support for up to {localizedNumber(plan.limits.maxNumberUploads)} files + + {bandwidth(plan.limits.uploadBandwidth)} upload bandwidth + {bandwidth(plan.limits.downloadBandwidth)} download bandwidth +
    + )} ); })} From 3356b88a3e3254283fd3db982748f613fd43cadb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 23 Mar 2022 11:23:55 +0100 Subject: [PATCH 009/240] feat(dashboard-v2): allow +
    + +

    + Don't have an account? Sign up +

    + + )} + +); + +LoginForm.propTypes = { + onSuccess: PropTypes.func.isRequired, +}; diff --git a/packages/dashboard-v2/src/components/forms/index.js b/packages/dashboard-v2/src/components/forms/index.js new file mode 100644 index 00000000..1cad6f41 --- /dev/null +++ b/packages/dashboard-v2/src/components/forms/index.js @@ -0,0 +1 @@ +export * from "./LoginForm"; diff --git a/packages/dashboard-v2/src/services/accountsService.js b/packages/dashboard-v2/src/services/accountsService.js new file mode 100644 index 00000000..37244e5f --- /dev/null +++ b/packages/dashboard-v2/src/services/accountsService.js @@ -0,0 +1,3 @@ +import ky from "ky"; + +export default ky.create({ prefixUrl: "/api" }); diff --git a/packages/dashboard-v2/yarn.lock b/packages/dashboard-v2/yarn.lock index 12ff2eb1..687e3c5b 100644 --- a/packages/dashboard-v2/yarn.lock +++ b/packages/dashboard-v2/yarn.lock @@ -3373,6 +3373,11 @@ dependencies: "@types/node" "*" +"@types/lodash@^4.14.175": + version "4.14.180" + resolved "https://registry.yarnpkg.com/@types/lodash/-/lodash-4.14.180.tgz#4ab7c9ddfc92ec4a887886483bc14c79fb380670" + integrity sha512-XOKXa1KIxtNXgASAnwj7cnttJxS4fksBRywK/9LzRV5YxrF80BXZIGeQSuoESQ/VkUj30Ae0+YcuHc15wJCB2g== + "@types/lodash@^4.14.92": version "4.14.178" resolved "https://registry.yarnpkg.com/@types/lodash/-/lodash-4.14.178.tgz#341f6d2247db528d4a13ddbb374bcdc80406f4f8" @@ -6366,6 +6371,11 @@ deep-object-diff@^1.1.0: resolved "https://registry.yarnpkg.com/deep-object-diff/-/deep-object-diff-1.1.7.tgz#348b3246f426427dd633eaa50e1ed1fc2eafc7e4" integrity sha512-QkgBca0mL08P6HiOjoqvmm6xOAl2W6CT2+34Ljhg0OeFan8cwlcdq8jrLKsBBuUFAZLsN5b6y491KdKEoSo9lg== +deepmerge@^2.1.1: + version "2.2.1" + resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-2.2.1.tgz#5d3ff22a01c00f645405a2fbc17d0778a1801170" + integrity sha512-R9hc1Xa/NOBi9WRVUWg19rl1UB7Tt4kuPd+thNJgFZoxXsTz7ncaPaeIm+40oSGuP33DfMb4sZt1QIGiJzC4EA== + deepmerge@^4.0.0, deepmerge@^4.2.2: version "4.2.2" resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-4.2.2.tgz#44d2ea3679b8f4d4ffba33f03d865fc1e7bf4955" @@ -7951,6 +7961,19 @@ format@^0.2.0: resolved "https://registry.yarnpkg.com/format/-/format-0.2.2.tgz#d6170107e9efdc4ed30c9dc39016df942b5cb58b" integrity sha1-1hcBB+nv3E7TDJ3DkBbflCtctYs= +formik@^2.2.9: + version "2.2.9" + resolved "https://registry.yarnpkg.com/formik/-/formik-2.2.9.tgz#8594ba9c5e2e5cf1f42c5704128e119fc46232d0" + integrity sha512-LQLcISMmf1r5at4/gyJigGn0gOwFbeEAlji+N9InZF6LIMXnFNkO42sCI8Jt84YZggpD4cPWObAZaxpEFtSzNA== + dependencies: + deepmerge "^2.1.1" + hoist-non-react-statics "^3.3.0" + lodash "^4.17.21" + lodash-es "^4.17.21" + react-fast-compare "^2.0.1" + tiny-warning "^1.0.2" + tslib "^1.10.0" + forwarded@0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/forwarded/-/forwarded-0.2.0.tgz#2269936428aad4c15c7ebe9779a84bf0b2a81811" @@ -10357,6 +10380,11 @@ klona@^2.0.4: resolved "https://registry.yarnpkg.com/klona/-/klona-2.0.5.tgz#d166574d90076395d9963aa7a928fabb8d76afbc" integrity sha512-pJiBpiXMbt7dkzXe8Ghj/u4FfXOOa98fPW+bihOJ4SjnoijweJrNThJfd3ifXpXhREjpoF2mZVH1GfS9LV3kHQ== +ky@^0.30.0: + version "0.30.0" + resolved "https://registry.yarnpkg.com/ky/-/ky-0.30.0.tgz#a3d293e4f6c4604a9a4694eceb6ce30e73d27d64" + integrity sha512-X/u76z4JtDVq10u1JA5UQfatPxgPaVDMYTrgHyiTpGN2z4TMEJkIHsoSBBSg9SWZEIXTKsi9kHgiQ9o3Y/4yog== + language-subtag-registry@~0.3.2: version "0.3.21" resolved "https://registry.yarnpkg.com/language-subtag-registry/-/language-subtag-registry-0.3.21.tgz#04ac218bea46f04cb039084602c6da9e788dd45a" @@ -10510,6 +10538,11 @@ lock@^1.1.0: resolved "https://registry.yarnpkg.com/lock/-/lock-1.1.0.tgz#53157499d1653b136ca66451071fca615703fa55" integrity sha1-UxV0mdFlOxNspmRRBx/KYVcD+lU= +lodash-es@^4.17.21: + version "4.17.21" + resolved "https://registry.yarnpkg.com/lodash-es/-/lodash-es-4.17.21.tgz#43e626c46e6591b7750beb2b50117390c609e3ee" + integrity sha512-mKnC+QJ9pWVzv+C4/U3rRsHapFfHvQFoFB92e52xeyGMcX6/OlIl78je1u8vePzYZSkkogMPJ2yjxxsb89cxyw== + lodash.clonedeep@4.5.0: version "4.5.0" resolved "https://registry.yarnpkg.com/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz#e23f3f9c4f8fbdde872529c1071857a086e5ccef" @@ -11183,6 +11216,11 @@ nano-css@^5.3.1: stacktrace-js "^2.0.2" stylis "^4.0.6" +nanoclone@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/nanoclone/-/nanoclone-0.2.1.tgz#dd4090f8f1a110d26bb32c49ed2f5b9235209ed4" + integrity sha512-wynEP02LmIbLpcYw8uBKpcfF6dmg2vcpKqxeH5UcoKEYdExslsdUA4ugFauuaeYdTB76ez6gJW8XAZ6CgkXYxA== + nanoid@^3.1.23, nanoid@^3.2.0, nanoid@^3.3.1: version "3.3.1" resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.1.tgz#6347a18cac88af88f58af0b3594b723d5e99bb35" @@ -12647,6 +12685,11 @@ proper-lockfile@^4.1.2: retry "^0.12.0" signal-exit "^3.0.2" +property-expr@^2.0.4: + version "2.0.5" + resolved "https://registry.yarnpkg.com/property-expr/-/property-expr-2.0.5.tgz#278bdb15308ae16af3e3b9640024524f4dc02cb4" + integrity sha512-IJUkICM5dP5znhCckHSv30Q4b5/JA5enCtkRHYaOVOAocnH/1BQEYTC5NMfT3AVl/iXKdr3aqQbQn9DxyWknwA== + property-information@^5.0.0, property-information@^5.3.0: version "5.6.0" resolved "https://registry.yarnpkg.com/property-information/-/property-information-5.6.0.tgz#61675545fb23002f245c6540ec46077d4da3ed69" @@ -12942,6 +12985,11 @@ react-error-overlay@^6.0.9: resolved "https://registry.yarnpkg.com/react-error-overlay/-/react-error-overlay-6.0.10.tgz#0fe26db4fa85d9dbb8624729580e90e7159a59a6" integrity sha512-mKR90fX7Pm5seCOfz8q9F+66VCc1PGsWSBxKbITjfKVQHMNF2zudxHnMdJiB1fRCb+XsbQV9sO9DCkgsMQgBIA== +react-fast-compare@^2.0.1: + version "2.0.4" + resolved "https://registry.yarnpkg.com/react-fast-compare/-/react-fast-compare-2.0.4.tgz#e84b4d455b0fec113e0402c329352715196f81f9" + integrity sha512-suNP+J1VU1MWFKcyt7RtjiSWUjvidmQSlqu+eHslq+342xCbGTYmC0mEhPCOHxlW0CywylOC1u2DFAT+bv4dBw== + react-fast-compare@^3.0.1, react-fast-compare@^3.1.1, react-fast-compare@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/react-fast-compare/-/react-fast-compare-3.2.0.tgz#641a9da81b6a6320f270e89724fb45a0b39e43bb" @@ -14830,6 +14878,11 @@ timsort@^0.3.0: resolved "https://registry.yarnpkg.com/timsort/-/timsort-0.3.0.tgz#405411a8e7e6339fe64db9a234de11dc31e02bd4" integrity sha1-QFQRqOfmM5/mTbmiNN4R3DHgK9Q= +tiny-warning@^1.0.2: + version "1.0.3" + resolved "https://registry.yarnpkg.com/tiny-warning/-/tiny-warning-1.0.3.tgz#94a30db453df4c643d0fd566060d60a875d84754" + integrity sha512-lBN9zLN/oAf68o3zNXYrdCt1kP8WsiGW8Oo2ka41b2IM5JL/S1CTyX1rW0mb/zSuJun0ZUrDxx4sqvYS2FWzPA== + tinycolor2@^1.4.1: version "1.4.2" resolved "https://registry.yarnpkg.com/tinycolor2/-/tinycolor2-1.4.2.tgz#3f6a4d1071ad07676d7fa472e1fac40a719d8803" @@ -14929,6 +14982,11 @@ token-types@^4.1.1: "@tokenizer/token" "^0.3.0" ieee754 "^1.2.1" +toposort@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/toposort/-/toposort-2.0.2.tgz#ae21768175d1559d48bef35420b2f4962f09c330" + integrity sha1-riF2gXXRVZ1IvvNUILL0li8JwzA= + tr46@~0.0.3: version "0.0.3" resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" @@ -16036,6 +16094,19 @@ yoga-layout-prebuilt@^1.10.0: dependencies: "@types/yoga-layout" "1.9.2" +yup@^0.32.11: + version "0.32.11" + resolved "https://registry.yarnpkg.com/yup/-/yup-0.32.11.tgz#d67fb83eefa4698607982e63f7ca4c5ed3cf18c5" + integrity sha512-Z2Fe1bn+eLstG8DRR6FTavGD+MeAwyfmouhHsIUgaADz8jvFKbO/fXc2trJKZg+5EBjh4gGm3iU/t3onKlXHIg== + dependencies: + "@babel/runtime" "^7.15.4" + "@types/lodash" "^4.14.175" + lodash "^4.17.21" + lodash-es "^4.17.21" + nanoclone "^0.2.1" + property-expr "^2.0.4" + toposort "^2.0.2" + yurnalist@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/yurnalist/-/yurnalist-2.1.0.tgz#44cf7ea5a33a8fab4968cc8c2970489f93760902" From dda507fd5fe963eb6a5f1f3295ecc58c1482d2fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 23 Mar 2022 11:44:00 +0100 Subject: [PATCH 014/240] feat(dashboard-v2): add /auth/login page --- .../src/components/NavBar/NavBar.js | 10 +++++--- packages/dashboard-v2/src/pages/auth/login.js | 23 +++++++++++++++++++ .../static/images/logo-black-text.svg | 19 +++++++++++++++ 3 files changed, 49 insertions(+), 3 deletions(-) create mode 100644 packages/dashboard-v2/src/pages/auth/login.js create mode 100644 packages/dashboard-v2/static/images/logo-black-text.svg diff --git a/packages/dashboard-v2/src/components/NavBar/NavBar.js b/packages/dashboard-v2/src/components/NavBar/NavBar.js index 1db72dda..3d443627 100644 --- a/packages/dashboard-v2/src/components/NavBar/NavBar.js +++ b/packages/dashboard-v2/src/components/NavBar/NavBar.js @@ -1,4 +1,4 @@ -import { Link } from "gatsby"; +import { Link, navigate } from "gatsby"; import styled from "styled-components"; import { screen } from "../../lib/cssHelpers"; @@ -7,6 +7,7 @@ import { CogIcon, LockClosedIcon, SkynetLogoIcon } from "../Icons"; import { PageContainer } from "../PageContainer"; import { NavBarLink, NavBarSection } from "."; +import accountsService from "../../services/accountsService"; const NavBarContainer = styled.div.attrs({ className: `grid sticky top-0 bg-white z-10 shadow-sm`, @@ -77,9 +78,12 @@ export const NavBar = () => ( partiallyActive /> { + await accountsService.post("logout"); + navigate("/auth/login"); + }} activeClassName="text-primary" + className="cursor-pointer" icon={LockClosedIcon} label="Log out" /> diff --git a/packages/dashboard-v2/src/pages/auth/login.js b/packages/dashboard-v2/src/pages/auth/login.js new file mode 100644 index 00000000..077dda61 --- /dev/null +++ b/packages/dashboard-v2/src/pages/auth/login.js @@ -0,0 +1,23 @@ +import { navigate } from "gatsby"; + +import AuthLayout from "../../layouts/AuthLayout"; + +import { LoginForm } from "../../components/forms"; + +const LoginPage = ({ location }) => { + const query = new URLSearchParams(location.search); + const redirectTo = query.get("return_to"); + + return ( +
    +
    + Skynet +
    + navigate(redirectTo || "/")} /> +
    + ); +}; + +LoginPage.Layout = AuthLayout; + +export default LoginPage; diff --git a/packages/dashboard-v2/static/images/logo-black-text.svg b/packages/dashboard-v2/static/images/logo-black-text.svg new file mode 100644 index 00000000..40e45ba8 --- /dev/null +++ b/packages/dashboard-v2/static/images/logo-black-text.svg @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + From 4a127da39e31dac2d7b7ff1a5df50851db50a340 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20Wypch=C5=82o?= Date: Thu, 24 Mar 2022 13:37:14 +0100 Subject: [PATCH 015/240] insert snippet for docker image developement builds (#1916) --- docker-compose.abuse-scanner.yml | 2 ++ docker-compose.blocker.yml | 2 ++ docker-compose.malware-scanner.yml | 2 ++ 3 files changed, 6 insertions(+) diff --git a/docker-compose.abuse-scanner.yml b/docker-compose.abuse-scanner.yml index f655b0ea..4edb6556 100644 --- a/docker-compose.abuse-scanner.yml +++ b/docker-compose.abuse-scanner.yml @@ -8,6 +8,8 @@ x-logging: &default-logging services: abuse-scanner: + # uncomment "build" and comment out "image" to build from sources + # build: https://github.com/SkynetLabs/abuse-scanner.git#main image: skynetlabs/abuse-scanner container_name: abuse-scanner restart: unless-stopped diff --git a/docker-compose.blocker.yml b/docker-compose.blocker.yml index 3c1deeaa..edcb45c0 100644 --- a/docker-compose.blocker.yml +++ b/docker-compose.blocker.yml @@ -13,6 +13,8 @@ services: - BLOCKER_PORT=4000 blocker: + # uncomment "build" and comment out "image" to build from sources + # build: https://github.com/SkynetLabs/blocker.git#main image: skynetlabs/blocker container_name: blocker restart: unless-stopped diff --git a/docker-compose.malware-scanner.yml b/docker-compose.malware-scanner.yml index 9fc68374..fba60f98 100644 --- a/docker-compose.malware-scanner.yml +++ b/docker-compose.malware-scanner.yml @@ -26,6 +26,8 @@ services: ipv4_address: 10.10.10.100 malware-scanner: + # uncomment "build" and comment out "image" to build from sources + # build: https://github.com/SkynetLabs/malware-scanner.git#main image: skynetlabs/malware-scanner container_name: malware-scanner restart: unless-stopped From 084ef0469040ead0a5242570ee9a20da8dac43d7 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 24 Mar 2022 13:45:10 +0100 Subject: [PATCH 016/240] use skynet-accounts image instead of local dockerfile --- docker-compose.accounts.yml | 8 +++----- docker/accounts/Dockerfile | 22 ---------------------- 2 files changed, 3 insertions(+), 27 deletions(-) delete mode 100644 docker/accounts/Dockerfile diff --git a/docker-compose.accounts.yml b/docker-compose.accounts.yml index a3941f6b..5d9d345c 100644 --- a/docker-compose.accounts.yml +++ b/docker-compose.accounts.yml @@ -20,11 +20,9 @@ services: - ACCOUNTS_LIMIT_ACCESS=${ACCOUNTS_LIMIT_ACCESS:-authenticated} # default to authenticated access only accounts: - build: - context: ./docker/accounts - dockerfile: Dockerfile - args: - branch: main + # uncomment "build" and comment out "image" to build from sources + # build: https://github.com/SkynetLabs/skynet-accounts.git#main + image: skynetlabs/skynet-accounts container_name: accounts restart: unless-stopped logging: *default-logging diff --git a/docker/accounts/Dockerfile b/docker/accounts/Dockerfile deleted file mode 100644 index 5cbf359a..00000000 --- a/docker/accounts/Dockerfile +++ /dev/null @@ -1,22 +0,0 @@ -FROM golang:1.16.7 -LABEL maintainer="SkynetLabs " - -ENV GOOS linux -ENV GOARCH amd64 - -ARG branch=main - -WORKDIR /root - -RUN git clone --single-branch --branch ${branch} https://github.com/SkynetLabs/skynet-accounts.git && \ - cd skynet-accounts && \ - go mod download && \ - make release - -ENV SKYNET_DB_HOST="localhost" -ENV SKYNET_DB_PORT="27017" -ENV SKYNET_DB_USER="username" -ENV SKYNET_DB_PASS="password" -ENV SKYNET_ACCOUNTS_PORT=3000 - -ENTRYPOINT ["skynet-accounts"] From 731b1b6d52c515864bc054ff1e1ec63974c7f8d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 24 Mar 2022 15:47:35 +0100 Subject: [PATCH 017/240] fix(dashboard-v2): address review comments --- packages/dashboard-v2/README.md | 4 +- packages/dashboard-v2/package.json | 2 +- .../src/components/NavBar/NavBar.js | 1 + .../src/components/forms/LoginForm.js | 127 +++++++++--------- 4 files changed, 71 insertions(+), 63 deletions(-) diff --git a/packages/dashboard-v2/README.md b/packages/dashboard-v2/README.md index c450ce50..ab0421f8 100644 --- a/packages/dashboard-v2/README.md +++ b/packages/dashboard-v2/README.md @@ -11,7 +11,7 @@ This is a Gatsby application. To run it locally, all you need is: ## Accessing remote APIs -To be able to log in on a local environment with your production credentials, you'll need to make the browser believe you're actually on the same domain, otherwise browser will block the session cookie. +To be able to log in on a local environment with your production credentials, you'll need to make the browser believe you're actually on the same domain, otherwise the browser will block the session cookie. To do the trick, edit your `/etc/hosts` file and add a record like this: @@ -19,7 +19,7 @@ To do the trick, edit your `/etc/hosts` file and add a record like this: 127.0.0.1 local.skynetpro.net ``` -then run `yarn secure` -- it will run `gatsby develop` with `--https --host=local.skynetpro.net -p=443` options. +then run `yarn develop:secure` -- it will run `gatsby develop` with `--https --host=local.skynetpro.net -p=443` options. If you're on macOS, you may need to `sudo` the command to successfully bind to port `443`. > **NOTE:** This should become easier once we have a docker image for the new dashboard. diff --git a/packages/dashboard-v2/package.json b/packages/dashboard-v2/package.json index b5f638d6..44f7595d 100644 --- a/packages/dashboard-v2/package.json +++ b/packages/dashboard-v2/package.json @@ -9,8 +9,8 @@ ], "scripts": { "develop": "gatsby develop", + "develop:secure": "gatsby develop --https --host=local.skynetpro.net -p=443", "start": "gatsby develop", - "secure": "gatsby develop --https --host=local.skynetpro.net -p=443", "build": "gatsby build", "serve": "gatsby serve", "clean": "gatsby clean", diff --git a/packages/dashboard-v2/src/components/NavBar/NavBar.js b/packages/dashboard-v2/src/components/NavBar/NavBar.js index 3d443627..65d9afe5 100644 --- a/packages/dashboard-v2/src/components/NavBar/NavBar.js +++ b/packages/dashboard-v2/src/components/NavBar/NavBar.js @@ -81,6 +81,7 @@ export const NavBar = () => ( onClick={async () => { await accountsService.post("logout"); navigate("/auth/login"); + // TODO: handle errors }} activeClassName="text-primary" className="cursor-pointer" diff --git a/packages/dashboard-v2/src/components/forms/LoginForm.js b/packages/dashboard-v2/src/components/forms/LoginForm.js index 93d7a1b9..61973215 100644 --- a/packages/dashboard-v2/src/components/forms/LoginForm.js +++ b/packages/dashboard-v2/src/components/forms/LoginForm.js @@ -1,3 +1,4 @@ +import { useState } from "react"; import PropTypes from "prop-types"; import { Formik, Form } from "formik"; import { Link } from "gatsby"; @@ -16,72 +17,78 @@ const loginSchema = Yup.object().shape({ const INVALID_CREDENTIALS_ERRORS = ["password mismatch", "user not found"]; -export const LoginForm = ({ onSuccess }) => ( - { - try { - await accountsService.post("login", { - json: values, - }); +export const LoginForm = ({ onSuccess }) => { + const [error, setError] = useState(null); - onSuccess(); - } catch (err) { - if (err.response) { - const data = await err.response.json(); + return ( + { + try { + await accountsService.post("login", { + json: values, + }); - if (INVALID_CREDENTIALS_ERRORS.includes(data.message)) { - setErrors({ - email: "Invalid e-mail address or password", - password: "Invalid e-mail address or password", - }); + onSuccess(); + } catch (err) { + if (err.response) { + const data = await err.response.json(); + + if (INVALID_CREDENTIALS_ERRORS.includes(data.message)) { + setError("Invalid email address or password."); + } else { + setError(data.message); + } + } else { + setError("An error occured when logging you in. Please try again."); } } - } - }} - > - {({ errors, touched }) => ( -
    -

    Log in to your account

    - - -
    - - Forgot your password? - -
    + }} + > + {({ errors, touched }) => ( + +

    Log in to your account

    + {error &&

    {error}

    } + + +
    + + Forgot your password? + +
    -
    - -
    +
    + +
    -

    - Don't have an account? Sign up -

    - - )} -
    -); +

    + Don't have an account? Sign up +

    + + )} +
    + ); +}; LoginForm.propTypes = { onSuccess: PropTypes.func.isRequired, From de7da6f56b5c089f3e705ce8708bcbbfc31965ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 23 Mar 2022 13:14:52 +0100 Subject: [PATCH 018/240] feat(dashboard-v2): implement account recovery flow --- .../src/components/forms/RecoveryForm.js | 57 +++++++++++++++ .../src/components/forms/ResetPasswordForm.js | 72 +++++++++++++++++++ .../src/pages/auth/reset-password.js | 50 +++++++++++++ .../dashboard-v2/src/pages/user/recover.js | 56 +++++++++++++++ 4 files changed, 235 insertions(+) create mode 100644 packages/dashboard-v2/src/components/forms/RecoveryForm.js create mode 100644 packages/dashboard-v2/src/components/forms/ResetPasswordForm.js create mode 100644 packages/dashboard-v2/src/pages/auth/reset-password.js create mode 100644 packages/dashboard-v2/src/pages/user/recover.js diff --git a/packages/dashboard-v2/src/components/forms/RecoveryForm.js b/packages/dashboard-v2/src/components/forms/RecoveryForm.js new file mode 100644 index 00000000..50564b34 --- /dev/null +++ b/packages/dashboard-v2/src/components/forms/RecoveryForm.js @@ -0,0 +1,57 @@ +import PropTypes from "prop-types"; +import { Formik, Form } from "formik"; +import * as Yup from "yup"; + +import { TextField } from "../Form/TextField"; +import { Button } from "../Button"; + +import accountsService from "../../services/accountsService"; + +const recoverySchema = Yup.object().shape({ + email: Yup.string().required("Email is required").email("Please provide a valid email address"), +}); + +export const RecoveryForm = ({ onSuccess, onFailure }) => ( + { + try { + await accountsService.post("user/recover/request", { + json: values, + }); + + onSuccess(); + } catch { + onFailure(); + } + }} + > + {({ errors, touched }) => ( +
    +

    Request account recovery

    + + +
    + +
    + + )} +
    +); + +RecoveryForm.propTypes = { + onFailure: PropTypes.func.isRequired, + onSuccess: PropTypes.func.isRequired, +}; diff --git a/packages/dashboard-v2/src/components/forms/ResetPasswordForm.js b/packages/dashboard-v2/src/components/forms/ResetPasswordForm.js new file mode 100644 index 00000000..5f3fbf0b --- /dev/null +++ b/packages/dashboard-v2/src/components/forms/ResetPasswordForm.js @@ -0,0 +1,72 @@ +import PropTypes from "prop-types"; +import { Formik, Form } from "formik"; +import * as Yup from "yup"; + +import { TextField } from "../Form/TextField"; +import { Button } from "../Button"; + +import accountsService from "../../services/accountsService"; + +const resetPasswordSchema = Yup.object().shape({ + password: Yup.string().required("Password is required").min(6, "Password has to be at least 6 characters long"), + confirmPassword: Yup.string().oneOf([Yup.ref("password"), null], "Passwords must match"), +}); + +export const ResetPasswordForm = ({ token, onSuccess, onFailure }) => ( + { + try { + await accountsService.post("user/recover", { + json: { + token, + password, + confirmPassword, + }, + }); + + onSuccess(); + } catch { + onFailure(); + } + }} + > + {({ errors, touched }) => ( +
    +

    Set your new password

    + + + +
    + +
    + + )} +
    +); + +ResetPasswordForm.propTypes = { + token: PropTypes.string.isRequired, + onFailure: PropTypes.func.isRequired, + onSuccess: PropTypes.func.isRequired, +}; diff --git a/packages/dashboard-v2/src/pages/auth/reset-password.js b/packages/dashboard-v2/src/pages/auth/reset-password.js new file mode 100644 index 00000000..9151f8b4 --- /dev/null +++ b/packages/dashboard-v2/src/pages/auth/reset-password.js @@ -0,0 +1,50 @@ +import { useState } from "react"; + +import AuthLayout from "../../layouts/AuthLayout"; + +import { RecoveryForm } from "../../components/forms/RecoveryForm"; +import HighlightedLink from "../../components/HighlightedLink"; + +const State = { + Pure: "PURE", + Success: "SUCCESS", + Failure: "FAILURE", +}; + +const ResetPasswordPage = () => { + const [state, setState] = useState(State.Pure); + + return ( +
    +
    + Skynet +
    + {state !== State.Success && ( + setState(State.Success)} onFailure={() => setState(State.Failure)} /> + )} + + {state === State.Success && ( +

    + Please check your email inbox for further instructions. +

    + )} + + {state === State.Failure && ( +

    Something went wrong, please try again later.

    + )} + +
    +

    + Suddenly remembered your password? Sign in +

    +

    + Don't actually have an account? Create one! +

    +
    +
    + ); +}; + +ResetPasswordPage.Layout = AuthLayout; + +export default ResetPasswordPage; diff --git a/packages/dashboard-v2/src/pages/user/recover.js b/packages/dashboard-v2/src/pages/user/recover.js new file mode 100644 index 00000000..6f419fdb --- /dev/null +++ b/packages/dashboard-v2/src/pages/user/recover.js @@ -0,0 +1,56 @@ +import { useState } from "react"; +import { navigate } from "gatsby"; + +import AuthLayout from "../../layouts/AuthLayout"; + +import { ResetPasswordForm } from "../../components/forms/ResetPasswordForm"; +import HighlightedLink from "../../components/HighlightedLink"; + +const State = { + Pure: "PURE", + Success: "SUCCESS", + Failure: "FAILURE", +}; + +const RecoverPage = ({ location }) => { + const query = new URLSearchParams(location.search); + const token = query.get("token"); + + const [state, setState] = useState(State.Pure); + + return ( +
    +
    + Skynet +
    + {state !== State.Success && ( + { + setState(State.Success); + navigate("/"); + }} + onFailure={() => setState(State.Failure)} + /> + )} + + {state === State.Success && ( +

    + All done! You will be redirected to your dashboard shortly. +

    + )} + + {state === State.Failure && ( +

    Something went wrong, please try again later.

    + )} + +

    + Suddenly remembered your old password? Sign in +

    +
    + ); +}; + +RecoverPage.Layout = AuthLayout; + +export default RecoverPage; From 202450e9d876c57210a6bfedcf28b1b91d5a3e86 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 23 Mar 2022 14:32:35 +0100 Subject: [PATCH 019/240] feat(dashboard-v2): implement account registration flow --- packages/dashboard-v2/gatsby-config.js | 2 +- .../src/components/forms/SignUpForm.js | 109 ++++++++++++++++++ .../dashboard-v2/src/layouts/AuthLayout.js | 49 ++++---- packages/dashboard-v2/src/lib/swrConfig.js | 4 + .../dashboard-v2/src/pages/auth/signup.js | 56 +++++++++ .../dashboard-v2/src/pages/user/confirm.js | 68 +++++++++++ 6 files changed, 265 insertions(+), 23 deletions(-) create mode 100644 packages/dashboard-v2/src/components/forms/SignUpForm.js create mode 100644 packages/dashboard-v2/src/pages/auth/signup.js create mode 100644 packages/dashboard-v2/src/pages/user/confirm.js diff --git a/packages/dashboard-v2/gatsby-config.js b/packages/dashboard-v2/gatsby-config.js index 017a4dfc..160a7784 100644 --- a/packages/dashboard-v2/gatsby-config.js +++ b/packages/dashboard-v2/gatsby-config.js @@ -26,7 +26,7 @@ module.exports = { app.use( "/api/", createProxyMiddleware({ - target: "https://account.siasky.net", + target: "https://account.skynetpro.net", secure: false, // Do not reject self-signed certificates. changeOrigin: true, }) diff --git a/packages/dashboard-v2/src/components/forms/SignUpForm.js b/packages/dashboard-v2/src/components/forms/SignUpForm.js new file mode 100644 index 00000000..7ff7ba87 --- /dev/null +++ b/packages/dashboard-v2/src/components/forms/SignUpForm.js @@ -0,0 +1,109 @@ +import PropTypes from "prop-types"; +import { Formik, Form } from "formik"; +import * as Yup from "yup"; + +import { TextField } from "../Form/TextField"; +import { Button } from "../Button"; + +import accountsService from "../../services/accountsService"; + +// TODO: better password strength validation +const registrationSchema = Yup.object().shape({ + email: Yup.string().required("Email is required").email("Please provide a valid email address"), + password: Yup.string().required("Password is required").min(6, "Password has to be at least 6 characters long"), + confirmPassword: Yup.string().oneOf([Yup.ref("password"), null], "Passwords must match"), +}); + +const USER_EXISTS_ERROR = "identity already belongs to an existing user"; + +export const SignUpForm = ({ onSuccess, onFailure }) => ( + { + try { + await accountsService.post("user", { + json: { + email, + password, + }, + }); + + onSuccess(); + } catch (err) { + let isFormErrorSet = false; + + if (err.response) { + const data = await err.response.json(); + + // If it's a user error, let's capture it and handle within the form. + if (USER_EXISTS_ERROR === data.message) { + setErrors({ email: "This email address already in use." }); + isFormErrorSet = true; + } + } + + if (!isFormErrorSet) { + onFailure(); + } + } + }} + > + {({ errors, touched }) => ( +
    +
    +

    Create your free account

    +

    Includes 100 GB storage at basic speed

    +
    + + + + +
    +
      +
    • At least 6 characters long
    • +
    • Significantly different from the email
    • +
    +
    + + + +
    + +
    + + )} +
    +); + +SignUpForm.propTypes = { + onFailure: PropTypes.func.isRequired, + onSuccess: PropTypes.func.isRequired, +}; diff --git a/packages/dashboard-v2/src/layouts/AuthLayout.js b/packages/dashboard-v2/src/layouts/AuthLayout.js index 9706c83b..8a803fed 100644 --- a/packages/dashboard-v2/src/layouts/AuthLayout.js +++ b/packages/dashboard-v2/src/layouts/AuthLayout.js @@ -3,7 +3,7 @@ import styled from "styled-components"; import { SWRConfig } from "swr"; import { UserProvider } from "../contexts/user"; -import { guestsOnly } from "../lib/swrConfig"; +import { guestsOnly, allUsers } from "../lib/swrConfig"; const Layout = styled.div.attrs({ className: "h-screen w-screen bg-black flex", @@ -21,25 +21,30 @@ const Content = styled.div.attrs({ className: "w-full md:w-5/12 md:max-w-[680px] shrink-0", })``; -const AuthLayout = ({ children }) => { - return ( - <> - - - - -
    -

    - The decentralized revolution starts with decentralized storage -

    -
    -
    - {children} -
    -
    -
    - - ); -}; +const AuthLayout = + (swrConfig) => + ({ children }) => { + return ( + <> + + + + +
    +

    + The decentralized revolution starts with decentralized storage +

    +
    +
    + {children} +
    +
    +
    + + ); + }; -export default AuthLayout; +// Some pages (e.g. email confirmation) need to be accessible to both logged-in and guest users. +export const AllUsersAuthLayout = AuthLayout(allUsers); + +export default AuthLayout(guestsOnly); diff --git a/packages/dashboard-v2/src/lib/swrConfig.js b/packages/dashboard-v2/src/lib/swrConfig.js index 3e5f730a..058b5ead 100644 --- a/packages/dashboard-v2/src/lib/swrConfig.js +++ b/packages/dashboard-v2/src/lib/swrConfig.js @@ -23,6 +23,10 @@ const redirectAuthenticated = (key) => return response.json(); }); +export const allUsers = { + fetcher: (key) => fetch(`${baseUrl}/${key}`).then((response) => response.json()), +}; + export const authenticatedOnly = { fetcher: redirectUnauthenticated, }; diff --git a/packages/dashboard-v2/src/pages/auth/signup.js b/packages/dashboard-v2/src/pages/auth/signup.js new file mode 100644 index 00000000..d3df874d --- /dev/null +++ b/packages/dashboard-v2/src/pages/auth/signup.js @@ -0,0 +1,56 @@ +import { useEffect, useState } from "react"; + +import AuthLayout from "../../layouts/AuthLayout"; + +import HighlightedLink from "../../components/HighlightedLink"; +import { SignUpForm } from "../../components/forms/SignUpForm"; +import { navigate } from "gatsby"; + +const State = { + Pure: "PURE", + Success: "SUCCESS", + Failure: "FAILURE", +}; + +const SignUpPage = () => { + const [state, setState] = useState(State.Pure); + + useEffect(() => { + if (state === State.Success) { + const timer = setTimeout(() => navigate("/"), 3000); + + return () => clearTimeout(timer); + } + }, [state]); + + return ( +
    +
    + Skynet +
    + {state !== State.Success && ( + setState(State.Success)} onFailure={() => setState(State.Failure)} /> + )} + + {state === State.Success && ( +
    +

    Please check your email inbox and confirm your email address.

    +

    You will be redirected to your dashboard shortly.

    + Click here to go there now. +
    + )} + + {state === State.Failure && ( +

    Something went wrong, please try again later.

    + )} + +

    + Already have an account? Sign in +

    +
    + ); +}; + +SignUpPage.Layout = AuthLayout; + +export default SignUpPage; diff --git a/packages/dashboard-v2/src/pages/user/confirm.js b/packages/dashboard-v2/src/pages/user/confirm.js new file mode 100644 index 00000000..a66fc368 --- /dev/null +++ b/packages/dashboard-v2/src/pages/user/confirm.js @@ -0,0 +1,68 @@ +import { useEffect, useState } from "react"; +import { navigate } from "gatsby"; + +import { AllUsersAuthLayout } from "../../layouts/AuthLayout"; + +import HighlightedLink from "../../components/HighlightedLink"; +import accountsService from "../../services/accountsService"; + +const State = { + Pure: "PURE", + Success: "SUCCESS", + Failure: "FAILURE", +}; + +const EmailConfirmationPage = ({ location }) => { + const query = new URLSearchParams(location.search); + const token = query.get("token"); + + const [state, setState] = useState(State.Pure); + + useEffect(() => { + let timer; + + async function confirm(token) { + try { + await accountsService.get("user/confirm", { searchParams: { token } }); + + timer = setTimeout(() => { + navigate("/"); + }, 3000); + setState(State.Success); + } catch { + setState(State.Failure); + } + } + + if (token) { + confirm(token); + } + + return () => clearTimeout(timer); + }, [token]); + + return ( +
    +
    + Skynet +
    +
    + {state === State.Pure &&

    Please wait while we verify your account...

    } + + {state === State.Success && ( + <> +

    All done!

    +

    You will be redirected to your dashboard shortly.

    + Redirect now. + + )} + + {state === State.Failure &&

    Something went wrong, please try again later.

    } +
    +
    + ); +}; + +EmailConfirmationPage.Layout = AllUsersAuthLayout; + +export default EmailConfirmationPage; From 2664a3c4c45e3b5caf3af3a0af41b1d49bba23b3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 24 Mar 2022 09:44:58 +0100 Subject: [PATCH 020/240] fix(dashboard-v2): styling fixes for mobile view --- packages/dashboard-v2/src/layouts/AuthLayout.js | 2 +- packages/dashboard-v2/src/pages/auth/login.js | 4 ++-- packages/dashboard-v2/src/pages/auth/reset-password.js | 4 ++-- packages/dashboard-v2/src/pages/auth/signup.js | 4 ++-- packages/dashboard-v2/src/pages/user/confirm.js | 4 ++-- packages/dashboard-v2/src/pages/user/recover.js | 4 ++-- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/packages/dashboard-v2/src/layouts/AuthLayout.js b/packages/dashboard-v2/src/layouts/AuthLayout.js index 8a803fed..85604321 100644 --- a/packages/dashboard-v2/src/layouts/AuthLayout.js +++ b/packages/dashboard-v2/src/layouts/AuthLayout.js @@ -6,7 +6,7 @@ import { UserProvider } from "../contexts/user"; import { guestsOnly, allUsers } from "../lib/swrConfig"; const Layout = styled.div.attrs({ - className: "h-screen w-screen bg-black flex", + className: "min-h-screen w-screen bg-black flex", })` background-image: url(/images/auth-bg.svg); background-repeat: no-repeat; diff --git a/packages/dashboard-v2/src/pages/auth/login.js b/packages/dashboard-v2/src/pages/auth/login.js index 077dda61..e3b5240b 100644 --- a/packages/dashboard-v2/src/pages/auth/login.js +++ b/packages/dashboard-v2/src/pages/auth/login.js @@ -9,8 +9,8 @@ const LoginPage = ({ location }) => { const redirectTo = query.get("return_to"); return ( -
    -
    +
    +
    Skynet
    navigate(redirectTo || "/")} /> diff --git a/packages/dashboard-v2/src/pages/auth/reset-password.js b/packages/dashboard-v2/src/pages/auth/reset-password.js index 9151f8b4..a7761327 100644 --- a/packages/dashboard-v2/src/pages/auth/reset-password.js +++ b/packages/dashboard-v2/src/pages/auth/reset-password.js @@ -15,8 +15,8 @@ const ResetPasswordPage = () => { const [state, setState] = useState(State.Pure); return ( -
    -
    +
    +
    Skynet
    {state !== State.Success && ( diff --git a/packages/dashboard-v2/src/pages/auth/signup.js b/packages/dashboard-v2/src/pages/auth/signup.js index d3df874d..210abab8 100644 --- a/packages/dashboard-v2/src/pages/auth/signup.js +++ b/packages/dashboard-v2/src/pages/auth/signup.js @@ -24,8 +24,8 @@ const SignUpPage = () => { }, [state]); return ( -
    -
    +
    +
    Skynet
    {state !== State.Success && ( diff --git a/packages/dashboard-v2/src/pages/user/confirm.js b/packages/dashboard-v2/src/pages/user/confirm.js index a66fc368..e0eb9778 100644 --- a/packages/dashboard-v2/src/pages/user/confirm.js +++ b/packages/dashboard-v2/src/pages/user/confirm.js @@ -42,8 +42,8 @@ const EmailConfirmationPage = ({ location }) => { }, [token]); return ( -
    -
    +
    +
    Skynet
    diff --git a/packages/dashboard-v2/src/pages/user/recover.js b/packages/dashboard-v2/src/pages/user/recover.js index 6f419fdb..686e677a 100644 --- a/packages/dashboard-v2/src/pages/user/recover.js +++ b/packages/dashboard-v2/src/pages/user/recover.js @@ -19,8 +19,8 @@ const RecoverPage = ({ location }) => { const [state, setState] = useState(State.Pure); return ( -
    -
    +
    +
    Skynet
    {state !== State.Success && ( From 6b733ab739ca84077580983f1efca4ecc6344ab5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 25 Mar 2022 10:52:28 +0100 Subject: [PATCH 021/240] style(dashboard-v2): unify password schemas --- .../src/components/forms/ResetPasswordForm.js | 9 ++------ .../src/components/forms/SignUpForm.js | 22 +++++++++---------- 2 files changed, 13 insertions(+), 18 deletions(-) diff --git a/packages/dashboard-v2/src/components/forms/ResetPasswordForm.js b/packages/dashboard-v2/src/components/forms/ResetPasswordForm.js index 5f3fbf0b..68e8480f 100644 --- a/packages/dashboard-v2/src/components/forms/ResetPasswordForm.js +++ b/packages/dashboard-v2/src/components/forms/ResetPasswordForm.js @@ -1,24 +1,19 @@ import PropTypes from "prop-types"; import { Formik, Form } from "formik"; -import * as Yup from "yup"; import { TextField } from "../Form/TextField"; import { Button } from "../Button"; +import { passwordSchema } from "./SignUpForm"; import accountsService from "../../services/accountsService"; -const resetPasswordSchema = Yup.object().shape({ - password: Yup.string().required("Password is required").min(6, "Password has to be at least 6 characters long"), - confirmPassword: Yup.string().oneOf([Yup.ref("password"), null], "Passwords must match"), -}); - export const ResetPasswordForm = ({ token, onSuccess, onFailure }) => ( { try { await accountsService.post("user/recover", { diff --git a/packages/dashboard-v2/src/components/forms/SignUpForm.js b/packages/dashboard-v2/src/components/forms/SignUpForm.js index 7ff7ba87..976c0c74 100644 --- a/packages/dashboard-v2/src/components/forms/SignUpForm.js +++ b/packages/dashboard-v2/src/components/forms/SignUpForm.js @@ -7,13 +7,19 @@ import { Button } from "../Button"; import accountsService from "../../services/accountsService"; -// TODO: better password strength validation -const registrationSchema = Yup.object().shape({ - email: Yup.string().required("Email is required").email("Please provide a valid email address"), - password: Yup.string().required("Password is required").min(6, "Password has to be at least 6 characters long"), - confirmPassword: Yup.string().oneOf([Yup.ref("password"), null], "Passwords must match"), +export const passwordSchema = Yup.object().shape({ + password: Yup.string().required("Password is required"), + confirmPassword: Yup.string() + .oneOf([Yup.ref("password"), null], "Passwords must match") + .required("Please re-type your password"), }); +const registrationSchema = Yup.object() + .shape({ + email: Yup.string().required("Email is required").email("Please provide a valid email address"), + }) + .concat(passwordSchema); + const USER_EXISTS_ERROR = "identity already belongs to an existing user"; export const SignUpForm = ({ onSuccess, onFailure }) => ( @@ -77,12 +83,6 @@ export const SignUpForm = ({ onSuccess, onFailure }) => ( error={errors.password} touched={touched.password} /> -
    -
      -
    • At least 6 characters long
    • -
    • Significantly different from the email
    • -
    -
    Date: Fri, 25 Mar 2022 10:52:59 +0100 Subject: [PATCH 022/240] style(dashboard-v2): unify wording of messages --- packages/dashboard-v2/src/components/forms/LoginForm.js | 2 +- packages/dashboard-v2/src/pages/auth/reset-password.js | 6 ++---- packages/dashboard-v2/src/pages/auth/signup.js | 2 +- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/packages/dashboard-v2/src/components/forms/LoginForm.js b/packages/dashboard-v2/src/components/forms/LoginForm.js index 61973215..a5a1deeb 100644 --- a/packages/dashboard-v2/src/components/forms/LoginForm.js +++ b/packages/dashboard-v2/src/components/forms/LoginForm.js @@ -70,7 +70,7 @@ export const LoginForm = ({ onSuccess }) => { touched={touched.password} />
    - + Forgot your password?
    diff --git a/packages/dashboard-v2/src/pages/auth/reset-password.js b/packages/dashboard-v2/src/pages/auth/reset-password.js index a7761327..8ecbfeaa 100644 --- a/packages/dashboard-v2/src/pages/auth/reset-password.js +++ b/packages/dashboard-v2/src/pages/auth/reset-password.js @@ -24,9 +24,7 @@ const ResetPasswordPage = () => { )} {state === State.Success && ( -

    - Please check your email inbox for further instructions. -

    +

    Please check your inbox for further instructions.

    )} {state === State.Failure && ( @@ -38,7 +36,7 @@ const ResetPasswordPage = () => { Suddenly remembered your password? Sign in

    - Don't actually have an account? Create one! + Don't actually have an account? Create one!

    diff --git a/packages/dashboard-v2/src/pages/auth/signup.js b/packages/dashboard-v2/src/pages/auth/signup.js index 210abab8..4acbae85 100644 --- a/packages/dashboard-v2/src/pages/auth/signup.js +++ b/packages/dashboard-v2/src/pages/auth/signup.js @@ -34,7 +34,7 @@ const SignUpPage = () => { {state === State.Success && (
    -

    Please check your email inbox and confirm your email address.

    +

    Please check your inbox and confirm your email address.

    You will be redirected to your dashboard shortly.

    Click here to go there now.
    From be82050b869b8b7eeadb1e93a0cf310eab097749 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 25 Mar 2022 10:53:16 +0100 Subject: [PATCH 023/240] fix(dashboard-v2): fix possible race condition --- .../dashboard-v2/src/pages/user/confirm.js | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/packages/dashboard-v2/src/pages/user/confirm.js b/packages/dashboard-v2/src/pages/user/confirm.js index e0eb9778..9e95e3e3 100644 --- a/packages/dashboard-v2/src/pages/user/confirm.js +++ b/packages/dashboard-v2/src/pages/user/confirm.js @@ -19,18 +19,25 @@ const EmailConfirmationPage = ({ location }) => { const [state, setState] = useState(State.Pure); useEffect(() => { + const controller = new AbortController(); let timer; async function confirm(token) { try { - await accountsService.get("user/confirm", { searchParams: { token } }); + await accountsService.get("user/confirm", { + signal: controller.signal, + searchParams: { token }, + }); timer = setTimeout(() => { navigate("/"); }, 3000); setState(State.Success); - } catch { - setState(State.Failure); + } catch (err) { + // Don't show an error message if request was aborted due to `token` changing. + if (err.code !== DOMException.ABORT_ERR) { + setState(State.Failure); + } } } @@ -38,7 +45,10 @@ const EmailConfirmationPage = ({ location }) => { confirm(token); } - return () => clearTimeout(timer); + return () => { + controller.abort(); + clearTimeout(timer); + }; }, [token]); return ( From 60c2d35eb9b81ce2e314a8879d84a718a245bea6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 24 Mar 2022 10:32:29 +0100 Subject: [PATCH 024/240] feat(dashboard-v2): add Alert component --- packages/dashboard-v2/src/components/Alert/Alert.js | 9 +++++++++ packages/dashboard-v2/src/components/Alert/index.js | 1 + 2 files changed, 10 insertions(+) create mode 100644 packages/dashboard-v2/src/components/Alert/Alert.js create mode 100644 packages/dashboard-v2/src/components/Alert/index.js diff --git a/packages/dashboard-v2/src/components/Alert/Alert.js b/packages/dashboard-v2/src/components/Alert/Alert.js new file mode 100644 index 00000000..0e6ab345 --- /dev/null +++ b/packages/dashboard-v2/src/components/Alert/Alert.js @@ -0,0 +1,9 @@ +import styled from "styled-components"; +import cn from "classnames"; + +export const Alert = styled.div.attrs(({ $variant }) => ({ + className: cn("px-3 py-2 sm:px-6 sm:py-4 rounded border", { + "bg-red-100 border-red-200 text-error": $variant === "error", + "bg-green-100 border-green-200 text-palette-400": $variant === "success", + }), +}))``; diff --git a/packages/dashboard-v2/src/components/Alert/index.js b/packages/dashboard-v2/src/components/Alert/index.js new file mode 100644 index 00000000..b8e17a03 --- /dev/null +++ b/packages/dashboard-v2/src/components/Alert/index.js @@ -0,0 +1 @@ +export * from "./Alert"; From 340fe5f2038fe9a50bf668d7edc3506e8d43c2ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 24 Mar 2022 10:33:09 +0100 Subject: [PATCH 025/240] fix(dashboard-v2): fix TextField customization via className --- packages/dashboard-v2/src/components/Form/TextField.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/dashboard-v2/src/components/Form/TextField.js b/packages/dashboard-v2/src/components/Form/TextField.js index 7eb811a8..6ae35021 100644 --- a/packages/dashboard-v2/src/components/Form/TextField.js +++ b/packages/dashboard-v2/src/components/Form/TextField.js @@ -2,7 +2,7 @@ import PropTypes from "prop-types"; import cn from "classnames"; import { Field } from "formik"; -export const TextField = ({ id, label, name, error, touched, ...props }) => { +export const TextField = ({ id, label, name, error, touched, className, ...props }) => { return (
    {label && ( @@ -13,7 +13,7 @@ export const TextField = ({ id, label, name, error, touched, ...props }) => { Date: Thu, 24 Mar 2022 10:39:18 +0100 Subject: [PATCH 026/240] feat(dashboard-v2): add Modal component --- packages/dashboard-v2/gatsby-browser.js | 8 +++- packages/dashboard-v2/gatsby-ssr.js | 8 +++- .../src/components/Modal/Modal.js | 37 ++++++++++++++++ .../src/components/Modal/ModalPortal.js | 16 +++++++ .../src/components/Modal/Overlay.js | 42 +++++++++++++++++++ .../src/components/Modal/index.js | 1 + 6 files changed, 110 insertions(+), 2 deletions(-) create mode 100644 packages/dashboard-v2/src/components/Modal/Modal.js create mode 100644 packages/dashboard-v2/src/components/Modal/ModalPortal.js create mode 100644 packages/dashboard-v2/src/components/Modal/Overlay.js create mode 100644 packages/dashboard-v2/src/components/Modal/index.js diff --git a/packages/dashboard-v2/gatsby-browser.js b/packages/dashboard-v2/gatsby-browser.js index a71e49c3..a39bdb48 100644 --- a/packages/dashboard-v2/gatsby-browser.js +++ b/packages/dashboard-v2/gatsby-browser.js @@ -6,8 +6,14 @@ import "@fontsource/sora/600.css"; // semibold import "@fontsource/source-sans-pro/400.css"; // normal import "@fontsource/source-sans-pro/600.css"; // semibold import "./src/styles/global.css"; +import { MODAL_ROOT_ID } from "./src/components/Modal"; export function wrapPageElement({ element, props }) { const Layout = element.type.Layout ?? React.Fragment; - return {element}; + return ( + + {element} +
    + + ); } diff --git a/packages/dashboard-v2/gatsby-ssr.js b/packages/dashboard-v2/gatsby-ssr.js index a71e49c3..a39bdb48 100644 --- a/packages/dashboard-v2/gatsby-ssr.js +++ b/packages/dashboard-v2/gatsby-ssr.js @@ -6,8 +6,14 @@ import "@fontsource/sora/600.css"; // semibold import "@fontsource/source-sans-pro/400.css"; // normal import "@fontsource/source-sans-pro/600.css"; // semibold import "./src/styles/global.css"; +import { MODAL_ROOT_ID } from "./src/components/Modal"; export function wrapPageElement({ element, props }) { const Layout = element.type.Layout ?? React.Fragment; - return {element}; + return ( + + {element} +
    + + ); } diff --git a/packages/dashboard-v2/src/components/Modal/Modal.js b/packages/dashboard-v2/src/components/Modal/Modal.js new file mode 100644 index 00000000..6fd8e00a --- /dev/null +++ b/packages/dashboard-v2/src/components/Modal/Modal.js @@ -0,0 +1,37 @@ +import cn from "classnames"; +import PropTypes from "prop-types"; + +import { PlusIcon } from "../Icons"; +import { Panel } from "../Panel"; + +import { ModalPortal } from "./ModalPortal"; +import { Overlay } from "./Overlay"; + +export const Modal = ({ children, className, onClose }) => ( + + +
    + + {children} +
    +
    +
    +); + +Modal.propTypes = { + /** + * Modal's body. + */ + children: PropTypes.node.isRequired, + /** + * Handler function to be called when user clicks on the "X" icon, + * or outside of the modal. + */ + onClose: PropTypes.func.isRequired, + /** + * Additional CSS classes to be applied to modal's body. + */ + className: PropTypes.string, +}; diff --git a/packages/dashboard-v2/src/components/Modal/ModalPortal.js b/packages/dashboard-v2/src/components/Modal/ModalPortal.js new file mode 100644 index 00000000..ef18e612 --- /dev/null +++ b/packages/dashboard-v2/src/components/Modal/ModalPortal.js @@ -0,0 +1,16 @@ +import { useEffect, useRef, useState } from "react"; +import { createPortal } from "react-dom"; + +export const MODAL_ROOT_ID = "__modal-root"; + +export const ModalPortal = ({ children }) => { + const ref = useRef(); + const [isClientSide, setIsClientSide] = useState(false); + + useEffect(() => { + ref.current = document.querySelector(MODAL_ROOT_ID) || document.body; + setIsClientSide(true); + }, []); + + return isClientSide ? createPortal(children, ref.current) : null; +}; diff --git a/packages/dashboard-v2/src/components/Modal/Overlay.js b/packages/dashboard-v2/src/components/Modal/Overlay.js new file mode 100644 index 00000000..7f1cbb35 --- /dev/null +++ b/packages/dashboard-v2/src/components/Modal/Overlay.js @@ -0,0 +1,42 @@ +import { useRef } from "react"; +import { useLockBodyScroll } from "react-use"; +import PropTypes from "prop-types"; + +export const Overlay = ({ children, onClick }) => { + const overlayRef = useRef(null); + + useLockBodyScroll(true); + + const handleClick = (event) => { + if (event.target !== overlayRef.current) { + return; + } + + event.nativeEvent.stopImmediatePropagation(); + + onClick?.(event); + }; + + return ( +
    + {children} +
    + ); +}; + +Overlay.propTypes = { + /** + * Overlay's body. + */ + children: PropTypes.node.isRequired, + /** + * Handler function to be called when user clicks on the overlay + * (but not the overlay's content). + */ + onClick: PropTypes.func, +}; diff --git a/packages/dashboard-v2/src/components/Modal/index.js b/packages/dashboard-v2/src/components/Modal/index.js new file mode 100644 index 00000000..28d34710 --- /dev/null +++ b/packages/dashboard-v2/src/components/Modal/index.js @@ -0,0 +1 @@ +export * from "./ModalPortal"; From 93809d5428917a0c943e79ed9308acd45ad5eb57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 24 Mar 2022 10:44:48 +0100 Subject: [PATCH 027/240] feat(dashboard-v2): implement data mutations for user accounts --- .../components/forms/AccountRemovalForm.js | 78 +++++++++++++ .../components/forms/AccountSettingsForm.js | 106 ++++++++++++++++++ .../dashboard-v2/src/pages/settings/index.js | 67 ++++++----- 3 files changed, 221 insertions(+), 30 deletions(-) create mode 100644 packages/dashboard-v2/src/components/forms/AccountRemovalForm.js create mode 100644 packages/dashboard-v2/src/components/forms/AccountSettingsForm.js diff --git a/packages/dashboard-v2/src/components/forms/AccountRemovalForm.js b/packages/dashboard-v2/src/components/forms/AccountRemovalForm.js new file mode 100644 index 00000000..bdd7196e --- /dev/null +++ b/packages/dashboard-v2/src/components/forms/AccountRemovalForm.js @@ -0,0 +1,78 @@ +import * as Yup from "yup"; +import { useState } from "react"; +import PropTypes from "prop-types"; +import { Formik, Form } from "formik"; + +import { Button } from "../Button"; +import { TextField } from "../Form/TextField"; +import accountsService from "../../services/accountsService"; + +const accountRemovalSchema = Yup.object().shape({ + confirm: Yup.string().oneOf(["delete"], `Type "delete" to confirm`), +}); + +export const AccountRemovalForm = ({ abort, onSuccess }) => { + const [error, setError] = useState(false); + + return ( + { + try { + setError(false); + await accountsService.delete("user"); + onSuccess(); + } catch { + setError(true); + } + }} + > + {({ errors, touched, isValid, dirty }) => ( +
    +
    +

    Delete account

    +

    + This will completely delete your account. This process can't be undone. +

    +
    + +
    + +

    Type "delete" in the field below to remove your account.

    + + + +
    + + +
    + {error && ( +
    + There was an error processing your request. Please try again later. +
    + )} + + )} +
    + ); +}; + +AccountRemovalForm.propTypes = { + abort: PropTypes.func.isRequired, + onSuccess: PropTypes.func.isRequired, +}; diff --git a/packages/dashboard-v2/src/components/forms/AccountSettingsForm.js b/packages/dashboard-v2/src/components/forms/AccountSettingsForm.js new file mode 100644 index 00000000..f979dd31 --- /dev/null +++ b/packages/dashboard-v2/src/components/forms/AccountSettingsForm.js @@ -0,0 +1,106 @@ +import * as Yup from "yup"; +import PropTypes from "prop-types"; +import { Formik, Form } from "formik"; + +import { Button } from "../Button"; +import { TextField } from "../Form/TextField"; +import accountsService from "../../services/accountsService"; + +const isPopulated = (value) => value?.length > 0; + +const emailUpdateSchema = Yup.object().shape({ + email: Yup.string().email("Please provide a valid email address"), + confirmEmail: Yup.string() + .oneOf([Yup.ref("email"), null], "Emails must match") + .when("email", { + is: isPopulated, + then: (schema) => schema.required("Please confirm new email address"), + }), + password: Yup.string().min(6, "Password has to be at least 6 characters long"), + confirmPassword: Yup.string() + .oneOf([Yup.ref("password"), null], "Passwords must match") + .when("password", { + is: isPopulated, + then: (schema) => schema.required("Please confirm new password"), + }), +}); + +export const AccountSettingsForm = ({ user, onSuccess, onFailure }) => { + return ( + { + try { + await accountsService.put("user", { + json: { email, password }, + }); + + resetForm(); + onSuccess(); + } catch { + onFailure(); + } + }} + > + {({ errors, touched, isValid, dirty }) => ( +
    +
    +
    + + +
    +
    + + +
    +
    +
    + +
    +
    + )} +
    + ); +}; + +AccountSettingsForm.propTypes = { + onSuccess: PropTypes.func.isRequired, + onFailure: PropTypes.func.isRequired, +}; diff --git a/packages/dashboard-v2/src/pages/settings/index.js b/packages/dashboard-v2/src/pages/settings/index.js index 459cf8c0..41ccf6b4 100644 --- a/packages/dashboard-v2/src/pages/settings/index.js +++ b/packages/dashboard-v2/src/pages/settings/index.js @@ -1,19 +1,31 @@ -import * as React from "react"; +import { useState } from "react"; import { useMedia } from "react-use"; -import styled from "styled-components"; +import { navigate } from "gatsby"; +import { useUser } from "../../contexts/user"; import theme from "../../lib/theme"; import UserSettingsLayout from "../../layouts/UserSettingsLayout"; -import { TextInputBasic } from "../../components/TextInputBasic/TextInputBasic"; -import { Button } from "../../components/Button"; import { AvatarUploader } from "../../components/AvatarUploader"; +import { AccountSettingsForm } from "../../components/forms/AccountSettingsForm"; +import { Modal } from "../../components/Modal/Modal"; +import { AccountRemovalForm } from "../../components/forms/AccountRemovalForm"; +import { Alert } from "../../components/Alert"; -const FormGroup = styled.div.attrs({ - className: "grid sm:grid-cols-[1fr_min-content] w-full gap-y-2 gap-x-4 items-end", -})``; +const State = { + Pure: "PURE", + Success: "SUCCESS", + Failure: "FAILURE", +}; const AccountPage = () => { const isLargeScreen = useMedia(`(min-width: ${theme.screens.xl})`); + const { user, mutate: reloadUser } = useUser(); + const [state, setState] = useState(State.Pure); + const [removalInitiated, setRemovalInitiated] = useState(false); + + const prompt = () => setRemovalInitiated(true); + const abort = () => setRemovalInitiated(false); + return ( <>
    @@ -32,28 +44,18 @@ const AccountPage = () => { )}
    - - -
    - -
    -
    - - -
    - -
    -
    - - -
    - -
    - - The password must be at least 6 characters long. Significantly different from the email and old - password. - -
    + {state === State.Failure && ( + There was an error processing your request. Please try again later. + )} + {state === State.Success && Changes saved successfully.} + { + reloadUser(); + setState(State.Success); + }} + onFailure={() => setState(State.Failure)} + />

    @@ -61,7 +63,7 @@ const AccountPage = () => {

    This will completely delete your account. This process can't be undone.

    ); From 07112383d3c8192691a756e733d4bce5c49879fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 24 Mar 2022 10:46:02 +0100 Subject: [PATCH 028/240] chore(dashboard-v2): cleanup AvatarUploader (user avatars are not available yet) --- packages/dashboard-v2/src/pages/settings/index.js | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/packages/dashboard-v2/src/pages/settings/index.js b/packages/dashboard-v2/src/pages/settings/index.js index 41ccf6b4..32ec95ac 100644 --- a/packages/dashboard-v2/src/pages/settings/index.js +++ b/packages/dashboard-v2/src/pages/settings/index.js @@ -1,11 +1,8 @@ import { useState } from "react"; -import { useMedia } from "react-use"; import { navigate } from "gatsby"; import { useUser } from "../../contexts/user"; -import theme from "../../lib/theme"; import UserSettingsLayout from "../../layouts/UserSettingsLayout"; -import { AvatarUploader } from "../../components/AvatarUploader"; import { AccountSettingsForm } from "../../components/forms/AccountSettingsForm"; import { Modal } from "../../components/Modal/Modal"; import { AccountRemovalForm } from "../../components/forms/AccountRemovalForm"; @@ -18,7 +15,6 @@ const State = { }; const AccountPage = () => { - const isLargeScreen = useMedia(`(min-width: ${theme.screens.xl})`); const { user, mutate: reloadUser } = useUser(); const [state, setState] = useState(State.Pure); const [removalInitiated, setRemovalInitiated] = useState(false); @@ -38,11 +34,6 @@ const AccountPage = () => {


    - {!isLargeScreen && ( -
    - -
    - )}
    {state === State.Failure && ( There was an error processing your request. Please try again later. @@ -70,9 +61,6 @@ const AccountPage = () => {
    -
    - {isLargeScreen && } -
    {removalInitiated && ( navigate("/auth/login")} /> From 1933ccd270266f48ed173f72a081db10f28d45cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 24 Mar 2022 18:47:35 +0100 Subject: [PATCH 029/240] feat(dashboard-v2): add 'info' variant to Alert component --- packages/dashboard-v2/src/components/Alert/Alert.js | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/dashboard-v2/src/components/Alert/Alert.js b/packages/dashboard-v2/src/components/Alert/Alert.js index 0e6ab345..4db72620 100644 --- a/packages/dashboard-v2/src/components/Alert/Alert.js +++ b/packages/dashboard-v2/src/components/Alert/Alert.js @@ -3,6 +3,7 @@ import cn from "classnames"; export const Alert = styled.div.attrs(({ $variant }) => ({ className: cn("px-3 py-2 sm:px-6 sm:py-4 rounded border", { + "bg-blue-100 border-blue-200 text-palette-400": $variant === "info", "bg-red-100 border-red-200 text-error": $variant === "error", "bg-green-100 border-green-200 text-palette-400": $variant === "success", }), From ddd109ab0dd2f8a5b10ff2f7f7958ee38b5a6d15 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 24 Mar 2022 18:48:04 +0100 Subject: [PATCH 030/240] fix(dashboard-v2): update side image on /api-keys --- packages/dashboard-v2/static/images/api-keys.svg | 1 + 1 file changed, 1 insertion(+) create mode 100644 packages/dashboard-v2/static/images/api-keys.svg diff --git a/packages/dashboard-v2/static/images/api-keys.svg b/packages/dashboard-v2/static/images/api-keys.svg new file mode 100644 index 00000000..35fe3744 --- /dev/null +++ b/packages/dashboard-v2/static/images/api-keys.svg @@ -0,0 +1 @@ + From 4c8328c21ff341e6e22471a3da2cba32b5499f24 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 24 Mar 2022 19:13:19 +0100 Subject: [PATCH 031/240] feat(dashboard-v2): implement data mutations for API keys --- .../src/components/APIKeyList/APIKey.js | 123 ++++++++++++++++++ .../src/components/APIKeyList/APIKeyList.js | 14 ++ .../src/components/APIKeyList/index.js | 1 + .../components/APIKeyList/useAPIKeyEdit.js | 31 +++++ .../components/APIKeyList/useAPIKeyRemoval.js | 39 ++++++ .../src/components/Modal/Modal.js | 2 +- .../src/components/Modal/index.js | 1 + .../src/components/forms/AddAPIKeyForm.js | 114 ++++++++++++++++ .../forms/AddSkylinkToAPIKeyForm.js | 73 +++++++++++ .../src/pages/settings/api-keys.js | 118 +++++++++++------ packages/dashboard-v2/tailwind.config.js | 4 + 11 files changed, 477 insertions(+), 43 deletions(-) create mode 100644 packages/dashboard-v2/src/components/APIKeyList/APIKey.js create mode 100644 packages/dashboard-v2/src/components/APIKeyList/APIKeyList.js create mode 100644 packages/dashboard-v2/src/components/APIKeyList/index.js create mode 100644 packages/dashboard-v2/src/components/APIKeyList/useAPIKeyEdit.js create mode 100644 packages/dashboard-v2/src/components/APIKeyList/useAPIKeyRemoval.js create mode 100644 packages/dashboard-v2/src/components/forms/AddAPIKeyForm.js create mode 100644 packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js diff --git a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js new file mode 100644 index 00000000..61170327 --- /dev/null +++ b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js @@ -0,0 +1,123 @@ +import dayjs from "dayjs"; +import { useCallback, useState } from "react"; +import { Alert } from "../Alert"; +import { Button } from "../Button"; +import { AddSkylinkToAPIKeyForm } from "../forms/AddSkylinkToAPIKeyForm"; +import { CogIcon, TrashIcon } from "../Icons"; +import { Modal } from "../Modal"; +import { useAPIKeyEdit } from "./useAPIKeyEdit"; +import { useAPIKeyRemoval } from "./useAPIKeyRemoval"; + +export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { + const { id, name, createdAt, skylinks } = apiKey; + const isPublic = apiKey.public === "true"; + const [error, setError] = useState(null); + + const onSkylinkListEdited = useCallback(() => { + setError(null); + onEdited(); + }, [onEdited]); + + const onSkylinkListEditFailure = (errorMessage) => setError(errorMessage); + + const { + removalError, + removalInitiated, + prompt: promptRemoval, + abort: abortRemoval, + confirm: confirmRemoval, + } = useAPIKeyRemoval({ + key: apiKey, + onSuccess: onRemoved, + onFailure: onRemovalError, + }); + + const { + editInitiated, + prompt: promptEdit, + abort: abortEdit, + removeSkylink, + } = useAPIKeyEdit({ + key: apiKey, + onSkylinkRemoved: onSkylinkListEdited, + onSkylinkRemovalFailure: onSkylinkListEditFailure, + }); + + const closeEditModal = useCallback(() => { + setError(null); + abortEdit(); + }, [abortEdit]); + + return ( +
  • + {name || id} + + {dayjs(createdAt).format("MMM DD, YYYY")} + + {isPublic && ( + + )} + + + + {removalInitiated && ( + +

    Delete API key

    +
    +

    Are you sure you want to delete the following API key?

    +

    {name || id}

    +
    + {removalError && {removalError}} + +
    + + +
    +
    + )} + {editInitiated && ( + +

    Covered Skylinks

    + {skylinks?.length > 0 ? ( +
      + {skylinks.map((skylink) => ( +
    • + + {skylink} + + +
    • + ))} +
    + ) : ( + No skylinks here yet. You can add the first one below 🙃 + )} + +
    + {error && {error}} + +
    +
    + +
    +
    + )} +
  • + ); +}; diff --git a/packages/dashboard-v2/src/components/APIKeyList/APIKeyList.js b/packages/dashboard-v2/src/components/APIKeyList/APIKeyList.js new file mode 100644 index 00000000..3d3e504d --- /dev/null +++ b/packages/dashboard-v2/src/components/APIKeyList/APIKeyList.js @@ -0,0 +1,14 @@ +import { APIKey } from "./APIKey"; + +export const APIKeyList = ({ keys, reloadKeys, title }) => { + return ( + <> +
    {title}
    +
      + {keys.map((key) => ( + + ))} +
    + + ); +}; diff --git a/packages/dashboard-v2/src/components/APIKeyList/index.js b/packages/dashboard-v2/src/components/APIKeyList/index.js new file mode 100644 index 00000000..8ade7744 --- /dev/null +++ b/packages/dashboard-v2/src/components/APIKeyList/index.js @@ -0,0 +1 @@ +export * from "./APIKeyList"; diff --git a/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyEdit.js b/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyEdit.js new file mode 100644 index 00000000..052102af --- /dev/null +++ b/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyEdit.js @@ -0,0 +1,31 @@ +import { useCallback, useState } from "react"; +import accountsService from "../../services/accountsService"; + +export const useAPIKeyEdit = ({ key, onSkylinkRemoved, onSkylinkRemovalFailure }) => { + const [editInitiated, setEditInitiated] = useState(false); + + const prompt = () => setEditInitiated(true); + const abort = () => setEditInitiated(false); + const removeSkylink = useCallback( + async (skylink) => { + try { + await accountsService.patch(`user/apikeys/${key.id}`, { + json: { + remove: [skylink], + }, + }); + onSkylinkRemoved(); + } catch { + onSkylinkRemovalFailure(); + } + }, + [onSkylinkRemoved, onSkylinkRemovalFailure, key] + ); + + return { + editInitiated, + prompt, + abort, + removeSkylink, + }; +}; diff --git a/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyRemoval.js b/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyRemoval.js new file mode 100644 index 00000000..46d5d424 --- /dev/null +++ b/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyRemoval.js @@ -0,0 +1,39 @@ +import { useCallback, useState } from "react"; +import accountsService from "../../services/accountsService"; + +export const useAPIKeyRemoval = ({ key, onSuccess }) => { + const [removalInitiated, setRemovalInitiated] = useState(false); + const [removalError, setRemovalError] = useState(null); + + const prompt = () => setRemovalInitiated(true); + const abort = () => setRemovalInitiated(false); + + const confirm = useCallback(async () => { + setRemovalError(null); + try { + await accountsService.delete(`user/apikeys/${key.id}`); + setRemovalInitiated(false); + onSuccess(); + } catch (err) { + let message = "There was an error processing your request. Please try again later."; + + if (err.response) { + const response = await err.response.json(); + + if (response.message) { + message = response.message; + } + } + + setRemovalError(message); + } + }, [onSuccess, key]); + + return { + removalInitiated, + removalError, + prompt, + abort, + confirm, + }; +}; diff --git a/packages/dashboard-v2/src/components/Modal/Modal.js b/packages/dashboard-v2/src/components/Modal/Modal.js index 6fd8e00a..c183e190 100644 --- a/packages/dashboard-v2/src/components/Modal/Modal.js +++ b/packages/dashboard-v2/src/components/Modal/Modal.js @@ -10,7 +10,7 @@ import { Overlay } from "./Overlay"; export const Modal = ({ children, className, onClose }) => ( -
    +
    diff --git a/packages/dashboard-v2/src/components/Modal/index.js b/packages/dashboard-v2/src/components/Modal/index.js index 28d34710..00ce01f6 100644 --- a/packages/dashboard-v2/src/components/Modal/index.js +++ b/packages/dashboard-v2/src/components/Modal/index.js @@ -1 +1,2 @@ export * from "./ModalPortal"; +export * from "./Modal"; diff --git a/packages/dashboard-v2/src/components/forms/AddAPIKeyForm.js b/packages/dashboard-v2/src/components/forms/AddAPIKeyForm.js new file mode 100644 index 00000000..703d88a0 --- /dev/null +++ b/packages/dashboard-v2/src/components/forms/AddAPIKeyForm.js @@ -0,0 +1,114 @@ +import * as Yup from "yup"; +import { forwardRef, useImperativeHandle, useState } from "react"; +import PropTypes from "prop-types"; +import { Formik, Form } from "formik"; + +import accountsService from "../../services/accountsService"; + +import { Alert } from "../Alert"; +import { Button } from "../Button"; +import { CopyButton } from "../CopyButton"; +import { TextField } from "../Form/TextField"; +import { CircledProgressIcon, PlusIcon } from "../Icons"; + +const newAPIKeySchema = Yup.object().shape({ + name: Yup.string(), +}); + +const State = { + Pure: "PURE", + Success: "SUCCESS", + Failure: "FAILURE", +}; + +export const APIKeyType = { + Public: "public", + General: "general", +}; + +export const AddAPIKeyForm = forwardRef(({ onSuccess, type }, ref) => { + const [state, setState] = useState(State.Pure); + const [generatedKey, setGeneratedKey] = useState(null); + + useImperativeHandle(ref, () => ({ + reset: () => setState(State.Pure), + })); + + return ( +
    + {state === State.Success && ( + + Success! +

    Please copy your new API key below. We'll never show it again!

    +
    + + {generatedKey} + + +
    +
    + )} + {state === State.Failure && ( + We were not able to generate a new key. Please try again later. + )} + { + try { + const { key } = await accountsService + .post("user/apikeys", { + json: { + name, + public: type === APIKeyType.Public ? "true" : "false", + skylinks: type === APIKeyType.Public ? [] : null, + }, + }) + .json(); + + resetForm(); + setGeneratedKey(key); + setState(State.Success); + onSuccess(); + } catch { + setState(State.Failure); + } + }} + > + {({ errors, touched, isSubmitting }) => ( +
    +
    + +
    +
    + {isSubmitting ? ( + + ) : ( + + )} +
    +
    + )} +
    +
    + ); +}); + +AddAPIKeyForm.displayName = "AddAPIKeyForm"; + +AddAPIKeyForm.propTypes = { + onSuccess: PropTypes.func.isRequired, + type: PropTypes.oneOf([APIKeyType.Public, APIKeyType.General]).isRequired, +}; diff --git a/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js b/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js new file mode 100644 index 00000000..fda27d36 --- /dev/null +++ b/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js @@ -0,0 +1,73 @@ +import * as Yup from "yup"; +import PropTypes from "prop-types"; +import { Formik, Form } from "formik"; + +import accountsService from "../../services/accountsService"; + +import { Button } from "../Button"; +import { TextField } from "../Form/TextField"; +import { CircledProgressIcon, PlusIcon } from "../Icons"; + +const newSkylinkSchema = Yup.object().shape({ + skylink: Yup.string().required("Provide a valid Skylink"), // TODO: Comprehensive Skylink validation +}); + +export const AddSkylinkToAPIKeyForm = ({ keyId, onSuccess, onFailure }) => ( + { + try { + await accountsService + .patch(`user/apikeys/${keyId}`, { + json: { + add: [skylink], + }, + }) + .json(); + + resetForm(); + onSuccess(); + } catch (err) { + if (err.response) { + const { message } = await err.response.json(); + onFailure(message); + } else { + onFailure("Unknown error occured, please try again."); + } + } + }} + > + {({ errors, touched, isSubmitting }) => ( +
    +
    + +
    +
    + {isSubmitting ? ( + + ) : ( + + )} +
    +
    + )} +
    +); + +AddSkylinkToAPIKeyForm.propTypes = { + onFailure: PropTypes.func.isRequired, + onSuccess: PropTypes.func.isRequired, + keyId: PropTypes.string.isRequired, +}; diff --git a/packages/dashboard-v2/src/pages/settings/api-keys.js b/packages/dashboard-v2/src/pages/settings/api-keys.js index 8ed8b1c8..3cbefb17 100644 --- a/packages/dashboard-v2/src/pages/settings/api-keys.js +++ b/packages/dashboard-v2/src/pages/settings/api-keys.js @@ -1,63 +1,97 @@ import useSWR from "swr"; -import dayjs from "dayjs"; +import { useCallback, useRef } from "react"; import UserSettingsLayout from "../../layouts/UserSettingsLayout"; -import { TextInputBasic } from "../../components/TextInputBasic"; -import { Button } from "../../components/Button"; -import { TrashIcon } from "../../components/Icons"; +import { AddAPIKeyForm, APIKeyType } from "../../components/forms/AddAPIKeyForm"; +import { APIKeyList } from "../../components/APIKeyList/APIKeyList"; +import { Alert } from "../../components/Alert"; const APIKeysPage = () => { - const { data: apiKeys } = useSWR("user/apikeys"); + const { data: apiKeys = [], mutate: reloadKeys, error } = useSWR("user/apikeys"); + const generalKeys = apiKeys.filter(({ public: isPublic }) => isPublic === "false"); + const publicKeys = apiKeys.filter(({ public: isPublic }) => isPublic === "true"); + + const publicFormRef = useRef(); + const generalFormRef = useRef(); + + const refreshState = useCallback( + (resetForms) => { + if (resetForms) { + publicFormRef.current?.reset(); + generalFormRef.current?.reset(); + } + reloadKeys(); + }, + [reloadKeys] + ); return ( <>
    -
    +

    API Keys

    -

    - At vero eos et caritatem, quae sine metu contineret, saluti prospexit civium, qua. Laudem et dolorem - aspernari ut ad naturam aut fu. +

    There are two types of API keys that you can generate for your account.

    +

    Make sure to use the appropriate type.

    +
    + +
    + +
    +
    Public keys
    +

    + Give read access to a selected list of Skylinks. You can share them publicly.

    + +
    + +
    + + {error ? ( + + An error occurred while loading your API keys. Please try again later. + + ) : ( +
    + {publicKeys?.length > 0 ? ( + refreshState(true)} /> + ) : ( + No public API keys found. + )} +
    + )}

    -
    -
    - -
    - -
    + +
    +
    General keys
    +

    + Give full access to Accounts service and are equivalent to using a JWT token. +

    +

    This type of API keys need to be kept secret and never shared with anyone.

    + +
    +
    + + {error ? ( + + An error occurred while loading your API keys. Please try again later. + + ) : ( +
    + {generalKeys?.length > 0 ? ( + refreshState(true)} /> + ) : ( + No general API keys found. + )} +
    + )}
    - {apiKeys?.length > 0 && ( -
    -
    API Keys
    -
      - {apiKeys.map(({ id, name, createdAt }) => ( -
    • - {name || id} - - {dayjs(createdAt).format("MMM DD, YYYY")} - - - -
    • - ))} -
    -
    - )}
    -
    - +
    +
    diff --git a/packages/dashboard-v2/tailwind.config.js b/packages/dashboard-v2/tailwind.config.js index 076d6912..636cd40e 100644 --- a/packages/dashboard-v2/tailwind.config.js +++ b/packages/dashboard-v2/tailwind.config.js @@ -54,6 +54,7 @@ module.exports = { wiggle: "wiggle 3s ease-in-out infinite", }, width: { + modal: "500px", page: "100%", "page-md": "640px", "page-lg": "896px", @@ -64,6 +65,9 @@ module.exports = { minWidth: { button: "112px", }, + maxWidth: { + modal: "calc(100vw - 1rem)", + }, }, }, plugins: [ From 3b981114826ffde1413e789edadc93586bba8478 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 25 Mar 2022 10:20:22 +0000 Subject: [PATCH 032/240] build(deps): bump minimist from 1.2.5 to 1.2.6 in /packages/dashboard Bumps [minimist](https://github.com/substack/minimist) from 1.2.5 to 1.2.6. - [Release notes](https://github.com/substack/minimist/releases) - [Commits](https://github.com/substack/minimist/compare/1.2.5...1.2.6) --- updated-dependencies: - dependency-name: minimist dependency-type: indirect ... Signed-off-by: dependabot[bot] --- packages/dashboard/yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 3c4368cd..6a27a893 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -1647,9 +1647,9 @@ minimatch@^3.0.4: brace-expansion "^1.1.7" minimist@^1.1.1, minimist@^1.2.0: - version "1.2.5" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" - integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== + version "1.2.6" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" + integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== ms@2.0.0: version "2.0.0" From 6cfb79d6cc1e61b299b4856412512a8061a94fb2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 25 Mar 2022 10:20:38 +0000 Subject: [PATCH 033/240] build(deps): bump minimist from 1.2.5 to 1.2.6 in /packages/health-check Bumps [minimist](https://github.com/substack/minimist) from 1.2.5 to 1.2.6. - [Release notes](https://github.com/substack/minimist/releases) - [Commits](https://github.com/substack/minimist/compare/1.2.5...1.2.6) --- updated-dependencies: - dependency-name: minimist dependency-type: indirect ... Signed-off-by: dependabot[bot] --- packages/health-check/yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/health-check/yarn.lock b/packages/health-check/yarn.lock index 7f465dbd..28a49b1b 100644 --- a/packages/health-check/yarn.lock +++ b/packages/health-check/yarn.lock @@ -2438,9 +2438,9 @@ minimatch@^3.0.4: brace-expansion "^1.1.7" minimist@^1.2.5: - version "1.2.5" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" - integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== + version "1.2.6" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" + integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== ms@2.0.0: version "2.0.0" From 8791aeb50f4e6453200c2810e8e31897d15db4d5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 25 Mar 2022 10:20:46 +0000 Subject: [PATCH 034/240] build(deps): bump minimist from 1.2.5 to 1.2.6 in /packages/dashboard-v2 Bumps [minimist](https://github.com/substack/minimist) from 1.2.5 to 1.2.6. - [Release notes](https://github.com/substack/minimist/releases) - [Commits](https://github.com/substack/minimist/compare/1.2.5...1.2.6) --- updated-dependencies: - dependency-name: minimist dependency-type: indirect ... Signed-off-by: dependabot[bot] --- packages/dashboard-v2/yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/dashboard-v2/yarn.lock b/packages/dashboard-v2/yarn.lock index 687e3c5b..52cf68b8 100644 --- a/packages/dashboard-v2/yarn.lock +++ b/packages/dashboard-v2/yarn.lock @@ -11040,9 +11040,9 @@ minimatch@^3.0.2, minimatch@^3.0.4: brace-expansion "^1.1.7" minimist@^1.1.1, minimist@^1.2.0, minimist@^1.2.3, minimist@^1.2.5: - version "1.2.5" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" - integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== + version "1.2.6" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" + integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== minipass-collect@^1.0.2: version "1.0.2" From 614b7791ec10bd272704a367505a72b95f8b50ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 25 Mar 2022 11:22:36 +0100 Subject: [PATCH 035/240] refactor(dashboard-v2): use a hook for adding skylinks to pubkeys --- .../src/components/APIKeyList/APIKey.js | 11 ++++---- .../components/APIKeyList/useAPIKeyEdit.js | 28 +++++++++++++------ .../components/APIKeyList/useAPIKeyRemoval.js | 6 ++-- .../forms/AddSkylinkToAPIKeyForm.js | 24 ++-------------- 4 files changed, 33 insertions(+), 36 deletions(-) diff --git a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js index 61170327..086dc493 100644 --- a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js +++ b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js @@ -36,11 +36,12 @@ export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { editInitiated, prompt: promptEdit, abort: abortEdit, + addSkylink, removeSkylink, } = useAPIKeyEdit({ key: apiKey, - onSkylinkRemoved: onSkylinkListEdited, - onSkylinkRemovalFailure: onSkylinkListEditFailure, + onSkylinkListUpdate: onSkylinkListEdited, + onSkylinkListUpdateFailure: onSkylinkListEditFailure, }); const closeEditModal = useCallback(() => { @@ -95,8 +96,8 @@ export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { {skylinks?.length > 0 ? (
      {skylinks.map((skylink) => ( -
    • - +
    • + {skylink} diff --git a/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyEdit.js b/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyEdit.js index 052102af..a821ca02 100644 --- a/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyEdit.js +++ b/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyEdit.js @@ -1,31 +1,43 @@ import { useCallback, useState } from "react"; import accountsService from "../../services/accountsService"; -export const useAPIKeyEdit = ({ key, onSkylinkRemoved, onSkylinkRemovalFailure }) => { +export const useAPIKeyEdit = ({ key, onSkylinkListUpdate, onSkylinkListUpdateFailure }) => { const [editInitiated, setEditInitiated] = useState(false); const prompt = () => setEditInitiated(true); const abort = () => setEditInitiated(false); - const removeSkylink = useCallback( - async (skylink) => { + const updateSkylinkList = useCallback( + async (action, skylink) => { try { await accountsService.patch(`user/apikeys/${key.id}`, { json: { - remove: [skylink], + [action]: [skylink], }, }); - onSkylinkRemoved(); - } catch { - onSkylinkRemovalFailure(); + onSkylinkListUpdate(); + + return true; + } catch (err) { + if (err.response) { + const { message } = await err.response.json(); + onSkylinkListUpdateFailure(message); + } else { + onSkylinkListUpdateFailure("Unknown error occured, please try again."); + } + + return false; } }, - [onSkylinkRemoved, onSkylinkRemovalFailure, key] + [onSkylinkListUpdate, onSkylinkListUpdateFailure, key] ); + const addSkylink = (skylink) => updateSkylinkList("add", skylink); + const removeSkylink = (skylink) => updateSkylinkList("remove", skylink); return { editInitiated, prompt, abort, + addSkylink, removeSkylink, }; }; diff --git a/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyRemoval.js b/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyRemoval.js index 46d5d424..b9c53bd9 100644 --- a/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyRemoval.js +++ b/packages/dashboard-v2/src/components/APIKeyList/useAPIKeyRemoval.js @@ -5,7 +5,10 @@ export const useAPIKeyRemoval = ({ key, onSuccess }) => { const [removalInitiated, setRemovalInitiated] = useState(false); const [removalError, setRemovalError] = useState(null); - const prompt = () => setRemovalInitiated(true); + const prompt = () => { + setRemovalError(null); + setRemovalInitiated(true); + }; const abort = () => setRemovalInitiated(false); const confirm = useCallback(async () => { @@ -19,7 +22,6 @@ export const useAPIKeyRemoval = ({ key, onSuccess }) => { if (err.response) { const response = await err.response.json(); - if (response.message) { message = response.message; } diff --git a/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js b/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js index fda27d36..8c01a0fb 100644 --- a/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js +++ b/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js @@ -12,31 +12,15 @@ const newSkylinkSchema = Yup.object().shape({ skylink: Yup.string().required("Provide a valid Skylink"), // TODO: Comprehensive Skylink validation }); -export const AddSkylinkToAPIKeyForm = ({ keyId, onSuccess, onFailure }) => ( +export const AddSkylinkToAPIKeyForm = ({ addSkylink }) => ( { - try { - await accountsService - .patch(`user/apikeys/${keyId}`, { - json: { - add: [skylink], - }, - }) - .json(); - + if (await addSkylink(skylink)) { resetForm(); - onSuccess(); - } catch (err) { - if (err.response) { - const { message } = await err.response.json(); - onFailure(message); - } else { - onFailure("Unknown error occured, please try again."); - } } }} > @@ -67,7 +51,5 @@ export const AddSkylinkToAPIKeyForm = ({ keyId, onSuccess, onFailure }) => ( ); AddSkylinkToAPIKeyForm.propTypes = { - onFailure: PropTypes.func.isRequired, - onSuccess: PropTypes.func.isRequired, - keyId: PropTypes.string.isRequired, + addSkylink: PropTypes.func.isRequired, }; From 8f2bd96ab308ca047bde47042f36feae3782216d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 25 Mar 2022 10:42:54 +0000 Subject: [PATCH 036/240] build(deps): bump minimist from 1.2.5 to 1.2.6 in /packages/website Bumps [minimist](https://github.com/substack/minimist) from 1.2.5 to 1.2.6. - [Release notes](https://github.com/substack/minimist/releases) - [Commits](https://github.com/substack/minimist/compare/1.2.5...1.2.6) --- updated-dependencies: - dependency-name: minimist dependency-type: indirect ... Signed-off-by: dependabot[bot] --- packages/website/yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 78db47fe..255e5afb 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -8729,9 +8729,9 @@ minimist-options@4.1.0: kind-of "^6.0.3" minimist@^1.1.1, minimist@^1.2.0, minimist@^1.2.3, minimist@^1.2.5: - version "1.2.5" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" - integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== + version "1.2.6" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" + integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== mitt@^1.2.0: version "1.2.0" From 9dd4b8eb172b1b2de99bdf20aa51689062b7e9bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 25 Mar 2022 11:45:58 +0100 Subject: [PATCH 037/240] feat(dashboard-v2): add skylink validation & parsing --- .../components/forms/AddSkylinkToAPIKeyForm.js | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js b/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js index 8c01a0fb..fd9fe54b 100644 --- a/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js +++ b/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js @@ -1,15 +1,22 @@ import * as Yup from "yup"; import PropTypes from "prop-types"; import { Formik, Form } from "formik"; - -import accountsService from "../../services/accountsService"; +import { parseSkylink } from "skynet-js"; import { Button } from "../Button"; import { TextField } from "../Form/TextField"; import { CircledProgressIcon, PlusIcon } from "../Icons"; const newSkylinkSchema = Yup.object().shape({ - skylink: Yup.string().required("Provide a valid Skylink"), // TODO: Comprehensive Skylink validation + skylink: Yup.string() + .required("Skylink is required") + .test("skylink", "Provide a valid Skylink", (value) => { + try { + return parseSkylink(value) !== null; + } catch { + return false; + } + }), }); export const AddSkylinkToAPIKeyForm = ({ addSkylink }) => ( @@ -19,7 +26,7 @@ export const AddSkylinkToAPIKeyForm = ({ addSkylink }) => ( }} validationSchema={newSkylinkSchema} onSubmit={async ({ skylink }, { resetForm }) => { - if (await addSkylink(skylink)) { + if (await addSkylink(parseSkylink(skylink))) { resetForm(); } }} From 11ec2afdc6f3aa131dfebb1097e827d6fa474392 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20Wypch=C5=82o?= Date: Fri, 25 Mar 2022 11:51:39 +0100 Subject: [PATCH 038/240] switch to siasky.net --- .github/workflows/deploy-website.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/deploy-website.yml b/.github/workflows/deploy-website.yml index a311d997..143675e2 100644 --- a/.github/workflows/deploy-website.yml +++ b/.github/workflows/deploy-website.yml @@ -45,7 +45,5 @@ jobs: uses: skynetlabs/deploy-to-skynet-action@v2 with: upload-dir: packages/website/public - portal-url: https://skynetpro.net - skynet-jwt: ${{ secrets.SKYNET_JWT }} github-token: ${{ secrets.GITHUB_TOKEN }} registry-seed: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' && secrets.WEBSITE_REGISTRY_SEED || '' }} From 08bab146ec644d0323da37c04b106b68270c3e7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 25 Mar 2022 12:44:09 +0100 Subject: [PATCH 039/240] feat(dashboard-v2): add node about public key needing configuration --- .../src/components/APIKeyList/APIKey.js | 24 +++++++++++++-- .../Icons/icons/ImportantNoteIcon.js | 11 +++++++ .../src/components/Icons/index.js | 1 + .../src/components/Tooltip/Tooltip.js | 29 +++++++++++++++++++ .../forms/AddSkylinkToAPIKeyForm.js | 1 + 5 files changed, 63 insertions(+), 3 deletions(-) create mode 100644 packages/dashboard-v2/src/components/Icons/icons/ImportantNoteIcon.js create mode 100644 packages/dashboard-v2/src/components/Tooltip/Tooltip.js diff --git a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js index 086dc493..257797f3 100644 --- a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js +++ b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js @@ -1,12 +1,16 @@ import dayjs from "dayjs"; +import cn from "classnames"; import { useCallback, useState } from "react"; + import { Alert } from "../Alert"; import { Button } from "../Button"; import { AddSkylinkToAPIKeyForm } from "../forms/AddSkylinkToAPIKeyForm"; -import { CogIcon, TrashIcon } from "../Icons"; +import { CogIcon, ImportantNoteIcon, TrashIcon } from "../Icons"; import { Modal } from "../Modal"; + import { useAPIKeyEdit } from "./useAPIKeyEdit"; import { useAPIKeyRemoval } from "./useAPIKeyRemoval"; +import { Tooltip } from "../Tooltip/Tooltip"; export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { const { id, name, createdAt, skylinks } = apiKey; @@ -49,9 +53,23 @@ export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { abortEdit(); }, [abortEdit]); + const needsAttention = isPublic && skylinks?.length === 0; + return ( -
    • - {name || id} +
    • + + {name || "unnamed key"} + {needsAttention && ( + + + + )} + {dayjs(createdAt).format("MMM DD, YYYY")} diff --git a/packages/dashboard-v2/src/components/Icons/icons/ImportantNoteIcon.js b/packages/dashboard-v2/src/components/Icons/icons/ImportantNoteIcon.js new file mode 100644 index 00000000..94514716 --- /dev/null +++ b/packages/dashboard-v2/src/components/Icons/icons/ImportantNoteIcon.js @@ -0,0 +1,11 @@ +import { withIconProps } from "../withIconProps"; + +export const ImportantNoteIcon = withIconProps(({ size, ...props }) => ( + + + + + + + +)); diff --git a/packages/dashboard-v2/src/components/Icons/index.js b/packages/dashboard-v2/src/components/Icons/index.js index e2af85e9..0bb96694 100644 --- a/packages/dashboard-v2/src/components/Icons/index.js +++ b/packages/dashboard-v2/src/components/Icons/index.js @@ -14,3 +14,4 @@ export * from "./icons/CopyIcon"; export * from "./icons/ShareIcon"; export * from "./icons/SimpleUploadIcon"; export * from "./icons/TrashIcon"; +export * from "./icons/ImportantNoteIcon"; diff --git a/packages/dashboard-v2/src/components/Tooltip/Tooltip.js b/packages/dashboard-v2/src/components/Tooltip/Tooltip.js new file mode 100644 index 00000000..7344bf01 --- /dev/null +++ b/packages/dashboard-v2/src/components/Tooltip/Tooltip.js @@ -0,0 +1,29 @@ +import React, { Children, cloneElement, useState } from "react"; +import styled, { keyframes } from "styled-components"; + +const fadeIn = keyframes` + 0% { opacity: 0; } + 100% { opacity: 1; } +`; + +const Popper = styled.div.attrs({ + className: `absolute left-full top-1/2 z-10 px-2 py-1 text-xs + bg-black/90 text-white rounded`, +})` + transform: translateY(-50%); + animation: ${fadeIn} 0.2s ease-in-out; +`; + +export const Tooltip = ({ message, children, className }) => { + const [visible, setVisible] = useState(false); + + const show = () => setVisible(true); + const hide = () => setVisible(false); + + return ( + + {children} + {visible && {message}} + + ); +}; diff --git a/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js b/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js index fd9fe54b..55f27a01 100644 --- a/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js +++ b/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js @@ -39,6 +39,7 @@ export const AddSkylinkToAPIKeyForm = ({ addSkylink }) => ( id="skylink" name="skylink" label="New Skylink" + placeholder="Paste a new Skylink here" error={errors.skylink} touched={touched.skylink} /> From 46d295e54ceb675d9dc0ec489d988e924acf62f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 25 Mar 2022 12:48:11 +0100 Subject: [PATCH 040/240] chore(dashboard-v2): cleanup unused imports --- packages/dashboard-v2/src/components/Tooltip/Tooltip.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/dashboard-v2/src/components/Tooltip/Tooltip.js b/packages/dashboard-v2/src/components/Tooltip/Tooltip.js index 7344bf01..d7bfde39 100644 --- a/packages/dashboard-v2/src/components/Tooltip/Tooltip.js +++ b/packages/dashboard-v2/src/components/Tooltip/Tooltip.js @@ -1,4 +1,4 @@ -import React, { Children, cloneElement, useState } from "react"; +import React, { useState } from "react"; import styled, { keyframes } from "styled-components"; const fadeIn = keyframes` From 52314130742c05ec88cb9158f7636b08e35f1e04 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 25 Mar 2022 12:54:59 +0100 Subject: [PATCH 041/240] fix(dashboard-v2): bulletproof emptying one's email address --- .../src/components/forms/AccountSettingsForm.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/packages/dashboard-v2/src/components/forms/AccountSettingsForm.js b/packages/dashboard-v2/src/components/forms/AccountSettingsForm.js index f979dd31..ad29b85c 100644 --- a/packages/dashboard-v2/src/components/forms/AccountSettingsForm.js +++ b/packages/dashboard-v2/src/components/forms/AccountSettingsForm.js @@ -16,7 +16,7 @@ const emailUpdateSchema = Yup.object().shape({ is: isPopulated, then: (schema) => schema.required("Please confirm new email address"), }), - password: Yup.string().min(6, "Password has to be at least 6 characters long"), + password: Yup.string().min(1, "Password can't be blank"), confirmPassword: Yup.string() .oneOf([Yup.ref("password"), null], "Passwords must match") .when("password", { @@ -38,7 +38,10 @@ export const AccountSettingsForm = ({ user, onSuccess, onFailure }) => { onSubmit={async ({ email, password }, { resetForm }) => { try { await accountsService.put("user", { - json: { email, password }, + json: { + email: email || undefined, + password: password || undefined, + }, }); resetForm(); From 2aa3437ab67c70dad5aebf0511a01c242c730f74 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 25 Mar 2022 12:57:57 +0100 Subject: [PATCH 042/240] chore(dashboard-v2): await reloadUser --- packages/dashboard-v2/src/pages/settings/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/dashboard-v2/src/pages/settings/index.js b/packages/dashboard-v2/src/pages/settings/index.js index 32ec95ac..ad7a34d8 100644 --- a/packages/dashboard-v2/src/pages/settings/index.js +++ b/packages/dashboard-v2/src/pages/settings/index.js @@ -41,8 +41,8 @@ const AccountPage = () => { {state === State.Success && Changes saved successfully.} { - reloadUser(); + onSuccess={async () => { + await reloadUser(); setState(State.Success); }} onFailure={() => setState(State.Failure)} From 5bb1ed18c439e923e910c9702830a0ebd957025d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 25 Mar 2022 13:39:57 +0100 Subject: [PATCH 043/240] chore(dashboard-v2): handle reloadUser error --- .../components/forms/AccountSettingsForm.js | 16 +++++++----- .../dashboard-v2/src/pages/settings/index.js | 26 ++++++++++++------- 2 files changed, 26 insertions(+), 16 deletions(-) diff --git a/packages/dashboard-v2/src/components/forms/AccountSettingsForm.js b/packages/dashboard-v2/src/components/forms/AccountSettingsForm.js index ad29b85c..2c382c1b 100644 --- a/packages/dashboard-v2/src/components/forms/AccountSettingsForm.js +++ b/packages/dashboard-v2/src/components/forms/AccountSettingsForm.js @@ -37,15 +37,17 @@ export const AccountSettingsForm = ({ user, onSuccess, onFailure }) => { validationSchema={emailUpdateSchema} onSubmit={async ({ email, password }, { resetForm }) => { try { - await accountsService.put("user", { - json: { - email: email || undefined, - password: password || undefined, - }, - }); + const user = await accountsService + .put("user", { + json: { + email: email || undefined, + password: password || undefined, + }, + }) + .json(); resetForm(); - onSuccess(); + await onSuccess(user); } catch { onFailure(); } diff --git a/packages/dashboard-v2/src/pages/settings/index.js b/packages/dashboard-v2/src/pages/settings/index.js index ad7a34d8..358a4b28 100644 --- a/packages/dashboard-v2/src/pages/settings/index.js +++ b/packages/dashboard-v2/src/pages/settings/index.js @@ -1,4 +1,4 @@ -import { useState } from "react"; +import { useCallback, useState } from "react"; import { navigate } from "gatsby"; import { useUser } from "../../contexts/user"; @@ -22,6 +22,21 @@ const AccountPage = () => { const prompt = () => setRemovalInitiated(true); const abort = () => setRemovalInitiated(false); + const onSettingsUpdated = useCallback( + async (updatedState) => { + try { + // Update state locally and request revalidation. + await reloadUser(updatedState); + } finally { + // If revalidation fails, we can't really do much. Request + // will be auto-retried by SWR, so we'll just show a message + // about the update request being successful. + setState(State.Success); + } + }, + [reloadUser] + ); + return ( <>
      @@ -39,14 +54,7 @@ const AccountPage = () => { There was an error processing your request. Please try again later. )} {state === State.Success && Changes saved successfully.} - { - await reloadUser(); - setState(State.Success); - }} - onFailure={() => setState(State.Failure)} - /> + setState(State.Failure)} />

    From c2ee546c920a2e3bb8785542a1aae5649e09cc1e Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 25 Mar 2022 14:56:08 +0100 Subject: [PATCH 044/240] enable lua code coverage --- .github/workflows/nginx-lua-unit-tests.yml | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/.github/workflows/nginx-lua-unit-tests.yml b/.github/workflows/nginx-lua-unit-tests.yml index 514459fa..f9d2da41 100644 --- a/.github/workflows/nginx-lua-unit-tests.yml +++ b/.github/workflows/nginx-lua-unit-tests.yml @@ -4,8 +4,15 @@ name: Nginx Lua Unit Tests on: + push: + branches: + - "master" + paths: + - ".github/workflows/nginx-lua-unit-tests.yml" + - "docker/nginx/libs/**.lua" pull_request: paths: + - ".github/workflows/nginx-lua-unit-tests.yml" - "docker/nginx/libs/**.lua" jobs: @@ -25,9 +32,16 @@ jobs: hererocks env --lua=5.1 -rlatest source env/bin/activate luarocks install busted + luarocks install luacov luarocks install hasher - name: Unit Tests run: | source env/bin/activate - busted --verbose --pattern=spec --directory=docker/nginx/libs . + busted --verbose --coverage --pattern=spec --directory=docker/nginx/libs . + cd docker/nginx/libs && luacov + + - uses: codecov/codecov-action@v2 + with: + directory: docker/nginx/libs + flags: nginx-lua From 45dc78ed193b2fc44ed6e1c9836cbdfbccfa10e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 25 Mar 2022 17:47:44 +0100 Subject: [PATCH 045/240] feat(dashboard-v2): add dedicated form for public api keys --- packages/dashboard-v2/gatsby-config.js | 1 + .../src/components/APIKeyList/APIKey.js | 39 ++-- .../components/forms/AddPublicAPIKeyForm.js | 194 ++++++++++++++++++ .../src/pages/settings/api-keys.js | 3 +- 4 files changed, 217 insertions(+), 20 deletions(-) create mode 100644 packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js diff --git a/packages/dashboard-v2/gatsby-config.js b/packages/dashboard-v2/gatsby-config.js index 160a7784..ce35de3a 100644 --- a/packages/dashboard-v2/gatsby-config.js +++ b/packages/dashboard-v2/gatsby-config.js @@ -5,6 +5,7 @@ module.exports = { title: `Accounts Dashboard`, siteUrl: `https://www.yourdomain.tld`, }, + trailingSlash: "never", plugins: [ "gatsby-plugin-image", "gatsby-plugin-provide-react", diff --git a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js index 257797f3..a11d1808 100644 --- a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js +++ b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js @@ -5,12 +5,11 @@ import { useCallback, useState } from "react"; import { Alert } from "../Alert"; import { Button } from "../Button"; import { AddSkylinkToAPIKeyForm } from "../forms/AddSkylinkToAPIKeyForm"; -import { CogIcon, ImportantNoteIcon, TrashIcon } from "../Icons"; +import { CogIcon, TrashIcon } from "../Icons"; import { Modal } from "../Modal"; import { useAPIKeyEdit } from "./useAPIKeyEdit"; import { useAPIKeyRemoval } from "./useAPIKeyRemoval"; -import { Tooltip } from "../Tooltip/Tooltip"; export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { const { id, name, createdAt, skylinks } = apiKey; @@ -53,22 +52,28 @@ export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { abortEdit(); }, [abortEdit]); - const needsAttention = isPublic && skylinks?.length === 0; + const skylinksNumber = skylinks?.length ?? 0; + const isNotConfigured = isPublic && skylinksNumber === 0; return (
  • - {name || "unnamed key"} - {needsAttention && ( - - - - )} + + {name || "unnamed key"} + + {dayjs(createdAt).format("MMM DD, YYYY")} @@ -77,16 +82,12 @@ export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { )} - diff --git a/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js b/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js new file mode 100644 index 00000000..25890275 --- /dev/null +++ b/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js @@ -0,0 +1,194 @@ +import * as Yup from "yup"; +import { forwardRef, useImperativeHandle, useState } from "react"; +import PropTypes from "prop-types"; +import { Formik, Form, FieldArray } from "formik"; +import { parseSkylink } from "skynet-js"; +import cn from "classnames"; + +import accountsService from "../../services/accountsService"; + +import { Alert } from "../Alert"; +import { Button } from "../Button"; +import { CopyButton } from "../CopyButton"; +import { TextField } from "../Form/TextField"; +import { PlusIcon, TrashIcon } from "../Icons"; + +const skylinkValidator = (optional) => (value) => { + if (!value) { + return optional; + } + + try { + return parseSkylink(value) !== null; + } catch { + return false; + } +}; + +const newPublicAPIKeySchema = Yup.object().shape({ + name: Yup.string(), + skylinks: Yup.array().of(Yup.string().test("skylink", "Provide a valid Skylink", skylinkValidator(false))), + nextSkylink: Yup.string().when("skylinks", { + is: (skylinks) => skylinks.length === 0, + then: (schema) => schema.test("skylink", "Provide a valid Skylink", skylinkValidator(true)), + otherwise: (schema) => schema.test("skylink", "Provide a valid Skylink", skylinkValidator(true)), + }), +}); + +const State = { + Pure: "PURE", + Success: "SUCCESS", + Failure: "FAILURE", +}; + +export const AddPublicAPIKeyForm = forwardRef(({ onSuccess }, ref) => { + const [state, setState] = useState(State.Pure); + const [generatedKey, setGeneratedKey] = useState(null); + + useImperativeHandle(ref, () => ({ + reset: () => setState(State.Pure), + })); + + return ( +
    + {state === State.Success && ( + + Success! +

    Please copy your new API key below. We'll never show it again!

    +
    + + {generatedKey} + + +
    +
    + )} + {state === State.Failure && ( + We were not able to generate a new key. Please try again later. + )} + { + try { + const { key } = await accountsService + .post("user/apikeys", { + json: { + name, + public: "true", + skylinks: [...skylinks, nextSkylink].filter(Boolean).map(parseSkylink), + }, + }) + .json(); + + resetForm(); + setGeneratedKey(key); + setState(State.Success); + onSuccess(); + } catch { + setState(State.Failure); + } + }} + > + {({ errors, touched, isSubmitting, values, isValid, setFieldValue, setFieldTouched }) => ( +
    +
    + +
    +
    +
    Skylinks accessible with the new key
    + { + const { skylinks = [] } = values; + const { skylinks: skylinksErrors = [] } = errors; + const { skylinks: skylinksTouched = [] } = touched; + + const appendSkylink = (skylink) => { + push(skylink); + setFieldValue("nextSkylink", "", false); + setFieldTouched("nextSkylink", false); + }; + const isNextSkylinkInvalid = Boolean( + errors.nextSkylink || !touched.nextSkylink || !values.nextSkylink + ); + + return ( +
    + {skylinks.map((_, index) => ( +
    + + + + +
    + ))} + +
    + { + if (event.key === "Enter" && isValid) { + event.preventDefault(); + appendSkylink(values.nextSkylink); + } + }} + /> + +
    +
    + ); + }} + /> +
    + +
    + +
    +
    + )} +
    +
    + ); +}); + +AddPublicAPIKeyForm.displayName = "AddAPIKeyForm"; + +AddPublicAPIKeyForm.propTypes = { + onSuccess: PropTypes.func.isRequired, +}; diff --git a/packages/dashboard-v2/src/pages/settings/api-keys.js b/packages/dashboard-v2/src/pages/settings/api-keys.js index 3cbefb17..05b2701c 100644 --- a/packages/dashboard-v2/src/pages/settings/api-keys.js +++ b/packages/dashboard-v2/src/pages/settings/api-keys.js @@ -6,6 +6,7 @@ import UserSettingsLayout from "../../layouts/UserSettingsLayout"; import { AddAPIKeyForm, APIKeyType } from "../../components/forms/AddAPIKeyForm"; import { APIKeyList } from "../../components/APIKeyList/APIKeyList"; import { Alert } from "../../components/Alert"; +import { AddPublicAPIKeyForm } from "../../components/forms/AddPublicAPIKeyForm"; const APIKeysPage = () => { const { data: apiKeys = [], mutate: reloadKeys, error } = useSWR("user/apikeys"); @@ -45,7 +46,7 @@ const APIKeysPage = () => {

    - +
    {error ? ( From 65cb6a4c2a6b5aaa613dde7b498a0066fc6ddcf9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20Wypch=C5=82o?= Date: Fri, 25 Mar 2022 18:56:03 +0100 Subject: [PATCH 046/240] include lua linter luacheck in github action (#1923) --- .github/workflows/nginx-lua-unit-tests.yml | 6 ++++++ docker/nginx/conf.d/include/track-download | 6 ++++-- docker/nginx/conf.d/include/track-registry | 3 ++- docker/nginx/conf.d/include/track-upload | 6 ++++-- docker/nginx/libs/basexx.lua | 24 +++++++++++----------- docker/nginx/libs/skynet/account.lua | 7 ++++--- docker/nginx/libs/skynet/skylink.lua | 2 +- docker/nginx/libs/skynet/skylink.spec.lua | 2 +- docker/nginx/libs/utils.spec.lua | 20 +++++++++--------- 9 files changed, 44 insertions(+), 32 deletions(-) diff --git a/.github/workflows/nginx-lua-unit-tests.yml b/.github/workflows/nginx-lua-unit-tests.yml index 514459fa..aab81ac2 100644 --- a/.github/workflows/nginx-lua-unit-tests.yml +++ b/.github/workflows/nginx-lua-unit-tests.yml @@ -26,6 +26,12 @@ jobs: source env/bin/activate luarocks install busted luarocks install hasher + luarocks install luacheck + + - name: Lint code + run: | + source env/bin/activate + luacheck docker/nginx/libs --std ngx_lua+busted - name: Unit Tests run: | diff --git a/docker/nginx/conf.d/include/track-download b/docker/nginx/conf.d/include/track-download index 408e4150..4e12fd41 100644 --- a/docker/nginx/conf.d/include/track-download +++ b/docker/nginx/conf.d/include/track-download @@ -16,7 +16,8 @@ log_by_lua_block { }) if err or (res and res.status ~= ngx.HTTP_NO_CONTENT) then - ngx.log(ngx.ERR, "Failed accounts service request /track/download/" .. skylink .. ": ", err or ("[HTTP " .. res.status .. "] " .. res.body)) + local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) + ngx.log(ngx.ERR, "Failed accounts service request /track/download/" .. skylink .. ": ", error_response) end end @@ -40,7 +41,8 @@ log_by_lua_block { }) if err or (res and res.status ~= ngx.HTTP_OK) then - ngx.log(ngx.ERR, "Failed malware-scanner request /scan/" .. skylink .. ": ", err or ("[HTTP " .. res.status .. "] " .. res.body)) + local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) + ngx.log(ngx.ERR, "Failed malware-scanner request /scan/" .. skylink .. ": ", error_response) end end diff --git a/docker/nginx/conf.d/include/track-registry b/docker/nginx/conf.d/include/track-registry index 8e8ae1d4..2c840491 100644 --- a/docker/nginx/conf.d/include/track-registry +++ b/docker/nginx/conf.d/include/track-registry @@ -19,7 +19,8 @@ log_by_lua_block { }) if err or (res and res.status ~= ngx.HTTP_NO_CONTENT) then - ngx.log(ngx.ERR, "Failed accounts service request /track/registry/" .. registry_action .. ": ", err or ("[HTTP " .. res.status .. "] " .. res.body)) + local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) + ngx.log(ngx.ERR, "Failed accounts service request /track/registry/" .. registry_action .. ": ", error_response) end end diff --git a/docker/nginx/conf.d/include/track-upload b/docker/nginx/conf.d/include/track-upload index edca6bd7..36b12b9e 100644 --- a/docker/nginx/conf.d/include/track-upload +++ b/docker/nginx/conf.d/include/track-upload @@ -15,7 +15,8 @@ log_by_lua_block { }) if err or (res and res.status ~= ngx.HTTP_NO_CONTENT) then - ngx.log(ngx.ERR, "Failed accounts service request /track/upload/" .. skylink .. ": ", err or ("[HTTP " .. res.status .. "] " .. res.body)) + local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) + ngx.log(ngx.ERR, "Failed accounts service request /track/upload/" .. skylink .. ": ", error_response) end end @@ -40,7 +41,8 @@ log_by_lua_block { }) if err or (res and res.status ~= ngx.HTTP_OK) then - ngx.log(ngx.ERR, "Failed malware-scanner request /scan/" .. skylink .. ": ", err or ("[HTTP " .. res.status .. "] " .. res.body)) + local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) + ngx.log(ngx.ERR, "Failed malware-scanner request /scan/" .. skylink .. ": ", error_response) end end diff --git a/docker/nginx/libs/basexx.lua b/docker/nginx/libs/basexx.lua index b077ee9a..b53c7337 100644 --- a/docker/nginx/libs/basexx.lua +++ b/docker/nginx/libs/basexx.lua @@ -21,7 +21,7 @@ local function divide_string( str, max ) return result end - + local function number_to_bit( num, length ) local bits = {} @@ -144,7 +144,7 @@ function basexx.to_basexx( str, alphabet, bits, pad ) end table.insert( result, pad ) - return table.concat( result ) + return table.concat( result ) end -------------------------------------------------------------------------------- @@ -225,16 +225,16 @@ local function length_error( len, d ) end local z85Decoder = { 0x00, 0x44, 0x00, 0x54, 0x53, 0x52, 0x48, 0x00, - 0x4B, 0x4C, 0x46, 0x41, 0x00, 0x3F, 0x3E, 0x45, - 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, - 0x08, 0x09, 0x40, 0x00, 0x49, 0x42, 0x4A, 0x47, - 0x51, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2A, - 0x2B, 0x2C, 0x2D, 0x2E, 0x2F, 0x30, 0x31, 0x32, - 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3A, - 0x3B, 0x3C, 0x3D, 0x4D, 0x00, 0x4E, 0x43, 0x00, - 0x00, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F, 0x10, - 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, - 0x19, 0x1A, 0x1B, 0x1C, 0x1D, 0x1E, 0x1F, 0x20, + 0x4B, 0x4C, 0x46, 0x41, 0x00, 0x3F, 0x3E, 0x45, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x40, 0x00, 0x49, 0x42, 0x4A, 0x47, + 0x51, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2A, + 0x2B, 0x2C, 0x2D, 0x2E, 0x2F, 0x30, 0x31, 0x32, + 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3A, + 0x3B, 0x3C, 0x3D, 0x4D, 0x00, 0x4E, 0x43, 0x00, + 0x00, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1A, 0x1B, 0x1C, 0x1D, 0x1E, 0x1F, 0x20, 0x21, 0x22, 0x23, 0x4F, 0x00, 0x50, 0x00, 0x00 } function basexx.from_z85( str, ignore ) diff --git a/docker/nginx/libs/skynet/account.lua b/docker/nginx/libs/skynet/account.lua index 5e0db371..6fa2c4d2 100644 --- a/docker/nginx/libs/skynet/account.lua +++ b/docker/nginx/libs/skynet/account.lua @@ -82,7 +82,8 @@ function _M.get_account_limits() -- fail gracefully in case /user/limits failed if err or (res and res.status ~= ngx.HTTP_OK) then - ngx.log(ngx.ERR, "Failed accounts service request /user/limits?unit=byte: ", err or ("[HTTP " .. res.status .. "] " .. res.body)) + local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) + ngx.log(ngx.ERR, "Failed accounts service request /user/limits?unit=byte: ", error_response) ngx.var.account_limits = cjson.encode(anon_limits) elseif res and res.status == ngx.HTTP_OK then ngx.var.account_limits = res.body @@ -109,7 +110,7 @@ function _M.has_subscription() end function _M.is_auth_required() - -- authentication is required if mode is set to "authenticated" + -- authentication is required if mode is set to "authenticated" -- or "subscription" (require active subscription to a premium plan) return os.getenv("ACCOUNTS_LIMIT_ACCESS") == "authenticated" or _M.is_subscription_required() end @@ -118,7 +119,7 @@ function _M.is_subscription_required() return os.getenv("ACCOUNTS_LIMIT_ACCESS") == "subscription" end -function is_access_always_allowed() +local is_access_always_allowed = function () -- options requests do not attach cookies - should always be available -- requests should not be limited based on accounts if accounts are not enabled return ngx.req.get_method() == "OPTIONS" or not _M.accounts_enabled() diff --git a/docker/nginx/libs/skynet/skylink.lua b/docker/nginx/libs/skynet/skylink.lua index adcf0b70..86d1c4bc 100644 --- a/docker/nginx/libs/skynet/skylink.lua +++ b/docker/nginx/libs/skynet/skylink.lua @@ -27,7 +27,7 @@ function _M.hash(skylink) -- parse with blake2b with key length of 32 local blake2bHashed = hasher.blake2b(rawMerkleRoot, 32) - + -- hex encode the blake hash local hexHashed = basexx.to_hex(blake2bHashed) diff --git a/docker/nginx/libs/skynet/skylink.spec.lua b/docker/nginx/libs/skynet/skylink.spec.lua index 0502a833..9977d7c8 100644 --- a/docker/nginx/libs/skynet/skylink.spec.lua +++ b/docker/nginx/libs/skynet/skylink.spec.lua @@ -7,7 +7,7 @@ describe("parse", function() it("should return unchanged base64 skylink", function() assert.is.same(skynet_skylink.parse(base64), base64) end) - + it("should transform base32 skylink into base64", function() assert.is.same(skynet_skylink.parse(base32), base64) end) diff --git a/docker/nginx/libs/utils.spec.lua b/docker/nginx/libs/utils.spec.lua index 8dd68e6e..c853c8cd 100644 --- a/docker/nginx/libs/utils.spec.lua +++ b/docker/nginx/libs/utils.spec.lua @@ -15,31 +15,31 @@ describe("extract_cookie", function() it("should return nil if cookie string is nil", function() local cookie = utils.extract_cookie_value(nil, "aaa") - + assert.is_nil(cookie) end) it("should return nil if cookie name is not found", function() local cookie = utils.extract_cookie(cookie_string, "foo") - + assert.is_nil(cookie) end) it("should return cookie if cookie_string starts with that cookie name", function() local cookie = utils.extract_cookie(cookie_string, "aaa") - + assert.are.equals(cookie, "aaa=bbb") end) it("should return cookie if cookie_string ends with that cookie name", function() local cookie = utils.extract_cookie(cookie_string, "xxx") - + assert.are.equals(cookie, "xxx=yyy") end) it("should return cookie with custom matcher", function() local cookie = utils.extract_cookie(cookie_string, "skynet[-]jwt") - + assert.are.equals(cookie, "skynet-jwt=MTY0NzUyr8jD-ytiWtspm0tGabKfooxeIDuWcXhJ3lnY0eEw==") end) end) @@ -49,31 +49,31 @@ describe("extract_cookie_value", function() it("should return nil if cookie string is nil", function() local value = utils.extract_cookie_value(nil, "aaa") - + assert.is_nil(value) end) it("should return nil if cookie name is not found", function() local value = utils.extract_cookie_value(cookie_string, "foo") - + assert.is_nil(value) end) it("should return value if cookie_string starts with that cookie name", function() local value = utils.extract_cookie_value(cookie_string, "aaa") - + assert.are.equals(value, "bbb") end) it("should return cookie if cookie_string ends with that cookie name", function() local value = utils.extract_cookie_value(cookie_string, "xxx") - + assert.are.equals(value, "yyy") end) it("should return cookie with custom matcher", function() local value = utils.extract_cookie_value(cookie_string, "skynet[-]jwt") - + assert.are.equals(value, "MTY0NzUyr8jD-ytiWtspm0tGabKfooxeIDuWcXhJ3lnY0eEw==") end) end) From 34bb7d55d1ac772539edacaa8805d2520f38332c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Mon, 28 Mar 2022 08:07:14 +0200 Subject: [PATCH 047/240] style(dashboard-v2): uncapitalize Skylinks --- .../dashboard-v2/src/components/APIKeyList/APIKey.js | 8 +++++--- .../src/components/forms/AddPublicAPIKeyForm.js | 10 +++++++--- packages/dashboard-v2/src/pages/settings/api-keys.js | 4 ++-- 3 files changed, 14 insertions(+), 8 deletions(-) diff --git a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js index a11d1808..5cb6680a 100644 --- a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js +++ b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js @@ -54,6 +54,8 @@ export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { const skylinksNumber = skylinks?.length ?? 0; const isNotConfigured = isPublic && skylinksNumber === 0; + const skylinksPhrasePrefix = skylinksNumber === 0 ? "No" : skylinksNumber; + const skylinksPhrase = `${skylinksPhrasePrefix} ${skylinksNumber === 1 ? "skylink" : "skylinks"} configured`; return (
  • { "text-palette-400": !isNotConfigured, })} > - {skylinksNumber} {skylinksNumber === 1 ? "Skylink" : "Skylinks"} configured + {skylinksPhrase} @@ -80,7 +82,7 @@ export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { {isPublic && (
  • -
    diff --git a/packages/dashboard-v2/src/pages/settings/api-keys.js b/packages/dashboard-v2/src/pages/settings/api-keys.js index 05b2701c..8b7cf87f 100644 --- a/packages/dashboard-v2/src/pages/settings/api-keys.js +++ b/packages/dashboard-v2/src/pages/settings/api-keys.js @@ -42,7 +42,7 @@ const APIKeysPage = () => {
    Public keys

    - Give read access to a selected list of Skylinks. You can share them publicly. + Public keys provide read access to a selected list of skylinks. You can share them publicly.

    @@ -68,7 +68,7 @@ const APIKeysPage = () => {
    General keys

    - Give full access to Accounts service and are equivalent to using a JWT token. + These keys provide full access to Accounts service and are equivalent to using a JWT token.

    This type of API keys need to be kept secret and never shared with anyone.

    From 07a5b79710601caf2034827efcf6c84a7e48e804 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Mon, 28 Mar 2022 08:29:03 +0200 Subject: [PATCH 048/240] style(dashboard-v2): prettier run --- packages/dashboard-v2/src/pages/settings/api-keys.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/dashboard-v2/src/pages/settings/api-keys.js b/packages/dashboard-v2/src/pages/settings/api-keys.js index 8b7cf87f..05013a92 100644 --- a/packages/dashboard-v2/src/pages/settings/api-keys.js +++ b/packages/dashboard-v2/src/pages/settings/api-keys.js @@ -42,7 +42,7 @@ const APIKeysPage = () => {
    Public keys

    - Public keys provide read access to a selected list of skylinks. You can share them publicly. + Public keys provide read access to a selected list of skylinks. You can share them publicly.

    From 34fbdf9e64ab9b035c4281f3266239888d948337 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Mon, 28 Mar 2022 09:29:26 +0200 Subject: [PATCH 049/240] style(dashboard-v2): wording --- packages/dashboard-v2/src/pages/settings/api-keys.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/dashboard-v2/src/pages/settings/api-keys.js b/packages/dashboard-v2/src/pages/settings/api-keys.js index 05013a92..1f6c93c5 100644 --- a/packages/dashboard-v2/src/pages/settings/api-keys.js +++ b/packages/dashboard-v2/src/pages/settings/api-keys.js @@ -70,7 +70,9 @@ const APIKeysPage = () => {

    These keys provide full access to Accounts service and are equivalent to using a JWT token.

    -

    This type of API keys need to be kept secret and never shared with anyone.

    +

    + This type of API keys needs to be kept secret and should never be shared with anyone. +

    From 1a147e53b39f8e39afdaffbb6aff5dbfca33aba1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:07:12 +0000 Subject: [PATCH 050/240] build(deps-dev): bump prettier in /packages/handshake-api Bumps [prettier](https://github.com/prettier/prettier) from 2.6.0 to 2.6.1. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](https://github.com/prettier/prettier/compare/2.6.0...2.6.1) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/handshake-api/package.json | 2 +- packages/handshake-api/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/handshake-api/package.json b/packages/handshake-api/package.json index ca69fcf8..c102dd9d 100644 --- a/packages/handshake-api/package.json +++ b/packages/handshake-api/package.json @@ -10,6 +10,6 @@ "punycode": "^2.1.1" }, "devDependencies": { - "prettier": "^2.6.0" + "prettier": "^2.6.1" } } diff --git a/packages/handshake-api/yarn.lock b/packages/handshake-api/yarn.lock index 256c2c69..421cde2e 100644 --- a/packages/handshake-api/yarn.lock +++ b/packages/handshake-api/yarn.lock @@ -314,10 +314,10 @@ path-to-regexp@0.1.7: resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-0.1.7.tgz#df604178005f522f15eb4490e7247a1bfaa67f8c" integrity sha1-32BBeABfUi8V60SQ5yR6G/qmf4w= -prettier@^2.6.0: - version "2.6.0" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.0.tgz#12f8f504c4d8ddb76475f441337542fa799207d4" - integrity sha512-m2FgJibYrBGGgQXNzfd0PuDGShJgRavjUoRCw1mZERIWVSXF0iLzLm+aOqTAbLnC3n6JzUhAA8uZnFVghHJ86A== +prettier@^2.6.1: + version "2.6.1" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.1.tgz#d472797e0d7461605c1609808e27b80c0f9cfe17" + integrity sha512-8UVbTBYGwN37Bs9LERmxCPjdvPxlEowx2urIL6urHzdb3SDq4B/Z6xLFCblrSnE4iKWcS6ziJ3aOYrc1kz/E2A== proxy-addr@~2.0.7: version "2.0.7" From 751ca6780fcd11767278167572d3cba881fc2ec7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:07:38 +0000 Subject: [PATCH 051/240] build(deps-dev): bump prettier in /packages/health-check Bumps [prettier](https://github.com/prettier/prettier) from 2.6.0 to 2.6.1. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](https://github.com/prettier/prettier/compare/2.6.0...2.6.1) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/health-check/package.json | 2 +- packages/health-check/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/health-check/package.json b/packages/health-check/package.json index fe12816e..fd512fc8 100644 --- a/packages/health-check/package.json +++ b/packages/health-check/package.json @@ -19,6 +19,6 @@ }, "devDependencies": { "jest": "^27.5.1", - "prettier": "^2.6.0" + "prettier": "^2.6.1" } } diff --git a/packages/health-check/yarn.lock b/packages/health-check/yarn.lock index 28a49b1b..5aae0c3d 100644 --- a/packages/health-check/yarn.lock +++ b/packages/health-check/yarn.lock @@ -2643,10 +2643,10 @@ prelude-ls@~1.1.2: resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" integrity sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ= -prettier@^2.6.0: - version "2.6.0" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.0.tgz#12f8f504c4d8ddb76475f441337542fa799207d4" - integrity sha512-m2FgJibYrBGGgQXNzfd0PuDGShJgRavjUoRCw1mZERIWVSXF0iLzLm+aOqTAbLnC3n6JzUhAA8uZnFVghHJ86A== +prettier@^2.6.1: + version "2.6.1" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.1.tgz#d472797e0d7461605c1609808e27b80c0f9cfe17" + integrity sha512-8UVbTBYGwN37Bs9LERmxCPjdvPxlEowx2urIL6urHzdb3SDq4B/Z6xLFCblrSnE4iKWcS6ziJ3aOYrc1kz/E2A== pretty-format@^27.5.1: version "27.5.1" From 20db75ef990afe742c4983375a194fb75346dd2b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:10:01 +0000 Subject: [PATCH 052/240] build(deps): bump next from 12.1.0 to 12.1.1 in /packages/dashboard Bumps [next](https://github.com/vercel/next.js) from 12.1.0 to 12.1.1. - [Release notes](https://github.com/vercel/next.js/releases) - [Changelog](https://github.com/vercel/next.js/blob/canary/release.js) - [Commits](https://github.com/vercel/next.js/compare/v12.1.0...v12.1.1) --- updated-dependencies: - dependency-name: next dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 144 +++++++++++++++++--------------- 2 files changed, 76 insertions(+), 70 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 6da74280..0008311e 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -20,7 +20,7 @@ "formik": "2.2.9", "http-status-codes": "2.2.0", "ky": "0.30.0", - "next": "12.1.0", + "next": "12.1.1", "normalize.css": "8.0.1", "pretty-bytes": "6.0.0", "react": "17.0.2", diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 6a27a893..602095d4 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -77,10 +77,10 @@ resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz#b520529ec21d8e5945a1851dfd1c32e94e39ff45" integrity sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA== -"@next/env@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/env/-/env-12.1.0.tgz#73713399399b34aa5a01771fb73272b55b22c314" - integrity sha512-nrIgY6t17FQ9xxwH3jj0a6EOiQ/WDHUos35Hghtr+SWN/ntHIQ7UpuvSi0vaLzZVHQWaDupKI+liO5vANcDeTQ== +"@next/env@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/env/-/env-12.1.1.tgz#8a927397697ee9d94852feb5fed57a813d299979" + integrity sha512-VmTRkfo/IXOQCATndjW3OjKb8zmAuB07eDdzO9XvuXZP87SyvnCYw3jrhUuFhOe/FVsKiloafa5LJfToUpvjUQ== "@next/eslint-plugin-next@12.1.0": version "12.1.0" @@ -89,60 +89,65 @@ dependencies: glob "7.1.7" -"@next/swc-android-arm64@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-12.1.0.tgz#865ba3a9afc204ff2bdeea49dd64d58705007a39" - integrity sha512-/280MLdZe0W03stA69iL+v6I+J1ascrQ6FrXBlXGCsGzrfMaGr7fskMa0T5AhQIVQD4nA/46QQWxG//DYuFBcA== +"@next/swc-android-arm-eabi@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-12.1.1.tgz#2b134efb6639a770db10688a93ce0d2a9362fc5e" + integrity sha512-phV9H6d1eK1oVC7nmKKcCXvgOWT4K7aLC/beyO6yvbFC4XtBLE21vPwVl7B4ybz5xjSa6TXoR3TMR6vkW6Mv+A== -"@next/swc-darwin-arm64@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-12.1.0.tgz#08e8b411b8accd095009ed12efbc2f1d4d547135" - integrity sha512-R8vcXE2/iONJ1Unf5Ptqjk6LRW3bggH+8drNkkzH4FLEQkHtELhvcmJwkXcuipyQCsIakldAXhRbZmm3YN1vXg== +"@next/swc-android-arm64@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-12.1.1.tgz#4fc66990c71c066f99fc435c0e8a4b3191bdfb4a" + integrity sha512-X5qEz0YeeYT0Gz2wXPAEtRKEuAsLUIEgC/DDfS98t/5Idjv0S4aqIX+TQdzoXP5bwQkIr+mSg+MBIdLtbtnCsA== -"@next/swc-darwin-x64@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-12.1.0.tgz#fcd684497a76e8feaca88db3c394480ff0b007cd" - integrity sha512-ieAz0/J0PhmbZBB8+EA/JGdhRHBogF8BWaeqR7hwveb6SYEIJaDNQy0I+ZN8gF8hLj63bEDxJAs/cEhdnTq+ug== +"@next/swc-darwin-arm64@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-12.1.1.tgz#a5b4ea73ebf769f48dae97942b6b6fbeaf3f1dfc" + integrity sha512-bKKSNaTdnO3XPnfaR4NSpPcbs80fdbtOYC2lgtqLzA0bOMioupixMP5GrA/gfJHwh7GRH+A+sbgKQWsqSsYAqQ== -"@next/swc-linux-arm-gnueabihf@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-12.1.0.tgz#9ec6380a27938a5799aaa6035c205b3c478468a7" - integrity sha512-njUd9hpl6o6A5d08dC0cKAgXKCzm5fFtgGe6i0eko8IAdtAPbtHxtpre3VeSxdZvuGFh+hb0REySQP9T1ttkog== +"@next/swc-darwin-x64@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-12.1.1.tgz#064d50c08d9eec0fc1ff76e190d4fe43184aa8b7" + integrity sha512-2VOsA6WLDuDBA6935djohWGGeUIKeQhXwDwu1CKx1b8+6YMMIvFr/y2dpPWoct+5/IjFz84a2MnbABwpoNB9YA== -"@next/swc-linux-arm64-gnu@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-12.1.0.tgz#7f4196dff1049cea479607c75b81033ae2dbd093" - integrity sha512-OqangJLkRxVxMhDtcb7Qn1xjzFA3s50EIxY7mljbSCLybU+sByPaWAHY4px97ieOlr2y4S0xdPKkQ3BCAwyo6Q== +"@next/swc-linux-arm-gnueabihf@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-12.1.1.tgz#6cd6edda7f17ad1ceb1cd242419d93a643b1de31" + integrity sha512-1urXtWwqjqbbpJBWeJYz5ATgelKacVNdKIdhfahbsmW+DZGoK5TYovgieyHFYUCyHdTuKeLTVR62ahIRUBv1YA== -"@next/swc-linux-arm64-musl@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-12.1.0.tgz#b445f767569cdc2dddee785ca495e1a88c025566" - integrity sha512-hB8cLSt4GdmOpcwRe2UzI5UWn6HHO/vLkr5OTuNvCJ5xGDwpPXelVkYW/0+C3g5axbDW2Tym4S+MQCkkH9QfWA== +"@next/swc-linux-arm64-gnu@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-12.1.1.tgz#d480c71de4150728c0c67a363c7f17291db3f070" + integrity sha512-CDD9yFuknDvTOzzDnvfmb58USI5Vu6FUyzw96udKj7KA/n1YrNQ4K8X7KsDCRZoqfRWYceAyj1EpwHkfdiB7bg== -"@next/swc-linux-x64-gnu@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-12.1.0.tgz#67610e9be4fbc987de7535f1bcb17e45fe12f90e" - integrity sha512-OKO4R/digvrVuweSw/uBM4nSdyzsBV5EwkUeeG4KVpkIZEe64ZwRpnFB65bC6hGwxIBnTv5NMSnJ+0K/WmG78A== +"@next/swc-linux-arm64-musl@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-12.1.1.tgz#9578705269b746617c763c1ac5c5b26084f1e5ce" + integrity sha512-nxyjgmbOpZm7gGPj9EV5Cqosoujt+ih/8SO2XG+BetgfAk0+c15793DHVAljNuc8GF9wpzqQnjMMUZ211VmQsg== -"@next/swc-linux-x64-musl@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-12.1.0.tgz#ea19a23db08a9f2e34ac30401f774cf7d1669d31" - integrity sha512-JohhgAHZvOD3rQY7tlp7NlmvtvYHBYgY0x5ZCecUT6eCCcl9lv6iV3nfu82ErkxNk1H893fqH0FUpznZ/H3pSw== +"@next/swc-linux-x64-gnu@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-12.1.1.tgz#40f3c79b65b6cfc880e6131a25f7936716ded1b9" + integrity sha512-L8Cu8kH3Vn2dnRpvcvGGA1TlmDP2WXJ+qDwvjb/ikDXLdRdmFvJwHh45JUGiW2FHed3lGseOgNsuYiDvnT8Cdw== -"@next/swc-win32-arm64-msvc@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-12.1.0.tgz#eadf054fc412085659b98e145435bbba200b5283" - integrity sha512-T/3gIE6QEfKIJ4dmJk75v9hhNiYZhQYAoYm4iVo1TgcsuaKLFa+zMPh4056AHiG6n9tn2UQ1CFE8EoybEsqsSw== +"@next/swc-linux-x64-musl@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-12.1.1.tgz#922ea0306d36b5fd860d8cc5a6f4c53dca09395c" + integrity sha512-4RAb7L69MoRSggBqUfF3OrtBCUN2zPDi7asfL7bfxEhH10LGzyfil8dT0GVjPOPFz/SyLx3ORd6avGij2IlJUA== -"@next/swc-win32-ia32-msvc@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-12.1.0.tgz#68faeae10c89f698bf9d28759172b74c9c21bda1" - integrity sha512-iwnKgHJdqhIW19H9PRPM9j55V6RdcOo6rX+5imx832BCWzkDbyomWnlzBfr6ByUYfhohb8QuH4hSGEikpPqI0Q== +"@next/swc-win32-arm64-msvc@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-12.1.1.tgz#be13af4e33c071e6ec97b2cfead51eb57ecf189b" + integrity sha512-zvkuNIgOxkAU3RbzWRGCcFasDxWJdhONt2YeRGe39dJERHhEFA1u4HgaZw/SFE/kfrNRUZbXjJNAg3OU/EpPZw== -"@next/swc-win32-x64-msvc@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-12.1.0.tgz#d27e7e76c87a460a4da99c5bfdb1618dcd6cd064" - integrity sha512-aBvcbMwuanDH4EMrL2TthNJy+4nP59Bimn8egqv6GHMVj0a44cU6Au4PjOhLNqEh9l+IpRGBqMTzec94UdC5xg== +"@next/swc-win32-ia32-msvc@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-12.1.1.tgz#2a5adb993542fc54fedfd525c69593f75c055595" + integrity sha512-GsNDtZ//uKWNVjiwv3YKQYsDXuRWTz8jTmxopf5Ws3dK+zA77hn4o46LBQg0JPCNqTUO6eIOlUBjqSL6ejxmSQ== + +"@next/swc-win32-x64-msvc@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-12.1.1.tgz#21c12feb6acf75cac7c1ae4ca7f251aa1943f081" + integrity sha512-nH5osn/uK9wsjT8Jh1YxMtRrkN5hoCNLQjsEdvfUfb+loQXeYiBd3n/0DUJkf6Scjfv6/htfUTPP3AEa7AbBxQ== "@nodelib/fs.scandir@2.1.5": version "2.1.5" @@ -1681,28 +1686,29 @@ natural-compare@^1.4.0: resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= -next@12.1.0: - version "12.1.0" - resolved "https://registry.yarnpkg.com/next/-/next-12.1.0.tgz#c33d753b644be92fc58e06e5a214f143da61dd5d" - integrity sha512-s885kWvnIlxsUFHq9UGyIyLiuD0G3BUC/xrH0CEnH5lHEWkwQcHOORgbDF0hbrW9vr/7am4ETfX4A7M6DjrE7Q== +next@12.1.1: + version "12.1.1" + resolved "https://registry.yarnpkg.com/next/-/next-12.1.1.tgz#f5e73d3a204da0632484a56040c23a4796958bc6" + integrity sha512-IOfEIAgroMtsoYz6HXpDS+b5WB9WZ+MH266COXGlcpIiYSgUyJf9xV6vF+zY2RPvBJFT4fUW0EVdVnoOmTloDw== dependencies: - "@next/env" "12.1.0" + "@next/env" "12.1.1" caniuse-lite "^1.0.30001283" postcss "8.4.5" - styled-jsx "5.0.0" + styled-jsx "5.0.1" use-subscription "1.5.1" optionalDependencies: - "@next/swc-android-arm64" "12.1.0" - "@next/swc-darwin-arm64" "12.1.0" - "@next/swc-darwin-x64" "12.1.0" - "@next/swc-linux-arm-gnueabihf" "12.1.0" - "@next/swc-linux-arm64-gnu" "12.1.0" - "@next/swc-linux-arm64-musl" "12.1.0" - "@next/swc-linux-x64-gnu" "12.1.0" - "@next/swc-linux-x64-musl" "12.1.0" - "@next/swc-win32-arm64-msvc" "12.1.0" - "@next/swc-win32-ia32-msvc" "12.1.0" - "@next/swc-win32-x64-msvc" "12.1.0" + "@next/swc-android-arm-eabi" "12.1.1" + "@next/swc-android-arm64" "12.1.1" + "@next/swc-darwin-arm64" "12.1.1" + "@next/swc-darwin-x64" "12.1.1" + "@next/swc-linux-arm-gnueabihf" "12.1.1" + "@next/swc-linux-arm64-gnu" "12.1.1" + "@next/swc-linux-arm64-musl" "12.1.1" + "@next/swc-linux-x64-gnu" "12.1.1" + "@next/swc-linux-x64-musl" "12.1.1" + "@next/swc-win32-arm64-msvc" "12.1.1" + "@next/swc-win32-ia32-msvc" "12.1.1" + "@next/swc-win32-x64-msvc" "12.1.1" node-releases@^2.0.2: version "2.0.2" @@ -2258,10 +2264,10 @@ stripe@8.210.0: "@types/node" ">=8.1.0" qs "^6.6.0" -styled-jsx@5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/styled-jsx/-/styled-jsx-5.0.0.tgz#816b4b92e07b1786c6b7111821750e0ba4d26e77" - integrity sha512-qUqsWoBquEdERe10EW8vLp3jT25s/ssG1/qX5gZ4wu15OZpmSMFI2v+fWlRhLfykA5rFtlJ1ME8A8pm/peV4WA== +styled-jsx@5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/styled-jsx/-/styled-jsx-5.0.1.tgz#78fecbbad2bf95ce6cd981a08918ce4696f5fc80" + integrity sha512-+PIZ/6Uk40mphiQJJI1202b+/dYeTVd9ZnMPR80pgiWbjIwvN2zIp4r9et0BgqBuShh48I0gttPlAXA7WVvBxw== supports-color@^5.3.0: version "5.5.0" From ca11f148cb1b239a9be7ddc383e8cccfcf34ba16 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:10:08 +0000 Subject: [PATCH 053/240] build(deps-dev): bump prettier in /packages/dnslink-api Bumps [prettier](https://github.com/prettier/prettier) from 2.6.0 to 2.6.1. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](https://github.com/prettier/prettier/compare/2.6.0...2.6.1) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dnslink-api/package.json | 2 +- packages/dnslink-api/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dnslink-api/package.json b/packages/dnslink-api/package.json index ab02b904..4b913067 100644 --- a/packages/dnslink-api/package.json +++ b/packages/dnslink-api/package.json @@ -8,6 +8,6 @@ "is-valid-domain": "^0.1.6" }, "devDependencies": { - "prettier": "^2.6.0" + "prettier": "^2.6.1" } } diff --git a/packages/dnslink-api/yarn.lock b/packages/dnslink-api/yarn.lock index 00d942fe..56631f9e 100644 --- a/packages/dnslink-api/yarn.lock +++ b/packages/dnslink-api/yarn.lock @@ -265,10 +265,10 @@ path-to-regexp@0.1.7: resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-0.1.7.tgz#df604178005f522f15eb4490e7247a1bfaa67f8c" integrity sha1-32BBeABfUi8V60SQ5yR6G/qmf4w= -prettier@^2.6.0: - version "2.6.0" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.0.tgz#12f8f504c4d8ddb76475f441337542fa799207d4" - integrity sha512-m2FgJibYrBGGgQXNzfd0PuDGShJgRavjUoRCw1mZERIWVSXF0iLzLm+aOqTAbLnC3n6JzUhAA8uZnFVghHJ86A== +prettier@^2.6.1: + version "2.6.1" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.1.tgz#d472797e0d7461605c1609808e27b80c0f9cfe17" + integrity sha512-8UVbTBYGwN37Bs9LERmxCPjdvPxlEowx2urIL6urHzdb3SDq4B/Z6xLFCblrSnE4iKWcS6ziJ3aOYrc1kz/E2A== proxy-addr@~2.0.7: version "2.0.7" From 302a36035d0605a2bb67b90ae11d814c38b15aa5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:10:12 +0000 Subject: [PATCH 054/240] build(deps): bump stripe from 8.210.0 to 8.212.0 in /packages/dashboard Bumps [stripe](https://github.com/stripe/stripe-node) from 8.210.0 to 8.212.0. - [Release notes](https://github.com/stripe/stripe-node/releases) - [Changelog](https://github.com/stripe/stripe-node/blob/master/CHANGELOG.md) - [Commits](https://github.com/stripe/stripe-node/compare/v8.210.0...v8.212.0) --- updated-dependencies: - dependency-name: stripe dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 6da74280..e46c21ea 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -27,7 +27,7 @@ "react-dom": "17.0.2", "react-toastify": "8.2.0", "skynet-js": "3.0.2", - "stripe": "8.210.0", + "stripe": "8.212.0", "swr": "1.2.2", "yup": "0.32.11" }, diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 6a27a893..3fc05e3f 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -2250,10 +2250,10 @@ strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== -stripe@8.210.0: - version "8.210.0" - resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.210.0.tgz#6e5ede9abd36406d39b89d9129df86fb33f43db3" - integrity sha512-NDQNEInrr1avwSEDB7Phe7PYNejtU9EkhOBlPa90Aomc3WvSXgOuX8MpswQ1mTw+W/lGpePwVqMsUvrvhUjZfA== +stripe@8.212.0: + version "8.212.0" + resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.212.0.tgz#78dc8d2be770580be23a8e597641a9ace6fd1035" + integrity sha512-xQ2uPMRAmRyOiMZktw3hY8jZ8LFR9lEQRPEaQ5WcDcn51kMyn46GeikOikxiFTHEN8PeKRdwtpz4yNArAvu/Kg== dependencies: "@types/node" ">=8.1.0" qs "^6.6.0" From 12e71406a2946c942f235ac4321167f3011c5978 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:10:20 +0000 Subject: [PATCH 055/240] build(deps-dev): bump eslint in /packages/dashboard Bumps [eslint](https://github.com/eslint/eslint) from 8.11.0 to 8.12.0. - [Release notes](https://github.com/eslint/eslint/releases) - [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md) - [Commits](https://github.com/eslint/eslint/compare/v8.11.0...v8.12.0) --- updated-dependencies: - dependency-name: eslint dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 6da74280..73f85b1b 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -35,7 +35,7 @@ "@tailwindcss/forms": "0.5.0", "@tailwindcss/typography": "0.5.2", "autoprefixer": "10.4.4", - "eslint": "8.11.0", + "eslint": "8.12.0", "eslint-config-next": "12.1.0", "postcss": "8.4.12", "prettier": "2.6.0", diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 6a27a893..06c0963f 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -911,10 +911,10 @@ eslint-visitor-keys@^3.0.0, eslint-visitor-keys@^3.3.0: resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.3.0.tgz#f6480fa6b1f30efe2d1968aa8ac745b862469826" integrity sha512-mQ+suqKJVyeuwGYHAdjMFqjCyfl8+Ldnxuyp3ldiMBFKkvytrXUZWaiPCEav8qDHKty44bD+qV1IP4T+w+xXRA== -eslint@8.11.0: - version "8.11.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.11.0.tgz#88b91cfba1356fc10bb9eb592958457dfe09fb37" - integrity sha512-/KRpd9mIRg2raGxHRGwW9ZywYNAClZrHjdueHcrVDuO3a6bj83eoTirCCk0M0yPwOjWYKHwRVRid+xK4F/GHgA== +eslint@8.12.0: + version "8.12.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.12.0.tgz#c7a5bd1cfa09079aae64c9076c07eada66a46e8e" + integrity sha512-it1oBL9alZg1S8UycLm5YDMAkIhtH6FtAzuZs6YvoGVldWjbS08BkAdb/ymP9LlAyq8koANu32U7Ib/w+UNh8Q== dependencies: "@eslint/eslintrc" "^1.2.1" "@humanwhocodes/config-array" "^0.9.2" From 012a434d9f69f288ff7a62cc8099d7fcf4ee9474 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:10:27 +0000 Subject: [PATCH 056/240] build(deps): bump gatsby-plugin-sharp in /packages/website Bumps [gatsby-plugin-sharp](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-sharp) from 4.10.1 to 4.10.2. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-sharp/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-sharp@4.10.2/packages/gatsby-plugin-sharp) --- updated-dependencies: - dependency-name: gatsby-plugin-sharp dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 42 +++++++++++++++++------------------ 2 files changed, 22 insertions(+), 22 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 76737420..7c715c30 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -20,7 +20,7 @@ "gatsby-plugin-postcss": "5.10.0", "gatsby-plugin-react-helmet": "5.10.0", "gatsby-plugin-robots-txt": "1.7.0", - "gatsby-plugin-sharp": "4.10.1", + "gatsby-plugin-sharp": "4.10.2", "gatsby-plugin-sitemap": "5.10.1", "gatsby-plugin-svgr": "3.0.0-beta.0", "gatsby-source-filesystem": "4.10.0", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 255e5afb..9721fd54 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6223,10 +6223,10 @@ gatsby-cli@^4.10.1: yoga-layout-prebuilt "^1.10.0" yurnalist "^2.1.0" -gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.8.2: - version "3.10.0" - resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.10.0.tgz#52be8a9a891d95686a7ee0c1cfef44f8e362232b" - integrity sha512-yaRI/uUsbIggPRfh0y6CH+fy2AqbFFLxCYndw5nrVByEY40+KaKs0wOF4yIgPRBZZUHOyfBJ+1AGo2JLHdY5lA== +gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.8.2: + version "3.10.1" + resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.10.1.tgz#0f5e6aeda5ef4b86218b27480a9766fe30af4393" + integrity sha512-WqNMm0u1CAZm6Q+UQ4dDHwIAt3l32NeIaPuSXmDX7QcMGR3FUUk8cl2Ym6gx1hfILm1aCexqfaSCLUXtaWKkbQ== dependencies: "@babel/runtime" "^7.15.4" ci-info "2.0.0" @@ -6376,10 +6376,10 @@ gatsby-plugin-robots-txt@1.7.0: "@babel/runtime" "^7.16.7" generate-robotstxt "^8.0.3" -gatsby-plugin-sharp@4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-sharp/-/gatsby-plugin-sharp-4.10.1.tgz#d72145f7649b71a1e5051dcf7ed8f4d1f72bb041" - integrity sha512-Y+kB5BSfcxMYO5s13W3NDeDH28RCzSa8goo1yQNTISiGaC6iBO4EIEVbUiUBkoLA5nf46J71ve8A3sprZ66bog== +gatsby-plugin-sharp@4.10.2: + version "4.10.2" + resolved "https://registry.yarnpkg.com/gatsby-plugin-sharp/-/gatsby-plugin-sharp-4.10.2.tgz#253a49c452a7409ceece4e541e4770e61a306bcc" + integrity sha512-MWzPTYnu7HZ0kctHtkLbZOe6ZGUqSsNATO3lWlSBIFpeimxaPF5iHBiu1CX/ofz4pwt7VamtIzAV28VB6sjONw== dependencies: "@babel/runtime" "^7.15.4" async "^3.2.3" @@ -6387,9 +6387,9 @@ gatsby-plugin-sharp@4.10.1: debug "^4.3.3" filenamify "^4.3.0" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" - gatsby-plugin-utils "^3.4.1" - gatsby-telemetry "^3.10.0" + gatsby-core-utils "^3.10.1" + gatsby-plugin-utils "^3.4.2" + gatsby-telemetry "^3.10.1" got "^11.8.3" lodash "^4.17.21" mini-svg-data-uri "^1.4.3" @@ -6429,14 +6429,14 @@ gatsby-plugin-typescript@^4.10.0: "@babel/runtime" "^7.15.4" babel-plugin-remove-graphql-queries "^4.10.0" -gatsby-plugin-utils@^3.4.1: - version "3.4.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.4.1.tgz#14c9cff75af32a32860575069af44bdabc8f65d9" - integrity sha512-sDMVGauxMgXyX8WGZDndZI2vIaolJzlXBMdKhgP7DIT+Qa5wjvyHWvZy34dxtVrT3IHPK/PRMgpE81Gr7gKveg== +gatsby-plugin-utils@^3.4.1, gatsby-plugin-utils@^3.4.2: + version "3.4.2" + resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.4.2.tgz#bdc66fd52c052c91af443981e1facbc097429dc7" + integrity sha512-HkVR8BnEdc915pmY2L9wPwFgjq303ThMH9UtT+frDOPzn+GFjPlBF5+YGJ3tZaxH0ouwpnGTn3Pu37tcRZcctA== dependencies: "@babel/runtime" "^7.15.4" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" gatsby-sharp "^0.4.0" graphql-compose "^9.0.7" import-from "^4.0.0" @@ -6477,10 +6477,10 @@ gatsby-source-filesystem@4.10.0: valid-url "^1.0.9" xstate "^4.26.1" -gatsby-telemetry@^3.10.0: - version "3.10.0" - resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.0.tgz#917a4914e531d401ecf98ac87d29128b30bfab13" - integrity sha512-Oe2OShJbylKr5C4FTl2P/JUX/xRkpYb6IMfEoAd5inG7HNQ1fikON4NdwvJjOp++My4kWo+LLCu92TZBkyTtZw== +gatsby-telemetry@^3.10.0, gatsby-telemetry@^3.10.1: + version "3.10.1" + resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.1.tgz#129c4309811cd9b2ba5e9d326ba47dddb59202ca" + integrity sha512-935quI1YsQfzYREuvPLNKBb7IUE2vX9p7WoS7Dc9TbV2xDZPTAzeOfX+HE56ZltkxMi8Zivp7mqe5+n//WL7EQ== dependencies: "@babel/code-frame" "^7.14.0" "@babel/runtime" "^7.15.4" @@ -6490,7 +6490,7 @@ gatsby-telemetry@^3.10.0: boxen "^4.2.0" configstore "^5.0.1" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" git-up "^4.0.5" is-docker "^2.2.1" lodash "^4.17.21" From 7f3800a7da1399e4472880c5a7d6ea62fc22313e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:10:30 +0000 Subject: [PATCH 057/240] build(deps): bump @fontsource/source-sans-pro in /packages/dashboard Bumps [@fontsource/source-sans-pro](https://github.com/fontsource/fontsource/tree/HEAD/fonts/google/source-sans-pro) from 4.5.4 to 4.5.6. - [Release notes](https://github.com/fontsource/fontsource/releases) - [Changelog](https://github.com/fontsource/fontsource/blob/main/CHANGELOG.md) - [Commits](https://github.com/fontsource/fontsource/commits/HEAD/fonts/google/source-sans-pro) --- updated-dependencies: - dependency-name: "@fontsource/source-sans-pro" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 6da74280..d94a3f39 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -9,7 +9,7 @@ }, "dependencies": { "@fontsource/sora": "4.5.3", - "@fontsource/source-sans-pro": "4.5.4", + "@fontsource/source-sans-pro": "4.5.6", "@stripe/react-stripe-js": "1.7.0", "@stripe/stripe-js": "1.25.0", "classnames": "2.3.1", diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 6a27a893..eed02fee 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -58,10 +58,10 @@ resolved "https://registry.yarnpkg.com/@fontsource/sora/-/sora-4.5.3.tgz#987c9b43acb00c9e3fa5377ebcedfd4ec9b760a7" integrity sha512-0ipYkroLonvChAyLajgIt6mImXMhvjrHwD5g7iX2ZR1eJ4hLDnwq6haW5pSeehe79lPjgp0BX6ZHivFIP0xR2g== -"@fontsource/source-sans-pro@4.5.4": - version "4.5.4" - resolved "https://registry.yarnpkg.com/@fontsource/source-sans-pro/-/source-sans-pro-4.5.4.tgz#51510723ff40f446c7800f133e9ae604ae2f38d7" - integrity sha512-+YYw6HRvH9wYE+U2Hvxyossg+MHPApAj7VIjEqaXenNeNQa4U3uPD0e7pc+1Gic3srCQATN15O3S9WSFLXTmwQ== +"@fontsource/source-sans-pro@4.5.6": + version "4.5.6" + resolved "https://registry.yarnpkg.com/@fontsource/source-sans-pro/-/source-sans-pro-4.5.6.tgz#1c74aa0168f0ad851e7c69a5ff25914c7691b6cb" + integrity sha512-MPv0Ye2OmcRD4wQ/7lOkysQpXpWkDSqZ2QHdNNLj7CQVtG03BScLMYQXZbYNhNMbH518tdMFewqDSu+/ikAMTg== "@humanwhocodes/config-array@^0.9.2": version "0.9.2" From 2056d8104ad820e2eb5b86c29d6b8c6c09b429b4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:11:33 +0000 Subject: [PATCH 058/240] build(deps): bump gatsby-plugin-image in /packages/website Bumps [gatsby-plugin-image](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-image) from 2.10.0 to 2.10.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-image/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-image@2.10.1/packages/gatsby-plugin-image) --- updated-dependencies: - dependency-name: gatsby-plugin-image dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 30 +++++++++++++++--------------- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 76737420..e5879934 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -15,7 +15,7 @@ "framer-motion": "6.2.8", "gatsby": "4.10.1", "gatsby-background-image": "1.6.0", - "gatsby-plugin-image": "2.10.0", + "gatsby-plugin-image": "2.10.1", "gatsby-plugin-manifest": "4.10.1", "gatsby-plugin-postcss": "5.10.0", "gatsby-plugin-react-helmet": "5.10.0", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 255e5afb..bf2ee321 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -3339,13 +3339,13 @@ babel-plugin-polyfill-regenerator@^0.3.0: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" -babel-plugin-remove-graphql-queries@^4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.0.tgz#882ec7e75627ffd844e5c4c6d7ae50afe87bc415" - integrity sha512-vANJvjh03qC7o6O3huCKO+Jtmee9WPUJm4Nm+qn/ww+GOOQwz0Z0bSMeBhUkJbT/Y1b1JlysHoxTO3ZNH47EwA== +babel-plugin-remove-graphql-queries@^4.10.0, babel-plugin-remove-graphql-queries@^4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.1.tgz#09357b7afad1d1bf359d97701ba267bf968197f4" + integrity sha512-1Irx5lUoQtU56u1hMtrgipjlRsUF4Pz6WDCDNVyTuvcHqlKHQK6pna4igHrdoWhSSgEcbimlxSy6tTvP6bkplg== dependencies: "@babel/runtime" "^7.15.4" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" babel-plugin-transform-react-remove-prop-types@^0.4.24: version "0.4.24" @@ -6223,10 +6223,10 @@ gatsby-cli@^4.10.1: yoga-layout-prebuilt "^1.10.0" yurnalist "^2.1.0" -gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.8.2: - version "3.10.0" - resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.10.0.tgz#52be8a9a891d95686a7ee0c1cfef44f8e362232b" - integrity sha512-yaRI/uUsbIggPRfh0y6CH+fy2AqbFFLxCYndw5nrVByEY40+KaKs0wOF4yIgPRBZZUHOyfBJ+1AGo2JLHdY5lA== +gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.8.2: + version "3.10.1" + resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.10.1.tgz#0f5e6aeda5ef4b86218b27480a9766fe30af4393" + integrity sha512-WqNMm0u1CAZm6Q+UQ4dDHwIAt3l32NeIaPuSXmDX7QcMGR3FUUk8cl2Ym6gx1hfILm1aCexqfaSCLUXtaWKkbQ== dependencies: "@babel/runtime" "^7.15.4" ci-info "2.0.0" @@ -6306,22 +6306,22 @@ gatsby-parcel-config@^0.1.0: "@parcel/transformer-raw" "^2.3.1" "@parcel/transformer-react-refresh-wrap" "^2.3.1" -gatsby-plugin-image@2.10.0: - version "2.10.0" - resolved "https://registry.yarnpkg.com/gatsby-plugin-image/-/gatsby-plugin-image-2.10.0.tgz#8b4bb0bb2113ab5fa542e52e83f75228ff577703" - integrity sha512-W6/RvRs27XG5TwxTEAhnY68g0LAqP6T2NDPPEzAe/V/x5PyPn5Zf/N1pPUoqqdJ2n48Wg2BSv3Asz5/4vHfRgw== +gatsby-plugin-image@2.10.1: + version "2.10.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-image/-/gatsby-plugin-image-2.10.1.tgz#7b9eda7334487dd0e4693996cf3664835e9c356e" + integrity sha512-ZFcaKkVz6h18jRzP9HHCcXzyIc/Gj57NZSycOWFxW9KLqkq3NZXVx3mkV9EQ+rup8r3RLiJu/AXEorZEy7iAhQ== dependencies: "@babel/code-frame" "^7.14.0" "@babel/parser" "^7.15.5" "@babel/runtime" "^7.15.4" "@babel/traverse" "^7.15.4" babel-jsx-utils "^1.1.0" - babel-plugin-remove-graphql-queries "^4.10.0" + babel-plugin-remove-graphql-queries "^4.10.1" camelcase "^5.3.1" chokidar "^3.5.2" common-tags "^1.8.2" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" objectFitPolyfill "^2.3.5" prop-types "^15.7.2" From 4b08040c341962388b9d1c8cd662132174d9edda Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:11:48 +0000 Subject: [PATCH 059/240] build(deps): bump @fontsource/sora in /packages/website Bumps [@fontsource/sora](https://github.com/fontsource/fontsource/tree/HEAD/fonts/google/sora) from 4.5.3 to 4.5.5. - [Release notes](https://github.com/fontsource/fontsource/releases) - [Changelog](https://github.com/fontsource/fontsource/blob/main/CHANGELOG.md) - [Commits](https://github.com/fontsource/fontsource/commits/HEAD/fonts/google/sora) --- updated-dependencies: - dependency-name: "@fontsource/sora" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 76737420..0b5369a9 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -5,7 +5,7 @@ "version": "0.1.0", "author": "Skynet Labs.", "dependencies": { - "@fontsource/sora": "4.5.3", + "@fontsource/sora": "4.5.5", "@fontsource/source-sans-pro": "4.5.4", "@svgr/webpack": "6.2.1", "bytes": "3.1.2", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 255e5afb..b10f7f99 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -1098,10 +1098,10 @@ minimatch "^3.0.4" strip-json-comments "^3.1.1" -"@fontsource/sora@4.5.3": - version "4.5.3" - resolved "https://registry.yarnpkg.com/@fontsource/sora/-/sora-4.5.3.tgz#987c9b43acb00c9e3fa5377ebcedfd4ec9b760a7" - integrity sha512-0ipYkroLonvChAyLajgIt6mImXMhvjrHwD5g7iX2ZR1eJ4hLDnwq6haW5pSeehe79lPjgp0BX6ZHivFIP0xR2g== +"@fontsource/sora@4.5.5": + version "4.5.5" + resolved "https://registry.yarnpkg.com/@fontsource/sora/-/sora-4.5.5.tgz#25e8e0a11d0a2a861ccce23a94383448c5beaa50" + integrity sha512-SeePOM5pvXaa2a1c9VuGPJGmHNcFSUBzVxfHMuQ/FrVeiXvF3XXyPbt68N6QmHK2rAH844BN1Y5zImxqa5ok6g== "@fontsource/source-sans-pro@4.5.4": version "4.5.4" From 660cbe751b2c0b34ef7cc197c97cfda87d86a486 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:13:03 +0000 Subject: [PATCH 060/240] build(deps): bump gatsby from 4.10.1 to 4.10.3 in /packages/website Bumps [gatsby](https://github.com/gatsbyjs/gatsby) from 4.10.1 to 4.10.3. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/compare/gatsby@4.10.1...gatsby@4.10.3) --- updated-dependencies: - dependency-name: gatsby dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 210 ++++++++++++++-------------------- 2 files changed, 86 insertions(+), 126 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 76737420..49404dc9 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -13,7 +13,7 @@ "copy-text-to-clipboard": "3.0.1", "crypto-browserify": "3.12.0", "framer-motion": "6.2.8", - "gatsby": "4.10.1", + "gatsby": "4.10.3", "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.10.0", "gatsby-plugin-manifest": "4.10.1", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 255e5afb..f2876a56 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -2436,7 +2436,7 @@ resolved "https://registry.yarnpkg.com/@types/get-port/-/get-port-3.2.0.tgz#f9e0a11443cc21336470185eae3dfba4495d29bc" integrity sha512-TiNg8R1kjDde5Pub9F9vCwZA/BNW9HeXP5b9j7Qucqncy/McfPZ6xze/EyBdXS5FhMIGN6Fx3vg75l5KHy3V1Q== -"@types/glob@*", "@types/glob@^7.1.1": +"@types/glob@*": version "7.2.0" resolved "https://registry.yarnpkg.com/@types/glob/-/glob-7.2.0.tgz#bc1b5bf3aa92f25bd5dd39f35c57361bdce5b2eb" integrity sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA== @@ -3339,23 +3339,23 @@ babel-plugin-polyfill-regenerator@^0.3.0: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" -babel-plugin-remove-graphql-queries@^4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.0.tgz#882ec7e75627ffd844e5c4c6d7ae50afe87bc415" - integrity sha512-vANJvjh03qC7o6O3huCKO+Jtmee9WPUJm4Nm+qn/ww+GOOQwz0Z0bSMeBhUkJbT/Y1b1JlysHoxTO3ZNH47EwA== +babel-plugin-remove-graphql-queries@^4.10.0, babel-plugin-remove-graphql-queries@^4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.1.tgz#09357b7afad1d1bf359d97701ba267bf968197f4" + integrity sha512-1Irx5lUoQtU56u1hMtrgipjlRsUF4Pz6WDCDNVyTuvcHqlKHQK6pna4igHrdoWhSSgEcbimlxSy6tTvP6bkplg== dependencies: "@babel/runtime" "^7.15.4" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" babel-plugin-transform-react-remove-prop-types@^0.4.24: version "0.4.24" resolved "https://registry.yarnpkg.com/babel-plugin-transform-react-remove-prop-types/-/babel-plugin-transform-react-remove-prop-types-0.4.24.tgz#f2edaf9b4c6a5fbe5c1d678bfb531078c1555f3a" integrity sha512-eqj0hVcJUR57/Ug2zE1Yswsw4LhuqqHhD+8v120T1cl3kjg76QwtyBrdIk4WVwK+lAhBJVYCd/v+4nc4y+8JsA== -babel-preset-gatsby@^2.10.0: - version "2.10.0" - resolved "https://registry.yarnpkg.com/babel-preset-gatsby/-/babel-preset-gatsby-2.10.0.tgz#83695f47dfbb5e6ea2ce2b504f1e8716d39a5535" - integrity sha512-rh8vXjNXzX8Hkt27R7L56EovUf1dZDQavaYiY8zMQno/0iK7XllgO18Cfkgg3yYro0u1jOBWpoderMmZBLaVgw== +babel-preset-gatsby@^2.10.1: + version "2.10.1" + resolved "https://registry.yarnpkg.com/babel-preset-gatsby/-/babel-preset-gatsby-2.10.1.tgz#a31fe2f4b4ed64204baca5ea8267639a00dd1a6b" + integrity sha512-wuEP2Tsf7MnblXIqJDdg+DOUXZhWQHBQYH/6cQ+HdEFiXu0gwskj/s5sPI6KoBgGK23EIZGr94HBtCq0D3aNRQ== dependencies: "@babel/plugin-proposal-class-properties" "^7.14.0" "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" @@ -3370,7 +3370,7 @@ babel-preset-gatsby@^2.10.0: babel-plugin-dynamic-import-node "^2.3.3" babel-plugin-macros "^2.8.0" babel-plugin-transform-react-remove-prop-types "^0.4.24" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" gatsby-legacy-polyfills "^2.10.0" backo2@^1.0.2, backo2@~1.0.2: @@ -4340,10 +4340,10 @@ create-ecdh@^4.0.0: bn.js "^4.1.0" elliptic "^6.5.3" -create-gatsby@^2.10.1: - version "2.10.1" - resolved "https://registry.yarnpkg.com/create-gatsby/-/create-gatsby-2.10.1.tgz#7172877693efe02bebf7bd8c15a4072e83dfb916" - integrity sha512-zkAtC6TLr6nNmZd2yKqnXuEMX2vX9ciu4VBtMY+4J/nQ/cV77xCAmoU9MCAjVDoLp2h8pNckYE1lneFxmhIgkQ== +create-gatsby@^2.10.2: + version "2.10.2" + resolved "https://registry.yarnpkg.com/create-gatsby/-/create-gatsby-2.10.2.tgz#ded9eb4066078845529a02bc966ef414a77b814a" + integrity sha512-OmuFey3Eoaek20m8Br/iIqEr76AUrl/ThCn7TBYJ6RvWVKezKV5UksQlFpdQgPK8kO9LogjkmiyA0k94VC3nXg== dependencies: "@babel/runtime" "^7.15.4" @@ -4808,20 +4808,6 @@ defined@^1.0.0: resolved "https://registry.yarnpkg.com/defined/-/defined-1.0.0.tgz#c98d9bcef75674188e110969151199e39b1fa693" integrity sha1-yY2bzvdWdBiOEQlpFRGZ45sfppM= -del@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/del/-/del-5.1.0.tgz#d9487c94e367410e6eff2925ee58c0c84a75b3a7" - integrity sha512-wH9xOVHnczo9jN2IW68BabcecVPxacIA3g/7z6vhSU/4stOKQzeCRK0yD0A24WiAAUJmmVpWqrERcTxnLo3AnA== - dependencies: - globby "^10.0.1" - graceful-fs "^4.2.2" - is-glob "^4.0.1" - is-path-cwd "^2.2.0" - is-path-inside "^3.0.1" - p-map "^3.0.0" - rimraf "^3.0.0" - slash "^3.0.0" - delayed-stream@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" @@ -5807,7 +5793,7 @@ fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== -fast-glob@^3.0.3, fast-glob@^3.1.1, fast-glob@^3.2.11, fast-glob@^3.2.9: +fast-glob@^3.1.1, fast-glob@^3.2.11, fast-glob@^3.2.9: version "3.2.11" resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.2.11.tgz#a1172ad95ceb8a16e20caa5c5e56480e5129c1d9" integrity sha512-xrO3+1bxSo3ZVHAnqzyuewYT6aMFHRAd4Kcs92MAonjwQZLsK9d0SF1IyQ3k5PoirxTW0Oe/RqFgMQ6TcNE5Ew== @@ -6172,10 +6158,10 @@ gatsby-background-image@1.6.0: short-uuid "^4.2.0" sort-media-queries "^0.2.2" -gatsby-cli@^4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby-cli/-/gatsby-cli-4.10.1.tgz#0c077a7c14de4a95a70edd32916a94580ff3dbda" - integrity sha512-bv1xJEAcv4vT3DKdOqT1W8qe4L0Yvw5sZoSXDSKX9K9YSGu/CnBJXPa31rNrv357mc4CyAf/Vdfnzvr0tNN+iQ== +gatsby-cli@^4.10.2: + version "4.10.2" + resolved "https://registry.yarnpkg.com/gatsby-cli/-/gatsby-cli-4.10.2.tgz#835a2c472d5cd1b9258e5208f7f7184e5fd1b97b" + integrity sha512-lA1zFuWZwE+VtKYgntls0EC5PG4QoqqeJFWP+83Lmh+9hoLLkmL1plALBQeI3JY/9KXgRiC4OoR94CQkI329TA== dependencies: "@babel/code-frame" "^7.14.0" "@babel/core" "^7.15.5" @@ -6193,13 +6179,13 @@ gatsby-cli@^4.10.1: common-tags "^1.8.2" configstore "^5.0.1" convert-hrtime "^3.0.0" - create-gatsby "^2.10.1" + create-gatsby "^2.10.2" envinfo "^7.8.1" execa "^5.1.1" fs-exists-cached "^1.0.0" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" - gatsby-telemetry "^3.10.0" + gatsby-core-utils "^3.10.1" + gatsby-telemetry "^3.10.1" hosted-git-info "^3.0.8" is-valid-path "^0.1.1" joi "^17.4.2" @@ -6223,10 +6209,10 @@ gatsby-cli@^4.10.1: yoga-layout-prebuilt "^1.10.0" yurnalist "^2.1.0" -gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.8.2: - version "3.10.0" - resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.10.0.tgz#52be8a9a891d95686a7ee0c1cfef44f8e362232b" - integrity sha512-yaRI/uUsbIggPRfh0y6CH+fy2AqbFFLxCYndw5nrVByEY40+KaKs0wOF4yIgPRBZZUHOyfBJ+1AGo2JLHdY5lA== +gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.8.2: + version "3.10.1" + resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.10.1.tgz#0f5e6aeda5ef4b86218b27480a9766fe30af4393" + integrity sha512-WqNMm0u1CAZm6Q+UQ4dDHwIAt3l32NeIaPuSXmDX7QcMGR3FUUk8cl2Ym6gx1hfILm1aCexqfaSCLUXtaWKkbQ== dependencies: "@babel/runtime" "^7.15.4" ci-info "2.0.0" @@ -6259,26 +6245,26 @@ gatsby-legacy-polyfills@^2.10.0: "@babel/runtime" "^7.15.4" core-js-compat "3.9.0" -gatsby-link@^4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/gatsby-link/-/gatsby-link-4.10.0.tgz#11565eca6df53e7952c44bc290791bb032fa88ce" - integrity sha512-icF3i58MWgk4hSLaI6s5xyUp/rPy6MK7F4hsETQgJR32aZzkhj5Ydd1Cqw5P0CYo8EdaYKtljFBVwai8TnY4MQ== +gatsby-link@^4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/gatsby-link/-/gatsby-link-4.10.1.tgz#f68b04b900c9c81070913d65a6e4051a2266dc1b" + integrity sha512-U9Qry93Q+aXF9acs1YPH+wzipPlZELUa619CAhZnLv2sk75Iq5SttMZI/d0uhgF+X80PvoEKMkLb/VE4YiqVtw== dependencies: "@babel/runtime" "^7.15.4" "@types/reach__router" "^1.3.10" - gatsby-page-utils "^2.10.0" + gatsby-page-utils "^2.10.1" prop-types "^15.7.2" -gatsby-page-utils@^2.10.0: - version "2.10.0" - resolved "https://registry.yarnpkg.com/gatsby-page-utils/-/gatsby-page-utils-2.10.0.tgz#8d7729714ca2c5b416ed527eeaa59f5737d20888" - integrity sha512-xyWHrMAJCd/w4mCZ1anK4ADT7pKdVZgQhppBWkm9H604p7RqsoloaQ9XGbPUuypzyPQw78yV5oY6bsaDpbvtrg== +gatsby-page-utils@^2.10.1: + version "2.10.1" + resolved "https://registry.yarnpkg.com/gatsby-page-utils/-/gatsby-page-utils-2.10.1.tgz#39420dd41508ca2793f0c838816b16fd10bbc8d7" + integrity sha512-juhN7/cLKoFGPW37xBCN78D02yO1htxR3raO/f2iseCCsyDjXRnqGHgpdFu8g8s8bkukL5vscgALcyChQf7NtA== dependencies: "@babel/runtime" "^7.15.4" bluebird "^3.7.2" chokidar "^3.5.2" fs-exists-cached "^1.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" glob "^7.2.0" lodash "^4.17.21" micromatch "^4.0.4" @@ -6336,20 +6322,20 @@ gatsby-plugin-manifest@4.10.1: semver "^7.3.5" sharp "^0.30.1" -gatsby-plugin-page-creator@^4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-page-creator/-/gatsby-plugin-page-creator-4.10.1.tgz#6c5308daba53729225578ca67e52f117088502a5" - integrity sha512-tTN4qHH2n7CiV/MNx/FcnBBOmCWzlMkpIR6AtJfxdO5sncn3XIEwMKNxvp9WUm2bevUodlynxlER1dOtgj+DJA== +gatsby-plugin-page-creator@^4.10.2: + version "4.10.2" + resolved "https://registry.yarnpkg.com/gatsby-plugin-page-creator/-/gatsby-plugin-page-creator-4.10.2.tgz#05e6e3b0bdf800a4358573768987ed73d50eb158" + integrity sha512-6oVkPe69dGnq4ZiUgTuuIzTyOTmC/awXyfCdfkvQHQZRqhyzhHMW95aFgr3y/qNlOmCKDaxYmxeT0KOKxcyxWw== dependencies: "@babel/runtime" "^7.15.4" "@babel/traverse" "^7.15.4" "@sindresorhus/slugify" "^1.1.2" chokidar "^3.5.2" fs-exists-cached "^1.0.0" - gatsby-core-utils "^3.10.0" - gatsby-page-utils "^2.10.0" - gatsby-plugin-utils "^3.4.1" - gatsby-telemetry "^3.10.0" + gatsby-core-utils "^3.10.1" + gatsby-page-utils "^2.10.1" + gatsby-plugin-utils "^3.4.2" + gatsby-telemetry "^3.10.1" globby "^11.0.4" lodash "^4.17.21" @@ -6416,10 +6402,10 @@ gatsby-plugin-svgr@3.0.0-beta.0: resolved "https://registry.yarnpkg.com/gatsby-plugin-svgr/-/gatsby-plugin-svgr-3.0.0-beta.0.tgz#7e5315f51dae2663a447899322ea1487cef93dd6" integrity sha512-oALTh6VwO6l3khgC/vGr706aqt38EkXwdr6iXVei/auOKGxpCLEuDCQVal1a4SpYXdjHjRsEyab6bxaHL2lzsA== -gatsby-plugin-typescript@^4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/gatsby-plugin-typescript/-/gatsby-plugin-typescript-4.10.0.tgz#ab518d6cca48cfc0b19ab56ea778ed57ba0e7e52" - integrity sha512-g6vbADv5+MRuNBkyvzpjzr2uwrkoNi/K+dAI2gcLdKQoITj6ZDTR9iB4yMF1s23XshlkwwN8+3/3VUiR1fguoQ== +gatsby-plugin-typescript@^4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-typescript/-/gatsby-plugin-typescript-4.10.1.tgz#1d94532f4cd97677c38bda3b4d92a50b3856e11d" + integrity sha512-yQZYRAZwtj20OrvsF8+xr9V0Jew//3HghM1LKvCB58wECvwLW9SXHzema92JubirFOk7VrdeQfVe3u4jCYDDYw== dependencies: "@babel/core" "^7.15.5" "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" @@ -6427,16 +6413,16 @@ gatsby-plugin-typescript@^4.10.0: "@babel/plugin-proposal-optional-chaining" "^7.14.5" "@babel/preset-typescript" "^7.15.0" "@babel/runtime" "^7.15.4" - babel-plugin-remove-graphql-queries "^4.10.0" + babel-plugin-remove-graphql-queries "^4.10.1" -gatsby-plugin-utils@^3.4.1: - version "3.4.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.4.1.tgz#14c9cff75af32a32860575069af44bdabc8f65d9" - integrity sha512-sDMVGauxMgXyX8WGZDndZI2vIaolJzlXBMdKhgP7DIT+Qa5wjvyHWvZy34dxtVrT3IHPK/PRMgpE81Gr7gKveg== +gatsby-plugin-utils@^3.4.1, gatsby-plugin-utils@^3.4.2: + version "3.4.2" + resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.4.2.tgz#bdc66fd52c052c91af443981e1facbc097429dc7" + integrity sha512-HkVR8BnEdc915pmY2L9wPwFgjq303ThMH9UtT+frDOPzn+GFjPlBF5+YGJ3tZaxH0ouwpnGTn3Pu37tcRZcctA== dependencies: "@babel/runtime" "^7.15.4" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" gatsby-sharp "^0.4.0" graphql-compose "^9.0.7" import-from "^4.0.0" @@ -6477,10 +6463,10 @@ gatsby-source-filesystem@4.10.0: valid-url "^1.0.9" xstate "^4.26.1" -gatsby-telemetry@^3.10.0: - version "3.10.0" - resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.0.tgz#917a4914e531d401ecf98ac87d29128b30bfab13" - integrity sha512-Oe2OShJbylKr5C4FTl2P/JUX/xRkpYb6IMfEoAd5inG7HNQ1fikON4NdwvJjOp++My4kWo+LLCu92TZBkyTtZw== +gatsby-telemetry@^3.10.0, gatsby-telemetry@^3.10.1: + version "3.10.1" + resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.1.tgz#129c4309811cd9b2ba5e9d326ba47dddb59202ca" + integrity sha512-935quI1YsQfzYREuvPLNKBb7IUE2vX9p7WoS7Dc9TbV2xDZPTAzeOfX+HE56ZltkxMi8Zivp7mqe5+n//WL7EQ== dependencies: "@babel/code-frame" "^7.14.0" "@babel/runtime" "^7.15.4" @@ -6490,7 +6476,7 @@ gatsby-telemetry@^3.10.0: boxen "^4.2.0" configstore "^5.0.1" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" git-up "^4.0.5" is-docker "^2.2.1" lodash "^4.17.21" @@ -6520,18 +6506,18 @@ gatsby-transformer-yaml@4.10.0: lodash "^4.17.21" unist-util-select "^1.5.0" -gatsby-worker@^1.10.0: - version "1.10.0" - resolved "https://registry.yarnpkg.com/gatsby-worker/-/gatsby-worker-1.10.0.tgz#19b958656c7a0ff2b52f24cf99b7c08131f5fa04" - integrity sha512-s4y3bI2ltbfm+hBI9OgDRkrtTIgiHW97DnbikzZtF0lgclqDh/7vhFvTjKGejObR/dbV28t+SAMJLzd9klrgog== +gatsby-worker@^1.10.1: + version "1.10.1" + resolved "https://registry.yarnpkg.com/gatsby-worker/-/gatsby-worker-1.10.1.tgz#d2549c9854effe3319bd4bd199be0a5c4d077af2" + integrity sha512-1bHZjWEKppJSLfuRGYIYhHZt9vYffptMPRs3zmrYBocmZcJvq0eNhTIXUvThbhP+2XHqAPHHBUcyKCwlWlMAzA== dependencies: "@babel/core" "^7.15.5" "@babel/runtime" "^7.15.4" -gatsby@4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-4.10.1.tgz#b00f0454baffebfe38de10aeb4db8aa6e39a5e4a" - integrity sha512-UCapYjofrdxa3bIjMUN0Y+EUIEHNX/srOonv03UeZRKHshwAPe6g1eZfXK4iFNy8LxNsH947D5hLN63pNK77zg== +gatsby@4.10.3: + version "4.10.3" + resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-4.10.3.tgz#72d9620d3f9a90c96e568f4803f86458d1dc6a53" + integrity sha512-G6YYwQWrN99KhJgLQl/oy3oKRuTdUcW7Bgb9vRchjY/Apk0eTA2wq33W5L9y+npR3nxly6ZJ2pM8FHw7WX4tKg== dependencies: "@babel/code-frame" "^7.14.0" "@babel/core" "^7.15.5" @@ -6558,8 +6544,8 @@ gatsby@4.10.1: babel-plugin-add-module-exports "^1.0.4" babel-plugin-dynamic-import-node "^2.3.3" babel-plugin-lodash "^3.3.4" - babel-plugin-remove-graphql-queries "^4.10.0" - babel-preset-gatsby "^2.10.0" + babel-plugin-remove-graphql-queries "^4.10.1" + babel-preset-gatsby "^2.10.1" better-opn "^2.1.1" bluebird "^3.7.2" body-parser "^1.19.0" @@ -6578,7 +6564,6 @@ gatsby@4.10.1: date-fns "^2.25.0" debug "^3.2.7" deepmerge "^4.2.2" - del "^5.1.0" detect-port "^1.3.0" devcert "^1.2.0" dotenv "^8.6.0" @@ -6602,20 +6587,21 @@ gatsby@4.10.1: find-cache-dir "^3.3.2" fs-exists-cached "1.0.0" fs-extra "^10.0.0" - gatsby-cli "^4.10.1" - gatsby-core-utils "^3.10.0" + gatsby-cli "^4.10.2" + gatsby-core-utils "^3.10.1" gatsby-graphiql-explorer "^2.10.0" gatsby-legacy-polyfills "^2.10.0" - gatsby-link "^4.10.0" - gatsby-page-utils "^2.10.0" + gatsby-link "^4.10.1" + gatsby-page-utils "^2.10.1" gatsby-parcel-config "^0.1.0" - gatsby-plugin-page-creator "^4.10.1" - gatsby-plugin-typescript "^4.10.0" - gatsby-plugin-utils "^3.4.1" + gatsby-plugin-page-creator "^4.10.2" + gatsby-plugin-typescript "^4.10.1" + gatsby-plugin-utils "^3.4.2" gatsby-react-router-scroll "^5.10.0" - gatsby-telemetry "^3.10.0" - gatsby-worker "^1.10.0" + gatsby-telemetry "^3.10.1" + gatsby-worker "^1.10.1" glob "^7.2.0" + globby "^11.1.0" got "^11.8.2" graphql "^15.7.2" graphql-compose "^9.0.7" @@ -6908,21 +6894,7 @@ globby@11.0.3: merge2 "^1.3.0" slash "^3.0.0" -globby@^10.0.1: - version "10.0.2" - resolved "https://registry.yarnpkg.com/globby/-/globby-10.0.2.tgz#277593e745acaa4646c3ab411289ec47a0392543" - integrity sha512-7dUi7RvCoT/xast/o/dLN53oqND4yk0nsHkhRgn9w65C4PofCLOoJ39iSOg+qVDdWQPIEj+eszMHQ+aLVwwQSg== - dependencies: - "@types/glob" "^7.1.1" - array-union "^2.1.0" - dir-glob "^3.0.1" - fast-glob "^3.0.3" - glob "^7.1.3" - ignore "^5.1.1" - merge2 "^1.2.3" - slash "^3.0.0" - -globby@^11.0.3, globby@^11.0.4: +globby@^11.0.3, globby@^11.0.4, globby@^11.1.0: version "11.1.0" resolved "https://registry.yarnpkg.com/globby/-/globby-11.1.0.tgz#bd4be98bb042f83d796f7e3811991fbe82a0d34b" integrity sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g== @@ -6968,7 +6940,7 @@ got@^9.6.0: to-readable-stream "^1.0.0" url-parse-lax "^3.0.0" -graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.2.0, graceful-fs@^4.2.2, graceful-fs@^4.2.3, graceful-fs@^4.2.4, graceful-fs@^4.2.9: +graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.2.0, graceful-fs@^4.2.3, graceful-fs@^4.2.4, graceful-fs@^4.2.9: version "4.2.9" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.9.tgz#041b05df45755e587a24942279b9d113146e1c96" integrity sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ== @@ -7301,7 +7273,7 @@ ignore@^4.0.6: resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg== -ignore@^5.1.1, ignore@^5.1.4, ignore@^5.1.8, ignore@^5.2.0: +ignore@^5.1.4, ignore@^5.1.8, ignore@^5.2.0: version "5.2.0" resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.0.tgz#6d3bac8fa7fe0d45d9f9be7bac2fc279577e345a" integrity sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ== @@ -7661,12 +7633,7 @@ is-obj@^2.0.0: resolved "https://registry.yarnpkg.com/is-obj/-/is-obj-2.0.0.tgz#473fb05d973705e3fd9620545018ca8e22ef4982" integrity sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w== -is-path-cwd@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/is-path-cwd/-/is-path-cwd-2.2.0.tgz#67d43b82664a7b5191fd9119127eb300048a9fdb" - integrity sha512-w942bTcih8fdJPJmQHFzkS76NEP8Kzzvmw92cXsazb8intwLqPibPPdXf4ANdKV3rYMuuQYGIWtvz9JilB3NFQ== - -is-path-inside@^3.0.1, is-path-inside@^3.0.2: +is-path-inside@^3.0.2: version "3.0.3" resolved "https://registry.yarnpkg.com/is-path-inside/-/is-path-inside-3.0.3.tgz#d231362e53a07ff2b0e0ea7fed049161ffd16283" integrity sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ== @@ -8562,7 +8529,7 @@ merge-stream@^2.0.0: resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-2.0.0.tgz#52823629a14dd00c9770fb6ad47dc6310f2c1f60" integrity sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w== -merge2@^1.2.3, merge2@^1.3.0, merge2@^1.4.1: +merge2@^1.3.0, merge2@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/merge2/-/merge2-1.4.1.tgz#4368892f885e907455a6fd7dc55c0c9d404990ae" integrity sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg== @@ -9306,13 +9273,6 @@ p-locate@^4.1.0: dependencies: p-limit "^2.2.0" -p-map@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/p-map/-/p-map-3.0.0.tgz#d704d9af8a2ba684e2600d9a215983d4141a979d" - integrity sha512-d3qXVTF/s+W+CdJ5A29wywV2n8CQQYahlgz2bFiA+4eVNJbHJodPZ+/gXwPGh0bOqA+j8S+6+ckmvLGPk1QpxQ== - dependencies: - aggregate-error "^3.0.0" - p-map@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/p-map/-/p-map-4.0.0.tgz#bb2f95a5eda2ec168ec9274e06a747c3e2904d2b" From 7f2d1fc7b742e1920a586a7be78131d819576794 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 12:13:11 +0000 Subject: [PATCH 061/240] build(deps): bump nanoid from 3.3.1 to 3.3.2 in /packages/website Bumps [nanoid](https://github.com/ai/nanoid) from 3.3.1 to 3.3.2. - [Release notes](https://github.com/ai/nanoid/releases) - [Changelog](https://github.com/ai/nanoid/blob/main/CHANGELOG.md) - [Commits](https://github.com/ai/nanoid/compare/3.3.1...3.3.2) --- updated-dependencies: - dependency-name: nanoid dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 76737420..55e8a961 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -29,7 +29,7 @@ "gbimage-bridge": "0.2.1", "http-status-codes": "2.2.0", "ms": "2.1.3", - "nanoid": "3.3.1", + "nanoid": "3.3.2", "normalize.css": "8.0.1", "path-browserify": "1.0.1", "polished": "4.1.4", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 255e5afb..8a918295 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -8831,10 +8831,10 @@ nano-css@^5.3.1: stacktrace-js "^2.0.2" stylis "^4.0.6" -nanoid@3.3.1, nanoid@^3.3.1: - version "3.3.1" - resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.1.tgz#6347a18cac88af88f58af0b3594b723d5e99bb35" - integrity sha512-n6Vs/3KGyxPQd6uO0eH4Bv0ojGSUvuLlIHtC3Y0kEO23YRge8H9x1GCzLn28YX0H66pMkxuaeESFq4tKISKwdw== +nanoid@3.3.2, nanoid@^3.3.1: + version "3.3.2" + resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.2.tgz#c89622fafb4381cd221421c69ec58547a1eec557" + integrity sha512-CuHBogktKwpm5g2sRgv83jEy2ijFzBwMoYA60orPDR7ynsLijJDqgsi4RDGj3OJpy3Ieb+LYwiRmIOGyytgITA== nanomatch@^1.2.9: version "1.2.13" From 0ac1e15cbb4272c1a91edc5c16937fa8a62f236e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 13:15:57 +0000 Subject: [PATCH 062/240] build(deps-dev): bump prettier in /packages/dashboard Bumps [prettier](https://github.com/prettier/prettier) from 2.6.0 to 2.6.1. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](https://github.com/prettier/prettier/compare/2.6.0...2.6.1) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 6 +++--- packages/dashboard/yarn.lock | 24 ++++++++++++------------ 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 6da74280..57871425 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -27,7 +27,7 @@ "react-dom": "17.0.2", "react-toastify": "8.2.0", "skynet-js": "3.0.2", - "stripe": "8.210.0", + "stripe": "8.212.0", "swr": "1.2.2", "yup": "0.32.11" }, @@ -35,10 +35,10 @@ "@tailwindcss/forms": "0.5.0", "@tailwindcss/typography": "0.5.2", "autoprefixer": "10.4.4", - "eslint": "8.11.0", + "eslint": "8.12.0", "eslint-config-next": "12.1.0", "postcss": "8.4.12", - "prettier": "2.6.0", + "prettier": "2.6.1", "tailwindcss": "3.0.23" } } diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 6a27a893..5232526d 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -911,10 +911,10 @@ eslint-visitor-keys@^3.0.0, eslint-visitor-keys@^3.3.0: resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.3.0.tgz#f6480fa6b1f30efe2d1968aa8ac745b862469826" integrity sha512-mQ+suqKJVyeuwGYHAdjMFqjCyfl8+Ldnxuyp3ldiMBFKkvytrXUZWaiPCEav8qDHKty44bD+qV1IP4T+w+xXRA== -eslint@8.11.0: - version "8.11.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.11.0.tgz#88b91cfba1356fc10bb9eb592958457dfe09fb37" - integrity sha512-/KRpd9mIRg2raGxHRGwW9ZywYNAClZrHjdueHcrVDuO3a6bj83eoTirCCk0M0yPwOjWYKHwRVRid+xK4F/GHgA== +eslint@8.12.0: + version "8.12.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.12.0.tgz#c7a5bd1cfa09079aae64c9076c07eada66a46e8e" + integrity sha512-it1oBL9alZg1S8UycLm5YDMAkIhtH6FtAzuZs6YvoGVldWjbS08BkAdb/ymP9LlAyq8koANu32U7Ib/w+UNh8Q== dependencies: "@eslint/eslintrc" "^1.2.1" "@humanwhocodes/config-array" "^0.9.2" @@ -1950,10 +1950,10 @@ prelude-ls@^1.2.1: resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.2.1.tgz#debc6489d7a6e6b0e7611888cec880337d316396" integrity sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g== -prettier@2.6.0: - version "2.6.0" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.0.tgz#12f8f504c4d8ddb76475f441337542fa799207d4" - integrity sha512-m2FgJibYrBGGgQXNzfd0PuDGShJgRavjUoRCw1mZERIWVSXF0iLzLm+aOqTAbLnC3n6JzUhAA8uZnFVghHJ86A== +prettier@2.6.1: + version "2.6.1" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.1.tgz#d472797e0d7461605c1609808e27b80c0f9cfe17" + integrity sha512-8UVbTBYGwN37Bs9LERmxCPjdvPxlEowx2urIL6urHzdb3SDq4B/Z6xLFCblrSnE4iKWcS6ziJ3aOYrc1kz/E2A== pretty-bytes@6.0.0: version "6.0.0" @@ -2250,10 +2250,10 @@ strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== -stripe@8.210.0: - version "8.210.0" - resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.210.0.tgz#6e5ede9abd36406d39b89d9129df86fb33f43db3" - integrity sha512-NDQNEInrr1avwSEDB7Phe7PYNejtU9EkhOBlPa90Aomc3WvSXgOuX8MpswQ1mTw+W/lGpePwVqMsUvrvhUjZfA== +stripe@8.212.0: + version "8.212.0" + resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.212.0.tgz#78dc8d2be770580be23a8e597641a9ace6fd1035" + integrity sha512-xQ2uPMRAmRyOiMZktw3hY8jZ8LFR9lEQRPEaQ5WcDcn51kMyn46GeikOikxiFTHEN8PeKRdwtpz4yNArAvu/Kg== dependencies: "@types/node" ">=8.1.0" qs "^6.6.0" From b2d0e26cbdaea0cf063eeed4db308363c9950b23 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 13:16:37 +0000 Subject: [PATCH 063/240] build(deps): bump @fontsource/sora in /packages/dashboard Bumps [@fontsource/sora](https://github.com/fontsource/fontsource/tree/HEAD/fonts/google/sora) from 4.5.3 to 4.5.5. - [Release notes](https://github.com/fontsource/fontsource/releases) - [Changelog](https://github.com/fontsource/fontsource/blob/main/CHANGELOG.md) - [Commits](https://github.com/fontsource/fontsource/commits/HEAD/fonts/google/sora) --- updated-dependencies: - dependency-name: "@fontsource/sora" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index fafb2d44..6fcaa2fa 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -8,7 +8,7 @@ "start": "next start" }, "dependencies": { - "@fontsource/sora": "4.5.3", + "@fontsource/sora": "4.5.5", "@fontsource/source-sans-pro": "4.5.6", "@stripe/react-stripe-js": "1.7.0", "@stripe/stripe-js": "1.25.0", diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 15e2502a..e866b64f 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -53,10 +53,10 @@ minimatch "^3.0.4" strip-json-comments "^3.1.1" -"@fontsource/sora@4.5.3": - version "4.5.3" - resolved "https://registry.yarnpkg.com/@fontsource/sora/-/sora-4.5.3.tgz#987c9b43acb00c9e3fa5377ebcedfd4ec9b760a7" - integrity sha512-0ipYkroLonvChAyLajgIt6mImXMhvjrHwD5g7iX2ZR1eJ4hLDnwq6haW5pSeehe79lPjgp0BX6ZHivFIP0xR2g== +"@fontsource/sora@4.5.5": + version "4.5.5" + resolved "https://registry.yarnpkg.com/@fontsource/sora/-/sora-4.5.5.tgz#25e8e0a11d0a2a861ccce23a94383448c5beaa50" + integrity sha512-SeePOM5pvXaa2a1c9VuGPJGmHNcFSUBzVxfHMuQ/FrVeiXvF3XXyPbt68N6QmHK2rAH844BN1Y5zImxqa5ok6g== "@fontsource/source-sans-pro@4.5.6": version "4.5.6" From 49292d39747e7b1abc1416687753f8ef73c68550 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 13:18:54 +0000 Subject: [PATCH 064/240] build(deps): bump gatsby-source-filesystem in /packages/website Bumps [gatsby-source-filesystem](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-source-filesystem) from 4.10.0 to 4.10.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-source-filesystem/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-source-filesystem@4.10.1/packages/gatsby-source-filesystem) --- updated-dependencies: - dependency-name: gatsby-source-filesystem dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 8 +- packages/website/yarn.lock | 236 ++++++++++++++-------------------- 2 files changed, 102 insertions(+), 142 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 76737420..ab7d2d4e 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -5,7 +5,7 @@ "version": "0.1.0", "author": "Skynet Labs.", "dependencies": { - "@fontsource/sora": "4.5.3", + "@fontsource/sora": "4.5.5", "@fontsource/source-sans-pro": "4.5.4", "@svgr/webpack": "6.2.1", "bytes": "3.1.2", @@ -13,7 +13,7 @@ "copy-text-to-clipboard": "3.0.1", "crypto-browserify": "3.12.0", "framer-motion": "6.2.8", - "gatsby": "4.10.1", + "gatsby": "4.10.3", "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.10.0", "gatsby-plugin-manifest": "4.10.1", @@ -23,13 +23,13 @@ "gatsby-plugin-sharp": "4.10.1", "gatsby-plugin-sitemap": "5.10.1", "gatsby-plugin-svgr": "3.0.0-beta.0", - "gatsby-source-filesystem": "4.10.0", + "gatsby-source-filesystem": "4.10.1", "gatsby-transformer-sharp": "4.10.0", "gatsby-transformer-yaml": "4.10.0", "gbimage-bridge": "0.2.1", "http-status-codes": "2.2.0", "ms": "2.1.3", - "nanoid": "3.3.1", + "nanoid": "3.3.2", "normalize.css": "8.0.1", "path-browserify": "1.0.1", "polished": "4.1.4", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 255e5afb..3958cb83 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -1098,10 +1098,10 @@ minimatch "^3.0.4" strip-json-comments "^3.1.1" -"@fontsource/sora@4.5.3": - version "4.5.3" - resolved "https://registry.yarnpkg.com/@fontsource/sora/-/sora-4.5.3.tgz#987c9b43acb00c9e3fa5377ebcedfd4ec9b760a7" - integrity sha512-0ipYkroLonvChAyLajgIt6mImXMhvjrHwD5g7iX2ZR1eJ4hLDnwq6haW5pSeehe79lPjgp0BX6ZHivFIP0xR2g== +"@fontsource/sora@4.5.5": + version "4.5.5" + resolved "https://registry.yarnpkg.com/@fontsource/sora/-/sora-4.5.5.tgz#25e8e0a11d0a2a861ccce23a94383448c5beaa50" + integrity sha512-SeePOM5pvXaa2a1c9VuGPJGmHNcFSUBzVxfHMuQ/FrVeiXvF3XXyPbt68N6QmHK2rAH844BN1Y5zImxqa5ok6g== "@fontsource/source-sans-pro@4.5.4": version "4.5.4" @@ -2436,7 +2436,7 @@ resolved "https://registry.yarnpkg.com/@types/get-port/-/get-port-3.2.0.tgz#f9e0a11443cc21336470185eae3dfba4495d29bc" integrity sha512-TiNg8R1kjDde5Pub9F9vCwZA/BNW9HeXP5b9j7Qucqncy/McfPZ6xze/EyBdXS5FhMIGN6Fx3vg75l5KHy3V1Q== -"@types/glob@*", "@types/glob@^7.1.1": +"@types/glob@*": version "7.2.0" resolved "https://registry.yarnpkg.com/@types/glob/-/glob-7.2.0.tgz#bc1b5bf3aa92f25bd5dd39f35c57361bdce5b2eb" integrity sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA== @@ -3339,23 +3339,23 @@ babel-plugin-polyfill-regenerator@^0.3.0: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" -babel-plugin-remove-graphql-queries@^4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.0.tgz#882ec7e75627ffd844e5c4c6d7ae50afe87bc415" - integrity sha512-vANJvjh03qC7o6O3huCKO+Jtmee9WPUJm4Nm+qn/ww+GOOQwz0Z0bSMeBhUkJbT/Y1b1JlysHoxTO3ZNH47EwA== +babel-plugin-remove-graphql-queries@^4.10.0, babel-plugin-remove-graphql-queries@^4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.1.tgz#09357b7afad1d1bf359d97701ba267bf968197f4" + integrity sha512-1Irx5lUoQtU56u1hMtrgipjlRsUF4Pz6WDCDNVyTuvcHqlKHQK6pna4igHrdoWhSSgEcbimlxSy6tTvP6bkplg== dependencies: "@babel/runtime" "^7.15.4" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" babel-plugin-transform-react-remove-prop-types@^0.4.24: version "0.4.24" resolved "https://registry.yarnpkg.com/babel-plugin-transform-react-remove-prop-types/-/babel-plugin-transform-react-remove-prop-types-0.4.24.tgz#f2edaf9b4c6a5fbe5c1d678bfb531078c1555f3a" integrity sha512-eqj0hVcJUR57/Ug2zE1Yswsw4LhuqqHhD+8v120T1cl3kjg76QwtyBrdIk4WVwK+lAhBJVYCd/v+4nc4y+8JsA== -babel-preset-gatsby@^2.10.0: - version "2.10.0" - resolved "https://registry.yarnpkg.com/babel-preset-gatsby/-/babel-preset-gatsby-2.10.0.tgz#83695f47dfbb5e6ea2ce2b504f1e8716d39a5535" - integrity sha512-rh8vXjNXzX8Hkt27R7L56EovUf1dZDQavaYiY8zMQno/0iK7XllgO18Cfkgg3yYro0u1jOBWpoderMmZBLaVgw== +babel-preset-gatsby@^2.10.1: + version "2.10.1" + resolved "https://registry.yarnpkg.com/babel-preset-gatsby/-/babel-preset-gatsby-2.10.1.tgz#a31fe2f4b4ed64204baca5ea8267639a00dd1a6b" + integrity sha512-wuEP2Tsf7MnblXIqJDdg+DOUXZhWQHBQYH/6cQ+HdEFiXu0gwskj/s5sPI6KoBgGK23EIZGr94HBtCq0D3aNRQ== dependencies: "@babel/plugin-proposal-class-properties" "^7.14.0" "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" @@ -3370,7 +3370,7 @@ babel-preset-gatsby@^2.10.0: babel-plugin-dynamic-import-node "^2.3.3" babel-plugin-macros "^2.8.0" babel-plugin-transform-react-remove-prop-types "^0.4.24" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" gatsby-legacy-polyfills "^2.10.0" backo2@^1.0.2, backo2@~1.0.2: @@ -4340,10 +4340,10 @@ create-ecdh@^4.0.0: bn.js "^4.1.0" elliptic "^6.5.3" -create-gatsby@^2.10.1: - version "2.10.1" - resolved "https://registry.yarnpkg.com/create-gatsby/-/create-gatsby-2.10.1.tgz#7172877693efe02bebf7bd8c15a4072e83dfb916" - integrity sha512-zkAtC6TLr6nNmZd2yKqnXuEMX2vX9ciu4VBtMY+4J/nQ/cV77xCAmoU9MCAjVDoLp2h8pNckYE1lneFxmhIgkQ== +create-gatsby@^2.10.2: + version "2.10.2" + resolved "https://registry.yarnpkg.com/create-gatsby/-/create-gatsby-2.10.2.tgz#ded9eb4066078845529a02bc966ef414a77b814a" + integrity sha512-OmuFey3Eoaek20m8Br/iIqEr76AUrl/ThCn7TBYJ6RvWVKezKV5UksQlFpdQgPK8kO9LogjkmiyA0k94VC3nXg== dependencies: "@babel/runtime" "^7.15.4" @@ -4808,20 +4808,6 @@ defined@^1.0.0: resolved "https://registry.yarnpkg.com/defined/-/defined-1.0.0.tgz#c98d9bcef75674188e110969151199e39b1fa693" integrity sha1-yY2bzvdWdBiOEQlpFRGZ45sfppM= -del@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/del/-/del-5.1.0.tgz#d9487c94e367410e6eff2925ee58c0c84a75b3a7" - integrity sha512-wH9xOVHnczo9jN2IW68BabcecVPxacIA3g/7z6vhSU/4stOKQzeCRK0yD0A24WiAAUJmmVpWqrERcTxnLo3AnA== - dependencies: - globby "^10.0.1" - graceful-fs "^4.2.2" - is-glob "^4.0.1" - is-path-cwd "^2.2.0" - is-path-inside "^3.0.1" - p-map "^3.0.0" - rimraf "^3.0.0" - slash "^3.0.0" - delayed-stream@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" @@ -5807,7 +5793,7 @@ fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== -fast-glob@^3.0.3, fast-glob@^3.1.1, fast-glob@^3.2.11, fast-glob@^3.2.9: +fast-glob@^3.1.1, fast-glob@^3.2.11, fast-glob@^3.2.9: version "3.2.11" resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.2.11.tgz#a1172ad95ceb8a16e20caa5c5e56480e5129c1d9" integrity sha512-xrO3+1bxSo3ZVHAnqzyuewYT6aMFHRAd4Kcs92MAonjwQZLsK9d0SF1IyQ3k5PoirxTW0Oe/RqFgMQ6TcNE5Ew== @@ -6172,10 +6158,10 @@ gatsby-background-image@1.6.0: short-uuid "^4.2.0" sort-media-queries "^0.2.2" -gatsby-cli@^4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby-cli/-/gatsby-cli-4.10.1.tgz#0c077a7c14de4a95a70edd32916a94580ff3dbda" - integrity sha512-bv1xJEAcv4vT3DKdOqT1W8qe4L0Yvw5sZoSXDSKX9K9YSGu/CnBJXPa31rNrv357mc4CyAf/Vdfnzvr0tNN+iQ== +gatsby-cli@^4.10.2: + version "4.10.2" + resolved "https://registry.yarnpkg.com/gatsby-cli/-/gatsby-cli-4.10.2.tgz#835a2c472d5cd1b9258e5208f7f7184e5fd1b97b" + integrity sha512-lA1zFuWZwE+VtKYgntls0EC5PG4QoqqeJFWP+83Lmh+9hoLLkmL1plALBQeI3JY/9KXgRiC4OoR94CQkI329TA== dependencies: "@babel/code-frame" "^7.14.0" "@babel/core" "^7.15.5" @@ -6193,13 +6179,13 @@ gatsby-cli@^4.10.1: common-tags "^1.8.2" configstore "^5.0.1" convert-hrtime "^3.0.0" - create-gatsby "^2.10.1" + create-gatsby "^2.10.2" envinfo "^7.8.1" execa "^5.1.1" fs-exists-cached "^1.0.0" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" - gatsby-telemetry "^3.10.0" + gatsby-core-utils "^3.10.1" + gatsby-telemetry "^3.10.1" hosted-git-info "^3.0.8" is-valid-path "^0.1.1" joi "^17.4.2" @@ -6223,10 +6209,10 @@ gatsby-cli@^4.10.1: yoga-layout-prebuilt "^1.10.0" yurnalist "^2.1.0" -gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.8.2: - version "3.10.0" - resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.10.0.tgz#52be8a9a891d95686a7ee0c1cfef44f8e362232b" - integrity sha512-yaRI/uUsbIggPRfh0y6CH+fy2AqbFFLxCYndw5nrVByEY40+KaKs0wOF4yIgPRBZZUHOyfBJ+1AGo2JLHdY5lA== +gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.8.2: + version "3.10.1" + resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.10.1.tgz#0f5e6aeda5ef4b86218b27480a9766fe30af4393" + integrity sha512-WqNMm0u1CAZm6Q+UQ4dDHwIAt3l32NeIaPuSXmDX7QcMGR3FUUk8cl2Ym6gx1hfILm1aCexqfaSCLUXtaWKkbQ== dependencies: "@babel/runtime" "^7.15.4" ci-info "2.0.0" @@ -6259,26 +6245,26 @@ gatsby-legacy-polyfills@^2.10.0: "@babel/runtime" "^7.15.4" core-js-compat "3.9.0" -gatsby-link@^4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/gatsby-link/-/gatsby-link-4.10.0.tgz#11565eca6df53e7952c44bc290791bb032fa88ce" - integrity sha512-icF3i58MWgk4hSLaI6s5xyUp/rPy6MK7F4hsETQgJR32aZzkhj5Ydd1Cqw5P0CYo8EdaYKtljFBVwai8TnY4MQ== +gatsby-link@^4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/gatsby-link/-/gatsby-link-4.10.1.tgz#f68b04b900c9c81070913d65a6e4051a2266dc1b" + integrity sha512-U9Qry93Q+aXF9acs1YPH+wzipPlZELUa619CAhZnLv2sk75Iq5SttMZI/d0uhgF+X80PvoEKMkLb/VE4YiqVtw== dependencies: "@babel/runtime" "^7.15.4" "@types/reach__router" "^1.3.10" - gatsby-page-utils "^2.10.0" + gatsby-page-utils "^2.10.1" prop-types "^15.7.2" -gatsby-page-utils@^2.10.0: - version "2.10.0" - resolved "https://registry.yarnpkg.com/gatsby-page-utils/-/gatsby-page-utils-2.10.0.tgz#8d7729714ca2c5b416ed527eeaa59f5737d20888" - integrity sha512-xyWHrMAJCd/w4mCZ1anK4ADT7pKdVZgQhppBWkm9H604p7RqsoloaQ9XGbPUuypzyPQw78yV5oY6bsaDpbvtrg== +gatsby-page-utils@^2.10.1: + version "2.10.1" + resolved "https://registry.yarnpkg.com/gatsby-page-utils/-/gatsby-page-utils-2.10.1.tgz#39420dd41508ca2793f0c838816b16fd10bbc8d7" + integrity sha512-juhN7/cLKoFGPW37xBCN78D02yO1htxR3raO/f2iseCCsyDjXRnqGHgpdFu8g8s8bkukL5vscgALcyChQf7NtA== dependencies: "@babel/runtime" "^7.15.4" bluebird "^3.7.2" chokidar "^3.5.2" fs-exists-cached "^1.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" glob "^7.2.0" lodash "^4.17.21" micromatch "^4.0.4" @@ -6336,20 +6322,20 @@ gatsby-plugin-manifest@4.10.1: semver "^7.3.5" sharp "^0.30.1" -gatsby-plugin-page-creator@^4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-page-creator/-/gatsby-plugin-page-creator-4.10.1.tgz#6c5308daba53729225578ca67e52f117088502a5" - integrity sha512-tTN4qHH2n7CiV/MNx/FcnBBOmCWzlMkpIR6AtJfxdO5sncn3XIEwMKNxvp9WUm2bevUodlynxlER1dOtgj+DJA== +gatsby-plugin-page-creator@^4.10.2: + version "4.10.2" + resolved "https://registry.yarnpkg.com/gatsby-plugin-page-creator/-/gatsby-plugin-page-creator-4.10.2.tgz#05e6e3b0bdf800a4358573768987ed73d50eb158" + integrity sha512-6oVkPe69dGnq4ZiUgTuuIzTyOTmC/awXyfCdfkvQHQZRqhyzhHMW95aFgr3y/qNlOmCKDaxYmxeT0KOKxcyxWw== dependencies: "@babel/runtime" "^7.15.4" "@babel/traverse" "^7.15.4" "@sindresorhus/slugify" "^1.1.2" chokidar "^3.5.2" fs-exists-cached "^1.0.0" - gatsby-core-utils "^3.10.0" - gatsby-page-utils "^2.10.0" - gatsby-plugin-utils "^3.4.1" - gatsby-telemetry "^3.10.0" + gatsby-core-utils "^3.10.1" + gatsby-page-utils "^2.10.1" + gatsby-plugin-utils "^3.4.2" + gatsby-telemetry "^3.10.1" globby "^11.0.4" lodash "^4.17.21" @@ -6416,10 +6402,10 @@ gatsby-plugin-svgr@3.0.0-beta.0: resolved "https://registry.yarnpkg.com/gatsby-plugin-svgr/-/gatsby-plugin-svgr-3.0.0-beta.0.tgz#7e5315f51dae2663a447899322ea1487cef93dd6" integrity sha512-oALTh6VwO6l3khgC/vGr706aqt38EkXwdr6iXVei/auOKGxpCLEuDCQVal1a4SpYXdjHjRsEyab6bxaHL2lzsA== -gatsby-plugin-typescript@^4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/gatsby-plugin-typescript/-/gatsby-plugin-typescript-4.10.0.tgz#ab518d6cca48cfc0b19ab56ea778ed57ba0e7e52" - integrity sha512-g6vbADv5+MRuNBkyvzpjzr2uwrkoNi/K+dAI2gcLdKQoITj6ZDTR9iB4yMF1s23XshlkwwN8+3/3VUiR1fguoQ== +gatsby-plugin-typescript@^4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-typescript/-/gatsby-plugin-typescript-4.10.1.tgz#1d94532f4cd97677c38bda3b4d92a50b3856e11d" + integrity sha512-yQZYRAZwtj20OrvsF8+xr9V0Jew//3HghM1LKvCB58wECvwLW9SXHzema92JubirFOk7VrdeQfVe3u4jCYDDYw== dependencies: "@babel/core" "^7.15.5" "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" @@ -6427,16 +6413,16 @@ gatsby-plugin-typescript@^4.10.0: "@babel/plugin-proposal-optional-chaining" "^7.14.5" "@babel/preset-typescript" "^7.15.0" "@babel/runtime" "^7.15.4" - babel-plugin-remove-graphql-queries "^4.10.0" + babel-plugin-remove-graphql-queries "^4.10.1" -gatsby-plugin-utils@^3.4.1: - version "3.4.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.4.1.tgz#14c9cff75af32a32860575069af44bdabc8f65d9" - integrity sha512-sDMVGauxMgXyX8WGZDndZI2vIaolJzlXBMdKhgP7DIT+Qa5wjvyHWvZy34dxtVrT3IHPK/PRMgpE81Gr7gKveg== +gatsby-plugin-utils@^3.4.1, gatsby-plugin-utils@^3.4.2: + version "3.4.2" + resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.4.2.tgz#bdc66fd52c052c91af443981e1facbc097429dc7" + integrity sha512-HkVR8BnEdc915pmY2L9wPwFgjq303ThMH9UtT+frDOPzn+GFjPlBF5+YGJ3tZaxH0ouwpnGTn3Pu37tcRZcctA== dependencies: "@babel/runtime" "^7.15.4" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" gatsby-sharp "^0.4.0" graphql-compose "^9.0.7" import-from "^4.0.0" @@ -6459,16 +6445,16 @@ gatsby-sharp@^0.4.0: "@types/sharp" "^0.29.5" sharp "^0.30.1" -gatsby-source-filesystem@4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/gatsby-source-filesystem/-/gatsby-source-filesystem-4.10.0.tgz#d51041c01b0e905a426f8ad81494175e2f2a1109" - integrity sha512-fRN7MFVnmxljVmZZCYswNNMdFygB0hfHmtTM6kdbBc8llkRPtr9tsvK6LHnWsxU2tzPHDTGvRORcSs/coT2v3A== +gatsby-source-filesystem@4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/gatsby-source-filesystem/-/gatsby-source-filesystem-4.10.1.tgz#c513fadb3cedb138ff28ba351ffd264524a0c28d" + integrity sha512-qdOWS234l6QyEN0M8tfdGQF530pK9nSiaT1JfSzZV7Bl9psX9SdsuOtfZ2AV0QVt1BQB7C53E/BNGaxMLCcnUg== dependencies: "@babel/runtime" "^7.15.4" chokidar "^3.5.2" file-type "^16.5.3" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" got "^9.6.0" md5-file "^5.0.0" mime "^2.5.2" @@ -6477,10 +6463,10 @@ gatsby-source-filesystem@4.10.0: valid-url "^1.0.9" xstate "^4.26.1" -gatsby-telemetry@^3.10.0: - version "3.10.0" - resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.0.tgz#917a4914e531d401ecf98ac87d29128b30bfab13" - integrity sha512-Oe2OShJbylKr5C4FTl2P/JUX/xRkpYb6IMfEoAd5inG7HNQ1fikON4NdwvJjOp++My4kWo+LLCu92TZBkyTtZw== +gatsby-telemetry@^3.10.0, gatsby-telemetry@^3.10.1: + version "3.10.1" + resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.1.tgz#129c4309811cd9b2ba5e9d326ba47dddb59202ca" + integrity sha512-935quI1YsQfzYREuvPLNKBb7IUE2vX9p7WoS7Dc9TbV2xDZPTAzeOfX+HE56ZltkxMi8Zivp7mqe5+n//WL7EQ== dependencies: "@babel/code-frame" "^7.14.0" "@babel/runtime" "^7.15.4" @@ -6490,7 +6476,7 @@ gatsby-telemetry@^3.10.0: boxen "^4.2.0" configstore "^5.0.1" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" git-up "^4.0.5" is-docker "^2.2.1" lodash "^4.17.21" @@ -6520,18 +6506,18 @@ gatsby-transformer-yaml@4.10.0: lodash "^4.17.21" unist-util-select "^1.5.0" -gatsby-worker@^1.10.0: - version "1.10.0" - resolved "https://registry.yarnpkg.com/gatsby-worker/-/gatsby-worker-1.10.0.tgz#19b958656c7a0ff2b52f24cf99b7c08131f5fa04" - integrity sha512-s4y3bI2ltbfm+hBI9OgDRkrtTIgiHW97DnbikzZtF0lgclqDh/7vhFvTjKGejObR/dbV28t+SAMJLzd9klrgog== +gatsby-worker@^1.10.1: + version "1.10.1" + resolved "https://registry.yarnpkg.com/gatsby-worker/-/gatsby-worker-1.10.1.tgz#d2549c9854effe3319bd4bd199be0a5c4d077af2" + integrity sha512-1bHZjWEKppJSLfuRGYIYhHZt9vYffptMPRs3zmrYBocmZcJvq0eNhTIXUvThbhP+2XHqAPHHBUcyKCwlWlMAzA== dependencies: "@babel/core" "^7.15.5" "@babel/runtime" "^7.15.4" -gatsby@4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-4.10.1.tgz#b00f0454baffebfe38de10aeb4db8aa6e39a5e4a" - integrity sha512-UCapYjofrdxa3bIjMUN0Y+EUIEHNX/srOonv03UeZRKHshwAPe6g1eZfXK4iFNy8LxNsH947D5hLN63pNK77zg== +gatsby@4.10.3: + version "4.10.3" + resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-4.10.3.tgz#72d9620d3f9a90c96e568f4803f86458d1dc6a53" + integrity sha512-G6YYwQWrN99KhJgLQl/oy3oKRuTdUcW7Bgb9vRchjY/Apk0eTA2wq33W5L9y+npR3nxly6ZJ2pM8FHw7WX4tKg== dependencies: "@babel/code-frame" "^7.14.0" "@babel/core" "^7.15.5" @@ -6558,8 +6544,8 @@ gatsby@4.10.1: babel-plugin-add-module-exports "^1.0.4" babel-plugin-dynamic-import-node "^2.3.3" babel-plugin-lodash "^3.3.4" - babel-plugin-remove-graphql-queries "^4.10.0" - babel-preset-gatsby "^2.10.0" + babel-plugin-remove-graphql-queries "^4.10.1" + babel-preset-gatsby "^2.10.1" better-opn "^2.1.1" bluebird "^3.7.2" body-parser "^1.19.0" @@ -6578,7 +6564,6 @@ gatsby@4.10.1: date-fns "^2.25.0" debug "^3.2.7" deepmerge "^4.2.2" - del "^5.1.0" detect-port "^1.3.0" devcert "^1.2.0" dotenv "^8.6.0" @@ -6602,20 +6587,21 @@ gatsby@4.10.1: find-cache-dir "^3.3.2" fs-exists-cached "1.0.0" fs-extra "^10.0.0" - gatsby-cli "^4.10.1" - gatsby-core-utils "^3.10.0" + gatsby-cli "^4.10.2" + gatsby-core-utils "^3.10.1" gatsby-graphiql-explorer "^2.10.0" gatsby-legacy-polyfills "^2.10.0" - gatsby-link "^4.10.0" - gatsby-page-utils "^2.10.0" + gatsby-link "^4.10.1" + gatsby-page-utils "^2.10.1" gatsby-parcel-config "^0.1.0" - gatsby-plugin-page-creator "^4.10.1" - gatsby-plugin-typescript "^4.10.0" - gatsby-plugin-utils "^3.4.1" + gatsby-plugin-page-creator "^4.10.2" + gatsby-plugin-typescript "^4.10.1" + gatsby-plugin-utils "^3.4.2" gatsby-react-router-scroll "^5.10.0" - gatsby-telemetry "^3.10.0" - gatsby-worker "^1.10.0" + gatsby-telemetry "^3.10.1" + gatsby-worker "^1.10.1" glob "^7.2.0" + globby "^11.1.0" got "^11.8.2" graphql "^15.7.2" graphql-compose "^9.0.7" @@ -6908,21 +6894,7 @@ globby@11.0.3: merge2 "^1.3.0" slash "^3.0.0" -globby@^10.0.1: - version "10.0.2" - resolved "https://registry.yarnpkg.com/globby/-/globby-10.0.2.tgz#277593e745acaa4646c3ab411289ec47a0392543" - integrity sha512-7dUi7RvCoT/xast/o/dLN53oqND4yk0nsHkhRgn9w65C4PofCLOoJ39iSOg+qVDdWQPIEj+eszMHQ+aLVwwQSg== - dependencies: - "@types/glob" "^7.1.1" - array-union "^2.1.0" - dir-glob "^3.0.1" - fast-glob "^3.0.3" - glob "^7.1.3" - ignore "^5.1.1" - merge2 "^1.2.3" - slash "^3.0.0" - -globby@^11.0.3, globby@^11.0.4: +globby@^11.0.3, globby@^11.0.4, globby@^11.1.0: version "11.1.0" resolved "https://registry.yarnpkg.com/globby/-/globby-11.1.0.tgz#bd4be98bb042f83d796f7e3811991fbe82a0d34b" integrity sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g== @@ -6968,7 +6940,7 @@ got@^9.6.0: to-readable-stream "^1.0.0" url-parse-lax "^3.0.0" -graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.2.0, graceful-fs@^4.2.2, graceful-fs@^4.2.3, graceful-fs@^4.2.4, graceful-fs@^4.2.9: +graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.2.0, graceful-fs@^4.2.3, graceful-fs@^4.2.4, graceful-fs@^4.2.9: version "4.2.9" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.9.tgz#041b05df45755e587a24942279b9d113146e1c96" integrity sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ== @@ -7301,7 +7273,7 @@ ignore@^4.0.6: resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg== -ignore@^5.1.1, ignore@^5.1.4, ignore@^5.1.8, ignore@^5.2.0: +ignore@^5.1.4, ignore@^5.1.8, ignore@^5.2.0: version "5.2.0" resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.0.tgz#6d3bac8fa7fe0d45d9f9be7bac2fc279577e345a" integrity sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ== @@ -7661,12 +7633,7 @@ is-obj@^2.0.0: resolved "https://registry.yarnpkg.com/is-obj/-/is-obj-2.0.0.tgz#473fb05d973705e3fd9620545018ca8e22ef4982" integrity sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w== -is-path-cwd@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/is-path-cwd/-/is-path-cwd-2.2.0.tgz#67d43b82664a7b5191fd9119127eb300048a9fdb" - integrity sha512-w942bTcih8fdJPJmQHFzkS76NEP8Kzzvmw92cXsazb8intwLqPibPPdXf4ANdKV3rYMuuQYGIWtvz9JilB3NFQ== - -is-path-inside@^3.0.1, is-path-inside@^3.0.2: +is-path-inside@^3.0.2: version "3.0.3" resolved "https://registry.yarnpkg.com/is-path-inside/-/is-path-inside-3.0.3.tgz#d231362e53a07ff2b0e0ea7fed049161ffd16283" integrity sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ== @@ -8562,7 +8529,7 @@ merge-stream@^2.0.0: resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-2.0.0.tgz#52823629a14dd00c9770fb6ad47dc6310f2c1f60" integrity sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w== -merge2@^1.2.3, merge2@^1.3.0, merge2@^1.4.1: +merge2@^1.3.0, merge2@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/merge2/-/merge2-1.4.1.tgz#4368892f885e907455a6fd7dc55c0c9d404990ae" integrity sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg== @@ -8831,10 +8798,10 @@ nano-css@^5.3.1: stacktrace-js "^2.0.2" stylis "^4.0.6" -nanoid@3.3.1, nanoid@^3.3.1: - version "3.3.1" - resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.1.tgz#6347a18cac88af88f58af0b3594b723d5e99bb35" - integrity sha512-n6Vs/3KGyxPQd6uO0eH4Bv0ojGSUvuLlIHtC3Y0kEO23YRge8H9x1GCzLn28YX0H66pMkxuaeESFq4tKISKwdw== +nanoid@3.3.2, nanoid@^3.3.1: + version "3.3.2" + resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.2.tgz#c89622fafb4381cd221421c69ec58547a1eec557" + integrity sha512-CuHBogktKwpm5g2sRgv83jEy2ijFzBwMoYA60orPDR7ynsLijJDqgsi4RDGj3OJpy3Ieb+LYwiRmIOGyytgITA== nanomatch@^1.2.9: version "1.2.13" @@ -9306,13 +9273,6 @@ p-locate@^4.1.0: dependencies: p-limit "^2.2.0" -p-map@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/p-map/-/p-map-3.0.0.tgz#d704d9af8a2ba684e2600d9a215983d4141a979d" - integrity sha512-d3qXVTF/s+W+CdJ5A29wywV2n8CQQYahlgz2bFiA+4eVNJbHJodPZ+/gXwPGh0bOqA+j8S+6+ckmvLGPk1QpxQ== - dependencies: - aggregate-error "^3.0.0" - p-map@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/p-map/-/p-map-4.0.0.tgz#bb2f95a5eda2ec168ec9274e06a747c3e2904d2b" From 0472e489e18cd47a20ef30bce2587aa6d9957297 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 13:19:13 +0000 Subject: [PATCH 065/240] build(deps-dev): bump prettier from 2.6.0 to 2.6.1 in /packages/website Bumps [prettier](https://github.com/prettier/prettier) from 2.6.0 to 2.6.1. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](https://github.com/prettier/prettier/compare/2.6.0...2.6.1) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 8 +- packages/website/yarn.lock | 234 ++++++++++++++-------------------- 2 files changed, 101 insertions(+), 141 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 76737420..c8fb9cd1 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -5,7 +5,7 @@ "version": "0.1.0", "author": "Skynet Labs.", "dependencies": { - "@fontsource/sora": "4.5.3", + "@fontsource/sora": "4.5.5", "@fontsource/source-sans-pro": "4.5.4", "@svgr/webpack": "6.2.1", "bytes": "3.1.2", @@ -13,7 +13,7 @@ "copy-text-to-clipboard": "3.0.1", "crypto-browserify": "3.12.0", "framer-motion": "6.2.8", - "gatsby": "4.10.1", + "gatsby": "4.10.3", "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.10.0", "gatsby-plugin-manifest": "4.10.1", @@ -29,7 +29,7 @@ "gbimage-bridge": "0.2.1", "http-status-codes": "2.2.0", "ms": "2.1.3", - "nanoid": "3.3.1", + "nanoid": "3.3.2", "normalize.css": "8.0.1", "path-browserify": "1.0.1", "polished": "4.1.4", @@ -49,7 +49,7 @@ "autoprefixer": "10.4.4", "cross-env": "7.0.3", "cypress": "9.5.2", - "prettier": "2.6.0", + "prettier": "2.6.1", "tailwindcss": "3.0.23" }, "keywords": [ diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 255e5afb..c59af36e 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -1098,10 +1098,10 @@ minimatch "^3.0.4" strip-json-comments "^3.1.1" -"@fontsource/sora@4.5.3": - version "4.5.3" - resolved "https://registry.yarnpkg.com/@fontsource/sora/-/sora-4.5.3.tgz#987c9b43acb00c9e3fa5377ebcedfd4ec9b760a7" - integrity sha512-0ipYkroLonvChAyLajgIt6mImXMhvjrHwD5g7iX2ZR1eJ4hLDnwq6haW5pSeehe79lPjgp0BX6ZHivFIP0xR2g== +"@fontsource/sora@4.5.5": + version "4.5.5" + resolved "https://registry.yarnpkg.com/@fontsource/sora/-/sora-4.5.5.tgz#25e8e0a11d0a2a861ccce23a94383448c5beaa50" + integrity sha512-SeePOM5pvXaa2a1c9VuGPJGmHNcFSUBzVxfHMuQ/FrVeiXvF3XXyPbt68N6QmHK2rAH844BN1Y5zImxqa5ok6g== "@fontsource/source-sans-pro@4.5.4": version "4.5.4" @@ -2436,7 +2436,7 @@ resolved "https://registry.yarnpkg.com/@types/get-port/-/get-port-3.2.0.tgz#f9e0a11443cc21336470185eae3dfba4495d29bc" integrity sha512-TiNg8R1kjDde5Pub9F9vCwZA/BNW9HeXP5b9j7Qucqncy/McfPZ6xze/EyBdXS5FhMIGN6Fx3vg75l5KHy3V1Q== -"@types/glob@*", "@types/glob@^7.1.1": +"@types/glob@*": version "7.2.0" resolved "https://registry.yarnpkg.com/@types/glob/-/glob-7.2.0.tgz#bc1b5bf3aa92f25bd5dd39f35c57361bdce5b2eb" integrity sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA== @@ -3339,23 +3339,23 @@ babel-plugin-polyfill-regenerator@^0.3.0: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" -babel-plugin-remove-graphql-queries@^4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.0.tgz#882ec7e75627ffd844e5c4c6d7ae50afe87bc415" - integrity sha512-vANJvjh03qC7o6O3huCKO+Jtmee9WPUJm4Nm+qn/ww+GOOQwz0Z0bSMeBhUkJbT/Y1b1JlysHoxTO3ZNH47EwA== +babel-plugin-remove-graphql-queries@^4.10.0, babel-plugin-remove-graphql-queries@^4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.1.tgz#09357b7afad1d1bf359d97701ba267bf968197f4" + integrity sha512-1Irx5lUoQtU56u1hMtrgipjlRsUF4Pz6WDCDNVyTuvcHqlKHQK6pna4igHrdoWhSSgEcbimlxSy6tTvP6bkplg== dependencies: "@babel/runtime" "^7.15.4" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" babel-plugin-transform-react-remove-prop-types@^0.4.24: version "0.4.24" resolved "https://registry.yarnpkg.com/babel-plugin-transform-react-remove-prop-types/-/babel-plugin-transform-react-remove-prop-types-0.4.24.tgz#f2edaf9b4c6a5fbe5c1d678bfb531078c1555f3a" integrity sha512-eqj0hVcJUR57/Ug2zE1Yswsw4LhuqqHhD+8v120T1cl3kjg76QwtyBrdIk4WVwK+lAhBJVYCd/v+4nc4y+8JsA== -babel-preset-gatsby@^2.10.0: - version "2.10.0" - resolved "https://registry.yarnpkg.com/babel-preset-gatsby/-/babel-preset-gatsby-2.10.0.tgz#83695f47dfbb5e6ea2ce2b504f1e8716d39a5535" - integrity sha512-rh8vXjNXzX8Hkt27R7L56EovUf1dZDQavaYiY8zMQno/0iK7XllgO18Cfkgg3yYro0u1jOBWpoderMmZBLaVgw== +babel-preset-gatsby@^2.10.1: + version "2.10.1" + resolved "https://registry.yarnpkg.com/babel-preset-gatsby/-/babel-preset-gatsby-2.10.1.tgz#a31fe2f4b4ed64204baca5ea8267639a00dd1a6b" + integrity sha512-wuEP2Tsf7MnblXIqJDdg+DOUXZhWQHBQYH/6cQ+HdEFiXu0gwskj/s5sPI6KoBgGK23EIZGr94HBtCq0D3aNRQ== dependencies: "@babel/plugin-proposal-class-properties" "^7.14.0" "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" @@ -3370,7 +3370,7 @@ babel-preset-gatsby@^2.10.0: babel-plugin-dynamic-import-node "^2.3.3" babel-plugin-macros "^2.8.0" babel-plugin-transform-react-remove-prop-types "^0.4.24" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" gatsby-legacy-polyfills "^2.10.0" backo2@^1.0.2, backo2@~1.0.2: @@ -4340,10 +4340,10 @@ create-ecdh@^4.0.0: bn.js "^4.1.0" elliptic "^6.5.3" -create-gatsby@^2.10.1: - version "2.10.1" - resolved "https://registry.yarnpkg.com/create-gatsby/-/create-gatsby-2.10.1.tgz#7172877693efe02bebf7bd8c15a4072e83dfb916" - integrity sha512-zkAtC6TLr6nNmZd2yKqnXuEMX2vX9ciu4VBtMY+4J/nQ/cV77xCAmoU9MCAjVDoLp2h8pNckYE1lneFxmhIgkQ== +create-gatsby@^2.10.2: + version "2.10.2" + resolved "https://registry.yarnpkg.com/create-gatsby/-/create-gatsby-2.10.2.tgz#ded9eb4066078845529a02bc966ef414a77b814a" + integrity sha512-OmuFey3Eoaek20m8Br/iIqEr76AUrl/ThCn7TBYJ6RvWVKezKV5UksQlFpdQgPK8kO9LogjkmiyA0k94VC3nXg== dependencies: "@babel/runtime" "^7.15.4" @@ -4808,20 +4808,6 @@ defined@^1.0.0: resolved "https://registry.yarnpkg.com/defined/-/defined-1.0.0.tgz#c98d9bcef75674188e110969151199e39b1fa693" integrity sha1-yY2bzvdWdBiOEQlpFRGZ45sfppM= -del@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/del/-/del-5.1.0.tgz#d9487c94e367410e6eff2925ee58c0c84a75b3a7" - integrity sha512-wH9xOVHnczo9jN2IW68BabcecVPxacIA3g/7z6vhSU/4stOKQzeCRK0yD0A24WiAAUJmmVpWqrERcTxnLo3AnA== - dependencies: - globby "^10.0.1" - graceful-fs "^4.2.2" - is-glob "^4.0.1" - is-path-cwd "^2.2.0" - is-path-inside "^3.0.1" - p-map "^3.0.0" - rimraf "^3.0.0" - slash "^3.0.0" - delayed-stream@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" @@ -5807,7 +5793,7 @@ fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== -fast-glob@^3.0.3, fast-glob@^3.1.1, fast-glob@^3.2.11, fast-glob@^3.2.9: +fast-glob@^3.1.1, fast-glob@^3.2.11, fast-glob@^3.2.9: version "3.2.11" resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.2.11.tgz#a1172ad95ceb8a16e20caa5c5e56480e5129c1d9" integrity sha512-xrO3+1bxSo3ZVHAnqzyuewYT6aMFHRAd4Kcs92MAonjwQZLsK9d0SF1IyQ3k5PoirxTW0Oe/RqFgMQ6TcNE5Ew== @@ -6172,10 +6158,10 @@ gatsby-background-image@1.6.0: short-uuid "^4.2.0" sort-media-queries "^0.2.2" -gatsby-cli@^4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby-cli/-/gatsby-cli-4.10.1.tgz#0c077a7c14de4a95a70edd32916a94580ff3dbda" - integrity sha512-bv1xJEAcv4vT3DKdOqT1W8qe4L0Yvw5sZoSXDSKX9K9YSGu/CnBJXPa31rNrv357mc4CyAf/Vdfnzvr0tNN+iQ== +gatsby-cli@^4.10.2: + version "4.10.2" + resolved "https://registry.yarnpkg.com/gatsby-cli/-/gatsby-cli-4.10.2.tgz#835a2c472d5cd1b9258e5208f7f7184e5fd1b97b" + integrity sha512-lA1zFuWZwE+VtKYgntls0EC5PG4QoqqeJFWP+83Lmh+9hoLLkmL1plALBQeI3JY/9KXgRiC4OoR94CQkI329TA== dependencies: "@babel/code-frame" "^7.14.0" "@babel/core" "^7.15.5" @@ -6193,13 +6179,13 @@ gatsby-cli@^4.10.1: common-tags "^1.8.2" configstore "^5.0.1" convert-hrtime "^3.0.0" - create-gatsby "^2.10.1" + create-gatsby "^2.10.2" envinfo "^7.8.1" execa "^5.1.1" fs-exists-cached "^1.0.0" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" - gatsby-telemetry "^3.10.0" + gatsby-core-utils "^3.10.1" + gatsby-telemetry "^3.10.1" hosted-git-info "^3.0.8" is-valid-path "^0.1.1" joi "^17.4.2" @@ -6223,10 +6209,10 @@ gatsby-cli@^4.10.1: yoga-layout-prebuilt "^1.10.0" yurnalist "^2.1.0" -gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.8.2: - version "3.10.0" - resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.10.0.tgz#52be8a9a891d95686a7ee0c1cfef44f8e362232b" - integrity sha512-yaRI/uUsbIggPRfh0y6CH+fy2AqbFFLxCYndw5nrVByEY40+KaKs0wOF4yIgPRBZZUHOyfBJ+1AGo2JLHdY5lA== +gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.8.2: + version "3.10.1" + resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.10.1.tgz#0f5e6aeda5ef4b86218b27480a9766fe30af4393" + integrity sha512-WqNMm0u1CAZm6Q+UQ4dDHwIAt3l32NeIaPuSXmDX7QcMGR3FUUk8cl2Ym6gx1hfILm1aCexqfaSCLUXtaWKkbQ== dependencies: "@babel/runtime" "^7.15.4" ci-info "2.0.0" @@ -6259,26 +6245,26 @@ gatsby-legacy-polyfills@^2.10.0: "@babel/runtime" "^7.15.4" core-js-compat "3.9.0" -gatsby-link@^4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/gatsby-link/-/gatsby-link-4.10.0.tgz#11565eca6df53e7952c44bc290791bb032fa88ce" - integrity sha512-icF3i58MWgk4hSLaI6s5xyUp/rPy6MK7F4hsETQgJR32aZzkhj5Ydd1Cqw5P0CYo8EdaYKtljFBVwai8TnY4MQ== +gatsby-link@^4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/gatsby-link/-/gatsby-link-4.10.1.tgz#f68b04b900c9c81070913d65a6e4051a2266dc1b" + integrity sha512-U9Qry93Q+aXF9acs1YPH+wzipPlZELUa619CAhZnLv2sk75Iq5SttMZI/d0uhgF+X80PvoEKMkLb/VE4YiqVtw== dependencies: "@babel/runtime" "^7.15.4" "@types/reach__router" "^1.3.10" - gatsby-page-utils "^2.10.0" + gatsby-page-utils "^2.10.1" prop-types "^15.7.2" -gatsby-page-utils@^2.10.0: - version "2.10.0" - resolved "https://registry.yarnpkg.com/gatsby-page-utils/-/gatsby-page-utils-2.10.0.tgz#8d7729714ca2c5b416ed527eeaa59f5737d20888" - integrity sha512-xyWHrMAJCd/w4mCZ1anK4ADT7pKdVZgQhppBWkm9H604p7RqsoloaQ9XGbPUuypzyPQw78yV5oY6bsaDpbvtrg== +gatsby-page-utils@^2.10.1: + version "2.10.1" + resolved "https://registry.yarnpkg.com/gatsby-page-utils/-/gatsby-page-utils-2.10.1.tgz#39420dd41508ca2793f0c838816b16fd10bbc8d7" + integrity sha512-juhN7/cLKoFGPW37xBCN78D02yO1htxR3raO/f2iseCCsyDjXRnqGHgpdFu8g8s8bkukL5vscgALcyChQf7NtA== dependencies: "@babel/runtime" "^7.15.4" bluebird "^3.7.2" chokidar "^3.5.2" fs-exists-cached "^1.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" glob "^7.2.0" lodash "^4.17.21" micromatch "^4.0.4" @@ -6336,20 +6322,20 @@ gatsby-plugin-manifest@4.10.1: semver "^7.3.5" sharp "^0.30.1" -gatsby-plugin-page-creator@^4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-page-creator/-/gatsby-plugin-page-creator-4.10.1.tgz#6c5308daba53729225578ca67e52f117088502a5" - integrity sha512-tTN4qHH2n7CiV/MNx/FcnBBOmCWzlMkpIR6AtJfxdO5sncn3XIEwMKNxvp9WUm2bevUodlynxlER1dOtgj+DJA== +gatsby-plugin-page-creator@^4.10.2: + version "4.10.2" + resolved "https://registry.yarnpkg.com/gatsby-plugin-page-creator/-/gatsby-plugin-page-creator-4.10.2.tgz#05e6e3b0bdf800a4358573768987ed73d50eb158" + integrity sha512-6oVkPe69dGnq4ZiUgTuuIzTyOTmC/awXyfCdfkvQHQZRqhyzhHMW95aFgr3y/qNlOmCKDaxYmxeT0KOKxcyxWw== dependencies: "@babel/runtime" "^7.15.4" "@babel/traverse" "^7.15.4" "@sindresorhus/slugify" "^1.1.2" chokidar "^3.5.2" fs-exists-cached "^1.0.0" - gatsby-core-utils "^3.10.0" - gatsby-page-utils "^2.10.0" - gatsby-plugin-utils "^3.4.1" - gatsby-telemetry "^3.10.0" + gatsby-core-utils "^3.10.1" + gatsby-page-utils "^2.10.1" + gatsby-plugin-utils "^3.4.2" + gatsby-telemetry "^3.10.1" globby "^11.0.4" lodash "^4.17.21" @@ -6416,10 +6402,10 @@ gatsby-plugin-svgr@3.0.0-beta.0: resolved "https://registry.yarnpkg.com/gatsby-plugin-svgr/-/gatsby-plugin-svgr-3.0.0-beta.0.tgz#7e5315f51dae2663a447899322ea1487cef93dd6" integrity sha512-oALTh6VwO6l3khgC/vGr706aqt38EkXwdr6iXVei/auOKGxpCLEuDCQVal1a4SpYXdjHjRsEyab6bxaHL2lzsA== -gatsby-plugin-typescript@^4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/gatsby-plugin-typescript/-/gatsby-plugin-typescript-4.10.0.tgz#ab518d6cca48cfc0b19ab56ea778ed57ba0e7e52" - integrity sha512-g6vbADv5+MRuNBkyvzpjzr2uwrkoNi/K+dAI2gcLdKQoITj6ZDTR9iB4yMF1s23XshlkwwN8+3/3VUiR1fguoQ== +gatsby-plugin-typescript@^4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-typescript/-/gatsby-plugin-typescript-4.10.1.tgz#1d94532f4cd97677c38bda3b4d92a50b3856e11d" + integrity sha512-yQZYRAZwtj20OrvsF8+xr9V0Jew//3HghM1LKvCB58wECvwLW9SXHzema92JubirFOk7VrdeQfVe3u4jCYDDYw== dependencies: "@babel/core" "^7.15.5" "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" @@ -6427,16 +6413,16 @@ gatsby-plugin-typescript@^4.10.0: "@babel/plugin-proposal-optional-chaining" "^7.14.5" "@babel/preset-typescript" "^7.15.0" "@babel/runtime" "^7.15.4" - babel-plugin-remove-graphql-queries "^4.10.0" + babel-plugin-remove-graphql-queries "^4.10.1" -gatsby-plugin-utils@^3.4.1: - version "3.4.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.4.1.tgz#14c9cff75af32a32860575069af44bdabc8f65d9" - integrity sha512-sDMVGauxMgXyX8WGZDndZI2vIaolJzlXBMdKhgP7DIT+Qa5wjvyHWvZy34dxtVrT3IHPK/PRMgpE81Gr7gKveg== +gatsby-plugin-utils@^3.4.1, gatsby-plugin-utils@^3.4.2: + version "3.4.2" + resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.4.2.tgz#bdc66fd52c052c91af443981e1facbc097429dc7" + integrity sha512-HkVR8BnEdc915pmY2L9wPwFgjq303ThMH9UtT+frDOPzn+GFjPlBF5+YGJ3tZaxH0ouwpnGTn3Pu37tcRZcctA== dependencies: "@babel/runtime" "^7.15.4" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" gatsby-sharp "^0.4.0" graphql-compose "^9.0.7" import-from "^4.0.0" @@ -6477,10 +6463,10 @@ gatsby-source-filesystem@4.10.0: valid-url "^1.0.9" xstate "^4.26.1" -gatsby-telemetry@^3.10.0: - version "3.10.0" - resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.0.tgz#917a4914e531d401ecf98ac87d29128b30bfab13" - integrity sha512-Oe2OShJbylKr5C4FTl2P/JUX/xRkpYb6IMfEoAd5inG7HNQ1fikON4NdwvJjOp++My4kWo+LLCu92TZBkyTtZw== +gatsby-telemetry@^3.10.0, gatsby-telemetry@^3.10.1: + version "3.10.1" + resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.1.tgz#129c4309811cd9b2ba5e9d326ba47dddb59202ca" + integrity sha512-935quI1YsQfzYREuvPLNKBb7IUE2vX9p7WoS7Dc9TbV2xDZPTAzeOfX+HE56ZltkxMi8Zivp7mqe5+n//WL7EQ== dependencies: "@babel/code-frame" "^7.14.0" "@babel/runtime" "^7.15.4" @@ -6490,7 +6476,7 @@ gatsby-telemetry@^3.10.0: boxen "^4.2.0" configstore "^5.0.1" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.0" + gatsby-core-utils "^3.10.1" git-up "^4.0.5" is-docker "^2.2.1" lodash "^4.17.21" @@ -6520,18 +6506,18 @@ gatsby-transformer-yaml@4.10.0: lodash "^4.17.21" unist-util-select "^1.5.0" -gatsby-worker@^1.10.0: - version "1.10.0" - resolved "https://registry.yarnpkg.com/gatsby-worker/-/gatsby-worker-1.10.0.tgz#19b958656c7a0ff2b52f24cf99b7c08131f5fa04" - integrity sha512-s4y3bI2ltbfm+hBI9OgDRkrtTIgiHW97DnbikzZtF0lgclqDh/7vhFvTjKGejObR/dbV28t+SAMJLzd9klrgog== +gatsby-worker@^1.10.1: + version "1.10.1" + resolved "https://registry.yarnpkg.com/gatsby-worker/-/gatsby-worker-1.10.1.tgz#d2549c9854effe3319bd4bd199be0a5c4d077af2" + integrity sha512-1bHZjWEKppJSLfuRGYIYhHZt9vYffptMPRs3zmrYBocmZcJvq0eNhTIXUvThbhP+2XHqAPHHBUcyKCwlWlMAzA== dependencies: "@babel/core" "^7.15.5" "@babel/runtime" "^7.15.4" -gatsby@4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-4.10.1.tgz#b00f0454baffebfe38de10aeb4db8aa6e39a5e4a" - integrity sha512-UCapYjofrdxa3bIjMUN0Y+EUIEHNX/srOonv03UeZRKHshwAPe6g1eZfXK4iFNy8LxNsH947D5hLN63pNK77zg== +gatsby@4.10.3: + version "4.10.3" + resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-4.10.3.tgz#72d9620d3f9a90c96e568f4803f86458d1dc6a53" + integrity sha512-G6YYwQWrN99KhJgLQl/oy3oKRuTdUcW7Bgb9vRchjY/Apk0eTA2wq33W5L9y+npR3nxly6ZJ2pM8FHw7WX4tKg== dependencies: "@babel/code-frame" "^7.14.0" "@babel/core" "^7.15.5" @@ -6558,8 +6544,8 @@ gatsby@4.10.1: babel-plugin-add-module-exports "^1.0.4" babel-plugin-dynamic-import-node "^2.3.3" babel-plugin-lodash "^3.3.4" - babel-plugin-remove-graphql-queries "^4.10.0" - babel-preset-gatsby "^2.10.0" + babel-plugin-remove-graphql-queries "^4.10.1" + babel-preset-gatsby "^2.10.1" better-opn "^2.1.1" bluebird "^3.7.2" body-parser "^1.19.0" @@ -6578,7 +6564,6 @@ gatsby@4.10.1: date-fns "^2.25.0" debug "^3.2.7" deepmerge "^4.2.2" - del "^5.1.0" detect-port "^1.3.0" devcert "^1.2.0" dotenv "^8.6.0" @@ -6602,20 +6587,21 @@ gatsby@4.10.1: find-cache-dir "^3.3.2" fs-exists-cached "1.0.0" fs-extra "^10.0.0" - gatsby-cli "^4.10.1" - gatsby-core-utils "^3.10.0" + gatsby-cli "^4.10.2" + gatsby-core-utils "^3.10.1" gatsby-graphiql-explorer "^2.10.0" gatsby-legacy-polyfills "^2.10.0" - gatsby-link "^4.10.0" - gatsby-page-utils "^2.10.0" + gatsby-link "^4.10.1" + gatsby-page-utils "^2.10.1" gatsby-parcel-config "^0.1.0" - gatsby-plugin-page-creator "^4.10.1" - gatsby-plugin-typescript "^4.10.0" - gatsby-plugin-utils "^3.4.1" + gatsby-plugin-page-creator "^4.10.2" + gatsby-plugin-typescript "^4.10.1" + gatsby-plugin-utils "^3.4.2" gatsby-react-router-scroll "^5.10.0" - gatsby-telemetry "^3.10.0" - gatsby-worker "^1.10.0" + gatsby-telemetry "^3.10.1" + gatsby-worker "^1.10.1" glob "^7.2.0" + globby "^11.1.0" got "^11.8.2" graphql "^15.7.2" graphql-compose "^9.0.7" @@ -6908,21 +6894,7 @@ globby@11.0.3: merge2 "^1.3.0" slash "^3.0.0" -globby@^10.0.1: - version "10.0.2" - resolved "https://registry.yarnpkg.com/globby/-/globby-10.0.2.tgz#277593e745acaa4646c3ab411289ec47a0392543" - integrity sha512-7dUi7RvCoT/xast/o/dLN53oqND4yk0nsHkhRgn9w65C4PofCLOoJ39iSOg+qVDdWQPIEj+eszMHQ+aLVwwQSg== - dependencies: - "@types/glob" "^7.1.1" - array-union "^2.1.0" - dir-glob "^3.0.1" - fast-glob "^3.0.3" - glob "^7.1.3" - ignore "^5.1.1" - merge2 "^1.2.3" - slash "^3.0.0" - -globby@^11.0.3, globby@^11.0.4: +globby@^11.0.3, globby@^11.0.4, globby@^11.1.0: version "11.1.0" resolved "https://registry.yarnpkg.com/globby/-/globby-11.1.0.tgz#bd4be98bb042f83d796f7e3811991fbe82a0d34b" integrity sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g== @@ -6968,7 +6940,7 @@ got@^9.6.0: to-readable-stream "^1.0.0" url-parse-lax "^3.0.0" -graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.2.0, graceful-fs@^4.2.2, graceful-fs@^4.2.3, graceful-fs@^4.2.4, graceful-fs@^4.2.9: +graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.2.0, graceful-fs@^4.2.3, graceful-fs@^4.2.4, graceful-fs@^4.2.9: version "4.2.9" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.9.tgz#041b05df45755e587a24942279b9d113146e1c96" integrity sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ== @@ -7301,7 +7273,7 @@ ignore@^4.0.6: resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg== -ignore@^5.1.1, ignore@^5.1.4, ignore@^5.1.8, ignore@^5.2.0: +ignore@^5.1.4, ignore@^5.1.8, ignore@^5.2.0: version "5.2.0" resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.0.tgz#6d3bac8fa7fe0d45d9f9be7bac2fc279577e345a" integrity sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ== @@ -7661,12 +7633,7 @@ is-obj@^2.0.0: resolved "https://registry.yarnpkg.com/is-obj/-/is-obj-2.0.0.tgz#473fb05d973705e3fd9620545018ca8e22ef4982" integrity sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w== -is-path-cwd@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/is-path-cwd/-/is-path-cwd-2.2.0.tgz#67d43b82664a7b5191fd9119127eb300048a9fdb" - integrity sha512-w942bTcih8fdJPJmQHFzkS76NEP8Kzzvmw92cXsazb8intwLqPibPPdXf4ANdKV3rYMuuQYGIWtvz9JilB3NFQ== - -is-path-inside@^3.0.1, is-path-inside@^3.0.2: +is-path-inside@^3.0.2: version "3.0.3" resolved "https://registry.yarnpkg.com/is-path-inside/-/is-path-inside-3.0.3.tgz#d231362e53a07ff2b0e0ea7fed049161ffd16283" integrity sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ== @@ -8562,7 +8529,7 @@ merge-stream@^2.0.0: resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-2.0.0.tgz#52823629a14dd00c9770fb6ad47dc6310f2c1f60" integrity sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w== -merge2@^1.2.3, merge2@^1.3.0, merge2@^1.4.1: +merge2@^1.3.0, merge2@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/merge2/-/merge2-1.4.1.tgz#4368892f885e907455a6fd7dc55c0c9d404990ae" integrity sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg== @@ -8831,10 +8798,10 @@ nano-css@^5.3.1: stacktrace-js "^2.0.2" stylis "^4.0.6" -nanoid@3.3.1, nanoid@^3.3.1: - version "3.3.1" - resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.1.tgz#6347a18cac88af88f58af0b3594b723d5e99bb35" - integrity sha512-n6Vs/3KGyxPQd6uO0eH4Bv0ojGSUvuLlIHtC3Y0kEO23YRge8H9x1GCzLn28YX0H66pMkxuaeESFq4tKISKwdw== +nanoid@3.3.2, nanoid@^3.3.1: + version "3.3.2" + resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.2.tgz#c89622fafb4381cd221421c69ec58547a1eec557" + integrity sha512-CuHBogktKwpm5g2sRgv83jEy2ijFzBwMoYA60orPDR7ynsLijJDqgsi4RDGj3OJpy3Ieb+LYwiRmIOGyytgITA== nanomatch@^1.2.9: version "1.2.13" @@ -9306,13 +9273,6 @@ p-locate@^4.1.0: dependencies: p-limit "^2.2.0" -p-map@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/p-map/-/p-map-3.0.0.tgz#d704d9af8a2ba684e2600d9a215983d4141a979d" - integrity sha512-d3qXVTF/s+W+CdJ5A29wywV2n8CQQYahlgz2bFiA+4eVNJbHJodPZ+/gXwPGh0bOqA+j8S+6+ckmvLGPk1QpxQ== - dependencies: - aggregate-error "^3.0.0" - p-map@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/p-map/-/p-map-4.0.0.tgz#bb2f95a5eda2ec168ec9274e06a747c3e2904d2b" @@ -9940,10 +9900,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.6.0: - version "2.6.0" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.0.tgz#12f8f504c4d8ddb76475f441337542fa799207d4" - integrity sha512-m2FgJibYrBGGgQXNzfd0PuDGShJgRavjUoRCw1mZERIWVSXF0iLzLm+aOqTAbLnC3n6JzUhAA8uZnFVghHJ86A== +prettier@2.6.1: + version "2.6.1" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.1.tgz#d472797e0d7461605c1609808e27b80c0f9cfe17" + integrity sha512-8UVbTBYGwN37Bs9LERmxCPjdvPxlEowx2urIL6urHzdb3SDq4B/Z6xLFCblrSnE4iKWcS6ziJ3aOYrc1kz/E2A== pretty-bytes@^5.4.1, pretty-bytes@^5.6.0: version "5.6.0" From 9b257d6d62da796cc07c3b7e914e8c1734e66818 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 13:24:01 +0000 Subject: [PATCH 066/240] build(deps-dev): bump eslint-config-next in /packages/dashboard Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 12.1.0 to 12.1.1. - [Release notes](https://github.com/vercel/next.js/releases) - [Changelog](https://github.com/vercel/next.js/blob/canary/release.js) - [Commits](https://github.com/vercel/next.js/commits/v12.1.1/packages/eslint-config-next) --- updated-dependencies: - dependency-name: eslint-config-next dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 199 +++++++++++++++++--------------- 2 files changed, 105 insertions(+), 96 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index b6db2dc5..bf517f01 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -36,7 +36,7 @@ "@tailwindcss/typography": "0.5.2", "autoprefixer": "10.4.4", "eslint": "8.12.0", - "eslint-config-next": "12.1.0", + "eslint-config-next": "12.1.1", "postcss": "8.4.12", "prettier": "2.6.1", "tailwindcss": "3.0.23" diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 3e4f20c6..98664b3f 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -82,10 +82,10 @@ resolved "https://registry.yarnpkg.com/@next/env/-/env-12.1.1.tgz#8a927397697ee9d94852feb5fed57a813d299979" integrity sha512-VmTRkfo/IXOQCATndjW3OjKb8zmAuB07eDdzO9XvuXZP87SyvnCYw3jrhUuFhOe/FVsKiloafa5LJfToUpvjUQ== -"@next/eslint-plugin-next@12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@next/eslint-plugin-next/-/eslint-plugin-next-12.1.0.tgz#32586a11378b3ffa5a93ac40a3c44ad99d70e95a" - integrity sha512-WFiyvSM2G5cQmh32t/SiQuJ+I2O+FHVlK/RFw5b1565O2kEM/36EXncjt88Pa+X5oSc+1SS+tWxowWJd1lqI+g== +"@next/eslint-plugin-next@12.1.1": + version "12.1.1" + resolved "https://registry.yarnpkg.com/@next/eslint-plugin-next/-/eslint-plugin-next-12.1.1.tgz#e3e51503e9d7f987a0e080344648bc84ac1e8eb8" + integrity sha512-5hd1VFWZzECADhvA+OE+g0CnrRBFZbPm03HbiUtpk7XeluNn7xVxBU6XvNQA+YrQ7qe5jCK9q7R8MbI9R55Y/Q== dependencies: glob "7.1.7" @@ -170,10 +170,10 @@ "@nodelib/fs.scandir" "2.1.5" fastq "^1.6.0" -"@rushstack/eslint-patch@^1.0.8": - version "1.1.0" - resolved "https://registry.yarnpkg.com/@rushstack/eslint-patch/-/eslint-patch-1.1.0.tgz#7f698254aadf921e48dda8c0a6b304026b8a9323" - integrity sha512-JLo+Y592QzIE+q7Dl2pMUtt4q8SKYI5jDrZxrozEQxnGVOyYE+GWK9eLkwTaeN9DDctlaRAQ3TBmzZ1qdLE30A== +"@rushstack/eslint-patch@1.0.8": + version "1.0.8" + resolved "https://registry.yarnpkg.com/@rushstack/eslint-patch/-/eslint-patch-1.0.8.tgz#be3e914e84eacf16dbebd311c0d0b44aa1174c64" + integrity sha512-ZK5v4bJwgXldAUA8r3q9YKfCwOqoHTK/ZqRjSeRXQrBXWouoPnS4MQtgC4AXGiiBuUu5wxrRgTlv0ktmM4P1Aw== "@stripe/react-stripe-js@1.7.0": version "1.7.0" @@ -223,48 +223,48 @@ resolved "https://registry.yarnpkg.com/@types/parse-json/-/parse-json-4.0.0.tgz#2f8bb441434d163b35fb8ffdccd7138927ffb8c0" integrity sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA== -"@typescript-eslint/parser@^5.0.0": - version "5.6.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.6.0.tgz#11677324659641400d653253c03dcfbed468d199" - integrity sha512-YVK49NgdUPQ8SpCZaOpiq1kLkYRPMv9U5gcMrywzI8brtwZjr/tG3sZpuHyODt76W/A0SufNjYt9ZOgrC4tLIQ== +"@typescript-eslint/parser@5.10.1": + version "5.10.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.10.1.tgz#4ce9633cc33fc70bc13786cb793c1a76fe5ad6bd" + integrity sha512-GReo3tjNBwR5RnRO0K2wDIDN31cM3MmDtgyQ85oAxAmC5K3j/g85IjP+cDfcqDsDDBf1HNKQAD0WqOYL8jXqUA== dependencies: - "@typescript-eslint/scope-manager" "5.6.0" - "@typescript-eslint/types" "5.6.0" - "@typescript-eslint/typescript-estree" "5.6.0" + "@typescript-eslint/scope-manager" "5.10.1" + "@typescript-eslint/types" "5.10.1" + "@typescript-eslint/typescript-estree" "5.10.1" debug "^4.3.2" -"@typescript-eslint/scope-manager@5.6.0": - version "5.6.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.6.0.tgz#9dd7f007dc8f3a34cdff6f79f5eaab27ae05157e" - integrity sha512-1U1G77Hw2jsGWVsO2w6eVCbOg0HZ5WxL/cozVSTfqnL/eB9muhb8THsP0G3w+BB5xAHv9KptwdfYFAUfzcIh4A== +"@typescript-eslint/scope-manager@5.10.1": + version "5.10.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.10.1.tgz#f0539c73804d2423506db2475352a4dec36cd809" + integrity sha512-Lyvi559Gvpn94k7+ElXNMEnXu/iundV5uFmCUNnftbFrUbAJ1WBoaGgkbOBm07jVZa682oaBU37ao/NGGX4ZDg== dependencies: - "@typescript-eslint/types" "5.6.0" - "@typescript-eslint/visitor-keys" "5.6.0" + "@typescript-eslint/types" "5.10.1" + "@typescript-eslint/visitor-keys" "5.10.1" -"@typescript-eslint/types@5.6.0": - version "5.6.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.6.0.tgz#745cb1b59daadcc1f32f7be95f0f68accf38afdd" - integrity sha512-OIZffked7mXv4mXzWU5MgAEbCf9ecNJBKi+Si6/I9PpTaj+cf2x58h2oHW5/P/yTnPkKaayfjhLvx+crnl5ubA== +"@typescript-eslint/types@5.10.1": + version "5.10.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.10.1.tgz#dca9bd4cb8c067fc85304a31f38ec4766ba2d1ea" + integrity sha512-ZvxQ2QMy49bIIBpTqFiOenucqUyjTQ0WNLhBM6X1fh1NNlYAC6Kxsx8bRTY3jdYsYg44a0Z/uEgQkohbR0H87Q== -"@typescript-eslint/typescript-estree@5.6.0": - version "5.6.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.6.0.tgz#dfbb19c9307fdd81bd9c650c67e8397821d7faf0" - integrity sha512-92vK5tQaE81rK7fOmuWMrSQtK1IMonESR+RJR2Tlc7w4o0MeEdjgidY/uO2Gobh7z4Q1hhS94Cr7r021fMVEeA== +"@typescript-eslint/typescript-estree@5.10.1": + version "5.10.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.10.1.tgz#b268e67be0553f8790ba3fe87113282977adda15" + integrity sha512-PwIGnH7jIueXv4opcwEbVGDATjGPO1dx9RkUl5LlHDSe+FXxPwFL5W/qYd5/NHr7f6lo/vvTrAzd0KlQtRusJQ== dependencies: - "@typescript-eslint/types" "5.6.0" - "@typescript-eslint/visitor-keys" "5.6.0" + "@typescript-eslint/types" "5.10.1" + "@typescript-eslint/visitor-keys" "5.10.1" debug "^4.3.2" globby "^11.0.4" is-glob "^4.0.3" semver "^7.3.5" tsutils "^3.21.0" -"@typescript-eslint/visitor-keys@5.6.0": - version "5.6.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.6.0.tgz#3e36509e103fe9713d8f035ac977235fd63cb6e6" - integrity sha512-1p7hDp5cpRFUyE3+lvA74egs+RWSgumrBpzBCDzfTFv0aQ7lIeay80yU0hIxgAhwQ6PcasW35kaOCyDOv6O/Ng== +"@typescript-eslint/visitor-keys@5.10.1": + version "5.10.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.10.1.tgz#29102de692f59d7d34ecc457ed59ab5fc558010b" + integrity sha512-NjQ0Xinhy9IL979tpoTRuLKxMc0zJC7QVSdeerXs2/QvOy2yRkzX5dRb10X5woNUdJgU8G3nYRDlI33sq1K4YQ== dependencies: - "@typescript-eslint/types" "5.6.0" + "@typescript-eslint/types" "5.10.1" eslint-visitor-keys "^3.0.0" acorn-jsx@^5.3.1: @@ -643,7 +643,7 @@ debug@^3.2.7: dependencies: ms "^2.1.1" -debug@^4.1.1, debug@^4.3.1, debug@^4.3.2: +debug@^4.1.1, debug@^4.3.2: version "4.3.3" resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.3.tgz#04266e0b70a98d4462e6e288e38259213332b664" integrity sha512-/zxw5+vh1Tfv+4Qn7a5nsbcJKPaSvCDhojn6FEl9vupwK2VCSDtEiEtqr8DFtzYFOdz63LBkxec7DYuc2jon6Q== @@ -786,22 +786,30 @@ escape-string-regexp@^4.0.0: resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== -eslint-config-next@12.1.0: - version "12.1.0" - resolved "https://registry.yarnpkg.com/eslint-config-next/-/eslint-config-next-12.1.0.tgz#8ace680dc5207e6ab6c915f3989adec122f582e7" - integrity sha512-tBhuUgoDITcdcM7xFvensi9I5WTI4dnvH4ETGRg1U8ZKpXrZsWQFdOKIDzR3RLP5HR3xXrLviaMM4c3zVoE/pA== +eslint-config-next@12.1.1: + version "12.1.1" + resolved "https://registry.yarnpkg.com/eslint-config-next/-/eslint-config-next-12.1.1.tgz#11f948c5f4959267c2157dff8f2c28d067e3e1d9" + integrity sha512-+Ql9F07Pafs+cDgy8Zp0F8FxCBq7ke02ZyC2/MMEiGAX+WlnuUCrboBDnfzmHJpAAkcBPjUthunu6LBnF9KWIQ== dependencies: - "@next/eslint-plugin-next" "12.1.0" - "@rushstack/eslint-patch" "^1.0.8" - "@typescript-eslint/parser" "^5.0.0" - eslint-import-resolver-node "^0.3.4" - eslint-import-resolver-typescript "^2.4.0" - eslint-plugin-import "^2.25.2" - eslint-plugin-jsx-a11y "^6.5.1" - eslint-plugin-react "^7.27.0" - eslint-plugin-react-hooks "^4.3.0" + "@next/eslint-plugin-next" "12.1.1" + "@rushstack/eslint-patch" "1.0.8" + "@typescript-eslint/parser" "5.10.1" + eslint-import-resolver-node "0.3.4" + eslint-import-resolver-typescript "2.4.0" + eslint-plugin-import "2.25.2" + eslint-plugin-jsx-a11y "6.5.1" + eslint-plugin-react "7.29.1" + eslint-plugin-react-hooks "4.3.0" -eslint-import-resolver-node@^0.3.4, eslint-import-resolver-node@^0.3.6: +eslint-import-resolver-node@0.3.4: + version "0.3.4" + resolved "https://registry.yarnpkg.com/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.4.tgz#85ffa81942c25012d8231096ddf679c03042c717" + integrity sha512-ogtf+5AB/O+nM6DIeBUNr2fuT7ot9Qg/1harBfBtaP13ekEWFQEEMP94BCB7zaNW3gyY+8SHYF00rnqYwXKWOA== + dependencies: + debug "^2.6.9" + resolve "^1.13.1" + +eslint-import-resolver-node@^0.3.6: version "0.3.6" resolved "https://registry.yarnpkg.com/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.6.tgz#4048b958395da89668252001dbd9eca6b83bacbd" integrity sha512-0En0w03NRVMn9Uiyn8YRPDKvWjxCWkslUEhGNTdGx15RvPJYQ+lbOlqrlNI2vEAs4pDYK4f/HN2TbDmk5TP0iw== @@ -809,46 +817,45 @@ eslint-import-resolver-node@^0.3.4, eslint-import-resolver-node@^0.3.6: debug "^3.2.7" resolve "^1.20.0" -eslint-import-resolver-typescript@^2.4.0: - version "2.5.0" - resolved "https://registry.yarnpkg.com/eslint-import-resolver-typescript/-/eslint-import-resolver-typescript-2.5.0.tgz#07661966b272d14ba97f597b51e1a588f9722f0a" - integrity sha512-qZ6e5CFr+I7K4VVhQu3M/9xGv9/YmwsEXrsm3nimw8vWaVHRDrQRp26BgCypTxBp3vUp4o5aVEJRiy0F2DFddQ== +eslint-import-resolver-typescript@2.4.0: + version "2.4.0" + resolved "https://registry.yarnpkg.com/eslint-import-resolver-typescript/-/eslint-import-resolver-typescript-2.4.0.tgz#ec1e7063ebe807f0362a7320543aaed6fe1100e1" + integrity sha512-useJKURidCcldRLCNKWemr1fFQL1SzB3G4a0li6lFGvlc5xGe1hY343bvG07cbpCzPuM/lK19FIJB3XGFSkplA== dependencies: - debug "^4.3.1" - glob "^7.1.7" + debug "^4.1.1" + glob "^7.1.6" is-glob "^4.0.1" - resolve "^1.20.0" + resolve "^1.17.0" tsconfig-paths "^3.9.0" -eslint-module-utils@^2.7.1: - version "2.7.1" - resolved "https://registry.yarnpkg.com/eslint-module-utils/-/eslint-module-utils-2.7.1.tgz#b435001c9f8dd4ab7f6d0efcae4b9696d4c24b7c" - integrity sha512-fjoetBXQZq2tSTWZ9yWVl2KuFrTZZH3V+9iD1V1RfpDgxzJR+mPd/KZmMiA8gbPqdBzpNiEHOuT7IYEWxrH0zQ== +eslint-module-utils@^2.7.0: + version "2.7.3" + resolved "https://registry.yarnpkg.com/eslint-module-utils/-/eslint-module-utils-2.7.3.tgz#ad7e3a10552fdd0642e1e55292781bd6e34876ee" + integrity sha512-088JEC7O3lDZM9xGe0RerkOMd0EjFl+Yvd1jPWIkMT5u3H9+HC34mWWPnqPrN13gieT9pBOO+Qt07Nb/6TresQ== dependencies: debug "^3.2.7" find-up "^2.1.0" - pkg-dir "^2.0.0" -eslint-plugin-import@^2.25.2: - version "2.25.3" - resolved "https://registry.yarnpkg.com/eslint-plugin-import/-/eslint-plugin-import-2.25.3.tgz#a554b5f66e08fb4f6dc99221866e57cfff824766" - integrity sha512-RzAVbby+72IB3iOEL8clzPLzL3wpDrlwjsTBAQXgyp5SeTqqY+0bFubwuo+y/HLhNZcXV4XqTBO4LGsfyHIDXg== +eslint-plugin-import@2.25.2: + version "2.25.2" + resolved "https://registry.yarnpkg.com/eslint-plugin-import/-/eslint-plugin-import-2.25.2.tgz#b3b9160efddb702fc1636659e71ba1d10adbe9e9" + integrity sha512-qCwQr9TYfoBHOFcVGKY9C9unq05uOxxdklmBXLVvcwo68y5Hta6/GzCZEMx2zQiu0woKNEER0LE7ZgaOfBU14g== dependencies: array-includes "^3.1.4" array.prototype.flat "^1.2.5" debug "^2.6.9" doctrine "^2.1.0" eslint-import-resolver-node "^0.3.6" - eslint-module-utils "^2.7.1" + eslint-module-utils "^2.7.0" has "^1.0.3" - is-core-module "^2.8.0" + is-core-module "^2.7.0" is-glob "^4.0.3" minimatch "^3.0.4" object.values "^1.1.5" resolve "^1.20.0" tsconfig-paths "^3.11.0" -eslint-plugin-jsx-a11y@^6.5.1: +eslint-plugin-jsx-a11y@6.5.1: version "6.5.1" resolved "https://registry.yarnpkg.com/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.5.1.tgz#cdbf2df901040ca140b6ec14715c988889c2a6d8" integrity sha512-sVCFKX9fllURnXT2JwLN5Qgo24Ug5NF6dxhkmxsMEUZhXRcGg+X3e1JbJ84YePQKBl5E0ZjAH5Q4rkdcGY99+g== @@ -866,27 +873,27 @@ eslint-plugin-jsx-a11y@^6.5.1: language-tags "^1.0.5" minimatch "^3.0.4" -eslint-plugin-react-hooks@^4.3.0: +eslint-plugin-react-hooks@4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/eslint-plugin-react-hooks/-/eslint-plugin-react-hooks-4.3.0.tgz#318dbf312e06fab1c835a4abef00121751ac1172" integrity sha512-XslZy0LnMn+84NEG9jSGR6eGqaZB3133L8xewQo3fQagbQuGt7a63gf+P1NGKZavEYEC3UXaWEAA/AqDkuN6xA== -eslint-plugin-react@^7.27.0: - version "7.27.1" - resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.27.1.tgz#469202442506616f77a854d91babaae1ec174b45" - integrity sha512-meyunDjMMYeWr/4EBLTV1op3iSG3mjT/pz5gti38UzfM4OPpNc2m0t2xvKCOMU5D6FSdd34BIMFOvQbW+i8GAA== +eslint-plugin-react@7.29.1: + version "7.29.1" + resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.29.1.tgz#6c40bc83142bb63d132a1b3565e2ea655411f800" + integrity sha512-WtzRpHMhsOX05ZrkyaaqmLl2uXGqmYooCfBxftJKlkYdsltiufGgfU7uuoHwR2lBam2Kh/EIVID4aU9e3kbCMA== dependencies: array-includes "^3.1.4" array.prototype.flatmap "^1.2.5" doctrine "^2.1.0" estraverse "^5.3.0" jsx-ast-utils "^2.4.1 || ^3.0.0" - minimatch "^3.0.4" + minimatch "^3.1.2" object.entries "^1.1.5" object.fromentries "^2.0.5" object.hasown "^1.1.0" object.values "^1.1.5" - prop-types "^15.7.2" + prop-types "^15.8.1" resolve "^2.0.0-next.3" semver "^6.3.0" string.prototype.matchall "^4.0.6" @@ -1170,7 +1177,7 @@ glob@7.1.7: once "^1.3.0" path-is-absolute "^1.0.0" -glob@^7.1.3, glob@^7.1.7: +glob@^7.1.3, glob@^7.1.6: version "7.2.0" resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.0.tgz#d15535af7732e02e948f4c41628bd910293f6023" integrity sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q== @@ -1345,14 +1352,7 @@ is-core-module@^2.2.0: dependencies: has "^1.0.3" -is-core-module@^2.8.0: - version "2.8.0" - resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.8.0.tgz#0321336c3d0925e497fd97f5d95cb114a5ccd548" - integrity sha512-vd15qHsaqrRL7dtH6QNuy0ndJmRDrS9HAM1CAiSifNUFv4x1a0CCVsj18hJ1mShxIG6T2i1sO78MkP56r0nYRw== - dependencies: - has "^1.0.3" - -is-core-module@^2.8.1: +is-core-module@^2.7.0, is-core-module@^2.8.1: version "2.8.1" resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.8.1.tgz#f59fdfca701d5879d0a6b100a40aa1560ce27211" integrity sha512-SdNCUs284hr40hFTFP6l0IfZ/RSrMXF3qgoRHd3/79unUTvrFO/JoXwkGm+5J/Oe3E/b5GsnG330uUNgRpu1PA== @@ -1651,6 +1651,13 @@ minimatch@^3.0.4: dependencies: brace-expansion "^1.1.7" +minimatch@^3.1.2: + version "3.1.2" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" + integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== + dependencies: + brace-expansion "^1.1.7" + minimist@^1.1.1, minimist@^1.2.0: version "1.2.6" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" @@ -1890,13 +1897,6 @@ picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.2.3: resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.0.tgz#f1f061de8f6a4bf022892e2d128234fb98302972" integrity sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw== -pkg-dir@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-2.0.0.tgz#f6d5d1109e19d63edf428e0bd57e12777615334b" - integrity sha1-9tXREJ4Z1j7fQo4L1X4Sd3YVM0s= - dependencies: - find-up "^2.1.0" - postcss-js@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/postcss-js/-/postcss-js-4.0.0.tgz#31db79889531b80dc7bc9b0ad283e418dce0ac00" @@ -1975,6 +1975,15 @@ prop-types@^15.7.2: object-assign "^4.1.1" react-is "^16.8.1" +prop-types@^15.8.1: + version "15.8.1" + resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.8.1.tgz#67d87bf1a694f48435cf332c24af10214a3140b5" + integrity sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg== + dependencies: + loose-envify "^1.4.0" + object-assign "^4.1.1" + react-is "^16.13.1" + property-expr@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/property-expr/-/property-expr-2.0.4.tgz#37b925478e58965031bb612ec5b3260f8241e910" @@ -2028,7 +2037,7 @@ react-fast-compare@^2.0.1: resolved "https://registry.yarnpkg.com/react-fast-compare/-/react-fast-compare-2.0.4.tgz#e84b4d455b0fec113e0402c329352715196f81f9" integrity sha512-suNP+J1VU1MWFKcyt7RtjiSWUjvidmQSlqu+eHslq+342xCbGTYmC0mEhPCOHxlW0CywylOC1u2DFAT+bv4dBw== -react-is@^16.7.0, react-is@^16.8.1: +react-is@^16.13.1, react-is@^16.7.0, react-is@^16.8.1: version "16.13.1" resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.13.1.tgz#789729a4dc36de2999dc156dd6c1d9c18cea56a4" integrity sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ== @@ -2088,7 +2097,7 @@ resolve-from@^5.0.0: resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-5.0.0.tgz#c35225843df8f776df21c57557bc087e9dfdfc69" integrity sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw== -resolve@^1.20.0, resolve@^1.22.0: +resolve@^1.13.1, resolve@^1.17.0, resolve@^1.20.0, resolve@^1.22.0: version "1.22.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.0.tgz#5e0b8c67c15df57a89bdbabe603a002f21731198" integrity sha512-Hhtrw0nLeSrFQ7phPp4OOcVjLPIeMnRlr5mcnVuMe7M/7eBn98A3hmFRLoFo3DLZkivSYwhRUJTyPyWAk56WLw== From 26a20a89829448113f19bab112112861bac43310 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 13:26:26 +0000 Subject: [PATCH 067/240] build(deps): bump gatsby-plugin-manifest in /packages/website Bumps [gatsby-plugin-manifest](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-manifest) from 4.10.1 to 4.10.2. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-manifest/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-manifest@4.10.2/packages/gatsby-plugin-manifest) --- updated-dependencies: - dependency-name: gatsby-plugin-manifest dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 4a550a9d..47bb5578 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -16,7 +16,7 @@ "gatsby": "4.10.3", "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.10.1", - "gatsby-plugin-manifest": "4.10.1", + "gatsby-plugin-manifest": "4.10.2", "gatsby-plugin-postcss": "5.10.0", "gatsby-plugin-react-helmet": "5.10.0", "gatsby-plugin-robots-txt": "1.7.0", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index ebdc27b4..42c2ea11 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -3339,7 +3339,7 @@ babel-plugin-polyfill-regenerator@^0.3.0: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" -babel-plugin-remove-graphql-queries@^4.10.0, babel-plugin-remove-graphql-queries@^4.10.1: +babel-plugin-remove-graphql-queries@^4.10.1: version "4.10.1" resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.1.tgz#09357b7afad1d1bf359d97701ba267bf968197f4" integrity sha512-1Irx5lUoQtU56u1hMtrgipjlRsUF4Pz6WDCDNVyTuvcHqlKHQK6pna4igHrdoWhSSgEcbimlxSy6tTvP6bkplg== @@ -6311,14 +6311,14 @@ gatsby-plugin-image@2.10.1: objectFitPolyfill "^2.3.5" prop-types "^15.7.2" -gatsby-plugin-manifest@4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-manifest/-/gatsby-plugin-manifest-4.10.1.tgz#01949125a70bac22f2d8946d5829b49f7f188ca2" - integrity sha512-D4WYQD1gDdyvWt8RYl4OC/i7thPkgtkm+kZW+d1JVpUTu+BrbdPYCIUMGdSrDyKxx3x0bhMmEf9hZW25acew0Q== +gatsby-plugin-manifest@4.10.2: + version "4.10.2" + resolved "https://registry.yarnpkg.com/gatsby-plugin-manifest/-/gatsby-plugin-manifest-4.10.2.tgz#117b44e0e219fa85d6b710d2ed985268d82a1e25" + integrity sha512-2QGrG3qFkUnp0IcxQ+uQS4/jPL4NMHShOEs/7JPsuIJSIdumnG7QYJ9xHbIBb8U5mIFLpeonADYJVbdTsnGtrg== dependencies: "@babel/runtime" "^7.15.4" - gatsby-core-utils "^3.10.0" - gatsby-plugin-utils "^3.4.1" + gatsby-core-utils "^3.10.1" + gatsby-plugin-utils "^3.4.2" semver "^7.3.5" sharp "^0.30.1" @@ -6415,7 +6415,7 @@ gatsby-plugin-typescript@^4.10.1: "@babel/runtime" "^7.15.4" babel-plugin-remove-graphql-queries "^4.10.1" -gatsby-plugin-utils@^3.4.1, gatsby-plugin-utils@^3.4.2: +gatsby-plugin-utils@^3.4.2: version "3.4.2" resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.4.2.tgz#bdc66fd52c052c91af443981e1facbc097429dc7" integrity sha512-HkVR8BnEdc915pmY2L9wPwFgjq303ThMH9UtT+frDOPzn+GFjPlBF5+YGJ3tZaxH0ouwpnGTn3Pu37tcRZcctA== @@ -6463,7 +6463,7 @@ gatsby-source-filesystem@4.10.0: valid-url "^1.0.9" xstate "^4.26.1" -gatsby-telemetry@^3.10.0, gatsby-telemetry@^3.10.1: +gatsby-telemetry@^3.10.1: version "3.10.1" resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.1.tgz#129c4309811cd9b2ba5e9d326ba47dddb59202ca" integrity sha512-935quI1YsQfzYREuvPLNKBb7IUE2vX9p7WoS7Dc9TbV2xDZPTAzeOfX+HE56ZltkxMi8Zivp7mqe5+n//WL7EQ== From fc4ebef90fe4dfe8c752f60985ca5554d255550b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 13:27:36 +0000 Subject: [PATCH 068/240] build(deps): bump @fontsource/source-sans-pro in /packages/website Bumps [@fontsource/source-sans-pro](https://github.com/fontsource/fontsource/tree/HEAD/fonts/google/source-sans-pro) from 4.5.4 to 4.5.6. - [Release notes](https://github.com/fontsource/fontsource/releases) - [Changelog](https://github.com/fontsource/fontsource/blob/main/CHANGELOG.md) - [Commits](https://github.com/fontsource/fontsource/commits/HEAD/fonts/google/source-sans-pro) --- updated-dependencies: - dependency-name: "@fontsource/source-sans-pro" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 4a550a9d..dc438bd2 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -6,7 +6,7 @@ "author": "Skynet Labs.", "dependencies": { "@fontsource/sora": "4.5.5", - "@fontsource/source-sans-pro": "4.5.4", + "@fontsource/source-sans-pro": "4.5.6", "@svgr/webpack": "6.2.1", "bytes": "3.1.2", "classnames": "2.3.1", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index ebdc27b4..a1d7adc0 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -1103,10 +1103,10 @@ resolved "https://registry.yarnpkg.com/@fontsource/sora/-/sora-4.5.5.tgz#25e8e0a11d0a2a861ccce23a94383448c5beaa50" integrity sha512-SeePOM5pvXaa2a1c9VuGPJGmHNcFSUBzVxfHMuQ/FrVeiXvF3XXyPbt68N6QmHK2rAH844BN1Y5zImxqa5ok6g== -"@fontsource/source-sans-pro@4.5.4": - version "4.5.4" - resolved "https://registry.yarnpkg.com/@fontsource/source-sans-pro/-/source-sans-pro-4.5.4.tgz#51510723ff40f446c7800f133e9ae604ae2f38d7" - integrity sha512-+YYw6HRvH9wYE+U2Hvxyossg+MHPApAj7VIjEqaXenNeNQa4U3uPD0e7pc+1Gic3srCQATN15O3S9WSFLXTmwQ== +"@fontsource/source-sans-pro@4.5.6": + version "4.5.6" + resolved "https://registry.yarnpkg.com/@fontsource/source-sans-pro/-/source-sans-pro-4.5.6.tgz#1c74aa0168f0ad851e7c69a5ff25914c7691b6cb" + integrity sha512-MPv0Ye2OmcRD4wQ/7lOkysQpXpWkDSqZ2QHdNNLj7CQVtG03BScLMYQXZbYNhNMbH518tdMFewqDSu+/ikAMTg== "@gatsbyjs/parcel-namer-relative-to-cwd@0.0.2": version "0.0.2" @@ -3339,7 +3339,7 @@ babel-plugin-polyfill-regenerator@^0.3.0: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" -babel-plugin-remove-graphql-queries@^4.10.0, babel-plugin-remove-graphql-queries@^4.10.1: +babel-plugin-remove-graphql-queries@^4.10.1: version "4.10.1" resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.1.tgz#09357b7afad1d1bf359d97701ba267bf968197f4" integrity sha512-1Irx5lUoQtU56u1hMtrgipjlRsUF4Pz6WDCDNVyTuvcHqlKHQK6pna4igHrdoWhSSgEcbimlxSy6tTvP6bkplg== @@ -6463,7 +6463,7 @@ gatsby-source-filesystem@4.10.0: valid-url "^1.0.9" xstate "^4.26.1" -gatsby-telemetry@^3.10.0, gatsby-telemetry@^3.10.1: +gatsby-telemetry@^3.10.1: version "3.10.1" resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.1.tgz#129c4309811cd9b2ba5e9d326ba47dddb59202ca" integrity sha512-935quI1YsQfzYREuvPLNKBb7IUE2vX9p7WoS7Dc9TbV2xDZPTAzeOfX+HE56ZltkxMi8Zivp7mqe5+n//WL7EQ== From 9308e3877b44438ec3476a35ee828d2a19c90129 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Mar 2022 13:30:37 +0000 Subject: [PATCH 069/240] build(deps): bump gatsby-plugin-sitemap in /packages/website Bumps [gatsby-plugin-sitemap](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-sitemap) from 5.10.1 to 5.10.2. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-sitemap/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-sitemap@5.10.2/packages/gatsby-plugin-sitemap) --- updated-dependencies: - dependency-name: gatsby-plugin-sitemap dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 5ca8fa6e..8e125354 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -21,7 +21,7 @@ "gatsby-plugin-react-helmet": "5.10.0", "gatsby-plugin-robots-txt": "1.7.0", "gatsby-plugin-sharp": "4.10.2", - "gatsby-plugin-sitemap": "5.10.1", + "gatsby-plugin-sitemap": "5.10.2", "gatsby-plugin-svgr": "3.0.0-beta.0", "gatsby-source-filesystem": "4.10.1", "gatsby-transformer-sharp": "4.10.0", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index dc1728c5..18a8670d 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -3339,7 +3339,7 @@ babel-plugin-polyfill-regenerator@^0.3.0: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" -babel-plugin-remove-graphql-queries@^4.10.0, babel-plugin-remove-graphql-queries@^4.10.1: +babel-plugin-remove-graphql-queries@^4.10.1: version "4.10.1" resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.1.tgz#09357b7afad1d1bf359d97701ba267bf968197f4" integrity sha512-1Irx5lUoQtU56u1hMtrgipjlRsUF4Pz6WDCDNVyTuvcHqlKHQK6pna4igHrdoWhSSgEcbimlxSy6tTvP6bkplg== @@ -6387,10 +6387,10 @@ gatsby-plugin-sharp@4.10.2: svgo "1.3.2" uuid "3.4.0" -gatsby-plugin-sitemap@5.10.1: - version "5.10.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-sitemap/-/gatsby-plugin-sitemap-5.10.1.tgz#297e9434802e1d829b257ab9627ba581f48cb154" - integrity sha512-EO5GWLhkN3gfOXLX8QlbIepu2Kq1kk4bBgU5M2CjZAyVQhahZAJxdBat7JgLTpKZL4lSJgVSCl9IkeKgHvm+pg== +gatsby-plugin-sitemap@5.10.2: + version "5.10.2" + resolved "https://registry.yarnpkg.com/gatsby-plugin-sitemap/-/gatsby-plugin-sitemap-5.10.2.tgz#208149b900b166c42aa88a5f5436f5c6bf6561e9" + integrity sha512-X6pVbytl/QfdfGrnXAEKPf5vc38WIbclmHYIfbgjXUYA9yckTxnfuYZqkS2YwCmbcUTHG1ugcmXMeBGVo77IBQ== dependencies: "@babel/runtime" "^7.15.4" common-tags "^1.8.2" @@ -6463,7 +6463,7 @@ gatsby-source-filesystem@4.10.1: valid-url "^1.0.9" xstate "^4.26.1" -gatsby-telemetry@^3.10.0, gatsby-telemetry@^3.10.1: +gatsby-telemetry@^3.10.1: version "3.10.1" resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.1.tgz#129c4309811cd9b2ba5e9d326ba47dddb59202ca" integrity sha512-935quI1YsQfzYREuvPLNKBb7IUE2vX9p7WoS7Dc9TbV2xDZPTAzeOfX+HE56ZltkxMi8Zivp7mqe5+n//WL7EQ== From c32457235605112100ba42cf08a7ab797ac59ed5 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Tue, 29 Mar 2022 12:53:21 +0200 Subject: [PATCH 070/240] ensure portal and server api headers on dnslink server --- docker/nginx/Dockerfile | 1 + .../{conf.d => conf.d.templates}/server.dnslink.conf | 9 +++++++++ 2 files changed, 10 insertions(+) rename docker/nginx/{conf.d => conf.d.templates}/server.dnslink.conf (51%) diff --git a/docker/nginx/Dockerfile b/docker/nginx/Dockerfile index 53944d8e..2093872c 100644 --- a/docker/nginx/Dockerfile +++ b/docker/nginx/Dockerfile @@ -16,6 +16,7 @@ COPY nginx.conf /usr/local/openresty/nginx/conf/nginx.conf CMD [ "bash", "-c", \ "./mo < /etc/nginx/conf.d.templates/server.account.conf > /etc/nginx/conf.d/server.account.conf ; \ ./mo < /etc/nginx/conf.d.templates/server.api.conf > /etc/nginx/conf.d/server.api.conf; \ + ./mo < /etc/nginx/conf.d.templates/server.dnslink.conf > /etc/nginx/conf.d/server.dnslink.conf; \ ./mo < /etc/nginx/conf.d.templates/server.hns.conf > /etc/nginx/conf.d/server.hns.conf; \ ./mo < /etc/nginx/conf.d.templates/server.skylink.conf > /etc/nginx/conf.d/server.skylink.conf ; \ while :; do sleep 6h & wait ${!}; /usr/local/openresty/bin/openresty -s reload; done & \ diff --git a/docker/nginx/conf.d/server.dnslink.conf b/docker/nginx/conf.d.templates/server.dnslink.conf similarity index 51% rename from docker/nginx/conf.d/server.dnslink.conf rename to docker/nginx/conf.d.templates/server.dnslink.conf index c35536ea..d42ee245 100644 --- a/docker/nginx/conf.d/server.dnslink.conf +++ b/docker/nginx/conf.d.templates/server.dnslink.conf @@ -12,5 +12,14 @@ server { ssl_certificate /etc/ssl/local-certificate.crt; ssl_certificate_key /etc/ssl/local-certificate.key; + set_by_lua_block $skynet_portal_domain { return "{{PORTAL_DOMAIN}}" } + set_by_lua_block $skynet_server_domain { + -- fall back to portal domain if server domain is not defined + if "{{SERVER_DOMAIN}}" == "" then + return "{{PORTAL_DOMAIN}}" + end + return "{{SERVER_DOMAIN}}" + } + include /etc/nginx/conf.d/server/server.dnslink; } From 6f5fda4d305faba4f21f514308290bf66e24bee4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 29 Mar 2022 15:57:55 +0200 Subject: [PATCH 071/240] feat(dashboard-v2): add portal settings provider --- packages/dashboard-v2/gatsby-browser.js | 11 +- packages/dashboard-v2/gatsby-ssr.js | 11 +- packages/dashboard-v2/package.json | 2 +- .../portal-settings/PortalSettingsContext.js | 9 + .../portal-settings/PortalSettingsProvider.js | 39 ++++ .../src/contexts/portal-settings/index.js | 2 + .../portal-settings/usePortalSettings.js | 5 + .../dashboard-v2/src/services/skynetClient.js | 3 + packages/dashboard-v2/yarn.lock | 168 ++++++++++++++++-- 9 files changed, 229 insertions(+), 21 deletions(-) create mode 100644 packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsContext.js create mode 100644 packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsProvider.js create mode 100644 packages/dashboard-v2/src/contexts/portal-settings/index.js create mode 100644 packages/dashboard-v2/src/contexts/portal-settings/usePortalSettings.js create mode 100644 packages/dashboard-v2/src/services/skynetClient.js diff --git a/packages/dashboard-v2/gatsby-browser.js b/packages/dashboard-v2/gatsby-browser.js index a39bdb48..79b58e24 100644 --- a/packages/dashboard-v2/gatsby-browser.js +++ b/packages/dashboard-v2/gatsby-browser.js @@ -7,13 +7,16 @@ import "@fontsource/source-sans-pro/400.css"; // normal import "@fontsource/source-sans-pro/600.css"; // semibold import "./src/styles/global.css"; import { MODAL_ROOT_ID } from "./src/components/Modal"; +import { PortalSettingsProvider } from "./src/contexts/portal-settings"; export function wrapPageElement({ element, props }) { const Layout = element.type.Layout ?? React.Fragment; return ( - - {element} -
    - + + + {element} +
    + + ); } diff --git a/packages/dashboard-v2/gatsby-ssr.js b/packages/dashboard-v2/gatsby-ssr.js index a39bdb48..79b58e24 100644 --- a/packages/dashboard-v2/gatsby-ssr.js +++ b/packages/dashboard-v2/gatsby-ssr.js @@ -7,13 +7,16 @@ import "@fontsource/source-sans-pro/400.css"; // normal import "@fontsource/source-sans-pro/600.css"; // semibold import "./src/styles/global.css"; import { MODAL_ROOT_ID } from "./src/components/Modal"; +import { PortalSettingsProvider } from "./src/contexts/portal-settings"; export function wrapPageElement({ element, props }) { const Layout = element.type.Layout ?? React.Fragment; return ( - - {element} -
    - + + + {element} +
    + + ); } diff --git a/packages/dashboard-v2/package.json b/packages/dashboard-v2/package.json index 44f7595d..b760bf48 100644 --- a/packages/dashboard-v2/package.json +++ b/packages/dashboard-v2/package.json @@ -39,7 +39,7 @@ "react-dropzone": "^12.0.4", "react-helmet": "^6.1.0", "react-use": "^17.3.2", - "skynet-js": "^3.0.2", + "skynet-js": "4.0.27-beta", "swr": "^1.2.2", "tailwindcss": "^3.0.23", "yup": "^0.32.11" diff --git a/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsContext.js b/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsContext.js new file mode 100644 index 00000000..07e7844c --- /dev/null +++ b/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsContext.js @@ -0,0 +1,9 @@ +import { createContext } from "react"; + +export const defaultSettings = { + areAccountsEnabled: false, + isAuthenticationRequired: true, + isSubscriptionRequired: true, +}; + +export const PortalSettingsContext = createContext(defaultSettings); diff --git a/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsProvider.js b/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsProvider.js new file mode 100644 index 00000000..a5a033c8 --- /dev/null +++ b/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsProvider.js @@ -0,0 +1,39 @@ +import { useEffect, useState } from "react"; +import useSWRImmutable from "swr/immutable"; + +import skynetClient from "../../services/skynetClient"; + +import { defaultSettings, PortalSettingsContext } from "./PortalSettingsContext"; + +const fetcher = async (path) => { + try { + const baseUrl = await skynetClient.portalUrl(); + + return fetch(`${baseUrl}/${path}`).then((response) => response.json()); + } catch (error) { + return fetch(path).then((response) => response.json()); + } +}; + +export const PortalSettingsProvider = ({ children }) => { + const { data, error } = useSWRImmutable("/__internal/do/not/use/accounts", fetcher); + const [loading, setLoading] = useState(true); + const [settings, setSettings] = useState(defaultSettings); + + useEffect(() => { + if (data || error) { + setLoading(false); + } + if (data) { + setSettings({ + areAccountsEnabled: data.enabled, + isAuthenticationRequired: data.auth_required, + isSubscriptionRequired: data.subscription_required, + }); + } + }, [data, error]); + + return ( + {children} + ); +}; diff --git a/packages/dashboard-v2/src/contexts/portal-settings/index.js b/packages/dashboard-v2/src/contexts/portal-settings/index.js new file mode 100644 index 00000000..c560bb5c --- /dev/null +++ b/packages/dashboard-v2/src/contexts/portal-settings/index.js @@ -0,0 +1,2 @@ +export * from "./PortalSettingsProvider"; +export * from "./usePortalSettings"; diff --git a/packages/dashboard-v2/src/contexts/portal-settings/usePortalSettings.js b/packages/dashboard-v2/src/contexts/portal-settings/usePortalSettings.js new file mode 100644 index 00000000..1614eb95 --- /dev/null +++ b/packages/dashboard-v2/src/contexts/portal-settings/usePortalSettings.js @@ -0,0 +1,5 @@ +import { useContext } from "react"; + +import { PortalSettingsContext } from "./PortalSettingsContext"; + +export const usePortalSettings = () => useContext(PortalSettingsContext); diff --git a/packages/dashboard-v2/src/services/skynetClient.js b/packages/dashboard-v2/src/services/skynetClient.js new file mode 100644 index 00000000..0549085c --- /dev/null +++ b/packages/dashboard-v2/src/services/skynetClient.js @@ -0,0 +1,3 @@ +import { SkynetClient } from "skynet-js"; + +export default new SkynetClient("https://skynetpro.net"); // TODO: proper API url diff --git a/packages/dashboard-v2/yarn.lock b/packages/dashboard-v2/yarn.lock index 52cf68b8..30d4e8e8 100644 --- a/packages/dashboard-v2/yarn.lock +++ b/packages/dashboard-v2/yarn.lock @@ -1107,7 +1107,7 @@ core-js-pure "^3.20.2" regenerator-runtime "^0.13.4" -"@babel/runtime@^7.0.0", "@babel/runtime@^7.1.2", "@babel/runtime@^7.10.0", "@babel/runtime@^7.10.2", "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.5", "@babel/runtime@^7.14.8", "@babel/runtime@^7.15.4", "@babel/runtime@^7.16.3", "@babel/runtime@^7.16.7", "@babel/runtime@^7.2.0", "@babel/runtime@^7.3.1", "@babel/runtime@^7.5.0", "@babel/runtime@^7.5.5", "@babel/runtime@^7.7.2", "@babel/runtime@^7.7.6", "@babel/runtime@^7.8.4", "@babel/runtime@^7.9.2": +"@babel/runtime@^7.0.0", "@babel/runtime@^7.1.2", "@babel/runtime@^7.10.0", "@babel/runtime@^7.10.2", "@babel/runtime@^7.12.5", "@babel/runtime@^7.14.8", "@babel/runtime@^7.15.4", "@babel/runtime@^7.16.3", "@babel/runtime@^7.16.7", "@babel/runtime@^7.2.0", "@babel/runtime@^7.3.1", "@babel/runtime@^7.5.0", "@babel/runtime@^7.5.5", "@babel/runtime@^7.7.2", "@babel/runtime@^7.7.6", "@babel/runtime@^7.8.4", "@babel/runtime@^7.9.2": version "7.17.2" resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.17.2.tgz#66f68591605e59da47523c631416b18508779941" integrity sha512-hzeyJyMA1YGdJTuWU0e/j4wKXrU4OMFvY2MSlaI9B7VQb0r5cxTE3EAIS2Q7Tn2RIcDkRvTA/v2JsAEhxe99uw== @@ -2100,6 +2100,19 @@ escape-string-regexp "^2.0.0" lodash.deburr "^4.1.0" +"@skynetlabs/tus-js-client@^2.3.0": + version "2.3.0" + resolved "https://registry.yarnpkg.com/@skynetlabs/tus-js-client/-/tus-js-client-2.3.0.tgz#a14fd4197e2bc4ce8be724967a0e4c17d937cb64" + integrity sha512-piGvPlJh+Bu3Qf08bDlc/TnFLXE81KnFoPgvnsddNwTSLyyspxPFxJmHO5ki6SYyOl3HmUtGPoix+r2M2UpFEA== + dependencies: + buffer-from "^0.1.1" + combine-errors "^3.0.3" + is-stream "^2.0.0" + js-base64 "^2.6.1" + lodash.throttle "^4.1.1" + proper-lockfile "^2.0.1" + url-parse "^1.4.3" + "@storybook/addon-actions@6.4.19", "@storybook/addon-actions@^6.4.19": version "6.4.19" resolved "https://registry.yarnpkg.com/@storybook/addon-actions/-/addon-actions-6.4.19.tgz#10631d9c0a6669810264ea7fac3bff7201553084" @@ -4493,6 +4506,13 @@ async-each@^1.0.1: resolved "https://registry.yarnpkg.com/async-each/-/async-each-1.0.3.tgz#b727dbf87d7651602f06f4d4ac387f47d91b0cbf" integrity sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ== +async-mutex@^0.3.2: + version "0.3.2" + resolved "https://registry.yarnpkg.com/async-mutex/-/async-mutex-0.3.2.tgz#1485eda5bda1b0ec7c8df1ac2e815757ad1831df" + integrity sha512-HuTK7E7MT7jZEh1P9GtRW9+aTWiDWWi9InbZ5hjxrnRa39KS4BW04+xLBhYNS2aXhHUIKZSw3gj4Pn1pj+qGAA== + dependencies: + tslib "^2.3.1" + async-retry-ng@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/async-retry-ng/-/async-retry-ng-2.0.1.tgz#f5285ec1c52654a2ba6a505d0c18b1eadfaebd41" @@ -4558,13 +4578,20 @@ axe-core@^4.3.5: resolved "https://registry.yarnpkg.com/axe-core/-/axe-core-4.4.1.tgz#7dbdc25989298f9ad006645cd396782443757413" integrity sha512-gd1kmb21kwNuWr6BQz8fv6GNECPBnUasepcoLbekws23NVBLODdsClRZ+bQ8+9Uomf3Sm3+Vwn0oYG9NvwnJCw== -axios@^0.21.0, axios@^0.21.1: +axios@^0.21.1: version "0.21.4" resolved "https://registry.yarnpkg.com/axios/-/axios-0.21.4.tgz#c67b90dc0568e5c1cf2b0b858c43ba28e2eda575" integrity sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg== dependencies: follow-redirects "^1.14.0" +axios@^0.26.0: + version "0.26.1" + resolved "https://registry.yarnpkg.com/axios/-/axios-0.26.1.tgz#1ede41c51fcf51bbbd6fd43669caaa4f0495aaa9" + integrity sha512-fPwcX4EvnSHuInCMItEhAGnaSEXRBjtzh9fOtsE6E1G6p7vl7edEeZe11QHf18+6+9gR5PbKV/sGKNaD8YaMeA== + dependencies: + follow-redirects "^1.14.8" + axobject-query@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/axobject-query/-/axobject-query-2.2.0.tgz#943d47e10c0b704aa42275e20edf3722648989be" @@ -4827,6 +4854,11 @@ balanced-match@^1.0.0: resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== +base32-decode@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/base32-decode/-/base32-decode-1.0.0.tgz#2a821d6a664890c872f20aa9aca95a4b4b80e2a7" + integrity sha512-KNWUX/R7wKenwE/G/qFMzGScOgVntOmbE27vvc6GrniDGYb6a5+qWcuoXl8WIOQL7q0TpK7nZDm1Y04Yi3Yn5g== + base32-encode@^1.1.1: version "1.2.0" resolved "https://registry.yarnpkg.com/base32-encode/-/base32-encode-1.2.0.tgz#e150573a5e431af0a998e32bdfde7045725ca453" @@ -5109,6 +5141,11 @@ buffer-equal@0.0.1: resolved "https://registry.yarnpkg.com/buffer-equal/-/buffer-equal-0.0.1.tgz#91bc74b11ea405bc916bc6aa908faafa5b4aac4b" integrity sha1-kbx0sR6kBbyRa8aqkI+q+ltKrEs= +buffer-from@^0.1.1: + version "0.1.2" + resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-0.1.2.tgz#15f4b9bcef012044df31142c14333caf6e0260d0" + integrity sha512-RiWIenusJsmI2KcvqQABB83tLxCByE3upSP8QU3rJDMVFGPWLvPQJt/O1Su9moRWeH7d+Q2HYb68f6+v+tw2vg== + buffer-from@^1.0.0: version "1.1.2" resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" @@ -5670,6 +5707,14 @@ colors@1.4.0: resolved "https://registry.yarnpkg.com/colors/-/colors-1.4.0.tgz#c50491479d4c1bdaed2c9ced32cf7c7dc2360f78" integrity sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA== +combine-errors@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/combine-errors/-/combine-errors-3.0.3.tgz#f4df6740083e5703a3181110c2b10551f003da86" + integrity sha1-9N9nQAg+VwOjGBEQwrEFUfAD2oY= + dependencies: + custom-error-instance "2.1.1" + lodash.uniqby "4.5.0" + combined-stream@^1.0.8: version "1.0.8" resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" @@ -6273,6 +6318,11 @@ csstype@^3.0.2, csstype@^3.0.6: resolved "https://registry.yarnpkg.com/csstype/-/csstype-3.0.10.tgz#2ad3a7bed70f35b965707c092e5f30b327c290e5" integrity sha512-2u44ZG2OcNUO9HDp/Jl8C07x6pU/eTR3ncV91SiK3dhG9TWvRVsCoJw14Ckx5DgWkzGA3waZWO3d7pgqpUI/XA== +custom-error-instance@2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/custom-error-instance/-/custom-error-instance-2.1.1.tgz#3cf6391487a6629a6247eb0ca0ce00081b7e361a" + integrity sha1-PPY5FIemYppiR+sMoM4ACBt+Nho= + cyclist@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/cyclist/-/cyclist-1.0.1.tgz#596e9698fd0c80e12038c2b82d6eb1b35b6224d9" @@ -7893,6 +7943,11 @@ follow-redirects@^1.0.0, follow-redirects@^1.14.0: resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.14.8.tgz#016996fb9a11a100566398b1c6839337d7bfa8fc" integrity sha512-1x0S9UVJHsQprFcEC/qnNzBLcIxsjAV905f/UkQxbclCsoTWlacCNOpQa/anodLl2uaEKFhfWOvM2Qg77+15zA== +follow-redirects@^1.14.8: + version "1.14.9" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.14.9.tgz#dd4ea157de7bfaf9ea9b3fbd85aa16951f78d8d7" + integrity sha512-MQDfihBQYMcyy5dhRDJUHcw7lb2Pv/TuE6xP1vyraLukNDHKbDxDNaOE3NbCAdKQApno+GPRyo1YAp89yCjK4w== + for-in@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" @@ -10202,6 +10257,11 @@ jpeg-js@^0.4.0: resolved "https://registry.yarnpkg.com/jpeg-js/-/jpeg-js-0.4.3.tgz#6158e09f1983ad773813704be80680550eff977b" integrity sha512-ru1HWKek8octvUHFHvE5ZzQ1yAsJmIvRdGWvSoKV52XKyuyYA437QWDttXT8eZXDSbuMpHlLzPDZUPd6idIz+Q== +js-base64@^2.6.1: + version "2.6.4" + resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-2.6.4.tgz#f4e686c5de1ea1f867dbcad3d46d969428df98c4" + integrity sha512-pZe//GGmwJndub7ZghVHz7vjb2LgC1m8B07Au3eYqeqv9emhESByMXxaEgkUkEqJe87oBbSniGYoQNIBklc7IQ== + js-cookie@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/js-cookie/-/js-cookie-2.2.1.tgz#69e106dc5d5806894562902aa5baec3744e9b2b8" @@ -10543,6 +10603,43 @@ lodash-es@^4.17.21: resolved "https://registry.yarnpkg.com/lodash-es/-/lodash-es-4.17.21.tgz#43e626c46e6591b7750beb2b50117390c609e3ee" integrity sha512-mKnC+QJ9pWVzv+C4/U3rRsHapFfHvQFoFB92e52xeyGMcX6/OlIl78je1u8vePzYZSkkogMPJ2yjxxsb89cxyw== +lodash._baseiteratee@~4.7.0: + version "4.7.0" + resolved "https://registry.yarnpkg.com/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz#34a9b5543572727c3db2e78edae3c0e9e66bd102" + integrity sha1-NKm1VDVycnw9sueO2uPA6eZr0QI= + dependencies: + lodash._stringtopath "~4.8.0" + +lodash._basetostring@~4.12.0: + version "4.12.0" + resolved "https://registry.yarnpkg.com/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz#9327c9dc5158866b7fa4b9d42f4638e5766dd9df" + integrity sha1-kyfJ3FFYhmt/pLnUL0Y45XZt2d8= + +lodash._baseuniq@~4.6.0: + version "4.6.0" + resolved "https://registry.yarnpkg.com/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz#0ebb44e456814af7905c6212fa2c9b2d51b841e8" + integrity sha1-DrtE5FaBSveQXGIS+iybLVG4Qeg= + dependencies: + lodash._createset "~4.0.0" + lodash._root "~3.0.0" + +lodash._createset@~4.0.0: + version "4.0.3" + resolved "https://registry.yarnpkg.com/lodash._createset/-/lodash._createset-4.0.3.tgz#0f4659fbb09d75194fa9e2b88a6644d363c9fe26" + integrity sha1-D0ZZ+7CddRlPqeK4imZE02PJ/iY= + +lodash._root@~3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/lodash._root/-/lodash._root-3.0.1.tgz#fba1c4524c19ee9a5f8136b4609f017cf4ded692" + integrity sha1-+6HEUkwZ7ppfgTa0YJ8BfPTe1pI= + +lodash._stringtopath@~4.8.0: + version "4.8.0" + resolved "https://registry.yarnpkg.com/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz#941bcf0e64266e5fc1d66fed0a6959544c576824" + integrity sha1-lBvPDmQmbl/B1m/tCmlZVExXaCQ= + dependencies: + lodash._basetostring "~4.12.0" + lodash.clonedeep@4.5.0: version "4.5.0" resolved "https://registry.yarnpkg.com/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz#e23f3f9c4f8fbdde872529c1071857a086e5ccef" @@ -10603,6 +10700,11 @@ lodash.merge@^4.6.2: resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.2.tgz#558aa53b43b661e1925a0afdfa36a9a1085fe57a" integrity sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ== +lodash.throttle@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/lodash.throttle/-/lodash.throttle-4.1.1.tgz#c23e91b710242ac70c37f1e1cda9274cc39bf2f4" + integrity sha1-wj6RtxAkKscMN/HhzaknTMOb8vQ= + lodash.truncate@^4.4.2: version "4.4.2" resolved "https://registry.yarnpkg.com/lodash.truncate/-/lodash.truncate-4.4.2.tgz#5a350da0b1113b837ecfffd5812cbe58d6eae193" @@ -10613,6 +10715,14 @@ lodash.uniq@4.5.0, lodash.uniq@^4.5.0: resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773" integrity sha1-0CJTc662Uq3BvILklFM5qEJ1R3M= +lodash.uniqby@4.5.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz#a3a17bbf62eeb6240f491846e97c1c4e2a5e1e21" + integrity sha1-o6F7v2LutiQPSRhG6XwcTipeHiE= + dependencies: + lodash._baseiteratee "~4.7.0" + lodash._baseuniq "~4.6.0" + lodash.without@^4.4.0: version "4.4.0" resolved "https://registry.yarnpkg.com/lodash.without/-/lodash.without-4.4.0.tgz#3cd4574a00b67bae373a94b748772640507b7aac" @@ -10969,6 +11079,11 @@ mime@^2.4.4, mime@^2.5.2: resolved "https://registry.yarnpkg.com/mime/-/mime-2.6.0.tgz#a2a682a95cd4d0cb1d6257e28f83da7e35800367" integrity sha512-USPkMeET31rOMiarsBNIHZKLGgvKc/LrjofAnBlOttf5ajRvqiRA8QsenbcooctK6d6Ts6aqZXBA+XbkKthiQg== +mime@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/mime/-/mime-3.0.0.tgz#b374550dca3a0c18443b0c950a6a58f1931cf7a7" + integrity sha512-jSCU7/VB1loIWBZe14aEYHU/+1UMEHoaO7qxCOVJOw9GgH72VAWppxNcjU+x9a2k3GSIBXNKxXQFqRvvZ7vr3A== + mimic-fn@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" @@ -12159,6 +12274,11 @@ posix-character-classes@^0.1.0: resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" integrity sha1-AerA/jta9xoqbAL+q7jB/vfgDqs= +post-me@^0.4.5: + version "0.4.5" + resolved "https://registry.yarnpkg.com/post-me/-/post-me-0.4.5.tgz#6171b721c7b86230c51cfbe48ddea047ef8831ce" + integrity sha512-XgPdktF/2M5jglgVDULr9NUb/QNv3bY3g6RG22iTb5MIMtB07/5FJB5fbVmu5Eaopowc6uZx7K3e7x1shPwnXw== + postcss-calc@^8.2.0: version "8.2.4" resolved "https://registry.yarnpkg.com/postcss-calc/-/postcss-calc-8.2.4.tgz#77b9c29bfcbe8a07ff6693dc87050828889739a5" @@ -12676,6 +12796,14 @@ prop-types@^15.0.0, prop-types@^15.6.0, prop-types@^15.6.1, prop-types@^15.7.2, object-assign "^4.1.1" react-is "^16.13.1" +proper-lockfile@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/proper-lockfile/-/proper-lockfile-2.0.1.tgz#159fb06193d32003f4b3691dd2ec1a634aa80d1d" + integrity sha1-FZ+wYZPTIAP0s2kd0uwaY0qoDR0= + dependencies: + graceful-fs "^4.1.2" + retry "^0.10.0" + proper-lockfile@^4.1.2: version "4.1.2" resolved "https://registry.yarnpkg.com/proper-lockfile/-/proper-lockfile-4.1.2.tgz#c8b9de2af6b2f1601067f98e01ac66baa223141f" @@ -13558,6 +13686,11 @@ ret@~0.1.10: resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" integrity sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg== +retry@^0.10.0: + version "0.10.1" + resolved "https://registry.yarnpkg.com/retry/-/retry-0.10.1.tgz#e76388d217992c252750241d3d3956fed98d8ff4" + integrity sha1-52OI0heZLCUnUCQdPTlW/tmNj/Q= + retry@^0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/retry/-/retry-0.12.0.tgz#1b42a6266a21f07421d1b0b54b7dc167b01c013b" @@ -13957,24 +14090,35 @@ sjcl@^1.0.8: resolved "https://registry.yarnpkg.com/sjcl/-/sjcl-1.0.8.tgz#f2ec8d7dc1f0f21b069b8914a41a8f236b0e252a" integrity sha512-LzIjEQ0S0DpIgnxMEayM1rq9aGwGRG4OnZhCdjx7glTaJtf4zRfpg87ImfjSJjoW9vKpagd82McDOwbRT5kQKQ== -skynet-js@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/skynet-js/-/skynet-js-3.0.2.tgz#d08a33066ee85b86e4ffc7c31591239a88da6fbe" - integrity sha512-rbmpOGbDwg2FcsZ7HkmGhVaUwWO6kaysRFKTBC3yGiV+b6fbnpPPNCskvh8kWwbTsj+koWkSRUFYqG7cc+eTuA== +skynet-js@^4.0.27-beta: + version "4.0.27-beta" + resolved "https://registry.yarnpkg.com/skynet-js/-/skynet-js-4.0.27-beta.tgz#4257bffda8757830656e0beb89d0d2e44da17e2f" + integrity sha512-JV+QE/2l2YwVN1jQHVMFXgggwtBrPAnuyXySbLgafEJAde5dUwSEr5YRMV+3LvEgYkGhxSb74pyq0u0wrF2sUg== dependencies: - "@babel/runtime" "^7.11.2" - axios "^0.21.0" + "@skynetlabs/tus-js-client" "^2.3.0" + async-mutex "^0.3.2" + axios "^0.26.0" + base32-decode "^1.0.0" base32-encode "^1.1.1" base64-js "^1.3.1" blakejs "^1.1.0" buffer "^6.0.1" - mime "^2.5.2" + mime "^3.0.0" path-browserify "^1.0.1" + post-me "^0.4.5" randombytes "^2.1.0" sjcl "^1.0.8" + skynet-mysky-utils "^0.3.0" tweetnacl "^1.0.3" url-join "^4.0.1" - url-parse "^1.4.7" + url-parse "^1.5.1" + +skynet-mysky-utils@^0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/skynet-mysky-utils/-/skynet-mysky-utils-0.3.0.tgz#87fdc0a5f8547cf660280ef86b7a762269919bad" + integrity sha512-X9L6SrVTdwTUFook/E6zUWCOpXHdyspLAu0elQbbPkZCWeFpr/XXTMbiyPV3m1liYsesngAKxzaSqylaTWOGUA== + dependencies: + post-me "^0.4.5" slash@^2.0.0: version "2.0.0" @@ -15061,7 +15205,7 @@ tslib@^1.10.0, tslib@^1.8.1, tslib@^1.9.0: resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== -tslib@^2, tslib@^2.0.0, tslib@^2.0.1, tslib@^2.0.3, tslib@^2.1.0, tslib@^2.3.0, tslib@~2.3.0: +tslib@^2, tslib@^2.0.0, tslib@^2.0.1, tslib@^2.0.3, tslib@^2.1.0, tslib@^2.3.0, tslib@^2.3.1, tslib@~2.3.0: version "2.3.1" resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.3.1.tgz#e8a335add5ceae51aa261d32a490158ef042ef01" integrity sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw== @@ -15419,7 +15563,7 @@ url-parse-lax@^3.0.0: dependencies: prepend-http "^2.0.0" -url-parse@^1.4.7: +url-parse@^1.4.3, url-parse@^1.5.1: version "1.5.10" resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== From ef97adf2fb10f4aef3d0be66546008bcc39f9690 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 29 Mar 2022 16:02:02 +0200 Subject: [PATCH 072/240] feat(dashboard-v2): redirect to /upgrade when unsubscribed user tries to access subscription-only features --- .../FullScreenLoadingIndicator.js | 7 +++++ .../src/components/LoadingIndicator/index.js | 1 + .../src/hooks/useUpgradeRedirect.js | 31 +++++++++++++++++++ .../src/layouts/DashboardLayout.js | 8 ++--- packages/dashboard-v2/src/pages/index.js | 7 +++++ 5 files changed, 48 insertions(+), 6 deletions(-) create mode 100644 packages/dashboard-v2/src/components/LoadingIndicator/FullScreenLoadingIndicator.js create mode 100644 packages/dashboard-v2/src/hooks/useUpgradeRedirect.js diff --git a/packages/dashboard-v2/src/components/LoadingIndicator/FullScreenLoadingIndicator.js b/packages/dashboard-v2/src/components/LoadingIndicator/FullScreenLoadingIndicator.js new file mode 100644 index 00000000..ad261e2e --- /dev/null +++ b/packages/dashboard-v2/src/components/LoadingIndicator/FullScreenLoadingIndicator.js @@ -0,0 +1,7 @@ +import { ContainerLoadingIndicator } from "./ContainerLoadingIndicator"; + +export const FullScreenLoadingIndicator = () => ( +
    + +
    +); diff --git a/packages/dashboard-v2/src/components/LoadingIndicator/index.js b/packages/dashboard-v2/src/components/LoadingIndicator/index.js index df7c2a88..5e7f91f4 100644 --- a/packages/dashboard-v2/src/components/LoadingIndicator/index.js +++ b/packages/dashboard-v2/src/components/LoadingIndicator/index.js @@ -1 +1,2 @@ export * from "./ContainerLoadingIndicator"; +export * from "./FullScreenLoadingIndicator"; diff --git a/packages/dashboard-v2/src/hooks/useUpgradeRedirect.js b/packages/dashboard-v2/src/hooks/useUpgradeRedirect.js new file mode 100644 index 00000000..5529c152 --- /dev/null +++ b/packages/dashboard-v2/src/hooks/useUpgradeRedirect.js @@ -0,0 +1,31 @@ +import { navigate } from "gatsby"; +import { useEffect, useState } from "react"; + +import { usePortalSettings } from "../contexts/portal-settings"; +import { useUser } from "../contexts/user"; +import freeTier from "../lib/tiers"; + +export default function useUpgradeRedirect() { + const [verifyingSubscription, setVerifyingSubscription] = useState(true); + const { user, loading: userDataLoading } = useUser(); + const { settings, loading: portalSettingsLoading } = usePortalSettings(); + + useEffect(() => { + setVerifyingSubscription(true); + const isDataLoaded = !userDataLoading && !portalSettingsLoading && user && settings; + const hasPaidSubscription = user.tier > freeTier.tier; + + if (isDataLoaded) { + if (settings.isSubscriptionRequired && !hasPaidSubscription) { + console.log("redirecting", user, settings); + navigate("/upgrade"); + } else { + setVerifyingSubscription(false); + } + } + }, [user, userDataLoading, settings.isSubscriptionRequired, portalSettingsLoading, settings]); + + return { + verifyingSubscription, + }; +} diff --git a/packages/dashboard-v2/src/layouts/DashboardLayout.js b/packages/dashboard-v2/src/layouts/DashboardLayout.js index b369ece3..76af9218 100644 --- a/packages/dashboard-v2/src/layouts/DashboardLayout.js +++ b/packages/dashboard-v2/src/layouts/DashboardLayout.js @@ -8,7 +8,7 @@ import { PageContainer } from "../components/PageContainer"; import { NavBar } from "../components/Navbar"; import { Footer } from "../components/Footer"; import { UserProvider, useUser } from "../contexts/user"; -import { ContainerLoadingIndicator } from "../components/LoadingIndicator"; +import { FullScreenLoadingIndicator } from "../components/LoadingIndicator"; const Wrapper = styled.div.attrs({ className: "min-h-screen overflow-hidden", @@ -24,11 +24,7 @@ const Layout = ({ children }) => { // Prevent from flashing the dashboard screen to unauthenticated users. return ( - {!user && ( -
    - -
    - )} + {!user && } {user && <>{children}}
    ); diff --git a/packages/dashboard-v2/src/pages/index.js b/packages/dashboard-v2/src/pages/index.js index 4db97e04..1fd88651 100644 --- a/packages/dashboard-v2/src/pages/index.js +++ b/packages/dashboard-v2/src/pages/index.js @@ -12,9 +12,16 @@ import Slider from "../components/Slider/Slider"; import CurrentUsage from "../components/CurrentUsage"; import Uploader from "../components/Uploader/Uploader"; import CurrentPlan from "../components/CurrentPlan"; +import { FullScreenLoadingIndicator } from "../components/LoadingIndicator"; +import useUpgradeRedirect from "../hooks/useUpgradeRedirect"; const IndexPage = () => { const showRecentActivity = useMedia(`(min-width: ${theme.screens.md})`); + const { verifyingSubscription } = useUpgradeRedirect(); + + if (verifyingSubscription) { + return ; + } return ( From 899f963b63c35866420c2eda14aaef0b22ac181b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 29 Mar 2022 16:03:30 +0200 Subject: [PATCH 073/240] feat(dashboard-v2): make PlansProvider compliant with portal settings --- .../src/contexts/plans/PlansProvider.js | 21 ++++++++++++------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/packages/dashboard-v2/src/contexts/plans/PlansProvider.js b/packages/dashboard-v2/src/contexts/plans/PlansProvider.js index c481e296..135c9bcb 100644 --- a/packages/dashboard-v2/src/contexts/plans/PlansProvider.js +++ b/packages/dashboard-v2/src/contexts/plans/PlansProvider.js @@ -1,7 +1,8 @@ import { useEffect, useState } from "react"; -import useSWR from "swr"; +import useSWRImmutable from "swr/immutable"; import freePlan from "../../lib/tiers"; +import { usePortalSettings } from "../portal-settings"; import { PlansContext } from "./PlansContext"; @@ -12,8 +13,9 @@ import { PlansContext } from "./PlansContext"; * * @see https://github.com/SkynetLabs/skynet-accounts/blob/7337e740b71b77e6d08016db801e293b8ad81abc/database/user.go#L53-L101 */ -const aggregatePlansAndLimits = (plans, limits) => { - const sortedPlans = [freePlan, ...plans].sort((planA, planB) => planA.tier - planB.tier); +const aggregatePlansAndLimits = (plans, limits, { includeFreePlan }) => { + const allPlans = includeFreePlan ? [freePlan, ...plans] : [...plans]; + const sortedPlans = allPlans.sort((planA, planB) => planA.tier - planB.tier); // Decorate each plan with its corresponding limits data, if available. if (limits?.length) { @@ -26,10 +28,11 @@ const aggregatePlansAndLimits = (plans, limits) => { }; export const PlansProvider = ({ children }) => { - const { data: rawPlans, error: plansError } = useSWR("stripe/prices"); - const { data: limits, error: limitsError } = useSWR("limits"); + const { settings } = usePortalSettings(); + const { data: rawPlans, error: plansError } = useSWRImmutable("stripe/prices"); + const { data: limits, error: limitsError } = useSWRImmutable("limits"); - const [plans, setPlans] = useState([freePlan]); + const [plans, setPlans] = useState(settings.isSubscriptionRequired ? [] : [freePlan]); const [loading, setLoading] = useState(true); const [error, setError] = useState(null); @@ -39,9 +42,11 @@ export const PlansProvider = ({ children }) => { setError(plansError || limitsError); } else if (rawPlans) { setLoading(false); - setPlans(aggregatePlansAndLimits(rawPlans, limits?.userLimits)); + setPlans( + aggregatePlansAndLimits(rawPlans, limits?.userLimits, { includeFreePlan: !settings.isSubscriptionRequired }) + ); } - }, [rawPlans, limits, plansError, limitsError]); + }, [rawPlans, limits, plansError, limitsError, settings.isSubscriptionRequired]); return {children}; }; From 0604198ca28aae92b232505330a4e554affcb09d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 29 Mar 2022 16:05:20 +0200 Subject: [PATCH 074/240] feat(dashboard-v2): make /upgrade page compliant with portal settings --- .../src/components/Slider/Slider.js | 3 +- packages/dashboard-v2/src/pages/upgrade.js | 35 ++++++++++++++----- 2 files changed, 29 insertions(+), 9 deletions(-) diff --git a/packages/dashboard-v2/src/components/Slider/Slider.js b/packages/dashboard-v2/src/components/Slider/Slider.js index 973b9941..33c3bc2a 100644 --- a/packages/dashboard-v2/src/components/Slider/Slider.js +++ b/packages/dashboard-v2/src/components/Slider/Slider.js @@ -40,7 +40,8 @@ const Slider = ({ slides, breakpoints, scrollerClassName, className }) => { ); React.useEffect(() => { - const maxIndex = slides.length - visibleSlides; + // Prevent negative values for activeIndex. + const maxIndex = Math.max(slides.length - visibleSlides, 0); // Make sure to not scroll too far when screen size changes. if (activeIndex > maxIndex) { diff --git a/packages/dashboard-v2/src/pages/upgrade.js b/packages/dashboard-v2/src/pages/upgrade.js index 894c8273..8e47472e 100644 --- a/packages/dashboard-v2/src/pages/upgrade.js +++ b/packages/dashboard-v2/src/pages/upgrade.js @@ -10,13 +10,11 @@ import { Panel } from "../components/Panel"; import Slider from "../components/Slider/Slider"; import { CheckmarkIcon } from "../components/Icons"; import { Button } from "../components/Button"; +import { usePortalSettings } from "../contexts/portal-settings"; +import { Alert } from "../components/Alert"; +import HighlightedLink from "../components/HighlightedLink"; -const SLIDER_BREAKPOINTS = [ - { - name: "xl", - scrollable: true, - visibleSlides: 4, - }, +const PAID_PORTAL_BREAKPOINTS = [ { name: "lg", scrollable: true, @@ -33,6 +31,15 @@ const SLIDER_BREAKPOINTS = [ }, ]; +const FREE_PORTAL_BREAKPOINTS = [ + { + name: "xl", + scrollable: true, + visibleSlides: 4, + }, + ...PAID_PORTAL_BREAKPOINTS, +]; + const PlanSummaryItem = ({ children }) => (
  • @@ -68,6 +75,7 @@ const localizedNumber = (value) => value.toLocaleString(); const PlansSlider = () => { const { user, error: userError } = useUser(); const { plans, loading, activePlan, error: plansError } = useActivePlan(user); + const { settings } = usePortalSettings(); if (userError || plansError) { return ( @@ -80,6 +88,18 @@ const PlansSlider = () => { return (
    + {settings.isSubscriptionRequired && !activePlan && ( + +

    This Skynet portal requires a paid subscription.

    +

    + If you're not ready for that yet, you can use your account on{" "} + + SkynetFree.net + {" "} + to store up to 100GB for free. +

    +
    + )} {!loading && ( { @@ -114,8 +134,7 @@ const PlansSlider = () => { ); })} - breakpoints={SLIDER_BREAKPOINTS} - scrollerClassName="gap-4 xl:gap-8" + breakpoints={settings.isSubscriptionRequired ? PAID_PORTAL_BREAKPOINTS : FREE_PORTAL_BREAKPOINTS} className="px-8 sm:px-4 md:px-0 lg:px-0" /> )} From 8cdf0f86b27cdc41ee84a14290b2c9189c482693 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 29 Mar 2022 16:07:23 +0200 Subject: [PATCH 075/240] feat(dashboard-v2): prepare /signup page for free & paid portals --- .../src/components/forms/SignUpForm.js | 5 -- .../dashboard-v2/src/pages/auth/signup.js | 62 ++++++++++++++----- 2 files changed, 47 insertions(+), 20 deletions(-) diff --git a/packages/dashboard-v2/src/components/forms/SignUpForm.js b/packages/dashboard-v2/src/components/forms/SignUpForm.js index 976c0c74..6725c673 100644 --- a/packages/dashboard-v2/src/components/forms/SignUpForm.js +++ b/packages/dashboard-v2/src/components/forms/SignUpForm.js @@ -61,11 +61,6 @@ export const SignUpForm = ({ onSuccess, onFailure }) => ( > {({ errors, touched }) => (
    -
    -

    Create your free account

    -

    Includes 100 GB storage at basic speed

    -
    - ( +
    +

    Create your free account

    +

    Includes 100 GB storage at basic speed

    +
    +); + +const PaidPortalHeader = () => ( +
    +

    Create your account

    +

    + If you're looking for a free portal, try{" "} + + SkynetFree.net + {" "} + with 100GB of free storage. +

    +
    +); const State = { Pure: "PURE", @@ -14,34 +36,44 @@ const State = { const SignUpPage = () => { const [state, setState] = useState(State.Pure); + const { settings } = usePortalSettings(); useEffect(() => { if (state === State.Success) { - const timer = setTimeout(() => navigate("/"), 3000); + const timer = setTimeout(() => navigate(settings.isSubscriptionRequired ? "/upgrade" : "/"), 3000); return () => clearTimeout(timer); } - }, [state]); + }, [state, settings.isSubscriptionRequired]); return (
    Skynet
    - {state !== State.Success && ( - setState(State.Success)} onFailure={() => setState(State.Failure)} /> - )} - {state === State.Success && ( -
    -

    Please check your inbox and confirm your email address.

    -

    You will be redirected to your dashboard shortly.

    - Click here to go there now. -
    - )} + {!settings.areAccountsEnabled && Sorry, registrations are currently disabled.} - {state === State.Failure && ( -

    Something went wrong, please try again later.

    + {settings.areAccountsEnabled && ( + <> + {settings.isSubscriptionRequired ? : } + + {state !== State.Success && ( + setState(State.Success)} onFailure={() => setState(State.Failure)} /> + )} + + {state === State.Success && ( +
    +

    Please check your inbox and confirm your email address.

    +

    You will be redirected to your dashboard shortly.

    + Click here to go there now. +
    + )} + + {state === State.Failure && ( +

    Something went wrong, please try again later.

    + )} + )}

    From d3c252a0b04d481e4e555bb8e0d37a6c2fc2e74d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 29 Mar 2022 16:08:26 +0200 Subject: [PATCH 076/240] fix(dashboard-v2): fix race conditions on /login & /logout calls --- .../src/components/NavBar/NavBar.js | 103 ++++++++++-------- .../src/contexts/user/UserProvider.js | 4 +- packages/dashboard-v2/src/lib/swrConfig.js | 11 +- packages/dashboard-v2/src/pages/auth/login.js | 16 ++- 4 files changed, 81 insertions(+), 53 deletions(-) diff --git a/packages/dashboard-v2/src/components/NavBar/NavBar.js b/packages/dashboard-v2/src/components/NavBar/NavBar.js index 65d9afe5..f75030bb 100644 --- a/packages/dashboard-v2/src/components/NavBar/NavBar.js +++ b/packages/dashboard-v2/src/components/NavBar/NavBar.js @@ -2,6 +2,7 @@ import { Link, navigate } from "gatsby"; import styled from "styled-components"; import { screen } from "../../lib/cssHelpers"; +import { useUser } from "../../contexts/user"; import { DropdownMenu, DropdownMenuLink } from "../DropdownMenu"; import { CogIcon, LockClosedIcon, SkynetLogoIcon } from "../Icons"; import { PageContainer } from "../PageContainer"; @@ -49,48 +50,60 @@ const NavBarBody = styled.nav.attrs({ } `; -export const NavBar = () => ( - - - - - - - - - Dashboard - - - Files - - - Payments - - - - - - { - await accountsService.post("logout"); - navigate("/auth/login"); - // TODO: handle errors - }} - activeClassName="text-primary" - className="cursor-pointer" - icon={LockClosedIcon} - label="Log out" - /> - - - - - -); +export const NavBar = () => { + const { mutate: setUserState } = useUser(); + + const onLogout = async () => { + try { + await accountsService.post("logout"); + // Don't refresh user state from server, as it will now respond with UNAUTHORIZED + // and user will be redirected to /auth/login with return_to query param (which we want empty). + await setUserState(null, { revalidate: false }); + navigate("/auth/login"); + } catch { + // Do nothing. + } + }; + + return ( + + + + + + + + + Dashboard + + + Files + + + Payments + + + + + + + + + + + + ); +}; diff --git a/packages/dashboard-v2/src/contexts/user/UserProvider.js b/packages/dashboard-v2/src/contexts/user/UserProvider.js index 4d1efac5..bb10ffe4 100644 --- a/packages/dashboard-v2/src/contexts/user/UserProvider.js +++ b/packages/dashboard-v2/src/contexts/user/UserProvider.js @@ -1,10 +1,10 @@ import { useEffect, useState } from "react"; -import useSWR from "swr"; +import useSWRImmutable from "swr/immutable"; import { UserContext } from "./UserContext"; export const UserProvider = ({ children }) => { - const { data: user, error, mutate } = useSWR("user"); + const { data: user, error, mutate } = useSWRImmutable("user"); const [loading, setLoading] = useState(true); useEffect(() => { diff --git a/packages/dashboard-v2/src/lib/swrConfig.js b/packages/dashboard-v2/src/lib/swrConfig.js index 058b5ead..16e2dbfb 100644 --- a/packages/dashboard-v2/src/lib/swrConfig.js +++ b/packages/dashboard-v2/src/lib/swrConfig.js @@ -15,12 +15,15 @@ const redirectUnauthenticated = (key) => }); const redirectAuthenticated = (key) => - fetch(`${baseUrl}/${key}`).then((response) => { - if (response.status === StatusCodes.OK) { - navigate(`/`); + fetch(`${baseUrl}/${key}`).then(async (response) => { + if (response.ok) { + await navigate("/"); + return response.json(); } - return response.json(); + // If there was an error, let's throw so useSWR's "error" property is populated instead "data". + const data = await response.json(); + throw new Error(data?.message || `Error occured when trying to fetch: ${key}`); }); export const allUsers = { diff --git a/packages/dashboard-v2/src/pages/auth/login.js b/packages/dashboard-v2/src/pages/auth/login.js index e3b5240b..8b0cfbb5 100644 --- a/packages/dashboard-v2/src/pages/auth/login.js +++ b/packages/dashboard-v2/src/pages/auth/login.js @@ -1,19 +1,31 @@ +import { useEffect } from "react"; import { navigate } from "gatsby"; import AuthLayout from "../../layouts/AuthLayout"; - import { LoginForm } from "../../components/forms"; +import { useUser } from "../../contexts/user"; const LoginPage = ({ location }) => { + const { user, mutate: refreshUserState } = useUser(); const query = new URLSearchParams(location.search); const redirectTo = query.get("return_to"); + useEffect(() => { + if (user) { + navigate(redirectTo || "/"); + } + }, [user, redirectTo]); + return (

    Skynet
    - navigate(redirectTo || "/")} /> + { + await refreshUserState(); + }} + />
    ); }; From 51c3d4af94956113c8ac18a7d8dec17ebfe63e4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 29 Mar 2022 16:08:51 +0200 Subject: [PATCH 077/240] refactor(dashboard-v2): use memoized SkynetClient instance --- packages/dashboard-v2/src/components/Uploader/UploaderItem.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/packages/dashboard-v2/src/components/Uploader/UploaderItem.js b/packages/dashboard-v2/src/components/Uploader/UploaderItem.js index 4f47809c..8ea279d6 100644 --- a/packages/dashboard-v2/src/components/Uploader/UploaderItem.js +++ b/packages/dashboard-v2/src/components/Uploader/UploaderItem.js @@ -5,12 +5,10 @@ import { StatusCodes } from "http-status-codes"; import copy from "copy-text-to-clipboard"; import path from "path-browserify"; import { useTimeoutFn } from "react-use"; -import { SkynetClient } from "skynet-js"; import { ProgressBar } from "./ProgressBar"; import UploaderItemIcon from "./UploaderItemIcon"; import buildUploadErrorMessage from "./buildUploadErrorMessage"; - -const skynetClient = new SkynetClient("https://siasky.net"); //TODO: proper API url +import skynetClient from "../../services/skynetClient"; const getFilePath = (file) => file.webkitRelativePath || file.path || file.name; From 36c18e4f6a647fc2e05b9176a800fa0c00e54aaf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 30 Mar 2022 15:35:36 +0200 Subject: [PATCH 078/240] fix: portal-aware amount of free storage on signup page --- .../portal-settings/PortalSettingsContext.js | 4 +- .../dashboard-v2/src/pages/auth/signup.js | 87 +++++++++++-------- 2 files changed, 51 insertions(+), 40 deletions(-) diff --git a/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsContext.js b/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsContext.js index 07e7844c..4c0cf185 100644 --- a/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsContext.js +++ b/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsContext.js @@ -2,8 +2,8 @@ import { createContext } from "react"; export const defaultSettings = { areAccountsEnabled: false, - isAuthenticationRequired: true, - isSubscriptionRequired: true, + isAuthenticationRequired: false, + isSubscriptionRequired: false, }; export const PortalSettingsContext = createContext(defaultSettings); diff --git a/packages/dashboard-v2/src/pages/auth/signup.js b/packages/dashboard-v2/src/pages/auth/signup.js index 174a17fd..036d5368 100644 --- a/packages/dashboard-v2/src/pages/auth/signup.js +++ b/packages/dashboard-v2/src/pages/auth/signup.js @@ -1,5 +1,6 @@ import { useEffect, useState } from "react"; import { navigate } from "gatsby"; +import bytes from "pretty-bytes"; import AuthLayout from "../../layouts/AuthLayout"; @@ -7,13 +8,21 @@ import { Alert } from "../../components/Alert"; import HighlightedLink from "../../components/HighlightedLink"; import { SignUpForm } from "../../components/forms/SignUpForm"; import { usePortalSettings } from "../../contexts/portal-settings"; +import { PlansProvider, usePlans } from "../../contexts/plans"; -const FreePortalHeader = () => ( -
    -

    Create your free account

    -

    Includes 100 GB storage at basic speed

    -
    -); +const FreePortalHeader = () => { + const { plans } = usePlans(); + + const freePlan = plans.find(({ price }) => price === 0); + const freeStorage = freePlan ? bytes(freePlan.limits?.storageLimit, { binary: true }) : null; + + return ( +
    +

    Create your free account

    + {freeStorage &&

    Includes {freeStorage} storage at basic speed

    } +
    + ); +}; const PaidPortalHeader = () => (
    @@ -47,39 +56,41 @@ const SignUpPage = () => { }, [state, settings.isSubscriptionRequired]); return ( -
    -
    - Skynet + +
    +
    + Skynet +
    + + {!settings.areAccountsEnabled && Sorry, registrations are currently disabled.} + + {settings.areAccountsEnabled && ( + <> + {settings.isSubscriptionRequired ? : } + + {state !== State.Success && ( + setState(State.Success)} onFailure={() => setState(State.Failure)} /> + )} + + {state === State.Success && ( +
    +

    Please check your inbox and confirm your email address.

    +

    You will be redirected to your dashboard shortly.

    + Click here to go there now. +
    + )} + + {state === State.Failure && ( +

    Something went wrong, please try again later.

    + )} + + )} + +

    + Already have an account? Sign in +

    - - {!settings.areAccountsEnabled && Sorry, registrations are currently disabled.} - - {settings.areAccountsEnabled && ( - <> - {settings.isSubscriptionRequired ? : } - - {state !== State.Success && ( - setState(State.Success)} onFailure={() => setState(State.Failure)} /> - )} - - {state === State.Success && ( -
    -

    Please check your inbox and confirm your email address.

    -

    You will be redirected to your dashboard shortly.

    - Click here to go there now. -
    - )} - - {state === State.Failure && ( -

    Something went wrong, please try again later.

    - )} - - )} - -

    - Already have an account? Sign in -

    -
    + ); }; From b6d5047d8617f8f8fcac2fc7d1bf54e2fb8966db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 30 Mar 2022 17:07:03 +0200 Subject: [PATCH 079/240] ops: add Michal's public key --- setup-scripts/support/authorized_keys | 1 + 1 file changed, 1 insertion(+) diff --git a/setup-scripts/support/authorized_keys b/setup-scripts/support/authorized_keys index 6ee7b264..b2848d66 100644 --- a/setup-scripts/support/authorized_keys +++ b/setup-scripts/support/authorized_keys @@ -8,3 +8,4 @@ ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPM43lzbKjFLChe5rKETxDpWpNlqXCGTBPiWlDN2vlLD ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIN6Kcx8yetova4/ALUQHigo/PBMJO33ZTKOsg2jxSO2a user@deploy.siasky.dev ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDcenWnMQ6q/OEC4ZmQgjLDV2obWlR3fENV0zRGFvJF+ marcins@siasky.net ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIB7prtVOTwtcSN9HkXum107RwcW5H8Vggx6Qv7T57ItT daniel@siasky.net +ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH+4IrfEM9H16jqvPZncHkWWoHO4/BVq7d4pEyzK4e0W michal.leszczyk@skynetlabs.com From 88f7170bb9899314478e6ae6084de14b4496e0bc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 31 Mar 2022 08:25:38 +0200 Subject: [PATCH 080/240] chore(dashboard-v2): update accounts disabled message --- packages/dashboard-v2/src/pages/auth/signup.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/dashboard-v2/src/pages/auth/signup.js b/packages/dashboard-v2/src/pages/auth/signup.js index 036d5368..2af428f9 100644 --- a/packages/dashboard-v2/src/pages/auth/signup.js +++ b/packages/dashboard-v2/src/pages/auth/signup.js @@ -62,7 +62,7 @@ const SignUpPage = () => { Skynet
    - {!settings.areAccountsEnabled && Sorry, registrations are currently disabled.} + {!settings.areAccountsEnabled && Accounts are not enabled on this portal.} {settings.areAccountsEnabled && ( <> From 93c6e790cddec9f86299779ea9b503a0c699cf7b Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 11:32:47 +0200 Subject: [PATCH 081/240] skip health checks if container is not running --- setup-scripts/bot_utils.py | 6 ++++++ setup-scripts/health-checker.py | 8 +++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/setup-scripts/bot_utils.py b/setup-scripts/bot_utils.py index b987e464..c6d0f201 100644 --- a/setup-scripts/bot_utils.py +++ b/setup-scripts/bot_utils.py @@ -32,6 +32,12 @@ sc_precision = 10**24 # Environment variable globals setup_done = False +# get docker container id and return None if container not found +def get_docker_container_id(container_name): + docker_cmd = "docker ps -q -f name=" + container_name + output = subprocess.check_output(docker_cmd, shell=True).decode("utf-8") + return None if output == "" else output + # find out local siad ip by inspecting its docker container def get_docker_container_ip(container_name): diff --git a/setup-scripts/health-checker.py b/setup-scripts/health-checker.py index 091ebe30..947ae307 100755 --- a/setup-scripts/health-checker.py +++ b/setup-scripts/health-checker.py @@ -10,7 +10,7 @@ import traceback from datetime import datetime, timedelta import requests -from bot_utils import setup, send_msg, get_docker_container_ip +from bot_utils import setup, send_msg, get_docker_container_id, get_docker_container_ip """ health-checker reads the /health-check endpoint of the portal and dispatches @@ -135,6 +135,12 @@ async def check_disk(): async def check_health(): print("\nChecking portal health status...") + # do not try to run health checks if health-check container does not exist + # possible use case is fresh or taken down server that has only skyd running + if not get_docker_container_id("health-check"): + print("Container health-check not found - skipping health checks") + return + try: endpoint = "http://{}:{}".format(get_docker_container_ip("health-check"), 3100) except: From 9711bc096c0a225d3269ce7f5f0a32f3268e1c0c Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 11:49:42 +0200 Subject: [PATCH 082/240] lint dockerfiles with hadolint --- .github/workflows/lint-dockerfiles.yml | 27 ++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/lint-dockerfiles.yml diff --git a/.github/workflows/lint-dockerfiles.yml b/.github/workflows/lint-dockerfiles.yml new file mode 100644 index 00000000..7a28d146 --- /dev/null +++ b/.github/workflows/lint-dockerfiles.yml @@ -0,0 +1,27 @@ +name: Dockerfile Lint + +on: + push: + branches: + - main + pull_request: + +jobs: + hadolint: + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + dockerfile: + - docker/nginx/Dockerfile + - docker/sia/Dockerfile + - packages/dashboard/Dockerfile + - packages/dnslink-api/Dockerfile + - packages/handshake-api/Dockerfile + - packages/health-check/Dockerfile + - packages/website/Dockerfile + steps: + - uses: actions/checkout@v3 + - uses: hadolint/hadolint-action@v2.0.0 + with: + dockerfile: ${{ matrix.dockerfile }} From a8d046ad568948c9d15ae7b7d8428104fdf36ce9 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 11:57:33 +0200 Subject: [PATCH 083/240] fix hadolint reported issues --- packages/health-check/Dockerfile | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/packages/health-check/Dockerfile b/packages/health-check/Dockerfile index 9480902c..d0c6bfc2 100644 --- a/packages/health-check/Dockerfile +++ b/packages/health-check/Dockerfile @@ -1,16 +1,15 @@ FROM node:16.14.2-alpine -RUN apk update && apk add dnsmasq +RUN apk --no-cache add dnsmasq=2.86-r0 && rm -rf /var/cache/apk/* WORKDIR /usr/app ENV PATH="/usr/app/bin:${PATH}" # schedule critical checks to run every 5 minutes (any failures will disable server) -RUN echo '*/5 * * * * source /etc/environment ; /usr/app/bin/cli run critical >> /proc/1/fd/1' >> /etc/crontabs/root - # schedule extended checks to run on every hour (optional checks, report only) -RUN echo '0 * * * * source /etc/environment ; /usr/app/bin/cli run extended >> /proc/1/fd/1' >> /etc/crontabs/root +RUN echo '*/5 * * * * source /etc/environment ; /usr/app/bin/cli run critical >> /proc/1/fd/1' >> /etc/crontabs/root && \ + echo '0 * * * * source /etc/environment ; /usr/app/bin/cli run extended >> /proc/1/fd/1' >> /etc/crontabs/root COPY package.json yarn.lock ./ From c7db33c91033fd848fa19ea484f06135a5c2cd39 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 11:59:30 +0200 Subject: [PATCH 084/240] fix hadolint reported issues --- packages/handshake-api/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/handshake-api/Dockerfile b/packages/handshake-api/Dockerfile index 06dbb253..92f30b36 100644 --- a/packages/handshake-api/Dockerfile +++ b/packages/handshake-api/Dockerfile @@ -15,4 +15,4 @@ ENV HSD_API_KEY="foo" EXPOSE 3100 ENV NODE_ENV production -CMD node src/index.js +CMD ["node", "src/index.js"] From 460ff626c62e536c8aa4e39698219fed4c9f37a2 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 12:00:35 +0200 Subject: [PATCH 085/240] fix hadolint reported issues --- packages/dnslink-api/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/dnslink-api/Dockerfile b/packages/dnslink-api/Dockerfile index ca6295a7..be1f9452 100644 --- a/packages/dnslink-api/Dockerfile +++ b/packages/dnslink-api/Dockerfile @@ -9,4 +9,4 @@ RUN yarn --frozen-lockfile COPY src/* src/ EXPOSE 3100 -CMD node src/index.js +CMD ["node", "src/index.js"] From aa03f62bc76c85bfd99d12e956090f6007c928a5 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 12:02:31 +0200 Subject: [PATCH 086/240] fix hadolint reported issues --- docker/nginx/Dockerfile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docker/nginx/Dockerfile b/docker/nginx/Dockerfile index 2093872c..eca1e3d8 100644 --- a/docker/nginx/Dockerfile +++ b/docker/nginx/Dockerfile @@ -1,5 +1,7 @@ FROM openresty/openresty:1.19.9.1-focal +WORKDIR / + RUN luarocks install lua-resty-http && \ luarocks install hasher && \ openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 \ From 2d52aa3b75d94a61e3da927707c8c9edc155fa75 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 12:05:08 +0200 Subject: [PATCH 087/240] fix hadolint reported issues --- docker/sia/Dockerfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docker/sia/Dockerfile b/docker/sia/Dockerfile index 887b92e9..ed1690db 100644 --- a/docker/sia/Dockerfile +++ b/docker/sia/Dockerfile @@ -5,10 +5,10 @@ ENV GOARCH amd64 ARG branch=portal-latest -RUN git clone https://gitlab.com/SkynetLabs/skyd.git Sia --single-branch --branch ${branch} -RUN make release --directory Sia +RUN git clone https://gitlab.com/SkynetLabs/skyd.git Sia --single-branch --branch ${branch} && \ + make release --directory Sia -FROM nebulouslabs/sia:latest +FROM nebulouslabs/sia:1.5.6 COPY --from=sia-builder /go/bin/ /usr/bin/ From 6f1c1af34209873f9bed63848bc21156df86e064 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 12:10:00 +0200 Subject: [PATCH 088/240] fix hadolint reported issues --- packages/health-check/Dockerfile | 3 ++- packages/website/Dockerfile | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/health-check/Dockerfile b/packages/health-check/Dockerfile index d0c6bfc2..a05d822b 100644 --- a/packages/health-check/Dockerfile +++ b/packages/health-check/Dockerfile @@ -1,6 +1,7 @@ FROM node:16.14.2-alpine -RUN apk --no-cache add dnsmasq=2.86-r0 && rm -rf /var/cache/apk/* +RUN apk add --no-cache dnsmasq=2.86-r0 && \ + rm -rf /var/cache/apk/* WORKDIR /usr/app diff --git a/packages/website/Dockerfile b/packages/website/Dockerfile index b5a9828c..68d0f191 100644 --- a/packages/website/Dockerfile +++ b/packages/website/Dockerfile @@ -1,6 +1,7 @@ FROM node:16.14.2-alpine -RUN apk update && apk add autoconf automake build-base libtool nasm pkgconfig +RUN apk add --no-cache autoconf=2.71-r0 automake=1.16.4-r1 build-base=0.5-r2 libtool=2.4.6-r7 nasm=2.15.05-r0 pkgconfig=1.8.0-r0 && \ + rm -rf /var/cache/apk/* WORKDIR /usr/app From fbdd689669d1d3191891cc1a7bca5216f9ed9127 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 12:18:26 +0200 Subject: [PATCH 089/240] fix hadolint reported issues --- docker/sia/Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker/sia/Dockerfile b/docker/sia/Dockerfile index ed1690db..4032168f 100644 --- a/docker/sia/Dockerfile +++ b/docker/sia/Dockerfile @@ -12,5 +12,5 @@ FROM nebulouslabs/sia:1.5.6 COPY --from=sia-builder /go/bin/ /usr/bin/ -RUN mv /usr/bin/skyd /usr/bin/siad || true && \ - mv /usr/bin/skyc /usr/bin/siac || true +RUN if [[ -f "/usr/bin/skyd" ]]; then mv /usr/bin/skyd /usr/bin/siad; fi && \ + if [[ -f "/usr/bin/skyc" ]]; then mv /usr/bin/skyc /usr/bin/siac; fi From cfdfc52e6ae84ace20db2666d11872fecdf9947b Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 12:23:16 +0200 Subject: [PATCH 090/240] fix hadolint reported issues --- docker/sia/Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker/sia/Dockerfile b/docker/sia/Dockerfile index 4032168f..953dd27c 100644 --- a/docker/sia/Dockerfile +++ b/docker/sia/Dockerfile @@ -12,5 +12,5 @@ FROM nebulouslabs/sia:1.5.6 COPY --from=sia-builder /go/bin/ /usr/bin/ -RUN if [[ -f "/usr/bin/skyd" ]]; then mv /usr/bin/skyd /usr/bin/siad; fi && \ - if [[ -f "/usr/bin/skyc" ]]; then mv /usr/bin/skyc /usr/bin/siac; fi +RUN if [ -f "/usr/bin/skyd" ]; then mv /usr/bin/skyd /usr/bin/siad; fi && \ + if [ -f "/usr/bin/skyc" ]; then mv /usr/bin/skyc /usr/bin/siac; fi From f9b151eb9242814d10d42ac249437803b784eed8 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 12:27:31 +0200 Subject: [PATCH 091/240] fix hadolint reported issues --- packages/website/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/website/Dockerfile b/packages/website/Dockerfile index 68d0f191..9bd5823c 100644 --- a/packages/website/Dockerfile +++ b/packages/website/Dockerfile @@ -1,6 +1,6 @@ FROM node:16.14.2-alpine -RUN apk add --no-cache autoconf=2.71-r0 automake=1.16.4-r1 build-base=0.5-r2 libtool=2.4.6-r7 nasm=2.15.05-r0 pkgconfig=1.8.0-r0 && \ +RUN apk add --no-cache autoconf=2.71-r0 automake=1.16.4-r1 build-base=0.5-r2 libtool=2.4.6-r7 nasm=2.15.05-r0 pkgconf=1.8.0-r0 && \ rm -rf /var/cache/apk/* WORKDIR /usr/app From 59c6b84d01f18ceca78f304f23a31c6bc2586128 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 12:33:54 +0200 Subject: [PATCH 092/240] fix hadolint reported issues --- .github/workflows/lint-dockerfiles.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lint-dockerfiles.yml b/.github/workflows/lint-dockerfiles.yml index 7a28d146..1eea156c 100644 --- a/.github/workflows/lint-dockerfiles.yml +++ b/.github/workflows/lint-dockerfiles.yml @@ -3,7 +3,7 @@ name: Dockerfile Lint on: push: branches: - - main + - master pull_request: jobs: From 94fb6dc244acbde43f238ca1f0564dc221d2b793 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 14:38:06 +0200 Subject: [PATCH 093/240] rename s3 backup subdirectory --- scripts/backup-aws-s3.sh | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/scripts/backup-aws-s3.sh b/scripts/backup-aws-s3.sh index 9e62cb79..f2d229fc 100755 --- a/scripts/backup-aws-s3.sh +++ b/scripts/backup-aws-s3.sh @@ -13,11 +13,13 @@ ENV_VARIABLES=("AWS_ACCESS_KEY_ID" "AWS_SECRET_ACCESS_KEY" "PORTAL_DOMAIN" "SERV for ENV_VARIABLE in "${ENV_VARIABLES[@]}"; do ENV_VARIABLE_VALUE=$(grep -v '^#' /home/user/skynet-webportal/.env | grep ${ENV_VARIABLE} || true) if test -z "${ENV_VARIABLE_VALUE}"; then - if $ENV_VARIABLE ~= "SERVER_DOMAIN"; then + # all variables except SERVER_DOMAIN are required + if [ "${ENV_VARIABLE}" != "SERVER_DOMAIN" ]; then echo "Environment variable ${ENV_VARIABLE} is not set" && exit 1 fi + else + export ${ENV_VARIABLE_VALUE} fi - export ${ENV_VARIABLE_VALUE} done # create bucket skynet-backup-[portaldomain] (replace dots with dashes and strip anything other than alnum) @@ -30,11 +32,17 @@ if test -z "${SERVER_DOMAIN}"; then SERVER_PREFIX=$(echo ${SERVER_UID} | tr '.' '-' | tr -cd '[[:alnum:]]-') else # use both uid and server domain if available (replace dots with dashes and strip anything other than alnum) - SERVER_PREFIX=$(echo ${SERVER_UID}-${SERVER_DOMAIN} | tr '.' '-' | tr -cd '[[:alnum:]]-') + SERVER_PREFIX=$(echo ${SERVER_DOMAIN}-${SERVER_UID} | tr '.' '-' | tr -cd '[[:alnum:]]-') + SERVER_PREFIX_LEGACY=$(echo ${SERVER_UID}-${SERVER_DOMAIN} | tr '.' '-' | tr -cd '[[:alnum:]]-') fi aws s3api create-bucket --acl private --bucket ${BUCKET_NAME} +# move old backup dir to new location if legacy backup path exists +if test -n "${SERVER_PREFIX_LEGACY}"; then + aws s3 mv --recursive s3://${BUCKET_NAME}/${SERVER_PREFIX_LEGACY} s3://${BUCKET_NAME}/${SERVER_PREFIX} +fi + # sync all nginx logs mkdir -p /home/user/skynet-webportal/docker/data/nginx/logs # ensure path exists aws s3 sync --no-progress /home/user/skynet-webportal/docker/data/nginx/logs s3://${BUCKET_NAME}/${SERVER_PREFIX}/docker/data/nginx/logs From 4f5b59c53a21ee9989495d22553e1311f9f30873 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20Wypch=C5=82o?= Date: Thu, 31 Mar 2022 15:15:26 +0200 Subject: [PATCH 094/240] don't need to remove apk cache --- packages/health-check/Dockerfile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/health-check/Dockerfile b/packages/health-check/Dockerfile index a05d822b..e9d15a77 100644 --- a/packages/health-check/Dockerfile +++ b/packages/health-check/Dockerfile @@ -1,7 +1,6 @@ FROM node:16.14.2-alpine -RUN apk add --no-cache dnsmasq=2.86-r0 && \ - rm -rf /var/cache/apk/* +RUN apk add --no-cache dnsmasq=2.86-r0 WORKDIR /usr/app From dd51ece41be806cce7d9825a77b3ac1b76369cca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20Wypch=C5=82o?= Date: Thu, 31 Mar 2022 15:15:38 +0200 Subject: [PATCH 095/240] don't need to remove apk cache --- packages/website/Dockerfile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/website/Dockerfile b/packages/website/Dockerfile index 9bd5823c..3a9fa9a1 100644 --- a/packages/website/Dockerfile +++ b/packages/website/Dockerfile @@ -1,7 +1,6 @@ FROM node:16.14.2-alpine -RUN apk add --no-cache autoconf=2.71-r0 automake=1.16.4-r1 build-base=0.5-r2 libtool=2.4.6-r7 nasm=2.15.05-r0 pkgconf=1.8.0-r0 && \ - rm -rf /var/cache/apk/* +RUN apk add --no-cache autoconf=2.71-r0 automake=1.16.4-r1 build-base=0.5-r2 libtool=2.4.6-r7 nasm=2.15.05-r0 pkgconf=1.8.0-r0 WORKDIR /usr/app From 42f3ef3e22c38cd06c745b5eb67a7f7dc9bb63f5 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 31 Mar 2022 15:23:58 +0200 Subject: [PATCH 096/240] add missing newline to satisfy flake8 --- setup-scripts/bot_utils.py | 1 + 1 file changed, 1 insertion(+) diff --git a/setup-scripts/bot_utils.py b/setup-scripts/bot_utils.py index c6d0f201..65e45bcb 100644 --- a/setup-scripts/bot_utils.py +++ b/setup-scripts/bot_utils.py @@ -32,6 +32,7 @@ sc_precision = 10**24 # Environment variable globals setup_done = False + # get docker container id and return None if container not found def get_docker_container_id(container_name): docker_cmd = "docker ps -q -f name=" + container_name From 8b87d107ee78d25b7645fcf0ee4f66b3aa99d8c4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 12:04:10 +0000 Subject: [PATCH 097/240] build(deps-dev): bump prettier in /packages/handshake-api Bumps [prettier](https://github.com/prettier/prettier) from 2.6.1 to 2.6.2. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](https://github.com/prettier/prettier/compare/2.6.1...2.6.2) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/handshake-api/package.json | 2 +- packages/handshake-api/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/handshake-api/package.json b/packages/handshake-api/package.json index c102dd9d..85265b03 100644 --- a/packages/handshake-api/package.json +++ b/packages/handshake-api/package.json @@ -10,6 +10,6 @@ "punycode": "^2.1.1" }, "devDependencies": { - "prettier": "^2.6.1" + "prettier": "^2.6.2" } } diff --git a/packages/handshake-api/yarn.lock b/packages/handshake-api/yarn.lock index 421cde2e..60c305b6 100644 --- a/packages/handshake-api/yarn.lock +++ b/packages/handshake-api/yarn.lock @@ -314,10 +314,10 @@ path-to-regexp@0.1.7: resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-0.1.7.tgz#df604178005f522f15eb4490e7247a1bfaa67f8c" integrity sha1-32BBeABfUi8V60SQ5yR6G/qmf4w= -prettier@^2.6.1: - version "2.6.1" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.1.tgz#d472797e0d7461605c1609808e27b80c0f9cfe17" - integrity sha512-8UVbTBYGwN37Bs9LERmxCPjdvPxlEowx2urIL6urHzdb3SDq4B/Z6xLFCblrSnE4iKWcS6ziJ3aOYrc1kz/E2A== +prettier@^2.6.2: + version "2.6.2" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.2.tgz#e26d71a18a74c3d0f0597f55f01fb6c06c206032" + integrity sha512-PkUpF+qoXTqhOeWL9fu7As8LXsIUZ1WYaJiY/a7McAQzxjk82OF0tibkFXVCDImZtWxbvojFjerkiLb0/q8mew== proxy-addr@~2.0.7: version "2.0.7" From 2b0382543836fbdf9947c47338b9883cc629d683 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 12:05:19 +0000 Subject: [PATCH 098/240] build(deps-dev): bump prettier in /packages/health-check Bumps [prettier](https://github.com/prettier/prettier) from 2.6.1 to 2.6.2. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](https://github.com/prettier/prettier/compare/2.6.1...2.6.2) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/health-check/package.json | 2 +- packages/health-check/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/health-check/package.json b/packages/health-check/package.json index fd512fc8..80c0fe5f 100644 --- a/packages/health-check/package.json +++ b/packages/health-check/package.json @@ -19,6 +19,6 @@ }, "devDependencies": { "jest": "^27.5.1", - "prettier": "^2.6.1" + "prettier": "^2.6.2" } } diff --git a/packages/health-check/yarn.lock b/packages/health-check/yarn.lock index 5aae0c3d..f831fe04 100644 --- a/packages/health-check/yarn.lock +++ b/packages/health-check/yarn.lock @@ -2643,10 +2643,10 @@ prelude-ls@~1.1.2: resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" integrity sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ= -prettier@^2.6.1: - version "2.6.1" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.1.tgz#d472797e0d7461605c1609808e27b80c0f9cfe17" - integrity sha512-8UVbTBYGwN37Bs9LERmxCPjdvPxlEowx2urIL6urHzdb3SDq4B/Z6xLFCblrSnE4iKWcS6ziJ3aOYrc1kz/E2A== +prettier@^2.6.2: + version "2.6.2" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.2.tgz#e26d71a18a74c3d0f0597f55f01fb6c06c206032" + integrity sha512-PkUpF+qoXTqhOeWL9fu7As8LXsIUZ1WYaJiY/a7McAQzxjk82OF0tibkFXVCDImZtWxbvojFjerkiLb0/q8mew== pretty-format@^27.5.1: version "27.5.1" From 9ec2ede0131ef0b464f78a397e54ca67296666cc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 12:06:21 +0000 Subject: [PATCH 099/240] build(deps-dev): bump prettier in /packages/dnslink-api Bumps [prettier](https://github.com/prettier/prettier) from 2.6.1 to 2.6.2. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](https://github.com/prettier/prettier/compare/2.6.1...2.6.2) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dnslink-api/package.json | 2 +- packages/dnslink-api/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dnslink-api/package.json b/packages/dnslink-api/package.json index 4b913067..cf579bc3 100644 --- a/packages/dnslink-api/package.json +++ b/packages/dnslink-api/package.json @@ -8,6 +8,6 @@ "is-valid-domain": "^0.1.6" }, "devDependencies": { - "prettier": "^2.6.1" + "prettier": "^2.6.2" } } diff --git a/packages/dnslink-api/yarn.lock b/packages/dnslink-api/yarn.lock index 56631f9e..de7a295e 100644 --- a/packages/dnslink-api/yarn.lock +++ b/packages/dnslink-api/yarn.lock @@ -265,10 +265,10 @@ path-to-regexp@0.1.7: resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-0.1.7.tgz#df604178005f522f15eb4490e7247a1bfaa67f8c" integrity sha1-32BBeABfUi8V60SQ5yR6G/qmf4w= -prettier@^2.6.1: - version "2.6.1" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.1.tgz#d472797e0d7461605c1609808e27b80c0f9cfe17" - integrity sha512-8UVbTBYGwN37Bs9LERmxCPjdvPxlEowx2urIL6urHzdb3SDq4B/Z6xLFCblrSnE4iKWcS6ziJ3aOYrc1kz/E2A== +prettier@^2.6.2: + version "2.6.2" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.2.tgz#e26d71a18a74c3d0f0597f55f01fb6c06c206032" + integrity sha512-PkUpF+qoXTqhOeWL9fu7As8LXsIUZ1WYaJiY/a7McAQzxjk82OF0tibkFXVCDImZtWxbvojFjerkiLb0/q8mew== proxy-addr@~2.0.7: version "2.0.7" From 8a96173db36b8a081c1f0a46bf70d518cffefd13 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 12:07:02 +0000 Subject: [PATCH 100/240] build(deps): bump @stripe/stripe-js in /packages/dashboard Bumps [@stripe/stripe-js](https://github.com/stripe/stripe-js) from 1.25.0 to 1.26.0. - [Release notes](https://github.com/stripe/stripe-js/releases) - [Commits](https://github.com/stripe/stripe-js/compare/v1.25.0...v1.26.0) --- updated-dependencies: - dependency-name: "@stripe/stripe-js" dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index bf517f01..2f0deb5d 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -11,7 +11,7 @@ "@fontsource/sora": "4.5.5", "@fontsource/source-sans-pro": "4.5.6", "@stripe/react-stripe-js": "1.7.0", - "@stripe/stripe-js": "1.25.0", + "@stripe/stripe-js": "1.26.0", "classnames": "2.3.1", "copy-text-to-clipboard": "^3.0.1", "dayjs": "1.11.0", diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 98664b3f..a9ad1cc7 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -182,10 +182,10 @@ dependencies: prop-types "^15.7.2" -"@stripe/stripe-js@1.25.0": - version "1.25.0" - resolved "https://registry.yarnpkg.com/@stripe/stripe-js/-/stripe-js-1.25.0.tgz#74334e3f9971e8dfd352a67581c6e02dc5c2ebf8" - integrity sha512-cywIoKu3sJnBPQ1eKi3BzFHWslA2ePqHvQhcxp7iYYlo1tWcVgEKTSh7y7hb6GoR4TyT3DwlK4v1vOZpVg8u4Q== +"@stripe/stripe-js@1.26.0": + version "1.26.0" + resolved "https://registry.yarnpkg.com/@stripe/stripe-js/-/stripe-js-1.26.0.tgz#45670924753c01e18d0544ea1f1067b474aaa96f" + integrity sha512-4R1vC75yKaCVFARW3bhelf9+dKt4NP4iZY/sIjGK7AAMBVvZ47eG74NvsAIUdUnhOXSWFMjdFWqv+etk5BDW4g== "@tailwindcss/forms@0.5.0": version "0.5.0" From cb1d0fe6dbe63c02d19e3dadc6b473f1a31942ba Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 12:07:29 +0000 Subject: [PATCH 101/240] build(deps-dev): bump prettier in /packages/dashboard Bumps [prettier](https://github.com/prettier/prettier) from 2.6.1 to 2.6.2. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](https://github.com/prettier/prettier/compare/2.6.1...2.6.2) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index bf517f01..6568d4ea 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -38,7 +38,7 @@ "eslint": "8.12.0", "eslint-config-next": "12.1.1", "postcss": "8.4.12", - "prettier": "2.6.1", + "prettier": "2.6.2", "tailwindcss": "3.0.23" } } diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 98664b3f..bf25b388 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -1956,10 +1956,10 @@ prelude-ls@^1.2.1: resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.2.1.tgz#debc6489d7a6e6b0e7611888cec880337d316396" integrity sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g== -prettier@2.6.1: - version "2.6.1" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.1.tgz#d472797e0d7461605c1609808e27b80c0f9cfe17" - integrity sha512-8UVbTBYGwN37Bs9LERmxCPjdvPxlEowx2urIL6urHzdb3SDq4B/Z6xLFCblrSnE4iKWcS6ziJ3aOYrc1kz/E2A== +prettier@2.6.2: + version "2.6.2" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.6.2.tgz#e26d71a18a74c3d0f0597f55f01fb6c06c206032" + integrity sha512-PkUpF+qoXTqhOeWL9fu7As8LXsIUZ1WYaJiY/a7McAQzxjk82OF0tibkFXVCDImZtWxbvojFjerkiLb0/q8mew== pretty-bytes@6.0.0: version "6.0.0" From 7b8b87ea6490851894282250cb812586263f0166 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 12:08:15 +0000 Subject: [PATCH 102/240] build(deps): bump next from 12.1.1 to 12.1.4 in /packages/dashboard Bumps [next](https://github.com/vercel/next.js) from 12.1.1 to 12.1.4. - [Release notes](https://github.com/vercel/next.js/releases) - [Changelog](https://github.com/vercel/next.js/blob/canary/release.js) - [Commits](https://github.com/vercel/next.js/compare/v12.1.1...v12.1.4) --- updated-dependencies: - dependency-name: next dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 146 +++++++++++++++----------------- 2 files changed, 70 insertions(+), 78 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index bf517f01..2638eee5 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -20,7 +20,7 @@ "formik": "2.2.9", "http-status-codes": "2.2.0", "ky": "0.30.0", - "next": "12.1.1", + "next": "12.1.4", "normalize.css": "8.0.1", "pretty-bytes": "6.0.0", "react": "17.0.2", diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 98664b3f..3adf6604 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -77,10 +77,10 @@ resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz#b520529ec21d8e5945a1851dfd1c32e94e39ff45" integrity sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA== -"@next/env@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/env/-/env-12.1.1.tgz#8a927397697ee9d94852feb5fed57a813d299979" - integrity sha512-VmTRkfo/IXOQCATndjW3OjKb8zmAuB07eDdzO9XvuXZP87SyvnCYw3jrhUuFhOe/FVsKiloafa5LJfToUpvjUQ== +"@next/env@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/env/-/env-12.1.4.tgz#5af629b43075281ecd7f87938802b7cf5b67e94b" + integrity sha512-7gQwotJDKnfMxxXd8xJ2vsX5AzyDxO3zou0+QOXX8/unypA6icw5+wf6A62yKZ6qQ4UZHHxS68pb6UV+wNneXg== "@next/eslint-plugin-next@12.1.1": version "12.1.1" @@ -89,65 +89,65 @@ dependencies: glob "7.1.7" -"@next/swc-android-arm-eabi@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-12.1.1.tgz#2b134efb6639a770db10688a93ce0d2a9362fc5e" - integrity sha512-phV9H6d1eK1oVC7nmKKcCXvgOWT4K7aLC/beyO6yvbFC4XtBLE21vPwVl7B4ybz5xjSa6TXoR3TMR6vkW6Mv+A== +"@next/swc-android-arm-eabi@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-12.1.4.tgz#c3dae178b7c15ad627d2e9b8dfb38caecb5c4ac7" + integrity sha512-FJg/6a3s2YrUaqZ+/DJZzeZqfxbbWrynQMT1C5wlIEq9aDLXCFpPM/PiOyJh0ahxc0XPmi6uo38Poq+GJTuKWw== -"@next/swc-android-arm64@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-12.1.1.tgz#4fc66990c71c066f99fc435c0e8a4b3191bdfb4a" - integrity sha512-X5qEz0YeeYT0Gz2wXPAEtRKEuAsLUIEgC/DDfS98t/5Idjv0S4aqIX+TQdzoXP5bwQkIr+mSg+MBIdLtbtnCsA== +"@next/swc-android-arm64@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-12.1.4.tgz#f320d60639e19ecffa1f9034829f2d95502a9a51" + integrity sha512-LXraazvQQFBgxIg3Htny6G5V5he9EK7oS4jWtMdTGIikmD/OGByOv8ZjLuVLZLtVm3UIvaAiGtlQSLecxJoJDw== -"@next/swc-darwin-arm64@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-12.1.1.tgz#a5b4ea73ebf769f48dae97942b6b6fbeaf3f1dfc" - integrity sha512-bKKSNaTdnO3XPnfaR4NSpPcbs80fdbtOYC2lgtqLzA0bOMioupixMP5GrA/gfJHwh7GRH+A+sbgKQWsqSsYAqQ== +"@next/swc-darwin-arm64@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-12.1.4.tgz#fd578278312613eddcf3aee26910100509941b63" + integrity sha512-SSST/dBymecllZxcqTCcSTCu5o1NKk9I+xcvhn/O9nH6GWjgvGgGkNqLbCarCa0jJ1ukvlBA138FagyrmZ/4rQ== -"@next/swc-darwin-x64@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-12.1.1.tgz#064d50c08d9eec0fc1ff76e190d4fe43184aa8b7" - integrity sha512-2VOsA6WLDuDBA6935djohWGGeUIKeQhXwDwu1CKx1b8+6YMMIvFr/y2dpPWoct+5/IjFz84a2MnbABwpoNB9YA== +"@next/swc-darwin-x64@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-12.1.4.tgz#ace5f80d8c8348efe194f6d7074c6213c52b3944" + integrity sha512-p1lwdX0TVjaoDXQVuAkjtxVBbCL/urgxiMCBwuPDO7TikpXtSRivi+mIzBj5q7ypgICFmIAOW3TyupXeoPRAnA== -"@next/swc-linux-arm-gnueabihf@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-12.1.1.tgz#6cd6edda7f17ad1ceb1cd242419d93a643b1de31" - integrity sha512-1urXtWwqjqbbpJBWeJYz5ATgelKacVNdKIdhfahbsmW+DZGoK5TYovgieyHFYUCyHdTuKeLTVR62ahIRUBv1YA== +"@next/swc-linux-arm-gnueabihf@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-12.1.4.tgz#2bf2c83863635f19c71c226a2df936e001cce29c" + integrity sha512-67PZlgkCn3TDxacdVft0xqDCL7Io1/C4xbAs0+oSQ0xzp6OzN2RNpuKjHJrJgKd0DsE1XZ9sCP27Qv0591yfyg== -"@next/swc-linux-arm64-gnu@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-12.1.1.tgz#d480c71de4150728c0c67a363c7f17291db3f070" - integrity sha512-CDD9yFuknDvTOzzDnvfmb58USI5Vu6FUyzw96udKj7KA/n1YrNQ4K8X7KsDCRZoqfRWYceAyj1EpwHkfdiB7bg== +"@next/swc-linux-arm64-gnu@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-12.1.4.tgz#d577190f641c9b4b463719dd6b8953b6ba9be8d9" + integrity sha512-OnOWixhhw7aU22TQdQLYrgpgFq0oA1wGgnjAiHJ+St7MLj82KTDyM9UcymAMbGYy6nG/TFOOHdTmRMtCRNOw0g== -"@next/swc-linux-arm64-musl@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-12.1.1.tgz#9578705269b746617c763c1ac5c5b26084f1e5ce" - integrity sha512-nxyjgmbOpZm7gGPj9EV5Cqosoujt+ih/8SO2XG+BetgfAk0+c15793DHVAljNuc8GF9wpzqQnjMMUZ211VmQsg== +"@next/swc-linux-arm64-musl@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-12.1.4.tgz#e70ffe70393d8f9242deecdb282ce5a8fd588b14" + integrity sha512-UoRMzPZnsAavdWtVylYxH8DNC7Uy0i6RrvNwT4PyQVdfANBn2omsUkcH5lgS2O7oaz0nAYLk1vqyZDO7+tJotA== -"@next/swc-linux-x64-gnu@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-12.1.1.tgz#40f3c79b65b6cfc880e6131a25f7936716ded1b9" - integrity sha512-L8Cu8kH3Vn2dnRpvcvGGA1TlmDP2WXJ+qDwvjb/ikDXLdRdmFvJwHh45JUGiW2FHed3lGseOgNsuYiDvnT8Cdw== +"@next/swc-linux-x64-gnu@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-12.1.4.tgz#91498a130387fb1961902f2bee55863f8e910cff" + integrity sha512-nM+MA/frxlTLUKLJKorctdI20/ugfHRjVEEkcLp/58LGG7slNaP1E5d5dRA1yX6ISjPcQAkywas5VlGCg+uTvA== -"@next/swc-linux-x64-musl@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-12.1.1.tgz#922ea0306d36b5fd860d8cc5a6f4c53dca09395c" - integrity sha512-4RAb7L69MoRSggBqUfF3OrtBCUN2zPDi7asfL7bfxEhH10LGzyfil8dT0GVjPOPFz/SyLx3ORd6avGij2IlJUA== +"@next/swc-linux-x64-musl@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-12.1.4.tgz#78057b03c148c121553d41521ad38f6c732762ff" + integrity sha512-GoRHxkuW4u4yKw734B9SzxJwVdyEJosaZ62P7ifOwcujTxhgBt3y76V2nNUrsSuopcKI2ZTDjaa+2wd5zyeXbA== -"@next/swc-win32-arm64-msvc@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-12.1.1.tgz#be13af4e33c071e6ec97b2cfead51eb57ecf189b" - integrity sha512-zvkuNIgOxkAU3RbzWRGCcFasDxWJdhONt2YeRGe39dJERHhEFA1u4HgaZw/SFE/kfrNRUZbXjJNAg3OU/EpPZw== +"@next/swc-win32-arm64-msvc@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-12.1.4.tgz#05bbaabacac23b8edf6caa99eb86b17550a09051" + integrity sha512-6TQkQze0ievXwHJcVUrIULwCYVe3ccX6T0JgZ1SiMeXpHxISN7VJF/O8uSCw1JvXZYZ6ud0CJ7nfC5HXivgfPg== -"@next/swc-win32-ia32-msvc@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-12.1.1.tgz#2a5adb993542fc54fedfd525c69593f75c055595" - integrity sha512-GsNDtZ//uKWNVjiwv3YKQYsDXuRWTz8jTmxopf5Ws3dK+zA77hn4o46LBQg0JPCNqTUO6eIOlUBjqSL6ejxmSQ== +"@next/swc-win32-ia32-msvc@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-12.1.4.tgz#8fd2fb48f04a2802e51fc320878bf6b411c1c866" + integrity sha512-CsbX/IXuZ5VSmWCpSetG2HD6VO5FTsO39WNp2IR2Ut/uom9XtLDJAZqjQEnbUTLGHuwDKFjrIO3LkhtROXLE/g== -"@next/swc-win32-x64-msvc@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-12.1.1.tgz#21c12feb6acf75cac7c1ae4ca7f251aa1943f081" - integrity sha512-nH5osn/uK9wsjT8Jh1YxMtRrkN5hoCNLQjsEdvfUfb+loQXeYiBd3n/0DUJkf6Scjfv6/htfUTPP3AEa7AbBxQ== +"@next/swc-win32-x64-msvc@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-12.1.4.tgz#a72ed44c9b1f850986a30fe36c59e01f8a79b5f3" + integrity sha512-JtYuWzKXKLDMgE/xTcFtCm1MiCIRaAc5XYZfYX3n/ZWSI1SJS/GMm+Su0SAHJgRFavJh6U/p998YwO/iGTIgqQ== "@nodelib/fs.scandir@2.1.5": version "2.1.5" @@ -1693,29 +1693,28 @@ natural-compare@^1.4.0: resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= -next@12.1.1: - version "12.1.1" - resolved "https://registry.yarnpkg.com/next/-/next-12.1.1.tgz#f5e73d3a204da0632484a56040c23a4796958bc6" - integrity sha512-IOfEIAgroMtsoYz6HXpDS+b5WB9WZ+MH266COXGlcpIiYSgUyJf9xV6vF+zY2RPvBJFT4fUW0EVdVnoOmTloDw== +next@12.1.4: + version "12.1.4" + resolved "https://registry.yarnpkg.com/next/-/next-12.1.4.tgz#597a9bdec7aec778b442c4f6d41afd2c64a54b23" + integrity sha512-DA4g97BM4Z0nKtDvCTm58RxdvoQyYzeg0AeVbh0N4Y/D8ELrNu47lQeEgRGF8hV4eQ+Sal90zxrJQQG/mPQ8CQ== dependencies: - "@next/env" "12.1.1" + "@next/env" "12.1.4" caniuse-lite "^1.0.30001283" postcss "8.4.5" styled-jsx "5.0.1" - use-subscription "1.5.1" optionalDependencies: - "@next/swc-android-arm-eabi" "12.1.1" - "@next/swc-android-arm64" "12.1.1" - "@next/swc-darwin-arm64" "12.1.1" - "@next/swc-darwin-x64" "12.1.1" - "@next/swc-linux-arm-gnueabihf" "12.1.1" - "@next/swc-linux-arm64-gnu" "12.1.1" - "@next/swc-linux-arm64-musl" "12.1.1" - "@next/swc-linux-x64-gnu" "12.1.1" - "@next/swc-linux-x64-musl" "12.1.1" - "@next/swc-win32-arm64-msvc" "12.1.1" - "@next/swc-win32-ia32-msvc" "12.1.1" - "@next/swc-win32-x64-msvc" "12.1.1" + "@next/swc-android-arm-eabi" "12.1.4" + "@next/swc-android-arm64" "12.1.4" + "@next/swc-darwin-arm64" "12.1.4" + "@next/swc-darwin-x64" "12.1.4" + "@next/swc-linux-arm-gnueabihf" "12.1.4" + "@next/swc-linux-arm64-gnu" "12.1.4" + "@next/swc-linux-arm64-musl" "12.1.4" + "@next/swc-linux-x64-gnu" "12.1.4" + "@next/swc-linux-x64-musl" "12.1.4" + "@next/swc-win32-arm64-msvc" "12.1.4" + "@next/swc-win32-ia32-msvc" "12.1.4" + "@next/swc-win32-x64-msvc" "12.1.4" node-releases@^2.0.2: version "2.0.2" @@ -2425,13 +2424,6 @@ url-parse@^1.4.7: querystringify "^2.1.1" requires-port "^1.0.0" -use-subscription@1.5.1: - version "1.5.1" - resolved "https://registry.yarnpkg.com/use-subscription/-/use-subscription-1.5.1.tgz#73501107f02fad84c6dd57965beb0b75c68c42d1" - integrity sha512-Xv2a1P/yReAjAbhylMfFplFKj9GssgTwN7RlcTxBujFQcloStWNDQdc4g4NRWH9xS4i/FDk04vQBptAXoF3VcA== - dependencies: - object-assign "^4.1.1" - util-deprecate@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" From c29eb0b678956af9bdaca627c2b08a86c66bfcc6 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 12:09:06 +0000 Subject: [PATCH 103/240] build(deps): bump gatsby from 4.10.3 to 4.11.1 in /packages/website Bumps [gatsby](https://github.com/gatsbyjs/gatsby) from 4.10.3 to 4.11.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/compare/gatsby@4.10.3...gatsby@4.11.1) --- updated-dependencies: - dependency-name: gatsby dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 693 +++++++++++++++++----------------- 2 files changed, 353 insertions(+), 342 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 3605dd76..25b4069b 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -13,7 +13,7 @@ "copy-text-to-clipboard": "3.0.1", "crypto-browserify": "3.12.0", "framer-motion": "6.2.8", - "gatsby": "4.10.3", + "gatsby": "4.11.1", "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.10.1", "gatsby-plugin-manifest": "4.10.2", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index ef122f09..767963d1 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -1669,15 +1669,15 @@ "@nodelib/fs.scandir" "2.1.5" fastq "^1.6.0" -"@parcel/bundler-default@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/bundler-default/-/bundler-default-2.3.2.tgz#329f171e210dfb22beaa52ae706ccde1dae384c1" - integrity sha512-JUrto4mjSD0ic9dEqRp0loL5o3HVYHja1ZIYSq+rBl2UWRV6/9cGTb07lXOCqqm0BWE+hQ4krUxB76qWaF0Lqw== +"@parcel/bundler-default@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/bundler-default/-/bundler-default-2.4.1.tgz#a158fe63d99e38865db8353132bd1b2ff62ab47a" + integrity sha512-PTfBOuoiiYdfwyoPFeBTOinyl1RL4qaoyAQ0PCe01C1i4NcRWCY1w7zRvwJW/OhU3Ka+LtioGmfxu5/drdXzLg== dependencies: - "@parcel/diagnostic" "2.3.2" - "@parcel/hash" "2.3.2" - "@parcel/plugin" "2.3.2" - "@parcel/utils" "2.3.2" + "@parcel/diagnostic" "2.4.1" + "@parcel/hash" "2.4.1" + "@parcel/plugin" "2.4.1" + "@parcel/utils" "2.4.1" nullthrows "^1.1.1" "@parcel/cache@2.3.1": @@ -1690,15 +1690,15 @@ "@parcel/utils" "2.3.1" lmdb "^2.0.2" -"@parcel/cache@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/cache/-/cache-2.3.2.tgz#ba8c2af02fd45b90c7bc6f829bfc566d1ded0a13" - integrity sha512-Xxq+ekgcFEme6Fn1v7rEOBkyMOUOUu7eNqQw0l6HQS+INZ2Q7YzzfdW7pI8rEOAAICVg5BWKpmBQZpgJlT+HxQ== +"@parcel/cache@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/cache/-/cache-2.4.1.tgz#94322d6de5b9ccb18d58585c267022f47a6315d3" + integrity sha512-2N5ly++p/yefmPdK39X1QIoA2e6NtS1aYSsxrIC9EX92Kjd7SfSceqUJhlJWB49omJSheEJLd1qM3EJG9EvICQ== dependencies: - "@parcel/fs" "2.3.2" - "@parcel/logger" "2.3.2" - "@parcel/utils" "2.3.2" - lmdb "^2.0.2" + "@parcel/fs" "2.4.1" + "@parcel/logger" "2.4.1" + "@parcel/utils" "2.4.1" + lmdb "2.2.4" "@parcel/codeframe@2.3.1": version "2.3.1" @@ -1707,38 +1707,38 @@ dependencies: chalk "^4.1.0" -"@parcel/codeframe@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/codeframe/-/codeframe-2.3.2.tgz#73fb5a89910b977342808ca8f6ece61fa01b7690" - integrity sha512-ireQALcxxrTdIEpzTOoMo/GpfbFm1qlyezeGl3Hce3PMvHLg3a5S6u/Vcy7SAjdld5GfhHEqVY+blME6Z4CyXQ== +"@parcel/codeframe@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/codeframe/-/codeframe-2.4.1.tgz#57dcedb0326ca120241d2f272b84019009350b20" + integrity sha512-m3WDeEpWvgqekCqsHfPMJrSQquahdIgSR1x1RDCqQ1YelvW0fQiGgu42MXI5tjoBrHC1l1mF01UDb+xMSxz1DA== dependencies: chalk "^4.1.0" -"@parcel/compressor-raw@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/compressor-raw/-/compressor-raw-2.3.2.tgz#1a808ae9e61ed86f655935e1d2a984383b3c00a7" - integrity sha512-8dIoFwinYK6bOTpnZOAwwIv0v73y0ezsctPmfMnIqVQPn7wJwfhw/gbKVcmK5AkgQMkyid98hlLZoaZtGF1Mdg== +"@parcel/compressor-raw@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/compressor-raw/-/compressor-raw-2.4.1.tgz#0bd2cb6fe02ae910e4e25f4db7b08ec1c1a52395" + integrity sha512-cEOOOzIK7glxCqJX0OfBFBZE/iT7tmjEOXswRY3CnqY9FGoY3NYDAsOLm7A73RuIdNaZfYVxVUy3g7OLpbKL+g== dependencies: - "@parcel/plugin" "2.3.2" + "@parcel/plugin" "2.4.1" -"@parcel/core@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/core/-/core-2.3.2.tgz#1b9a79c1ff96dba5e0f53d4277bed4e7ab4590d0" - integrity sha512-gdJzpsgeUhv9H8T0UKVmyuptiXdduEfKIUx0ci+/PGhq8cCoiFnlnuhW6H7oLr79OUc+YJStabDJuG4U2A6ysw== +"@parcel/core@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/core/-/core-2.4.1.tgz#436b219769f273af299deb81f576be5b528c7e27" + integrity sha512-h2FvqLA75ZQdIXX1y+ylGjIIi7YtbAUJyIapxaO081h3EsYG2jr9sRL4sym5ECgmvbyua/DEgtMLX3eGYn09FA== dependencies: - "@parcel/cache" "2.3.2" - "@parcel/diagnostic" "2.3.2" - "@parcel/events" "2.3.2" - "@parcel/fs" "2.3.2" - "@parcel/graph" "2.3.2" - "@parcel/hash" "2.3.2" - "@parcel/logger" "2.3.2" - "@parcel/package-manager" "2.3.2" - "@parcel/plugin" "2.3.2" + "@parcel/cache" "2.4.1" + "@parcel/diagnostic" "2.4.1" + "@parcel/events" "2.4.1" + "@parcel/fs" "2.4.1" + "@parcel/graph" "2.4.1" + "@parcel/hash" "2.4.1" + "@parcel/logger" "2.4.1" + "@parcel/package-manager" "2.4.1" + "@parcel/plugin" "2.4.1" "@parcel/source-map" "^2.0.0" - "@parcel/types" "2.3.2" - "@parcel/utils" "2.3.2" - "@parcel/workers" "2.3.2" + "@parcel/types" "2.4.1" + "@parcel/utils" "2.4.1" + "@parcel/workers" "2.4.1" abortcontroller-polyfill "^1.1.9" base-x "^3.0.8" browserslist "^4.6.6" @@ -1747,7 +1747,7 @@ dotenv-expand "^5.1.0" json-source-map "^0.6.1" json5 "^2.2.0" - msgpackr "^1.5.1" + msgpackr "^1.5.4" nullthrows "^1.1.1" semver "^5.7.1" @@ -1759,10 +1759,10 @@ json-source-map "^0.6.1" nullthrows "^1.1.1" -"@parcel/diagnostic@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/diagnostic/-/diagnostic-2.3.2.tgz#1d3f0b55bfd9839c6f41d704ebbc89a96cca88dc" - integrity sha512-/xW93Az4AOiifuYW/c4CDbUcu3lx5FcUDAj9AGiR9NSTsF/ROC/RqnxvQ3AGtqa14R7vido4MXEpY3JEp6FsqA== +"@parcel/diagnostic@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/diagnostic/-/diagnostic-2.4.1.tgz#edb275699b543f71cf933bea141a3165ad919a0d" + integrity sha512-wmJIfn0PG2ABuraS+kMjl6UKaLjTDTtG+XkjJLWHzU/dd5RozqAZDKp65GWjvHzHLx7KICTAdUJsXh2s3TnTOQ== dependencies: json-source-map "^0.6.1" nullthrows "^1.1.1" @@ -1772,10 +1772,10 @@ resolved "https://registry.yarnpkg.com/@parcel/events/-/events-2.3.1.tgz#77108bd706638831339b96eaab39a0e9137aa92e" integrity sha512-J2rWKGl1Z2IvwwDwWYz/4gUxC1P4LsioUyOo1HYGT+N5+r41P8ZB5CM/aosI2qu5mMsH8rTpclOv5E36vCSQxw== -"@parcel/events@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/events/-/events-2.3.2.tgz#b6bcfbbc96d883716ee9d0e6ab232acdee862790" - integrity sha512-WiYIwXMo4Vd+pi58vRoHkul8TPE5VEfMY+3FYwVCKPl/LYqSD+vz6wMx9uG18mEbB1d/ofefv5ZFQNtPGKO4tQ== +"@parcel/events@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/events/-/events-2.4.1.tgz#6e1ba26d55f7a2d6a7491e0901d287de3e471e99" + integrity sha512-er2jwyzYt3Zimkrp7TR865GIeIMYNd7YSSxW39y/egm4LIPBsruUpHSnKRD5b65Jd+gckkxDsnrpADG6MH1zNw== "@parcel/fs-search@2.3.1": version "2.3.1" @@ -1784,10 +1784,10 @@ dependencies: detect-libc "^1.0.3" -"@parcel/fs-search@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/fs-search/-/fs-search-2.3.2.tgz#18611877ac1b370932c71987c2ec0e93a4a7e53d" - integrity sha512-u3DTEFnPtKuZvEtgGzfVjQUytegSSn3POi7WfwMwPIaeDPfYcyyhfl+c96z7VL9Gk/pqQ99/cGyAwFdFsnxxXA== +"@parcel/fs-search@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/fs-search/-/fs-search-2.4.1.tgz#ae195107895f366183ed0a3fa34bd4eeeaf3dfef" + integrity sha512-xfoLvHjHkZm4VZf3UWU5v6gzz+x7IBVY7siHGn0YyGwvlv73FmiR4mCSizqerXOyXknF2fpg6tNHNQyyNLS32Q== dependencies: detect-libc "^1.0.3" @@ -1802,23 +1802,23 @@ "@parcel/watcher" "^2.0.0" "@parcel/workers" "2.3.1" -"@parcel/fs@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/fs/-/fs-2.3.2.tgz#9628441a84c2582e1f6e69549feb0da0cc143e40" - integrity sha512-XV+OsnRpN01QKU37lBN0TFKvv7uPKfQGbqFqYOrMbXH++Ae8rBU0Ykz+Yu4tv2h7shMlde+AMKgRnRTAJZpWEQ== +"@parcel/fs@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/fs/-/fs-2.4.1.tgz#49e22a8f8018916a4922682e8e608256752c9692" + integrity sha512-kE9HzW6XjO/ZA5bQnAzp1YVmGlXeDqUaius2cH2K0wU7KQX/GBjyfEWJm/UsKPB6QIrGXgkPH6ashNzOgwDqpw== dependencies: - "@parcel/fs-search" "2.3.2" - "@parcel/types" "2.3.2" - "@parcel/utils" "2.3.2" + "@parcel/fs-search" "2.4.1" + "@parcel/types" "2.4.1" + "@parcel/utils" "2.4.1" "@parcel/watcher" "^2.0.0" - "@parcel/workers" "2.3.2" + "@parcel/workers" "2.4.1" -"@parcel/graph@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/graph/-/graph-2.3.2.tgz#4194816952ab322ab22a17f7d9ea17befbade64d" - integrity sha512-ltTBM3IEqumgmy4ABBFETT8NtAwSsjD9mY3WCyJ5P8rUshfVCg093rvBPbpuJYMaH/TV1AHVaWfZqaZ4JQDIQQ== +"@parcel/graph@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/graph/-/graph-2.4.1.tgz#33c8d370603e898d1ef6e99b4936b90c45d6d76c" + integrity sha512-3JCnPI9BJdKpGIk6NtVN7ML3C/J9Ey+WfUfk8WisDxFP7vjYkXwZbNSR/HnxH+Y03wmB6cv4HI8A4kndF0H0pw== dependencies: - "@parcel/utils" "2.3.2" + "@parcel/utils" "2.4.1" nullthrows "^1.1.1" "@parcel/hash@2.3.1": @@ -1829,10 +1829,10 @@ detect-libc "^1.0.3" xxhash-wasm "^0.4.2" -"@parcel/hash@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/hash/-/hash-2.3.2.tgz#33b8ff04bb44f6661bdc1054b302ef1b6bd3acb3" - integrity sha512-SMtYTsHihws/wqdVnOr0QAGyGYsW9rJSJkkoRujUxo8l2ctnBN1ztv89eOUrdtgHsmcnj/oz1yw6sN38X+BUng== +"@parcel/hash@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/hash/-/hash-2.4.1.tgz#475ecec62b08dbd21dddb62d6dc5b9148a6e5fe5" + integrity sha512-Ch1kkFPedef3geapU+XYmAdZY29u3eQXn/twMjowAKkWCmj6wZ+muUgBmOO2uCfK3xys7GycI8jYZcAbF5DVLg== dependencies: detect-libc "^1.0.3" xxhash-wasm "^0.4.2" @@ -1845,13 +1845,13 @@ "@parcel/diagnostic" "2.3.1" "@parcel/events" "2.3.1" -"@parcel/logger@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/logger/-/logger-2.3.2.tgz#b5fc7a9c1664ee0286d0f67641c7c81c8fec1561" - integrity sha512-jIWd8TXDQf+EnNWSa7Q10lSQ6C1LSH8OZkTlaINrfVIw7s+3tVxO3I4pjp7/ARw7RX2gdNPlw6fH4Gn/HvvYbw== +"@parcel/logger@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/logger/-/logger-2.4.1.tgz#8f87097009d6847409da69ecbc248a136b2f36c2" + integrity sha512-wm7FoKY+1dyo+Dd7Z4b0d6hmpgRBWfZwCoZSSyhgbG96Ty68/oo3m7oEMXPfry8IVGIhShmWKDp4py44PH3l7w== dependencies: - "@parcel/diagnostic" "2.3.2" - "@parcel/events" "2.3.2" + "@parcel/diagnostic" "2.4.1" + "@parcel/events" "2.4.1" "@parcel/markdown-ansi@2.3.1": version "2.3.1" @@ -1860,40 +1860,40 @@ dependencies: chalk "^4.1.0" -"@parcel/markdown-ansi@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/markdown-ansi/-/markdown-ansi-2.3.2.tgz#2a5be7ce76a506a9d238ea2257cb28e43abe4902" - integrity sha512-l01ggmag5QScCk9mYA0xHh5TWSffR84uPFP2KvaAMQQ9NLNufcFiU0mn/Mtr3pCb5L5dSzmJ+Oo9s7P1Kh/Fmg== +"@parcel/markdown-ansi@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/markdown-ansi/-/markdown-ansi-2.4.1.tgz#65f798234e5767d92c5f411de5aae11e611cd9b6" + integrity sha512-BkWhzbKQhTQ9lS96ZMMG0KyXSJBFdNeBVobWrdrrwcFlNER0nt2m6fdF7Hfpf1TqFhM4tT+GNFtON7ybL53RiQ== dependencies: chalk "^4.1.0" -"@parcel/namer-default@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/namer-default/-/namer-default-2.3.2.tgz#84e17abfc84fd293b23b3f405280ed2e279c75d8" - integrity sha512-3QUMC0+5+3KMKfoAxYAbpZtuRqTgyZKsGDWzOpuqwemqp6P8ahAvNPwSCi6QSkGcTmvtYwBu9/NHPSONxIFOfg== +"@parcel/namer-default@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/namer-default/-/namer-default-2.4.1.tgz#63442b2bf06ec555f825924435f450c9768bcc5a" + integrity sha512-a/Xulfia7JJP6Cw/D6Wq5xX6IAKVKMRPEYtU2wB8vKuwC/et6kXi+0bFVeCLnTjDzVtsjDdyOEwfRC4yiEy3BA== dependencies: - "@parcel/diagnostic" "2.3.2" - "@parcel/plugin" "2.3.2" + "@parcel/diagnostic" "2.4.1" + "@parcel/plugin" "2.4.1" nullthrows "^1.1.1" -"@parcel/node-resolver-core@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/node-resolver-core/-/node-resolver-core-2.3.2.tgz#dd360f405949fdcd62980cd44825052ab28f6135" - integrity sha512-wmrnMNzJN4GuHw2Ftho+BWgSWR6UCkW3XoMdphqcxpw/ieAdS2a+xYSosYkZgQZ6lGutSvLyJ1CkVvP6RLIdQQ== +"@parcel/node-resolver-core@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/node-resolver-core/-/node-resolver-core-2.4.1.tgz#640fd087f610f030db7411bb2f61ae0e896d7cd1" + integrity sha512-CvCADj3l4o5USqz/ZCaqbK8gdAQK63q94oSa0KnP6hrcDI/gDyf5Bk4+3cD4kSI+ByuN6aFLAYBS2nHBh5O/MQ== dependencies: - "@parcel/diagnostic" "2.3.2" - "@parcel/utils" "2.3.2" + "@parcel/diagnostic" "2.4.1" + "@parcel/utils" "2.4.1" nullthrows "^1.1.1" -"@parcel/optimizer-terser@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/optimizer-terser/-/optimizer-terser-2.3.2.tgz#790b69e6ecc6ef0d8f25b57e9a13806e1f1c2943" - integrity sha512-dOapHhfy0xiNZa2IoEyHGkhhla07xsja79NPem14e5jCqY6Oi40jKNV4ab5uu5u1elWUjJuw69tiYbkDZWbKQw== +"@parcel/optimizer-terser@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/optimizer-terser/-/optimizer-terser-2.4.1.tgz#999ae4551448540494f79861d4f68eb0cd0bfa48" + integrity sha512-naRdp6gApWHUI1FCBZEJs9NzNngjZx8hRhIHeQtTxWpc2Mu8cVzxbVHNAwUj10nW3iOYmxyj4wleOArl8xpVCQ== dependencies: - "@parcel/diagnostic" "2.3.2" - "@parcel/plugin" "2.3.2" + "@parcel/diagnostic" "2.4.1" + "@parcel/plugin" "2.4.1" "@parcel/source-map" "^2.0.0" - "@parcel/utils" "2.3.2" + "@parcel/utils" "2.4.1" nullthrows "^1.1.1" terser "^5.2.0" @@ -1910,38 +1910,38 @@ "@parcel/workers" "2.3.1" semver "^5.7.1" -"@parcel/package-manager@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/package-manager/-/package-manager-2.3.2.tgz#380f0741c9d0c79c170c437efae02506484df315" - integrity sha512-pAQfywKVORY8Ee+NHAyKzzQrKbnz8otWRejps7urwhDaTVLfAd5C/1ZV64ATZ9ALYP9jyoQ8bTaxVd4opcSuwg== +"@parcel/package-manager@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/package-manager/-/package-manager-2.4.1.tgz#fcd05b0d1999bef52496599043e0d5432abf57da" + integrity sha512-JUUinm4U3hy4epHl9A389xb+BGiFR8n9+qw3Z4UDfS1te43sh8+0virBGcnai/G7mlr5/vHW+l9xulc7WQaY6w== dependencies: - "@parcel/diagnostic" "2.3.2" - "@parcel/fs" "2.3.2" - "@parcel/logger" "2.3.2" - "@parcel/types" "2.3.2" - "@parcel/utils" "2.3.2" - "@parcel/workers" "2.3.2" + "@parcel/diagnostic" "2.4.1" + "@parcel/fs" "2.4.1" + "@parcel/logger" "2.4.1" + "@parcel/types" "2.4.1" + "@parcel/utils" "2.4.1" + "@parcel/workers" "2.4.1" semver "^5.7.1" -"@parcel/packager-js@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/packager-js/-/packager-js-2.3.2.tgz#2d2566bde0da921042b79aa827c71109665d795c" - integrity sha512-3OP0Ro9M1J+PIKZK4Ec2N5hjIPiqk++B2kMFeiUqvaNZjJgKrPPEICBhjS52rma4IE/NgmIMB3aI5pWqE/KwNA== +"@parcel/packager-js@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/packager-js/-/packager-js-2.4.1.tgz#f544f9e48718a1187be7856a5e638dc231e1867e" + integrity sha512-broWBUQisJLF5ThFtnl/asypuLMlMBwFPBTr8Ho9FYlL6W4wUzIymu7eOcuDljstmbD6luNVGMdCBYqt3IhHmw== dependencies: - "@parcel/diagnostic" "2.3.2" - "@parcel/hash" "2.3.2" - "@parcel/plugin" "2.3.2" + "@parcel/diagnostic" "2.4.1" + "@parcel/hash" "2.4.1" + "@parcel/plugin" "2.4.1" "@parcel/source-map" "^2.0.0" - "@parcel/utils" "2.3.2" + "@parcel/utils" "2.4.1" globals "^13.2.0" nullthrows "^1.1.1" -"@parcel/packager-raw@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/packager-raw/-/packager-raw-2.3.2.tgz#869cc3e7bee8ff3655891a0af400cf4e7dd4f144" - integrity sha512-RnoZ7WgNAFWkEPrEefvyDqus7xfv9XGprHyTbfLittPaVAZpl+4eAv43nXyMfzk77Cgds6KcNpkosj3acEpNIQ== +"@parcel/packager-raw@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/packager-raw/-/packager-raw-2.4.1.tgz#2566bd6187cf4e2393e5aad2b567d803248fdacb" + integrity sha512-4lCY3TjiYaZyRIqshNF21i6XkQ5PJyr+ahhK4O2IymuYuD8/wGH2amTZqKPpGLuiF3j1HskRRUNv1ekpvExJ8w== dependencies: - "@parcel/plugin" "2.3.2" + "@parcel/plugin" "2.4.1" "@parcel/plugin@2.3.1": version "2.3.1" @@ -1950,62 +1950,62 @@ dependencies: "@parcel/types" "2.3.1" -"@parcel/plugin@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/plugin/-/plugin-2.3.2.tgz#7701c40567d2eddd5d5b2b6298949cd03a2a22fa" - integrity sha512-SaLZAJX4KH+mrAmqmcy9KJN+V7L+6YNTlgyqYmfKlNiHu7aIjLL+3prX8QRcgGtjAYziCxvPj0cl1CCJssaiGg== +"@parcel/plugin@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/plugin/-/plugin-2.4.1.tgz#15294d796be2703b16fa4e617967cfaa8e5631d4" + integrity sha512-EJzNhwNWYuSpIPRlG1U2hKcovq/RsVie4Os1z51/e2dcCto/uAoJOMoWYYsCxtjkJ7BjFYyQ7fcZRKM9DEr6gQ== dependencies: - "@parcel/types" "2.3.2" + "@parcel/types" "2.4.1" -"@parcel/reporter-dev-server@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/reporter-dev-server/-/reporter-dev-server-2.3.2.tgz#46ee4c53ad08c8b8afd2c79fb37381b6ba55cfb5" - integrity sha512-E7LtnjAX4iiWMw2qKUyFBi3+bDz0UGjqgHoPQylUYYLi6opXjJz/oC+cCcCy4e3RZlkrl187XonvagS59YjDxA== +"@parcel/reporter-dev-server@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/reporter-dev-server/-/reporter-dev-server-2.4.1.tgz#dc29b399f0402ad6327fa1697ddc8bee74e7ff7d" + integrity sha512-tRz1LHiudDhujBC3kJ3Qm0Wnbo3p3SpE6fjyCFRhdv2PJnEufNTTwzEUoa7lYZACwFVQUtrh6F7nMXFw6ynrsQ== dependencies: - "@parcel/plugin" "2.3.2" - "@parcel/utils" "2.3.2" + "@parcel/plugin" "2.4.1" + "@parcel/utils" "2.4.1" -"@parcel/resolver-default@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/resolver-default/-/resolver-default-2.3.2.tgz#286070412ad7fe506f7c88409f39b362d2041798" - integrity sha512-y3r+xOwWsATrNGUWuZ6soA7q24f8E5tY1AZ9lHCufnkK2cdKZJ5O1cyd7ohkAiKZx2/pMd+FgmVZ/J3oxetXkA== +"@parcel/resolver-default@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/resolver-default/-/resolver-default-2.4.1.tgz#0ac851a42c9fb7521936339341f69730e6052495" + integrity sha512-iJRt1+7lk0n7+wb+S/tVyiObbaiYP1YQGKRsTE8y4Kgp4/OPukdUHGFJwzbojWa0HnyoXm3zEgelVz7cHl47fQ== dependencies: - "@parcel/node-resolver-core" "2.3.2" - "@parcel/plugin" "2.3.2" + "@parcel/node-resolver-core" "2.4.1" + "@parcel/plugin" "2.4.1" -"@parcel/runtime-browser-hmr@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/runtime-browser-hmr/-/runtime-browser-hmr-2.3.2.tgz#cb23a850324ea792168438a9be6a345ebb66eb6d" - integrity sha512-nRD6uOyF1+HGylP9GASbYmvUDOsDaNwvaxuGTSh8+5M0mmCgib+hVBiPEKbwdmKjGbUPt9wRFPyMa/JpeQZsIQ== +"@parcel/runtime-browser-hmr@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/runtime-browser-hmr/-/runtime-browser-hmr-2.4.1.tgz#dcc0d5b41e5662aa694dc5ad937c00d088c80dca" + integrity sha512-INsr78Kn0OuwMdXHCzw7v6l3Gf/UBTYtX7N7JNDOIBEFFkuZQiFWyAOI2P/DvMm8qeqcsrKliBO5Xty/a2Ivaw== dependencies: - "@parcel/plugin" "2.3.2" - "@parcel/utils" "2.3.2" + "@parcel/plugin" "2.4.1" + "@parcel/utils" "2.4.1" -"@parcel/runtime-js@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/runtime-js/-/runtime-js-2.3.2.tgz#c0e14251ce43f95977577e23bb9ac5c2487f3bb1" - integrity sha512-SJepcHvYO/7CEe/Q85sngk+smcJ6TypuPh4D2R8kN+cAJPi5WvbQEe7+x5BEgbN+5Jumi/Uo3FfOOE5mYh+F6g== +"@parcel/runtime-js@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/runtime-js/-/runtime-js-2.4.1.tgz#7322a434a49ce78a14dccfb945dfc24f009397df" + integrity sha512-/EXwRpo+GPvWgN5yD0hjjt84Gm6QWp757dqOOzTG5R2rm1WU+g1a+zJJB1zXkxhu9lleQs44D1jEffzhh2Voyw== dependencies: - "@parcel/plugin" "2.3.2" - "@parcel/utils" "2.3.2" + "@parcel/plugin" "2.4.1" + "@parcel/utils" "2.4.1" nullthrows "^1.1.1" -"@parcel/runtime-react-refresh@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/runtime-react-refresh/-/runtime-react-refresh-2.3.2.tgz#11961d7429ae3333b7efe14c4f57515df57eb5f2" - integrity sha512-P+GRPO2XVDSBQ4HmRSj2xfbHSQvL9+ahTE/AB74IJExLTITv5l4SHAV3VsiKohuHYUAYHW3A/Oe7tEFCAb6Cug== +"@parcel/runtime-react-refresh@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/runtime-react-refresh/-/runtime-react-refresh-2.4.1.tgz#86c9e2bbf4ce7a4bfed493da07716f8c3a24948d" + integrity sha512-a4GBQ/fO7Mklh1M1G2JVpJBPbZD7YXUPAzh9Y4vpCf0ouTHBRMc8ew4CyKPJIrrTly5P42tFWnD3P4FVNKwHOQ== dependencies: - "@parcel/plugin" "2.3.2" - "@parcel/utils" "2.3.2" + "@parcel/plugin" "2.4.1" + "@parcel/utils" "2.4.1" react-refresh "^0.9.0" -"@parcel/runtime-service-worker@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/runtime-service-worker/-/runtime-service-worker-2.3.2.tgz#aa91797e57d1bb5b2aac04ac62c5410709ae0a27" - integrity sha512-iREHj/eapphC4uS/zGUkiTJvG57q+CVbTrfE42kB8ECtf/RYNo5YC9htdvPZjRSXDPrEPc5NCoKp4X09ENNikw== +"@parcel/runtime-service-worker@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/runtime-service-worker/-/runtime-service-worker-2.4.1.tgz#928fb063273766ea52d8839758c212bbc657f1cb" + integrity sha512-WtMKSiyQ0kF78rBw0XIx7n65mMb+6GBx+5m49r1aVZzeZEOSynpjJzJvqo7rxVmA7qTDkD2bko7BH41iScsEaw== dependencies: - "@parcel/plugin" "2.3.2" - "@parcel/utils" "2.3.2" + "@parcel/plugin" "2.4.1" + "@parcel/utils" "2.4.1" nullthrows "^1.1.1" "@parcel/source-map@^2.0.0": @@ -2015,45 +2015,45 @@ dependencies: detect-libc "^1.0.3" -"@parcel/transformer-js@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/transformer-js/-/transformer-js-2.3.2.tgz#24bcb488d5f82678343a5630fe4bbe822789ac33" - integrity sha512-U1fbIoAoqR5P49S+DMhH8BUd9IHRPwrTTv6ARYGsYnhuNsjTFhNYE0kkfRYboe/e0z7vEbeJICZXjnZ7eQDw5A== +"@parcel/transformer-js@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/transformer-js/-/transformer-js-2.4.1.tgz#824fc0cf86225a18eb3ac330a5096795ffb65374" + integrity sha512-39Y9RUuDk5dc09Z3Pgj8snQd5E8926IqOowdTLKNJr7EcmkwHdinbpI4EqgKnisOwX4NSzxUti1I2DHsP1QZHw== dependencies: - "@parcel/diagnostic" "2.3.2" - "@parcel/plugin" "2.3.2" + "@parcel/diagnostic" "2.4.1" + "@parcel/plugin" "2.4.1" "@parcel/source-map" "^2.0.0" - "@parcel/utils" "2.3.2" - "@parcel/workers" "2.3.2" - "@swc/helpers" "^0.2.11" + "@parcel/utils" "2.4.1" + "@parcel/workers" "2.4.1" + "@swc/helpers" "^0.3.6" browserslist "^4.6.6" detect-libc "^1.0.3" nullthrows "^1.1.1" regenerator-runtime "^0.13.7" semver "^5.7.1" -"@parcel/transformer-json@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/transformer-json/-/transformer-json-2.3.2.tgz#4c470e86659e87ee13b1f31e75a3621d3615b6bd" - integrity sha512-Pv2iPaxKINtFwOk5fDbHjQlSm2Vza/NLimQY896FLxiXPNAJxWGvMwdutgOPEBKksxRx9LZPyIOHiRVZ0KcA3w== +"@parcel/transformer-json@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/transformer-json/-/transformer-json-2.4.1.tgz#0585e539db5a81899a0409cfee63f509b81d6962" + integrity sha512-bAwKyWb2/Wm6GS7OpQg1lWgcq+VDBXTKy5oFGX3edbpZFsrb59Ln1v+1jI888zRq4ehDBybhx8WTxPKTJnU+jA== dependencies: - "@parcel/plugin" "2.3.2" + "@parcel/plugin" "2.4.1" json5 "^2.2.0" -"@parcel/transformer-raw@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/transformer-raw/-/transformer-raw-2.3.2.tgz#40d21773e295bae3b16bfe7a89e414ccf534b9c5" - integrity sha512-lY7eOCaALZ90+GH+4PZRmAPGQRXoZ66NakSdhEtH6JSSAYOmZKDvNLGTMRo/vK1oELzWMuAHGdqvbcPDtNLLVw== +"@parcel/transformer-raw@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/transformer-raw/-/transformer-raw-2.4.1.tgz#5e1842fbd661b6058294a7ba984a34b6896c3e65" + integrity sha512-0PzdWJSGSTQ522aohymHEnq4GABy0mHSs+LkPZyMfNmX9ZAIyy6XuFJ9dz8nUmP4Nhn8qDvbRjoAYXR3XsGDGQ== dependencies: - "@parcel/plugin" "2.3.2" + "@parcel/plugin" "2.4.1" -"@parcel/transformer-react-refresh-wrap@^2.3.1": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/transformer-react-refresh-wrap/-/transformer-react-refresh-wrap-2.3.2.tgz#43ecfe6f4567b88abb81db9fe56b8d860d6a69f7" - integrity sha512-FZaderyCExn0SBZ6D+zHPWc8JSn9YDcbfibv0wkCl+D7sYfeWZ22i7MRp5NwCe/TZ21WuxDWySCggEp/Waz2xg== +"@parcel/transformer-react-refresh-wrap@^2.3.2": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/transformer-react-refresh-wrap/-/transformer-react-refresh-wrap-2.4.1.tgz#14f9194f30e417b46fc325f78ee4035254670f64" + integrity sha512-zF6pzj/BwSiD1jA/BHDCEJnKSIDekjblU+OWp1WpSjA1uYkJORuZ5knLcq6mXOQ8M2NCbOXosc1ru8071i8sYA== dependencies: - "@parcel/plugin" "2.3.2" - "@parcel/utils" "2.3.2" + "@parcel/plugin" "2.4.1" + "@parcel/utils" "2.4.1" react-refresh "^0.9.0" "@parcel/types@2.3.1": @@ -2069,17 +2069,17 @@ "@parcel/workers" "2.3.1" utility-types "^3.10.0" -"@parcel/types@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/types/-/types-2.3.2.tgz#7eb6925bc852a518dd75b742419e51292418769f" - integrity sha512-C77Ct1xNM7LWjPTfe/dQ/9rq1efdsX5VJu2o8/TVi6qoFh64Wp/c5/vCHwKInOTBZUTchVO6z4PGJNIZoUVJuA== +"@parcel/types@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/types/-/types-2.4.1.tgz#4cd7b99db403ec36a1fe9f31a6320b2f6148f580" + integrity sha512-YqkiyGS8oiD89Z2lJP7sbjn0F0wlSJMAuqgqf7obeKj0zmZJS7n2xK0uUEuIlUO+Cbqgl0kCGsUSjuT8xcEqjg== dependencies: - "@parcel/cache" "2.3.2" - "@parcel/diagnostic" "2.3.2" - "@parcel/fs" "2.3.2" - "@parcel/package-manager" "2.3.2" + "@parcel/cache" "2.4.1" + "@parcel/diagnostic" "2.4.1" + "@parcel/fs" "2.4.1" + "@parcel/package-manager" "2.4.1" "@parcel/source-map" "^2.0.0" - "@parcel/workers" "2.3.2" + "@parcel/workers" "2.4.1" utility-types "^3.10.0" "@parcel/utils@2.3.1": @@ -2095,16 +2095,16 @@ "@parcel/source-map" "^2.0.0" chalk "^4.1.0" -"@parcel/utils@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/utils/-/utils-2.3.2.tgz#4aab052fc9f3227811a504da7b9663ca75004f55" - integrity sha512-xzZ+0vWhrXlLzGoz7WlANaO5IPtyWGeCZruGtepUL3yheRWb1UU4zFN9xz7Z+j++Dmf1Fgkc3qdk/t4O8u9HLQ== +"@parcel/utils@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/utils/-/utils-2.4.1.tgz#1d8e30fc0fb61a52c3445235f0ed2e0130a29797" + integrity sha512-hmbrnPtFAfMT6s9FMMIVlIzCwEFX/+byB67GoJmSCAMRmj6RMu4a6xKlv2FdzkTKJV2ucg8vxAcua0MQ/q8rkQ== dependencies: - "@parcel/codeframe" "2.3.2" - "@parcel/diagnostic" "2.3.2" - "@parcel/hash" "2.3.2" - "@parcel/logger" "2.3.2" - "@parcel/markdown-ansi" "2.3.2" + "@parcel/codeframe" "2.4.1" + "@parcel/diagnostic" "2.4.1" + "@parcel/hash" "2.4.1" + "@parcel/logger" "2.4.1" + "@parcel/markdown-ansi" "2.4.1" "@parcel/source-map" "^2.0.0" chalk "^4.1.0" @@ -2128,15 +2128,15 @@ chrome-trace-event "^1.0.2" nullthrows "^1.1.1" -"@parcel/workers@2.3.2": - version "2.3.2" - resolved "https://registry.yarnpkg.com/@parcel/workers/-/workers-2.3.2.tgz#05ffa2da9169bfb83335892c2b8abce55686ceb1" - integrity sha512-JbOm+Ceuyymd1SuKGgodC2EXAiPuFRpaNUSJpz3NAsS3lVIt2TDAPMOWBivS7sML/KltspUfl/Q9YwO0TPUFNw== +"@parcel/workers@2.4.1": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@parcel/workers/-/workers-2.4.1.tgz#27bc3ac703625bc1694873fee07fdbeaf555d987" + integrity sha512-EYujbJOblFqIt2NGQ+baIYTuavJqbhy84IfZ3j0jmACeKO5Ew1EHXZyl9LJgWHKaIPZsnvnbxw2mDOF05K65xQ== dependencies: - "@parcel/diagnostic" "2.3.2" - "@parcel/logger" "2.3.2" - "@parcel/types" "2.3.2" - "@parcel/utils" "2.3.2" + "@parcel/diagnostic" "2.4.1" + "@parcel/logger" "2.4.1" + "@parcel/types" "2.4.1" + "@parcel/utils" "2.4.1" chrome-trace-event "^1.0.2" nullthrows "^1.1.1" @@ -2312,10 +2312,10 @@ "@svgr/plugin-jsx" "^6.2.1" "@svgr/plugin-svgo" "^6.2.0" -"@swc/helpers@^0.2.11": - version "0.2.14" - resolved "https://registry.yarnpkg.com/@swc/helpers/-/helpers-0.2.14.tgz#20288c3627442339dd3d743c944f7043ee3590f0" - integrity sha512-wpCQMhf5p5GhNg2MmGKXzUNwxe7zRiCsmqYsamez2beP7mKPCSiu+BjZcdN95yYSzO857kr0VfQewmGpS77nqA== +"@swc/helpers@^0.3.6": + version "0.3.8" + resolved "https://registry.yarnpkg.com/@swc/helpers/-/helpers-0.3.8.tgz#5b9ecf4ee480ca00f1ffbc2d1a5d4eed0d1afe81" + integrity sha512-aWItSZvJj4+GI6FWkjZR13xPNPctq2RRakzo+O6vN7bC2yjwdg5EFpgaSAUn95b7BGSgcflvzVDPoKmJv24IOg== "@szmarczak/http-timer@^1.1.2": version "1.1.2" @@ -3339,23 +3339,23 @@ babel-plugin-polyfill-regenerator@^0.3.0: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" -babel-plugin-remove-graphql-queries@^4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.10.1.tgz#09357b7afad1d1bf359d97701ba267bf968197f4" - integrity sha512-1Irx5lUoQtU56u1hMtrgipjlRsUF4Pz6WDCDNVyTuvcHqlKHQK6pna4igHrdoWhSSgEcbimlxSy6tTvP6bkplg== +babel-plugin-remove-graphql-queries@^4.10.1, babel-plugin-remove-graphql-queries@^4.11.1: + version "4.11.1" + resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.11.1.tgz#6f107865e8c1a83807c4b48b2262f5e0e0ba537e" + integrity sha512-Bqbeow4Xf+Vm4YhAucRGJjf9pNAXakSndYiLKfvef/W6mdtBh00SM8FMaX0U3rtR7ZUXV63RmIyOybVQ6SWCyg== dependencies: "@babel/runtime" "^7.15.4" - gatsby-core-utils "^3.10.1" + gatsby-core-utils "^3.11.1" babel-plugin-transform-react-remove-prop-types@^0.4.24: version "0.4.24" resolved "https://registry.yarnpkg.com/babel-plugin-transform-react-remove-prop-types/-/babel-plugin-transform-react-remove-prop-types-0.4.24.tgz#f2edaf9b4c6a5fbe5c1d678bfb531078c1555f3a" integrity sha512-eqj0hVcJUR57/Ug2zE1Yswsw4LhuqqHhD+8v120T1cl3kjg76QwtyBrdIk4WVwK+lAhBJVYCd/v+4nc4y+8JsA== -babel-preset-gatsby@^2.10.1: - version "2.10.1" - resolved "https://registry.yarnpkg.com/babel-preset-gatsby/-/babel-preset-gatsby-2.10.1.tgz#a31fe2f4b4ed64204baca5ea8267639a00dd1a6b" - integrity sha512-wuEP2Tsf7MnblXIqJDdg+DOUXZhWQHBQYH/6cQ+HdEFiXu0gwskj/s5sPI6KoBgGK23EIZGr94HBtCq0D3aNRQ== +babel-preset-gatsby@^2.11.1: + version "2.11.1" + resolved "https://registry.yarnpkg.com/babel-preset-gatsby/-/babel-preset-gatsby-2.11.1.tgz#860d8d9903df38c314fa6f0cfdb197d02555c4e4" + integrity sha512-NGUNAIb3hzD1Mt97q5T3gSSuVuaqnYFSm7AvgByDa3Mk2ohF5Ni86sCLVPRIntIzJvgU5OWY4Qz+6rrI1SwprQ== dependencies: "@babel/plugin-proposal-class-properties" "^7.14.0" "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" @@ -3370,8 +3370,8 @@ babel-preset-gatsby@^2.10.1: babel-plugin-dynamic-import-node "^2.3.3" babel-plugin-macros "^2.8.0" babel-plugin-transform-react-remove-prop-types "^0.4.24" - gatsby-core-utils "^3.10.1" - gatsby-legacy-polyfills "^2.10.0" + gatsby-core-utils "^3.11.1" + gatsby-legacy-polyfills "^2.11.0" backo2@^1.0.2, backo2@~1.0.2: version "1.0.2" @@ -4340,10 +4340,10 @@ create-ecdh@^4.0.0: bn.js "^4.1.0" elliptic "^6.5.3" -create-gatsby@^2.10.2: - version "2.10.2" - resolved "https://registry.yarnpkg.com/create-gatsby/-/create-gatsby-2.10.2.tgz#ded9eb4066078845529a02bc966ef414a77b814a" - integrity sha512-OmuFey3Eoaek20m8Br/iIqEr76AUrl/ThCn7TBYJ6RvWVKezKV5UksQlFpdQgPK8kO9LogjkmiyA0k94VC3nXg== +create-gatsby@^2.11.1: + version "2.11.1" + resolved "https://registry.yarnpkg.com/create-gatsby/-/create-gatsby-2.11.1.tgz#8d73cce07ff0006386795ca1b74a0bdbb023500b" + integrity sha512-ltSLSsbQRoCXxKzgkxp5PBv60O1BL0IdeKKbgmwEcYxiDVw4pXPcFmIqMmvHfk9fqzbCyPzehIQHdlEpJGDYwQ== dependencies: "@babel/runtime" "^7.15.4" @@ -6158,10 +6158,10 @@ gatsby-background-image@1.6.0: short-uuid "^4.2.0" sort-media-queries "^0.2.2" -gatsby-cli@^4.10.2: - version "4.10.2" - resolved "https://registry.yarnpkg.com/gatsby-cli/-/gatsby-cli-4.10.2.tgz#835a2c472d5cd1b9258e5208f7f7184e5fd1b97b" - integrity sha512-lA1zFuWZwE+VtKYgntls0EC5PG4QoqqeJFWP+83Lmh+9hoLLkmL1plALBQeI3JY/9KXgRiC4OoR94CQkI329TA== +gatsby-cli@^4.11.1: + version "4.11.1" + resolved "https://registry.yarnpkg.com/gatsby-cli/-/gatsby-cli-4.11.1.tgz#a549a91cbd7e7bb9a98413cf604af09d10ef75c2" + integrity sha512-RDOFIzKAyysa51x0mMoMtdVhyOX2UkBuEyelGqpuchl8b/ddka/cjEYHk3QRSq55+cBN0/1cTHt/A139ooAKUg== dependencies: "@babel/code-frame" "^7.14.0" "@babel/core" "^7.15.5" @@ -6179,13 +6179,13 @@ gatsby-cli@^4.10.2: common-tags "^1.8.2" configstore "^5.0.1" convert-hrtime "^3.0.0" - create-gatsby "^2.10.2" + create-gatsby "^2.11.1" envinfo "^7.8.1" execa "^5.1.1" fs-exists-cached "^1.0.0" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.1" - gatsby-telemetry "^3.10.1" + gatsby-core-utils "^3.11.1" + gatsby-telemetry "^3.11.1" hosted-git-info "^3.0.8" is-valid-path "^0.1.1" joi "^17.4.2" @@ -6209,10 +6209,10 @@ gatsby-cli@^4.10.2: yoga-layout-prebuilt "^1.10.0" yurnalist "^2.1.0" -gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.8.2: - version "3.10.1" - resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.10.1.tgz#0f5e6aeda5ef4b86218b27480a9766fe30af4393" - integrity sha512-WqNMm0u1CAZm6Q+UQ4dDHwIAt3l32NeIaPuSXmDX7QcMGR3FUUk8cl2Ym6gx1hfILm1aCexqfaSCLUXtaWKkbQ== +gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.11.1, gatsby-core-utils@^3.8.2: + version "3.11.1" + resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.11.1.tgz#ea87c1d3aa45c26c9ea32b8e8b029afe6a56f8c7" + integrity sha512-Op9/uihtcsDLlZDfRsGJ1ya2mFx2YH9Zmx93bawElZ0YpIzKjCkNTp+I5i5UANxvs5I+Fljl0WHQRudMWg+fWA== dependencies: "@babel/runtime" "^7.15.4" ci-info "2.0.0" @@ -6230,67 +6230,67 @@ gatsby-core-utils@^3.10.0, gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.8.2: tmp "^0.2.1" xdg-basedir "^4.0.0" -gatsby-graphiql-explorer@^2.10.0: - version "2.10.0" - resolved "https://registry.yarnpkg.com/gatsby-graphiql-explorer/-/gatsby-graphiql-explorer-2.10.0.tgz#6d36ed936170673b7439989c2617369a151c4e51" - integrity sha512-JZJZwsOuBA0eQ3hzI/jxCgOWj6ziHRg7kyh6hp9CfdEHLhYauL02U0HFkNrKnFy4Ld2W83T91fcpXztM7A/L/w== +gatsby-graphiql-explorer@^2.11.0: + version "2.11.0" + resolved "https://registry.yarnpkg.com/gatsby-graphiql-explorer/-/gatsby-graphiql-explorer-2.11.0.tgz#7e886846482ad72bd49f515e7faa658a94342803" + integrity sha512-nMNXlF/pleO/rH66t00SdXdKq3vV0/Su5EEQY7xg3yRc38ueC2UkZq10nrJiVoc05RO8Txo5o2gpoC2DP07lFg== dependencies: "@babel/runtime" "^7.15.4" -gatsby-legacy-polyfills@^2.10.0: - version "2.10.0" - resolved "https://registry.yarnpkg.com/gatsby-legacy-polyfills/-/gatsby-legacy-polyfills-2.10.0.tgz#f2d3b85f27644f77aaa428eac1e0d1e5f96343da" - integrity sha512-+S6Nv2vFqtsa/waxb/dW2xpIqk/l44fFnz9bb1vuS/+mDNLd1Xb/SKdGzxWLSSNbI8CY3JoJC+AAzO6fOqIyLg== +gatsby-legacy-polyfills@^2.11.0: + version "2.11.0" + resolved "https://registry.yarnpkg.com/gatsby-legacy-polyfills/-/gatsby-legacy-polyfills-2.11.0.tgz#8b2afc4d97f44eb5767fe9b49f55ff675055ffd2" + integrity sha512-ulkRNCitwFjwUM4f2ufljH0WjELm6QEIOGRryNRt9LKJEB9QGmdm+KUAWIv7xrFUqKq1Pn6is64wcfXDw21zSA== dependencies: "@babel/runtime" "^7.15.4" core-js-compat "3.9.0" -gatsby-link@^4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby-link/-/gatsby-link-4.10.1.tgz#f68b04b900c9c81070913d65a6e4051a2266dc1b" - integrity sha512-U9Qry93Q+aXF9acs1YPH+wzipPlZELUa619CAhZnLv2sk75Iq5SttMZI/d0uhgF+X80PvoEKMkLb/VE4YiqVtw== +gatsby-link@^4.11.1: + version "4.11.1" + resolved "https://registry.yarnpkg.com/gatsby-link/-/gatsby-link-4.11.1.tgz#f8bfee4c7f3bf0ede255bddf87d0f13c64ed39f2" + integrity sha512-wOhdgsnzHr4iYWo3iKadw8jj5PmIu1wbi6LUftwQzFOFvkBaJvC/br1ju8W0nbwSjWG474hTZRon43xDQX9bIw== dependencies: "@babel/runtime" "^7.15.4" "@types/reach__router" "^1.3.10" - gatsby-page-utils "^2.10.1" + gatsby-page-utils "^2.11.1" prop-types "^15.7.2" -gatsby-page-utils@^2.10.1: - version "2.10.1" - resolved "https://registry.yarnpkg.com/gatsby-page-utils/-/gatsby-page-utils-2.10.1.tgz#39420dd41508ca2793f0c838816b16fd10bbc8d7" - integrity sha512-juhN7/cLKoFGPW37xBCN78D02yO1htxR3raO/f2iseCCsyDjXRnqGHgpdFu8g8s8bkukL5vscgALcyChQf7NtA== +gatsby-page-utils@^2.11.1: + version "2.11.1" + resolved "https://registry.yarnpkg.com/gatsby-page-utils/-/gatsby-page-utils-2.11.1.tgz#dd10f99184b64528ae76f2b654b8ed1b23cb9c39" + integrity sha512-K1Mbk4CKYZwpJcE4zk4JAff7ZBNFXI0fC8lZwLbDAzVcqYUaouqqqnoU7WeB8HHUqDQi05CXItx1bbZFDGIymw== dependencies: "@babel/runtime" "^7.15.4" bluebird "^3.7.2" chokidar "^3.5.2" fs-exists-cached "^1.0.0" - gatsby-core-utils "^3.10.1" + gatsby-core-utils "^3.11.1" glob "^7.2.0" lodash "^4.17.21" micromatch "^4.0.4" -gatsby-parcel-config@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/gatsby-parcel-config/-/gatsby-parcel-config-0.1.0.tgz#8d42731799b875428db4836a6c9248438affd361" - integrity sha512-IbPqIW1kaa2SsVCT0jjlkyqgiT3DEE0XilSANNDdcdq23NpenwEo496uW5zt13sOUXEjX4QuHcrDmGvAMYiRNA== +gatsby-parcel-config@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/gatsby-parcel-config/-/gatsby-parcel-config-0.2.0.tgz#0b1795d17c825bd293c372fa0acfa987aa91111e" + integrity sha512-BbsSm5O0R7IvCRLNSk3lBpkU8RtSOn8s7Ifa7bHF63PzTG1SUpBjwMF6301tCbvdSXWrP7n9dsfaXS6ex/TElQ== dependencies: "@gatsbyjs/parcel-namer-relative-to-cwd" "0.0.2" - "@parcel/bundler-default" "^2.3.1" - "@parcel/compressor-raw" "^2.3.1" - "@parcel/namer-default" "^2.3.1" - "@parcel/optimizer-terser" "^2.3.1" - "@parcel/packager-js" "^2.3.1" - "@parcel/packager-raw" "^2.3.1" - "@parcel/reporter-dev-server" "^2.3.1" - "@parcel/resolver-default" "^2.3.1" - "@parcel/runtime-browser-hmr" "^2.3.1" - "@parcel/runtime-js" "^2.3.1" - "@parcel/runtime-react-refresh" "^2.3.1" - "@parcel/runtime-service-worker" "^2.3.1" - "@parcel/transformer-js" "^2.3.1" - "@parcel/transformer-json" "^2.3.1" - "@parcel/transformer-raw" "^2.3.1" - "@parcel/transformer-react-refresh-wrap" "^2.3.1" + "@parcel/bundler-default" "^2.3.2" + "@parcel/compressor-raw" "^2.3.2" + "@parcel/namer-default" "^2.3.2" + "@parcel/optimizer-terser" "^2.3.2" + "@parcel/packager-js" "^2.3.2" + "@parcel/packager-raw" "^2.3.2" + "@parcel/reporter-dev-server" "^2.3.2" + "@parcel/resolver-default" "^2.3.2" + "@parcel/runtime-browser-hmr" "^2.3.2" + "@parcel/runtime-js" "^2.3.2" + "@parcel/runtime-react-refresh" "^2.3.2" + "@parcel/runtime-service-worker" "^2.3.2" + "@parcel/transformer-js" "^2.3.2" + "@parcel/transformer-json" "^2.3.2" + "@parcel/transformer-raw" "^2.3.2" + "@parcel/transformer-react-refresh-wrap" "^2.3.2" gatsby-plugin-image@2.10.1: version "2.10.1" @@ -6322,20 +6322,20 @@ gatsby-plugin-manifest@4.10.2: semver "^7.3.5" sharp "^0.30.1" -gatsby-plugin-page-creator@^4.10.2: - version "4.10.2" - resolved "https://registry.yarnpkg.com/gatsby-plugin-page-creator/-/gatsby-plugin-page-creator-4.10.2.tgz#05e6e3b0bdf800a4358573768987ed73d50eb158" - integrity sha512-6oVkPe69dGnq4ZiUgTuuIzTyOTmC/awXyfCdfkvQHQZRqhyzhHMW95aFgr3y/qNlOmCKDaxYmxeT0KOKxcyxWw== +gatsby-plugin-page-creator@^4.11.1: + version "4.11.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-page-creator/-/gatsby-plugin-page-creator-4.11.1.tgz#750f4b773684777cec6caa9266787427ed2630a6" + integrity sha512-6XET4qYqu2yVwUU6sO44wSR62zQZdq7BoMvN9OhKpUDBZYLfve9CwufkhZZnQvq+axNZZMUmKa/RqbBXiE6/yA== dependencies: "@babel/runtime" "^7.15.4" "@babel/traverse" "^7.15.4" "@sindresorhus/slugify" "^1.1.2" chokidar "^3.5.2" fs-exists-cached "^1.0.0" - gatsby-core-utils "^3.10.1" - gatsby-page-utils "^2.10.1" - gatsby-plugin-utils "^3.4.2" - gatsby-telemetry "^3.10.1" + gatsby-core-utils "^3.11.1" + gatsby-page-utils "^2.11.1" + gatsby-plugin-utils "^3.5.1" + gatsby-telemetry "^3.11.1" globby "^11.0.4" lodash "^4.17.21" @@ -6402,10 +6402,10 @@ gatsby-plugin-svgr@3.0.0-beta.0: resolved "https://registry.yarnpkg.com/gatsby-plugin-svgr/-/gatsby-plugin-svgr-3.0.0-beta.0.tgz#7e5315f51dae2663a447899322ea1487cef93dd6" integrity sha512-oALTh6VwO6l3khgC/vGr706aqt38EkXwdr6iXVei/auOKGxpCLEuDCQVal1a4SpYXdjHjRsEyab6bxaHL2lzsA== -gatsby-plugin-typescript@^4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-typescript/-/gatsby-plugin-typescript-4.10.1.tgz#1d94532f4cd97677c38bda3b4d92a50b3856e11d" - integrity sha512-yQZYRAZwtj20OrvsF8+xr9V0Jew//3HghM1LKvCB58wECvwLW9SXHzema92JubirFOk7VrdeQfVe3u4jCYDDYw== +gatsby-plugin-typescript@^4.11.1: + version "4.11.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-typescript/-/gatsby-plugin-typescript-4.11.1.tgz#dcd96ded685f8c4a73ae5524faab342f9c9e3c1d" + integrity sha512-6ef2wRhPqcLPyekEAU3xcoqI59r+mDnCzn/O+8hRgwJyx/2dwvF8brusetXoqdTk4Vyhk44p8dog8+gCGATckw== dependencies: "@babel/core" "^7.15.5" "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" @@ -6413,34 +6413,34 @@ gatsby-plugin-typescript@^4.10.1: "@babel/plugin-proposal-optional-chaining" "^7.14.5" "@babel/preset-typescript" "^7.15.0" "@babel/runtime" "^7.15.4" - babel-plugin-remove-graphql-queries "^4.10.1" + babel-plugin-remove-graphql-queries "^4.11.1" -gatsby-plugin-utils@^3.4.2: - version "3.4.2" - resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.4.2.tgz#bdc66fd52c052c91af443981e1facbc097429dc7" - integrity sha512-HkVR8BnEdc915pmY2L9wPwFgjq303ThMH9UtT+frDOPzn+GFjPlBF5+YGJ3tZaxH0ouwpnGTn3Pu37tcRZcctA== +gatsby-plugin-utils@^3.4.2, gatsby-plugin-utils@^3.5.1: + version "3.5.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.5.1.tgz#9aed9deec0f4ee82bfc7390f735b9455ca4f8494" + integrity sha512-RZXUvwQjTnkukMfAGr+DCz/qZj7g6REljTmQS43MaovWO4Yf4YGvs+1Leays7J0XmqN2I3SIZGBgt4tgKCsNVQ== dependencies: "@babel/runtime" "^7.15.4" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.1" - gatsby-sharp "^0.4.0" + gatsby-core-utils "^3.11.1" + gatsby-sharp "^0.5.0" graphql-compose "^9.0.7" import-from "^4.0.0" joi "^17.4.2" mime "^3.0.0" -gatsby-react-router-scroll@^5.10.0: - version "5.10.0" - resolved "https://registry.yarnpkg.com/gatsby-react-router-scroll/-/gatsby-react-router-scroll-5.10.0.tgz#4a146dbe4079024290b21599a67238189f73cd40" - integrity sha512-uyWRQTNsHoQHJKZxnpHX4wmtS6ptVmUKGkUqox367gDPm6FHAGUF/Jv630C8xYZJ9Y8TuozlZqdquWTpuLDRFw== +gatsby-react-router-scroll@^5.11.0: + version "5.11.0" + resolved "https://registry.yarnpkg.com/gatsby-react-router-scroll/-/gatsby-react-router-scroll-5.11.0.tgz#866b89366146d8df3852ed699d12be1e9fce4acc" + integrity sha512-g/lyG0X73cpI9DdYvCv5rZiV8LqHjn6q1l8Vfm/jBS7wtv8XxNR4BxUqkbMeHRcvZcX5bXku6FFSFUAOd9c3QQ== dependencies: "@babel/runtime" "^7.15.4" prop-types "^15.7.2" -gatsby-sharp@^0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/gatsby-sharp/-/gatsby-sharp-0.4.0.tgz#9e26c004935750bd334fb041da1b0ad5a5a6955c" - integrity sha512-Q2iP6HEs1MRdcMRj7NwZ4l6/1U61vx2DrWNgGwqEEhIFAAgUMlWscaeCpEgahC3t4D66LmuDQkbzBvBcH0Dwxw== +gatsby-sharp@^0.5.0: + version "0.5.0" + resolved "https://registry.yarnpkg.com/gatsby-sharp/-/gatsby-sharp-0.5.0.tgz#879d3c462eefa917cb3a50c6ec891951d9740f56" + integrity sha512-9wZS0ADZsKTCsU66sxIP/tCHgFaREyoYm53tepgtp/YSVWNrurx9/0kGf8XsFFY9OecrqIRNuk1cWe7XKCpbQA== dependencies: "@types/sharp" "^0.29.5" sharp "^0.30.1" @@ -6463,10 +6463,10 @@ gatsby-source-filesystem@4.10.1: valid-url "^1.0.9" xstate "^4.26.1" -gatsby-telemetry@^3.10.1: - version "3.10.1" - resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.10.1.tgz#129c4309811cd9b2ba5e9d326ba47dddb59202ca" - integrity sha512-935quI1YsQfzYREuvPLNKBb7IUE2vX9p7WoS7Dc9TbV2xDZPTAzeOfX+HE56ZltkxMi8Zivp7mqe5+n//WL7EQ== +gatsby-telemetry@^3.10.1, gatsby-telemetry@^3.11.1: + version "3.11.1" + resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.11.1.tgz#87caed899143276056e9af20ab38c15ad9dcdf52" + integrity sha512-TPNKTpuYFyULOuRvhpXUtj8h2E7bvrTYsRC/aKeHoWqEchwwbzPwBSJd+3ZFjsxLHIXAa5sTAlR2wd9SYBgOlA== dependencies: "@babel/code-frame" "^7.14.0" "@babel/runtime" "^7.15.4" @@ -6476,7 +6476,7 @@ gatsby-telemetry@^3.10.1: boxen "^4.2.0" configstore "^5.0.1" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.1" + gatsby-core-utils "^3.11.1" git-up "^4.0.5" is-docker "^2.2.1" lodash "^4.17.21" @@ -6506,18 +6506,18 @@ gatsby-transformer-yaml@4.10.0: lodash "^4.17.21" unist-util-select "^1.5.0" -gatsby-worker@^1.10.1: - version "1.10.1" - resolved "https://registry.yarnpkg.com/gatsby-worker/-/gatsby-worker-1.10.1.tgz#d2549c9854effe3319bd4bd199be0a5c4d077af2" - integrity sha512-1bHZjWEKppJSLfuRGYIYhHZt9vYffptMPRs3zmrYBocmZcJvq0eNhTIXUvThbhP+2XHqAPHHBUcyKCwlWlMAzA== +gatsby-worker@^1.11.0: + version "1.11.0" + resolved "https://registry.yarnpkg.com/gatsby-worker/-/gatsby-worker-1.11.0.tgz#bf8c3b9374390260b8335d7cfccbc332d0716727" + integrity sha512-uJ5bNrifIrS20o0SYkmb379logfRKO35cqYxd2R0uNf9kWGaQOda0SZfm7Uw+Vdx7cO9Ra8p1ArijbHm7ZArCA== dependencies: "@babel/core" "^7.15.5" "@babel/runtime" "^7.15.4" -gatsby@4.10.3: - version "4.10.3" - resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-4.10.3.tgz#72d9620d3f9a90c96e568f4803f86458d1dc6a53" - integrity sha512-G6YYwQWrN99KhJgLQl/oy3oKRuTdUcW7Bgb9vRchjY/Apk0eTA2wq33W5L9y+npR3nxly6ZJ2pM8FHw7WX4tKg== +gatsby@4.11.1: + version "4.11.1" + resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-4.11.1.tgz#ffe7754c9c368fd746bdeca808572641a378addb" + integrity sha512-ffEXb/mvZtB0cQ8javEkhruubxjTbZSsN81IYGGY/ym4YB+Zm1a8K0NV7DsRGsPO9nx7Z/D/OBVxVmse1Nnxzw== dependencies: "@babel/code-frame" "^7.14.0" "@babel/core" "^7.15.5" @@ -6530,7 +6530,7 @@ gatsby@4.10.3: "@gatsbyjs/reach-router" "^1.3.6" "@gatsbyjs/webpack-hot-middleware" "^2.25.2" "@nodelib/fs.walk" "^1.2.8" - "@parcel/core" "^2.3.1" + "@parcel/core" "^2.3.2" "@pmmmwh/react-refresh-webpack-plugin" "^0.4.3" "@types/http-proxy" "^1.17.7" "@typescript-eslint/eslint-plugin" "^4.33.0" @@ -6544,8 +6544,8 @@ gatsby@4.10.3: babel-plugin-add-module-exports "^1.0.4" babel-plugin-dynamic-import-node "^2.3.3" babel-plugin-lodash "^3.3.4" - babel-plugin-remove-graphql-queries "^4.10.1" - babel-preset-gatsby "^2.10.1" + babel-plugin-remove-graphql-queries "^4.11.1" + babel-preset-gatsby "^2.11.1" better-opn "^2.1.1" bluebird "^3.7.2" body-parser "^1.19.0" @@ -6587,19 +6587,19 @@ gatsby@4.10.3: find-cache-dir "^3.3.2" fs-exists-cached "1.0.0" fs-extra "^10.0.0" - gatsby-cli "^4.10.2" - gatsby-core-utils "^3.10.1" - gatsby-graphiql-explorer "^2.10.0" - gatsby-legacy-polyfills "^2.10.0" - gatsby-link "^4.10.1" - gatsby-page-utils "^2.10.1" - gatsby-parcel-config "^0.1.0" - gatsby-plugin-page-creator "^4.10.2" - gatsby-plugin-typescript "^4.10.1" - gatsby-plugin-utils "^3.4.2" - gatsby-react-router-scroll "^5.10.0" - gatsby-telemetry "^3.10.1" - gatsby-worker "^1.10.1" + gatsby-cli "^4.11.1" + gatsby-core-utils "^3.11.1" + gatsby-graphiql-explorer "^2.11.0" + gatsby-legacy-polyfills "^2.11.0" + gatsby-link "^4.11.1" + gatsby-page-utils "^2.11.1" + gatsby-parcel-config "^0.2.0" + gatsby-plugin-page-creator "^4.11.1" + gatsby-plugin-typescript "^4.11.1" + gatsby-plugin-utils "^3.5.1" + gatsby-react-router-scroll "^5.11.0" + gatsby-telemetry "^3.11.1" + gatsby-worker "^1.11.0" glob "^7.2.0" globby "^11.1.0" got "^11.8.2" @@ -6672,7 +6672,7 @@ gatsby@4.10.3: xstate "^4.26.0" yaml-loader "^0.6.0" optionalDependencies: - gatsby-sharp "^0.4.0" + gatsby-sharp "^0.5.0" gauge@~2.7.3: version "2.7.4" @@ -8096,6 +8096,17 @@ listr2@^3.8.3: through "^2.3.8" wrap-ansi "^7.0.0" +lmdb@2.2.4: + version "2.2.4" + resolved "https://registry.yarnpkg.com/lmdb/-/lmdb-2.2.4.tgz#6494d5a1d1db152e0be759edcfa06893e4cbdb53" + integrity sha512-gto+BB2uEob8qRiTlOq+R3uX0YNHsX9mjxj9Sbdue/LIKqu6IlZjrsjKeGyOMquc/474GEqFyX2pdytpydp0rQ== + dependencies: + msgpackr "^1.5.4" + nan "^2.14.2" + node-gyp-build "^4.2.3" + ordered-binary "^1.2.4" + weak-lru-cache "^1.2.2" + lmdb@^2.0.2, lmdb@^2.2.3, lmdb@^2.2.4: version "2.2.6" resolved "https://registry.yarnpkg.com/lmdb/-/lmdb-2.2.6.tgz#a52ef533812b8abcbe0033fc9d74d215e7dfc0a0" @@ -8753,7 +8764,7 @@ msgpackr-extract@^1.0.14: nan "^2.14.2" node-gyp-build "^4.2.3" -msgpackr@^1.5.1, msgpackr@^1.5.4: +msgpackr@^1.5.4: version "1.5.4" resolved "https://registry.yarnpkg.com/msgpackr/-/msgpackr-1.5.4.tgz#2b6ea6cb7d79c0ad98fc76c68163c48eda50cf0d" integrity sha512-Z7w5Jg+2Q9z9gJxeM68d7tSuWZZGnFIRhZnyqcZCa/1dKkhOCNvR1TUV3zzJ3+vj78vlwKRzUgVDlW4jiSOeDA== From 7a400be362ad718d8fb81457b36738cd59036863 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 13:05:56 +0000 Subject: [PATCH 104/240] build(deps-dev): bump eslint-config-next in /packages/dashboard Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 12.1.1 to 12.1.4. - [Release notes](https://github.com/vercel/next.js/releases) - [Changelog](https://github.com/vercel/next.js/blob/canary/release.js) - [Commits](https://github.com/vercel/next.js/commits/v12.1.4/packages/eslint-config-next) --- updated-dependencies: - dependency-name: eslint-config-next dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 7917eb36..f25952ed 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -36,7 +36,7 @@ "@tailwindcss/typography": "0.5.2", "autoprefixer": "10.4.4", "eslint": "8.12.0", - "eslint-config-next": "12.1.1", + "eslint-config-next": "12.1.4", "postcss": "8.4.12", "prettier": "2.6.2", "tailwindcss": "3.0.23" diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index f0e782a8..b71531a1 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -82,10 +82,10 @@ resolved "https://registry.yarnpkg.com/@next/env/-/env-12.1.4.tgz#5af629b43075281ecd7f87938802b7cf5b67e94b" integrity sha512-7gQwotJDKnfMxxXd8xJ2vsX5AzyDxO3zou0+QOXX8/unypA6icw5+wf6A62yKZ6qQ4UZHHxS68pb6UV+wNneXg== -"@next/eslint-plugin-next@12.1.1": - version "12.1.1" - resolved "https://registry.yarnpkg.com/@next/eslint-plugin-next/-/eslint-plugin-next-12.1.1.tgz#e3e51503e9d7f987a0e080344648bc84ac1e8eb8" - integrity sha512-5hd1VFWZzECADhvA+OE+g0CnrRBFZbPm03HbiUtpk7XeluNn7xVxBU6XvNQA+YrQ7qe5jCK9q7R8MbI9R55Y/Q== +"@next/eslint-plugin-next@12.1.4": + version "12.1.4" + resolved "https://registry.yarnpkg.com/@next/eslint-plugin-next/-/eslint-plugin-next-12.1.4.tgz#9c52637af8eecab24dac3f2e5098376f6fc2dff4" + integrity sha512-BRy565KVK6Cdy8LHaHTiwctLqBu/RT84RLpESug70BDJzBlV8QBvODyx/j7wGhvYqp9kvstM05lyb6JaTkSCcQ== dependencies: glob "7.1.7" @@ -786,12 +786,12 @@ escape-string-regexp@^4.0.0: resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== -eslint-config-next@12.1.1: - version "12.1.1" - resolved "https://registry.yarnpkg.com/eslint-config-next/-/eslint-config-next-12.1.1.tgz#11f948c5f4959267c2157dff8f2c28d067e3e1d9" - integrity sha512-+Ql9F07Pafs+cDgy8Zp0F8FxCBq7ke02ZyC2/MMEiGAX+WlnuUCrboBDnfzmHJpAAkcBPjUthunu6LBnF9KWIQ== +eslint-config-next@12.1.4: + version "12.1.4" + resolved "https://registry.yarnpkg.com/eslint-config-next/-/eslint-config-next-12.1.4.tgz#939ea2ff33034763300bf1e62482cea91212d274" + integrity sha512-Uj0jrVjoQbg9qerxRjSHoOOv3PEzoZxpb8G9LYct25fsflP8xIiUq0l4WEu2KSB5owuLv5hie7wSMqPEsHj+bQ== dependencies: - "@next/eslint-plugin-next" "12.1.1" + "@next/eslint-plugin-next" "12.1.4" "@rushstack/eslint-patch" "1.0.8" "@typescript-eslint/parser" "5.10.1" eslint-import-resolver-node "0.3.4" From 359607542c1d2434c29692e8aaa27ecdb991992a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 13:07:16 +0000 Subject: [PATCH 105/240] build(deps): bump stripe from 8.212.0 to 8.215.0 in /packages/dashboard Bumps [stripe](https://github.com/stripe/stripe-node) from 8.212.0 to 8.215.0. - [Release notes](https://github.com/stripe/stripe-node/releases) - [Changelog](https://github.com/stripe/stripe-node/blob/master/CHANGELOG.md) - [Commits](https://github.com/stripe/stripe-node/compare/v8.212.0...v8.215.0) --- updated-dependencies: - dependency-name: stripe dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 4ba2eedf..c3c2f61f 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -27,7 +27,7 @@ "react-dom": "17.0.2", "react-toastify": "8.2.0", "skynet-js": "3.0.2", - "stripe": "8.212.0", + "stripe": "8.215.0", "swr": "1.2.2", "yup": "0.32.11" }, diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 8ccc3ee4..94fe762f 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -1993,10 +1993,10 @@ punycode@^2.1.0: resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== -qs@^6.6.0: - version "6.10.1" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.10.1.tgz#4931482fa8d647a5aab799c5271d2133b981fb6a" - integrity sha512-M528Hph6wsSVOBiYUnGf+K/7w0hNshs/duGsNXPUCLH5XAqjEtiPGwNONLV0tBH8NoGb0mvD5JubnUTrujKDTg== +qs@^6.10.3: + version "6.10.3" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.10.3.tgz#d6cde1b2ffca87b5aa57889816c5f81535e22e8e" + integrity sha512-wr7M2E0OFRfIfJZjKGieI8lBKb7fRCH4Fv5KNPEs7gJ8jadvotdsS08PzOKR7opXhZ/Xkjtt3WF9g38drmyRqQ== dependencies: side-channel "^1.0.4" @@ -2264,13 +2264,13 @@ strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== -stripe@8.212.0: - version "8.212.0" - resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.212.0.tgz#78dc8d2be770580be23a8e597641a9ace6fd1035" - integrity sha512-xQ2uPMRAmRyOiMZktw3hY8jZ8LFR9lEQRPEaQ5WcDcn51kMyn46GeikOikxiFTHEN8PeKRdwtpz4yNArAvu/Kg== +stripe@8.215.0: + version "8.215.0" + resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.215.0.tgz#bb464e256fb83da9ea2f514711fd0f6f7ae7dc9a" + integrity sha512-M+7iTZ9bzTkU1Ms+Zsuh0mTQfEzOjMoqyEaVBpuUmdbWTvshavzpAihsOkfabEu+sNY0vdbQxxHZ4kI3W8pKHQ== dependencies: "@types/node" ">=8.1.0" - qs "^6.6.0" + qs "^6.10.3" styled-jsx@5.0.1: version "5.0.1" From aca857117c4549a7d22a16e08322a8dc5bf4a7c7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 13:09:44 +0000 Subject: [PATCH 106/240] build(deps): bump polished from 4.1.4 to 4.2.1 in /packages/website Bumps [polished](https://github.com/styled-components/polished) from 4.1.4 to 4.2.1. - [Release notes](https://github.com/styled-components/polished/releases) - [Commits](https://github.com/styled-components/polished/compare/v4.1.4...v4.2.1) --- updated-dependencies: - dependency-name: polished dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 25b4069b..f560b94e 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -32,7 +32,7 @@ "nanoid": "3.3.2", "normalize.css": "8.0.1", "path-browserify": "1.0.1", - "polished": "4.1.4", + "polished": "4.2.1", "postcss": "8.4.12", "prop-types": "15.8.1", "react": "17.0.2", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 767963d1..7023ed0f 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -989,10 +989,10 @@ core-js-pure "^3.20.2" regenerator-runtime "^0.13.4" -"@babel/runtime@^7.1.2", "@babel/runtime@^7.10.0", "@babel/runtime@^7.10.2", "@babel/runtime@^7.15.4", "@babel/runtime@^7.16.3", "@babel/runtime@^7.16.5", "@babel/runtime@^7.16.7", "@babel/runtime@^7.7.2", "@babel/runtime@^7.8.4", "@babel/runtime@^7.9.2": - version "7.17.2" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.17.2.tgz#66f68591605e59da47523c631416b18508779941" - integrity sha512-hzeyJyMA1YGdJTuWU0e/j4wKXrU4OMFvY2MSlaI9B7VQb0r5cxTE3EAIS2Q7Tn2RIcDkRvTA/v2JsAEhxe99uw== +"@babel/runtime@^7.1.2", "@babel/runtime@^7.10.0", "@babel/runtime@^7.10.2", "@babel/runtime@^7.15.4", "@babel/runtime@^7.16.3", "@babel/runtime@^7.16.5", "@babel/runtime@^7.16.7", "@babel/runtime@^7.17.8", "@babel/runtime@^7.7.2", "@babel/runtime@^7.8.4", "@babel/runtime@^7.9.2": + version "7.17.8" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.17.8.tgz#3e56e4aff81befa55ac3ac6a0967349fd1c5bca2" + integrity sha512-dQpEpK0O9o6lj6oPu0gRDbbnk+4LeHlNcBpspf6Olzt3GIX4P1lWF1gS+pHLDFlaJvbR6q7jCfQ08zA4QJBnmA== dependencies: regenerator-runtime "^0.13.4" @@ -9555,12 +9555,12 @@ pngjs@^3.0.0, pngjs@^3.3.3: resolved "https://registry.yarnpkg.com/pngjs/-/pngjs-3.4.0.tgz#99ca7d725965fb655814eaf65f38f12bbdbf555f" integrity sha512-NCrCHhWmnQklfH4MtJMRjZ2a8c80qXeMlQMv2uVp9ISJMTt562SbGd6n2oq0PaPgKm7Z6pL9E2UlLIhC+SHL3w== -polished@4.1.4: - version "4.1.4" - resolved "https://registry.yarnpkg.com/polished/-/polished-4.1.4.tgz#640293ba834109614961a700fdacbb6599fb12d0" - integrity sha512-Nq5Mbza+Auo7N3sQb1QMFaQiDO+4UexWuSGR7Cjb4Sw11SZIJcrrFtiZ+L0jT9MBsUsxDboHVASbCLbE1rnECg== +polished@4.2.1: + version "4.2.1" + resolved "https://registry.yarnpkg.com/polished/-/polished-4.2.1.tgz#e38cdf4244b3bea63f77b0f8ab2335e22a66bd08" + integrity sha512-vRkUnHBwVX7kIeCzCghcLCWoDenV+sV7lkItnmTc7bb6Uzbe8ogU1FxqEW8+dXCxUX8YW8vusQ0HTk2yES7bfQ== dependencies: - "@babel/runtime" "^7.16.7" + "@babel/runtime" "^7.17.8" popmotion@11.0.3: version "11.0.3" From cd9af0abfcb6291ed6e5a93191447bf158f39084 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 13:13:20 +0000 Subject: [PATCH 107/240] build(deps): bump gatsby-plugin-manifest in /packages/website Bumps [gatsby-plugin-manifest](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-manifest) from 4.10.2 to 4.11.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-manifest/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-manifest@4.11.1/packages/gatsby-plugin-manifest) --- updated-dependencies: - dependency-name: gatsby-plugin-manifest dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 25b4069b..f77cb367 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -16,7 +16,7 @@ "gatsby": "4.11.1", "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.10.1", - "gatsby-plugin-manifest": "4.10.2", + "gatsby-plugin-manifest": "4.11.1", "gatsby-plugin-postcss": "5.10.0", "gatsby-plugin-react-helmet": "5.10.0", "gatsby-plugin-robots-txt": "1.7.0", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 767963d1..1039bd99 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6311,14 +6311,14 @@ gatsby-plugin-image@2.10.1: objectFitPolyfill "^2.3.5" prop-types "^15.7.2" -gatsby-plugin-manifest@4.10.2: - version "4.10.2" - resolved "https://registry.yarnpkg.com/gatsby-plugin-manifest/-/gatsby-plugin-manifest-4.10.2.tgz#117b44e0e219fa85d6b710d2ed985268d82a1e25" - integrity sha512-2QGrG3qFkUnp0IcxQ+uQS4/jPL4NMHShOEs/7JPsuIJSIdumnG7QYJ9xHbIBb8U5mIFLpeonADYJVbdTsnGtrg== +gatsby-plugin-manifest@4.11.1: + version "4.11.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-manifest/-/gatsby-plugin-manifest-4.11.1.tgz#fb3061c2e989acb2634719c1e8645fd1388f4b3b" + integrity sha512-m5cdi6KBc8+zmnlIfEh92sXpFEUfjuCrjM5BKc8e6v0jxJS0CqVrZOyT12mT2yq9H12UrkzFx1qaI8e2/IJiGA== dependencies: "@babel/runtime" "^7.15.4" - gatsby-core-utils "^3.10.1" - gatsby-plugin-utils "^3.4.2" + gatsby-core-utils "^3.11.1" + gatsby-plugin-utils "^3.5.1" semver "^7.3.5" sharp "^0.30.1" From 8e802306675cee2a529c24f93783ee9516803368 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 13:13:31 +0000 Subject: [PATCH 108/240] build(deps): bump gatsby-transformer-yaml in /packages/website Bumps [gatsby-transformer-yaml](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-transformer-yaml) from 4.10.0 to 4.11.0. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-transformer-yaml/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-transformer-yaml@4.11.0/packages/gatsby-transformer-yaml) --- updated-dependencies: - dependency-name: gatsby-transformer-yaml dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 25b4069b..65281e4f 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -25,7 +25,7 @@ "gatsby-plugin-svgr": "3.0.0-beta.0", "gatsby-source-filesystem": "4.10.1", "gatsby-transformer-sharp": "4.10.0", - "gatsby-transformer-yaml": "4.10.0", + "gatsby-transformer-yaml": "4.11.0", "gbimage-bridge": "0.2.1", "http-status-codes": "2.2.0", "ms": "2.1.3", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 767963d1..2927add8 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6496,10 +6496,10 @@ gatsby-transformer-sharp@4.10.0: semver "^7.3.5" sharp "^0.30.1" -gatsby-transformer-yaml@4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/gatsby-transformer-yaml/-/gatsby-transformer-yaml-4.10.0.tgz#cc227d30710daee7ba3034e0c567463503b99167" - integrity sha512-CSSiCo1TPi07jDbdw2Gm66Ao20kgvXHMa7YEnK94tCIZwjBpkognkUf3qHXRs6MhRTyx1gjnVQPmeAVg/1geJQ== +gatsby-transformer-yaml@4.11.0: + version "4.11.0" + resolved "https://registry.yarnpkg.com/gatsby-transformer-yaml/-/gatsby-transformer-yaml-4.11.0.tgz#900bf446ce7aece9253f46244519ccb5bd8cf7f2" + integrity sha512-GTCkULgOxbyRbovO9VHi0P+7iv/fEQG3uBeKiJyvMRUDD4bIQ9uIdT7hZ1RPwctu9dpt9T/X7kx+CShRzmELYw== dependencies: "@babel/runtime" "^7.15.4" js-yaml "^3.14.1" From d25b5595efc71e33bd537ca90fdbd7ef97755d0f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 13:26:53 +0000 Subject: [PATCH 109/240] build(deps): bump gatsby-plugin-image in /packages/website Bumps [gatsby-plugin-image](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-image) from 2.10.1 to 2.11.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-image/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-image@2.11.1/packages/gatsby-plugin-image) --- updated-dependencies: - dependency-name: gatsby-plugin-image dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index e3af2085..9d0a7302 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -15,7 +15,7 @@ "framer-motion": "6.2.8", "gatsby": "4.11.1", "gatsby-background-image": "1.6.0", - "gatsby-plugin-image": "2.10.1", + "gatsby-plugin-image": "2.11.1", "gatsby-plugin-manifest": "4.11.1", "gatsby-plugin-postcss": "5.10.0", "gatsby-plugin-react-helmet": "5.10.0", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 6c65aeec..860b612f 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -3339,7 +3339,7 @@ babel-plugin-polyfill-regenerator@^0.3.0: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" -babel-plugin-remove-graphql-queries@^4.10.1, babel-plugin-remove-graphql-queries@^4.11.1: +babel-plugin-remove-graphql-queries@^4.11.1: version "4.11.1" resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.11.1.tgz#6f107865e8c1a83807c4b48b2262f5e0e0ba537e" integrity sha512-Bqbeow4Xf+Vm4YhAucRGJjf9pNAXakSndYiLKfvef/W6mdtBh00SM8FMaX0U3rtR7ZUXV63RmIyOybVQ6SWCyg== @@ -6292,22 +6292,22 @@ gatsby-parcel-config@^0.2.0: "@parcel/transformer-raw" "^2.3.2" "@parcel/transformer-react-refresh-wrap" "^2.3.2" -gatsby-plugin-image@2.10.1: - version "2.10.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-image/-/gatsby-plugin-image-2.10.1.tgz#7b9eda7334487dd0e4693996cf3664835e9c356e" - integrity sha512-ZFcaKkVz6h18jRzP9HHCcXzyIc/Gj57NZSycOWFxW9KLqkq3NZXVx3mkV9EQ+rup8r3RLiJu/AXEorZEy7iAhQ== +gatsby-plugin-image@2.11.1: + version "2.11.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-image/-/gatsby-plugin-image-2.11.1.tgz#1e800b65e8c18cc524c5855b9dbdb907745fdb0c" + integrity sha512-4tfDdcczBVOL6ELKNWuXQ9h1V/5DhBMIVHmr6FPwm8xgL8ARqfQMXX2mzUjpNiu7WDiMlm9cWrTQQaZAARhAwg== dependencies: "@babel/code-frame" "^7.14.0" "@babel/parser" "^7.15.5" "@babel/runtime" "^7.15.4" "@babel/traverse" "^7.15.4" babel-jsx-utils "^1.1.0" - babel-plugin-remove-graphql-queries "^4.10.1" + babel-plugin-remove-graphql-queries "^4.11.1" camelcase "^5.3.1" chokidar "^3.5.2" common-tags "^1.8.2" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.1" + gatsby-core-utils "^3.11.1" objectFitPolyfill "^2.3.5" prop-types "^15.7.2" From 7bd54359e6840427fd9541ee3a09a1a560fcf4f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 6 Apr 2022 11:10:28 +0200 Subject: [PATCH 110/240] Dashboard v2 lighthouse scores improvements (#1972) * Metadata improvements * Accessibility improvements * Improve performance on mobile --- packages/dashboard-v2/gatsby-config.js | 4 +- .../src/components/APIKeyList/APIKey.js | 14 ++- .../dashboard-v2/src/components/CopyButton.js | 4 +- .../components/CurrentUsage/CurrentUsage.js | 1 - .../src/components/FileList/FileTable.js | 6 +- .../src/components/Metadata/Metadata.js | 27 +++++ .../src/components/Metadata/index.js | 1 + .../src/components/Modal/Modal.js | 2 +- .../src/components/NavBar/NavBar.js | 1 + .../src/components/Slider/Bullets.js | 1 + .../src/components/Uploader/Uploader.js | 6 +- .../src/components/forms/AddAPIKeyForm.js | 4 +- .../components/forms/AddPublicAPIKeyForm.js | 5 +- .../forms/AddSkylinkToAPIKeyForm.js | 2 +- packages/dashboard-v2/src/pages/auth/login.js | 24 +++-- .../src/pages/auth/reset-password.js | 54 +++++----- .../dashboard-v2/src/pages/auth/signup.js | 4 + packages/dashboard-v2/src/pages/files.js | 32 +++--- packages/dashboard-v2/src/pages/index.js | 98 ++++++++++-------- .../src/pages/settings/api-keys.js | 4 + .../dashboard-v2/src/pages/settings/export.js | 4 + .../dashboard-v2/src/pages/settings/index.js | 4 + .../src/pages/settings/notifications.js | 6 +- packages/dashboard-v2/src/pages/upgrade.js | 4 + .../dashboard-v2/src/pages/user/confirm.js | 36 ++++--- .../dashboard-v2/src/pages/user/recover.js | 60 ++++++----- packages/dashboard-v2/static/favicon.ico | Bin 0 -> 2118 bytes 27 files changed, 258 insertions(+), 150 deletions(-) create mode 100644 packages/dashboard-v2/src/components/Metadata/Metadata.js create mode 100644 packages/dashboard-v2/src/components/Metadata/index.js create mode 100644 packages/dashboard-v2/static/favicon.ico diff --git a/packages/dashboard-v2/gatsby-config.js b/packages/dashboard-v2/gatsby-config.js index ce35de3a..c6096a98 100644 --- a/packages/dashboard-v2/gatsby-config.js +++ b/packages/dashboard-v2/gatsby-config.js @@ -2,8 +2,8 @@ const { createProxyMiddleware } = require("http-proxy-middleware"); module.exports = { siteMetadata: { - title: `Accounts Dashboard`, - siteUrl: `https://www.yourdomain.tld`, + title: "Skynet Account", + siteUrl: `https://account.${process.env.GATSBY_PORTAL_DOMAIN}/`, }, trailingSlash: "never", plugins: [ diff --git a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js index 5cb6680a..3269bb9f 100644 --- a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js +++ b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js @@ -83,13 +83,19 @@ export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { {isPublic && ( )} - @@ -121,7 +127,11 @@ export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { {skylink} -
  • diff --git a/packages/dashboard-v2/src/components/CopyButton.js b/packages/dashboard-v2/src/components/CopyButton.js index 479352d2..9cbf43d2 100644 --- a/packages/dashboard-v2/src/components/CopyButton.js +++ b/packages/dashboard-v2/src/components/CopyButton.js @@ -22,7 +22,7 @@ const TooltipContent = styled.div.attrs({ className: "bg-primary-light/10 text-palette-600 py-2 px-4 ", })``; -export const CopyButton = ({ value, className }) => { +export const CopyButton = ({ value, className, ariaLabel = "Copy" }) => { const containerRef = useRef(); const [copied, setCopied] = useState(false); const [timer, setTimer] = useState(null); @@ -39,7 +39,7 @@ export const CopyButton = ({ value, className }) => { return (
    - diff --git a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js index 44be79ed..081b9cca 100644 --- a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js +++ b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js @@ -101,7 +101,6 @@ export default function CurrentUsage() { > UPGRADE {" "} - {/* TODO: proper URL */} {usage.filesLimit}
    diff --git a/packages/dashboard-v2/src/components/FileList/FileTable.js b/packages/dashboard-v2/src/components/FileList/FileTable.js index 90c9600f..c2f133d6 100644 --- a/packages/dashboard-v2/src/components/FileList/FileTable.js +++ b/packages/dashboard-v2/src/components/FileList/FileTable.js @@ -84,19 +84,19 @@ export default function FileTable({ items }) { {date}
    - + {skylink}
    - - diff --git a/packages/dashboard-v2/src/components/Metadata/Metadata.js b/packages/dashboard-v2/src/components/Metadata/Metadata.js new file mode 100644 index 00000000..5bb98330 --- /dev/null +++ b/packages/dashboard-v2/src/components/Metadata/Metadata.js @@ -0,0 +1,27 @@ +import { Helmet } from "react-helmet"; +import { graphql, useStaticQuery } from "gatsby"; + +export const Metadata = ({ children }) => { + const { site } = useStaticQuery( + graphql` + query Q { + site { + siteMetadata { + title + } + } + } + ` + ); + + const { title } = site.siteMetadata; + + return ( + + + + + {children} + + ); +}; diff --git a/packages/dashboard-v2/src/components/Metadata/index.js b/packages/dashboard-v2/src/components/Metadata/index.js new file mode 100644 index 00000000..8abb6696 --- /dev/null +++ b/packages/dashboard-v2/src/components/Metadata/index.js @@ -0,0 +1 @@ +export * from "./Metadata"; diff --git a/packages/dashboard-v2/src/components/Modal/Modal.js b/packages/dashboard-v2/src/components/Modal/Modal.js index c183e190..ac7bd98e 100644 --- a/packages/dashboard-v2/src/components/Modal/Modal.js +++ b/packages/dashboard-v2/src/components/Modal/Modal.js @@ -11,7 +11,7 @@ export const Modal = ({ children, className, onClose }) => (
    - {children} diff --git a/packages/dashboard-v2/src/components/NavBar/NavBar.js b/packages/dashboard-v2/src/components/NavBar/NavBar.js index f75030bb..6d2cb9eb 100644 --- a/packages/dashboard-v2/src/components/NavBar/NavBar.js +++ b/packages/dashboard-v2/src/components/NavBar/NavBar.js @@ -94,6 +94,7 @@ export const NavBar = () => { partiallyActive /> (
    ) : (
    - Add, or drop your files here diff --git a/packages/dashboard-v2/src/components/forms/AddAPIKeyForm.js b/packages/dashboard-v2/src/components/forms/AddAPIKeyForm.js index 703d88a0..ccea02a5 100644 --- a/packages/dashboard-v2/src/components/forms/AddAPIKeyForm.js +++ b/packages/dashboard-v2/src/components/forms/AddAPIKeyForm.js @@ -44,7 +44,7 @@ export const AddAPIKeyForm = forwardRef(({ onSuccess, type }, ref) => { {generatedKey} - +
    )} @@ -94,7 +94,7 @@ export const AddAPIKeyForm = forwardRef(({ onSuccess, type }, ref) => { {isSubmitting ? ( ) : ( - )} diff --git a/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js b/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js index 2184c513..c98daac9 100644 --- a/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js +++ b/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js @@ -59,7 +59,7 @@ export const AddPublicAPIKeyForm = forwardRef(({ onSuccess }, ref) => { {generatedKey} - +
    )} @@ -137,7 +137,7 @@ export const AddPublicAPIKeyForm = forwardRef(({ onSuccess }, ref) => { touched={skylinksTouched[index]} /> - @@ -160,6 +160,7 @@ export const AddPublicAPIKeyForm = forwardRef(({ onSuccess }, ref) => { /> )} diff --git a/packages/dashboard-v2/src/pages/auth/login.js b/packages/dashboard-v2/src/pages/auth/login.js index 8b0cfbb5..5812fd8f 100644 --- a/packages/dashboard-v2/src/pages/auth/login.js +++ b/packages/dashboard-v2/src/pages/auth/login.js @@ -4,6 +4,7 @@ import { navigate } from "gatsby"; import AuthLayout from "../../layouts/AuthLayout"; import { LoginForm } from "../../components/forms"; import { useUser } from "../../contexts/user"; +import { Metadata } from "../../components/Metadata"; const LoginPage = ({ location }) => { const { user, mutate: refreshUserState } = useUser(); @@ -17,16 +18,21 @@ const LoginPage = ({ location }) => { }, [user, redirectTo]); return ( -
    -
    - Skynet + <> + + Sign In + +
    +
    + Skynet +
    + { + await refreshUserState(); + }} + />
    - { - await refreshUserState(); - }} - /> -
    + ); }; diff --git a/packages/dashboard-v2/src/pages/auth/reset-password.js b/packages/dashboard-v2/src/pages/auth/reset-password.js index 8ecbfeaa..88db338a 100644 --- a/packages/dashboard-v2/src/pages/auth/reset-password.js +++ b/packages/dashboard-v2/src/pages/auth/reset-password.js @@ -4,6 +4,7 @@ import AuthLayout from "../../layouts/AuthLayout"; import { RecoveryForm } from "../../components/forms/RecoveryForm"; import HighlightedLink from "../../components/HighlightedLink"; +import { Metadata } from "../../components/Metadata"; const State = { Pure: "PURE", @@ -15,31 +16,36 @@ const ResetPasswordPage = () => { const [state, setState] = useState(State.Pure); return ( -
    -
    - Skynet + <> + + Reset Password + +
    +
    + Skynet +
    + {state !== State.Success && ( + setState(State.Success)} onFailure={() => setState(State.Failure)} /> + )} + + {state === State.Success && ( +

    Please check your inbox for further instructions.

    + )} + + {state === State.Failure && ( +

    Something went wrong, please try again later.

    + )} + +
    +

    + Suddenly remembered your password? Sign in +

    +

    + Don't actually have an account? Create one! +

    +
    - {state !== State.Success && ( - setState(State.Success)} onFailure={() => setState(State.Failure)} /> - )} - - {state === State.Success && ( -

    Please check your inbox for further instructions.

    - )} - - {state === State.Failure && ( -

    Something went wrong, please try again later.

    - )} - -
    -

    - Suddenly remembered your password? Sign in -

    -

    - Don't actually have an account? Create one! -

    -
    -
    + ); }; diff --git a/packages/dashboard-v2/src/pages/auth/signup.js b/packages/dashboard-v2/src/pages/auth/signup.js index 2af428f9..b6f0e0ac 100644 --- a/packages/dashboard-v2/src/pages/auth/signup.js +++ b/packages/dashboard-v2/src/pages/auth/signup.js @@ -9,6 +9,7 @@ import HighlightedLink from "../../components/HighlightedLink"; import { SignUpForm } from "../../components/forms/SignUpForm"; import { usePortalSettings } from "../../contexts/portal-settings"; import { PlansProvider, usePlans } from "../../contexts/plans"; +import { Metadata } from "../../components/Metadata"; const FreePortalHeader = () => { const { plans } = usePlans(); @@ -57,6 +58,9 @@ const SignUpPage = () => { return ( + + Sign Up +
    Skynet diff --git a/packages/dashboard-v2/src/pages/files.js b/packages/dashboard-v2/src/pages/files.js index 197cc031..f4a47a1d 100644 --- a/packages/dashboard-v2/src/pages/files.js +++ b/packages/dashboard-v2/src/pages/files.js @@ -1,28 +1,34 @@ import * as React from "react"; +import { useSearchParam } from "react-use"; import DashboardLayout from "../layouts/DashboardLayout"; import { Panel } from "../components/Panel"; import { Tab, TabPanel, Tabs } from "../components/Tabs"; +import { Metadata } from "../components/Metadata"; import FileList from "../components/FileList/FileList"; -import { useSearchParam } from "react-use"; const FilesPage = () => { const defaultTab = useSearchParam("tab"); return ( - - - - - - - - - - - - + <> + + My Files + + + + + + + + + + + + + + ); }; diff --git a/packages/dashboard-v2/src/pages/index.js b/packages/dashboard-v2/src/pages/index.js index 1fd88651..15edd552 100644 --- a/packages/dashboard-v2/src/pages/index.js +++ b/packages/dashboard-v2/src/pages/index.js @@ -13,6 +13,7 @@ import CurrentUsage from "../components/CurrentUsage"; import Uploader from "../components/Uploader/Uploader"; import CurrentPlan from "../components/CurrentPlan"; import { FullScreenLoadingIndicator } from "../components/LoadingIndicator"; +import { Metadata } from "../components/Metadata"; import useUpgradeRedirect from "../hooks/useUpgradeRedirect"; const IndexPage = () => { @@ -24,51 +25,60 @@ const IndexPage = () => { } return ( - -
    - - - - - - - - - - - - , - - Usage - - } - className="h-[330px]" - > - - , - - Current plan - - } - className="h-[330px]" - > - - , - ]} - /> -
    - {showRecentActivity && ( -
    - -
    + <> + + Dashboard + + {verifyingSubscription ? ( + + ) : ( + +
    + + + + + + + + + + + + , + + Usage + + } + className="h-[330px]" + > + + , + + Current plan + + } + className="h-[330px]" + > + + , + ]} + /> +
    + {showRecentActivity && ( +
    + +
    + )} +
    )} -
    + ); }; diff --git a/packages/dashboard-v2/src/pages/settings/api-keys.js b/packages/dashboard-v2/src/pages/settings/api-keys.js index 1f6c93c5..03486248 100644 --- a/packages/dashboard-v2/src/pages/settings/api-keys.js +++ b/packages/dashboard-v2/src/pages/settings/api-keys.js @@ -7,6 +7,7 @@ import { AddAPIKeyForm, APIKeyType } from "../../components/forms/AddAPIKeyForm" import { APIKeyList } from "../../components/APIKeyList/APIKeyList"; import { Alert } from "../../components/Alert"; import { AddPublicAPIKeyForm } from "../../components/forms/AddPublicAPIKeyForm"; +import { Metadata } from "../../components/Metadata"; const APIKeysPage = () => { const { data: apiKeys = [], mutate: reloadKeys, error } = useSWR("user/apikeys"); @@ -29,6 +30,9 @@ const APIKeysPage = () => { return ( <> + + API Keys +
    diff --git a/packages/dashboard-v2/src/pages/settings/export.js b/packages/dashboard-v2/src/pages/settings/export.js index ad05f5ff..7a75bc0c 100644 --- a/packages/dashboard-v2/src/pages/settings/export.js +++ b/packages/dashboard-v2/src/pages/settings/export.js @@ -4,6 +4,7 @@ import UserSettingsLayout from "../../layouts/UserSettingsLayout"; import { Switch } from "../../components/Switch"; import { Button } from "../../components/Button"; +import { Metadata } from "../../components/Metadata"; const useExportOptions = () => { const [pinnedFiles, setPinnedFiles] = useState(false); @@ -29,6 +30,9 @@ const ExportPage = () => { return ( <> + + Export +
    diff --git a/packages/dashboard-v2/src/pages/settings/index.js b/packages/dashboard-v2/src/pages/settings/index.js index 358a4b28..23a815e2 100644 --- a/packages/dashboard-v2/src/pages/settings/index.js +++ b/packages/dashboard-v2/src/pages/settings/index.js @@ -7,6 +7,7 @@ import { AccountSettingsForm } from "../../components/forms/AccountSettingsForm" import { Modal } from "../../components/Modal/Modal"; import { AccountRemovalForm } from "../../components/forms/AccountRemovalForm"; import { Alert } from "../../components/Alert"; +import { Metadata } from "../../components/Metadata"; const State = { Pure: "PURE", @@ -39,6 +40,9 @@ const AccountPage = () => { return ( <> + + Settings +
    diff --git a/packages/dashboard-v2/src/pages/settings/notifications.js b/packages/dashboard-v2/src/pages/settings/notifications.js index b46a1da4..447e40c8 100644 --- a/packages/dashboard-v2/src/pages/settings/notifications.js +++ b/packages/dashboard-v2/src/pages/settings/notifications.js @@ -1,13 +1,17 @@ import * as React from "react"; +import { StaticImage } from "gatsby-plugin-image"; import UserSettingsLayout from "../../layouts/UserSettingsLayout"; import { Switch } from "../../components/Switch"; -import { StaticImage } from "gatsby-plugin-image"; +import { Metadata } from "../../components/Metadata"; const NotificationsPage = () => { return ( <> + + Notifications +

    Notifications

    diff --git a/packages/dashboard-v2/src/pages/upgrade.js b/packages/dashboard-v2/src/pages/upgrade.js index 8e47472e..9f69487e 100644 --- a/packages/dashboard-v2/src/pages/upgrade.js +++ b/packages/dashboard-v2/src/pages/upgrade.js @@ -13,6 +13,7 @@ import { Button } from "../components/Button"; import { usePortalSettings } from "../contexts/portal-settings"; import { Alert } from "../components/Alert"; import HighlightedLink from "../components/HighlightedLink"; +import { Metadata } from "../components/Metadata"; const PAID_PORTAL_BREAKPOINTS = [ { @@ -88,6 +89,9 @@ const PlansSlider = () => { return (
    + + Upgrade + {settings.isSubscriptionRequired && !activePlan && (

    This Skynet portal requires a paid subscription.

    diff --git a/packages/dashboard-v2/src/pages/user/confirm.js b/packages/dashboard-v2/src/pages/user/confirm.js index 9e95e3e3..b4ce6bc1 100644 --- a/packages/dashboard-v2/src/pages/user/confirm.js +++ b/packages/dashboard-v2/src/pages/user/confirm.js @@ -5,6 +5,7 @@ import { AllUsersAuthLayout } from "../../layouts/AuthLayout"; import HighlightedLink from "../../components/HighlightedLink"; import accountsService from "../../services/accountsService"; +import { Metadata } from "../../components/Metadata"; const State = { Pure: "PURE", @@ -52,24 +53,29 @@ const EmailConfirmationPage = ({ location }) => { }, [token]); return ( -
    -
    - Skynet -
    -
    - {state === State.Pure &&

    Please wait while we verify your account...

    } + <> + + Confirm E-mail Address + +
    +
    + Skynet +
    +
    + {state === State.Pure &&

    Please wait while we verify your account...

    } - {state === State.Success && ( - <> -

    All done!

    -

    You will be redirected to your dashboard shortly.

    - Redirect now. - - )} + {state === State.Success && ( + <> +

    All done!

    +

    You will be redirected to your dashboard shortly.

    + Redirect now. + + )} - {state === State.Failure &&

    Something went wrong, please try again later.

    } + {state === State.Failure &&

    Something went wrong, please try again later.

    } +
    -
    + ); }; diff --git a/packages/dashboard-v2/src/pages/user/recover.js b/packages/dashboard-v2/src/pages/user/recover.js index 686e677a..d8d02e8a 100644 --- a/packages/dashboard-v2/src/pages/user/recover.js +++ b/packages/dashboard-v2/src/pages/user/recover.js @@ -5,6 +5,7 @@ import AuthLayout from "../../layouts/AuthLayout"; import { ResetPasswordForm } from "../../components/forms/ResetPasswordForm"; import HighlightedLink from "../../components/HighlightedLink"; +import { Metadata } from "../../components/Metadata"; const State = { Pure: "PURE", @@ -19,35 +20,40 @@ const RecoverPage = ({ location }) => { const [state, setState] = useState(State.Pure); return ( -
    -
    - Skynet -
    - {state !== State.Success && ( - { - setState(State.Success); - navigate("/"); - }} - onFailure={() => setState(State.Failure)} - /> - )} + <> + + Recover Your Account + +
    +
    + Skynet +
    + {state !== State.Success && ( + { + setState(State.Success); + navigate("/"); + }} + onFailure={() => setState(State.Failure)} + /> + )} - {state === State.Success && ( -

    - All done! You will be redirected to your dashboard shortly. + {state === State.Success && ( +

    + All done! You will be redirected to your dashboard shortly. +

    + )} + + {state === State.Failure && ( +

    Something went wrong, please try again later.

    + )} + +

    + Suddenly remembered your old password? Sign in

    - )} - - {state === State.Failure && ( -

    Something went wrong, please try again later.

    - )} - -

    - Suddenly remembered your old password? Sign in -

    -
    +
    + ); }; diff --git a/packages/dashboard-v2/static/favicon.ico b/packages/dashboard-v2/static/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..9229fbf780c52d9d25e2183c0effe239dd2728dd GIT binary patch literal 2118 zcmV-M2)Xx(P)RT(~arVF-3X?a8o@+eOO1vEksNT^L4i?pS? zGjpFa_ntF5TNVgSR!EH+O{o}6G@z1bNRVez0u;Kt_nv!ax2u$A6CgkW0YZ2+L`XDR z1#DW{()IiQb7pobr6JWx{@i=coOAyFeE;`9t`LXuTbZsA!xQ~t-Jh2TFH3}{6DQEJ z6zHVn=d$E!>4ZfC^CXFAOg6;-{0rK#2(l(bi6EE4Cxy8zUvSIUSxJyd0Rx1evq8d3 zha9Xa(>gb=iy)OEOqCGRhoRgjg}D-58;WpffF}-SLzdsS%z?raVZb67@GTf{F2-MV z(;;3%66v9mpUF~Vb13?^4dbll7gOv$>{{hgcsXEBn}Asfe+!Jr!P=_3OLR`PC=u47m}Isz}7LsTJhYKlCX6 zBrpm{_G9fwFm8vh)jxegBJUdaX<*jugv4$kh1*sRUB<(^s6k0J8xl1@Q`Ifu62!Wz z+yV4rnwc|67!;s5J#&f^`FEE?D^M;J+P z;%n0lV?YH4c$so)2pvDO1^^yEi{W=B-2JRDm%Hq(_dtH+>c$*)kzLPGfJosn$QKta zdXmew2L_S72C-xyFa#|NKOLOcpAXIQu&HjCTdHZ^SoVznTV2RCE8l@Qznmh#O=J3h z78I6XfMX0$4v)2*l}sob3GuObZu4h&@jgg+93dg9d26nxo0q_V3qw69jAg11h#;Qj zDR}?8_2qtS+zU2;*M?vpB_R1gT_ocp*w^H!af_x%#v;V~H0>t?U?2=j)mQNTdY7PD zZXhCJQB%m#rURBP$K+3N@Hbh3=G!-{-;CwC{F!BN-%?!>mGOpHxy46*@Pyi|a1O0SL$oa(Oxy+yS{A3FTxaVkXbQxJ`r$#~X7z z9fPQnAa>SWcDz`7_lT%XxTM6vdWYOb$_E}95$<@4!#JM08fQ1lVbNqhSso#BHJ{WcsMGC+s#y>%;d%dC-$XAo6C?u463wTSt8Zevs@3$fuj%5eDahUm$bsR1c?k;$bnU{Q6G z%e5hDFGq%yXJFl#IBPZxFwkdI8<>z~c0H(G+CkpL$0@rrh6 z!b;0^Hrf0IDAoPZmRK~kif*_X;|+K=K;SP^z5r6+!1y}IjgWpAu)v^VWaa$>qR}3v zGas{V*m7Xe(PRkxXg2%`;~!Ar2(tJz&iRIrFF>whcV)?!F!w{qpRoSdE^(;fig+sT z)pDGaKyHFu>ZNk7Z#Xh)4S3=J0}u%!EL15d*q8U%n?De0HMc&=a~u3_7^$sr*=Z5=#{DWog{4r;P%E_h zCCAPZsfPA)*!UqQk7VpavYAR>lqbtMjYx2N<{jkw26<%#wZXJgG+ z*N|LpM^^j=o(nl5vj6G{7H?h8Y>jY>(6n6>)&N^XP*^gaKLT)S=|n$IDgsqZlJ*-%E4s_CX$-kA59MkIQa@fv`6?8@k zw^$U8So06Ne!n&3U&N(q*60gNWKkFOY>#U${)_>uw%0_Zh=dv&7HaewVf{yk?y^PX zX*3dZO~zAYCT&K^hMG}%GUjzB)AbYvw~dZ-5; z!<>{o530&fZU3Nf`+3q7K-7m>-d9&P+7gDpAywt9R6xgS?w{vDC|LpBIEbSh$nHyP0=?P zw;tMn89qqS+)N~k&F7e|6B6ir;v;d3??cJ&F#iP?H%Mm!b#eF8VSrZkti zGFk(^_;+E!A%^ce)A_=Ha+r79E$ViFRx$_Ca4go%YaylE-qQ4i87Y>Id~#4Me|QZS zy~FwqZM;@g@x?SS6;hRRY?lL)suBzkoldE#L;6}S+wRy2CSwue3)wHE_`m)L)*x*d wcr!_T1R3R2QHrnKyh^M|E8>b`?IF+j55uL_p0enzz5oCK07*qoM6N<$f=9md3IG5A literal 0 HcmV?d00001 From 5473b8475a9052fb23571ccbb979ac030d9b6761 Mon Sep 17 00:00:00 2001 From: Ivaylo Novakov Date: Wed, 6 Apr 2022 11:59:28 +0200 Subject: [PATCH 111/240] Update portal control scripts, so they can talk to the new health-check container. --- scripts/portal-down.sh | 6 ++++-- scripts/portal-up.sh | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/scripts/portal-down.sh b/scripts/portal-down.sh index 0b42b53a..a60ed863 100755 --- a/scripts/portal-down.sh +++ b/scripts/portal-down.sh @@ -2,15 +2,17 @@ set -e # exit on first error -while getopts d:t: flag +while getopts d:t:r: flag do case "${flag}" in d) delay=${OPTARG};; t) timeout=${OPTARG};; + r) reason=${OPTARG};; esac done delay=${delay:-0} # default to no delay timeout=${timeout:-300} # default timeout is 300s +reason=${reason:-"disabled manually"} countdown() { local secs=$1 @@ -25,7 +27,7 @@ countdown() { countdown $delay # stop healh-check so the server is taken our of load balancer -docker exec health-check cli/disable +docker exec health-check cli disable $reason # then wait 5 minutes for the load balancer to propagate the dns records countdown $timeout diff --git a/scripts/portal-up.sh b/scripts/portal-up.sh index 1a287f2f..fcd7fe80 100755 --- a/scripts/portal-up.sh +++ b/scripts/portal-up.sh @@ -3,4 +3,4 @@ set -e # exit on first error # start the health-checks service -docker exec health-check cli/enable +docker exec health-check cli enable From 9b3e659ec57a7bec8e0a49101a4a2070d7c9d2fd Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 1 Apr 2022 16:14:55 +0200 Subject: [PATCH 112/240] lua testing and codecov v3 --- .github/workflows/nginx-lua-unit-tests.yml | 47 +- .gitignore | 4 + docker/nginx/conf.d/include/location-skylink | 16 +- .../conf.d/include/location-skynet-registry | 8 +- docker/nginx/conf.d/include/track-download | 55 -- docker/nginx/conf.d/include/track-registry | 33 -- docker/nginx/conf.d/include/track-upload | 55 -- docker/nginx/conf.d/server/server.api | 64 +- docker/nginx/libs/skynet/account.lua | 4 +- docker/nginx/libs/skynet/modules.lua | 23 + docker/nginx/libs/skynet/modules.spec.lua | 95 +++ docker/nginx/libs/skynet/scanner.lua | 26 + docker/nginx/libs/skynet/scanner.spec.lua | 121 ++++ docker/nginx/libs/skynet/tracker.lua | 91 +++ docker/nginx/libs/skynet/tracker.spec.lua | 550 ++++++++++++++++++ docker/nginx/libs/skynet/utils.lua | 13 +- docker/nginx/libs/skynet/utils.spec.lua | 65 +++ docker/nginx/libs/utils.lua | 38 ++ docker/nginx/libs/utils.spec.lua | 124 ++++ docker/nginx/testing/.luacov | 6 + docker/nginx/testing/Dockerfile | 11 + docker/nginx/testing/README.md | 3 + docker/nginx/testing/rbusted | 8 + 23 files changed, 1278 insertions(+), 182 deletions(-) delete mode 100644 docker/nginx/conf.d/include/track-download delete mode 100644 docker/nginx/conf.d/include/track-registry delete mode 100644 docker/nginx/conf.d/include/track-upload create mode 100644 docker/nginx/libs/skynet/modules.lua create mode 100644 docker/nginx/libs/skynet/modules.spec.lua create mode 100644 docker/nginx/libs/skynet/scanner.lua create mode 100644 docker/nginx/libs/skynet/scanner.spec.lua create mode 100644 docker/nginx/libs/skynet/tracker.lua create mode 100644 docker/nginx/libs/skynet/tracker.spec.lua create mode 100644 docker/nginx/libs/skynet/utils.spec.lua create mode 100644 docker/nginx/testing/.luacov create mode 100644 docker/nginx/testing/Dockerfile create mode 100644 docker/nginx/testing/README.md create mode 100755 docker/nginx/testing/rbusted diff --git a/.github/workflows/nginx-lua-unit-tests.yml b/.github/workflows/nginx-lua-unit-tests.yml index b86a4e04..6c9fba83 100644 --- a/.github/workflows/nginx-lua-unit-tests.yml +++ b/.github/workflows/nginx-lua-unit-tests.yml @@ -6,48 +6,37 @@ name: Nginx Lua Unit Tests on: push: branches: - - "master" - paths: - - ".github/workflows/nginx-lua-unit-tests.yml" - - "docker/nginx/libs/**.lua" + - master pull_request: - paths: - - ".github/workflows/nginx-lua-unit-tests.yml" - - "docker/nginx/libs/**.lua" jobs: - build: + test: runs-on: ubuntu-latest - + container: openresty/openresty:1.19.9.1-focal steps: - - uses: actions/checkout@v2 - - uses: actions/setup-python@v2 - with: - python-version: "3.x" - architecture: "x64" + - uses: actions/checkout@v3 - name: Install Dependencies run: | - pip install hererocks - hererocks env --lua=5.1 -rlatest - source env/bin/activate + luarocks install lua-resty-http + luarocks install hasher luarocks install busted luarocks install luacov - luarocks install hasher luarocks install luacheck - - name: Lint code - run: | - source env/bin/activate - luacheck docker/nginx/libs --std ngx_lua+busted + - name: Lint Code With Luacheck + run: luacheck docker/nginx/libs --std ngx_lua+busted - - name: Unit Tests - run: | - source env/bin/activate - busted --verbose --coverage --pattern=spec --directory=docker/nginx/libs . - cd docker/nginx/libs && luacov + - name: Run Tests With Busted + # ran from root repo directory; produces luacov.stats.out file + run: docker/nginx/testing/rbusted --lpath='docker/nginx/libs/?.lua;docker/nginx/libs/?/?.lua' --verbose --coverage --pattern=spec docker/nginx/libs - - uses: codecov/codecov-action@v2 + - name: Generate Code Coverage Report With Luacov + # requires config file in cwd; produces luacov.report.out file + run: cp docker/nginx/testing/.luacov . && luacov && rm .luacov + + - uses: codecov/codecov-action@v3 with: - directory: docker/nginx/libs + root_dir: ${GITHUB_WORKSPACE} + files: ./luacov.report.out flags: nginx-lua diff --git a/.gitignore b/.gitignore index 4b85194e..8a98ee28 100644 --- a/.gitignore +++ b/.gitignore @@ -86,6 +86,10 @@ __pycache__ /.idea/ /venv* +# Luacov file +luacov.stats.out +luacov.report.out + # Setup-script log files setup-scripts/serverload.log setup-scripts/serverload.json diff --git a/docker/nginx/conf.d/include/location-skylink b/docker/nginx/conf.d/include/location-skylink index 995a6e2d..b214e3a9 100644 --- a/docker/nginx/conf.d/include/location-skylink +++ b/docker/nginx/conf.d/include/location-skylink @@ -1,5 +1,4 @@ include /etc/nginx/conf.d/include/cors; -include /etc/nginx/conf.d/include/track-download; limit_conn downloads_by_ip 100; # ddos protection: max 100 downloads at a time @@ -37,3 +36,18 @@ proxy_read_timeout 600; proxy_set_header User-Agent: Sia-Agent; proxy_pass http://sia:9980/skynet/skylink/$skylink$path$is_args$args; + +log_by_lua_block { + local skynet_account = require("skynet.account") + local skynet_modules = require("skynet.modules") + local skynet_scanner = require("skynet.scanner") + local skynet_tracker = require("skynet.tracker") + + if skynet_modules.is_enabled("a") then + skynet_tracker.track_download(ngx.header["Skynet-Skylink"], ngx.status, skynet_account.get_auth_headers(), ngx.var.body_bytes_sent) + end + + if skynet_modules.is_enabled("s") then + skynet_scanner.scan_skylink(ngx.header["Skynet-Skylink"]) + end +} diff --git a/docker/nginx/conf.d/include/location-skynet-registry b/docker/nginx/conf.d/include/location-skynet-registry index 33838f70..cd450be9 100644 --- a/docker/nginx/conf.d/include/location-skynet-registry +++ b/docker/nginx/conf.d/include/location-skynet-registry @@ -1,6 +1,5 @@ include /etc/nginx/conf.d/include/cors; include /etc/nginx/conf.d/include/sia-auth; -include /etc/nginx/conf.d/include/track-registry; limit_req zone=registry_access_by_ip burst=600 nodelay; limit_req zone=registry_access_by_ip_throttled burst=200 nodelay; @@ -30,3 +29,10 @@ access_by_lua_block { end end } + +log_by_lua_block { + local skynet_account = require("skynet.account") + local skynet_tracker = require("skynet.tracker") + + skynet_tracker.track_registry(ngx.status, skynet_account.get_auth_headers(), ngx.req.get_method()) +} diff --git a/docker/nginx/conf.d/include/track-download b/docker/nginx/conf.d/include/track-download deleted file mode 100644 index 4e12fd41..00000000 --- a/docker/nginx/conf.d/include/track-download +++ /dev/null @@ -1,55 +0,0 @@ -log_by_lua_block { - local skynet_account = require("skynet.account") - - -- tracking runs only when request comes from authenticated user - if skynet_account.is_authenticated() then - local function track(premature, skylink, status, body_bytes_sent, auth_headers) - if premature then return end - - local httpc = require("resty.http").new() - local query = table.concat({ "status=" .. status, "bytes=" .. body_bytes_sent }, "&") - - -- 10.10.10.70 points to accounts service (alias not available when using resty-http) - local res, err = httpc:request_uri("http://10.10.10.70:3000/track/download/" .. skylink .. "?" .. query, { - method = "POST", - headers = auth_headers, - }) - - if err or (res and res.status ~= ngx.HTTP_NO_CONTENT) then - local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) - ngx.log(ngx.ERR, "Failed accounts service request /track/download/" .. skylink .. ": ", error_response) - end - end - - if ngx.header["Skynet-Skylink"] and ngx.status >= ngx.HTTP_OK and ngx.status < ngx.HTTP_SPECIAL_RESPONSE then - local auth_headers = skynet_account.get_auth_headers() - local ok, err = ngx.timer.at(0, track, ngx.header["Skynet-Skylink"], ngx.status, ngx.var.body_bytes_sent, auth_headers) - if err then ngx.log(ngx.ERR, "Failed to create timer: ", err) end - end - end - - -- this block runs only when scanner module is enabled - if os.getenv("PORTAL_MODULES"):match("s") then - local function scan(premature, skylink) - if premature then return end - - local httpc = require("resty.http").new() - - -- 10.10.10.101 points to malware-scanner service (alias not available when using resty-http) - local res, err = httpc:request_uri("http://10.10.10.101:4000/scan/" .. skylink, { - method = "POST", - }) - - if err or (res and res.status ~= ngx.HTTP_OK) then - local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) - ngx.log(ngx.ERR, "Failed malware-scanner request /scan/" .. skylink .. ": ", error_response) - end - end - - -- scan all skylinks but make sure to only run if skylink is present (empty if request failed) - if ngx.header["Skynet-Skylink"] then - local ok, err = ngx.timer.at(0, scan, ngx.header["Skynet-Skylink"]) - if err then ngx.log(ngx.ERR, "Failed to create timer: ", err) end - end - end -} diff --git a/docker/nginx/conf.d/include/track-registry b/docker/nginx/conf.d/include/track-registry deleted file mode 100644 index 2c840491..00000000 --- a/docker/nginx/conf.d/include/track-registry +++ /dev/null @@ -1,33 +0,0 @@ -log_by_lua_block { - local skynet_account = require("skynet.account") - - -- tracking runs only when request comes from authenticated user - if skynet_account.is_authenticated() then - local function track(premature, request_method, auth_headers) - if premature then return end - - local httpc = require("resty.http").new() - - -- based on request method we assign a registry action string used - -- in track endpoint namely "read" for GET and "write" for POST - local registry_action = request_method == "GET" and "read" or "write" - - -- 10.10.10.70 points to accounts service (alias not available when using resty-http) - local res, err = httpc:request_uri("http://10.10.10.70:3000/track/registry/" .. registry_action, { - method = "POST", - headers = auth_headers, - }) - - if err or (res and res.status ~= ngx.HTTP_NO_CONTENT) then - local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) - ngx.log(ngx.ERR, "Failed accounts service request /track/registry/" .. registry_action .. ": ", error_response) - end - end - - if ngx.status == ngx.HTTP_OK or ngx.status == ngx.HTTP_NOT_FOUND then - local auth_headers = skynet_account.get_auth_headers() - local ok, err = ngx.timer.at(0, track, ngx.req.get_method(), auth_headers) - if err then ngx.log(ngx.ERR, "Failed to create timer: ", err) end - end - end -} diff --git a/docker/nginx/conf.d/include/track-upload b/docker/nginx/conf.d/include/track-upload deleted file mode 100644 index 36b12b9e..00000000 --- a/docker/nginx/conf.d/include/track-upload +++ /dev/null @@ -1,55 +0,0 @@ -log_by_lua_block { - local skynet_account = require("skynet.account") - - -- tracking runs only when request comes from authenticated user - if skynet_account.is_authenticated() then - local function track(premature, skylink, auth_headers) - if premature then return end - - local httpc = require("resty.http").new() - - -- 10.10.10.70 points to accounts service (alias not available when using resty-http) - local res, err = httpc:request_uri("http://10.10.10.70:3000/track/upload/" .. skylink, { - method = "POST", - headers = auth_headers, - }) - - if err or (res and res.status ~= ngx.HTTP_NO_CONTENT) then - local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) - ngx.log(ngx.ERR, "Failed accounts service request /track/upload/" .. skylink .. ": ", error_response) - end - end - - -- report all skylinks (header empty if request failed) but only if jwt is preset (user is authenticated) - if ngx.header["Skynet-Skylink"] then - local auth_headers = skynet_account.get_auth_headers() - local ok, err = ngx.timer.at(0, track, ngx.header["Skynet-Skylink"], auth_headers) - if err then ngx.log(ngx.ERR, "Failed to create timer: ", err) end - end - end - - -- this block runs only when scanner module is enabled - if os.getenv("PORTAL_MODULES"):match("s") then - local function scan(premature, skylink) - if premature then return end - - local httpc = require("resty.http").new() - - -- 10.10.10.101 points to malware-scanner service (alias not available when using resty-http) - local res, err = httpc:request_uri("http://10.10.10.101:4000/scan/" .. skylink, { - method = "POST", - }) - - if err or (res and res.status ~= ngx.HTTP_OK) then - local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) - ngx.log(ngx.ERR, "Failed malware-scanner request /scan/" .. skylink .. ": ", error_response) - end - end - - -- scan all skylinks but make sure to only run if skylink is present (empty if request failed) - if ngx.header["Skynet-Skylink"] then - local ok, err = ngx.timer.at(0, scan, ngx.header["Skynet-Skylink"]) - if err then ngx.log(ngx.ERR, "Failed to create timer: ", err) end - end - end -} diff --git a/docker/nginx/conf.d/server/server.api b/docker/nginx/conf.d/server/server.api index f681cca8..84842a03 100644 --- a/docker/nginx/conf.d/server/server.api +++ b/docker/nginx/conf.d/server/server.api @@ -206,7 +206,6 @@ location /skynet/registry/subscription { location /skynet/skyfile { include /etc/nginx/conf.d/include/cors; include /etc/nginx/conf.d/include/sia-auth; - include /etc/nginx/conf.d/include/track-upload; include /etc/nginx/conf.d/include/generate-siapath; include /etc/nginx/conf.d/include/portal-access-check; @@ -228,12 +227,26 @@ location /skynet/skyfile { # proxy this call to siad endpoint (make sure the ip is correct) proxy_pass http://sia:9980/skynet/skyfile/$dir1/$dir2/$dir3$is_args$args; + + log_by_lua_block { + local skynet_account = require("skynet.account") + local skynet_modules = require("skynet.modules") + local skynet_scanner = require("skynet.scanner") + local skynet_tracker = require("skynet.tracker") + + if skynet_modules.is_enabled("a") then + skynet_tracker.track_upload(ngx.header["Skynet-Skylink"], ngx.status, skynet_account.get_auth_headers()) + end + + if skynet_modules.is_enabled("s") then + skynet_scanner.scan_skylink(ngx.header["Skynet-Skylink"]) + end + } } # endpoint implementing resumable file uploads open protocol https://tus.io location /skynet/tus { include /etc/nginx/conf.d/include/cors-headers; # include cors headers but do not overwrite OPTIONS response - include /etc/nginx/conf.d/include/track-upload; limit_req zone=uploads_by_ip burst=10 nodelay; limit_req zone=uploads_by_ip_throttled; @@ -294,12 +307,26 @@ location /skynet/tus { end end } + + log_by_lua_block { + local skynet_account = require("skynet.account") + local skynet_modules = require("skynet.modules") + local skynet_scanner = require("skynet.scanner") + local skynet_tracker = require("skynet.tracker") + + if skynet_modules.is_enabled("a") then + skynet_tracker.track_upload(ngx.header["Skynet-Skylink"], ngx.status, skynet_account.get_auth_headers()) + end + + if skynet_modules.is_enabled("s") then + skynet_scanner.scan_skylink(ngx.header["Skynet-Skylink"]) + end + } } location /skynet/pin { include /etc/nginx/conf.d/include/cors; include /etc/nginx/conf.d/include/sia-auth; - include /etc/nginx/conf.d/include/track-upload; include /etc/nginx/conf.d/include/generate-siapath; include /etc/nginx/conf.d/include/portal-access-check; @@ -311,6 +338,21 @@ location /skynet/pin { proxy_set_header User-Agent: Sia-Agent; proxy_pass http://sia:9980$uri?siapath=$dir1/$dir2/$dir3&$args; + + log_by_lua_block { + local skynet_account = require("skynet.account") + local skynet_modules = require("skynet.modules") + local skynet_scanner = require("skynet.scanner") + local skynet_tracker = require("skynet.tracker") + + if skynet_modules.is_enabled("a") then + skynet_tracker.track_upload(ngx.header["Skynet-Skylink"], ngx.status, skynet_account.get_auth_headers()) + end + + if skynet_modules.is_enabled("s") then + skynet_scanner.scan_skylink(ngx.header["Skynet-Skylink"]) + end + } } location /skynet/metadata { @@ -357,7 +399,6 @@ location ~ "^/file/(([a-zA-Z0-9-_]{46}|[a-z0-9]{55})(/.*)?)$" { location /skynet/trustless/basesector { include /etc/nginx/conf.d/include/cors; - include /etc/nginx/conf.d/include/track-download; limit_conn downloads_by_ip 100; # ddos protection: max 100 downloads at a time @@ -391,6 +432,21 @@ location /skynet/trustless/basesector { proxy_set_header User-Agent: Sia-Agent; proxy_pass http://sia:9980; + + log_by_lua_block { + local skynet_account = require("skynet.account") + local skynet_modules = require("skynet.modules") + local skynet_scanner = require("skynet.scanner") + local skynet_tracker = require("skynet.tracker") + + if skynet_modules.is_enabled("a") then + skynet_tracker.track_download(ngx.header["Skynet-Skylink"], ngx.status, skynet_account.get_auth_headers(), ngx.var.body_bytes_sent) + end + + if skynet_modules.is_enabled("s") then + skynet_scanner.scan_skylink(ngx.header["Skynet-Skylink"]) + end + } } location /__internal/do/not/use/accounts { diff --git a/docker/nginx/libs/skynet/account.lua b/docker/nginx/libs/skynet/account.lua index 6fa2c4d2..56c99897 100644 --- a/docker/nginx/libs/skynet/account.lua +++ b/docker/nginx/libs/skynet/account.lua @@ -59,7 +59,9 @@ function _M.exit_access_forbidden(message) end function _M.accounts_enabled() - return os.getenv("PORTAL_MODULES"):match("a") ~= nil + local skynet_modules = require("skynet.modules") + + return skynet_modules.is_enabled("a") end function _M.get_account_limits() diff --git a/docker/nginx/libs/skynet/modules.lua b/docker/nginx/libs/skynet/modules.lua new file mode 100644 index 00000000..607e6d8e --- /dev/null +++ b/docker/nginx/libs/skynet/modules.lua @@ -0,0 +1,23 @@ +local _M = {} + +local utils = require("utils") + +function _M.is_enabled(module_abbr) + if type(module_abbr) ~= "string" or module_abbr:len() ~= 1 then + error("Module abbreviation '" .. tostring(module_abbr) .. "' should be exactly one character long string") + end + + local enabled_modules = utils.getenv("PORTAL_MODULES") + + if not enabled_modules then + return false + end + + return enabled_modules:find(module_abbr) ~= nil +end + +function _M.is_disabled(module_abbr) + return not _M.is_enabled(module_abbr) +end + +return _M diff --git a/docker/nginx/libs/skynet/modules.spec.lua b/docker/nginx/libs/skynet/modules.spec.lua new file mode 100644 index 00000000..0797a32d --- /dev/null +++ b/docker/nginx/libs/skynet/modules.spec.lua @@ -0,0 +1,95 @@ +-- luacheck: ignore os + +local skynet_modules = require("skynet.modules") + +describe("is_enabled", function() + before_each(function() + stub(os, "getenv") + end) + + after_each(function() + os.getenv:revert() + end) + + it("should return false if PORTAL_MODULES are not defined", function() + os.getenv.on_call_with("PORTAL_MODULES").returns(nil) + + assert.is_false(skynet_modules.is_enabled("a")) + end) + + it("should return false if PORTAL_MODULES are empty", function() + os.getenv.on_call_with("PORTAL_MODULES").returns("") + + assert.is_false(skynet_modules.is_enabled("a")) + end) + + it("should return false if module is not enabled", function() + os.getenv.on_call_with("PORTAL_MODULES").returns("qwerty") + + assert.is_false(skynet_modules.is_enabled("a")) + end) + + it("should return true if module is enabled", function() + os.getenv.on_call_with("PORTAL_MODULES").returns("asdfg") + + assert.is_true(skynet_modules.is_enabled("a")) + end) + + it("should throw an error for empty module", function() + assert.has_error(function() + skynet_modules.is_enabled() + end, "Module abbreviation 'nil' should be exactly one character long string") + end) + + it("should throw an error for too long module", function() + assert.has_error(function() + skynet_modules.is_enabled("gandalf") + end, "Module abbreviation 'gandalf' should be exactly one character long string") + end) +end) + +describe("is_disabled", function() + before_each(function() + stub(os, "getenv") + end) + + after_each(function() + os.getenv:revert() + end) + + it("should return true if PORTAL_MODULES are not defined", function() + os.getenv.on_call_with("PORTAL_MODULES").returns(nil) + + assert.is_true(skynet_modules.is_disabled("a")) + end) + + it("should return true if PORTAL_MODULES are empty", function() + os.getenv.on_call_with("PORTAL_MODULES").returns("") + + assert.is_true(skynet_modules.is_disabled("a")) + end) + + it("should return true if module is not enabled", function() + os.getenv.on_call_with("PORTAL_MODULES").returns("qwerty") + + assert.is_true(skynet_modules.is_disabled("a")) + end) + + it("should return false if module is enabled", function() + os.getenv.on_call_with("PORTAL_MODULES").returns("asdfg") + + assert.is_false(skynet_modules.is_disabled("a")) + end) + + it("should throw an error for empty module", function() + assert.has_error(function() + skynet_modules.is_disabled() + end, "Module abbreviation 'nil' should be exactly one character long string") + end) + + it("should throw an error for too long module", function() + assert.has_error(function() + skynet_modules.is_disabled("gandalf") + end, "Module abbreviation 'gandalf' should be exactly one character long string") + end) +end) \ No newline at end of file diff --git a/docker/nginx/libs/skynet/scanner.lua b/docker/nginx/libs/skynet/scanner.lua new file mode 100644 index 00000000..445f1ae9 --- /dev/null +++ b/docker/nginx/libs/skynet/scanner.lua @@ -0,0 +1,26 @@ +local _M = {} + +function _M.scan_skylink_timer(premature, skylink) + if premature then return end + + local httpc = require("resty.http").new() + + -- 10.10.10.101 points to malware-scanner service (alias not available when using resty-http) + local res, err = httpc:request_uri("http://10.10.10.101:4000/scan/" .. skylink, { + method = "POST", + }) + + if err or (res and res.status ~= ngx.HTTP_OK) then + local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) + ngx.log(ngx.ERR, "Failed malware-scanner request /scan/" .. skylink .. ": ", error_response) + end +end + +function _M.scan_skylink(skylink) + if not skylink then return end + + local ok, err = ngx.timer.at(0, _M.scan_skylink_timer, skylink) + if not ok then ngx.log(ngx.ERR, "Failed to create timer: ", err) end +end + +return _M diff --git a/docker/nginx/libs/skynet/scanner.spec.lua b/docker/nginx/libs/skynet/scanner.spec.lua new file mode 100644 index 00000000..400c301c --- /dev/null +++ b/docker/nginx/libs/skynet/scanner.spec.lua @@ -0,0 +1,121 @@ +-- luacheck: ignore ngx + +local skynet_scanner = require("skynet.scanner") +local skylink = "AQBG8n_sgEM_nlEp3G0w3vLjmdvSZ46ln8ZXHn-eObZNjA" + +describe("scan_skylink", function() + before_each(function() + stub(ngx.timer, "at") + end) + + after_each(function() + ngx.timer.at:revert() + end) + + it("should schedule a timer when skylink is provided", function() + ngx.timer.at.invokes(function() return true, nil end) + + skynet_scanner.scan_skylink(skylink) + + assert.stub(ngx.timer.at).was_called_with(0, skynet_scanner.scan_skylink_timer, skylink) + end) + + it("should log an error if timer failed to create", function() + stub(ngx, "log") + + ngx.timer.at.invokes(function() return false, "such a failure" end) + + skynet_scanner.scan_skylink(skylink) + + assert.stub(ngx.timer.at).was_called_with(0, skynet_scanner.scan_skylink_timer, skylink) + assert.stub(ngx.log).was_called_with(ngx.ERR, "Failed to create timer: ", "such a failure") + + ngx.log:revert() + end) + + it("should not schedule a timer if skylink is not provided", function() + skynet_scanner.scan_skylink() + + assert.stub(ngx.timer.at).was_not_called() + end) +end) + +describe("scan_skylink_timer", function() + before_each(function() + stub(ngx, "log") + end) + + after_each(function() + local resty_http = require("resty.http") + + ngx.log:revert() + resty_http.new:revert() + end) + + it("should exit early on premature", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 200 } -- return 200 success + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_scanner.scan_skylink_timer(true, skylink) + + assert.stub(request_uri).was_not_called() + assert.stub(ngx.log).was_not_called() + end) + + it("should make a post request with skylink to scanner service", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 200 } -- return 200 success + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_scanner.scan_skylink_timer(false, skylink) + + local uri = "http://10.10.10.101:4000/scan/" .. skylink + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST" }) + assert.stub(ngx.log).was_not_called() + end) + + it("should log message on scanner request failure with response code", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 404, body = "baz" } -- return 404 failure + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_scanner.scan_skylink_timer(false, skylink) + + local uri = "http://10.10.10.101:4000/scan/" .. skylink + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST" }) + assert.stub(ngx.log).was_called_with( + ngx.ERR, + "Failed malware-scanner request /scan/AQBG8n_sgEM_nlEp3G0w3vLjmdvSZ46ln8ZXHn-eObZNjA: ", + "[HTTP 404] baz" + ) + end) + + it("should log message on scanner request error", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return nil, "foo != bar" -- return error + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_scanner.scan_skylink_timer(false, skylink) + + local uri = "http://10.10.10.101:4000/scan/" .. skylink + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST" }) + assert.stub(ngx.log).was_called_with( + ngx.ERR, + "Failed malware-scanner request /scan/AQBG8n_sgEM_nlEp3G0w3vLjmdvSZ46ln8ZXHn-eObZNjA: ", + "foo != bar" + ) + end) +end) \ No newline at end of file diff --git a/docker/nginx/libs/skynet/tracker.lua b/docker/nginx/libs/skynet/tracker.lua new file mode 100644 index 00000000..78fa6995 --- /dev/null +++ b/docker/nginx/libs/skynet/tracker.lua @@ -0,0 +1,91 @@ +local _M = {} + +local utils = require("utils") + +function _M.track_download_timer(premature, skylink, status, auth_headers, body_bytes_sent) + if premature then return end + + local httpc = require("resty.http").new() + local query = table.concat({ "status=" .. status, "bytes=" .. body_bytes_sent }, "&") + + -- 10.10.10.70 points to accounts service (alias not available when using resty-http) + local res, err = httpc:request_uri("http://10.10.10.70:3000/track/download/" .. skylink .. "?" .. query, { + method = "POST", + headers = auth_headers, + }) + + if err or (res and res.status ~= 204) then + local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) + ngx.log(ngx.ERR, "Failed accounts service request /track/download/" .. skylink .. ": ", error_response) + end +end + +function _M.track_download(skylink, status_code, auth_headers, body_bytes_sent) + local has_auth_headers = not utils.is_table_empty(auth_headers) + local status_success = status_code >= 200 and status_code <= 299 + + if skylink and status_success and has_auth_headers then + local ok, err = ngx.timer.at(0, _M.track_download_timer, skylink, status_code, auth_headers, body_bytes_sent) + if not ok then ngx.log(ngx.ERR, "Failed to create timer: ", err) end + end +end + +function _M.track_upload_timer(premature, skylink, auth_headers) + if premature then return end + + local httpc = require("resty.http").new() + + -- 10.10.10.70 points to accounts service (alias not available when using resty-http) + local res, err = httpc:request_uri("http://10.10.10.70:3000/track/upload/" .. skylink, { + method = "POST", + headers = auth_headers, + }) + + if err or (res and res.status ~= 204) then + local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) + ngx.log(ngx.ERR, "Failed accounts service request /track/upload/" .. skylink .. ": ", error_response) + end +end + +function _M.track_upload(skylink, status_code, auth_headers) + local has_auth_headers = not utils.is_table_empty(auth_headers) + local status_success = status_code >= 200 and status_code <= 299 + + if skylink and status_success and has_auth_headers then + local ok, err = ngx.timer.at(0, _M.track_upload_timer, skylink, auth_headers) + if not ok then ngx.log(ngx.ERR, "Failed to create timer: ", err) end + end +end + +function _M.track_registry_timer(premature, auth_headers, request_method) + if premature then return end + + local httpc = require("resty.http").new() + + -- based on request method we assign a registry action string used + -- in track endpoint namely "read" for GET and "write" for POST + local registry_action = request_method == "GET" and "read" or "write" + + -- 10.10.10.70 points to accounts service (alias not available when using resty-http) + local res, err = httpc:request_uri("http://10.10.10.70:3000/track/registry/" .. registry_action, { + method = "POST", + headers = auth_headers, + }) + + if err or (res and res.status ~= 204) then + local error_response = err or ("[HTTP " .. res.status .. "] " .. res.body) + ngx.log(ngx.ERR, "Failed accounts service request /track/registry/" .. registry_action .. ": ", error_response) + end +end + +function _M.track_registry(status_code, auth_headers, request_method) + local has_auth_headers = not utils.is_table_empty(auth_headers) + local tracked_status = status_code == 200 or status_code == 404 + + if tracked_status and has_auth_headers then + local ok, err = ngx.timer.at(0, _M.track_registry_timer, auth_headers, request_method) + if not ok then ngx.log(ngx.ERR, "Failed to create timer: ", err) end + end +end + +return _M diff --git a/docker/nginx/libs/skynet/tracker.spec.lua b/docker/nginx/libs/skynet/tracker.spec.lua new file mode 100644 index 00000000..41dab843 --- /dev/null +++ b/docker/nginx/libs/skynet/tracker.spec.lua @@ -0,0 +1,550 @@ +-- luacheck: ignore ngx + +local skynet_tracker = require("skynet.tracker") + +local valid_skylink = "AQBG8n_sgEM_nlEp3G0w3vLjmdvSZ46ln8ZXHn-eObZNjA" +local valid_status_code = 200 +local valid_auth_headers = { ["Skynet-Api-Key"] = "foo" } + +describe("track_download", function() + local valid_body_bytes_sent = 12345 + + before_each(function() + stub(ngx.timer, "at") + end) + + after_each(function() + ngx.timer.at:revert() + end) + + it("should schedule a timer when conditions are met", function() + ngx.timer.at.invokes(function() return true, nil end) + + skynet_tracker.track_download(valid_skylink, valid_status_code, valid_auth_headers, valid_body_bytes_sent) + + assert.stub(ngx.timer.at).was_called_with( + 0, + skynet_tracker.track_download_timer, + valid_skylink, + valid_status_code, + valid_auth_headers, + valid_body_bytes_sent + ) + end) + + it("should not schedule a timer if skylink is empty", function() + ngx.timer.at.invokes(function() return true, nil end) + + skynet_tracker.track_download(nil, valid_status_code, valid_auth_headers, valid_body_bytes_sent) + + assert.stub(ngx.timer.at).was_not_called() + end) + + it("should not schedule a timer if status code is not in 2XX range", function() + ngx.timer.at.invokes(function() return true, nil end) + + -- couple of example of 4XX and 5XX codes + skynet_tracker.track_download(valid_skylink, 401, valid_auth_headers, valid_body_bytes_sent) + skynet_tracker.track_download(valid_skylink, 403, valid_auth_headers, valid_body_bytes_sent) + skynet_tracker.track_download(valid_skylink, 490, valid_auth_headers, valid_body_bytes_sent) + skynet_tracker.track_download(valid_skylink, 500, valid_auth_headers, valid_body_bytes_sent) + skynet_tracker.track_download(valid_skylink, 502, valid_auth_headers, valid_body_bytes_sent) + + assert.stub(ngx.timer.at).was_not_called() + end) + + it("should not schedule a timer if auth headers are empty", function() + ngx.timer.at.invokes(function() return true, nil end) + + skynet_tracker.track_download(valid_skylink, valid_status_code, {}, valid_body_bytes_sent) + + assert.stub(ngx.timer.at).was_not_called() + end) + + it("should log an error if timer failed to create", function() + stub(ngx, "log") + ngx.timer.at.invokes(function() return false, "such a failure" end) + + skynet_tracker.track_download(valid_skylink, valid_status_code, valid_auth_headers, valid_body_bytes_sent) + + assert.stub(ngx.timer.at).was_called_with( + 0, + skynet_tracker.track_download_timer, + valid_skylink, + valid_status_code, + valid_auth_headers, + valid_body_bytes_sent + ) + assert.stub(ngx.log).was_called_with(ngx.ERR, "Failed to create timer: ", "such a failure") + + ngx.log:revert() + end) + + describe("track_download_timer", function() + before_each(function() + stub(ngx, "log") + end) + + after_each(function() + local resty_http = require("resty.http") + + ngx.log:revert() + resty_http.new:revert() + end) + + it("should exit early on premature", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 200 } -- return 200 success + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_download_timer( + true, + valid_skylink, + valid_status_code, + valid_auth_headers, + valid_body_bytes_sent + ) + + assert.stub(request_uri).was_not_called() + assert.stub(ngx.log).was_not_called() + end) + + it("should make a post request to tracker service", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 204 } -- return 204 success + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_download_timer( + false, + valid_skylink, + valid_status_code, + valid_auth_headers, + valid_body_bytes_sent + ) + + local uri_params = "status=" .. valid_status_code .. "&bytes=" .. valid_body_bytes_sent + local uri = "http://10.10.10.70:3000/track/download/" .. valid_skylink .. "?" .. uri_params + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(ngx.log).was_not_called() + end) + + it("should log message on tracker request failure with response code", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 404, body = "baz" } -- return 404 failure + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_download_timer( + false, + valid_skylink, + valid_status_code, + valid_auth_headers, + valid_body_bytes_sent + ) + + local uri_params = "status=" .. valid_status_code .. "&bytes=" .. valid_body_bytes_sent + local uri = "http://10.10.10.70:3000/track/download/" .. valid_skylink .. "?" .. uri_params + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(ngx.log).was_called_with( + ngx.ERR, + "Failed accounts service request /track/download/" .. valid_skylink .. ": ", + "[HTTP 404] baz" + ) + end) + + it("should log message on tracker request error", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return nil, "foo != bar" -- return error + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_download_timer( + false, + valid_skylink, + valid_status_code, + valid_auth_headers, + valid_body_bytes_sent + ) + + local uri_params = "status=" .. valid_status_code .. "&bytes=" .. valid_body_bytes_sent + local uri = "http://10.10.10.70:3000/track/download/" .. valid_skylink .. "?" .. uri_params + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(ngx.log).was_called_with( + ngx.ERR, + "Failed accounts service request /track/download/" .. valid_skylink .. ": ", + "foo != bar" + ) + end) + end) +end) + +describe("track_upload", function() + before_each(function() + stub(ngx.timer, "at") + end) + + after_each(function() + ngx.timer.at:revert() + end) + + it("should schedule a timer when conditions are met", function() + ngx.timer.at.invokes(function() return true, nil end) + + skynet_tracker.track_upload(valid_skylink, valid_status_code, valid_auth_headers) + + assert.stub(ngx.timer.at).was_called_with( + 0, + skynet_tracker.track_upload_timer, + valid_skylink, + valid_auth_headers + ) + end) + + it("should not schedule a timer if skylink is empty", function() + ngx.timer.at.invokes(function() return true, nil end) + + skynet_tracker.track_upload(nil, valid_status_code, valid_auth_headers) + + assert.stub(ngx.timer.at).was_not_called() + end) + + it("should not schedule a timer if status code is not in 2XX range", function() + ngx.timer.at.invokes(function() return true, nil end) + + -- couple of example of 4XX and 5XX codes + skynet_tracker.track_upload(valid_skylink, 401, valid_auth_headers) + skynet_tracker.track_upload(valid_skylink, 403, valid_auth_headers) + skynet_tracker.track_upload(valid_skylink, 490, valid_auth_headers) + skynet_tracker.track_upload(valid_skylink, 500, valid_auth_headers) + skynet_tracker.track_upload(valid_skylink, 502, valid_auth_headers) + + assert.stub(ngx.timer.at).was_not_called() + end) + + it("should not schedule a timer if auth headers are empty", function() + ngx.timer.at.invokes(function() return true, nil end) + + skynet_tracker.track_upload(valid_skylink, valid_status_code, {}) + + assert.stub(ngx.timer.at).was_not_called() + end) + + it("should log an error if timer failed to create", function() + stub(ngx, "log") + ngx.timer.at.invokes(function() return false, "such a failure" end) + + skynet_tracker.track_upload(valid_skylink, valid_status_code, valid_auth_headers) + + assert.stub(ngx.timer.at).was_called_with( + 0, + skynet_tracker.track_upload_timer, + valid_skylink, + valid_auth_headers + ) + assert.stub(ngx.log).was_called_with(ngx.ERR, "Failed to create timer: ", "such a failure") + + ngx.log:revert() + end) + + describe("track_upload_timer", function() + before_each(function() + stub(ngx, "log") + end) + + after_each(function() + local resty_http = require("resty.http") + + ngx.log:revert() + resty_http.new:revert() + end) + + it("should exit early on premature", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 200 } -- return 200 success + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_upload_timer( + true, + valid_skylink, + valid_auth_headers + ) + + assert.stub(request_uri).was_not_called() + assert.stub(ngx.log).was_not_called() + end) + + it("should make a post request to tracker service", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 204 } -- return 204 success + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_upload_timer( + false, + valid_skylink, + valid_auth_headers + ) + + local uri = "http://10.10.10.70:3000/track/upload/" .. valid_skylink + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(ngx.log).was_not_called() + end) + + it("should log message on tracker request failure with response code", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 404, body = "baz" } -- return 404 failure + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_upload_timer( + false, + valid_skylink, + valid_auth_headers + ) + + local uri = "http://10.10.10.70:3000/track/upload/" .. valid_skylink + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(ngx.log).was_called_with( + ngx.ERR, + "Failed accounts service request /track/upload/" .. valid_skylink .. ": ", + "[HTTP 404] baz" + ) + end) + + it("should log message on tracker request error", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return nil, "foo != bar" -- return error + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_upload_timer( + false, + valid_skylink, + valid_auth_headers + ) + + local uri = "http://10.10.10.70:3000/track/upload/" .. valid_skylink + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(ngx.log).was_called_with( + ngx.ERR, + "Failed accounts service request /track/upload/" .. valid_skylink .. ": ", + "foo != bar" + ) + end) + end) +end) + +describe("track_registry", function() + local status_code_ok = 200 + local status_code_not_found = 404 + local request_method_write = "POST" + local request_method_read = "GET" + + before_each(function() + stub(ngx.timer, "at") + end) + + after_each(function() + ngx.timer.at:revert() + end) + + it("should schedule a timer when status code was 200", function() + ngx.timer.at.invokes(function() return true, nil end) + + skynet_tracker.track_registry(status_code_ok, valid_auth_headers, request_method_write) + + assert.stub(ngx.timer.at).was_called_with( + 0, + skynet_tracker.track_registry_timer, + valid_auth_headers, + request_method_write + ) + end) + + it("should schedule a timer when status code was 404", function() + ngx.timer.at.invokes(function() return true, nil end) + + skynet_tracker.track_registry(status_code_not_found, valid_auth_headers, request_method_write) + + assert.stub(ngx.timer.at).was_called_with( + 0, + skynet_tracker.track_registry_timer, + valid_auth_headers, + request_method_write + ) + end) + + it("should not schedule a timer if status code is not in 200 or 404", function() + ngx.timer.at.invokes(function() return true, nil end) + + -- couple of example of invalid 2XX, 4XX and 5XX codes + skynet_tracker.track_registry(204, valid_auth_headers, request_method_write) + skynet_tracker.track_registry(206, valid_auth_headers, request_method_write) + skynet_tracker.track_registry(401, valid_auth_headers, request_method_write) + skynet_tracker.track_registry(403, valid_auth_headers, request_method_write) + skynet_tracker.track_registry(490, valid_auth_headers, request_method_write) + skynet_tracker.track_registry(500, valid_auth_headers, request_method_write) + skynet_tracker.track_registry(502, valid_auth_headers, request_method_write) + + assert.stub(ngx.timer.at).was_not_called() + end) + + it("should not schedule a timer if auth headers are empty", function() + ngx.timer.at.invokes(function() return true, nil end) + + skynet_tracker.track_registry(status_code_ok, {}, request_method_write) + + assert.stub(ngx.timer.at).was_not_called() + end) + + it("should log an error if timer failed to create", function() + stub(ngx, "log") + ngx.timer.at.invokes(function() return false, "such a failure" end) + + skynet_tracker.track_registry(status_code_ok, valid_auth_headers, request_method_write) + + assert.stub(ngx.timer.at).was_called_with( + 0, + skynet_tracker.track_registry_timer, + valid_auth_headers, + request_method_write + ) + assert.stub(ngx.log).was_called_with(ngx.ERR, "Failed to create timer: ", "such a failure") + + ngx.log:revert() + end) + + describe("track_registry_timer", function() + before_each(function() + stub(ngx, "log") + end) + + after_each(function() + local resty_http = require("resty.http") + + ngx.log:revert() + resty_http.new:revert() + end) + + it("should exit early on premature", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 200 } -- return 200 success + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_registry_timer( + true, + valid_auth_headers, + request_method_write + ) + + assert.stub(request_uri).was_not_called() + assert.stub(ngx.log).was_not_called() + end) + + it("should make a post request to registry write tracker service", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 204 } -- return 204 success + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_registry_timer( + false, + valid_auth_headers, + request_method_write + ) + + local uri = "http://10.10.10.70:3000/track/registry/write" + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(ngx.log).was_not_called() + end) + + it("should make a post request to registry read tracker service", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 204 } -- return 204 success + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_registry_timer( + false, + valid_auth_headers, + request_method_read + ) + + local uri = "http://10.10.10.70:3000/track/registry/read" + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(ngx.log).was_not_called() + end) + + it("should log message on tracker request failure with response code", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return { status = 404, body = "baz" } -- return 404 failure + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_registry_timer( + false, + valid_auth_headers, + request_method_write + ) + + local uri = "http://10.10.10.70:3000/track/registry/write" + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(ngx.log).was_called_with( + ngx.ERR, + "Failed accounts service request /track/registry/write: ", + "[HTTP 404] baz" + ) + end) + + it("should log message on tracker request error", function() + local resty_http = require("resty.http") + local request_uri = spy.new(function() + return nil, "foo != bar" -- return error + end) + local httpc = mock({ request_uri = request_uri }) + stub(resty_http, "new").returns(httpc) + + skynet_tracker.track_registry_timer( + false, + valid_auth_headers, + request_method_write + ) + + local uri = "http://10.10.10.70:3000/track/registry/write" + assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(ngx.log).was_called_with( + ngx.ERR, + "Failed accounts service request /track/registry/write: ", + "foo != bar" + ) + end) + end) +end) \ No newline at end of file diff --git a/docker/nginx/libs/skynet/utils.lua b/docker/nginx/libs/skynet/utils.lua index adee23b2..05755f7b 100644 --- a/docker/nginx/libs/skynet/utils.lua +++ b/docker/nginx/libs/skynet/utils.lua @@ -1,13 +1,20 @@ local _M = {} +local ngx_base64 = require("ngx.base64") +local utils = require("utils") + function _M.authorization_header() -- read api password from env variable - local apipassword = os.getenv("SIA_API_PASSWORD") + local apipassword = utils.getenv("SIA_API_PASSWORD") -- if api password is not available as env variable, read it from disk - if apipassword == nil or apipassword == "" then + if not apipassword then -- open apipassword file for reading (b flag is required for some reason) -- (file /etc/.sia/apipassword has to be mounted from the host system) local apipassword_file = io.open("/data/sia/apipassword", "rb") + -- make sure to throw a meaningful error if apipassword file does not exist + if not apipassword_file then + error("Error reading /data/sia/apipassword file") + end -- read apipassword file contents and trim newline (important) apipassword = apipassword_file:read("*all"):gsub("%s+", "") -- make sure to close file after reading the password @@ -15,7 +22,7 @@ function _M.authorization_header() end -- encode the user:password authorization string -- (in our case user is empty so it is just :password) - local content = require("ngx.base64").encode_base64url(":" .. apipassword) + local content = ngx_base64.encode_base64url(":" .. apipassword) -- set authorization header with proper base64 encoded string return "Basic " .. content end diff --git a/docker/nginx/libs/skynet/utils.spec.lua b/docker/nginx/libs/skynet/utils.spec.lua new file mode 100644 index 00000000..171be4fa --- /dev/null +++ b/docker/nginx/libs/skynet/utils.spec.lua @@ -0,0 +1,65 @@ +-- luacheck: ignore io + +local utils = require('utils') +local skynet_utils = require('skynet.utils') + +describe("authorization_header", function() + local apipassword = "ddd0c1430fbf2708" + local expected_header = "Basic OmRkZDBjMTQzMGZiZjI3MDg" + + it("reads SIA_API_PASSWORD from env variable and returns a header", function() + -- stub getenv on SIA_API_PASSWORD + stub(utils, "getenv") + utils.getenv.on_call_with("SIA_API_PASSWORD").returns(apipassword) + + local header = skynet_utils.authorization_header() + + assert.is_equal(header, expected_header) + + -- revert stub to original function + utils.getenv:revert() + end) + + it("uses /data/sia/apipassword file if SIA_API_PASSWORD env var is missing", function() + -- stub /data/sia/apipassword file + stub(io, "open") + io.open.on_call_with("/data/sia/apipassword", "rb").returns(mock({ + read = spy.new(function() return apipassword end), + close = spy.new() + })) + + local header = skynet_utils.authorization_header() + + assert.is_equal(header, expected_header) + + -- revert stub to original function + io.open:revert() + end) + + it("should choose env variable over file if both are available", function() + -- stub getenv on SIA_API_PASSWORD + stub(utils, "getenv") + utils.getenv.on_call_with("SIA_API_PASSWORD").returns(apipassword) + + -- stub /data/sia/apipassword file + stub(io, "open") + io.open.on_call_with("/data/sia/apipassword", "rb").returns(mock({ + read = spy.new(function() return "foooooooooooooo" end), + close = spy.new() + })) + + local header = skynet_utils.authorization_header() + + assert.is_equal(header, "Basic OmRkZDBjMTQzMGZiZjI3MDg") + + -- revert stubs to original function + utils.getenv:revert() + io.open:revert() + end) + + it("should error out if neither env variable is available nor file exists", function() + assert.has_error(function() + skynet_utils.authorization_header() + end, "Error reading /data/sia/apipassword file") + end) +end) diff --git a/docker/nginx/libs/utils.lua b/docker/nginx/libs/utils.lua index 4330c94c..3b9b2592 100644 --- a/docker/nginx/libs/utils.lua +++ b/docker/nginx/libs/utils.lua @@ -42,4 +42,42 @@ function _M.extract_cookie_value(cookie_string, name_matcher) return string.sub(cookie, value_start) end +-- utility function that builds on os.getenv to get environment variable value +-- * will always return nil for both unset and empty env vars +-- * parse "boolean": "true" and "1" as true, "false" and "0" as false, throws for others +-- * parse "integer": any numerical string gets converted, otherwise returns nil +function _M.getenv(name, parse) + local value = os.getenv(name) + + -- treat empty string value as nil to simplify comparisons + if value == nil or value == "" then + return nil + end + + -- do not parse the value + if parse == nil then + return value + end + + -- try to parse as boolean + if parse == "boolean" then + if value == "true" or value == "1" then + return true + end + + if value == "false" or value == "0" then + return false + end + + error("utils.getenv: Parsing value '" .. tostring(value) .. "' to boolean is not supported") + end + + -- try to parse as integer + if parse == "integer" then + return tonumber(value) + end + + error("utils.getenv: Parsing to '" .. parse .. "' is not supported") +end + return _M diff --git a/docker/nginx/libs/utils.spec.lua b/docker/nginx/libs/utils.spec.lua index c853c8cd..af43e898 100644 --- a/docker/nginx/libs/utils.spec.lua +++ b/docker/nginx/libs/utils.spec.lua @@ -1,3 +1,5 @@ +-- luacheck: ignore os + local utils = require('utils') describe("is_table_empty", function() @@ -77,3 +79,125 @@ describe("extract_cookie_value", function() assert.are.equals(value, "MTY0NzUyr8jD-ytiWtspm0tGabKfooxeIDuWcXhJ3lnY0eEw==") end) end) + +describe("getenv", function() + before_each(function() + stub(os, "getenv") + end) + + after_each(function() + os.getenv:revert() + end) + + it("should return nil for not existing env var", function() + os.getenv.on_call_with("foo").returns(nil) + + assert.is_nil(utils.getenv("foo")) + end) + + it("should return nil for env var that is an empty string", function() + os.getenv.on_call_with("foo").returns("") + + assert.is_nil(utils.getenv("foo")) + end) + + it("should return the value as is when it is non empty string", function() + os.getenv.on_call_with("foo").returns("bar") + + assert.is_equal(utils.getenv("foo"), "bar") + end) + + describe("parse", function() + it("should throw on not supported parser", function() + os.getenv.on_call_with("foo").returns("test") + + assert.has_error(function() + utils.getenv("foo", "starwars") + end, "utils.getenv: Parsing to 'starwars' is not supported") + end) + + describe("as boolean", function() + it("should return nil for not existing env var", function() + os.getenv.on_call_with("foo").returns(nil) + + assert.is_nil(utils.getenv("foo", "boolean")) + end) + + it("should return nil for env var that is an empty string", function() + os.getenv.on_call_with("foo").returns("") + + assert.is_nil(utils.getenv("foo", "boolean")) + end) + + it("should parse 'true' string as true", function() + os.getenv.on_call_with("foo").returns("true") + + assert.is_true(utils.getenv("foo", "boolean")) + end) + + it("should parse '1' string as true", function() + os.getenv.on_call_with("foo").returns("1") + + assert.is_true(utils.getenv("foo", "boolean")) + end) + + it("should parse 'false' string as false", function() + os.getenv.on_call_with("foo").returns("false") + + assert.is_false(utils.getenv("foo", "boolean")) + end) + + it("should parse '0' string as false", function() + os.getenv.on_call_with("foo").returns("0") + + assert.is_false(utils.getenv("foo", "boolean")) + end) + + it("should throw an error for not supported string", function() + os.getenv.on_call_with("foo").returns("mandalorian") + + assert.has_error(function() + utils.getenv("foo", "boolean") + end, "utils.getenv: Parsing value 'mandalorian' to boolean is not supported") + end) + end) + + describe("as integer", function() + it("should return nil for not existing env var", function() + os.getenv.on_call_with("foo").returns(nil) + + assert.is_nil(utils.getenv("foo", "integer")) + end) + + it("should return nil for env var that is an empty string", function() + os.getenv.on_call_with("foo").returns("") + + assert.is_nil(utils.getenv("foo", "integer")) + end) + + it("should parse '0' string as 0", function() + os.getenv.on_call_with("foo").returns("0") + + assert.equals(utils.getenv("foo", "integer"), 0) + end) + + it("should parse '1' string as 1", function() + os.getenv.on_call_with("foo").returns("1") + + assert.equals(utils.getenv("foo", "integer"), 1) + end) + + it("should parse '-1' string as 1", function() + os.getenv.on_call_with("foo").returns("-1") + + assert.equals(utils.getenv("foo", "integer"), -1) + end) + + it("should return nil for non numerical string", function() + os.getenv.on_call_with("foo").returns("test") + + assert.is_nil(utils.getenv("foo", "integer")) + end) + end) + end) +end) diff --git a/docker/nginx/testing/.luacov b/docker/nginx/testing/.luacov new file mode 100644 index 00000000..2c55f3da --- /dev/null +++ b/docker/nginx/testing/.luacov @@ -0,0 +1,6 @@ +exclude = { + "/usr/local/openresty", -- internal openresty libraries + "rbusted", -- busted executable + "basexx", -- external library https://github.com/aiq/basexx +} +includeuntestedfiles = true diff --git a/docker/nginx/testing/Dockerfile b/docker/nginx/testing/Dockerfile new file mode 100644 index 00000000..ae2cd78f --- /dev/null +++ b/docker/nginx/testing/Dockerfile @@ -0,0 +1,11 @@ +FROM openresty/openresty:1.19.9.1-focal + +WORKDIR /etc/nginx + +RUN luarocks install lua-resty-http && \ + luarocks install hasher && \ + luarocks install busted + +COPY rbusted /etc/nginx/ + +CMD /etc/nginx/rbusted --verbose --pattern=spec /usr/local/openresty/site/lualib diff --git a/docker/nginx/testing/README.md b/docker/nginx/testing/README.md new file mode 100644 index 00000000..f40e8d95 --- /dev/null +++ b/docker/nginx/testing/README.md @@ -0,0 +1,3 @@ +# Running tests locally + +`docker run -v $(pwd)/docker/nginx/libs:/usr/local/openresty/site/lualib --rm -it $(docker build -q docker/nginx/testing)` diff --git a/docker/nginx/testing/rbusted b/docker/nginx/testing/rbusted new file mode 100755 index 00000000..94149350 --- /dev/null +++ b/docker/nginx/testing/rbusted @@ -0,0 +1,8 @@ +#!/usr/bin/env resty + +setmetatable(_G, nil) + +pcall(require, "luarocks.loader") + +-- Busted command-line runner +require "busted.runner"({ standalone = false }) From e2171b5a8923803d0d79b610ca9d9537cd74b5d1 Mon Sep 17 00:00:00 2001 From: Ivaylo Novakov Date: Wed, 6 Apr 2022 18:18:32 +0200 Subject: [PATCH 113/240] Don't use a default reason when downing a portal. --- scripts/portal-down.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/scripts/portal-down.sh b/scripts/portal-down.sh index a60ed863..476ce837 100755 --- a/scripts/portal-down.sh +++ b/scripts/portal-down.sh @@ -12,7 +12,11 @@ do done delay=${delay:-0} # default to no delay timeout=${timeout:-300} # default timeout is 300s -reason=${reason:-"disabled manually"} + +if [[ -z $reason ]]; then + echo "Please provide a reason for disabling the portal (use '-r ')." + exit 1 +fi countdown() { local secs=$1 @@ -26,7 +30,7 @@ countdown() { # delay disabling the portal countdown $delay -# stop healh-check so the server is taken our of load balancer +# stop health-check so the server is taken our of load balancer docker exec health-check cli disable $reason # then wait 5 minutes for the load balancer to propagate the dns records From a6687a8457f2b456b98d838f275fadeb6c7c07d3 Mon Sep 17 00:00:00 2001 From: Ivaylo Novakov Date: Wed, 6 Apr 2022 18:19:20 +0200 Subject: [PATCH 114/240] Fix README link. --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 4c27d268..337f9791 100644 --- a/README.md +++ b/README.md @@ -5,8 +5,8 @@ Latest Skynet Webportal setup documentation and the setup process Skynet Labs supports is located at https://docs.siasky.net/webportal-management/overview. -Some of the scripts and setup documentation contained in this repository -(`skynet-webportal`) can be outdated and generally should not be used. +Some scripts and setup documentation contained in this repository +(`skynet-webportal`) may be outdated and generally should not be used. ## Web application @@ -35,7 +35,7 @@ For the purposes of complying with our code license, you can use the following S `fb6c9320bc7e01fbb9cd8d8c3caaa371386928793c736837832e634aaaa484650a3177d6714a` ## Running a Portal -For those interested in running a Webportal, head over to our developer docs [here](https://docs.siasky.net/webportal-management/overview.) to learn more. +For those interested in running a Webportal, head over to our developer docs [here](https://portal-docs.skynetlabs.com/) to learn more. ## Contributing From 688dbbd52fcb33259fa740bfa9b45abf06261355 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 7 Apr 2022 12:59:20 +0200 Subject: [PATCH 115/240] ops(dashboard-v2): prepare Dockerfile (#1971) * ops(dashboard-v2): prepare Dockerfile * ops(dashboard-v2): lint dashboard-v2/Dockerfile --- .github/workflows/lint-dockerfiles.yml | 1 + docker-compose.accounts.yml | 22 +++++++++++++++++++ packages/dashboard-v2/Dockerfile | 14 ++++++++++++ packages/dashboard-v2/gatsby-config.js | 2 +- .../src/hooks/useUpgradeRedirect.js | 1 - .../src/layouts/DashboardLayout.js | 2 +- .../src/layouts/UserSettingsLayout.js | 2 +- .../dashboard-v2/src/pages/auth/signup.js | 2 +- packages/dashboard-v2/yarn.lock | 2 +- 9 files changed, 42 insertions(+), 6 deletions(-) create mode 100644 packages/dashboard-v2/Dockerfile diff --git a/.github/workflows/lint-dockerfiles.yml b/.github/workflows/lint-dockerfiles.yml index 1eea156c..467dc117 100644 --- a/.github/workflows/lint-dockerfiles.yml +++ b/.github/workflows/lint-dockerfiles.yml @@ -16,6 +16,7 @@ jobs: - docker/nginx/Dockerfile - docker/sia/Dockerfile - packages/dashboard/Dockerfile + - packages/dashboard-v2/Dockerfile - packages/dnslink-api/Dockerfile - packages/handshake-api/Dockerfile - packages/health-check/Dockerfile diff --git a/docker-compose.accounts.yml b/docker-compose.accounts.yml index 5d9d345c..73953a57 100644 --- a/docker-compose.accounts.yml +++ b/docker-compose.accounts.yml @@ -75,3 +75,25 @@ services: - 3000 depends_on: - mongo + + dashboard-v2: + build: + context: ./packages/dashboard-v2 + dockerfile: Dockerfile + container_name: dashboard-v2 + restart: unless-stopped + logging: *default-logging + env_file: + - .env + environment: + - GATSBY_PORTAL_DOMAIN=${PORTAL_DOMAIN} + volumes: + - ./docker/data/dashboard-v2/.cache:/usr/app/.cache + - ./docker/data/dashboard-v2/public:/usr/app/public + networks: + shared: + ipv4_address: 10.10.10.90 + expose: + - 9000 + depends_on: + - mongo diff --git a/packages/dashboard-v2/Dockerfile b/packages/dashboard-v2/Dockerfile new file mode 100644 index 00000000..70790cfa --- /dev/null +++ b/packages/dashboard-v2/Dockerfile @@ -0,0 +1,14 @@ +FROM node:16.14.2-alpine + +WORKDIR /usr/app + +COPY package.json yarn.lock ./ + +RUN yarn --frozen-lockfile + +COPY static ./static +COPY src ./src +COPY gatsby*.js ./ +COPY postcss.config.js tailwind.config.js ./ + +CMD ["sh", "-c", "yarn build && yarn serve --host 0.0.0.0 -p 9000"] diff --git a/packages/dashboard-v2/gatsby-config.js b/packages/dashboard-v2/gatsby-config.js index c6096a98..2280f99b 100644 --- a/packages/dashboard-v2/gatsby-config.js +++ b/packages/dashboard-v2/gatsby-config.js @@ -18,7 +18,7 @@ module.exports = { resolve: "gatsby-source-filesystem", options: { name: "images", - path: "./src/images/", + path: "./static/images/", }, __key: "images", }, diff --git a/packages/dashboard-v2/src/hooks/useUpgradeRedirect.js b/packages/dashboard-v2/src/hooks/useUpgradeRedirect.js index 5529c152..54efd956 100644 --- a/packages/dashboard-v2/src/hooks/useUpgradeRedirect.js +++ b/packages/dashboard-v2/src/hooks/useUpgradeRedirect.js @@ -17,7 +17,6 @@ export default function useUpgradeRedirect() { if (isDataLoaded) { if (settings.isSubscriptionRequired && !hasPaidSubscription) { - console.log("redirecting", user, settings); navigate("/upgrade"); } else { setVerifyingSubscription(false); diff --git a/packages/dashboard-v2/src/layouts/DashboardLayout.js b/packages/dashboard-v2/src/layouts/DashboardLayout.js index 76af9218..fe4c5385 100644 --- a/packages/dashboard-v2/src/layouts/DashboardLayout.js +++ b/packages/dashboard-v2/src/layouts/DashboardLayout.js @@ -5,7 +5,7 @@ import { SWRConfig } from "swr"; import { authenticatedOnly } from "../lib/swrConfig"; import { PageContainer } from "../components/PageContainer"; -import { NavBar } from "../components/Navbar"; +import { NavBar } from "../components/NavBar"; import { Footer } from "../components/Footer"; import { UserProvider, useUser } from "../contexts/user"; import { FullScreenLoadingIndicator } from "../components/LoadingIndicator"; diff --git a/packages/dashboard-v2/src/layouts/UserSettingsLayout.js b/packages/dashboard-v2/src/layouts/UserSettingsLayout.js index 2ca769bc..d7b9b7d4 100644 --- a/packages/dashboard-v2/src/layouts/UserSettingsLayout.js +++ b/packages/dashboard-v2/src/layouts/UserSettingsLayout.js @@ -6,7 +6,7 @@ import { SWRConfig } from "swr"; import { authenticatedOnly } from "../lib/swrConfig"; import { PageContainer } from "../components/PageContainer"; -import { NavBar } from "../components/Navbar"; +import { NavBar } from "../components/NavBar"; import { Footer } from "../components/Footer"; import { UserProvider, useUser } from "../contexts/user"; import { ContainerLoadingIndicator } from "../components/LoadingIndicator"; diff --git a/packages/dashboard-v2/src/pages/auth/signup.js b/packages/dashboard-v2/src/pages/auth/signup.js index b6f0e0ac..4da915f1 100644 --- a/packages/dashboard-v2/src/pages/auth/signup.js +++ b/packages/dashboard-v2/src/pages/auth/signup.js @@ -15,7 +15,7 @@ const FreePortalHeader = () => { const { plans } = usePlans(); const freePlan = plans.find(({ price }) => price === 0); - const freeStorage = freePlan ? bytes(freePlan.limits?.storageLimit, { binary: true }) : null; + const freeStorage = freePlan?.limits ? bytes(freePlan.limits?.storageLimit, { binary: true }) : null; return (
    diff --git a/packages/dashboard-v2/yarn.lock b/packages/dashboard-v2/yarn.lock index 30d4e8e8..c3de4379 100644 --- a/packages/dashboard-v2/yarn.lock +++ b/packages/dashboard-v2/yarn.lock @@ -14090,7 +14090,7 @@ sjcl@^1.0.8: resolved "https://registry.yarnpkg.com/sjcl/-/sjcl-1.0.8.tgz#f2ec8d7dc1f0f21b069b8914a41a8f236b0e252a" integrity sha512-LzIjEQ0S0DpIgnxMEayM1rq9aGwGRG4OnZhCdjx7glTaJtf4zRfpg87ImfjSJjoW9vKpagd82McDOwbRT5kQKQ== -skynet-js@^4.0.27-beta: +skynet-js@4.0.27-beta: version "4.0.27-beta" resolved "https://registry.yarnpkg.com/skynet-js/-/skynet-js-4.0.27-beta.tgz#4257bffda8757830656e0beb89d0d2e44da17e2f" integrity sha512-JV+QE/2l2YwVN1jQHVMFXgggwtBrPAnuyXySbLgafEJAde5dUwSEr5YRMV+3LvEgYkGhxSb74pyq0u0wrF2sUg== From e7183f471bd2dfd9a7ce7dddaded074d9cecbe64 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20Wypch=C5=82o?= Date: Thu, 7 Apr 2022 13:52:23 +0200 Subject: [PATCH 116/240] remove max body size constraint on tus endpoint (#1976) --- docker/nginx/conf.d/server/server.api | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker/nginx/conf.d/server/server.api b/docker/nginx/conf.d/server/server.api index f681cca8..5bd1aa61 100644 --- a/docker/nginx/conf.d/server/server.api +++ b/docker/nginx/conf.d/server/server.api @@ -241,8 +241,8 @@ location /skynet/tus { limit_conn upload_conn 5; limit_conn upload_conn_rl 1; - # TUS chunks size is 40M + leaving 10M of breathing room - client_max_body_size 50M; + # Do not limit body size in nginx, skyd will reject early on too large upload + client_max_body_size 0; # Those timeouts need to be elevated since skyd can stall reading # data for a while when overloaded which would terminate connection From d577f332b68170ac82689fb8a980e2ef4db90eac Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 7 Apr 2022 14:12:24 +0200 Subject: [PATCH 117/240] use website docker image --- docker-compose.yml | 8 +++++--- packages/website/Dockerfile | 16 +++++++++++----- 2 files changed, 16 insertions(+), 8 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 2879b8b6..973d5a97 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -82,9 +82,11 @@ services: - website website: - build: - context: ./packages/website - dockerfile: Dockerfile + # uncomment "build" and comment out "image" to build from sources + # build: + # context: https://github.com/SkynetLabs/skynet-webportal.git#master + # dockerfile: ./packages/website/Dockerfile + image: skynetlabs/website container_name: website restart: unless-stopped logging: *default-logging diff --git a/packages/website/Dockerfile b/packages/website/Dockerfile index 3a9fa9a1..9477a4f6 100644 --- a/packages/website/Dockerfile +++ b/packages/website/Dockerfile @@ -4,16 +4,22 @@ RUN apk add --no-cache autoconf=2.71-r0 automake=1.16.4-r1 build-base=0.5-r2 lib WORKDIR /usr/app -COPY package.json yarn.lock ./ +COPY packages/website/package.json packages/website/yarn.lock ./ ENV GATSBY_TELEMETRY_DISABLED 1 ENV CYPRESS_INSTALL_BINARY 0 RUN yarn --frozen-lockfile -COPY data ./data -COPY src ./src -COPY static ./static -COPY gatsby-browser.js gatsby-config.js gatsby-node.js gatsby-ssr.js postcss.config.js tailwind.config.js ./ +COPY packages/website/data ./data +COPY packages/website/src ./src +COPY packages/website/static ./static +COPY packages/website/gatsby-browser.js \ + packages/website/gatsby-config.js \ + packages/website/gatsby-node.js \ + packages/website/gatsby-ssr.js \ + packages/website/postcss.config.js \ + packages/website/tailwind.config.js \ + ./ RUN yarn build From 40b8390c193e519e4b564c3dea75d17ab1e94fec Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 7 Apr 2022 14:38:19 +0200 Subject: [PATCH 118/240] use handshake-api docker image --- docker-compose.yml | 8 +++++--- packages/handshake-api/Dockerfile | 4 ++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 973d5a97..1ab54e0f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -120,9 +120,11 @@ services: - 12037 handshake-api: - build: - context: ./packages/handshake-api - dockerfile: Dockerfile + # uncomment "build" and comment out "image" to build from sources + # build: + # context: https://github.com/SkynetLabs/skynet-webportal.git#master + # dockerfile: ./packages/handshake-api/Dockerfile + image: skynetlabs/handshake-api container_name: handshake-api restart: unless-stopped logging: *default-logging diff --git a/packages/handshake-api/Dockerfile b/packages/handshake-api/Dockerfile index 92f30b36..2f6930b0 100644 --- a/packages/handshake-api/Dockerfile +++ b/packages/handshake-api/Dockerfile @@ -2,11 +2,11 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY package.json yarn.lock ./ +COPY packages/handshake-api/package.json packages/handshake-api/yarn.lock ./ RUN yarn --frozen-lockfile -COPY src/* src/ +COPY packages/handshake-api/src/* src/ ENV HSD_NETWORK="main" ENV HSD_HOST="0.0.0.0" From 1d50d51f2987526256033fa73dfaa45b3be259f6 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 7 Apr 2022 14:39:53 +0200 Subject: [PATCH 119/240] use dnslink-api docker image --- docker-compose.yml | 8 +++++--- packages/dnslink-api/Dockerfile | 4 ++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 1ab54e0f..153d6f16 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -144,9 +144,11 @@ services: - handshake dnslink-api: - build: - context: ./packages/dnslink-api - dockerfile: Dockerfile + # uncomment "build" and comment out "image" to build from sources + # build: + # context: https://github.com/SkynetLabs/skynet-webportal.git#master + # dockerfile: ./packages/dnslink-api/Dockerfile + image: skynetlabs/dnslink-api container_name: dnslink-api restart: unless-stopped logging: *default-logging diff --git a/packages/dnslink-api/Dockerfile b/packages/dnslink-api/Dockerfile index be1f9452..fd477e87 100644 --- a/packages/dnslink-api/Dockerfile +++ b/packages/dnslink-api/Dockerfile @@ -2,11 +2,11 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY package.json yarn.lock ./ +COPY packages/dnslink-api/package.json packages/dnslink-api/yarn.lock ./ RUN yarn --frozen-lockfile -COPY src/* src/ +COPY packages/dnslink-api/src/* src/ EXPOSE 3100 CMD ["node", "src/index.js"] From 73dad081eaf9a76b3c1de248fd2b3fdc8ef54021 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 7 Apr 2022 14:41:18 +0200 Subject: [PATCH 120/240] use health-check docker image --- docker-compose.yml | 8 +++++--- packages/health-check/Dockerfile | 8 ++++---- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 153d6f16..5838f136 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -159,9 +159,11 @@ services: - 3100 health-check: - build: - context: ./packages/health-check - dockerfile: Dockerfile + # uncomment "build" and comment out "image" to build from sources + # build: + # context: https://github.com/SkynetLabs/skynet-webportal.git#master + # dockerfile: ./packages/health-check/Dockerfile + image: skynetlabs/health-check container_name: health-check restart: unless-stopped logging: *default-logging diff --git a/packages/health-check/Dockerfile b/packages/health-check/Dockerfile index e9d15a77..cc4cb793 100644 --- a/packages/health-check/Dockerfile +++ b/packages/health-check/Dockerfile @@ -11,13 +11,13 @@ ENV PATH="/usr/app/bin:${PATH}" RUN echo '*/5 * * * * source /etc/environment ; /usr/app/bin/cli run critical >> /proc/1/fd/1' >> /etc/crontabs/root && \ echo '0 * * * * source /etc/environment ; /usr/app/bin/cli run extended >> /proc/1/fd/1' >> /etc/crontabs/root -COPY package.json yarn.lock ./ +COPY packages/health-check/package.json packages/health-check/yarn.lock ./ RUN yarn --frozen-lockfile -COPY src src -COPY cli cli -COPY bin bin +COPY packages/health-check/src src +COPY packages/health-check/cli cli +COPY packages/health-check/bin bin EXPOSE 3100 ENV NODE_ENV production From 7963c2cb63ee07817362e685f8134bf45cdffe02 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 7 Apr 2022 14:47:49 +0200 Subject: [PATCH 121/240] use dashboard docker images --- docker-compose.accounts.yml | 16 ++++++++++------ packages/dashboard-v2/Dockerfile | 12 +++++++----- packages/dashboard/Dockerfile | 13 ++++++++----- 3 files changed, 25 insertions(+), 16 deletions(-) diff --git a/docker-compose.accounts.yml b/docker-compose.accounts.yml index 73953a57..9fa4722d 100644 --- a/docker-compose.accounts.yml +++ b/docker-compose.accounts.yml @@ -55,9 +55,11 @@ services: - mongo dashboard: - build: - context: ./packages/dashboard - dockerfile: Dockerfile + # uncomment "build" and comment out "image" to build from sources + # build: + # context: https://github.com/SkynetLabs/skynet-webportal.git#master + # dockerfile: ./packages/dashboard/Dockerfile + image: skynetlabs/dashboard container_name: dashboard restart: unless-stopped logging: *default-logging @@ -77,9 +79,11 @@ services: - mongo dashboard-v2: - build: - context: ./packages/dashboard-v2 - dockerfile: Dockerfile + # uncomment "build" and comment out "image" to build from sources + # build: + # context: https://github.com/SkynetLabs/skynet-webportal.git#master + # dockerfile: ./packages/dashboard-v2/Dockerfile + image: skynetlabs/dashboard-v2 container_name: dashboard-v2 restart: unless-stopped logging: *default-logging diff --git a/packages/dashboard-v2/Dockerfile b/packages/dashboard-v2/Dockerfile index 70790cfa..eaa4d073 100644 --- a/packages/dashboard-v2/Dockerfile +++ b/packages/dashboard-v2/Dockerfile @@ -2,13 +2,15 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY package.json yarn.lock ./ +COPY packages/dashboard-v2/package.json packages/dashboard-v2/yarn.lock ./ RUN yarn --frozen-lockfile -COPY static ./static -COPY src ./src -COPY gatsby*.js ./ -COPY postcss.config.js tailwind.config.js ./ +COPY packages/dashboard/static ./static +COPY packages/dashboard/src ./src +COPY packages/dashboard/gatsby*.js ./ +COPY packages/dashboard/postcss.config.js \ + packages/dashboard/tailwind.config.js \ + ./ CMD ["sh", "-c", "yarn build && yarn serve --host 0.0.0.0 -p 9000"] diff --git a/packages/dashboard/Dockerfile b/packages/dashboard/Dockerfile index 39707664..5d8d8391 100644 --- a/packages/dashboard/Dockerfile +++ b/packages/dashboard/Dockerfile @@ -2,14 +2,17 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY package.json yarn.lock ./ +COPY packages/dashboard/package.json packages/dashboard/yarn.lock ./ ENV NEXT_TELEMETRY_DISABLED 1 RUN yarn --frozen-lockfile -COPY public ./public -COPY src ./src -COPY styles ./styles -COPY .eslintrc.json postcss.config.js tailwind.config.js ./ +COPY packages/dashboard/public ./public +COPY packages/dashboard/src ./src +COPY packages/dashboard/styles ./styles +COPY packages/dashboard/.eslintrc.json \ + packages/dashboard/postcss.config.js \ + packages/dashboard/tailwind.config.js \ + ./ CMD ["sh", "-c", "env | grep -E 'NEXT_PUBLIC|STRIPE|ACCOUNTS' > .env.local && yarn build && yarn start"] From e8d68a0fa06db2f2f3959189c58c9b65e66108ae Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 7 Apr 2022 14:51:12 +0200 Subject: [PATCH 122/240] clean up docker images --- packages/dashboard-v2/Dockerfile | 8 +++++--- packages/dashboard/Dockerfile | 4 +++- packages/dnslink-api/Dockerfile | 4 +++- packages/handshake-api/Dockerfile | 4 +++- packages/health-check/Dockerfile | 4 +++- packages/website/Dockerfile | 9 ++++----- 6 files changed, 21 insertions(+), 12 deletions(-) diff --git a/packages/dashboard-v2/Dockerfile b/packages/dashboard-v2/Dockerfile index eaa4d073..4655767b 100644 --- a/packages/dashboard-v2/Dockerfile +++ b/packages/dashboard-v2/Dockerfile @@ -2,14 +2,16 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY packages/dashboard-v2/package.json packages/dashboard-v2/yarn.lock ./ +COPY packages/dashboard-v2/package.json \ + packages/dashboard-v2/yarn.lock \ + ./ RUN yarn --frozen-lockfile COPY packages/dashboard/static ./static COPY packages/dashboard/src ./src -COPY packages/dashboard/gatsby*.js ./ -COPY packages/dashboard/postcss.config.js \ +COPY packages/dashboard/gatsby*.js \ + packages/dashboard/postcss.config.js \ packages/dashboard/tailwind.config.js \ ./ diff --git a/packages/dashboard/Dockerfile b/packages/dashboard/Dockerfile index 5d8d8391..25f584b3 100644 --- a/packages/dashboard/Dockerfile +++ b/packages/dashboard/Dockerfile @@ -2,7 +2,9 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY packages/dashboard/package.json packages/dashboard/yarn.lock ./ +COPY packages/dashboard/package.json \ + packages/dashboard/yarn.lock \ + ./ ENV NEXT_TELEMETRY_DISABLED 1 RUN yarn --frozen-lockfile diff --git a/packages/dnslink-api/Dockerfile b/packages/dnslink-api/Dockerfile index fd477e87..9ded8cbf 100644 --- a/packages/dnslink-api/Dockerfile +++ b/packages/dnslink-api/Dockerfile @@ -2,7 +2,9 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY packages/dnslink-api/package.json packages/dnslink-api/yarn.lock ./ +COPY packages/dnslink-api/package.json \ + packages/dnslink-api/yarn.lock \ + ./ RUN yarn --frozen-lockfile diff --git a/packages/handshake-api/Dockerfile b/packages/handshake-api/Dockerfile index 2f6930b0..211044c1 100644 --- a/packages/handshake-api/Dockerfile +++ b/packages/handshake-api/Dockerfile @@ -2,7 +2,9 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY packages/handshake-api/package.json packages/handshake-api/yarn.lock ./ +COPY packages/handshake-api/package.json \ + packages/handshake-api/yarn.lock \ + ./ RUN yarn --frozen-lockfile diff --git a/packages/health-check/Dockerfile b/packages/health-check/Dockerfile index cc4cb793..15ef0086 100644 --- a/packages/health-check/Dockerfile +++ b/packages/health-check/Dockerfile @@ -11,7 +11,9 @@ ENV PATH="/usr/app/bin:${PATH}" RUN echo '*/5 * * * * source /etc/environment ; /usr/app/bin/cli run critical >> /proc/1/fd/1' >> /etc/crontabs/root && \ echo '0 * * * * source /etc/environment ; /usr/app/bin/cli run extended >> /proc/1/fd/1' >> /etc/crontabs/root -COPY packages/health-check/package.json packages/health-check/yarn.lock ./ +COPY packages/health-check/package.json \ + packages/health-check/yarn.lock \ + ./ RUN yarn --frozen-lockfile diff --git a/packages/website/Dockerfile b/packages/website/Dockerfile index 9477a4f6..dad0e393 100644 --- a/packages/website/Dockerfile +++ b/packages/website/Dockerfile @@ -4,7 +4,9 @@ RUN apk add --no-cache autoconf=2.71-r0 automake=1.16.4-r1 build-base=0.5-r2 lib WORKDIR /usr/app -COPY packages/website/package.json packages/website/yarn.lock ./ +COPY packages/website/package.json \ + packages/website/yarn.lock \ + ./ ENV GATSBY_TELEMETRY_DISABLED 1 ENV CYPRESS_INSTALL_BINARY 0 @@ -13,10 +15,7 @@ RUN yarn --frozen-lockfile COPY packages/website/data ./data COPY packages/website/src ./src COPY packages/website/static ./static -COPY packages/website/gatsby-browser.js \ - packages/website/gatsby-config.js \ - packages/website/gatsby-node.js \ - packages/website/gatsby-ssr.js \ +COPY packages/website/gatsby-*.js \ packages/website/postcss.config.js \ packages/website/tailwind.config.js \ ./ From 7707a34564102f430bc4548b56dd63cdfdb43c60 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 7 Apr 2022 14:55:54 +0200 Subject: [PATCH 123/240] fix dashboard-v2 dockerfile --- packages/dashboard-v2/Dockerfile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard-v2/Dockerfile b/packages/dashboard-v2/Dockerfile index 4655767b..4c834e0c 100644 --- a/packages/dashboard-v2/Dockerfile +++ b/packages/dashboard-v2/Dockerfile @@ -8,11 +8,11 @@ COPY packages/dashboard-v2/package.json \ RUN yarn --frozen-lockfile -COPY packages/dashboard/static ./static -COPY packages/dashboard/src ./src -COPY packages/dashboard/gatsby*.js \ - packages/dashboard/postcss.config.js \ - packages/dashboard/tailwind.config.js \ +COPY packages/dashboard-v2/static ./static +COPY packages/dashboard-v2/src ./src +COPY packages/dashboard-v2/gatsby*.js \ + packages/dashboard-v2/postcss.config.js \ + packages/dashboard-v2/tailwind.config.js \ ./ CMD ["sh", "-c", "yarn build && yarn serve --host 0.0.0.0 -p 9000"] From 8bdb64e745818207da0ab6fc32a4185c2358e2aa Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 7 Apr 2022 14:57:53 +0200 Subject: [PATCH 124/240] build gatsby as a part of docker build process --- packages/dashboard-v2/Dockerfile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/dashboard-v2/Dockerfile b/packages/dashboard-v2/Dockerfile index 4c834e0c..9fb4c604 100644 --- a/packages/dashboard-v2/Dockerfile +++ b/packages/dashboard-v2/Dockerfile @@ -15,4 +15,8 @@ COPY packages/dashboard-v2/gatsby*.js \ packages/dashboard-v2/tailwind.config.js \ ./ -CMD ["sh", "-c", "yarn build && yarn serve --host 0.0.0.0 -p 9000"] +RUN yarn build + +EXPOSE 9000 + +CMD ["sh", "-c", "yarn serve --host 0.0.0.0 -p 9000"] From 6a1e73db2192df5e8634de96e89df0ddcaa1748f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20Wypch=C5=82o?= Date: Thu, 7 Apr 2022 15:08:51 +0200 Subject: [PATCH 125/240] update dashboard-v2 ip --- docker-compose.accounts.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.accounts.yml b/docker-compose.accounts.yml index 73953a57..3c2c46a9 100644 --- a/docker-compose.accounts.yml +++ b/docker-compose.accounts.yml @@ -92,7 +92,7 @@ services: - ./docker/data/dashboard-v2/public:/usr/app/public networks: shared: - ipv4_address: 10.10.10.90 + ipv4_address: 10.10.10.86 expose: - 9000 depends_on: From 66cdd712f09d14be05784d4c110943d1b436a2eb Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 7 Apr 2022 15:16:25 +0200 Subject: [PATCH 126/240] revert using image for dashboard --- docker-compose.accounts.yml | 16 ++++++---------- packages/dashboard-v2/Dockerfile | 20 ++++++-------------- packages/dashboard/Dockerfile | 15 +++++---------- 3 files changed, 17 insertions(+), 34 deletions(-) diff --git a/docker-compose.accounts.yml b/docker-compose.accounts.yml index 9fa4722d..73953a57 100644 --- a/docker-compose.accounts.yml +++ b/docker-compose.accounts.yml @@ -55,11 +55,9 @@ services: - mongo dashboard: - # uncomment "build" and comment out "image" to build from sources - # build: - # context: https://github.com/SkynetLabs/skynet-webportal.git#master - # dockerfile: ./packages/dashboard/Dockerfile - image: skynetlabs/dashboard + build: + context: ./packages/dashboard + dockerfile: Dockerfile container_name: dashboard restart: unless-stopped logging: *default-logging @@ -79,11 +77,9 @@ services: - mongo dashboard-v2: - # uncomment "build" and comment out "image" to build from sources - # build: - # context: https://github.com/SkynetLabs/skynet-webportal.git#master - # dockerfile: ./packages/dashboard-v2/Dockerfile - image: skynetlabs/dashboard-v2 + build: + context: ./packages/dashboard-v2 + dockerfile: Dockerfile container_name: dashboard-v2 restart: unless-stopped logging: *default-logging diff --git a/packages/dashboard-v2/Dockerfile b/packages/dashboard-v2/Dockerfile index 9fb4c604..70790cfa 100644 --- a/packages/dashboard-v2/Dockerfile +++ b/packages/dashboard-v2/Dockerfile @@ -2,21 +2,13 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY packages/dashboard-v2/package.json \ - packages/dashboard-v2/yarn.lock \ - ./ +COPY package.json yarn.lock ./ RUN yarn --frozen-lockfile -COPY packages/dashboard-v2/static ./static -COPY packages/dashboard-v2/src ./src -COPY packages/dashboard-v2/gatsby*.js \ - packages/dashboard-v2/postcss.config.js \ - packages/dashboard-v2/tailwind.config.js \ - ./ +COPY static ./static +COPY src ./src +COPY gatsby*.js ./ +COPY postcss.config.js tailwind.config.js ./ -RUN yarn build - -EXPOSE 9000 - -CMD ["sh", "-c", "yarn serve --host 0.0.0.0 -p 9000"] +CMD ["sh", "-c", "yarn build && yarn serve --host 0.0.0.0 -p 9000"] diff --git a/packages/dashboard/Dockerfile b/packages/dashboard/Dockerfile index 25f584b3..39707664 100644 --- a/packages/dashboard/Dockerfile +++ b/packages/dashboard/Dockerfile @@ -2,19 +2,14 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY packages/dashboard/package.json \ - packages/dashboard/yarn.lock \ - ./ +COPY package.json yarn.lock ./ ENV NEXT_TELEMETRY_DISABLED 1 RUN yarn --frozen-lockfile -COPY packages/dashboard/public ./public -COPY packages/dashboard/src ./src -COPY packages/dashboard/styles ./styles -COPY packages/dashboard/.eslintrc.json \ - packages/dashboard/postcss.config.js \ - packages/dashboard/tailwind.config.js \ - ./ +COPY public ./public +COPY src ./src +COPY styles ./styles +COPY .eslintrc.json postcss.config.js tailwind.config.js ./ CMD ["sh", "-c", "env | grep -E 'NEXT_PUBLIC|STRIPE|ACCOUNTS' > .env.local && yarn build && yarn start"] From 1c3fcf69998e5ed1c3403451eff806614e6e5770 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 8 Apr 2022 11:51:53 +0200 Subject: [PATCH 127/240] add newlines on eof --- docker/nginx/libs/skynet/modules.spec.lua | 2 +- docker/nginx/libs/skynet/scanner.spec.lua | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docker/nginx/libs/skynet/modules.spec.lua b/docker/nginx/libs/skynet/modules.spec.lua index 0797a32d..0eaaf081 100644 --- a/docker/nginx/libs/skynet/modules.spec.lua +++ b/docker/nginx/libs/skynet/modules.spec.lua @@ -92,4 +92,4 @@ describe("is_disabled", function() skynet_modules.is_disabled("gandalf") end, "Module abbreviation 'gandalf' should be exactly one character long string") end) -end) \ No newline at end of file +end) diff --git a/docker/nginx/libs/skynet/scanner.spec.lua b/docker/nginx/libs/skynet/scanner.spec.lua index 400c301c..584f07ae 100644 --- a/docker/nginx/libs/skynet/scanner.spec.lua +++ b/docker/nginx/libs/skynet/scanner.spec.lua @@ -118,4 +118,4 @@ describe("scan_skylink_timer", function() "foo != bar" ) end) -end) \ No newline at end of file +end) From 4e64ddd798fdb629b577a0ade16004ce9acb0c46 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 8 Apr 2022 13:20:05 +0200 Subject: [PATCH 128/240] match lowercase true/false --- docker/nginx/libs/utils.lua | 4 ++-- docker/nginx/libs/utils.spec.lua | 12 ++++++++++++ 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/docker/nginx/libs/utils.lua b/docker/nginx/libs/utils.lua index 3b9b2592..8b77d802 100644 --- a/docker/nginx/libs/utils.lua +++ b/docker/nginx/libs/utils.lua @@ -61,11 +61,11 @@ function _M.getenv(name, parse) -- try to parse as boolean if parse == "boolean" then - if value == "true" or value == "1" then + if string.lower(value) == "true" or value == "1" then return true end - if value == "false" or value == "0" then + if string.lower(value) == "false" or value == "0" then return false end diff --git a/docker/nginx/libs/utils.spec.lua b/docker/nginx/libs/utils.spec.lua index af43e898..78aa0833 100644 --- a/docker/nginx/libs/utils.spec.lua +++ b/docker/nginx/libs/utils.spec.lua @@ -135,6 +135,12 @@ describe("getenv", function() assert.is_true(utils.getenv("foo", "boolean")) end) + it("should parse 'True' string as true", function() + os.getenv.on_call_with("foo").returns("True") + + assert.is_true(utils.getenv("foo", "boolean")) + end) + it("should parse '1' string as true", function() os.getenv.on_call_with("foo").returns("1") @@ -147,6 +153,12 @@ describe("getenv", function() assert.is_false(utils.getenv("foo", "boolean")) end) + it("should parse 'False' string as false", function() + os.getenv.on_call_with("foo").returns("False") + + assert.is_false(utils.getenv("foo", "boolean")) + end) + it("should parse '0' string as false", function() os.getenv.on_call_with("foo").returns("0") From a0693ac6b66a2c709fb098e99725c2de0859e295 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 8 Apr 2022 13:20:48 +0200 Subject: [PATCH 129/240] fix bad test title --- docker/nginx/libs/utils.spec.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/nginx/libs/utils.spec.lua b/docker/nginx/libs/utils.spec.lua index 78aa0833..71ef086c 100644 --- a/docker/nginx/libs/utils.spec.lua +++ b/docker/nginx/libs/utils.spec.lua @@ -199,7 +199,7 @@ describe("getenv", function() assert.equals(utils.getenv("foo", "integer"), 1) end) - it("should parse '-1' string as 1", function() + it("should parse '-1' string as -1", function() os.getenv.on_call_with("foo").returns("-1") assert.equals(utils.getenv("foo", "integer"), -1) From 2e39fb47362fe3a2f13c5903efad400e2745b930 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 8 Apr 2022 13:24:35 +0200 Subject: [PATCH 130/240] remove spy stub that will never be called --- docker/nginx/libs/skynet/scanner.spec.lua | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/docker/nginx/libs/skynet/scanner.spec.lua b/docker/nginx/libs/skynet/scanner.spec.lua index 584f07ae..533ef44c 100644 --- a/docker/nginx/libs/skynet/scanner.spec.lua +++ b/docker/nginx/libs/skynet/scanner.spec.lua @@ -54,9 +54,7 @@ describe("scan_skylink_timer", function() it("should exit early on premature", function() local resty_http = require("resty.http") - local request_uri = spy.new(function() - return { status = 200 } -- return 200 success - end) + local request_uri = spy.new() local httpc = mock({ request_uri = request_uri }) stub(resty_http, "new").returns(httpc) From cfe4ca0d87af67986af8c503fe44545435d1ff93 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 8 Apr 2022 13:56:20 +0200 Subject: [PATCH 131/240] add skynet-sponsor-key dnslink functionality --- docker/nginx/conf.d/server/server.dnslink | 17 ++++++++++--- packages/dnslink-api/src/index.js | 29 +++++++++++++++++++---- 2 files changed, 38 insertions(+), 8 deletions(-) diff --git a/docker/nginx/conf.d/server/server.dnslink b/docker/nginx/conf.d/server/server.dnslink index cf385a1d..139196ef 100644 --- a/docker/nginx/conf.d/server/server.dnslink +++ b/docker/nginx/conf.d/server/server.dnslink @@ -5,6 +5,7 @@ location / { set $path $uri; rewrite_by_lua_block { + local cjson = require("cjson") local cache = ngx.shared.dnslink local cache_value = cache:get(ngx.var.host) @@ -28,13 +29,23 @@ location / { ngx.exit(ngx.status) end else - ngx.var.skylink = res.body + local resolved = cjson.decode(res.body) + + ngx.var.skylink = resolved.skylink + if resolved.sponsor then + ngx.req.set_header("Skynet-Api-Key", resolved.sponsor) + end local cache_ttl = 300 -- 5 minutes cache expire time - cache:set(ngx.var.host, ngx.var.skylink, cache_ttl) + cache:set(ngx.var.host, res.body, cache_ttl) end else - ngx.var.skylink = cache_value + local resolved = cjson.decode(cache_value) + + ngx.var.skylink = resolved.skylink + if resolved.sponsor then + ngx.req.set_header("Skynet-Api-Key", resolved.sponsor) + end end ngx.var.skylink = require("skynet.skylink").parse(ngx.var.skylink) diff --git a/packages/dnslink-api/src/index.js b/packages/dnslink-api/src/index.js index 300277c2..8ea0aeec 100644 --- a/packages/dnslink-api/src/index.js +++ b/packages/dnslink-api/src/index.js @@ -8,12 +8,14 @@ const port = Number(process.env.DNSLINK_API_PORT) || 3100; const server = express(); const dnslinkNamespace = "skynet-ns"; +const sponsorNamespace = "skynet-sponsor-key"; const dnslinkRegExp = new RegExp(`^dnslink=/${dnslinkNamespace}/.+$`); +const sponsorRegExp = new RegExp(`^${sponsorNamespace}=[a-zA-Z0-9]+$`); const dnslinkSkylinkRegExp = new RegExp(`^dnslink=/${dnslinkNamespace}/([a-zA-Z0-9_-]{46}|[a-z0-9]{55})`); const hint = `valid example: dnslink=/${dnslinkNamespace}/3ACpC9Umme41zlWUgMQh1fw0sNwgWwyfDDhRQ9Sppz9hjQ`; server.get("/dnslink/:name", async (req, res) => { - const success = (skylink) => res.send(skylink); + const success = (response) => res.json(response); const failure = (message) => res.status(400).send(message); if (!isValidDomain(req.params.name)) { @@ -22,7 +24,7 @@ server.get("/dnslink/:name", async (req, res) => { const lookup = `_dnslink.${req.params.name}`; - dns.resolveTxt(lookup, (error, records) => { + dns.resolveTxt(lookup, (error, addresses) => { if (error) { if (error.code === "ENOTFOUND") { return failure(`ENOTFOUND: ${lookup} TXT record doesn't exist`); @@ -35,11 +37,12 @@ server.get("/dnslink/:name", async (req, res) => { return failure(`Failed to fetch ${lookup} TXT record: ${error.message}`); } - if (records.length === 0) { + if (addresses.length === 0) { return failure(`No TXT record found for ${lookup}`); } - const dnslinks = records.flat().filter((record) => dnslinkRegExp.test(record)); + const records = addresses.flat(); + const dnslinks = records.filter((record) => dnslinkRegExp.test(record)); if (dnslinks.length === 0) { return failure(`TXT records for ${lookup} found but none of them contained valid skynet dnslink - ${hint}`); @@ -58,9 +61,25 @@ server.get("/dnslink/:name", async (req, res) => { const skylink = matchSkylink[1]; + // check if _dnslink records contain skynet-sponsor-key entries + const sponsors = records.filter((record) => sponsorRegExp.test(record)); + + if (sponsors.length > 1) { + return failure(`Multiple TXT records with valid sponsor key found for ${lookup}, only one allowed`); + } + + if (sponsors.length === 1) { + // extract just the key part from the record + const sponsor = sponsors[0].substring(sponsors[0].indexOf("=") + 1); + + console.log(`${req.params.name} => ${skylink} | sponsor: ${sponsor}`); + + return success({ skylink, sponsor }); + } + console.log(`${req.params.name} => ${skylink}`); - return success(skylink); + return success({ skylink }); }); }); From 8edd2e21bb57cf5a07465a6ab7d49f736210fc65 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sat, 9 Apr 2022 12:31:58 +0000 Subject: [PATCH 132/240] build(deps): bump moment from 2.29.1 to 2.29.2 in /packages/website Bumps [moment](https://github.com/moment/moment) from 2.29.1 to 2.29.2. - [Release notes](https://github.com/moment/moment/releases) - [Changelog](https://github.com/moment/moment/blob/develop/CHANGELOG.md) - [Commits](https://github.com/moment/moment/compare/2.29.1...2.29.2) --- updated-dependencies: - dependency-name: moment dependency-type: indirect ... Signed-off-by: dependabot[bot] --- packages/website/yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 860b612f..3c99c390 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -8737,9 +8737,9 @@ mkdirp@^0.5.1, mkdirp@^0.5.4, mkdirp@~0.5.1: minimist "^1.2.5" moment@^2.29.1: - version "2.29.1" - resolved "https://registry.yarnpkg.com/moment/-/moment-2.29.1.tgz#b2be769fa31940be9eeea6469c075e35006fa3d3" - integrity sha512-kHmoybcPV8Sqy59DwNDY3Jefr64lK/by/da0ViFcuA4DH0vQg5Q6Ze5VimxkfQNSC+Mls/Kx53s7TjP1RhFEDQ== + version "2.29.2" + resolved "https://registry.yarnpkg.com/moment/-/moment-2.29.2.tgz#00910c60b20843bcba52d37d58c628b47b1f20e4" + integrity sha512-UgzG4rvxYpN15jgCmVJwac49h9ly9NurikMWGPdVxm8GZD6XjkKPxDTjQQ43gtGgnV3X0cAyWDdP2Wexoquifg== ms@2.0.0: version "2.0.0" From 8b4b298349672baaa360336fe33836b19bab92b1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sat, 9 Apr 2022 14:49:12 +0000 Subject: [PATCH 133/240] build(deps): bump moment from 2.29.1 to 2.29.2 in /packages/dashboard-v2 Bumps [moment](https://github.com/moment/moment) from 2.29.1 to 2.29.2. - [Release notes](https://github.com/moment/moment/releases) - [Changelog](https://github.com/moment/moment/blob/develop/CHANGELOG.md) - [Commits](https://github.com/moment/moment/compare/2.29.1...2.29.2) --- updated-dependencies: - dependency-name: moment dependency-type: indirect ... Signed-off-by: dependabot[bot] --- packages/dashboard-v2/yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/dashboard-v2/yarn.lock b/packages/dashboard-v2/yarn.lock index c3de4379..39b088e4 100644 --- a/packages/dashboard-v2/yarn.lock +++ b/packages/dashboard-v2/yarn.lock @@ -11242,9 +11242,9 @@ mkdirp@^1.0.3, mkdirp@^1.0.4: integrity sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw== moment@^2.29.1: - version "2.29.1" - resolved "https://registry.yarnpkg.com/moment/-/moment-2.29.1.tgz#b2be769fa31940be9eeea6469c075e35006fa3d3" - integrity sha512-kHmoybcPV8Sqy59DwNDY3Jefr64lK/by/da0ViFcuA4DH0vQg5Q6Ze5VimxkfQNSC+Mls/Kx53s7TjP1RhFEDQ== + version "2.29.2" + resolved "https://registry.yarnpkg.com/moment/-/moment-2.29.2.tgz#00910c60b20843bcba52d37d58c628b47b1f20e4" + integrity sha512-UgzG4rvxYpN15jgCmVJwac49h9ly9NurikMWGPdVxm8GZD6XjkKPxDTjQQ43gtGgnV3X0cAyWDdP2Wexoquifg== move-concurrently@^1.0.1: version "1.0.1" From 2c2a1259d3d2271d3b0a99321bcfe3305a6a5087 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 7 Apr 2022 13:52:50 +0200 Subject: [PATCH 134/240] refactor(dashboard-v2): move access guards outside of SWRConfig --- packages/dashboard-v2/gatsby-browser.js | 12 ++-- packages/dashboard-v2/gatsby-ssr.js | 12 ++-- .../src/components/NavBar/NavBar.js | 2 +- .../portal-settings/PortalSettingsProvider.js | 2 +- .../src/contexts/user/UserProvider.js | 36 +++++++++-- .../dashboard-v2/src/layouts/AuthLayout.js | 45 +++++++------- .../src/layouts/DashboardLayout.js | 31 ++++------ .../src/layouts/UserSettingsLayout.js | 61 ++++--------------- packages/dashboard-v2/src/lib/swrConfig.js | 45 +++++--------- 9 files changed, 107 insertions(+), 139 deletions(-) diff --git a/packages/dashboard-v2/gatsby-browser.js b/packages/dashboard-v2/gatsby-browser.js index 79b58e24..030fcadd 100644 --- a/packages/dashboard-v2/gatsby-browser.js +++ b/packages/dashboard-v2/gatsby-browser.js @@ -1,4 +1,5 @@ import * as React from "react"; +import { SWRConfig } from "swr"; import "@fontsource/sora/300.css"; // light import "@fontsource/sora/400.css"; // normal import "@fontsource/sora/500.css"; // medium @@ -6,6 +7,7 @@ import "@fontsource/sora/600.css"; // semibold import "@fontsource/source-sans-pro/400.css"; // normal import "@fontsource/source-sans-pro/600.css"; // semibold import "./src/styles/global.css"; +import swrConfig from "./src/lib/swrConfig"; import { MODAL_ROOT_ID } from "./src/components/Modal"; import { PortalSettingsProvider } from "./src/contexts/portal-settings"; @@ -13,10 +15,12 @@ export function wrapPageElement({ element, props }) { const Layout = element.type.Layout ?? React.Fragment; return ( - - {element} -
    - + + + {element} +
    + + ); } diff --git a/packages/dashboard-v2/gatsby-ssr.js b/packages/dashboard-v2/gatsby-ssr.js index 79b58e24..030fcadd 100644 --- a/packages/dashboard-v2/gatsby-ssr.js +++ b/packages/dashboard-v2/gatsby-ssr.js @@ -1,4 +1,5 @@ import * as React from "react"; +import { SWRConfig } from "swr"; import "@fontsource/sora/300.css"; // light import "@fontsource/sora/400.css"; // normal import "@fontsource/sora/500.css"; // medium @@ -6,6 +7,7 @@ import "@fontsource/sora/600.css"; // semibold import "@fontsource/source-sans-pro/400.css"; // normal import "@fontsource/source-sans-pro/600.css"; // semibold import "./src/styles/global.css"; +import swrConfig from "./src/lib/swrConfig"; import { MODAL_ROOT_ID } from "./src/components/Modal"; import { PortalSettingsProvider } from "./src/contexts/portal-settings"; @@ -13,10 +15,12 @@ export function wrapPageElement({ element, props }) { const Layout = element.type.Layout ?? React.Fragment; return ( - - {element} -
    - + + + {element} +
    + + ); } diff --git a/packages/dashboard-v2/src/components/NavBar/NavBar.js b/packages/dashboard-v2/src/components/NavBar/NavBar.js index 6d2cb9eb..9ad8e91c 100644 --- a/packages/dashboard-v2/src/components/NavBar/NavBar.js +++ b/packages/dashboard-v2/src/components/NavBar/NavBar.js @@ -97,7 +97,7 @@ export const NavBar = () => { as="button" onClick={onLogout} activeClassName="text-primary" - className="cursor-pointer" + className="cursor-pointer w-full" icon={LockClosedIcon} label="Log out" /> diff --git a/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsProvider.js b/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsProvider.js index a5a033c8..5d8de1ab 100644 --- a/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsProvider.js +++ b/packages/dashboard-v2/src/contexts/portal-settings/PortalSettingsProvider.js @@ -16,7 +16,7 @@ const fetcher = async (path) => { }; export const PortalSettingsProvider = ({ children }) => { - const { data, error } = useSWRImmutable("/__internal/do/not/use/accounts", fetcher); + const { data, error } = useSWRImmutable("__internal/do/not/use/accounts", fetcher); const [loading, setLoading] = useState(true); const [settings, setSettings] = useState(defaultSettings); diff --git a/packages/dashboard-v2/src/contexts/user/UserProvider.js b/packages/dashboard-v2/src/contexts/user/UserProvider.js index bb10ffe4..014d5b7f 100644 --- a/packages/dashboard-v2/src/contexts/user/UserProvider.js +++ b/packages/dashboard-v2/src/contexts/user/UserProvider.js @@ -1,17 +1,41 @@ +import { navigate } from "gatsby"; import { useEffect, useState } from "react"; import useSWRImmutable from "swr/immutable"; +import { UnauthorizedError } from "../../lib/swrConfig"; +import { FullScreenLoadingIndicator } from "../../components/LoadingIndicator"; import { UserContext } from "./UserContext"; -export const UserProvider = ({ children }) => { +export const UserProvider = ({ children, allowGuests = false, allowAuthenticated = true }) => { const { data: user, error, mutate } = useSWRImmutable("user"); const [loading, setLoading] = useState(true); useEffect(() => { - if (user || error) { - setLoading(false); - } - }, [user, error]); + const guard = async () => { + if (user) { + if (!allowAuthenticated) { + navigate("/"); + } else { + setLoading(false); + } + } else if (error) { + if (error instanceof UnauthorizedError && !allowGuests) { + await navigate(`/auth/login?return_to=${encodeURIComponent(window.location.href)}`); + } else { + setLoading(false); + } + } else if (user === null) { + setLoading(false); + } + }; - return {children}; + guard(); + }, [user, error, allowGuests, allowAuthenticated]); + + return ( + + {loading && } + {!loading && children} + + ); }; diff --git a/packages/dashboard-v2/src/layouts/AuthLayout.js b/packages/dashboard-v2/src/layouts/AuthLayout.js index 85604321..847562e5 100644 --- a/packages/dashboard-v2/src/layouts/AuthLayout.js +++ b/packages/dashboard-v2/src/layouts/AuthLayout.js @@ -1,9 +1,7 @@ import * as React from "react"; import styled from "styled-components"; -import { SWRConfig } from "swr"; import { UserProvider } from "../contexts/user"; -import { guestsOnly, allUsers } from "../lib/swrConfig"; const Layout = styled.div.attrs({ className: "min-h-screen w-screen bg-black flex", @@ -22,29 +20,32 @@ const Content = styled.div.attrs({ })``; const AuthLayout = - (swrConfig) => - ({ children }) => { - return ( + (userProviderProps) => + ({ children }) => + ( <> - - - - -
    -

    - The decentralized revolution starts with decentralized storage -

    -
    -
    - {children} -
    -
    -
    + + + +
    +

    + The decentralized revolution starts with decentralized storage +

    +
    +
    + {children} +
    +
    ); - }; // Some pages (e.g. email confirmation) need to be accessible to both logged-in and guest users. -export const AllUsersAuthLayout = AuthLayout(allUsers); +export const AllUsersAuthLayout = AuthLayout({ + allowGuests: true, + allowAuthenticated: true, +}); -export default AuthLayout(guestsOnly); +export default AuthLayout({ + allowGuests: true, + allowAuthenticated: false, +}); diff --git a/packages/dashboard-v2/src/layouts/DashboardLayout.js b/packages/dashboard-v2/src/layouts/DashboardLayout.js index fe4c5385..633057eb 100644 --- a/packages/dashboard-v2/src/layouts/DashboardLayout.js +++ b/packages/dashboard-v2/src/layouts/DashboardLayout.js @@ -1,8 +1,5 @@ import * as React from "react"; import styled from "styled-components"; -import { SWRConfig } from "swr"; - -import { authenticatedOnly } from "../lib/swrConfig"; import { PageContainer } from "../components/PageContainer"; import { NavBar } from "../components/NavBar"; @@ -30,22 +27,16 @@ const Layout = ({ children }) => { ); }; -const DashboardLayout = ({ children }) => { - return ( - <> - - - - - -
    {children}
    -
    -
    - - - - - ); -}; +const DashboardLayout = ({ children }) => ( + <> + + + + {children} +
    + + + +); export default DashboardLayout; diff --git a/packages/dashboard-v2/src/layouts/UserSettingsLayout.js b/packages/dashboard-v2/src/layouts/UserSettingsLayout.js index d7b9b7d4..81820021 100644 --- a/packages/dashboard-v2/src/layouts/UserSettingsLayout.js +++ b/packages/dashboard-v2/src/layouts/UserSettingsLayout.js @@ -1,43 +1,12 @@ import * as React from "react"; import { Link } from "gatsby"; import styled from "styled-components"; -import { SWRConfig } from "swr"; -import { authenticatedOnly } from "../lib/swrConfig"; - -import { PageContainer } from "../components/PageContainer"; -import { NavBar } from "../components/NavBar"; -import { Footer } from "../components/Footer"; -import { UserProvider, useUser } from "../contexts/user"; -import { ContainerLoadingIndicator } from "../components/LoadingIndicator"; - -const Wrapper = styled.div.attrs({ - className: "min-h-screen overflow-hidden", -})` - background-image: url(/images/dashboard-bg.svg); - background-position: center -280px; - background-repeat: no-repeat; -`; - -const Layout = ({ children }) => { - const { user } = useUser(); - - // Prevent from flashing the dashboard screen to unauthenticated users. - return ( - - {!user && ( -
    - -
    - )} - {user && <>{children}} -
    - ); -}; +import DashboardLayout from "./DashboardLayout"; const Sidebar = () => ( -
    - {children} + +
    +
    + Skynet +
    + {children} +
    +
    diff --git a/packages/dashboard-v2/src/pages/auth/login.js b/packages/dashboard-v2/src/pages/auth/login.js index 5812fd8f..8d51968d 100644 --- a/packages/dashboard-v2/src/pages/auth/login.js +++ b/packages/dashboard-v2/src/pages/auth/login.js @@ -22,16 +22,11 @@ const LoginPage = ({ location }) => { Sign In -
    -
    - Skynet -
    - { - await refreshUserState(); - }} - /> -
    + { + await refreshUserState(); + }} + /> ); }; diff --git a/packages/dashboard-v2/src/pages/auth/registration.js b/packages/dashboard-v2/src/pages/auth/registration.js index e8e67354..b58562fd 100644 --- a/packages/dashboard-v2/src/pages/auth/registration.js +++ b/packages/dashboard-v2/src/pages/auth/registration.js @@ -61,11 +61,7 @@ const SignUpPage = () => { Sign Up -
    -
    - Skynet -
    - +
    {!settings.areAccountsEnabled && Accounts are not enabled on this portal.} {settings.areAccountsEnabled && ( diff --git a/packages/dashboard-v2/src/pages/auth/reset-password.js b/packages/dashboard-v2/src/pages/auth/reset-password.js index 88db338a..74c40203 100644 --- a/packages/dashboard-v2/src/pages/auth/reset-password.js +++ b/packages/dashboard-v2/src/pages/auth/reset-password.js @@ -20,30 +20,25 @@ const ResetPasswordPage = () => { Reset Password -
    -
    - Skynet -
    - {state !== State.Success && ( - setState(State.Success)} onFailure={() => setState(State.Failure)} /> - )} + {state !== State.Success && ( + setState(State.Success)} onFailure={() => setState(State.Failure)} /> + )} - {state === State.Success && ( -

    Please check your inbox for further instructions.

    - )} + {state === State.Success && ( +

    Please check your inbox for further instructions.

    + )} - {state === State.Failure && ( -

    Something went wrong, please try again later.

    - )} + {state === State.Failure && ( +

    Something went wrong, please try again later.

    + )} -
    -

    - Suddenly remembered your password? Sign in -

    -

    - Don't actually have an account? Create one! -

    -
    +
    +

    + Suddenly remembered your password? Sign in +

    +

    + Don't actually have an account? Create one! +

    ); diff --git a/packages/dashboard-v2/src/pages/user/confirm.js b/packages/dashboard-v2/src/pages/user/confirm.js index b4ce6bc1..1430a4f9 100644 --- a/packages/dashboard-v2/src/pages/user/confirm.js +++ b/packages/dashboard-v2/src/pages/user/confirm.js @@ -57,23 +57,18 @@ const EmailConfirmationPage = ({ location }) => { Confirm E-mail Address -
    -
    - Skynet -
    -
    - {state === State.Pure &&

    Please wait while we verify your account...

    } +
    + {state === State.Pure &&

    Please wait while we verify your account...

    } - {state === State.Success && ( - <> -

    All done!

    -

    You will be redirected to your dashboard shortly.

    - Redirect now. - - )} + {state === State.Success && ( + <> +

    All done!

    +

    You will be redirected to your dashboard shortly.

    + Redirect now. + + )} - {state === State.Failure &&

    Something went wrong, please try again later.

    } -
    + {state === State.Failure &&

    Something went wrong, please try again later.

    }
    ); diff --git a/packages/dashboard-v2/src/pages/user/recover.js b/packages/dashboard-v2/src/pages/user/recover.js index d8d02e8a..ddba982f 100644 --- a/packages/dashboard-v2/src/pages/user/recover.js +++ b/packages/dashboard-v2/src/pages/user/recover.js @@ -24,35 +24,30 @@ const RecoverPage = ({ location }) => { Recover Your Account -
    -
    - Skynet -
    - {state !== State.Success && ( - { - setState(State.Success); - navigate("/"); - }} - onFailure={() => setState(State.Failure)} - /> - )} + {state !== State.Success && ( + { + setState(State.Success); + navigate("/"); + }} + onFailure={() => setState(State.Failure)} + /> + )} - {state === State.Success && ( -

    - All done! You will be redirected to your dashboard shortly. -

    - )} - - {state === State.Failure && ( -

    Something went wrong, please try again later.

    - )} - -

    - Suddenly remembered your old password? Sign in + {state === State.Success && ( +

    + All done! You will be redirected to your dashboard shortly.

    -
    + )} + + {state === State.Failure && ( +

    Something went wrong, please try again later.

    + )} + +

    + Suddenly remembered your old password? Sign in +

    ); }; From 2e7bccf6044fbe867aabd893eea0e80bf113463d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Mon, 11 Apr 2022 13:10:33 +0200 Subject: [PATCH 139/240] fix(dashboard-v2): bound graph labels to the container box --- .../src/components/CurrentUsage/GraphBar.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js b/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js index 96421f6e..1afab541 100644 --- a/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js +++ b/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js @@ -12,11 +12,13 @@ const BarTip = styled.span.attrs({ })``; const BarLabel = styled.span.attrs({ - className: "bg-white rounded border-2 border-palette-200 px-3 whitespace-nowrap absolute shadow", + className: "usage-label bg-white rounded border-2 border-palette-200 px-3 whitespace-nowrap absolute shadow", })` - right: max(0%, ${({ $percentage }) => 100 - $percentage}%); - top: -0.5rem; - transform: translateX(50%); + ${({ $percentage }) => ` + left: max(0%, ${$percentage}%); + top: -0.5rem; + transform: translateX(-${$percentage}%); + `} `; export const GraphBar = ({ value, limit, label }) => { From 2965c8bbc65623e1e908b69ff3fdb85f739c25f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Mon, 11 Apr 2022 13:20:51 +0200 Subject: [PATCH 140/240] fix(dashboard-v2): hide 'WAIT' since already says 'Processing' --- packages/dashboard-v2/src/components/Uploader/UploaderItem.js | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/dashboard-v2/src/components/Uploader/UploaderItem.js b/packages/dashboard-v2/src/components/Uploader/UploaderItem.js index 8ea279d6..46653877 100644 --- a/packages/dashboard-v2/src/components/Uploader/UploaderItem.js +++ b/packages/dashboard-v2/src/components/Uploader/UploaderItem.js @@ -109,7 +109,6 @@ export default function UploaderItem({ onUploadStateChange, upload }) { {upload.status === "uploading" && ( {Math.floor(upload.progress * 100)}% )} - {upload.status === "processing" && Wait} {upload.status === "complete" && (
    {!success && ( @@ -72,6 +84,9 @@ export default function Recovery() { validationSchema={validationSchema} onSubmit={onSubmit} button="Send recovery link" + onError={(errorMessage) => + setSkynetFreeInviteVisible(errorMessage === "registrations are currently disabled") + } /> )} From d15d2146f5f17c8a5b96d906ef7cdb36b9648a4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 12 Apr 2022 12:55:09 +0200 Subject: [PATCH 151/240] ops(dashboard-v2): improve local developer experience --- packages/dashboard-v2/.env.development | 2 ++ packages/dashboard-v2/README.md | 19 +++++++++----- packages/dashboard-v2/gatsby-config.js | 26 ++++++++++++++++--- packages/dashboard-v2/package.json | 4 ++- .../dashboard-v2/src/services/skynetClient.js | 2 +- packages/dashboard-v2/yarn.lock | 20 ++++++++++++++ 6 files changed, 61 insertions(+), 12 deletions(-) create mode 100644 packages/dashboard-v2/.env.development diff --git a/packages/dashboard-v2/.env.development b/packages/dashboard-v2/.env.development new file mode 100644 index 00000000..bee30f49 --- /dev/null +++ b/packages/dashboard-v2/.env.development @@ -0,0 +1,2 @@ +GATSBY_PORTAL_DOMAIN= +GATSBY_HOST= diff --git a/packages/dashboard-v2/README.md b/packages/dashboard-v2/README.md index ab0421f8..e8924bc3 100644 --- a/packages/dashboard-v2/README.md +++ b/packages/dashboard-v2/README.md @@ -11,15 +11,20 @@ This is a Gatsby application. To run it locally, all you need is: ## Accessing remote APIs -To be able to log in on a local environment with your production credentials, you'll need to make the browser believe you're actually on the same domain, otherwise the browser will block the session cookie. +To have a fully functioning local environment, you'll need to make the browser believe you're actually on the same domain as a working API (i.e. a remote dev or production server) -- otherwise the browser will block the session cookie. +To do the trick, configure proper environment variables in the `.env.development` file. +This file allows to easily control which domain name you want to use locally and which API you'd like to access. -To do the trick, edit your `/etc/hosts` file and add a record like this: +Example: -``` -127.0.0.1 local.skynetpro.net +```env +GATSBY_PORTAL_DOMAIN=skynetfree.net # Use skynetfree.net APIs +GATSBY_HOST=local.skynetfree.net # Address of your local build ``` -then run `yarn develop:secure` -- it will run `gatsby develop` with `--https --host=local.skynetpro.net -p=443` options. -If you're on macOS, you may need to `sudo` the command to successfully bind to port `443`. +> It's recommended to keep the 2LD the same, so any cookies dispatched by the API work without issues. -> **NOTE:** This should become easier once we have a docker image for the new dashboard. +With the file configured, run `yarn develop:secure` -- it will run `gatsby develop` with `--https -p=443` options. +If you're on macOS, you may need to `sudo` the command to successfully bind to port `443` (https). + +Gatsby will automatically add a proper entry to your `/etc/hosts` file and clean it up when process exits. diff --git a/packages/dashboard-v2/gatsby-config.js b/packages/dashboard-v2/gatsby-config.js index 2280f99b..6994f956 100644 --- a/packages/dashboard-v2/gatsby-config.js +++ b/packages/dashboard-v2/gatsby-config.js @@ -1,9 +1,15 @@ +require("dotenv").config({ + path: `.env.${process.env.NODE_ENV}`, +}); + const { createProxyMiddleware } = require("http-proxy-middleware"); +const { GATSBY_PORTAL_DOMAIN } = process.env; + module.exports = { siteMetadata: { - title: "Skynet Account", - siteUrl: `https://account.${process.env.GATSBY_PORTAL_DOMAIN}/`, + title: `Accounts Dashboard`, + siteUrl: `https://account.${GATSBY_PORTAL_DOMAIN}`, }, trailingSlash: "never", plugins: [ @@ -24,13 +30,27 @@ module.exports = { }, ], developMiddleware: (app) => { + // Proxy Accounts service API requests: app.use( "/api/", createProxyMiddleware({ - target: "https://account.skynetpro.net", + target: `https://account.${GATSBY_PORTAL_DOMAIN}`, secure: false, // Do not reject self-signed certificates. changeOrigin: true, }) ); + + // Proxy /skynet requests (e.g. uploads) + app.use( + ["/skynet", "/__internal/"], + createProxyMiddleware({ + target: `https://${GATSBY_PORTAL_DOMAIN}`, + secure: false, // Do not reject self-signed certificates. + changeOrigin: true, + pathRewrite: { + "^/skynet": "", + }, + }) + ); }, }; diff --git a/packages/dashboard-v2/package.json b/packages/dashboard-v2/package.json index b760bf48..694a6129 100644 --- a/packages/dashboard-v2/package.json +++ b/packages/dashboard-v2/package.json @@ -9,7 +9,7 @@ ], "scripts": { "develop": "gatsby develop", - "develop:secure": "gatsby develop --https --host=local.skynetpro.net -p=443", + "develop:secure": "dotenv -e .env.development -- gatsby develop --https -p=443", "start": "gatsby develop", "build": "gatsby build", "serve": "gatsby serve", @@ -60,6 +60,8 @@ "babel-loader": "^8.2.3", "babel-plugin-preval": "^5.1.0", "babel-plugin-styled-components": "^2.0.2", + "dotenv": "^16.0.0", + "dotenv-cli": "^5.1.0", "eslint": "^8.9.0", "eslint-config-react-app": "^7.0.0", "eslint-plugin-storybook": "^0.5.6", diff --git a/packages/dashboard-v2/src/services/skynetClient.js b/packages/dashboard-v2/src/services/skynetClient.js index 0549085c..a01e96f9 100644 --- a/packages/dashboard-v2/src/services/skynetClient.js +++ b/packages/dashboard-v2/src/services/skynetClient.js @@ -1,3 +1,3 @@ import { SkynetClient } from "skynet-js"; -export default new SkynetClient("https://skynetpro.net"); // TODO: proper API url +export default new SkynetClient(`https://${process.env.GATSBY_PORTAL_DOMAIN}`); diff --git a/packages/dashboard-v2/yarn.lock b/packages/dashboard-v2/yarn.lock index c3de4379..19741a86 100644 --- a/packages/dashboard-v2/yarn.lock +++ b/packages/dashboard-v2/yarn.lock @@ -6735,11 +6735,31 @@ dot-prop@^5.2.0: dependencies: is-obj "^2.0.0" +dotenv-cli@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/dotenv-cli/-/dotenv-cli-5.1.0.tgz#0d2942b089082da0157f9b26bd6c5c4dd51ef48e" + integrity sha512-NoEZAlKo9WVrG0b3i9mBxdD6INdDuGqdgR74t68t8084QcI077/1MnPerRW1odl+9uULhcdnQp2U0pYVppKHOA== + dependencies: + cross-spawn "^7.0.3" + dotenv "^16.0.0" + dotenv-expand "^8.0.1" + minimist "^1.2.5" + dotenv-expand@^5.1.0: version "5.1.0" resolved "https://registry.yarnpkg.com/dotenv-expand/-/dotenv-expand-5.1.0.tgz#3fbaf020bfd794884072ea26b1e9791d45a629f0" integrity sha512-YXQl1DSa4/PQyRfgrv6aoNjhasp/p4qs9FjJ4q4cQk+8m4r6k4ZSiEyytKG8f8W9gi8WsQtIObNmKd+tMzNTmA== +dotenv-expand@^8.0.1: + version "8.0.3" + resolved "https://registry.yarnpkg.com/dotenv-expand/-/dotenv-expand-8.0.3.tgz#29016757455bcc748469c83a19b36aaf2b83dd6e" + integrity sha512-SErOMvge0ZUyWd5B0NXMQlDkN+8r+HhVUsxgOO7IoPDOdDRD2JjExpN6y3KnFR66jsJMwSn1pqIivhU5rcJiNg== + +dotenv@^16.0.0: + version "16.0.0" + resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.0.0.tgz#c619001253be89ebb638d027b609c75c26e47411" + integrity sha512-qD9WU0MPM4SWLPJy/r2Be+2WgQj8plChsyrCNQzW/0WjvcJQiKQJ9mH3ZgB3fxbUUxgc/11ZJ0Fi5KiimWGz2Q== + dotenv@^8.0.0, dotenv@^8.6.0: version "8.6.0" resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-8.6.0.tgz#061af664d19f7f4d8fc6e4ff9b584ce237adcb8b" From 53b0687b2125ef5baa9becb9b69c3ae2c89d9c8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 12 Apr 2022 13:18:15 +0200 Subject: [PATCH 152/240] fix(dashboard-v2): get rid of downloads section --- .../FileList/useFormattedFilesData.js | 2 +- .../components/LatestActivity/LatestActivity.js | 14 ++------------ .../LatestActivity/useFormattedActivityData.js | 2 +- packages/dashboard-v2/src/pages/files.js | 17 ++--------------- 4 files changed, 6 insertions(+), 29 deletions(-) diff --git a/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js b/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js index 82d95090..36a1feae 100644 --- a/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js +++ b/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js @@ -10,7 +10,7 @@ const parseFileName = (fileName) => { const formatItem = ({ size, name: rawFileName, uploadedOn, downloadedOn, ...rest }) => { const [name, type] = parseFileName(rawFileName); - const date = dayjs(uploadedOn || downloadedOn).format("MM/DD/YYYY; HH:MM"); + const date = dayjs(uploadedOn || downloadedOn).format("MM/DD/YYYY HH:MM"); return { ...rest, diff --git a/packages/dashboard-v2/src/components/LatestActivity/LatestActivity.js b/packages/dashboard-v2/src/components/LatestActivity/LatestActivity.js index 535bceba..627314b7 100644 --- a/packages/dashboard-v2/src/components/LatestActivity/LatestActivity.js +++ b/packages/dashboard-v2/src/components/LatestActivity/LatestActivity.js @@ -1,23 +1,13 @@ import * as React from "react"; import { Panel } from "../Panel"; -import { Tab, TabPanel, Tabs } from "../Tabs"; import ActivityTable from "./ActivityTable"; export default function LatestActivity() { return ( - - - - - - - - - - - + + ); } diff --git a/packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js b/packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js index cf55703c..913e4859 100644 --- a/packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js +++ b/packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js @@ -10,7 +10,7 @@ const parseFileName = (fileName) => { const formatItem = ({ size, name: rawFileName, uploadedOn, downloadedOn, ...rest }) => { const [name, type] = parseFileName(rawFileName); - const date = dayjs(uploadedOn || downloadedOn).format("MM/DD/YYYY; HH:MM"); + const date = dayjs(uploadedOn || downloadedOn).format("MM/DD/YYYY HH:MM"); return { ...rest, diff --git a/packages/dashboard-v2/src/pages/files.js b/packages/dashboard-v2/src/pages/files.js index f4a47a1d..be856d4a 100644 --- a/packages/dashboard-v2/src/pages/files.js +++ b/packages/dashboard-v2/src/pages/files.js @@ -1,32 +1,19 @@ import * as React from "react"; -import { useSearchParam } from "react-use"; import DashboardLayout from "../layouts/DashboardLayout"; import { Panel } from "../components/Panel"; -import { Tab, TabPanel, Tabs } from "../components/Tabs"; import { Metadata } from "../components/Metadata"; import FileList from "../components/FileList/FileList"; const FilesPage = () => { - const defaultTab = useSearchParam("tab"); - return ( <> - My Files + Files - - - - - - - - - - + ); From efed2045afedcac6ff761392cbe6a8e84b9f92c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 12 Apr 2022 13:20:40 +0200 Subject: [PATCH 153/240] feat(dashboard-v2): proper copies about api keys --- .../src/components/APIKeyList/APIKey.js | 30 +++++----- .../src/components/HighlightedLink.js | 2 +- .../src/components/Tooltip/index.js | 1 + .../src/components/forms/AddAPIKeyForm.js | 48 +++++++-------- .../components/forms/AddPublicAPIKeyForm.js | 12 ++-- .../src/layouts/UserSettingsLayout.js | 4 +- .../{api-keys.js => developer-settings.js} | 60 +++++++++++-------- 7 files changed, 81 insertions(+), 76 deletions(-) create mode 100644 packages/dashboard-v2/src/components/Tooltip/index.js rename packages/dashboard-v2/src/pages/settings/{api-keys.js => developer-settings.js} (57%) diff --git a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js index 3269bb9f..cadc2775 100644 --- a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js +++ b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js @@ -13,7 +13,7 @@ import { useAPIKeyRemoval } from "./useAPIKeyRemoval"; export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { const { id, name, createdAt, skylinks } = apiKey; - const isPublic = apiKey.public === "true"; + const isSponsorKey = apiKey.public === "true"; const [error, setError] = useState(null); const onSkylinkListEdited = useCallback(() => { @@ -53,9 +53,9 @@ export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => { }, [abortEdit]); const skylinksNumber = skylinks?.length ?? 0; - const isNotConfigured = isPublic && skylinksNumber === 0; + const isNotConfigured = isSponsorKey && skylinksNumber === 0; const skylinksPhrasePrefix = skylinksNumber === 0 ? "No" : skylinksNumber; - const skylinksPhrase = `${skylinksPhrasePrefix} ${skylinksNumber === 1 ? "skylink" : "skylinks"} configured`; + const skylinksPhrase = `${skylinksPhrasePrefix} ${skylinksNumber === 1 ? "skylink" : "skylinks"} sponsored`; return (
  • { {name || "unnamed key"} - + {isSponsorKey && ( + + )} {dayjs(createdAt).format("MMM DD, YYYY")} - {isPublic && ( + {isSponsorKey && ( - )} + + +
    +
    )} @@ -110,5 +104,5 @@ AddAPIKeyForm.displayName = "AddAPIKeyForm"; AddAPIKeyForm.propTypes = { onSuccess: PropTypes.func.isRequired, - type: PropTypes.oneOf([APIKeyType.Public, APIKeyType.General]).isRequired, + type: PropTypes.oneOf([APIKeyType.Sponsor, APIKeyType.General]).isRequired, }; diff --git a/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js b/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js index c98daac9..b9540ea1 100644 --- a/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js +++ b/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js @@ -52,10 +52,10 @@ export const AddPublicAPIKeyForm = forwardRef(({ onSuccess }, ref) => { return (
    {state === State.Success && ( - + Success!

    Please copy your new API key below. We'll never show it again!

    -
    +
    {generatedKey} @@ -101,14 +101,14 @@ export const AddPublicAPIKeyForm = forwardRef(({ onSuccess }, ref) => { type="text" id="name" name="name" - label="Public API Key Name" + label="Sponsor API Key Name" placeholder="my_applications_statistics" error={errors.name} touched={touched.name} />
    -
    Skylinks accessible with the new key
    +
    Skylinks sponsored by the new key
    { @@ -182,7 +182,7 @@ export const AddPublicAPIKeyForm = forwardRef(({ onSuccess }, ref) => { className={cn("px-2.5", { "cursor-wait": isSubmitting })} disabled={!isValid || isSubmitting} > - {isSubmitting ? "Generating" : "Generate"} your public key + {isSubmitting ? "Generating your sponsor key..." : "Generate your sponsor key"}
    @@ -192,7 +192,7 @@ export const AddPublicAPIKeyForm = forwardRef(({ onSuccess }, ref) => { ); }); -AddPublicAPIKeyForm.displayName = "AddAPIKeyForm"; +AddPublicAPIKeyForm.displayName = "AddPublicAPIKeyForm"; AddPublicAPIKeyForm.propTypes = { onSuccess: PropTypes.func.isRequired, diff --git a/packages/dashboard-v2/src/layouts/UserSettingsLayout.js b/packages/dashboard-v2/src/layouts/UserSettingsLayout.js index 81820021..f008ee40 100644 --- a/packages/dashboard-v2/src/layouts/UserSettingsLayout.js +++ b/packages/dashboard-v2/src/layouts/UserSettingsLayout.js @@ -16,8 +16,8 @@ const Sidebar = () => ( Export - - API Keys + + Developer settings diff --git a/packages/dashboard-v2/src/pages/settings/api-keys.js b/packages/dashboard-v2/src/pages/settings/developer-settings.js similarity index 57% rename from packages/dashboard-v2/src/pages/settings/api-keys.js rename to packages/dashboard-v2/src/pages/settings/developer-settings.js index 03486248..02f92e1b 100644 --- a/packages/dashboard-v2/src/pages/settings/api-keys.js +++ b/packages/dashboard-v2/src/pages/settings/developer-settings.js @@ -8,11 +8,12 @@ import { APIKeyList } from "../../components/APIKeyList/APIKeyList"; import { Alert } from "../../components/Alert"; import { AddPublicAPIKeyForm } from "../../components/forms/AddPublicAPIKeyForm"; import { Metadata } from "../../components/Metadata"; +import HighlightedLink from "../../components/HighlightedLink"; -const APIKeysPage = () => { - const { data: apiKeys = [], mutate: reloadKeys, error } = useSWR("user/apikeys"); - const generalKeys = apiKeys.filter(({ public: isPublic }) => isPublic === "false"); - const publicKeys = apiKeys.filter(({ public: isPublic }) => isPublic === "true"); +const DeveloperSettingsPage = () => { + const { data: allKeys = [], mutate: reloadKeys, error } = useSWR("user/apikeys"); + const apiKeys = allKeys.filter(({ public: isPublic }) => isPublic === "false"); + const sponsorKeys = allKeys.filter(({ public: isPublic }) => isPublic === "true"); const publicFormRef = useRef(); const generalFormRef = useRef(); @@ -31,53 +32,60 @@ const APIKeysPage = () => { return ( <> - API Keys + Developer settings
    -
    +
    -

    API Keys

    -

    There are two types of API keys that you can generate for your account.

    -

    Make sure to use the appropriate type.

    +

    Developer settings

    +

    API keys allow developers and applications to extend the functionality of your portal account.

    +

    Skynet uses two types of API keys, explained below.


    -
    Public keys
    -

    - Public keys provide read access to a selected list of skylinks. You can share them publicly. +

    Sponsor keys
    +
    +

    + Sponsor keys allow users without an account on this portal to download skylinks covered by the API key.

    - +

    + Learn more about sponsoring content with Sponsor API Keys{" "} + + here + + . +

    {" "} + {/* TODO: missing documentation link */}
    - {error ? ( - An error occurred while loading your API keys. Please try again later. + An error occurred while loading your sponsor keys. Please try again later. ) : (
    - {publicKeys?.length > 0 ? ( - refreshState(true)} /> + {sponsorKeys?.length > 0 ? ( + refreshState(true)} /> ) : ( - No public API keys found. + No sponsor keys found. )}
    )}
    +
    -
    General keys
    +
    API keys

    These keys provide full access to Accounts service and are equivalent to using a JWT token.

    -

    +

    This type of API keys needs to be kept secret and should never be shared with anyone.

    -
    @@ -88,10 +96,10 @@ const APIKeysPage = () => { ) : (
    - {generalKeys?.length > 0 ? ( - refreshState(true)} /> + {apiKeys?.length > 0 ? ( + refreshState(true)} /> ) : ( - No general API keys found. + No API keys found. )}
    )} @@ -105,6 +113,6 @@ const APIKeysPage = () => { ); }; -APIKeysPage.Layout = UserSettingsLayout; +DeveloperSettingsPage.Layout = UserSettingsLayout; -export default APIKeysPage; +export default DeveloperSettingsPage; From 38407f6a317a85b793350957227669c3353ef22d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 12 Apr 2022 13:21:24 +0200 Subject: [PATCH 154/240] fix(dashboard-v2): fix redirect after creating an account --- .../src/components/forms/SignUpForm.js | 16 ++++++----- .../src/pages/auth/registration.js | 28 +++++++------------ 2 files changed, 19 insertions(+), 25 deletions(-) diff --git a/packages/dashboard-v2/src/components/forms/SignUpForm.js b/packages/dashboard-v2/src/components/forms/SignUpForm.js index 6725c673..c6ebed3e 100644 --- a/packages/dashboard-v2/src/components/forms/SignUpForm.js +++ b/packages/dashboard-v2/src/components/forms/SignUpForm.js @@ -32,14 +32,16 @@ export const SignUpForm = ({ onSuccess, onFailure }) => ( validationSchema={registrationSchema} onSubmit={async ({ email, password }, { setErrors }) => { try { - await accountsService.post("user", { - json: { - email, - password, - }, - }); + const user = await accountsService + .post("user", { + json: { + email, + password, + }, + }) + .json(); - onSuccess(); + onSuccess(user); } catch (err) { let isFormErrorSet = false; diff --git a/packages/dashboard-v2/src/pages/auth/registration.js b/packages/dashboard-v2/src/pages/auth/registration.js index b58562fd..5764ad6a 100644 --- a/packages/dashboard-v2/src/pages/auth/registration.js +++ b/packages/dashboard-v2/src/pages/auth/registration.js @@ -1,5 +1,4 @@ -import { useEffect, useState } from "react"; -import { navigate } from "gatsby"; +import { useCallback, useState } from "react"; import bytes from "pretty-bytes"; import AuthLayout from "../../layouts/AuthLayout"; @@ -10,6 +9,7 @@ import { SignUpForm } from "../../components/forms/SignUpForm"; import { usePortalSettings } from "../../contexts/portal-settings"; import { PlansProvider, usePlans } from "../../contexts/plans"; import { Metadata } from "../../components/Metadata"; +import { useUser } from "../../contexts/user"; const FreePortalHeader = () => { const { plans } = usePlans(); @@ -47,14 +47,14 @@ const State = { const SignUpPage = () => { const [state, setState] = useState(State.Pure); const { settings } = usePortalSettings(); + const { mutate: refreshUserState } = useUser(); - useEffect(() => { - if (state === State.Success) { - const timer = setTimeout(() => navigate(settings.isSubscriptionRequired ? "/upgrade" : "/"), 3000); - - return () => clearTimeout(timer); - } - }, [state, settings.isSubscriptionRequired]); + const onUserCreated = useCallback( + (newUser) => { + refreshUserState(newUser); + }, + [refreshUserState] + ); return ( @@ -70,7 +70,7 @@ const SignUpPage = () => { {state !== State.Success && ( <> - setState(State.Success)} onFailure={() => setState(State.Failure)} /> + setState(State.Failure)} />

    Already have an account? Sign in @@ -78,14 +78,6 @@ const SignUpPage = () => { )} - {state === State.Success && ( -

    -

    Please check your inbox and confirm your email address.

    -

    You will be redirected to your dashboard shortly.

    - Click here to go there now. -
    - )} - {state === State.Failure && (

    Something went wrong, please try again later.

    )} From b572cdf72cc2b290124ef283377567696dc69dde Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 12 Apr 2022 13:22:26 +0200 Subject: [PATCH 155/240] feat(dashboard-v2): proper copies on user settings pages + fix for account removal redirection --- .../AvatarUploader/AvatarUploader.js | 5 ++- .../src/components/CurrentPlan/CurrentPlan.js | 12 ++++-- .../src/components/Footer/Footer.js | 13 +++++- .../src/components/Uploader/Uploader.js | 2 +- .../components/forms/AccountRemovalForm.js | 3 +- .../dashboard-v2/src/pages/settings/export.js | 4 +- .../dashboard-v2/src/pages/settings/index.js | 42 ++++++++++++++----- .../src/pages/settings/notifications.js | 11 ++--- 8 files changed, 63 insertions(+), 29 deletions(-) diff --git a/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js b/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js index 9f5bbc82..2a3e400d 100644 --- a/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js +++ b/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js @@ -1,7 +1,7 @@ import { useEffect, useState } from "react"; import { useUser } from "../../contexts/user"; -import { SimpleUploadIcon } from "../Icons"; +// import { SimpleUploadIcon } from "../Icons"; const AVATAR_PLACEHOLDER = "/images/avatar-placeholder.svg"; @@ -20,6 +20,7 @@ export const AvatarUploader = (props) => { >
    + {/* TODO: uncomment when avatar uploads work
    - {/* TODO: actual uploading */}
    + */}
    ); }; diff --git a/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js b/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js index f8a5cf9e..fac41363 100644 --- a/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js +++ b/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js @@ -1,5 +1,6 @@ import dayjs from "dayjs"; import relativeTime from "dayjs/plugin/relativeTime"; +import prettyBytes from "pretty-bytes"; import { useUser } from "../../contexts/user"; import useActivePlan from "../../hooks/useActivePlan"; @@ -28,17 +29,20 @@ const CurrentPlan = () => { } return ( -
    +

    {activePlan.name}

    -
    - {activePlan.price === 0 &&

    100GB without paying a dime! 🎉

    } +
    + {activePlan.price === 0 && activePlan.limits && ( +

    {prettyBytes(activePlan.limits.storageLimit)} without paying a dime! 🎉

    + )} {activePlan.price !== 0 && (user.subscriptionCancelAtPeriodEnd ? (

    Your subscription expires {dayjs(user.subscribedUntil).fromNow()}

    ) : (

    {dayjs(user.subscribedUntil).fromNow(true)} until the next payment

    ))} - + + {user.subscriptionStatus && }
    diff --git a/packages/dashboard-v2/src/components/Footer/Footer.js b/packages/dashboard-v2/src/components/Footer/Footer.js index 501d502d..8096337a 100644 --- a/packages/dashboard-v2/src/components/Footer/Footer.js +++ b/packages/dashboard-v2/src/components/Footer/Footer.js @@ -1,8 +1,19 @@ import * as React from "react"; +import styled from "styled-components"; + import { PageContainer } from "../PageContainer"; +const FooterLink = styled.a.attrs({ + className: "text-palette-400 underline decoration-dotted decoration-offset-4 decoration-1", + rel: "noreferrer", + target: "_blank", +})``; + export const Footer = () => ( -

    © Skynet Labs Inc. All rights reserved.

    +

    + Made by Skynet Labs. Open-sourced{" "} + on Github. +

    ); diff --git a/packages/dashboard-v2/src/components/Uploader/Uploader.js b/packages/dashboard-v2/src/components/Uploader/Uploader.js index ab26d6c6..7b9a15df 100644 --- a/packages/dashboard-v2/src/components/Uploader/Uploader.js +++ b/packages/dashboard-v2/src/components/Uploader/Uploader.js @@ -118,7 +118,7 @@ const Uploader = ({ mode }) => {
    {uploads.length > 0 && ( -
    +
    {uploads.map((upload) => ( ))} diff --git a/packages/dashboard-v2/src/components/forms/AccountRemovalForm.js b/packages/dashboard-v2/src/components/forms/AccountRemovalForm.js index bdd7196e..02e465fe 100644 --- a/packages/dashboard-v2/src/components/forms/AccountRemovalForm.js +++ b/packages/dashboard-v2/src/components/forms/AccountRemovalForm.js @@ -34,8 +34,9 @@ export const AccountRemovalForm = ({ abort, onSuccess }) => {

    Delete account

    +

    This will completely delete your account.

    - This will completely delete your account. This process can't be undone. + This process cannot be undone.

    diff --git a/packages/dashboard-v2/src/pages/settings/export.js b/packages/dashboard-v2/src/pages/settings/export.js index 7a75bc0c..437f2b2f 100644 --- a/packages/dashboard-v2/src/pages/settings/export.js +++ b/packages/dashboard-v2/src/pages/settings/export.js @@ -38,8 +38,8 @@ const ExportPage = () => {

    Export

    - Et quidem exercitus quid ex eo delectu rerum, quem modo ista sis aequitate. Probabo, inquit, modo dixi, - constituto. + Select the items you want to export. You can use this data to migrate your account to another Skynet + portal.


    diff --git a/packages/dashboard-v2/src/pages/settings/index.js b/packages/dashboard-v2/src/pages/settings/index.js index 23a815e2..f8449cdc 100644 --- a/packages/dashboard-v2/src/pages/settings/index.js +++ b/packages/dashboard-v2/src/pages/settings/index.js @@ -8,6 +8,10 @@ import { Modal } from "../../components/Modal/Modal"; import { AccountRemovalForm } from "../../components/forms/AccountRemovalForm"; import { Alert } from "../../components/Alert"; import { Metadata } from "../../components/Metadata"; +import HighlightedLink from "../../components/HighlightedLink"; +import { AvatarUploader } from "../../components/AvatarUploader/AvatarUploader"; +import { useMedia } from "react-use"; +import theme from "../../lib/theme"; const State = { Pure: "PURE", @@ -19,10 +23,16 @@ const AccountPage = () => { const { user, mutate: reloadUser } = useUser(); const [state, setState] = useState(State.Pure); const [removalInitiated, setRemovalInitiated] = useState(false); + const isLargeScreen = useMedia(`(min-width: ${theme.screens.xl})`); const prompt = () => setRemovalInitiated(true); const abort = () => setRemovalInitiated(false); + const onAccountRemoved = useCallback(async () => { + await reloadUser(null); + await navigate("/auth/login"); + }, [reloadUser]); + const onSettingsUpdated = useCallback( async (updatedState) => { try { @@ -45,14 +55,7 @@ const AccountPage = () => {
    -
    -

    Account

    -

    - Tum dicere exorsus est laborum et quasi involuta aperiri, altera prompta et expedita. Primum igitur, - inquit, modo ista sis aequitate. -

    -
    -
    +

    Account

    {state === State.Failure && ( There was an error processing your request. Please try again later. @@ -63,7 +66,23 @@ const AccountPage = () => {
    Delete account
    -

    This will completely delete your account. This process can't be undone.

    +
    +

    + This action will delete your account and cannot be undone. +

    +

    + Your uploaded files will remain accessible while any portal continues to{" "} + + pin + {" "} + them to Skynet. +

    +
    +
    + {isLargeScreen && } +
    {removalInitiated && ( - navigate("/auth/login")} /> + )}
    diff --git a/packages/dashboard-v2/src/pages/settings/notifications.js b/packages/dashboard-v2/src/pages/settings/notifications.js index 447e40c8..fc109d5c 100644 --- a/packages/dashboard-v2/src/pages/settings/notifications.js +++ b/packages/dashboard-v2/src/pages/settings/notifications.js @@ -18,18 +18,13 @@ const NotificationsPage = () => {
    {/* TODO: saves on change */} - I agreee to get the latest news, updates and special offers delivered to my email inbox. + I agree to receive emails of the latest news, updates and offers.

    Statistics
    - {/* TODO: proper content :) */} -

    - Si sine causa, nollem me tamen laudandis maioribus meis corrupisti nec in malis. Si sine causa, mox - videro. -

    - +

    Check below to be notified by email when your usage approaches your plan's limits.

    • {/* TODO: saves on change */} @@ -37,7 +32,7 @@ const NotificationsPage = () => {
    • {/* TODO: saves on change */} - File limit + Files limit
    From e839184ee57079b3b581f2e7d020bb592bb69144 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 12 Apr 2022 13:22:59 +0200 Subject: [PATCH 156/240] style(dashboard-v2): prettier run --- packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js b/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js index fac41363..62828ded 100644 --- a/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js +++ b/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js @@ -41,7 +41,7 @@ const CurrentPlan = () => { ) : (

    {dayjs(user.subscribedUntil).fromNow(true)} until the next payment

    ))} - + {user.subscriptionStatus && }
    From 331776675f39b1760c8dd01d3b08430ab449feaa Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Apr 2022 13:02:44 +0000 Subject: [PATCH 157/240] build(deps): bump @stripe/stripe-js in /packages/dashboard Bumps [@stripe/stripe-js](https://github.com/stripe/stripe-js) from 1.26.0 to 1.27.0. - [Release notes](https://github.com/stripe/stripe-js/releases) - [Commits](https://github.com/stripe/stripe-js/compare/v1.26.0...v1.27.0) --- updated-dependencies: - dependency-name: "@stripe/stripe-js" dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 6b9e8c62..a184c7b8 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -11,7 +11,7 @@ "@fontsource/sora": "4.5.5", "@fontsource/source-sans-pro": "4.5.6", "@stripe/react-stripe-js": "1.7.1", - "@stripe/stripe-js": "1.26.0", + "@stripe/stripe-js": "1.27.0", "classnames": "2.3.1", "copy-text-to-clipboard": "^3.0.1", "dayjs": "1.11.0", diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index c005a16c..94f7ef53 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -182,10 +182,10 @@ dependencies: prop-types "^15.7.2" -"@stripe/stripe-js@1.26.0": - version "1.26.0" - resolved "https://registry.yarnpkg.com/@stripe/stripe-js/-/stripe-js-1.26.0.tgz#45670924753c01e18d0544ea1f1067b474aaa96f" - integrity sha512-4R1vC75yKaCVFARW3bhelf9+dKt4NP4iZY/sIjGK7AAMBVvZ47eG74NvsAIUdUnhOXSWFMjdFWqv+etk5BDW4g== +"@stripe/stripe-js@1.27.0": + version "1.27.0" + resolved "https://registry.yarnpkg.com/@stripe/stripe-js/-/stripe-js-1.27.0.tgz#ab0c82fa89fd40260de4414f69868b769e810550" + integrity sha512-SEiybUBu+tlsFKuzdFFydxxjkbrdzHo0tz/naYC5Dt9or/Ux2gcKJBPYQ4RmqQCNHFxgyNj6UYsclywwhe2inQ== "@tailwindcss/forms@0.5.0": version "0.5.0" From a8976b79f7806dbb818cb240b12fa678466a0b87 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Apr 2022 13:03:10 +0000 Subject: [PATCH 158/240] build(deps): bump swr from 1.2.2 to 1.3.0 in /packages/dashboard Bumps [swr](https://github.com/vercel/swr) from 1.2.2 to 1.3.0. - [Release notes](https://github.com/vercel/swr/releases) - [Commits](https://github.com/vercel/swr/compare/1.2.2...1.3.0) --- updated-dependencies: - dependency-name: swr dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 6b9e8c62..2f206140 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -28,7 +28,7 @@ "react-toastify": "8.2.0", "skynet-js": "3.0.2", "stripe": "8.216.0", - "swr": "1.2.2", + "swr": "1.3.0", "yup": "0.32.11" }, "devDependencies": { diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index c005a16c..426092b2 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -2280,10 +2280,10 @@ supports-preserve-symlinks-flag@^1.0.0: resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== -swr@1.2.2: - version "1.2.2" - resolved "https://registry.yarnpkg.com/swr/-/swr-1.2.2.tgz#6cae09928d30593a7980d80f85823e57468fac5d" - integrity sha512-ky0BskS/V47GpW8d6RU7CPsr6J8cr7mQD6+do5eky3bM0IyJaoi3vO8UhvrzJaObuTlGhPl2szodeB2dUd76Xw== +swr@1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/swr/-/swr-1.3.0.tgz#c6531866a35b4db37b38b72c45a63171faf9f4e8" + integrity sha512-dkghQrOl2ORX9HYrMDtPa7LTVHJjCTeZoB1dqTbnnEDlSvN8JEKpYIYurDfvbQFUUS8Cg8PceFVZNkW0KNNYPw== tailwindcss@3.0.23: version "3.0.23" From ab002ab5dd7d37c77ef6e34368fd897f38a5a03d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Apr 2022 13:03:52 +0000 Subject: [PATCH 159/240] build(deps): bump gatsby-plugin-robots-txt in /packages/website Bumps [gatsby-plugin-robots-txt](https://github.com/mdreizin/gatsby-plugin-robots-txt) from 1.7.0 to 1.7.1. - [Release notes](https://github.com/mdreizin/gatsby-plugin-robots-txt/releases) - [Commits](https://github.com/mdreizin/gatsby-plugin-robots-txt/compare/v1.7.0...v1.7.1) --- updated-dependencies: - dependency-name: gatsby-plugin-robots-txt dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 9d0a7302..ad1db597 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -19,7 +19,7 @@ "gatsby-plugin-manifest": "4.11.1", "gatsby-plugin-postcss": "5.10.0", "gatsby-plugin-react-helmet": "5.10.0", - "gatsby-plugin-robots-txt": "1.7.0", + "gatsby-plugin-robots-txt": "1.7.1", "gatsby-plugin-sharp": "4.10.2", "gatsby-plugin-sitemap": "5.10.2", "gatsby-plugin-svgr": "3.0.0-beta.0", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 860b612f..2940f22a 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6354,10 +6354,10 @@ gatsby-plugin-react-helmet@5.10.0: dependencies: "@babel/runtime" "^7.15.4" -gatsby-plugin-robots-txt@1.7.0: - version "1.7.0" - resolved "https://registry.yarnpkg.com/gatsby-plugin-robots-txt/-/gatsby-plugin-robots-txt-1.7.0.tgz#58ac310c9fb7e58162d6e21802884b342837b451" - integrity sha512-Y1D8FBeXNtECoCd0g0jIkhKpSvzFzeh2xpt1xTvGluRP6xmqJq7iB3DPEv7xqGlZAcfzaSxw/j5++Y+3WLva8A== +gatsby-plugin-robots-txt@1.7.1: + version "1.7.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-robots-txt/-/gatsby-plugin-robots-txt-1.7.1.tgz#f956729e34f6269cc314352e9ef1cf7b4c515a68" + integrity sha512-ZdZm8/4b7Whf+W5kf+DqjZwz/+DY+IB7xp227+m2f2rgGUsz8yVCz4RitiN5+EInGFZFry0v+IbrUKCXTpIZYg== dependencies: "@babel/runtime" "^7.16.7" generate-robotstxt "^8.0.3" @@ -8737,9 +8737,9 @@ mkdirp@^0.5.1, mkdirp@^0.5.4, mkdirp@~0.5.1: minimist "^1.2.5" moment@^2.29.1: - version "2.29.1" - resolved "https://registry.yarnpkg.com/moment/-/moment-2.29.1.tgz#b2be769fa31940be9eeea6469c075e35006fa3d3" - integrity sha512-kHmoybcPV8Sqy59DwNDY3Jefr64lK/by/da0ViFcuA4DH0vQg5Q6Ze5VimxkfQNSC+Mls/Kx53s7TjP1RhFEDQ== + version "2.29.2" + resolved "https://registry.yarnpkg.com/moment/-/moment-2.29.2.tgz#00910c60b20843bcba52d37d58c628b47b1f20e4" + integrity sha512-UgzG4rvxYpN15jgCmVJwac49h9ly9NurikMWGPdVxm8GZD6XjkKPxDTjQQ43gtGgnV3X0cAyWDdP2Wexoquifg== ms@2.0.0: version "2.0.0" From f9dfb364c0aed299217df2cc0e9d081ef1b1b532 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Apr 2022 13:04:05 +0000 Subject: [PATCH 160/240] build(deps): bump react-dropzone in /packages/website Bumps [react-dropzone](https://github.com/react-dropzone/react-dropzone) from 12.0.4 to 12.0.5. - [Release notes](https://github.com/react-dropzone/react-dropzone/releases) - [Commits](https://github.com/react-dropzone/react-dropzone/compare/v12.0.4...v12.0.5) --- updated-dependencies: - dependency-name: react-dropzone dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 9d0a7302..0f101f78 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -37,7 +37,7 @@ "prop-types": "15.8.1", "react": "17.0.2", "react-dom": "17.0.2", - "react-dropzone": "12.0.4", + "react-dropzone": "12.0.5", "react-helmet": "6.1.0", "react-use": "17.3.2", "skynet-js": "4.0.26-beta", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 860b612f..70f29876 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -8737,9 +8737,9 @@ mkdirp@^0.5.1, mkdirp@^0.5.4, mkdirp@~0.5.1: minimist "^1.2.5" moment@^2.29.1: - version "2.29.1" - resolved "https://registry.yarnpkg.com/moment/-/moment-2.29.1.tgz#b2be769fa31940be9eeea6469c075e35006fa3d3" - integrity sha512-kHmoybcPV8Sqy59DwNDY3Jefr64lK/by/da0ViFcuA4DH0vQg5Q6Ze5VimxkfQNSC+Mls/Kx53s7TjP1RhFEDQ== + version "2.29.2" + resolved "https://registry.yarnpkg.com/moment/-/moment-2.29.2.tgz#00910c60b20843bcba52d37d58c628b47b1f20e4" + integrity sha512-UgzG4rvxYpN15jgCmVJwac49h9ly9NurikMWGPdVxm8GZD6XjkKPxDTjQQ43gtGgnV3X0cAyWDdP2Wexoquifg== ms@2.0.0: version "2.0.0" @@ -10209,10 +10209,10 @@ react-dom@17.0.2: object-assign "^4.1.1" scheduler "^0.20.2" -react-dropzone@12.0.4: - version "12.0.4" - resolved "https://registry.yarnpkg.com/react-dropzone/-/react-dropzone-12.0.4.tgz#b88eeaa2c7118f7fd042404682b17a1d466f2fcf" - integrity sha512-fcqHEYe1MzAghU6/Hz86lHDlBNsA+lO48nAcm7/wA+kIzwS6uuJbUG33tBZjksj7GAZ1iUQ6NHwjUURPmSGang== +react-dropzone@12.0.5: + version "12.0.5" + resolved "https://registry.yarnpkg.com/react-dropzone/-/react-dropzone-12.0.5.tgz#f9b557484a8afd6267f670f96a770ddd3948838b" + integrity sha512-zUjZigD0VJ91CSm9T1h7ErxFReBLaa9sjS2dUL0+inb0RROZpSJTNDHPY1rrBES5V2NXhF8v0kghmaHc81BMFg== dependencies: attr-accept "^2.2.2" file-selector "^0.4.0" From b731d80ea0f526b4e19e497c89df8381e98df9c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 13 Apr 2022 08:23:44 +0200 Subject: [PATCH 161/240] ops(dashboard-v2): remove .env.development from repo --- packages/dashboard-v2/.env.development | 2 -- 1 file changed, 2 deletions(-) delete mode 100644 packages/dashboard-v2/.env.development diff --git a/packages/dashboard-v2/.env.development b/packages/dashboard-v2/.env.development deleted file mode 100644 index bee30f49..00000000 --- a/packages/dashboard-v2/.env.development +++ /dev/null @@ -1,2 +0,0 @@ -GATSBY_PORTAL_DOMAIN= -GATSBY_HOST= From a392863cbe21a5faffeed975b933b97640c7c8a7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 13 Apr 2022 08:29:11 +0200 Subject: [PATCH 162/240] fix(dashboard-v2): use binary: true --- packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js | 2 +- .../dashboard-v2/src/components/CurrentUsage/CurrentUsage.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js b/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js index 62828ded..d6df8506 100644 --- a/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js +++ b/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js @@ -33,7 +33,7 @@ const CurrentPlan = () => {

    {activePlan.name}

    {activePlan.price === 0 && activePlan.limits && ( -

    {prettyBytes(activePlan.limits.storageLimit)} without paying a dime! 🎉

    +

    {prettyBytes(activePlan.limits.storageLimit, { binary: true })} without paying a dime! 🎉

    )} {activePlan.price !== 0 && (user.subscriptionCancelAtPeriodEnd ? ( diff --git a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js index 081b9cca..3947638d 100644 --- a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js +++ b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js @@ -44,7 +44,7 @@ const useUsageData = () => { }; const size = (bytes) => { - const text = fileSize(bytes ?? 0, { maximumFractionDigits: 0 }); + const text = fileSize(bytes ?? 0, { maximumFractionDigits: 0, binary: true }); const [value, unit] = text.split(" "); return { From bf55ca8fbed5fbf7bffeb056861bb1bf10f0f873 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 13 Apr 2022 08:30:31 +0200 Subject: [PATCH 163/240] fix(dashboard-v2): use unambigous date format --- .../src/components/FileList/useFormattedFilesData.js | 2 +- .../src/components/LatestActivity/useFormattedActivityData.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js b/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js index 36a1feae..f7895450 100644 --- a/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js +++ b/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js @@ -10,7 +10,7 @@ const parseFileName = (fileName) => { const formatItem = ({ size, name: rawFileName, uploadedOn, downloadedOn, ...rest }) => { const [name, type] = parseFileName(rawFileName); - const date = dayjs(uploadedOn || downloadedOn).format("MM/DD/YYYY HH:MM"); + const date = dayjs(uploadedOn || downloadedOn).format("MMM D, YYYY HH:MM"); return { ...rest, diff --git a/packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js b/packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js index 913e4859..6e378436 100644 --- a/packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js +++ b/packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js @@ -10,7 +10,7 @@ const parseFileName = (fileName) => { const formatItem = ({ size, name: rawFileName, uploadedOn, downloadedOn, ...rest }) => { const [name, type] = parseFileName(rawFileName); - const date = dayjs(uploadedOn || downloadedOn).format("MM/DD/YYYY HH:MM"); + const date = dayjs(uploadedOn || downloadedOn).format("MMM D, YYYY HH:MM"); return { ...rest, From 9d079830ac49fd6c9e5386eb540ea92bffaff06e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Wed, 13 Apr 2022 15:25:17 +0200 Subject: [PATCH 164/240] refactor(dashboard-v2): fix typos, change copies, rename components --- packages/dashboard-v2/gatsby-config.js | 2 +- .../src/components/APIKeyList/APIKey.js | 4 +-- .../FileList/useFormattedFilesData.js | 3 ++- .../LatestActivity/ActivityTable.js | 4 +-- .../useFormattedActivityData.js | 26 ------------------- ...yForm.js => AddSkylinkToSponsorKeyForm.js} | 4 +-- ...blicAPIKeyForm.js => AddSponsorKeyForm.js} | 10 +++---- packages/dashboard-v2/src/lib/config.js | 1 + .../src/pages/settings/developer-settings.js | 9 +++---- 9 files changed, 18 insertions(+), 45 deletions(-) delete mode 100644 packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js rename packages/dashboard-v2/src/components/forms/{AddSkylinkToAPIKeyForm.js => AddSkylinkToSponsorKeyForm.js} (94%) rename packages/dashboard-v2/src/components/forms/{AddPublicAPIKeyForm.js => AddSponsorKeyForm.js} (96%) create mode 100644 packages/dashboard-v2/src/lib/config.js diff --git a/packages/dashboard-v2/gatsby-config.js b/packages/dashboard-v2/gatsby-config.js index 6994f956..0e269557 100644 --- a/packages/dashboard-v2/gatsby-config.js +++ b/packages/dashboard-v2/gatsby-config.js @@ -8,7 +8,7 @@ const { GATSBY_PORTAL_DOMAIN } = process.env; module.exports = { siteMetadata: { - title: `Accounts Dashboard`, + title: `Account Dashboard`, siteUrl: `https://account.${GATSBY_PORTAL_DOMAIN}`, }, trailingSlash: "never", diff --git a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js index cadc2775..b90a539e 100644 --- a/packages/dashboard-v2/src/components/APIKeyList/APIKey.js +++ b/packages/dashboard-v2/src/components/APIKeyList/APIKey.js @@ -4,7 +4,7 @@ import { useCallback, useState } from "react"; import { Alert } from "../Alert"; import { Button } from "../Button"; -import { AddSkylinkToAPIKeyForm } from "../forms/AddSkylinkToAPIKeyForm"; +import { AddSkylinkToSponsorKeyForm } from "../forms/AddSkylinkToSponsorKeyForm"; import { CogIcon, TrashIcon } from "../Icons"; import { Modal } from "../Modal"; @@ -145,7 +145,7 @@ export const APIKey = ({ apiKey, onRemoved, onEdited, onRemovalError }) => {
    {error && {error}} - +
    diff --git a/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js b/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js index f7895450..87bf1af6 100644 --- a/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js +++ b/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js @@ -1,6 +1,7 @@ import { useMemo } from "react"; import prettyBytes from "pretty-bytes"; import dayjs from "dayjs"; +import { DATE_FORMAT } from "../../lib/config"; const parseFileName = (fileName) => { const lastDotIndex = Math.max(0, fileName.lastIndexOf(".")) || Infinity; @@ -10,7 +11,7 @@ const parseFileName = (fileName) => { const formatItem = ({ size, name: rawFileName, uploadedOn, downloadedOn, ...rest }) => { const [name, type] = parseFileName(rawFileName); - const date = dayjs(uploadedOn || downloadedOn).format("MMM D, YYYY HH:MM"); + const date = dayjs(uploadedOn || downloadedOn).format(DATE_FORMAT); return { ...rest, diff --git a/packages/dashboard-v2/src/components/LatestActivity/ActivityTable.js b/packages/dashboard-v2/src/components/LatestActivity/ActivityTable.js index 2ee95e0f..3bea206f 100644 --- a/packages/dashboard-v2/src/components/LatestActivity/ActivityTable.js +++ b/packages/dashboard-v2/src/components/LatestActivity/ActivityTable.js @@ -3,13 +3,13 @@ import useSWR from "swr"; import { Table, TableBody, TableCell, TableRow } from "../Table"; import { ContainerLoadingIndicator } from "../LoadingIndicator"; +import useFormattedFilesData from "../FileList/useFormattedFilesData"; import { ViewAllLink } from "./ViewAllLink"; -import useFormattedActivityData from "./useFormattedActivityData"; export default function ActivityTable({ type }) { const { data, error } = useSWR(`user/${type}?pageSize=3`); - const items = useFormattedActivityData(data?.items || []); + const items = useFormattedFilesData(data?.items || []); if (!items.length) { return ( diff --git a/packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js b/packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js deleted file mode 100644 index 6e378436..00000000 --- a/packages/dashboard-v2/src/components/LatestActivity/useFormattedActivityData.js +++ /dev/null @@ -1,26 +0,0 @@ -import { useMemo } from "react"; -import prettyBytes from "pretty-bytes"; -import dayjs from "dayjs"; - -const parseFileName = (fileName) => { - const lastDotIndex = Math.max(0, fileName.lastIndexOf(".")) || Infinity; - - return [fileName.substr(0, lastDotIndex), fileName.substr(lastDotIndex)]; -}; - -const formatItem = ({ size, name: rawFileName, uploadedOn, downloadedOn, ...rest }) => { - const [name, type] = parseFileName(rawFileName); - const date = dayjs(uploadedOn || downloadedOn).format("MMM D, YYYY HH:MM"); - - return { - ...rest, - date, - size: prettyBytes(size), - type, - name, - }; -}; - -const useFormattedActivityData = (items) => useMemo(() => items.map(formatItem), [items]); - -export default useFormattedActivityData; diff --git a/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js b/packages/dashboard-v2/src/components/forms/AddSkylinkToSponsorKeyForm.js similarity index 94% rename from packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js rename to packages/dashboard-v2/src/components/forms/AddSkylinkToSponsorKeyForm.js index 60ed905c..71742096 100644 --- a/packages/dashboard-v2/src/components/forms/AddSkylinkToAPIKeyForm.js +++ b/packages/dashboard-v2/src/components/forms/AddSkylinkToSponsorKeyForm.js @@ -19,7 +19,7 @@ const newSkylinkSchema = Yup.object().shape({ }), }); -export const AddSkylinkToAPIKeyForm = ({ addSkylink }) => ( +export const AddSkylinkToSponsorKeyForm = ({ addSkylink }) => ( ( ); -AddSkylinkToAPIKeyForm.propTypes = { +AddSkylinkToSponsorKeyForm.propTypes = { addSkylink: PropTypes.func.isRequired, }; diff --git a/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js b/packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js similarity index 96% rename from packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js rename to packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js index b9540ea1..0f8b8c62 100644 --- a/packages/dashboard-v2/src/components/forms/AddPublicAPIKeyForm.js +++ b/packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js @@ -25,7 +25,7 @@ const skylinkValidator = (optional) => (value) => { } }; -const newPublicAPIKeySchema = Yup.object().shape({ +const newSponsorKeySchema = Yup.object().shape({ name: Yup.string(), skylinks: Yup.array().of(Yup.string().test("skylink", "Provide a valid Skylink", skylinkValidator(false))), nextSkylink: Yup.string().when("skylinks", { @@ -41,7 +41,7 @@ const State = { Failure: "FAILURE", }; -export const AddPublicAPIKeyForm = forwardRef(({ onSuccess }, ref) => { +export const AddSponsorKeyForm = forwardRef(({ onSuccess }, ref) => { const [state, setState] = useState(State.Pure); const [generatedKey, setGeneratedKey] = useState(null); @@ -72,7 +72,7 @@ export const AddPublicAPIKeyForm = forwardRef(({ onSuccess }, ref) => { skylinks: [], nextSkylink: "", }} - validationSchema={newPublicAPIKeySchema} + validationSchema={newSponsorKeySchema} onSubmit={async ({ name, skylinks, nextSkylink }, { resetForm }) => { try { const { key } = await accountsService @@ -192,8 +192,8 @@ export const AddPublicAPIKeyForm = forwardRef(({ onSuccess }, ref) => { ); }); -AddPublicAPIKeyForm.displayName = "AddPublicAPIKeyForm"; +AddSponsorKeyForm.displayName = "AddSponsorKeyForm"; -AddPublicAPIKeyForm.propTypes = { +AddSponsorKeyForm.propTypes = { onSuccess: PropTypes.func.isRequired, }; diff --git a/packages/dashboard-v2/src/lib/config.js b/packages/dashboard-v2/src/lib/config.js new file mode 100644 index 00000000..9c3beb35 --- /dev/null +++ b/packages/dashboard-v2/src/lib/config.js @@ -0,0 +1 @@ +export const DATE_FORMAT = "MMM D, YYYY HH:MM"; diff --git a/packages/dashboard-v2/src/pages/settings/developer-settings.js b/packages/dashboard-v2/src/pages/settings/developer-settings.js index 02f92e1b..cb58ab51 100644 --- a/packages/dashboard-v2/src/pages/settings/developer-settings.js +++ b/packages/dashboard-v2/src/pages/settings/developer-settings.js @@ -6,7 +6,7 @@ import UserSettingsLayout from "../../layouts/UserSettingsLayout"; import { AddAPIKeyForm, APIKeyType } from "../../components/forms/AddAPIKeyForm"; import { APIKeyList } from "../../components/APIKeyList/APIKeyList"; import { Alert } from "../../components/Alert"; -import { AddPublicAPIKeyForm } from "../../components/forms/AddPublicAPIKeyForm"; +import { AddSponsorKeyForm } from "../../components/forms/AddSponsorKeyForm"; import { Metadata } from "../../components/Metadata"; import HighlightedLink from "../../components/HighlightedLink"; @@ -59,7 +59,7 @@ const DeveloperSettingsPage = () => {

    {" "} {/* TODO: missing documentation link */}
    - +
    {error ? ( @@ -81,10 +81,7 @@ const DeveloperSettingsPage = () => {
    API keys

    - These keys provide full access to Accounts service and are equivalent to using a JWT token. -

    -

    - This type of API keys needs to be kept secret and should never be shared with anyone. + These keys allow uploading and downloading skyfiles, as well as reading and writing to the registry.

    From ef53c3a7b158543d8b9158fc0cf534d4407a4e7e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 14 Apr 2022 09:03:07 +0000 Subject: [PATCH 165/240] build(deps): bump gatsby from 4.11.2 to 4.12.1 in /packages/website Bumps [gatsby](https://github.com/gatsbyjs/gatsby) from 4.11.2 to 4.12.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/compare/gatsby@4.11.2...gatsby@4.12.1) --- updated-dependencies: - dependency-name: gatsby dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 338 ++++++++++++++++++++-------------- 2 files changed, 204 insertions(+), 136 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 83b3db88..f59e1146 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -13,7 +13,7 @@ "copy-text-to-clipboard": "3.0.1", "crypto-browserify": "3.12.0", "framer-motion": "6.2.8", - "gatsby": "4.11.2", + "gatsby": "4.12.1", "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.11.1", "gatsby-plugin-manifest": "4.11.1", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 8ffd53a6..ef7fce83 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -2594,10 +2594,10 @@ resolved "https://registry.yarnpkg.com/@types/scheduler/-/scheduler-0.16.2.tgz#1a62f89525723dde24ba1b01b092bf5df8ad4d39" integrity sha512-hppQEBDmlwhFAXKJX2KnWLYu5yMfi91yazPb2l+lbJiwW+wdo1gNeRA+3RgNSO39WYX2euey41KEwnqesU2Jew== -"@types/sharp@^0.29.5": - version "0.29.5" - resolved "https://registry.yarnpkg.com/@types/sharp/-/sharp-0.29.5.tgz#9c7032d30d138ad16dde6326beaff2af757b91b3" - integrity sha512-3TC+S3H5RwnJmLYMHrcdfNjz/CaApKmujjY9b6PU/pE6n0qfooi99YqXGWoW8frU9EWYj/XTI35Pzxa+ThAZ5Q== +"@types/sharp@^0.30.0": + version "0.30.2" + resolved "https://registry.yarnpkg.com/@types/sharp/-/sharp-0.30.2.tgz#df5ff34140b3bad165482e6f3d26b08e42a0503a" + integrity sha512-uLCBwjDg/BTcQit0dpNGvkIjvH3wsb8zpaJePCjvONBBSfaKHoxXBIuq1MT8DMQEfk2fKYnpC9QExCgFhkGkMQ== dependencies: "@types/node" "*" @@ -3339,23 +3339,23 @@ babel-plugin-polyfill-regenerator@^0.3.0: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" -babel-plugin-remove-graphql-queries@^4.11.1: - version "4.11.1" - resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.11.1.tgz#6f107865e8c1a83807c4b48b2262f5e0e0ba537e" - integrity sha512-Bqbeow4Xf+Vm4YhAucRGJjf9pNAXakSndYiLKfvef/W6mdtBh00SM8FMaX0U3rtR7ZUXV63RmIyOybVQ6SWCyg== +babel-plugin-remove-graphql-queries@^4.11.1, babel-plugin-remove-graphql-queries@^4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.12.1.tgz#08e7531ed3c61aaa3c2f083ddce8040844e611d4" + integrity sha512-z4Z0VkDpmoIW3cihPYEb+HJMgwa+RF77LnpgAC6y6ozS76ci3ENqfIry/vvdD6auys5TG3xYZ0eHpdPobXzhfA== dependencies: "@babel/runtime" "^7.15.4" - gatsby-core-utils "^3.11.1" + gatsby-core-utils "^3.12.1" babel-plugin-transform-react-remove-prop-types@^0.4.24: version "0.4.24" resolved "https://registry.yarnpkg.com/babel-plugin-transform-react-remove-prop-types/-/babel-plugin-transform-react-remove-prop-types-0.4.24.tgz#f2edaf9b4c6a5fbe5c1d678bfb531078c1555f3a" integrity sha512-eqj0hVcJUR57/Ug2zE1Yswsw4LhuqqHhD+8v120T1cl3kjg76QwtyBrdIk4WVwK+lAhBJVYCd/v+4nc4y+8JsA== -babel-preset-gatsby@^2.11.1: - version "2.11.1" - resolved "https://registry.yarnpkg.com/babel-preset-gatsby/-/babel-preset-gatsby-2.11.1.tgz#860d8d9903df38c314fa6f0cfdb197d02555c4e4" - integrity sha512-NGUNAIb3hzD1Mt97q5T3gSSuVuaqnYFSm7AvgByDa3Mk2ohF5Ni86sCLVPRIntIzJvgU5OWY4Qz+6rrI1SwprQ== +babel-preset-gatsby@^2.12.1: + version "2.12.1" + resolved "https://registry.yarnpkg.com/babel-preset-gatsby/-/babel-preset-gatsby-2.12.1.tgz#33d904dc54d5395e049fb346015eba1dbd62bfbf" + integrity sha512-ozpDqxxQa32gZVeXO07S0jLJvfewzMLAytP6QHJvVlHEcDnfo7sTo/r3ZNm+2SzeHP51eTDuTFo46WWQnY5kMw== dependencies: "@babel/plugin-proposal-class-properties" "^7.14.0" "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" @@ -3370,8 +3370,8 @@ babel-preset-gatsby@^2.11.1: babel-plugin-dynamic-import-node "^2.3.3" babel-plugin-macros "^2.8.0" babel-plugin-transform-react-remove-prop-types "^0.4.24" - gatsby-core-utils "^3.11.1" - gatsby-legacy-polyfills "^2.11.0" + gatsby-core-utils "^3.12.1" + gatsby-legacy-polyfills "^2.12.1" backo2@^1.0.2, backo2@~1.0.2: version "1.0.2" @@ -3566,7 +3566,7 @@ braces@^2.3.1: split-string "^3.0.2" to-regex "^3.0.1" -braces@^3.0.1, braces@~3.0.2: +braces@^3.0.2, braces@~3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== @@ -4340,10 +4340,10 @@ create-ecdh@^4.0.0: bn.js "^4.1.0" elliptic "^6.5.3" -create-gatsby@^2.11.2: - version "2.11.2" - resolved "https://registry.yarnpkg.com/create-gatsby/-/create-gatsby-2.11.2.tgz#b932bb16f024c929c4597225771275d54f3541bc" - integrity sha512-EHlULRVoiXoLM400sLYNtFRy5pemp2WoNKR6vjUlFnLBqn+BGe+TJAmKfwqHYFheXMozKqY2bW0ekuDj2x8zAg== +create-gatsby@^2.12.1: + version "2.12.1" + resolved "https://registry.yarnpkg.com/create-gatsby/-/create-gatsby-2.12.1.tgz#da5ab2b6dde54d62ec853b699c5aceafb0f166a2" + integrity sha512-dOsEy9feLJVFVzFFnA6xJL9OhfYcKewaGMqI9uUaUdifIehBjb5jdeWi+cNy49j2FQLMm38jfZ2SNSQjEK2yOw== dependencies: "@babel/runtime" "^7.15.4" @@ -5384,15 +5384,15 @@ eslint-plugin-jsx-a11y@^6.5.1: language-tags "^1.0.5" minimatch "^3.0.4" -eslint-plugin-react-hooks@^4.3.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/eslint-plugin-react-hooks/-/eslint-plugin-react-hooks-4.3.0.tgz#318dbf312e06fab1c835a4abef00121751ac1172" - integrity sha512-XslZy0LnMn+84NEG9jSGR6eGqaZB3133L8xewQo3fQagbQuGt7a63gf+P1NGKZavEYEC3UXaWEAA/AqDkuN6xA== +eslint-plugin-react-hooks@^4.4.0: + version "4.4.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-react-hooks/-/eslint-plugin-react-hooks-4.4.0.tgz#71c39e528764c848d8253e1aa2c7024ed505f6c4" + integrity sha512-U3RVIfdzJaeKDQKEJbz5p3NW8/L80PCATJAfuojwbaEL+gBjfGdhUcGde+WGUW46Q5sr/NgxevsIiDtNXrvZaQ== -eslint-plugin-react@^7.29.2: - version "7.29.2" - resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.29.2.tgz#2d4da69d30d0a736efd30890dc6826f3e91f3f7c" - integrity sha512-ypEBTKOy5liFQXZWMchJ3LN0JX1uPI6n7MN7OPHKacqXAxq5gYC30TdO7wqGYQyxD1OrzpobdHC3hDmlRWDg9w== +eslint-plugin-react@^7.29.4: + version "7.29.4" + resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.29.4.tgz#4717de5227f55f3801a5fd51a16a4fa22b5914d2" + integrity sha512-CVCXajliVh509PcZYRFyu/BoUEz452+jtQJq2b3Bae4v3xBUWPLCmtmBM+ZinG4MzwmxJgJ2M5rMqhqLVn7MtQ== dependencies: array-includes "^3.1.4" array.prototype.flatmap "^1.2.5" @@ -6158,10 +6158,10 @@ gatsby-background-image@1.6.0: short-uuid "^4.2.0" sort-media-queries "^0.2.2" -gatsby-cli@^4.11.2: - version "4.11.2" - resolved "https://registry.yarnpkg.com/gatsby-cli/-/gatsby-cli-4.11.2.tgz#0bd5c218f378edb0e674f7ba7a903be202fe3620" - integrity sha512-MypoVvMwWcDEtf5JTm1UTdGeOavRjnNRKfuUqvbhvb+q1vQ2xIFhu/pK9sdOlQfL6v6Fl8xwO2FuOfz+i53z3w== +gatsby-cli@^4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/gatsby-cli/-/gatsby-cli-4.12.1.tgz#157d6dbe783102248af2c938816a58401afeb64b" + integrity sha512-vlSqri0p9HpLfACFtUCJhxQArzxSvdcUkrN4Jlw8RgeJYxcJyb8VPPDJHJT3rMGRKZFeBaAeqMbqx/eK4K5F1w== dependencies: "@babel/code-frame" "^7.14.0" "@babel/core" "^7.15.5" @@ -6179,13 +6179,13 @@ gatsby-cli@^4.11.2: common-tags "^1.8.2" configstore "^5.0.1" convert-hrtime "^3.0.0" - create-gatsby "^2.11.2" + create-gatsby "^2.12.1" envinfo "^7.8.1" execa "^5.1.1" fs-exists-cached "^1.0.0" fs-extra "^10.0.0" - gatsby-core-utils "^3.11.1" - gatsby-telemetry "^3.11.1" + gatsby-core-utils "^3.12.1" + gatsby-telemetry "^3.12.1" hosted-git-info "^3.0.8" is-valid-path "^0.1.1" joi "^17.4.2" @@ -6209,10 +6209,10 @@ gatsby-cli@^4.11.2: yoga-layout-prebuilt "^1.10.0" yurnalist "^2.1.0" -gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.11.1, gatsby-core-utils@^3.8.2: - version "3.11.1" - resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.11.1.tgz#ea87c1d3aa45c26c9ea32b8e8b029afe6a56f8c7" - integrity sha512-Op9/uihtcsDLlZDfRsGJ1ya2mFx2YH9Zmx93bawElZ0YpIzKjCkNTp+I5i5UANxvs5I+Fljl0WHQRudMWg+fWA== +gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.11.1, gatsby-core-utils@^3.12.1, gatsby-core-utils@^3.8.2: + version "3.12.1" + resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.12.1.tgz#590ec08de7168b086b7d49128732b9ada95b985f" + integrity sha512-jBG1MfR6t2MZNIl8LQ3Cwc92F6uFNcEC091IK+qKVy9FNT0+WzcKQ6Olip6u1NSvCatfrg1FqrH0K78a6lmnLQ== dependencies: "@babel/runtime" "^7.15.4" ci-info "2.0.0" @@ -6222,7 +6222,7 @@ gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.11.1, gatsby-core-utils@^3.8.2: fs-extra "^10.0.0" got "^11.8.3" import-from "^4.0.0" - lmdb "^2.2.4" + lmdb "^2.2.6" lock "^1.1.0" node-object-hash "^2.3.10" proper-lockfile "^4.1.2" @@ -6230,49 +6230,49 @@ gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.11.1, gatsby-core-utils@^3.8.2: tmp "^0.2.1" xdg-basedir "^4.0.0" -gatsby-graphiql-explorer@^2.11.0: - version "2.11.0" - resolved "https://registry.yarnpkg.com/gatsby-graphiql-explorer/-/gatsby-graphiql-explorer-2.11.0.tgz#7e886846482ad72bd49f515e7faa658a94342803" - integrity sha512-nMNXlF/pleO/rH66t00SdXdKq3vV0/Su5EEQY7xg3yRc38ueC2UkZq10nrJiVoc05RO8Txo5o2gpoC2DP07lFg== +gatsby-graphiql-explorer@^2.12.1: + version "2.12.1" + resolved "https://registry.yarnpkg.com/gatsby-graphiql-explorer/-/gatsby-graphiql-explorer-2.12.1.tgz#4fad5b9a3ccbcc4871f70222e8ac1ca880ff844d" + integrity sha512-H5phTjIGUiUZxN3C0hogH66lB+qC9HO9O4m4RpHZ3JyxVIvPemGSNmgovhL7+LydS34UY5rbT0UBFwaxrHMZpQ== dependencies: "@babel/runtime" "^7.15.4" -gatsby-legacy-polyfills@^2.11.0: - version "2.11.0" - resolved "https://registry.yarnpkg.com/gatsby-legacy-polyfills/-/gatsby-legacy-polyfills-2.11.0.tgz#8b2afc4d97f44eb5767fe9b49f55ff675055ffd2" - integrity sha512-ulkRNCitwFjwUM4f2ufljH0WjELm6QEIOGRryNRt9LKJEB9QGmdm+KUAWIv7xrFUqKq1Pn6is64wcfXDw21zSA== +gatsby-legacy-polyfills@^2.12.1: + version "2.12.1" + resolved "https://registry.yarnpkg.com/gatsby-legacy-polyfills/-/gatsby-legacy-polyfills-2.12.1.tgz#62ad6432b3c17f7f5640786ed00dba88da60ab22" + integrity sha512-x2Njk0GsBKsiVBDZHI7nVWDNBPQeonQsElzFEDoSJpW47j9H8PPJDeOUZ+u5q76rtxuQQo/VXl/eD817qRBxAA== dependencies: "@babel/runtime" "^7.15.4" core-js-compat "3.9.0" -gatsby-link@^4.11.1: - version "4.11.1" - resolved "https://registry.yarnpkg.com/gatsby-link/-/gatsby-link-4.11.1.tgz#f8bfee4c7f3bf0ede255bddf87d0f13c64ed39f2" - integrity sha512-wOhdgsnzHr4iYWo3iKadw8jj5PmIu1wbi6LUftwQzFOFvkBaJvC/br1ju8W0nbwSjWG474hTZRon43xDQX9bIw== +gatsby-link@^4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/gatsby-link/-/gatsby-link-4.12.1.tgz#131448e9c51e0c9a65e2a342603d496e85cea2da" + integrity sha512-ILWYNqyTlEt2bOVWgzwmbijwC+Ow4CZVbnWOyaQ/jvu5z3ZGL0z5tGGD+sjZAHc8anOMWn/JWhL0BKGVaxjMGQ== dependencies: "@babel/runtime" "^7.15.4" "@types/reach__router" "^1.3.10" - gatsby-page-utils "^2.11.1" + gatsby-page-utils "^2.12.1" prop-types "^15.7.2" -gatsby-page-utils@^2.11.1: - version "2.11.1" - resolved "https://registry.yarnpkg.com/gatsby-page-utils/-/gatsby-page-utils-2.11.1.tgz#dd10f99184b64528ae76f2b654b8ed1b23cb9c39" - integrity sha512-K1Mbk4CKYZwpJcE4zk4JAff7ZBNFXI0fC8lZwLbDAzVcqYUaouqqqnoU7WeB8HHUqDQi05CXItx1bbZFDGIymw== +gatsby-page-utils@^2.12.1: + version "2.12.1" + resolved "https://registry.yarnpkg.com/gatsby-page-utils/-/gatsby-page-utils-2.12.1.tgz#ee5dbd21b8e22003e5b0c7e4d86ed3b89773c0ac" + integrity sha512-2NPfVHRoHYcqUZrGVAvHN28uqI/PTGE/DrpE79YR/blbnloEzwzpAGNbBjWitgcR0st5q5NrATJQ/Imu3M7ApA== dependencies: "@babel/runtime" "^7.15.4" bluebird "^3.7.2" chokidar "^3.5.2" fs-exists-cached "^1.0.0" - gatsby-core-utils "^3.11.1" + gatsby-core-utils "^3.12.1" glob "^7.2.0" lodash "^4.17.21" - micromatch "^4.0.4" + micromatch "^4.0.5" -gatsby-parcel-config@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/gatsby-parcel-config/-/gatsby-parcel-config-0.2.0.tgz#0b1795d17c825bd293c372fa0acfa987aa91111e" - integrity sha512-BbsSm5O0R7IvCRLNSk3lBpkU8RtSOn8s7Ifa7bHF63PzTG1SUpBjwMF6301tCbvdSXWrP7n9dsfaXS6ex/TElQ== +gatsby-parcel-config@^0.3.1: + version "0.3.1" + resolved "https://registry.yarnpkg.com/gatsby-parcel-config/-/gatsby-parcel-config-0.3.1.tgz#424c7b3d65b60e2e454cd9d61d4c5de752aad576" + integrity sha512-Wpz6DSKiWeqVyZUNmO7EHy0h9ISG+HfUD8v2g0kN4ZcZjJtSiWvGym1+6Swgjo9bQvy59qa7bO4hKGA9gHvMVg== dependencies: "@gatsbyjs/parcel-namer-relative-to-cwd" "0.0.2" "@parcel/bundler-default" "^2.3.2" @@ -6322,21 +6322,21 @@ gatsby-plugin-manifest@4.11.1: semver "^7.3.5" sharp "^0.30.1" -gatsby-plugin-page-creator@^4.11.1: - version "4.11.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-page-creator/-/gatsby-plugin-page-creator-4.11.1.tgz#750f4b773684777cec6caa9266787427ed2630a6" - integrity sha512-6XET4qYqu2yVwUU6sO44wSR62zQZdq7BoMvN9OhKpUDBZYLfve9CwufkhZZnQvq+axNZZMUmKa/RqbBXiE6/yA== +gatsby-plugin-page-creator@^4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-page-creator/-/gatsby-plugin-page-creator-4.12.1.tgz#36460f5308df8b04bb2b0649150cb87e3eb15c8f" + integrity sha512-McVYpXWgneo1+3+8KGrGATgNwAYtZXbFKL8Q18lwH+bt5f2NbYP23g+xGitxT62zvhhzs0AjuEJa7BoTEmFTMQ== dependencies: "@babel/runtime" "^7.15.4" "@babel/traverse" "^7.15.4" "@sindresorhus/slugify" "^1.1.2" chokidar "^3.5.2" fs-exists-cached "^1.0.0" - gatsby-core-utils "^3.11.1" - gatsby-page-utils "^2.11.1" - gatsby-plugin-utils "^3.5.1" - gatsby-telemetry "^3.11.1" - globby "^11.0.4" + gatsby-core-utils "^3.12.1" + gatsby-page-utils "^2.12.1" + gatsby-plugin-utils "^3.6.1" + gatsby-telemetry "^3.12.1" + globby "^11.1.0" lodash "^4.17.21" gatsby-plugin-postcss@5.10.0: @@ -6402,10 +6402,10 @@ gatsby-plugin-svgr@3.0.0-beta.0: resolved "https://registry.yarnpkg.com/gatsby-plugin-svgr/-/gatsby-plugin-svgr-3.0.0-beta.0.tgz#7e5315f51dae2663a447899322ea1487cef93dd6" integrity sha512-oALTh6VwO6l3khgC/vGr706aqt38EkXwdr6iXVei/auOKGxpCLEuDCQVal1a4SpYXdjHjRsEyab6bxaHL2lzsA== -gatsby-plugin-typescript@^4.11.1: - version "4.11.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-typescript/-/gatsby-plugin-typescript-4.11.1.tgz#dcd96ded685f8c4a73ae5524faab342f9c9e3c1d" - integrity sha512-6ef2wRhPqcLPyekEAU3xcoqI59r+mDnCzn/O+8hRgwJyx/2dwvF8brusetXoqdTk4Vyhk44p8dog8+gCGATckw== +gatsby-plugin-typescript@^4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-typescript/-/gatsby-plugin-typescript-4.12.1.tgz#8fe51b57f1fca5027f5dd558b73364a4c34a0a38" + integrity sha512-7ZzGTL+hNGGmiIk4j4QSZYyYsy4i9EW/zgK/IJwmpSBNzoagI/Pz64ntNWpxZstfgzkuIYZfvuvj3Ao9mKF5aw== dependencies: "@babel/core" "^7.15.5" "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" @@ -6413,37 +6413,37 @@ gatsby-plugin-typescript@^4.11.1: "@babel/plugin-proposal-optional-chaining" "^7.14.5" "@babel/preset-typescript" "^7.15.0" "@babel/runtime" "^7.15.4" - babel-plugin-remove-graphql-queries "^4.11.1" + babel-plugin-remove-graphql-queries "^4.12.1" -gatsby-plugin-utils@^3.4.2, gatsby-plugin-utils@^3.5.1: - version "3.5.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.5.1.tgz#9aed9deec0f4ee82bfc7390f735b9455ca4f8494" - integrity sha512-RZXUvwQjTnkukMfAGr+DCz/qZj7g6REljTmQS43MaovWO4Yf4YGvs+1Leays7J0XmqN2I3SIZGBgt4tgKCsNVQ== +gatsby-plugin-utils@^3.4.2, gatsby-plugin-utils@^3.5.1, gatsby-plugin-utils@^3.6.1: + version "3.6.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.6.1.tgz#31d742e1aded08439ad42959880821e1fc9740cd" + integrity sha512-Ebk98v4mxaDWjGFl6VBeNv1zjeJ7UCQ29UTabzY2BpztvUCBHfLVQdMmuaAgzPRn+A3SFVOGpcl++CF0IEl+7A== dependencies: "@babel/runtime" "^7.15.4" fs-extra "^10.0.0" - gatsby-core-utils "^3.11.1" - gatsby-sharp "^0.5.0" + gatsby-core-utils "^3.12.1" + gatsby-sharp "^0.6.1" graphql-compose "^9.0.7" import-from "^4.0.0" joi "^17.4.2" mime "^3.0.0" -gatsby-react-router-scroll@^5.11.0: - version "5.11.0" - resolved "https://registry.yarnpkg.com/gatsby-react-router-scroll/-/gatsby-react-router-scroll-5.11.0.tgz#866b89366146d8df3852ed699d12be1e9fce4acc" - integrity sha512-g/lyG0X73cpI9DdYvCv5rZiV8LqHjn6q1l8Vfm/jBS7wtv8XxNR4BxUqkbMeHRcvZcX5bXku6FFSFUAOd9c3QQ== +gatsby-react-router-scroll@^5.12.1: + version "5.12.1" + resolved "https://registry.yarnpkg.com/gatsby-react-router-scroll/-/gatsby-react-router-scroll-5.12.1.tgz#10fdf43c1179ae53e7726c6c8d894139e7862e8f" + integrity sha512-zZCTiicALh6eSsQAgIhSCmQm6Dl6fY6eaKmOXGMMbVtUKmiGxikh2MFN6S5J5JU9MV/piSheVqYkouyTDGXbuw== dependencies: "@babel/runtime" "^7.15.4" - prop-types "^15.7.2" + prop-types "^15.8.1" -gatsby-sharp@^0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/gatsby-sharp/-/gatsby-sharp-0.5.0.tgz#879d3c462eefa917cb3a50c6ec891951d9740f56" - integrity sha512-9wZS0ADZsKTCsU66sxIP/tCHgFaREyoYm53tepgtp/YSVWNrurx9/0kGf8XsFFY9OecrqIRNuk1cWe7XKCpbQA== +gatsby-sharp@^0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/gatsby-sharp/-/gatsby-sharp-0.6.1.tgz#48805690cb020111722cc25445b4b662446da6d0" + integrity sha512-KhBFE72QLlrAgeMWNoBV2LDp0nZ9ZOw1pY5wIohb/ktDFRUi9K5nwVCJvDJonfPn100mxtDqnZVckXirtcHVzQ== dependencies: - "@types/sharp" "^0.29.5" - sharp "^0.30.1" + "@types/sharp" "^0.30.0" + sharp "^0.30.3" gatsby-source-filesystem@4.10.1: version "4.10.1" @@ -6463,10 +6463,10 @@ gatsby-source-filesystem@4.10.1: valid-url "^1.0.9" xstate "^4.26.1" -gatsby-telemetry@^3.10.1, gatsby-telemetry@^3.11.1: - version "3.11.1" - resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.11.1.tgz#87caed899143276056e9af20ab38c15ad9dcdf52" - integrity sha512-TPNKTpuYFyULOuRvhpXUtj8h2E7bvrTYsRC/aKeHoWqEchwwbzPwBSJd+3ZFjsxLHIXAa5sTAlR2wd9SYBgOlA== +gatsby-telemetry@^3.10.1, gatsby-telemetry@^3.12.1: + version "3.12.1" + resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.12.1.tgz#a3508a45d95f2c3457db7dbe2628560d00c43beb" + integrity sha512-sAL2T9GdYpceGlFP6CymVDoy0UEhRvrJApv/mu7sU6F0gu8g8rOLvRxVYE3Y2D9RdfCzkuLIonzmscmVIduyOg== dependencies: "@babel/code-frame" "^7.14.0" "@babel/runtime" "^7.15.4" @@ -6476,7 +6476,7 @@ gatsby-telemetry@^3.10.1, gatsby-telemetry@^3.11.1: boxen "^4.2.0" configstore "^5.0.1" fs-extra "^10.0.0" - gatsby-core-utils "^3.11.1" + gatsby-core-utils "^3.12.1" git-up "^4.0.5" is-docker "^2.2.1" lodash "^4.17.21" @@ -6506,18 +6506,18 @@ gatsby-transformer-yaml@4.11.0: lodash "^4.17.21" unist-util-select "^1.5.0" -gatsby-worker@^1.11.0: - version "1.11.0" - resolved "https://registry.yarnpkg.com/gatsby-worker/-/gatsby-worker-1.11.0.tgz#bf8c3b9374390260b8335d7cfccbc332d0716727" - integrity sha512-uJ5bNrifIrS20o0SYkmb379logfRKO35cqYxd2R0uNf9kWGaQOda0SZfm7Uw+Vdx7cO9Ra8p1ArijbHm7ZArCA== +gatsby-worker@^1.12.1: + version "1.12.1" + resolved "https://registry.yarnpkg.com/gatsby-worker/-/gatsby-worker-1.12.1.tgz#553a0fd5ad796567fc3ab965490270ff7b0ae680" + integrity sha512-9slhXsK1/N4nJK+Yia84PL/zvNqV/bqD820W4R2f5jh5gEnVYrY2TcnG6A+UDbY7orhS0CLf1mMW9WKd6u6CUA== dependencies: "@babel/core" "^7.15.5" "@babel/runtime" "^7.15.4" -gatsby@4.11.2: - version "4.11.2" - resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-4.11.2.tgz#fba8843316992e2f0eafc5ae3ee6fb37ce7aa953" - integrity sha512-kJ2gHQzO3efV1BaynGfxi0divFOorUqxKom/QdIEnaj9VMkNRnrpNxUNsT4ljq+d9BTlq/0AAIpGNQZKC1ZgFg== +gatsby@4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-4.12.1.tgz#b9a72bca167662a05d7154e5e6091f31aa333efd" + integrity sha512-/QteQShPAW1dRmG9wrjHmdfQEQxh6WfOi9jnJXAxljAx8UlRt0JFntxMc9gWGUJD6fXYKmf13Jan9izuNDQxNQ== dependencies: "@babel/code-frame" "^7.14.0" "@babel/core" "^7.15.5" @@ -6544,8 +6544,8 @@ gatsby@4.11.2: babel-plugin-add-module-exports "^1.0.4" babel-plugin-dynamic-import-node "^2.3.3" babel-plugin-lodash "^3.3.4" - babel-plugin-remove-graphql-queries "^4.11.1" - babel-preset-gatsby "^2.11.1" + babel-plugin-remove-graphql-queries "^4.12.1" + babel-preset-gatsby "^2.12.1" better-opn "^2.1.1" bluebird "^3.7.2" body-parser "^1.19.0" @@ -6574,8 +6574,8 @@ gatsby@4.11.2: eslint-plugin-graphql "^4.0.0" eslint-plugin-import "^2.25.4" eslint-plugin-jsx-a11y "^6.5.1" - eslint-plugin-react "^7.29.2" - eslint-plugin-react-hooks "^4.3.0" + eslint-plugin-react "^7.29.4" + eslint-plugin-react-hooks "^4.4.0" eslint-webpack-plugin "^2.6.0" event-source-polyfill "^1.0.25" execa "^5.1.1" @@ -6587,19 +6587,19 @@ gatsby@4.11.2: find-cache-dir "^3.3.2" fs-exists-cached "1.0.0" fs-extra "^10.0.0" - gatsby-cli "^4.11.2" - gatsby-core-utils "^3.11.1" - gatsby-graphiql-explorer "^2.11.0" - gatsby-legacy-polyfills "^2.11.0" - gatsby-link "^4.11.1" - gatsby-page-utils "^2.11.1" - gatsby-parcel-config "^0.2.0" - gatsby-plugin-page-creator "^4.11.1" - gatsby-plugin-typescript "^4.11.1" - gatsby-plugin-utils "^3.5.1" - gatsby-react-router-scroll "^5.11.0" - gatsby-telemetry "^3.11.1" - gatsby-worker "^1.11.0" + gatsby-cli "^4.12.1" + gatsby-core-utils "^3.12.1" + gatsby-graphiql-explorer "^2.12.1" + gatsby-legacy-polyfills "^2.12.1" + gatsby-link "^4.12.1" + gatsby-page-utils "^2.12.1" + gatsby-parcel-config "^0.3.1" + gatsby-plugin-page-creator "^4.12.1" + gatsby-plugin-typescript "^4.12.1" + gatsby-plugin-utils "^3.6.1" + gatsby-react-router-scroll "^5.12.1" + gatsby-telemetry "^3.12.1" + gatsby-worker "^1.12.1" glob "^7.2.0" globby "^11.1.0" got "^11.8.2" @@ -6614,7 +6614,7 @@ gatsby@4.11.2: joi "^17.4.2" json-loader "^0.5.7" latest-version "5.1.0" - lmdb "^2.2.3" + lmdb "~2.2.3" lodash "^4.17.21" md5-file "^5.0.0" meant "^1.0.3" @@ -6672,7 +6672,7 @@ gatsby@4.11.2: xstate "^4.26.0" yaml-loader "^0.6.0" optionalDependencies: - gatsby-sharp "^0.5.0" + gatsby-sharp "^0.6.1" gauge@~2.7.3: version "2.7.4" @@ -6894,7 +6894,7 @@ globby@11.0.3: merge2 "^1.3.0" slash "^3.0.0" -globby@^11.0.3, globby@^11.0.4, globby@^11.1.0: +globby@^11.0.3, globby@^11.1.0: version "11.1.0" resolved "https://registry.yarnpkg.com/globby/-/globby-11.1.0.tgz#bd4be98bb042f83d796f7e3811991fbe82a0d34b" integrity sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g== @@ -8096,6 +8096,36 @@ listr2@^3.8.3: through "^2.3.8" wrap-ansi "^7.0.0" +lmdb-darwin-arm64@2.3.2: + version "2.3.2" + resolved "https://registry.yarnpkg.com/lmdb-darwin-arm64/-/lmdb-darwin-arm64-2.3.2.tgz#edcd324e4693abfcd02e7c5ba44a7f0e209f7588" + integrity sha512-20lWWUPGKnSZRFY8FBm+vZEFx/5Deh0joz6cqJ8/0SuO/ejqRCppSsNqAxPqW87KUNR5rNfhaA2oRekMeb0cwQ== + +lmdb-darwin-x64@2.3.2: + version "2.3.2" + resolved "https://registry.yarnpkg.com/lmdb-darwin-x64/-/lmdb-darwin-x64-2.3.2.tgz#6561f37d0461c3128b92fb80996c54e6243af939" + integrity sha512-BsBnOfgK1B11Dh4RgcgBTmkmsPv3mjBPKsA4W4E+18SW9K2aRi86CAMPXqjfY/OJDUe1pSrpVf1A83b8N/C9rg== + +lmdb-linux-arm64@2.3.2: + version "2.3.2" + resolved "https://registry.yarnpkg.com/lmdb-linux-arm64/-/lmdb-linux-arm64-2.3.2.tgz#feb4a52a0030feb9520543c78919c30250a85107" + integrity sha512-DIibLZHpwwlIsP9cBRmw0xqDy6wZH+CDAnOTI+eihQ5PdWjTs+kaQs5O/x8l6/8fwCB0TPYKWTqfdUbvd/F7AA== + +lmdb-linux-arm@2.3.2: + version "2.3.2" + resolved "https://registry.yarnpkg.com/lmdb-linux-arm/-/lmdb-linux-arm-2.3.2.tgz#d8ee33547cc0f671efcf63ca381306df51f972f5" + integrity sha512-ofxfxVQqMbaC2Ygjzk8k6xgS5Dg/3cANeLcEx14T35GoU5pQKlLAWjypptyLQEeOboEmEOpZmHMoD7sWu/zakQ== + +lmdb-linux-x64@2.3.2: + version "2.3.2" + resolved "https://registry.yarnpkg.com/lmdb-linux-x64/-/lmdb-linux-x64-2.3.2.tgz#1c66a012199ab5235d3fcec8c3fdad573cf3eff4" + integrity sha512-HBUd013RRQ2KpiyBqqqSPSEwPpVUpTJZdTZGDVQFQZuxqyJumt4Wye3uh6ZgEiBtxzSelt4xvAeNjYPH0dcZSQ== + +lmdb-win32-x64@2.3.2: + version "2.3.2" + resolved "https://registry.yarnpkg.com/lmdb-win32-x64/-/lmdb-win32-x64-2.3.2.tgz#e65f79bfbb9f09ebfa53d3b03959bc581ebda55a" + integrity sha512-/hir5oU+GYm7/B6QirrpyOmIuzCKiIbWoKIJI2ebXeJlrs6Jj7UY9caPBYVkCzd79QzJnB7hIlX/F6Jx6gcUmg== + lmdb@2.2.4: version "2.2.4" resolved "https://registry.yarnpkg.com/lmdb/-/lmdb-2.2.4.tgz#6494d5a1d1db152e0be759edcfa06893e4cbdb53" @@ -8107,7 +8137,26 @@ lmdb@2.2.4: ordered-binary "^1.2.4" weak-lru-cache "^1.2.2" -lmdb@^2.0.2, lmdb@^2.2.3, lmdb@^2.2.4: +lmdb@^2.0.2, lmdb@^2.2.6: + version "2.3.3" + resolved "https://registry.yarnpkg.com/lmdb/-/lmdb-2.3.3.tgz#ee0c53a5f5c2509c566b891803b3322e5a59095f" + integrity sha512-CrooSvHOzd+jPXCXpiffu2+5m90Fe6L/cw90fg+4sCWNrw3W7/ad20CGuTkMVU7mAuwXEAJAfnUwvHN2pS9Rqg== + dependencies: + msgpackr "^1.5.4" + nan "^2.14.2" + node-addon-api "^4.3.0" + node-gyp-build-optional-packages "^4.3.2" + ordered-binary "^1.2.4" + weak-lru-cache "^1.2.2" + optionalDependencies: + lmdb-darwin-arm64 "2.3.2" + lmdb-darwin-x64 "2.3.2" + lmdb-linux-arm "2.3.2" + lmdb-linux-arm64 "2.3.2" + lmdb-linux-x64 "2.3.2" + lmdb-win32-x64 "2.3.2" + +lmdb@~2.2.3: version "2.2.6" resolved "https://registry.yarnpkg.com/lmdb/-/lmdb-2.2.6.tgz#a52ef533812b8abcbe0033fc9d74d215e7dfc0a0" integrity sha512-UmQV0oZZcV3EN6rjcAjIiuWcc3MYZGWQ0GUYz46Ron5fuTa/dUow7WSQa6leFkvZIKVUdECBWVw96tckfEzUFQ== @@ -8579,13 +8628,13 @@ micromatch@^3.1.10: snapdragon "^0.8.1" to-regex "^3.0.2" -micromatch@^4.0.4: - version "4.0.4" - resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.4.tgz#896d519dfe9db25fce94ceb7a500919bf881ebf9" - integrity sha512-pRmzw/XUcwXGpD9aI9q/0XOwLNygjETJ8y0ao0wdqprrzDa4YnxLcz7fQRZr8voh8V10kGhABbNcHVk5wHgWwg== +micromatch@^4.0.4, micromatch@^4.0.5: + version "4.0.5" + resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.5.tgz#bc8999a7cbbf77cdc89f132f6e467051b49090c6" + integrity sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA== dependencies: - braces "^3.0.1" - picomatch "^2.2.3" + braces "^3.0.2" + picomatch "^2.3.1" miller-rabin@^4.0.0: version "4.0.1" @@ -8919,6 +8968,11 @@ node-fetch@^2.6.1, node-fetch@^2.6.6, node-fetch@^2.6.7: dependencies: whatwg-url "^5.0.0" +node-gyp-build-optional-packages@^4.3.2: + version "4.3.2" + resolved "https://registry.yarnpkg.com/node-gyp-build-optional-packages/-/node-gyp-build-optional-packages-4.3.2.tgz#82de9bdf9b1ad042457533afb2f67469dc2264bb" + integrity sha512-P5Ep3ISdmwcCkZIaBaQamQtWAG0facC89phWZgi5Z3hBU//J6S48OIvyZWSPPf6yQMklLZiqoosWAZUj7N+esA== + node-gyp-build@^4.2.3, node-gyp-build@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.3.0.tgz#9f256b03e5826150be39c764bf51e993946d71a3" @@ -9509,7 +9563,7 @@ picocolors@^1.0.0: resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c" integrity sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ== -picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.2.3: +picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.3.1: version "2.3.1" resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== @@ -10871,6 +10925,20 @@ sharp@^0.30.1: tar-fs "^2.1.1" tunnel-agent "^0.6.0" +sharp@^0.30.3: + version "0.30.3" + resolved "https://registry.yarnpkg.com/sharp/-/sharp-0.30.3.tgz#315a1817423a4d1cde5119a21c99c234a7a6fb37" + integrity sha512-rjpfJFK58ZOFSG8sxYSo3/JQb4ej095HjXp9X7gVu7gEn1aqSG8TCW29h/Rr31+PXrFADo1H/vKfw0uhMQWFtg== + dependencies: + color "^4.2.1" + detect-libc "^2.0.1" + node-addon-api "^4.3.0" + prebuild-install "^7.0.1" + semver "^7.3.5" + simple-get "^4.0.1" + tar-fs "^2.1.1" + tunnel-agent "^0.6.0" + shebang-command@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" From 96402be5ed783ae078dd186fcdd30141b67d4469 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 14 Apr 2022 09:03:43 +0000 Subject: [PATCH 166/240] build(deps): bump gatsby-plugin-postcss in /packages/website Bumps [gatsby-plugin-postcss](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-postcss) from 5.10.0 to 5.12.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-postcss/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-postcss@5.12.1/packages/gatsby-plugin-postcss) --- updated-dependencies: - dependency-name: gatsby-plugin-postcss dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 877daf5a..3c501d27 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -17,7 +17,7 @@ "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.11.1", "gatsby-plugin-manifest": "4.11.1", - "gatsby-plugin-postcss": "5.10.0", + "gatsby-plugin-postcss": "5.12.1", "gatsby-plugin-react-helmet": "5.10.0", "gatsby-plugin-robots-txt": "1.7.1", "gatsby-plugin-sharp": "4.10.2", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index b3a56aba..c53de30a 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6339,10 +6339,10 @@ gatsby-plugin-page-creator@^4.11.1: globby "^11.0.4" lodash "^4.17.21" -gatsby-plugin-postcss@5.10.0: - version "5.10.0" - resolved "https://registry.yarnpkg.com/gatsby-plugin-postcss/-/gatsby-plugin-postcss-5.10.0.tgz#e241f1671e66f7b660826f39fd26591aae652716" - integrity sha512-s1zzysu1kKIqR+CfQeQsG0CCdj2S7tjc4BhCY2a3V4cl7ORJtMx1HGKDUzE9gV/EXRTmr9lhE9Gl+2v8fRouvA== +gatsby-plugin-postcss@5.12.1: + version "5.12.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-postcss/-/gatsby-plugin-postcss-5.12.1.tgz#8be5cf7bbfbb27967cad2c5da8dbe1b8c7e576b8" + integrity sha512-gNfMl/ZWCZpnCsy+IPzRPzqaPPStbUr/LG8eikGbyoZj1gSjom/a7Hi3z29sWx/vEd4dAHGRPS+n7bjf3iOnNw== dependencies: "@babel/runtime" "^7.15.4" postcss-loader "^4.3.0" From bfae3dc9aec8f59877179dec0bf4deb6dd9e466a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 14 Apr 2022 09:36:51 +0000 Subject: [PATCH 167/240] build(deps): bump gatsby-plugin-sharp in /packages/website Bumps [gatsby-plugin-sharp](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-sharp) from 4.10.2 to 4.12.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-sharp/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-sharp@4.12.1/packages/gatsby-plugin-sharp) --- updated-dependencies: - dependency-name: gatsby-plugin-sharp dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 60 ++++++++++++++--------------------- 2 files changed, 24 insertions(+), 38 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index cbc2f83e..b85b4d13 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -20,7 +20,7 @@ "gatsby-plugin-postcss": "5.12.1", "gatsby-plugin-react-helmet": "5.10.0", "gatsby-plugin-robots-txt": "1.7.1", - "gatsby-plugin-sharp": "4.10.2", + "gatsby-plugin-sharp": "4.12.1", "gatsby-plugin-sitemap": "5.11.1", "gatsby-plugin-svgr": "3.0.0-beta.0", "gatsby-source-filesystem": "4.10.1", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 7437470d..046620e4 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -4710,10 +4710,10 @@ debug@^3.0.0, debug@^3.1.0, debug@^3.2.6, debug@^3.2.7: dependencies: ms "^2.1.1" -debug@^4.0.1, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2, debug@^4.3.3, debug@~4.3.1: - version "4.3.3" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.3.tgz#04266e0b70a98d4462e6e288e38259213332b664" - integrity sha512-/zxw5+vh1Tfv+4Qn7a5nsbcJKPaSvCDhojn6FEl9vupwK2VCSDtEiEtqr8DFtzYFOdz63LBkxec7DYuc2jon6Q== +debug@^4.0.1, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2, debug@^4.3.4, debug@~4.3.1: + version "4.3.4" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" + integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== dependencies: ms "2.1.2" @@ -6362,28 +6362,28 @@ gatsby-plugin-robots-txt@1.7.1: "@babel/runtime" "^7.16.7" generate-robotstxt "^8.0.3" -gatsby-plugin-sharp@4.10.2: - version "4.10.2" - resolved "https://registry.yarnpkg.com/gatsby-plugin-sharp/-/gatsby-plugin-sharp-4.10.2.tgz#253a49c452a7409ceece4e541e4770e61a306bcc" - integrity sha512-MWzPTYnu7HZ0kctHtkLbZOe6ZGUqSsNATO3lWlSBIFpeimxaPF5iHBiu1CX/ofz4pwt7VamtIzAV28VB6sjONw== +gatsby-plugin-sharp@4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-sharp/-/gatsby-plugin-sharp-4.12.1.tgz#f97cb29074f4a07b469b9ddb1058a3574928d4eb" + integrity sha512-P6noUl5LyASwYtCRSo1rjchk/ytfJvSFTLwzgXr1TiQHgZh06SUIqR8v3UqT90EDERNd1GeEBsQjRfWkrV2nbg== dependencies: "@babel/runtime" "^7.15.4" async "^3.2.3" bluebird "^3.7.2" - debug "^4.3.3" + debug "^4.3.4" filenamify "^4.3.0" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.1" - gatsby-plugin-utils "^3.4.2" - gatsby-telemetry "^3.10.1" + gatsby-core-utils "^3.12.1" + gatsby-plugin-utils "^3.6.1" + gatsby-telemetry "^3.12.1" got "^11.8.3" lodash "^4.17.21" - mini-svg-data-uri "^1.4.3" + mini-svg-data-uri "^1.4.4" potrace "^2.1.8" - probe-image-size "^7.0.0" + probe-image-size "^7.2.3" progress "^2.0.3" semver "^7.3.5" - sharp "^0.30.1" + sharp "^0.30.3" svgo "1.3.2" uuid "3.4.0" @@ -6415,7 +6415,7 @@ gatsby-plugin-typescript@^4.12.1: "@babel/runtime" "^7.15.4" babel-plugin-remove-graphql-queries "^4.12.1" -gatsby-plugin-utils@^3.4.2, gatsby-plugin-utils@^3.5.1, gatsby-plugin-utils@^3.6.1: +gatsby-plugin-utils@^3.5.1, gatsby-plugin-utils@^3.6.1: version "3.6.1" resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.6.1.tgz#31d742e1aded08439ad42959880821e1fc9740cd" integrity sha512-Ebk98v4mxaDWjGFl6VBeNv1zjeJ7UCQ29UTabzY2BpztvUCBHfLVQdMmuaAgzPRn+A3SFVOGpcl++CF0IEl+7A== @@ -6463,7 +6463,7 @@ gatsby-source-filesystem@4.10.1: valid-url "^1.0.9" xstate "^4.26.1" -gatsby-telemetry@^3.10.1, gatsby-telemetry@^3.12.1: +gatsby-telemetry@^3.12.1: version "3.12.1" resolved "https://registry.yarnpkg.com/gatsby-telemetry/-/gatsby-telemetry-3.12.1.tgz#a3508a45d95f2c3457db7dbe2628560d00c43beb" integrity sha512-sAL2T9GdYpceGlFP6CymVDoy0UEhRvrJApv/mu7sU6F0gu8g8rOLvRxVYE3Y2D9RdfCzkuLIonzmscmVIduyOg== @@ -8717,10 +8717,10 @@ mini-css-extract-plugin@1.6.2: schema-utils "^3.0.0" webpack-sources "^1.1.0" -mini-svg-data-uri@^1.4.3: - version "1.4.3" - resolved "https://registry.yarnpkg.com/mini-svg-data-uri/-/mini-svg-data-uri-1.4.3.tgz#43177b2e93766ba338931a3e2a84a3dfd3a222b8" - integrity sha512-gSfqpMRC8IxghvMcxzzmMnWpXAChSA+vy4cia33RgerMS8Fex95akUyQZPbxJJmeBGiGmK7n/1OpUX8ksRjIdA== +mini-svg-data-uri@^1.4.4: + version "1.4.4" + resolved "https://registry.yarnpkg.com/mini-svg-data-uri/-/mini-svg-data-uri-1.4.4.tgz#8ab0aabcdf8c29ad5693ca595af19dd2ead09939" + integrity sha512-r9deDe9p5FJUPZAk3A59wGH7Ii9YrjjWw0jmw/liSbHl2CHiyXj6FcDXDu2K3TjVAXqiJdaw3xxwlZZr9E6nHg== minimalistic-assert@^1.0.0, minimalistic-assert@^1.0.1: version "1.0.1" @@ -9983,7 +9983,7 @@ pretty-error@^2.1.2: lodash "^4.17.20" renderkid "^2.0.4" -probe-image-size@^7.0.0: +probe-image-size@^7.0.0, probe-image-size@^7.2.3: version "7.2.3" resolved "https://registry.yarnpkg.com/probe-image-size/-/probe-image-size-7.2.3.tgz#d49c64be540ec8edea538f6f585f65a9b3ab4309" integrity sha512-HubhG4Rb2UH8YtV4ba0Vp5bQ7L78RTONYu/ujmCu5nBI8wGv24s4E9xSKBi0N1MowRpxk76pFCpJtW0KPzOK0w== @@ -10911,21 +10911,7 @@ shallow-compare@^1.2.2: resolved "https://registry.yarnpkg.com/shallow-compare/-/shallow-compare-1.2.2.tgz#fa4794627bf455a47c4f56881d8a6132d581ffdb" integrity sha512-LUMFi+RppPlrHzbqmFnINTrazo0lPNwhcgzuAXVVcfy/mqPDrQmHAyz5bvV0gDAuRFrk804V0HpQ6u9sZ0tBeg== -sharp@^0.30.1: - version "0.30.2" - resolved "https://registry.yarnpkg.com/sharp/-/sharp-0.30.2.tgz#95b309b2740424702dc19b62a62595dd34a458b1" - integrity sha512-mrMeKI5ECTdYhslPlA2TbBtU3nZXMEBcQwI6qYXjPlu1LpW4HBZLFm6xshMI1HpIdEEJ3UcYp5AKifLT/fEHZQ== - dependencies: - color "^4.2.1" - detect-libc "^2.0.1" - node-addon-api "^4.3.0" - prebuild-install "^7.0.1" - semver "^7.3.5" - simple-get "^4.0.1" - tar-fs "^2.1.1" - tunnel-agent "^0.6.0" - -sharp@^0.30.3: +sharp@^0.30.1, sharp@^0.30.3: version "0.30.3" resolved "https://registry.yarnpkg.com/sharp/-/sharp-0.30.3.tgz#315a1817423a4d1cde5119a21c99c234a7a6fb37" integrity sha512-rjpfJFK58ZOFSG8sxYSo3/JQb4ej095HjXp9X7gVu7gEn1aqSG8TCW29h/Rr31+PXrFADo1H/vKfw0uhMQWFtg== From ed3850bb77edaed3cf016eae4e7f4e7ec245dfb9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 14 Apr 2022 09:36:52 +0000 Subject: [PATCH 168/240] build(deps): bump framer-motion in /packages/website Bumps [framer-motion](https://github.com/framer/motion) from 6.2.8 to 6.2.10. - [Release notes](https://github.com/framer/motion/releases) - [Changelog](https://github.com/framer/motion/blob/main/CHANGELOG.md) - [Commits](https://github.com/framer/motion/compare/v6.2.8...v6.2.10) --- updated-dependencies: - dependency-name: framer-motion dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index cbc2f83e..7b6494cf 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -12,7 +12,7 @@ "classnames": "2.3.1", "copy-text-to-clipboard": "3.0.1", "crypto-browserify": "3.12.0", - "framer-motion": "6.2.8", + "framer-motion": "6.2.10", "gatsby": "4.12.1", "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.11.1", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 7437470d..3f805ae3 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6068,10 +6068,10 @@ fragment-cache@^0.2.1: dependencies: map-cache "^0.2.2" -framer-motion@6.2.8: - version "6.2.8" - resolved "https://registry.yarnpkg.com/framer-motion/-/framer-motion-6.2.8.tgz#02abb529191af7e2df444185fe27e932215b715d" - integrity sha512-4PtBWFJ6NqR350zYVt9AsFDtISTqsdqna79FvSYPfYDXuuqFmiKtZdkTnYPslnsOMedTW0pEvaQ7eqjD+sA+HA== +framer-motion@6.2.10: + version "6.2.10" + resolved "https://registry.yarnpkg.com/framer-motion/-/framer-motion-6.2.10.tgz#7fb300d4c559f0991be5499f99d055a04851fcb3" + integrity sha512-nfkpA5r3leVOYJH0YXV1cMOLNJuAoznR3Cswet5wCIDi7AZwS62N+u0EmGSNG1JHtglDo5erqyamc55M2XICvA== dependencies: framesync "6.0.1" hey-listen "^1.0.8" From 47e8abd5324cd63e804d77f205806adfba35238a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 14 Apr 2022 09:37:04 +0000 Subject: [PATCH 169/240] build(deps-dev): bump tailwindcss in /packages/website Bumps [tailwindcss](https://github.com/tailwindlabs/tailwindcss) from 3.0.23 to 3.0.24. - [Release notes](https://github.com/tailwindlabs/tailwindcss/releases) - [Changelog](https://github.com/tailwindlabs/tailwindcss/blob/master/CHANGELOG.md) - [Commits](https://github.com/tailwindlabs/tailwindcss/compare/v3.0.23...v3.0.24) --- updated-dependencies: - dependency-name: tailwindcss dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 56 +++++++++++++++++------------------ 2 files changed, 29 insertions(+), 29 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index cbc2f83e..1cab4c79 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -50,7 +50,7 @@ "cross-env": "7.0.3", "cypress": "9.5.2", "prettier": "2.6.2", - "tailwindcss": "3.0.23" + "tailwindcss": "3.0.24" }, "keywords": [ "gatsby" diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 7437470d..a0c88f8d 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -8072,10 +8072,10 @@ levn@^0.4.1: prelude-ls "^1.2.1" type-check "~0.4.0" -lilconfig@^2.0.3, lilconfig@^2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/lilconfig/-/lilconfig-2.0.4.tgz#f4507d043d7058b380b6a8f5cb7bcd4b34cee082" - integrity sha512-bfTIN7lEsiooCocSISTWXkiWJkRqtL9wYtYy+8EK3Y41qh3mpwPU0ycTOgjdY9ErwXCc8QyrQp82bdL0Xkm9yA== +lilconfig@^2.0.3, lilconfig@^2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/lilconfig/-/lilconfig-2.0.5.tgz#19e57fd06ccc3848fd1891655b5a447092225b25" + integrity sha512-xaYmXZtTHPAw5m+xLN8ab9C+3a8YmV3asNSPOATITbtwrfbwaLJj8h66H1WMIpALCkqsIzK3h7oQ+PdX+LQ9Eg== lines-and-columns@^1.1.6: version "1.2.4" @@ -9105,10 +9105,10 @@ object-copy@^0.1.0: define-property "^0.2.5" kind-of "^3.0.3" -object-hash@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/object-hash/-/object-hash-2.2.0.tgz#5ad518581eefc443bd763472b8ff2e9c2c0d54a5" - integrity sha512-gScRMn0bS5fH+IuwyIFgnh9zBdo4DV+6GhygmWM9HyNJSgS0hScp1f5vjtm7oIIOiT9trXrShAkLFSc2IqKNgw== +object-hash@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/object-hash/-/object-hash-3.0.0.tgz#73f97f753e7baffc0e2cc9d6e079079744ac82e9" + integrity sha512-RSn9F68PjH9HqtltsSnqYC1XXoWe9Bju5+213R98cNGttag9q9yAOTzdbsqvIa7aNm5WffBZFpWYr2aWrklWAw== object-inspect@^1.11.0, object-inspect@^1.9.0: version "1.12.0" @@ -9693,12 +9693,12 @@ postcss-js@^4.0.0: dependencies: camelcase-css "^2.0.1" -postcss-load-config@^3.1.0: - version "3.1.3" - resolved "https://registry.yarnpkg.com/postcss-load-config/-/postcss-load-config-3.1.3.tgz#21935b2c43b9a86e6581a576ca7ee1bde2bd1d23" - integrity sha512-5EYgaM9auHGtO//ljHH+v/aC/TQ5LHXtL7bQajNAUBKUVKiYE8rYpFms7+V26D9FncaGe2zwCoPQsFKb5zF/Hw== +postcss-load-config@^3.1.4: + version "3.1.4" + resolved "https://registry.yarnpkg.com/postcss-load-config/-/postcss-load-config-3.1.4.tgz#1ab2571faf84bb078877e1d07905eabe9ebda855" + integrity sha512-6DiM4E7v4coTE4uzA8U//WhtPwyhiim3eyjEMFCnUpzbrkK9wJHgKDT2mR+HbtSrd/NubVaYTOpSpjUl8NQeRg== dependencies: - lilconfig "^2.0.4" + lilconfig "^2.0.5" yaml "^1.10.2" postcss-loader@^4.3.0: @@ -9892,10 +9892,10 @@ postcss-reduce-transforms@^5.1.0: dependencies: postcss-value-parser "^4.2.0" -postcss-selector-parser@^6.0.2, postcss-selector-parser@^6.0.4, postcss-selector-parser@^6.0.5, postcss-selector-parser@^6.0.6, postcss-selector-parser@^6.0.9: - version "6.0.9" - resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-6.0.9.tgz#ee71c3b9ff63d9cd130838876c13a2ec1a992b2f" - integrity sha512-UO3SgnZOVTwu4kyLR22UQ1xZh086RyNZppb7lLAKBFK8a32ttG5i87Y/P3+2bRSjZNyJ1B7hfFNo273tKe9YxQ== +postcss-selector-parser@^6.0.10, postcss-selector-parser@^6.0.2, postcss-selector-parser@^6.0.4, postcss-selector-parser@^6.0.5, postcss-selector-parser@^6.0.6, postcss-selector-parser@^6.0.9: + version "6.0.10" + resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-6.0.10.tgz#79b61e2c0d1bfc2602d549e11d0876256f8df88d" + integrity sha512-IQ7TZdoaqbT+LCpShg46jnZVlhWD2w6iQYAcYXfHARZ7X1t/UGhhceQDs5X0cGqKvYlHNOuv7Oa1xmb0oQuA3w== dependencies: cssesc "^3.0.0" util-deprecate "^1.0.2" @@ -9920,7 +9920,7 @@ postcss-value-parser@^4.1.0, postcss-value-parser@^4.2.0: resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz#723c09920836ba6d3e5af019f92bc0971c02e514" integrity sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ== -postcss@8.4.12, postcss@^8.2.15, postcss@^8.2.9, postcss@^8.3.11, postcss@^8.4.6: +postcss@8.4.12, postcss@^8.2.15, postcss@^8.2.9, postcss@^8.3.11, postcss@^8.4.12: version "8.4.12" resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.12.tgz#1e7de78733b28970fa4743f7da6f3763648b1905" integrity sha512-lg6eITwYe9v6Hr5CncVbK70SoioNQIq81nsaG86ev5hAidQvmOeETBqs7jm43K2F5/Ley3ytDtriImV6TpNiSg== @@ -11680,29 +11680,29 @@ table@^6.0.9: string-width "^4.2.3" strip-ansi "^6.0.1" -tailwindcss@3.0.23: - version "3.0.23" - resolved "https://registry.yarnpkg.com/tailwindcss/-/tailwindcss-3.0.23.tgz#c620521d53a289650872a66adfcb4129d2200d10" - integrity sha512-+OZOV9ubyQ6oI2BXEhzw4HrqvgcARY38xv3zKcjnWtMIZstEsXdI9xftd1iB7+RbOnj2HOEzkA0OyB5BaSxPQA== +tailwindcss@3.0.24: + version "3.0.24" + resolved "https://registry.yarnpkg.com/tailwindcss/-/tailwindcss-3.0.24.tgz#22e31e801a44a78a1d9a81ecc52e13b69d85704d" + integrity sha512-H3uMmZNWzG6aqmg9q07ZIRNIawoiEcNFKDfL+YzOPuPsXuDXxJxB9icqzLgdzKNwjG3SAro2h9SYav8ewXNgig== dependencies: arg "^5.0.1" - chalk "^4.1.2" chokidar "^3.5.3" color-name "^1.1.4" - cosmiconfig "^7.0.1" detective "^5.2.0" didyoumean "^1.2.2" dlv "^1.1.3" fast-glob "^3.2.11" glob-parent "^6.0.2" is-glob "^4.0.3" + lilconfig "^2.0.5" normalize-path "^3.0.0" - object-hash "^2.2.0" - postcss "^8.4.6" + object-hash "^3.0.0" + picocolors "^1.0.0" + postcss "^8.4.12" postcss-js "^4.0.0" - postcss-load-config "^3.1.0" + postcss-load-config "^3.1.4" postcss-nested "5.0.6" - postcss-selector-parser "^6.0.9" + postcss-selector-parser "^6.0.10" postcss-value-parser "^4.2.0" quick-lru "^5.1.1" resolve "^1.22.0" From ad090fd1ff9a8cf88a84e58fef67904d1c394785 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 14 Apr 2022 15:58:01 +0200 Subject: [PATCH 170/240] pass skylink from request context to /user/limits --- docker/nginx/libs/skynet/account.lua | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/docker/nginx/libs/skynet/account.lua b/docker/nginx/libs/skynet/account.lua index 56c99897..709d8130 100644 --- a/docker/nginx/libs/skynet/account.lua +++ b/docker/nginx/libs/skynet/account.lua @@ -76,9 +76,16 @@ function _M.get_account_limits() if ngx.var.account_limits == "" then local httpc = require("resty.http").new() + local uri = "http://10.10.10.70:3000/user/limits" + + -- include skylink if it is available in the context of request + -- todo: this should not rely on skylink variable to be defined + if ngx.var.skylink ~= nil and ngx.var.skylink ~= "" then + uri = uri .. "/" .. ngx.var.skylink + end -- 10.10.10.70 points to accounts service (alias not available when using resty-http) - local res, err = httpc:request_uri("http://10.10.10.70:3000/user/limits?unit=byte", { + local res, err = httpc:request_uri(uri .. "?unit=byte", { headers = auth_headers, }) From 1e713c61c9ec0044bcda215e7b6b0d21975aa4be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 14 Apr 2022 18:29:07 +0200 Subject: [PATCH 171/240] fix(dashboard-v2): fix current usage graph on portals without Stripe configured --- .../src/components/CurrentUsage/CurrentUsage.js | 10 ++++++++-- .../src/components/CurrentUsage/GraphBar.js | 4 ++-- .../src/components/CurrentUsage/UsageGraph.js | 4 +++- .../src/contexts/plans/PlansProvider.js | 15 ++++++++++++--- packages/dashboard-v2/src/hooks/useActivePlan.js | 1 + 5 files changed, 26 insertions(+), 8 deletions(-) diff --git a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js index 3947638d..f9dbbc36 100644 --- a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js +++ b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js @@ -1,6 +1,7 @@ import { useEffect, useMemo, useState } from "react"; import fileSize from "pretty-bytes"; import { Link } from "gatsby"; +import cn from "classnames"; import useSWR from "swr"; import { useUser } from "../../contexts/user"; @@ -62,7 +63,9 @@ const ErrorMessage = () => ( ); export default function CurrentUsage() { + const { activePlan, plans } = useActivePlan(); const { usage, error, loading } = useUsageData(); + const nextPlan = useMemo(() => plans.find(({ tier }) => tier > activePlan?.tier), [plans, activePlan]); const storageUsage = size(usage.storageUsed); const storageLimit = size(usage.storageLimit); const filesUsedLabel = useMemo(() => ({ value: usage.filesUsed, unit: "files" }), [usage.filesUsed]); @@ -89,7 +92,7 @@ export default function CurrentUsage() { {storageLimit.text}
    - +
    @@ -97,7 +100,10 @@ export default function CurrentUsage() { UPGRADE {" "} diff --git a/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js b/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js index 1afab541..fd9a015e 100644 --- a/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js +++ b/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js @@ -21,11 +21,11 @@ const BarLabel = styled.span.attrs({ `} `; -export const GraphBar = ({ value, limit, label }) => { +export const GraphBar = ({ value, limit, label, className }) => { const percentage = typeof limit !== "number" || limit === 0 ? 0 : (value / limit) * 100; return ( -
    +
    diff --git a/packages/dashboard-v2/src/components/CurrentUsage/UsageGraph.js b/packages/dashboard-v2/src/components/CurrentUsage/UsageGraph.js index 3f6f23c2..de4e7e46 100644 --- a/packages/dashboard-v2/src/components/CurrentUsage/UsageGraph.js +++ b/packages/dashboard-v2/src/components/CurrentUsage/UsageGraph.js @@ -1,9 +1,11 @@ import styled from "styled-components"; +import usageGraphBg from "../../../static/images/usage-graph-bg.svg"; + export const UsageGraph = styled.div.attrs({ className: "w-full my-3 grid grid-flow-row grid-rows-2", })` height: 146px; - background: url(/images/usage-graph-bg.svg) no-repeat; + background: url(${usageGraphBg}) no-repeat; background-size: cover; `; diff --git a/packages/dashboard-v2/src/contexts/plans/PlansProvider.js b/packages/dashboard-v2/src/contexts/plans/PlansProvider.js index 135c9bcb..7c6579ad 100644 --- a/packages/dashboard-v2/src/contexts/plans/PlansProvider.js +++ b/packages/dashboard-v2/src/contexts/plans/PlansProvider.js @@ -19,7 +19,14 @@ const aggregatePlansAndLimits = (plans, limits, { includeFreePlan }) => { // Decorate each plan with its corresponding limits data, if available. if (limits?.length) { - return sortedPlans.map((plan) => ({ ...plan, limits: limits[plan.tier] || null })); + return limits.map((limitsDescriptor, index) => { + const asssociatedPlan = sortedPlans.find((plan) => plan.tier === index) || {}; + + return { + ...asssociatedPlan, + limits: limitsDescriptor || null, + }; + }); } // If we don't have the limits data yet, set just return the plans. @@ -40,10 +47,12 @@ export const PlansProvider = ({ children }) => { if (plansError || limitsError) { setLoading(false); setError(plansError || limitsError); - } else if (rawPlans) { + } else if (rawPlans || limits) { setLoading(false); setPlans( - aggregatePlansAndLimits(rawPlans, limits?.userLimits, { includeFreePlan: !settings.isSubscriptionRequired }) + aggregatePlansAndLimits(rawPlans || [], limits?.userLimits, { + includeFreePlan: !settings.isSubscriptionRequired, + }) ); } }, [rawPlans, limits, plansError, limitsError, settings.isSubscriptionRequired]); diff --git a/packages/dashboard-v2/src/hooks/useActivePlan.js b/packages/dashboard-v2/src/hooks/useActivePlan.js index de71a036..e843f510 100644 --- a/packages/dashboard-v2/src/hooks/useActivePlan.js +++ b/packages/dashboard-v2/src/hooks/useActivePlan.js @@ -10,6 +10,7 @@ export default function useActivePlan(user) { useEffect(() => { if (user) { + console.log("setActivePlan"); setActivePlan(plans.find((plan) => plan.tier === user.tier)); } }, [plans, user]); From e4fe4dd9015bc1e41db89f020c708f5411201d42 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 14 Apr 2022 18:30:27 +0200 Subject: [PATCH 172/240] ops(dashboard-v2): publish new dashboard under /v2 prefix --- docker/nginx/conf.d/server/server.account | 4 ++++ packages/dashboard-v2/gatsby-config.js | 1 + packages/dashboard-v2/package.json | 4 ++-- .../src/components/AvatarUploader/AvatarUploader.js | 6 +++--- packages/dashboard-v2/src/layouts/AuthLayout.js | 7 +++++-- packages/dashboard-v2/src/layouts/DashboardLayout.js | 4 +++- .../dashboard-v2/src/pages/settings/developer-settings.js | 4 +++- packages/dashboard-v2/src/pages/settings/export.js | 4 +++- packages/dashboard-v2/src/pages/settings/notifications.js | 7 ++++--- 9 files changed, 28 insertions(+), 13 deletions(-) diff --git a/docker/nginx/conf.d/server/server.account b/docker/nginx/conf.d/server/server.account index 127ba4bf..9737003d 100644 --- a/docker/nginx/conf.d/server/server.account +++ b/docker/nginx/conf.d/server/server.account @@ -3,6 +3,10 @@ listen 443 ssl http2; include /etc/nginx/conf.d/include/ssl-settings; include /etc/nginx/conf.d/include/init-optional-variables; +location /v2 { + proxy_pass http://dashboard-v2:9000; +} + location / { proxy_pass http://dashboard:3000; } diff --git a/packages/dashboard-v2/gatsby-config.js b/packages/dashboard-v2/gatsby-config.js index 0e269557..d087fa65 100644 --- a/packages/dashboard-v2/gatsby-config.js +++ b/packages/dashboard-v2/gatsby-config.js @@ -11,6 +11,7 @@ module.exports = { title: `Account Dashboard`, siteUrl: `https://account.${GATSBY_PORTAL_DOMAIN}`, }, + pathPrefix: "/v2", trailingSlash: "never", plugins: [ "gatsby-plugin-image", diff --git a/packages/dashboard-v2/package.json b/packages/dashboard-v2/package.json index 694a6129..80070815 100644 --- a/packages/dashboard-v2/package.json +++ b/packages/dashboard-v2/package.json @@ -11,8 +11,8 @@ "develop": "gatsby develop", "develop:secure": "dotenv -e .env.development -- gatsby develop --https -p=443", "start": "gatsby develop", - "build": "gatsby build", - "serve": "gatsby serve", + "build": "gatsby build --prefix-paths", + "serve": "gatsby serve --prefix-paths", "clean": "gatsby clean", "lint": "eslint .", "prettier": "prettier .", diff --git a/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js b/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js index 2a3e400d..f97ca2d5 100644 --- a/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js +++ b/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js @@ -3,14 +3,14 @@ import { useEffect, useState } from "react"; import { useUser } from "../../contexts/user"; // import { SimpleUploadIcon } from "../Icons"; -const AVATAR_PLACEHOLDER = "/images/avatar-placeholder.svg"; +import avatarPlaceholder from "../../../static/images/avatar-placeholder.svg"; export const AvatarUploader = (props) => { const { user } = useUser(); - const [imageUrl, setImageUrl] = useState(AVATAR_PLACEHOLDER); + const [imageUrl, setImageUrl] = useState(avatarPlaceholder); useEffect(() => { - setImageUrl(user.avatarUrl ?? AVATAR_PLACEHOLDER); + setImageUrl(user.avatarUrl ?? avatarPlaceholder); }, [user]); return ( diff --git a/packages/dashboard-v2/src/layouts/AuthLayout.js b/packages/dashboard-v2/src/layouts/AuthLayout.js index 8141e606..323e4319 100644 --- a/packages/dashboard-v2/src/layouts/AuthLayout.js +++ b/packages/dashboard-v2/src/layouts/AuthLayout.js @@ -3,10 +3,13 @@ import styled from "styled-components"; import { UserProvider } from "../contexts/user"; +import skynetLogo from "../../static/images/logo-black-text.svg"; +import authBg from "../../static/images/auth-bg.svg"; + const Layout = styled.div.attrs({ className: "min-h-screen w-screen bg-black flex", })` - background-image: url(/images/auth-bg.svg); + background-image: url(${authBg}); background-repeat: no-repeat; background-position: center center; `; @@ -36,7 +39,7 @@ const AuthLayout =
    - Skynet + Skynet
    {children}
    diff --git a/packages/dashboard-v2/src/layouts/DashboardLayout.js b/packages/dashboard-v2/src/layouts/DashboardLayout.js index 633057eb..8ac7c393 100644 --- a/packages/dashboard-v2/src/layouts/DashboardLayout.js +++ b/packages/dashboard-v2/src/layouts/DashboardLayout.js @@ -7,10 +7,12 @@ import { Footer } from "../components/Footer"; import { UserProvider, useUser } from "../contexts/user"; import { FullScreenLoadingIndicator } from "../components/LoadingIndicator"; +import dashboardBg from "../../static/images/dashboard-bg.svg"; + const Wrapper = styled.div.attrs({ className: "min-h-screen overflow-hidden", })` - background-image: url(/images/dashboard-bg.svg); + background-image: url(${dashboardBg}); background-position: center -280px; background-repeat: no-repeat; `; diff --git a/packages/dashboard-v2/src/pages/settings/developer-settings.js b/packages/dashboard-v2/src/pages/settings/developer-settings.js index cb58ab51..3f1917c1 100644 --- a/packages/dashboard-v2/src/pages/settings/developer-settings.js +++ b/packages/dashboard-v2/src/pages/settings/developer-settings.js @@ -10,6 +10,8 @@ import { AddSponsorKeyForm } from "../../components/forms/AddSponsorKeyForm"; import { Metadata } from "../../components/Metadata"; import HighlightedLink from "../../components/HighlightedLink"; +import apiKeysImg from "../../../static/images/api-keys.svg"; + const DeveloperSettingsPage = () => { const { data: allKeys = [], mutate: reloadKeys, error } = useSWR("user/apikeys"); const apiKeys = allKeys.filter(({ public: isPublic }) => isPublic === "false"); @@ -103,7 +105,7 @@ const DeveloperSettingsPage = () => {
    - +
    diff --git a/packages/dashboard-v2/src/pages/settings/export.js b/packages/dashboard-v2/src/pages/settings/export.js index 437f2b2f..aeb8aed3 100644 --- a/packages/dashboard-v2/src/pages/settings/export.js +++ b/packages/dashboard-v2/src/pages/settings/export.js @@ -6,6 +6,8 @@ import { Switch } from "../../components/Switch"; import { Button } from "../../components/Button"; import { Metadata } from "../../components/Metadata"; +import exportImg from "../../../static/images/import-export.svg"; + const useExportOptions = () => { const [pinnedFiles, setPinnedFiles] = useState(false); const [uploadHistory, setUploadHistory] = useState(false); @@ -65,7 +67,7 @@ const ExportPage = () => {
  • - +
    diff --git a/packages/dashboard-v2/src/pages/settings/notifications.js b/packages/dashboard-v2/src/pages/settings/notifications.js index fc109d5c..5467f3a5 100644 --- a/packages/dashboard-v2/src/pages/settings/notifications.js +++ b/packages/dashboard-v2/src/pages/settings/notifications.js @@ -1,11 +1,12 @@ import * as React from "react"; -import { StaticImage } from "gatsby-plugin-image"; import UserSettingsLayout from "../../layouts/UserSettingsLayout"; import { Switch } from "../../components/Switch"; import { Metadata } from "../../components/Metadata"; +import inboxImg from "../../../static/images/inbox.svg"; + const NotificationsPage = () => { return ( <> @@ -37,8 +38,8 @@ const NotificationsPage = () => {
    -
    - +
    +
    From babb6a48ad5dd2e6154908995a5583141c64eef1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 14 Apr 2022 18:33:39 +0200 Subject: [PATCH 173/240] ops(dashboard-v2): fix SkynetClient on multi-server portals --- packages/dashboard-v2/src/services/skynetClient.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/dashboard-v2/src/services/skynetClient.js b/packages/dashboard-v2/src/services/skynetClient.js index a01e96f9..cb236ade 100644 --- a/packages/dashboard-v2/src/services/skynetClient.js +++ b/packages/dashboard-v2/src/services/skynetClient.js @@ -1,3 +1,6 @@ import { SkynetClient } from "skynet-js"; -export default new SkynetClient(`https://${process.env.GATSBY_PORTAL_DOMAIN}`); +const { NODE_ENV, GATSBY_PORTAL_DOMAIN } = process.env; + +// In production-like environment, let SkynetClient figure out the best portal +export default new SkynetClient(NODE_ENV === "development" ? `https://${GATSBY_PORTAL_DOMAIN}` : undefined); From 03c9fe01b238e113a3daac243cb81e914ef0c475 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 14 Apr 2022 18:34:16 +0200 Subject: [PATCH 174/240] fix(dashboard-v2): fix skylinks validation for sponsor keys --- packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js b/packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js index 0f8b8c62..236cdc9b 100644 --- a/packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js +++ b/packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js @@ -80,7 +80,7 @@ export const AddSponsorKeyForm = forwardRef(({ onSuccess }, ref) => { json: { name, public: "true", - skylinks: [...skylinks, nextSkylink].filter(Boolean).map(parseSkylink), + skylinks: [...skylinks, nextSkylink].filter(Boolean).map((skylink) => parseSkylink(skylink)), }, }) .json(); From 77d3145c0bc771ec54e39aa52842df9943ee4c37 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 14 Apr 2022 18:37:30 +0200 Subject: [PATCH 175/240] ops(dashboard-v2): don't actually launch the new dashboard yet :) --- docker/nginx/conf.d/server/server.account | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/docker/nginx/conf.d/server/server.account b/docker/nginx/conf.d/server/server.account index 9737003d..9d444296 100644 --- a/docker/nginx/conf.d/server/server.account +++ b/docker/nginx/conf.d/server/server.account @@ -3,9 +3,10 @@ listen 443 ssl http2; include /etc/nginx/conf.d/include/ssl-settings; include /etc/nginx/conf.d/include/init-optional-variables; -location /v2 { - proxy_pass http://dashboard-v2:9000; -} +# Uncomment to launch new Dashboard under /v2 path +# location /v2 { +# proxy_pass http://dashboard-v2:9000; +# } location / { proxy_pass http://dashboard:3000; From d6fe2d2f1d875481af84b7b4408a1f43e6a1bc12 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Thu, 14 Apr 2022 18:41:20 +0200 Subject: [PATCH 176/240] chore(dashboard-v2): cleanup console.log call --- packages/dashboard-v2/src/hooks/useActivePlan.js | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/dashboard-v2/src/hooks/useActivePlan.js b/packages/dashboard-v2/src/hooks/useActivePlan.js index e843f510..de71a036 100644 --- a/packages/dashboard-v2/src/hooks/useActivePlan.js +++ b/packages/dashboard-v2/src/hooks/useActivePlan.js @@ -10,7 +10,6 @@ export default function useActivePlan(user) { useEffect(() => { if (user) { - console.log("setActivePlan"); setActivePlan(plans.find((plan) => plan.tier === user.tier)); } }, [plans, user]); From 7248147ba72f127f6f37094dbad1404d53669c65 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 15 Apr 2022 16:19:04 +0200 Subject: [PATCH 177/240] fix(dashboard-v2): always set portal domain for SkynetClient --- packages/dashboard-v2/src/services/skynetClient.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/packages/dashboard-v2/src/services/skynetClient.js b/packages/dashboard-v2/src/services/skynetClient.js index cb236ade..a01e96f9 100644 --- a/packages/dashboard-v2/src/services/skynetClient.js +++ b/packages/dashboard-v2/src/services/skynetClient.js @@ -1,6 +1,3 @@ import { SkynetClient } from "skynet-js"; -const { NODE_ENV, GATSBY_PORTAL_DOMAIN } = process.env; - -// In production-like environment, let SkynetClient figure out the best portal -export default new SkynetClient(NODE_ENV === "development" ? `https://${GATSBY_PORTAL_DOMAIN}` : undefined); +export default new SkynetClient(`https://${process.env.GATSBY_PORTAL_DOMAIN}`); From 916a420b720cb03a6a01391078bb81c038fe2e10 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 15 Apr 2022 16:01:52 +0200 Subject: [PATCH 178/240] refactor(dashboard-v2): replace pretty-bytes with in-house solution --- packages/dashboard-v2/package.json | 1 - .../src/components/CurrentPlan/CurrentPlan.js | 4 ++-- .../components/CurrentUsage/CurrentUsage.js | 4 ++-- .../FileList/useFormattedFilesData.js | 4 ++-- .../src/components/Uploader/UploaderItem.js | 4 ++-- .../Uploader/buildUploadErrorMessage.js | 4 ++-- packages/dashboard-v2/src/lib/humanBytes.js | 21 +++++++++++++++++++ .../src/pages/auth/registration.js | 4 ++-- packages/dashboard-v2/src/pages/upgrade.js | 6 +++--- packages/dashboard-v2/yarn.lock | 5 ----- 10 files changed, 36 insertions(+), 21 deletions(-) create mode 100644 packages/dashboard-v2/src/lib/humanBytes.js diff --git a/packages/dashboard-v2/package.json b/packages/dashboard-v2/package.json index 80070815..2e17c56b 100644 --- a/packages/dashboard-v2/package.json +++ b/packages/dashboard-v2/package.json @@ -33,7 +33,6 @@ "nanoid": "^3.3.1", "path-browserify": "^1.0.1", "postcss": "^8.4.6", - "pretty-bytes": "^6.0.0", "react": "^17.0.1", "react-dom": "^17.0.1", "react-dropzone": "^12.0.4", diff --git a/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js b/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js index d6df8506..f9bc101a 100644 --- a/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js +++ b/packages/dashboard-v2/src/components/CurrentPlan/CurrentPlan.js @@ -1,9 +1,9 @@ import dayjs from "dayjs"; import relativeTime from "dayjs/plugin/relativeTime"; -import prettyBytes from "pretty-bytes"; import { useUser } from "../../contexts/user"; import useActivePlan from "../../hooks/useActivePlan"; +import humanBytes from "../../lib/humanBytes"; import { ContainerLoadingIndicator } from "../LoadingIndicator"; import LatestPayment from "./LatestPayment"; @@ -33,7 +33,7 @@ const CurrentPlan = () => {

    {activePlan.name}

    {activePlan.price === 0 && activePlan.limits && ( -

    {prettyBytes(activePlan.limits.storageLimit, { binary: true })} without paying a dime! 🎉

    +

    {humanBytes(activePlan.limits.storageLimit)} without paying a dime! 🎉

    )} {activePlan.price !== 0 && (user.subscriptionCancelAtPeriodEnd ? ( diff --git a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js index f9dbbc36..c678585b 100644 --- a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js +++ b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js @@ -1,5 +1,4 @@ import { useEffect, useMemo, useState } from "react"; -import fileSize from "pretty-bytes"; import { Link } from "gatsby"; import cn from "classnames"; import useSWR from "swr"; @@ -10,6 +9,7 @@ import { ContainerLoadingIndicator } from "../LoadingIndicator"; import { GraphBar } from "./GraphBar"; import { UsageGraph } from "./UsageGraph"; +import humanBytes from "../../lib/humanBytes"; const useUsageData = () => { const { user } = useUser(); @@ -45,7 +45,7 @@ const useUsageData = () => { }; const size = (bytes) => { - const text = fileSize(bytes ?? 0, { maximumFractionDigits: 0, binary: true }); + const text = humanBytes(bytes ?? 0, { precision: 0 }); const [value, unit] = text.split(" "); return { diff --git a/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js b/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js index 87bf1af6..10639458 100644 --- a/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js +++ b/packages/dashboard-v2/src/components/FileList/useFormattedFilesData.js @@ -1,7 +1,7 @@ import { useMemo } from "react"; -import prettyBytes from "pretty-bytes"; import dayjs from "dayjs"; import { DATE_FORMAT } from "../../lib/config"; +import humanBytes from "../../lib/humanBytes"; const parseFileName = (fileName) => { const lastDotIndex = Math.max(0, fileName.lastIndexOf(".")) || Infinity; @@ -16,7 +16,7 @@ const formatItem = ({ size, name: rawFileName, uploadedOn, downloadedOn, ...rest return { ...rest, date, - size: prettyBytes(size), + size: humanBytes(size, { precision: 2 }), type, name, }; diff --git a/packages/dashboard-v2/src/components/Uploader/UploaderItem.js b/packages/dashboard-v2/src/components/Uploader/UploaderItem.js index 46653877..7e19051b 100644 --- a/packages/dashboard-v2/src/components/Uploader/UploaderItem.js +++ b/packages/dashboard-v2/src/components/Uploader/UploaderItem.js @@ -1,6 +1,5 @@ import * as React from "react"; import cn from "classnames"; -import bytes from "pretty-bytes"; import { StatusCodes } from "http-status-codes"; import copy from "copy-text-to-clipboard"; import path from "path-browserify"; @@ -9,6 +8,7 @@ import { ProgressBar } from "./ProgressBar"; import UploaderItemIcon from "./UploaderItemIcon"; import buildUploadErrorMessage from "./buildUploadErrorMessage"; import skynetClient from "../../services/skynetClient"; +import humanBytes from "../../lib/humanBytes"; const getFilePath = (file) => file.webkitRelativePath || file.path || file.name; @@ -88,7 +88,7 @@ export default function UploaderItem({ onUploadStateChange, upload }) {
    {upload.status === "uploading" && ( - Uploading {bytes(upload.file.size * upload.progress)} of {bytes(upload.file.size)} + Uploading {humanBytes(upload.file.size * upload.progress)} of {humanBytes(upload.file.size)} )} {upload.status === "enqueued" && Upload in queue, please wait} diff --git a/packages/dashboard-v2/src/components/Uploader/buildUploadErrorMessage.js b/packages/dashboard-v2/src/components/Uploader/buildUploadErrorMessage.js index c41cd717..11cfed4b 100644 --- a/packages/dashboard-v2/src/components/Uploader/buildUploadErrorMessage.js +++ b/packages/dashboard-v2/src/components/Uploader/buildUploadErrorMessage.js @@ -1,5 +1,5 @@ import { getReasonPhrase } from "http-status-codes"; -import bytes from "pretty-bytes"; +import humanBytes from "../../lib/humanBytes"; export default function buildUploadErrorMessage(error) { // The request was made and the server responded with a status code that falls out of the range of 2xx @@ -29,7 +29,7 @@ export default function buildUploadErrorMessage(error) { const matchTusMaxFileSizeError = error.message.match(/upload exceeds maximum size: \d+ > (?\d+)/); if (matchTusMaxFileSizeError) { - return `File exceeds size limit of ${bytes(parseInt(matchTusMaxFileSizeError.groups.limit, 10))}`; + return `File exceeds size limit of ${humanBytes(matchTusMaxFileSizeError.groups.limit, { precision: 0 })}`; } // TODO: We should add a note "our team has been notified" and have some kind of notification with this error. diff --git a/packages/dashboard-v2/src/lib/humanBytes.js b/packages/dashboard-v2/src/lib/humanBytes.js new file mode 100644 index 00000000..ac1fbfa2 --- /dev/null +++ b/packages/dashboard-v2/src/lib/humanBytes.js @@ -0,0 +1,21 @@ +const UNITS = ["B", "kB", "MB", "GB", "TB", "PB", "EB"]; +const BASE = 1024; +const DEFAULT_OPTIONS = { precision: 1 }; + +export default function humanBytes(bytes, { precision } = DEFAULT_OPTIONS) { + if (!Number.isFinite(bytes) || bytes < 0) { + throw new TypeError(`Expected a finite, positive number. Received: ${typeof bytes}: ${bytes}`); + } + + let value = bytes; + let unitIndex = 0; + + while (value >= BASE) { + value /= BASE; + unitIndex += 1; + } + + const localizedValue = value.toLocaleString(undefined, { maximumFractionDigits: precision }); + + return `${localizedValue} ${UNITS[unitIndex]}`; +} diff --git a/packages/dashboard-v2/src/pages/auth/registration.js b/packages/dashboard-v2/src/pages/auth/registration.js index 5764ad6a..899abe50 100644 --- a/packages/dashboard-v2/src/pages/auth/registration.js +++ b/packages/dashboard-v2/src/pages/auth/registration.js @@ -1,5 +1,4 @@ import { useCallback, useState } from "react"; -import bytes from "pretty-bytes"; import AuthLayout from "../../layouts/AuthLayout"; @@ -10,12 +9,13 @@ import { usePortalSettings } from "../../contexts/portal-settings"; import { PlansProvider, usePlans } from "../../contexts/plans"; import { Metadata } from "../../components/Metadata"; import { useUser } from "../../contexts/user"; +import humanBytes from "../../lib/humanBytes"; const FreePortalHeader = () => { const { plans } = usePlans(); const freePlan = plans.find(({ price }) => price === 0); - const freeStorage = freePlan?.limits ? bytes(freePlan.limits?.storageLimit, { binary: true }) : null; + const freeStorage = freePlan?.limits ? humanBytes(freePlan.limits?.storageLimit, { binary: true }) : null; return (
    diff --git a/packages/dashboard-v2/src/pages/upgrade.js b/packages/dashboard-v2/src/pages/upgrade.js index 9f69487e..f3a531da 100644 --- a/packages/dashboard-v2/src/pages/upgrade.js +++ b/packages/dashboard-v2/src/pages/upgrade.js @@ -1,5 +1,4 @@ import * as React from "react"; -import bytes from "pretty-bytes"; import styled from "styled-components"; import { useUser } from "../contexts/user"; @@ -14,6 +13,7 @@ import { usePortalSettings } from "../contexts/portal-settings"; import { Alert } from "../components/Alert"; import HighlightedLink from "../components/HighlightedLink"; import { Metadata } from "../components/Metadata"; +import humanBytes from "../lib/humanBytes"; const PAID_PORTAL_BREAKPOINTS = [ { @@ -67,9 +67,9 @@ const Price = ({ price }) => (
    ); -const bandwidth = (value) => `${bytes(value, { bits: true })}/s`; +const bandwidth = (value) => `${humanBytes(value, { bits: true })}/s`; -const storage = (value) => bytes(value, { binary: true }); +const storage = (value) => humanBytes(value, { binary: true }); const localizedNumber = (value) => value.toLocaleString(); diff --git a/packages/dashboard-v2/yarn.lock b/packages/dashboard-v2/yarn.lock index 0ac39653..bf3123ca 100644 --- a/packages/dashboard-v2/yarn.lock +++ b/packages/dashboard-v2/yarn.lock @@ -12696,11 +12696,6 @@ pretty-bytes@^5.4.1: resolved "https://registry.yarnpkg.com/pretty-bytes/-/pretty-bytes-5.6.0.tgz#356256f643804773c82f64723fe78c92c62beaeb" integrity sha512-FFw039TmrBqFK8ma/7OL3sDz/VytdtJr044/QUJtH0wK9lb9jLq9tJyIxUwtQJHwar2BqtiA4iCWSwo9JLkzFg== -pretty-bytes@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/pretty-bytes/-/pretty-bytes-6.0.0.tgz#928be2ad1f51a2e336add8ba764739f9776a8140" - integrity sha512-6UqkYefdogmzqAZWzJ7laYeJnaXDy2/J+ZqiiMtS7t7OfpXWTlaeGMwX8U6EFvPV/YWWEKRkS8hKS4k60WHTOg== - pretty-error@^2.1.1, pretty-error@^2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/pretty-error/-/pretty-error-2.1.2.tgz#be89f82d81b1c86ec8fdfbc385045882727f93b6" From 5a2a2b650815cfe378196172cb06c77eb388dcde Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 15 Apr 2022 16:09:03 +0200 Subject: [PATCH 179/240] feat(dashboard-v2): add Stripe integration --- packages/dashboard-v2/gatsby-browser.js | 14 ++- packages/dashboard-v2/gatsby-ssr.js | 14 ++- packages/dashboard-v2/package.json | 2 + .../src/contexts/plans/PlansProvider.js | 16 ++-- packages/dashboard-v2/src/pages/upgrade.js | 95 +++++++++++++++++-- packages/dashboard-v2/yarn.lock | 12 +++ 6 files changed, 128 insertions(+), 25 deletions(-) diff --git a/packages/dashboard-v2/gatsby-browser.js b/packages/dashboard-v2/gatsby-browser.js index 030fcadd..927fd206 100644 --- a/packages/dashboard-v2/gatsby-browser.js +++ b/packages/dashboard-v2/gatsby-browser.js @@ -1,5 +1,7 @@ import * as React from "react"; import { SWRConfig } from "swr"; +import { Elements } from "@stripe/react-stripe-js"; +import { loadStripe } from "@stripe/stripe-js"; import "@fontsource/sora/300.css"; // light import "@fontsource/sora/400.css"; // normal import "@fontsource/sora/500.css"; // medium @@ -11,15 +13,19 @@ import swrConfig from "./src/lib/swrConfig"; import { MODAL_ROOT_ID } from "./src/components/Modal"; import { PortalSettingsProvider } from "./src/contexts/portal-settings"; +const stripePromise = loadStripe(process.env.GATSBY_STRIPE_PUBLISHABLE_KEY); + export function wrapPageElement({ element, props }) { const Layout = element.type.Layout ?? React.Fragment; return ( - - {element} -
    - + + + {element} +
    + + ); diff --git a/packages/dashboard-v2/gatsby-ssr.js b/packages/dashboard-v2/gatsby-ssr.js index 030fcadd..927fd206 100644 --- a/packages/dashboard-v2/gatsby-ssr.js +++ b/packages/dashboard-v2/gatsby-ssr.js @@ -1,5 +1,7 @@ import * as React from "react"; import { SWRConfig } from "swr"; +import { Elements } from "@stripe/react-stripe-js"; +import { loadStripe } from "@stripe/stripe-js"; import "@fontsource/sora/300.css"; // light import "@fontsource/sora/400.css"; // normal import "@fontsource/sora/500.css"; // medium @@ -11,15 +13,19 @@ import swrConfig from "./src/lib/swrConfig"; import { MODAL_ROOT_ID } from "./src/components/Modal"; import { PortalSettingsProvider } from "./src/contexts/portal-settings"; +const stripePromise = loadStripe(process.env.GATSBY_STRIPE_PUBLISHABLE_KEY); + export function wrapPageElement({ element, props }) { const Layout = element.type.Layout ?? React.Fragment; return ( - - {element} -
    - + + + {element} +
    + + ); diff --git a/packages/dashboard-v2/package.json b/packages/dashboard-v2/package.json index 2e17c56b..53edfa12 100644 --- a/packages/dashboard-v2/package.json +++ b/packages/dashboard-v2/package.json @@ -22,6 +22,8 @@ "dependencies": { "@fontsource/sora": "^4.5.3", "@fontsource/source-sans-pro": "^4.5.3", + "@stripe/react-stripe-js": "^1.7.1", + "@stripe/stripe-js": "^1.27.0", "classnames": "^2.3.1", "copy-text-to-clipboard": "^3.0.1", "dayjs": "^1.10.8", diff --git a/packages/dashboard-v2/src/contexts/plans/PlansProvider.js b/packages/dashboard-v2/src/contexts/plans/PlansProvider.js index 7c6579ad..906bd7f4 100644 --- a/packages/dashboard-v2/src/contexts/plans/PlansProvider.js +++ b/packages/dashboard-v2/src/contexts/plans/PlansProvider.js @@ -19,14 +19,16 @@ const aggregatePlansAndLimits = (plans, limits, { includeFreePlan }) => { // Decorate each plan with its corresponding limits data, if available. if (limits?.length) { - return limits.map((limitsDescriptor, index) => { - const asssociatedPlan = sortedPlans.find((plan) => plan.tier === index) || {}; + return limits + .map((limitsDescriptor, index) => { + const asssociatedPlan = sortedPlans.find((plan) => plan.tier === index) || {}; - return { - ...asssociatedPlan, - limits: limitsDescriptor || null, - }; - }); + return { + ...asssociatedPlan, + limits: limitsDescriptor || null, + }; + }) + .slice(includeFreePlan ? 1 : 2); } // If we don't have the limits data yet, set just return the plans. diff --git a/packages/dashboard-v2/src/pages/upgrade.js b/packages/dashboard-v2/src/pages/upgrade.js index f3a531da..61973ec0 100644 --- a/packages/dashboard-v2/src/pages/upgrade.js +++ b/packages/dashboard-v2/src/pages/upgrade.js @@ -1,5 +1,7 @@ import * as React from "react"; import styled from "styled-components"; +import { useStripe } from "@stripe/react-stripe-js"; +import cn from "classnames"; import { useUser } from "../contexts/user"; import { PlansProvider } from "../contexts/plans/PlansProvider"; @@ -13,7 +15,9 @@ import { usePortalSettings } from "../contexts/portal-settings"; import { Alert } from "../components/Alert"; import HighlightedLink from "../components/HighlightedLink"; import { Metadata } from "../components/Metadata"; +import accountsService from "../services/accountsService"; import humanBytes from "../lib/humanBytes"; +import { Modal } from "../components/Modal"; const PAID_PORTAL_BREAKPOINTS = [ { @@ -77,6 +81,11 @@ const PlansSlider = () => { const { user, error: userError } = useUser(); const { plans, loading, activePlan, error: plansError } = useActivePlan(user); const { settings } = usePortalSettings(); + const [showPaymentError, setShowPaymentError] = React.useState(true); + const stripe = useStripe(); + // This will be the base plan that we compare upload/download speeds against. + // On will either be the user's active plan or lowest of available tiers. + const basePlan = activePlan || plans[0]; if (userError || plansError) { return ( @@ -87,6 +96,22 @@ const PlansSlider = () => { ); } + const handleSubscribe = async (selectedPlan) => { + try { + const { sessionId } = await accountsService + .post("stripe/checkout", { + json: { + price: selectedPlan.stripe, + }, + }) + .json(); + await stripe.redirectToCheckout({ sessionId }); + } catch (error) { + console.log(error); + setShowPaymentError(true); + } + }; + return (
    @@ -108,40 +133,90 @@ const PlansSlider = () => { { const isHigherThanCurrent = plan.tier > activePlan?.tier; + const isCurrentPlanPaid = activePlan?.tier > 1; const isCurrent = plan.tier === activePlan?.tier; + const isLower = plan.tier < activePlan?.tier; + const speed = plan.limits.uploadBandwidth; + const currentSpeed = basePlan?.limits?.uploadBandwidth; + const speedChange = speed > currentSpeed ? speed / currentSpeed : currentSpeed / speed; + const hasActivePlan = Boolean(activePlan); return ( - + + {isCurrent && ( +
    + + Current plan + +
    + )}

    {plan.name}

    {plan.description}
    - + {(!hasActivePlan || isHigherThanCurrent) && + (isCurrentPlanPaid ? ( + + ) : ( + + ))} + {isCurrent && } + {isLower && ( + + )}
    {plan.limits && (
      - Pin up to {storage(plan.limits.storageLimit)} of censorship-resistant storage + Pin up to {storage(plan.limits.storageLimit)} on decentralized storage Support for up to {localizedNumber(plan.limits.maxNumberUploads)} files - {bandwidth(plan.limits.uploadBandwidth)} upload bandwidth - {bandwidth(plan.limits.downloadBandwidth)} download bandwidth + + {speed === currentSpeed + ? `${bandwidth(plan.limits.uploadBandwidth)} upload and ${bandwidth( + plan.limits.downloadBandwidth + )} download` + : `${speedChange}X ${ + speed > currentSpeed ? "faster" : "slower" + } upload and download speeds (${bandwidth(plan.limits.uploadBandwidth)} and ${bandwidth( + plan.limits.downloadBandwidth + )})`} + + + {plan.limits.maxUploadSize === plan.limits.storageLimit + ? "No limit to file upload size" + : `Upload files up to ${storage(plan.limits.maxUploadSize)}`} +
    )}
    ); })} breakpoints={settings.isSubscriptionRequired ? PAID_PORTAL_BREAKPOINTS : FREE_PORTAL_BREAKPOINTS} - className="px-8 sm:px-4 md:px-0 lg:px-0" + className="px-8 sm:px-4 md:px-0 lg:px-0 mt-10" /> )} + {showPaymentError && ( + setShowPaymentError(false)}> +

    Oops! 😔

    +

    There was an error contacting our payments provider

    +

    Please try again later

    +
    + )}
    ); }; diff --git a/packages/dashboard-v2/yarn.lock b/packages/dashboard-v2/yarn.lock index bf3123ca..ae43c2db 100644 --- a/packages/dashboard-v2/yarn.lock +++ b/packages/dashboard-v2/yarn.lock @@ -3107,6 +3107,18 @@ resolve-from "^5.0.0" store2 "^2.12.0" +"@stripe/react-stripe-js@^1.7.1": + version "1.7.1" + resolved "https://registry.yarnpkg.com/@stripe/react-stripe-js/-/react-stripe-js-1.7.1.tgz#6e1db8f4a0eaf2193b153173d4aa7c38b681310d" + integrity sha512-GiUPoMo0xVvmpRD6JR9JAhAZ0W3ZpnYZNi0KE+91+tzrSFVpChKZbeSsJ5InlZhHFk9NckJCt1wOYBTqNsvt3A== + dependencies: + prop-types "^15.7.2" + +"@stripe/stripe-js@^1.27.0": + version "1.27.0" + resolved "https://registry.yarnpkg.com/@stripe/stripe-js/-/stripe-js-1.27.0.tgz#ab0c82fa89fd40260de4414f69868b769e810550" + integrity sha512-SEiybUBu+tlsFKuzdFFydxxjkbrdzHo0tz/naYC5Dt9or/Ux2gcKJBPYQ4RmqQCNHFxgyNj6UYsclywwhe2inQ== + "@szmarczak/http-timer@^1.1.2": version "1.1.2" resolved "https://registry.yarnpkg.com/@szmarczak/http-timer/-/http-timer-1.1.2.tgz#b1665e2c461a2cd92f4c1bbf50d5454de0d4b421" From 7e8d033bed3417f619fb578bcd01b8339409320c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 15 Apr 2022 16:10:16 +0200 Subject: [PATCH 180/240] fix(dashboard-v2): fix Button styles on Safari when used as polymorphic component --- .../src/components/Button/Button.js | 28 +++++++++++++------ 1 file changed, 19 insertions(+), 9 deletions(-) diff --git a/packages/dashboard-v2/src/components/Button/Button.js b/packages/dashboard-v2/src/components/Button/Button.js index 328d52cd..2a49244e 100644 --- a/packages/dashboard-v2/src/components/Button/Button.js +++ b/packages/dashboard-v2/src/components/Button/Button.js @@ -5,15 +5,25 @@ import styled from "styled-components"; /** * Primary UI component for user interaction */ -export const Button = styled.button.attrs(({ disabled, $primary, type }) => ({ - type, - className: cn("px-6 py-2.5 rounded-full font-sans uppercase text-xs tracking-wide transition-[opacity_filter]", { - "bg-primary text-palette-600": $primary, - "bg-white border-2 border-black text-palette-600": !$primary, - "cursor-not-allowed opacity-60": disabled, - "hover:brightness-90": !disabled, - }), -}))``; +export const Button = styled.button.attrs(({ as: polymorphicAs, disabled, $primary, type }) => { + // We want to default to type=button in most cases, but sometimes we use this component + // as a polymorphic one (i.e. for links), and then we should avoid setting `type` property, + // as it breaks styling in Safari. + const typeAttr = polymorphicAs && polymorphicAs !== "button" ? undefined : type; + + return { + type: typeAttr, + className: cn( + "px-6 py-2.5 inline-block rounded-full font-sans uppercase text-xs tracking-wide transition-[opacity_filter]", + { + "bg-primary text-palette-600": $primary, + "bg-white border-2 border-black text-palette-600": !$primary, + "cursor-not-allowed opacity-60": disabled, + "hover:brightness-90": !disabled, + } + ), + }; +})``; Button.propTypes = { /** From b9d9059de40bae14f10cf37676aee879f9a7be79 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 15 Apr 2022 16:10:45 +0200 Subject: [PATCH 181/240] feat(dashboard-v2): add platform-specific favicons --- .../src/components/Metadata/Metadata.js | 17 ++++++++++++++++- .../static/apple-touch-icon-144x144.png | Bin 0 -> 9842 bytes .../static/apple-touch-icon-152x152.png | Bin 0 -> 12071 bytes .../dashboard-v2/static/favicon-16x16.png | Bin 0 -> 453 bytes .../dashboard-v2/static/favicon-32x32.png | Bin 0 -> 1042 bytes packages/dashboard-v2/static/favicon.ico | Bin 2118 -> 5430 bytes .../dashboard-v2/static/mstile-144x144.png | Bin 0 -> 9842 bytes 7 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 packages/dashboard-v2/static/apple-touch-icon-144x144.png create mode 100644 packages/dashboard-v2/static/apple-touch-icon-152x152.png create mode 100644 packages/dashboard-v2/static/favicon-16x16.png create mode 100644 packages/dashboard-v2/static/favicon-32x32.png create mode 100644 packages/dashboard-v2/static/mstile-144x144.png diff --git a/packages/dashboard-v2/src/components/Metadata/Metadata.js b/packages/dashboard-v2/src/components/Metadata/Metadata.js index 5bb98330..0e1dd2b6 100644 --- a/packages/dashboard-v2/src/components/Metadata/Metadata.js +++ b/packages/dashboard-v2/src/components/Metadata/Metadata.js @@ -1,6 +1,13 @@ import { Helmet } from "react-helmet"; import { graphql, useStaticQuery } from "gatsby"; +import favicon from "../../../static/favicon.ico"; +import favicon16 from "../../../static/favicon-16x16.png"; +import favicon32 from "../../../static/favicon-32x32.png"; +import appleIcon144 from "../../../static/apple-touch-icon-144x144.png"; +import appleIcon152 from "../../../static/apple-touch-icon-152x152.png"; +import msTileIcon from "../../../static/mstile-144x144.png"; + export const Metadata = ({ children }) => { const { site } = useStaticQuery( graphql` @@ -18,7 +25,15 @@ export const Metadata = ({ children }) => { return ( - + + + + + + + + + {children} diff --git a/packages/dashboard-v2/static/apple-touch-icon-144x144.png b/packages/dashboard-v2/static/apple-touch-icon-144x144.png new file mode 100644 index 0000000000000000000000000000000000000000..ec40c3e02c28b36e5a95c103c7e8fb8af4fe853c GIT binary patch literal 9842 zcmV-&CXLyNP)oXO>c+km`=m(Fbz{1Z$&OLgu#7! z8E*An335>o0nxKT%ZrK%NQ##CpD%@Z!EjM3|9qn zN>0fs`BN2P^cJ9F<(W6c^^5WSK82YA7&o!w{B|?(iF=LDw-^?~al~{yX~}O+VTwKQ zBFDGPN2)ovK`}*oOakL;k1B0;vS4x}5L@yZwWzcC@)`u=OP?g>loZG`%FX$(lH^wu z_T^!GhA>pGlDTFi95y^tULlA@UkQ^B}!;wCn9s1t%oN z?Lase<%usdx6n}@CwlddiNcwnXM{55bca2jZQO}Cd=$97sC#uaZqM}XIX&A^Mm zuL+t5$hNhwUMB=5d7f;^yBRK~tfP$rQ>9a9F;O@J_yEesK$jvi-<+^Jhh+Om9!AtU z6$4e{Yx=;T`w-a-JPkY-4|$`n{{%6<4wL{#RagPepA z7z9HJt{UbL=rgEnK!^yMM?I($vIC9My7aA3PC5DIwZrMarNFI-2EerR9dz%ec+v|n ziFMJ$|4A&3^wJpuW6F39;UQGNN4;e`;*+rQLt*kP&?se86-Z0FF$0k+P+bAC*xd6R zKSiY1PX@(^#OdNV*CWO3LF9gvN2oUsl(bKg|2Z+tpdDz^J)bVF9Zo~I7}YhvIlah8 z3xJlibB_J_0=VRdniFEx5h z2jv-r+XDfN*~5D!a||WRw`3o8ArG zWilAp8+W27@pCkJZ8%m;5s}!>nCPYte;kE1ln~*5&{=pTkNBGerog`$D@MKz++h)t zW$iy!%+w?jqi`nh0C2s*3`hWu3NtDqadd>_tH9ONTRWM8JWv80RbfTAET$cvf#~;9 z3A!2;c(_>On*d!Dl$4nTX5=-T|C${^~STYGWZAb1`}Z(x;M;3AZ#G1Dn5v7W?SQ$GMkCG&=sR+KvVjOmjsl+` zXl@*t&LtSJP86B3JhSF2(8c(PsVH0k{0cZD(-3xBU!OYXVZ3D8 zK$v!84#=&*7ZIJ^t;{fFqrn^k{VRgjYa`d$gAwOM*#(rG^AS+l<0w20)fW-YC07O| z0OcsE-$7&*u(!k~aCIxgRH<)uOw_1>%meNLt_7XuuUFq><1XN@;#VJ|)!D&Jo=9vr zYQXn_tGp(97y?jbJHpKQtm}8D^AurH3}S2v`TY5Eua=$#cNv1kGb((K(jM z6NypdPLQ>w#>LjK9CHl#I;yLz30XdUiXMu7Fch309214JP+bf18K5>C*{A?_Abg#m zl_XB20}XCn$`p#i3qgO5GNWgGeCDJd0#NsXEW^w(9=2mt#T3bK7~^PPh42swtuZLs z2!}xG1kKmSrSs&7#CCWZ=s$y;neG&>xZbhPTkeu<+klS|G*Fm^<7||t5m}fe z5}k)DAxeE1(Jd(Nr{40-xgJ`4VRp?)FAl}4E!N@R*?WIwF4!yaHI(#>cXE+a!xomVjJ8E}eZmkZ&yXMQARb z91KL^2Y{bq)+5S>rCupIug`&e!g}3MRQV!qt18B&I3|aQ!a2Zy2bN}`mHCdnDDS4; z+&^la?T+9AYSuqI=kff`rneh2fctwPsycO6>#u$6^PUw{p9i^`pn1qsZrM0K2qw=j z>R5lrhY6bdfy;rHOoG);xz2S4GZ*2@1yiJZV)Nu3laux1qeN+ac8c3tdJv zIZn>0=jl>jLgeEF%_ElHE@$D&uoxdFV%O1k?PxJU^C0L)fmeGphD#*c51YC zqG5V6n4q;E^us8-yL^w`KB=hI;)Hsb*{IwRb50}E+1C;5j#OrC@=RM&m%BjXH|!Ey z7NPfqi1p9Gbk75@9}{iu&8di6k8xq__L)2;XuSno4RY96>f{o~imTO`Y>aR{W)9QH zboQBZ-^D&D_S&PyB1ArI9tej$22$^J@-W)f;bwy7_MDPz9g7^nQDBb0)SFvTy`}pg zc16-{Xg{opD6>It7^ONj+KoHSgeWVmA0NjjQCLG|Ip}mV9I0h&)S}(v-#$#Q?hk`J zQ&3(NYdLC6*@HE1OcV5pUfAxq2llaxQI^GX&PSq84Ok2Md)kf9#TgIRd5n?)@X6kA z6h9eiInSz=bw2N)6P9hbS7C!U|@Y} z2pdu6fqWCy-w=h@#>=DhF#Sl>m<{?UFuj-Pkc5?pL_LPcEd;G3T+fT1e1FG*aj``* zeoWBZ2i#gpBtn*KRK0Fg`qV%^4sspBeuPE9X`cHU_`!$ve{AGDa-4(j058~o_qcA!H7JM>c(!Hk!n9DK1pFNrQLN~hSJ9{ z(NPG>8KCPB`CE(O+=A*VL|(F{1^7ZcTjCHtoCbOo$V$*faVM z$S;9sX*bUIWS%cU^C&^<2~^(;@&%MV)rmy?20_c643#(Zj2n~Jn2@DCCXWf4Z=gI< zfk<@8#*dCdAF)oDMr$`fWHIn4=Bonh0@;Y_8iefxEnjEK@3~Q97RYVD7eH+;!V%ev z@*e6b&d1gu87boec5(?xhEOAgK;64G9#<>3A z)W8JIw}GZfDj*V5WFvDCIcr#beCFI-5Ht@HG*<$3M7LY4`3!^`fIkq0_r|?HPwWDT z^W8(xydC7-z;{rNSVZCx%s26_@_D*W8Z(vUew3qyM50SJdf)K(CwcxruQ7w>D#zKzIQ%(86uXTepR?i%gz0)#^q zreB_tJc$~YqVf|fil*0bEXTU%6YWR%w{e6$koY=~I}WBhKorhJxevI;oXfoA+KF&C z$dmE33ttB+a@yRqBFivIOp&fr0~3X_P<{{0Pj!^kxAqn@Ep%eKWCsK4lSE;ObjWrf zGHJ#dT?5=t`t2^(Y{PB9YS16X5t}V`=k!Yy0?Y^AE_g!9^BE1s?OanA(+=0gK58tU zc~xn-nxOgAp!(QhJO!EfGm66bDC-ct*dHmwT!$!}iLwOYbW}GZ zvfEi~($(9a&u|#mA{C_{e@ql!3i>0HR7fNy2VWs*tsGPzaS~k+R+^h((ut;_+<>qa zWmfu=6OsyafK9+klvk{kFseOm?Ql*!m*qXcv!FjCXdO#o$|I*?FuuCywb${*w8L2l z{}7e`=VHL=>*qY?^^lS%? z8uNhVAQuB0fyY62I;3WKK54zD1B+ta-lX02QX?eHHFT~bUW#-j2XqW{rx zGb)!==0xW?R{r!ToB?_#%1T70Sz6Mg*8wEwxIe;U@OAjaegK|GEBR1CCCrDzcZAJCFZm6KaZz}^j%h-1uDv< z8m1l2MsyAEIou6U?5D!i>Hx|&5P86=h+R&8d1g7_B?xO!E<`wrvIWs~z;gtx!F7m$BE(E7I=*+o)&gglb~;=lEM-8LAf} zG85GU2wURW3Y#!iZ!Dh=_bpL42jzbQb4rNBtyRVde-Hpf^%<7{)r`9d2_qW}cj>r|5jn2T<1O6HDEr< zwFsXAT@;gY$3XWOe@tFP*^KDhPNZ1YPNTz^C3OA(vapay>~*HAskb%`Qr2KZqWwDx zYbD%_U9qb`?gQpk{Iq#Ha5t(Ose5lmepzO#%j-ez0(viem3;_L0^cQQzFL}3?|eF1 zZHLo<3lWw9m(iWjrI;BEYy;hl$cw<%cxCx&w8bbeQTQuhNd+Pi;1+`B!-JGH9Fb@g zT?6`$ATL;9d0wZ)yuH_lK;j*De8XDC%>Ei!joG!v?$|!gB3*}e<1~cNf!t1a7efW4 z1H6K=9^o031Jt_@g8Lxl@gudEF`s9aWRYc{i$UCWJOupOIOFmHu$_7;>dB)XigYN( zMB&rG73D;t0Nh2;{D(ox8U>N~EXMbE5Oifc3Enp(^u(-zb3^>{b#|KIvSux2E4~R> zP0-xpq!&G{ahZ*IAj?rcgXoM@S)%(epAN0ZY>ew(UBrp>+RN;o7?|OWD^Q)4CGG&^ zZIlRjF{UBju*$4fRv9J=*MZ(pP9y@zR|%Rc1}STJA~6b|1-;B9%XZ*KjLG)p)jKv0 z_9BFJpcj&nT=J`f%JaZ#gjX$#l-HOxKT-o-0I~|<8qn!ZSsmbYlt&TWNYL6_khi~H zJ*zYaxCV3?$k}9eiB6Td8`y;MbA$-9nylS^`DNu{qHrB>Qz?;XdeAornzs&8*6>7P z6#fLWkajG31d)4y|5_m`sS!1%qjDRP?|040LYJlhk#d{j@rwstUMFJoriKWa3!L%3dudwe%nAdfxHO1g`joBQ-;58 ziL@K{B7CWoNCZ%Mn0oV;zUmdrpkci2ME?lovTnooBCJ;sT}IH_?olc`#6{t`D35}k zlgcNxO+j+GT^7fH#}L-W%yEB_MAQg?yHPIkmSv8&BRq=o6!q@Pr&x8UcHC~vLL{+D z=NYSHm5Ej7ZdLU#h#Br+6T)_D8_a^T!iNxUvNEEetcMAjpBpgCfHy4y?Kjqo*!cRu#l%M3N2M)k`er>CCY z%myfO81y-W4Jezbx9nM%Mb4<(k*1liB=kCvYf+u+DJ#w@SD!<`HiQ>Yt^heJN9S}t z!ovjK4pgjjoRfWXe9;)5G}}pBi*RQb*>%oxjGO9Hh!+w=bZCb)gex##YRvOw zmS0W}veUeilPCM0*=SZR`66&D-PZzzNk>p7Z(ChK(`hUIu&$xF{c6g(R#* zBqklmuTO!_zA&B~us@@A<2FR@?dfa3dr8b?=C#Fc;1=L{YaU8|XEL7-Jpg*Usk%VJxn`Xh}nAllO!w7`pQkqF5n524b;0n zpl?V>#6NsQ;Vj@{lp8^prsrFEq(9^I-w2w^`_d=IxE9FQfWVa+*md-Ro1z zW+JE^sD6}sYllbKba~w=7PU!SF0AFwCJVeS*}zmdC9oaO4|os%yX!IxMaRgwqv&&=OD5kIJcN=bgfVZ za|~#rdJks5RLC}BKC#vgF9BVJ$a(2XOZrA;H<9arY)0cLxpnVQUhOyv=Yxi*G!Pbf z%F5H{An+H~)=+(wTV#Q%SRx~4>cEAWC%ijUB|t09#=w4*KaWFTpDsmZ&jMBgU!uF1 zxl>kkLh=x*2^s0`HCC)wJDh=VC910tIWyH;6UViPBvkf*Jc+OY*zS49S0uJeF$0mM zD4#;O6xA7pL?Ut*=s)DFwo+R6K`l^PqVPUcZ%aSk*3i)%PLd+Mm^$@lRHkr_)XYvm ztV3Cp&fn!dpq!AD1EBYze2aR^-tDlMyE1xA2W~+1E<{exA?_$4_g=zGGx>2$h8FoG z`TDdQ^AWBExei#I(!oqIN#0qO*Qf=BKzb=nHL0hOnyr>s(5 z`{dCCBgMF3yn9i#jM^axe*_j(A`-nAI-u_(X#F~;BK=7e&O^B$xH5aM`nZ89UDyahpAlii0b%`y z>=T~fiK6f!RBx(GB>FJ$Aob?01yX?Z!tCc{Ux@ zSpGz}Vcf_k<#QZF`FGS?NjU44=X)~BF;RFXhQRwkb+VD3j$ZCW0oeqs0-}Pb$rrKJ zFjHR*hm_02d=vN(upE&i8GVu))9n~I;lHJ?O-ZOOMfsn=4~RnhE8Lp( zH|wX>o5T_4-vA#5u@=?xm4)-1WiYc4t_S@UBL74bevx)Kx3WG%UsIbPt51g8&J;k>SG5+;Mdhp%5@O=9&k57^9}NcUEfe!1Fpin zqgzyw04&2C1=)zO9%CUBt5mK}AIC*ue3cuPmZ)(J8oyZWhe*s|xRIdwSVbNB$C#Oq zUk3gjm{v$O+A|Vuo%2XS;SefKgnKZPScVk6{yauFq5!?KGH#X19Stz_dwq6 ziy$q*3~GV=Vs6a8pv>t$*+4}i(MsnnMBW{*wK$$m1ketbfIf;OJ1SZ_q~75<)+wI= zv>%3psD2CKUV>K9_x@SEqQ+^cn0ZK|bIQxAqK^U`0coP#W$m9@u1^8R7yIY&0aY-E zL7oD7rk}3zz2l^kxftdH%VX0%KB+gifV>an5mb+L)v!BrNyWiVc|?*=I_CRwxvyIRAQiSJ97}f?%fXn9K`sJra}>9ai^BW?c;jus0m|*zKBFW zxiwD!i9|c|s8IuH0~hp1BziC=DMIyw@oSDEy+$4K*Jy|D z!c6o!Kc%DnWLKX7n2%99z($1CpgXKdUQkBvMUCmeO{gqKm|sDkn+ckaRL(!=*w=vu zClXz0Hq4sl>PfKMQ@EOz`{eT!sxOw^c(S*+?#(CO*A2z`-z z<(R_=Pk^ij-Q!v5KVNqrK(tK~=?r}~JU zo_ciSKLVnUfqd4f{3JS2?B9g}W-7(v(U5zEn8PR!BHSO(S@!Abf8g8UTtx2zu0lB- zp@Xs$s7T5ix;K<90Dgv7v@zA=#; z3`F7QF&nd3ZB#~rm7V8F%;zZfQYSvia|rvv_@Y#Z!izDH+8I4)souk2-o`9N^PPB! zJYV}4>pWtN8^*gA^;=ki1G^_jjTxx?6p44pt4<_3Vuz`K@Dj?$yDL(RNAl`zezzNQ z5P1NzMq+Jfvat+fhQ3`Ot5G(_TQj(NQmFF?G2(!*ena-jEbBzRF*F&<7J~c+ciq55 z+-L=yC?XfL3;2ZDSuv%9tA9~6F$ku2J_^As3-bWog*-hndgJsuh6nng^<_mO#X64& z<60nJ1LlY7{T@eQh?zB4>w`$NLi!vG906T{%7fIquLoQme2q{Q%fmc@>bLtO5=ohH9|mTC+zb4V zc>1baZjE#U_;k+0xR$nN{q13bW+z_K<#JTN0M;Ayu9T2_gJ6tYfXdH7?_I$O_W%F} z7)eAyRE*!5RnvI{m_fsMpQCM`%k%1!1;BraazUR&VpYsx(0dU1x@T6StzTLFst#@b z<0yO==z5T#SH}^Mjm4M_!sP_b=LXVwfa9VtzDh$6CQ-Nm)n6fUMwdjZLL|};hMmCO zAWv9ty^Exu`c~_N<}1~^Q0@d~jF@c9!N^wX&G!wgbDx;;5{aGyyAp-xqWViD{%W%- zk=QQ=-41du!bWE|>FTK z4dpCEE(I>9JLO_vy{lq6z@Iq_i;k{dj!cF~Eb3%Y2&x}JcpPL#LB5Qk;g4Z_rI&!0 zF`KXKA-x?`5kHa)QPV(Y0}DXTL;24LOMv-k^3h9ui&E-veJv8sQ3ciC`ZsbFtPa`rX<=gm(MEfP{Xfbn8 zor7>z_o+{X&5|bfQc++D0XR;KatPrQpmyi6r60boGNveuFOu&xX@@g0t5@6x?p6o!9afwn zWDJ;oKW&~QM&#Qlw_A&I7RgvfjX^C?KQg%D<^|=YpzDBn0}+YCVp5ad5?Ept>|tf1 zm;(s6qI}Oy@OK`>0-@R+|Z0V^;I zMA@jKA!ec&*8-K@=tO)ybX>45*!OM4~D1c|`9cJvB9N zNJ);5D`wCzzUan|Itp{IDaM%Z&~8NeB*^@!O(X*5Q=KP4*Tp*q`G@Q&dR%0Is@$+~ z%itX=3TL6Z6p@dkT!Jv$>N&B*JtY~cfDC5jM4|wC2;>EX?*qSZHU}PE8%zK*s0Hdr zhE;s{inqgAm~YZP1YCsbLb^{GdqMvX$S%wtsk^O>c3oZUn~xI_2T2_T~=dKGLKxH49f} zIZsARCb5bI8MjO&Yk0iMJP|P?m0^{dDvjelSVdOqq`_1fUVPF|Ll26XDl%0%@RY<% zb3i_R#?Hu1DqdofWs(?MM)i=K@R(CXV!7nid#aOr6T#G+3px(ijZ88Oq$9pp zAuhfursH6I$CJSLbhD*)l4HCMQkf~MP4L*Kt<8 literal 0 HcmV?d00001 diff --git a/packages/dashboard-v2/static/apple-touch-icon-152x152.png b/packages/dashboard-v2/static/apple-touch-icon-152x152.png new file mode 100644 index 0000000000000000000000000000000000000000..f65a5ddb0e8ac4376aee0cf8613dce0bfc9bcfac GIT binary patch literal 12071 zcmV+?FWAtDP)1^@s67{VYS00009a7bBm000ie z000ie0hKEb8vpQOa}im6KoWe9c{N4UE- zCJH6^M=&8kFwS0sF*e3^V(bvAP^wXhD!UkC$JhigKfJF^4IvI8Ho<@iCcM``C}9{v zi0TrRVN^<0%BUI*RW$qbk8|(cbI*Ow{js|*7J_HyeRuc#_@3vS^W5h=&vVZ`SAZVv zY22~=!AkQShc^P2Nxk5+uFSmJn>XHpi1jA@jOaiWh&P36MtXAqUt2m*h5t3dYHDN_ zCf*2w9QLtSllO+ek}R={K{sw-%)*M{w=L_ZwZW?E&pfcgw5|qm9sWUu6&mtmCIU3B zRH>$gWkUvI^~aI?7%w57)viUc_GZEIe}@;Fg;m$rgC1*{k!D@3d3vbr>eOY7e7u}7 zt6rEt4)Q|05Ig*w7nY9^V#Ua6GaQG563Y@WBET{26sGz0@;Xg|7wcr({3gtKV}%!m zC8XAc)5c6V=&)jw-xLSy(N1`lg4#MGZFrjp);!udsImM(Y$I6HmW@e!lMu(+waSIq zOM%sd|0Y%oAgglty-kB{1hKBJmEU%7mI}+tkG0X24mzw^mbjnQ68R>*&go6Td6VWs zd7#y&rhr=LrngBWz>I|n>heQR&cd^Ju)e8sH{g=hw488R)VYs#SI?-FN5wyk(Emjj52!oiaw)59|b< zMtKVKzaTu0%8Lv}`y>6Z_-#AB2OL%?U`^6lw|w~d1m(i-A+;&jgzu+eq(eGf1#%p4 zBC5ZP$g#j7sDcQ^XIVRCG?5%f(va@Ml<>yDcF+{$KHyZd{a2t7B^zIyScB9>;Tqe75!!H}v3v#?4+7nZNV5?%lu zfm}y_^!&6#^0TIfHQ;qZX|e+J9NFed zERGe!p9#y7)?UMRzrhg8PYd&X2CVvH?{kdLc$%z4Njd^d4{X>%c4X)|NhEs?QcsMT;A+pLQQo1`x$Z$tPF zumQ+~AzZ4UWK)&Wvwyj5Q}WoRz!I;FpRZng%&$~bB+Fi^E89JIx|p1VumHNQVjKClcYN>AH=_M~2_|S-tYFT|!WnpqVVm)& z?)CjO?oIF1N|BzD=I=#nIIz$UDZ zZ{Madv`#TWhPKL=k?vUg5P2Ec0Xz%(4X#`UE(h6$>gS@XK=IvF9Ul3bs|A+3 z5BMzbAm}3SIPe1fg}u}FCt2o}caB7PHzMx^HlVDU@Ey^xu_Z9PmORa!u_cm7TArR$U7V{eIgB*v0oMT^D;efF72}y{BFiwhLJsv<`%#`i1%C``n@dmyv)%B}Qe8{D_U9+d7 zT!8RS6En2Utb8%PmuV;Hd+9Gc*NU&|_mEomu}*`<8qKLqsKOH7GNnlmbPLG81LA|! zMs}LZJO^9}+)jV=vd5p_pSti&{@dzP8_jP`-Z;Cb+6OKHP9Z+Av(PiZuh1X8*qX07 z^s$WwtDAt>5@{KN)w*um@+WZ7c}L+D873Bap<(V_>fsfwx&vez!nf&%{Y4Qz-TmftZ?NtV&2${fSZ=3f$G$G1M>;1ro7>r)+#McacjIF2PcZ+() zck9Xv1+V9oI|bFRmP&_9o_Oh^6G4)&d>B#y&^^F^K;-QVM%R17mGck^TF8G)*sOeO zyvEoXv|>Y5#W6&zk#wn>xZ{gdR}qi4MX8=5(<}0@`RHRzSxQ5+5js*QHkhN8Z$@GXk4=XDZdR=8B{~_R0z_Y;~s=B2xCQM;^lcsCB;$wMb zti@zCqMJZIM{yETjU5nkEK6l{jL3)SkM5Y7uMT|_qaw5ska#&u(8}c&hpQ0zE0lNG z@u<9@7uWLRK@kr=!`g$pW%7raN7$ABt`rkEE1wQ!C;92{T_E2Aj_k1g+8ZZN(%c37 zGH^VDg`dvESBpN@#lhOxQC%prGlo5sYZ3WGb5y;7s(ZP%BYc$p=#eRT>`F}+*!-{- zleM5Dl+sWlyhh1tAUyv z|2j$Sex)uB*CYHj%DSR;-z&0~#1gAUWFA1|n<$^jyrZs$YhB(vmeBc<3)Y?kdMzsM zjzH)!mdA$b#hmByGRoT-EWEH(>^5ELb%Wb|;6<(iSyyN$m3Z{MSON?!rrvjvF9Dwp zT<<1o+phylxB&X2G5yiEK|YMI+j*Ee8Lu!fTiIM$x}$LjB3m+{T@vy`24UDC_7^J? z!*t)%;iwXi9^g2?3z%*VK50-uxBpSmS8{2n?ybyzVYIsD!ot3P@O)ge&6A)oIc zY3DC32exEE@A>fM)o46vVo*nGI{Oa2GD#H=#-px{*#s^<8u2EBoFH6R;=1&-WX* z^8DXp7KiJBOD3Af|1_4#!jY6oeyNT;44j`Wi!sem*O%DE)E3Jh?3kx*{rUO5$oFZn zz71@yjBzcMJjx!(WtlBDPrk-=OJkSGv95kc!X{u%)uzgA04d8@>FNud0Fj+2L;9n= zHT=cwDU0X2vUONZ%R{U^tN!d*PLqED_+DjM)X1mrK)H+hB;eS&@&)v=JNXth0XBPE zX>vGlZt2P@JjDFB;aV4E)Qd{%e$WdTjCN3O6Ixf*wB?%0ST?6sCj4%doeir$+K0%e zfal6jmK&=?p}qWDak?DUPZ}QOOnmi#zhyBwmvp!?QaJ_$bra~e;cP;&aV;%g81d%) zwl9O+(}Ks>lKg?Uw7x$%;W9FRtp4aFM9)LnUk+RcSFmOwqC(CJL-#C{x6G5T9?IK5 zZ${-Oq{->o(MK_g*(nyC405jH+e@_!Pv4L)c13tPU3m)FdH^5%5fhwg_?;0;9tOVR zo3NheO-Xx|cKHgxAqc0=ldm4=5M&p^vA~}IKV~sGITN%nHc}^0lRWp}#$~83FK+?P z?JYkl?}sabduGl~8zb@=1`F0%S(Ug;1Fuc#ZLnfxo9cw^hh^u3)gOVd6?oQ;D|+#; zoP7HjJ~~gn1ZRgG27DcOe^Fey7ubUENU)_i<^cG4W71?5%7qA@2i8Tlj@Xg>GTlOd zbbblD+#zbxEaS9i&Xl89VQ zLqHA%E(1+KA`V4G&HVwe*|WVujb#0{cxqd>E0(3rEX^4!x3pMkavbm|&~OToPYTF` zpua+YVP?L>s0itB1pTyvSej+<#@dR}e6gJ7zY5r2(OM#&r|zWz2&+Li%!4lp3RI=k zoh`o=)r&yN`@)4?sBQzfi9vDLh9&KBEs+j4f@}pgpxVo>pnZt^bNc3y-gO$ME6oF| zsgL2((YEY-uw3Buhrmfdc{@+-_G|eH{n5p<@+B=Q<(u422E7jDFr(~qAXg&Xl0CU& zQCzjA$#T#Sf^0_hSdiNpjD9nMb0Cp5cGC*&(qW~;Gk`yy+?MmgLE!DZ%ko^-V<3ab zhJx07)d^UY(qt`gHL7QW^t=TEx?^E_Ig(tPLq`=XCwLy{e@Zf)gNeD?q^Hx zcHn;pT~~czCcIBq&>lqoS#S(gXKIQQ*n^uUX9HhFSvxTp@s0Gyfz2rQdhg`v-cI{6 zbw=n?W4%5oO|C|@d^AH5)b=!3p~w_O2J}biEX`VmtWWmf_DA0ZJs#ov<(t%nEBsEB zKS%f>>F|UWe8eX)O?u7_texnpGcj#@-LYOLq_>rJP{8Cil6cFbzx^8CF>9;-5*c$h zLzO8Oaj1@gl)*x{T_+ZgiP;XZ z@IxD{w&N7T&(rI8m_JsUtN{KNIJ^p7F?F(Jy`I6sr>f=K^JT}u>Ibw6xR@M;a4k^P zR+Hs(KX5Cs4cP9zUCd&x#AHz}O^ybJ!2bnq2c8RXLabT6w-{E)yOkGWw!3JT5-Uw^ zgjSEL<@7N9(R*g$%Z`J^8TRW<>I_ED0>27+If^sxOIw`*ScZ}Se+_({#bjNiow4`l zcf`feR4)VW$HjO4oHRKt*wZ#PKC4*OwsS{g4U5H&5(~>O-z1p+XKd+xEwS#S4Nc6R zBWLBy@*?YmF19>423+L$IN-)C+(1?R<}ozg19A;;brv!1W>CA6Xf^^{Kn_P3q53U^ z?b$63tJ7_8m!Z59;fRda$0#36XW@2jr_PaBI;?bf1S)@vu$+oJ87`3uupi`~8b@8V z=Br&CEDqq4XEzO3Wk(QQgnMemqsslpmw>B4ze#`LmCkLtV>eGj^>Rdx1Rex#M!7qC z)k>YWX!8$w?C)^kEZ|=OF9JUTQrrtfy9)8F-tFvI>2Mh;|A4T*lpa4Fa*Xhc^hZxm z%U8EJm<@Er85O4!< zcc$*Ar!+Yf<+l(%it15_ybAgd%6*7Dh!f`gImKx%-a4CScC0kH66JSYwkK2q#VOpy zYAN8J;JRsAzLrjd`Q)_O>8O4kVQn>n>;?IXTN&~=s#_8Hev4z6j5ddBK|YV_g$S#& zHeW*Yc2sT#o{T)S+m05Kr)=6%@Rb$Kni*}$iso4SvFKT z%{d+GK`%o|5LuD6wIAUL+^N=g0jUQlr{Rt)pOEq@!sEaLZj$Bc>|UQW_7*kGM{FK_9*@EWT-%Xy3xm=5)AH36XpMy> z%9IZO1o%skYg+B!cN1|WPJ^7#z`RfUK)(lEL4V=dnsPPm>IRU_z$wAiJ4W>h;6_C5 z@NBiVlUn{7>$Ufi};ET8zRoz8U z^`_jrCpQ9D0Pm{QP~C&b9XQ9p*J`l~uugL>!^H;A2R#Gi5U(G8x5fxNf%`#!gz^x= z&Mc;98P#nRLzOSb&;P6R*<&Q&>mCN9_to~XhOase7E7ykARYb$B;Nt~5~`N~-)687 z)~_<;?lm5Vavh?_dEQI)>Z-o@X%BEcaFw??F?2kv-~QyEp2g6PDIF+G&WAn)awEze z42m7LaT6f!Vf9!{)*zgY>UoH409{rbIX-#sk@Mz6_XAI%Jc!7TfXC<;FCDceyB%MP z!)1v4W9^pdf(JKB+3liseGK@jyV-3S>{YPEA;6=EymR6d>KNp9+^K`RsxSto+c~=# z^s^|-suN9hW8CDF>0Jn41N{p9h5S9%F^8k-`7RDuf}DfsW>nS}*g3gocjKPaxfXYi zE^MRDISQAl9?CI@Uf}k>ZbbA}kexL_R%^_vZMxUVd=hj6BFl^O zI*J{qc-K|Y_m@$95aB+M2XUrC7&ol8x0ozL_{RXtYbO|R)yEht9B*Q^=wmAvu94E@ zQB*fnV_OO$`%%3fk;@`4$+YlXa8@+|dPNYh#BFG#mR#$ff^0?jZp{|%I1lM?EpRc& zMQFYa$%u4|?m@W+ksE;ryf@9(Y0p@nomPX7BAkutp=EObufN`SxZh)x?T9?=0=}f# zgR|AP7n5a({$muYL;~;_gVFIOR*OEy;$Yn*b#b_eNPiOB!qPm?0_WjuiDu?paQ0MG zuLa6GFZ@VzI4DvQf~RrsLAtYZur?j`P+5<#3G`#Y@`{X=_>t|1E&wCkYXIAfq0w&A z16JYQg7Qg3PH?tbr0o(9mj?R* zn%&xx4dU0R19^!d7a+UY7~ksYtdgS2h9|f>zFdBonmzgE&`{otg7+6tD%= z(}3j_jak0>_aSmOa3k;_{gL0#I(yf?z|-MTsC*RBb0{9T2^@n`(Awl{4@l~kQ{92` z$E884!&0VQB6~2o7umLwO=oeNxvvc?>cqPf89 zoX{AN2XIFbJkt5*w_CzCAi4#WldDT+!GLcsJqL0t!p-zY&vj}qq{U zj*xX#NBD}Kei*?Ld?UXz#k@#pc6}%1(&Q?X&z9A6Miob;aDnqzzFgC=*J?s(as+S# z%88}dqrk+&wA=D&KX4bY1@vk9rBI6BeoUh*Lpc#YhUPyp9g<7m2Rwj_tKDO~@y+zW zviu;fHtc~MjynbCT>QrfOR}LY_{zoyuS{ii;4%6mUxURw*4j8&o1kGVz66WO=Mb(m zg)3yfYN+22`l;+?nSPr-c@vy02Yx$S^1L%Hbh2EAWD0q9-iF9F;HSauCo8T~<|U7z zx!X_280EaSeC;96BYYQF0G^3x(%8kGx1W35D?m>I&IdUeW#vT38Y1)|Ulp&Me9ZD~ z)9v~4C={?ZRF&K`IRm(@U3F8%?E<|7WE64vs~t;|cK|nl9#@rM|_UGboB_ihln?ct{J0au!M0`bA%(R+tHqMbcBIrEr`3hGC z?qM+cz*Ky7h=bL|uOLk}fIez7A9SQN(LM<%?`1H0$ZVs`Ti))e4O8UHE?@-uE!_RcI*+%W zFBeEX3FSPuu`qkxjAgSn^9Anhz`tp<+lntSGGZ01d`Ic5aW7lT}ggu5vsZ5I#m8&U3Jun>Eyx{XKI%Qi=zgYXfQV`Iv_o-aPbVDya^?U{VdD@?H*)&B}|SUJP% zO`W4N`F>5mZ8w+?*zX9<#dD<)s@lYYZt=L(_d(_3)tkVX$C^0H%^Pg zzW_NUV{DRcnMW0ur6{`#cq{#drY*|5HRR1HFrW zbPIQUvRw>qGw!DP@>1W!ca8ge6;2DFJce)s$eqB;9YQQszS86^z&WU%2ONt?FLIA} z55k%B7w(B-wV-^7q)R1}(qt>}`_*WEsF%F~_0PzcoCkR?{n5jbR@(8JCWiuFMfD7a z8`@wc1_>r}!hgZ80QwjrSD<>gw*|W0VCOG;cQ^A-spOZIr+}xN83E8;!1q9IMtQvE z+>d6yoL1X_+l6}?B5Sg_8-qLqx(SiTI^1V9DHf)%-1K^NyqJ6t;m?cI!d0dmKG0Hu za=IJD|3rV`(xC0UeZS3+%AT;>^K}mB)!^+`@EMGTH7uJ%0T}}iqk0)4sj)fG;%&m0 zi(#Dzxbx7W{M7K4W2!!da2?7Wh`ekZYub)4w+V9<$kDi4R6hj`Z*{frV?cfn>f&I{ zlqPF{|5cQ46N|CUq-TL&432-Qi%a=@R{2en!%@8sk&_zQZQ?7)*Sk=;0`!SMqs4fe zkn{9T1KkW9)7liajq%;M=L&AX-RI56txh0pzU+ACOjr`j2mqUyag-*10~}i)TM5@9 z%6TsM_nzR`pqQYyy8zN;Im$%{R{-VUY%A|03~Ll$_krF4vW5QWr&Pxds^d5L?qXcG^#g(Y^dC7s<6`(?_Bbu%9`sN=!Ubhr`scs+4V03}Dj z48F=9;H{B|WMdt#^EfB{a2xzKf&MPY3NHrbv6=lY$-bvKLYIE>bvMc%Wx-ni0Arh% zkkVu==*6g9gy0TXu7+|bT^#;BSevh>f$spfX3t7k)Yj2!BWxwCHb#C^ti>0w)gXTd z9BM8t1!<6M%K0VqM_uNa{d4D&~ZaK2TTS1ZQujpFP$2?7B7wAg0IOxv`pS%_tLDk5K-7~0+vS<%Ganl;f_Rj;`;vAP|V ztq8YwyerUSF#*vHAX{+zzP@5~pkqIz$p)$V0r@>aKcHTI)viL4{LoXh@XVgLXR z%}GQ-RI_pZE>rX66(?^omR511WGC=;?{TfAqcm9udNs<~6TW;ej;f6LRO&;d9`Yox z1?Ya>hT9%=BCr)@LxqWH`I_`~2k2EO*E3k?azc15`9czYHj!PmZWL4Jur%k9foJdJR583JR_&D%4EGAcFr}Ka%OcR>S zPk*$F!NMlcUqtkJL_BTZnXhGTYmqtsep(}6*7RBv(A8CS`Dt=0@TU{T#k*RX+)M9w zq2+Wt@E-aLFGbt5m(ExoHGL?Tcfr|r;^IfgRG%TtXxgpGRjl2(quRd_c+t&$bivvq zvh78uBeJX`U%L?b7r~C+wlT=kZ!t2u0QzKwES3R(iHn+NWEcgtb^@Ua|32uMnLQTc zyPmK1<*H>ClQp1Q5V;7|WtHtlmC%IWpUARRiB**_b^=!ef8;&H+s?+EoQHNf%KJO; zbtnDNua~f<3|+PLBB!Ut;YN@j)hVcG94tn{H-OK~baM18RJ`7h*y{~5@|>6=$(-SG zNWrG(5Z#LM?JQ2!0Ct|3QmGHxq& zmnuXhsU(C#!#3y5i2Om#sXZYtZ8dd!jqXkhyb3tSMMx+809A8+0bq=(12oL3d`khQpfQLb8lt)x4_mS?&4qB z`On4$yAswII9|EQ*DhUv5Ww)iJ36nX2d-K{+A#t zBF2^R+c1btkAd&uPV5OEmbLh6J4j79U|o>zQMDV$gR{|X&feEjnZWz;wOK8ez6x?X z!WF@3KGy1EtvqeCb|{y$un|&S6g9nA5&ieE=A-f?_QeKk1}8F2D5IE z?YfJ}yAZt&IM&lN9`8XXErp$@7vD=-s}AcG;2PX1-1&<#V!Tt6U*E?XtTsmeG{${Q z6J+*SvL5uWDIRdBi?aH^>&g=5--Yt&%qxlsy-#gaKQvE5mC|H2ZXeih1HH0P5C}&g zFvSgPV_5~-Vd;|~?=zkgm@4!TArs4*t+s>Nq~YoW7SiNIRDXc5vUD|;ZkrHBwJB>n zkIchyWjD^ly52kVZ6=l9P_~{HhZ_;O0p)E|Y;*SVyuO!&uMUfQK|T=K=-7t;wnA7c z7qhX(G=s&;jE&D;g+b*ZL_Uu)p2U27Ny?YPoU$}1FQ?%XN=2H0>S~m$QGJv&IX(08 zLcZ$yXMOq<)7~}>79IpW9$|#axY*E`8}WY7wbb{#koQ}I?@d^4yR~=At~GV*qfxo% zeeY7atH)KIpuuR2ay=qnb_tqYiP?95Ky#Z*v%k^+;|;EQa;TF}I0p2OK^HSY%TK$R zby=vp!0ht}edhR~HA zhuy#fhFVpv?{0h}mrmNMRu7<~_0OXbw0 z!Rq3M6|7j80t3VfJX%y&w$8iEukLT5oB^~KmLi|3cbR2%#)93rx05^r`u89^P<;X9 zWrSCOeYiL00=g1pIqn6d>rg!$k)OkzK7ACbYrO}GZQgRbYA)NaO{`~tUkaYf>>8q| z3-y>-p@6j^TR0|p79)PS`T(7KuJUWZx#a+CUHr?xlq2QmhNYmqiaT$AoK50#_oqF3 z*^1!Qn!sWEvtY3c_t4A}#I;bJhHA=-miGn0S_;OI{17;->*xC+il$|B>~?MH1*m?( zJ=ztxd$_Q^Xo?$8?&!8`axD4lUB!I8DvV#*A2= z5gjGN@tAtcbSJDa@JF~4iuMwxHlc{=LNG1E6is$hT|?7S)iZI2`rb%>fNs;t(8X43 z@A9Aal<5#_nr+VD)$`Jq0!!o-&`$&3_1?oYk1$i$cv!*tG(yyc=7aB|@1MinTU=30 zKxqGx{jTiJ@N5?G)3VRDSVg{NWCubaexCPz)-BU9ERhuWWcDoQyykNz;S9aVCJ(Vr zg|_h$>x_ImKIXUYwk98kd(!&2Qm$!}G#F8Z@Pt`yv9v6JF}zkZ3zoi$$~J^Ad0~jU zx%Bhf(9~Fd59;DzT`0y(%9ER>!L<7}Y`4KGB zBMs{K8fa;@Oz#A}4CK~e3r^eBCl<#ds5cWXd34IbRQ?)5%>C-6A-rI zUJ%++<3?0RksMPk4Jv2)ZO-kmlvfb02K_^j-NEsfZM;ICn#`k_vFem_%%-v?Jueqy zrYYSjXSE&e2x+nm)l)z=A;!ZN6}iZbWbb>SsJy&Fsc2b?_+XY|%+rhSzSi>FYmN0X z=uIG3(;w}mz4O#YK$Z-vjgdc%abIVH#X8bfP<^VFac_P*5s^!9kIVO}(p9HDtXPIo zq$C`Hz|3WvbAk0D?s>~^W?P=83Kv9Z$+4^v4A2_Zi&towuPp!=Pkebs2}c3;8w0 zYFZ-eXdY_ywZNQ^d$;vl5Kcn%*MO4{IRw>SeDk8lWvo=z%Z~+b!}72Xz-Z<4K`1qiD7k3cX`e+I2Mr;fC0*}pzCqFBg#}#UV)aYETdRLH3oJ8&t(z! zMU;oLmsZVkfzM)6EIC$N0b5$la-h)Sa5*CDP~HX{jqr28;lO&}5L6EVSq+*k`4vgp z3+zVZWzZKvo(KJJAlp%%L3jaWxA%JFgPyD7G7N#q^;4~ z4$EzQUY7m!oPcF7Id$^&D#D(u{1|jU$k=YWKj@v@Dm-tZfTB#@D>CtguQQW~_~a9_#hJWxD%SI8Us$THey| zZTfxCVELNK(pKSLEZw@=>*~;u9(JsW*D&46n>SXSR*$vyM#PF%XuBLXfj6aFL(@%tzVHC&l&s-xTiIUolDVar*VMrcHhO|qqV${2x z&1`3xv}lpkNR--CPs^c6jZs`l^hhz$vdy%J7_%Bzl3Xp`bKRQzro}wV^XGfc`JMBy z#W&PwEmaHSIE)?mig!}({2x%N6S#$mO`ZvFjmP+f`*@Bu9Kc1KMZu{a zWay9NL->ddoR;!RLwCIbH>EsR14?xUE11GPoR{*mf#g2q8fLLi%AFRLB6$pxXe-su z2p(xb+`tHq_D3ky9vsAFyu}ms7CNE97`k{PJVr`GE)-bQWhX>(%4|NCiN|vMQbZlS}Pw^<`zK#X;jm%?U zjYseSKXFdV?XaH=$Y@l(6d7$PcQ+r>g$Qnikc%<<1g?gCUA@BY-yQTJQ=!H9fRERh vk@DxB;a{I=7{_r8yYLOKr2MHdek<=cF3oQ{YJe-o00000NkvXXu0mjfTIbEZ literal 0 HcmV?d00001 diff --git a/packages/dashboard-v2/static/favicon-32x32.png b/packages/dashboard-v2/static/favicon-32x32.png new file mode 100644 index 0000000000000000000000000000000000000000..99ee3c1c4bbb8ef8e98fb9861dc8d9a59bebf791 GIT binary patch literal 1042 zcmV+t1nv8YP)3?uTv zjLJNfis?&GGLc9`gb(3MDrMM*bV^DnQWFx9J|qrdQlo?wnH5Qt3??Cih)56XT<6T0 zd-0A1y}00V?^%28z5Zu?{MWu*lK)vQ8!sWGm2fBSL$o#lD`>W?2oy3@Ja-9)KbngM+xXqTPu{r2J${ z&_mCdi)|QFY7XEwDL-2^>!|N5Wo^y*b}VSyIi!3K?!-W;nU06+W*v%bg(4eOK|Tq~ zD>g?(A)T#nZUe*ttgL9B91egz*rLdmE3&TA;UYBhwMxoQjoA61yd$~+rYf?@LjgpK zEW%h()%W9lK{Sg+?k`?~2i8?Iv#ZNPi?GP1;cc81mAqR-sYevk*XM~P($>{hT@+b2 z{z5l4OZnr?0Sp?yfTu+0R!jL8ifpWi&M47_zbmrwm?jGL2ns157MvfhT{ zutSl(A^7}Oyoq~oP?2p#x0J6eK|F?^@Ei_H`C=?B&)SAR71=gLwyXpOomGc*0R83n z5mES!YJ)H8L zxJ7hCCsyD`MfM_&NckMh6KVMXzX~!tCgl&}YQX{fu)gZBUIQKY4dYAAaa?nr_hUUP z4`~djlcLQw2-dr=bUvwE{{*jLyOf`QbmSdS+vnw3)iYR#rc6zHsq_K(u>=JI)o zsEw=2=YG77XREB*Y!+-1d27hpvhoKd<-cH#xS%wq;#Js)AMilw?0T#gQ5uJ5MBAR1 zR?~0`9<6BlFh|NyG_jo`$ZJ|{@5d_{X03!C2eVun1A zrwxzlm!;EU*uItk;?SAmLegE)p1~{F*z}rJWV6K$YIJR709Q1ds294D-GL9A90-R* zYL1s6CkhT2)5LZN{k9JvKui&=Hu*xPEo1|FTV3JWy_R>2*6bD4+>Y!MgRE)pM+RUJ z$S5&T=3}Oqf{mgZ5S9NK-j(vcc8(kwfZ>3;1S6iosSEuHxg^cxAL^kX^>>@u0ssI2 M07*qoM6N<$g0Xe$u>b%7 literal 0 HcmV?d00001 diff --git a/packages/dashboard-v2/static/favicon.ico b/packages/dashboard-v2/static/favicon.ico index 9229fbf780c52d9d25e2183c0effe239dd2728dd..5c4ae3031313d43c6a282374e98ce65102415205 100644 GIT binary patch literal 5430 zcmeI0eMpsO7>6I7s7R5+N}}T*NjcCB#L9NDK)Pku5@Egp3FoW2cQV#6NV5 z7-NhWF+xVj7$IZCkQORKG(yJMB3z6b5_-~z!zRAFey8`A$9L!0@q@8HI&g8{&vSo0 z-@fHsp38UTb#;27aJV)6Mw9)&a|5+|{ss6sd7o{~UULGy#1zkb*^MGCR8FF$)^c1T=@N$wA*R z$frZG$YK}>`(}_QpbdV7J5cJ?D50&|s*?|OpqRVR37W$gd=1B-1$KM!2Wa09ZSNrO z!C9z>i*OEJh7UkFl5pCK-$`5c5qKAruN9i022}4jq{ocZxVjXN)Oa<<_dszaV1C6` z!z8v{puIQ}#w&LvD900MG2cuQdmlW89lo8mYHJPWpw73MPJcV7cE9!c(z7eiC!oEq z1?}B1Xn$`)i67_d*bc)KM9=RceHwe#Sj&Tt*0dU4hc3`QteLO*ZdC?>b3wwnRGD*+ z#+`dG=-kvx&P`4`_uHG!E&Pog7M8GqeB_&sBUbNB92!CI(evN-uK;^r2)d)Cu;$&_ z{%Ywvtvh@YuE1T;ow4(*yEg$k%eC8CpM1q|9(0GT-m~N=zOQa|9OQTrW;ReaI)rM9>HQmks!aLlZ-h+a)!E?d zBex&EJK+!TYikbsKyP*h zXnfkIba$$ByIO;+=K!15%HQ`tX|JwVXzxNM!SZTu`nJ(r72gK>mNNTw z^po(fZ;lM}s`BC#|C#xq?}BeUyUuhUq|XJi874t-nz!bN_5R% zwU2|&x#oHlF2glY{W@6vn}}|Emv#PO{$hOlLF=h8*N6QT=-u!(*xK(w*O=Ac1X;h~ zu>Ay@OV+m-TP@s%DNtU`OY_?Y2i3MULoWgSQ|_5R{4}R0p!%z4+5+iQ4ZRaHpu3{F zIzt`O&2O`k9Ic?*;*6h%b`=c4X|QwKhHiJb)%V}1P9DwWCRqJ7e?#ck-mUH%y4G5E z%>3`5Z~7aXSi4iocPp3i<989PzT_}ueK)h^Bt~cEF<7pyY`%U!{^g*1ZE=#iKRKN@ z<-)fa=D~94{O3Fed^Pq(FJ5`>f!1^NZ-PJWux=dt=U{auA42-wiu$kDCPr^i68v1! z=ioBvEzo#Q!G|ykdN+K3)jqUdo%L+Q?gy=%pEFlo=RV`N+IlskHgXie8}KvaQd{p= zJ8b#w@W-NjPzybvJsyD@@I73Dv#{oV`|;29|KAD({x4M&1haWTaKR<`FNB7bqGZEz zY&4N-cz-&TC>l&I?=4HFdK1an-xnVJI9Rk)TL0S0D-Xs~K`_1q3qde_JqQL<31|pn Y%dwT%N*P+-Xo8&Nejx~!V}8ZpABV|x`Tzg` literal 2118 zcmV-M2)Xx(P)RT(~arVF-3X?a8o@+eOO1vEksNT^L4i?pS? zGjpFa_ntF5TNVgSR!EH+O{o}6G@z1bNRVez0u;Kt_nv!ax2u$A6CgkW0YZ2+L`XDR z1#DW{()IiQb7pobr6JWx{@i=coOAyFeE;`9t`LXuTbZsA!xQ~t-Jh2TFH3}{6DQEJ z6zHVn=d$E!>4ZfC^CXFAOg6;-{0rK#2(l(bi6EE4Cxy8zUvSIUSxJyd0Rx1evq8d3 zha9Xa(>gb=iy)OEOqCGRhoRgjg}D-58;WpffF}-SLzdsS%z?raVZb67@GTf{F2-MV z(;;3%66v9mpUF~Vb13?^4dbll7gOv$>{{hgcsXEBn}Asfe+!Jr!P=_3OLR`PC=u47m}Isz}7LsTJhYKlCX6 zBrpm{_G9fwFm8vh)jxegBJUdaX<*jugv4$kh1*sRUB<(^s6k0J8xl1@Q`Ifu62!Wz z+yV4rnwc|67!;s5J#&f^`FEE?D^M;J+P z;%n0lV?YH4c$so)2pvDO1^^yEi{W=B-2JRDm%Hq(_dtH+>c$*)kzLPGfJosn$QKta zdXmew2L_S72C-xyFa#|NKOLOcpAXIQu&HjCTdHZ^SoVznTV2RCE8l@Qznmh#O=J3h z78I6XfMX0$4v)2*l}sob3GuObZu4h&@jgg+93dg9d26nxo0q_V3qw69jAg11h#;Qj zDR}?8_2qtS+zU2;*M?vpB_R1gT_ocp*w^H!af_x%#v;V~H0>t?U?2=j)mQNTdY7PD zZXhCJQB%m#rURBP$K+3N@Hbh3=G!-{-;CwC{F!BN-%?!>mGOpHxy46*@Pyi|a1O0SL$oa(Oxy+yS{A3FTxaVkXbQxJ`r$#~X7z z9fPQnAa>SWcDz`7_lT%XxTM6vdWYOb$_E}95$<@4!#JM08fQ1lVbNqhSso#BHJ{WcsMGC+s#y>%;d%dC-$XAo6C?u463wTSt8Zevs@3$fuj%5eDahUm$bsR1c?k;$bnU{Q6G z%e5hDFGq%yXJFl#IBPZxFwkdI8<>z~c0H(G+CkpL$0@rrh6 z!b;0^Hrf0IDAoPZmRK~kif*_X;|+K=K;SP^z5r6+!1y}IjgWpAu)v^VWaa$>qR}3v zGas{V*m7Xe(PRkxXg2%`;~!Ar2(tJz&iRIrFF>whcV)?!F!w{qpRoSdE^(;fig+sT z)pDGaKyHFu>ZNk7Z#Xh)4S3=J0}u%!EL15d*q8U%n?De0HMc&=a~u3_7^$sr*=Z5=#{DWog{4r;P%E_h zCCAPZsfPA)*!UqQk7VpavYAR>lqbtMjYx2N<{jkw26<%#wZXJgG+ z*N|LpM^^j=o(nl5vj6G{7H?h8Y>jY>(6n6>)&N^XP*^gaKLT)S=|n$IDgsqZlJ*-%E4s_CX$-kA59MkIQa@fv`6?8@k zw^$U8So06Ne!n&3U&N(q*60gNWKkFOY>#U${)_>uw%0_Zh=dv&7HaewVf{yk?y^PX zX*3dZO~zAYCT&K^hMG}%GUjzB)AbYvw~dZ-5; z!<>{o530&fZU3Nf`+3q7K-7m>-d9&P+7gDpAywt9R6xgS?w{vDC|LpBIEbSh$nHyP0=?P zw;tMn89qqS+)N~k&F7e|6B6ir;v;d3??cJ&F#iP?H%Mm!b#eF8VSrZkti zGFk(^_;+E!A%^ce)A_=Ha+r79E$ViFRx$_Ca4go%YaylE-qQ4i87Y>Id~#4Me|QZS zy~FwqZM;@g@x?SS6;hRRY?lL)suBzkoldE#L;6}S+wRy2CSwue3)wHE_`m)L)*x*d wcr!_T1R3R2QHrnKyh^M|E8>b`?IF+j55uL_p0enzz5oCK07*qoM6N<$f=9md3IG5A diff --git a/packages/dashboard-v2/static/mstile-144x144.png b/packages/dashboard-v2/static/mstile-144x144.png new file mode 100644 index 0000000000000000000000000000000000000000..ec40c3e02c28b36e5a95c103c7e8fb8af4fe853c GIT binary patch literal 9842 zcmV-&CXLyNP)oXO>c+km`=m(Fbz{1Z$&OLgu#7! z8E*An335>o0nxKT%ZrK%NQ##CpD%@Z!EjM3|9qn zN>0fs`BN2P^cJ9F<(W6c^^5WSK82YA7&o!w{B|?(iF=LDw-^?~al~{yX~}O+VTwKQ zBFDGPN2)ovK`}*oOakL;k1B0;vS4x}5L@yZwWzcC@)`u=OP?g>loZG`%FX$(lH^wu z_T^!GhA>pGlDTFi95y^tULlA@UkQ^B}!;wCn9s1t%oN z?Lase<%usdx6n}@CwlddiNcwnXM{55bca2jZQO}Cd=$97sC#uaZqM}XIX&A^Mm zuL+t5$hNhwUMB=5d7f;^yBRK~tfP$rQ>9a9F;O@J_yEesK$jvi-<+^Jhh+Om9!AtU z6$4e{Yx=;T`w-a-JPkY-4|$`n{{%6<4wL{#RagPepA z7z9HJt{UbL=rgEnK!^yMM?I($vIC9My7aA3PC5DIwZrMarNFI-2EerR9dz%ec+v|n ziFMJ$|4A&3^wJpuW6F39;UQGNN4;e`;*+rQLt*kP&?se86-Z0FF$0k+P+bAC*xd6R zKSiY1PX@(^#OdNV*CWO3LF9gvN2oUsl(bKg|2Z+tpdDz^J)bVF9Zo~I7}YhvIlah8 z3xJlibB_J_0=VRdniFEx5h z2jv-r+XDfN*~5D!a||WRw`3o8ArG zWilAp8+W27@pCkJZ8%m;5s}!>nCPYte;kE1ln~*5&{=pTkNBGerog`$D@MKz++h)t zW$iy!%+w?jqi`nh0C2s*3`hWu3NtDqadd>_tH9ONTRWM8JWv80RbfTAET$cvf#~;9 z3A!2;c(_>On*d!Dl$4nTX5=-T|C${^~STYGWZAb1`}Z(x;M;3AZ#G1Dn5v7W?SQ$GMkCG&=sR+KvVjOmjsl+` zXl@*t&LtSJP86B3JhSF2(8c(PsVH0k{0cZD(-3xBU!OYXVZ3D8 zK$v!84#=&*7ZIJ^t;{fFqrn^k{VRgjYa`d$gAwOM*#(rG^AS+l<0w20)fW-YC07O| z0OcsE-$7&*u(!k~aCIxgRH<)uOw_1>%meNLt_7XuuUFq><1XN@;#VJ|)!D&Jo=9vr zYQXn_tGp(97y?jbJHpKQtm}8D^AurH3}S2v`TY5Eua=$#cNv1kGb((K(jM z6NypdPLQ>w#>LjK9CHl#I;yLz30XdUiXMu7Fch309214JP+bf18K5>C*{A?_Abg#m zl_XB20}XCn$`p#i3qgO5GNWgGeCDJd0#NsXEW^w(9=2mt#T3bK7~^PPh42swtuZLs z2!}xG1kKmSrSs&7#CCWZ=s$y;neG&>xZbhPTkeu<+klS|G*Fm^<7||t5m}fe z5}k)DAxeE1(Jd(Nr{40-xgJ`4VRp?)FAl}4E!N@R*?WIwF4!yaHI(#>cXE+a!xomVjJ8E}eZmkZ&yXMQARb z91KL^2Y{bq)+5S>rCupIug`&e!g}3MRQV!qt18B&I3|aQ!a2Zy2bN}`mHCdnDDS4; z+&^la?T+9AYSuqI=kff`rneh2fctwPsycO6>#u$6^PUw{p9i^`pn1qsZrM0K2qw=j z>R5lrhY6bdfy;rHOoG);xz2S4GZ*2@1yiJZV)Nu3laux1qeN+ac8c3tdJv zIZn>0=jl>jLgeEF%_ElHE@$D&uoxdFV%O1k?PxJU^C0L)fmeGphD#*c51YC zqG5V6n4q;E^us8-yL^w`KB=hI;)Hsb*{IwRb50}E+1C;5j#OrC@=RM&m%BjXH|!Ey z7NPfqi1p9Gbk75@9}{iu&8di6k8xq__L)2;XuSno4RY96>f{o~imTO`Y>aR{W)9QH zboQBZ-^D&D_S&PyB1ArI9tej$22$^J@-W)f;bwy7_MDPz9g7^nQDBb0)SFvTy`}pg zc16-{Xg{opD6>It7^ONj+KoHSgeWVmA0NjjQCLG|Ip}mV9I0h&)S}(v-#$#Q?hk`J zQ&3(NYdLC6*@HE1OcV5pUfAxq2llaxQI^GX&PSq84Ok2Md)kf9#TgIRd5n?)@X6kA z6h9eiInSz=bw2N)6P9hbS7C!U|@Y} z2pdu6fqWCy-w=h@#>=DhF#Sl>m<{?UFuj-Pkc5?pL_LPcEd;G3T+fT1e1FG*aj``* zeoWBZ2i#gpBtn*KRK0Fg`qV%^4sspBeuPE9X`cHU_`!$ve{AGDa-4(j058~o_qcA!H7JM>c(!Hk!n9DK1pFNrQLN~hSJ9{ z(NPG>8KCPB`CE(O+=A*VL|(F{1^7ZcTjCHtoCbOo$V$*faVM z$S;9sX*bUIWS%cU^C&^<2~^(;@&%MV)rmy?20_c643#(Zj2n~Jn2@DCCXWf4Z=gI< zfk<@8#*dCdAF)oDMr$`fWHIn4=Bonh0@;Y_8iefxEnjEK@3~Q97RYVD7eH+;!V%ev z@*e6b&d1gu87boec5(?xhEOAgK;64G9#<>3A z)W8JIw}GZfDj*V5WFvDCIcr#beCFI-5Ht@HG*<$3M7LY4`3!^`fIkq0_r|?HPwWDT z^W8(xydC7-z;{rNSVZCx%s26_@_D*W8Z(vUew3qyM50SJdf)K(CwcxruQ7w>D#zKzIQ%(86uXTepR?i%gz0)#^q zreB_tJc$~YqVf|fil*0bEXTU%6YWR%w{e6$koY=~I}WBhKorhJxevI;oXfoA+KF&C z$dmE33ttB+a@yRqBFivIOp&fr0~3X_P<{{0Pj!^kxAqn@Ep%eKWCsK4lSE;ObjWrf zGHJ#dT?5=t`t2^(Y{PB9YS16X5t}V`=k!Yy0?Y^AE_g!9^BE1s?OanA(+=0gK58tU zc~xn-nxOgAp!(QhJO!EfGm66bDC-ct*dHmwT!$!}iLwOYbW}GZ zvfEi~($(9a&u|#mA{C_{e@ql!3i>0HR7fNy2VWs*tsGPzaS~k+R+^h((ut;_+<>qa zWmfu=6OsyafK9+klvk{kFseOm?Ql*!m*qXcv!FjCXdO#o$|I*?FuuCywb${*w8L2l z{}7e`=VHL=>*qY?^^lS%? z8uNhVAQuB0fyY62I;3WKK54zD1B+ta-lX02QX?eHHFT~bUW#-j2XqW{rx zGb)!==0xW?R{r!ToB?_#%1T70Sz6Mg*8wEwxIe;U@OAjaegK|GEBR1CCCrDzcZAJCFZm6KaZz}^j%h-1uDv< z8m1l2MsyAEIou6U?5D!i>Hx|&5P86=h+R&8d1g7_B?xO!E<`wrvIWs~z;gtx!F7m$BE(E7I=*+o)&gglb~;=lEM-8LAf} zG85GU2wURW3Y#!iZ!Dh=_bpL42jzbQb4rNBtyRVde-Hpf^%<7{)r`9d2_qW}cj>r|5jn2T<1O6HDEr< zwFsXAT@;gY$3XWOe@tFP*^KDhPNZ1YPNTz^C3OA(vapay>~*HAskb%`Qr2KZqWwDx zYbD%_U9qb`?gQpk{Iq#Ha5t(Ose5lmepzO#%j-ez0(viem3;_L0^cQQzFL}3?|eF1 zZHLo<3lWw9m(iWjrI;BEYy;hl$cw<%cxCx&w8bbeQTQuhNd+Pi;1+`B!-JGH9Fb@g zT?6`$ATL;9d0wZ)yuH_lK;j*De8XDC%>Ei!joG!v?$|!gB3*}e<1~cNf!t1a7efW4 z1H6K=9^o031Jt_@g8Lxl@gudEF`s9aWRYc{i$UCWJOupOIOFmHu$_7;>dB)XigYN( zMB&rG73D;t0Nh2;{D(ox8U>N~EXMbE5Oifc3Enp(^u(-zb3^>{b#|KIvSux2E4~R> zP0-xpq!&G{ahZ*IAj?rcgXoM@S)%(epAN0ZY>ew(UBrp>+RN;o7?|OWD^Q)4CGG&^ zZIlRjF{UBju*$4fRv9J=*MZ(pP9y@zR|%Rc1}STJA~6b|1-;B9%XZ*KjLG)p)jKv0 z_9BFJpcj&nT=J`f%JaZ#gjX$#l-HOxKT-o-0I~|<8qn!ZSsmbYlt&TWNYL6_khi~H zJ*zYaxCV3?$k}9eiB6Td8`y;MbA$-9nylS^`DNu{qHrB>Qz?;XdeAornzs&8*6>7P z6#fLWkajG31d)4y|5_m`sS!1%qjDRP?|040LYJlhk#d{j@rwstUMFJoriKWa3!L%3dudwe%nAdfxHO1g`joBQ-;58 ziL@K{B7CWoNCZ%Mn0oV;zUmdrpkci2ME?lovTnooBCJ;sT}IH_?olc`#6{t`D35}k zlgcNxO+j+GT^7fH#}L-W%yEB_MAQg?yHPIkmSv8&BRq=o6!q@Pr&x8UcHC~vLL{+D z=NYSHm5Ej7ZdLU#h#Br+6T)_D8_a^T!iNxUvNEEetcMAjpBpgCfHy4y?Kjqo*!cRu#l%M3N2M)k`er>CCY z%myfO81y-W4Jezbx9nM%Mb4<(k*1liB=kCvYf+u+DJ#w@SD!<`HiQ>Yt^heJN9S}t z!ovjK4pgjjoRfWXe9;)5G}}pBi*RQb*>%oxjGO9Hh!+w=bZCb)gex##YRvOw zmS0W}veUeilPCM0*=SZR`66&D-PZzzNk>p7Z(ChK(`hUIu&$xF{c6g(R#* zBqklmuTO!_zA&B~us@@A<2FR@?dfa3dr8b?=C#Fc;1=L{YaU8|XEL7-Jpg*Usk%VJxn`Xh}nAllO!w7`pQkqF5n524b;0n zpl?V>#6NsQ;Vj@{lp8^prsrFEq(9^I-w2w^`_d=IxE9FQfWVa+*md-Ro1z zW+JE^sD6}sYllbKba~w=7PU!SF0AFwCJVeS*}zmdC9oaO4|os%yX!IxMaRgwqv&&=OD5kIJcN=bgfVZ za|~#rdJks5RLC}BKC#vgF9BVJ$a(2XOZrA;H<9arY)0cLxpnVQUhOyv=Yxi*G!Pbf z%F5H{An+H~)=+(wTV#Q%SRx~4>cEAWC%ijUB|t09#=w4*KaWFTpDsmZ&jMBgU!uF1 zxl>kkLh=x*2^s0`HCC)wJDh=VC910tIWyH;6UViPBvkf*Jc+OY*zS49S0uJeF$0mM zD4#;O6xA7pL?Ut*=s)DFwo+R6K`l^PqVPUcZ%aSk*3i)%PLd+Mm^$@lRHkr_)XYvm ztV3Cp&fn!dpq!AD1EBYze2aR^-tDlMyE1xA2W~+1E<{exA?_$4_g=zGGx>2$h8FoG z`TDdQ^AWBExei#I(!oqIN#0qO*Qf=BKzb=nHL0hOnyr>s(5 z`{dCCBgMF3yn9i#jM^axe*_j(A`-nAI-u_(X#F~;BK=7e&O^B$xH5aM`nZ89UDyahpAlii0b%`y z>=T~fiK6f!RBx(GB>FJ$Aob?01yX?Z!tCc{Ux@ zSpGz}Vcf_k<#QZF`FGS?NjU44=X)~BF;RFXhQRwkb+VD3j$ZCW0oeqs0-}Pb$rrKJ zFjHR*hm_02d=vN(upE&i8GVu))9n~I;lHJ?O-ZOOMfsn=4~RnhE8Lp( zH|wX>o5T_4-vA#5u@=?xm4)-1WiYc4t_S@UBL74bevx)Kx3WG%UsIbPt51g8&J;k>SG5+;Mdhp%5@O=9&k57^9}NcUEfe!1Fpin zqgzyw04&2C1=)zO9%CUBt5mK}AIC*ue3cuPmZ)(J8oyZWhe*s|xRIdwSVbNB$C#Oq zUk3gjm{v$O+A|Vuo%2XS;SefKgnKZPScVk6{yauFq5!?KGH#X19Stz_dwq6 ziy$q*3~GV=Vs6a8pv>t$*+4}i(MsnnMBW{*wK$$m1ketbfIf;OJ1SZ_q~75<)+wI= zv>%3psD2CKUV>K9_x@SEqQ+^cn0ZK|bIQxAqK^U`0coP#W$m9@u1^8R7yIY&0aY-E zL7oD7rk}3zz2l^kxftdH%VX0%KB+gifV>an5mb+L)v!BrNyWiVc|?*=I_CRwxvyIRAQiSJ97}f?%fXn9K`sJra}>9ai^BW?c;jus0m|*zKBFW zxiwD!i9|c|s8IuH0~hp1BziC=DMIyw@oSDEy+$4K*Jy|D z!c6o!Kc%DnWLKX7n2%99z($1CpgXKdUQkBvMUCmeO{gqKm|sDkn+ckaRL(!=*w=vu zClXz0Hq4sl>PfKMQ@EOz`{eT!sxOw^c(S*+?#(CO*A2z`-z z<(R_=Pk^ij-Q!v5KVNqrK(tK~=?r}~JU zo_ciSKLVnUfqd4f{3JS2?B9g}W-7(v(U5zEn8PR!BHSO(S@!Abf8g8UTtx2zu0lB- zp@Xs$s7T5ix;K<90Dgv7v@zA=#; z3`F7QF&nd3ZB#~rm7V8F%;zZfQYSvia|rvv_@Y#Z!izDH+8I4)souk2-o`9N^PPB! zJYV}4>pWtN8^*gA^;=ki1G^_jjTxx?6p44pt4<_3Vuz`K@Dj?$yDL(RNAl`zezzNQ z5P1NzMq+Jfvat+fhQ3`Ot5G(_TQj(NQmFF?G2(!*ena-jEbBzRF*F&<7J~c+ciq55 z+-L=yC?XfL3;2ZDSuv%9tA9~6F$ku2J_^As3-bWog*-hndgJsuh6nng^<_mO#X64& z<60nJ1LlY7{T@eQh?zB4>w`$NLi!vG906T{%7fIquLoQme2q{Q%fmc@>bLtO5=ohH9|mTC+zb4V zc>1baZjE#U_;k+0xR$nN{q13bW+z_K<#JTN0M;Ayu9T2_gJ6tYfXdH7?_I$O_W%F} z7)eAyRE*!5RnvI{m_fsMpQCM`%k%1!1;BraazUR&VpYsx(0dU1x@T6StzTLFst#@b z<0yO==z5T#SH}^Mjm4M_!sP_b=LXVwfa9VtzDh$6CQ-Nm)n6fUMwdjZLL|};hMmCO zAWv9ty^Exu`c~_N<}1~^Q0@d~jF@c9!N^wX&G!wgbDx;;5{aGyyAp-xqWViD{%W%- zk=QQ=-41du!bWE|>FTK z4dpCEE(I>9JLO_vy{lq6z@Iq_i;k{dj!cF~Eb3%Y2&x}JcpPL#LB5Qk;g4Z_rI&!0 zF`KXKA-x?`5kHa)QPV(Y0}DXTL;24LOMv-k^3h9ui&E-veJv8sQ3ciC`ZsbFtPa`rX<=gm(MEfP{Xfbn8 zor7>z_o+{X&5|bfQc++D0XR;KatPrQpmyi6r60boGNveuFOu&xX@@g0t5@6x?p6o!9afwn zWDJ;oKW&~QM&#Qlw_A&I7RgvfjX^C?KQg%D<^|=YpzDBn0}+YCVp5ad5?Ept>|tf1 zm;(s6qI}Oy@OK`>0-@R+|Z0V^;I zMA@jKA!ec&*8-K@=tO)ybX>45*!OM4~D1c|`9cJvB9N zNJ);5D`wCzzUan|Itp{IDaM%Z&~8NeB*^@!O(X*5Q=KP4*Tp*q`G@Q&dR%0Is@$+~ z%itX=3TL6Z6p@dkT!Jv$>N&B*JtY~cfDC5jM4|wC2;>EX?*qSZHU}PE8%zK*s0Hdr zhE;s{inqgAm~YZP1YCsbLb^{GdqMvX$S%wtsk^O>c3oZUn~xI_2T2_T~=dKGLKxH49f} zIZsARCb5bI8MjO&Yk0iMJP|P?m0^{dDvjelSVdOqq`_1fUVPF|Ll26XDl%0%@RY<% zb3i_R#?Hu1DqdofWs(?MM)i=K@R(CXV!7nid#aOr6T#G+3px(ijZ88Oq$9pp zAuhfursH6I$CJSLbhD*)l4HCMQkf~MP4L*Kt<8 literal 0 HcmV?d00001 From 525583af88dc68296449da005bed439478657e86 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 15 Apr 2022 16:12:42 +0200 Subject: [PATCH 182/240] fix(dashboard-v2): allow passing additional classnames to Panels + ensure all slides are equal height --- packages/dashboard-v2/src/components/Panel/Panel.js | 9 +++++++-- packages/dashboard-v2/src/components/Slider/Slide.js | 2 +- packages/dashboard-v2/src/components/Slider/Slider.js | 2 +- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/packages/dashboard-v2/src/components/Panel/Panel.js b/packages/dashboard-v2/src/components/Panel/Panel.js index 27551ecd..fe50cc89 100644 --- a/packages/dashboard-v2/src/components/Panel/Panel.js +++ b/packages/dashboard-v2/src/components/Panel/Panel.js @@ -14,8 +14,8 @@ const PanelTitle = styled.h6.attrs({ * * These additional props will be rendered onto the panel's body element. */ -export const Panel = ({ title, ...props }) => ( -
    +export const Panel = ({ title, wrapperClassName, ...props }) => ( +
    {title && {title}}
    @@ -26,8 +26,13 @@ Panel.propTypes = { * Label of the panel */ title: PropTypes.oneOfType([PropTypes.string, PropTypes.node]), + /** + * CSS class to be applied to the external container + */ + wrapperClassName: PropTypes.string, }; Panel.defaultProps = { title: "", + wrapperClassName: "", }; diff --git a/packages/dashboard-v2/src/components/Slider/Slide.js b/packages/dashboard-v2/src/components/Slider/Slide.js index 42d354ff..eafbc563 100644 --- a/packages/dashboard-v2/src/components/Slider/Slide.js +++ b/packages/dashboard-v2/src/components/Slider/Slide.js @@ -2,7 +2,7 @@ import styled from "styled-components"; import PropTypes from "prop-types"; const Slide = styled.div.attrs(({ isVisible }) => ({ - className: `slider-slide transition-opacity ${isVisible ? "" : "opacity-50 cursor-pointer select-none"}`, + className: `slider-slide transition-opacity h-full ${isVisible ? "" : "opacity-50 cursor-pointer select-none"}`, }))``; Slide.propTypes = { diff --git a/packages/dashboard-v2/src/components/Slider/Slider.js b/packages/dashboard-v2/src/components/Slider/Slider.js index 33c3bc2a..5b902c58 100644 --- a/packages/dashboard-v2/src/components/Slider/Slider.js +++ b/packages/dashboard-v2/src/components/Slider/Slider.js @@ -62,7 +62,7 @@ const Slider = ({ slides, breakpoints, scrollerClassName, className }) => { const isVisible = index >= activeIndex && index < activeIndex + visibleSlides; return ( -
    +
    Date: Fri, 15 Apr 2022 16:53:49 +0200 Subject: [PATCH 183/240] refactor(dashboard-v2): move upgrade screen under /payments url --- .../components/CurrentPlan/SuggestedPlan.js | 2 +- .../components/CurrentUsage/CurrentUsage.js | 2 +- .../src/hooks/useUpgradeRedirect.js | 2 +- packages/dashboard-v2/src/pages/payments.js | 225 ++++++++++++++++- packages/dashboard-v2/src/pages/upgrade.js | 232 ------------------ 5 files changed, 226 insertions(+), 237 deletions(-) delete mode 100644 packages/dashboard-v2/src/pages/upgrade.js diff --git a/packages/dashboard-v2/src/components/CurrentPlan/SuggestedPlan.js b/packages/dashboard-v2/src/components/CurrentPlan/SuggestedPlan.js index 21aa9b48..ed59c382 100644 --- a/packages/dashboard-v2/src/components/CurrentPlan/SuggestedPlan.js +++ b/packages/dashboard-v2/src/components/CurrentPlan/SuggestedPlan.js @@ -14,7 +14,7 @@ const SuggestedPlan = ({ plans, activePlan }) => {

    Discover {nextPlan.name}

    {nextPlan.description}

    -
    diff --git a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js index c678585b..cac40771 100644 --- a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js +++ b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js @@ -99,7 +99,7 @@ export default function CurrentUsage() { Files { - return <>PAYMENTS HISTORY; +const PAID_PORTAL_BREAKPOINTS = [ + { + name: "lg", + scrollable: true, + visibleSlides: 3, + }, + { + name: "sm", + scrollable: true, + visibleSlides: 2, + }, + { + scrollable: true, + visibleSlides: 1, + }, +]; + +const FREE_PORTAL_BREAKPOINTS = [ + { + name: "xl", + scrollable: true, + visibleSlides: 4, + }, + ...PAID_PORTAL_BREAKPOINTS, +]; + +const PlanSummaryItem = ({ children }) => ( +
  • + +
    {children}
    +
  • +); + +const Description = styled.div` + display: -webkit-box; + -webkit-line-clamp: 4; + -webkit-box-orient: vertical; + overflow: hidden; + flex-shrink: 0; + height: 6rem; +`; + +const Price = ({ price }) => ( +
    +

    + $ + {price} +

    +

    per month

    +
    +); + +const bandwidth = (value) => `${humanBytes(value, { bits: true })}/s`; + +const storage = (value) => humanBytes(value, { binary: true }); + +const localizedNumber = (value) => value.toLocaleString(); + +const PlansSlider = () => { + const { user, error: userError } = useUser(); + const { plans, loading, activePlan, error: plansError } = useActivePlan(user); + const { settings } = usePortalSettings(); + const [showPaymentError, setShowPaymentError] = React.useState(false); + const stripe = useStripe(); + // This will be the base plan that we compare upload/download speeds against. + // On will either be the user's active plan or lowest of available tiers. + const basePlan = activePlan || plans[0]; + + if (userError || plansError) { + return ( +
    +

    Oooops!

    +

    Something went wrong, please try again later.

    +
    + ); + } + + const handleSubscribe = async (selectedPlan) => { + try { + const { sessionId } = await accountsService + .post("stripe/checkout", { + json: { + price: selectedPlan.stripe, + }, + }) + .json(); + await stripe.redirectToCheckout({ sessionId }); + } catch (error) { + setShowPaymentError(true); + console.error(error); + } + }; + + return ( +
    + + Payments + + {settings.isSubscriptionRequired && !activePlan && ( + +

    This Skynet portal requires a paid subscription.

    +

    + If you're not ready for that yet, you can use your account on{" "} + + SkynetFree.net + {" "} + to store up to 100GB for free. +

    +
    + )} + {!loading && ( + { + const isHigherThanCurrent = plan.tier > activePlan?.tier; + const isCurrentPlanPaid = activePlan?.tier > 1; + const isCurrent = plan.tier === activePlan?.tier; + const isLower = plan.tier < activePlan?.tier; + const speed = plan.limits.uploadBandwidth; + const currentSpeed = basePlan?.limits?.uploadBandwidth; + const speedChange = speed > currentSpeed ? speed / currentSpeed : currentSpeed / speed; + const hasActivePlan = Boolean(activePlan); + + return ( + + {isCurrent && ( +
    + + Current plan + +
    + )} +

    {plan.name}

    + {plan.description} + + +
    + {(!hasActivePlan || isHigherThanCurrent) && + (isCurrentPlanPaid ? ( + + ) : ( + + ))} + {isCurrent && } + {isLower && ( + + )} +
    + {plan.limits && ( +
      + + Pin up to {storage(plan.limits.storageLimit)} on decentralized storage + + + Support for up to {localizedNumber(plan.limits.maxNumberUploads)} files + + + {speed === currentSpeed + ? `${bandwidth(plan.limits.uploadBandwidth)} upload and ${bandwidth( + plan.limits.downloadBandwidth + )} download` + : `${speedChange}X ${ + speed > currentSpeed ? "faster" : "slower" + } upload and download speeds (${bandwidth(plan.limits.uploadBandwidth)} and ${bandwidth( + plan.limits.downloadBandwidth + )})`} + + + {plan.limits.maxUploadSize === plan.limits.storageLimit + ? "No limit to file upload size" + : `Upload files up to ${storage(plan.limits.maxUploadSize)}`} + +
    + )} +
    + ); + })} + breakpoints={settings.isSubscriptionRequired ? PAID_PORTAL_BREAKPOINTS : FREE_PORTAL_BREAKPOINTS} + className="px-8 sm:px-4 md:px-0 lg:px-0 mt-10" + /> + )} + {showPaymentError && ( + setShowPaymentError(false)}> +

    Oops! 😔

    +

    There was an error contacting our payments provider

    +

    Please try again later

    +
    + )} +
    + ); }; +const PaymentsPage = () => ( + + + +); + PaymentsPage.Layout = DashboardLayout; export default PaymentsPage; diff --git a/packages/dashboard-v2/src/pages/upgrade.js b/packages/dashboard-v2/src/pages/upgrade.js deleted file mode 100644 index 61973ec0..00000000 --- a/packages/dashboard-v2/src/pages/upgrade.js +++ /dev/null @@ -1,232 +0,0 @@ -import * as React from "react"; -import styled from "styled-components"; -import { useStripe } from "@stripe/react-stripe-js"; -import cn from "classnames"; - -import { useUser } from "../contexts/user"; -import { PlansProvider } from "../contexts/plans/PlansProvider"; -import useActivePlan from "../hooks/useActivePlan"; -import DashboardLayout from "../layouts/DashboardLayout"; -import { Panel } from "../components/Panel"; -import Slider from "../components/Slider/Slider"; -import { CheckmarkIcon } from "../components/Icons"; -import { Button } from "../components/Button"; -import { usePortalSettings } from "../contexts/portal-settings"; -import { Alert } from "../components/Alert"; -import HighlightedLink from "../components/HighlightedLink"; -import { Metadata } from "../components/Metadata"; -import accountsService from "../services/accountsService"; -import humanBytes from "../lib/humanBytes"; -import { Modal } from "../components/Modal"; - -const PAID_PORTAL_BREAKPOINTS = [ - { - name: "lg", - scrollable: true, - visibleSlides: 3, - }, - { - name: "sm", - scrollable: true, - visibleSlides: 2, - }, - { - scrollable: true, - visibleSlides: 1, - }, -]; - -const FREE_PORTAL_BREAKPOINTS = [ - { - name: "xl", - scrollable: true, - visibleSlides: 4, - }, - ...PAID_PORTAL_BREAKPOINTS, -]; - -const PlanSummaryItem = ({ children }) => ( -
  • - -
    {children}
    -
  • -); - -const Description = styled.div` - display: -webkit-box; - -webkit-line-clamp: 4; - -webkit-box-orient: vertical; - overflow: hidden; - flex-shrink: 0; - height: 6rem; -`; - -const Price = ({ price }) => ( -
    -

    - $ - {price} -

    -

    per month

    -
    -); - -const bandwidth = (value) => `${humanBytes(value, { bits: true })}/s`; - -const storage = (value) => humanBytes(value, { binary: true }); - -const localizedNumber = (value) => value.toLocaleString(); - -const PlansSlider = () => { - const { user, error: userError } = useUser(); - const { plans, loading, activePlan, error: plansError } = useActivePlan(user); - const { settings } = usePortalSettings(); - const [showPaymentError, setShowPaymentError] = React.useState(true); - const stripe = useStripe(); - // This will be the base plan that we compare upload/download speeds against. - // On will either be the user's active plan or lowest of available tiers. - const basePlan = activePlan || plans[0]; - - if (userError || plansError) { - return ( -
    -

    Oooops!

    -

    Something went wrong, please try again later.

    -
    - ); - } - - const handleSubscribe = async (selectedPlan) => { - try { - const { sessionId } = await accountsService - .post("stripe/checkout", { - json: { - price: selectedPlan.stripe, - }, - }) - .json(); - await stripe.redirectToCheckout({ sessionId }); - } catch (error) { - console.log(error); - setShowPaymentError(true); - } - }; - - return ( -
    - - Upgrade - - {settings.isSubscriptionRequired && !activePlan && ( - -

    This Skynet portal requires a paid subscription.

    -

    - If you're not ready for that yet, you can use your account on{" "} - - SkynetFree.net - {" "} - to store up to 100GB for free. -

    -
    - )} - {!loading && ( - { - const isHigherThanCurrent = plan.tier > activePlan?.tier; - const isCurrentPlanPaid = activePlan?.tier > 1; - const isCurrent = plan.tier === activePlan?.tier; - const isLower = plan.tier < activePlan?.tier; - const speed = plan.limits.uploadBandwidth; - const currentSpeed = basePlan?.limits?.uploadBandwidth; - const speedChange = speed > currentSpeed ? speed / currentSpeed : currentSpeed / speed; - const hasActivePlan = Boolean(activePlan); - - return ( - - {isCurrent && ( -
    - - Current plan - -
    - )} -

    {plan.name}

    - {plan.description} - - -
    - {(!hasActivePlan || isHigherThanCurrent) && - (isCurrentPlanPaid ? ( - - ) : ( - - ))} - {isCurrent && } - {isLower && ( - - )} -
    - {plan.limits && ( -
      - - Pin up to {storage(plan.limits.storageLimit)} on decentralized storage - - - Support for up to {localizedNumber(plan.limits.maxNumberUploads)} files - - - {speed === currentSpeed - ? `${bandwidth(plan.limits.uploadBandwidth)} upload and ${bandwidth( - plan.limits.downloadBandwidth - )} download` - : `${speedChange}X ${ - speed > currentSpeed ? "faster" : "slower" - } upload and download speeds (${bandwidth(plan.limits.uploadBandwidth)} and ${bandwidth( - plan.limits.downloadBandwidth - )})`} - - - {plan.limits.maxUploadSize === plan.limits.storageLimit - ? "No limit to file upload size" - : `Upload files up to ${storage(plan.limits.maxUploadSize)}`} - -
    - )} -
    - ); - })} - breakpoints={settings.isSubscriptionRequired ? PAID_PORTAL_BREAKPOINTS : FREE_PORTAL_BREAKPOINTS} - className="px-8 sm:px-4 md:px-0 lg:px-0 mt-10" - /> - )} - {showPaymentError && ( - setShowPaymentError(false)}> -

    Oops! 😔

    -

    There was an error contacting our payments provider

    -

    Please try again later

    -
    - )} -
    - ); -}; - -const UpgradePage = () => ( - - - -); - -UpgradePage.Layout = DashboardLayout; - -export default UpgradePage; From 3ed20e670b759bf5c0ac49a79532bd38cbafd757 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 15 Apr 2022 17:02:49 +0200 Subject: [PATCH 184/240] feat(dashboard-v2): add custom 404 page --- packages/dashboard-v2/src/pages/404.js | 61 +++++++------------------- 1 file changed, 17 insertions(+), 44 deletions(-) diff --git a/packages/dashboard-v2/src/pages/404.js b/packages/dashboard-v2/src/pages/404.js index fd99104f..36c9165a 100644 --- a/packages/dashboard-v2/src/pages/404.js +++ b/packages/dashboard-v2/src/pages/404.js @@ -1,54 +1,27 @@ import * as React from "react"; -import { Link } from "gatsby"; -// styles -const pageStyles = { - color: "#232129", - padding: "96px", - fontFamily: "-apple-system, Roboto, sans-serif, serif", -}; -const headingStyles = { - marginTop: 0, - marginBottom: 64, - maxWidth: 320, -}; +import DashboardLayout from "../layouts/DashboardLayout"; -const paragraphStyles = { - marginBottom: 48, -}; -const codeStyles = { - color: "#8A6534", - padding: 4, - backgroundColor: "#FFF4DB", - fontSize: "1.25rem", - borderRadius: 4, -}; +import { Metadata } from "../components/Metadata"; +import HighlightedLink from "../components/HighlightedLink"; -// markup const NotFoundPage = () => { return ( -
    - Not found -

    Page not found

    -

    - Sorry{" "} - - 😔 - {" "} - we couldn’t find what you were looking for. -
    - {process.env.NODE_ENV === "development" ? ( - <> -
    - Try creating a page in src/pages/. -
    - - ) : null} -
    - Go home. -

    -
    +
    + + Not found + +
    +

    Oops! 😔

    +

    Whatever you're looking for is not here.

    +

    + Would you like to go back to homepage? +

    +
    +
    ); }; +NotFoundPage.Layout = DashboardLayout; + export default NotFoundPage; From c325865faa6346d19558944f502ef7b0e1bf17b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 15 Apr 2022 17:10:29 +0200 Subject: [PATCH 185/240] chore(dashboard-v2): hide notifications and import/export links --- packages/dashboard-v2/src/layouts/UserSettingsLayout.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/dashboard-v2/src/layouts/UserSettingsLayout.js b/packages/dashboard-v2/src/layouts/UserSettingsLayout.js index f008ee40..9bda3f96 100644 --- a/packages/dashboard-v2/src/layouts/UserSettingsLayout.js +++ b/packages/dashboard-v2/src/layouts/UserSettingsLayout.js @@ -10,12 +10,14 @@ const Sidebar = () => ( Account + {/* Notifications Export + */} Developer settings From 8a0bbfc2999ac61305b4a35def6092e01c58195e Mon Sep 17 00:00:00 2001 From: Matthew Sevey Date: Fri, 15 Apr 2022 12:50:07 -0400 Subject: [PATCH 186/240] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 337f9791..e2c1714f 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ ## Latest Setup Documentation Latest Skynet Webportal setup documentation and the setup process Skynet Labs -supports is located at https://docs.siasky.net/webportal-management/overview. +supports is located at https://portal-docs.skynetlabs.com/. Some scripts and setup documentation contained in this repository (`skynet-webportal`) may be outdated and generally should not be used. From 07f5352bf081d960ada7bf19e61f42a60a3813cc Mon Sep 17 00:00:00 2001 From: Matthew Sevey Date: Fri, 15 Apr 2022 12:50:26 -0400 Subject: [PATCH 187/240] Update README.md --- setup-scripts/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup-scripts/README.md b/setup-scripts/README.md index 1d032795..d5237e09 100644 --- a/setup-scripts/README.md +++ b/setup-scripts/README.md @@ -2,7 +2,7 @@ > :warning: This documentation is outdated and should be used for reference only. Portal setup documentation is located at -https://docs.siasky.net/webportal-management/overview. +https://portal-docs.skynetlabs.com/. This directory contains a setup guide and scripts that will install and configure some basic requirements for running a Skynet Portal. The assumption is From ea11c3de487d3ccba3131038541558171bf4628b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 15 Apr 2022 20:45:22 +0200 Subject: [PATCH 188/240] feat(dashboard-v2): add sharing features, pagination and mobile view for /files page --- .../src/components/FileList/FileList.js | 71 +++----- .../src/components/FileList/FileTable.js | 170 +++++++----------- .../src/components/FileList/MobileFileList.js | 84 +++++++++ .../src/components/FileList/Pagination.js | 32 ++++ .../components/FileList/useSkylinkOptions.js | 35 ++++ .../components/FileList/useSkylinkSharing.js | 40 +++++ .../src/components/PopoverMenu/PopoverMenu.js | 29 ++- packages/dashboard-v2/src/pages/files.js | 2 +- packages/dashboard-v2/tailwind.config.js | 1 + 9 files changed, 310 insertions(+), 154 deletions(-) create mode 100644 packages/dashboard-v2/src/components/FileList/MobileFileList.js create mode 100644 packages/dashboard-v2/src/components/FileList/Pagination.js create mode 100644 packages/dashboard-v2/src/components/FileList/useSkylinkOptions.js create mode 100644 packages/dashboard-v2/src/components/FileList/useSkylinkSharing.js diff --git a/packages/dashboard-v2/src/components/FileList/FileList.js b/packages/dashboard-v2/src/components/FileList/FileList.js index 6342b970..ad6087ed 100644 --- a/packages/dashboard-v2/src/components/FileList/FileList.js +++ b/packages/dashboard-v2/src/components/FileList/FileList.js @@ -1,29 +1,40 @@ -import * as React from "react"; +import { useState } from "react"; import useSWR from "swr"; import { useMedia } from "react-use"; import theme from "../../lib/theme"; import { ContainerLoadingIndicator } from "../LoadingIndicator"; -import { Select, SelectOption } from "../Select"; -import { Switch } from "../Switch"; -import { TextInputIcon } from "../TextInputIcon/TextInputIcon"; -import { SearchIcon } from "../Icons"; import FileTable from "./FileTable"; import useFormattedFilesData from "./useFormattedFilesData"; +import { MobileFileList } from "./MobileFileList"; +import { Pagination } from "./Pagination"; + +const PAGE_SIZE = 10; const FileList = ({ type }) => { const isMediumScreenOrLarger = useMedia(`(min-width: ${theme.screens.md})`); - const { data, error } = useSWR(`user/${type}?pageSize=10`); + const [offset, setOffset] = useState(0); + const baseUrl = `user/${type}?pageSize=${PAGE_SIZE}`; + const { + data, + error, + mutate: refreshList, + } = useSWR(`${baseUrl}&offset=${offset}`, { + revalidateOnMount: true, + }); const items = useFormattedFilesData(data?.items || []); + const count = data?.count || 0; - const setFilter = (name, value) => console.log("filter", name, "set to", value); + // Next page preloading + const hasMoreRecords = data ? data.offset + data.pageSize < data.count : false; + const nextPageOffset = hasMoreRecords ? data.offset + data.pageSize : offset; + useSWR(`${baseUrl}&offset=${nextPageOffset}`); if (!items.length) { return (
    - {/* TODO: proper error message */} {!data && !error && } {!data && error &&

    An error occurred while loading this data.

    } {data &&

    No {type} found.

    } @@ -32,42 +43,14 @@ const FileList = ({ type }) => { } return ( -
    -
    - } - onChange={console.log.bind(console)} - /> -
    - setFilter("showSmallFiles", value)} className="mr-8"> - - Show small files - - -
    - File type: - -
    -
    - Sort: - -
    -
    -
    - {/* TODO: mobile view (it's not tabular) */} - {isMediumScreenOrLarger ? : "Mobile view"} -
    + <> + {isMediumScreenOrLarger ? ( + + ) : ( + + )} + + ); }; diff --git a/packages/dashboard-v2/src/components/FileList/FileTable.js b/packages/dashboard-v2/src/components/FileList/FileTable.js index c2f133d6..88477648 100644 --- a/packages/dashboard-v2/src/components/FileList/FileTable.js +++ b/packages/dashboard-v2/src/components/FileList/FileTable.js @@ -2,110 +2,78 @@ import { CogIcon, ShareIcon } from "../Icons"; import { PopoverMenu } from "../PopoverMenu/PopoverMenu"; import { Table, TableBody, TableCell, TableHead, TableHeadCell, TableRow } from "../Table"; import { CopyButton } from "../CopyButton"; +import { useSkylinkOptions } from "./useSkylinkOptions"; +import { useSkylinkSharing } from "./useSkylinkSharing"; -const buildShareMenu = (item) => { - return [ - { - label: "Facebook", - callback: () => { - console.info("share to Facebook", item); - }, - }, - { - label: "Twitter", - callback: () => { - console.info("share to Twitter", item); - }, - }, - { - label: "Discord", - callback: () => { - console.info("share to Discord", item); - }, - }, - ]; -}; +const SkylinkOptionsMenu = ({ skylink, onUpdated }) => { + const { inProgress, options } = useSkylinkOptions({ skylink, onUpdated }); -const buildOptionsMenu = (item) => { - return [ - { - label: "Preview", - callback: () => { - console.info("preview", item); - }, - }, - { - label: "Download", - callback: () => { - console.info("download", item); - }, - }, - { - label: "Unpin", - callback: () => { - console.info("unpin", item); - }, - }, - { - label: "Report", - callback: () => { - console.info("report", item); - }, - }, - ]; -}; - -export default function FileTable({ items }) { return ( - - - - Name - Type - - Size - - Uploaded - Skylink - Activity - - - - {items.map((item) => { - const { id, name, type, size, date, skylink } = item; + + + + ); +}; - return ( - - {name} - {type} - - {size} - - {date} - -
    - - {skylink} -
    -
    - -
    - - - - - - -
    -
    -
    - ); - })} -
    -
    +const SkylinkSharingMenu = ({ skylink }) => { + const { options } = useSkylinkSharing(skylink); + + return ( + + + + ); +}; + +export default function FileTable({ items, onUpdated }) { + return ( +
    + + + + Name + Type + + Size + + Uploaded + Skylink + Activity + + + + {items.map((item) => { + const { id, name, type, size, date, skylink } = item; + + return ( + + {name} + {type} + + {size} + + {date} + +
    + + {skylink} +
    +
    + +
    + + +
    +
    +
    + ); + })} +
    +
    +
    ); } diff --git a/packages/dashboard-v2/src/components/FileList/MobileFileList.js b/packages/dashboard-v2/src/components/FileList/MobileFileList.js new file mode 100644 index 00000000..bd11aa10 --- /dev/null +++ b/packages/dashboard-v2/src/components/FileList/MobileFileList.js @@ -0,0 +1,84 @@ +import { useState } from "react"; +import cn from "classnames"; + +import { ChevronDownIcon } from "../Icons"; +import { useSkylinkSharing } from "./useSkylinkSharing"; +import { ContainerLoadingIndicator } from "../LoadingIndicator"; +import { useSkylinkOptions } from "./useSkylinkOptions"; + +const SharingMenu = ({ skylink }) => { + const { options } = useSkylinkSharing(skylink); + + return ( +
    + {options.map(({ label, callback }, index) => ( + + ))} +
    + ); +}; + +const OptionsMenu = ({ skylink, onUpdated }) => { + const { inProgress, options } = useSkylinkOptions({ skylink, onUpdated }); + + return ( +
    +
    + {options.map(({ label, callback }, index) => ( + + ))} +
    + {inProgress && ( + + )} +
    + ); +}; + +const ListItem = ({ item, onUpdated }) => { + const { name, type, size, date, skylink } = item; + const [open, setOpen] = useState(false); + + const toggle = () => setOpen((open) => !open); + + return ( +
    +
    +
    +
    {name}
    +
    + {type} + {size} + {date} +
    +
    + +
    +
    + + +
    +
    + ); +}; + +export const MobileFileList = ({ items, onUpdated }) => { + return ( +
    + {items.map((item) => ( + + ))} +
    + ); +}; diff --git a/packages/dashboard-v2/src/components/FileList/Pagination.js b/packages/dashboard-v2/src/components/FileList/Pagination.js new file mode 100644 index 00000000..248c03a3 --- /dev/null +++ b/packages/dashboard-v2/src/components/FileList/Pagination.js @@ -0,0 +1,32 @@ +import { Button } from "../Button"; + +export const Pagination = ({ count, offset, setOffset, pageSize }) => { + const start = count ? offset + 1 : 0; + const end = offset + pageSize > count ? count : offset + pageSize; + + const showPaginationButtons = offset > 0 || count > end; + + return ( + + ); +}; diff --git a/packages/dashboard-v2/src/components/FileList/useSkylinkOptions.js b/packages/dashboard-v2/src/components/FileList/useSkylinkOptions.js new file mode 100644 index 00000000..ad116cd4 --- /dev/null +++ b/packages/dashboard-v2/src/components/FileList/useSkylinkOptions.js @@ -0,0 +1,35 @@ +import { useMemo, useState } from "react"; + +import accountsService from "../../services/accountsService"; +import skynetClient from "../../services/skynetClient"; + +export const useSkylinkOptions = ({ skylink, onUpdated }) => { + const [inProgress, setInProgress] = useState(false); + + const options = useMemo( + () => [ + { + label: "Preview", + callback: async () => window.open(await skynetClient.getSkylinkUrl(skylink)), + }, + { + label: "Download", + callback: () => skynetClient.downloadFile(skylink), + }, + { + label: "Unpin", + callback: async () => { + setInProgress(true); + await accountsService.delete(`user/uploads/${skylink}`); + await onUpdated(); // No need to setInProgress(false), since at this point this hook should already be unmounted + }, + }, + ], + [skylink, onUpdated] + ); + + return { + inProgress, + options, + }; +}; diff --git a/packages/dashboard-v2/src/components/FileList/useSkylinkSharing.js b/packages/dashboard-v2/src/components/FileList/useSkylinkSharing.js new file mode 100644 index 00000000..0b09302b --- /dev/null +++ b/packages/dashboard-v2/src/components/FileList/useSkylinkSharing.js @@ -0,0 +1,40 @@ +import { useEffect, useMemo, useState } from "react"; +import copy from "copy-text-to-clipboard"; + +import skynetClient from "../../services/skynetClient"; + +const COPY_LINK_LABEL = "Copy link"; + +export const useSkylinkSharing = (skylink) => { + const [copied, setCopied] = useState(false); + const [copyLabel, setCopyLabel] = useState(COPY_LINK_LABEL); + + useEffect(() => { + if (copied) { + setCopyLabel("Copied!"); + + const timeout = setTimeout(() => setCopied(false), 1500); + + return () => clearTimeout(timeout); + } else { + setCopyLabel(COPY_LINK_LABEL); + } + }, [copied]); + + const options = useMemo( + () => [ + { + label: copyLabel, + callback: async () => { + setCopied(true); + copy(await skynetClient.getSkylinkUrl(skylink)); + }, + }, + ], + [skylink, copyLabel] + ); + + return { + options, + }; +}; diff --git a/packages/dashboard-v2/src/components/PopoverMenu/PopoverMenu.js b/packages/dashboard-v2/src/components/PopoverMenu/PopoverMenu.js index 1826cd92..dd5a8597 100644 --- a/packages/dashboard-v2/src/components/PopoverMenu/PopoverMenu.js +++ b/packages/dashboard-v2/src/components/PopoverMenu/PopoverMenu.js @@ -2,6 +2,9 @@ import { Children, cloneElement, useRef, useState } from "react"; import PropTypes from "prop-types"; import { useClickAway } from "react-use"; import styled, { css, keyframes } from "styled-components"; +import cn from "classnames"; + +import { ContainerLoadingIndicator } from "../LoadingIndicator"; const dropDown = keyframes` 0% { @@ -41,15 +44,15 @@ const Option = styled.li.attrs({ hover:before:content-['']`, })``; -export const PopoverMenu = ({ options, children, openClassName, ...props }) => { +export const PopoverMenu = ({ options, children, openClassName, inProgress, ...props }) => { const containerRef = useRef(); const [open, setOpen] = useState(false); useClickAway(containerRef, () => setOpen(false)); - const handleChoice = (callback) => () => { + const handleChoice = (callback) => async () => { + await callback(); setOpen(false); - callback(); }; return ( @@ -62,11 +65,16 @@ export const PopoverMenu = ({ options, children, openClassName, ...props }) => { )} {open && ( - {options.map(({ label, callback }) => ( - - ))} +
    + {options.map(({ label, callback }) => ( + + ))} + {inProgress && ( + + )} +
    )} @@ -87,4 +95,9 @@ PopoverMenu.propTypes = { callback: PropTypes.func.isRequired, }) ).isRequired, + + /** + * If true, a loading icon will be displayed to signal an async action is taking place. + */ + inProgress: PropTypes.bool, }; diff --git a/packages/dashboard-v2/src/pages/files.js b/packages/dashboard-v2/src/pages/files.js index be856d4a..b927c09f 100644 --- a/packages/dashboard-v2/src/pages/files.js +++ b/packages/dashboard-v2/src/pages/files.js @@ -12,7 +12,7 @@ const FilesPage = () => { Files - + diff --git a/packages/dashboard-v2/tailwind.config.js b/packages/dashboard-v2/tailwind.config.js index 636cd40e..141d689e 100644 --- a/packages/dashboard-v2/tailwind.config.js +++ b/packages/dashboard-v2/tailwind.config.js @@ -29,6 +29,7 @@ module.exports = { textColor: (theme) => ({ ...theme("colors"), ...colors }), placeholderColor: (theme) => ({ ...theme("colors"), ...colors }), outlineColor: (theme) => ({ ...theme("colors"), ...colors }), + divideColor: (theme) => ({ ...theme("colors"), ...colors }), extend: { fontFamily: { sans: ["Sora", ...defaultTheme.fontFamily.sans], From 581c93d0cddef21359b322c6b277a35beb51423b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Fri, 15 Apr 2022 23:16:15 +0200 Subject: [PATCH 189/240] Add stripe's publishable key for Gatsby --- docker-compose.accounts.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/docker-compose.accounts.yml b/docker-compose.accounts.yml index 3c2c46a9..468cc0b5 100644 --- a/docker-compose.accounts.yml +++ b/docker-compose.accounts.yml @@ -87,6 +87,7 @@ services: - .env environment: - GATSBY_PORTAL_DOMAIN=${PORTAL_DOMAIN} + - GATSBY_STRIPE_PUBLISHABLE_KEY=${STRIPE_PUBLISHABLE_KEY} volumes: - ./docker/data/dashboard-v2/.cache:/usr/app/.cache - ./docker/data/dashboard-v2/public:/usr/app/public From 7863faa701dda307b4f32a4026245831188767f3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Apr 2022 12:13:40 +0000 Subject: [PATCH 190/240] build(deps): bump gatsby-plugin-image in /packages/website Bumps [gatsby-plugin-image](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-image) from 2.11.1 to 2.12.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-image/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-image@2.12.1/packages/gatsby-plugin-image) --- updated-dependencies: - dependency-name: gatsby-plugin-image dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 16 ++++++++-------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 945de31f..b100c42d 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -15,7 +15,7 @@ "framer-motion": "6.2.10", "gatsby": "4.12.1", "gatsby-background-image": "1.6.0", - "gatsby-plugin-image": "2.11.1", + "gatsby-plugin-image": "2.12.1", "gatsby-plugin-manifest": "4.11.1", "gatsby-plugin-postcss": "5.12.1", "gatsby-plugin-react-helmet": "5.10.0", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 9ffd42ed..3d40f151 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -3339,7 +3339,7 @@ babel-plugin-polyfill-regenerator@^0.3.0: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" -babel-plugin-remove-graphql-queries@^4.11.1, babel-plugin-remove-graphql-queries@^4.12.1: +babel-plugin-remove-graphql-queries@^4.12.1: version "4.12.1" resolved "https://registry.yarnpkg.com/babel-plugin-remove-graphql-queries/-/babel-plugin-remove-graphql-queries-4.12.1.tgz#08e7531ed3c61aaa3c2f083ddce8040844e611d4" integrity sha512-z4Z0VkDpmoIW3cihPYEb+HJMgwa+RF77LnpgAC6y6ozS76ci3ENqfIry/vvdD6auys5TG3xYZ0eHpdPobXzhfA== @@ -6292,24 +6292,24 @@ gatsby-parcel-config@^0.3.1: "@parcel/transformer-raw" "^2.3.2" "@parcel/transformer-react-refresh-wrap" "^2.3.2" -gatsby-plugin-image@2.11.1: - version "2.11.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-image/-/gatsby-plugin-image-2.11.1.tgz#1e800b65e8c18cc524c5855b9dbdb907745fdb0c" - integrity sha512-4tfDdcczBVOL6ELKNWuXQ9h1V/5DhBMIVHmr6FPwm8xgL8ARqfQMXX2mzUjpNiu7WDiMlm9cWrTQQaZAARhAwg== +gatsby-plugin-image@2.12.1: + version "2.12.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-image/-/gatsby-plugin-image-2.12.1.tgz#302324125a1e018ff669772495f4b291bd00a832" + integrity sha512-Azofblt5ZSk2NqCOrBI1WijcJw6dVHCKz85lz6J7qB3Fvy+YVjs/vbUODlXUwi3926Q5m7C2zdH0MQrk4T0DDQ== dependencies: "@babel/code-frame" "^7.14.0" "@babel/parser" "^7.15.5" "@babel/runtime" "^7.15.4" "@babel/traverse" "^7.15.4" babel-jsx-utils "^1.1.0" - babel-plugin-remove-graphql-queries "^4.11.1" + babel-plugin-remove-graphql-queries "^4.12.1" camelcase "^5.3.1" chokidar "^3.5.2" common-tags "^1.8.2" fs-extra "^10.0.0" - gatsby-core-utils "^3.11.1" + gatsby-core-utils "^3.12.1" objectFitPolyfill "^2.3.5" - prop-types "^15.7.2" + prop-types "^15.8.1" gatsby-plugin-manifest@4.11.1: version "4.11.1" From b9046189e2817dffda9bc0f1563521d5d802a8d9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Apr 2022 12:13:50 +0000 Subject: [PATCH 191/240] build(deps): bump nanoid from 3.3.2 to 3.3.3 in /packages/website Bumps [nanoid](https://github.com/ai/nanoid) from 3.3.2 to 3.3.3. - [Release notes](https://github.com/ai/nanoid/releases) - [Changelog](https://github.com/ai/nanoid/blob/main/CHANGELOG.md) - [Commits](https://github.com/ai/nanoid/compare/3.3.2...3.3.3) --- updated-dependencies: - dependency-name: nanoid dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 945de31f..d1eac3e2 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -29,7 +29,7 @@ "gbimage-bridge": "0.2.1", "http-status-codes": "2.2.0", "ms": "2.1.3", - "nanoid": "3.3.2", + "nanoid": "3.3.3", "normalize.css": "8.0.1", "path-browserify": "1.0.1", "polished": "4.2.1", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 9ffd42ed..3dcbec79 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -8858,10 +8858,10 @@ nano-css@^5.3.1: stacktrace-js "^2.0.2" stylis "^4.0.6" -nanoid@3.3.2, nanoid@^3.3.1: - version "3.3.2" - resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.2.tgz#c89622fafb4381cd221421c69ec58547a1eec557" - integrity sha512-CuHBogktKwpm5g2sRgv83jEy2ijFzBwMoYA60orPDR7ynsLijJDqgsi4RDGj3OJpy3Ieb+LYwiRmIOGyytgITA== +nanoid@3.3.3, nanoid@^3.3.1: + version "3.3.3" + resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.3.tgz#fd8e8b7aa761fe807dba2d1b98fb7241bb724a25" + integrity sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w== nanomatch@^1.2.9: version "1.2.13" From 4eb5683168688e223f274a872797ff78ad3bc8c5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Apr 2022 12:14:02 +0000 Subject: [PATCH 192/240] build(deps): bump framer-motion in /packages/website Bumps [framer-motion](https://github.com/framer/motion) from 6.2.10 to 6.3.0. - [Release notes](https://github.com/framer/motion/releases) - [Changelog](https://github.com/framer/motion/blob/main/CHANGELOG.md) - [Commits](https://github.com/framer/motion/compare/v6.2.10...v6.3.0) --- updated-dependencies: - dependency-name: framer-motion dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 945de31f..a5b1a586 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -12,7 +12,7 @@ "classnames": "2.3.1", "copy-text-to-clipboard": "3.0.1", "crypto-browserify": "3.12.0", - "framer-motion": "6.2.10", + "framer-motion": "6.3.0", "gatsby": "4.12.1", "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.11.1", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 9ffd42ed..fcddda72 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6068,10 +6068,10 @@ fragment-cache@^0.2.1: dependencies: map-cache "^0.2.2" -framer-motion@6.2.10: - version "6.2.10" - resolved "https://registry.yarnpkg.com/framer-motion/-/framer-motion-6.2.10.tgz#7fb300d4c559f0991be5499f99d055a04851fcb3" - integrity sha512-nfkpA5r3leVOYJH0YXV1cMOLNJuAoznR3Cswet5wCIDi7AZwS62N+u0EmGSNG1JHtglDo5erqyamc55M2XICvA== +framer-motion@6.3.0: + version "6.3.0" + resolved "https://registry.yarnpkg.com/framer-motion/-/framer-motion-6.3.0.tgz#0e50ef04b4fa070fca7d04bc32fb1d64027b7ea7" + integrity sha512-Nm6l2cemuFeSC1fmq9R32sCQs1eplOuZ3r14/PxRDewpE3NUr+ul5ulGRRzk8K0Aa5p76Tedi3sfCUaTPa5fRg== dependencies: framesync "6.0.1" hey-listen "^1.0.8" From 48067ac1016b955cb6e4ecfca9ff5f049ae1145a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Apr 2022 12:14:13 +0000 Subject: [PATCH 193/240] build(deps): bump polished from 4.2.1 to 4.2.2 in /packages/website Bumps [polished](https://github.com/styled-components/polished) from 4.2.1 to 4.2.2. - [Release notes](https://github.com/styled-components/polished/releases) - [Commits](https://github.com/styled-components/polished/compare/v4.2.1...v4.2.2) --- updated-dependencies: - dependency-name: polished dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 945de31f..a2db5944 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -32,7 +32,7 @@ "nanoid": "3.3.2", "normalize.css": "8.0.1", "path-browserify": "1.0.1", - "polished": "4.2.1", + "polished": "4.2.2", "postcss": "8.4.12", "prop-types": "15.8.1", "react": "17.0.2", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 9ffd42ed..0098cc19 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -9609,10 +9609,10 @@ pngjs@^3.0.0, pngjs@^3.3.3: resolved "https://registry.yarnpkg.com/pngjs/-/pngjs-3.4.0.tgz#99ca7d725965fb655814eaf65f38f12bbdbf555f" integrity sha512-NCrCHhWmnQklfH4MtJMRjZ2a8c80qXeMlQMv2uVp9ISJMTt562SbGd6n2oq0PaPgKm7Z6pL9E2UlLIhC+SHL3w== -polished@4.2.1: - version "4.2.1" - resolved "https://registry.yarnpkg.com/polished/-/polished-4.2.1.tgz#e38cdf4244b3bea63f77b0f8ab2335e22a66bd08" - integrity sha512-vRkUnHBwVX7kIeCzCghcLCWoDenV+sV7lkItnmTc7bb6Uzbe8ogU1FxqEW8+dXCxUX8YW8vusQ0HTk2yES7bfQ== +polished@4.2.2: + version "4.2.2" + resolved "https://registry.yarnpkg.com/polished/-/polished-4.2.2.tgz#2529bb7c3198945373c52e34618c8fe7b1aa84d1" + integrity sha512-Sz2Lkdxz6F2Pgnpi9U5Ng/WdWAUZxmHrNPoVlm3aAemxoy2Qy7LGjQg4uf8qKelDAUW94F4np3iH2YPf2qefcQ== dependencies: "@babel/runtime" "^7.17.8" From 075f1aa113b322fd3ce8a6242be662bfe3524f88 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Apr 2022 12:15:15 +0000 Subject: [PATCH 194/240] build(deps): bump next from 12.1.4 to 12.1.5 in /packages/dashboard Bumps [next](https://github.com/vercel/next.js) from 12.1.4 to 12.1.5. - [Release notes](https://github.com/vercel/next.js/releases) - [Changelog](https://github.com/vercel/next.js/blob/canary/release.js) - [Commits](https://github.com/vercel/next.js/compare/v12.1.4...v12.1.5) --- updated-dependencies: - dependency-name: next dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 138 ++++++++++++++++---------------- 2 files changed, 70 insertions(+), 70 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 86f4e5b7..e06e8d53 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -20,7 +20,7 @@ "formik": "2.2.9", "http-status-codes": "2.2.0", "ky": "0.30.0", - "next": "12.1.4", + "next": "12.1.5", "normalize.css": "8.0.1", "pretty-bytes": "6.0.0", "react": "17.0.2", diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index c315e931..3b617f13 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -77,10 +77,10 @@ resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz#b520529ec21d8e5945a1851dfd1c32e94e39ff45" integrity sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA== -"@next/env@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/env/-/env-12.1.4.tgz#5af629b43075281ecd7f87938802b7cf5b67e94b" - integrity sha512-7gQwotJDKnfMxxXd8xJ2vsX5AzyDxO3zou0+QOXX8/unypA6icw5+wf6A62yKZ6qQ4UZHHxS68pb6UV+wNneXg== +"@next/env@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/env/-/env-12.1.5.tgz#a21ba6708022d630402ca2b340316e69a0296dfc" + integrity sha512-+34yUJslfJi7Lyx6ELuN8nWcOzi27izfYnZIC1Dqv7kmmfiBVxgzR3BXhlvEMTKC2IRJhXVs2FkMY+buQe3k7Q== "@next/eslint-plugin-next@12.1.4": version "12.1.4" @@ -89,65 +89,65 @@ dependencies: glob "7.1.7" -"@next/swc-android-arm-eabi@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-12.1.4.tgz#c3dae178b7c15ad627d2e9b8dfb38caecb5c4ac7" - integrity sha512-FJg/6a3s2YrUaqZ+/DJZzeZqfxbbWrynQMT1C5wlIEq9aDLXCFpPM/PiOyJh0ahxc0XPmi6uo38Poq+GJTuKWw== +"@next/swc-android-arm-eabi@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-12.1.5.tgz#36729ab3dfd7743e82cfe536b43254dcb146620c" + integrity sha512-SKnGTdYcoN04Y2DvE0/Y7/MjkA+ltsmbuH/y/hR7Ob7tsj+8ZdOYuk+YvW1B8dY20nDPHP58XgDTSm2nA8BzzA== -"@next/swc-android-arm64@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-12.1.4.tgz#f320d60639e19ecffa1f9034829f2d95502a9a51" - integrity sha512-LXraazvQQFBgxIg3Htny6G5V5he9EK7oS4jWtMdTGIikmD/OGByOv8ZjLuVLZLtVm3UIvaAiGtlQSLecxJoJDw== +"@next/swc-android-arm64@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-12.1.5.tgz#52578f552305c92d0b9b81d603c9643fb71e0835" + integrity sha512-YXiqgQ/9Rxg1dXp6brXbeQM1JDx9SwUY/36JiE+36FXqYEmDYbxld9qkX6GEzkc5rbwJ+RCitargnzEtwGW0mw== -"@next/swc-darwin-arm64@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-12.1.4.tgz#fd578278312613eddcf3aee26910100509941b63" - integrity sha512-SSST/dBymecllZxcqTCcSTCu5o1NKk9I+xcvhn/O9nH6GWjgvGgGkNqLbCarCa0jJ1ukvlBA138FagyrmZ/4rQ== +"@next/swc-darwin-arm64@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-12.1.5.tgz#3d5b53211484c72074f4975ba0ec2b1107db300e" + integrity sha512-y8mhldb/WFZ6lFeowkGfi0cO/lBdiBqDk4T4LZLvCpoQp4Or/NzUN6P5NzBQZ5/b4oUHM/wQICEM+1wKA4qIVw== -"@next/swc-darwin-x64@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-12.1.4.tgz#ace5f80d8c8348efe194f6d7074c6213c52b3944" - integrity sha512-p1lwdX0TVjaoDXQVuAkjtxVBbCL/urgxiMCBwuPDO7TikpXtSRivi+mIzBj5q7ypgICFmIAOW3TyupXeoPRAnA== +"@next/swc-darwin-x64@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-12.1.5.tgz#adcabb732d226453777c0d37d58eaff9328b66fd" + integrity sha512-wqJ3X7WQdTwSGi0kIDEmzw34QHISRIQ5uvC+VXmsIlCPFcMA+zM5723uh8NfuKGquDMiEMS31a83QgkuHMYbwQ== -"@next/swc-linux-arm-gnueabihf@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-12.1.4.tgz#2bf2c83863635f19c71c226a2df936e001cce29c" - integrity sha512-67PZlgkCn3TDxacdVft0xqDCL7Io1/C4xbAs0+oSQ0xzp6OzN2RNpuKjHJrJgKd0DsE1XZ9sCP27Qv0591yfyg== +"@next/swc-linux-arm-gnueabihf@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-12.1.5.tgz#82a7cde67482b756bc65fbebf1dfa8a782074e93" + integrity sha512-WnhdM5duONMvt2CncAl+9pim0wBxDS2lHoo7ub/o/i1bRbs11UTzosKzEXVaTDCUkCX2c32lIDi1WcN2ZPkcdw== -"@next/swc-linux-arm64-gnu@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-12.1.4.tgz#d577190f641c9b4b463719dd6b8953b6ba9be8d9" - integrity sha512-OnOWixhhw7aU22TQdQLYrgpgFq0oA1wGgnjAiHJ+St7MLj82KTDyM9UcymAMbGYy6nG/TFOOHdTmRMtCRNOw0g== +"@next/swc-linux-arm64-gnu@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-12.1.5.tgz#f82ca014504950aab751e81f467492e9be0bad5d" + integrity sha512-Jq2H68yQ4bLUhR/XQnbw3LDW0GMQn355qx6rU36BthDLeGue7YV7MqNPa8GKvrpPocEMW77nWx/1yI6w6J07gw== -"@next/swc-linux-arm64-musl@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-12.1.4.tgz#e70ffe70393d8f9242deecdb282ce5a8fd588b14" - integrity sha512-UoRMzPZnsAavdWtVylYxH8DNC7Uy0i6RrvNwT4PyQVdfANBn2omsUkcH5lgS2O7oaz0nAYLk1vqyZDO7+tJotA== +"@next/swc-linux-arm64-musl@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-12.1.5.tgz#f811ec9f4b12a978426c284c95ab2f515ddf7f9e" + integrity sha512-KgPjwdbhDqXI7ghNN8V/WAiLquc9Ebe8KBrNNEL0NQr+yd9CyKJ6KqjayVkmX+hbHzbyvbui/5wh/p3CZQ9xcQ== -"@next/swc-linux-x64-gnu@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-12.1.4.tgz#91498a130387fb1961902f2bee55863f8e910cff" - integrity sha512-nM+MA/frxlTLUKLJKorctdI20/ugfHRjVEEkcLp/58LGG7slNaP1E5d5dRA1yX6ISjPcQAkywas5VlGCg+uTvA== +"@next/swc-linux-x64-gnu@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-12.1.5.tgz#d44857257e6d20dc841998951d584ab1f25772c3" + integrity sha512-O2ErUTvCJ6DkNTSr9pbu1n3tcqykqE/ebty1rwClzIYdOgpB3T2MfEPP+K7GhUR87wmN/hlihO9ch7qpVFDGKw== -"@next/swc-linux-x64-musl@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-12.1.4.tgz#78057b03c148c121553d41521ad38f6c732762ff" - integrity sha512-GoRHxkuW4u4yKw734B9SzxJwVdyEJosaZ62P7ifOwcujTxhgBt3y76V2nNUrsSuopcKI2ZTDjaa+2wd5zyeXbA== +"@next/swc-linux-x64-musl@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-12.1.5.tgz#3cc523abadc9a2a6de680593aff06e71cc29ecef" + integrity sha512-1eIlZmlO/VRjxxzUBcVosf54AFU3ltAzHi+BJA+9U/lPxCYIsT+R4uO3QksRzRjKWhVQMRjEnlXyyq5SKJm7BA== -"@next/swc-win32-arm64-msvc@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-12.1.4.tgz#05bbaabacac23b8edf6caa99eb86b17550a09051" - integrity sha512-6TQkQze0ievXwHJcVUrIULwCYVe3ccX6T0JgZ1SiMeXpHxISN7VJF/O8uSCw1JvXZYZ6ud0CJ7nfC5HXivgfPg== +"@next/swc-win32-arm64-msvc@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-12.1.5.tgz#c62232d869f1f9b22e8f24e4e7f05307c20f30ca" + integrity sha512-oromsfokbEuVb0CBLLE7R9qX3KGXucZpsojLpzUh1QJjuy1QkrPJncwr8xmWQnwgtQ6ecMWXgXPB+qtvizT9Tw== -"@next/swc-win32-ia32-msvc@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-12.1.4.tgz#8fd2fb48f04a2802e51fc320878bf6b411c1c866" - integrity sha512-CsbX/IXuZ5VSmWCpSetG2HD6VO5FTsO39WNp2IR2Ut/uom9XtLDJAZqjQEnbUTLGHuwDKFjrIO3LkhtROXLE/g== +"@next/swc-win32-ia32-msvc@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-12.1.5.tgz#2bd9b28a9ba730d12a493e7d9d18e150fe89d496" + integrity sha512-a/51L5KzBpeZSW9LbekMo3I3Cwul+V+QKwbEIMA+Qwb2qrlcn1L9h3lt8cHqNTFt2y72ce6aTwDTw1lyi5oIRA== -"@next/swc-win32-x64-msvc@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-12.1.4.tgz#a72ed44c9b1f850986a30fe36c59e01f8a79b5f3" - integrity sha512-JtYuWzKXKLDMgE/xTcFtCm1MiCIRaAc5XYZfYX3n/ZWSI1SJS/GMm+Su0SAHJgRFavJh6U/p998YwO/iGTIgqQ== +"@next/swc-win32-x64-msvc@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-12.1.5.tgz#02f377e4d41eaaacf265e34bab9bacd8efc4a351" + integrity sha512-/SoXW1Ntpmpw3AXAzfDRaQidnd8kbZ2oSni8u5z0yw6t4RwJvmdZy1eOaAADRThWKV+2oU90++LSnXJIwBRWYQ== "@nodelib/fs.scandir@2.1.5": version "2.1.5" @@ -1686,28 +1686,28 @@ natural-compare@^1.4.0: resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= -next@12.1.4: - version "12.1.4" - resolved "https://registry.yarnpkg.com/next/-/next-12.1.4.tgz#597a9bdec7aec778b442c4f6d41afd2c64a54b23" - integrity sha512-DA4g97BM4Z0nKtDvCTm58RxdvoQyYzeg0AeVbh0N4Y/D8ELrNu47lQeEgRGF8hV4eQ+Sal90zxrJQQG/mPQ8CQ== +next@12.1.5: + version "12.1.5" + resolved "https://registry.yarnpkg.com/next/-/next-12.1.5.tgz#7a07687579ddce61ee519493e1c178d83abac063" + integrity sha512-YGHDpyfgCfnT5GZObsKepmRnne7Kzp7nGrac07dikhutWQug7hHg85/+sPJ4ZW5Q2pDkb+n0FnmLkmd44htIJQ== dependencies: - "@next/env" "12.1.4" + "@next/env" "12.1.5" caniuse-lite "^1.0.30001283" postcss "8.4.5" styled-jsx "5.0.1" optionalDependencies: - "@next/swc-android-arm-eabi" "12.1.4" - "@next/swc-android-arm64" "12.1.4" - "@next/swc-darwin-arm64" "12.1.4" - "@next/swc-darwin-x64" "12.1.4" - "@next/swc-linux-arm-gnueabihf" "12.1.4" - "@next/swc-linux-arm64-gnu" "12.1.4" - "@next/swc-linux-arm64-musl" "12.1.4" - "@next/swc-linux-x64-gnu" "12.1.4" - "@next/swc-linux-x64-musl" "12.1.4" - "@next/swc-win32-arm64-msvc" "12.1.4" - "@next/swc-win32-ia32-msvc" "12.1.4" - "@next/swc-win32-x64-msvc" "12.1.4" + "@next/swc-android-arm-eabi" "12.1.5" + "@next/swc-android-arm64" "12.1.5" + "@next/swc-darwin-arm64" "12.1.5" + "@next/swc-darwin-x64" "12.1.5" + "@next/swc-linux-arm-gnueabihf" "12.1.5" + "@next/swc-linux-arm64-gnu" "12.1.5" + "@next/swc-linux-arm64-musl" "12.1.5" + "@next/swc-linux-x64-gnu" "12.1.5" + "@next/swc-linux-x64-musl" "12.1.5" + "@next/swc-win32-arm64-msvc" "12.1.5" + "@next/swc-win32-ia32-msvc" "12.1.5" + "@next/swc-win32-x64-msvc" "12.1.5" node-releases@^2.0.2: version "2.0.2" From de824d5c3546876d132748dacb1abe48fab328c8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Apr 2022 12:15:28 +0000 Subject: [PATCH 195/240] build(deps): bump dayjs from 1.11.0 to 1.11.1 in /packages/dashboard Bumps [dayjs](https://github.com/iamkun/dayjs) from 1.11.0 to 1.11.1. - [Release notes](https://github.com/iamkun/dayjs/releases) - [Changelog](https://github.com/iamkun/dayjs/blob/dev/CHANGELOG.md) - [Commits](https://github.com/iamkun/dayjs/compare/v1.11.0...v1.11.1) --- updated-dependencies: - dependency-name: dayjs dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 86f4e5b7..d5f1e5fb 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -14,7 +14,7 @@ "@stripe/stripe-js": "1.27.0", "classnames": "2.3.1", "copy-text-to-clipboard": "^3.0.1", - "dayjs": "1.11.0", + "dayjs": "1.11.1", "express-jwt": "6.1.1", "fast-levenshtein": "3.0.0", "formik": "2.2.9", diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index c315e931..f0f1fe47 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -624,10 +624,10 @@ damerau-levenshtein@^1.0.7: resolved "https://registry.yarnpkg.com/damerau-levenshtein/-/damerau-levenshtein-1.0.7.tgz#64368003512a1a6992593741a09a9d31a836f55d" integrity sha512-VvdQIPGdWP0SqFXghj79Wf/5LArmreyMsGLa6FG6iC4t3j7j5s71TrwWmT/4akbDQIqjfACkLZmjXhA7g2oUZw== -dayjs@1.11.0: - version "1.11.0" - resolved "https://registry.yarnpkg.com/dayjs/-/dayjs-1.11.0.tgz#009bf7ef2e2ea2d5db2e6583d2d39a4b5061e805" - integrity sha512-JLC809s6Y948/FuCZPm5IX8rRhQwOiyMb2TfVVQEixG7P8Lm/gt5S7yoQZmC8x1UehI9Pb7sksEt4xx14m+7Ug== +dayjs@1.11.1: + version "1.11.1" + resolved "https://registry.yarnpkg.com/dayjs/-/dayjs-1.11.1.tgz#90b33a3dda3417258d48ad2771b415def6545eb0" + integrity sha512-ER7EjqVAMkRRsxNCC5YqJ9d9VQYuWdGt7aiH2qA5R5wt8ZmWaP2dLUSIK6y/kVzLMlmh1Tvu5xUf4M/wdGJ5KA== debug@^2.6.9: version "2.6.9" From 67f798a0dd630d2bb15f87457674e6cbee6bd1b8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Apr 2022 12:15:44 +0000 Subject: [PATCH 196/240] build(deps-dev): bump eslint-config-next in /packages/dashboard Bumps [eslint-config-next](https://github.com/vercel/next.js/tree/HEAD/packages/eslint-config-next) from 12.1.4 to 12.1.5. - [Release notes](https://github.com/vercel/next.js/releases) - [Changelog](https://github.com/vercel/next.js/blob/canary/release.js) - [Commits](https://github.com/vercel/next.js/commits/v12.1.5/packages/eslint-config-next) --- updated-dependencies: - dependency-name: eslint-config-next dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 86f4e5b7..94a07c1f 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -36,7 +36,7 @@ "@tailwindcss/typography": "0.5.2", "autoprefixer": "10.4.4", "eslint": "8.13.0", - "eslint-config-next": "12.1.4", + "eslint-config-next": "12.1.5", "postcss": "8.4.12", "prettier": "2.6.2", "tailwindcss": "3.0.23" diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index c315e931..602ac01f 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -82,10 +82,10 @@ resolved "https://registry.yarnpkg.com/@next/env/-/env-12.1.4.tgz#5af629b43075281ecd7f87938802b7cf5b67e94b" integrity sha512-7gQwotJDKnfMxxXd8xJ2vsX5AzyDxO3zou0+QOXX8/unypA6icw5+wf6A62yKZ6qQ4UZHHxS68pb6UV+wNneXg== -"@next/eslint-plugin-next@12.1.4": - version "12.1.4" - resolved "https://registry.yarnpkg.com/@next/eslint-plugin-next/-/eslint-plugin-next-12.1.4.tgz#9c52637af8eecab24dac3f2e5098376f6fc2dff4" - integrity sha512-BRy565KVK6Cdy8LHaHTiwctLqBu/RT84RLpESug70BDJzBlV8QBvODyx/j7wGhvYqp9kvstM05lyb6JaTkSCcQ== +"@next/eslint-plugin-next@12.1.5": + version "12.1.5" + resolved "https://registry.yarnpkg.com/@next/eslint-plugin-next/-/eslint-plugin-next-12.1.5.tgz#273885b35e6bbcd40ff1436d2a8d0ec03fb6f6ef" + integrity sha512-Cnb8ERC5bNKBFrnMH6203sp/b0Y78QRx1XsFu+86oBtDBmQmOFoHu7teQjHm69ER73XKK3aGaeoLiXacHoUFsg== dependencies: glob "7.1.7" @@ -786,12 +786,12 @@ escape-string-regexp@^4.0.0: resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== -eslint-config-next@12.1.4: - version "12.1.4" - resolved "https://registry.yarnpkg.com/eslint-config-next/-/eslint-config-next-12.1.4.tgz#939ea2ff33034763300bf1e62482cea91212d274" - integrity sha512-Uj0jrVjoQbg9qerxRjSHoOOv3PEzoZxpb8G9LYct25fsflP8xIiUq0l4WEu2KSB5owuLv5hie7wSMqPEsHj+bQ== +eslint-config-next@12.1.5: + version "12.1.5" + resolved "https://registry.yarnpkg.com/eslint-config-next/-/eslint-config-next-12.1.5.tgz#658cc61194a32dfd917a3db199351396ea5db1d1" + integrity sha512-P+DCt5ti63KhC0qNLzrAmPcwRGq8pYqgcf/NNr1E+WjCrMkWdCAXkIANTquo+kcO1adR2k1lTo5GCrNUtKy4hQ== dependencies: - "@next/eslint-plugin-next" "12.1.4" + "@next/eslint-plugin-next" "12.1.5" "@rushstack/eslint-patch" "1.0.8" "@typescript-eslint/parser" "5.10.1" eslint-import-resolver-node "0.3.4" From dac20c400c9cbea49df04df8c8df9b534a7b2154 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Apr 2022 12:16:06 +0000 Subject: [PATCH 197/240] build(deps): bump stripe from 8.216.0 to 8.217.0 in /packages/dashboard Bumps [stripe](https://github.com/stripe/stripe-node) from 8.216.0 to 8.217.0. - [Release notes](https://github.com/stripe/stripe-node/releases) - [Changelog](https://github.com/stripe/stripe-node/blob/master/CHANGELOG.md) - [Commits](https://github.com/stripe/stripe-node/compare/v8.216.0...v8.217.0) --- updated-dependencies: - dependency-name: stripe dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 86f4e5b7..300d23bd 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -27,7 +27,7 @@ "react-dom": "17.0.2", "react-toastify": "8.2.0", "skynet-js": "3.0.2", - "stripe": "8.216.0", + "stripe": "8.217.0", "swr": "1.3.0", "yup": "0.32.11" }, diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index c315e931..b5277ea8 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -2248,10 +2248,10 @@ strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== -stripe@8.216.0: - version "8.216.0" - resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.216.0.tgz#23c047498526d13a238c3aca7b4dc8cbbd522e46" - integrity sha512-LY8cNGizEnklIa4T82l6mZW0HS4cfzo1hNuhT+ZR9PBkmYcSUbg3ilUBVF0FCd4RP+NA44VEVfoSTTZ1Gg5+rQ== +stripe@8.217.0: + version "8.217.0" + resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.217.0.tgz#5e8ae744e0e8fca6e7c1d50c131ec3d77dff0999" + integrity sha512-CHWazNOrb1EBxTpepv5hCKMxOwF/oW3E4zRi8/LZIy5FC2y7A7NzcuE1aErYXLId3bKPe20HOmWKvjDRU2bXaA== dependencies: "@types/node" ">=8.1.0" qs "^6.10.3" From 35df124ccc425f1ddac57293c8fe767e65f91632 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:06:51 +0000 Subject: [PATCH 198/240] build(deps): bump @stripe/react-stripe-js in /packages/dashboard Bumps [@stripe/react-stripe-js](https://github.com/stripe/react-stripe-js) from 1.7.1 to 1.7.2. - [Release notes](https://github.com/stripe/react-stripe-js/releases) - [Changelog](https://github.com/stripe/react-stripe-js/blob/master/CHANGELOG.md) - [Commits](https://github.com/stripe/react-stripe-js/compare/v1.7.1...v1.7.2) --- updated-dependencies: - dependency-name: "@stripe/react-stripe-js" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 4 ++-- packages/dashboard/yarn.lock | 16 ++++++++-------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 86f4e5b7..b8dfcd5d 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -10,7 +10,7 @@ "dependencies": { "@fontsource/sora": "4.5.5", "@fontsource/source-sans-pro": "4.5.6", - "@stripe/react-stripe-js": "1.7.1", + "@stripe/react-stripe-js": "1.7.2", "@stripe/stripe-js": "1.27.0", "classnames": "2.3.1", "copy-text-to-clipboard": "^3.0.1", @@ -27,7 +27,7 @@ "react-dom": "17.0.2", "react-toastify": "8.2.0", "skynet-js": "3.0.2", - "stripe": "8.216.0", + "stripe": "8.217.0", "swr": "1.3.0", "yup": "0.32.11" }, diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index c315e931..b850803b 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -175,10 +175,10 @@ resolved "https://registry.yarnpkg.com/@rushstack/eslint-patch/-/eslint-patch-1.0.8.tgz#be3e914e84eacf16dbebd311c0d0b44aa1174c64" integrity sha512-ZK5v4bJwgXldAUA8r3q9YKfCwOqoHTK/ZqRjSeRXQrBXWouoPnS4MQtgC4AXGiiBuUu5wxrRgTlv0ktmM4P1Aw== -"@stripe/react-stripe-js@1.7.1": - version "1.7.1" - resolved "https://registry.yarnpkg.com/@stripe/react-stripe-js/-/react-stripe-js-1.7.1.tgz#6e1db8f4a0eaf2193b153173d4aa7c38b681310d" - integrity sha512-GiUPoMo0xVvmpRD6JR9JAhAZ0W3ZpnYZNi0KE+91+tzrSFVpChKZbeSsJ5InlZhHFk9NckJCt1wOYBTqNsvt3A== +"@stripe/react-stripe-js@1.7.2": + version "1.7.2" + resolved "https://registry.yarnpkg.com/@stripe/react-stripe-js/-/react-stripe-js-1.7.2.tgz#87cc5464378fb28bc7390702415cf70f13a46bcd" + integrity sha512-IAVg2nPUPoSwI//XDRCO7D8mGeK4+N3Xg63fYZHmlfEWAuFVcuaqJKTT67uzIdKYZhHZ/NMdZw/ttz+GOjP/rQ== dependencies: prop-types "^15.7.2" @@ -2248,10 +2248,10 @@ strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== -stripe@8.216.0: - version "8.216.0" - resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.216.0.tgz#23c047498526d13a238c3aca7b4dc8cbbd522e46" - integrity sha512-LY8cNGizEnklIa4T82l6mZW0HS4cfzo1hNuhT+ZR9PBkmYcSUbg3ilUBVF0FCd4RP+NA44VEVfoSTTZ1Gg5+rQ== +stripe@8.217.0: + version "8.217.0" + resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.217.0.tgz#5e8ae744e0e8fca6e7c1d50c131ec3d77dff0999" + integrity sha512-CHWazNOrb1EBxTpepv5hCKMxOwF/oW3E4zRi8/LZIy5FC2y7A7NzcuE1aErYXLId3bKPe20HOmWKvjDRU2bXaA== dependencies: "@types/node" ">=8.1.0" qs "^6.10.3" From 07f56fad02ca100d6178e4705319b4a618f49576 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:07:12 +0000 Subject: [PATCH 199/240] build(deps-dev): bump tailwindcss in /packages/dashboard Bumps [tailwindcss](https://github.com/tailwindlabs/tailwindcss) from 3.0.23 to 3.0.24. - [Release notes](https://github.com/tailwindlabs/tailwindcss/releases) - [Changelog](https://github.com/tailwindlabs/tailwindcss/blob/master/CHANGELOG.md) - [Commits](https://github.com/tailwindlabs/tailwindcss/compare/v3.0.23...v3.0.24) --- updated-dependencies: - dependency-name: tailwindcss dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 4 +- packages/dashboard/yarn.lock | 204 ++++++-------------------------- 2 files changed, 37 insertions(+), 171 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 86f4e5b7..70a78e7f 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -27,7 +27,7 @@ "react-dom": "17.0.2", "react-toastify": "8.2.0", "skynet-js": "3.0.2", - "stripe": "8.216.0", + "stripe": "8.217.0", "swr": "1.3.0", "yup": "0.32.11" }, @@ -39,6 +39,6 @@ "eslint-config-next": "12.1.4", "postcss": "8.4.12", "prettier": "2.6.2", - "tailwindcss": "3.0.23" + "tailwindcss": "3.0.24" } } diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index c315e931..236c3733 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -2,27 +2,6 @@ # yarn lockfile v1 -"@babel/code-frame@^7.0.0": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.14.5.tgz#23b08d740e83f49c5e59945fbf1b43e80bbf4edb" - integrity sha512-9pzDqyc6OLDaqe+zbACgFkb6fKMNG6CObKpnYXChRsvYGyEdc7CA2BaqeOM+vOtCS5ndmJicPJhKAwYRI6UfFw== - dependencies: - "@babel/highlight" "^7.14.5" - -"@babel/helper-validator-identifier@^7.14.5": - version "7.15.7" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.15.7.tgz#220df993bfe904a4a6b02ab4f3385a5ebf6e2389" - integrity sha512-K4JvCtQqad9OY2+yTU8w+E82ywk/fe+ELNlt1G8z3bVGlZfn/hOcQQsUhGhW/N+tb3fxK800wLtKOE/aM0m72w== - -"@babel/highlight@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.14.5.tgz#6861a52f03966405001f6aa534a01a24d99e8cd9" - integrity sha512-qf9u2WFWVV0MppaL877j2dBtQIDgmidgjGk5VIMw3OadXvYaXn66U1BFlH2t4+t3i+8PhedppRv+i40ABzd+gg== - dependencies: - "@babel/helper-validator-identifier" "^7.14.5" - chalk "^2.0.0" - js-tokens "^4.0.0" - "@babel/runtime-corejs3@^7.10.2": version "7.16.3" resolved "https://registry.yarnpkg.com/@babel/runtime-corejs3/-/runtime-corejs3-7.16.3.tgz#1e25de4fa994c57c18e5fdda6cc810dac70f5590" @@ -218,11 +197,6 @@ resolved "https://registry.yarnpkg.com/@types/node/-/node-16.10.1.tgz#f3647623199ca920960006b3dccf633ea905f243" integrity sha512-4/Z9DMPKFexZj/Gn3LylFgamNKHm4K3QDi0gz9B26Uk0c8izYf97B5fxfpspMNkWlFupblKM/nV8+NA9Ffvr+w== -"@types/parse-json@^4.0.0": - version "4.0.0" - resolved "https://registry.yarnpkg.com/@types/parse-json/-/parse-json-4.0.0.tgz#2f8bb441434d163b35fb8ffdccd7138927ffb8c0" - integrity sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA== - "@typescript-eslint/parser@5.10.1": version "5.10.1" resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.10.1.tgz#4ce9633cc33fc70bc13786cb793c1a76fe5ad6bd" @@ -311,13 +285,6 @@ ansi-regex@^5.0.1: resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== -ansi-styles@^3.2.1: - version "3.2.1" - resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" - integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== - dependencies: - color-convert "^1.9.0" - ansi-styles@^4.1.0: version "4.3.0" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" @@ -513,16 +480,7 @@ caniuse-lite@^1.0.30001283, caniuse-lite@^1.0.30001317: resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001319.tgz#eb4da4eb3ecdd409f7ba1907820061d56096e88f" integrity sha512-xjlIAFHucBRSMUo1kb5D4LYgcN1M45qdKP++lhqowDpwJwGkpIRTt5qQqnhxjj1vHcI7nrJxWhCC1ATrCEBTcw== -chalk@^2.0.0: - version "2.4.2" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" - integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== - dependencies: - ansi-styles "^3.2.1" - escape-string-regexp "^1.0.5" - supports-color "^5.3.0" - -chalk@^4.0.0, chalk@^4.1.2: +chalk@^4.0.0: version "4.1.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== @@ -555,13 +513,6 @@ clsx@^1.1.1: resolved "https://registry.yarnpkg.com/clsx/-/clsx-1.1.1.tgz#98b3134f9abbdf23b2663491ace13c5c03a73188" integrity sha512-6/bPho624p3S2pMyvP5kKBPXnI3ufHLObBFCfgx+LkeR5lg2XYy2hqZqUf45ypD8COn2bhgGJSUE+l5dhNBieA== -color-convert@^1.9.0: - version "1.9.3" - resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" - integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== - dependencies: - color-name "1.1.3" - color-convert@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" @@ -569,11 +520,6 @@ color-convert@^2.0.1: dependencies: color-name "~1.1.4" -color-name@1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" - integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= - color-name@^1.1.4, color-name@~1.1.4: version "1.1.4" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" @@ -594,17 +540,6 @@ core-js-pure@^3.19.0: resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.19.1.tgz#edffc1fc7634000a55ba05e95b3f0fe9587a5aa4" integrity sha512-Q0Knr8Es84vtv62ei6/6jXH/7izKmOrtrxH9WJTHLCMAVeU+8TF8z8Nr08CsH4Ot0oJKzBzJJL9SJBYIv7WlfQ== -cosmiconfig@^7.0.1: - version "7.0.1" - resolved "https://registry.yarnpkg.com/cosmiconfig/-/cosmiconfig-7.0.1.tgz#714d756522cace867867ccb4474c5d01bbae5d6d" - integrity sha512-a1YWNUV2HwGimB7dU2s1wUMurNKjpx60HxBB6xUM8Re+2s1g1IIfJvFR0/iCF+XHdE0GMTKTuLR32UQff4TEyQ== - dependencies: - "@types/parse-json" "^4.0.0" - import-fresh "^3.2.1" - parse-json "^5.0.0" - path-type "^4.0.0" - yaml "^1.10.0" - cross-spawn@^7.0.2: version "7.0.3" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.3.tgz#f73a85b9d5d41d045551c177e2882d4ac85728a6" @@ -729,13 +664,6 @@ emoji-regex@^9.2.2: resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-9.2.2.tgz#840c8803b0d8047f4ff0cf963176b32d4ef3ed72" integrity sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg== -error-ex@^1.3.1: - version "1.3.2" - resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" - integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== - dependencies: - is-arrayish "^0.2.1" - es-abstract@^1.19.0, es-abstract@^1.19.1: version "1.19.1" resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.19.1.tgz#d4885796876916959de78edaa0df456627115ec3" @@ -776,11 +704,6 @@ escalade@^3.1.1: resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.1.tgz#d8cfdc7000965c5a0174b4a82eaa5c0552742e40" integrity sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw== -escape-string-regexp@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" - integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= - escape-string-regexp@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" @@ -1213,11 +1136,6 @@ has-bigints@^1.0.1: resolved "https://registry.yarnpkg.com/has-bigints/-/has-bigints-1.0.1.tgz#64fe6acb020673e3b78db035a5af69aa9d07b113" integrity sha512-LSBS2LjbNBTf6287JEbEzvJgftkF5qFkmCo9hDRpAzKhUOlJ+hx8dd4USs00SgsUNwc4617J9ki5YtEClM2ffA== -has-flag@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" - integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= - has-flag@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" @@ -1264,13 +1182,6 @@ ignore@^5.1.4, ignore@^5.2.0: resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.0.tgz#6d3bac8fa7fe0d45d9f9be7bac2fc279577e345a" integrity sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ== -import-cwd@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/import-cwd/-/import-cwd-3.0.0.tgz#20845547718015126ea9b3676b7592fb8bd4cf92" - integrity sha512-4pnzH16plW+hgvRECbDWpQl3cqtvSofHWh44met7ESfZ8UZOWWddm8hEyDTqREJ9RbYHY8gi8DqmaelApoOGMg== - dependencies: - import-from "^3.0.0" - import-fresh@^3.0.0, import-fresh@^3.2.1: version "3.3.0" resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" @@ -1279,13 +1190,6 @@ import-fresh@^3.0.0, import-fresh@^3.2.1: parent-module "^1.0.0" resolve-from "^4.0.0" -import-from@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/import-from/-/import-from-3.0.0.tgz#055cfec38cd5a27d8057ca51376d7d3bf0891966" - integrity sha512-CiuXOFFSzkU5x/CR0+z7T91Iht4CXgfCxVOFRhh2Zyhg5wOpWvvDLQUsWl+gcN+QscYBjez8hDCt85O7RLDttQ== - dependencies: - resolve-from "^5.0.0" - imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" @@ -1313,11 +1217,6 @@ internal-slot@^1.0.3: has "^1.0.3" side-channel "^1.0.4" -is-arrayish@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" - integrity sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0= - is-bigint@^1.0.1: version "1.0.4" resolved "https://registry.yarnpkg.com/is-bigint/-/is-bigint-1.0.4.tgz#08147a1875bc2b32005d41ccd8291dffc6691df3" @@ -1434,7 +1333,7 @@ isexe@^2.0.0: resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= -"js-tokens@^3.0.0 || ^4.0.0", js-tokens@^4.0.0: +"js-tokens@^3.0.0 || ^4.0.0": version "4.0.0" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== @@ -1446,11 +1345,6 @@ js-yaml@^4.1.0: dependencies: argparse "^2.0.1" -json-parse-even-better-errors@^2.3.0: - version "2.3.1" - resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz#7c47805a94319928e05777405dc12e1f7a4ee02d" - integrity sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w== - json-schema-traverse@^0.4.1: version "0.4.1" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" @@ -1534,15 +1428,10 @@ levn@^0.4.1: prelude-ls "^1.2.1" type-check "~0.4.0" -lilconfig@^2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/lilconfig/-/lilconfig-2.0.3.tgz#68f3005e921dafbd2a2afb48379986aa6d2579fd" - integrity sha512-EHKqr/+ZvdKCifpNrJCKxBTgk5XupZA3y/aCPY9mxfgBzmgh93Mt/WqjjQ38oMxXuvDokaKiM3lAgvSH2sjtHg== - -lines-and-columns@^1.1.6: - version "1.1.6" - resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.1.6.tgz#1c00c743b433cd0a4e80758f7b64a57440d9ff00" - integrity sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA= +lilconfig@^2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/lilconfig/-/lilconfig-2.0.5.tgz#19e57fd06ccc3848fd1891655b5a447092225b25" + integrity sha512-xaYmXZtTHPAw5m+xLN8ab9C+3a8YmV3asNSPOATITbtwrfbwaLJj8h66H1WMIpALCkqsIzK3h7oQ+PdX+LQ9Eg== locate-path@^2.0.0: version "2.0.0" @@ -1734,10 +1623,10 @@ object-assign@^4.1.1: resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= -object-hash@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/object-hash/-/object-hash-2.2.0.tgz#5ad518581eefc443bd763472b8ff2e9c2c0d54a5" - integrity sha512-gScRMn0bS5fH+IuwyIFgnh9zBdo4DV+6GhygmWM9HyNJSgS0hScp1f5vjtm7oIIOiT9trXrShAkLFSc2IqKNgw== +object-hash@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/object-hash/-/object-hash-3.0.0.tgz#73f97f753e7baffc0e2cc9d6e079079744ac82e9" + integrity sha512-RSn9F68PjH9HqtltsSnqYC1XXoWe9Bju5+213R98cNGttag9q9yAOTzdbsqvIa7aNm5WffBZFpWYr2aWrklWAw== object-inspect@^1.11.0, object-inspect@^1.9.0: version "1.11.0" @@ -1839,16 +1728,6 @@ parent-module@^1.0.0: dependencies: callsites "^3.0.0" -parse-json@^5.0.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.2.0.tgz#c76fc66dee54231c962b22bcc8a72cf2f99753cd" - integrity sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg== - dependencies: - "@babel/code-frame" "^7.0.0" - error-ex "^1.3.1" - json-parse-even-better-errors "^2.3.0" - lines-and-columns "^1.1.6" - path-browserify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/path-browserify/-/path-browserify-1.0.1.tgz#d98454a9c3753d5790860f16f68867b9e46be1fd" @@ -1896,13 +1775,12 @@ postcss-js@^4.0.0: dependencies: camelcase-css "^2.0.1" -postcss-load-config@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/postcss-load-config/-/postcss-load-config-3.1.0.tgz#d39c47091c4aec37f50272373a6a648ef5e97829" - integrity sha512-ipM8Ds01ZUophjDTQYSVP70slFSYg3T0/zyfII5vzhN6V57YSxMgG5syXuwi5VtS8wSf3iL30v0uBdoIVx4Q0g== +postcss-load-config@^3.1.4: + version "3.1.4" + resolved "https://registry.yarnpkg.com/postcss-load-config/-/postcss-load-config-3.1.4.tgz#1ab2571faf84bb078877e1d07905eabe9ebda855" + integrity sha512-6DiM4E7v4coTE4uzA8U//WhtPwyhiim3eyjEMFCnUpzbrkK9wJHgKDT2mR+HbtSrd/NubVaYTOpSpjUl8NQeRg== dependencies: - import-cwd "^3.0.0" - lilconfig "^2.0.3" + lilconfig "^2.0.5" yaml "^1.10.2" postcss-nested@5.0.6: @@ -1912,10 +1790,10 @@ postcss-nested@5.0.6: dependencies: postcss-selector-parser "^6.0.6" -postcss-selector-parser@^6.0.6, postcss-selector-parser@^6.0.9: - version "6.0.9" - resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-6.0.9.tgz#ee71c3b9ff63d9cd130838876c13a2ec1a992b2f" - integrity sha512-UO3SgnZOVTwu4kyLR22UQ1xZh086RyNZppb7lLAKBFK8a32ttG5i87Y/P3+2bRSjZNyJ1B7hfFNo273tKe9YxQ== +postcss-selector-parser@^6.0.10, postcss-selector-parser@^6.0.6: + version "6.0.10" + resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-6.0.10.tgz#79b61e2c0d1bfc2602d549e11d0876256f8df88d" + integrity sha512-IQ7TZdoaqbT+LCpShg46jnZVlhWD2w6iQYAcYXfHARZ7X1t/UGhhceQDs5X0cGqKvYlHNOuv7Oa1xmb0oQuA3w== dependencies: cssesc "^3.0.0" util-deprecate "^1.0.2" @@ -1925,7 +1803,7 @@ postcss-value-parser@^4.2.0: resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz#723c09920836ba6d3e5af019f92bc0971c02e514" integrity sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ== -postcss@8.4.12, postcss@^8.4.6: +postcss@8.4.12, postcss@^8.4.12: version "8.4.12" resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.12.tgz#1e7de78733b28970fa4743f7da6f3763648b1905" integrity sha512-lg6eITwYe9v6Hr5CncVbK70SoioNQIq81nsaG86ev5hAidQvmOeETBqs7jm43K2F5/Ley3ytDtriImV6TpNiSg== @@ -2075,11 +1953,6 @@ resolve-from@^4.0.0: resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== -resolve-from@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-5.0.0.tgz#c35225843df8f776df21c57557bc087e9dfdfc69" - integrity sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw== - resolve@^1.13.1, resolve@^1.17.0, resolve@^1.20.0, resolve@^1.22.0: version "1.22.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.0.tgz#5e0b8c67c15df57a89bdbabe603a002f21731198" @@ -2248,10 +2121,10 @@ strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== -stripe@8.216.0: - version "8.216.0" - resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.216.0.tgz#23c047498526d13a238c3aca7b4dc8cbbd522e46" - integrity sha512-LY8cNGizEnklIa4T82l6mZW0HS4cfzo1hNuhT+ZR9PBkmYcSUbg3ilUBVF0FCd4RP+NA44VEVfoSTTZ1Gg5+rQ== +stripe@8.217.0: + version "8.217.0" + resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.217.0.tgz#5e8ae744e0e8fca6e7c1d50c131ec3d77dff0999" + integrity sha512-CHWazNOrb1EBxTpepv5hCKMxOwF/oW3E4zRi8/LZIy5FC2y7A7NzcuE1aErYXLId3bKPe20HOmWKvjDRU2bXaA== dependencies: "@types/node" ">=8.1.0" qs "^6.10.3" @@ -2261,13 +2134,6 @@ styled-jsx@5.0.1: resolved "https://registry.yarnpkg.com/styled-jsx/-/styled-jsx-5.0.1.tgz#78fecbbad2bf95ce6cd981a08918ce4696f5fc80" integrity sha512-+PIZ/6Uk40mphiQJJI1202b+/dYeTVd9ZnMPR80pgiWbjIwvN2zIp4r9et0BgqBuShh48I0gttPlAXA7WVvBxw== -supports-color@^5.3.0: - version "5.5.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" - integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== - dependencies: - has-flag "^3.0.0" - supports-color@^7.1.0: version "7.2.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" @@ -2285,29 +2151,29 @@ swr@1.3.0: resolved "https://registry.yarnpkg.com/swr/-/swr-1.3.0.tgz#c6531866a35b4db37b38b72c45a63171faf9f4e8" integrity sha512-dkghQrOl2ORX9HYrMDtPa7LTVHJjCTeZoB1dqTbnnEDlSvN8JEKpYIYurDfvbQFUUS8Cg8PceFVZNkW0KNNYPw== -tailwindcss@3.0.23: - version "3.0.23" - resolved "https://registry.yarnpkg.com/tailwindcss/-/tailwindcss-3.0.23.tgz#c620521d53a289650872a66adfcb4129d2200d10" - integrity sha512-+OZOV9ubyQ6oI2BXEhzw4HrqvgcARY38xv3zKcjnWtMIZstEsXdI9xftd1iB7+RbOnj2HOEzkA0OyB5BaSxPQA== +tailwindcss@3.0.24: + version "3.0.24" + resolved "https://registry.yarnpkg.com/tailwindcss/-/tailwindcss-3.0.24.tgz#22e31e801a44a78a1d9a81ecc52e13b69d85704d" + integrity sha512-H3uMmZNWzG6aqmg9q07ZIRNIawoiEcNFKDfL+YzOPuPsXuDXxJxB9icqzLgdzKNwjG3SAro2h9SYav8ewXNgig== dependencies: arg "^5.0.1" - chalk "^4.1.2" chokidar "^3.5.3" color-name "^1.1.4" - cosmiconfig "^7.0.1" detective "^5.2.0" didyoumean "^1.2.2" dlv "^1.1.3" fast-glob "^3.2.11" glob-parent "^6.0.2" is-glob "^4.0.3" + lilconfig "^2.0.5" normalize-path "^3.0.0" - object-hash "^2.2.0" - postcss "^8.4.6" + object-hash "^3.0.0" + picocolors "^1.0.0" + postcss "^8.4.12" postcss-js "^4.0.0" - postcss-load-config "^3.1.0" + postcss-load-config "^3.1.4" postcss-nested "5.0.6" - postcss-selector-parser "^6.0.9" + postcss-selector-parser "^6.0.10" postcss-value-parser "^4.2.0" quick-lru "^5.1.1" resolve "^1.22.0" @@ -2456,7 +2322,7 @@ yallist@^4.0.0: resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== -yaml@^1.10.0, yaml@^1.10.2: +yaml@^1.10.2: version "1.10.2" resolved "https://registry.yarnpkg.com/yaml/-/yaml-1.10.2.tgz#2301c5ffbf12b467de8da2333a459e29e7920e4b" integrity sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg== From 31cf7445b6c4c77ab93e6871d9125176411c4251 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:07:55 +0000 Subject: [PATCH 200/240] build(deps): bump skynet-js in /packages/health-check Bumps [skynet-js](https://github.com/SkynetLabs/skynet-js) from 4.0.19-beta to 4.1.0. - [Release notes](https://github.com/SkynetLabs/skynet-js/releases) - [Changelog](https://github.com/SkynetLabs/skynet-js/blob/master/CHANGELOG-BETA.md) - [Commits](https://github.com/SkynetLabs/skynet-js/compare/v4.0.19-beta...v4.1.0) --- updated-dependencies: - dependency-name: skynet-js dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/health-check/package.json | 2 +- packages/health-check/yarn.lock | 77 +++++++++++++++++------------- 2 files changed, 46 insertions(+), 33 deletions(-) diff --git a/packages/health-check/package.json b/packages/health-check/package.json index 9c6e2025..117ced46 100644 --- a/packages/health-check/package.json +++ b/packages/health-check/package.json @@ -13,7 +13,7 @@ "http-status-codes": "^2.2.0", "lodash": "^4.17.21", "lowdb": "^1.0.0", - "skynet-js": "^4.0.19-beta", + "skynet-js": "^4.1.0", "write-file-atomic": "^4.0.1", "yargs": "^17.4.1" }, diff --git a/packages/health-check/yarn.lock b/packages/health-check/yarn.lock index 4343388e..15cf315c 100644 --- a/packages/health-check/yarn.lock +++ b/packages/health-check/yarn.lock @@ -515,6 +515,19 @@ dependencies: "@sinonjs/commons" "^1.7.0" +"@skynetlabs/tus-js-client@^2.3.0": + version "2.3.0" + resolved "https://registry.yarnpkg.com/@skynetlabs/tus-js-client/-/tus-js-client-2.3.0.tgz#a14fd4197e2bc4ce8be724967a0e4c17d937cb64" + integrity sha512-piGvPlJh+Bu3Qf08bDlc/TnFLXE81KnFoPgvnsddNwTSLyyspxPFxJmHO5ki6SYyOl3HmUtGPoix+r2M2UpFEA== + dependencies: + buffer-from "^0.1.1" + combine-errors "^3.0.3" + is-stream "^2.0.0" + js-base64 "^2.6.1" + lodash.throttle "^4.1.1" + proper-lockfile "^2.0.1" + url-parse "^1.4.3" + "@szmarczak/http-timer@^4.0.5": version "4.0.6" resolved "https://registry.yarnpkg.com/@szmarczak/http-timer/-/http-timer-4.0.6.tgz#b4a914bb62e7c272d4e5989fe4440f812ab1d807" @@ -736,17 +749,24 @@ array-flatten@1.1.1: resolved "https://registry.yarnpkg.com/array-flatten/-/array-flatten-1.1.1.tgz#9a5f699051b1e7073328f2a008968b64ea2955d2" integrity sha1-ml9pkFGx5wczKPKgCJaLZOopVdI= +async-mutex@^0.3.2: + version "0.3.2" + resolved "https://registry.yarnpkg.com/async-mutex/-/async-mutex-0.3.2.tgz#1485eda5bda1b0ec7c8df1ac2e815757ad1831df" + integrity sha512-HuTK7E7MT7jZEh1P9GtRW9+aTWiDWWi9InbZ5hjxrnRa39KS4BW04+xLBhYNS2aXhHUIKZSw3gj4Pn1pj+qGAA== + dependencies: + tslib "^2.3.1" + asynckit@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= -axios@^0.24.0: - version "0.24.0" - resolved "https://registry.yarnpkg.com/axios/-/axios-0.24.0.tgz#804e6fa1e4b9c5288501dd9dff56a7a0940d20d6" - integrity sha512-Q6cWsys88HoPgAaFAVUb0WpPk0O8iTeisR9IMqy9G8AbO4NlpVknrnQS03zzF9PGAWgO3cgletO3VjV/P7VztA== +axios@^0.26.0: + version "0.26.1" + resolved "https://registry.yarnpkg.com/axios/-/axios-0.26.1.tgz#1ede41c51fcf51bbbd6fd43669caaa4f0495aaa9" + integrity sha512-fPwcX4EvnSHuInCMItEhAGnaSEXRBjtzh9fOtsE6E1G6p7vl7edEeZe11QHf18+6+9gR5PbKV/sGKNaD8YaMeA== dependencies: - follow-redirects "^1.14.4" + follow-redirects "^1.14.8" babel-jest@^27.5.1: version "27.5.1" @@ -1407,10 +1427,10 @@ find-up@^4.0.0, find-up@^4.1.0: locate-path "^5.0.0" path-exists "^4.0.0" -follow-redirects@^1.14.4: - version "1.14.8" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.14.8.tgz#016996fb9a11a100566398b1c6839337d7bfa8fc" - integrity sha512-1x0S9UVJHsQprFcEC/qnNzBLcIxsjAV905f/UkQxbclCsoTWlacCNOpQa/anodLl2uaEKFhfWOvM2Qg77+15zA== +follow-redirects@^1.14.8: + version "1.14.9" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.14.9.tgz#dd4ea157de7bfaf9ea9b3fbd85aa16951f78d8d7" + integrity sha512-MQDfihBQYMcyy5dhRDJUHcw7lb2Pv/TuE6xP1vyraLukNDHKbDxDNaOE3NbCAdKQApno+GPRyo1YAp89yCjK4w== form-data@^3.0.0: version "3.0.1" @@ -2410,10 +2430,10 @@ mime@1.6.0: resolved "https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1" integrity sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg== -mime@^2.5.2: - version "2.5.2" - resolved "https://registry.yarnpkg.com/mime/-/mime-2.5.2.tgz#6e3dc6cc2b9510643830e5f19d5cb753da5eeabe" - integrity sha512-tqkh47FzKeCPD2PUiPB6pkbMzsCasjxAfC62/Wap5qrUWcb+sFasXUC5I3gYM5iBM8v/Qpn4UK0x+j0iHyFPDg== +mime@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/mime/-/mime-3.0.0.tgz#b374550dca3a0c18443b0c950a6a58f1931cf7a7" + integrity sha512-jSCU7/VB1loIWBZe14aEYHU/+1UMEHoaO7qxCOVJOw9GgH72VAWppxNcjU+x9a2k3GSIBXNKxXQFqRvvZ7vr3A== mimic-fn@^2.1.0: version "2.1.0" @@ -2896,24 +2916,25 @@ sjcl@^1.0.8: resolved "https://registry.yarnpkg.com/sjcl/-/sjcl-1.0.8.tgz#f2ec8d7dc1f0f21b069b8914a41a8f236b0e252a" integrity sha512-LzIjEQ0S0DpIgnxMEayM1rq9aGwGRG4OnZhCdjx7glTaJtf4zRfpg87ImfjSJjoW9vKpagd82McDOwbRT5kQKQ== -skynet-js@^4.0.19-beta: - version "4.0.19-beta" - resolved "https://registry.yarnpkg.com/skynet-js/-/skynet-js-4.0.19-beta.tgz#d4c640898c79cf69e45aa1c3c1ed5c80aa1aeced" - integrity sha512-d8/q3E3OjUxgCCAW28gNFvbahj0ks8ym122XTopbRyvAZKk9+/Z4ians9v8Tov36Z4k/un+Ilw/0i6DtM8c8Dw== +skynet-js@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/skynet-js/-/skynet-js-4.1.0.tgz#eccb84d04e9f42aa4f86ecb24fb4d59ed21e44cc" + integrity sha512-VmUjJ9QnLpfuQA2j7vzFh8JvukjQlX4QLGw1HY3VyslFPj92vPpyO8gqjPfzgbkR05TXL7CbdqZoLZr/RBDZPw== dependencies: - axios "^0.24.0" + "@skynetlabs/tus-js-client" "^2.3.0" + async-mutex "^0.3.2" + axios "^0.26.0" base32-decode "^1.0.0" base32-encode "^1.1.1" base64-js "^1.3.1" blakejs "^1.1.0" buffer "^6.0.1" - mime "^2.5.2" + mime "^3.0.0" path-browserify "^1.0.1" post-me "^0.4.5" randombytes "^2.1.0" sjcl "^1.0.8" skynet-mysky-utils "^0.3.0" - tus-js-client "^2.2.0" tweetnacl "^1.0.3" url-join "^4.0.1" url-parse "^1.5.1" @@ -3120,18 +3141,10 @@ tr46@^2.1.0: dependencies: punycode "^2.1.1" -tus-js-client@^2.2.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/tus-js-client/-/tus-js-client-2.3.0.tgz#5d76145476cea46a4e7c045a0054637cddf8dc39" - integrity sha512-I4cSwm6N5qxqCmBqenvutwSHe9ntf81lLrtf6BmLpG2v4wTl89atCQKqGgqvkodE6Lx+iKIjMbaXmfvStTg01g== - dependencies: - buffer-from "^0.1.1" - combine-errors "^3.0.3" - is-stream "^2.0.0" - js-base64 "^2.6.1" - lodash.throttle "^4.1.1" - proper-lockfile "^2.0.1" - url-parse "^1.4.3" +tslib@^2.3.1: + version "2.3.1" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.3.1.tgz#e8a335add5ceae51aa261d32a490158ef042ef01" + integrity sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw== tweetnacl@^1.0.3: version "1.0.3" From 9441c6d2e873fc4e43e3729da9d32f6cf66c9272 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:10:53 +0000 Subject: [PATCH 201/240] build(deps): bump skynet-js in /packages/website Bumps [skynet-js](https://github.com/SkynetLabs/skynet-js) from 4.0.26-beta to 4.1.0. - [Release notes](https://github.com/SkynetLabs/skynet-js/releases) - [Changelog](https://github.com/SkynetLabs/skynet-js/blob/master/CHANGELOG-BETA.md) - [Commits](https://github.com/SkynetLabs/skynet-js/compare/v4.0.26-beta...v4.1.0) --- updated-dependencies: - dependency-name: skynet-js dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 191e3f54..1ec5fef9 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -40,7 +40,7 @@ "react-dropzone": "12.0.5", "react-helmet": "6.1.0", "react-use": "17.3.2", - "skynet-js": "4.0.26-beta", + "skynet-js": "4.1.0", "stream-browserify": "3.0.0", "swr": "1.2.2" }, diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index d5a1b5be..30097510 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -11017,10 +11017,10 @@ sjcl@^1.0.8: resolved "https://registry.yarnpkg.com/sjcl/-/sjcl-1.0.8.tgz#f2ec8d7dc1f0f21b069b8914a41a8f236b0e252a" integrity sha512-LzIjEQ0S0DpIgnxMEayM1rq9aGwGRG4OnZhCdjx7glTaJtf4zRfpg87ImfjSJjoW9vKpagd82McDOwbRT5kQKQ== -skynet-js@4.0.26-beta: - version "4.0.26-beta" - resolved "https://registry.yarnpkg.com/skynet-js/-/skynet-js-4.0.26-beta.tgz#5b6e924a0efa5fd6ee2c00760e1d4ce92d1ba0a9" - integrity sha512-YPqjNyqL6AhS9jMLyJ5PoilDZ7f2YFrqqhXUnzLBrjmWxICxcDeRu2GJh9MGCJUZ2Cv35IlG1ch4eiqFbs1wqA== +skynet-js@4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/skynet-js/-/skynet-js-4.1.0.tgz#eccb84d04e9f42aa4f86ecb24fb4d59ed21e44cc" + integrity sha512-VmUjJ9QnLpfuQA2j7vzFh8JvukjQlX4QLGw1HY3VyslFPj92vPpyO8gqjPfzgbkR05TXL7CbdqZoLZr/RBDZPw== dependencies: "@skynetlabs/tus-js-client" "^2.3.0" async-mutex "^0.3.2" From 8e14d33a172baac3ae07a8f7766978405f147540 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Tue, 19 Apr 2022 11:20:24 +0200 Subject: [PATCH 202/240] run lua unit tests only when lua path has modified files --- .github/workflows/nginx-lua-unit-tests.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/nginx-lua-unit-tests.yml b/.github/workflows/nginx-lua-unit-tests.yml index 6c9fba83..5af9c101 100644 --- a/.github/workflows/nginx-lua-unit-tests.yml +++ b/.github/workflows/nginx-lua-unit-tests.yml @@ -7,7 +7,11 @@ on: push: branches: - master + paths: + - docker/nginx/libs/** pull_request: + paths: + - docker/nginx/libs/** jobs: test: From 3973cfc057e511448f0ec1f28452f83104af67d7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:27:29 +0000 Subject: [PATCH 203/240] build(deps): bump gatsby-plugin-react-helmet in /packages/website Bumps [gatsby-plugin-react-helmet](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-react-helmet) from 5.10.0 to 5.12.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-react-helmet/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-react-helmet@5.12.1/packages/gatsby-plugin-react-helmet) --- updated-dependencies: - dependency-name: gatsby-plugin-react-helmet dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 1ec5fef9..6d97a10c 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -18,7 +18,7 @@ "gatsby-plugin-image": "2.12.1", "gatsby-plugin-manifest": "4.11.1", "gatsby-plugin-postcss": "5.12.1", - "gatsby-plugin-react-helmet": "5.10.0", + "gatsby-plugin-react-helmet": "5.12.1", "gatsby-plugin-robots-txt": "1.7.1", "gatsby-plugin-sharp": "4.12.1", "gatsby-plugin-sitemap": "5.11.1", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 30097510..b61e7f93 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6347,10 +6347,10 @@ gatsby-plugin-postcss@5.12.1: "@babel/runtime" "^7.15.4" postcss-loader "^4.3.0" -gatsby-plugin-react-helmet@5.10.0: - version "5.10.0" - resolved "https://registry.yarnpkg.com/gatsby-plugin-react-helmet/-/gatsby-plugin-react-helmet-5.10.0.tgz#d6491d35d4b4e3bb36631c1a93f4e53913f42cbb" - integrity sha512-QcypYLqnwKoD84f9c6Yfajs/sLfVmxPSOPWwHaK+3NG1IjmmQrL42qn2CP6gs29WznGzrThGeGiwIVdA5x31JA== +gatsby-plugin-react-helmet@5.12.1: + version "5.12.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-react-helmet/-/gatsby-plugin-react-helmet-5.12.1.tgz#98205abb73cd7a522f2891b3a42514ae2b41ca57" + integrity sha512-lW9uRpkccSj0NC41dunFM4AoDuQockgpWHcvLivzGWMnWYtGWPNci7zy8+NUL1+6CchQqWTr0LZEeGYgpHym+w== dependencies: "@babel/runtime" "^7.15.4" From 455fce5511065b640229a3747fbee1d2568b47e9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:28:30 +0000 Subject: [PATCH 204/240] build(deps): bump gatsby-plugin-manifest in /packages/website Bumps [gatsby-plugin-manifest](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-manifest) from 4.11.1 to 4.12.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-manifest/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-manifest@4.12.1/packages/gatsby-plugin-manifest) --- updated-dependencies: - dependency-name: gatsby-plugin-manifest dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 1ec5fef9..2374ac68 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -16,7 +16,7 @@ "gatsby": "4.12.1", "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.12.1", - "gatsby-plugin-manifest": "4.11.1", + "gatsby-plugin-manifest": "4.12.1", "gatsby-plugin-postcss": "5.12.1", "gatsby-plugin-react-helmet": "5.10.0", "gatsby-plugin-robots-txt": "1.7.1", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 30097510..431f98db 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6209,7 +6209,7 @@ gatsby-cli@^4.12.1: yoga-layout-prebuilt "^1.10.0" yurnalist "^2.1.0" -gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.11.1, gatsby-core-utils@^3.12.1, gatsby-core-utils@^3.8.2: +gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.12.1, gatsby-core-utils@^3.8.2: version "3.12.1" resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.12.1.tgz#590ec08de7168b086b7d49128732b9ada95b985f" integrity sha512-jBG1MfR6t2MZNIl8LQ3Cwc92F6uFNcEC091IK+qKVy9FNT0+WzcKQ6Olip6u1NSvCatfrg1FqrH0K78a6lmnLQ== @@ -6311,16 +6311,16 @@ gatsby-plugin-image@2.12.1: objectFitPolyfill "^2.3.5" prop-types "^15.8.1" -gatsby-plugin-manifest@4.11.1: - version "4.11.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-manifest/-/gatsby-plugin-manifest-4.11.1.tgz#fb3061c2e989acb2634719c1e8645fd1388f4b3b" - integrity sha512-m5cdi6KBc8+zmnlIfEh92sXpFEUfjuCrjM5BKc8e6v0jxJS0CqVrZOyT12mT2yq9H12UrkzFx1qaI8e2/IJiGA== +gatsby-plugin-manifest@4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-manifest/-/gatsby-plugin-manifest-4.12.1.tgz#25342272c03fdce95901eb42a3ece09f12e4be4a" + integrity sha512-AZ0vtO/+khtpum4VUX/Gj/oRer6ckcEfVU/DNd3QlpG7ucHSzHKSwSLP6F5kevCHo7DS4hCMV8RixPlcv0ePWA== dependencies: "@babel/runtime" "^7.15.4" - gatsby-core-utils "^3.11.1" - gatsby-plugin-utils "^3.5.1" + gatsby-core-utils "^3.12.1" + gatsby-plugin-utils "^3.6.1" semver "^7.3.5" - sharp "^0.30.1" + sharp "^0.30.3" gatsby-plugin-page-creator@^4.12.1: version "4.12.1" @@ -6415,7 +6415,7 @@ gatsby-plugin-typescript@^4.12.1: "@babel/runtime" "^7.15.4" babel-plugin-remove-graphql-queries "^4.12.1" -gatsby-plugin-utils@^3.5.1, gatsby-plugin-utils@^3.6.1: +gatsby-plugin-utils@^3.6.1: version "3.6.1" resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.6.1.tgz#31d742e1aded08439ad42959880821e1fc9740cd" integrity sha512-Ebk98v4mxaDWjGFl6VBeNv1zjeJ7UCQ29UTabzY2BpztvUCBHfLVQdMmuaAgzPRn+A3SFVOGpcl++CF0IEl+7A== From 409406832f51e13d18ed2bf56dbbf4ab14f9543d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:28:42 +0000 Subject: [PATCH 205/240] build(deps): bump swr from 1.2.2 to 1.3.0 in /packages/website Bumps [swr](https://github.com/vercel/swr) from 1.2.2 to 1.3.0. - [Release notes](https://github.com/vercel/swr/releases) - [Commits](https://github.com/vercel/swr/compare/1.2.2...1.3.0) --- updated-dependencies: - dependency-name: swr dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 1ec5fef9..41728886 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -42,7 +42,7 @@ "react-use": "17.3.2", "skynet-js": "4.1.0", "stream-browserify": "3.0.0", - "swr": "1.2.2" + "swr": "1.3.0" }, "devDependencies": { "@tailwindcss/typography": "0.5.2", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 30097510..acebe829 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -11637,10 +11637,10 @@ svgo@^2.5.0, svgo@^2.7.0: picocolors "^1.0.0" stable "^0.1.8" -swr@1.2.2: - version "1.2.2" - resolved "https://registry.yarnpkg.com/swr/-/swr-1.2.2.tgz#6cae09928d30593a7980d80f85823e57468fac5d" - integrity sha512-ky0BskS/V47GpW8d6RU7CPsr6J8cr7mQD6+do5eky3bM0IyJaoi3vO8UhvrzJaObuTlGhPl2szodeB2dUd76Xw== +swr@1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/swr/-/swr-1.3.0.tgz#c6531866a35b4db37b38b72c45a63171faf9f4e8" + integrity sha512-dkghQrOl2ORX9HYrMDtPa7LTVHJjCTeZoB1dqTbnnEDlSvN8JEKpYIYurDfvbQFUUS8Cg8PceFVZNkW0KNNYPw== symbol-observable@^1.0.4: version "1.2.0" From 8dca68f154e107ba430865b8630eb7abbece6c78 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:28:59 +0000 Subject: [PATCH 206/240] build(deps-dev): bump cypress from 9.5.2 to 9.5.4 in /packages/website Bumps [cypress](https://github.com/cypress-io/cypress) from 9.5.2 to 9.5.4. - [Release notes](https://github.com/cypress-io/cypress/releases) - [Changelog](https://github.com/cypress-io/cypress/blob/develop/.releaserc.base.js) - [Commits](https://github.com/cypress-io/cypress/compare/v9.5.2...v9.5.4) --- updated-dependencies: - dependency-name: cypress dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 1ec5fef9..9850c333 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -48,7 +48,7 @@ "@tailwindcss/typography": "0.5.2", "autoprefixer": "10.4.4", "cross-env": "7.0.3", - "cypress": "9.5.2", + "cypress": "9.5.4", "prettier": "2.6.2", "tailwindcss": "3.0.24" }, diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 30097510..6d6bd923 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -4613,10 +4613,10 @@ custom-error-instance@2.1.1: resolved "https://registry.yarnpkg.com/custom-error-instance/-/custom-error-instance-2.1.1.tgz#3cf6391487a6629a6247eb0ca0ce00081b7e361a" integrity sha1-PPY5FIemYppiR+sMoM4ACBt+Nho= -cypress@9.5.2: - version "9.5.2" - resolved "https://registry.yarnpkg.com/cypress/-/cypress-9.5.2.tgz#8fb6ee4a890fbc35620800810bf6fb11995927bd" - integrity sha512-gYiQYvJozMzDOriUV1rCt6CeRM/pRK4nhwGJj3nJQyX2BoUdTCVwp30xDMKc771HiNVhBtgj5o5/iBdVDVXQUg== +cypress@9.5.4: + version "9.5.4" + resolved "https://registry.yarnpkg.com/cypress/-/cypress-9.5.4.tgz#49d9272f62eba12f2314faf29c2a865610e87550" + integrity sha512-6AyJAD8phe7IMvOL4oBsI9puRNOWxZjl8z1lgixJMcgJ85JJmyKeP6uqNA0dI1z14lmJ7Qklf2MOgP/xdAqJ/Q== dependencies: "@cypress/request" "^2.88.10" "@cypress/xvfb" "^1.2.4" @@ -4650,7 +4650,7 @@ cypress@9.5.2: listr2 "^3.8.3" lodash "^4.17.21" log-symbols "^4.0.0" - minimist "^1.2.5" + minimist "^1.2.6" ospath "^1.2.2" pretty-bytes "^5.6.0" proxy-from-env "1.0.0" @@ -8755,7 +8755,7 @@ minimist-options@4.1.0: is-plain-obj "^1.1.0" kind-of "^6.0.3" -minimist@^1.1.1, minimist@^1.2.0, minimist@^1.2.3, minimist@^1.2.5: +minimist@^1.1.1, minimist@^1.2.0, minimist@^1.2.3, minimist@^1.2.5, minimist@^1.2.6: version "1.2.6" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== From 8736e1ff312e90bfa1e9b3de9d34a1e5d6de3ab0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:29:59 +0000 Subject: [PATCH 207/240] build(deps): bump gatsby-transformer-sharp in /packages/website Bumps [gatsby-transformer-sharp](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-transformer-sharp) from 4.10.0 to 4.12.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-transformer-sharp/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-transformer-sharp@4.12.1/packages/gatsby-transformer-sharp) --- updated-dependencies: - dependency-name: gatsby-transformer-sharp dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 1ec5fef9..1cdf41f5 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -24,7 +24,7 @@ "gatsby-plugin-sitemap": "5.11.1", "gatsby-plugin-svgr": "3.0.0-beta.0", "gatsby-source-filesystem": "4.10.1", - "gatsby-transformer-sharp": "4.10.0", + "gatsby-transformer-sharp": "4.12.1", "gatsby-transformer-yaml": "4.11.0", "gbimage-bridge": "0.2.1", "http-status-codes": "2.2.0", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 30097510..1fb7369d 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6482,19 +6482,19 @@ gatsby-telemetry@^3.12.1: lodash "^4.17.21" node-fetch "^2.6.7" -gatsby-transformer-sharp@4.10.0: - version "4.10.0" - resolved "https://registry.yarnpkg.com/gatsby-transformer-sharp/-/gatsby-transformer-sharp-4.10.0.tgz#9db793a219d0fa85b7d33cb37b32aba63df4c58a" - integrity sha512-Gp9eRkGQOrkoD+yJgK2ZdXuVbet/opxdEnuTZ6BhLEVhfTwOnMEaui6ZqO0cKJ7/NYlptO38p+C5cyizC0FRYA== +gatsby-transformer-sharp@4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/gatsby-transformer-sharp/-/gatsby-transformer-sharp-4.12.1.tgz#e26dc3540e97fc1c802518967c1e8d8a4ed96fae" + integrity sha512-14AGG10Jf7ZBWxJDN2jSupAsBofoGU+p7+QJRzDrKdJrzp9v/yO/1xPB+r7UxtlW0l8cqPT6UyCITvJbWTDaww== dependencies: "@babel/runtime" "^7.15.4" bluebird "^3.7.2" common-tags "^1.8.2" fs-extra "^10.0.0" potrace "^2.1.8" - probe-image-size "^7.0.0" + probe-image-size "^7.2.3" semver "^7.3.5" - sharp "^0.30.1" + sharp "^0.30.3" gatsby-transformer-yaml@4.11.0: version "4.11.0" @@ -9983,7 +9983,7 @@ pretty-error@^2.1.2: lodash "^4.17.20" renderkid "^2.0.4" -probe-image-size@^7.0.0, probe-image-size@^7.2.3: +probe-image-size@^7.2.3: version "7.2.3" resolved "https://registry.yarnpkg.com/probe-image-size/-/probe-image-size-7.2.3.tgz#d49c64be540ec8edea538f6f585f65a9b3ab4309" integrity sha512-HubhG4Rb2UH8YtV4ba0Vp5bQ7L78RTONYu/ujmCu5nBI8wGv24s4E9xSKBi0N1MowRpxk76pFCpJtW0KPzOK0w== From 3d6f5b57eabfafcbb6240f83e90a4d80285ab009 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:39:06 +0000 Subject: [PATCH 208/240] build(deps): bump gatsby-plugin-sitemap in /packages/website Bumps [gatsby-plugin-sitemap](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-plugin-sitemap) from 5.11.1 to 5.12.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-sitemap/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-plugin-sitemap@5.12.1/packages/gatsby-plugin-sitemap) --- updated-dependencies: - dependency-name: gatsby-plugin-sitemap dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 6 +++--- packages/website/yarn.lock | 40 +++++++++++++++++------------------ 2 files changed, 23 insertions(+), 23 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 1ec5fef9..38c541a0 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -16,12 +16,12 @@ "gatsby": "4.12.1", "gatsby-background-image": "1.6.0", "gatsby-plugin-image": "2.12.1", - "gatsby-plugin-manifest": "4.11.1", + "gatsby-plugin-manifest": "4.12.1", "gatsby-plugin-postcss": "5.12.1", "gatsby-plugin-react-helmet": "5.10.0", "gatsby-plugin-robots-txt": "1.7.1", "gatsby-plugin-sharp": "4.12.1", - "gatsby-plugin-sitemap": "5.11.1", + "gatsby-plugin-sitemap": "5.12.1", "gatsby-plugin-svgr": "3.0.0-beta.0", "gatsby-source-filesystem": "4.10.1", "gatsby-transformer-sharp": "4.10.0", @@ -48,7 +48,7 @@ "@tailwindcss/typography": "0.5.2", "autoprefixer": "10.4.4", "cross-env": "7.0.3", - "cypress": "9.5.2", + "cypress": "9.5.4", "prettier": "2.6.2", "tailwindcss": "3.0.24" }, diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index 30097510..0a1f2daa 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -4613,10 +4613,10 @@ custom-error-instance@2.1.1: resolved "https://registry.yarnpkg.com/custom-error-instance/-/custom-error-instance-2.1.1.tgz#3cf6391487a6629a6247eb0ca0ce00081b7e361a" integrity sha1-PPY5FIemYppiR+sMoM4ACBt+Nho= -cypress@9.5.2: - version "9.5.2" - resolved "https://registry.yarnpkg.com/cypress/-/cypress-9.5.2.tgz#8fb6ee4a890fbc35620800810bf6fb11995927bd" - integrity sha512-gYiQYvJozMzDOriUV1rCt6CeRM/pRK4nhwGJj3nJQyX2BoUdTCVwp30xDMKc771HiNVhBtgj5o5/iBdVDVXQUg== +cypress@9.5.4: + version "9.5.4" + resolved "https://registry.yarnpkg.com/cypress/-/cypress-9.5.4.tgz#49d9272f62eba12f2314faf29c2a865610e87550" + integrity sha512-6AyJAD8phe7IMvOL4oBsI9puRNOWxZjl8z1lgixJMcgJ85JJmyKeP6uqNA0dI1z14lmJ7Qklf2MOgP/xdAqJ/Q== dependencies: "@cypress/request" "^2.88.10" "@cypress/xvfb" "^1.2.4" @@ -4650,7 +4650,7 @@ cypress@9.5.2: listr2 "^3.8.3" lodash "^4.17.21" log-symbols "^4.0.0" - minimist "^1.2.5" + minimist "^1.2.6" ospath "^1.2.2" pretty-bytes "^5.6.0" proxy-from-env "1.0.0" @@ -6209,7 +6209,7 @@ gatsby-cli@^4.12.1: yoga-layout-prebuilt "^1.10.0" yurnalist "^2.1.0" -gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.11.1, gatsby-core-utils@^3.12.1, gatsby-core-utils@^3.8.2: +gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.12.1, gatsby-core-utils@^3.8.2: version "3.12.1" resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.12.1.tgz#590ec08de7168b086b7d49128732b9ada95b985f" integrity sha512-jBG1MfR6t2MZNIl8LQ3Cwc92F6uFNcEC091IK+qKVy9FNT0+WzcKQ6Olip6u1NSvCatfrg1FqrH0K78a6lmnLQ== @@ -6311,16 +6311,16 @@ gatsby-plugin-image@2.12.1: objectFitPolyfill "^2.3.5" prop-types "^15.8.1" -gatsby-plugin-manifest@4.11.1: - version "4.11.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-manifest/-/gatsby-plugin-manifest-4.11.1.tgz#fb3061c2e989acb2634719c1e8645fd1388f4b3b" - integrity sha512-m5cdi6KBc8+zmnlIfEh92sXpFEUfjuCrjM5BKc8e6v0jxJS0CqVrZOyT12mT2yq9H12UrkzFx1qaI8e2/IJiGA== +gatsby-plugin-manifest@4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-manifest/-/gatsby-plugin-manifest-4.12.1.tgz#25342272c03fdce95901eb42a3ece09f12e4be4a" + integrity sha512-AZ0vtO/+khtpum4VUX/Gj/oRer6ckcEfVU/DNd3QlpG7ucHSzHKSwSLP6F5kevCHo7DS4hCMV8RixPlcv0ePWA== dependencies: "@babel/runtime" "^7.15.4" - gatsby-core-utils "^3.11.1" - gatsby-plugin-utils "^3.5.1" + gatsby-core-utils "^3.12.1" + gatsby-plugin-utils "^3.6.1" semver "^7.3.5" - sharp "^0.30.1" + sharp "^0.30.3" gatsby-plugin-page-creator@^4.12.1: version "4.12.1" @@ -6387,14 +6387,14 @@ gatsby-plugin-sharp@4.12.1: svgo "1.3.2" uuid "3.4.0" -gatsby-plugin-sitemap@5.11.1: - version "5.11.1" - resolved "https://registry.yarnpkg.com/gatsby-plugin-sitemap/-/gatsby-plugin-sitemap-5.11.1.tgz#863397fe9dd5aab89bda8db09ef9b877c960150e" - integrity sha512-tt92KLUDS+eCrqSA5oYieDGjXLyUDXfYKEwLhYKXk7KlMMjporFJWVrc4Ba8WD04bUWVnzc2rqr19/zQI0ZIpQ== +gatsby-plugin-sitemap@5.12.1: + version "5.12.1" + resolved "https://registry.yarnpkg.com/gatsby-plugin-sitemap/-/gatsby-plugin-sitemap-5.12.1.tgz#782a926a558d31663d4a8e66b9466c86df278568" + integrity sha512-Njdx91OF4xiFqHSSA3Yrnzxm4qu4xHyrhkiwQniFncoIGMI6IXqk9aDoxo3E1jZDWGPsI/2gzdcd8dBNQq9juA== dependencies: "@babel/runtime" "^7.15.4" common-tags "^1.8.2" - minimatch "^3.0.4" + minimatch "^3.1.2" sitemap "^7.0.0" gatsby-plugin-svgr@3.0.0-beta.0: @@ -6415,7 +6415,7 @@ gatsby-plugin-typescript@^4.12.1: "@babel/runtime" "^7.15.4" babel-plugin-remove-graphql-queries "^4.12.1" -gatsby-plugin-utils@^3.5.1, gatsby-plugin-utils@^3.6.1: +gatsby-plugin-utils@^3.6.1: version "3.6.1" resolved "https://registry.yarnpkg.com/gatsby-plugin-utils/-/gatsby-plugin-utils-3.6.1.tgz#31d742e1aded08439ad42959880821e1fc9740cd" integrity sha512-Ebk98v4mxaDWjGFl6VBeNv1zjeJ7UCQ29UTabzY2BpztvUCBHfLVQdMmuaAgzPRn+A3SFVOGpcl++CF0IEl+7A== @@ -8755,7 +8755,7 @@ minimist-options@4.1.0: is-plain-obj "^1.1.0" kind-of "^6.0.3" -minimist@^1.1.1, minimist@^1.2.0, minimist@^1.2.3, minimist@^1.2.5: +minimist@^1.1.1, minimist@^1.2.0, minimist@^1.2.3, minimist@^1.2.5, minimist@^1.2.6: version "1.2.6" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== From 11324290353126df2110b1e66d060be397056d4b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:46:26 +0000 Subject: [PATCH 209/240] build(deps): bump gatsby-transformer-yaml in /packages/website Bumps [gatsby-transformer-yaml](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-transformer-yaml) from 4.11.0 to 4.12.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-transformer-yaml/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-transformer-yaml@4.12.1/packages/gatsby-transformer-yaml) --- updated-dependencies: - dependency-name: gatsby-transformer-yaml dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 509fa80d..ad6ffb6e 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -25,7 +25,7 @@ "gatsby-plugin-svgr": "3.0.0-beta.0", "gatsby-source-filesystem": "4.10.1", "gatsby-transformer-sharp": "4.12.1", - "gatsby-transformer-yaml": "4.11.0", + "gatsby-transformer-yaml": "4.12.1", "gbimage-bridge": "0.2.1", "http-status-codes": "2.2.0", "ms": "2.1.3", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index da81d6f5..059884f7 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6496,10 +6496,10 @@ gatsby-transformer-sharp@4.12.1: semver "^7.3.5" sharp "^0.30.3" -gatsby-transformer-yaml@4.11.0: - version "4.11.0" - resolved "https://registry.yarnpkg.com/gatsby-transformer-yaml/-/gatsby-transformer-yaml-4.11.0.tgz#900bf446ce7aece9253f46244519ccb5bd8cf7f2" - integrity sha512-GTCkULgOxbyRbovO9VHi0P+7iv/fEQG3uBeKiJyvMRUDD4bIQ9uIdT7hZ1RPwctu9dpt9T/X7kx+CShRzmELYw== +gatsby-transformer-yaml@4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/gatsby-transformer-yaml/-/gatsby-transformer-yaml-4.12.1.tgz#0c372c25304d3305b3dcdc2b39c08e059d8f3d74" + integrity sha512-mpliK4YDMDBUe+g6JO6B8qhQffbBLoJI9q/4ja4YSbY/Jaj2tv/tkhepuwxOMuUwmQcBRu+OQ5J0RNiCI1aUcQ== dependencies: "@babel/runtime" "^7.15.4" js-yaml "^3.14.1" @@ -10911,7 +10911,7 @@ shallow-compare@^1.2.2: resolved "https://registry.yarnpkg.com/shallow-compare/-/shallow-compare-1.2.2.tgz#fa4794627bf455a47c4f56881d8a6132d581ffdb" integrity sha512-LUMFi+RppPlrHzbqmFnINTrazo0lPNwhcgzuAXVVcfy/mqPDrQmHAyz5bvV0gDAuRFrk804V0HpQ6u9sZ0tBeg== -sharp@^0.30.1, sharp@^0.30.3: +sharp@^0.30.3: version "0.30.3" resolved "https://registry.yarnpkg.com/sharp/-/sharp-0.30.3.tgz#315a1817423a4d1cde5119a21c99c234a7a6fb37" integrity sha512-rjpfJFK58ZOFSG8sxYSo3/JQb4ej095HjXp9X7gVu7gEn1aqSG8TCW29h/Rr31+PXrFADo1H/vKfw0uhMQWFtg== From 316eb3bef9aa22ba241b93bd1cfe0aa19cec9be4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:47:08 +0000 Subject: [PATCH 210/240] build(deps): bump gatsby-source-filesystem in /packages/website Bumps [gatsby-source-filesystem](https://github.com/gatsbyjs/gatsby/tree/HEAD/packages/gatsby-source-filesystem) from 4.10.1 to 4.12.1. - [Release notes](https://github.com/gatsbyjs/gatsby/releases) - [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-source-filesystem/CHANGELOG.md) - [Commits](https://github.com/gatsbyjs/gatsby/commits/gatsby-source-filesystem@4.12.1/packages/gatsby-source-filesystem) --- updated-dependencies: - dependency-name: gatsby-source-filesystem dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/website/package.json | 2 +- packages/website/yarn.lock | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/website/package.json b/packages/website/package.json index 509fa80d..daba4ea1 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -23,7 +23,7 @@ "gatsby-plugin-sharp": "4.12.1", "gatsby-plugin-sitemap": "5.12.1", "gatsby-plugin-svgr": "3.0.0-beta.0", - "gatsby-source-filesystem": "4.10.1", + "gatsby-source-filesystem": "4.12.1", "gatsby-transformer-sharp": "4.12.1", "gatsby-transformer-yaml": "4.11.0", "gbimage-bridge": "0.2.1", diff --git a/packages/website/yarn.lock b/packages/website/yarn.lock index da81d6f5..e48536bb 100644 --- a/packages/website/yarn.lock +++ b/packages/website/yarn.lock @@ -6209,7 +6209,7 @@ gatsby-cli@^4.12.1: yoga-layout-prebuilt "^1.10.0" yurnalist "^2.1.0" -gatsby-core-utils@^3.10.1, gatsby-core-utils@^3.12.1, gatsby-core-utils@^3.8.2: +gatsby-core-utils@^3.12.1, gatsby-core-utils@^3.8.2: version "3.12.1" resolved "https://registry.yarnpkg.com/gatsby-core-utils/-/gatsby-core-utils-3.12.1.tgz#590ec08de7168b086b7d49128732b9ada95b985f" integrity sha512-jBG1MfR6t2MZNIl8LQ3Cwc92F6uFNcEC091IK+qKVy9FNT0+WzcKQ6Olip6u1NSvCatfrg1FqrH0K78a6lmnLQ== @@ -6445,16 +6445,16 @@ gatsby-sharp@^0.6.1: "@types/sharp" "^0.30.0" sharp "^0.30.3" -gatsby-source-filesystem@4.10.1: - version "4.10.1" - resolved "https://registry.yarnpkg.com/gatsby-source-filesystem/-/gatsby-source-filesystem-4.10.1.tgz#c513fadb3cedb138ff28ba351ffd264524a0c28d" - integrity sha512-qdOWS234l6QyEN0M8tfdGQF530pK9nSiaT1JfSzZV7Bl9psX9SdsuOtfZ2AV0QVt1BQB7C53E/BNGaxMLCcnUg== +gatsby-source-filesystem@4.12.1: + version "4.12.1" + resolved "https://registry.yarnpkg.com/gatsby-source-filesystem/-/gatsby-source-filesystem-4.12.1.tgz#86f45cc047b0b9ca06b5e4ef5c48e69fa3ec2206" + integrity sha512-lbtKa7oR2Q+8Qa8gZych/JaRBeoIW/dk4rfy13DOrSgUJK9gZFkpLuFQ471Z0JiHitDPswienBW60HjYvymOCw== dependencies: "@babel/runtime" "^7.15.4" chokidar "^3.5.2" file-type "^16.5.3" fs-extra "^10.0.0" - gatsby-core-utils "^3.10.1" + gatsby-core-utils "^3.12.1" got "^9.6.0" md5-file "^5.0.0" mime "^2.5.2" @@ -10911,7 +10911,7 @@ shallow-compare@^1.2.2: resolved "https://registry.yarnpkg.com/shallow-compare/-/shallow-compare-1.2.2.tgz#fa4794627bf455a47c4f56881d8a6132d581ffdb" integrity sha512-LUMFi+RppPlrHzbqmFnINTrazo0lPNwhcgzuAXVVcfy/mqPDrQmHAyz5bvV0gDAuRFrk804V0HpQ6u9sZ0tBeg== -sharp@^0.30.1, sharp@^0.30.3: +sharp@^0.30.3: version "0.30.3" resolved "https://registry.yarnpkg.com/sharp/-/sharp-0.30.3.tgz#315a1817423a4d1cde5119a21c99c234a7a6fb37" integrity sha512-rjpfJFK58ZOFSG8sxYSo3/JQb4ej095HjXp9X7gVu7gEn1aqSG8TCW29h/Rr31+PXrFADo1H/vKfw0uhMQWFtg== From 0e480051a307f17350352b3edcdd92dc7b8a43c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20Wypch=C5=82o?= Date: Tue, 19 Apr 2022 11:55:41 +0200 Subject: [PATCH 211/240] change weekly dependabot schedule to monthly --- .github/dependabot.yml | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 05669038..beb0a9e2 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -3,48 +3,48 @@ updates: - package-ecosystem: npm directory: "/packages/dashboard" schedule: - interval: weekly + interval: monthly - package-ecosystem: npm directory: "/packages/dnslink-api" schedule: - interval: weekly + interval: monthly - package-ecosystem: npm directory: "/packages/handshake-api" schedule: - interval: weekly + interval: monthly - package-ecosystem: npm directory: "/packages/health-check" schedule: - interval: weekly + interval: monthly - package-ecosystem: npm directory: "/packages/website" schedule: - interval: weekly + interval: monthly - package-ecosystem: docker directory: "/docker/nginx" schedule: - interval: weekly + interval: monthly - package-ecosystem: docker directory: "/docker/sia" schedule: - interval: weekly + interval: monthly - package-ecosystem: docker directory: "/packages/dashboard" schedule: - interval: weekly + interval: monthly - package-ecosystem: docker directory: "/packages/dnslink-api" schedule: - interval: weekly + interval: monthly - package-ecosystem: docker directory: "/packages/handshake-api" schedule: - interval: weekly + interval: monthly - package-ecosystem: docker directory: "/packages/health-check" schedule: - interval: weekly + interval: monthly - package-ecosystem: docker directory: "/packages/website" schedule: - interval: weekly + interval: monthly From fe227f4449e221a155785cbdc351058f99f74e00 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Apr 2022 09:59:57 +0000 Subject: [PATCH 212/240] build(deps): bump stripe from 8.217.0 to 8.218.0 in /packages/dashboard Bumps [stripe](https://github.com/stripe/stripe-node) from 8.217.0 to 8.218.0. - [Release notes](https://github.com/stripe/stripe-node/releases) - [Changelog](https://github.com/stripe/stripe-node/blob/master/CHANGELOG.md) - [Commits](https://github.com/stripe/stripe-node/compare/v8.217.0...v8.218.0) --- updated-dependencies: - dependency-name: stripe dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 89bc5af2..6dd91ade 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -27,7 +27,7 @@ "react-dom": "17.0.2", "react-toastify": "8.2.0", "skynet-js": "3.0.2", - "stripe": "8.217.0", + "stripe": "8.218.0", "swr": "1.3.0", "yup": "0.32.11" }, diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 1034a786..2d85e0a1 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -2121,10 +2121,10 @@ strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== -stripe@8.217.0: - version "8.217.0" - resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.217.0.tgz#5e8ae744e0e8fca6e7c1d50c131ec3d77dff0999" - integrity sha512-CHWazNOrb1EBxTpepv5hCKMxOwF/oW3E4zRi8/LZIy5FC2y7A7NzcuE1aErYXLId3bKPe20HOmWKvjDRU2bXaA== +stripe@8.218.0: + version "8.218.0" + resolved "https://registry.yarnpkg.com/stripe/-/stripe-8.218.0.tgz#c63e751acd1ab4ef833a65e3d7713f8565d71d81" + integrity sha512-cH0CAep/x+N39dnfVKJxRpgPF5ggMR26Ckn0VkHH1rtFUspJzAEu4yTApSEszD2mirMK1gD42+oihJ1uJmbnUw== dependencies: "@types/node" ">=8.1.0" qs "^6.10.3" From f433287bb690d360f00bccfb03c5d0e5be37dd17 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Leszczyk?= Date: Tue, 19 Apr 2022 13:16:57 +0200 Subject: [PATCH 213/240] Dashboard v2 - fixes + publishing under /v2 path (#2008) * fix(dashboard-v2): fix current usage graph on portals without Stripe configured * ops(dashboard-v2): publish new dashboard under /v2 prefix * ops(dashboard-v2): fix SkynetClient on multi-server portals * fix(dashboard-v2): fix skylinks validation for sponsor keys * ops(dashboard-v2): don't actually launch the new dashboard yet :) * chore(dashboard-v2): cleanup console.log call * fix(dashboard-v2): always set portal domain for SkynetClient --- docker/nginx/conf.d/server/server.account | 5 +++++ packages/dashboard-v2/gatsby-config.js | 1 + packages/dashboard-v2/package.json | 4 ++-- .../components/AvatarUploader/AvatarUploader.js | 6 +++--- .../src/components/CurrentUsage/CurrentUsage.js | 10 ++++++++-- .../src/components/CurrentUsage/GraphBar.js | 4 ++-- .../src/components/CurrentUsage/UsageGraph.js | 4 +++- .../src/components/forms/AddSponsorKeyForm.js | 2 +- .../src/contexts/plans/PlansProvider.js | 15 ++++++++++++--- packages/dashboard-v2/src/layouts/AuthLayout.js | 7 +++++-- .../dashboard-v2/src/layouts/DashboardLayout.js | 4 +++- .../src/pages/settings/developer-settings.js | 4 +++- .../dashboard-v2/src/pages/settings/export.js | 4 +++- .../src/pages/settings/notifications.js | 7 ++++--- 14 files changed, 55 insertions(+), 22 deletions(-) diff --git a/docker/nginx/conf.d/server/server.account b/docker/nginx/conf.d/server/server.account index 127ba4bf..9d444296 100644 --- a/docker/nginx/conf.d/server/server.account +++ b/docker/nginx/conf.d/server/server.account @@ -3,6 +3,11 @@ listen 443 ssl http2; include /etc/nginx/conf.d/include/ssl-settings; include /etc/nginx/conf.d/include/init-optional-variables; +# Uncomment to launch new Dashboard under /v2 path +# location /v2 { +# proxy_pass http://dashboard-v2:9000; +# } + location / { proxy_pass http://dashboard:3000; } diff --git a/packages/dashboard-v2/gatsby-config.js b/packages/dashboard-v2/gatsby-config.js index 0e269557..d087fa65 100644 --- a/packages/dashboard-v2/gatsby-config.js +++ b/packages/dashboard-v2/gatsby-config.js @@ -11,6 +11,7 @@ module.exports = { title: `Account Dashboard`, siteUrl: `https://account.${GATSBY_PORTAL_DOMAIN}`, }, + pathPrefix: "/v2", trailingSlash: "never", plugins: [ "gatsby-plugin-image", diff --git a/packages/dashboard-v2/package.json b/packages/dashboard-v2/package.json index 694a6129..80070815 100644 --- a/packages/dashboard-v2/package.json +++ b/packages/dashboard-v2/package.json @@ -11,8 +11,8 @@ "develop": "gatsby develop", "develop:secure": "dotenv -e .env.development -- gatsby develop --https -p=443", "start": "gatsby develop", - "build": "gatsby build", - "serve": "gatsby serve", + "build": "gatsby build --prefix-paths", + "serve": "gatsby serve --prefix-paths", "clean": "gatsby clean", "lint": "eslint .", "prettier": "prettier .", diff --git a/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js b/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js index 2a3e400d..f97ca2d5 100644 --- a/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js +++ b/packages/dashboard-v2/src/components/AvatarUploader/AvatarUploader.js @@ -3,14 +3,14 @@ import { useEffect, useState } from "react"; import { useUser } from "../../contexts/user"; // import { SimpleUploadIcon } from "../Icons"; -const AVATAR_PLACEHOLDER = "/images/avatar-placeholder.svg"; +import avatarPlaceholder from "../../../static/images/avatar-placeholder.svg"; export const AvatarUploader = (props) => { const { user } = useUser(); - const [imageUrl, setImageUrl] = useState(AVATAR_PLACEHOLDER); + const [imageUrl, setImageUrl] = useState(avatarPlaceholder); useEffect(() => { - setImageUrl(user.avatarUrl ?? AVATAR_PLACEHOLDER); + setImageUrl(user.avatarUrl ?? avatarPlaceholder); }, [user]); return ( diff --git a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js index 3947638d..f9dbbc36 100644 --- a/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js +++ b/packages/dashboard-v2/src/components/CurrentUsage/CurrentUsage.js @@ -1,6 +1,7 @@ import { useEffect, useMemo, useState } from "react"; import fileSize from "pretty-bytes"; import { Link } from "gatsby"; +import cn from "classnames"; import useSWR from "swr"; import { useUser } from "../../contexts/user"; @@ -62,7 +63,9 @@ const ErrorMessage = () => ( ); export default function CurrentUsage() { + const { activePlan, plans } = useActivePlan(); const { usage, error, loading } = useUsageData(); + const nextPlan = useMemo(() => plans.find(({ tier }) => tier > activePlan?.tier), [plans, activePlan]); const storageUsage = size(usage.storageUsed); const storageLimit = size(usage.storageLimit); const filesUsedLabel = useMemo(() => ({ value: usage.filesUsed, unit: "files" }), [usage.filesUsed]); @@ -89,7 +92,7 @@ export default function CurrentUsage() { {storageLimit.text}
    - +
    @@ -97,7 +100,10 @@ export default function CurrentUsage() { UPGRADE {" "} diff --git a/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js b/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js index 1afab541..fd9a015e 100644 --- a/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js +++ b/packages/dashboard-v2/src/components/CurrentUsage/GraphBar.js @@ -21,11 +21,11 @@ const BarLabel = styled.span.attrs({ `} `; -export const GraphBar = ({ value, limit, label }) => { +export const GraphBar = ({ value, limit, label, className }) => { const percentage = typeof limit !== "number" || limit === 0 ? 0 : (value / limit) * 100; return ( -
    +
    diff --git a/packages/dashboard-v2/src/components/CurrentUsage/UsageGraph.js b/packages/dashboard-v2/src/components/CurrentUsage/UsageGraph.js index 3f6f23c2..de4e7e46 100644 --- a/packages/dashboard-v2/src/components/CurrentUsage/UsageGraph.js +++ b/packages/dashboard-v2/src/components/CurrentUsage/UsageGraph.js @@ -1,9 +1,11 @@ import styled from "styled-components"; +import usageGraphBg from "../../../static/images/usage-graph-bg.svg"; + export const UsageGraph = styled.div.attrs({ className: "w-full my-3 grid grid-flow-row grid-rows-2", })` height: 146px; - background: url(/images/usage-graph-bg.svg) no-repeat; + background: url(${usageGraphBg}) no-repeat; background-size: cover; `; diff --git a/packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js b/packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js index 0f8b8c62..236cdc9b 100644 --- a/packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js +++ b/packages/dashboard-v2/src/components/forms/AddSponsorKeyForm.js @@ -80,7 +80,7 @@ export const AddSponsorKeyForm = forwardRef(({ onSuccess }, ref) => { json: { name, public: "true", - skylinks: [...skylinks, nextSkylink].filter(Boolean).map(parseSkylink), + skylinks: [...skylinks, nextSkylink].filter(Boolean).map((skylink) => parseSkylink(skylink)), }, }) .json(); diff --git a/packages/dashboard-v2/src/contexts/plans/PlansProvider.js b/packages/dashboard-v2/src/contexts/plans/PlansProvider.js index 135c9bcb..7c6579ad 100644 --- a/packages/dashboard-v2/src/contexts/plans/PlansProvider.js +++ b/packages/dashboard-v2/src/contexts/plans/PlansProvider.js @@ -19,7 +19,14 @@ const aggregatePlansAndLimits = (plans, limits, { includeFreePlan }) => { // Decorate each plan with its corresponding limits data, if available. if (limits?.length) { - return sortedPlans.map((plan) => ({ ...plan, limits: limits[plan.tier] || null })); + return limits.map((limitsDescriptor, index) => { + const asssociatedPlan = sortedPlans.find((plan) => plan.tier === index) || {}; + + return { + ...asssociatedPlan, + limits: limitsDescriptor || null, + }; + }); } // If we don't have the limits data yet, set just return the plans. @@ -40,10 +47,12 @@ export const PlansProvider = ({ children }) => { if (plansError || limitsError) { setLoading(false); setError(plansError || limitsError); - } else if (rawPlans) { + } else if (rawPlans || limits) { setLoading(false); setPlans( - aggregatePlansAndLimits(rawPlans, limits?.userLimits, { includeFreePlan: !settings.isSubscriptionRequired }) + aggregatePlansAndLimits(rawPlans || [], limits?.userLimits, { + includeFreePlan: !settings.isSubscriptionRequired, + }) ); } }, [rawPlans, limits, plansError, limitsError, settings.isSubscriptionRequired]); diff --git a/packages/dashboard-v2/src/layouts/AuthLayout.js b/packages/dashboard-v2/src/layouts/AuthLayout.js index 8141e606..323e4319 100644 --- a/packages/dashboard-v2/src/layouts/AuthLayout.js +++ b/packages/dashboard-v2/src/layouts/AuthLayout.js @@ -3,10 +3,13 @@ import styled from "styled-components"; import { UserProvider } from "../contexts/user"; +import skynetLogo from "../../static/images/logo-black-text.svg"; +import authBg from "../../static/images/auth-bg.svg"; + const Layout = styled.div.attrs({ className: "min-h-screen w-screen bg-black flex", })` - background-image: url(/images/auth-bg.svg); + background-image: url(${authBg}); background-repeat: no-repeat; background-position: center center; `; @@ -36,7 +39,7 @@ const AuthLayout =
    - Skynet + Skynet
    {children}
    diff --git a/packages/dashboard-v2/src/layouts/DashboardLayout.js b/packages/dashboard-v2/src/layouts/DashboardLayout.js index 633057eb..8ac7c393 100644 --- a/packages/dashboard-v2/src/layouts/DashboardLayout.js +++ b/packages/dashboard-v2/src/layouts/DashboardLayout.js @@ -7,10 +7,12 @@ import { Footer } from "../components/Footer"; import { UserProvider, useUser } from "../contexts/user"; import { FullScreenLoadingIndicator } from "../components/LoadingIndicator"; +import dashboardBg from "../../static/images/dashboard-bg.svg"; + const Wrapper = styled.div.attrs({ className: "min-h-screen overflow-hidden", })` - background-image: url(/images/dashboard-bg.svg); + background-image: url(${dashboardBg}); background-position: center -280px; background-repeat: no-repeat; `; diff --git a/packages/dashboard-v2/src/pages/settings/developer-settings.js b/packages/dashboard-v2/src/pages/settings/developer-settings.js index cb58ab51..3f1917c1 100644 --- a/packages/dashboard-v2/src/pages/settings/developer-settings.js +++ b/packages/dashboard-v2/src/pages/settings/developer-settings.js @@ -10,6 +10,8 @@ import { AddSponsorKeyForm } from "../../components/forms/AddSponsorKeyForm"; import { Metadata } from "../../components/Metadata"; import HighlightedLink from "../../components/HighlightedLink"; +import apiKeysImg from "../../../static/images/api-keys.svg"; + const DeveloperSettingsPage = () => { const { data: allKeys = [], mutate: reloadKeys, error } = useSWR("user/apikeys"); const apiKeys = allKeys.filter(({ public: isPublic }) => isPublic === "false"); @@ -103,7 +105,7 @@ const DeveloperSettingsPage = () => {
    - +
    diff --git a/packages/dashboard-v2/src/pages/settings/export.js b/packages/dashboard-v2/src/pages/settings/export.js index 437f2b2f..aeb8aed3 100644 --- a/packages/dashboard-v2/src/pages/settings/export.js +++ b/packages/dashboard-v2/src/pages/settings/export.js @@ -6,6 +6,8 @@ import { Switch } from "../../components/Switch"; import { Button } from "../../components/Button"; import { Metadata } from "../../components/Metadata"; +import exportImg from "../../../static/images/import-export.svg"; + const useExportOptions = () => { const [pinnedFiles, setPinnedFiles] = useState(false); const [uploadHistory, setUploadHistory] = useState(false); @@ -65,7 +67,7 @@ const ExportPage = () => {
    - +
    diff --git a/packages/dashboard-v2/src/pages/settings/notifications.js b/packages/dashboard-v2/src/pages/settings/notifications.js index fc109d5c..5467f3a5 100644 --- a/packages/dashboard-v2/src/pages/settings/notifications.js +++ b/packages/dashboard-v2/src/pages/settings/notifications.js @@ -1,11 +1,12 @@ import * as React from "react"; -import { StaticImage } from "gatsby-plugin-image"; import UserSettingsLayout from "../../layouts/UserSettingsLayout"; import { Switch } from "../../components/Switch"; import { Metadata } from "../../components/Metadata"; +import inboxImg from "../../../static/images/inbox.svg"; + const NotificationsPage = () => { return ( <> @@ -37,8 +38,8 @@ const NotificationsPage = () => {
    -
    - +
    +
    From abf202ca54dffaf49e5df21e90ed2a25335c0e4c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 20 Apr 2022 15:05:11 +0000 Subject: [PATCH 214/240] build(deps): bump express-jwt from 6.1.1 to 6.1.2 in /packages/dashboard Bumps [express-jwt](https://github.com/auth0/express-jwt) from 6.1.1 to 6.1.2. - [Release notes](https://github.com/auth0/express-jwt/releases) - [Changelog](https://github.com/auth0/express-jwt/blob/master/CHANGELOG.md) - [Commits](https://github.com/auth0/express-jwt/compare/v6.1.1...v6.1.2) --- updated-dependencies: - dependency-name: express-jwt dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- packages/dashboard/package.json | 2 +- packages/dashboard/yarn.lock | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/dashboard/package.json b/packages/dashboard/package.json index 6dd91ade..a10f5b26 100644 --- a/packages/dashboard/package.json +++ b/packages/dashboard/package.json @@ -15,7 +15,7 @@ "classnames": "2.3.1", "copy-text-to-clipboard": "^3.0.1", "dayjs": "1.11.1", - "express-jwt": "6.1.1", + "express-jwt": "6.1.2", "fast-levenshtein": "3.0.0", "formik": "2.2.9", "http-status-codes": "2.2.0", diff --git a/packages/dashboard/yarn.lock b/packages/dashboard/yarn.lock index 2d85e0a1..f4e7ce67 100644 --- a/packages/dashboard/yarn.lock +++ b/packages/dashboard/yarn.lock @@ -357,10 +357,10 @@ ast-types-flow@^0.0.7: resolved "https://registry.yarnpkg.com/ast-types-flow/-/ast-types-flow-0.0.7.tgz#f70b735c6bca1a5c9c22d982c3e39e7feba3bdad" integrity sha1-9wtzXGvKGlycItmCw+Oef+ujva0= -async@^1.5.0: - version "1.5.2" - resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" - integrity sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo= +async@^3.2.2: + version "3.2.3" + resolved "https://registry.yarnpkg.com/async/-/async-3.2.3.tgz#ac53dafd3f4720ee9e8a160628f18ea91df196c9" + integrity sha512-spZRyzKL5l5BZQrr/6m/SqFdBN0q3OCI0f9rjfBzCMBIP4p75P620rR3gTmaksNOhmzgdxcaxdNfMy6anrbM0g== autoprefixer@10.4.4: version "10.4.4" @@ -920,12 +920,12 @@ esutils@^2.0.2: resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== -express-jwt@6.1.1: - version "6.1.1" - resolved "https://registry.yarnpkg.com/express-jwt/-/express-jwt-6.1.1.tgz#2b157fb4fa33c2d367ee71c61b5aca762de39657" - integrity sha512-m8gkY04v5jtiFZn6bYQINYX/DVXq1DVb5nIW7H8l87qJ4BBvtQKFRpxyRE31odct7OPfHdT+B8678zJHhlMrpw== +express-jwt@6.1.2: + version "6.1.2" + resolved "https://registry.yarnpkg.com/express-jwt/-/express-jwt-6.1.2.tgz#4a6cc11d1dcff6f23126dd79ec5b2b441333e78b" + integrity sha512-l5dlf5lNM/1EODMsJGfHn1VnrhhsUYEetzrKFStJZLjFQXtR+HGdBiW+jUNZ+ISsFe+h7Wl/hQKjLrY2TX0Qkg== dependencies: - async "^1.5.0" + async "^3.2.2" express-unless "^1.0.0" jsonwebtoken "^8.1.0" lodash "^4.17.21" From de7e7879b7b9be86084013bb0f4ac3c4d6958505 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 21 Apr 2022 10:48:53 +0200 Subject: [PATCH 215/240] use dashboard dockerhub image --- docker-compose.accounts.yml | 12 ++++++------ packages/dashboard-v2/Dockerfile | 14 +++++++++----- packages/dashboard/Dockerfile | 15 ++++++++++----- 3 files changed, 25 insertions(+), 16 deletions(-) diff --git a/docker-compose.accounts.yml b/docker-compose.accounts.yml index 3c2c46a9..47668b60 100644 --- a/docker-compose.accounts.yml +++ b/docker-compose.accounts.yml @@ -55,9 +55,11 @@ services: - mongo dashboard: - build: - context: ./packages/dashboard - dockerfile: Dockerfile + # uncomment "build" and comment out "image" to build from sources + # build: + # context: https://github.com/SkynetLabs/skynet-webportal.git#master + # dockerfile: ./packages/dashboard/Dockerfile + image: skynetlabs/dashboard container_name: dashboard restart: unless-stopped logging: *default-logging @@ -77,9 +79,7 @@ services: - mongo dashboard-v2: - build: - context: ./packages/dashboard-v2 - dockerfile: Dockerfile + build: packages/dashboard-v2/Dockerfile container_name: dashboard-v2 restart: unless-stopped logging: *default-logging diff --git a/packages/dashboard-v2/Dockerfile b/packages/dashboard-v2/Dockerfile index 70790cfa..4c834e0c 100644 --- a/packages/dashboard-v2/Dockerfile +++ b/packages/dashboard-v2/Dockerfile @@ -2,13 +2,17 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY package.json yarn.lock ./ +COPY packages/dashboard-v2/package.json \ + packages/dashboard-v2/yarn.lock \ + ./ RUN yarn --frozen-lockfile -COPY static ./static -COPY src ./src -COPY gatsby*.js ./ -COPY postcss.config.js tailwind.config.js ./ +COPY packages/dashboard-v2/static ./static +COPY packages/dashboard-v2/src ./src +COPY packages/dashboard-v2/gatsby*.js \ + packages/dashboard-v2/postcss.config.js \ + packages/dashboard-v2/tailwind.config.js \ + ./ CMD ["sh", "-c", "yarn build && yarn serve --host 0.0.0.0 -p 9000"] diff --git a/packages/dashboard/Dockerfile b/packages/dashboard/Dockerfile index 39707664..25f584b3 100644 --- a/packages/dashboard/Dockerfile +++ b/packages/dashboard/Dockerfile @@ -2,14 +2,19 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY package.json yarn.lock ./ +COPY packages/dashboard/package.json \ + packages/dashboard/yarn.lock \ + ./ ENV NEXT_TELEMETRY_DISABLED 1 RUN yarn --frozen-lockfile -COPY public ./public -COPY src ./src -COPY styles ./styles -COPY .eslintrc.json postcss.config.js tailwind.config.js ./ +COPY packages/dashboard/public ./public +COPY packages/dashboard/src ./src +COPY packages/dashboard/styles ./styles +COPY packages/dashboard/.eslintrc.json \ + packages/dashboard/postcss.config.js \ + packages/dashboard/tailwind.config.js \ + ./ CMD ["sh", "-c", "env | grep -E 'NEXT_PUBLIC|STRIPE|ACCOUNTS' > .env.local && yarn build && yarn start"] From 68bd26f17e4726e2e1134e0bf0d1016ef45d3ee5 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 21 Apr 2022 11:27:34 +0200 Subject: [PATCH 216/240] fix context on dasboard-v2 container --- docker-compose.accounts.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docker-compose.accounts.yml b/docker-compose.accounts.yml index 47668b60..b154bac7 100644 --- a/docker-compose.accounts.yml +++ b/docker-compose.accounts.yml @@ -79,7 +79,9 @@ services: - mongo dashboard-v2: - build: packages/dashboard-v2/Dockerfile + build: + context: . + dockerfile: packages/dashboard-v2/Dockerfile container_name: dashboard-v2 restart: unless-stopped logging: *default-logging From 98306b473c00af6f0ff2b6870cd0deffd90938f8 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 21 Apr 2022 14:22:50 +0200 Subject: [PATCH 217/240] use official nginx entrypoint with envsubst and custom restart script --- docker-compose.yml | 8 +- docker/nginx/Dockerfile | 41 +- .../conf.d.templates/server.account.conf | 45 - .../server.account.conf.template | 39 + docker/nginx/conf.d.templates/server.api.conf | 43 - .../conf.d.templates/server.api.conf.template | 39 + ...link.conf => server.dnslink.conf.template} | 8 +- docker/nginx/conf.d.templates/server.hns.conf | 45 - .../conf.d.templates/server.hns.conf.template | 41 + .../conf.d.templates/server.skylink.conf | 43 - .../server.skylink.conf.template | 39 + .../20-envsubst-on-templates.sh | 36 + .../40-reload-every-x-hours.sh | 20 + .../50-generate-local-certificate.sh | 18 + docker/nginx/docker-entrypoint.sh | 42 + docker/nginx/mo | 1106 ----------------- docker/nginx/nginx.conf | 3 + 17 files changed, 307 insertions(+), 1309 deletions(-) delete mode 100644 docker/nginx/conf.d.templates/server.account.conf create mode 100644 docker/nginx/conf.d.templates/server.account.conf.template delete mode 100644 docker/nginx/conf.d.templates/server.api.conf create mode 100644 docker/nginx/conf.d.templates/server.api.conf.template rename docker/nginx/conf.d.templates/{server.dnslink.conf => server.dnslink.conf.template} (71%) delete mode 100644 docker/nginx/conf.d.templates/server.hns.conf create mode 100644 docker/nginx/conf.d.templates/server.hns.conf.template delete mode 100644 docker/nginx/conf.d.templates/server.skylink.conf create mode 100644 docker/nginx/conf.d.templates/server.skylink.conf.template create mode 100755 docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh create mode 100755 docker/nginx/docker-entrypoint.d/40-reload-every-x-hours.sh create mode 100755 docker/nginx/docker-entrypoint.d/50-generate-local-certificate.sh create mode 100755 docker/nginx/docker-entrypoint.sh delete mode 100755 docker/nginx/mo diff --git a/docker-compose.yml b/docker-compose.yml index 5838f136..d92b14fe 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -54,9 +54,11 @@ services: - ./docker/data/certbot:/etc/letsencrypt nginx: - build: - context: ./docker/nginx - dockerfile: Dockerfile + # uncomment "build" and comment out "image" to build from sources + # build: + # context: https://github.com/SkynetLabs/skynet-webportal.git#master + # dockerfile: ./docker/nginx/Dockerfile + image: skynetlabs/nginx container_name: nginx restart: unless-stopped logging: *default-logging diff --git a/docker/nginx/Dockerfile b/docker/nginx/Dockerfile index eca1e3d8..12b27712 100644 --- a/docker/nginx/Dockerfile +++ b/docker/nginx/Dockerfile @@ -2,25 +2,26 @@ FROM openresty/openresty:1.19.9.1-focal WORKDIR / -RUN luarocks install lua-resty-http && \ - luarocks install hasher && \ - openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 \ - -subj '/CN=local-certificate' \ - -keyout /etc/ssl/local-certificate.key \ - -out /etc/ssl/local-certificate.crt +RUN apt-get update && apt-get --no-install-recommends install bc=1.07.1-2build1 && \ + apt-get clean && rm -rf /var/lib/apt/lists/* && \ + luarocks install lua-resty-http && \ + luarocks install hasher -COPY mo ./ -COPY libs /etc/nginx/libs -COPY conf.d /etc/nginx/conf.d -COPY conf.d.templates /etc/nginx/conf.d.templates -COPY nginx.conf /usr/local/openresty/nginx/conf/nginx.conf +# reload nginx every 6 hours (for reloading certificates) +ENV NGINX_ENTRYPOINT_RELOAD_EVERY_X_HOURS 6 -CMD [ "bash", "-c", \ - "./mo < /etc/nginx/conf.d.templates/server.account.conf > /etc/nginx/conf.d/server.account.conf ; \ - ./mo < /etc/nginx/conf.d.templates/server.api.conf > /etc/nginx/conf.d/server.api.conf; \ - ./mo < /etc/nginx/conf.d.templates/server.dnslink.conf > /etc/nginx/conf.d/server.dnslink.conf; \ - ./mo < /etc/nginx/conf.d.templates/server.hns.conf > /etc/nginx/conf.d/server.hns.conf; \ - ./mo < /etc/nginx/conf.d.templates/server.skylink.conf > /etc/nginx/conf.d/server.skylink.conf ; \ - while :; do sleep 6h & wait ${!}; /usr/local/openresty/bin/openresty -s reload; done & \ - /usr/local/openresty/bin/openresty '-g daemon off;'" \ - ] +# copy entrypoint and entrypoint scripts +COPY docker/nginx/docker-entrypoint.sh / +COPY docker/nginx/docker-entrypoint.d /docker-entrypoint.d + +# copy nginx configuration files and libraries +COPY docker/nginx/libs /etc/nginx/libs +COPY docker/nginx/conf.d /etc/nginx/conf.d +COPY docker/nginx/conf.d.templates /etc/nginx/templates +COPY docker/nginx/nginx.conf /usr/local/openresty/nginx/conf/nginx.conf + +ENTRYPOINT ["/docker-entrypoint.sh"] + +STOPSIGNAL SIGQUIT + +CMD ["nginx", "-g", "daemon off;"] diff --git a/docker/nginx/conf.d.templates/server.account.conf b/docker/nginx/conf.d.templates/server.account.conf deleted file mode 100644 index af3b7c4d..00000000 --- a/docker/nginx/conf.d.templates/server.account.conf +++ /dev/null @@ -1,45 +0,0 @@ -{{#ACCOUNTS_ENABLED}} - {{#PORTAL_DOMAIN}} - server { - server_name account.{{PORTAL_DOMAIN}}; # example: account.siasky.net - - include /etc/nginx/conf.d/server/server.http; - } - - server { - server_name account.{{PORTAL_DOMAIN}}; # example: account.siasky.net - - set_by_lua_block $skynet_portal_domain { return "{{PORTAL_DOMAIN}}" } - set_by_lua_block $skynet_server_domain { - -- fall back to portal domain if server domain is not defined - if "{{SERVER_DOMAIN}}" == "" then - return "{{PORTAL_DOMAIN}}" - end - return "{{SERVER_DOMAIN}}" - } - - include /etc/nginx/conf.d/server/server.account; - } - {{/PORTAL_DOMAIN}} - - {{#SERVER_DOMAIN}} - server { - server_name account.{{SERVER_DOMAIN}}; # example: account.eu-ger-1.siasky.net - - include /etc/nginx/conf.d/server/server.http; - - set_by_lua_block $server_alias { return string.match("{{SERVER_DOMAIN}}", "^([^.]+)") } - } - - server { - server_name account.{{SERVER_DOMAIN}}; # example: account.eu-ger-1.siasky.net - - set_by_lua_block $skynet_portal_domain { return "{{SERVER_DOMAIN}}" } - set_by_lua_block $skynet_server_domain { return "{{SERVER_DOMAIN}}" } - - include /etc/nginx/conf.d/server/server.account; - - set_by_lua_block $server_alias { return string.match("{{SERVER_DOMAIN}}", "^([^.]+)") } - } - {{/SERVER_DOMAIN}} -{{/ACCOUNTS_ENABLED}} diff --git a/docker/nginx/conf.d.templates/server.account.conf.template b/docker/nginx/conf.d.templates/server.account.conf.template new file mode 100644 index 00000000..64de6523 --- /dev/null +++ b/docker/nginx/conf.d.templates/server.account.conf.template @@ -0,0 +1,39 @@ +server { + server_name account.${PORTAL_DOMAIN}; # example: account.siasky.net + + include /etc/nginx/conf.d/server/server.http; +} + +server { + server_name account.${PORTAL_DOMAIN}; # example: account.siasky.net + + set_by_lua_block $skynet_portal_domain { return "${PORTAL_DOMAIN}" } + set_by_lua_block $skynet_server_domain { + -- fall back to portal domain if server domain is not defined + if "${SERVER_DOMAIN}" == "" then + return "${PORTAL_DOMAIN}" + end + return "${SERVER_DOMAIN}" + } + + include /etc/nginx/conf.d/server/server.account; +} + +server { + server_name account.${SERVER_DOMAIN}; # example: account.eu-ger-1.siasky.net + + include /etc/nginx/conf.d/server/server.http; + + set_by_lua_block $server_alias { return string.match("${SERVER_DOMAIN}", "^([^.]+)") } +} + +server { + server_name account.${SERVER_DOMAIN}; # example: account.eu-ger-1.siasky.net + + set_by_lua_block $skynet_portal_domain { return "${SERVER_DOMAIN}" } + set_by_lua_block $skynet_server_domain { return "${SERVER_DOMAIN}" } + + include /etc/nginx/conf.d/server/server.account; + + set_by_lua_block $server_alias { return string.match("${SERVER_DOMAIN}", "^([^.]+)") } +} diff --git a/docker/nginx/conf.d.templates/server.api.conf b/docker/nginx/conf.d.templates/server.api.conf deleted file mode 100644 index 591212ba..00000000 --- a/docker/nginx/conf.d.templates/server.api.conf +++ /dev/null @@ -1,43 +0,0 @@ -{{#PORTAL_DOMAIN}} -server { - server_name {{PORTAL_DOMAIN}}; # example: siasky.net - - include /etc/nginx/conf.d/server/server.http; -} - -server { - server_name {{PORTAL_DOMAIN}}; # example: siasky.net - - set_by_lua_block $skynet_portal_domain { return "{{PORTAL_DOMAIN}}" } - set_by_lua_block $skynet_server_domain { - -- fall back to portal domain if server domain is not defined - if "{{SERVER_DOMAIN}}" == "" then - return "{{PORTAL_DOMAIN}}" - end - return "{{SERVER_DOMAIN}}" - } - - include /etc/nginx/conf.d/server/server.api; -} -{{/PORTAL_DOMAIN}} - -{{#SERVER_DOMAIN}} -server { - server_name {{SERVER_DOMAIN}}; # example: eu-ger-1.siasky.net - - include /etc/nginx/conf.d/server/server.http; - - set_by_lua_block $server_alias { return string.match("{{SERVER_DOMAIN}}", "^([^.]+)") } -} - -server { - server_name {{SERVER_DOMAIN}}; # example: eu-ger-1.siasky.net - - set_by_lua_block $skynet_portal_domain { return "{{SERVER_DOMAIN}}" } - set_by_lua_block $skynet_server_domain { return "{{SERVER_DOMAIN}}" } - - include /etc/nginx/conf.d/server/server.api; - - set_by_lua_block $server_alias { return string.match("{{SERVER_DOMAIN}}", "^([^.]+)") } -} -{{/SERVER_DOMAIN}} diff --git a/docker/nginx/conf.d.templates/server.api.conf.template b/docker/nginx/conf.d.templates/server.api.conf.template new file mode 100644 index 00000000..7d36ff08 --- /dev/null +++ b/docker/nginx/conf.d.templates/server.api.conf.template @@ -0,0 +1,39 @@ +server { + server_name ${PORTAL_DOMAIN}; # example: siasky.net + + include /etc/nginx/conf.d/server/server.http; +} + +server { + server_name ${PORTAL_DOMAIN}; # example: siasky.net + + set_by_lua_block $skynet_portal_domain { return "${PORTAL_DOMAIN}" } + set_by_lua_block $skynet_server_domain { + -- fall back to portal domain if server domain is not defined + if "${SERVER_DOMAIN}" == "" then + return "${PORTAL_DOMAIN}" + end + return "${SERVER_DOMAIN}" + } + + include /etc/nginx/conf.d/server/server.api; +} + +server { + server_name ${SERVER_DOMAIN}; # example: eu-ger-1.siasky.net + + include /etc/nginx/conf.d/server/server.http; + + set_by_lua_block $server_alias { return string.match("${SERVER_DOMAIN}", "^([^.]+)") } +} + +server { + server_name ${SERVER_DOMAIN}; # example: eu-ger-1.siasky.net + + set_by_lua_block $skynet_portal_domain { return "${SERVER_DOMAIN}" } + set_by_lua_block $skynet_server_domain { return "${SERVER_DOMAIN}" } + + include /etc/nginx/conf.d/server/server.api; + + set_by_lua_block $server_alias { return string.match("${SERVER_DOMAIN}", "^([^.]+)") } +} diff --git a/docker/nginx/conf.d.templates/server.dnslink.conf b/docker/nginx/conf.d.templates/server.dnslink.conf.template similarity index 71% rename from docker/nginx/conf.d.templates/server.dnslink.conf rename to docker/nginx/conf.d.templates/server.dnslink.conf.template index d42ee245..95c623b6 100644 --- a/docker/nginx/conf.d.templates/server.dnslink.conf +++ b/docker/nginx/conf.d.templates/server.dnslink.conf.template @@ -12,13 +12,13 @@ server { ssl_certificate /etc/ssl/local-certificate.crt; ssl_certificate_key /etc/ssl/local-certificate.key; - set_by_lua_block $skynet_portal_domain { return "{{PORTAL_DOMAIN}}" } + set_by_lua_block $skynet_portal_domain { return "${PORTAL_DOMAIN}" } set_by_lua_block $skynet_server_domain { -- fall back to portal domain if server domain is not defined - if "{{SERVER_DOMAIN}}" == "" then - return "{{PORTAL_DOMAIN}}" + if "${SERVER_DOMAIN}" == "" then + return "${PORTAL_DOMAIN}" end - return "{{SERVER_DOMAIN}}" + return "${SERVER_DOMAIN}" } include /etc/nginx/conf.d/server/server.dnslink; diff --git a/docker/nginx/conf.d.templates/server.hns.conf b/docker/nginx/conf.d.templates/server.hns.conf deleted file mode 100644 index 0e4f21f3..00000000 --- a/docker/nginx/conf.d.templates/server.hns.conf +++ /dev/null @@ -1,45 +0,0 @@ -{{#PORTAL_DOMAIN}} -server { - server_name *.hns.{{PORTAL_DOMAIN}}; # example: *.hns.siasky.net - - include /etc/nginx/conf.d/server/server.http; -} - -server { - server_name *.hns.{{PORTAL_DOMAIN}}; # example: *.hns.siasky.net - - set_by_lua_block $skynet_portal_domain { return "{{PORTAL_DOMAIN}}" } - set_by_lua_block $skynet_server_domain { - -- fall back to portal domain if server domain is not defined - if "{{SERVER_DOMAIN}}" == "" then - return "{{PORTAL_DOMAIN}}" - end - return "{{SERVER_DOMAIN}}" - } - - proxy_set_header Host {{PORTAL_DOMAIN}}; - include /etc/nginx/conf.d/server/server.hns; -} -{{/PORTAL_DOMAIN}} - -{{#SERVER_DOMAIN}} -server { - server_name *.hns.{{SERVER_DOMAIN}}; # example: *.hns.eu-ger-1.siasky.net - - include /etc/nginx/conf.d/server/server.http; - - set_by_lua_block $server_alias { return string.match("{{SERVER_DOMAIN}}", "^([^.]+)") } -} - -server { - server_name *.hns.{{SERVER_DOMAIN}}; # example: *.hns.eu-ger-1.siasky.net - - set_by_lua_block $skynet_portal_domain { return "{{SERVER_DOMAIN}}" } - set_by_lua_block $skynet_server_domain { return "{{SERVER_DOMAIN}}" } - - proxy_set_header Host {{SERVER_DOMAIN}}; - include /etc/nginx/conf.d/server/server.hns; - - set_by_lua_block $server_alias { return string.match("{{SERVER_DOMAIN}}", "^([^.]+)") } -} -{{/SERVER_DOMAIN}} diff --git a/docker/nginx/conf.d.templates/server.hns.conf.template b/docker/nginx/conf.d.templates/server.hns.conf.template new file mode 100644 index 00000000..7067ce4d --- /dev/null +++ b/docker/nginx/conf.d.templates/server.hns.conf.template @@ -0,0 +1,41 @@ +server { + server_name *.hns.${PORTAL_DOMAIN}; # example: *.hns.siasky.net + + include /etc/nginx/conf.d/server/server.http; +} + +server { + server_name *.hns.${PORTAL_DOMAIN}; # example: *.hns.siasky.net + + set_by_lua_block $skynet_portal_domain { return "${PORTAL_DOMAIN}" } + set_by_lua_block $skynet_server_domain { + -- fall back to portal domain if server domain is not defined + if "${SERVER_DOMAIN}" == "" then + return "${PORTAL_DOMAIN}" + end + return "${SERVER_DOMAIN}" + } + + proxy_set_header Host ${PORTAL_DOMAIN}; + include /etc/nginx/conf.d/server/server.hns; +} + +server { + server_name *.hns.${SERVER_DOMAIN}; # example: *.hns.eu-ger-1.siasky.net + + include /etc/nginx/conf.d/server/server.http; + + set_by_lua_block $server_alias { return string.match("${SERVER_DOMAIN}", "^([^.]+)") } +} + +server { + server_name *.hns.${SERVER_DOMAIN}; # example: *.hns.eu-ger-1.siasky.net + + set_by_lua_block $skynet_portal_domain { return "${SERVER_DOMAIN}" } + set_by_lua_block $skynet_server_domain { return "${SERVER_DOMAIN}" } + + proxy_set_header Host ${SERVER_DOMAIN}; + include /etc/nginx/conf.d/server/server.hns; + + set_by_lua_block $server_alias { return string.match("${SERVER_DOMAIN}", "^([^.]+)") } +} diff --git a/docker/nginx/conf.d.templates/server.skylink.conf b/docker/nginx/conf.d.templates/server.skylink.conf deleted file mode 100644 index a97e240c..00000000 --- a/docker/nginx/conf.d.templates/server.skylink.conf +++ /dev/null @@ -1,43 +0,0 @@ -{{#PORTAL_DOMAIN}} -server { - server_name *.{{PORTAL_DOMAIN}}; # example: *.siasky.net - - include /etc/nginx/conf.d/server/server.http; -} - -server { - server_name *.{{PORTAL_DOMAIN}}; # example: *.siasky.net - - set_by_lua_block $skynet_portal_domain { return "{{PORTAL_DOMAIN}}" } - set_by_lua_block $skynet_server_domain { - -- fall back to portal domain if server domain is not defined - if "{{SERVER_DOMAIN}}" == "" then - return "{{PORTAL_DOMAIN}}" - end - return "{{SERVER_DOMAIN}}" - } - - include /etc/nginx/conf.d/server/server.skylink; -} -{{/PORTAL_DOMAIN}} - -{{#SERVER_DOMAIN}} -server { - server_name *.{{SERVER_DOMAIN}}; # example: *.eu-ger-1.siasky.net - - include /etc/nginx/conf.d/server/server.http; - - set_by_lua_block $server_alias { return string.match("{{SERVER_DOMAIN}}", "^([^.]+)") } -} - -server { - server_name *.{{SERVER_DOMAIN}}; # example: *.eu-ger-1.siasky.net - - set_by_lua_block $skynet_portal_domain { return "{{SERVER_DOMAIN}}" } - set_by_lua_block $skynet_server_domain { return "{{SERVER_DOMAIN}}" } - - include /etc/nginx/conf.d/server/server.skylink; - - set_by_lua_block $server_alias { return string.match("{{SERVER_DOMAIN}}", "^([^.]+)") } -} -{{/SERVER_DOMAIN}} diff --git a/docker/nginx/conf.d.templates/server.skylink.conf.template b/docker/nginx/conf.d.templates/server.skylink.conf.template new file mode 100644 index 00000000..7e22c13c --- /dev/null +++ b/docker/nginx/conf.d.templates/server.skylink.conf.template @@ -0,0 +1,39 @@ +server { + server_name *.${PORTAL_DOMAIN}; # example: *.siasky.net + + include /etc/nginx/conf.d/server/server.http; +} + +server { + server_name *.${PORTAL_DOMAIN}; # example: *.siasky.net + + set_by_lua_block $skynet_portal_domain { return "${PORTAL_DOMAIN}" } + set_by_lua_block $skynet_server_domain { + -- fall back to portal domain if server domain is not defined + if "${SERVER_DOMAIN}" == "" then + return "${PORTAL_DOMAIN}" + end + return "${SERVER_DOMAIN}" + } + + include /etc/nginx/conf.d/server/server.skylink; +} + +server { + server_name *.${SERVER_DOMAIN}; # example: *.eu-ger-1.siasky.net + + include /etc/nginx/conf.d/server/server.http; + + set_by_lua_block $server_alias { return string.match("${SERVER_DOMAIN}", "^([^.]+)") } +} + +server { + server_name *.${SERVER_DOMAIN}; # example: *.eu-ger-1.siasky.net + + set_by_lua_block $skynet_portal_domain { return "${SERVER_DOMAIN}" } + set_by_lua_block $skynet_server_domain { return "${SERVER_DOMAIN}" } + + include /etc/nginx/conf.d/server/server.skylink; + + set_by_lua_block $server_alias { return string.match("${SERVER_DOMAIN}", "^([^.]+)") } +} diff --git a/docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh b/docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh new file mode 100755 index 00000000..c46cea44 --- /dev/null +++ b/docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh @@ -0,0 +1,36 @@ +#!/bin/sh + +# https://github.com/nginxinc/docker-nginx/blob/master/entrypoint/20-envsubst-on-templates.sh +# Copyright (C) 2011-2016 Nginx, Inc. +# All rights reserved. + +set -e + +ME=$(basename $0) + +auto_envsubst() { + local template_dir="${NGINX_ENVSUBST_TEMPLATE_DIR:-/etc/nginx/templates}" + local suffix="${NGINX_ENVSUBST_TEMPLATE_SUFFIX:-.template}" + local output_dir="${NGINX_ENVSUBST_OUTPUT_DIR:-/etc/nginx/conf.d}" + + local template defined_envs relative_path output_path subdir + defined_envs=$(printf '${%s} ' $(env | cut -d= -f1)) + [ -d "$template_dir" ] || return 0 + if [ ! -w "$output_dir" ]; then + echo >&3 "$ME: ERROR: $template_dir exists, but $output_dir is not writable" + return 0 + fi + find "$template_dir" -follow -type f -name "*$suffix" -print | while read -r template; do + relative_path="${template#$template_dir/}" + output_path="$output_dir/${relative_path%$suffix}" + subdir=$(dirname "$relative_path") + # create a subdirectory where the template file exists + mkdir -p "$output_dir/$subdir" + echo >&3 "$ME: Running envsubst on $template to $output_path" + envsubst "$defined_envs" < "$template" > "$output_path" + done +} + +auto_envsubst + +exit 0 diff --git a/docker/nginx/docker-entrypoint.d/40-reload-every-x-hours.sh b/docker/nginx/docker-entrypoint.d/40-reload-every-x-hours.sh new file mode 100755 index 00000000..cdd7d17e --- /dev/null +++ b/docker/nginx/docker-entrypoint.d/40-reload-every-x-hours.sh @@ -0,0 +1,20 @@ +#!/bin/sh + +# source: https://github.com/nginxinc/docker-nginx/pull/509 + +set -e + +ME=$(basename $0) + +[ "${NGINX_ENTRYPOINT_RELOAD_EVERY_X_HOURS:-}" ] || exit 0 +if [ $(echo "$NGINX_ENTRYPOINT_RELOAD_EVERY_X_HOURS > 0" | bc) = 0 ]; then + echo >&3 "$ME: Error. Provide integer or floating point number greater that 0. See 'man sleep'." + exit 1 +fi + +start_background_reload() { + echo >&3 "$ME: Reloading Nginx every $NGINX_ENTRYPOINT_RELOAD_EVERY_X_HOURS hour(s)" + while :; do sleep ${NGINX_ENTRYPOINT_RELOAD_EVERY_X_HOURS}h; echo >&3 "$ME: Reloading Nginx ..." && nginx -s reload; done & +} + +start_background_reload diff --git a/docker/nginx/docker-entrypoint.d/50-generate-local-certificate.sh b/docker/nginx/docker-entrypoint.d/50-generate-local-certificate.sh new file mode 100755 index 00000000..d556fd3e --- /dev/null +++ b/docker/nginx/docker-entrypoint.d/50-generate-local-certificate.sh @@ -0,0 +1,18 @@ +#!/bin/sh + +# Generate locally signed ssl certificate to be used on routes +# that do not require certificate issued by trusted CA + +set -e + +ME=$(basename $0) + +generate_local_certificate() { + echo >&3 "$ME: Generating locally signed ssl certificate" + openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 \ + -subj '/CN=local-certificate' \ + -keyout /etc/ssl/local-certificate.key \ + -out /etc/ssl/local-certificate.crt +} + +generate_local_certificate diff --git a/docker/nginx/docker-entrypoint.sh b/docker/nginx/docker-entrypoint.sh new file mode 100755 index 00000000..07793211 --- /dev/null +++ b/docker/nginx/docker-entrypoint.sh @@ -0,0 +1,42 @@ +#!/bin/sh +# vim:sw=4:ts=4:et + +# https://github.com/nginxinc/docker-nginx/blob/master/entrypoint/docker-entrypoint.sh +# Copyright (C) 2011-2016 Nginx, Inc. +# All rights reserved. + +set -e + +if [ -z "${NGINX_ENTRYPOINT_QUIET_LOGS:-}" ]; then + exec 3>&1 +else + exec 3>/dev/null +fi + +if [ "$1" = "nginx" -o "$1" = "nginx-debug" ]; then + if /usr/bin/find "/docker-entrypoint.d/" -mindepth 1 -maxdepth 1 -type f -print -quit 2>/dev/null | read v; then + echo >&3 "$0: /docker-entrypoint.d/ is not empty, will attempt to perform configuration" + + echo >&3 "$0: Looking for shell scripts in /docker-entrypoint.d/" + find "/docker-entrypoint.d/" -follow -type f -print | sort -V | while read -r f; do + case "$f" in + *.sh) + if [ -x "$f" ]; then + echo >&3 "$0: Launching $f"; + "$f" + else + # warn on shell scripts without exec bit + echo >&3 "$0: Ignoring $f, not executable"; + fi + ;; + *) echo >&3 "$0: Ignoring $f";; + esac + done + + echo >&3 "$0: Configuration complete; ready for start up" + else + echo >&3 "$0: No files found in /docker-entrypoint.d/, skipping configuration" + fi +fi + +exec "$@" diff --git a/docker/nginx/mo b/docker/nginx/mo deleted file mode 100755 index ba8e48d1..00000000 --- a/docker/nginx/mo +++ /dev/null @@ -1,1106 +0,0 @@ -#!/usr/bin/env bash -# -#/ Mo is a mustache template rendering software written in bash. It inserts -#/ environment variables into templates. -#/ -#/ Simply put, mo will change {{VARIABLE}} into the value of that -#/ environment variable. You can use {{#VARIABLE}}content{{/VARIABLE}} to -#/ conditionally display content or iterate over the values of an array. -#/ -#/ Learn more about mustache templates at https://mustache.github.io/ -#/ -#/ Simple usage: -#/ -#/ mo [OPTIONS] filenames... -#/ -#/ Options: -#/ -#/ -u, --fail-not-set -#/ Fail upon expansion of an unset variable. -#/ -x, --fail-on-function -#/ Fail when a function returns a non-zero status code. -#/ -e, --false -#/ Treat the string "false" as empty for conditionals. -#/ -h, --help -#/ This message. -#/ -s=FILE, --source=FILE -#/ Load FILE into the environment before processing templates. -#/ Can be used multiple times. -# -# Mo is under a MIT style licence with an additional non-advertising clause. -# See LICENSE.md for the full text. -# -# This is open source! Please feel free to contribute. -# -# https://github.com/tests-always-included/mo - - -# Public: Template parser function. Writes templates to stdout. -# -# $0 - Name of the mo file, used for getting the help message. -# $@ - Filenames to parse. -# -# Options: -# -# --allow-function-arguments -# -# Permit functions in templates to be called with additional arguments. This -# puts template data directly in to the path of an eval statement. Use with -# caution. Not listed in the help because it only makes sense when mo is -# sourced. -# -# -u, --fail-not-set -# -# Fail upon expansion of an unset variable. Default behavior is to silently -# ignore and expand into empty string. -# -# -x, --fail-on-function -# -# Fail when a function used by a template returns an error status code. -# Alternately, ou may set the MO_FAIL_ON_FUNCTION environment variable to a -# non-empty value to enable this behavior. -# -# -e, --false -# -# Treat "false" as an empty value. You may set the MO_FALSE_IS_EMPTY -# environment variable instead to a non-empty value to enable this behavior. -# -# -h, --help -# -# Display a help message. -# -# -s=FILE, --source=FILE -# -# Source a file into the environment before processing template files. -# This can be used multiple times. -# -# -- -# -# Used to indicate the end of options. You may optionally use this when -# filenames may start with two hyphens. -# -# Mo uses the following environment variables: -# -# MO_ALLOW_FUNCTION_ARGUMENTS - When set to a non-empty value, this allows -# functions referenced in templates to receive additional -# options and arguments. This puts the content from the -# template directly into an eval statement. Use with extreme -# care. -# MO_FUNCTION_ARGS - Arguments passed to the function -# MO_FAIL_ON_FUNCTION - If a function returns a non-zero status code, abort -# with an error. -# MO_FAIL_ON_UNSET - When set to a non-empty value, expansion of an unset env -# variable will be aborted with an error. -# MO_FALSE_IS_EMPTY - When set to a non-empty value, the string "false" will be -# treated as an empty value for the purposes of conditionals. -# MO_ORIGINAL_COMMAND - Used to find the `mo` program in order to generate a -# help message. -# -# Returns nothing. -mo() ( - # This function executes in a subshell so IFS is reset. - # Namespace this variable so we don't conflict with desired values. - local moContent f2source files doubleHyphens - - IFS=$' \n\t' - files=() - doubleHyphens=false - - if [[ $# -gt 0 ]]; then - for arg in "$@"; do - if $doubleHyphens; then - #: After we encounter two hyphens together, all the rest - #: of the arguments are files. - files=("${files[@]}" "$arg") - else - case "$arg" in - -h|--h|--he|--hel|--help|-\?) - moUsage "$0" - exit 0 - ;; - - --allow-function-arguments) - # shellcheck disable=SC2030 - MO_ALLOW_FUNCTION_ARGUMENTS=true - ;; - - -u | --fail-not-set) - # shellcheck disable=SC2030 - MO_FAIL_ON_UNSET=true - ;; - - -x | --fail-on-function) - # shellcheck disable=SC2030 - MO_FAIL_ON_FUNCTION=true - ;; - - -e | --false) - # shellcheck disable=SC2030 - MO_FALSE_IS_EMPTY=true - ;; - - -s=* | --source=*) - if [[ "$arg" == --source=* ]]; then - f2source="${arg#--source=}" - else - f2source="${arg#-s=}" - fi - - if [[ -f "$f2source" ]]; then - # shellcheck disable=SC1090 - . "$f2source" - else - echo "No such file: $f2source" >&2 - exit 1 - fi - ;; - - --) - #: Set a flag indicating we've encountered double hyphens - doubleHyphens=true - ;; - - *) - #: Every arg that is not a flag or a option should be a file - files=(${files[@]+"${files[@]}"} "$arg") - ;; - esac - fi - done - fi - - moGetContent moContent "${files[@]}" || return 1 - moParse "$moContent" "" true -) - - -# Internal: Call a function. -# -# $1 - Variable for output -# $2 - Function to call -# $3 - Content to pass -# $4 - Additional arguments as a single string -# -# This can be dangerous, especially if you are using tags like -# {{someFunction ; rm -rf / }} -# -# Returns nothing. -moCallFunction() { - local moArgs moContent moFunctionArgs moFunctionResult - - moArgs=() - moTrimWhitespace moFunctionArgs "$4" - - # shellcheck disable=SC2031 - if [[ -n "${MO_ALLOW_FUNCTION_ARGUMENTS-}" ]]; then - # Intentionally bad behavior - # shellcheck disable=SC2206 - moArgs=($4) - fi - - moContent=$(echo -n "$3" | MO_FUNCTION_ARGS="$moFunctionArgs" eval "$2" "${moArgs[@]}") || { - moFunctionResult=$? - # shellcheck disable=SC2031 - if [[ -n "${MO_FAIL_ON_FUNCTION-}" && "$moFunctionResult" != 0 ]]; then - echo "Function '$2' with args (${moArgs[*]+"${moArgs[@]}"}) failed with status code $moFunctionResult" - exit "$moFunctionResult" - fi - } - - # shellcheck disable=SC2031 - local "$1" && moIndirect "$1" "$moContent" -} - - -# Internal: Scan content until the right end tag is found. Creates an array -# with the following members: -# -# [0] = Content before end tag -# [1] = End tag (complete tag) -# [2] = Content after end tag -# -# Everything using this function uses the "standalone tags" logic. -# -# $1 - Name of variable for the array -# $2 - Content -# $3 - Name of end tag -# $4 - If -z, do standalone tag processing before finishing -# -# Returns nothing. -moFindEndTag() { - local content remaining scanned standaloneBytes tag - - #: Find open tags - scanned="" - moSplit content "$2" '{{' '}}' - - while [[ "${#content[@]}" -gt 1 ]]; do - moTrimWhitespace tag "${content[1]}" - - #: Restore content[1] before we start using it - content[1]='{{'"${content[1]}"'}}' - - case $tag in - '#'* | '^'*) - #: Start another block - scanned="${scanned}${content[0]}${content[1]}" - moTrimWhitespace tag "${tag:1}" - moFindEndTag content "${content[2]}" "$tag" "loop" - scanned="${scanned}${content[0]}${content[1]}" - remaining=${content[2]} - ;; - - '/'*) - #: End a block - could be ours - moTrimWhitespace tag "${tag:1}" - scanned="$scanned${content[0]}" - - if [[ "$tag" == "$3" ]]; then - #: Found our end tag - if [[ -z "${4-}" ]] && moIsStandalone standaloneBytes "$scanned" "${content[2]}" true; then - #: This is also a standalone tag - clean up whitespace - #: and move those whitespace bytes to the "tag" element - # shellcheck disable=SC2206 - standaloneBytes=( $standaloneBytes ) - content[1]="${scanned:${standaloneBytes[0]}}${content[1]}${content[2]:0:${standaloneBytes[1]}}" - scanned="${scanned:0:${standaloneBytes[0]}}" - content[2]="${content[2]:${standaloneBytes[1]}}" - fi - - local "$1" && moIndirectArray "$1" "$scanned" "${content[1]}" "${content[2]}" - return 0 - fi - - scanned="$scanned${content[1]}" - remaining=${content[2]} - ;; - - *) - #: Ignore all other tags - scanned="${scanned}${content[0]}${content[1]}" - remaining=${content[2]} - ;; - esac - - moSplit content "$remaining" '{{' '}}' - done - - #: Did not find our closing tag - scanned="$scanned${content[0]}" - local "$1" && moIndirectArray "$1" "${scanned}" "" "" -} - - -# Internal: Find the first index of a substring. If not found, sets the -# index to -1. -# -# $1 - Destination variable for the index -# $2 - Haystack -# $3 - Needle -# -# Returns nothing. -moFindString() { - local pos string - - string=${2%%$3*} - [[ "$string" == "$2" ]] && pos=-1 || pos=${#string} - local "$1" && moIndirect "$1" "$pos" -} - - -# Internal: Generate a dotted name based on current context and target name. -# -# $1 - Target variable to store results -# $2 - Context name -# $3 - Desired variable name -# -# Returns nothing. -moFullTagName() { - if [[ -z "${2-}" ]] || [[ "$2" == *.* ]]; then - local "$1" && moIndirect "$1" "$3" - else - local "$1" && moIndirect "$1" "${2}.${3}" - fi -} - - -# Internal: Fetches the content to parse into a variable. Can be a list of -# partials for files or the content from stdin. -# -# $1 - Variable name to assign this content back as -# $2-@ - File names (optional) -# -# Returns nothing. -moGetContent() { - local moContent moFilename moTarget - - moTarget=$1 - shift - if [[ "${#@}" -gt 0 ]]; then - moContent="" - - for moFilename in "$@"; do - #: This is so relative paths work from inside template files - moContent="$moContent"'{{>'"$moFilename"'}}' - done - else - moLoadFile moContent || return 1 - fi - - local "$moTarget" && moIndirect "$moTarget" "$moContent" -} - - -# Internal: Indent a string, placing the indent at the beginning of every -# line that has any content. -# -# $1 - Name of destination variable to get an array of lines -# $2 - The indent string -# $3 - The string to reindent -# -# Returns nothing. -moIndentLines() { - local content fragment len posN posR result trimmed - - result="" - - #: Remove the period from the end of the string. - len=$((${#3} - 1)) - content=${3:0:$len} - - if [[ -z "${2-}" ]]; then - local "$1" && moIndirect "$1" "$content" - - return 0 - fi - - moFindString posN "$content" $'\n' - moFindString posR "$content" $'\r' - - while [[ "$posN" -gt -1 ]] || [[ "$posR" -gt -1 ]]; do - if [[ "$posN" -gt -1 ]]; then - fragment="${content:0:$posN + 1}" - content=${content:$posN + 1} - else - fragment="${content:0:$posR + 1}" - content=${content:$posR + 1} - fi - - moTrimChars trimmed "$fragment" false true " " $'\t' $'\n' $'\r' - - if [[ -n "$trimmed" ]]; then - fragment="$2$fragment" - fi - - result="$result$fragment" - - moFindString posN "$content" $'\n' - moFindString posR "$content" $'\r' - - # If the content ends in a newline, do not indent. - if [[ "$posN" -eq ${#content} ]]; then - # Special clause for \r\n - if [[ "$posR" -eq "$((posN - 1))" ]]; then - posR=-1 - fi - - posN=-1 - fi - - if [[ "$posR" -eq ${#content} ]]; then - posR=-1 - fi - done - - moTrimChars trimmed "$content" false true " " $'\t' - - if [[ -n "$trimmed" ]]; then - content="$2$content" - fi - - result="$result$content" - - local "$1" && moIndirect "$1" "$result" -} - - -# Internal: Send a variable up to the parent of the caller of this function. -# -# $1 - Variable name -# $2 - Value -# -# Examples -# -# callFunc () { -# local "$1" && moIndirect "$1" "the value" -# } -# callFunc dest -# echo "$dest" # writes "the value" -# -# Returns nothing. -moIndirect() { - unset -v "$1" - printf -v "$1" '%s' "$2" -} - - -# Internal: Send an array as a variable up to caller of a function -# -# $1 - Variable name -# $2-@ - Array elements -# -# Examples -# -# callFunc () { -# local myArray=(one two three) -# local "$1" && moIndirectArray "$1" "${myArray[@]}" -# } -# callFunc dest -# echo "${dest[@]}" # writes "one two three" -# -# Returns nothing. -moIndirectArray() { - unset -v "$1" - - # IFS must be set to a string containing space or unset in order for - # the array slicing to work regardless of the current IFS setting on - # bash 3. This is detailed further at - # https://github.com/fidian/gg-core/pull/7 - eval "$(printf "IFS= %s=(\"\${@:2}\") IFS=%q" "$1" "$IFS")" -} - - -# Internal: Determine if a given environment variable exists and if it is -# an array. -# -# $1 - Name of environment variable -# -# Be extremely careful. Even if strict mode is enabled, it is not honored -# in newer versions of Bash. Any errors that crop up here will not be -# caught automatically. -# -# Examples -# -# var=(abc) -# if moIsArray var; then -# echo "This is an array" -# echo "Make sure you don't accidentally use \$var" -# fi -# -# Returns 0 if the name is not empty, 1 otherwise. -moIsArray() { - # Namespace this variable so we don't conflict with what we're testing. - local moTestResult - - moTestResult=$(declare -p "$1" 2>/dev/null) || return 1 - [[ "${moTestResult:0:10}" == "declare -a" ]] && return 0 - [[ "${moTestResult:0:10}" == "declare -A" ]] && return 0 - - return 1 -} - - -# Internal: Determine if the given name is a defined function. -# -# $1 - Function name to check -# -# Be extremely careful. Even if strict mode is enabled, it is not honored -# in newer versions of Bash. Any errors that crop up here will not be -# caught automatically. -# -# Examples -# -# moo () { -# echo "This is a function" -# } -# if moIsFunction moo; then -# echo "moo is a defined function" -# fi -# -# Returns 0 if the name is a function, 1 otherwise. -moIsFunction() { - local functionList functionName - - functionList=$(declare -F) - # shellcheck disable=SC2206 - functionList=( ${functionList//declare -f /} ) - - for functionName in "${functionList[@]}"; do - if [[ "$functionName" == "$1" ]]; then - return 0 - fi - done - - return 1 -} - - -# Internal: Determine if the tag is a standalone tag based on whitespace -# before and after the tag. -# -# Passes back a string containing two numbers in the format "BEFORE AFTER" -# like "27 10". It indicates the number of bytes remaining in the "before" -# string (27) and the number of bytes to trim in the "after" string (10). -# Useful for string manipulation: -# -# $1 - Variable to set for passing data back -# $2 - Content before the tag -# $3 - Content after the tag -# $4 - true/false: is this the beginning of the content? -# -# Examples -# -# moIsStandalone RESULT "$before" "$after" false || return 0 -# RESULT_ARRAY=( $RESULT ) -# echo "${before:0:${RESULT_ARRAY[0]}}...${after:${RESULT_ARRAY[1]}}" -# -# Returns nothing. -moIsStandalone() { - local afterTrimmed beforeTrimmed char - - moTrimChars beforeTrimmed "$2" false true " " $'\t' - moTrimChars afterTrimmed "$3" true false " " $'\t' - char=$((${#beforeTrimmed} - 1)) - char=${beforeTrimmed:$char} - - # If the content before didn't end in a newline - if [[ "$char" != $'\n' ]] && [[ "$char" != $'\r' ]]; then - # and there was content or this didn't start the file - if [[ -n "$char" ]] || ! $4; then - # then this is not a standalone tag. - return 1 - fi - fi - - char=${afterTrimmed:0:1} - - # If the content after doesn't start with a newline and it is something - if [[ "$char" != $'\n' ]] && [[ "$char" != $'\r' ]] && [[ -n "$char" ]]; then - # then this is not a standalone tag. - return 2 - fi - - if [[ "$char" == $'\r' ]] && [[ "${afterTrimmed:1:1}" == $'\n' ]]; then - char="$char"$'\n' - fi - - local "$1" && moIndirect "$1" "$((${#beforeTrimmed})) $((${#3} + ${#char} - ${#afterTrimmed}))" -} - - -# Internal: Join / implode an array -# -# $1 - Variable name to receive the joined content -# $2 - Joiner -# $3-$* - Elements to join -# -# Returns nothing. -moJoin() { - local joiner part result target - - target=$1 - joiner=$2 - result=$3 - shift 3 - - for part in "$@"; do - result="$result$joiner$part" - done - - local "$target" && moIndirect "$target" "$result" -} - - -# Internal: Read a file into a variable. -# -# $1 - Variable name to receive the file's content -# $2 - Filename to load - if empty, defaults to /dev/stdin -# -# Returns nothing. -moLoadFile() { - local content len - - # The subshell removes any trailing newlines. We forcibly add - # a dot to the content to preserve all newlines. - # As a future optimization, it would be worth considering removing - # cat and replacing this with a read loop. - - content=$(cat -- "${2:-/dev/stdin}" && echo '.') || return 1 - len=$((${#content} - 1)) - content=${content:0:$len} # Remove last dot - - local "$1" && moIndirect "$1" "$content" -} - - -# Internal: Process a chunk of content some number of times. Writes output -# to stdout. -# -# $1 - Content to parse repeatedly -# $2 - Tag prefix (context name) -# $3-@ - Names to insert into the parsed content -# -# Returns nothing. -moLoop() { - local content context contextBase - - content=$1 - contextBase=$2 - shift 2 - - while [[ "${#@}" -gt 0 ]]; do - moFullTagName context "$contextBase" "$1" - moParse "$content" "$context" false - shift - done -} - - -# Internal: Parse a block of text, writing the result to stdout. -# -# $1 - Block of text to change -# $2 - Current name (the variable NAME for what {{.}} means) -# $3 - true when no content before this, false otherwise -# -# Returns nothing. -moParse() { - # Keep naming variables mo* here to not overwrite needed variables - # used in the string replacements - local moArgs moBlock moContent moCurrent moIsBeginning moNextIsBeginning moTag - - moCurrent=$2 - moIsBeginning=$3 - - # Find open tags - moSplit moContent "$1" '{{' '}}' - - while [[ "${#moContent[@]}" -gt 1 ]]; do - moTrimWhitespace moTag "${moContent[1]}" - moNextIsBeginning=false - - case $moTag in - '#'*) - # Loop, if/then, or pass content through function - # Sets context - moStandaloneAllowed moContent "${moContent[@]}" "$moIsBeginning" - moTrimWhitespace moTag "${moTag:1}" - - # Split arguments from the tag name. Arguments are passed to - # functions. - moArgs=$moTag - moTag=${moTag%% *} - moTag=${moTag%%$'\t'*} - moArgs=${moArgs:${#moTag}} - moFindEndTag moBlock "$moContent" "$moTag" - moFullTagName moTag "$moCurrent" "$moTag" - - if moTest "$moTag"; then - # Show / loop / pass through function - if moIsFunction "$moTag"; then - moCallFunction moContent "$moTag" "${moBlock[0]}" "$moArgs" - moParse "$moContent" "$moCurrent" false - moContent="${moBlock[2]}" - elif moIsArray "$moTag"; then - eval "moLoop \"\${moBlock[0]}\" \"$moTag\" \"\${!${moTag}[@]}\"" - else - moParse "${moBlock[0]}" "$moCurrent" true - fi - fi - - moContent="${moBlock[2]}" - ;; - - '>'*) - # Load partial - get name of file relative to cwd - moPartial moContent "${moContent[@]}" "$moIsBeginning" "$moCurrent" - moNextIsBeginning=${moContent[1]} - moContent=${moContent[0]} - ;; - - '/'*) - # Closing tag - If hit in this loop, we simply ignore - # Matching tags are found in moFindEndTag - moStandaloneAllowed moContent "${moContent[@]}" "$moIsBeginning" - ;; - - '^'*) - # Display section if named thing does not exist - moStandaloneAllowed moContent "${moContent[@]}" "$moIsBeginning" - moTrimWhitespace moTag "${moTag:1}" - moFindEndTag moBlock "$moContent" "$moTag" - moFullTagName moTag "$moCurrent" "$moTag" - - if ! moTest "$moTag"; then - moParse "${moBlock[0]}" "$moCurrent" false "$moCurrent" - fi - - moContent="${moBlock[2]}" - ;; - - '!'*) - # Comment - ignore the tag content entirely - # Trim spaces/tabs before the comment - moStandaloneAllowed moContent "${moContent[@]}" "$moIsBeginning" - ;; - - .) - # Current content (environment variable or function) - moStandaloneDenied moContent "${moContent[@]}" - moShow "$moCurrent" "$moCurrent" - ;; - - '=') - # Change delimiters - # Any two non-whitespace sequences separated by whitespace. - # This tag is ignored. - moStandaloneAllowed moContent "${moContent[@]}" "$moIsBeginning" - ;; - - '{'*) - # Unescaped - split on }}} not }} - moStandaloneDenied moContent "${moContent[@]}" - moContent="${moTag:1}"'}}'"$moContent" - moSplit moContent "$moContent" '}}}' - moTrimWhitespace moTag "${moContent[0]}" - moArgs=$moTag - moTag=${moTag%% *} - moTag=${moTag%%$'\t'*} - moArgs=${moArgs:${#moTag}} - moFullTagName moTag "$moCurrent" "$moTag" - moContent=${moContent[1]} - - # Now show the value - # Quote moArgs here, do not quote it later. - moShow "$moTag" "$moCurrent" "$moArgs" - ;; - - '&'*) - # Unescaped - moStandaloneDenied moContent "${moContent[@]}" - moTrimWhitespace moTag "${moTag:1}" - moFullTagName moTag "$moCurrent" "$moTag" - moShow "$moTag" "$moCurrent" - ;; - - *) - # Normal environment variable or function call - moStandaloneDenied moContent "${moContent[@]}" - moArgs=$moTag - moTag=${moTag%% *} - moTag=${moTag%%$'\t'*} - moArgs=${moArgs:${#moTag}} - moFullTagName moTag "$moCurrent" "$moTag" - - # Quote moArgs here, do not quote it later. - moShow "$moTag" "$moCurrent" "$moArgs" - ;; - esac - - moIsBeginning=$moNextIsBeginning - moSplit moContent "$moContent" '{{' '}}' - done - - echo -n "${moContent[0]}" -} - - -# Internal: Process a partial. -# -# Indentation should be applied to the entire partial. -# -# This sends back the "is beginning" flag because the newline after a -# standalone partial is consumed. That newline is very important in the middle -# of content. We send back this flag to reset the processing loop's -# `moIsBeginning` variable, so the software thinks we are back at the -# beginning of a file and standalone processing continues to work. -# -# Prefix all variables. -# -# $1 - Name of destination variable. Element [0] is the content, [1] is the -# true/false flag indicating if we are at the beginning of content. -# $2 - Content before the tag that was not yet written -# $3 - Tag content -# $4 - Content after the tag -# $5 - true/false: is this the beginning of the content? -# $6 - Current context name -# -# Returns nothing. -moPartial() { - # Namespace variables here to prevent conflicts. - local moContent moFilename moIndent moIsBeginning moPartial moStandalone moUnindented - - if moIsStandalone moStandalone "$2" "$4" "$5"; then - # shellcheck disable=SC2206 - moStandalone=( $moStandalone ) - echo -n "${2:0:${moStandalone[0]}}" - moIndent=${2:${moStandalone[0]}} - moContent=${4:${moStandalone[1]}} - moIsBeginning=true - else - moIndent="" - echo -n "$2" - moContent=$4 - moIsBeginning=$5 - fi - - moTrimWhitespace moFilename "${3:1}" - - # Execute in subshell to preserve current cwd and environment - ( - # It would be nice to remove `dirname` and use a function instead, - # but that's difficult when you're only given filenames. - cd "$(dirname -- "$moFilename")" || exit 1 - moUnindented="$( - moLoadFile moPartial "${moFilename##*/}" || exit 1 - moParse "${moPartial}" "$6" true - - # Fix bash handling of subshells and keep trailing whitespace. - # This is removed in moIndentLines. - echo -n "." - )" || exit 1 - moIndentLines moPartial "$moIndent" "$moUnindented" - echo -n "$moPartial" - ) || exit 1 - - # If this is a standalone tag, the trailing newline after the tag is - # removed and the contents of the partial are added, which typically - # contain a newline. We need to send a signal back to the processing - # loop that the moIsBeginning flag needs to be turned on again. - # - # [0] is the content, [1] is that flag. - local "$1" && moIndirectArray "$1" "$moContent" "$moIsBeginning" -} - - -# Internal: Show an environment variable or the output of a function to -# stdout. -# -# Limit/prefix any variables used. -# -# $1 - Name of environment variable or function -# $2 - Current context -# $3 - Arguments string if $1 is a function -# -# Returns nothing. -moShow() { - # Namespace these variables - local moJoined moNameParts moContent - - if moIsFunction "$1"; then - moCallFunction moContent "$1" "" "$3" - moParse "$moContent" "$2" false - return 0 - fi - - moSplit moNameParts "$1" "." - - if [[ -z "${moNameParts[1]-}" ]]; then - if moIsArray "$1"; then - eval moJoin moJoined "," "\${$1[@]}" - echo -n "$moJoined" - else - # shellcheck disable=SC2031 - if moTestVarSet "$1"; then - echo -n "${!1}" - elif [[ -n "${MO_FAIL_ON_UNSET-}" ]]; then - echo "Env variable not set: $1" >&2 - exit 1 - fi - fi - else - # Further subindexes are disallowed - eval "echo -n \"\${${moNameParts[0]}[${moNameParts[1]%%.*}]}\"" - fi -} - - -# Internal: Split a larger string into an array. -# -# $1 - Destination variable -# $2 - String to split -# $3 - Starting delimiter -# $4 - Ending delimiter (optional) -# -# Returns nothing. -moSplit() { - local pos result - - result=( "$2" ) - moFindString pos "${result[0]}" "$3" - - if [[ "$pos" -ne -1 ]]; then - # The first delimiter was found - result[1]=${result[0]:$pos + ${#3}} - result[0]=${result[0]:0:$pos} - - if [[ -n "${4-}" ]]; then - moFindString pos "${result[1]}" "$4" - - if [[ "$pos" -ne -1 ]]; then - # The second delimiter was found - result[2]="${result[1]:$pos + ${#4}}" - result[1]="${result[1]:0:$pos}" - fi - fi - fi - - local "$1" && moIndirectArray "$1" "${result[@]}" -} - - -# Internal: Handle the content for a standalone tag. This means removing -# whitespace (not newlines) before a tag and whitespace and a newline after -# a tag. That is, assuming, that the line is otherwise empty. -# -# $1 - Name of destination "content" variable. -# $2 - Content before the tag that was not yet written -# $3 - Tag content (not used) -# $4 - Content after the tag -# $5 - true/false: is this the beginning of the content? -# -# Returns nothing. -moStandaloneAllowed() { - local bytes - - if moIsStandalone bytes "$2" "$4" "$5"; then - # shellcheck disable=SC2206 - bytes=( $bytes ) - echo -n "${2:0:${bytes[0]}}" - local "$1" && moIndirect "$1" "${4:${bytes[1]}}" - else - echo -n "$2" - local "$1" && moIndirect "$1" "$4" - fi -} - - -# Internal: Handle the content for a tag that is never "standalone". No -# adjustments are made for newlines and whitespace. -# -# $1 - Name of destination "content" variable. -# $2 - Content before the tag that was not yet written -# $3 - Tag content (not used) -# $4 - Content after the tag -# -# Returns nothing. -moStandaloneDenied() { - echo -n "$2" - local "$1" && moIndirect "$1" "$4" -} - - -# Internal: Determines if the named thing is a function or if it is a -# non-empty environment variable. When MO_FALSE_IS_EMPTY is set to a -# non-empty value, then "false" is also treated is an empty value. -# -# Do not use variables without prefixes here if possible as this needs to -# check if any name exists in the environment -# -# $1 - Name of environment variable or function -# $2 - Current value (our context) -# MO_FALSE_IS_EMPTY - When set to a non-empty value, this will say the -# string value "false" is empty. -# -# Returns 0 if the name is not empty, 1 otherwise. When MO_FALSE_IS_EMPTY -# is set, this returns 1 if the name is "false". -moTest() { - # Test for functions - moIsFunction "$1" && return 0 - - if moIsArray "$1"; then - # Arrays must have at least 1 element - eval "[[ \"\${#${1}[@]}\" -gt 0 ]]" && return 0 - else - # If MO_FALSE_IS_EMPTY is set, then return 1 if the value of - # the variable is "false". - # shellcheck disable=SC2031 - [[ -n "${MO_FALSE_IS_EMPTY-}" ]] && [[ "${!1-}" == "false" ]] && return 1 - - # Environment variables must not be empty - [[ -n "${!1-}" ]] && return 0 - fi - - return 1 -} - -# Internal: Determine if a variable is assigned, even if it is assigned an empty -# value. -# -# $1 - Variable name to check. -# -# Returns true (0) if the variable is set, 1 if the variable is unset. -moTestVarSet() { - [[ "${!1-a}" == "${!1-b}" ]] -} - - -# Internal: Trim the leading whitespace only. -# -# $1 - Name of destination variable -# $2 - The string -# $3 - true/false - trim front? -# $4 - true/false - trim end? -# $5-@ - Characters to trim -# -# Returns nothing. -moTrimChars() { - local back current front last target varName - - target=$1 - current=$2 - front=$3 - back=$4 - last="" - shift 4 # Remove target, string, trim front flag, trim end flag - - while [[ "$current" != "$last" ]]; do - last=$current - - for varName in "$@"; do - $front && current="${current/#$varName}" - $back && current="${current/%$varName}" - done - done - - local "$target" && moIndirect "$target" "$current" -} - - -# Internal: Trim leading and trailing whitespace from a string. -# -# $1 - Name of variable to store trimmed string -# $2 - The string -# -# Returns nothing. -moTrimWhitespace() { - local result - - moTrimChars result "$2" true true $'\r' $'\n' $'\t' " " - local "$1" && moIndirect "$1" "$result" -} - - -# Internal: Displays the usage for mo. Pulls this from the file that -# contained the `mo` function. Can only work when the right filename -# comes is the one argument, and that only happens when `mo` is called -# with `$0` set to this file. -# -# $1 - Filename that has the help message -# -# Returns nothing. -moUsage() { - grep '^#/' "${MO_ORIGINAL_COMMAND}" | cut -c 4- - echo "" - echo "MO_VERSION=$MO_VERSION" -} - - -# Save the original command's path for usage later -MO_ORIGINAL_COMMAND="$(cd "${BASH_SOURCE[0]%/*}" || exit 1; pwd)/${BASH_SOURCE[0]##*/}" -MO_VERSION="2.2.0" - -# If sourced, load all functions. -# If executed, perform the actions as expected. -if [[ "$0" == "${BASH_SOURCE[0]}" ]] || [[ -z "${BASH_SOURCE[0]}" ]]; then - mo "$@" -fi diff --git a/docker/nginx/nginx.conf b/docker/nginx/nginx.conf index 3517a6bc..de55d276 100644 --- a/docker/nginx/nginx.conf +++ b/docker/nginx/nginx.conf @@ -19,6 +19,9 @@ user root; worker_processes auto; +# Enables the use of JIT for regular expressions to speed-up their processing. +pcre_jit on; + #error_log logs/error.log; #error_log logs/error.log notice; #error_log logs/error.log info; From 306442eef3f72d33157bf34df5c95bd6dd49dd50 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 21 Apr 2022 15:26:12 +0200 Subject: [PATCH 218/240] use volumes to mount nginx configuration --- docker-compose.yml | 4 ++++ docker/nginx/Dockerfile | 6 ------ .../docker-entrypoint.d/50-generate-local-certificate.sh | 2 +- 3 files changed, 5 insertions(+), 7 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index d92b14fe..6450a10f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -71,6 +71,10 @@ services: - ./docker/data/nginx/skynet:/data/nginx/skynet:ro - ./docker/data/sia/apipassword:/data/sia/apipassword:ro - ./docker/data/certbot:/etc/letsencrypt + - ./docker/nginx/libs:/etc/nginx/libs + - ./docker/nginx/conf.d:/etc/nginx/conf.d + - ./docker/nginx/conf.d.templates:/etc/nginx/templates + - ./docker/nginx/nginx.conf:/usr/local/openresty/nginx/conf/nginx.conf networks: shared: ipv4_address: 10.10.10.30 diff --git a/docker/nginx/Dockerfile b/docker/nginx/Dockerfile index 12b27712..b294d522 100644 --- a/docker/nginx/Dockerfile +++ b/docker/nginx/Dockerfile @@ -14,12 +14,6 @@ ENV NGINX_ENTRYPOINT_RELOAD_EVERY_X_HOURS 6 COPY docker/nginx/docker-entrypoint.sh / COPY docker/nginx/docker-entrypoint.d /docker-entrypoint.d -# copy nginx configuration files and libraries -COPY docker/nginx/libs /etc/nginx/libs -COPY docker/nginx/conf.d /etc/nginx/conf.d -COPY docker/nginx/conf.d.templates /etc/nginx/templates -COPY docker/nginx/nginx.conf /usr/local/openresty/nginx/conf/nginx.conf - ENTRYPOINT ["/docker-entrypoint.sh"] STOPSIGNAL SIGQUIT diff --git a/docker/nginx/docker-entrypoint.d/50-generate-local-certificate.sh b/docker/nginx/docker-entrypoint.d/50-generate-local-certificate.sh index d556fd3e..f5ecada1 100755 --- a/docker/nginx/docker-entrypoint.d/50-generate-local-certificate.sh +++ b/docker/nginx/docker-entrypoint.d/50-generate-local-certificate.sh @@ -7,7 +7,7 @@ set -e ME=$(basename $0) -generate_local_certificate() { +generate_local_certificate() { echo >&3 "$ME: Generating locally signed ssl certificate" openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 \ -subj '/CN=local-certificate' \ From 6d2d053e23b6199a4dde6926634fe19f29e2e220 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 21 Apr 2022 15:36:17 +0200 Subject: [PATCH 219/240] lint testing nginx dockerfile --- .github/workflows/lint-dockerfiles.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/lint-dockerfiles.yml b/.github/workflows/lint-dockerfiles.yml index 467dc117..afdd6558 100644 --- a/.github/workflows/lint-dockerfiles.yml +++ b/.github/workflows/lint-dockerfiles.yml @@ -14,6 +14,7 @@ jobs: matrix: dockerfile: - docker/nginx/Dockerfile + - docker/nginx/testing/Dockerfile - docker/sia/Dockerfile - packages/dashboard/Dockerfile - packages/dashboard-v2/Dockerfile From 873f23b7bfd1be9de47349e42ac2d4e047659e81 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 21 Apr 2022 15:57:16 +0200 Subject: [PATCH 220/240] add nginx license source --- docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh | 1 + docker/nginx/docker-entrypoint.sh | 1 + 2 files changed, 2 insertions(+) diff --git a/docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh b/docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh index c46cea44..14d97a76 100755 --- a/docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh +++ b/docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh @@ -1,6 +1,7 @@ #!/bin/sh # https://github.com/nginxinc/docker-nginx/blob/master/entrypoint/20-envsubst-on-templates.sh +# https://github.com/nginxinc/docker-nginx/blob/master/LICENSE # Copyright (C) 2011-2016 Nginx, Inc. # All rights reserved. diff --git a/docker/nginx/docker-entrypoint.sh b/docker/nginx/docker-entrypoint.sh index 07793211..3802dab5 100755 --- a/docker/nginx/docker-entrypoint.sh +++ b/docker/nginx/docker-entrypoint.sh @@ -2,6 +2,7 @@ # vim:sw=4:ts=4:et # https://github.com/nginxinc/docker-nginx/blob/master/entrypoint/docker-entrypoint.sh +# https://github.com/nginxinc/docker-nginx/blob/master/LICENSE # Copyright (C) 2011-2016 Nginx, Inc. # All rights reserved. From ac99a426b33417d5e1c9b2e24eae076d8f065c50 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 21 Apr 2022 15:59:07 +0200 Subject: [PATCH 221/240] fix DL3014 warning --- docker/nginx/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/nginx/Dockerfile b/docker/nginx/Dockerfile index b294d522..f35c0aff 100644 --- a/docker/nginx/Dockerfile +++ b/docker/nginx/Dockerfile @@ -2,7 +2,7 @@ FROM openresty/openresty:1.19.9.1-focal WORKDIR / -RUN apt-get update && apt-get --no-install-recommends install bc=1.07.1-2build1 && \ +RUN apt-get update && apt-get --no-install-recommends -y install bc=1.07.1-2build1 && \ apt-get clean && rm -rf /var/lib/apt/lists/* && \ luarocks install lua-resty-http && \ luarocks install hasher From 1d6d3cbfb601a69c14da18828b43e512195c92c5 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Thu, 21 Apr 2022 16:01:20 +0200 Subject: [PATCH 222/240] fix DL3025 warning --- docker/nginx/testing/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/nginx/testing/Dockerfile b/docker/nginx/testing/Dockerfile index ae2cd78f..ed7740b6 100644 --- a/docker/nginx/testing/Dockerfile +++ b/docker/nginx/testing/Dockerfile @@ -8,4 +8,4 @@ RUN luarocks install lua-resty-http && \ COPY rbusted /etc/nginx/ -CMD /etc/nginx/rbusted --verbose --pattern=spec /usr/local/openresty/site/lualib +CMD ["/etc/nginx/rbusted", "--verbose", "--pattern=spec", "/usr/local/openresty/site/lualib"] From c9c393ae4f4f09b25255ce4ee3ed0a9e4d8af6f4 Mon Sep 17 00:00:00 2001 From: Matthew Sevey Date: Thu, 21 Apr 2022 12:57:09 -0400 Subject: [PATCH 223/240] Point to latest semver release for docker images --- docker-compose.abuse-scanner.yml | 2 +- docker-compose.blocker.yml | 2 +- docker-compose.malware-scanner.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/docker-compose.abuse-scanner.yml b/docker-compose.abuse-scanner.yml index 4edb6556..6080ebcd 100644 --- a/docker-compose.abuse-scanner.yml +++ b/docker-compose.abuse-scanner.yml @@ -10,7 +10,7 @@ services: abuse-scanner: # uncomment "build" and comment out "image" to build from sources # build: https://github.com/SkynetLabs/abuse-scanner.git#main - image: skynetlabs/abuse-scanner + image: skynetlabs/abuse-scanner:0.1.0 container_name: abuse-scanner restart: unless-stopped logging: *default-logging diff --git a/docker-compose.blocker.yml b/docker-compose.blocker.yml index edcb45c0..29d29e34 100644 --- a/docker-compose.blocker.yml +++ b/docker-compose.blocker.yml @@ -15,7 +15,7 @@ services: blocker: # uncomment "build" and comment out "image" to build from sources # build: https://github.com/SkynetLabs/blocker.git#main - image: skynetlabs/blocker + image: skynetlabs/blocker:0.1.0 container_name: blocker restart: unless-stopped logging: *default-logging diff --git a/docker-compose.malware-scanner.yml b/docker-compose.malware-scanner.yml index fba60f98..ee3b6700 100644 --- a/docker-compose.malware-scanner.yml +++ b/docker-compose.malware-scanner.yml @@ -28,7 +28,7 @@ services: malware-scanner: # uncomment "build" and comment out "image" to build from sources # build: https://github.com/SkynetLabs/malware-scanner.git#main - image: skynetlabs/malware-scanner + image: skynetlabs/malware-scanner:0.1.0 container_name: malware-scanner restart: unless-stopped logging: *default-logging From 9e675a2a043029c4d17d0eb0cf859035f39bd49d Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 10:17:30 +0200 Subject: [PATCH 224/240] add comment about skynet_portal_domain being set to server domain --- docker/nginx/conf.d.templates/server.account.conf.template | 7 ++++++- docker/nginx/conf.d.templates/server.api.conf.template | 7 ++++++- docker/nginx/conf.d.templates/server.hns.conf.template | 7 ++++++- docker/nginx/conf.d.templates/server.skylink.conf.template | 7 ++++++- 4 files changed, 24 insertions(+), 4 deletions(-) diff --git a/docker/nginx/conf.d.templates/server.account.conf.template b/docker/nginx/conf.d.templates/server.account.conf.template index 64de6523..8507c407 100644 --- a/docker/nginx/conf.d.templates/server.account.conf.template +++ b/docker/nginx/conf.d.templates/server.account.conf.template @@ -30,7 +30,12 @@ server { server { server_name account.${SERVER_DOMAIN}; # example: account.eu-ger-1.siasky.net - set_by_lua_block $skynet_portal_domain { return "${SERVER_DOMAIN}" } + set_by_lua_block $skynet_portal_domain { + -- when accessing portal directly through server domain, portal domain should be set to server domain + -- motivation: skynet-js uses Skynet-Portal-Api header (that is set to $skynet_portal_domain) to detect current + -- portal address and it should be server domain when accessing specific server by its domain address + return "${SERVER_DOMAIN}" + } set_by_lua_block $skynet_server_domain { return "${SERVER_DOMAIN}" } include /etc/nginx/conf.d/server/server.account; diff --git a/docker/nginx/conf.d.templates/server.api.conf.template b/docker/nginx/conf.d.templates/server.api.conf.template index 7d36ff08..5f742127 100644 --- a/docker/nginx/conf.d.templates/server.api.conf.template +++ b/docker/nginx/conf.d.templates/server.api.conf.template @@ -30,7 +30,12 @@ server { server { server_name ${SERVER_DOMAIN}; # example: eu-ger-1.siasky.net - set_by_lua_block $skynet_portal_domain { return "${SERVER_DOMAIN}" } + set_by_lua_block $skynet_portal_domain { + -- when accessing portal directly through server domain, portal domain should be set to server domain + -- motivation: skynet-js uses Skynet-Portal-Api header (that is set to $skynet_portal_domain) to detect current + -- portal address and it should be server domain when accessing specific server by its domain address + return "${SERVER_DOMAIN}" + } set_by_lua_block $skynet_server_domain { return "${SERVER_DOMAIN}" } include /etc/nginx/conf.d/server/server.api; diff --git a/docker/nginx/conf.d.templates/server.hns.conf.template b/docker/nginx/conf.d.templates/server.hns.conf.template index 7067ce4d..f7bb43fb 100644 --- a/docker/nginx/conf.d.templates/server.hns.conf.template +++ b/docker/nginx/conf.d.templates/server.hns.conf.template @@ -31,7 +31,12 @@ server { server { server_name *.hns.${SERVER_DOMAIN}; # example: *.hns.eu-ger-1.siasky.net - set_by_lua_block $skynet_portal_domain { return "${SERVER_DOMAIN}" } + set_by_lua_block $skynet_portal_domain { + -- when accessing portal directly through server domain, portal domain should be set to server domain + -- motivation: skynet-js uses Skynet-Portal-Api header (that is set to $skynet_portal_domain) to detect current + -- portal address and it should be server domain when accessing specific server by its domain address + return "${SERVER_DOMAIN}" + } set_by_lua_block $skynet_server_domain { return "${SERVER_DOMAIN}" } proxy_set_header Host ${SERVER_DOMAIN}; diff --git a/docker/nginx/conf.d.templates/server.skylink.conf.template b/docker/nginx/conf.d.templates/server.skylink.conf.template index 7e22c13c..0d337abb 100644 --- a/docker/nginx/conf.d.templates/server.skylink.conf.template +++ b/docker/nginx/conf.d.templates/server.skylink.conf.template @@ -30,7 +30,12 @@ server { server { server_name *.${SERVER_DOMAIN}; # example: *.eu-ger-1.siasky.net - set_by_lua_block $skynet_portal_domain { return "${SERVER_DOMAIN}" } + set_by_lua_block $skynet_portal_domain { + -- when accessing portal directly through server domain, portal domain should be set to server domain + -- motivation: skynet-js uses Skynet-Portal-Api header (that is set to $skynet_portal_domain) to detect current + -- portal address and it should be server domain when accessing specific server by its domain address + return "${SERVER_DOMAIN}" + } set_by_lua_block $skynet_server_domain { return "${SERVER_DOMAIN}" } include /etc/nginx/conf.d/server/server.skylink; From d65397ac675abe2a6a258658bee748a62d6135b7 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 14:00:33 +0200 Subject: [PATCH 225/240] include nginx list of license conditions and disclaimer --- .../20-envsubst-on-templates.sh | 22 +++++++++++++++++++ docker/nginx/docker-entrypoint.sh | 22 +++++++++++++++++++ 2 files changed, 44 insertions(+) diff --git a/docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh b/docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh index 14d97a76..be9c5f8e 100755 --- a/docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh +++ b/docker/nginx/docker-entrypoint.d/20-envsubst-on-templates.sh @@ -2,9 +2,31 @@ # https://github.com/nginxinc/docker-nginx/blob/master/entrypoint/20-envsubst-on-templates.sh # https://github.com/nginxinc/docker-nginx/blob/master/LICENSE + # Copyright (C) 2011-2016 Nginx, Inc. # All rights reserved. +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. + +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. + set -e ME=$(basename $0) diff --git a/docker/nginx/docker-entrypoint.sh b/docker/nginx/docker-entrypoint.sh index 3802dab5..d45a6d9a 100755 --- a/docker/nginx/docker-entrypoint.sh +++ b/docker/nginx/docker-entrypoint.sh @@ -3,9 +3,31 @@ # https://github.com/nginxinc/docker-nginx/blob/master/entrypoint/docker-entrypoint.sh # https://github.com/nginxinc/docker-nginx/blob/master/LICENSE + # Copyright (C) 2011-2016 Nginx, Inc. # All rights reserved. +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. + +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. + set -e if [ -z "${NGINX_ENTRYPOINT_QUIET_LOGS:-}" ]; then From b88cdf6d76bd83a598d3abc473ca3ca6f178eaff Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 14:14:50 +0200 Subject: [PATCH 226/240] track anon uploads --- docker/nginx/libs/skynet/tracker.lua | 2 +- docker/nginx/libs/skynet/tracker.spec.lua | 9 +++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/docker/nginx/libs/skynet/tracker.lua b/docker/nginx/libs/skynet/tracker.lua index 78fa6995..89848d2c 100644 --- a/docker/nginx/libs/skynet/tracker.lua +++ b/docker/nginx/libs/skynet/tracker.lua @@ -51,7 +51,7 @@ function _M.track_upload(skylink, status_code, auth_headers) local has_auth_headers = not utils.is_table_empty(auth_headers) local status_success = status_code >= 200 and status_code <= 299 - if skylink and status_success and has_auth_headers then + if skylink and status_success then local ok, err = ngx.timer.at(0, _M.track_upload_timer, skylink, auth_headers) if not ok then ngx.log(ngx.ERR, "Failed to create timer: ", err) end end diff --git a/docker/nginx/libs/skynet/tracker.spec.lua b/docker/nginx/libs/skynet/tracker.spec.lua index 41dab843..d6c59c4a 100644 --- a/docker/nginx/libs/skynet/tracker.spec.lua +++ b/docker/nginx/libs/skynet/tracker.spec.lua @@ -231,12 +231,17 @@ describe("track_upload", function() assert.stub(ngx.timer.at).was_not_called() end) - it("should not schedule a timer if auth headers are empty", function() + it("should schedule a timer if auth headers are empty", function() ngx.timer.at.invokes(function() return true, nil end) skynet_tracker.track_upload(valid_skylink, valid_status_code, {}) - assert.stub(ngx.timer.at).was_not_called() + assert.stub(ngx.timer.at).was_called_with( + 0, + skynet_tracker.track_upload_timer, + valid_skylink, + {} + ) end) it("should log an error if timer failed to create", function() From d27dca72d13bfada3d75501d98f7585693872ff1 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 14:26:34 +0200 Subject: [PATCH 227/240] remove unused variable --- docker/nginx/libs/skynet/tracker.lua | 1 - 1 file changed, 1 deletion(-) diff --git a/docker/nginx/libs/skynet/tracker.lua b/docker/nginx/libs/skynet/tracker.lua index 89848d2c..56f9dcc4 100644 --- a/docker/nginx/libs/skynet/tracker.lua +++ b/docker/nginx/libs/skynet/tracker.lua @@ -48,7 +48,6 @@ function _M.track_upload_timer(premature, skylink, auth_headers) end function _M.track_upload(skylink, status_code, auth_headers) - local has_auth_headers = not utils.is_table_empty(auth_headers) local status_success = status_code >= 200 and status_code <= 299 if skylink and status_success then From 5bde83fc197ab4fe12dbe243e5f4e8472f0e0520 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 14:45:44 +0200 Subject: [PATCH 228/240] use multi stage build for website to slim down the image --- packages/website/Dockerfile | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/packages/website/Dockerfile b/packages/website/Dockerfile index dad0e393..bf4d34e4 100644 --- a/packages/website/Dockerfile +++ b/packages/website/Dockerfile @@ -1,15 +1,15 @@ -FROM node:16.14.2-alpine - -RUN apk add --no-cache autoconf=2.71-r0 automake=1.16.4-r1 build-base=0.5-r2 libtool=2.4.6-r7 nasm=2.15.05-r0 pkgconf=1.8.0-r0 +# builder stage - use debian base image to avoid needing to install missing packages +FROM node:16.14.2-bullseye as builder WORKDIR /usr/app +# disable gatsby telemetry and installing cypress binary +ENV GATSBY_TELEMETRY_DISABLED 1 +ENV CYPRESS_INSTALL_BINARY 0 + COPY packages/website/package.json \ packages/website/yarn.lock \ ./ - -ENV GATSBY_TELEMETRY_DISABLED 1 -ENV CYPRESS_INSTALL_BINARY 0 RUN yarn --frozen-lockfile COPY packages/website/data ./data @@ -22,6 +22,16 @@ COPY packages/website/gatsby-*.js \ RUN yarn build +# main stage - use alpine base image to minimise the resulting image footprint +FROM node:16.14.2-alpine + +WORKDIR /usr/app + +# install http server for serving website files +RUN npm install --global http-server@14.1.0 + +COPY --from=builder /usr/app/public /usr/app/public + EXPOSE 9000 -CMD ["sh", "-c", "yarn serve --host 0.0.0.0"] +CMD http-server /usr/app/public -s -p 9000 From 1c1615cd5fc274b79b3cef72898318f28e9e5780 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 14:49:05 +0200 Subject: [PATCH 229/240] convert CMD into JSON notation --- packages/website/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/website/Dockerfile b/packages/website/Dockerfile index bf4d34e4..39b17d37 100644 --- a/packages/website/Dockerfile +++ b/packages/website/Dockerfile @@ -34,4 +34,4 @@ COPY --from=builder /usr/app/public /usr/app/public EXPOSE 9000 -CMD http-server /usr/app/public -s -p 9000 +CMD ["http-server", "/usr/app/public", "-s -p 9000"] From 20f6831eb0aa2edfe359c83ba6a4d363703a2847 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 15:00:05 +0200 Subject: [PATCH 230/240] track file uploader ip --- docker/nginx/libs/skynet/tracker.lua | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/docker/nginx/libs/skynet/tracker.lua b/docker/nginx/libs/skynet/tracker.lua index 56f9dcc4..769de45c 100644 --- a/docker/nginx/libs/skynet/tracker.lua +++ b/docker/nginx/libs/skynet/tracker.lua @@ -1,5 +1,6 @@ local _M = {} +local cjson = require("cjson") local utils = require("utils") function _M.track_download_timer(premature, skylink, status, auth_headers, body_bytes_sent) @@ -30,7 +31,7 @@ function _M.track_download(skylink, status_code, auth_headers, body_bytes_sent) end end -function _M.track_upload_timer(premature, skylink, auth_headers) +function _M.track_upload_timer(premature, skylink, auth_headers, uploader_ip) if premature then return end local httpc = require("resty.http").new() @@ -39,6 +40,7 @@ function _M.track_upload_timer(premature, skylink, auth_headers) local res, err = httpc:request_uri("http://10.10.10.70:3000/track/upload/" .. skylink, { method = "POST", headers = auth_headers, + body = cjson.encode({ ip = uploader_ip }) }) if err or (res and res.status ~= 204) then @@ -49,9 +51,10 @@ end function _M.track_upload(skylink, status_code, auth_headers) local status_success = status_code >= 200 and status_code <= 299 + local uploader_ip = ngx.var.remote_addr if skylink and status_success then - local ok, err = ngx.timer.at(0, _M.track_upload_timer, skylink, auth_headers) + local ok, err = ngx.timer.at(0, _M.track_upload_timer, skylink, auth_headers, uploader_ip) if not ok then ngx.log(ngx.ERR, "Failed to create timer: ", err) end end end From e8babb625e6fc9e5a452aeb03314040ec144f838 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 15:08:01 +0200 Subject: [PATCH 231/240] try formvalue --- docker/nginx/libs/skynet/tracker.lua | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/docker/nginx/libs/skynet/tracker.lua b/docker/nginx/libs/skynet/tracker.lua index 769de45c..b26cc5e5 100644 --- a/docker/nginx/libs/skynet/tracker.lua +++ b/docker/nginx/libs/skynet/tracker.lua @@ -39,8 +39,10 @@ function _M.track_upload_timer(premature, skylink, auth_headers, uploader_ip) -- 10.10.10.70 points to accounts service (alias not available when using resty-http) local res, err = httpc:request_uri("http://10.10.10.70:3000/track/upload/" .. skylink, { method = "POST", - headers = auth_headers, - body = cjson.encode({ ip = uploader_ip }) + body = "ip=" .. uploader_ip, + headers = { + ["Content-Type"] = "application/x-www-form-urlencoded" + } }) if err or (res and res.status ~= 204) then From 5301384609a02523e50210f6cab990180aca49a8 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 15:16:07 +0200 Subject: [PATCH 232/240] do not include form header --- docker/nginx/libs/skynet/tracker.lua | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/docker/nginx/libs/skynet/tracker.lua b/docker/nginx/libs/skynet/tracker.lua index b26cc5e5..43d8319b 100644 --- a/docker/nginx/libs/skynet/tracker.lua +++ b/docker/nginx/libs/skynet/tracker.lua @@ -39,10 +39,8 @@ function _M.track_upload_timer(premature, skylink, auth_headers, uploader_ip) -- 10.10.10.70 points to accounts service (alias not available when using resty-http) local res, err = httpc:request_uri("http://10.10.10.70:3000/track/upload/" .. skylink, { method = "POST", + headers = auth_headers, body = "ip=" .. uploader_ip, - headers = { - ["Content-Type"] = "application/x-www-form-urlencoded" - } }) if err or (res and res.status ~= 204) then From 39f9b4d19640c24c7dba8bfc1b6e3ef55904217f Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 15:19:07 +0200 Subject: [PATCH 233/240] fix headers --- docker/nginx/libs/skynet/tracker.lua | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/docker/nginx/libs/skynet/tracker.lua b/docker/nginx/libs/skynet/tracker.lua index 43d8319b..8b3bd0f5 100644 --- a/docker/nginx/libs/skynet/tracker.lua +++ b/docker/nginx/libs/skynet/tracker.lua @@ -1,6 +1,5 @@ local _M = {} -local cjson = require("cjson") local utils = require("utils") function _M.track_download_timer(premature, skylink, status, auth_headers, body_bytes_sent) @@ -36,10 +35,18 @@ function _M.track_upload_timer(premature, skylink, auth_headers, uploader_ip) local httpc = require("resty.http").new() + -- set correct content type header and include auth headers + local headers = { + ["Content-Type"] = "application/x-www-form-urlencoded", + } + for key, value in ipairs(auth_headers) do + headers[key] = value + end + -- 10.10.10.70 points to accounts service (alias not available when using resty-http) local res, err = httpc:request_uri("http://10.10.10.70:3000/track/upload/" .. skylink, { method = "POST", - headers = auth_headers, + headers = headers, body = "ip=" .. uploader_ip, }) From f88dcf3eee5af9a2207c1d8cf4d3f166c6e9915e Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 15:34:28 +0200 Subject: [PATCH 234/240] include unit tests for uploader ip --- docker/nginx/conf.d/server/server.api | 21 ++++++- docker/nginx/libs/skynet/tracker.lua | 5 +- docker/nginx/libs/skynet/tracker.spec.lua | 67 ++++++++++++++++------- 3 files changed, 68 insertions(+), 25 deletions(-) diff --git a/docker/nginx/conf.d/server/server.api b/docker/nginx/conf.d/server/server.api index 0243ab90..48e7a638 100644 --- a/docker/nginx/conf.d/server/server.api +++ b/docker/nginx/conf.d/server/server.api @@ -235,7 +235,12 @@ location /skynet/skyfile { local skynet_tracker = require("skynet.tracker") if skynet_modules.is_enabled("a") then - skynet_tracker.track_upload(ngx.header["Skynet-Skylink"], ngx.status, skynet_account.get_auth_headers()) + skynet_tracker.track_upload( + ngx.header["Skynet-Skylink"], + ngx.status, + skynet_account.get_auth_headers(), + ngx.var.remote_addr + ) end if skynet_modules.is_enabled("s") then @@ -315,7 +320,12 @@ location /skynet/tus { local skynet_tracker = require("skynet.tracker") if skynet_modules.is_enabled("a") then - skynet_tracker.track_upload(ngx.header["Skynet-Skylink"], ngx.status, skynet_account.get_auth_headers()) + skynet_tracker.track_upload( + ngx.header["Skynet-Skylink"], + ngx.status, + skynet_account.get_auth_headers(), + ngx.var.remote_addr + ) end if skynet_modules.is_enabled("s") then @@ -346,7 +356,12 @@ location /skynet/pin { local skynet_tracker = require("skynet.tracker") if skynet_modules.is_enabled("a") then - skynet_tracker.track_upload(ngx.header["Skynet-Skylink"], ngx.status, skynet_account.get_auth_headers()) + skynet_tracker.track_upload( + ngx.header["Skynet-Skylink"], + ngx.status, + skynet_account.get_auth_headers(), + ngx.var.remote_addr + ) end if skynet_modules.is_enabled("s") then diff --git a/docker/nginx/libs/skynet/tracker.lua b/docker/nginx/libs/skynet/tracker.lua index 8b3bd0f5..2a89bb4b 100644 --- a/docker/nginx/libs/skynet/tracker.lua +++ b/docker/nginx/libs/skynet/tracker.lua @@ -41,7 +41,7 @@ function _M.track_upload_timer(premature, skylink, auth_headers, uploader_ip) } for key, value in ipairs(auth_headers) do headers[key] = value - end + end -- 10.10.10.70 points to accounts service (alias not available when using resty-http) local res, err = httpc:request_uri("http://10.10.10.70:3000/track/upload/" .. skylink, { @@ -56,9 +56,8 @@ function _M.track_upload_timer(premature, skylink, auth_headers, uploader_ip) end end -function _M.track_upload(skylink, status_code, auth_headers) +function _M.track_upload(skylink, status_code, auth_headers, uploader_ip) local status_success = status_code >= 200 and status_code <= 299 - local uploader_ip = ngx.var.remote_addr if skylink and status_success then local ok, err = ngx.timer.at(0, _M.track_upload_timer, skylink, auth_headers, uploader_ip) diff --git a/docker/nginx/libs/skynet/tracker.spec.lua b/docker/nginx/libs/skynet/tracker.spec.lua index d6c59c4a..98d587d8 100644 --- a/docker/nginx/libs/skynet/tracker.spec.lua +++ b/docker/nginx/libs/skynet/tracker.spec.lua @@ -5,6 +5,7 @@ local skynet_tracker = require("skynet.tracker") local valid_skylink = "AQBG8n_sgEM_nlEp3G0w3vLjmdvSZ46ln8ZXHn-eObZNjA" local valid_status_code = 200 local valid_auth_headers = { ["Skynet-Api-Key"] = "foo" } +local valid_ip = "12.34.56.78" describe("track_download", function() local valid_body_bytes_sent = 12345 @@ -200,20 +201,21 @@ describe("track_upload", function() it("should schedule a timer when conditions are met", function() ngx.timer.at.invokes(function() return true, nil end) - skynet_tracker.track_upload(valid_skylink, valid_status_code, valid_auth_headers) + skynet_tracker.track_upload(valid_skylink, valid_status_code, valid_auth_headers, valid_ip) assert.stub(ngx.timer.at).was_called_with( 0, skynet_tracker.track_upload_timer, valid_skylink, - valid_auth_headers + valid_auth_headers, + valid_ip ) end) it("should not schedule a timer if skylink is empty", function() ngx.timer.at.invokes(function() return true, nil end) - skynet_tracker.track_upload(nil, valid_status_code, valid_auth_headers) + skynet_tracker.track_upload(nil, valid_status_code, valid_auth_headers, valid_ip) assert.stub(ngx.timer.at).was_not_called() end) @@ -222,11 +224,11 @@ describe("track_upload", function() ngx.timer.at.invokes(function() return true, nil end) -- couple of example of 4XX and 5XX codes - skynet_tracker.track_upload(valid_skylink, 401, valid_auth_headers) - skynet_tracker.track_upload(valid_skylink, 403, valid_auth_headers) - skynet_tracker.track_upload(valid_skylink, 490, valid_auth_headers) - skynet_tracker.track_upload(valid_skylink, 500, valid_auth_headers) - skynet_tracker.track_upload(valid_skylink, 502, valid_auth_headers) + skynet_tracker.track_upload(valid_skylink, 401, valid_auth_headers, valid_ip) + skynet_tracker.track_upload(valid_skylink, 403, valid_auth_headers, valid_ip) + skynet_tracker.track_upload(valid_skylink, 490, valid_auth_headers, valid_ip) + skynet_tracker.track_upload(valid_skylink, 500, valid_auth_headers, valid_ip) + skynet_tracker.track_upload(valid_skylink, 502, valid_auth_headers, valid_ip) assert.stub(ngx.timer.at).was_not_called() end) @@ -234,13 +236,14 @@ describe("track_upload", function() it("should schedule a timer if auth headers are empty", function() ngx.timer.at.invokes(function() return true, nil end) - skynet_tracker.track_upload(valid_skylink, valid_status_code, {}) + skynet_tracker.track_upload(valid_skylink, valid_status_code, {}, valid_ip) assert.stub(ngx.timer.at).was_called_with( 0, skynet_tracker.track_upload_timer, valid_skylink, - {} + {}, + valid_ip ) end) @@ -248,13 +251,14 @@ describe("track_upload", function() stub(ngx, "log") ngx.timer.at.invokes(function() return false, "such a failure" end) - skynet_tracker.track_upload(valid_skylink, valid_status_code, valid_auth_headers) + skynet_tracker.track_upload(valid_skylink, valid_status_code, valid_auth_headers, valid_ip) assert.stub(ngx.timer.at).was_called_with( 0, skynet_tracker.track_upload_timer, valid_skylink, - valid_auth_headers + valid_auth_headers, + valid_ip ) assert.stub(ngx.log).was_called_with(ngx.ERR, "Failed to create timer: ", "such a failure") @@ -284,7 +288,8 @@ describe("track_upload", function() skynet_tracker.track_upload_timer( true, valid_skylink, - valid_auth_headers + valid_auth_headers, + valid_ip ) assert.stub(request_uri).was_not_called() @@ -302,11 +307,19 @@ describe("track_upload", function() skynet_tracker.track_upload_timer( false, valid_skylink, - valid_auth_headers + valid_auth_headers, + valid_ip ) local uri = "http://10.10.10.70:3000/track/upload/" .. valid_skylink - assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(request_uri).was_called_with(httpc, uri, { + method = "POST", + headers = { + ["Content-Type"] = "application/x-www-form-urlencoded", + ["Skynet-Api-Key"] = "foo", + }, + body = "ip=" .. valid_ip + }) assert.stub(ngx.log).was_not_called() end) @@ -321,11 +334,19 @@ describe("track_upload", function() skynet_tracker.track_upload_timer( false, valid_skylink, - valid_auth_headers + valid_auth_headers, + valid_ip ) local uri = "http://10.10.10.70:3000/track/upload/" .. valid_skylink - assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(request_uri).was_called_with(httpc, uri, { + method = "POST", + headers = { + ["Content-Type"] = "application/x-www-form-urlencoded", + ["Skynet-Api-Key"] = "foo", + }, + body = "ip=" .. valid_ip + }) assert.stub(ngx.log).was_called_with( ngx.ERR, "Failed accounts service request /track/upload/" .. valid_skylink .. ": ", @@ -344,11 +365,19 @@ describe("track_upload", function() skynet_tracker.track_upload_timer( false, valid_skylink, - valid_auth_headers + valid_auth_headers, + valid_ip ) local uri = "http://10.10.10.70:3000/track/upload/" .. valid_skylink - assert.stub(request_uri).was_called_with(httpc, uri, { method = "POST", headers = valid_auth_headers }) + assert.stub(request_uri).was_called_with(httpc, uri, { + method = "POST", + headers = { + ["Content-Type"] = "application/x-www-form-urlencoded", + ["Skynet-Api-Key"] = "foo", + }, + body = "ip=" .. valid_ip + }) assert.stub(ngx.log).was_called_with( ngx.ERR, "Failed accounts service request /track/upload/" .. valid_skylink .. ": ", From 077295806471cafb4bdf44800d5b3223f584c532 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 17:06:17 +0200 Subject: [PATCH 235/240] use pairs instead of ipairs --- docker/nginx/libs/skynet/tracker.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/nginx/libs/skynet/tracker.lua b/docker/nginx/libs/skynet/tracker.lua index 2a89bb4b..37413215 100644 --- a/docker/nginx/libs/skynet/tracker.lua +++ b/docker/nginx/libs/skynet/tracker.lua @@ -39,7 +39,7 @@ function _M.track_upload_timer(premature, skylink, auth_headers, uploader_ip) local headers = { ["Content-Type"] = "application/x-www-form-urlencoded", } - for key, value in ipairs(auth_headers) do + for key, value in pairs(auth_headers) do headers[key] = value end From 446049986c815da8dc644152e2d730dba9ad794c Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 22 Apr 2022 17:33:26 +0200 Subject: [PATCH 236/240] Revert "Merge pull request #1917 from SkynetLabs/use-accounts-image" This reverts commit f3ec613a5aea5a31ecfa9e66426067e29401ed71, reversing changes made to 25d573b9bad6aa437190c3b0f202b75d32536e60. --- docker-compose.accounts.yml | 8 +++++--- docker/accounts/Dockerfile | 22 ++++++++++++++++++++++ 2 files changed, 27 insertions(+), 3 deletions(-) create mode 100644 docker/accounts/Dockerfile diff --git a/docker-compose.accounts.yml b/docker-compose.accounts.yml index b154bac7..e4806e91 100644 --- a/docker-compose.accounts.yml +++ b/docker-compose.accounts.yml @@ -20,9 +20,11 @@ services: - ACCOUNTS_LIMIT_ACCESS=${ACCOUNTS_LIMIT_ACCESS:-authenticated} # default to authenticated access only accounts: - # uncomment "build" and comment out "image" to build from sources - # build: https://github.com/SkynetLabs/skynet-accounts.git#main - image: skynetlabs/skynet-accounts + build: + context: ./docker/accounts + dockerfile: Dockerfile + args: + branch: main container_name: accounts restart: unless-stopped logging: *default-logging diff --git a/docker/accounts/Dockerfile b/docker/accounts/Dockerfile new file mode 100644 index 00000000..5cbf359a --- /dev/null +++ b/docker/accounts/Dockerfile @@ -0,0 +1,22 @@ +FROM golang:1.16.7 +LABEL maintainer="SkynetLabs " + +ENV GOOS linux +ENV GOARCH amd64 + +ARG branch=main + +WORKDIR /root + +RUN git clone --single-branch --branch ${branch} https://github.com/SkynetLabs/skynet-accounts.git && \ + cd skynet-accounts && \ + go mod download && \ + make release + +ENV SKYNET_DB_HOST="localhost" +ENV SKYNET_DB_PORT="27017" +ENV SKYNET_DB_USER="username" +ENV SKYNET_DB_PASS="password" +ENV SKYNET_ACCOUNTS_PORT=3000 + +ENTRYPOINT ["skynet-accounts"] From cdfd94d29083fda8275d6e4599d89732a3cb35db Mon Sep 17 00:00:00 2001 From: Matthew Sevey Date: Fri, 22 Apr 2022 13:50:28 -0400 Subject: [PATCH 237/240] Revert "Revert "Merge pull request #1917 from SkynetLabs/use-accounts-image"" --- docker-compose.accounts.yml | 8 +++----- docker/accounts/Dockerfile | 22 ---------------------- 2 files changed, 3 insertions(+), 27 deletions(-) delete mode 100644 docker/accounts/Dockerfile diff --git a/docker-compose.accounts.yml b/docker-compose.accounts.yml index e4806e91..b154bac7 100644 --- a/docker-compose.accounts.yml +++ b/docker-compose.accounts.yml @@ -20,11 +20,9 @@ services: - ACCOUNTS_LIMIT_ACCESS=${ACCOUNTS_LIMIT_ACCESS:-authenticated} # default to authenticated access only accounts: - build: - context: ./docker/accounts - dockerfile: Dockerfile - args: - branch: main + # uncomment "build" and comment out "image" to build from sources + # build: https://github.com/SkynetLabs/skynet-accounts.git#main + image: skynetlabs/skynet-accounts container_name: accounts restart: unless-stopped logging: *default-logging diff --git a/docker/accounts/Dockerfile b/docker/accounts/Dockerfile deleted file mode 100644 index 5cbf359a..00000000 --- a/docker/accounts/Dockerfile +++ /dev/null @@ -1,22 +0,0 @@ -FROM golang:1.16.7 -LABEL maintainer="SkynetLabs " - -ENV GOOS linux -ENV GOARCH amd64 - -ARG branch=main - -WORKDIR /root - -RUN git clone --single-branch --branch ${branch} https://github.com/SkynetLabs/skynet-accounts.git && \ - cd skynet-accounts && \ - go mod download && \ - make release - -ENV SKYNET_DB_HOST="localhost" -ENV SKYNET_DB_PORT="27017" -ENV SKYNET_DB_USER="username" -ENV SKYNET_DB_PASS="password" -ENV SKYNET_ACCOUNTS_PORT=3000 - -ENTRYPOINT ["skynet-accounts"] From 3fff75aab5a7b8b7ede30867a68384ce49919a26 Mon Sep 17 00:00:00 2001 From: Ivaylo Novakov Date: Mon, 25 Apr 2022 10:06:27 +0200 Subject: [PATCH 238/240] Mongo: ShardingTaskExecutorPoolMinSize=10 (#2038) --- docker-compose.mongodb.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.mongodb.yml b/docker-compose.mongodb.yml index 610d5308..e8eb9aca 100644 --- a/docker-compose.mongodb.yml +++ b/docker-compose.mongodb.yml @@ -15,7 +15,7 @@ services: mongo: image: mongo:4.4.1 - command: --keyFile=/data/mgkey --replSet=${SKYNET_DB_REPLICASET:-skynet} + command: --keyFile=/data/mgkey --replSet=${SKYNET_DB_REPLICASET:-skynet} --setParameter ShardingTaskExecutorPoolMinSize=10 container_name: mongo restart: unless-stopped logging: *default-logging From 82cc22f36718de8b8d9855e79535aeb4a715b25e Mon Sep 17 00:00:00 2001 From: firyx <29089732+firyx@users.noreply.github.com> Date: Tue, 26 Apr 2022 16:39:35 +0200 Subject: [PATCH 239/240] Fix dashboard-v2 Dockerfile context (#2051) --- changelog/items/bugs-fixed/fix-context.md | 2 ++ docker-compose.accounts.yml | 4 ++-- packages/dashboard-v2/Dockerfile | 14 +++++++------- 3 files changed, 11 insertions(+), 9 deletions(-) create mode 100644 changelog/items/bugs-fixed/fix-context.md diff --git a/changelog/items/bugs-fixed/fix-context.md b/changelog/items/bugs-fixed/fix-context.md new file mode 100644 index 00000000..e94c8e6e --- /dev/null +++ b/changelog/items/bugs-fixed/fix-context.md @@ -0,0 +1,2 @@ +- Fix `dashboard-v2` Dockerfile context in `docker-compose.accounts.yml` to + avoid Ansible deploy (docker compose build) `permission denied` issues. \ No newline at end of file diff --git a/docker-compose.accounts.yml b/docker-compose.accounts.yml index b154bac7..221badf8 100644 --- a/docker-compose.accounts.yml +++ b/docker-compose.accounts.yml @@ -80,8 +80,8 @@ services: dashboard-v2: build: - context: . - dockerfile: packages/dashboard-v2/Dockerfile + context: ./packages/dashboard-v2 + dockerfile: Dockerfile container_name: dashboard-v2 restart: unless-stopped logging: *default-logging diff --git a/packages/dashboard-v2/Dockerfile b/packages/dashboard-v2/Dockerfile index 4c834e0c..86fe89bc 100644 --- a/packages/dashboard-v2/Dockerfile +++ b/packages/dashboard-v2/Dockerfile @@ -2,17 +2,17 @@ FROM node:16.14.2-alpine WORKDIR /usr/app -COPY packages/dashboard-v2/package.json \ - packages/dashboard-v2/yarn.lock \ +COPY package.json \ + yarn.lock \ ./ RUN yarn --frozen-lockfile -COPY packages/dashboard-v2/static ./static -COPY packages/dashboard-v2/src ./src -COPY packages/dashboard-v2/gatsby*.js \ - packages/dashboard-v2/postcss.config.js \ - packages/dashboard-v2/tailwind.config.js \ +COPY static ./static +COPY src ./src +COPY gatsby*.js \ + postcss.config.js \ + tailwind.config.js \ ./ CMD ["sh", "-c", "yarn build && yarn serve --host 0.0.0.0 -p 9000"] From 744b410ba7cac9590489f04aa088a18cf9341bc9 Mon Sep 17 00:00:00 2001 From: PJ Date: Wed, 27 Apr 2022 08:48:16 +0200 Subject: [PATCH 240/240] Update abuse tags --- docker-compose.abuse-scanner.yml | 2 +- docker-compose.blocker.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose.abuse-scanner.yml b/docker-compose.abuse-scanner.yml index 6080ebcd..2eae443b 100644 --- a/docker-compose.abuse-scanner.yml +++ b/docker-compose.abuse-scanner.yml @@ -10,7 +10,7 @@ services: abuse-scanner: # uncomment "build" and comment out "image" to build from sources # build: https://github.com/SkynetLabs/abuse-scanner.git#main - image: skynetlabs/abuse-scanner:0.1.0 + image: skynetlabs/abuse-scanner:0.1.1 container_name: abuse-scanner restart: unless-stopped logging: *default-logging diff --git a/docker-compose.blocker.yml b/docker-compose.blocker.yml index 29d29e34..db398805 100644 --- a/docker-compose.blocker.yml +++ b/docker-compose.blocker.yml @@ -15,7 +15,7 @@ services: blocker: # uncomment "build" and comment out "image" to build from sources # build: https://github.com/SkynetLabs/blocker.git#main - image: skynetlabs/blocker:0.1.0 + image: skynetlabs/blocker:0.1.1 container_name: blocker restart: unless-stopped logging: *default-logging