Skip to content

Commit

Permalink
Merge pull request #231 from GTBitsOfGood/ash/208-fontAdjustments
Browse files Browse the repository at this point in the history
Ash/208 font adjustments
  • Loading branch information
avayedawadi authored Oct 31, 2023
2 parents d7fa20c + 2a63e10 commit c06a913
Show file tree
Hide file tree
Showing 37 changed files with 280 additions and 71 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@
"react-icons": "^4.7.1",
"react-rating-stars-component": "^2.2.0",
"swr": "^2.0.3",
"typeface-inter": "^3.18.1",
"xlsx": "^0.18.5"
},
"devDependencies": {
Expand Down
Binary file added public/fonts/europa-bold-webfont.woff2
Binary file not shown.
Binary file added public/fonts/europa-light-webfont.woff2
Binary file not shown.
Binary file added public/fonts/europa-regular-webfont.woff2
Binary file not shown.
9 changes: 8 additions & 1 deletion src/components/AddStandard/AddStandardForm.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,14 @@ const AddStandardForm = () => {
{({ handleSubmit, values }) => (
<Box p={14} pb={14} w="full" as="form" onSubmit={handleSubmit}>
<HStack>
<Heading as="h1" size="xl" color="Grey" textAlign="left" my={2}>
<Heading
as="h1"
size="xl"
color="#515254"
textAlign="left"
my={2}
fontFamily="Roboto Slab"
>
Add a New Standard
</Heading>

Expand Down
3 changes: 2 additions & 1 deletion src/components/AddStandard/CreateTag.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ const CreateTag = () => {
<Box mb={4}>
<FormLabel
fontSize="xl"
color="#8C8C8C"
color="#51524"
fontFamily="'Europa-Bold', sans-serif"
fontWeight="bold"
textAlign="left"
mb={1}
Expand Down
9 changes: 5 additions & 4 deletions src/components/AddStandard/EditAddStandard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,15 @@ const EditAddStandard = ({ handleSubmit }) => {
capitalizeAndRemoveDash(buildingType.name)
);
return (
<Box>
<Box fontFamily="'Europa-Regular', sans-serif">
<Box w="50%">
<MassUpload name="massUpload" />

<FormLabel
fontSize="xl"
fontSize="2xl"
fontWeight="bold"
color="#8C8C8C"
fontFamily="'Europa-Bold', sans-serif"
color="#515254"
mb={1}
mt={5}
>
Expand Down Expand Up @@ -76,7 +77,7 @@ const EditAddStandard = ({ handleSubmit }) => {
/>
</Box>

<FormLabel fontSize="xl" fontWeight="bold" color="#8C8C8C" mb={1} mt={5}>
<FormLabel fontSize="xl" fontWeight="bold" color="#515254" mb={1} mt={5}>
Tags
</FormLabel>

Expand Down
8 changes: 7 additions & 1 deletion src/components/ArchivedReportView/ArchivedReportView.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,13 @@ const ArchivedReportView = () => {
console.log(archivedReports);
return (
<>
<Heading fontSize="1.5em">Completed Reports</Heading>
<Heading
fontSize="1.5em"
fontFamily="'Roboto Slab'
, serif"
>
Completed Reports
</Heading>
{user?.isLoggedIn && (
<Link
href="/archived-reports"
Expand Down
26 changes: 15 additions & 11 deletions src/components/CategoryCards/CategoryCards.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,21 @@ import CategoryCard from "./CategoryCard";
function CategoryCards(props) {
return (
<>
{Object.keys(primaryCategoryNames).sort((a, b) => primaryCategoryNames[a].localeCompare(primaryCategoryNames[b])).map((categoryInitials) => {
const name = primaryCategoryNames[categoryInitials].trim();
return (
<CategoryCard
routerQuery={props.routerQuery}
initials={categoryInitials}
title={name}
key={name}
/>
);
})}
{Object.keys(primaryCategoryNames)
.sort((a, b) =>
primaryCategoryNames[a].localeCompare(primaryCategoryNames[b])
)
.map((categoryInitials) => {
const name = primaryCategoryNames[categoryInitials].trim();
return (
<CategoryCard
routerQuery={props.routerQuery}
initials={categoryInitials}
title={name}
key={name}
/>
);
})}
</>
);
}
Expand Down
6 changes: 5 additions & 1 deletion src/components/FormComponents/Error.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,11 @@ const Error = ({ name }) => {
const {
meta: { error },
} = useField(name, { subscription: { error: true } });
return <FormErrorMessage>{error}</FormErrorMessage>;
return (
<FormErrorMessage fontFamily="'Europa-Regular', sans-serif">
{error}
</FormErrorMessage>
);
};

export default Error;
8 changes: 7 additions & 1 deletion src/components/FormComponents/InputControl.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,12 @@ const InputControl = ({ name, label, type, ...props }) => {
return (
<Control name={name}>
<HStack>
<FormLabel htmlFor={name} m={0} color="Grey">
<FormLabel
htmlFor={name}
m={0}
color="Grey"
fontFamily="'Europa-Regular', sans-serif"
>
{label}
</FormLabel>
<Error name={name} />
Expand All @@ -20,6 +25,7 @@ const InputControl = ({ name, label, type, ...props }) => {
isInvalid={meta.error && meta.touched}
id={name}
type={type}
fontFamily="'Europa-Regular', sans-serif"
/>
</Control>
);
Expand Down
3 changes: 2 additions & 1 deletion src/components/FormComponents/Multiselect.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ const Multiselect = ({ name, label, entries }) => {
m={0}
fontSize="xl"
fontWeight="bold"
color="#8C8C8C"
fontFamily="'Europa-Bold', sans-serif"
color="#515254"
>
{label}
</FormLabel>
Expand Down
15 changes: 13 additions & 2 deletions src/components/FormComponents/TextareaControl.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,23 @@ const AdaptedTextarea = ({ input, meta, ...rest }) => (
const TextareaControl = ({ name, label, ...props }) => (
<Control name={name}>
<HStack>
<FormLabel htmlFor={name} m={0} color="Grey">
<FormLabel
htmlFor={name}
m={0}
color="Grey"
fontFamily="'Europa-Regular', sans-serif"
>
{label}
</FormLabel>
<Error name={name} />
</HStack>
<Field name={name} component={AdaptedTextarea} id={name} {...props} />
<Field
name={name}
component={AdaptedTextarea}
id={name}
fontFamily="'Europa-Regular', sans-serif"
{...props}
/>
</Control>
);

Expand Down
18 changes: 15 additions & 3 deletions src/components/Login/LoginComponent/LoginComponent.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,14 @@ const LoginComponent = () => {
};

return (
<Flex direction="column" height="65%" width="60%" gap="1em">
<Text fontSize="3xl" as="b">
<Flex
direction="column"
height="65%"
width="60%"
gap="1em"
fontFamily="Europa-Regular"
>
<Text fontSize="3xl" as="b" fontFamily="Roboto Slab">
Login
</Text>
<Box>
Expand All @@ -46,7 +52,13 @@ const LoginComponent = () => {
/>
</FormControl>
</Box>
<Button width="100%" height="2.3em" variant="Blue" onClick={handleSubmit}>
<Button
width="100%"
height="2.3em"
variant="Blue"
onClick={handleSubmit}
fontFamily="Europa-Bold"
>
Log In
</Button>
{/* <Center gap="0.3em">
Expand Down
10 changes: 8 additions & 2 deletions src/components/Modals/BuildingTypeModal/BuildingTypeModal.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,15 @@ const BuildingTypeModal = ({ isOpen, onClose }) => {
size={{ base: "xs", md: "2xl", lg: "4xl" }}
>
<ModalOverlay />
<ModalContent rounded={14}>
<ModalContent rounded={14} fontFamily="Europa-Regular">
<ModalCloseButton right={2} top={0} m={4} />
<ModalHeader mt={8} mx={6} fontSize="4xl" color="#6D6E70">
<ModalHeader
mt={8}
mx={6}
fontSize="4xl"
color="#6D6E70"
fontFamily="Roboto Slab"
>
Add A New Building Type
</ModalHeader>
<Form
Expand Down
11 changes: 9 additions & 2 deletions src/components/Modals/CardModal/CardModal.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ const CardModal = ({
size={{ base: "xs", md: "2xl", lg: "4xl" }}
>
<ModalOverlay />
<ModalContent rounded={14}>
<ModalContent rounded={14} fontFamily="'Europa-Regular', sans-serif">
<ModalCloseButton right={2} top={0} m={4} />
<ModalHeader mt={10} mx={6}>
<Flex
Expand All @@ -266,7 +266,9 @@ const CardModal = ({
{editing ? (
<InputControl name="title" size="lg"></InputControl>
) : (
<Heading mb={2}>{card.title}</Heading>
<Heading mb={2} fontFamily="'Roboto Slab', serif" color="#515254">
{card.title}
</Heading>
)}
{user?.isAdmin ? (
!editing ? (
Expand Down Expand Up @@ -296,6 +298,7 @@ const CardModal = ({
whiteSpace="nowrap"
width="auto"
onClick={onDiscardChangesOpen}
fontFamily="Europa-Bold"
>
Discard Changes
</Button>
Expand All @@ -310,6 +313,7 @@ const CardModal = ({
_active={{ bgColor: "#057b8f" }}
onClick={onSaveChangesOpen}
isDisabled={form.hasValidationErrors}
fontFamily="Europa-Bold"
>
Save Changes
</Button>
Expand Down Expand Up @@ -604,6 +608,7 @@ const CardModal = ({
variant="Red"
size="lg"
onClick={onDeleteStandardOpen}
fontFamily="Europa-Bold"
>
Delete Standard
</Button>
Expand All @@ -616,6 +621,7 @@ const CardModal = ({
setSelectedImage(0);
openImagePreviewCallback();
}}
fontFamily="Europa-Bold"
>
View Notes
</Button>
Expand All @@ -624,6 +630,7 @@ const CardModal = ({
variant="Blue-rounded"
size="lg"
isDisabled={user?.isLoggedIn ? false : true}
fontFamily="Europa-Bold"
>
{!selected
? "Add to Report"
Expand Down
4 changes: 3 additions & 1 deletion src/components/Modals/CardModal/ConfirmActionModal.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ const ConfirmActionModal = ({
return (
<Modal isOpen={isOpen} onClose={onClose} isCentered={true}>
<ModalOverlay />
<ModalContent rounded={14}>
<ModalContent rounded={14} fontFamily="Europa-Regular">
<ModalHeader
pt={10}
display="flex"
Expand Down Expand Up @@ -81,6 +81,7 @@ const ConfirmActionModal = ({
fontSize="md"
width="auto"
onClick={onClose}
fontFamily="Europa-Bold"
>
{abandonActionText}
</Button>
Expand All @@ -91,6 +92,7 @@ const ConfirmActionModal = ({
fontSize="md"
width="auto"
onClick={handleAction}
fontFamily="Europa-Bold"
>
{confirmActionText}
</Button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ const ConfirmActionModal = ({
{...rest}
>
<ModalOverlay />
<ModalContent rounded={14} display="flex">
<ModalContent rounded={14} display="flex" fontFamily="Europa-Regular">
<ModalHeader
pt={10}
display="flex"
Expand Down Expand Up @@ -65,6 +65,8 @@ const ConfirmActionModal = ({
size="sm"
fontSize="md"
width="auto"
fontWeight="700"
fontFamily="Europa-Bold"
onClick={handleCancelAction ? handleCancelAction : onClose}
>
{cancelButtonText}
Expand All @@ -74,6 +76,8 @@ const ConfirmActionModal = ({
size="sm"
fontSize="md"
width="auto"
fontWeight="700"
fontFamily="Europa-Bold"
onClick={handleAction}
>
{confirmButtonText}
Expand Down
Loading

1 comment on commit c06a913

@github-actions
Copy link

Choose a reason for hiding this comment

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

Deploy preview for southface ready!

✅ Preview
https://southface-n0d4qp7th-bitsofgood.vercel.app

Built with commit c06a913.
This pull request is being automatically deployed with vercel-action

Please sign in to comment.