diff --git a/api/etemplate.php b/api/etemplate.php index 31e94bbdca..13a445ca9a 100644 --- a/api/etemplate.php +++ b/api/etemplate.php @@ -161,6 +161,7 @@ function send_template() if (!empty($attrs['image']) && (empty($attrs['background_image']) || $attrs['background_image'] === 'false')) { $tag = 'et2-image'; + $attrs['src'] = $attrs['image']; } // novalidation --> noValidation if (!empty($attrs['novalidation']) && in_array($attrs['novalidation'], ['true', '1'], true)) diff --git a/api/js/etemplate/Et2Image/Et2Image.ts b/api/js/etemplate/Et2Image/Et2Image.ts index fffc37e39c..3212b2b285 100644 --- a/api/js/etemplate/Et2Image/Et2Image.ts +++ b/api/js/etemplate/Et2Image/Et2Image.ts @@ -122,6 +122,11 @@ export class Et2Image extends Et2Widget(LitElement) implements et2_IDetachedDOM } } + get src() + { + return this.__src; + } + _handleClick(_ev : MouseEvent) : boolean { if(this.href)