Template

Difference between revisions of "ReferenceBook"

From CNAC

m
m
 
(63 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>{| style="width: 30em; font-size: 90%; border: 1px solid #aaaaaa; background-color: #f9f9f9; color: black; margin-bottom: 0.5em; margin-left: 1em; padding: 0.2em; float: right; clear: right; text-align:left;"
+
</noinclude><includeonly>
! style="text-align: center; background-color:#ccccff;" colspan="2" |<span style="font-size: larger;">{{PAGENAME}}</span>
+
{{#if:{{{Subtitle|}}}| <h3>[[Book Subtitle::{{{Subtitle|}}}]]</h3>}}
 +
<div class="row">
 +
<div class="large-4 large-push-8 columns">
 +
{| 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; font-size: 1.2rem;"|{{#arraymaptemplate:{{{Author(s) Name|}}}|Arraymap Author|,|<br>}}
 
|-
 
|-
! Title
+
{{#if:{{{Book Cover Image|}}}| {{!}} style="text-align:center;"{{!}}{{#set:Book Cover Image=File:{{{Book Cover Image|}}} }}[[Image:{{{Book Cover Image|}}}|link=]]
| [[Book Title::{{PAGENAME}}]]
+
{{!}}-}}
 +
{{#if:{{{Publisher|}}}| {{!}} '''Publisher:''' [[Book Publisher::{{{Publisher|}}}]]
 +
{{!}}-}}
 +
{{#if:{{{Publish Date|}}}| {{!}} '''Publish Date:''' [[Book Publish Date::{{{Publish Date|}}}]]
 +
{{!}}-}}
 +
{{#if:{{{ISBN-10|}}}| {{!}} '''ISBN-10:''' [[Book ISBN-10::{{{ISBN-10|}}}]]
 +
{{!}}-}}
 +
{{#if:{{{ISBN-13|}}}| {{!}} '''ISBN-13:''' [[Book ISBN-13::{{{ISBN-13|}}}]]
 +
{{!}}-}}
 +
{{#if:{{{Edition|}}}| {{!}} '''Edition:''' [[Book Edition::{{{Edition|}}}]]
 +
{{!}}-}}
 +
{{#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}} }}
 
|-
 
|-
! Author(s) Name
+
| {{{Links|}}}{{ShowLinks}}
| [[Book Author Name::{{{Author(s) Name|}}}]]
 
|-
 
! Book Cover Image
 
| [[Book Cover Image::{{{Book Cover Image|}}}]]
 
|-
 
! Publisher
 
| [[Book Publisher::{{{Publisher|}}}]]
 
|-
 
! Publish Date
 
| [[Book Publish Date::{{{Publish Date|}}}]]
 
|-
 
! ISBN-10
 
| [[Book ISBN-10::{{{ISBN-10|}}}]]
 
|-
 
! ISBN-13
 
| [[Book ISBN-13::{{{ISBN-13|}}}]]
 
|-
 
! Edition
 
| [[Book Edition::{{{Edition|}}}]]
 
|-
 
! Binding
 
| {{#arraymap:{{{Binding|}}}|,|x|[[Book Binding::x]]}}
 
 
 
|-
 
! Other Images
 
| [[Book Additional Images::{{{Other Images|}}}]]
 
|-
 
! Summary
 
| [[Book Summary::{{{Summary|}}}]]
 
|-
 
! Excerpt
 
| [[Book Excerpt::{{{Excerpt|}}}]]
 
 
|}
 
|}
 
+
</div>
 +
<div class="large-8 large-pull-4 columns">
 +
{{#if:{{{Summary|}}}|{{#set:Book Summary={{{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}}|}}
 +
</div>
 +
</div>
 +
{{{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.