From 99442ccb8cd5974adb0fa5bfb960d2644e55571c Mon Sep 17 00:00:00 2001 From: Kyle Suss Date: Tue, 7 Jan 2020 11:59:05 -0700 Subject: [PATCH] Pass props down to Tooltip components --- src/components/tooltip/TooltipLinkList.js | 8 ++++---- src/components/tooltip/TooltipMessage.js | 4 ++-- src/components/tooltip/TooltipNote.js | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/components/tooltip/TooltipLinkList.js b/src/components/tooltip/TooltipLinkList.js index f21c1976..715e85c0 100644 --- a/src/components/tooltip/TooltipLinkList.js +++ b/src/components/tooltip/TooltipLinkList.js @@ -12,10 +12,10 @@ const List = styled.ul` list-style: none; `; -export function TooltipLinkList({ links, LinkWrapper }) { +export function TooltipLinkList({ links, LinkWrapper, ...rest }) { return ( - - {links.map(({ title, onClick, active, ...rest }, index) => ( + + {links.map(({ title, onClick, active, ...linkRest }, index) => ( ))} diff --git a/src/components/tooltip/TooltipMessage.js b/src/components/tooltip/TooltipMessage.js index 63553324..ca13e015 100644 --- a/src/components/tooltip/TooltipMessage.js +++ b/src/components/tooltip/TooltipMessage.js @@ -32,9 +32,9 @@ const MessageWrapper = styled.div` box-sizing: border-box; `; -export function TooltipMessage({ title, desc, links }) { +export function TooltipMessage({ title, desc, links, ...rest }) { return ( - + {title && {title}} {desc && {desc}} diff --git a/src/components/tooltip/TooltipNote.js b/src/components/tooltip/TooltipNote.js index 4a7b2d92..97171241 100644 --- a/src/components/tooltip/TooltipNote.js +++ b/src/components/tooltip/TooltipNote.js @@ -19,8 +19,8 @@ const Note = styled.div` margin: 6px; `; -export function TooltipNote({ note }) { - return {note}; +export function TooltipNote({ note, ...rest }) { + return {note}; } TooltipNote.propTypes = {