Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update hs form from summer to fall #97

Merged
merged 3 commits into from
Jul 27, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,12 @@ const color = require('cli-color');

const { validateData } = require('./data/validate');

const { OVERRIDE_NODE_ENV = '', FB_PIXEL_ID, HIGHSCHOOL_FORM_ACTIVE = 'false' } = process.env;
const {
OVERRIDE_NODE_ENV = '',
FB_PIXEL_ID,
HIGHSCHOOL_FORM_ACTIVE = 'false',
HIGHSCHOOL_FORM_RESPONSES_NAME = '__TAB_NAME_NOT_SET__',
} = process.env;

const isHsFormActive = HIGHSCHOOL_FORM_ACTIVE?.toLowerCase() === 'true';

Expand All @@ -24,6 +29,7 @@ module.exports = (phase, { defaultConfig }) => {
'WUFOO_TOKEN',
'WUFOO_CONTACT_FORM_ID',
'GOOGLE_EVENTS_CALENDAR_ID',
'HIGHSCHOOL_FORM_RESPONSES_NAME',
]);
validateData();
}
Expand All @@ -43,6 +49,7 @@ module.exports = (phase, { defaultConfig }) => {
OVERRIDE_NODE_ENV,
FB_PIXEL_ID,
HIGHSCHOOL_FORM_ACTIVE: isHsFormActive,
HIGHSCHOOL_FORM_RESPONSES_NAME,
},
async redirects() {
return [
Expand Down
30 changes: 15 additions & 15 deletions pages/programs/highschool/apply.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,21 +54,22 @@ const HighschoolSignup: NextPage<HighschoolSignupProps> = ({ courses }) => {
>
<div className='program-header'>
<div className='header-card'>
<h1 className='dynamic-xl secondary'>Summer 2023</h1>
<h2 className='dynamic-h2 secondary'>Coding Camp Application</h2>
<h1 className='dynamic-xl secondary'>Fall 2023</h1>
<h2 className='dynamic-h2 secondary'>After-School Application</h2>
<p className='dynamic-txt'>
Open to rising sophomores through graduating seniors
<b> (Graduating classes of 2023, 2024, 2025, and 2026)</b>.
</p>
<p className='dynamic-txt'>
{/* Common meeting time */}
{/* <p className='dynamic-txt'>
Classes meet <b className='secondary'> three hours</b> a day,
<b className='secondary'> Monday</b> through <b className='secondary'>Friday</b>.
</p>
</p> */}
<p className='dynamic-txt'>
Summer classes start
<b className='secondary'> June 1st </b>
and end on
<b className='secondary'> June 30th</b>.
Fall classes start the week of
<b className='secondary'> August 21st </b>
and end the week of
<b className='secondary'> December 11th</b>.
</p>
</div>
<Link href='/programs/highschool' passHref>
Expand All @@ -87,7 +88,7 @@ const HighschoolSignup: NextPage<HighschoolSignupProps> = ({ courses }) => {
<div className='left-col'>
<div className='hs-program-overview'>
<p>
{`This summer, we are offering both in-person and virtual classes. You can enroll in one or the other- there is no hybrid option. If you're able to arrange for reliable transportation to our learning center in the Marigny, we recommend in-person classes. We have a great lab with brand new equipment and an awesome staff to get you started on your coding journey. You'll also meet other students from a wide range of schools and backgrounds!`}
{`This fall, we are offering both in-person and virtual classes. You can enroll in one or the other- there is no hybrid option. If you're able to arrange for reliable transportation to our learning center in the Marigny, we recommend in-person classes. We have a great lab with brand new equipment and an awesome staff to get you started on your coding journey. You'll also meet other students from a wide range of schools and backgrounds!`}
</p>
<br />

Expand All @@ -101,10 +102,10 @@ const HighschoolSignup: NextPage<HighschoolSignupProps> = ({ courses }) => {
<div className='reqs-list'>
<b>For virtual classes, you will need:</b>
<ul>
<li>laptop/desktop computer (Mac, Windows, or Chromebook)</li>
<li>webcam and mic </li>
<li>reliable internet connection </li>
<li>quiet place to work</li>
<li>Laptop/desktop computer (Mac, Windows, or Chromebook)</li>
<li>Webcam and mic</li>
<li>Reliable internet connection </li>
<li>Quiet place to work</li>
</ul>
</div>
</div>
Expand Down Expand Up @@ -200,8 +201,7 @@ const HighschoolSignup: NextPage<HighschoolSignupProps> = ({ courses }) => {
</div>
<PlainCard noDivider={true}>
<p>
Within 3 business days of completing this form, you will receive more detailed
information about the course and next steps to finalize enrollment.
{`Within 3 business days of completing this form, you will receive more detailed information about the course and next steps to finalize enrollment.`}
</p>
<br />
<p>
Expand Down
5 changes: 3 additions & 2 deletions src/Forms/Form.HighschoolApplication.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ import {
referencedByOptions,
} from './formData/highSchoolApplicationData';

const sheetsTabName = process.env.HIGHSCHOOL_FORM_RESPONSES_NAME;

const getSelectedCourseTimes = (selected: string): { options: TOption[]; note: string } | null => {
if (selected === 'fundamentals') {
return { options: courseTimes.fundamentals, note: courseTimes.notes.fundamentals };
Expand All @@ -35,7 +37,6 @@ interface HighSchoolApplicationProps {
}

const HighSchoolApplication = ({ onSubmitComplete }: HighSchoolApplicationProps) => {
const sheetsTabName = 'Applications - Summer 2023';
const form = useForm();
const [isSubmitting, setIsSubmitting] = useState(false);
const hasErrors = form.hasErrors();
Expand All @@ -61,7 +62,7 @@ const HighSchoolApplication = ({ onSubmitComplete }: HighSchoolApplicationProps)
tabName: sheetsTabName,
date: Date.now(),
});
form.clear();
// form.clear();
ptbarnum4 marked this conversation as resolved.
Show resolved Hide resolved
form.notifySuccess();
onSubmitComplete?.();
} catch {
Expand Down
24 changes: 12 additions & 12 deletions src/Forms/formData/highSchoolApplicationData.ts
Original file line number Diff line number Diff line change
Expand Up @@ -166,37 +166,37 @@ export const courseTimes = {
fundamentals: [
{
course: 'fundamentals',
value: 'fundamentals-onsite-m-f-9-12',
value: 'fundamentals-onsite-w-4-8',
location: 'In Person',
preReq: 'No Prerequisite',
time: 'Monday - Friday, 9:00am - 12:00pm',
name: 'In Person: Monday - Friday, 9:00am - 12:00pm',
time: 'Wednesdays | 4:45pm - 8:00pm',
name: 'In Person: Wednesdays | 4:45pm - 8:00pm',
},
{
course: 'fundamentals',
value: 'fundamentals-virtual-m-f-1-4',
value: 'fundamentals-virtual-t-th-5-7',
location: 'Virtual',
preReq: 'No Prerequisite',
time: 'Monday - Friday, 1:00pm - 4:00pm',
name: 'Virtual: Monday - Friday, 1:00pm - 4:00pm',
time: 'Tuesdays + Thursdays | 5:00pm - 7:00pm',
name: 'Virtual: Tuesdays + Thursdays | 5:00pm - 7:00pm',
},
],
advanced: [
{
course: 'advanced',
value: 'advanced-virtual-m-f-9-12',
value: 'advanced-virtual-th-4-8',
location: 'Virtual',
preReq: 'Fundamentals of HTML, CSS, and Javascript',
time: 'Monday - Friday, 9:00am - 12:00pm',
name: 'Virtual: Monday - Friday, 9:00am - 12:00pm',
time: 'Thursdays | 4:45pm - 8:00pm',
name: 'Virtual: Thursdays | 4:45pm - 8:00pm',
},
{
course: 'advanced',
value: 'advanced-onsite-m-f-1-4',
value: 'advanced-onsite-t-th-5-7',
location: 'In Person',
preReq: 'Fundamentals of HTML, CSS, and Javascript',
time: 'Monday - Friday, 1:00pm - 4:00pm',
name: 'In Person: Monday - Friday, 1:00pm - 4:00pm',
time: 'Tuesdays + Thursdays | 5:00pm - 7:00pm',
name: 'In Person: Tuesdays + Thursdays | 5:00pm - 7:00pm',
},
],
};
Expand Down
Loading