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

feat: triad logo updates #630

Merged
merged 5 commits into from
Dec 20, 2024
Merged
Show file tree
Hide file tree
Changes from 4 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
1 change: 0 additions & 1 deletion app/[locale]/[...uriSegments]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,6 @@ const sectionMap = {
searchResults: SearchPageTemplate,
slideshows: SlideshowPageTemplate,
staffProfiles: StaffPageTemplate,
// userProfilePage: UserProfilePageTemplate,
};

const UriSegmentsPage: FunctionComponent<UriSegmentProps> = async ({
Expand Down
36 changes: 36 additions & 0 deletions components/atomic/Button/Hamburger/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
"use client";
import { FunctionComponent } from "react";
import classNames from "classnames";
import { useTranslation } from "react-i18next";
import { IconComposer } from "@rubin-epo/epo-react-lib";
import styles from "./styles.module.scss";

interface HamburgerProps {
active: boolean;
onClick: MouseEventHandler<HTMLButtonElement>;
className?: string;
}

const Hamburger: FunctionComponent<HamburgerProps> = ({
active,
onClick,
className,
}) => {
const { t } = useTranslation();

return (
<button
aria-haspopup="dialog"
aria-expanded={active}
onClick={onClick}
className={classNames(styles.hamburger, className)}
>
<span className="a-hidden">{t("toggle-nav")}</span>
<IconComposer icon="Hamburger" />
</button>
);
};

Hamburger.displayName = "Atom.Button.Hamburger";

export default Hamburger;
22 changes: 22 additions & 0 deletions components/atomic/Button/Hamburger/styles.module.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
@use "abstracts/mixins/base";
@use "abstracts/functions";

.hamburger {
@include base.fluid-scale(
width,
functions.header(button-width-tablet),
functions.header(button-width-mobile),
functions.break(tablet),
functions.break(mobile)
);

height: 100%;
display: flex;
align-items: center;
justify-content: center;
transition: background-color 0.2s;

&[aria-expanded="true"] {
background-color: var(--color-rubin-teal-600, #0c4a47);
}
}
1 change: 1 addition & 0 deletions components/atomic/Button/patterns/GoogleSSOButton.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
"use client";
import PropTypes from "prop-types";
import { useGoogleLogin } from "@react-oauth/google";
import { usePathname, useRouter } from "next/navigation";
Expand Down
1 change: 1 addition & 0 deletions components/atomic/Button/patterns/SSOButton.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
"use client";
/* eslint-disable react/prop-types */
import { useState, useEffect } from "react";
import PropTypes from "prop-types";
Expand Down
3 changes: 0 additions & 3 deletions components/auth/AuthorizePage/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,12 @@ const AUTHORIZED_TYPES = {
pages: false,
educatorPages: true,
studentPages: false,
userProfilePage: true,
investigationLandingPage: false,
};

function isAuthorized(typeHandle, user, status) {
if (typeHandle === "educatorPages")
return user?.group === "educators" && status === "active";
if (typeHandle === "userProfilePage") return !!user && status === "active";
return false;
}

Expand Down Expand Up @@ -95,7 +93,6 @@ AuthorizePage.propTypes = {
"pages",
"educatorPages",
"studentPages",
"userProfilePage",
"investigationLandingPage",
]),
children: PropTypes.node,
Expand Down
30 changes: 0 additions & 30 deletions components/global/Header/Hamburger.js

This file was deleted.

169 changes: 0 additions & 169 deletions components/global/Header/Navigation.js

This file was deleted.

82 changes: 0 additions & 82 deletions components/global/Header/UserNav/index.js

This file was deleted.

Loading
Loading