Giter Club home page Giter Club logo

salesforce-webviewer-attachments's Introduction

How to View, Edit, Annotate and Redact Salesforce Record Attachment Files in a Lightning Web Component

Overview

This repository is a ready-to-deploy Salesforce implementation of Apryse SDK's WebViewer. This LWC Component will have the ability to enable client-side viewing, editing, annotation and redaction and much more in your Salesforce environment using Salesforce files or external files.

Quick Installation

Prerequisites

Required tools: VS Code + Salesforce Extension

Installation Steps

  • Clone the repository to your local and open it in VS Code with the Salesforce Extension installed.
  • Authenticate your environment (you can follow this example)
  • Right-click on the force-app folder and select SFDX: Deploy Source To Org or use sf project deploy start in your terminal
  • Once deployed, navigate to a Lightning page, click Setup > Edit Page and drag and drop the pdftronWebviewerContainer into the desired location of your Lightning page

Note on Salesforce deployment size limits

Please note that maximum deployment size is capped to ~39MB - in some cases the WebViewer worker files stored in /staticresources/ exceed that file size limit. If you are facing this error, please split up your deployments in multiple parts to adhere to this size limit.

Example 1

Your /staticresources/ exceeds the 39MB limit - please deploy worker files one by one.

Example 2

Your /staticresources/ do not exceed the 39MB limit, but your total project is above the limit - you can deploy staticresources first, then deploy the other metadata types like so:

  1. Deploy only StaticResource type sf project deploy start -m StaticResource

  2. Deploy other Metadata types sf project deploy start -m AuraDefinitionBundle ApexClass LightningComponentBundle LightningMessageChannel

Guide

This repository serves as the code-along sample for this guide.

Project Structure

The Apryse SDK WebViewer integrates with Salesforce by using WebViewer's source files in Salesforce's /staticresources/ - we leverage LWC to contain WebViewer UI inside of an iframe. We can use your browser's postMessage API and leverage the main LWC component to communicate with other LWC components and use Apex to retrieve files, user information and other data from Salesforce to build a fully custom document workflow.

Documentation

You can find WebViewer's Salesforce-specific documentation here. For technical inquiries reach out to [email protected] - for information on licensing you can contact [email protected]

salesforce-webviewer-attachments's People

Contributors

tommywintersr avatar swoshua avatar correyl avatar mparizeau-pdftron avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.