Skip to content

Commit

Permalink
fix(css): Fix missing % in calculation (#4157)
Browse files Browse the repository at this point in the history
This bug has always been there, as far as I can tell, since the ads UI
was added.  This issue was caught by an internal compilation tool and
another project that consumes our UI.
  • Loading branch information
joeyparrish authored Apr 26, 2022
1 parent 71b6de8 commit 1c86195
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ui/less/ad_controls.less
Original file line number Diff line number Diff line change
Expand Up @@ -78,11 +78,11 @@

/* This math is determining how far the button is from the right edge.
* Ad panel's parent is centered and @bottom-controls-width wide, so
* 100 - @bottom-controls-width = margins from both sides of the container.
* 100% - @bottom-controls-width = margins from both sides of the container.
* That divided by 2 is margin on one side, so we take that, and move the
* button from its normal position to the right by that percentage.
*/
right: calc((100 - @bottom-controls-width) / 2 * -1);
right: calc((100% - @bottom-controls-width) / 2 * -1);
display: flex;
flex-direction: row;
margin: 0;
Expand Down

0 comments on commit 1c86195

Please sign in to comment.