Skip to content

Commit

Permalink
Update styles for rich text link/doc tooltips
Browse files Browse the repository at this point in the history
  • Loading branch information
albinazs committed Jul 5, 2023
1 parent c7039ed commit 94ac18b
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
7 changes: 2 additions & 5 deletions client/src/components/Draftail/Tooltip/Tooltip.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,11 @@ $tooltip-z-index: $draftail-tooltip-z-index;
$tooltip-color-no: theme('colors.critical.100');

@mixin arrow--top {
margin-top: $tooltip-arrow-spacing;
margin-top: $tooltip-spacing;
transform: translateX(calc(var(--w-direction-factor) * -50%));

&::before {
bottom: 100%;
inset-inline-start: 50%;
transform: translateX(calc(var(--w-direction-factor) * -50%));
border-bottom-color: $tooltip-chrome;
content: none;
}
}

Expand Down
7 changes: 5 additions & 2 deletions client/src/components/Draftail/decorators/TooltipEntity.js
Original file line number Diff line number Diff line change
Expand Up @@ -116,12 +116,15 @@ class TooltipEntity extends Component {
</a>
) : null}

<button className="button Tooltip__button" onClick={this.onEdit}>
<button
className="button button-small Tooltip__button"
onClick={this.onEdit}
>
Edit
</button>

<button
className="button button-secondary no Tooltip__button"
className="button button-small button-secondary no Tooltip__button"
onClick={this.onRemove}
>
Remove
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,13 +68,13 @@ exports[`TooltipEntity #openTooltip 1`] = `
www.example.com
</a>
<button
className="button Tooltip__button"
className="button button-small Tooltip__button"
onClick={[Function]}
>
Edit
</button>
<button
className="button button-secondary no Tooltip__button"
className="button button-small button-secondary no Tooltip__button"
onClick={[Function]}
>
Remove
Expand Down

0 comments on commit 94ac18b

Please sign in to comment.