Skip to content

Commit

Permalink
Add Toggle support to Familiars (#16582)
Browse files Browse the repository at this point in the history
  • Loading branch information
DocSchlock authored Sep 20, 2024
1 parent 0468fee commit ca58c39
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/module/actor/familiar/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ type SourceOmission =
| "customModifiers"
| "details"
| "perception"
| "toggles"
| "resources"
| "saves"
| "skills"
Expand Down
28 changes: 28 additions & 0 deletions src/styles/actor/familiar/_index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,34 @@
}
}

.section-container.toggles ul.option-toggles {
display: flex;
flex-direction: column;
gap: var(--space-4);
list-style: none;

> li {
width: 100%;

label {
display: flex;
align-items: center;
gap: var(--space-4);

input {
margin: 0;
padding: 0;
}
}

select {
background: none;
margin-left: 0.25em;
text-transform: none;
}
}
}

.familiar-section {
flex-basis: 50%;
display: flex;
Expand Down
5 changes: 5 additions & 0 deletions static/templates/actors/familiar/sheet.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,11 @@
</div>
</div>
{{!-- ABILITIES --}}
{{#if toggles.actions}}
<div class="toggles section-container headerless">
{{> "systems/pf2e/templates/actors/partials/toggles.hbs" toggles=toggles.actions}}
</div>
{{/if}}
<div class="section-container">
<div class="section-header">
<h4>{{localize "PF2E.Familiar.AbilitiesLabel"}}</h4>
Expand Down

0 comments on commit ca58c39

Please sign in to comment.