Templates download/Transclusion and Manual:Extension/BlueSpiceTagCloud: Difference between pages

(Difference between pages)
No edit summary
Tag: 2017 source edit
 
No edit summary
Tag: 2017 source edit
 
Line 1: Line 1:
<div class="downloadarea">
{{DISPLAYTITLE:Tag cloud}}
<span class="getButton">[[Media:HW-transclusion-en.zip|Download]]</span>


[[File:HW-transclusion.png|450x450px]]
The extension ''TagCloud'' visualizes terms from your wiki based on importance. It can be included on any wiki page. The source for the tag cloud terms can be categories or searchstats.<br /> [[File:tagcloud-example.png|alt=Tagcloud example|center|750x750px|Tag cloud example]]
</div>This template creates a page banner that you can include on portal pages, for example. You can see an example here in the Helpdesk on the topic pages, e.g, [[quality assurance]].
==Inserting a tag cloud==
==Importing the template==
A tag cloud can be inserted directly in source editing mode with the tag <code><nowiki><bs:tagcloud /></nowiki></code>. To insert a tag cloud with [[Manual:Extension/VisualEditor|VisualEditor]], select ''Insert > Magic word > Tag cloud''.  
The import file is included in the archive file ''HW-transclusion-en.zip''. Unpack the zip file first.
[[File:TagCloud1.png|Tag cloud tag in "Insert magic" dialog|alt=Inserting a tag cloud with VisualEditor|border|center|450x450px]]
==Configuration==
If tag is added using VisualEditor, a configuration dialog appears. It shows configuration options in two tabs: ''Common'' and ''Advanced''.<br />
[[File:TagCloud2.png|alt=tag cloud example|border|center|650x650px]]
===Common configuration===
{| class="wikitable"
|+
!Parameter!!Display name
! Description
|-
|renderer||Type
|Mode of rendering the cloud


On the page ''Special:Import'' follow these steps:
*List
*Text (font size depends on frequency)
*3D: rotating, ineractive view
|-
|width
|Width
|Part of the page width taken by the cloud in percent or pixels (e.g., 50%, 150px)
|-
|showcount
|Show count
|Whether to show the numeric frequency of the term in the cloud
|}
===Advanced configuration===
{| class="wikitable"
|+
!Parameter
!Display name
!Description
|-
|store
|Store
|Source of the data - category or searchstats
|-
|minsize
|Min font size
|Smallest possible font displayed in the cloud
|-
|maxsize
|Max font size
|Biggest possible font displayed in the cloud
|-
|exclude
|Exclude pages
|List of categories to exclude from the cloud, separated by comma - "category1, category2, category3"
|}
==Examples==
===Text===
Tag parameters:
 
<code><nowiki><bs:tagcloud count="10" minsize="12" maxsize="34" exclude="Imported vocabulary, Project" /></nowiki></code>


#'''Select file''' and choose ''HW-transclusion-en.xml''.
Output:
#'''Enter''' an Interwiki prefix. Since this field is required, simply add ''hw'' (for hallowelt).
#'''Keep''' the selection ''Import to default locations''.
#'''Click''' ''Upload file...'' .


The template is now available in your wiki.
Shows a tag cloud with the 10 (count) categories that have the most page associations. The smallest possible font-size is 12 pixels (minsize) and the largest possible font-size is 34 pixels (maxsize). The categories ''Imported vocabulary'' and ''Project'' have been excluded from the output.Since the data source ''category'' is the default for a tag cloud, it is not necessary to specify it in the tag.
[[File:tagcloud-example-exclude.png|center|650x650px|link=Special:FilePath/tagcloud-example-exclude.png]]


==Pages included in the import==
===3D canvas===
The xml import creates the following files in your wiki:
Tag parameters:


*Template:Transclusion
<code><nowiki><bs:tagcloud renderer="canvas3d"  store="category" count="15" minsize="12" maxsize="40" showcount="false" /></nowiki></code>
*Template:Transclusion/styles.css


==Using the template==
Output:


#Add the template from the [[Manual:Extension/VisualEditor|VisualEditor]] insert-dialog.
The renderer ''canvas3d'' produces an interactive tag cloud. The cloud rotates when the cursor hovers over the tag cloud. It shows the 15 (count) most tagged categories. It is important to set the count limit, since the default count is set to 40, wich produces a 3D cloud where the results are hard to distinguish visually.  The data source is set to category (store). This is optional, since category is the default store value. The font sizes range from 12 pixels (minsize) to 40 pixels (maxsize). How many pages and files are associated with each category is not shown (''showcount="false"'').
#Fill in the form fields as needed.
[[File:tagcloud-canvas3D.png|center|350x350px|link=Special:FilePath/tagcloud-canvas3D.png]]
{{Messagebox|boxtype=note|Note text=If, after importin the template to your wiki, the input fields are not displayed when you first integrate it into a wiki page, you need to open the template in the template namespace, make a change (e.g. insert spaces) and save the template. The input fields should now be displayed correctly.}}
===List===
Tag parameters:


<code><nowiki><bs:tagcloud renderer="list" store="searchstats" count="5" /></nowiki></code>


[[File:HW-transclusion-templatedata-en.png|alt=Input fields for transclusion|center|thumb|400x400px|Input fields for transclusion]]
Output:


The renderer type ''list'' produces a simple unordered list.
[[File:tagcloud-list-searchstats.png|center|link=Special:FilePath/tagcloud-list-searchstats.png]]


