-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #87 from hotosm/fix/create-project-issues
Fix Create Project Issues
- Loading branch information
Showing
23 changed files
with
720 additions
and
165 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 7 additions & 3 deletions
10
src/frontend/src/components/CreateProject/CreateProjectHeader/index.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 37 additions & 0 deletions
37
src/frontend/src/components/CreateProject/ExitCreateProjectModal/index.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import { useTypedDispatch } from '@Store/hooks'; | ||
import { useNavigate } from 'react-router-dom'; | ||
import { FlexRow } from '@Components/common/Layouts'; | ||
import { Button } from '@Components/RadixComponents/Button'; | ||
import { toggleModal } from '@Store/actions/common'; | ||
|
||
export default function ExitCreateProjectModal() { | ||
const dispatch = useTypedDispatch(); | ||
const navigate = useNavigate(); | ||
|
||
return ( | ||
<section> | ||
<p className="naxatw-mb-3"> | ||
This page has some unsaved changes, are you sure you want to leave this | ||
page? | ||
</p> | ||
<FlexRow className="naxatw-w-full" gap={2}> | ||
<Button | ||
variant="ghost" | ||
className="naxatw-text-red" | ||
onClick={() => { | ||
navigate('/projects'); | ||
dispatch(toggleModal(null)); | ||
}} | ||
> | ||
Leave | ||
</Button> | ||
<Button | ||
className="naxatw-bg-red naxatw-px-5" | ||
onClick={() => dispatch(toggleModal(null))} | ||
> | ||
Stay | ||
</Button> | ||
</FlexRow> | ||
</section> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.