Skip to content

Minor fixes #304

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
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
11 changes: 1 addition & 10 deletions frontend/components/Course/CourseSidebarNav.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { useContext } from "react";
import { Segment, Menu, Image, Icon, Label } from "semantic-ui-react";
import { Segment, Menu, Image, Icon } from "semantic-ui-react";
import { useRouter } from "next/router";
import Link from "next/link";

Expand Down Expand Up @@ -90,15 +90,6 @@ const CourseSidebarNav = (props: CourseSidebarProps) => {
}}
/>
Analytics
<Label
color="violet"
content="Beta"
size="tiny"
style={{
float: "none",
verticalAlign: "bottom",
}}
/>
</Menu.Item>
</Link>
)}
Expand Down
9 changes: 5 additions & 4 deletions frontend/components/Guide/InstructorGuide.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import {
HoldOfficeHours,
Analytics,
Settings,
Feedback,
} from "./InstructorGuideContent";
import { useSection } from "./utils";

Expand All @@ -32,6 +33,8 @@ export default function InstructorGuide() {

const [SettingsHeader, SettingsBody] = useSection("Settings", Settings);

const [FeedbackHeader, FeedbackBody] = useSection("Feedback", Feedback);

return (
<>
<Segment basic>
Expand All @@ -43,6 +46,7 @@ export default function InstructorGuide() {
<HoldOHHeader />
<AnalyticsHeader />
<SettingsHeader />
<FeedbackHeader />
</List>
</Segment>

Expand All @@ -52,10 +56,7 @@ export default function InstructorGuide() {
<HoldOHBody />
<AnalyticsBody />
<SettingsBody />
<p>
Have any lingering questions? Please email us at [email protected]
- we&apos;re happy to help!
</p>
<FeedbackBody />
</>
);
}
20 changes: 20 additions & 0 deletions frontend/components/Guide/InstructorGuideContent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -292,3 +292,23 @@ export const Settings = ({ ref }) => (
</Segment>
</div>
);

export const Feedback = ({ ref }) => (
<div ref={ref}>
<Segment basic>
<h3>Feedback</h3>
<Divider />
<p>
Have any lingering questions? Please email us at [email protected]
or fill out{" "}
<a
href="https://airtable.com/appFRa4NQvNMEbWsA/shrX0oFscDxpo1TnF"
rel="noopener"
>
this feedback form
</a>{" "}
- we&apos;re happy to help!
</p>
</Segment>
</div>
);
9 changes: 5 additions & 4 deletions frontend/components/Guide/StudentGuide.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import {
JoiningOfficeHours,
WhileInQueue,
Settings,
Feedback,
} from "./StudentGuideContent";
import { useSection } from "./utils";

Expand All @@ -27,6 +28,8 @@ export default function StudentGuide() {
WhileInQueue
);
const [SettingsHeader, SettingsBody] = useSection("Settings", Settings);
const [FeedbackHeader, FeedbackBody] = useSection("Feedback", Feedback);

return (
<>
<Segment basic>
Expand All @@ -37,6 +40,7 @@ export default function StudentGuide() {
<JoiningOHHeader />
<WhileInQueueHeader />
<SettingsHeader />
<FeedbackHeader />
</List>
</Segment>

Expand All @@ -45,10 +49,7 @@ export default function StudentGuide() {
<JoiningOHBody />
<WhileInQueueBody />
<SettingsBody />
<p>
Have any lingering questions? Please email us at [email protected]
- we&apos;re happy to help!
</p>
<FeedbackBody />
</>
);
}
22 changes: 21 additions & 1 deletion frontend/components/Guide/StudentGuideContent.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Segment, List } from "semantic-ui-react";
import { Segment, List, Divider } from "semantic-ui-react";

import { CenteredImage } from "./utils";

Expand Down Expand Up @@ -163,3 +163,23 @@ export const Settings = ({ ref }) => (
</Segment>
</div>
);

export const Feedback = ({ ref }) => (
<div ref={ref}>
<Segment basic>
<h3>Feedback</h3>
<Divider />
<p>
Have any lingering questions? Please email us at [email protected]
or fill out{" "}
<a
href="https://airtable.com/appFRa4NQvNMEbWsA/shrX0oFscDxpo1TnF"
rel="noopener"
>
this feedback form
</a>{" "}
- we&apos;re happy to help!
</p>
</Segment>
</div>
);
7 changes: 5 additions & 2 deletions frontend/components/Home/Dashboard/Dashboard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,15 @@ import { useContext, useState, useEffect } from "react";
import { Grid, Header, Segment, Message } from "semantic-ui-react";
import Alert from "@material-ui/lab/Alert";
import Snackbar from "@material-ui/core/Snackbar";
import { useMediaQuery } from "@material-ui/core";
import InstructorCourses from "./InstructorCourses";
import StudentCourses from "./StudentCourses";
import Footer from "../../common/Footer";
import { AuthUserContext } from "../../../context/auth";
import { Kind, UserMembership } from "../../../types";
import { useMemberships } from "../../../hooks/data-fetching/dashboard";
import { isLeadershipRole } from "../../../utils/enums";
import { CHANGELOG_TOKEN } from "../../../constants";
import { CHANGELOG_TOKEN, MOBILE_BP } from "../../../constants";
import ModalShowNewChanges from "./Modals/ModalShowNewChanges";
import updatedMd from "../../Changelog/changelogfile.md";
import tips from "./tips.json";
Expand Down Expand Up @@ -55,6 +56,8 @@ const Dashboard = () => {

const [tipDisp, setTipDisp] = useState(false);

const isMobile = useMediaQuery(`(max-width: ${MOBILE_BP})`);

const getTip = () => {
const filteredTips = canCreateCourse
? tips
Expand Down Expand Up @@ -89,7 +92,7 @@ const Dashboard = () => {
<Header as="h2">Student Courses</Header>
</Segment>
</Segment>
{tipDisp && (
{tipDisp && !isMobile && (
<div
style={{
position: "absolute",
Expand Down
2 changes: 1 addition & 1 deletion frontend/pages/courses/[course]/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const QueuePage = (props: QueuePageProps) => {
url="/api/ws/subscribe/"
findOrigin={
process.env.NODE_ENV === "development"
? () => "ws://localhost:8000"
? () => "ws://127.0.0.1:8000"
: undefined
}
>
Expand Down