Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@formsort/react-embed

Package Overview
Dependencies
Maintainers
6
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@formsort/react-embed - npm Package Compare versions

Comparing version 3.1.2 to 3.2.2

6

CHANGELOG.md
# CHANGELOG
## 3.2.2
### Various fixes & improvements
- update react-embed dependencies (#118) by @alikirec
## 3.1.2

@@ -3,0 +9,0 @@

13

lib/index.js

@@ -5,3 +5,4 @@ "use strict";

const tslib_1 = require("tslib");
const web_embed_api_1 = tslib_1.__importStar(require("@formsort/web-embed-api"));
const embed_messaging_manager_1 = require("@formsort/embed-messaging-manager");
const web_embed_api_1 = tslib_1.__importDefault(require("@formsort/web-embed-api"));
const react_1 = tslib_1.__importStar(require("react"));

@@ -11,7 +12,7 @@ exports.eventMapping = {

onRedirect: 'redirect',
onFlowLoaded: web_embed_api_1.SupportedAnalyticsEvent.FlowLoaded,
onFlowClosed: web_embed_api_1.SupportedAnalyticsEvent.FlowClosed,
onFlowFinalized: web_embed_api_1.SupportedAnalyticsEvent.FlowFinalized,
onStepLoaded: web_embed_api_1.SupportedAnalyticsEvent.StepLoaded,
onStepCompleted: web_embed_api_1.SupportedAnalyticsEvent.StepCompleted,
onFlowLoaded: embed_messaging_manager_1.SupportedAnalyticsEvent.FlowLoaded,
onFlowClosed: embed_messaging_manager_1.SupportedAnalyticsEvent.FlowClosed,
onFlowFinalized: embed_messaging_manager_1.SupportedAnalyticsEvent.FlowFinalized,
onStepLoaded: embed_messaging_manager_1.SupportedAnalyticsEvent.StepLoaded,
onStepCompleted: embed_messaging_manager_1.SupportedAnalyticsEvent.StepCompleted,
};

@@ -18,0 +19,0 @@ const attachEventListenersToEmbed = (embed, events) => {

{
"name": "@formsort/react-embed",
"version": "3.1.2",
"version": "3.2.2",
"description": "Embed formsort flows in react components",

@@ -60,3 +60,4 @@ "publishConfig": {

"dependencies": {
"@formsort/web-embed-api": "^2.4.1"
"@formsort/embed-messaging-manager": "^0.1.1",
"@formsort/web-embed-api": "^2.6.0"
},

@@ -63,0 +64,0 @@ "peerDependencies": {

@@ -7,2 +7,4 @@ # @formsort/react-embed

**Important note:** This package is intended for use in React web applications. If you're looking to embed Formsort flows in React Native applications, please see [React native embed guide](./ReactNativeEmbed.md).
## Installation

@@ -43,18 +45,18 @@

| Prop name | Description | Required | Example values |
| ------------- | ------------------------------------------------------------------------------------------------------------ | -------- | ---------------------------------------------------------- |
| clientLabel | client name | yes | `formsort` |
| flowLabel | flow name | yes | `onboarding` |
| variantLabel | variant name | no | `main` |
| responderUuid | responder uuid to load existing answers for | no | `e4923baa-dc2d-4555-813c-a166952292fa` |
| formsortEnv | formsort integrations environment label, if not using production | no | `staging` |
| queryParams | additional query params, to pre-populate answers in the form | no | `[['name', 'Olivia'], ['age', '3']]` |
| embedConfig | config passed to the underlying [`FormsortWebEmbed`](https://github.com/formsort/oss/tree/master/packages/web-embed-api) | no | `{ style: { height: '100%' } }` |
| onFlowLoaded | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#flowloaded-answers--key-string-any----void) | no | `() => { console.log('flow loaded') }` |
| onFlowClosed | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#flowclosed-answers--key-string-any---void) | no | `() => { console.log('flow closed') }` |
| onFlowFinalized | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#flowfinalized-answers--key-string-any---void) | no | `() => { console.log('flow finalized') }` |
| onStepLoaded | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#steploaded-answers--key-string-any---void) | no | `() => { console.log('step loaded') }` |
| onStepCompleted | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#steploaded-answers--key-string-any---void) | no | `() => { console.log('step loaded') }` |
| onRedirect | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#redirect--url-string-answers--key-string-any-----cancel-boolean---undefined) | no | `(url: string) => { console.log('redirecting to:', url) }` |
| onUnauthorized | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#unauthorized---void) | no | `() => { console.log('ID token is missing or invalid.') }` |
| Prop name | Description | Required | Example values |
| --------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- | ---------------------------------------------------------- |
| clientLabel | client name | yes | `formsort` |
| flowLabel | flow name | yes | `onboarding` |
| variantLabel | variant name | no | `main` |
| responderUuid | responder uuid to load existing answers for | no | `e4923baa-dc2d-4555-813c-a166952292fa` |
| formsortEnv | formsort integrations environment label, if not using production | no | `staging` |
| queryParams | additional query params, to pre-populate answers in the form | no | `[['name', 'Olivia'], ['age', '3']]` |
| embedConfig | config passed to the underlying [`FormsortWebEmbed`](https://github.com/formsort/oss/tree/master/packages/web-embed-api) | no | `{ style: { height: '100%' } }` |
| onFlowLoaded | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#flowloaded-answers--key-string-any----void) | no | `() => { console.log('flow loaded') }` |
| onFlowClosed | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#flowclosed-answers--key-string-any---void) | no | `() => { console.log('flow closed') }` |
| onFlowFinalized | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#flowfinalized-answers--key-string-any---void) | no | `() => { console.log('flow finalized') }` |
| onStepLoaded | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#steploaded-answers--key-string-any---void) | no | `() => { console.log('step loaded') }` |
| onStepCompleted | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#steploaded-answers--key-string-any---void) | no | `() => { console.log('step loaded') }` |
| onRedirect | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#redirect--url-string-answers--key-string-any-----cancel-boolean---undefined) | no | `(url: string) => { console.log('redirecting to:', url) }` |
| onUnauthorized | [event listener](https://github.com/formsort/oss/tree/master/packages/web-embed-api#unauthorized---void) | no | `() => { console.log('ID token is missing or invalid.') }` |

@@ -80,2 +82,1 @@ ### Loading a specific variant revision

```
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc