@@ -104,12 +104,18 @@ const CreateTaskModal = ({ events, onClose, onCreated }) => {
104104 onClick = { ( e ) => e . target === e . currentTarget && onClose ( ) } >
105105 < motion . div
106106 className = "modal"
107+ role = "dialog"
108+ aria-modal = "true"
109+ aria-labelledby = "create-task-title"
107110 style = { { maxWidth : 560 } }
108111 initial = { { opacity : 0 , scale : 0.95 } }
109112 animate = { { opacity : 1 , scale : 1 } } >
110113 < div className = "modal-header" >
111- < h2 className = "modal-title" > Create Task</ h2 >
112- < button className = "btn btn-ghost btn-sm" onClick = { onClose } >
114+ < h2 id = "create-task-title" className = "modal-title" > Create Task</ h2 >
115+ < button
116+ className = "btn btn-ghost btn-sm"
117+ onClick = { onClose }
118+ aria-label = "Close create task dialog" >
113119 < RiCloseLine />
114120 </ button >
115121 </ div >
@@ -310,11 +316,14 @@ const SubmitTaskModal = ({ task, onClose, onSubmitted }) => {
310316 onClick = { ( e ) => e . target === e . currentTarget && onClose ( ) } >
311317 < motion . div
312318 className = "modal"
319+ role = "dialog"
320+ aria-modal = "true"
321+ aria-labelledby = "submit-task-title"
313322 initial = { { opacity : 0 , scale : 0.95 } }
314323 animate = { { opacity : 1 , scale : 1 } } >
315324 < div className = "modal-header" >
316325 < div >
317- < h2 className = "modal-title" > Submit Task</ h2 >
326+ < h2 id = "submit-task-title" className = "modal-title" > Submit Task</ h2 >
318327 < p
319328 style = { {
320329 fontSize : "0.82rem" ,
@@ -324,7 +333,10 @@ const SubmitTaskModal = ({ task, onClose, onSubmitted }) => {
324333 { task . title }
325334 </ p >
326335 </ div >
327- < button className = "btn btn-ghost btn-sm" onClick = { onClose } >
336+ < button
337+ className = "btn btn-ghost btn-sm"
338+ onClick = { onClose }
339+ aria-label = "Close submit task dialog" >
328340 < RiCloseLine />
329341 </ button >
330342 </ div >
0 commit comments