-
Notifications
You must be signed in to change notification settings - Fork 11
Refactor sidepanel for multiple buttons #1270
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
Conversation
| position: plugin.position || "top", | ||
| panel: () => ( | ||
| <SidebarPanel heading={plugin.heading} Button={plugin.button}> | ||
| <SidebarPanel heading={plugin.heading} buttons={plugin.button || []}> |
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.
I think this should say plugin.buttons rather than plugin.button
| {buttons?.length > 0 && ( | ||
| <div className="sidebar__panel-buttons"> | ||
| {buttons.map((btn, i) => ( | ||
| <DesignSystemButton key={i} {...btn} /> | ||
| ))} | ||
| </div> | ||
| )} |
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.
would be nice to have a quick test for this
loiswells97
left a comment
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.
Looks great! ✅
closes https://github.com/RaspberryPiFoundation/digital-editor-issues/issues/991