-
Notifications
You must be signed in to change notification settings - Fork 5
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
Link to teacher emails from teacher features #1231
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1231 +/- ##
=======================================
Coverage 36.63% 36.63%
=======================================
Files 447 447
Lines 19666 19666
Branches 6475 6475
=======================================
Hits 7205 7205
Misses 11816 11816
Partials 645 645 ☔ View full report in Codecov by Sentry. 🚨 Try these New Features:
|
<IsaacCard doc={{ clickUrl: "/pages/isaac_embedded_schools", | ||
image: {src: "/assets/phy/icons/teacher_features_sprite.svg#groups"}, | ||
title: "Teacher Ambassadors", | ||
<IsaacCard doc={{ clickUrl: isTeacherOrAbove(user) ? "/teacher_emails" : "/pages/contact_us_teacher", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Jacob is right, you don't need the conditional here. But only because there's an easier way to implement the route that will give you the conditional redirect for free.
@@ -138,6 +139,7 @@ export const RoutesPhy = [ | |||
<StaticPageRoute key={key++} exact path="/alevel" pageId="alevel" />, | |||
<TrackedRoute key={key++} exact path="/teacher_features" component={TeacherFeatures}/>, | |||
<TrackedRoute key={key++} exact path="/tutor_features" component={TutorFeatures}/>, | |||
<TrackedRoute key={key++} exact path="/teacher_emails" component={TeacherEmails}/>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of making a new component and making a new route like this, you could instead add it to the Teacher Pages
bit below using <StaticPageRoute>
like the mentoring pages.
I would also like it if we could force the fragment ID to be teacher_emails_frag
so that it is more unique. Then the pageId
you need for the route would be fragments/teacher_emails_frag
.
No description provided.