Template:Episode: Difference between revisions

From SGUTranscripts
Jump to navigation Jump to search
m (sandboxing)
m (so proud of this template. just tiny markup and desc tweaks here)
 
(75 intermediate revisions by the same user not shown)
Line 1: Line 1:
<div style="background-color: #eeffee; margin: 0 2.5%; padding: 0 0px; border: 1px solid #22b222;">
<includeonly><div style="background-color: #eeffee; margin: 0 2.5%; padding: 0 0px; border: 1px solid #22b222;">
{| border="0"
{| border="0"
|-
|-  
| width="3" bgcolor=#22b222|&nbsp;
| width="3" bgcolor=#22b222|&nbsp;
| width="40" align="center"|[[File:Emblem-pen-green.png|25x25px|link=]]
| width="40" align="center"|[[File:Emblem-pen-green.png|25x25px|link=]]
{{!}}{{#switch: {{#expr: ( {{JULIANDAY|{{CURRENTYEAR}}|{{CURRENTMONTH}}|{{CURRENTDAY}}}}-{{JULIANDAY|{{{3}}}|{{{1}}}|{{{2}}}}} ) }}
|{{#ifexpr: {{JULIANDAY|{{CURRENTYEAR}}|{{CURRENTMONTH}}|{{CURRENTDAY}}|({{CURRENTHOUR}}-4)}}<{{JULIANDAY|{{{3}}}|{{{1}}}|{{{2}}}}}  
| {{#expr: ({{JULIANDAY|{{CURRENTYEAR}}|{{CURRENTMONTH}}|{{CURRENTDAY}}}}-{{JULIANDAY|{{{3}}}|{{{1}}}|{{{2}}}}}) < 7 }} = This is the '''latest episode''' and it is not yet complete. Please help us complete the transcript as soon as possible by transcribing a section. Remember to add your [[Transcribing templates|Transcribing template]] to the top of this episode (and to your section) before you start so that we don't duplicate your efforts.
 
| {{#expr: ({{JULIANDAY|{{CURRENTYEAR}}|{{CURRENTMONTH}}|{{CURRENTDAY}}}}-{{JULIANDAY|{{{3}}}|{{{1}}}|{{{2}}}}}) < 365 }} = This is a '''recent episode''' and it is not yet complete. Please help us complete the transcript as soon as possible by transcribing a section.  Remember to add your [[Transcribing templates|Transcribing template]] to the top of this episode (and to your section) before you start so that we don't duplicate your efforts.
<!--
| {{#expr: ({{JULIANDAY|{{CURRENTYEAR}}|{{CURRENTMONTH}}|{{CURRENTDAY}}}}-{{JULIANDAY|{{{3}}}|{{{1}}}|{{{2}}}}}) >= 365 }} = This episode is not yet complete. Please help us complete the transcript as soon as possible by transcribing a section. Remember to add your [[Transcribing templates|Transcribing template]] to the top of this episode (and to your section) before you start so that we don't duplicate your efforts.
 
}}
*** If the current Julian time is less than the input time, then the input time is still in the future, so the box will read: -->
 
| This transcript outline is for an '''upcoming episode'''. Please help us complete the transcript once the episode is released.<br>Remember to add a [[:Category:Transcribing templates|Transcribing template]] to the top of this transcript before you start so that we don't duplicate your efforts. <!--
 
*** But if the current Julian time is greater than the input, then the episode is from the past. How long ago? Well...
 
-->|{{#ifexpr: ({{JULIANDAY|{{CURRENTYEAR}}|{{CURRENTMONTH}}|{{CURRENTDAY}}}}-{{JULIANDAY|{{{3}}}|{{{1}}}|{{{2}}}}}) > 365
 
<!--
 
*** If the current Julian time is more than a year ahead of the input time, then the episode is over one year old and is no longer "recent", so the box will read: -->
 
| This transcript is not finished. Please help us finish it!<br>Add a [[:Category:Transcribing templates|Transcribing template]] to the top of this transcript before you start so that we don't duplicate your efforts.|
 
{{#ifexpr: ({{JULIANDAY|{{CURRENTYEAR}}|{{CURRENTMONTH}}|{{CURRENTDAY}}|({{CURRENTHOUR}}-2)}}-{{JULIANDAY|{{{3}}}|{{{1}}}|{{{2}}}}}) < 7
 
<!--
 
*** But if less than a year has passed, then, if the episode is less than 7 days in the past, it's the latest episode, so the box will read: -->  
 
| This is the transcript for the '''latest episode''' and it is not yet complete. Please help us complete it!<br>Add a [[:Category:Transcribing templates|Transcribing template]] to the top of this episode before you start so that we don't duplicate your efforts. <!--
 
*** Otherwise, it's just a recent episode from the past 365 days, producing: -->
 
| This is a transcript of a '''recent episode''' and it is not finished. Please help us finish it!<br>Add a [[:Category:Transcribing templates|Transcribing template]] to the top of this transcript before you start so that we don't duplicate your efforts.}}}}}}
|}
|}
</div><noinclude>
</div></includeonly><noinclude><!--


[[User:Xanderox#Sandboxing]]
Shorthand breakdown of #if: strings:


{{ IF: Julian less than input
| THEN: upcoming
| IF NOT, THEN
{{ IF input is greater than 365 from Julian
| THEN: old
| IF NOT, THEN
{{ IF input is less than 7 days ago
| THEN: latest
| IF NOT, THEN: recent
}} (close expression for over 7/under 7 days)
}} (close expression for over 1 year/under 1 year)
}} (close expression for future or not) }}
-->
=== Description ===
=== Description ===
Include this template at the top of episodes that are incomplete. Use the parameters "MM", "DD", and "YYYY", which represent the broadcast date. Once I get this template squared up, it should be able to calculate how "recent" the episode is, and will display the relevant message. The "latest episode" message will be for the episode whose broadcast date is no more than 6 days older than the current date; the "recent episode" message will be for the one whose date is no more than a year older than the current date; all older episodes will just say "This episode...". (So this template is attempting to be a mashup of the [[Template:LatestEpisode|Latest Episode]], [[Template:RecentEpisode|Recent Episode]], and [[Template:OldEpisode|Old Episode]] templates.
Include this template at the top of episodes that are incomplete. Use the parameters "M", "D", and "YYYY", which represent the broadcast date. It will calculate how "recent" the episode is, and will display a relevant message that asks for help completing the transcript.  
 
The "latest episode" message will be for the episode whose broadcast date is no more than 6 days older than today's date, {{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}} ({{CURRENTTIME}}); the "recent episode" message will be for episodes whose date is no more than a year before today's date; all episodes older than one year will just say "This episode...". (So this template is a mashup of the [[Template:LatestEpisode|Latest Episode]], [[Template:RecentEpisode|Recent Episode]], and [[Template:OldEpisode|Old Episode]] templates.) Episodes whose broadcast dates are still in the future will have the "upcoming episode" message.
<br><br>
Based on the calculation setup, it will generate one of the following message boxes:
 
{{LatestEpisode}}
 
or
 
{{RecentEpisode}}
 
or
 
{{OldEpisode}}
 
or


{{UpcomingEpisode}}
=== Usage ===
=== Usage ===
<pre>{{Episode}}</pre>
<pre>{{Episode|M|D|YYYY}}</pre>
[[Category: Message templates]]
[[Category: Message templates]]
[[Category: Templates]]
[[Category: Templates]]
</noinclude>
</noinclude>

Latest revision as of 04:19, 2 May 2024

Description

Include this template at the top of episodes that are incomplete. Use the parameters "M", "D", and "YYYY", which represent the broadcast date. It will calculate how "recent" the episode is, and will display a relevant message that asks for help completing the transcript.

The "latest episode" message will be for the episode whose broadcast date is no more than 6 days older than today's date, November 21, 2024 (21:37); the "recent episode" message will be for episodes whose date is no more than a year before today's date; all episodes older than one year will just say "This episode...". (So this template is a mashup of the Latest Episode, Recent Episode, and Old Episode templates.) Episodes whose broadcast dates are still in the future will have the "upcoming episode" message.

Based on the calculation setup, it will generate one of the following message boxes:

  Emblem-pen-green.png This is the transcript for the latest episode and it is not yet complete. Please help us complete it!
Add a Transcribing template to the top of this episode before you start so that we don't duplicate your efforts.

or

  Emblem-pen-green.png This is a transcript of a recent episode and it is not finished. Please help us finish it!
Add a Transcribing template to the top of this transcript before you start so that we don't duplicate your efforts.

or

  Emblem-pen-green.png This transcript is not finished. Please help us finish it!
Add a Transcribing template to the top of this transcript before you start so that we don't duplicate your efforts.

or

  Emblem-pen-green.png This transcript outline is for an upcoming episode. Please help us complete the transcript once the episode is released.
Remember to add a Transcribing template to the top of this transcript before you start so that we don't duplicate your efforts.

Usage

{{Episode|M|D|YYYY}}