Skip to content

Commit

Permalink
added styles
Browse files Browse the repository at this point in the history
  • Loading branch information
Rouncer27 committed Jun 12, 2023
1 parent 1772fcd commit 976dbd4
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 1 deletion.
25 changes: 24 additions & 1 deletion src/components/shared/formParts/InputNumber.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,11 @@ const InputNumber = ({
required,
handleNumberUp,
handleNumberDown,
color,
}) => {
console.log("color", color)
return (
<InputFieldStyled size={size} position={position}>
<InputFieldStyled size={size} position={position} color={color}>
<label htmlFor={nameId}>
<button
type="button"
Expand Down Expand Up @@ -51,6 +53,7 @@ const InputNumber = ({
>
&#8722;
</button>
<span className="color-mark" />
<span className="main-label">
{title} <span className="required">&#42;</span>
</span>
Expand Down Expand Up @@ -99,6 +102,26 @@ const InputFieldStyled = styled.div`
width: 100%;
line-height: 1.5;
.color-mark {
display: inline-block;
width: 2.5rem;
height: 2.5rem;
margin-left: 2.5rem;
border-radius: 50%;
background-color: ${props =>
props.color === "yellow"
? colors.colorAccent
: props.color === "orange"
? colors.colorTertiary
: props.color === "blue"
? colors.colorShad
: props.color === "green"
? colors.colorShad2
: props.color === "red"
? colors.colorPrimary
: colors.colorPrimary};
}
.main-label {
padding-left: 2.5rem;
}
Expand Down
3 changes: 3 additions & 0 deletions src/components/templates/contact/ContactForm.js
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,7 @@ const ContactForm = ({ data }) => {
type="number"
nameId={flavSlug}
required={false}
color={flav.colour}
/>
)
})}
Expand Down Expand Up @@ -286,6 +287,8 @@ const StyledDiv = styled.div`
`

const SubmitButton = styled.div`
margin-top: 5rem;
p {
${B1White};
}
Expand Down

0 comments on commit 976dbd4

Please sign in to comment.