Tag Action
What is Tag action ?
Tag Action is a feature in SharinPix which provides field update when a tag is applied on an image. It supports both Standard and Custom objects. This feature is available in both Salesforce Classic and Lightning.
Enabling Tag action in Salesforce Classic Experience
To activate Tag Action in the Salesforce Classic Experience, you only need to add the code snippet below within a Visualforce Page. It is to be noted that the recordId attribute takes as value the Album Id of the corresponding SharinPix Album.
<sharinpix:TagAction recordId="{!$CurrentPage.Parameters.Id}" />
Enabling Tag action in Salesforce Lightning Experience
- Drag and drop the SharinPix Album component from the App builder and place it on the Lightning Page.
- From the component properties menu, click on the checkbox Enable Action.
- Save the page when you are done.
Information:
The SharinPix Album component was previously named SharinPix.
Configuring Tag Action
Note: The present example requires an access to the Administration Dashboard. For more information about how to access and use the Administration Dashboard, refer to the following article:
- The Tag Action feature can be set up through the SharinPix Admin Panel in the Tags tab (you can access the admin Panel from SharinPix Settings tab within Salesforce).
- Create a new tag or edit an existing one.
- In the Tag Actions section:
- Field name: Insert the Salesforce API name of the field you want to update
- Value: Select between a predefined value or a custom one
- Click on Update Tag to save the action.
- Optional: Click on button New Tag Action to create more Tag Actions for the current tag.
Note:
For the Tag Action to work properly, you should ensure that the users have access to the field applied to the Tag Action's configuration.
Name | Description |
---|---|
Width | The original width of the image. |
Height | The original height of the image. |
Full url | The url of the image with maximum width and height of 1920px. |
Large url | The url of the image with maximum width and height of 200px. |
Mini url | The url of the image with maximum width and height of 100px. |
Original url | The url of the original image |
Id | The SharinPix Id of the image as stored in the database of SharinPix. |
Geolocation | Geolocation value found in the image metadata. |
Fit to size |
A URL to the image fitted to the specified size. Click here for more details about Fit to size. |
Fill to size | A URL to the image filled to the specified size. Click here for more details about Fill to size. |
Scale to size | A URL to the image filled to the specified size. Click here for more details about Scale to size. |
Pad to size | A URL to the image padded to the specified size. Click here for more details about Pad to size. |
Custom value | Add a custom value to the field (can be a text, true or false, a numeric) |
Watermark | Adds a watermark on the image. Click here for more details about how to add a Watermark. |
Limit to size | Sets a size limit. Click here for more details about Limit to size. |
Transformation
The difference between Fit, Fill, Scale and Pad is as follows:
- Fit to sIze: The image is resized so that it takes up as much space as possible within a bounding box defined by the given width and height parameters. The original aspect ratio is retained and all of the original image is visible.
- Fill to size: An image is created with the exact given width and height while retaining the original aspect ratio, using only part of the image that fills the given dimensions if necessary (only part of the original image might be visible if the requested aspect ratio is different from the original aspect ratio).
- Scale to size: Changes the size of the image exactly to the given width and height without necessarily retaining the original aspect ratio: all original image parts are visible but might be stretched or shrunk.
- Pad to size: Resizes the image to fill the given width and height while retaining the original aspect ratio and with all of the original image visible. If the proportions of the original image do not match the given width and height, padding is added to the image to reach the required size.
- Limit to size: Sets a size limit. If an image's dimensions exceed the limit value entered, the image is scaled down to that specified value.
The image below depicts how to apply the value Fit to size:

Note: The original image is not affected. The size can be specified by using <width>x<height> or <width and height>.
Examples are:
- 500x500 for a width and height of 500px. This can also be only written as "500".
- 600x400 for a width of 600px and height of 400px.
- 750 for a width and height of both 750px.
For more information about fit, fill, scale and pad, refer to the following article:
Watermark
When choosing the option Watermark, the following is displayed in the Tag Actions section:
You can now set:
- The Image Id of the watermark image to be used in the Image field.
- The width of the watermark in the Width field.
- The height of the watermark in the Height field.
- Choose the watermark format in the field labelled Format. It can either be in pixels or in percentage.
- The opacity in the field labelled Opacity.
For more information about Watermark, refer to the following article:
Tag action in effect
Assuming the newly-created tag action is properly configured, each time the tag is applied to an image, the tag action is executed and the selected value is inserted into the defined field as described above.
Note:
By default, the SharinPix Tag Action is not triggered when uploading images using the SharinPix mobile app.
To enable the Tag Action feature when uploading images using the SharinPix mobile app, refer to the following article:
Tag Action does not work when uploading images using the SharinPix mobile app. What should I do?
0 Comments
Add your comment