Constructor
new LightboxImage(fileLink, fileTitle, index, position, thumb, [caption])
#
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
fileLink |
string | Link to the file - generally a thumb URL |
|
fileTitle |
mw.Title | Represents the File: page |
|
index |
number | Which number file this is |
|
position |
number | The relative position of this image to others with same file |
|
thumb |
HTMLImageElement | The thumbnail that represents this image on the page |
|
caption |
string |
optional |
The caption, if any. |
Properties
alt :string
#
caption :string
#
index :number
#
What number this image is in the array of indexed images
Type:
- number
originalHeight :number
#
Height of the full-sized file (read from HTML data attribute, might be missing)
Type:
- number
originalWidth :number
#
Width of the full-sized file (read from HTML data attribute, might be missing)
Type:
- number
position :number
#
The relative position of this image to others with same file
Type:
- number
src :string
#
Link to the file - generally a thumb URL
Type:
- string
thumbnail :HTMLImageElement
#
The element that holds the already-loaded thumbnail of the image
Type:
Methods
getUrlParam() → {Object|null}
#
null}
#
Parses the handler-specific thumbnail parameter (multilingual SVG lang, PDF page,
or paged TIFF lossy-prefixed page) from the sample thumbnail URL, if present.
Returns:
name/value are the
handler parameter (e.g. lang/de), urlParam is the width-less iiurlparam string
(e.g. langde, or lossy-page1 for paged TIFFs).
- Type
-
Object
|
null
Parses the handler-specific thumbnail parameter (multilingual SVG lang, PDF page,
or paged TIFF lossy-prefixed page) from the sample thumbnail URL, if present.