Skip to content

Commit

Permalink
Merge pull request #2359 from gordon-cs/develop
Browse files Browse the repository at this point in the history
Release: small fixes and improvements
  • Loading branch information
russtuck authored Jul 11, 2024
2 parents c39147d + e429082 commit a963483
Show file tree
Hide file tree
Showing 8 changed files with 161 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ const SocialMediaLinks = ({ profile, createSnackbar, myProf }) => {
className={styles.gc360_my_profile_edit_icon}
onClick={() => setSocialLinksOpen(true)}
size="large"
aria-label="Update social media links"
>
<EditIcon />
</IconButton>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,12 @@ const UpdatePhone = () => {

return (
<div>
<IconButton className={styles.edit_button} onClick={() => setOpen(true)} size="large">
<IconButton
className={styles.edit_button}
onClick={() => setOpen(true)}
size="large"
aria-label="Update mobile phone number"
>
<EditIcon fontSize="small" />
</IconButton>
<GordonDialogBox
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,12 @@ const UpdatePlannedGraduationYear = (props) => {

return (
<div>
<IconButton style={{ marginBottom: '0.5rem' }} onClick={() => setOpen(true)} size="large">
<IconButton
style={{ marginBottom: '0.5rem' }}
onClick={() => setOpen(true)}
size="large"
aria-label="Update planned graduation year"
>
<EditIcon style={{ fontSize: 20 }} />
</IconButton>
<GordonDialogBox
Expand Down
6 changes: 5 additions & 1 deletion src/views/About/contributors.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,10 @@
},
{
"title": "Summer Practicum, 2023",
"body": "Jack Hammond, Arabella Ji '24, Matt Jones '25, Gideon Kim '24, Jae Min Lee '24, Eric Mo '24, Antônia Vontobel '25, Andrew Wang '24 (Directors: Jonathan Senning, Ph.D. '85 and Russ Tuck, Ph.D.; Additional code reviews and mentoring: Evan Platzer '20, Amos Cha '23, and Bennett Forkner)"
"body": "Andrew Wang '24, Antônia Vontobel '25, Arabella Ji '24, Eric Mo '24, Gideon Kim '24, Jack Hammond, Jae Min Lee '24, Matt Jones '25 (Directors: Jonathan Senning, Ph.D. '85 and Russ Tuck, Ph.D.; Additional code reviews and mentoring: Evan Platzer '20, Amos Cha '23, and Bennett Forkner)"
},
{
"title": "Summer Practicum, 2024",
"body": "Collin Williams '26, Danya Li '25, Hunter Simpson '26, Isaiah Diaz '26, Luke Hart '25, Tsion Tezera '26, Yushin Jo '26 (Directors: Jonathan Senning, Ph.D. '85 and Russ Tuck, Ph.D.; Additional code reviews and mentoring: Evan Platzer '20 and Amos Cha '23)"
}
]
99 changes: 90 additions & 9 deletions src/views/Events/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import {
Select,
TextField,
} from '@mui/material';
import { HashLink } from 'react-router-hash-link';
import AddIcon from '@mui/icons-material/Add';
import EventIcon from '@mui/icons-material/Event';
import FilterListIcon from '@mui/icons-material/FilterList';
Expand All @@ -38,7 +39,7 @@ const Events = () => {
const [includePast, setIncludePast] = useState(false);
const [loading, setLoading] = useState(true);
const [filters, setFilters] = useState([]);
const [timeFilter, setTimeFilter] = useState('');
const [timeFilter, setTimeFilter] = useState('2 Weeks');
const [hasInitializedEvents, setHasInitializedEvents] = useState(false);
const futureEvents = useMemo(() => gordonEvent.getFutureEvents(allEvents), [allEvents]);
const [width] = useWindowSize();
Expand Down Expand Up @@ -145,11 +146,57 @@ const Events = () => {
</div>
);

let filterReminder;

if (timeFilter != '') {
filterReminder = (
<>
<div align="center">
Your search is limited to {timeFilter}. Check out the top of the page if you want to
change your filters.
</div>
<div align="center">
<Button
variant="contained"
color="secondary"
component={HashLink}
to="#top"
smooth
id="bottom"
>
Jump to Top
</Button>
</div>
</>
);
} else {
filterReminder = (
<>
<div align="center">
You have reached the end of Gordon's events. Check out the top of the page if you want to
add filters.
</div>
<div align="center">
<Button
variant="contained"
color="secondary"
component={HashLink}
to="#top"
smooth
id="bottom"
>
Jump to Top
</Button>
</div>
</>
);
}

if (width >= 920) {
return (
<Grid container justifyContent="center" spacing={6}>
<Grid item xs={12} lg={10} xl={8}>
<CardHeader title={searchPageTitle} className="gc360_header" />
<CardHeader title={searchPageTitle} className="gc360_header" id="top" />
<Card style={{ padding: '0 3vw' }}>
<CardContent>
{/* Search Bar and Filters */}
Expand Down Expand Up @@ -230,14 +277,18 @@ const Events = () => {
}
value={filters}
renderInput={(param) => (
<TextField {...param} variant="filled" label="Filters" />
<TextField {...param} variant="filled" label="Event Type" />
)}
/>
</Grid>
<Grid container item xs={3.25}>
<FormControlLabel
control={
<Checkbox checked={includePast} onChange={handleChangeIncludePast} />
<Checkbox
checked={includePast}
onChange={handleChangeIncludePast}
color="secondary"
/>
}
label="Include Past"
/>
Expand All @@ -249,7 +300,7 @@ const Events = () => {

<Grid item xs={8}>
<FormControl fullWidth variant="filled">
<InputLabel id="event-time">Time Filters</InputLabel>
<InputLabel id="event-time">Time Window</InputLabel>
<Select
labelId="event-time"
id="even-time"
Expand All @@ -269,6 +320,18 @@ const Events = () => {
</Grid>
</Grid>
</Collapse>
<Grid item container marginTop={2} justifyContent="center" alignItems="center">
<Button
variant="contained"
color="secondary"
component={HashLink}
to="#bottom"
smooth
id="top"
>
Jump to Bottom
</Button>
</Grid>
</Grid>
</Grid>
</CardContent>
Expand All @@ -280,14 +343,15 @@ const Events = () => {
<Grid item xs={12}>
{content}
</Grid>
<CardHeader item xs={12} className="gc360_header" title={filterReminder} id="bottom" />
</Grid>
</Grid>
);
} else if (width < 920) {
return (
<Grid container justifyContent="center" spacing={6}>
<Grid item xs={12} lg={10} xl={8}>
<CardHeader title={searchPageTitle} className="gc360_header" />
<CardHeader title={searchPageTitle} className="gc360_header" id="top" />
<Card style={{ padding: '0 3vw' }}>
<CardContent>
{/* Search Bar and Filters */}
Expand Down Expand Up @@ -354,7 +418,11 @@ const Events = () => {
<Grid container item justifyContent="center">
<FormControlLabel
control={
<Checkbox checked={includePast} onChange={handleChangeIncludePast} />
<Checkbox
checked={includePast}
onChange={handleChangeIncludePast}
color="secondary"
/>
}
label="Include Past"
/>
Expand All @@ -381,7 +449,7 @@ const Events = () => {
))
}
renderInput={(param) => (
<TextField {...param} variant="filled" label="Filters" />
<TextField {...param} variant="filled" label="Event Type" />
)}
/>
</Grid>
Expand All @@ -392,7 +460,7 @@ const Events = () => {
)}
<Grid item xs={11}>
<FormControl fullWidth variant="filled">
<InputLabel id="event-time">Time Filters</InputLabel>
<InputLabel id="event-time">Time Window</InputLabel>
<Select
labelId="event-time"
id="even-time"
Expand All @@ -412,6 +480,18 @@ const Events = () => {
</Grid>
</Grid>
</Collapse>
<Grid item container marginTop={2} justifyContent="center" alignItems="center">
<Button
variant="contained"
color="secondary"
component={HashLink}
to="#bottom"
smooth
id="top"
>
Jump to Bottom
</Button>
</Grid>
</Grid>
</CardContent>
</Card>
Expand All @@ -420,6 +500,7 @@ const Events = () => {
<Grid item xs={12}>
{content}
</Grid>
<CardHeader item xs={12} className="gc360_header" title={filterReminder} />
</Grid>
</Grid>
);
Expand Down
49 changes: 49 additions & 0 deletions src/views/Help/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ const Help = () => {
<Card className={styles.help}>
<CardHeader
className={styles.help_title}
id="jump-to"
title="Jump To:"
titleTypographyProps={{ variant: 'h4' }}
/>
Expand Down Expand Up @@ -164,6 +165,14 @@ const Help = () => {
, or the Registrar.
</li>
</Typography>
<Link
className={`gc360_text_link`}
style={{ padding: '0 1.5vw', display: 'block', marginTop: '10px' }}
to="#jump-to"
smooth
>
Return to Top of Page
</Link>
</CardContent>
</Card>

Expand Down Expand Up @@ -205,6 +214,14 @@ const Help = () => {
Involvements.
</li>
</Typography>
<Link
className={`gc360_text_link`}
style={{ padding: '0 1.5vw', display: 'block', marginTop: '10px' }}
to="#jump-to"
smooth
>
Return to Top of Page
</Link>
</CardContent>
</Card>

Expand Down Expand Up @@ -251,6 +268,14 @@ const Help = () => {
will fill where there is no Image loaded.
</li>
</Typography>
<Link
className={`gc360_text_link`}
style={{ padding: '0 1.5vw', display: 'block', marginTop: '10px' }}
to="#jump-to"
smooth
>
Return to Top of Page
</Link>
</CardContent>
</Card>

Expand All @@ -270,6 +295,14 @@ const Help = () => {
peculiar behaviors.
</li>
</Typography>
<Link
className={`gc360_text_link`}
style={{ padding: '0 1.5vw', display: 'block', marginTop: '10px' }}
to="#jump-to"
smooth
>
Return to Top of Page
</Link>
</CardContent>
</Card>

Expand All @@ -284,6 +317,14 @@ const Help = () => {
</li>
<li>Gordon 360 is not supported on Internet Explorer.</li>
</Typography>
<Link
className={`gc360_text_link`}
style={{ padding: '0 1.5vw', display: 'block', marginTop: '10px' }}
to="#jump-to"
smooth
>
Return to Top of Page
</Link>
</CardContent>
</Card>

Expand Down Expand Up @@ -328,6 +369,14 @@ const Help = () => {
to Involvements to receive emails!
</li>
</Typography>
<Link
className={`gc360_text_link`}
style={{ padding: '0 1.5vw', display: 'block', marginTop: '10px' }}
to="#jump-to"
smooth
>
Return to Top of Page
</Link>
</CardContent>
</Card>
</CardContent>
Expand Down
4 changes: 2 additions & 2 deletions src/views/Home/components/DiningBalance/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ const DiningBalance = () => {
{
labels: ['Days Finished', 'Days Remaining'],
data: [daysFinished, daysLeftRounded],
backgroundColor: [daysColor, emptyColor],
backgroundColor: [emptyColor, daysColor],
},
{
labels: ['Swipes Used', 'Swipes Remaining'],
Expand Down Expand Up @@ -228,7 +228,7 @@ const DiningBalance = () => {
variant="contained"
color="secondary"
component={Link}
href="https://gordon.cafebonappetit.com/"
href="https://www.gordonmetz.com/"
target="_blank"
rel="noopener noreferrer"
>
Expand Down
4 changes: 2 additions & 2 deletions src/views/Links/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ const Links = () => (
className={`gc360_text_link`}
target="_blank"
>
<ListItemText primary="Criterion"></ListItemText>
<ListItemText primary="Criterion (Timesheets)"></ListItemText>
</Link>
</ListItem>
<ListItem>
Expand All @@ -137,7 +137,7 @@ const Links = () => (
className={`gc360_text_link`}
target="_blank"
>
<ListItemText primary="25Live"></ListItemText>
<ListItemText primary="25Live (Scheduling)"></ListItemText>
</Link>
</ListItem>
<ListItem>
Expand Down

0 comments on commit a963483

Please sign in to comment.