This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"engines": { | |
"node": "18.16.0", | |
"npm": "9.x.x" | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { ShowToastEvent } from 'lightning/platformShowToastEvent'; | |
import { getRecord } from 'lightning/uiRecordApi'; | |
import { api, LightningElement, track, wire } from 'lwc'; | |
const ICONS = { | |
Account: 'standard:account', | |
Asset: 'standard:asset_object' | |
}; | |
export default class CustomMapView extends LightningElement { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<lightning-map list-view={listView} map-markers={mapMarkers} zoom-level={zoomLevel} style={styles}></lightning-map> | |
</template> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8" ?> | |
<LightningComponentBundle xmlns="http://soap.sforce.com/2006/04/metadata"> | |
<apiVersion>59.0</apiVersion> | |
<isExposed>true</isExposed> | |
<masterLabel>Custom Map View</masterLabel> | |
<description>Configurable map component for displaying locations via Google Maps API.</description> | |
<targets> | |
<target>lightning__RecordPage</target> | |
</targets> | |
<targetConfigs> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const base64 = 'JVBERi0xLjMKJcTl8uXrp/Og0MTGCjMgMCBvYmoKPDwgL0ZpbHRlciAvRmxh...'; | |
export { base64 }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { api, LightningElement } from 'lwc'; | |
import { base64 } from './example.js'; | |
export default class Base64ToPdf extends LightningElement { | |
pdf = `data:application/pdf;base64,${base64}`; | |
fileName = 'example.pdf'; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<a class="slds-button slds-button_brand" href={pdf} download={fileName}>Download PDF File</a> | |
</template> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { api, LightningElement } from 'lwc'; | |
import { base64 } from './example.js'; | |
export default class Base64ToPdf extends LightningElement { | |
pdf = `data:application/pdf;base64,${base64}`; | |
fileName = 'example.pdf'; | |
get pdfSrc() { | |
return this.pdf; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<lightning-card title="Base64 To PDF" icon-name="doctype:pdf"> | |
<a class="slds-button slds-button_brand" href={pdf} download={fileName} slot="actions">Download PDF File</a> | |
<div class="slds-p-around_medium"> | |
<iframe src={pdfSrc} height="100%" width="500px" title="iFrame"></iframe> | |
</div> | |
</lightning-card> | |
</template> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8" ?> | |
<LightningComponentBundle xmlns="http://soap.sforce.com/2006/04/metadata"> | |
<apiVersion>59.0</apiVersion> | |
<isExposed>true</isExposed> | |
<masterLabel>Open Record Page Flow Action</masterLabel> | |
<description>Component to forward to a record page from flow.</description> | |
<targets> | |
<target>lightning__FlowScreen</target> | |
</targets> | |
<targetConfigs> |