Changes for page InfoboxStyles
Last modified by Mads Pedersen on 2026/07/28 06:53
From version 8.11
edited by Mads Pedersen
on 2026/01/20 14:55
on 2026/01/20 14:55
Change comment:
There is no comment for this version
To version 8.13
edited by Mads Pedersen
on 2026/01/20 15:00
on 2026/01/20 15:00
Change comment:
There is no comment for this version
Summary
-
Objects (1 modified, 0 added, 1 removed)
Details
- XWiki.WikiMacroClass[0]
-
- Macro code
-
... ... @@ -1,15 +1,15 @@ 1 1 {{velocity}} 2 2 {{html clean="false"}} 3 -<div style="float:right; width:280px; margin:0 0 1em 1em; border:1px solid #aaa; background:#f8f9fa; font-size:0.9em; font-family: 'Helvetica Neue', Helvetica, Arial,sans-serif; line-height: 1.5; box-shadow: 0 2px 4px rgba(0,0,0,0.1);">3 +<div style="float:right; width:280px; margin:0 0 1em 1em; border:1px solid #aaa; background:#f8f9fa; font-size:0.9em; font-family: sans-serif; line-height: 1.5; box-shadow: 0 2px 4px rgba(0,0,0,0.1);"> 4 4 <table style="width:100%; border-collapse:collapse;"> 5 - ## TitleRow5 + ## Header 6 6 #if($xcontext.macro.params.title && "$!xcontext.macro.params.title" != "") 7 - <caption style="background:#eeeeee; font-weight:bold; padding:10px; border:1px solid #aaa; border-bottom:none; color: #000; font-size: 1.1em;">7 + <caption style="background:#eeeeee; font-weight:bold; padding:10px; border:1px solid #aaa; border-bottom:none; color: #000;"> 8 8 $xcontext.macro.params.title 9 9 </caption> 10 10 #end 11 11 12 - ## Image Row12 + ## Image 13 13 #if($xcontext.macro.params.image && "$!xcontext.macro.params.image" != "") 14 14 <tr> 15 15 <td colspan="2" style="text-align:center; padding:8px; background: #fff;"> ... ... @@ -21,11 +21,10 @@ 21 21 </tr> 22 22 #end 23 23 24 - ## Data Rows (Label=Value) 25 - #set($content = $xcontext.macro.params.data) 26 - #if($content && "$!content" != "") 27 - #foreach($line in $content.split("\n")) 28 - ## Trim the line and check if it has a "=" and isn't just whitespace 24 + ## Parse the Macro Content (The big box) 25 + #set($macroContent = $xcontext.macro.content) 26 + #if($macroContent && "$!macroContent.trim()" != "") 27 + #foreach($line in $macroContent.split("\n")) 29 29 #set($trimmedLine = $line.trim()) 30 30 #if($trimmedLine.contains("=") && $trimmedLine.length() > 2) 31 31 #set($parts = $trimmedLine.split("=", 2)) - Content description (Not applicable for "No content" type)
-
... ... @@ -1,0 +1,1 @@ 1 +Write lines into the infobox like "Label=Example text" - Macro content availability
-
... ... @@ -1,1 +1,1 @@ 1 - No content1 +Mandatory
- XWiki.WikiMacroParameterClass[3]
-
- Parameter description
-
... ... @@ -1,1 +1,0 @@ 1 -Write lines into the infobox like "Label=Example text" - Parameter name
-
... ... @@ -1,1 +1,0 @@ 1 -data - Parameter order property
-
... ... @@ -1,1 +1,0 @@ 1 -13 - Parameter type
-
... ... @@ -1,1 +1,0 @@ 1 -TextArea