Skip to content

Commit

Permalink
Merge pull request #255 from sunrise-stake/develop
Browse files Browse the repository at this point in the history
Hotfix to fix info modal closing and improve deployment reliability
  • Loading branch information
dankelleher authored May 11, 2023
2 parents b5b4dbd + 517dc3b commit fe3c0a8
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 8 deletions.
3 changes: 1 addition & 2 deletions packages/app/src/common/components/Button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,7 @@ const Button: React.FC<ButtonProps> = ({
<InfoModal
title={disabledTitle}
message={disabledMessage}
ok={infoModal.onModalOK}
show={infoModal.modalShown}
modalControl={infoModal}
/>
{children}
</button>
Expand Down
18 changes: 14 additions & 4 deletions packages/app/src/common/components/modals/InfoModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,23 @@ import { Dialog } from "@headlessui/react";
import { ExclamationTriangleIcon } from "@heroicons/react/24/solid";
import React, { type FC, type PropsWithChildren } from "react";

import { BaseModal, type ModalProps } from "./";
import { BaseModal } from "./";
import { type ModalControl } from "../../hooks";

type InfoModalProps = { title: string; message?: string } & PropsWithChildren &
Omit<ModalProps, "cancel">;
type InfoModalProps = {
title: string;
message?: string;
modalControl: ModalControl;
} & PropsWithChildren;
const InfoModal: FC<InfoModalProps> = (props) => {
return (
<BaseModal cancelVisible={false} {...props} cancel={() => {}}>
<BaseModal
cancelVisible={false}
{...props}
ok={props.modalControl.onModalOK}
cancel={props.modalControl.onModalClose}
show={props.modalControl.modalShown}
>
<div className="mx-auto flex h-12 w-12 items-center justify-center rounded-full">
<ExclamationTriangleIcon
className="w-8"
Expand Down
4 changes: 2 additions & 2 deletions vercel.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"installCommand": "yarn install --network-concurrency 10",
"installCommand": "yarn install --network-concurrency 2",
"buildCommand": "yarn build",
"outputDirectory": "packages/app/build"
}
}

1 comment on commit fe3c0a8

@vercel
Copy link

@vercel vercel bot commented on fe3c0a8 May 11, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

app – ./

app-git-main-sunrise-stake.vercel.app
app.sunrisestake.com
app-sunrise-stake.vercel.app

Please sign in to comment.