@meiko/sortter-resellers-web-component
v1.0.5
Published
The sortter-reseller-form-web-component is a custom web component designed to integrate seamlessly with Sortter Affiliates. Built using Lit, this component allows you to easily embed Sortter's loan application form into your website or application. Instal
Downloads
511
Keywords
Readme
Sortter Resellers Web Component
The sortter-reseller-form-web-component is a custom web component designed to integrate seamlessly with Sortter Affiliates. Built using Lit, this component allows you to easily embed Sortter's loan application form into your website or application. Installation
You can load the script in directly in your html
<script type="module" src="< path-to-the-script-file >"></script>
Usage
To use the Sortter Form Web Component, you can include the tag in your HTML code, along with attributes to customize the form according to your needs.
<sortter-reseller-form
alternativeUrl="string | null"
b2cUrl="string | null"
b2bUrl="string | null"
defaultLoanType="personal | corporate"
privacyPolicyUrl="string"
privacyPolicyText="string"
splashLogo="url"
stage="test | null"
theme="'custom || Sortter || '' "
type="both | personal | corporate"
utm="string"
></sortter-reseller-form>
Available Attributes for UI and functionality
- alternativeUrl: If redirect does not work and you want to use alternative location, define alternative Url. Defaults to redirectUrl.
- b2cUrl: Url redirect to business to customer link. This is defined by default, but it can be overwritten if needed.
- b2bUrl: Url redirect to business to business link. This is defined by default, but it can be overwritten if needed.
- defaultLoanType: This atttribute works only when "type" attribute is set to value "both". It defines which loan type will be shown first by default.
- privacyPolicyUrl: URL to your privacy policy page.
- privacyPolicyText: Text to display for the privacy policy link.
- splashLogo: URL to the splash logo image that will be displayed at the splash screen.
- stage: use 'test' if you want to see where the user would be redirected without actually redirecting them.
- theme: Defaults to "Sortter". Use 'custom' to return without styles
- type: Define what loan types you want to include
- utm: You can include UTM query to this attribute. It will be added to end of b2cUrl or b2bUrl as is.
Available Attributes for amount settings
- b2bLoanAmount: Default value for loan in B2B
- b2bLoanPeriod: Default value for loan period in B2B
- b2bLoanMax: Max value of loan for B2B, defaults to 10_000_000
- b2cLoanAmount: Default value for loan in B2C
- b2cLoanPeriod: Default value for loan in B2C
- b2cLoanMax: Max value of loan for B2C, defaults to 70_000