Compare commits
3 Commits
db77413296
...
696c427ea6
Author | SHA1 | Date |
---|---|---|
vilmibm | 696c427ea6 | |
vilmibm | e40eb87e1d | |
vilmibm | 84ae05d776 |
|
@ -9,10 +9,10 @@
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
<div id="deck"></div>
|
||||||
|
<div id="info" style="height: 275px; width: 500px; margin-left: 200px; overflow:auto"></div>
|
||||||
<button id="reset">reset</button>
|
<button id="reset">reset</button>
|
||||||
<br>
|
<br>
|
||||||
<div id="deck"></div>
|
|
||||||
<div id="info" style="height: 325px; width: 500px; margin-left: 200px; overflow:auto"></div>
|
|
||||||
<div id="table"></div>
|
<div id="table"></div>
|
||||||
|
|
||||||
<div class="blueprint card">
|
<div class="blueprint card">
|
||||||
|
|
11
tarot.js
11
tarot.js
|
@ -1,6 +1,15 @@
|
||||||
import CardDB from './carddb.js';
|
import CardDB from './carddb.js';
|
||||||
import CardPile from './cardpile.js';
|
import CardPile from './cardpile.js';
|
||||||
|
|
||||||
|
/* TODO
|
||||||
|
*
|
||||||
|
* - drag and drop the cards wherever
|
||||||
|
* - card front art
|
||||||
|
* - card back art for deck
|
||||||
|
* - fill in interpretive descriptions
|
||||||
|
* - fill in rest of keywords
|
||||||
|
*/
|
||||||
|
|
||||||
class Tarot {
|
class Tarot {
|
||||||
constructor() {
|
constructor() {
|
||||||
this.cardDB = new CardDB();
|
this.cardDB = new CardDB();
|
||||||
|
@ -97,7 +106,7 @@ class Tarot {
|
||||||
const cardElem = bp.cloneNode(true);
|
const cardElem = bp.cloneNode(true);
|
||||||
cardElem.classList.remove("blueprint");
|
cardElem.classList.remove("blueprint");
|
||||||
cardElem.setAttribute("data-cardName", cardName)
|
cardElem.setAttribute("data-cardName", cardName)
|
||||||
cardElem.setAttribute("style", "float:left; margin-right: 20px; width: 150px; height: 250px; border: 1px solid pink;");
|
cardElem.setAttribute("style", "float:left; margin-right: 20px; width: 150px; height: 250px; border: 1px solid grey; box-shadow: 2px 2px 2px pink; text-align:center;");
|
||||||
cardElem.querySelector("span").innerHTML = cardName;
|
cardElem.querySelector("span").innerHTML = cardName;
|
||||||
cardElem.addEventListener("mouseenter", this.render.bind(this));
|
cardElem.addEventListener("mouseenter", this.render.bind(this));
|
||||||
elem.append(cardElem);
|
elem.append(cardElem);
|
||||||
|
|
Loading…
Reference in New Issue