Skip to content

Commit

Permalink
Try to make stuff with constants a bit clearer.
Browse files Browse the repository at this point in the history
  • Loading branch information
johndoknjas committed Feb 5, 2025
1 parent 4234a06 commit 5ff2d15
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
2 changes: 1 addition & 1 deletion ui/round/css/_app-layout.scss
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@

.rclock-bottom {
grid-area: 6 / 1 / 8 / 2;
margin-top: $col1-bottom-clock-top-margin;
margin-top: -$col1-bottom-clock-shift-up;
}

cg-board {
Expand Down
17 changes: 8 additions & 9 deletions ui/round/css/_constants.scss
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
// layout
$col1-player-clock-height: 50px;
$bottom-clock-shift-up-percent: 0.06;
// todo:
// use this new percent variable to ideally clean up code a bit.
// review your changes, see if they make sense
// take screenshots of the clocks, and compare against screenshots of master.
// look at positionings of username and material too.
$col1-bottom-clock-top-margin: -3px;
$col1-bottom-clock-height: 47px;
$col1-user-height: $col1-player-clock-height * 3 / 5;
$col1-mat-height: $col1-player-clock-height * 2 / 5;
$col1-bottom-user-height: $col1-bottom-clock-height * 3 / 5;
$col1-bottom-mat-height: $col1-bottom-clock-height * 2 / 5;
$user-to-clock-size: 3 / 5;
$col1-player-clock-height: 50px;
$col1-bottom-clock-shift-up: 3px;
$col1-bottom-clock-technical-height: $col1-player-clock-height - $col1-bottom-clock-shift-up;
$col1-user-height: $col1-player-clock-height * $user-to-clock-size;
$col1-mat-height: $col1-player-clock-height - $col1-user-height;
$col1-bottom-user-height: $col1-bottom-clock-technical-height * $user-to-clock-size;
$col1-bottom-mat-height: $col1-bottom-clock-technical-height - $col1-bottom-user-height;
$col1-moves-height: 4em;
$move-tag: 'kwdb';
$rmoves-tag: 'rm6';
Expand Down

0 comments on commit 5ff2d15

Please sign in to comment.