updated card images
This commit is contained in:
@@ -814,6 +814,27 @@
|
||||
return window.TarotCardImages.resolveTarotCardImage(name) || null;
|
||||
}
|
||||
|
||||
function openTarotCardInfo(cardName, trumpNumber = null) {
|
||||
const detail = {};
|
||||
const normalizedCardName = toDisplayText(cardName);
|
||||
const normalizedTrumpNumber = toFiniteNumber(trumpNumber);
|
||||
|
||||
if (normalizedCardName) {
|
||||
detail.cardName = normalizedCardName;
|
||||
}
|
||||
|
||||
if (normalizedTrumpNumber != null) {
|
||||
detail.trumpNumber = normalizedTrumpNumber;
|
||||
}
|
||||
|
||||
if (!detail.cardName && detail.trumpNumber == null) {
|
||||
return false;
|
||||
}
|
||||
|
||||
document.dispatchEvent(new CustomEvent("nav:tarot-trump", { detail }));
|
||||
return true;
|
||||
}
|
||||
|
||||
function openTarotCardLightbox(cardName, fallbackSrc = "", fallbackLabel = "") {
|
||||
const openLightbox = window.TarotUiLightbox?.open;
|
||||
if (typeof openLightbox !== "function") {
|
||||
@@ -867,6 +888,7 @@
|
||||
getWallFaceLetter,
|
||||
getWallTarotCard,
|
||||
resolveCardImageUrl,
|
||||
openTarotCardInfo,
|
||||
openTarotCardLightbox,
|
||||
MOTHER_CONNECTORS,
|
||||
formatDirectionName,
|
||||
|
||||
Reference in New Issue
Block a user