Template

Difference between revisions of "ReferenceBook"

From CNAC

m
m
 
(50 intermediate revisions by the same user not shown)
Line 4: Line 4:
 
<pre>
 
<pre>
 
{{ReferenceBook
 
{{ReferenceBook
|Title=
+
|Subtitle=
 
|Author(s) Name=
 
|Author(s) Name=
 
|Book Cover Image=
 
|Book Cover Image=
Line 13: Line 13:
 
|Edition=
 
|Edition=
 
|Binding=
 
|Binding=
 +
|Links=
 
|Other Images=
 
|Other Images=
 
|Summary=
 
|Summary=
 
|Excerpt=
 
|Excerpt=
 +
|Keywords=
 
}}
 
}}
 
</pre>
 
</pre>
 
Edit the page to see the template text.
 
Edit the page to see the template text.
 
</noinclude><includeonly>
 
</noinclude><includeonly>
 +
{{#if:{{{Subtitle|}}}| <h3>[[Book Subtitle::{{{Subtitle|}}}]]</h3>}}
 
<div class="row">
 
<div class="row">
 
<div class="large-4 large-push-8 columns">
 
<div class="large-4 large-push-8 columns">
{| style="width: auto; font-size: 90%; border: 1px solid #aaaaaa; background-color: #f9f9f9; color: black; margin:0 auto 1.5rem; text-align:center;"
+
{| class="infobox-page" style="width: auto; font-size: 90%; background-color: #f9f9f9; color: black; margin:0 auto 1.5rem; text-align:center;min-width:250px;"
! style="text-align: center; background-color:#ccccff;" |<span style="font-size: 1.2rem;">{{#arraymap:{{{Author(s) Name|}}}|,|x|[[Book Author Name::x]]}}</span>
+
| style="text-align: center; background-color:#ccccff; font-size: 1.2rem;"|{{#arraymaptemplate:{{{Author(s) Name|}}}|Arraymap Author|,|<br>}}
 
|-
 
|-
| style="text-align:center;"|{{#set:Book Cover Image=File:{{{Book Cover Image|}}} }}[[Image:{{{Book Cover Image|}}}|link=]]
+
{{#if:{{{Book Cover Image|}}}| {{!}} style="text-align:center;"{{!}}{{#set:Book Cover Image=File:{{{Book Cover Image|}}} }}[[Image:{{{Book Cover Image|}}}|link=]]
|-
+
{{!}}-}}
! '''Publisher:''' [[Book Publisher::{{{Publisher|}}}]]
+
{{#if:{{{Publisher|}}}| {{!}} '''Publisher:''' [[Book Publisher::{{{Publisher|}}}]]
|-
+
{{!}}-}}
! '''Publish Date:''' [[Book Publish Date::{{{Publish Date|}}}]]
+
{{#if:{{{Publish Date|}}}| {{!}} '''Publish Date:''' [[Book Publish Date::{{{Publish Date|}}}]]
|-
+
{{!}}-}}
! '''ISBN-10:''' [[Book ISBN-10::{{{ISBN-10|}}}]]
+
{{#if:{{{ISBN-10|}}}| {{!}} '''ISBN-10:''' [[Book ISBN-10::{{{ISBN-10|}}}]]
|-
+
{{!}}-}}
! '''ISBN-13:''' [[Book ISBN-13::{{{ISBN-13|}}}]]
+
{{#if:{{{ISBN-13|}}}| {{!}} '''ISBN-13:''' [[Book ISBN-13::{{{ISBN-13|}}}]]
|-
+
{{!}}-}}
! '''Edition:''' [[Book Edition::{{{Edition|}}}]]
+
{{#if:{{{Edition|}}}| {{!}} '''Edition:''' [[Book Edition::{{{Edition|}}}]]
|-
+
{{!}}-}}
! '''Binding:''' [[Book Binding::{{{Binding|}}}]]
+
{{#if:{{{Binding|}}}| {{!}} '''Binding:''' {{#arraymap:{{{Binding|}}}|,|x|[[Book Binding::x]]}}
 +
{{!}}-}}
 +
| '''Keywords:''' {{#arraymap:{{#show:{{FULLPAGENAME}}|?Page keywords}}|,|@@@@|{{#queryformlink:form=Keyword Search|link text=@@@@|link type=|query string=KeywordQuery[keywords]=@@@@&_run}} }}
 
|-
 
|-
 +
| {{{Links|}}}{{ShowLinks}}
 
|}
 
|}
 
</div>
 
</div>
 
<div class="large-8 large-pull-4 columns">
 
<div class="large-8 large-pull-4 columns">
== Summary ==
+
{{#if:{{{Summary|}}}|{{#set:Book Summary={{{Summary|}}} }}{{{Summary|}}} }}
[[Book Summary::{{{Summary|}}}]]
+
{{#if:{{{Excerpt|}}}|<hr>{{#set:Book Excerpt={{{Excerpt|}}}}}{{{Excerpt|}}} }}
 
+
{{#if:{{#ask: [[-Has subobject::{{FULLPAGENAME}}]][[Has Image::+]]|?Has Image=|mainlabel=-|limit=1|link=none|searchlabel=}}|{{ShowOtherImages}}|}}
== Excerpt ==
 
[[Book Excerpt::{{{Excerpt|}}}]]
 
 
 
== Images ==
 
[[Book Additional Images::{{{Other Images|}}}]]
 
 
</div>
 
</div>
 
</div>
 
</div>
{{#set:Book Title={{PAGENAME}}}}
+
{{{Other Images|}}}
 +
{{#set:Book Title={{PAGENAME}}}}{{#set:Book Author Last Name Sort={{{Author Lastname Sort|}}}}}{{#if:{{{Keywords|}}}|{{keywords|1={{{Keywords}}}}}|}}
 +
__NOTOC__
 
[[Category:Books]]
 
[[Category:Books]]
 
</includeonly>
 
</includeonly>

Latest revision as of 20:32, 20 March 2020

This is the "ReferenceBook" template. It should be called in the following format:

{{ReferenceBook
|Subtitle=
|Author(s) Name=
|Book Cover Image=
|Publisher=
|Publish Date=
|ISBN-10=
|ISBN-13=
|Edition=
|Binding=
|Links=
|Other Images=
|Summary=
|Excerpt=
|Keywords=
}}

Edit the page to see the template text.