Template:MachineInfoBox: Difference between revisions

From CoMakingSpace Wiki

(Created page with "<noinclude>{{MachineInfoBox |machine name= Example: 3D Printer |image= |access=upon introduction |status=working |type=CNC (additive manufacturing) |location=3D Printer...")
 
m (removed leading empty lines)
(30 intermediate revisions by 4 users not shown)
Line 1: Line 1:
<noinclude>{{MachineInfoBox
<noinclude>{{MachineInfoBox
|machine name= Example: 3D Printer
|machine name= Example: 3D Printer
|image=
|german=3D-Drucker
|access=upon introduction
|image=Prusa i3 MK2S.JPG
|extrabox=yes
|access=
|status=working
|status=working
|type=[[CNC]] (additive manufacturing)
|type=[[CNC]] (additive manufacturing)
Line 10: Line 12:
|firmware=[[Marlin]]
|firmware=[[Marlin]]
|software=[[Cura]]
|software=[[Cura]]
|tutors=[[User:Mitja|Mitja]], [[User:Lukas|Lukas]]
|tutors=
|manual=
|manual=
|similar=
|similar=
}}
}}
 
We call pretty much all electric devices and big or small power tools "[[machines]]" in this wiki. Their pages should contain this [[InfoBoxes|InfoBox]]!
We call a more or less autonomous device a "machine" and its page should contain this [[InfoBoxes|InfoBox]].


== Documentation ==
== Documentation ==
Line 22: Line 23:
{{MachineInfoBox
{{MachineInfoBox
|machine name=
|machine name=
|german=
|image=
|image=
|synonyms=
|synonyms=
Line 27: Line 29:
|material=
|material=
|location=
|location=
|access=
|status=
|status=
|firmware=
|firmware=
|software=
|software=
|manual=
|manual=
|tutors=
|used with=
|used with=
|similar=
|similar=
}}
}}
</pre>
</pre>
Default values for some parameters exist, other fields will only be shown when used. Make frequent use of the "Show preview" button and it should be clear.
Most fields will only be shown when used, so the box can be more or less detailed. Make frequent use of the "Show preview" button and it should be clear.


For example, entering the following leads to the '''box on the right''':
For example, entering the following leads to the '''box on the right''':
Line 43: Line 43:
{{MachineInfoBox
{{MachineInfoBox
|machine name= Example: 3D Printer
|machine name= Example: 3D Printer
|image=
|german=3D-Drucker
|access=upon introduction
|image=Prusa i3 MK2S.JPG
|status=working
|status=working
|type=[[CNC]] (additive manufacturing)
|type=[[CNC]] (additive manufacturing)
Line 52: Line 52:
|firmware=[[Marlin]]
|firmware=[[Marlin]]
|software=[[Cura]]
|software=[[Cura]]
|tutors=[[User:Mitja|Mitja]], [[User:Lukas|Lukas]]
|manual=
|manual=
|similar=
|similar=
}}
}}
</pre>
</pre>
== Advanced Users (SMW) ==
There is a "hidden" parameter in this template that's not in the copy template: <code>extrabox</code>. To enable <code>extrabox</code>, just give it any value (e.g. "true", "blablabla") and it should cause the box to behave as an extra without "Has image::".
You can use it when you '''don't''' want the InfoBox to set a "Has image::" and "Has German::" value (as it automatically does for "image" and "german"). That's useful on pretty much every page with multiple InfoBoxes so there is just one "main" image to represent the page in galleries.
"Access" and "Tutors" should automatically gather their content from the SMW property "Introduction for::" since January 2022.
Questions, feedback and further improvements are welcome!


