summaryrefslogtreecommitdiff
path: root/scripts/gui/table.js
diff options
context:
space:
mode:
authorKyle Gunger <kgunger12@gmail.com>2022-07-20 10:58:42 -0400
committerKyle Gunger <kgunger12@gmail.com>2022-07-20 10:58:42 -0400
commit68db9abc7a02c78a0f170003c32d1fcd796eb212 (patch)
tree602e9be8f4641991a9666315426a8ca10807c78c /scripts/gui/table.js
parent5207f04d5b775bf4805d83c81aaad1cfcf3fe68a (diff)
Replace var with let + visual tweaks
- Replace var with let in most of my code - No longer bring cards to forfront of deck when hovering - Tweaks for dropdown selector input
Diffstat (limited to 'scripts/gui/table.js')
-rw-r--r--scripts/gui/table.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/scripts/gui/table.js b/scripts/gui/table.js
index 46a520b..911e513 100644
--- a/scripts/gui/table.js
+++ b/scripts/gui/table.js
@@ -63,7 +63,7 @@ class Table{
// {data.options object} options as found in Deck constructor
newDeck(data)
{
- var d = new Deck(data.id, data.options);
+ let d = new Deck(data.id, data.options);
this.decks[data.id] = d;
this.root.appendChild(d.e);
}
@@ -75,7 +75,7 @@ class Table{
// {data.deck} the id of the deck to add the card to
newCard(data)
{
- var c = new Card(data.id, data.data);
+ let c = new Card(data.id, data.data);
this.cards[data.id] = c;
this.decks[data.deck].appendCard(c);
this.drag.addTarget(c.e);
@@ -165,8 +165,8 @@ class Table{
if(event.drag.length < 1)
return;
- var c = event.drag[0].e.card;
- var d = this.checkDeck(event.x, event.y);
+ let c = event.drag[0].e.card;
+ let d = this.checkDeck(event.x, event.y);
if(c !== null)
{