-
Notifications
You must be signed in to change notification settings - Fork 35
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 #143 from bluewave-labs/reorganized-components
reorganized components
- Loading branch information
Showing
25 changed files
with
95 additions
and
36 deletions.
There are no files selected for viewing
6 changes: 3 additions & 3 deletions
6
...teActivityButton/CreateActivityButton.jsx → ...teActivityButton/CreateActivityButton.jsx
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
2 changes: 1 addition & 1 deletion
2
...vityButton/CreateActivityButtonStyles.css → ...vityButton/CreateActivityButtonStyles.css
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
@import "../../styles/variables.css"; | ||
@import "../../../styles/variables.css"; | ||
|
||
.bannerStyle{ | ||
display: flex; | ||
|
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
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
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
frontend/src/components/Title/Title.jsx → ...end/src/components/Header/Title/Title.jsx
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
File renamed without changes.
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
import { React } from 'react'; | ||
import PropTypes from 'prop-types'; | ||
import CloseOutlinedIcon from '@mui/icons-material/CloseOutlined'; | ||
import styles from './GuideTemplate.module.scss'; | ||
import classNames from 'classnames'; | ||
import Button from '../../components/Button/Button'; | ||
import { useNavigate } from 'react-router-dom'; | ||
|
||
const GuideTemplate = ({ title = '', handleButtonClick = () => null, activeButton = 0, leftContent = () => null, rightContent = () => null, leftAppearance = () => null }) => { | ||
const navigate = useNavigate(); | ||
const buttons = ['Content', 'Appearance']; | ||
return ( | ||
<div className={styles.container}> | ||
<div className={styles.popup}> | ||
<div className={styles.header}> | ||
<span style={{ marginLeft: '5px' }}>{title}</span> | ||
<CloseOutlinedIcon style={{ color: '#98A2B3', fontSize: '20px' }} /> | ||
</div> | ||
<div className={styles.content}> | ||
{/* Content and Appereance buttons */} | ||
<div className={styles.buttons}> | ||
{buttons.map((buttonName, index) => ( | ||
<button | ||
key={index} | ||
className={classNames(styles.menuButton, { | ||
[styles.active]: activeButton === index, | ||
})} | ||
onClick={() => handleButtonClick(index)} | ||
> | ||
{buttonName} | ||
</button> | ||
))} | ||
</div> | ||
<div className={styles.leftRightContent}> | ||
{activeButton === 1 ? leftAppearance() : leftContent()} | ||
{rightContent()} | ||
</div> | ||
<div className={styles.optionButtons}> | ||
<Button text='Cancel' buttonType='secondary-grey' onClick={() => {navigate('/');}}/> | ||
<Button text='Save'/> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
</div> | ||
); | ||
}; | ||
|
||
GuideTemplate.propTypes = { | ||
title: PropTypes.string, | ||
handleButtonClick: PropTypes.func, | ||
activeButton: PropTypes.number, | ||
leftContent: PropTypes.func, | ||
rightContent: PropTypes.func, | ||
leftAppearance: PropTypes.func, | ||
}; | ||
|
||
export default GuideTemplate; |
2 changes: 1 addition & 1 deletion
2
...s/GuideTemplate/GuideTemplate.module.scss → ...s/GuideTemplate/GuideTemplate.module.scss
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
@use '../../../styles/globals.scss' as *; | ||
@use '../../styles/globals.scss' as *; | ||
|
||
.container { | ||
|
||
|
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,12 @@ | ||
# Guide Template | ||
|
||
The Guide Template is designed for creating "Create Activity" pages, such as CreatePopupPage and CreateBannerPage. | ||
|
||
## Overview | ||
|
||
- **LeftContent**: Displayed when the "Content" button is clicked. | ||
- **LeftAppearance**: Displayed when the "Appearance" button is clicked. | ||
- **RightContent**: Always visible on the page. | ||
- **onSave**: Specifies the action to be taken when the "Save" button is clicked. | ||
- **title**: Allows editing of the page title. | ||
- **handleButtonClick**: Manages which button is clicked (either "Appearance" or "Content"). |
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
...components/templates/HomePageTemplate.jsx → ...tes/HomePageTemplate/HomePageTemplate.jsx
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