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

@@ -325,4 +325,58 @@
text-align: center;
font-weight: bold;
}
// ── Magic tab — Arcane Stress row ──────────────────────────
.stress-controls {
display: flex;
align-items: center;
gap: 6px;
flex-wrap: nowrap;
padding: 4px 0;
.stress-btn {
display: inline-flex;
align-items: center;
justify-content: center;
width: 22px;
height: 22px;
border: 1px solid @color-olive;
border-radius: 3px;
background: fade(@color-dark, 6%);
color: @color-dark;
font-size: 1rem;
line-height: 1;
cursor: pointer;
flex-shrink: 0;
text-decoration: none;
&:hover { background: fade(@color-blue, 15%); border-color: @color-blue; }
}
.arcane-stress-display {
font-family: @font-secondary;
font-size: @font-size-lg;
font-weight: bold;
color: @color-dark;
min-width: 3rem;
text-align: center;
flex-shrink: 0;
&.stress-at-limit { color: #c0392b; }
}
.stress-bonus-label {
margin-left: auto; // push threshold bonus to the right
font-size: @font-size-sm;
color: @color-olive;
white-space: nowrap;
flex-shrink: 0;
}
.stress-bonus-input {
width: 3rem;
text-align: center;
flex-shrink: 0;
}
}
}

View File

@@ -121,12 +121,25 @@
}
}
// Settlement inventory: simpler lists (no equip slot, no qty)
.item-list--weapons {
.item-list-header, .item-entry {
grid-template-columns: @item-img-size 1fr 6rem 4rem;
}
}
.item-list--armor {
.item-list-header, .item-entry {
grid-template-columns: @item-img-size 1fr 3.5rem 2.5rem 3.5rem 1.5rem 1.8rem 5.5rem;
}
}
.item-list--armors {
.item-list-header, .item-entry {
grid-template-columns: @item-img-size 1fr 6rem 4rem;
}
}
.item-list--ammo {
.item-list-header, .item-entry {
grid-template-columns: @item-img-size 1fr 4rem 3.5rem;
@@ -180,6 +193,49 @@
}
}
// ── NPC-specific grid variants ───────────────────────────────
// NPC Skill list: [color emoji] [name] [pool] [threshold] [roll btn] [actions]
.item-list--npc-skill {
.item-list-header, .item-entry {
grid-template-columns: 1.8rem 1fr 3.5rem 3.5rem 2rem 4.5rem;
}
}
// NPC Weapon list: [img] [name] [damage] [AP] [actions incl attack+dmg+edit+del]
.item-list--npc-weapon {
.item-list-header, .item-entry {
grid-template-columns: @item-img-size 1fr 3.5rem 2.5rem 7rem;
}
}
// NPC Trait list: [img] [name] [type badge] [actions]
.item-list--npc-trait {
.item-list-header, .item-entry {
grid-template-columns: @item-img-size 1fr 6rem 3.5rem;
}
}
// NPC Armor list: [img] [name] [AV] [penalty] [actions]
.item-list--npc-armor {
.item-list-header, .item-entry {
grid-template-columns: @item-img-size 1fr 3rem 3rem 3.5rem;
}
}
// NPC Equipment list: [img] [name] [actions]
.item-list--npc-equip {
.item-list-header, .item-entry {
grid-template-columns: @item-img-size 1fr 3.5rem;
}
}
// NPC Attack list: [img] [name] [damage] [AP] [actions: roll+edit+del]
.item-list--npc-attack {
.item-list-header, .item-entry {
grid-template-columns: @item-img-size 1fr 7rem 3rem 6rem;
}
}
.item-usage {
font-size: @font-size-xs;
color: @color-dark;
@@ -273,3 +329,12 @@
}
}
}
// ── Regiment list (settlement garrison tab) ──────────────────────────────────
.oathhammer {
.item-list--regiment {
.item-list-header, .item-entry {
grid-template-columns: @item-img-size 1fr 4rem 5rem 4rem 4.5rem;
}
}
}

View File

