Components
Kind: element (inline) · Session key: vatCodePicker · React: <FinBazeVatCodePicker />
Create the session#
mutation {
createEmbedSession(input: {
companyId: "…"
user: { externalUserId: "…" }
components: { vatCodePicker: { enabled: true } }
}) { clientSecret }
}
Requirements#
No feature requirements.
Component features#
None.
Options#
Passed to instance.create("vat-code-picker", options) or as props.
| Option | Type | |
|---|---|---|
value | string | The VAT code chosen at first. |
direction | 'sales' | 'purchase' | Sales (default) or purchases. |
country | string | Only this country's codes. Defaults to all for sales and the company's country for purchases. |
label | string | The field label. |
disabled | boolean | Show the field but do not allow changes. |
Every component also takes appearance and navigation ("internal" or "external").
Events#
| Event | React prop |
|---|---|
ready | onReady |
navigate | onNavigate |
error | onError |
change | onChange |
Use it#
import { FinBazeVatCodePicker } from "@finbaze/embed-react";
<FinBazeVatCodePicker />
const component = instance.create("vat-code-picker");
component.mount("#finbaze");