mirror of
https://github.com/TiddlyWiki/TiddlyWiki5.git
synced 2026-04-27 02:24:40 +00:00
First pass at external image support
A bunch of little changes that together enable external image support. Try: ``` tiddlywiki editions/tw5.com --verbose --build externalimages ``` Then open `externalimages.html`, look for the images in the more/types tab of the sidebar, open them and verify that they are set with an external SRC attribute, not a data URI.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
title: ImageWidget
|
||||
created: 20140416160234142
|
||||
modified: 20140416160234142
|
||||
modified: 20140611160234142
|
||||
tags: widget
|
||||
|
||||
! Introduction
|
||||
@@ -18,3 +18,11 @@ Any content of the `<$image>` widget is ignored.
|
||||
|tooltip |The tooltip to be displayed over the image |
|
||||
|class |CSS classes to be assigned to the `<img>` element |
|
||||
|
||||
! External Images and the ''_canonical_uri'' field
|
||||
|
||||
When used to display tiddler-based images, the image widget operates in two distinct modes:
|
||||
|
||||
* If the ''_canonical_uri'' field is present then it is used as the ''src'' attribute of the generated `<img>` element and the ''text'' field is ignored
|
||||
* Without the ''_canonical_uri'' field, the image widget generates an `<img>` element that embeds the image data directly using a `data:` URI.
|
||||
|
||||
See ExternalImages for more details.
|
||||
|
||||
Reference in New Issue
Block a user