diff --git a/package-lock.json b/package-lock.json index 58c6614d..79093e13 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "@accordproject/cicero-ui", - "version": "0.5.9", + "version": "0.5.10", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 215dd087..d9e7b52f 100644 --- a/package.json +++ b/package.json @@ -110,4 +110,4 @@ "/src/**/?(*.)(spec|test).{js,jsx,mjs}" ] } -} \ No newline at end of file +} diff --git a/src/components/ConditionalBoolean.js b/src/components/ConditionalBoolean.js index 437d4258..cf3f7dda 100644 --- a/src/components/ConditionalBoolean.js +++ b/src/components/ConditionalBoolean.js @@ -44,7 +44,7 @@ const ConditionalBoolean = (props) => { somethingLength: props.nodeValue.position.popupWidth, somethingHeight: props.nodeValue.position.popupHeight + (props.nodeValue.position.popupHeight * 0.5), - caretTop: props.nodeValue.position.popupHeight, + caretTop: 1, caretLeft: (tooltipWidth / 2), tooltipHeight: 0.1, }; diff --git a/src/components/ConditionalSwitch.js b/src/components/ConditionalSwitch.js index 21cac60d..595480d5 100644 --- a/src/components/ConditionalSwitch.js +++ b/src/components/ConditionalSwitch.js @@ -14,7 +14,7 @@ const ConditionalSwitch = (props) => { const conditionalTooltip = { className: 'conditionalTooltip', currentHover: props.currentHover, - caretTop: 20, + caretTop: 1.45, caretLeft: 2, tooltipHeight: 1.85, }; diff --git a/src/components/styles.js b/src/components/styles.js index 04f137ca..70a15d5f 100644 --- a/src/components/styles.js +++ b/src/components/styles.js @@ -24,7 +24,7 @@ export const ClauseConditionalTooltip = styled.div` &:before { content: ''; position: absolute; - top: ${props => props.caretTop - 1}px; + top: ${props => props.caretTop}em; left: ${props => props.caretLeft - 1}px; border-top: 5px solid #141F3C; border-left: 5px solid transparent; @@ -34,7 +34,7 @@ export const ClauseConditionalTooltip = styled.div` &:after { content: ''; position: absolute; - top: ${props => props.caretTop - 1}px; + top: ${props => props.caretTop}em; left: ${props => props.caretLeft}px; border-top: 4px solid #141F3C; border-left: 4px solid transparent; diff --git a/src/styles.css b/src/styles.css index 925ae13e..db74063a 100644 --- a/src/styles.css +++ b/src/styles.css @@ -18,8 +18,6 @@ a { .conditionalTooltip { opacity: 1 !important; - height: max-content; - width: max-content; border: 1px solid #141F3C; border-radius: 2px; background-color: #141F3C;