Thumbnail Macro

Last modified by Thomas Mortagne on 2023/10/16 00:16

cogDisplays an image as thumbnail.
TypeXAR
Category
Developed by

Flavius Olaru

Active Installs56
Rating
0 Votes
LicenseGNU Lesser General Public License 2.1

Installable with the Extension Manager

Description

A replacement of the image syntax ([[image]] in XWiki Syntax 2.0+) that displays an image as a thumbnail with a link to the full image.

Usage

{{thumbnail image='404.png' height="50" keepAspectRatio="true"/}}
ParamRequiredDefault ValueDescription
imageYN/AThe reference to the image using the XWiki Syntax 2.0 Image Syntax (e.g. wiki:space.page@attachment).
widthNN/ADefines the width of the displayed image.
heightNN/ADefines the height of the displayed image.
keepAspectRatioNtrue if only one of width or height is specifiedKeeps the aspect ratio when resizing the image.

Screenshots

thumbnail.png

Prerequisites & Installation Instructions

We recommend using the Extension Manager to install this extension (Make sure that the text "Installable with the Extension Manager" is displayed at the top right location on this page to know if this extension can be installed with the Extension Manager). Note that installing Extensions when being offline is currently not supported and you'd need to use some complex manual method.

You can also use the following manual method, which is useful if this extension cannot be installed with the Extension Manager or if you're using an old version of XWiki that doesn't have the Extension Manager:

  1. Log in the wiki with a user having Administration rights
  2. Go to the Administration page and select the Import category
  3. Follow the on-screen instructions to upload the downloaded XAR
  4. Click on the uploaded XAR and follow the instructions
  5. You'll also need to install all dependent Extensions that are not already installed in your wiki

Release Notes

v1.1

Added fix for empty width, height and integrated it with lightbox macro.

Dependencies

Dependencies for this extension (thumbnail-macro 1.1):

Tags:
    

Get Connected