Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[#2018] Replace titles with tooltips on sheets #2074

Merged
merged 3 commits into from
Jan 20, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Whitespace adjustments.
  • Loading branch information
Fyorl committed Jan 20, 2023
commit 0d3e012304134da28757563e2675412ac0438618
10 changes: 6 additions & 4 deletions templates/actors/character-sheet.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -159,9 +159,11 @@
<span class="ability-mod" data-tooltip="DND5E.Modifier">
{{numberFormat ability.mod decimals=0 sign=true}}
</span>
<input type="hidden" name="system.abilities.{{id}}.proficient" value="{{ability.baseProf}}" data-dtype="Number"/>
<a class="proficiency-toggle ability-proficiency"
data-tooltip="DND5E.Proficiency">{{{ability.icon}}}</a>
<input type="hidden" name="system.abilities.{{id}}.proficient" value="{{ability.baseProf}}"
data-dtype="Number"/>
<a class="proficiency-toggle ability-proficiency" data-tooltip="DND5E.Proficiency">
{{{ability.icon}}}
</a>
<span class="ability-save" data-tooltip="DND5E.SavingThrow">
{{numberFormat ability.save decimals=0 sign=true}}
</span>
Expand All @@ -179,7 +181,7 @@
{{#with (lookup ../skills s) as |skill|}}
<li class="skill flexrow {{#if skill.value}}proficient{{/if}}" data-skill="{{s}}">
<input type="hidden" name="system.skills.{{s}}.value"
value="{{skill.baseValue}}" data-dtype="Number">
value="{{skill.baseValue}}" data-dtype="Number">
<a class="proficiency-toggle skill-proficiency" data-tooltip="{{skill.hover}}">{{{skill.icon}}}</a>
<div class="skill-name-controls">
<h4 class="skill-name rollable">{{skill.label}}</h4>
Expand Down
4 changes: 3 additions & 1 deletion templates/actors/group-sheet.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@
<li class="attribute movement">
<h4 class="attribute-name box-title">{{localize "DND5E.Movement"}}</h4>
<a class="action-button config-button" data-action="movementConfig"
data-tooltip="DND5E.MovementConfig"><i class="fas fa-cog"></i></a>
data-tooltip="DND5E.MovementConfig">
<i class="fas fa-cog"></i>
</a>
<div class="attribute-value">
<span>{{movement.primary}}</span>
</div>
Expand Down
28 changes: 15 additions & 13 deletions templates/actors/npc-sheet.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
</li>
<li>
<input type="text" name="system.details.source" value="{{system.details.source}}"
placeholder="{{ localize 'DND5E.Source' }}"/>
placeholder="{{ localize 'DND5E.Source' }}"/>
</li>
</ul>

Expand Down Expand Up @@ -124,11 +124,13 @@
{{numberFormat ability.mod decimals=0 sign=true}}
</span>
<input type="hidden" name="system.abilities.{{id}}.proficient" value="{{ability.baseProf}}"
data-dtype="Number"/>
<a class="proficiency-toggle ability-proficiency"
data-tooltip="DND5E.Proficiency">{{{ability.icon}}}</a>
data-dtype="Number"/>
<a class="proficiency-toggle ability-proficiency" data-tooltip="DND5E.Proficiency">
{{{ability.icon}}}
</a>
<span class="ability-save" data-tooltip="DND5E.SavingThrow">
{{numberFormat ability.save decimals=0 sign=true}}</span>
{{numberFormat ability.save decimals=0 sign=true}}
</span>
</div>
<a class="config-button" data-action="ability" data-tooltip="DND5E.AbilityConfigure">
<i class="fas fa-cog"></i>
Expand Down Expand Up @@ -170,8 +172,8 @@
<h4>{{ localize "DND5E.LegAct" }}</h4>
<div class="counter-value">
<input name="system.resources.legact.value" type="text" step="any"
value="{{system.resources.legact.value}}" placeholder="0"
data-tooltip="DND5E.LegActRemaining" data-dtype="Number">
value="{{system.resources.legact.value}}" placeholder="0"
data-tooltip="DND5E.LegActRemaining" data-dtype="Number">
<span class="sep">/</span>
{{numberInput system.resources.legact.max name="system.resources.legact.max" min=0 step=1
placeholder=0}}
Expand All @@ -181,8 +183,8 @@
<h4>{{ localize "DND5E.LegRes" }}</h4>
<div class="counter-value">
<input name="system.resources.legres.value" type="text" step="any"
value="{{system.resources.legres.value}}" placeholder="0"
data-tooltip="DND5E.LegResRemaining" data-dtype="Number">
value="{{system.resources.legres.value}}" placeholder="0"
data-tooltip="DND5E.LegResRemaining" data-dtype="Number">
<span class="sep">/</span>
{{numberInput system.resources.legres.max name="system.resources.legres.max" min=0 step=1
placeholder=0}}
Expand All @@ -192,11 +194,11 @@
<h4>{{ localize "DND5E.LairAct" }}</h4>
<div class="counter-value">
<input name="system.resources.lair.value" type="checkbox"
value="{{system.resources.lair.value}}"
data-dtype="Boolean" {{checked system.resources.lair.value}}>
value="{{system.resources.lair.value}}"
data-dtype="Boolean" {{checked system.resources.lair.value}}>
<input name="system.resources.lair.initiative" type="number" step="any"
value="{{system.resources.lair.initiative}}"
placeholder="20" data-tooltip="DND5E.LairActionInitiative">
value="{{system.resources.lair.initiative}}"
placeholder="20" data-tooltip="DND5E.LairActionInitiative">
</div>
</div>
</div>
Expand Down
4 changes: 2 additions & 2 deletions templates/actors/parts/actor-inventory.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<h3>
{{localize "DND5E.Currency"}}
<a class="action-button currency-convert {{rollableClass}}" data-action="convertCurrency"
data-tooltip="DND5E.CurrencyConvert">
data-tooltip="DND5E.CurrencyConvert">
<i class="fas fa-coins"></i>
</a>
</h3>
Expand Down Expand Up @@ -70,7 +70,7 @@
{{#if ctx.attunement}}
<div class="item-detail attunement">
<i class="fas {{ctx.attunement.icon}} {{ctx.attunement.cls}}"
data-tooltip="{{ctx.attunement.title}}"></i>
data-tooltip="{{ctx.attunement.title}}"></i>
</div>
{{/if}}
{{/if}}
Expand Down
5 changes: 3 additions & 2 deletions templates/actors/parts/actor-spellbook.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,9 @@
{{else}}
<li class="item flexrow inventory-header spellbook-header spellbook-empty">
<div class="item-controls flexrow">
<a class="item-control item-create" data-tooltip="DND5E.SpellCreate"
data-type="spell" data-level="{{lvl}}"><i class="fas fa-plus"></i> {{localize "DND5E.SpellAdd"}}</a>
<a class="item-control item-create" data-tooltip="DND5E.SpellCreate" data-type="spell" data-level="{{lvl}}">
<i class="fas fa-plus"></i> {{localize "DND5E.SpellAdd"}}
</a>
</div>
</li>
<li class="item flexrow"><p class="notes">{{localize "DND5E.NoSpellLevels"}}</p></li>
Expand Down
2 changes: 1 addition & 1 deletion templates/apps/actor-type.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
{{/each}}
<li class="custom-type form-group">
<input type="radio" name="value" value="custom"
data-tooltip="{{custom.label}}" {{checked custom.chosen}}>
data-tooltip="{{custom.label}}" {{checked custom.chosen}}>
<label>{{custom.label}}</label>
<input type="text" name="custom" value="{{custom.value}}"/>
</li>
Expand Down
2 changes: 1 addition & 1 deletion templates/apps/hit-dice-config.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<div class="form-fields">
<button class="decrement" type="button">-</button>
<input data-tooltip="DND5E.HitDiceRemaining" class="current"
name="{{this.classItemId}}" type="number" value="{{this.currentHitDice}}">
name="{{this.classItemId}}" type="number" value="{{this.currentHitDice}}">
<span class="sep">/</span>
<input data-tooltip="DND5E.HitDiceMax" class="max" type="number" value="{{this.maxHitDice}}" disabled>
<button class="increment" type="button">+</button>
Expand Down
6 changes: 3 additions & 3 deletions templates/items/parts/item-activation.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,10 @@
<label>{{ localize "DND5E.Range" }}</label>
<div class="form-fields">
<input type="number" step="any" name="system.range.value" value="{{system.range.value}}"
placeholder="{{localize 'DND5E.Normal'}}" data-tooltip="DND5E.RangeNormal">
placeholder="{{localize 'DND5E.Normal'}}" data-tooltip="DND5E.RangeNormal">
<span class="sep">/</span>
<input type="number" step="any" name="system.range.long" value="{{system.range.long}}"
placeholder="{{localize 'DND5E.Long'}}" data-tooltip="DND5E.RangeLong">
placeholder="{{localize 'DND5E.Long'}}" data-tooltip="DND5E.RangeLong">
<select name="system.range.units" data-tooltip="DND5E.RangeUnits">
{{selectOptions config.distanceUnits selected=system.range.units blank=(localize "DND5E.None")}}
</select>
Expand Down Expand Up @@ -101,7 +101,7 @@
<label>{{ localize "DND5E.LimitedUses" }}</label>
<div class="form-fields">
<input type="number" step="any" name="system.uses.value"
value="{{system.uses.value}}" data-tooltip="DND5E.UsesAvailable">
value="{{system.uses.value}}" data-tooltip="DND5E.UsesAvailable">
<span class="sep">{{localize "DND5E.of"}}</span>
<input type="text" name="system.uses.max" value="{{source.uses.max}}"
data-tooltip="DND5E.UsesMax" data-formula-editor>
Expand Down
4 changes: 2 additions & 2 deletions templates/items/parts/item-advancement.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@
{{#if isEmbedded}}
{{#if advancementEditable}}
<a class="item-control" data-action="toggle-configuration"
data-tooltip="DND5E.AdvancementConfigurationActionDisable">
data-tooltip="DND5E.AdvancementConfigurationActionDisable">
<i class="fas fa-lock-open"></i> {{localize "DND5E.AdvancementConfigurationModeEnabled"}}
</a>
{{else}}
<a class="item-control" data-action="toggle-configuration"
data-tooltip="DND5E.AdvancementConfigurationActionEnable">
data-tooltip="DND5E.AdvancementConfigurationActionEnable">
<i class="fas fa-lock"></i> {{localize "DND5E.AdvancementConfigurationModeDisabled"}}
</a>
{{/if}}
Expand Down