Difference between revisions of "Template:Text"

From Shangpa Resource Center
 
(94 intermediate revisions by the same user not shown)
Line 9: Line 9:
 
|Other titles=
 
|Other titles=
 
|Subject=
 
|Subject=
 +
|SubTopics=
 
|Author=
 
|Author=
 
|Associated Person=
 
|Associated Person=
 
|BDRC link=
 
|BDRC link=
|Volume=
 
 
|Classification=
 
|Classification=
 
|Notes=
 
|Notes=
 +
|TranslationFileEN=
 +
|TranslationFileFR=
 +
|TranslationAccessLevel=
 
}}
 
}}
 
</pre>
 
</pre>
 
Edit the page to see the template text.
 
Edit the page to see the template text.
 
</noinclude><includeonly>
 
</noinclude><includeonly>
<templatestyles src="Text/styles.css" />
+
{{#set:TextID={{{Text ID|}}}}}
 +
{{#set:TibetanTitle={{{Tibetan Title|}}}}}
 +
{{#set:WylieTitle={{{Wylie Title|}}}}}
 +
{{#arraymap:{{{Other titles|}}}|,|x|{{#set:OtherTitles=x}}}}
 +
{{#arraymap:{{{Subject|}}}|,|x|{{#set:Subject=x}}}}
 +
{{#arraymap:{{{SubTopics|}}}|,|x|{{#set:SubTopics=x}}}}
 +
{{#arraymap:{{{Author|}}}|,|x|{{#set:Author=x}}}}
 +
{{#arraymap:{{{Associated Person|}}}|,|x|{{#set:AssociatedPerson=x}}}}
 +
{{#arraymap:{{{BDRC link|}}}|,|x|{{#set:BDRCLink=x}}}}
 +
{{#arraymap:{{{Classification|}}}|,|x|{{#set:Classification=x}}}}
 +
{{#set:Notes={{{Notes|}}}}}
 +
{{#set:TranslationFileEN={{{TranslationFileEN|}}}}}
 +
{{#set:TranslationFileFR={{{TranslationFileFR|}}}}}
 +
{{#set:TranslationAccessLevel={{{TranslationAccessLevel|}}}}}
 
<div class="text_left_column">
 
<div class="text_left_column">
 
{| class="text_properties"
 
{| class="text_properties"
! Text ID
+
! Resource ID  
| [[TextID::{{{Text ID|}}}]]
+
| {{{Text ID|}}}
 
|-
 
|-
! Tibetan Title
+
! Title
| [[TibetanTitle::{{{Tibetan Title|}}}]]
+
| {{{Wylie Title|}}}
|-
 
! Wylie Title
 
| [[WylieTitle::{{{Wylie Title|}}}]]
 
 
|-
 
|-
 +
{{#if: {{{Other titles|}}} |
 
! Alt. title
 
! Alt. title
| {{#arraymap:{{{Alt. title|}}}|,|x|[[AltTitle::x]]}}
+
{{!}} {{#arraymap:{{{Other titles|}}}|,|x|x|<br/>}}
|-
+
{{!}}-|}}
! Subject
+
{{#if: {{{Subject|}}} |
| [[Subject::{{{Subject|}}}]]
+
! Topics
|-
+
{{!}} {{#arraymap:{{{Subject|}}}|,|x|[[:Topic:x|x]]}}
! Author
+
{{!}}-|}}
| {{#arraymap:{{{Author|}}}|,|x|x}}
+
{{#if: {{{SubTopics|}}}|
|-
+
! Sub-Topics
 +
{{!}} {{#arraymap:{{{SubTopics|}}}|,|x|x}}
 +
{{!}}-|}}
 +
{{#if: {{{Author|}}} | ! Author
 +
{{!}} {{#arraymap:{{{Author|}}}|,|x|[[x]]}}
 +
{{!}}-|}}
 +
{{#if: {{{Associated Person|}}} |  
 
! Associated Person
 
! Associated Person
| {{#arraymap:{{{Associated Person|}}}|,|x|x}}
+
{{!}} {{#arraymap:{{{Associated Person|}}}|,|x|[[x]]|<br/>}}
|-
+
{{!}}-|}}
! BDRC link
+
{{#if: {{{BDRC link|}}}|
| {{{BDRC link|}}}  
+
! Link
|-
+
{{!}} {{{BDRC link|}}}
! Volume
+
{{!}}-|}}
| [[Volume::{{{Volume|}}}]]
+
{{#if: {{{Classification|}}} |
|-
 
 
! Classification
 
! Classification
| {{#arraymap:{{{Classification|}}}|,|x|[[Classification::x]]}}
+
{{!}} {{#arraymap:{{{Classification|}}}|,|x|[[x]]}}
|-
+
{{!}}-|}}
 +
{{#if: {{{Notes|}}}|
 
! Notes
 
! Notes
| [[Notes::{{{Notes|}}}]]  
+
{{!}} {{{Notes|}}}
 +
{{!}}-|}}
 +
{{#ifeq:{{{TranslationAccessLevel|}}}|public|
 +
! Traductions (PDF files)
 +
{{!}} {{#if: {{{TranslationFileFR|}}}|[[Media:{{{TranslationFileFR|}}}|French]]|}} {{#if: {{{TranslationFileEN|}}}|[[Media:{{{TranslationFileEN|}}}|English]]|}}
 +
{{!}}-|}}
 +
{{#ifingroup:{{{TranslationAccessLevel|}}}|
 +
! Translations (PDF files)
 +
{{!}} {{#if: {{{TranslationFileFR|}}}|[[Media:{{{TranslationFileFR|}}}|French]]|}} {{#if: {{{TranslationFileEN|}}}|<br/>[[Media:{{{TranslationFileEN|}}}|English]]|}}
 +
{{!}}-|}}
 
|}
 
|}
 
</div>
 
</div>
Line 62: Line 91:
  
 
   .firstHeading {
 
   .firstHeading {
     margin-left: 31%;
+
     margin-left: 21%;
 +
text-transform: lowercase;
 
  }
 
  }
 
}}
 
}}
<h2 style="text-align:center;">{{#show: {{FULLPAGENAME}} |?TibetanTitle}}</h2>
+
 
[[Category:Text]] [[Category: {{#show: {{FULLPAGENAME}} |?Subject}}]]
+
[[Category:Text]] {{#arraymap:{{{Subject|}}}|,|x|[[Category:x]]| }} {{#arraymap:{{{Classification|}}}|,|x|[[Category:x]]| }}
 
</includeonly>
 
</includeonly>

Latest revision as of 14:49, 31 October 2019

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

{{Text
|Text ID=
|Tibetan Title=
|Wylie Title=
|Other titles=
|Subject=
|SubTopics=
|Author=
|Associated Person=
|BDRC link=
|Classification=
|Notes=
|TranslationFileEN=
|TranslationFileFR=
|TranslationAccessLevel=
}}

Edit the page to see the template text.