Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Name

Type

Description

page

String

The UUID of your page (required)

business

String

The slug of your business (required)

lang

String

Set the widget language

reservation

String

The ID of the reservation to show (used for cancellation)

resource

String

The ID of the resource to preselect

contact

String

If specified, skip the contact details step and link the reservation to this contact ID

lead

String

If specified, skip the contact details step and link the reservation to this lead ID

auto

String

Space-separated string containing the properties that should automatically retrieved from the current URL. Currently supported: reservation resource

autoList (script only)

AttributeTokenList (see below)

An object representing the auto property with add/remove/toggle/contains methods.

Common events

Properties of events can be found in the detail property of the CustomEvent. These events bubble up the tree.

...

Name

Type

Description

isOpen

property

Dynamic boolean property to check whether the widget is shown

open()

method

Call to open the widget

close()

method

Call to close the widget

toggle()

method

Call to toggle open/close

open

event

Fired when the widget is opened

close

event

Fired when the widget is closed

AttributeTokenList

This object mimics the behaviour of DOMTokenList, as we cannot instantiate that directly. This object is a view of the attribute of an element and thus does not have any state of its own. When adding or removing tokens, extra whitespace can be stripped and duplicates can be removed.

Name

Type

Description

add(…tokens: string[])

method

Accepts any number of parameters. Each parameter is treated as a String token to be added to the attribute.

remove(…tokens: string[])

method

Accepts any number of parameters. Each parameter is treated as a String token to be removed from the attribute.

contains(token: string): boolean

method

Returns whether or not token is part of the token list.

toggle(token: string): boolean

toggle(token: string, force: boolean): boolean

method

Add or removes the token to the list, depending on the current state or the force parameter. Returns whether the token is in the list after the call.

length: number

property

The amount of tokens in the list.

item(index: number): string

method

Returns the token at the specified index.