--- a/src/pyams_content/component/illustration/__init__.py Tue Mar 26 12:33:58 2019 +0100
+++ b/src/pyams_content/component/illustration/__init__.py Tue Mar 26 16:47:26 2019 +0100
@@ -217,3 +217,26 @@
"""Illustration renderers vocabulary"""
content_interface = IIllustration
+
+
+#
+# Custom image file to illustration adapter
+#
+
+@adapter_config(context=IImage, provides=IBasicIllustration)
+class VirtualIllustration(object):
+ """Virtual illustration based on image file"""
+
+ title = None
+ alt_title = None
+ author = None
+
+ def __init__(self, source):
+ self.source = source
+
+ @property
+ def data(self):
+ return self.source
+
+ def has_data(self):
+ return bool(self.source)