Fix promotion overlay and study player alignment

pull/9240/head
Benedikt Werner 2021-06-25 01:09:24 +02:00
parent ee6fc18e1b
commit c85abe90c3
No known key found for this signature in database
GPG Key ID: 1DBFF0F8E9E121EB
6 changed files with 11 additions and 4 deletions

View File

@ -22,9 +22,9 @@ $player-height: 1.6rem;
@extend %flex-between-nowrap, %metal, %box-shadow;
position: absolute;
left: 0;
right: 0;
font-weight: bold;
width: var(--cg-width, 100%);
height: $player-height;
white-space: nowrap;
@ -37,7 +37,7 @@ $player-height: 1.6rem;
&-bot {
@extend %box-radius-bottom;
bottom: #{-$player-height};
top: var(--cg-height, 100%);
}
.left {

View File

@ -52,6 +52,7 @@ export function makeConfig(ctrl: AnalyseCtrl): CgConfig {
orientation: ctrl.bottomColor(),
coordinates: pref.coords !== Prefs.Coords.Hidden && !ctrl.embed,
addPieceZIndex: pref.is3d,
addDimensionsCssVars: true,
viewOnly: !!ctrl.embed,
movable: {
free: false,

View File

@ -1,9 +1,12 @@
#promotion-choice {
@extend %abs-100;
background: fade-out($c-bg-page, 0.3);
z-index: z('cg__promotion');
position: absolute;
width: var(--cg-width, 100%);
height: var(--cg-height, 100%);
right: 0;
square {
cursor: pointer;
border-radius: 50%;

View File

@ -12,6 +12,7 @@ export function makeConfig(opts: CgConfig, pref: PuzPrefs, userMove: UserMove):
lastMove: opts.lastMove,
coordinates: pref.coords !== Prefs.Coords.Hidden,
addPieceZIndex: pref.is3d,
addDimensionsCssVars: true,
movable: {
free: false,
color: opts.movable!.color,

View File

@ -24,6 +24,7 @@ export function makeConfig(ctrl: Controller): CgConfig {
lastMove: opts.lastMove,
coordinates: ctrl.pref.coords !== Prefs.Coords.Hidden,
addPieceZIndex: ctrl.pref.is3d,
addDimensionsCssVars: true,
movable: {
free: false,
color: opts.movable!.color,

View File

@ -23,6 +23,7 @@ export function makeConfig(ctrl: RoundController): Config {
check: !!step.check,
coordinates: data.pref.coords !== Prefs.Coords.Hidden,
addPieceZIndex: ctrl.data.pref.is3d,
addDimensionsCssVars: true,
highlight: {
lastMove: data.pref.highlight,
check: data.pref.highlight,