mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-07-21 18:09:54 +02:00
[UI] Make sheet tab scrollsbars stable, remove fieldsets, and adjust padding (#1944)
Some checks failed
Project CI / build (24.x) (push) Has been cancelled
Some checks failed
Project CI / build (24.x) (push) Has been cancelled
* Remove certain fieldsets and adjust scrollsbars * Also remove fieldset for npc features and fix padding issue in full screen notes
This commit is contained in:
parent
1dcfc92a03
commit
eccab6ad64
30 changed files with 298 additions and 302 deletions
|
|
@ -7,7 +7,7 @@ export default class AdversarySheet extends DHBaseActorSheet {
|
|||
/** @inheritDoc */
|
||||
static DEFAULT_OPTIONS = {
|
||||
classes: ['adversary'],
|
||||
position: { width: 645, height: 760 },
|
||||
position: { width: 645, height: 750 },
|
||||
window: { resizable: true },
|
||||
actions: {
|
||||
toggleHitPoints: AdversarySheet.#toggleHitPoints,
|
||||
|
|
|
|||
|
|
@ -261,7 +261,7 @@
|
|||
|
||||
fieldset {
|
||||
align-items: center;
|
||||
margin-top: 5px;
|
||||
margin: 5px 0 0 0;
|
||||
border-radius: 6px;
|
||||
border-color: @color-fieldset-border;
|
||||
padding-inline: 0.625rem;
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ body.game:is(.performance-low, .noblur) {
|
|||
position: relative;
|
||||
min-height: -webkit-fill-available;
|
||||
transition: opacity 0.3s ease;
|
||||
padding-bottom: 20px;
|
||||
padding-bottom: 16px;
|
||||
|
||||
.tab {
|
||||
padding: 0 10px;
|
||||
|
|
|
|||
|
|
@ -39,6 +39,20 @@
|
|||
|
||||
.window-header > .attribution-header-label {
|
||||
margin-right: var(--spacer-4);
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.tab-navigation {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.tab {
|
||||
flex: 1;
|
||||
padding: 0;
|
||||
overflow: hidden;
|
||||
.search-section {
|
||||
padding: 12px 14px var(--spacer-8) 12px;
|
||||
}
|
||||
}
|
||||
|
||||
.tab.inventory {
|
||||
|
|
@ -46,7 +60,7 @@
|
|||
display: grid;
|
||||
grid-template-columns: 1fr 1fr 1fr 1fr;
|
||||
gap: 10px;
|
||||
padding: 10px 10px 0;
|
||||
padding: var(--spacer-8) 16px var(--spacer-8) 16px;
|
||||
|
||||
.input {
|
||||
color: light-dark(@dark, @beige);
|
||||
|
|
@ -57,7 +71,6 @@
|
|||
.tab.notes.active {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
margin-top: -10px; // will be removed once tab-navigation bottom margin is removed on all actor sheets
|
||||
scrollbar-gutter: unset;
|
||||
|
||||
// Add padding around top level level prosemirrors used for note tabs
|
||||
|
|
@ -66,6 +79,7 @@
|
|||
.editor-content {
|
||||
scrollbar-gutter: stable;
|
||||
padding-right: @right-padding;
|
||||
padding-bottom: 4px;
|
||||
}
|
||||
&.inactive {
|
||||
button.toggle {
|
||||
|
|
@ -76,7 +90,7 @@
|
|||
}
|
||||
}
|
||||
&.active {
|
||||
padding: 8px 0 4px 16px;
|
||||
padding: 8px 0 0 16px;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -7,9 +7,8 @@
|
|||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
overflow-y: auto;
|
||||
padding-bottom: 20px;
|
||||
.with-scroll-shadows();
|
||||
padding: 7px calc(12px - var(--scrollbar-width)) 4px 12px;
|
||||
.stable-scroll-container();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,12 +5,8 @@
|
|||
.application.sheet.daggerheart.actor.dh-style.adversary {
|
||||
.tab.features {
|
||||
.feature-section {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
overflow-y: auto;
|
||||
padding-bottom: 20px;
|
||||
.with-scroll-shadows();
|
||||
padding: 16px calc(16px - var(--scrollbar-width)) 4px 16px;
|
||||
.stable-scroll-container();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,9 +30,9 @@
|
|||
grid-row: 2;
|
||||
grid-column: 2;
|
||||
&.active {
|
||||
overflow: hidden;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
margin: 0 0 10px 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -9,16 +9,13 @@
|
|||
flex-direction: column;
|
||||
gap: 10px;
|
||||
height: 100%;
|
||||
overflow-y: auto;
|
||||
padding-top: 8px;
|
||||
padding-bottom: 20px;
|
||||
height: 100%;
|
||||
.with-scroll-shadows();
|
||||
padding: 12px calc(12px - var(--scrollbar-width)) 4px 12px;
|
||||
.stable-scroll-container();
|
||||
}
|
||||
|
||||
.characteristics-section {
|
||||
gap: 20px;
|
||||
padding: 0 10px;
|
||||
padding: 0 4px;
|
||||
}
|
||||
|
||||
.biography-section {
|
||||
|
|
|
|||
|
|
@ -8,9 +8,8 @@
|
|||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
overflow-y: auto;
|
||||
padding-bottom: 20px;
|
||||
.with-scroll-shadows();
|
||||
padding: 7px calc(12px - var(--scrollbar-width)) 4px 12px;
|
||||
.stable-scroll-container();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,9 +8,8 @@
|
|||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
overflow-y: auto;
|
||||
padding-bottom: 20px;
|
||||
.with-scroll-shadows();
|
||||
padding: 7px calc(12px - var(--scrollbar-width)) 4px 12px;
|
||||
.stable-scroll-container();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -19,16 +19,19 @@
|
|||
|
||||
.application.sheet.daggerheart.actor.dh-style.character {
|
||||
.character-header-sheet {
|
||||
padding: 0 15px;
|
||||
padding-top: var(--header-height);
|
||||
width: 100%;
|
||||
|
||||
> *:not(line-div, .tab-navigation) {
|
||||
padding-left: 15px;
|
||||
padding-right: 15px;
|
||||
}
|
||||
|
||||
.name-row {
|
||||
display: flex;
|
||||
gap: 6px;
|
||||
align-items: start;
|
||||
justify-content: space-between;
|
||||
padding: 0;
|
||||
padding-top: 5px;
|
||||
flex: 1;
|
||||
|
||||
|
|
@ -100,8 +103,8 @@
|
|||
.character-details {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
padding: 5px 0;
|
||||
margin-bottom: 8px;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 10px;
|
||||
font-size: var(--font-size-12);
|
||||
color: @color-text-emphatic;
|
||||
|
||||
|
|
@ -130,7 +133,6 @@
|
|||
.character-row {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding: 0;
|
||||
margin-bottom: 12px;
|
||||
|
||||
.resource-section {
|
||||
|
|
@ -218,12 +220,11 @@
|
|||
|
||||
.character-traits {
|
||||
display: flex;
|
||||
padding: 0;
|
||||
margin-bottom: 15px;
|
||||
justify-content: space-between;
|
||||
max-width: 38.5rem;
|
||||
gap: 0.5rem;
|
||||
padding-left: 0.5rem;
|
||||
margin-left: 0.5rem;
|
||||
|
||||
.trait {
|
||||
cursor: pointer;
|
||||
|
|
@ -325,5 +326,9 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
.tab-navigation button[data-action="openSettings"] {
|
||||
margin-right: 12px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
@import './sheet.less';
|
||||
@import './biography.less';
|
||||
@import './effects.less';
|
||||
@import './features.less';
|
||||
@import './header.less';
|
||||
@import './inventory.less';
|
||||
@import './loadout.less';
|
||||
@import './sheet.less';
|
||||
@import './sidebar.less';
|
||||
|
|
|
|||
|
|
@ -8,10 +8,8 @@
|
|||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
overflow-y: auto;
|
||||
margin-top: 20px;
|
||||
padding-bottom: 20px;
|
||||
.with-scroll-shadows();
|
||||
padding: 8px calc(12px - var(--scrollbar-width)) 4px 12px;
|
||||
.stable-scroll-container();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,11 +50,8 @@
|
|||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
height: 100%;
|
||||
overflow-y: auto;
|
||||
margin-top: 20px;
|
||||
padding-bottom: 20px;
|
||||
.with-scroll-shadows();
|
||||
padding: 8px calc(12px - var(--scrollbar-width)) 4px 12px;
|
||||
.stable-scroll-container();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@
|
|||
&.active {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
overflow: hidden;
|
||||
margin: 0 0 10px 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,10 @@
|
|||
@import '../../../utils/colors.less';
|
||||
@import '../../../utils/fonts.less';
|
||||
|
||||
.application.sheet.daggerheart.actor.dh-style.companion {
|
||||
.application.sheet.daggerheart.actor.dh-style.companion .tab.details.active {
|
||||
padding: 12px calc(12px - var(--scrollbar-width)) 4px 12px;
|
||||
.stable-scroll-container();
|
||||
|
||||
.partner-section,
|
||||
.attack-section,
|
||||
.experience-list {
|
||||
|
|
|
|||
|
|
@ -6,9 +6,8 @@
|
|||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
overflow-y: auto;
|
||||
padding-bottom: 20px;
|
||||
.with-scroll-shadows();
|
||||
padding: 7px calc(12px - var(--scrollbar-width)) 4px 12px;
|
||||
.stable-scroll-container();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,12 +5,8 @@
|
|||
.application.sheet.daggerheart.actor.dh-style.environment {
|
||||
.tab.features {
|
||||
.feature-section {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
overflow-y: auto;
|
||||
padding-bottom: 4px;
|
||||
.with-scroll-shadows();
|
||||
padding: 16px calc(16px - var(--scrollbar-width)) 4px 16px;
|
||||
.stable-scroll-container();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
@import './sheet.less';
|
||||
@import './features.less';
|
||||
@import './header.less';
|
||||
@import './potentialAdversaries.less';
|
||||
@import './sheet.less';
|
||||
|
|
|
|||
|
|
@ -6,9 +6,8 @@
|
|||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
overflow-y: auto;
|
||||
padding-bottom: 4px;
|
||||
.with-scroll-shadows();
|
||||
padding: 7px calc(12px - var(--scrollbar-width)) 4px 12px;
|
||||
.stable-scroll-container();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,9 +14,7 @@
|
|||
|
||||
.application.sheet.daggerheart.actor.dh-style.environment {
|
||||
.tab {
|
||||
flex: 1;
|
||||
overflow-y: auto;
|
||||
|
||||
&.active {
|
||||
overflow: hidden;
|
||||
display: flex;
|
||||
|
|
|
|||
|
|
@ -7,12 +7,8 @@
|
|||
}
|
||||
|
||||
.feature-section {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
overflow-y: auto;
|
||||
padding-bottom: 4px;
|
||||
.with-scroll-shadows();
|
||||
padding: 16px calc(16px - var(--scrollbar-width)) 4px 16px;
|
||||
.stable-scroll-container();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,7 +3,8 @@
|
|||
@import '../../../utils/mixin.less';
|
||||
|
||||
.application.sheet.daggerheart.actor.dh-style.party .tab.partyMembers {
|
||||
overflow: auto;
|
||||
padding: 12px calc(12px - var(--scrollbar-width)) 4px 12px;
|
||||
.stable-scroll-container();
|
||||
|
||||
.actions-section {
|
||||
display: flex;
|
||||
|
|
|
|||
|
|
@ -17,15 +17,8 @@
|
|||
});
|
||||
|
||||
.application.sheet.daggerheart.actor.dh-style.party {
|
||||
.tab {
|
||||
flex: 1;
|
||||
overflow-y: auto;
|
||||
scrollbar-gutter: stable;
|
||||
|
||||
&.active {
|
||||
overflow: auto;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
.tab.active {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -174,10 +174,10 @@
|
|||
--fade-start: 0;
|
||||
}
|
||||
10%, 100% {
|
||||
--fade-start: 12px;
|
||||
--fade-start: 14px;
|
||||
}
|
||||
0%, 90% {
|
||||
--fade-end: 12px;
|
||||
--fade-end: 14px;
|
||||
}
|
||||
100% {
|
||||
--fade-end: 0;
|
||||
|
|
@ -198,3 +198,9 @@
|
|||
transparent 100%
|
||||
);
|
||||
}
|
||||
|
||||
.stable-scroll-container() {
|
||||
overflow-y: auto;
|
||||
scrollbar-gutter: stable;
|
||||
.with-scroll-shadows();
|
||||
}
|
||||
|
|
@ -1,14 +1,15 @@
|
|||
<section class='tab {{tabs.features.cssClass}} {{tabs.features.id}}' data-tab='{{tabs.features.id}}'
|
||||
data-group='{{tabs.features.group}}'>
|
||||
<div class="feature-section">
|
||||
{{> 'daggerheart.inventory-items'
|
||||
title=tabs.features.label
|
||||
type='feature'
|
||||
collection=@root.features
|
||||
hideContextMenu=true
|
||||
hideModifyControls=true
|
||||
canCreate=@root.editable
|
||||
showActions=@root.editable
|
||||
}}
|
||||
<div class="feature-section items-list">
|
||||
{{#each @root.features as |item|}}
|
||||
{{> "daggerheart.inventory-item"
|
||||
item=item
|
||||
type="feature"
|
||||
actorType=@root.document.type
|
||||
hideContextMenu=true
|
||||
hideModifyControls=true
|
||||
showActions=@root.editable
|
||||
}}
|
||||
{{/each}}
|
||||
</div>
|
||||
</section>
|
||||
|
|
@ -79,8 +79,6 @@
|
|||
{{/if}}
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="character-row">
|
||||
|
|
|
|||
|
|
@ -3,15 +3,16 @@
|
|||
data-tab='{{tabs.features.id}}'
|
||||
data-group='{{tabs.features.group}}'
|
||||
>
|
||||
<div class="feature-section">
|
||||
{{> 'daggerheart.inventory-items'
|
||||
title=tabs.features.label
|
||||
type='feature'
|
||||
collection=@root.features
|
||||
hideContextMenu=true
|
||||
hideModifyControls=true
|
||||
canCreate=@root.editable
|
||||
showActions=@root.editable
|
||||
}}
|
||||
<div class="feature-section items-list">
|
||||
{{#each @root.features as |item|}}
|
||||
{{> "daggerheart.inventory-item"
|
||||
item=item
|
||||
type="feature"
|
||||
actorType=@root.document.type
|
||||
hideContextMenu=true
|
||||
hideModifyControls=true
|
||||
showActions=@root.editable
|
||||
}}
|
||||
{{/each}}
|
||||
</div>
|
||||
</section>
|
||||
|
|
@ -1,14 +1,15 @@
|
|||
<section class='tab {{tabs.features.cssClass}} {{tabs.features.id}}' data-tab='{{tabs.features.id}}'
|
||||
data-group='{{tabs.features.group}}'>
|
||||
<div class="feature-section">
|
||||
{{> 'daggerheart.inventory-items'
|
||||
title=tabs.features.label
|
||||
type='feature'
|
||||
collection=@root.features
|
||||
hideContextMenu=true
|
||||
hideModifyControls=true
|
||||
canCreate=@root.editable
|
||||
showActions=@root.editable
|
||||
}}
|
||||
<div class="feature-section items-list">
|
||||
{{#each @root.features as |item|}}
|
||||
{{> "daggerheart.inventory-item"
|
||||
item=item
|
||||
type="feature"
|
||||
actorType=@root.document.type
|
||||
hideContextMenu=true
|
||||
hideModifyControls=true
|
||||
showActions=@root.editable
|
||||
}}
|
||||
{{/each}}
|
||||
</div>
|
||||
</section>
|
||||
Loading…
Add table
Add a link
Reference in a new issue