== Bugs/Future Development ==
== Bugs/Future Development ==
*"smart" behavior like color change according to status would be nice
*"smart" behavior like color change according to status would be nice
</noinclude>
</noinclude>
{| class="wikitable" style="float:right; margin-left: 10px; border-style: solid; border-width: 5px; border-color: black"
{| class="wikitable" style="float:right; margin-left: 10px; border-style: solid; border-width: 5px; border-color: black"
!colspan="2"|<small style="float:right">[[Template:MachineInfoBox|MachineInfoBox]]</small><br>
!colspan="2"|<small style="float:right">[[Template:MachineInfoBox|MachineInfoBox]]</small><br>
<big>'''{{{machine name|Unnamed Machine}}}'''</big>
<big>'''{{{machine name|Unnamed Machine}}}'''</big>
|-
|-
!colspan="2"| [[File:{{#if: {{{image|}}} | {{{image}}} |machine-default.png}}|frameless|300px]]
!colspan="2"| [[{{#if: {{{extrabox|}}} |File: | Has image::File:}}{{#if: {{{image|}}} |{{{image}}} |machine-default.png}}|frameless|300px]]
|-
|-
{{#if: {{{synonyms|}}} |
{{#if: {{{synonyms|}}} |
Line 99: Line 106:
|}}
|}}
|-
|-
{{#if: {{{access|}}} |
|Access Requirements:
{{!}}-
| {{#ask: [[Introduction for::{{PAGENAME}}]]}}
{{!}} Access:
{{!}} {{{access}}}
|}}
|-
|-
{{#if: {{{status|}}} |
{{#if: {{{status|}}} |
Line 129: Line 133:
|}}
|}}
|-  
|-  
| Tutors: [[Tutors|(?)]]
| [[Tutors]]:
| {{{tutors|}}}
| {{#ask: [[Introduction for::{{PAGENAME}}]] |?Tutor= |format=plainlist |mainlabel=-  |valuesep=<br/>  }}
|-
|-
{{#if: {{{similar|}}} |
{{#if: {{{similar|}}} |
Line 139: Line 143:
|}
|}
[[Category:Machines]]
[[Category:Machines]]
[[Has caption::{{#if: {{{extrabox|}}} | |{{PAGENAME}}}}| ]]
{{#if:{{{german|}}} | [[Has German::{{{german}}}|]] | }}<noinclude>
== Template Parameters ==
<templatedata>
{
"params": {
"machine name": {
"label": "The name of your machine",
"description": "The name of your machine",
"type": "string",
"default": "Unnamed Machine",
"required": true
},
"german": {
"label": "The (best) German name of your machine (invisible)",
"description": "The (best) German name of your machine (not visible, but usable for advanced pages like automatic galleries)",
"type": "string",
"suggested": true
},
"extrabox": {
"label": "Extrabox? (advanced - if in doubt, ignore this)",
"description": "Apply this parameter if you use the template as an additional InfoBox on a machine page with an existing \"main\" box. This will remove the \"Has Image\" parameter from this infobox so its image is NOT included as an SMW property of the page.",
"type": "boolean"
},
"image": {
"label": "An image of the machine (example.jpg)",
"description": "The file name of the image which best represents the machine. If you do not fill the parameter \"extrabox\", this will be added to the page as a Semantic MediaWiki property.",
"type": "wiki-file-name",
"default": "machine-default.png",
"suggested": true
},
"synonyms": {
"label": "Synonyms for the machine's name",
"description": "Existing synonyms for the name of the machines. You might include translations here.",
"example": "DE: Bohrmaschine",
"type": "string",
"suggested": true
},
"type": {
"label": "Which type of machine is it?",
"description": "Which type of machine is this InfoBox referring to? ",
"example": "[[CNC]] / [[metalworking]]",
"suggested": true,
"type": "string"
},
"status": {
"label": "The status of the machine",
"description": "The status of the machine - link the corresponding \"do-something\" issue in case of problems!",
"example": "available / broken",
"type": "string"
},
"material": {
"label": "Material the machine can be used with",
"description": "Links to materials the machine can be used with. Links should ideally be within our wiki.",
"example": "[[wood]]",
"type": "wiki-page-name",
"suggested": true
},
"used with": {
"label": "Tools to use the machine with",
"description": "Links to tools the machine can be used with. Links should ideally be within our wiki",
"example": "[[Drill Bits|drill bits]]",
"type": "wiki-page-name"
},
"location": {
"label": "The location of the tool",
"description": "The location of the tool within the CoMakingSpace",
"example": "[[Location::Wood Workshop|wood workshop]]",
"type": "wiki-page-name",
"suggested": true
},
"access": {
"label": "Access requirements",
"description": "Currently unused - previously indicated the access requirements to use the machine",
"example": "[[introduction]]",
"type": "string"
},
"tutors": {
"label": "Tutors for the machine",
"description": "Currently unused - previously list of tutors who can give introductions to the machine",
"example": "[[Tutor::User:Lukas|Lukas]]",
"type": "string"
},
"manual": {
"label": "Link to the manual",
"description": "Link to the manual of the machine. This should be a public source. If there is no link, indicate where the manual is located in the CoMakingSpace. Leave empty if not applicable",
"type": "url",
"suggested": true
},
"software": {
"label": "Software",
"description": "Does the machine require a computer with a certain software?",
"example": "[[Slic3r]]",
"type": "string"
},
"firmware": {
"label": "Firmware",
"description": "Is a firmware installed on the machine that may need to be maintained?",
"example": "[[Marlin]]",
"type": "string"
},
"similar": {
"label": "Links to similar machines",
"description": "Provide links to similar machines or tools in our wiki.",
"type": "wiki-page-name"
}
},
"description": "We call pretty much all electric devices and big or small power tools \"machines\" in this wiki. Their pages should contain this InfoBox!",
"paramOrder": [
"machine name",
"german",
"image",
"synonyms",
"type",
"status",
"material",
"used with",
"similar",
"location",
"access",
"tutors",
"manual",
"software",
"firmware",
"extrabox"
]
}
</templatedata>
</noinclude>

Revision as of 21:55, 4 May 2022

MachineInfoBox

Example: 3D Printer

Prusa i3 MK2S.JPG
Type: CNC (additive manufacturing)
Material: 1.75 mm filament
Location: 3D printer farm
Access Requirements:
Status: working
Firmware: Marlin
Software: Cura
Tutors:


We call pretty much all electric devices and big or small power tools "machines" in this wiki. Their pages should contain this InfoBox!

Documentation

To use this template, simply copy this code into your page and enter the relevant parameters:

{{MachineInfoBox
|machine name=
|german=
|image=
|synonyms=
|type=
|material=
|location=
|status=
|firmware=
|software=
|manual=
|used with=
|similar=
}}

Most fields will only be shown when used, so the box can be more or less detailed. Make frequent use of the "Show preview" button and it should be clear.

For example, entering the following leads to the box on the right:

{{MachineInfoBox
|machine name= Example: 3D Printer
|german=3D-Drucker
|image=Prusa i3 MK2S.JPG
|status=working
|type=[[CNC]] (additive manufacturing)
|location=[[3D Printer Farm|3D printer farm]]
|material=[[3D Printing Materials|1.75 mm filament]]
|used with=
|firmware=[[Marlin]]
|software=[[Cura]]
|manual=
|similar=
}}

Advanced Users (SMW)

There is a "hidden" parameter in this template that's not in the copy template: extrabox. To enable extrabox, just give it any value (e.g. "true", "blablabla") and it should cause the box to behave as an extra without "Has image::".

You can use it when you don't want the InfoBox to set a "Has image::" and "Has German::" value (as it automatically does for "image" and "german"). That's useful on pretty much every page with multiple InfoBoxes so there is just one "main" image to represent the page in galleries.

"Access" and "Tutors" should automatically gather their content from the SMW property "Introduction for::" since January 2022.

Questions, feedback and further improvements are welcome!

Bugs/Future Development

  • "smart" behavior like color change according to status would be nice


MachineInfoBox

Unnamed Machine

Machine-default.png
Access Requirements:
Tutors:


Template Parameters

We call pretty much all electric devices and big or small power tools "machines" in this wiki. Their pages should contain this InfoBox!

Template parameters

ParameterDescriptionTypeStatus
The name of your machinemachine name

The name of your machine

Default
Unnamed Machine
Stringrequired
The (best) German name of your machine (invisible)german

The (best) German name of your machine (not visible, but usable for advanced pages like automatic galleries)

Stringsuggested
An image of the machine (example.jpg)image

The file name of the image which best represents the machine. If you do not fill the parameter "extrabox", this will be added to the page as a Semantic MediaWiki property.

Default
machine-default.png
Filesuggested
Synonyms for the machine's namesynonyms

Existing synonyms for the name of the machines. You might include translations here.

Example
DE: Bohrmaschine
Stringsuggested
Which type of machine is it?type

Which type of machine is this InfoBox referring to?

Example
[[CNC]] / [[metalworking]]
Stringsuggested
The status of the machinestatus

The status of the machine - link the corresponding "do-something" issue in case of problems!

Example
available / broken
Stringoptional
Material the machine can be used withmaterial

Links to materials the machine can be used with. Links should ideally be within our wiki.

Example
[[wood]]
Pagesuggested
Tools to use the machine withused with

Links to tools the machine can be used with. Links should ideally be within our wiki

Example
[[Drill Bits|drill bits]]
Pageoptional
Links to similar machinessimilar

Provide links to similar machines or tools in our wiki.

Pageoptional
The location of the toollocation

The location of the tool within the CoMakingSpace

Example
[[Location::Wood Workshop|wood workshop]]
Pagesuggested
Access requirementsaccess

Currently unused - previously indicated the access requirements to use the machine

Example
[[introduction]]
Stringoptional
Tutors for the machinetutors

Currently unused - previously list of tutors who can give introductions to the machine

Example
[[Tutor::User:Lukas|Lukas]]
Stringoptional
Link to the manualmanual

Link to the manual of the machine. This should be a public source. If there is no link, indicate where the manual is located in the CoMakingSpace. Leave empty if not applicable

URLsuggested
Softwaresoftware

Does the machine require a computer with a certain software?

Example
[[Slic3r]]
Stringoptional
Firmwarefirmware

Is a firmware installed on the machine that may need to be maintained?

Example
[[Marlin]]
Stringoptional
Extrabox? (advanced - if in doubt, ignore this)extrabox

Apply this parameter if you use the template as an additional InfoBox on a machine page with an existing "main" box. This will remove the "Has Image" parameter from this infobox so its image is NOT included as an SMW property of the page.

Booleanoptional