<br />
<br />
{| class="contenttable-blue" style="width:950px;"
 
|+ style="box-sizing: inherit; padding-top: 8px; padding-bottom: 8px; color: rgb(119, 119, 119); text-align: left;" |
The tag cloud of type ''list'' ignores the following parameters: ''minsize'', ''maxsize''
! style="background-color:rgb(239, 243, 249);text-align:inherit;box-sizing:inherit;padding:4px;border:1px solid rgb(177, 185, 207);color:rgb(62, 83, 137);" |Input field
 
! style="background-color:rgb(239, 243, 249);text-align:inherit;box-sizing:inherit;padding:4px;border:1px solid rgb(177, 185, 207);color:rgb(62, 83, 137);" |Description
{{Box Links-en|Topic1=[[Reference:BlueSpiceTagCloud]]}}
|- style="box-sizing: inherit; border: 1px solid rgb(177, 185, 207); border-spacing: 0px; border-collapse: collapse; padding: 10px;"
 
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |Page to transclude into this document
{{Translation}}
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |Page name of the page containing the section (including the namespace prefix if the page is not in the main namespace).
[[Category:Content]]
|- style="box-sizing: inherit; border: 1px solid rgb(177, 185, 207); border-spacing: 0px; border-collapse: collapse; padding: 10px;"
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |Page section
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |Heading of the section you want to transclude. If a section contains sub-headings, these are included up to the next heading at the same level of the section.
|- style="box-sizing: inherit; border: 1px solid rgb(177, 185, 207); border-spacing: 0px; border-collapse: collapse; padding: 10px;"
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |Color style
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |If you want to apply a background color, you can select one here. Choices are: blue, green, grey, red, yellow
|- style="box-sizing: inherit; border: 1px solid rgb(177, 185, 207); border-spacing: 0px; border-collapse: collapse; padding: 10px;"
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |Background
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |If you don't like any of the color styles, you can [https://www.w3schools.com/colors/colors_picker.asp enter your own color in hex format] (e.g. # cce6ff).
|- style="box-sizing: inherit; border: 1px solid rgb(177, 185, 207); border-spacing: 0px; border-collapse: collapse; padding: 10px;"
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |Border
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |Creates a border color. Apply only when you use a custom background color instead of the color style (which already uses its own border color).
|- style="box-sizing: inherit; border: 1px solid rgb(177, 185, 207); border-spacing: 0px; border-collapse: collapse; padding: 10px;"
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |Padding
| style="box-sizing:inherit;padding:10px;border:1px solid rgb(177, 185, 207);border-spacing:0px;border-collapse:collapse;" |Distance from box to box content.  Default value: 20px. You can set this to any other pixel-value or simple enter 0 for now padding.
|}
__NOTOC__

Latest revision as of 17:21, 20 May 2022


The extension TagCloud visualizes terms from your wiki based on importance. It can be included on any wiki page. The source for the tag cloud terms can be categories or searchstats.

Tagcloud example

Inserting a tag cloud

A tag cloud can be inserted directly in source editing mode with the tag <bs:tagcloud />. To insert a tag cloud with VisualEditor, select Insert > Magic word > Tag cloud.

Inserting a tag cloud with VisualEditor

Configuration

If tag is added using VisualEditor, a configuration dialog appears. It shows configuration options in two tabs: Common and Advanced.

tag cloud example

Common configuration

Parameter Display name Description
renderer Type Mode of rendering the cloud
  • List
  • Text (font size depends on frequency)
  • 3D: rotating, ineractive view
width Width Part of the page width taken by the cloud in percent or pixels (e.g., 50%, 150px)
showcount Show count Whether to show the numeric frequency of the term in the cloud

Advanced configuration

Parameter Display name Description
store Store Source of the data - category or searchstats
minsize Min font size Smallest possible font displayed in the cloud
maxsize Max font size Biggest possible font displayed in the cloud
exclude Exclude pages List of categories to exclude from the cloud, separated by comma - "category1, category2, category3"

Examples

Text

Tag parameters:

<bs:tagcloud count="10" minsize="12" maxsize="34" exclude="Imported vocabulary, Project" />

Output:

Shows a tag cloud with the 10 (count) categories that have the most page associations. The smallest possible font-size is 12 pixels (minsize) and the largest possible font-size is 34 pixels (maxsize). The categories Imported vocabulary and Project have been excluded from the output.Since the data source category is the default for a tag cloud, it is not necessary to specify it in the tag.

tagcloud-example-exclude.png

3D canvas

Tag parameters:

<bs:tagcloud renderer="canvas3d" store="category" count="15" minsize="12" maxsize="40" showcount="false" />

Output:

The renderer canvas3d produces an interactive tag cloud. The cloud rotates when the cursor hovers over the tag cloud. It shows the 15 (count) most tagged categories. It is important to set the count limit, since the default count is set to 40, wich produces a 3D cloud where the results are hard to distinguish visually. The data source is set to category (store). This is optional, since category is the default store value. The font sizes range from 12 pixels (minsize) to 40 pixels (maxsize). How many pages and files are associated with each category is not shown (showcount="false").

tagcloud-canvas3D.png

List

Tag parameters:

<bs:tagcloud renderer="list" store="searchstats" count="5" />

Output:

The renderer type list produces a simple unordered list.

tagcloud-list-searchstats.png


The tag cloud of type list ignores the following parameters: minsize, maxsize

Related info



To submit feedback about this documentation, visit our community forum.

Discussions