@@ -115,6 +115,25 @@
color: @color-blue;
}
// ── Enchantment fieldset ─────────────────────────────────────
.enchantment-fieldset {
.enchant-cursed-label {
display: flex;
align-items: center;
gap: 4px;
flex-shrink: 0;
margin-left: 8px;
font-family: @font-secondary;
font-size: @font-size-base;
color: @color-dark;
white-space: nowrap;
input[type="checkbox"] {
margin: 0;
}
}
}
// ── Class proficiency checkboxes ────────────────────────────
.proficiency-section {
display: flex;
@@ -150,3 +169,78 @@
}
}
}
// SkillNPC sheet — vertical stack layout
.oathhammer .skillnpc-sheet {
.skillnpc-stats {
display: flex;
flex-direction: column;
gap: 2px;
margin-bottom: 6px;
.form-group > label {
flex: 0 0 9rem;
}
}
}
// NpcAttack sheet — vertical stack layout (mirrors skillnpc)
.oathhammer .npcattack-sheet {
.npcattack-stats {
display: flex;
flex-direction: column;
gap: 2px;
margin-bottom: 6px;
.form-group > label {
flex: 0 0 9rem;
}
}
}
// Regiment sheet
.oathhammer .regiment-sheet {
display: flex;
flex-direction: column;
gap: 6px;
.regiment-stats-row {
display: grid;
grid-template-columns: 1fr 1fr 1fr;
gap: 4px;
.form-group > label { flex: 0 0 6rem; }
}
.regiment-armor-fields {
display: flex;
gap: 4px;
input[type="number"] { width: 3rem; }
}
.regiment-skill-row,
.regiment-attack-row,
.regiment-trait-row {
display: grid;
gap: 4px;
margin-bottom: 2px;
align-items: center;
input, select { font-size: @font-size-sm; padding: 1px 3px; }
a.item-delete { text-align: center; color: @color-dark; opacity: 0.4; &:hover { color: #c0392b; opacity: 1; } }
}
.regiment-skill-header,
.regiment-attack-header {
font-weight: bold;
font-size: @font-size-xs;
color: @color-dark;
opacity: 0.6;
text-transform: uppercase;
}
.regiment-skill-row { grid-template-columns: 1fr 3rem 6rem 1.5rem; }
.regiment-attack-row { grid-template-columns: 1fr 3.5rem 6rem 3rem 1fr 1.5rem; }
.regiment-trait-row { grid-template-columns: 1fr 2fr 1.5rem; }
}

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;
}

View File

@@ -284,6 +284,21 @@
flex-wrap: wrap;
gap: 4px;
align-items: center;
// Allow color badges here too (shared with .roll-info-block)
.roll-color-badge {
display: inline-flex;
align-items: center;
gap: 4px;
padding: 2px 7px;
border-radius: 4px;
font-size: @font-size-xs;
font-weight: bold;
border: 1px solid;
}
.color-badge-white { background: #f0f0f0; color: #555; border-color: #ccc; }
.color-badge-red { background: fade(#e74c3c, 12%); color: #c0392b; border-color: fade(#e74c3c, 35%); }
.color-badge-black { background: fade(#2c3e50, 10%); color: #2c3e50; border-color: fade(#2c3e50, 35%); }
}
.damage-formula-badge {

View File

@@ -10,6 +10,9 @@
background: fade(#f5ead0, 40%);
.oh-roll-header {
display: flex;
align-items: center;
gap: 6px;
font-family: @font-secondary;
font-size: @font-size-base;
font-weight: bold;
@@ -17,6 +20,15 @@
margin-bottom: 4px;
border-bottom: 1px solid @color-olive-faint;
padding-bottom: 3px;
.oh-card-weapon-img {
width: 28px;
height: 28px;
object-fit: contain;
border: 1px solid @color-olive-faint;
border-radius: 3px;
flex-shrink: 0;
}
}
.oh-roll-info {

View File

@@ -42,12 +42,13 @@
}
.oathhammer .settlement-archetype-badge {
font-size: @font-size-sm;
color: @color-dark;
background: fade(@color-gold, 15%);
border: 1px solid fade(@color-gold, 40%);
font-size: @font-size-base;
font-weight: 600;
color: darken(@color-dark, 5%);
background: fade(@color-gold, 20%);
border: 1px solid fade(@color-gold, 55%);
border-radius: 3px;
padding: 1px 6px;
padding: 1px 8px;
white-space: nowrap;
}
@@ -176,3 +177,34 @@
&:hover { color: darken(#3a7a3a, 15%); }
}
.oathhammer .settlement-buildings-header {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 6px;
.settlement-hint { margin: 0; }
.collect-taxes-btn {
display: inline-flex;
align-items: center;
gap: 5px;
padding: 3px 10px;
background: fade(@color-gold, 20%);
border: 1px solid fade(@color-gold, 60%);
border-radius: 4px;
font-size: @font-size-sm;
font-weight: bold;
color: @color-dark;
cursor: pointer;
white-space: nowrap;
&:hover {
background: fade(@color-gold, 40%);
border-color: @color-gold;
}
i { color: @color-gold; }
}
}

View File

@@ -26,7 +26,7 @@
// Layout
@portrait-height: 150px;
@left-panel-width: 180px;
@npc-left-width: 160px;
@npc-left-width: 120px;
@item-img-size: 24px;
@item-sheet-img: 52px;
@label-min-width: 9rem;