Skip to content

New @anvilco/anvil-embed-frame package #12

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Oct 3, 2022
Merged

Conversation

Winggo
Copy link
Contributor

@Winggo Winggo commented Sep 30, 2022

Description of the change

Build a new AnvilEmbedFrame react component that can be used for embedding Etch e-signatures, Workflows, and Editors, now that the app have a uniform protocol for window.postMessage(object). All events are handled by the onEvent callback.

Once this package is published, we can deprecate @anvil/react-signature-frame and @anvilco/react-signature-modal.

Works for standalone Etch
Can be embedded
Pasted Graphic 4

Gets signerComplete event
Pasted Graphic 3

Gets signerError event
Pasted Graphic 5

Works for Workflows
Can be embedded
Pasted Graphic 8

Gets forgeSubmitPage and forgeComplete events
Pasted Graphic 6

Works for Editors
Can be embedded
Pasted Graphic 9
Pasted Graphic 12
Pasted Graphic 14
Pasted Graphic 16

Gets embeddedError event
Token Used

Gets castEdit event
Pasted Graphic 10

Gets etchPacketSent event
Pasted Graphic 13

Gets weldCreate event
Pasted Graphic 15

Gets weldEdit event
Pasted Graphic 17

Type of change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Related issues

Fixes anvilco/public-repos#18

Dev Checklist

  • The code changed/added as part of this pull request has been covered with tests
  • All tests related to the changed code pass in development
  • No previous tests unrelated to the changed code fail in development

@Winggo Winggo added the enhancement New feature or request label Sep 30, 2022
@Winggo Winggo self-assigned this Sep 30, 2022
@Winggo Winggo requested a review from benogle October 1, 2022 00:00
Copy link
Contributor

@benogle benogle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job on the PR, thanks for being super thorough in the main post!

@Winggo
Copy link
Contributor Author

Winggo commented Oct 1, 2022

Tested manually embedding e-sign packets, workflows, and editors (PDF template, etch, workflow).

Checked that all events are received:

  • signerComplete
  • signerError
  • forgeSubmitPage
  • forgeComplete
  • embeddedError
  • castEdit
  • etchPacketSent
  • weldCreate
  • weldEdit

@Winggo
Copy link
Contributor Author

Winggo commented Oct 1, 2022

Haven't included TypeScript support yet -- think I should include in this PR?

@benogle
Copy link
Contributor

benogle commented Oct 1, 2022

Haven't included TypeScript support yet -- think I should include in this PR?

Yeah if possible, good catch

@Winggo Winggo merged commit c848742 into main Oct 3, 2022
@Winggo Winggo deleted the wt/add-anvilEmbedFrame branch October 3, 2022 20:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants