0 Votes

Changes for page View File Macro

Last modified by Ryan C on 2025/04/30 07:54

From version 16.1
edited by Ryan C
on 2025/04/30 07:54
Change comment: Migrated property [featureMandatory] from class [XWiki.WikiMacroParameterClass]
To version 2.1
edited by Ryan C
on 2025/03/15 08:54
Change comment: Install extension [com.xwiki.pro:xwiki-pro-macros-ui/1.26.7]

Summary

Details

Page properties
Content
... ... @@ -14,7 +14,6 @@
14 14  
15 15  = Example Usage =
16 16  
17 -
18 18  Thumbnails side by side:
19 19  
20 20  {{view-file display="thumbnail" name="Test.ppt"/}} {{view-file display="thumbnail" name="TestPDF.pdf"/}}
... ... @@ -33,3 +33,4 @@
33 33  Full Presentation:
34 34  
35 35  {{view-file display="full" name="Test.ppt"/}}
35 +
XWiki.WikiMacroClass[0]
Macro code
... ... @@ -1,10 +1,0 @@
1 -{{velocity}}
2 -#set ($name = $xcontext.macro.params.name)
3 -#set ($page = $xcontext.macro.params.page)
4 -#set ($display = $xcontext.macro.params.display)
5 -#set ($width = $xcontext.macro.params.width)
6 -#set ($height = $xcontext.macro.params.height)
7 -
8 -#viewFile($name $page $display $width $height)
9 -{{/velocity}}
10 -
Macro visibility
... ... @@ -1,1 +1,0 @@
1 -Current Wiki
Cached
... ... @@ -1,1 +1,0 @@
1 -No
Supports inline mode
... ... @@ -1,1 +1,0 @@
1 -Yes
Macro description
... ... @@ -1,2 +1,0 @@
1 -Displays a file viewer for attachments (PDF, images, etc).
2 -
Asynchronous rendering
... ... @@ -1,1 +1,0 @@
1 -No
Default categories
... ... @@ -1,1 +1,0 @@
1 -Content
Macro name
... ... @@ -1,1 +1,0 @@
1 -view-file
Macro id
... ... @@ -1,1 +1,0 @@
1 -view-file
XWiki.WikiMacroParameterClass[0]
Parameter name
... ... @@ -1,1 +1,0 @@
1 -name
Parameter description
... ... @@ -1,1 +1,0 @@
1 -The exact name of the attachment (e.g. myfile.pdf)
Parameter type
... ... @@ -1,1 +1,0 @@
1 -unknown
Parameter mandatory
... ... @@ -1,1 +1,0 @@
1 -Yes
XWiki.WikiMacroParameterClass[1]
Parameter name
... ... @@ -1,1 +1,0 @@
1 -page
Parameter description
... ... @@ -1,1 +1,0 @@
1 -The page that holds the attachment (e.g. Studies.MyFilePage)
Parameter type
... ... @@ -1,1 +1,0 @@
1 -unknown
Parameter mandatory
... ... @@ -1,1 +1,0 @@
1 -No
XWiki.WikiMacroParameterClass[2]
Parameter default value
... ... @@ -1,1 +1,0 @@
1 -thumbnail (button in inline mode)
Parameter name
... ... @@ -1,1 +1,0 @@
1 -display
Parameter description
... ... @@ -1,1 +1,0 @@
1 -Values below ⬇️
Parameter type
... ... @@ -1,1 +1,0 @@
1 -unknown
Parameter mandatory
... ... @@ -1,1 +1,0 @@
1 -No
XWiki.WikiMacroParameterClass[3]
Parameter default value
... ... @@ -1,1 +1,0 @@
1 -100% for the full view or 100px for the thumbnail
Parameter name
... ... @@ -1,1 +1,0 @@
1 -width
Parameter description
... ... @@ -1,1 +1,0 @@
1 -Examples: 100%, 600px
Parameter type
... ... @@ -1,1 +1,0 @@
1 -unknown
Parameter mandatory
... ... @@ -1,1 +1,0 @@
1 -No
XWiki.WikiMacroParameterClass[4]
Parameter name
... ... @@ -1,1 +1,0 @@
1 -height
Parameter description
... ... @@ -1,1 +1,0 @@
1 -Examples: 100%, 600px
Parameter type
... ... @@ -1,1 +1,0 @@
1 -unknown
Parameter mandatory
... ... @@ -1,1 +1,0 @@
1 -No
XWiki.WikiMacroParameterClass[5]
Parameter name
... ... @@ -1,1 +1,0 @@
1 -alt
Parameter description
... ... @@ -1,1 +1,0 @@
1 -Alias for attachment name (used for display titles)
Parameter type
... ... @@ -1,1 +1,0 @@
1 -unknown
Parameter mandatory
... ... @@ -1,1 +1,0 @@
1 -No