Skip to content
Merged
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
13 changes: 13 additions & 0 deletions components/sessions/SessionToggles.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import type { NextPage } from 'next'
import { useContext } from 'react'
import Link from 'next/link'
import { AuthContext } from '../../context/AuthContext'

interface SessionPageProps {
Expand All @@ -8,6 +9,7 @@ interface SessionPageProps {
onMySessions: (val: boolean) => void
isGridView: boolean
isMySessions: boolean
reportLink?: string
}

export const SessionToggles: NextPage<SessionPageProps> = ({
Expand All @@ -16,11 +18,22 @@ export const SessionToggles: NextPage<SessionPageProps> = ({
isGridView,
onMySessions,
isMySessions,
reportLink,
}) => {
const { isAuthenticated } = useContext(AuthContext)

return (
<div className="space-x-4 md:space-x-8 w-full md:w-1/3 flex justify-end items-center">
{reportLink && (
<Link
className="btn-secondary"
href={reportLink}
target="_blank"
rel="noreferrer"
>
View Annual Report
</Link>
)}
<button type="button" onClick={() => onChangeViewType(true)}>
<i
className={`fa fa-th text-2xl ${
Expand Down
1 change: 1 addition & 0 deletions pages/past-events/2025.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ const Home2025: NextPage<SessionProps> = ({
isGridView={isGridView}
onMySessions={setShowMysessions}
isMySessions={showMySessions}
reportLink="https://bit.ly/dcKe-flutterKe-2025-report"
/>
</div>
</div>
Expand Down
Loading