Skip to main content

Privacy Policy

This section describes the BfmPrivacyPolicyComponent component.

Composition

The BfmPrivacyPolicyComponent component is composed of the following elements:

Usage

To use the BfmPrivacyPolicyComponent, you need to import it in your component:

privacy-policy.component.ts
import { BfmPrivacyPolicyComponent } from "@celerofinancas/ui-auth";

@Component({
standalone: true,
selector: 'bfm-privacy-policy',
imports: [BfmPrivacyPolicyComponent],
templateUrl: './privacy-policy.component.html',
})
export class PrivacyPolicyComponent {}

Then, you can use the BfmPrivacyPolicyComponent in your template:

privacy-policy.component.html
  <bfm-privacy-policy 
[hasAccepted]="hasAccepted"
[showUseTerms]="showUseTerms"
[downloadTermDescription]="downloadTermDescription"
[acceptTermDescription]="acceptTermDescription"
[privacyPolicyImage]="privacyPolicyImage"
/>

Inputs

The BfmPrivacyPolicyComponent has the following inputs:

hasAccepted

Controls weather the user has already accepted the policy

TypeDefault
booleanfalse

showUseTerms

Controls whether the user terms are displayed.

TypeDefault
booleanfalse

downloadTermDescription

Text to show in the download button

TypeDefault
stringBaixar termo

acceptTermDescription

Text to show in the accept button

TypeDefault
stringAceitar

privacyPolicyImage

The image displayed in the page.

TypeDefault
stringassets/terms/privacy-policy.svg

Events

The BfmPrivacyPolicyComponent has the following events:

Configuration

TOKEN PRIVACY_POLICY_TERMS

To customize the BfmPrivacyPolicyComponent, you can inject the PRIVACY_POLICY_TERMS token in your module.

This token is used to provide custom values to the component. If is not provided, the default values will be used.

Properties

KeyDescriptionDefault
visibleTermsDetermines if terms are visiblefalse

The PRIVACY_POLICY_TERMS default values are:

{
"visibleTerms": "false",
}

Example

To customize the BfmPrivacyPolicyComponent, you can inject the PRIVACY_POLICY_TERMS token in your module.

app.config.ts
import { ApplicationConfig } from "@angular/core";
import { PRIVACY_POLICY_TERMS} from "@celerofinancas/ui-auth";

export const appConfig: ApplicationConfig = {
providers: [
{
provide: PRIVACY_POLICY_TERMS,
useValue: {
visibleTerms: true,
},
}
],
};