Skip to main content

IEpilogue interface

📖 Description​

Interface that describes the properties to define a form epilogue within a form definition. An epilogue can be used by runners (that support it) to show a closing message when a form is completed.

📃 Type declaration​

interface IEpilogue {
  context: Context | undefined;Readonly
  branch: string | undefined;Readonly
  title?: string;ReadonlyOptional
  description?: string;ReadonlyOptional
  image?: string;ReadonlyOptional
  video?: string;ReadonlyOptional
  button?: {
    label: string;
    url: string;
    target: "self" | "blank";
  };ReadonlyOptional
  repeatable?: boolean;ReadonlyOptional
  redirectUrl?: string;ReadonlyOptional
  getRedirect?: () => string | undefined;FunctionOptional
}
🖱ī¸ Hover with the mouse over a property name for a tooltip with the description of that property. Click it for more information.

🗃ī¸ Properties​


🏷ī¸ branch​

Contains the branch identifier of the epilogue. This property is undefined if the epilogue is not set for a certain branch. This is the case when the root epilogue is supplied.

Type​

string | undefined


🏷ī¸ button​

Contains an optional button with a hyperlink to show.

Type​

{
/* Specifies the label for the button. */
label: string;

/* Specifies the URL for the button. */
url: string;

/* Specifies if the button should open a new window/tab. */
target: "self" | "blank";
}

🏷ī¸ context​

Contains the Context instance for the epilogue.

Type​

Context | undefined


🏷ī¸ description​

Contains the description (supports markdown).

Type​

string


🏷ī¸ image​

Contains the URL of an image to show.

Type​

string

tip

It is possible to embed images using Base64 encoding.


🏷ī¸ redirectUrl​

Contains an URL to redirect to when the form ends.

Type​

string

warning

When this property is used, all other properties are ignored.


🏷ī¸ repeatable​

Contains if the form is repeatable. If set to true a button will be shown to start a new form session.

Type​

boolean


🏷ī¸ title​

Contains the title (supports markdown).

Type​

string


🏷ī¸ video​

Contains the URL of a video to show. Currently, YouTube and Vimeo are supported. The shareable URL of the video needs to be supplied.

Type​

string

â–ļī¸ Functions​


🔧 getRedirect​

Redirect helper function that is useful for retrieving the actual URL to redirect to when a redirectUrl is set. Any variables used in the redirect URL are processed and the function returns a valid URL or undefined if the URL is invalid.

Signature​

() => string | undefined

Return value​

Returns a valid URL or undefined if the URL is invalid.