-
Notifications
You must be signed in to change notification settings - Fork 16
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
Added Accordion Component #23
Added Accordion Component #23
Conversation
Thank you for your PR @Ashwathi23! Please ensure you fill in all fields in the description template above. |
Sure,i have updated the template. |
Thank you @Ashwathi23! I don't agree that unit tests are N/A here - all new components should have unit tests - but I am happy for that to be addressed in a separate PR. |
} from './Accordion.style'; | ||
|
||
type AccordionProps = { | ||
items: { title: string; content: string }[]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggestion: Content could be a ReactNode
rather than a string
, to allow for more complex content to be displayed in an accordion (such as tables, images, text with headings and lists).
@@ -0,0 +1,25 @@ | |||
import styled from 'styled-components'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Really nice work on the styled components structure here!
import { renderWithDeps } from '../../../jest.utils'; | ||
import { Accordion } from './Accordion'; | ||
|
||
describe('<Accordion />', () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add an accessibility test here. You can find an example of how to do this in the updated testing template.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added the accessibility test in Accordion.test.tsx
Summary
What is the nature of this pull request?
Description of change
Added a new component accordion and updated the files to solve the error during git action.
Planner card link
https://teams.microsoft.com/l/entity/com.microsoft.teamspace.tab.planner/tt.c_19:[email protected]_p_TOGdCftBI0mZ937fEIW0jsgAHPsL_h_1710632381880?tenantId=d02378ec-1688-46d5-8540-1c28b5f470f6&webUrl=https%3A%2F%2Ftasks.teams.microsoft.com%2Fteamsui%2FpersonalApp%2Falltasklists&context=%7B%22subEntityId%22%3A%22%2Fv1%2Fplan%2FTOGdCftBI0mZ937fEIW0jsgAHPsL%2Ftask%2FNoIex0qPVU-TaNCSasyjM8gAKRdm%22%2C%22channelId%22%3A%2219%3Ac1b94839a3db4c6e8bf052aeadb33d9b%40thread.tacv2%22%7D
Readiness