UNPKG

fonteva-design-guide

Version:

## Dev, Build and Test

41 lines (35 loc) 998 B
import { api } from 'lwc'; // import getDirectLink from '@Salesforce/apex/Framework.AwsUtil.getDirectLink'; import PFM_Element from 'c/pfmElement'; export default class PfmImg extends PFM_Element { // IMG @api src; @api align; @api alt; @api name; @api border; @api width; @api height; @api hspace; @api vspace; constructor() { super(); } connectedCallback() { this.updateSrc(); } renderedCallback() { super.initializeElement(this, super.__proto__, 'img'); } updateSrc() { // if (this.src && this.src.match(/.*AwsProxy.key=(.*)&bucket=(.*)/)) { // const srcUrl = { // url: this.src // }; // this.src = ''; // getDirectLink(srcUrl).then(result => { // this.src = result; // }); // } } }