E.g:
<div title="Property Description" class="**vfsEdit**" vfsEditType="simple" style="font-size:11.9px !important">Lorem ipsum dolor sit amet, consectetur adipisicing elit. Aspernatur repellendus eum reprehenderit ut quae enim iusto nihil, qui, consequatur impedit dolorem voluptatum, necessitatibus! Voluptas obcaecati ipsam accusantium illum dolorum quaerat cumque praesentium nemo dignissimos necessitatibus non repellat nisi ex est doloremque ut atque, eveniet asperiores ratione minima soluta sint sapiente. Cum suscipit tempore dicta, voluptatem ipsam quibusdam nemo quisquam expedita provident nulla minus aspernatur sequi, quia reprehenderit? Nisi, maiores saepe, sequi totam tempore voluptas. Aut iste nam enim quidem, hic doloribus consequuntur. Ipsam veritatis, perferendis perspiciatis qu</div>
UNLESS - vf-cf-mf= “Some number”
E.g :
<div>
<div class="contactEmail vfsCopyFit" vf-cf-mf="9" vf-var="user.email" >john.public@1stDemoMortgage.com</div>
</div>
<style>
.contactEmail {
white-space: nowrap;
overflow: hidden;
}
</style>
NOTE - the editor only knows what to do based on how you set up the document.
CSS Rules:
.contactEmail {
width: 0px; -- Good
width: 0; -- Not good
}
E.g:
<td bgcolor="#ffffff" id="e183702a">
<img src="http://placehold.it/600x300" class="vfsEdit">
</td>
E.g
The Image Toolbar
This now uses two classes for image picking
How to Use
Wrap with an ided element ( div or td )
E.g
There are a few way to have the piece access the images for an element.
NOTE: It’s very important in the HTML to wrap the img element in a (div or td) with an id. The editor uses this div to build it’s controls.
Exact Match - specify the exact node and subnode where the image array exist you want.
<div bgcolor="#ffffff" id="e183702a8dbc4ca28d989af2814800fc">
<img src="http://placehold.it/600x300" class="vfsEdit" vfs-image="template.imageArr1" style="width: 600px; max-width: 600px; height: auto; background: #dddddd">
</div>
<td bgcolor="#ffffff" id="e183702a8dbc4ca28d989af2814800fc">
<img src="http://placehold.it/600x300" class="vfsEdit" vfs-image="user.dogs" style="width: 600px; max-width: 600px; height: auto; background: #dddddd">
</td>
Template Assumption Match - specify the exact node you want and the editor will check the root and if not found with then check the template node.
<td bgcolor="#ffffff" id="e183702a8dbc4ca28d989af2814800fc">
<img src="http://placehold.it/600x300" class="vfsEdit" vfs-image="imageArr1" style="width: 600px; max-width: 600px; height: auto; background: #dddddd">
</td>
**Using a Div to inject the image into the background-image
<div id="divImageParent">
<div class="vfsEdit vfImage" vf-image-property="background-image" vfs-image="imageArr1">
</td>
"version": "1.6",
"type": "email",
"jobId": "VE2017050920243446785ae1",
"authentication": {
"sponsorKey": "70d1e05967d44c8d9a550fefe4530633",
"clientKey": "f03cbf3cabac41b0ad9518462c897d1c"
},
"email": {
"subject": "Test Email",
"from" : {
"name": "John Public",
"email": "john.public@velma.com"
}
},
"template": {
"Email_SubjectLine":"text here",
"description": "VFS Email Editing Images",
"mediaType":"Email",
"name":"VFS Email Editing Images",
"sku":"30551",
"url":"https://s3-us-west-2.amazonaws.com/vfs-assets/user/dcarter/editor/ImageEditing/emailWithImages.html",
"imageArr1": [
{
"url": "https://s3-us-west-2.amazonaws.com/vfs-assets/user/dcarter/editor/ImageEditing/image1.jpg",
},
{
"url": "https://s3-us-west-2.amazonaws.com/vfs-assets/user/dcarter/editor/ImageEditing/image2.jpg",
},
{
"url": "https://s3-us-west-2.amazonaws.com/vfs-assets/user/dcarter/editor/ImageEditing/image3.jpg",
}
]
},
"user": {
"AppUniqueID": "",
"ID": 1010,
"firstName": "John",
"lastName": "Public",
"companyName": "The really long first demo mortage company name that doesn't seem to fit",
"dogs": [
{
"url": "https://s3-us-west-2.amazonaws.com/vfs-assets/user/dcarter/editor/ImageEditing/dog1.jpg",
},
{
"url": "https://s3-us-west-2.amazonaws.com/vfs-assets/user/dcarter/editor/ImageEditing/dog2.png",
},
{
"url": "https://s3-us-west-2.amazonaws.com/vfs-assets/user/dcarter/editor/ImageEditing/dog3.jpg",
}
]
}
}
Class: vfColor - this enables an element to have a color injected.
Attributes: vf-color-property - this is the css property to inject the color.
To Enable: add “colorPicking”: “true” in the template node of the command packet (can be added from the Fulfillment library in Velma).
This enables the color picking symbol to appear in the editor.
E.g:
Clicking this will show the color picker.
Use Color - Will inject the color into the editor specified elements. Clear Color - Will remove the color from the editor specified elements.
Html
E.g:
This will inject the color choosen into the background-color property.
<div class="vfColor" vf-color-property="background-color" >
<h3><b>Some Text </b></h3>
</div>
This will inject the color choosen into the color property.
<div class="vfColor" vf-color-property="color" >
<h3><b>Some Text </b></h3>
</div>
Color Picking Flow
Setting up command packet.
E.g:
E.g:
<?xml version="1.0" encoding="UTF-8"?>
<CORSConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
<CORSRule>
<AllowedOrigin>*</AllowedOrigin>
<AllowedMethod>GET</AllowedMethod>
</CORSRule>
</CORSConfiguration>
E.g:
vf-char-count=”int” - represents the max characters
E.g:
<div title="Property Description" class="vfEdit"
vf-char-count="150" >Lorem ipsum dolor sit amet, consectetur adipisicing elit.
</div>
On the editor you will see a counter on the bottom right of the editable area showing the total and current count of characters.