This repository has been archived by the owner on May 12, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/master'
- Loading branch information
Showing
19 changed files
with
16,082 additions
and
143 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
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
Binary file not shown.
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,32 @@ | ||
{ | ||
"0": { | ||
"icon": "FaHome", | ||
"title": "CPF Housing Usage", | ||
"description": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Vitae auctor eu augue ut lectus." | ||
}, | ||
"1": { | ||
"icon": "FaCalculator", | ||
"title": "Mortgage Calculator", | ||
"description": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Wres bes awer." | ||
}, | ||
"2": { | ||
"icon": "FaHome", | ||
"title": "CPF Housing Usage with a very very long title", | ||
"description": "Hard choices, easy life. Easy choices, hard life." | ||
}, | ||
"3": { | ||
"icon": "FaGraduationCap", | ||
"title": "Education", | ||
"description": "Education is an admirable thing, but it is well to remember from time to time that nothing that is worth knowing can be taught." | ||
}, | ||
"4": { | ||
"icon": "FaRegMoneyBillAlt", | ||
"title": "Investment", | ||
"description": "Description goes here" | ||
}, | ||
"5": { | ||
"icon": "FaRegStickyNote", | ||
"title": "Statements", | ||
"description": "Description goes here" | ||
} | ||
} |
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,56 @@ | ||
{ | ||
"0": { | ||
"icon": "FaCalculator", | ||
"title": "Ordinary Account (OA)", | ||
"slug": "/ordinary_account", | ||
"description": "Description goes here" | ||
}, | ||
"1": { | ||
"icon": "FaCalculator", | ||
"title": "Special Account (SA)", | ||
"slug": "/special_account", | ||
"description": "Description goes here" | ||
}, | ||
"2": { | ||
"icon": "FaCalculator", | ||
"title": "Medisave Account (MA)", | ||
"slug": "/medisave_account", | ||
"description": "Description goes here" | ||
}, | ||
"3": { | ||
"icon": "FaCalculator", | ||
"title": "Apply/change GIRO for Repayment of Education Loan", | ||
"slug": "/giro_education", | ||
"description": "Description goes here" | ||
}, | ||
"4": { | ||
"icon": "FaCalculator", | ||
"title": "Defer Repayment", | ||
"slug": "/defer_repayment", | ||
"description": "Description goes here" | ||
}, | ||
"5": { | ||
"icon": "FaCalculator", | ||
"title": "Change Monthly Instalment", | ||
"slug": "/monthly_instalment", | ||
"description": "Description goes here" | ||
}, | ||
"6": { | ||
"icon": "FaCalculator", | ||
"title": "CPFIS Self-Awareness Questionnaire (SAQ) Status", | ||
"slug": "/saq_status", | ||
"description": "Description goes here" | ||
}, | ||
"7": { | ||
"icon": "FaCalculator", | ||
"title": "Apply to Withdraw", | ||
"slug": "/apply_withdraw", | ||
"description": "Description goes here" | ||
}, | ||
"8": { | ||
"icon": "FaCalculator", | ||
"title": "Apply to Transfer", | ||
"slug": "/apply_transfer", | ||
"description": "Description goes here" | ||
} | ||
} |
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,109 @@ | ||
import React from "react"; | ||
import { MdAddCircle } from "react-icons/md"; | ||
import { IconContext } from "react-icons"; | ||
import styled from "styled-components"; | ||
|
||
const Wrapper = styled.div` | ||
padding: 15px; | ||
cursor: pointer; | ||
`; | ||
|
||
const Card = styled.div` | ||
padding: 20px; | ||
width: 280px; | ||
height: 280px; | ||
border-radius: 20px; | ||
overflow: hidden; | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
justify-content: center; | ||
`; | ||
|
||
const Button = styled.div` | ||
height: 70px; | ||
width: 70px; | ||
margin-bottom: 1rem; | ||
border-radius: 40px; | ||
box-shadow: 0 5px 15px 0 rgba(70, 70, 70, 0.15); | ||
background: #40514e; | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
cursor: pointer; | ||
&:hover { | ||
box-shadow: 0 5px 15px 0 rgba(70, 70, 70, 0.5); | ||
transition: all 0.5s ease-out; | ||
} | ||
`; | ||
|
||
export default function AddButton(props) { | ||
const { addButtonHandler } = props; | ||
|
||
return ( | ||
<Wrapper> | ||
<Card> | ||
<Button | ||
onClick={() => { | ||
addButtonHandler(); | ||
}} | ||
> | ||
<IconContext.Provider value={{ color: "#ffffff", size: "36px" }}> | ||
<MdAddCircle /> | ||
</IconContext.Provider> | ||
</Button> | ||
<p>Add items</p> | ||
</Card> | ||
</Wrapper> | ||
); | ||
} | ||
|
||
// import React from "react"; | ||
// import { Button, Col, Container } from "react-bootstrap"; | ||
// // import Favourites_card from "./Favourites_card"; | ||
// import { IoIosAddCircle } from "react-icons/io"; | ||
// import { IconContext } from "react-icons"; | ||
// import styled from "styled-components"; | ||
// import Favourites_addon from "./Favourites_addon"; | ||
|
||
// const Add_Button = styled(Button)` | ||
// background-color: gray; | ||
// border-radius: 100%; | ||
// `; | ||
|
||
// const Container_ = styled(Container)` | ||
// // border-style: solid; | ||
// height: 300px; | ||
// // padding-top: 50px; | ||
// // padding-right: 50px; | ||
// // padding-bottom: 50px; | ||
// // padding-left: 50px; | ||
// padding: 40%; | ||
// text-align: center; | ||
// `; | ||
|
||
// function Favourites_addbutton(props) { | ||
// const [modalShow, setModalShow] = React.useState(false); | ||
// const { Items, data } = props; | ||
// console.log(Items); | ||
// return ( | ||
// <Col sm={4}> | ||
// <Container_> | ||
// <Add_Button variant="secondary" onClick={() => setModalShow(true)}> | ||
// <IconContext.Provider value={{ size: "45px", color: "white" }}> | ||
// <IoIosAddCircle /> | ||
// </IconContext.Provider> | ||
// </Add_Button> | ||
// <Favourites_addon | ||
// Items={Items} | ||
// data={data} | ||
// show={modalShow} | ||
// onHide={() => setModalShow(false)} | ||
// /> | ||
// </Container_> | ||
// </Col> | ||
// ); | ||
// } | ||
|
||
// export default Favourites_addbutton; |
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,104 @@ | ||
import React from "react"; | ||
import * as FAIcon from "react-icons/fa"; | ||
import { IconContext } from "react-icons"; | ||
import styled from "styled-components"; | ||
|
||
const Wrapper = styled.div` | ||
padding: 15px; | ||
`; | ||
|
||
const Card = styled.div` | ||
padding: 20px; | ||
width: 280px; | ||
height: 280px; | ||
border-radius: 20px; | ||
overflow: hidden; | ||
cursor: pointer; | ||
&:hover { | ||
box-shadow: 0 5px 15px 0 rgba(70, 70, 70, 0.5); | ||
transition: all 0.5s ease-out; | ||
} | ||
${props => { | ||
if (props.selected) { | ||
return ` | ||
box-shadow: 0 5px 15px 0 rgba(70, 70, 70, 0.5); | ||
border: rgba(17, 153, 158, 0.7); | ||
border-width: 2px; | ||
border-style: solid; | ||
transition: all 0.5s ease-out; | ||
`; | ||
} else { | ||
return ` | ||
box-shadow: 0 5px 15px 0 rgba(70, 70, 70, 0.15); | ||
border: transparent; | ||
border-width: 2px; | ||
border-style: solid; | ||
transition: all 0.5s ease-out; | ||
`; | ||
} | ||
}} | ||
`; | ||
|
||
const defaults = require("../asset/favourites.json")["0"]; | ||
|
||
export default function FavouritesCard(props) { | ||
const { icon, title, description } = props.data || defaults; | ||
const selected = props.selected || false; | ||
const handleClick = props.onClick; | ||
|
||
return ( | ||
<Wrapper onClick={handleClick}> | ||
<Card selected={selected}> | ||
<IconContext.Provider value={{ color: "11999e", size: "64px" }}> | ||
{React.createElement(FAIcon[icon])} | ||
</IconContext.Provider> | ||
<h2 className="my-2"> | ||
{title.length > 25 ? title.substring(0, 25) + "..." : title} | ||
</h2> | ||
<p> | ||
{description.length > 85 | ||
? description.substring(0, 85) + "..." | ||
: description} | ||
</p> | ||
</Card> | ||
</Wrapper> | ||
); | ||
} | ||
|
||
// import React from "react"; | ||
// import { Row, Container } from "react-bootstrap"; | ||
// import * as MaterialDesign from "react-icons/fa"; | ||
// import { IconContext } from "react-icons"; | ||
// import styled from "styled-components"; | ||
// import "./test.css"; | ||
|
||
// const IconContext_ = styled(IconContext)` | ||
// // border-style: solid; | ||
// align: center; | ||
// `; | ||
|
||
// function Favourites_card(props) { | ||
// console.log(props); | ||
// const { icon, header, description } = props.data; | ||
// const mdIcon = MaterialDesign[icon]; | ||
// const size_ = props.size; | ||
// console.log(size_); | ||
// console.log({ mdIcon }); | ||
// return ( | ||
// <Container> | ||
// <IconContext_.Provider value={{ color: "11999e", size: size_ }}> | ||
// <Row>{React.createElement(mdIcon)}</Row> | ||
// </IconContext_.Provider> | ||
// <Row> | ||
// <h4 className="title">{header}</h4> | ||
// </Row> | ||
// <Row className="hide"> | ||
// <p className="body p">{description}</p> | ||
// </Row> | ||
// </Container> | ||
// ); | ||
// } | ||
|
||
// export default Favourites_card; |
Oops, something went wrong.