File tree Expand file tree Collapse file tree 1 file changed +28
-2
lines changed
src/components/ChooseSession Expand file tree Collapse file tree 1 file changed +28
-2
lines changed Original file line number Diff line number Diff line change 11import { useState } from "react" ;
22import { useCookies } from "react-cookie" ;
3- import { ExclamationCircleIcon } from "@heroicons/react/24/outline" ;
3+ import {
4+ ExclamationCircleIcon ,
5+ FaceFrownIcon ,
6+ } from "@heroicons/react/24/outline" ;
47import {
58 exampleAccount ,
69 SessionList ,
@@ -119,11 +122,34 @@ const ChooseSession = (): JSX.Element => {
119122 />
120123 </ div >
121124 < div className = "max-h-screen overflow-auto rounded-sm bg-grey-primary p-3 shadow-inner" >
122- { data ? (
125+ { data && data . items . length > 0 ? (
123126 < SessionList
124127 sessions = { data . items }
125128 onClickDelete = { ( sessionId ) => deleteSession . mutate ( { sessionId } ) }
126129 />
130+ ) : data && sessionNameFilter != "" ? (
131+ < div className = "flex min-h-full flex-col items-center justify-center" >
132+ < FaceFrownIcon
133+ className = "mx-auto h-8 w-8 text-blue-primary"
134+ aria-hidden = "true"
135+ />
136+ < p className = "mt-4 text-lg font-semibold leading-6 text-blue-secondary" >
137+ No results found
138+ </ p >
139+ < p className = "mt-2 block text-center text-sm leading-6 text-blue-primary" >
140+ No programs found with that name. Please try a different name, or
141+ create a new program.
142+ </ p >
143+ </ div >
144+ ) : data ? (
145+ < div className = "flex min-h-full flex-col items-center justify-center" >
146+ < p className = "mt-4 text-lg font-semibold leading-6 text-blue-secondary" >
147+ No programs found
148+ </ p >
149+ < p className = "mt-2 block text-center text-sm leading-6 text-blue-primary" >
150+ You don't have any programs yet. Create a new one!
151+ </ p >
152+ </ div >
127153 ) : isError ? (
128154 < div className = "flex min-h-full flex-col items-center justify-center" >
129155 < ExclamationCircleIcon
You can’t perform that action at this time.
0 commit comments