mirror of
https://github.com/Investigamer/cardconjurer.git
synced 2025-07-27 05:14:53 -05:00
Merge pull request #1 from RojjaCebolla/patch-1
Use tilde as shorthand for {cardname}
This commit is contained in:
@@ -217,7 +217,7 @@
|
|||||||
<h5 class='margin-top'>Text Codes:</h5>
|
<h5 class='margin-top'>Text Codes:</h5>
|
||||||
<div class='text-codes margin-bottom padding'>
|
<div class='text-codes margin-bottom padding'>
|
||||||
<h5>Code</h5><h5>Result</h5>
|
<h5>Code</h5><h5>Result</h5>
|
||||||
<h5>{cardname}</h5><h5>Inserts the name of the card</h5>
|
<h5>{cardname}</h5><h5>Inserts the name of the card (or use a tilde: ~)</h5>
|
||||||
<h5>{-}</h5><h5>Inserts an em-dash</h5>
|
<h5>{-}</h5><h5>Inserts an em-dash</h5>
|
||||||
<h5>{i}</h5><h5>Italicizes text</h5>
|
<h5>{i}</h5><h5>Italicizes text</h5>
|
||||||
<h5>{/i}</h5><h5>Removes italicization</h5>
|
<h5>{/i}</h5><h5>Removes italicization</h5>
|
||||||
|
@@ -891,8 +891,8 @@ function writeText(textObject, targetContext) {
|
|||||||
rawText = params.get('copyright'); //so people using CC for custom card games without WotC's IP can customize their copyright info
|
rawText = params.get('copyright'); //so people using CC for custom card games without WotC's IP can customize their copyright info
|
||||||
if (rawText == 'none') { rawText = ''; }
|
if (rawText == 'none') { rawText = ''; }
|
||||||
}
|
}
|
||||||
if (rawText.toLowerCase().includes('{cardname}')) {
|
if (rawText.toLowerCase().includes('{cardname}' || '~')) {
|
||||||
rawText = rawText.replace(/{cardname}/ig, getCardName());
|
rawText = rawText.replace(/{cardname}|~/ig, getCardName());
|
||||||
}
|
}
|
||||||
if (document.querySelector('#info-artist').value == '') {
|
if (document.querySelector('#info-artist').value == '') {
|
||||||
rawText = rawText.replace('\uFFEE{elemidinfo-artist}', '');
|
rawText = rawText.replace('\uFFEE{elemidinfo-artist}', '');
|
||||||
|
Reference in New Issue
Block a user