beginnings of darkmode

pull/65/head
macniel 2025-11-09 00:41:49 +01:00
parent 34d7175c39
commit 0f9032c3f5
7 changed files with 74 additions and 8 deletions

View File

@ -41,6 +41,7 @@ $attribute-die-border-color: #000;
$attribute-die-color: #F00; $attribute-die-color: #F00;
$attribute-die-label-color: #FFF; $attribute-die-label-color: #FFF;
$attribute-die-label-color-darkmode: #000;
$attribute-die-co-color: #b3241a; $attribute-die-co-color: #b3241a;
$attribute-die-sm-color: #8259a3; $attribute-die-sm-color: #8259a3;
@ -68,6 +69,8 @@ $attribute-die-flaw-text-color: #FFF;
$attribute-label-color: #000; $attribute-label-color: #000;
$attribute-label-color-darkmode: #FFF;
$rollable-die-border-color: #000; $rollable-die-border-color: #000;

View File

@ -3,7 +3,7 @@
@use "../atoms/assets"; @use "../atoms/assets";
@use "sass:color"; @use "sass:color";
@mixin attributes { @mixin attributes($darkmode: false) {
display: flex; display: flex;
position: relative; position: relative;
top: -10px; top: -10px;
@ -36,7 +36,11 @@
line-height: 48px; line-height: 48px;
vertical-align: middle; vertical-align: middle;
text-align: center; text-align: center;
color: colours.$attribute-die-label-color; @if $darkmode {
color: colours.$attribute-die-label-color-darkmode;
} @else {
color: colours.$attribute-die-label-color;
}
} }
.name { .name {
@ -47,7 +51,12 @@
line-height: 12px; line-height: 12px;
vertical-align: middle; vertical-align: middle;
text-align: center; text-align: center;
color: colours.$attribute-label-color; @if $darkmode {
color: colours.$attribute-label-color-darkmode;
} @else {
color: colours.$attribute-label-color;
}
} }
} }

View File

@ -10,9 +10,17 @@
position: relative; position: relative;
.attributes { .attributes {
@include attribute-die.attributes @include attribute-die.attributes(false)
} }
} }
} }
.theme-dark {
.dsa41.sheet.actor.character {
.attributes {
@include attribute-die.attributes(true)
}
}
}

View File

@ -74,3 +74,29 @@
} }
} }
// darkmode
.theme-dark {
.dsa41.sheet {
.sheet-tabs {
a[data-action="tab"].active {
background: rgba(0, 0, 0, 0.3);
&::after {
background: rgba(0, 0, 0, 0.3);
}
}
}
section.tab {
background: rgba(0, 0, 0, 0.3);
}
}
}

View File

@ -10,7 +10,7 @@
height: 100%; height: 100%;
.attributes { .attributes {
@include attribute-die.attributes; @include attribute-die.attributes(false);
top: 0; top: 0;
left: 0; left: 0;
justify-content: center; justify-content: center;
@ -101,3 +101,14 @@
} }
} }
} }
.theme-dark {
.dsa41.dialog.talent, .dsa41.dialog.eigenschaft {
section[data-application-part] {
.attributes {
@include attribute-die.attributes(true);
}
}
}
}

View File

@ -10,7 +10,7 @@
height: 100%; height: 100%;
.attributes { .attributes {
@include attribute-die.attributes; @include attribute-die.attributes(false);
top: 0; top: 0;
left: 0; left: 0;
justify-content: center; justify-content: center;
@ -101,3 +101,13 @@
} }
} }
} }
.theme-dark {
.dsa41.dialog.liturgy {
section[data-application-part] {
.attributes {
@include attribute-die.attributes(true);
}
}
}
}

View File

@ -1,6 +1,5 @@
<div class="player-action {{this.source}} {{this.type}}" data-action="openCombatAction"> <div class="player-action {{this.source}} {{this.type}} {{this.cost}}" data-action="openCombatAction">
<span class="name">{{this.name}}</span> <span class="name">{{this.name}}</span>
<span class="time">{{this.cost}}</span>
</div> </div>