mirror of
https://github.com/standardebooks/web.git
synced 2025-07-16 03:16:36 -04:00
Tweak wanted list template structure
This commit is contained in:
parent
b8690f91b5
commit
e4e945f63f
3 changed files with 39 additions and 49 deletions
|
@ -1,34 +0,0 @@
|
||||||
<?
|
|
||||||
/**
|
|
||||||
* @var Ebook $ebook
|
|
||||||
*/
|
|
||||||
|
|
||||||
if(!isset($ebook->EbookPlaceholder)){
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
$showPlaceholderMetadata = $showPlaceholderMetadata ?? false;
|
|
||||||
?>
|
|
||||||
<li>
|
|
||||||
<p>
|
|
||||||
<? if(isset($ebook->EbookPlaceholder->TranscriptionUrl)){ ?><a href="<?= $ebook->EbookPlaceholder->TranscriptionUrl ?>"><? } ?><i><?= Formatter::EscapeHtml($ebook->Title) ?></i><? if(isset($ebook->EbookPlaceholder->TranscriptionUrl)){ ?></a><? } ?>
|
|
||||||
|
|
||||||
|
|
||||||
by <?= Formatter::EscapeHtml($ebook->AuthorsString) ?>. <?= $ebook->ContributorsHtml ?>
|
|
||||||
|
|
||||||
<? foreach($ebook->CollectionMemberships as $index => $collectionMembership){ ?>
|
|
||||||
<? if($index == 0){ ?><?= Template::CollectionDescriptor(['collectionMembership' => $collectionMembership]) ?><? }else{ ?><?= lcfirst(Template::CollectionDescriptor(['collectionMembership' => $collectionMembership])) ?><? } ?><? if($index < sizeof($ebook->CollectionMemberships) - 1){ ?>, <? } ?><? if($index == sizeof($ebook->CollectionMemberships) - 1){ ?>.<? } ?>
|
|
||||||
<? } ?>
|
|
||||||
|
|
||||||
<? if(isset($ebook->EbookPlaceholder->Notes)){ ?>
|
|
||||||
<?= Formatter::MarkdownToHtml($ebook->EbookPlaceholder->Notes, true) ?>
|
|
||||||
<? } ?>
|
|
||||||
<? if($showPlaceholderMetadata){ ?>
|
|
||||||
— <a href="<?= $ebook->Url ?>">View placeholder.</a>
|
|
||||||
<? } ?>
|
|
||||||
|
|
||||||
<? if($ebook->EbookPlaceholder->IsPatron){ ?>
|
|
||||||
<a class="patron-selection" href="/donate#patrons-circle">Patron selection!</a>
|
|
||||||
<? } ?>
|
|
||||||
</p>
|
|
||||||
</li>
|
|
34
templates/WantedEbooksList.php
Normal file
34
templates/WantedEbooksList.php
Normal file
|
@ -0,0 +1,34 @@
|
||||||
|
<?
|
||||||
|
/**
|
||||||
|
* @var array<Ebook> $ebooks
|
||||||
|
*/
|
||||||
|
|
||||||
|
$showPlaceholderMetadata = $showPlaceholderMetadata ?? false;
|
||||||
|
?>
|
||||||
|
<ul class="wanted-list">
|
||||||
|
<? foreach($ebooks as $ebook){ ?>
|
||||||
|
<li>
|
||||||
|
<p>
|
||||||
|
<? if(isset($ebook->EbookPlaceholder->TranscriptionUrl)){ ?><a href="<?= $ebook->EbookPlaceholder->TranscriptionUrl ?>"><? } ?><i><?= Formatter::EscapeHtml($ebook->Title) ?></i><? if(isset($ebook->EbookPlaceholder->TranscriptionUrl)){ ?></a><? } ?>
|
||||||
|
|
||||||
|
|
||||||
|
by <?= Formatter::EscapeHtml($ebook->AuthorsString) ?>. <?= $ebook->ContributorsHtml ?>
|
||||||
|
|
||||||
|
<? foreach($ebook->CollectionMemberships as $index => $collectionMembership){ ?>
|
||||||
|
<? if($index == 0){ ?><?= Template::CollectionDescriptor(['collectionMembership' => $collectionMembership]) ?><? }else{ ?><?= lcfirst(Template::CollectionDescriptor(['collectionMembership' => $collectionMembership])) ?><? } ?><? if($index < sizeof($ebook->CollectionMemberships) - 1){ ?>, <? } ?><? if($index == sizeof($ebook->CollectionMemberships) - 1){ ?>.<? } ?>
|
||||||
|
<? } ?>
|
||||||
|
|
||||||
|
<? if(isset($ebook->EbookPlaceholder->Notes)){ ?>
|
||||||
|
<?= Formatter::MarkdownToHtml($ebook->EbookPlaceholder->Notes, true) ?>
|
||||||
|
<? } ?>
|
||||||
|
<? if($showPlaceholderMetadata){ ?>
|
||||||
|
— <a href="<?= $ebook->Url ?>">View placeholder.</a>
|
||||||
|
<? } ?>
|
||||||
|
|
||||||
|
<? if($ebook->EbookPlaceholder?->IsPatron){ ?>
|
||||||
|
<a class="patron-selection" href="/donate#patrons-circle">Patron selection!</a>
|
||||||
|
<? } ?>
|
||||||
|
</p>
|
||||||
|
</li>
|
||||||
|
<? } ?>
|
||||||
|
</ul>
|
|
@ -10,31 +10,21 @@ $advancedEbooks = Ebook::GetByIsWantedAndDifficulty(Enums\EbookPlaceholderDiffic
|
||||||
<p>If you’re interested in producing an ebook for Standard Ebooks, why not work on one of these books?</p>
|
<p>If you’re interested in producing an ebook for Standard Ebooks, why not work on one of these books?</p>
|
||||||
<p>If something in this list interests you, please <a href="https://groups.google.com/g/standardebooks">contact us at our mailing list</a> for help before you start work.</p>
|
<p>If something in this list interests you, please <a href="https://groups.google.com/g/standardebooks">contact us at our mailing list</a> for help before you start work.</p>
|
||||||
<p>If you want to suggest a different book to produce, please carefully review <a href="/contribute/collections-policy">the kinds of work we do and don’t accept</a>.</p>
|
<p>If you want to suggest a different book to produce, please carefully review <a href="/contribute/collections-policy">the kinds of work we do and don’t accept</a>.</p>
|
||||||
|
|
||||||
<h2>Add a book to this list</h2>
|
<h2>Add a book to this list</h2>
|
||||||
<p><a href="/donate#patrons-circle">Patrons Circle members</a> may submit ebooks for inclusion on this list.</p>
|
<p><a href="/donate#patrons-circle">Patrons Circle members</a> may submit ebooks for inclusion on this list.</p>
|
||||||
<p>Patrons Circle members <a href="/polls">periodically vote on a selection from this list</a> to pick one ebook for immediate production. You can <a href="/donate#patrons-circle">join the Patrons Circle</a> to have a voice in the future of the Standard Ebooks catalog.</p>
|
<p>Patrons Circle members <a href="/polls">periodically vote on a selection from this list</a> to pick one ebook for immediate production. You can <a href="/donate#patrons-circle">join the Patrons Circle</a> to have a voice in the future of the Standard Ebooks catalog.</p>
|
||||||
|
|
||||||
<h2>For your first production</h2>
|
<h2>For your first production</h2>
|
||||||
<p>If nothing on the list below interests you, you can pitch us something else you’d like to work on.</p>
|
<p>If nothing on the list below interests you, you can pitch us something else you’d like to work on.</p>
|
||||||
<p>First productions should be on the shorter side (less than 100,000 words maximum) and without too many complex formatting issues like illustrations, significant endnotes, letters, poems, etc. Most short plain fiction novels fall in this category.</p>
|
<p>First productions should be on the shorter side (less than 100,000 words maximum) and without too many complex formatting issues like illustrations, significant endnotes, letters, poems, etc. Most short plain fiction novels fall in this category.</p>
|
||||||
<ul class="wanted-list">
|
<?= Template::WantedEbooksList(['ebooks' => $beginnerEbooks, 'showPlaceholderMetadata' => Session::$User?->Benefits->CanEditEbookPlaceholders]) ?>
|
||||||
<? foreach($beginnerEbooks as $ebook){ ?>
|
|
||||||
<?= Template::WantedEbook(['ebook' => $ebook, 'showPlaceholderMetadata' => Session::$User?->Benefits->CanEditEbookPlaceholders]) ?>
|
|
||||||
<? } ?>
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
<h2>Moderate-difficulty productions</h2>
|
<h2>Moderate-difficulty productions</h2>
|
||||||
<ul class="wanted-list">
|
<?= Template::WantedEbooksList(['ebooks' => $intermediateEbooks, 'showPlaceholderMetadata' => Session::$User?->Benefits->CanEditEbookPlaceholders]) ?>
|
||||||
<? foreach($intermediateEbooks as $ebook){ ?>
|
|
||||||
<?= Template::WantedEbook(['ebook' => $ebook, 'showPlaceholderMetadata' => Session::$User?->Benefits->CanEditEbookPlaceholders]) ?>
|
|
||||||
<? } ?>
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
<h2>Advanced productions</h2>
|
<h2>Advanced productions</h2>
|
||||||
<ul class="wanted-list">
|
<?= Template::WantedEbooksList(['ebooks' => $advancedEbooks, 'showPlaceholderMetadata' => Session::$User?->Benefits->CanEditEbookPlaceholders]) ?>
|
||||||
<? foreach($advancedEbooks as $ebook){ ?>
|
|
||||||
<?= Template::WantedEbook(['ebook' => $ebook, 'showPlaceholderMetadata' => Session::$User?->Benefits->CanEditEbookPlaceholders]) ?>
|
|
||||||
<? } ?>
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
<h2 id="verne">Jules Verne</h2>
|
<h2 id="verne">Jules Verne</h2>
|
||||||
<p>Verne has a complex publication and translation history. Please review these notes before starting any Verne books.</p>
|
<p>Verne has a complex publication and translation history. Please review these notes before starting any Verne books.</p>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue