Web Dev Solutions

Catalin Mititiuc

aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/counter.js')
-rw-r--r--src/modules/counter.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/modules/counter.js b/src/modules/counter.js
index 162e56e..21a0238 100644
--- a/src/modules/counter.js
+++ b/src/modules/counter.js
@@ -44,6 +44,9 @@ export default class Counter {
return this.svg.querySelectorAll(`use[data-allegiance="${al}"][data-number="${n}"]`);
}
+ getTrace({ dataset: { allegiance, number } }) {
+ return this.svg.querySelector(this.traceSelector(number, allegiance));
+ }
getCellPosition(cell) {
let pt = new DOMPoint(0, 0),
@@ -144,9 +147,6 @@ export default class Counter {
const counter = this.getCounter(troopAllegiance, troopNumber),
lockedSl = this.svg.querySelector('.sight-line:not(.active)');
- counter.setAttributeNS(null, 'x', 0);
- counter.setAttributeNS(null, 'y', 0);
-
if (!lockedSl) {
this.container.sightLine.clear();
} else {