diff --git a/lang/en.json b/lang/en.json index cf105df..9ae578d 100644 --- a/lang/en.json +++ b/lang/en.json @@ -5,5 +5,9 @@ "SETTINGS.SimpleInitFormulaL": "Enter an initiative formula, such as d20+@dex", "SIMPLE.NotifyInitFormulaUpdated": "Initiative formula was updated to:", - "SIMPLE.NotifyInitFormulaInvalid": "Initiative formula was invalid:" + "SIMPLE.NotifyInitFormulaInvalid": "Initiative formula was invalid:", + + "SIMPLE.ResourceMin": "Min", + "SIMPLE.ResourceValue": "Value", + "SIMPLE.ResourceMax": "Max" } \ No newline at end of file diff --git a/module/actor-sheet.js b/module/actor-sheet.js index f4f7efb..86a97b1 100644 --- a/module/actor-sheet.js +++ b/module/actor-sheet.js @@ -21,9 +21,10 @@ export class SimpleActorSheet extends ActorSheet { /** @override */ getData() { const data = super.getData(); - data.dtypes = ["String", "Number", "Boolean", "Formula"]; + data.dtypes = ["String", "Number", "Boolean", "Formula", "Resource"]; for ( let attr of Object.values(data.data.attributes) ) { attr.isCheckbox = attr.dtype === "Boolean"; + attr.isResource = attr.dtype === "Resource"; } data.shorthand = !!game.settings.get("worldbuilding", "macroShorthand"); return data; diff --git a/module/item-sheet.js b/module/item-sheet.js index c516f1b..44ad27b 100644 --- a/module/item-sheet.js +++ b/module/item-sheet.js @@ -20,9 +20,10 @@ export class SimpleItemSheet extends ItemSheet { /** @override */ getData() { const data = super.getData(); - data.dtypes = ["String", "Number", "Boolean", "Formula"]; + data.dtypes = ["String", "Number", "Boolean", "Formula", "Resource"]; for ( let attr of Object.values(data.data.attributes) ) { attr.isCheckbox = attr.dtype === "Boolean"; + attr.isResource = attr.dtype === "Resource"; } return data; } diff --git a/styles/simple.css b/styles/simple.css index 38e13fc..b6d6d9a 100644 --- a/styles/simple.css +++ b/styles/simple.css @@ -144,6 +144,17 @@ line-height: 28px; border: none; } +.worldbuilding .attributes-list .attribute-col label { + font-size: 10px; + text-align: center; + line-height: 1; +} +.worldbuilding .attributes-list .attribute-col input { + font-size: 11px; + text-align: center; + line-height: 1; + height: 50%; +} .worldbuilding.sheet.actor { min-width: 560px; min-height: 420px; diff --git a/styles/simple.less b/styles/simple.less index deb4c89..06402e1 100644 --- a/styles/simple.less +++ b/styles/simple.less @@ -164,6 +164,21 @@ line-height: 28px; border: none; } + + .attribute-col { + label { + font-size: 10px; + text-align: center; + line-height: 1; + } + + input { + font-size: 11px; + text-align: center; + line-height: 1; + height: 50%; + } + } } } diff --git a/templates/actor-sheet.html b/templates/actor-sheet.html index d83d203..555bb86 100644 --- a/templates/actor-sheet.html +++ b/templates/actor-sheet.html @@ -77,10 +77,30 @@ {{#each data.attributes as |attr key|}}