Nombreuses corrections sur les fiches settlement/NPC

This commit is contained in:
2026-03-22 21:35:47 +01:00
parent ec291e9c60
commit b46c6d804c
51 changed files with 2892 additions and 227 deletions

View File

@@ -1,22 +1,209 @@
// ============================================================
// NPC SHEET — NPC-specific layout
// NPC SHEET — layout, vitals, skills, traits
// ============================================================
.oathhammer .npc-main {
.npc-left {
min-width: @npc-left-width;
max-width: @npc-left-width;
display: flex;
flex-direction: column;
align-items: center;
gap: 4px;
flex-shrink: 0;
.actor-img {
width: 100%;
height: 170px;
object-fit: cover;
object-position: center top;
}
}
.npc-right {
flex: 1;
display: flex;
flex-direction: column;
gap: 4px;
gap: 6px;
min-width: 0;
}
// Name row
.character-name {
display: flex;
align-items: center;
gap: 4px;
border-bottom: 1px solid @color-olive;
padding-bottom: 4px;
input {
flex: 1;
font-family: @font-primary;
font-size: @font-size-lg;
}
}
// Vitals: 2×2 grid (Grit | Defense / Armor | Movement)
.npc-vitals-grid {
display: grid;
grid-template-columns: 1fr 1fr 1fr;
gap: 4px 10px;
padding: 4px 6px;
border: 1px solid @color-olive;
border-radius: 3px;
background: rgba(0, 0, 0, 0.08);
.npc-vital {
display: flex;
align-items: center;
gap: 4px;
.vital-label {
font-family: @font-secondary;
font-size: @font-size-sm;
font-weight: bold;
color: @color-dark;
white-space: nowrap;
min-width: 4.5rem;
}
.vital-roll-label {
cursor: pointer;
color: @color-blue;
transition: color 0.15s;
i { margin-right: 2px; font-size: 0.75rem; }
&:hover { color: @color-gold; text-decoration: underline; }
}
.vital-value {
display: flex;
align-items: center;
gap: 3px;
flex: 1;
div.form-group { display: contents; }
input, .npc-num-input {
width: 2.8rem;
text-align: center;
font-size: @font-size-sm;
padding: 1px 2px;
}
.res-sep { opacity: 0.6; font-size: @font-size-xs; }
}
}
.npc-vital-grit .vital-value {
.grit-btn {
display: inline-flex;
align-items: center;
justify-content: center;
width: 1.2rem;
height: 1.2rem;
font-size: 0.85rem;
font-weight: bold;
line-height: 1;
border: 1px solid @color-olive;
border-radius: 3px;
background: @color-olive-faint;
color: @color-dark;
cursor: pointer;
user-select: none;
flex-shrink: 0;
&:hover { background: @color-gold; border-color: @color-gold; }
}
}
}
// Statistics fieldset grid
}
// Inline color badge (emoji in play mode)
.oathhammer .npc-color-badge {
font-size: 0.85rem;
flex-shrink: 0;
line-height: 1;
}
// Inline color dropdown (in edit mode) — fixed width so it doesn't stretch the grid
.oathhammer .npc-color-select {
width: 88px;
max-width: 88px;
flex-shrink: 0;
font-size: @font-size-xs;
padding: 0 2px;
height: 20px;
min-width: 0;
}
// Subtype badge (play mode) / select (edit mode)
.oathhammer .npc-subtype-badge {
font-size: @font-size-base;
font-weight: 600;
color: @color-dark;
background: fade(@color-gold, 20%);
border: 1px solid fade(@color-gold, 50%);
border-radius: 3px;
padding: 1px 8px;
}
.oathhammer .npc-subtype-select {
font-size: @font-size-sm;
padding: 0 2px;
height: 20px;
min-width: 80px;
}
// ============================================================
// NPC SKILLS TAB
// ============================================================
// Color emoji indicator per dice type
.oathhammer .npc-skill-color {
font-size: 0.95rem;
text-align: center;
line-height: 1;
justify-self: center;
}
.oathhammer .npc-skill-color-white { opacity: 0.75; }
.oathhammer .npc-skill-color-red { color: #cc4444; }
.oathhammer .npc-skill-color-black { color: #333; font-weight: bold; }
// Roll button in skill list
.oathhammer .npc-skill-roll-btn {
color: @color-gold;
padding: 2px 4px;
border: 1px solid fade(@color-gold, 40%);
border-radius: 3px;
font-size: @font-size-sm;
text-align: center;
justify-self: center;
&:hover { background: fade(@color-gold, 15%); }
}
// ============================================================
// NPC TRAITS TAB
// ============================================================
// Type badge used in traits list
.oathhammer .npc-trait-type-badge {
font-size: 0.72rem;
padding: 1px 5px;
border-radius: 3px;
white-space: nowrap;
background: fade(@color-gold, 15%);
border: 1px solid fade(@color-gold, 35%);
color: @color-dark;
text-align: center;
overflow: hidden;
text-overflow: ellipsis;
}
// ============================================================
// NPC SKILL DIALOG
// ============================================================
.npc-skill-dialog {
display: flex;
flex-direction: column;
gap: 8px;
padding: 4px 0;
}