From 9d2cf4c2643ab1adb09b3700b2b547b69dbeb514 Mon Sep 17 00:00:00 2001 From: badcold Date: Sun, 21 Apr 2024 10:48:35 +0200 Subject: [PATCH] fixup contract reward name + spacing between filters --- index.ts | 20 ++++++++++---------- style.css | 4 ++++ 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/index.ts b/index.ts index 94693f3..dc75241 100644 --- a/index.ts +++ b/index.ts @@ -2,7 +2,7 @@ let contracts; let costs = ["sheep", "cow", "wool", "bread", "cheese", "whisky"] let rewards = ["cotton", "tobacco", "sugarCane", "upgrade", "expansion", "gold", "hops"] -let exports = ["cotton", "tobacco", "sugarCane"] +let imports = ["cotton", "tobacco", "sugarCane"] let bonuses = ["upgrade", "expansion", "gold", "hops"] function init() { @@ -43,11 +43,11 @@ function buildHeader() { Costs: ${buildCheckBoxes(costs)} -
- - - Exports: - ${buildCheckBoxes(exports)} +
+ + + Imports: + ${buildCheckBoxes(imports)}
@@ -71,8 +71,8 @@ function setAllCostsCheckboxes(value: boolean) { update(); } -function setAllExportsCheckboxes(value: boolean) { - for (const filter of exports) { +function setAllImportsCheckboxes(value: boolean) { + for (const filter of imports) { let checkBox = document.getElementById(filter) as HTMLInputElement; checkBox.checked = value; } @@ -97,9 +97,9 @@ function buildCheckBoxes(filters: string[]): string { function buildCheckBox(filterKey: string): string { let capitalized = filterKey[0].toUpperCase() + filterKey.slice(1); - return ` + return ` - `; + `; } diff --git a/style.css b/style.css index 99ac353..24ea57f 100644 --- a/style.css +++ b/style.css @@ -7,6 +7,10 @@ } } +.filterElement { + margin: 15px; +} + .contract { margin: 5px; float: left;