Web Dev Solutions

Catalin Mititiuc

aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCatalin Mititiuc <webdevcat@proton.me>2024-05-28 14:45:20 -0700
committerCatalin Mititiuc <webdevcat@proton.me>2024-05-28 14:45:20 -0700
commite8fbe161e473a949f776f89d94e9816a64cd3114 (patch)
tree5def4f8e9e499d3280bc83c5f23edd642850193c /src/modules
parenta34cd1a5414eec5a059c5f20a3940bf4ef6b977e (diff)
Import mapsheets.svg
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/record_sheet.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/modules/record_sheet.js b/src/modules/record_sheet.js
index 185a96c..61cea98 100644
--- a/src/modules/record_sheet.js
+++ b/src/modules/record_sheet.js
@@ -1,5 +1,7 @@
import { Observable } from "./observable";
// import counters from '../../public/assets/images/counters.svg';
+// console.log('counters', counters);
+
// import svg from '../../public/assets/images/counters.svg';
// const doc = new DOMParser().parseFromString(svg, 'image/svg+xml');
@@ -40,7 +42,9 @@ function createIcon(number) {
icon.setAttributeNS(null, 'viewBox', '-6 -6 12 12');
icon.setAttribute('xmlns', svgns);
- use.setAttributeNS(null, 'href', `assets/images/counters.svg?v=${cacheBuster}#counter-base`);
+ // use.setAttributeNS(null, 'href', `assets/images/counters.svg?v=${cacheBuster}#counter-base`);
+ use.setAttributeNS(null, 'href', `assets/images/counters.svg#counter-base`);
+ // use.setAttributeNS(null, 'href', `${counters}#counter-base`);
text.textContent = number;
@@ -64,8 +68,9 @@ function createWeaponIcon(type) {
icon.setAttribute('xmlns', svgns);
icon.classList.add('weapon-icon');
- use.setAttributeNS(null, 'href', `assets/images/counters.svg?v=${cacheBuster}#${type}`);
+ // use.setAttributeNS(null, 'href', `assets/images/counters.svg?v=${cacheBuster}#${type}`);
// use.setAttributeNS(null, 'href', `${counters}#${type}`);
+ use.setAttributeNS(null, 'href', `assets/images/counters.svg#${type}`);
icon.appendChild(use);
// icon.appendChild(document.importNode(doc.querySelector(`#${type}`), true));