prefs
Types
#PreferenceValue
Preference with its new desired value.
Properties:
- path
string
The preference path
- value
- (optional)
any
Preference value. None indicate to use the default.
#TranslateLanguageSettings
Current settings active for the given language pair or just the source language.
Properties:
- isLanguagePairOnAlwaysTranslateList
boolean
Is the given language pair on the always translate list.
- isLanguageInNeverTranslateList
boolean
Is the given language source language on the never translate list.
- isSiteOnNeverTranslateList
boolean
Is the given site on the never translate list.
- shouldShowAlwaysTranslateShortcut
boolean
Should show always translate shortcut for this language.
- shouldShowNeverTranslateShortcut
boolean
Should show never translate shortcut for this language.
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onChanged
Fired when a preference value has changed.
Parameters:
- newValue
PreferenceValue
Information about the changed preference.
Methods
#get
Get a specific named preference value.
Parameters:
- path
string
The preference path
#set
Set a specific preference.
Parameters:
- newValue
PreferenceValue
⚠ NO DESCRIPTION PROVIDED
#getForCache
Get all preferences to be cached on the JS side with one call. Only changes to these will be reported by onChanged. The result type is optimized for bulk transfer of over 450 values
Parameters:
- paths
Which preferences are needed
Array
of:- string
#setLanguagePairToAlwaysTranslate
Translate: Add or remove a pair of languages to the preference for automatic translation.
Parameters:
- tabId
integer
The tab id used to look up the translate manager stored in the WebContents data. Not used for anything else.
- enable
boolean
true to add the language pair to the list, false to remove it from the list.
- original_language
string
Original language to translate from.
- target_language
string
Target language to translate to.
#setLanguageToNeverTranslate
Translate: Add or remove a pair of languages to the preference for never doing automatic translation.
Parameters:
- tabId
integer
The tab id used to look up the translate manager stored in the WebContents data. Not used for anything else.
- block
boolean
true to add the language to the blocked list, false to remove it from the list.
- original_language
string
Original language to never translate from.
- target_language
string
Target language to never translate to.
#setSiteToNeverTranslate
Translate: Add or remove a site to the preference for never doing automatic translation.
Parameters:
- tabId
integer
The tab id used to look up the translate manager stored in the WebContents data and the site to block.
- block
boolean
true to add the language to the blocked list, false to remove it from the list.
- original_language
string
Original language to never translate from.
- target_language
string
Target language to never translate to.
#getTranslateSettings
Translate: Get settings for the given language pair.
Parameters:
- tabId
integer
The tab id used to look up the translate manager stored in the WebContents data. Not used for anything else.
- original_language
string
Original language to never translate from.
- target_language
string
Target language to never translate to.
#setTranslationDeclined
Translate: Translation dialog was closed without being used, record that fact.
Parameters:
- tabId
integer
The tab id used to look up the translate manager stored in the WebContents data. Not used for anything else.
- explicitly_closed
boolean
true if the dialog was closed explicitly (from close button), otherwise false if it was closed from clicking outside it or similar.
- original_language
string
Original language of the page.
- target_language
string
Target language selected.
#resetTranslationPrefs
Translate: Resets the translation preferences to defaults.
- api['name']
- ⚠ WARNING! Failed to get info as type not provided
contacts
Types
#ContactPropertyName
ENUM
Property types for adding, updating and removing postal address and phonenumbers for contacts.
- postalAddress
- phoneNumber
#EmailAddress
An email address object
Properties:
- id
string
The unique identifier for the email address. IDs are unique within the current profile, and they remain valid even after the browser is restarted.
- emailAddress
- (optional)
string
The email address of the contact.
- type
- (optional)
string
The type of email address. WORK, HOME etc
- favorite
- (optional)
boolean
Is this email address favorite for user.
- obsolete
- (optional)
boolean
Is this email address obsolete. If true it should not show up in autocomplete when composing email
#Phonenumber
A phonenumber object
Properties:
- id
string
The unique identifier for the phonenumber. IDs are unique within the current profile, and they remain valid even after the browser is restarted.
- phoneNumber
- (optional)
string
The phonenumber.
- type
- (optional)
string
The type of phonenumber. WORK, HOME etc
#PostalAddress
A postal address object
Properties:
- id
string
The unique identifier for the postal address. IDs are unique within the current profile, and they remain valid even after the browser is restarted.
- postalAddress
- (optional)
string
The postal address.
- type
- (optional)
string
The type of postal address. WORK, HOME etc
#Contact
A contact object
Properties:
- id
string
The unique identifier for the contact. IDs are unique within the current profile, and they remain valid even after the browser is restarted.
- name
- (optional)
string
The name id of the contact.
- birthday
- (optional)
number
The birthday of the contact.
- note
- (optional)
string
A note for the contact.
- emailAddresses
⚠ NO DESCRIPTION PROVIDED
Array
of:- EmailAddress
- phoneNumbers
⚠ NO DESCRIPTION PROVIDED
Array
of:- Phonenumber
- postalAddresses
⚠ NO DESCRIPTION PROVIDED
Array
of:- PostalAddress
- avatarUrl
- (optional)
string
A url for the contact avatar url.
- separator
boolean
Is this contact a dummy separator.
- generatedFromSentMail
boolean
Is this contact generated by sent mail.
- trusted
- (optional)
boolean
Can this contact load external content
#CreateUpdateDetails
Object passed to the create and update contact function.
Properties:
- name
- (optional)
string
The name of the contact.
- birthday
- (optional)
number
The birthday of the contact. In milliseconds since epoch
- note
- (optional)
string
The note for the contact.
- generatedFromSentMail
- (optional)
boolean
Was this contact generated by sent mail.
- avatarUrl
- (optional)
string
A url for the contact avatar url.
- separator
- (optional)
boolean
Is this contact a dummy separator.
- trusted
- (optional)
boolean
Can this contact load external content
#AddPropertyDetails
Object passed to the addPropertyItem() function.
Properties:
- propertyName
ContactPropertyName
The type to add (postal address, phone).
- contactId
string
The id of the contact.
- propertyValue
string
The email address or phonenumber of the contact.
- type
string
The type of email address. Example: WORK, HOME. Note type=INTERNET is default.
- asDefault
- (optional)
boolean
Should the email address be default for the contact
#EmailAddressAddUpdate
Object passed to the addPropertyItem() function.
Properties:
- contactId
string
The id of the contact.
- emailAddress
- (optional)
string
The email address of the contact.
- type
- (optional)
string
The type of email address. WORK, HOME etc
- favorite
- (optional)
boolean
Is this email address favorite for user.
- obsolete
- (optional)
boolean
Is this email address obsolete. If true it should not show up in autocomplete when composing email
#RemovePropertyDetails
Object passed to the removeProperty() function.
Properties:
- propertyName
ContactPropertyName
The property name to remove (postal address, phone).
- contactId
string
The id of the contact.
- propertyId
string
The email address of the contact.
#UpdatePropertyDetails
Object passed to the updateProperty() function.
Properties:
- propertyName
ContactPropertyName
The property name to be updated (address, phone).
- contactId
string
The id of the contact.
- propertyId
string
The id of the property to be updated.
- propertyValue
string
The email address or phonenumber value to update for the given contact.
- type
string
The type of address, phone. WORK, HOME etc
#CreateManyContactsResults
Object stating how many contacts were created successfully and how many creations resulted in errors
Properties:
- created_count
- (optional)
integer
Number of contacts created
- failed_count
- (optional)
integer
Number of failed contacts creation attempts
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onContactCreated
Fired when a contact is created.
Parameters:
- createdContact
Contact
The created contact
#onContactRemoved
Fired when contact is deleted.
Parameters:
- removedContact
Contact
The deleted contact
#onContactChanged
Fired when contact is updated.
Parameters:
- changedContact
Contact
The changed contact
Methods
#getAll
Retrieves all contacts
#getAllEmailAddresses
Retrieves all email addresses for all contacts
#create
Creates a contact.
Parameters:
- contact
CreateUpdateDetails
⚠ NO DESCRIPTION PROVIDED
#createMany
Creates / imports multiple contacts.
Parameters:
- contactList
⚠ NO DESCRIPTION PROVIDED
Array
of:- CreateUpdateDetailsMinimum items: 1
#update
Updates the properties of a contact. Specify only the properties that you want to change. Unspecified properties will be left unchanged.
Parameters:
- id
string
The contact id to be updated
- changes
CreateUpdateDetails
⚠ NO DESCRIPTION PROVIDED
#delete
Deletes a contact.
Parameters:
- id
string
⚠ NO DESCRIPTION PROVIDED
#addPropertyItem
Adds a property to a contact.
Parameters:
- propertyToAdd
AddPropertyDetails
⚠ NO DESCRIPTION PROVIDED
#addEmailAddress
Adds an email address to a contact.
Parameters:
- emailToAdd
EmailAddressAddUpdate
Object holding the fields for the email address to create
#updateEmailAddress
Updates an email address for a contact.
Parameters:
- emailAddressId
string
The id of email address to update
- emailToUpdate
EmailAddressAddUpdate
Object holding the fields for the email address to update
#removeEmailAddress
Removes an email address for a contact.
Parameters:
- removeEmail
object
An object specifying properties to remove email address.
Object Properties:
- contactId
string
The contact id of which email address to remove.
- emailAddressId
string
The id of email address to remove
#updatePropertyItem
Updates a property for a contact.
Parameters:
- propertyToUpdate
UpdatePropertyDetails
⚠ NO DESCRIPTION PROVIDED
#removePropertyItem
Removes a property from a contact.
Parameters:
- propertyToRemove
RemovePropertyDetails
⚠ NO DESCRIPTION PROVIDED
#readThunderbirdContacts
Read thunderbird contacts from db files.
Parameters:
- path
string
Profile Path to thunderbird directory, containing: abook.sqlite and history.sqlite files.
contextMenu
Types
#Rect
Position and size of item that opens menu
Properties:
- x
number
Left position of item that opens menu, screen coordinates.
- y
number
Top position of item that opens menu, screen coordinates.
- width
number
Width of item that opens menu.
- height
number
Height of item that opens menu.
#Origin
ENUM
Menu location with respect to rectangle. With pointer the size and height is ignored.
- pointer
- topLeft
- bottomLeft
- topRight
- bottomRight
#ItemType
ENUM
What kind of item.
- command
- checkbox
- radio
- folder
#Icons
- Icons
Icons encoded as base64.
Array
of:- string
#ContainerMode
ENUM
Defines container layouts.
- inline
- folder
#ContainerContent
ENUM
Defines functionality to set up on the C++ side. One or more menu items may be created.
- extensions
- imageinprofile
- linkinprofile
- linktohighlight
- notes
- pwa
- linkinpwa
- sendlinktodevices
- sendpagetodevices
- sendimagetodevices
- spellcheck
- spellcheckoptions
- speech
#Item
One menu item.
Properties:
- name
string
Text in item.
- id
integer
The unique id of item.
- type
ItemType
The kind of menu element
- action
- (optional)
string
Action to execute. This is used for actions that needs to execute in C++. The value must be well defined
- radiogroup
- (optional)
integer
The radiobutton group this item belongs to.
- checked
- (optional)
boolean
true if the checkbox is checked, otherwise false. Only applies for type='checkbox'.
- enabled
- (optional)
boolean
true if the item is enabled.
- url
- (optional)
string
Url that can be used to determine a corresponding icon.
- shortcut
- (optional)
string
A shortcut displayed next to the name. No binding is added.
- showshortcut
- (optional)
boolean
Controls if a shortcut shall be shown. Needed for elements where shortcut is set up in C++ code
- persistent
- (optional)
boolean
If true the menu item will remain open after menu item is clicked with mouse.
- icons
- (optional)
Icons
Icon in PNG format encoded as base64.
#Container
Container to expand
Properties:
- id
integer
The unique id of item.
- name
string
Text in item when mode is folder
- content
ContainerContent
Specifies an element to expand in C++ to one or more elements. How it is expanded is implementation specific.
- mode
ContainerMode
Container content format
- icons
- (optional)
Icons
Icon in PNG format encoded as base64.
#Separator
One separator
Properties:
- label
- (optional)
string
Text in item.
#Element
One element in menu. All optional, but one and only one of 'item', 'separator' or 'container' should be set. 'children' is only considered when 'item' is set.
Properties:
- item
- (optional)
Item
⚠ NO DESCRIPTION PROVIDED
- container
- (optional)
Container
⚠ NO DESCRIPTION PROVIDED
- separator
- (optional)
Separator
⚠ NO DESCRIPTION PROVIDED
- children
- (optional)
Child menu items.
Array
of:- Element
#UpdateItem
⚠ NO DESCRIPTION PROVIDED
Properties:
- id
integer
The unique id of item.
- name
- (optional)
string
Text in item.
- checked
- (optional)
boolean
true if checkbox is checked, otherwise false. Only applies for type='checkbox'.
#DocumentType
ENUM
The kind of document menu.
- page
- link
- image
- selection
#TextfieldType
ENUM
Defines the type of textfield
- addressfield
- searchfield
- regular
- document
#DocumentSupport
⚠ NO DESCRIPTION PROVIDED
Properties:
- copy
boolean
For elements outside editor
- audio
boolean
⚠ NO DESCRIPTION PROVIDED
- canvas
boolean
⚠ NO DESCRIPTION PROVIDED
- editoptions
boolean
⚠ NO DESCRIPTION PROVIDED
- emoji
boolean
⚠ NO DESCRIPTION PROVIDED
- extensions
boolean
⚠ NO DESCRIPTION PROVIDED
- highlight
boolean
⚠ NO DESCRIPTION PROVIDED
- pictureinpicture
boolean
⚠ NO DESCRIPTION PROVIDED
- password
boolean
⚠ NO DESCRIPTION PROVIDED
- passwordgeneration
boolean
⚠ NO DESCRIPTION PROVIDED
- passwordshowall
boolean
⚠ NO DESCRIPTION PROVIDED
- paste
boolean
⚠ NO DESCRIPTION PROVIDED
- plugin
boolean
⚠ NO DESCRIPTION PROVIDED
- qrcode
boolean
⚠ NO DESCRIPTION PROVIDED
- sendtodevices
boolean
⚠ NO DESCRIPTION PROVIDED
- video
boolean
⚠ NO DESCRIPTION PROVIDED
#DocumentArea
⚠ NO DESCRIPTION PROVIDED
Properties:
- devtools
boolean
⚠ NO DESCRIPTION PROVIDED
- editor
boolean
⚠ NO DESCRIPTION PROVIDED
- image
boolean
⚠ NO DESCRIPTION PROVIDED
- frame
boolean
⚠ NO DESCRIPTION PROVIDED
- webpanel
boolean
⚠ NO DESCRIPTION PROVIDED
#DocumentParams
Properties of the document that requests a menu
Properties:
- linkurl
string
⚠ NO DESCRIPTION PROVIDED
- linktitle
string
⚠ NO DESCRIPTION PROVIDED
- pageurl
string
⚠ NO DESCRIPTION PROVIDED
- pagetitle
string
⚠ NO DESCRIPTION PROVIDED
- srcurl
string
⚠ NO DESCRIPTION PROVIDED
- selection
string
⚠ NO DESCRIPTION PROVIDED
- printableselection
string
⚠ NO DESCRIPTION PROVIDED
- selectionurl
string
⚠ NO DESCRIPTION PROVIDED
- keywordurl
string
⚠ NO DESCRIPTION PROVIDED
- isdevtools
boolean
⚠ NO DESCRIPTION PROVIDED
- iseditable
boolean
⚠ NO DESCRIPTION PROVIDED
- isimage
boolean
⚠ NO DESCRIPTION PROVIDED
- isframe
boolean
⚠ NO DESCRIPTION PROVIDED
- ismailcontent
boolean
⚠ NO DESCRIPTION PROVIDED
- iswebpanel
boolean
⚠ NO DESCRIPTION PROVIDED
- ismailto
boolean
⚠ NO DESCRIPTION PROVIDED
- iswebpagewidget
boolean
⚠ NO DESCRIPTION PROVIDED
- isreader
boolean
⚠ NO DESCRIPTION PROVIDED
- isrichtexteditor
boolean
⚠ NO DESCRIPTION PROVIDED
- support
DocumentSupport
⚠ NO DESCRIPTION PROVIDED
- textfield
- (optional)
TextfieldType
⚠ NO DESCRIPTION PROVIDED
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onDocumentMenu
Fires when a document menu is requested.
Parameters:
- window
integer
id of window where command occurred.
- document
integer
id of the document requesting this menu.
- state
DocumentParams
Document data for the given type of menu.
Methods
#show
Shows a new context menu.
Parameters:
- properties
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- children
⚠ NO DESCRIPTION PROVIDED
Array
of:- Element
- documentId
integer
⚠ NO DESCRIPTION PROVIDED
- icons
Icons
Default and folder icons.
- forceViews
boolean
⚠ NO DESCRIPTION PROVIDED
- origin
Origin
⚠ NO DESCRIPTION PROVIDED
- rect
Rect
⚠ NO DESCRIPTION PROVIDED
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
#update
Updates as context menu entry.
Parameters:
- properties
Updates for a persistent menu.
Array
of:- UpdateItem
calendar
Types
#AccountType
ENUM
The account type. Maps to int in db: 0: Local. 1: Vivaldi.net calendar. 2: Google Calendar. 3: CalDAV. 4: Read only iCal.
- local
- vivaldi
- google
- caldav
- ical
- fastmail
#RecurrenceException
A object describing how an instance of event recurrence is changed.
Properties:
- exception_id
- (optional)
string
The id of the exception.
- cancelled
- (optional)
boolean
If a certain instance of recurring event is cancelled.
- date
number
The date of a recurring event that an exception should be added to. In milliseconds since the epoch.
- exception_event_id
- (optional)
string
The id of the event that serves as exception to the event in a recurrence series.
- parent_event_id
- (optional)
string
The id of the event that is parent to all the others events in the recurrence series.
#CreateNotificationRow
An object describing notification to be created during event creation.
Properties:
- name
string
Name of the notification.
- when
number
When this notification should fire. In milliseconds since the epoch.
#CreateInviteRow
An object describing invite to be created during event creation.
Properties:
- name
string
Name of the invite.
- address
string
The invite address.
- partstat
string
The participation status for the event invite.
#SupportedCalendarComponents
An object describing supported calendar component set.
Properties:
- vevent
boolean
Does the calendar support vevent.
- vtodo
boolean
Does the calendar support vtodo.
- vjournal
boolean
Does the calendar support vjournal.
#Notification
An object describing notification.
Properties:
- id
string
The unique identifier for the notification. IDs are unique within the current profile, and they remain valid even after the browser is restarted.
- event_id
- (optional)
string
The event id this notification applies to.
- name
string
Name of the notification.
- description
- (optional)
string
The description of the notification.
- when
number
When this notification should fire. In milliseconds since the epoch.
- period
- (optional)
number
If not null, when the notification will fire. In milliseconds since the epoch.
- delay
- (optional)
integer
The notification will fire after delay minutes from now. Can not be used together with when.
#Invite
Object describing event invite.
Properties:
- id
string
The id of the invite.
- event_id
string
The id of the event that this invite applies to.
- name
- (optional)
string
The name of the contact to send the invite to.
- address
string
The address of the contact to send the invite to.
- sent
- (optional)
boolean
States if the event invite has been sent or not.
- partstat
- (optional)
string
The participation status for the event invite.
#CalendarEvent
A calendar event. An event belongs to a single Calendar.
Properties:
- id
string
The unique identifier for the event. IDs are unique within the current profile, and they remain valid even after the browser is restarted.
- calendarId
string
The calendar id of the event.
- alarmId
- (optional)
string
The alarm id of the event.
- title
string
Title of event.
- description
- (optional)
string
The event description.
- start
- (optional)
number
When this event starts, in milliseconds since the epoch.
- end
- (optional)
number
When this event ends, in milliseconds since the epoch.
- allDay
- (optional)
boolean
All day event.
- is_recurring
- (optional)
boolean
Is this a recurring event.
- location
- (optional)
string
The location of the event.
- url
- (optional)
string
The url of the event.
- etag
- (optional)
string
The CalDAV etag id of the event.
- href
- (optional)
string
The CalDAV href id of the event.
- uid
- (optional)
string
The event uid.
- eventTypeId
- (optional)
string
The event type id.
- task
- (optional)
boolean
Whether this event is a task. Tasks can be marked as completed.
- complete
- (optional)
boolean
If this event is a task type you can mark it as complete.
- trash
- (optional)
boolean
Is this event trashed.
- trash_time
- (optional)
number
When this event was trashed, in milliseconds since the epoch.
- sequence
- (optional)
integer
iCal sequence field according to: https://tools.ietf.org/html/rfc5545#section-3.8.7.4.
- ical
- (optional)
string
The original ical message.
- rrule
- (optional)
string
The recurring rule. In iCalendar format.
- recurrenceExceptions
- (optional)
List of recurrence exceptions. Either cancelled instances or moved.
Array
of:- RecurrenceException
- notifications
- (optional)
List of notifications.
Array
of:- Notification
- organizer
- (optional)
string
The organizer of the event.
- invites
- (optional)
List of invites.
Array
of:- Invite
- timezone
- (optional)
string
The timezone of the event.
- priority
- (optional)
integer
Priority of event or task. Must be in the range [0..9]. 0 is equivalent of no priority.
- status
- (optional)
string
The overall status or confirmation for the event or todo.
- percentage_complete
- (optional)
integer
The percent completion of a todo to the organizer.
- categories
- (optional)
string
Event or todo categories. A comma separated list.
- component_class
- (optional)
string
Access classification for a event or todo.
- attachment
- (optional)
string
Document object for a event or todo.
- completed
- (optional)
number
The date and time that a todo was actually completed.
- syncPending
- (optional)
boolean
Does this event have any pending sync changes.
- deletePending
- (optional)
boolean
Should the event be deleted locally once server deletion is completed.
- end_recurring
- (optional)
number
When this event ends re-occurring. In milliseconds since the epoch.
#CreateDetails
Object passed to the create() function.
Properties:
- title
string
⚠ NO DESCRIPTION PROVIDED
- description
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- start
- (optional)
number
When this event shoud starts, in milliseconds since the epoch.
- end
- (optional)
number
When this event should ends, in milliseconds since the epoch.
- allDay
- (optional)
boolean
Is this a all day event.
- is_recurring
- (optional)
boolean
Is this a recurring event.
- location
- (optional)
string
The location of the event.
- url
- (optional)
string
The url of the event.
- calendarId
string
The calendar id of the event.
- etag
- (optional)
string
The CalDAV etag id of the event.
- href
- (optional)
string
The CalDAV href id of the event.
- uid
- (optional)
string
The event uid.
- task
- (optional)
boolean
Whether this event is a task. Tasks can be marked as completed.
- complete
- (optional)
boolean
If this event is a task type you can mark it as complete.
- sequence
- (optional)
integer
iCal sequence field according to: https://tools.ietf.org/html/rfc5545#section-3.8.7.4.
- ical
- (optional)
string
The original ical message.
- rrule
- (optional)
string
The recurring rule. In iCalendar format.
- eventTypeId
- (optional)
string
The event type id of the event.
- organizer
- (optional)
string
The organizer of the event.
- recurrenceExceptions
- (optional)
List of recurrence exceptions.
Array
of:- RecurrenceException
- notifications
- (optional)
List of notifications to create.
Array
of:- CreateNotificationRow
- invites
- (optional)
List of invites to create.
Array
of:- CreateInviteRow
- timezone
- (optional)
string
The timezone of the event to create.
- is_template
boolean
Is the event a template or not.
- priority
- (optional)
integer
Priority of event or task. Must be in the range [0..9]. 0 is equivalent of no priority.
- status
- (optional)
string
The overall status or confirmation for the event or todo.
- percentage_complete
- (optional)
integer
The percent completion of a todo to the organizer.
- categories
- (optional)
string
Event or todo categories. A comma separated list.
- component_class
- (optional)
string
Access classification for a event or todo.
- attachment
- (optional)
string
Document object for a event or todo.
- completed
- (optional)
number
The date and time that a todo was actually completed.
- syncPending
- (optional)
boolean
Does this event have any pending sync changes.
- deletePending
- (optional)
boolean
Should the event be deleted locally once server deletion is completed.
- end_recurring
- (optional)
number
When this event ends re-occurring. In milliseconds since the epoch.
#EventType
A event type.
Properties:
- id
string
The unique identifier for the event type. IDs are unique within the current profile, and they remain valid even after the browser is restarted.
- name
string
The event type name.
- color
- (optional)
string
The color of the event type.
- iconindex
- (optional)
integer
The event type icon index.
#CreateEventType
Object passed to the typeCreate() function.
Properties:
- name
string
⚠ NO DESCRIPTION PROVIDED
- color
- (optional)
string
The color of the event type.
- iconindex
- (optional)
integer
The event type iconindex.
#CreateEventsResults
Object stating how many events were created successfully and how many creations resulted in errors.
Properties:
- created_count
integer
Number of events created.
- failed_count
integer
Number of failed event creation attempts.
#CreateCalendarDetails
Object passed to the createCalendar() function.
Properties:
- accountId
string
The id of the account the calendar belongs to.
- name
string
The name of the calendar to be created.
- description
- (optional)
string
The description of the calendar to be created.
- orderindex
- (optional)
integer
The UI order of the calendar.
- iconindex
- (optional)
integer
The iconindex of the calendar.
- color
- (optional)
string
The color of the calendar.
- hidden
- (optional)
boolean
If this calendar should be visible.
- active
- (optional)
boolean
If this CalDAV calendar should be polled.
- lastChecked
- (optional)
number
When this calendar last checked for updates. In milliseconds since the epoch.
- timezone
- (optional)
string
The timezone of the calendar.
- ctag
- (optional)
string
The ctag field of the CalDAV calendar.
- supportedCalendarComponent
SupportedCalendarComponents
⚠ NO DESCRIPTION PROVIDED
#Calendar
Calendar that owns events.
Properties:
- id
string
The unique identifier for the calendar. IDs are unique within the current profile, and they remain valid even after the browser is restarted.
- accountId
string
The id of the account the calendar belongs to.
- name
string
The name of the calendar.
- description
- (optional)
string
The calendar description.
- orderindex
- (optional)
integer
The UI order of the calendar.
- color
- (optional)
string
The UI color of the calendar.
- hidden
- (optional)
boolean
States if the calendar is hidden in the UI.
- active
- (optional)
boolean
States if a CalDAV calendar should be polled.
- iconindex
- (optional)
integer
Icon index of the calendar.
- ctag
- (optional)
string
The ctag field of the CalDAV calendar.
- lastChecked
- (optional)
number
When this calendar last checked for updates. In milliseconds since the epoch.
- timezone
- (optional)
string
The timezone of the calendar.
- supportedCalendarComponent
SupportedCalendarComponents
⚠ NO DESCRIPTION PROVIDED
#updateCalendar
Object to update calendar.
Properties:
- accountId
- (optional)
string
The id of the account the calendar belongs to.
- name
- (optional)
string
The name of the calendar.
- description
- (optional)
string
The calendar description.
- orderindex
- (optional)
integer
The UI order of the calendar.
- color
- (optional)
string
The UI color of the calendar.
- hidden
- (optional)
boolean
States if the calendar is hidden in the UI.
- active
- (optional)
boolean
States if a CalDAV calendar should be polled.
- iconindex
- (optional)
integer
Icon index of the calendar.
- ctag
- (optional)
string
The ctag field of the CalDAV calendar.
- lastChecked
- (optional)
number
When this calendar last checked for updates. In milliseconds since the epoch.
- timezone
- (optional)
string
The timezone of the calendar.
- supportedCalendarComponent
- (optional)
SupportedCalendarComponents
⚠ NO DESCRIPTION PROVIDED
#updatedAccount
Object to update calendar.
Properties:
- name
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- username
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- url
- (optional)
string
The updated url of the account.
- account_type
- (optional)
AccountType
The type of account.
- interval
- (optional)
integer
The interval how often this account should poll. In seconds.
#createdAccount
Object to create calendar.
Properties:
- name
string
⚠ NO DESCRIPTION PROVIDED
- username
string
⚠ NO DESCRIPTION PROVIDED
- url
string
The url of the account to create.
- account_type
- (optional)
AccountType
The type of account.
- interval
- (optional)
integer
The interval how often this account should poll. In seconds.
#Account
An object describing calendar account.
Properties:
- id
string
The unique identifier for the account. IDs are unique within the current profile, and they remain valid even after the browser is restarted.
- name
string
Name of the account.
- username
string
The username of the account.
- url
string
The base url of the account.
- account_type
- (optional)
AccountType
The type of account.
- interval
- (optional)
integer
The interval how often this account should poll. In seconds.
#EventTemplate
A event template object.
Properties:
- id
string
The unique identifier for the event template.
- name
string
The name of the event template.
- ical
string
The ical of the event template.
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onIcsFileOpened
Called when the user opens a downloaded ics file
Parameters:
- filePath
string
⚠ NO DESCRIPTION PROVIDED
#onWebcalUrlOpened
Called when the user opens a webcal link
Parameters:
- url
string
⚠ NO DESCRIPTION PROVIDED
#onMailtoOpened
Called when the user opens a mailto link
Parameters:
- mailto
string
⚠ NO DESCRIPTION PROVIDED
#onEventCreated
Fired when a event is created.
Parameters:
- createdEvent
CalendarEvent
The created event.
#onNotificationChanged
Fired when notification is created, updated or deleted.
Parameters:
- changedNotification
Notification
The created, changed or updated notification.
#onCalendarDataChanged
Fired when the calendar datamodel should be reloaded.
Methods
#getAllEvents
Retrieves all events in calendar.
#getAllEventTypes
Retrieves all event types.
#getAllNotifications
Retrieves all notifications.
#eventCreate
Creates a event in the specified calendar.
Parameters:
- event
CreateDetails
⚠ NO DESCRIPTION PROVIDED
#eventsCreate
Creates multiple events.
Parameters:
- eventsList
⚠ NO DESCRIPTION PROVIDED
Array
of:- CreateDetailsMinimum items: 1
#deleteEvent
Deletes an event.
Parameters:
- id
string
⚠ NO DESCRIPTION PROVIDED
#deleteEventException
Deletes an recurring event exception.
Parameters:
- exception_id
string
The id of the exception to delete.
#updateRecurrenceException
Updates the recurrence exception of an event. Specify only the properties that you want to change. Unspecified properties will be left unchanged.
Parameters:
- recurrenceId
string
⚠ NO DESCRIPTION PROVIDED
- changes
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- cancelled
- (optional)
boolean
If a certain instance of recurring event is cancelled.
- date
- (optional)
number
The date of a recurring event that an exception should be added to. In milliseconds since the epoch.
- exception_event_id
- (optional)
string
The id of the event that serves as exception to the event in a recurrence series.
- parent_event_id
- (optional)
string
The id of the event that is parent to all the others events in the recurrence series.
#updateEvent
Updates the properties of an event. Specify only the properties that you want to change. Unspecified properties will be left unchanged.
Parameters:
- id
string
⚠ NO DESCRIPTION PROVIDED
- changes
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- calendarId
- (optional)
string
The updated calendar id of event.
- alarmId
- (optional)
string
The updated alarm id of event.
- title
- (optional)
string
The updated title of event.
- description
- (optional)
string
The updated description of event.
- start
- (optional)
number
When this event shoud starts, in milliseconds since the epoch.
- end
- (optional)
number
Updated time when this event should end, in milliseconds since the epoch.
- allDay
- (optional)
boolean
Is this all day event.
- location
- (optional)
string
The location of the event.
- is_recurring
- (optional)
boolean
Is this a recurring event.
- url
- (optional)
string
The url of the event.
- etag
- (optional)
string
The CalDAV.etag of the event.
- href
- (optional)
string
The href id of the event.
- uid
- (optional)
string
The event uid.
- eventTypeId
- (optional)
string
The event type id.
- task
- (optional)
boolean
Whether this event is a task. Tasks can be marked as completed.
- complete
- (optional)
boolean
If this event is a task type you can mark it as complete.
- trash
- (optional)
boolean
Is this event trashed.
- sequence
- (optional)
integer
iCal sequence field according to: https://tools.ietf.org/html/rfc5545#section-3.8.7.4.
- ical
- (optional)
string
The original ical message.
- rrule
- (optional)
string
The recurring rule. In iCalendar format.
- organizer
- (optional)
string
The organizer of the event.
- timezone
- (optional)
string
The timezone of the event.
- priority
- (optional)
integer
Priority of event or task. Must be in the range [0..9]. 0 is equivalent of no priority.
- status
- (optional)
string
The overall status or confirmation for the event or todo.
- percentage_complete
- (optional)
integer
The percent completion of a todo to the Organizer.
- categories
- (optional)
string
Event or todo categories. A comma separated list.
- component_class
- (optional)
string
Access classification for a event or todo.
- attachment
- (optional)
string
Access classification for a event or todo.
- completed
- (optional)
number
The date and time that a todo was actually completed.
- syncPending
- (optional)
boolean
Does this event have any pending sync changes.
- deletePending
- (optional)
boolean
Should the event be deleted locally once server deletion is completed.
- end_recurring
- (optional)
number
When this event ends re-occurring. In milliseconds since the epoch.
#create
Creates a calendar.
Parameters:
- calendar
CreateCalendarDetails
⚠ NO DESCRIPTION PROVIDED
#getAll
Returns all calendars.
#delete
Deletes a calendar, with all its events and event exceptions.
Parameters:
- id
string
The id of the calendar to be deleted.
#update
Updates the properties of an calendar. Specify only the properties that you want to change. Unspecified properties will be left unchanged.
Parameters:
- id
string
⚠ NO DESCRIPTION PROVIDED
- changes
updateCalendar
⚠ NO DESCRIPTION PROVIDED
#eventTypeCreate
Creates a event type.
Parameters:
- event_type
CreateEventType
⚠ NO DESCRIPTION PROVIDED
#eventTypeUpdate
Updates the properties of an event type. Specify only the properties that you want to change. Unspecified properties will be left unchanged.
Parameters:
- id
string
⚠ NO DESCRIPTION PROVIDED
- changes
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- name
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- color
- (optional)
string
The updated color of the event type.
- iconindex
- (optional)
integer
The iconindex of the event type.
#deleteEventType
Deletes an event type.
Parameters:
- id
string
⚠ NO DESCRIPTION PROVIDED
#createEventException
Creates an exception to event instance in recurring series.
Parameters:
- parent_event_id
string
The parent id of the event in the recurrence series.
- exception_event_id
- (optional)
string
The id of the event that serves as exception to the event in a recurrence series.
- cancelled
boolean
Cancel this instance of recurring event.
- date
- (optional)
number
When the exception should happen. In milliseconds since the epoch.
#createNotification
Creates a notification.
Parameters:
- createNotification
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- event_id
- (optional)
string
The event id of the event to create the notification for.
- name
string
The name of the notification.
- description
- (optional)
string
The description of the notification.
- when
number
When the notification should fire. In milliseconds since the epoch.
- period
- (optional)
number
If not null, when the notification will fire. In milliseconds since the epoch.
- delay
- (optional)
integer
The notification will fire after delay minutes from now. Can not be used together with when.
#updateNotification
Updates the properties of a notification. Specify only the properties that you want to change. Unspecified properties will be left unchanged.
Parameters:
- id
string
The id of the notification to update.
- changes
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- name
- (optional)
string
The name of the notification.
- description
- (optional)
string
The description of the notification.
- when
- (optional)
number
When the notification should fire. In milliseconds since the epoch.
- period
- (optional)
number
If not null, when the notification will fire. In milliseconds since the epoch.
- delay
- (optional)
integer
The notification will fire after delay minutes from now. Can not be used together with when.
#deleteNotification
Deletes a notification.
Parameters:
- id
string
⚠ NO DESCRIPTION PROVIDED
#createInvite
Creates an invite for event.
Parameters:
- createInvite
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- event_id
string
The event id of the event to create the invite for.
- address
string
The email address to send the invite to.
- name
string
The name of the persion to send the invite to.
- partstat
- (optional)
string
The participation status for the event invite
- sent
- (optional)
boolean
Has the invite been sent.
#deleteInvite
Deletes an invite.
Parameters:
- id
string
The invite id to delete.
#updateInvite
Updates an invite for event.
Parameters:
- updateInvite
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- id
string
The id of the invite to update.
- address
- (optional)
string
The email address to send the invite to.
- name
- (optional)
string
The name of the persion to send the invite to.
- partstat
- (optional)
string
The participation status for the event invite.
- sent
- (optional)
boolean
Has the invite been sent.
#getAllAccounts
Retrieves all calendar accounts.
#createAccount
Creates an account.
Parameters:
- toCreate
createdAccount
⚠ NO DESCRIPTION PROVIDED
#updateAccount
Updates the properties of an account. Specify only the properties that you want to change. Unspecified properties will be left unchanged.
Parameters:
- id
string
⚠ NO DESCRIPTION PROVIDED
- changes
updatedAccount
⚠ NO DESCRIPTION PROVIDED
#deleteAccount
Deletes an account and its calendars, events, recurring_exceptions, notifications etc
Parameters:
- id
string
The account id to be deleted
#createEventTemplate
Creates an event template.
Parameters:
- name
string
The event template name.
- ical
string
The event template ical.
#getAllEventTemplates
Retrieves all event templates.
#updateEventTemplate
Updates the properties of an event template. Specify only the properties that you want to change. Unspecified properties will be left unchanged.
Parameters:
- id
string
The id of the event template to update.
- changes
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- name
- (optional)
string
The updated name of the event template.
- ical
- (optional)
string
The updated ical of the event template.
#getParentExceptionId
Returns the parent event id of a exception event id.
Parameters:
- exception_event_id
string
The id of the event exception to return the parent event id for.
#deleteEventTemplate
Deletes an event template.
Parameters:
- id
string
The id of the event template to delete.
mousegestures
pageActions
Types
#ScriptOverride
ENUM
Whether a script should be always enabled or disabled.
- no_override
- enabled
- disabled
#OverridenScript
Used to report that a script is always enabled or disabled
Properties:
- script
string
⚠ NO DESCRIPTION PROVIDED
- override
ScriptOverride
⚠ NO DESCRIPTION PROVIDED
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onScriptsChanged
Fired when new scripts have been found in a page action directory or when some scripts were modified or deleted
#onOverridesChanged
Fired when something (usually a call to setScriptOverrideForTab) caused script overrides to change
Parameters:
- tab_id
integer
⚠ NO DESCRIPTION PROVIDED
Methods
#getScripts
Returns the full path to all known page action scripts.
#setScriptOverrideForTab
Permanently enables or disables a script for a given tab, or cancels the override
Parameters:
- script
string
⚠ NO DESCRIPTION PROVIDED
- tab_id
integer
⚠ NO DESCRIPTION PROVIDED
- override
ScriptOverride
⚠ NO DESCRIPTION PROVIDED
#getScriptOverridesForTab
Get which scripts have been permanently enabled or disabled for a given tab
Parameters:
- tab_id
integer
⚠ NO DESCRIPTION PROVIDED
settings
Types
#ContentSettingsTypeEnum
ENUM
ContentSettingsType, see /components/content_settings/core/common/content_settings_types.h
- plugins
- popups
- geolocation
- notifications
#ContentSettingEnum
ENUM
ContentSetting, see /components/content_settings/core/common/content_settings_types.h
- allow
- block
- ask
- session_only
- num_settings
#ContentSettingItem
A full content setting description.
Properties:
- primary_pattern
string
URL pattern to match for the setting.
- secondary_pattern
string
This is only used for certain types. See https://developer.chrome.com/extensions/contentSettings#patterns
- type
ContentSettingsTypeEnum
⚠ NO DESCRIPTION PROVIDED
- setting
ContentSettingEnum
⚠ NO DESCRIPTION PROVIDED
Methods
#setContentSetting
Set a contentSetting outside the extension space.
Parameters:
- settingsItem
ContentSettingItem
⚠ NO DESCRIPTION PROVIDED
tabsPrivate
Types
#TabAlertState
ENUM
The active media type.
- recording
- capturing
- playing
- muting
- bluetooth
- usb
- pip
- desktop_capturing
- vr_presenting_in_headset
- serial_connected
- bluetooth_scan
- hid_connected
- audio_recording
- video_recording
#TranslateStep
ENUM
Denotes which state the page is in with respect to translate.
- idle
- before_translate
- translating
- after_translate
- translate_error
#TranslateError
ENUM
Signals translation errors.
- no_error
- network
- init_error
- unknown_language
- unsupported_language
- identical_languages
- translation_error
- translation_timeout
- unexpected_script_error
- bad_origin
- script_load_error
#UpdateTabInfo
Object passed to the update and returned in the get function function.
Properties:
- showImages
- (optional)
boolean
Show images for all pages loaded in this tab. Default is true.
- loadFromCacheOnly
- (optional)
boolean
Only load the page from cache. Default is false.
- mimeType
- (optional)
string
The current documents mimetype.
- muteTab
- (optional)
boolean
If the tab should be quiet.
#DragData
Provides custom drag data.
Properties:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- mimeType
string
The mime type to use for the custom data.
- customData
string
The custom data.
- url
string
The url for the data. Needed for the html5 drag and drop engine. Not set in the onDropEnd event.
- title
string
The title for the data. Needed for the html5 drag and drop engine. Not set in the onDropEnd event.
- imageData
- (optional)
binary
The raw image data in RGBA format for the image to use during drag drop instead of a tab capture.
- posX
- (optional)
number
X offset inside the given app window in the UI coordinates.
- posY
- (optional)
number
Y offset inside the given app window in the UI coordinates.
- width
number
Width of the capture in the UI coordinates.
- height
number
Height of the capture in the UI coordinates.
- cursorX
integer
X offset into the image for the cursor during drag.
- cursorY
integer
Y offset into the image for the cursor during drag.
- isFromTouch
- (optional)
boolean
True if the drag was initiated from touch. Default is false.
#NavigationRect
Rect struct for spatial navigation.
Properties:
- left
integer
left
- top
integer
top
- width
integer
width
- height
integer
height
- right
integer
right
- bottom
integer
bottom
- href
string
Url of focused element in case it's a link.
#NavigationDirection
ENUM
Which direction to move the current spatnav rect.
- left
- right
- up
- down
#LanguageDetectionDetails
Details the language detection for the current page. Corresponds to LanguageDetectionDetails in C++.
Properties:
- url
string
The url of the page detected was done on.
- contentLanguage
string
The language detected by the content (Content-Language).
- cldLanguage
string
The language detected by CLD (Chromium's Compact Language Detector library).
- isCldReliable
boolean
true if the CLD detection is reliable, otherwise false.
- hasNoTranslate
boolean
Whether the notranslate is specified in head tag as a meta; or
- htmlRootLanguage
string
The language written in the lang attribute of the html element.
- adoptedLanguage
string
The adopted language, usually a authoritive decision on the different language tags in a document.
#CloseSpatnavParams
Reports layout change and element null check
Properties:
- layout_changed
boolean
True if layout changed
- current_element_valid
boolean
True is current element is not null. Currently used to see if previous escape closed a menu that made our current element disappear.
#TabPerformanceData
Memory information about a tab.
Properties:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- memoryUsage
integer
Memory usage of tab in bytes.
#SendTabToSelfAction
ENUM
⚠ NO DESCRIPTION PROVIDED
- delete
- dismiss
#SendTabToSelfTargetType
ENUM
⚠ NO DESCRIPTION PROVIDED
- phone
- tablet
- desktop
#SendTabToSelfTarget
Information of a target device (another Vivaldi instance).
Properties:
- guid
string
Unique identifier.
- name
string
Name of the device
- type
SendTabToSelfTargetType
The device type. Can be used to pick a proper icon.
#SendTabToSelfTargets
Information of all target devices
Properties:
- valid
boolean
Tells if sub system is ready or not.
- entries
⚠ NO DESCRIPTION PROVIDED
Array
of:- SendTabToSelfTarget
#SendTabToSelfEntry
Url received from another Vivaldi instance.
Properties:
- guid
string
Unique identifier.
- url
string
The url.
- title
string
The url's title.
- deviceName
string
Sharing device name.
- sharedTime
number
Sharing time.
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onSendTabToSelfAdded
Fired when one or more urls are received from a remote instance.
Parameters:
- entries
⚠ NO DESCRIPTION PROVIDED
Array
of:- SendTabToSelfEntry
#onSendTabToSelfDismissed
Fired when one or more entries not to be used anymore.
Parameters:
- guids
⚠ NO DESCRIPTION PROVIDED
Array
of:- string
#onMediaStateChanged
Fired when the media state changes on the tab.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- tabState
All the active media states for this tab.
Array
of:- TabAlertState
#onThemeColorChanged
Fired when a meta theme-color has a value from the web page.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- rgb
string
Fired when the theme-color in the meta header field has changed. Format is #rrggbb and provided in css hex.
#onTabUpdated
Fires when a |WebContent| is changed in some way.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- tabInfo
UpdateTabInfo
⚠ NO DESCRIPTION PROVIDED
#onDragEnd
Fires when tab dragging ends.
Parameters:
- dragAborted
boolean
This is an aborted drag (using ESC or similar).
- dropOutsideWindow
boolean
This is a valid drop outside any app window.
- posX
integer
X position of the drop in screen coordinates.
- posY
integer
Y position of the drop in screen coordinates.
#onPermissionAccessed
Fires when a |permission| is accessed.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- permission
string
⚠ NO DESCRIPTION PROVIDED
- origin
string
⚠ NO DESCRIPTION PROVIDED
- blocked
string
Current permission setting. 'allow', 'block', 'ask' or 'default'
#onKeyboardChanged
Fires for all keyboard changes that have not been consumed by the browser
Parameters:
- windowId
integer
Id of the browser window this keyboard event originates from.
- down
boolean
True when pressed, false when released
- modifiers
integer
Modifier state when change occured
- windowsKeyCode
integer
Value of key that changed
- afterGesture
boolean
True when the keyboard event completed a mouse or wheel gesture
- autoRepeat
boolean
True if the event is a result of automatic keyboard repeat.
#onMouseChanged
Fires when mouse state has changed.
Parameters:
- motion
boolean
True when mouse has moved, false when mouse is pressed/released.
#onKeyboardShortcut
Fires when on a keystroke that hasn't been consumed by the browser
Parameters:
- windowId
integer
Id of the browser window this keyboard event originates from.
- shortcutText
string
String representation of a keyboard shortcut
- autoRepeat
boolean
True if the shortcut is generated as a result of automatic keyboard repeat
- fromDevtools
boolean
True if the shortcut comes from a devtools window
- forcedBrowserPriority
boolean
True if shortcut forced browser priority.
#onMouseGestureDetection
Fires when we detect a possible start of a mouse-gesture related event
Parameters:
- windowId
integer
Id of the Vivaldi window where the event was originated
#onMouseGesture
Fires when the user triggered a mouse gesture
Parameters:
- windowId
integer
Id of the Vivaldi window where the event was originated
- clientX
number
X-coordinate of the gesture start point
- clientY
number
Y-coordinate of the gesture start point
- gestureDirections
string
Sequence of gesture directions
#onTabSwitchEnd
Fires when the tab switch using mouse wheel terminates
Parameters:
- windowId
integer
Id of the Vivaldi window where the event was originated
#onRockerGesture
Fires when the user triggered a rocker gesture
Parameters:
- windowId
integer
Id of the Vivaldi window where the event was originated
- isLeft
boolean
True if this is the left rocker gesture
#onWebviewClickCheck
Fires to check if the user clicks on a webview.
Parameters:
- windowId
integer
Id of the Vivaldi window where the event was originated
- mousedown
boolean
true if this is a mousedown event, false for mouseup
- button
integer
the mouse button that was pressed, the values match DOM's MouseEvent.button
- clientX
number
X-coordinates of the click
- clientY
number
Y-coordinates of the click
#onPageZoom
Fires on page zoom events
Parameters:
- windowId
integer
Id of the Vivaldi window where the event was originated
- steps
number
Number of basic steps to increase or decrease zoom.
- clientX
number
X-coordinates of the pointer position
- clientY
number
Y-coordinates of the pointer position
#onBeforeUnloadDialogClosed
Fired when a beforeunload dialog has been closed.
Parameters:
- windowId
integer
Window Id containg the tab Id.
- tabId
integer
Tab id for the beforeunload dialog.
- proceed
boolean
If true, the tab operation that triggered the dialog has been allowed to proceed.
#onLanguageDetermined
Fired when the language of the current page has been determined.
Parameters:
- tabId
integer
The tab Id.
- details
LanguageDetectionDetails
⚠ NO DESCRIPTION PROVIDED
#onShowTranslationUI
Fired when we should show translation UI. The status decides what UI we should show.
Parameters:
- tabId
integer
The tab Id.
- step
TranslateStep
⚠ NO DESCRIPTION PROVIDED
- error
TranslateError
⚠ NO DESCRIPTION PROVIDED
- automaticTranslation
boolean
true if this was triggered by an automatic translation.
#onPageTranslated
Fired when a translation has been completed on a page.
Parameters:
- tabId
integer
The tab Id.
- srcLang
string
Source language code it was translated from.
- destLang
string
Destination language code it was translated to.
- error
TranslateError
⚠ NO DESCRIPTION PROVIDED
#onIsPageTranslatedChanged
Fired when a translation state has changed on a page, eg. revert has been used.
Parameters:
- tabId
integer
The tab Id.
- isTranslated
boolean
The translation state has changed. For eg. revert, it will be false after revert has been invoked.
#onTabResourceMetricsRefreshed
Fired when resource metrics are updated.
Parameters:
- info
TabPerformanceData
⚠ NO DESCRIPTION PROVIDED
Methods
#update
Update the given tab with Vivaldi-specific properties.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- tabInfo
UpdateTabInfo
⚠ NO DESCRIPTION PROVIDED
#get
Get Vivaldi-specific properties from the tab.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
#insertText
Insert text into editable fields.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- text
string
The text to insert
#startDrag
Starts the HTML5 drag of the given tabs.
Parameters:
- dragData
DragData
The drag data to be transported in the dataobject.
#scrollPage
Scrolls the page up or down, depending on a parameter
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- scrollType
string
Whether to scroll up or down, and by how much
- scrollAmount
- (optional)
integer
The amount to scroll by
#moveSpatnavRect
Move current spatnav rect in |direction|
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- direction
NavigationDirection
⚠ NO DESCRIPTION PROVIDED
#activateSpatnavElement
Activate currently focused spatnav element
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- modifiers
integer
Keyboard modifiers to simulate shift or ctrl-clicking
#closeSpatnavOrCurrentOpenMenu
Returns true if layout changes by un-hovering the current spatnav element.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
#hasBeforeUnloadOrUnload
Check if a page contains a beforeunload or unload handler.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
#translatePage
Attempts to translate the given page.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- srcLang
string
Source language code to translate from. May be omitted.
- destLang
string
Destination language code to translate to. Must be present.
#revertTranslatePage
Attempts to revert the translating of the given page.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
#determineTextLanguage
Attempts to determined the language of the given text.
Parameters:
- tabId
integer
Any valid tabId can be used here, it is only used to determine which renderer to use.
- text
string
String to determine the language for. If the string is too short, this operation might not yield a language code.
#loadViaLifeCycleUnit
Calls TabLifecycleUnitSource::TabLifecycleUnit::Load if there is a TLU associated with the webcontents for the tab.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
#getTabPerformanceData
Look up performance data about tab. We might migrate to TabRendererData instead.
Parameters:
- tabId
integer
Id for tab we want info about.
#getSendTabToSelfTargets
Fetch current targets with information that can be used to make a menu.
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
#sendSendTabToSelfTarget
Send url and title to target that matches with the guid.
Parameters:
- url
string
⚠ NO DESCRIPTION PROVIDED
- title
string
⚠ NO DESCRIPTION PROVIDED
- guid
string
⚠ NO DESCRIPTION PROVIDED
#getSendTabToSelfEntries
Fetch current entries that have been shared to us.
Parameters:
- silent
boolean
Allow operation to mute error message if it is called too early on startup.
#execSendTabToSelfAction
Delete entries from the model.
Parameters:
- action
SendTabToSelfAction
⚠ NO DESCRIPTION PROVIDED
- guids
⚠ NO DESCRIPTION PROVIDED
Array
of:- string
#dismissSendTabToSelfEntries
Dismiss entries from the model.
Parameters:
- guids
⚠ NO DESCRIPTION PROVIDED
Array
of:- string
runtimePrivate
Types
#FeatureFlagInfo
Object returned from the getAllFeatureFlags function.
Properties:
- name
string
Name of this feature flag. This is the key used to look up the name.
- enabled
boolean
Enabled state of the feature
#UserProfile
Object returned from the getUserProfiles function.
Properties:
- name
string
Name of this user profile. For a guest profile, this should be ignored and translated string used instead.
- active
boolean
true if this is the active profile, otherwise false.
- path
string
Path of this user profile. This is used when opening and deleting profiles as it's unique.
- image
string
base64 encoded data url with the image to use for this profile. Empty for Guest profile.
- imageIndex
integer
The index into our array of default images this user is using. Corrensponds to |UserProfileImage| index value. Not valid for guest profiles.
- guest
boolean
true if this is the guest profile, otherwise false.
- customAvatar
string
Link to a HTTP-loadble custom avatar, if available.
#UserProfileImage
Object returned from the |getUserProfileImages|.
Properties:
- index
integer
Index of this user profile image in the table of available images.
- name
string
Name of this user profile image.
- image
string
base64 encoded data url with the image.
#ProfileStatEntry
Object returned from the |getProfileStatistics|.
Properties:
- category
string
Category of the count, 'History', 'Passwords' etc..
- count
integer
Number of data entries for this category.
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onProfilesUpdated
Fired when profiles have changed and the UI must be updated to reflect it.
Methods
#exit
Close all browsers and exit the application.
Parameters:
- prompt
boolean
Show exit confirmation when true.
#restart
Close all browsers and restart the application.
#getAllFeatureFlags
Gets all the registered Vivaldi feature flags.
#isGuestSession
Checks whether the current profile is running as a guest session or not.
#hasGuestSession
Checks whether any guest session is open.
#switchToGuestSession
Switch to a guest session.
#closeGuestSession
Close all guest session windows.
#openProfileSelectionWindow
Open window for profile management.
#getUserProfiles
Get all or just the active registered user profile(s).
Parameters:
- activeOnly
- (optional)
boolean
If true, only return the active profile.
#openNamedProfile
Open a new window using the given named profile.
Parameters:
- profilePath
string
Path of the profile to open.
#closeActiveProfile
Close all windows for the active profile in this window.
#getUserProfileImages
Get all available user profiles images.
#updateActiveProfile
Updates the name and icon index for the active profile.
Parameters:
- name
string
New name for the profile.
- avatarIndex
integer
Index into the avatar table for the new avatar.
- createDesktopIcon
- (optional)
boolean
Create desktop icon if true, otherwise removes any created profile icon for this profile. Windows only.
#hasDesktopShortcut
Checks whether the active profile has a generated desktop shortcut. Windows only, other platforms will return false.
#getProfileDefaults
Returns defaults for a new profile.
#createProfile
Creates a new profile with the given name and icon.
Parameters:
- name
string
Name for the profile.
- avatarIndex
integer
Index into the avatar table for the avatar for the new profile.
- createDesktopIcon
boolean
Create desktop icon.
#getProfileStatistics
Returns statistics for the profile associated with the given profile path.
Parameters:
- profilePath
string
Path of the profile, unique per profile.
#deleteProfile
Deletes a profile after closing all open windows for that profile.
Parameters:
- profilePath
string
Path of the profile, unique per profile.
searchEngines
Types
#DefaultType
ENUM
⚠ NO DESCRIPTION PROVIDED
- defaultSearch
- defaultPrivate
- defaultSearchField
- defaultSearchFieldPrivate
- defaultSpeeddials
- defaultSpeeddialsPrivate
- defaultImage
#TemplateURL
Represents a specific search engine. Urls and post params should only be used when editing the properties of a TemplateURL
Properties:
- guid
string
⚠ NO DESCRIPTION PROVIDED
- readOnly
boolean
Search engines are marked as read only if they are provided by extensions, or early on if they come from the set available before the service is fully loaded
- extensionId
string
For regular search engines, this string is empty. Otherwise it contains the id of the extension that provided the search.
- name
string
⚠ NO DESCRIPTION PROVIDED
- keyword
string
⚠ NO DESCRIPTION PROVIDED
- faviconUrl
string
⚠ NO DESCRIPTION PROVIDED
- url
string
⚠ NO DESCRIPTION PROVIDED
- postParams
string
⚠ NO DESCRIPTION PROVIDED
- suggestUrl
string
⚠ NO DESCRIPTION PROVIDED
- suggestPostParams
string
⚠ NO DESCRIPTION PROVIDED
- imageUrl
string
⚠ NO DESCRIPTION PROVIDED
- imagePostParams
string
⚠ NO DESCRIPTION PROVIDED
- prepopulateId
integer
⚠ NO DESCRIPTION PROVIDED
- starterPackId
integer
⚠ NO DESCRIPTION PROVIDED
- isActive
integer
0 is unspecified, 1 is active, 2 is inactive.
#AllTemplateURLs
⚠ NO DESCRIPTION PROVIDED
Properties:
- templateUrls
⚠ NO DESCRIPTION PROVIDED
Array
of:- TemplateURL
- starterPackEngines
⚠ NO DESCRIPTION PROVIDED
Array
of:- TemplateURL
- defaultSearch
string
⚠ NO DESCRIPTION PROVIDED
- defaultPrivate
string
⚠ NO DESCRIPTION PROVIDED
- defaultSearchField
string
⚠ NO DESCRIPTION PROVIDED
- defaultSearchFieldPrivate
string
⚠ NO DESCRIPTION PROVIDED
- defaultSpeeddials
string
⚠ NO DESCRIPTION PROVIDED
- defaultSpeeddialsPrivate
string
⚠ NO DESCRIPTION PROVIDED
- defaultImage
string
⚠ NO DESCRIPTION PROVIDED
- systemDefaultSearchChanged
boolean
⚠ NO DESCRIPTION PROVIDED
#SearchRequest
⚠ NO DESCRIPTION PROVIDED
Properties:
- url
string
⚠ NO DESCRIPTION PROVIDED
- contentType
string
⚠ NO DESCRIPTION PROVIDED
- postParams
string
⚠ NO DESCRIPTION PROVIDED
#SwitchPromptData
⚠ NO DESCRIPTION PROVIDED
Properties:
- shouldPrompt
boolean
True if the user should be prompted to switch search engines.
- promptType
string
Type of the dialog that should be displayed.
- currentSearchEngine
TemplateURL
⚠ NO DESCRIPTION PROVIDED
- partnerSearchEngines
⚠ NO DESCRIPTION PROVIDED
Array
of:- TemplateURL
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onTemplateUrlsChanged
Informs that template URLs have changed
Methods
#getKeywordForUrl
Obtains the default keyword for a given search URL
Parameters:
- url
string
⚠ NO DESCRIPTION PROVIDED
#getTemplateUrls
Retrieves data about all template URLS.
#addTemplateUrl
Adds a template url.
Parameters:
- templateUrl
TemplateURL
⚠ NO DESCRIPTION PROVIDED
#removeTemplateUrl
Removes a template url.
Parameters:
- guid
string
⚠ NO DESCRIPTION PROVIDED
#updateTemplateUrl
Changes a template url.
Parameters:
- templateUrl
TemplateURL
⚠ NO DESCRIPTION PROVIDED
#moveTemplateUrl
reorders by moving a search engine before another one
Parameters:
- guid
string
The search engine to move
- successor_guid
- (optional)
string
The search engine will be moved before the one with this guid or to the end if omitted. Must be different from guid.
#setDefault
Sets a default template url.
Parameters:
- defaultType
DefaultType
⚠ NO DESCRIPTION PROVIDED
- guid
string
⚠ NO DESCRIPTION PROVIDED
#getSearchRequest
Provides the request info to use for performing a search
Parameters:
- guid
string
⚠ NO DESCRIPTION PROVIDED
- searchTerms
string
⚠ NO DESCRIPTION PROVIDED
#repairPrepopulatedTemplateUrls
resets the prepopulated template urls and the default search
Parameters:
- onlyKeepPrepopulated
boolean
⚠ NO DESCRIPTION PROVIDED
#getSwitchPromptData
Gathers and returns the needed info for partner search engine switch dialog.
#acknowledgeSwitchPrompt
Mark current switch prompt as seen.
#setIsActive
Used to enable or disable a starter pack engine.
Parameters:
- guid
string
⚠ NO DESCRIPTION PROVIDED
- isActive
boolean
⚠ NO DESCRIPTION PROVIDED
sessionsPrivate
Types
#ContentType
ENUM
Defines role of a node in content. 'group' is the same as a stack.
- window
- workspace
- pinned
- group
- tab
#BackupType
ENUM
Defines how a backup should be made.
- backup
- autosave
#WorkspaceId
- WorkspaceId
number
Unique identifier.
#ContentTarget
Settings used when moving an element in a saved session.
Properties:
- beforeTabId
number
Target id. Move items before tab with this id. At end if negative.
- group
- (optional)
string
Target tab stack id. Remove id if empty.
- pinned
- (optional)
boolean
Target pinned state.
- windowId
- (optional)
number
Target window id. Not set when target is within a workspace.
- workspace
- (optional)
WorkspaceId
Target workspace id. Remove id if negative.
#WorkspaceItem
Holds information of a workspace. Not actual tabs, but the workspace itself.
Properties:
- id
WorkspaceId
⚠ NO DESCRIPTION PROVIDED
- name
string
Name shown in UI.
- icon
string
Icon shown in UI.
- emoji
string
emoji shown in UI.
#TabContent
Holds information of a tab
Properties:
- id
number
Unique identifier.
- index
number
Index as stored in database.
- name
string
Active page title. Can be empty.
- fixedName
string
Name provided by user. Overrides 'name'. Has not been set if string is empty.
- url
string
Url of active entry in navigation list.
- pinned
boolean
Pinned state of the tab.
- quarantine
boolean
Tab is not installed if true
- group
string
The group (stack) the tab belongs to. Can be empty which means no group.
- fixedGroupName
string
Name provided by user. Has not been set if string is empty.
#WindowContent
Holds information of a window.
Properties:
- id
number
Unique identifier.
- quarantine
boolean
Window is not installed if true.
- tabs
Tabs in window.
Array
of:- TabContent
#WorkspaceContent
Holds information, including tabs of a workspace.
Properties:
- id
WorkspaceId
⚠ NO DESCRIPTION PROVIDED
- quarantine
boolean
Workspace is not installed if true.
- tabs
Tabs in workspace.
Array
of:- TabContent
- name
string
Name shown in UI.
- icon
string
Icon shown in UI.
- emoji
string
emoji shown in UI.
#ContentModel
⚠ NO DESCRIPTION PROVIDED
Properties:
- id
number
Session identifier.
- windows
⚠ NO DESCRIPTION PROVIDED
Array
of:- WindowContent
- workspaces
⚠ NO DESCRIPTION PROVIDED
Array
of:- WorkspaceContent
#GroupAlias
⚠ NO DESCRIPTION PROVIDED
Properties:
- group
string
Existing group id.
- alias
string
A new unique id that can be used instead of the existing.
#WorkspaceState
⚠ NO DESCRIPTION PROVIDED
Properties:
- groups
List of new group ids. There must be one entry for each affected group.
Array
of:- GroupAlias
- item
WorkspaceItem
List of workspaces in session.
#ContentCommands
⚠ NO DESCRIPTION PROVIDED
Properties:
- ids
Tabs and windows in a session.
Array
of:- number
- groupAliases
- (optional)
A list of new group ids that must be supplied when creating a window. There must be one entry for each affected group.
Array
of:- GroupAlias
- move
- (optional)
boolean
For moving tabs.
- pin
- (optional)
boolean
For setting pinned state.
- quarantine
- (optional)
boolean
For setting quarantine state.
- remove
- (optional)
boolean
For deleting a tab.
- tabstack
- (optional)
boolean
For creating a stack. There must be at least two tabs in the 'ids' list.
- title
- (optional)
string
For setting title. Ignored if number of ids is not 1.
- target
- (optional)
ContentTarget
Used for commands: ['move', 'tabstack'].
- type
- (optional)
ContentType
Used for commands: ['title'].
- window
- (optional)
boolean
For creating a window.
- workspace
- (optional)
boolean
For creating a workspace.
- workspaceState
- (optional)
WorkspaceState
Used for commands: ['workspace']
- workspaceId
- (optional)
WorkspaceId
Used for commands: ['workspace']
#ItemType
ENUM
Defines supported items
- folder
- node
- history
#GroupName
Holds custom name for a group (tab stack).
Properties:
- id
string
Group identifier.
- name
string
Visible name in UI.
#SessionItem
Object that holds all information about a single session.
Properties:
- id
number
Unique identifier.
- type
ItemType
Tells what kind of item. 'folder' or 'node'. A 'node' can have children (it is then a container).
- name
string
Session display name.
- createDateJS
number
Session save date in JS format.
- modifyDateJS
number
Session update date in JS format.
- windows
number
Number of windows in this session.
- tabs
number
Number of tabs in this session.
- quarantined
number
Number of quarantined (inactive) tabs in this session.
- workspaces
List of workspaces in session.
Array
of:- WorkspaceItem
- groupNames
List of custom group names (tab stack names) in session. Can be empty.
Array
of:- GroupName
- parentId
number
Unique identifier.
- containerId
number
Set for elements in a container or trash, -1 otherwise.
- content
- (optional)
ContentModel
⚠ NO DESCRIPTION PROVIDED
- children
- (optional)
An ordered list of children of this node.
Array
of:- SessionItem
#SessionIds
- SessionIds
⚠ NO DESCRIPTION PROVIDED
Array
of:- number
#SessionModel
⚠ NO DESCRIPTION PROVIDED
Properties:
- items
⚠ NO DESCRIPTION PROVIDED
Array
of:- SessionItem
- rootId
number
⚠ NO DESCRIPTION PROVIDED
- autosaveId
number
⚠ NO DESCRIPTION PROVIDED
- trashId
number
⚠ NO DESCRIPTION PROVIDED
- loadingFailed
boolean
⚠ NO DESCRIPTION PROVIDED
#SessionOpenOptions
Options for opening the session.
Properties:
- newWindow
boolean
The session will open in a new window.
- oneWindow
boolean
All tabs will open in one windows.
- withWorkspace
boolean
Open workspace tabs.
- tabIds
Open given tabs only.
Array
of:- number
#SessionAddOptions
Options for adding a new session or updating an existing session.
Properties:
- name
string
User friendly description of the session. [add, duplicate].
- filename
string
Filename without extension. Final name be extended with numbers (N) on collision. [all]
- parentId
number
Parent of new session node in the model. [add, duplicate].
- index
number
Where to insert among parent's siblings. [add, duplicate].
- owner
string
Free form token that is passed back with the event. Allows proper handling when data is added. [add, duplicate].
- fromId
- (optional)
number
If set, the new entry is copied from the given.
- windowId
- (optional)
integer
Save only the given window. 0 or not set means all windows. Ignored if 'fromId' is set. [add, update]
- ids
- (optional)
List of tab identifiers to be saved. Ignored if 'fromId' is set. [add, upddate]
Array
of:- integer
- backup
- (optional)
BackupType
Special flag for timed backups. No other options are then used.
#SessionChange
ENUM
Defines what has changed.
- added
- changed
- deleted
- moved
- content
#SessionChangeData
⚠ NO DESCRIPTION PROVIDED
Properties:
- owner
string
Caller component (in UI) identifier.
- parentId
number
Set for 'added' and 'moved' events.
- index
number
Set for 'added' and 'moved' events.
- item
- (optional)
SessionItem
Set for 'added' and 'changed' event.
- content
- (optional)
ContentModel
Set for 'content' event.
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onChanged
Fired when a session is added or removed.
Parameters:
- id
number
⚠ NO DESCRIPTION PROVIDED
- change
SessionChange
⚠ NO DESCRIPTION PROVIDED
- data
SessionChangeData
⚠ NO DESCRIPTION PROVIDED
#onPersistentLoad
Fired when a persisted session is loaded.
Parameters:
- state
boolean
⚠ NO DESCRIPTION PROVIDED
Methods
#getAll
Returns all previously saved sessions stored on disk.
#add
Saves all open tabs to the named session.
Parameters:
- options
SessionAddOptions
Controls the adding behavior.
#delete
Deletes session. Items in the trash folder are permanently removed. Others are moved to trash.
Parameters:
- id
number
Identifier of session to delete.
- index
number
Index to move to in trash folder.
#emptyTrash
Permanently deletes all trashed session.
#getAutosaveIds
Get ids for nodes that are older than 'days' old from the time the function was called
Parameters:
- days
number
Number of days to go hack in history.
#getContent
Returns contents of a session.
Parameters:
- id
number
Identifier of session.
#makeContainer
Turns a history session into the default entry of the container.
Parameters:
- id
number
Session identifier.
#modifyContent
Changes internal settings in a session
Parameters:
- id
number
Session identifier.
- commands
ContentCommands
Describes changes to be made
#move
Moves session.
Parameters:
- id
number
Identifier of session to move.
- parentId
number
New parent
- index
number
Position in new parent's child list.
#open
Open a specific named session.
Parameters:
- id
number
Identifier of session to open.
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- options
SessionOpenOptions
Session open options.
#rename
Renames the named session.
Parameters:
- id
number
Identifier of session to rename.
- name
string
New name.
#update
Updates a session with current open tabs.
Parameters:
- id
number
Identifier of session to update.
- options
SessionAddOptions
Controls the update behavior.
#restoreLastClosed
Will restore the last session called from any profile. Returns true if a window was created.
webViewPrivate
Types
#ThumbnailParams
Object passed to various thumbnail capture functions.
Properties:
- width
- (optional)
integer
The width of the scaled output bitmap.
- height
- (optional)
integer
The height of the scaled output bitmap.
- scale
- (optional)
number
Set scale of the output bitmap, defaults to 0.5. Note that |width.height| will be used if both |scale| and |width.height| are set.
Methods
#getThumbnail
⚠ NO DESCRIPTION PROVIDED
Parameters:
- instanceId
integer
⚠ NO DESCRIPTION PROVIDED
- params
ThumbnailParams
⚠ NO DESCRIPTION PROVIDED
#showPageInfo
⚠ NO DESCRIPTION PROVIDED
Parameters:
- instanceId
integer
⚠ NO DESCRIPTION PROVIDED
- position
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- left
integer
Anchor left position, screen coordinates.
- top
integer
Anchor top position, screen coordinates.
#setIsFullscreen
⚠ NO DESCRIPTION PROVIDED
Parameters:
- instanceId
integer
⚠ NO DESCRIPTION PROVIDED
- isFullscreen
boolean
This is used to set a webview as fullscreen or not. This is needed for updating the pseudo-style :fullscreen when going in and out of fullscreen not via element.requestFullscreen and element.cancelFullscreen .
#getPageHistory
⚠ NO DESCRIPTION PROVIDED
Parameters:
- instanceId
integer
The instance ID of the guest
process.
#allowBlockedInsecureContent
Will load all blocked content in a page.
Parameters:
- instanceId
integer
⚠ NO DESCRIPTION PROVIDED
#sendRequest
Navigates the webview to a given URL but with greater control over the sent request.
Parameters:
- instanceId
integer
⚠ NO DESCRIPTION PROVIDED
- url
string
The URL of the page to navigate to.
- transitionType
historyPrivate.TransitionType
How the URL was reached.
- fromUrlField
boolean
Whether the request came from the url field
- usePost
boolean
Whether to perform the navigation via POST.
- postData
string
When using POST, this will be the body of the request.
- extraHeaders
string
Extra headers to pass with the request. See OpenURLParams in chromium code.
#getPageSelection
Get any selected text in the page.
Parameters:
- instanceId
integer
⚠ NO DESCRIPTION PROVIDED
thumbnails
Types
#CaptureBookmarkParams
A structure containing parameters for the captureUrl call.
Properties:
- bookmarkId
string
Bookmark id to associate the captured thumbnail with.
- url
string
url to load and generate thumbnail for.
#CaptureUIParams
A structure containing parameters for the captureUI call.
Properties:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- posX
number
X offset inside the given app window in the UI coordinates.
- posY
number
Y offset inside the given app window in the UI coordinates.
- width
number
Width of the capture in the UI coordinates.
- height
number
Height of the capture in the UI coordinates.
- encodeFormat
- (optional)
string
The encoding format. 'jpg' or 'png'. Defaults to 'png'.
- encodeQuality
- (optional)
integer
The jpg encoding quality if format is 'jpg', otherwise ignored. Default is 90, which is very high quality.
- saveToDisk
- (optional)
boolean
The resulting image is saved under the configurable directory. Default is false.
- showFileInPath
- (optional)
boolean
If |saveToBasePath| is provided, setting this to true will open the folder with the file selected after capture has completed. Default is false.
- copyToClipboard
- (optional)
boolean
If true, will copy the image to clipboard in a raw and uncompressed format. This will override any file path arguments. Default is false.
- saveFilePattern
- (optional)
string
If set, will use this pattern to contruct the filename. Note that the file name is still guaranteed to be unique, and (1), (2) etc might be appended if needed.
#CaptureRect
Rect struct for capture actions where the result wanted is a cut-out of the full tab.
Properties:
- left
integer
x
- top
integer
y
- width
integer
width
- height
integer
height
#CaptureTabParams
A structure containing parameters for the captureTab call.
Properties:
- encodeFormat
- (optional)
string
The encoding format. 'jpg' or 'png'. Defaults to 'png'.
- encodeQuality
- (optional)
integer
The jpg encoding quality if format is 'jpg', otherwise ignored. Default is 90, which is very high quality.
- fullPage
- (optional)
boolean
true to capture the full height of the page, restricted to 20000 pixels height. Default is false.
- rect
- (optional)
CaptureRect
Wanted rect, output is not scaled.
- width
- (optional)
integer
The resulting width of the capture after scaling. Ignored if |fullPage| is true.
- height
- (optional)
integer
The resulting height of the capture after scaling or if onlyVisible is false, the maximum number of pixels to capture in height.
- saveToDisk
- (optional)
boolean
The resulting image is saved under the configurable directory. Default is false.
- showFileInPath
- (optional)
boolean
If |saveToBasePath| is provided, setting this to true will open the folder with the file selected after capture has completed. Default is false.
- copyToClipboard
- (optional)
boolean
If true, will copy the image to clipboard in a raw and uncompressed format. This will override any file path arguments. Default is false.
- saveFilePattern
- (optional)
string
If set, will use this pattern to contruct the filename. Note that the file name is still guaranteed to be unique, and (1), (2) etc might be appended if needed.
Methods
#captureUI
Captures a part of the visible UI for the given app window.
Parameters:
- params
CaptureUIParams
⚠ NO DESCRIPTION PROVIDED
#captureTab
Captures the contents of a tab.
Parameters:
- tabId
integer
The tab id to capture. 0 to capture the current active tab.
- params
CaptureTabParams
⚠ NO DESCRIPTION PROVIDED
#captureBookmark
Loads a url then captures the contents of it and attached it to a bookmark.
Parameters:
- params
CaptureBookmarkParams
⚠ NO DESCRIPTION PROVIDED
bookmarkContextMenu
Types
#Rect
Position and size of element in menu bar.
Properties:
- x
integer
Left position of item that opens menu, screen coordinates.
- y
integer
Top position of item that opens menu, screen coordinates.
- width
integer
Width of item that opens menu.
- height
integer
Height of item that opens menu.
#FolderEntry
⚠ NO DESCRIPTION PROVIDED
Properties:
- id
string
Bookmark folder id.
- offset
integer
Offset into folder.
- folderGroup
boolean
When true, sorted content will have folders first or last in list.
- rect
Rect
⚠ NO DESCRIPTION PROVIDED
#SortOrder
ENUM
Defines how to sort container items.
- ascending
- descending
#SortField
ENUM
Defines what element to use as sort key
- title
- url
- nickname
- description
- dateAdded
#Edge
ENUM
Defines position of menu items added in chrome code wrt bookmark items.
- above
- below
- off
#Icons
- Icons
Icons encoded as base64
Array
of:- string
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onOpen
Fires before menu opens.
Parameters:
- id
string
Menu id, same as the bookmark folder to be shown.
#onClose
Fires before menu closes.
Methods
#show
Shows a context menu.
Parameters:
- properties
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- siblings
List of menu entries.
Array
of:- FolderEntry
- id
string
Bookmark folder id. Must match an id in the sibling list.
- edge
- (optional)
Edge
Where to place extra menu items
- sortField
- (optional)
SortField
⚠ NO DESCRIPTION PROVIDED
- sortOrder
- (optional)
SortOrder
⚠ NO DESCRIPTION PROVIDED
- icons
Icons
Default and folder icons.
vivaldiAccount
Types
#FetchErrorType
ENUM
⚠ NO DESCRIPTION PROVIDED
- no_error: Everything went fine
- network_error: Couldn't fetch data because of a network issue.
- server_error: The server provided an unexpected response to our request.
- invalid_credentials: The server explicitly rejected our credentials.
#FetchError
properties of an error that occured during a network request.
Properties:
- errorType
FetchErrorType
⚠ NO DESCRIPTION PROVIDED
- serverMessage
string
⚠ NO DESCRIPTION PROVIDED
- errorCode
integer
⚠ NO DESCRIPTION PROVIDED
#AccountInfo
A structure detailing the informations about the currrently logged in account.
Properties:
- accountId
string
The unique account identifier, as retrieved from the server. Typically, this is just a case-sensitive version of the username or an empty string if it hasn't been retrieved yet. The UI should check whether this is empty to determine whether the user has set up an account, even if the tokens might be missing.
- username
string
The username, as entered by the user.
- pictureUrl
string
A link to the user's avatar. This is typically an https url, but the server is free to provide any valid url.
- donationTier
string
⚠ NO DESCRIPTION PROVIDED
#State
Data reporting the current state of the account and associated tokens.
Properties:
- accountInfo
AccountInfo
⚠ NO DESCRIPTION PROVIDED
- hasSavedPassword
boolean
Whether we found a password for this sync account in the password manager.
- hasToken
boolean
If we have a token, we are practically logged in (but we may still need to get the accountId to be fully operational).
- accessToken
string
The actual access token. This is provided as a temporary measure until the notification code is moved to C++.
- hasEncryptedToken
boolean
We found a saved encrypted token, but could not decrypt it.
- tokenRequestTime
number
⚠ NO DESCRIPTION PROVIDED
- nextTokenRequestTime
number
⚠ NO DESCRIPTION PROVIDED
- lastTokenFetchError
FetchError
⚠ NO DESCRIPTION PROVIDED
- lastAccountInfoFetchError
FetchError
⚠ NO DESCRIPTION PROVIDED
- isReady
boolean
⚠ NO DESCRIPTION PROVIDED
#PendingRegistration
Information about an account that's in the process of registering.
Properties:
- username
string
⚠ NO DESCRIPTION PROVIDED
- password
string
⚠ NO DESCRIPTION PROVIDED
- recovery_email
string
⚠ NO DESCRIPTION PROVIDED
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onAccountStateChanged
Fired whenever something changed with the account
Parameters:
- state
State
⚠ NO DESCRIPTION PROVIDED
Methods
#login
Attempt to obtain an access token for vivaldi.net using the provided credentials.
Parameters:
- username
string
⚠ NO DESCRIPTION PROVIDED
- password
string
⚠ NO DESCRIPTION PROVIDED
- savePassword
boolean
⚠ NO DESCRIPTION PROVIDED
#logout
Clear the previously obtained tokens and forget the logged in username.
#getState
Retrieve the current state of the account manager.
#setPendingRegistration
Stores credentials for an account in the process of registering. Call without parameter to discard the currently stored credentials
Parameters:
- registration
- (optional)
PendingRegistration
⚠ NO DESCRIPTION PROVIDED
#getPendingRegistration
Retrieves the last stored credentials for a registration in progress.
savedpasswords
Types
#SavedPasswordItem
Item containing saved password.
Properties:
- index
string
Saved password index in the list.
- origin
string
The origin url of saved password.
- username
string
The user name of saved password.
- password
string
The password in clear text.
#PasswordForm
Information about the password form to store or retrieve. The fields should match those documented in chromium/components/password_manager/core/browser/password_form.h
Properties:
- signon_realm
string
⚠ NO DESCRIPTION PROVIDED
- origin
string
⚠ NO DESCRIPTION PROVIDED
- username
string
⚠ NO DESCRIPTION PROVIDED
- password
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
Methods
#createDelegate
Creates a passwords_private_delegate for the current user profile.
#add
Stores a password in the password store.
Parameters:
- isExplicit
boolean
The action was initiated as the result of user input
- passwordForm
PasswordForm
⚠ NO DESCRIPTION PROVIDED
#get
Retrieves a password in the password store.
Parameters:
- passwordForm
PasswordForm
⚠ NO DESCRIPTION PROVIDED
#delete
Removes a password in the password store.
Parameters:
- isExplicit
boolean
The action was initiated as the result of user input
- passwordForm
PasswordForm
⚠ NO DESCRIPTION PROVIDED
#getList
Retrieves list of saved passwords.
#remove
Removes an item from the list retrieved with getList.
Parameters:
- id
string
⚠ NO DESCRIPTION PROVIDED
#authenticate
Before showing password to the user, make sure they are authenticated via the OS.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
directMatch
Types
#Item
A Direct match item
Properties:
- name
string
⚠ NO DESCRIPTION PROVIDED
- title
string
⚠ NO DESCRIPTION PROVIDED
- image_url
string
⚠ NO DESCRIPTION PROVIDED
- image_path
string
⚠ NO DESCRIPTION PROVIDED
- category
number
⚠ NO DESCRIPTION PROVIDED
- display_location_address_bar
boolean
⚠ NO DESCRIPTION PROVIDED
- display_location_sd_dialog
boolean
⚠ NO DESCRIPTION PROVIDED
- redirect_url
string
⚠ NO DESCRIPTION PROVIDED
- allowed_to_be_default_match
boolean
⚠ NO DESCRIPTION PROVIDED
#Items
- Items
A Direct match items array
Array
of:- Item
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onPopularSitesReady
Fires when data has become available in backend.
Methods
#hide
Hides direct match so it will not show up in omnibox.
Parameters:
- url
string
The url of a direct match provider to hide.
#getPopularSites
Fetch popular sites from DM units sorted asc by `position` where sd_dialog=true
#getForCategory
Returns direct match items for provided `category_id` sorted asc by `position` and filtered by `display_locations`
Parameters:
- categoryId
number
⚠ NO DESCRIPTION PROVIDED
#resetHidden
Reset all previously hidden direct match providers.
historyPrivate
Types
#TransitionType
ENUM
The transition type for this visit from its referrer.
- link
- typed
- auto_bookmark
- auto_subframe
- manual_subframe
- generated
- auto_toplevel
- form_submit
- reload
- keyword
- keyword_generated
#HistoryPrivateItem
An object encapsulating one result of a history query. Properties marked with 'Used for statistics' can be removed if we make a new API function for stats.
Properties:
- id
string
The unique identifier for the item.
- url
string
The URL navigated to by a user.
- address
string
Used for statistics. The address of the page navigated to by a user.
- title
string
The title of the page when it was last loaded.
- visitTime
number
When this page was visited, represented in milliseconds since the epoch.
- transitionType
TransitionType
Used for statistics. The transition type for this visit from its referrer.
- dateKey
string
Date string of the visit. Format: YYYY-MM-DD
#TopUrlItem
An object encapsulating one result of a top url history query.
Properties:
- date
string
The date of the visit for the top url
- url
string
The url visited
- numberOfVisit
- (optional)
integer
The visit count of the url.
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onVisitModified
Fired when one or more URLs are removed from the history service. When all visits have been removed the URL is purged from history.
Parameters:
- modified
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- urls
- (optional)
⚠ NO DESCRIPTION PROVIDED
Array
of:- string
Methods
#deleteVisits
Deletes all visits of the given URL for a certain period.
Parameters:
- details
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- url
string
The URL to remove.
- time
number
The visit time of the item to remove, represented in milliseconds since the epoch. IMPORTANT: This must be the exact visit time, to the microsecond. If it is truncated, then the deletion will not be synced.
#getTopUrlsPerDay
Retrives top url per day. Sorted by number of visits within the day
Parameters:
- maxTopUrlResults
number
The number of top urls to return per day.
#visitSearch
Retrives all visits. Sorted by visit time descending.
Parameters:
- query
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- startTime
- (optional)
number
Limit results to those visited after this date, represented in milliseconds since the epoch. If not specified, this defaults to 24 hours in the past.
- endTime
- (optional)
number
Limit results to those visited before this date, represented in milliseconds since the epoch.
#updateTopSites
Requests an update for top sites
sync
Types
#SyncNotificationClientStatus
ENUM
Used to report whether we have a connection to the notification server.
- connected
- disconnected
#EngineState
ENUM
The state of the sync engine.
- stopped: Sync has not been requested by the user
- starting: Sync has been requested but the engine is not done starting
- starting_server_error: Sync has been requested but the engine is not done starting and can't do so because of a server issue
- started: The sync engine is running normally
- clearing_data: The sync engine is running, but it is in the process of requesting server data to be cleared.
- configuration_pending: The sync engine is running, but it is waiting for the current setup to be complete before actually syncing anything
- failed: The sync engine encountered an error that forced it to stop.
#DisableReason
ENUM
The reason why the sync engine is in a failed state. This should be kept in sync with SyncService::DisableReason (chromium/components/sync/driver/sync_service.h)
- enterprise_policy
- not_signed_in
- unrecoverable_error
- flag
#CycleStatus
ENUM
Error occuring as part of the sync cycle. This should be kept in sync with VivaldiSyncUIHelper::CycleStatus (sync/vivaldi_sync_ui_helper.h)
- not_synced
- success
- auth_error
- server_error
- network_error
- conflict
- throttled
- other_error
#ProtocolErrorType
ENUM
Possible error types for errors returned as part of sync server responses. This should be kept in sync with syncer::SyncProtocolErrorType (chromium/components/sync/protocol/sync_protocol_error.h)
- success
- not_my_birthday
- throttled
- transient_error
- migration_done
- disabled_by_admin
- partial_failure
- client_data_obsolete
- encryption_obsolete
- conflict
- invalid_message
- unknown
#ClientAction
ENUM
Possible action that the client can take to fix the last server-returned error. This should be kept in sync with syncer::ClientAction (chromium/components/sync/protocol/sync_protocol_error.h)
- upgrade_client
- disable_sync_on_client
- stop_sync_for_disabled_account
- reset_local_sync_data
- unknown
#DataType
ENUM
User selectable data types that we support
- bookmarks
- preferences
- passwords
- autofill
- history
- extensions
- apps
- reading_list
- tabs
- notes
#DataTypeSelection
A structure containing the system status of a data type.
Properties:
- dataType
DataType
⚠ NO DESCRIPTION PROVIDED
- enabled
boolean
true if we want to sync this data type, otherwise false.
#EngineData
Contains information about the state of the sync engine.
Properties:
- engineState
EngineState
⚠ NO DESCRIPTION PROVIDED
- disableReasons
⚠ NO DESCRIPTION PROVIDED
Array
of:- DisableReason
- protocolErrorType
ProtocolErrorType
⚠ NO DESCRIPTION PROVIDED
- protocolErrorDescription
string
Plain english description of the error as sent by the server
- protocolErrorClientAction
ClientAction
⚠ NO DESCRIPTION PROVIDED
- usesEncryptionPassword
boolean
Whether encryption has been set up
- needsDecryptionPassword
boolean
Whether a password is needed to decrypt the sync data
- isEncryptingEverything
boolean
Wheter the engine is encrypting all data types
- isSetupInProgress
boolean
Whether the sync service is being configured.
- isFirstSetupComplete
boolean
Whether the sync service has been configured and started before.
- syncEverything
boolean
Indicates that all datatypes will always be synced.
- dataTypes
List of available data types and whether the user chose to sync them.
Array
of:- DataTypeSelection
- isReady
boolean
⚠ NO DESCRIPTION PROVIDED
#CycleData
Contains information about the last sync cycle.
Properties:
- cycleStartTime
number
The last time a sync cycle started.
- downloadUpdatesStatus
CycleStatus
Whether the download updates part of the last sync cycle was successful
- commitStatus
CycleStatus
Whether the commit part of the last sync cycle was successful
- nextRetryTime
number
The time at which the next sync attempt will be made, if the last one failed
- isReady
boolean
⚠ NO DESCRIPTION PROVIDED
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onEngineStateChanged
Fired when the sync engine state has changed.
Parameters:
- data
EngineData
⚠ NO DESCRIPTION PROVIDED
#onCycleCompleted
Fired when a sync cycle completed.
Parameters:
- data
CycleData
⚠ NO DESCRIPTION PROVIDED
Methods
#setEncryptionPassword
Sets the password to use for encryption/decryption of Sync data. If an empty password is supplied, the password supplied when logging in will be used.
Parameters:
- password
- (optional)
string
The encryption password to use. If not specified, We will attempt to use the currently stored login password instead.
#backupEncryptionToken
Saves the token derived from the encryption password to a file
Parameters:
- target_file
string
The file to which the token should be saved
#restoreEncryptionToken
Uses a previously backed-up token to set up encryption
Parameters:
- source_file
string
The file from which the token should be recovered
#getDefaultSessionName
Returns the device name as determined by the OS.
#setTypes
Sets which data types should be synced
Parameters:
- syncEverything
boolean
Sets which datatypes sould be synced.
- types
List of data types to be enabled
Array
of:- DataTypeSelection
#getEngineState
Returns informations about the status of the sync engine.
#getLastCycleState
Returns informations about the status of the last sync cycle.
#setupComplete
Informs the backend that the user is done configuring sync types
#clearData
Clear all the user's data on the server side and logs them out
accessKeys
Types
#AccessKeyDefinition
Contains the access key character and all relevant attributes from the element it belongs to
Properties:
- access_key
string
The access key itself, without modifiers
- tagname
string
The tagname of the access key element
- title
string
The title attribute of the access key element
- href
string
The href attribute of the access key element
- value
string
The value attribute of the access key element
- textContent
string
The textContent of the access key element
- id
string
The id attribute of the access key element
Methods
#getAccessKeysForPage
Get a list of all access keys defined on this page
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
#action
Find the element corresponding to an access key and fire the access key action
Parameters:
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
- id
string
Element ID to be used for lookup
zoom
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onDefaultZoomChanged
Fired when the default zoom changes.
Parameters:
- zoomlevel
number
The new zoom level
#onUIZoomChanged
Fired when the UI zoom changes.
Parameters:
- zoomlevel
number
The new UI zoom level
Methods
#setVivaldiUIZoom
⚠ NO DESCRIPTION PROVIDED
Parameters:
- zoomFactor
number
The new value for Vivaldi UI zoom factor.
#getVivaldiUIZoom
⚠ NO DESCRIPTION PROVIDED
#setDefaultZoom
⚠ NO DESCRIPTION PROVIDED
Parameters:
- zoomFactor
number
The new Vivaldi default global zoom factor.
#getDefaultZoom
⚠ NO DESCRIPTION PROVIDED
infobars
Types
#ButtonAction
ENUM
⚠ NO DESCRIPTION PROVIDED
- accept
- cancel
- link
- dismiss
#InfobarButton
Button to be shown in the infobar.
Properties:
- text
string
Text to be shown in the button.
- action
ButtonAction
The action to be performed when clicking this button.
- prominent
boolean
This is the prominent button and should receive styling accordingly.
#Infobar
Object passed to the onInfobarCreated event.
Properties:
- tabId
integer
The tabId this infobar is associated with.
- identifier
integer
The identifier used to identify this infobar. It is only unique in combination with |tabId|.
- messageText
string
The message text to be shown in the infobar.
- buttons
⚠ NO DESCRIPTION PROVIDED
Array
of:- InfobarButton
- linkText
string
The text associated with a link to be shown in the infobar.
- isCloseable
boolean
Should we have a dismiss button or not.
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onInfobarCreated
Fired when a infobar has been created and should be shown.
Parameters:
- params
Infobar
Information about the infobar.
#onInfobarRemoved
Fired when a infobar has been removed and should no longer be visible.
Parameters:
- tabId
integer
The tabId this infobar is associated with.
- identifier
integer
The identifier used to identify this infobar. It is only unique in combination with |tabId|.
Methods
#sendButtonAction
Send the action defined on the clicked button.
Parameters:
- tabId
integer
The tabId this infobar is associated with.
- identifier
integer
The identifier used to identify this infobar. It is only unique in combination with |tabId|.
- action
string
The click action for this button. This must be the same as defined in the |InfoBarButton| type for this button.
#showInfobar
Invokes an infobar in the specified tab.
Parameters:
- tabId
integer
The tabId of the tab where the infobar will appear.
contentBlocking
Types
#RuleGroup
ENUM
Used to specify whether a specific operation should apply to tracking blocking or adblocking.
- tracking
- ad_blocking
#ExceptionList
ENUM
Used to inform whether the exception list used in a rule group is a list of exemptions or a list for which process is enabled
- process_list
- exempt_list
#PresetKind
ENUM
Which rough category a given preset list falls in
- ads
- trackers
- partners
- annoyances
- cookie_notices
- other
- regional
#FetchResult
ENUM
The result of a fetch operation on a rule source.
- success: Fetch completed successfully.
- download_failed: For an online source, failed to download using the provided URL.
- file_not_found: For a local source, the file provided didn't seem to exist.
- file_read_error: For a local source, the file provided couldn't be read.
- file_unsupported: The rules file is of an invalid format or doesn't contain any valid rule.
- failed_saving_parsed_rules: The rules were fetched and compiled properly, but the result couldn't be saved to the profile.
- unknown: No fetching attempt has completed yet.
#RulesInfo
Information about the rules themselves and more detailed parsing results
Properties:
- valid_rules
integer
The number of entries in the file that resulted in a rule being compiled.
- unsupported_rules
integer
The number of entries in the file that resolved to valid rules that either didn't make sense or are not supported at this time.
- invalid_rules
integer
The number of entries in the file that resolved to valid rules that could not be parsed to a rule or were explicitly against the spec.
#AdBlockMetadata
Information extracted from the adblock file comments. If the user added a malicous source, these could be anything. Handle with care.
Properties:
- homepage
string
URL pointing to the original website for this list.
- title
string
List name.
- expires
integer
How often the list is refreshed, in hours.
- license
string
URL pointing to licensing info for the list.
- version
integer
Version number of the list.
#RuleSourceSettings
Parameters used when parsing the rules list. Can only be modified when the source is disabled
Properties:
- allow_abp_snippets
boolean
If false, any present abp snippet rules will be ignored.
- naked_hostname_is_pure_host
boolean
If true, any rule that looks like just a host name will be converted to match only the host part of the url.
- use_whole_document_allow
boolean
If true, any allow rule using the document type will cause all resources loaded by matching documents to be allowed (ABP beahvior).
#RuleSource
Information about a loaded rule source, including its fetching status and metadata retrieved when extracting rules from it
Properties:
- source_url
string
For an online source, this is the url that was provided when setting it up.
- source_file
string
For an local source, this is the file that was provided when setting it up.
- is_from_url
boolean
indicates whether the rule source is online or local, and which of the source_url and source_file fields is valid
- settings
RuleSourceSettings
See RuleSourceSettings.
- id
integer
⚠ NO DESCRIPTION PROVIDED
- rules_list_checksum
string
Checksum of the compiled rule file derived from this source. This will be the empty string if the rule source has never been fetched succesfully.
- unsafe_adblock_metadata
AdBlockMetadata
⚠ NO DESCRIPTION PROVIDED
- last_update
number
The last time the source was successfully fetched and the corresponding rules updated. Represented in milliseconds since the epoch.
- next_fetch
number
The next time a fetching and updating from the rule source will be attempted. Represented in milliseconds since the epoch.
- is_fetching
boolean
Whether fetching of the rule source is in progress
- last_fetch_result
FetchResult
The result of the last fetch attempt
- rules_info
RulesInfo
⚠ NO DESCRIPTION PROVIDED
- preset_id
string
⚠ NO DESCRIPTION PROVIDED
- preset_kind
- (optional)
PresetKind
⚠ NO DESCRIPTION PROVIDED
- removable
boolean
⚠ NO DESCRIPTION PROVIDED
- loaded
boolean
⚠ NO DESCRIPTION PROVIDED
#BlockedCounter
How often requests relating to a domain were blocked
Properties:
- domain
string
⚠ NO DESCRIPTION PROVIDED
- ads_blocked
integer
⚠ NO DESCRIPTION PROVIDED
- trackers_blocked
integer
⚠ NO DESCRIPTION PROVIDED
#BlockedUrlsInfo
Information about a blocked URL
Properties:
- url
string
⚠ NO DESCRIPTION PROVIDED
- blocked_count
integer
⚠ NO DESCRIPTION PROVIDED
#TrackerInfo
Information for a given tracker
Properties:
- source_id
integer
The id of the rule source from which this info was obtained.
- info
any
⚠ NO DESCRIPTION PROVIDED
#BlockedTrackersInfo
Information about a blocked tracker
Properties:
- domain
string
⚠ NO DESCRIPTION PROVIDED
- blocked_urls
blocked urls that belong to this tracker
Array
of:- BlockedUrlsInfo
- tracker_info
⚠ NO DESCRIPTION PROVIDED
Array
of:- TrackerInfo
- blocked_count
integer
⚠ NO DESCRIPTION PROVIDED
#TabBlockedUrlsInfo
Information about urls that got blocked, per tab
Properties:
- tab_id
integer
⚠ NO DESCRIPTION PROVIDED
- total_blocked_count
integer
⚠ NO DESCRIPTION PROVIDED
- blocked_trackers_info
blocked urls that belong to a known tracker, alongside with tracker information.
Array
of:- BlockedTrackersInfo
- blocked_urls_info
blocked urls for which there is no tracker information.
Array
of:- BlockedUrlsInfo
#AdAttributionDomain
Information about which domain ad attribution is enabled for, if any, for a given tab
Properties:
- tab_id
integer
⚠ NO DESCRIPTION PROVIDED
- domain
string
⚠ NO DESCRIPTION PROVIDED
- active
boolean
True if the tab is currently on the ad attribution domain, causing ad attribution to be enabled.
#AllowedAdAttributionTrackers
Information about which trackers have been allowed for ad attribution, per tab
Properties:
- tab_id
integer
⚠ NO DESCRIPTION PROVIDED
- tracker_urls
⚠ NO DESCRIPTION PROVIDED
Array
of:- string
#URLPartnerInfo
Information about the URL given - Is it a partner? What name does it have?
Properties:
- status
boolean
⚠ NO DESCRIPTION PROVIDED
- name
string
Name of the partner, or empty if unknown (in which case a generic message should be used)
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onRuleSourceAdded
Fired when a known rule source has been added
Parameters:
- rule_source
RuleSource
⚠ NO DESCRIPTION PROVIDED
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
#onRuleSourceUpdated
The properties of a rule source have been updated, either because a fetch started or completed.
Parameters:
- rule_source
RuleSource
⚠ NO DESCRIPTION PROVIDED
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
#onRuleSourceEnabled
Fired when a known rule source has been enabled
Parameters:
- source_id
integer
⚠ NO DESCRIPTION PROVIDED
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
#onRuleSourceDisabled
Fired when a known rule source has been disabled
Parameters:
- source_id
integer
⚠ NO DESCRIPTION PROVIDED
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
#onRuleSourceRemoved
Fired when a known rule source has been removed
Parameters:
- source_id
integer
⚠ NO DESCRIPTION PROVIDED
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
#onStateChanged
Fired when an exception state has changed.
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
#onExceptionsChanged
Fired when the list of exceptions has changed.
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- exception_list
ExceptionList
⚠ NO DESCRIPTION PROVIDED
#onUrlsBlocked
Fired when urls have been blocked by either the ad-blocker or the tracker-blocker. This is fired at most once per second.
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- tab_ids
⚠ NO DESCRIPTION PROVIDED
Array
of:- integer
#onAdAttributionDomainChanged
Fires when the eTLD+s on which ad attribution is active changes or if the tab is navigated away from that domain.
Parameters:
- tab_id
integer
⚠ NO DESCRIPTION PROVIDED
#onAdAttributionTrackersAllowed
Fired when trackers have been allowed on some tabs, as a result of ad attribution.
Parameters:
- tab_ids
⚠ NO DESCRIPTION PROVIDED
Array
of:- integer
Methods
#addKnownSourceFromURL
Adds an online rule source. Newly added sources are automatically enabled.
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- url
string
⚠ NO DESCRIPTION PROVIDED
- source_settings
- (optional)
RuleSourceSettings
⚠ NO DESCRIPTION PROVIDED
#addKnownSourceFromFile
Adds an local rule source. Newly added sources are automatically enabled.
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- file
string
⚠ NO DESCRIPTION PROVIDED
- source_settings
- (optional)
RuleSourceSettings
⚠ NO DESCRIPTION PROVIDED
#setKnownSourceSettings
Changes the settings used when parsing the rules
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- source_id
integer
⚠ NO DESCRIPTION PROVIDED
- source_settings
RuleSourceSettings
⚠ NO DESCRIPTION PROVIDED
#enableSource
Enables and loads a known rule source
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- source_id
integer
⚠ NO DESCRIPTION PROVIDED
#disableSource
Disables and unloads a known rule source
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- source_id
integer
⚠ NO DESCRIPTION PROVIDED
#fetchSourceNow
Forces fetching of a loaded rule source. Does nothing if a fetch is already in progress
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- source_id
integer
⚠ NO DESCRIPTION PROVIDED
#deleteKnownSource
Remove a known rule source. The source will be disabled before removal.
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- source_id
integer
⚠ NO DESCRIPTION PROVIDED
#resetPresetSources
Re-adds all preset sources that were removed by the user.
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
#getRuleSource
Gets detailed information about a known rule source
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- source_id
integer
⚠ NO DESCRIPTION PROVIDED
#getRuleSources
Gets detailed information about all known rule sources. Loaded sources will have extra information.
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
#setActiveExceptionsList
Sets whether a rule group should use a list of exempted domains or a list of domains to which it applies.
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- state
ExceptionList
⚠ NO DESCRIPTION PROVIDED
#getActiveExceptionsList
Checks whether a rule group is using a list of exempted domains or a list of domains to which it applies
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
#addExceptionForDomain
Adds an item to the exception list
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- exception_list
ExceptionList
⚠ NO DESCRIPTION PROVIDED
- domain
string
⚠ NO DESCRIPTION PROVIDED
#removeExceptionForDomain
Removes an item from the exception list
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- exception_list
ExceptionList
⚠ NO DESCRIPTION PROVIDED
- domain
string
⚠ NO DESCRIPTION PROVIDED
#removeAllExceptions
Removes all domains from the exception list
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- exception_list
ExceptionList
⚠ NO DESCRIPTION PROVIDED
#getExceptions
Retrieves all domains from the exeption list
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- exception_list
ExceptionList
⚠ NO DESCRIPTION PROVIDED
#getAllExceptionLists
Retrieves all the exception lists
#getBlockedUrlsInfo
Retrieves information about which URLs have been blocked from loading in a given tab
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- tab_ids
A list of tabs for which to retrieve blocked urls information.
Array
of:- integer
#getAdBlockingStats
Retrieves the stats for ads and trackers blocked.
#clearAdBlockingStats
Resets ad blocking stats.
#isExemptOfFiltering
Returns whether a page URL will be exempt from filtering by a given rule group, based on the active exception list.
Parameters:
- rule_group
RuleGroup
⚠ NO DESCRIPTION PROVIDED
- url
string
⚠ NO DESCRIPTION PROVIDED
#isExemptByPartnerURL
Returns whether a page URL will be exempt from filtering by a partnership exception.
Parameters:
- url
string
⚠ NO DESCRIPTION PROVIDED
- tab_id
integer
⚠ NO DESCRIPTION PROVIDED
#getAdAttributionDomain
Gets the eTLD+1 for which ad attribution is currently active on the given tabs, if any.
Parameters:
- tab_ids
A list of tabs for which to retrieve the ad attribution stats.
Array
of:- integer
#getAdAttributionAllowedTrackers
Gets the allowed ad attribution trackers for the given tabs, if any.
Parameters:
- tab_ids
A list of tabs for which to retrieve allowed ad attribution trackers.
Array
of:- integer
protonvpn
Types
#Status
An object containg status info for protonvpn.
Properties:
- isLoggedIn
boolean
The user is logged into vivaldi account.
Methods
#getStatus
⚠ NO DESCRIPTION PROVIDED
mailPrivate
Types
#message
Message object. Used to create message in full text database table.
Properties:
- searchListId
integer
⚠ NO DESCRIPTION PROVIDED
- subject
string
The message subject.
- body
string
The message body.
- to
string
The message to address .
- cc
string
The message cc address .
- from
string
The message from address .
- replyTo
string
The message reply address .
#migration
Migration object. Returns search db version and if migration of search db is needed.
Properties:
- dbVersion
integer
The mail search db version.
- migrationNeeded
boolean
If database migration is needed.
#SearchResults
Results object from mail search.
Properties:
- message
string
Error message. If any.
- search_list_ids
Resulting search list ids.
Array
of:- number
- success
boolean
Indicates if error occurred.
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onUpgradeProgress
Reports import progress.
Parameters:
- progress
integer
Number of rows upgraded.
- total
integer
Total number of rows to be upgraded.
- msg
string
Message to be printed out.
#onDeleteMessagesProgress
Reports progress when deleting messages.
Parameters:
- delete_progress_count
integer
Number of messages deleted.
Methods
#getFilePaths
Returns array of file paths under a given directory.
Parameters:
- path
string
The root folder from where to build up the file paths.
#getFullPath
Given a file entry, return full path of the file
Parameters:
- filesystem
string
The file entry to be looked up
- path
string
The path
#getMailFilePaths
Returns array of file paths under the default profile /Mail directory.
#writeTextToMessageFile
Saves a mail to disk. The root folder location is the profile directory of the current running instance /Mail
Parameters:
- paths
String array that is used to create a folder structure, starting at user default profile /Mail The function returns error if empty
Array
of:- string
- fileName
string
The file name to be created/saved/overridden.
- raw
string
The raw mail content.
- append
- (optional)
boolean
Whether to append to file instead of write.
#writeBufferToMessageFile
Saves a mail to disk. The root folder location is the profile directory of the current running instance /Mail
Parameters:
- paths
String array that is used to create a folder structure, starting at user default profile /Mail The function returns error if empty
Array
of:- string
- fileName
string
The file name to be created/saved/overridden.
- raw
binary
The raw mail content as arrayBuffer
- append
- (optional)
boolean
Whether to append to file instead of write.
#deleteMessageFile
Deletes a file. The root folder location is the profile directory of the current running instance /Mail
Parameters:
- paths
String array that is used to build path to the file. Starting at user default profile/Mail.
Array
of:- string
- fileName
string
The file name to be deleted. With ending.
#renameMessageFile
Renames a file. The root folder location is the profile directory of the current running instance /Mail
Parameters:
- paths
String array that is used to build path to the file. Starting at user default profile/Mail.
Array
of:- string
- fileName
string
The file name to be renamed.
- newFileName
string
The new name for the file.
#readFileToBuffer
Reads the contents of a file. Returns the content as arrayBuffer
Parameters:
- fileName
string
Absoloute path to the file to be read.
#readMessageFileToBuffer
Reads a mail. The root folder location is the profile directory of the current running instance /Mail
Parameters:
- paths
String array that is used to build path to the file. Starting at user default profile/Mail.
Array
of:- string
- fileName
string
The file name to be read.
#messageFileExists
Check if file exists.Returns true if the file exists.
Parameters:
- paths
String array that is used to build path to the file. Starting at user default profile/Mail.
Array
of:- string
- fileName
string
The file name to be checked.
#readFileToText
Reads a file. Returns the file content as text.
Parameters:
- path
string
Absoulout path to the file to be read.
#getFileDirectory
Returns the user mail data directory and verfies that the directory exists.
Parameters:
- hashedAccountId
string
First 6 characters from the MD5 hash of the accountId. Appended to the end of the default mail data directory
#createFileDirectory
Creates the user mail data directory.
Parameters:
- hashedAccountId
string
First 6 characters from the MD5 hash of the accountId. Appended to the end of the default mail data directory
#createMessages
Creates messages for full text search.
Parameters:
- messages
⚠ NO DESCRIPTION PROVIDED
Array
of:- message
#deleteMessages
Deletes messages from full text search.
Parameters:
- messages
⚠ NO DESCRIPTION PROVIDED
Array
of:- integer
#updateMessage
Updates a message. All properties needs to be specified both new and previous ones.
Parameters:
- message
message
⚠ NO DESCRIPTION PROVIDED
#searchMessages
Searches messages with certain query.
Parameters:
- searchValue
string
The value to search for
#matchMessage
Does search value match certain message.
Parameters:
- searchListId
integer
The searchListId of the message to be checked.
- searchValue
string
The value to search for
#getDBVersion
Returns SQLite database version for MailDB.
#startMigration
Migrates the full text database index to contentless. Track progress in the listener: onUpgradeProgress. This can be slow.
#deleteMailSearchDB
Deletes MailSearchDB and MaildSearchDB-journal file. Re-creates the files afterwards. This action cannot be reverted.
#checkMailSearchDBHealth
Checks mail search db for errors.
menubar
Types
#Mode
ENUM
What part menubar to manipulate
- all
- update
- tabs
#Edge
ENUM
Defines position of menu items added in chrome code wrt container items.
- above
- below
- off
#ItemType
ENUM
What kind of item.
- command
- checkbox
- radio
- folder
- container
- separator
#MenuItem
One menu item.
Properties:
- name
string
Text in item.
- action
string
Action to execute.
- id
integer
The unique id of item.
- items
- (optional)
Child menu items.
Array
of:- MenuItem
- visible
- (optional)
boolean
Whether this menu item is visible or not. Defaults to true.
- type
- (optional)
ItemType
'normal' or 'checkbox'. Defaults to 'normal'.
- checked
- (optional)
boolean
true if the checkbox is checked, otherwise false. Only applies for type='checkbox'.
- enabled
- (optional)
boolean
false if the item should appear as grayed out. Assumed true if not set.
- withNoWindow
boolean
true if the item should remain normal when no windows are open. If false the item will be grayed out.
- emphasized
- (optional)
boolean
true if the item should appear in an emphasized style (typically bold).
- shortcut
- (optional)
string
String which illustrates a shortcut. The presence of a string will not execute menu action.
- url
- (optional)
string
Url that can be used to determine a corresponding icon.
- parameter
- (optional)
string
Parameter to command. Sent back unaltered.
- index
- (optional)
integer
Index in menu list. Can only be used insert into an existing list.
- edge
- (optional)
Edge
Where to place extra menu items
- icon
- (optional)
string
Icon in PNG format encoded as base64.
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onActivated
Fired when a main menu item is activated.
Parameters:
- window
integer
id of window where command occurred.
- action
string
Action to execute.
- parameter
string
Free format parameter to 'command'. Can be empty.
Methods
#getHasWindows
Returns true if there is one or more windows present in any profile.
#setup
Setup application's main menu.
Parameters:
- items
Menu items with string label.
Array
of:- MenuItem
utilities
Types
#Color
Object defining an RGB color.
Properties:
- red
integer
Red color.
- green
integer
Green color.
- blue
integer
Blue color.
#GetEnvVarsResponse
- GetEnvVarsResponse
object
Object containing valid environment variable values.
Object Properties:
- type
string
#WindowState
ENUM
The state of this browser window.
- normal: Normal window state (i.e. not minimized, maximized, or fullscreen).
- minimized: Minimized window state.
- maximized: Maximized window state.
- fullscreen: Fullscreen window state.
#WindowType
ENUM
Type of window. normal is a browser-window.
- normal
- popup
- settings
#WindowRestoreState
ENUM
State of window after going out of fullscreen.
- normal
- minimized
- maximized
#WindowRestoreStateFromFullscreen
ENUM
State of window after going out of html-fullscreen.
- normal
- minimized
- maximized
- fullscreen
#StatusbarMode
ENUM
Statusbar view setting. 'on' | 'off' | 'overlay' (StatusBarDisplayValues from gen/prefs/prefNames.js)
- on
- off
- overlay
#WindowProperties
Type WindowState in ./stores/WindowStore.js
Properties:
- type
WindowType
⚠ NO DESCRIPTION PROVIDED
- state
- (optional)
WindowState
⚠ NO DESCRIPTION PROVIDED
- restoreStateFullscreen
WindowRestoreState
⚠ NO DESCRIPTION PROVIDED
- restoreStateHtml5Fullscreen
WindowRestoreStateFromFullscreen
⚠ NO DESCRIPTION PROVIDED
- nativeDecorations
boolean
Window is uses native window-controls.
- incognito
boolean
Window is incognito.
- guest
boolean
Window is guest.
- html5FullScreen
boolean
Window is fullscreened through htmlelement.requestFullScreen.
- active
boolean
Window is active.
- minimalUI
- (optional)
boolean
Window is incognito.
- visibleUI
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- bookmarksBar
boolean
Showing bookmarksbar.
- addressBar
boolean
Showing addressbar.
- panelToggle
boolean
Showing panel-toggle.
- tabs
boolean
Showing tabs.
- statusBar
StatusbarMode
⚠ NO DESCRIPTION PROVIDED
#BroadcastAction
Identifies broadcast type. Only one property should be used.
Properties:
- startDragging
- (optional)
boolean
⚠ NO DESCRIPTION PROVIDED
- endDragging
- (optional)
boolean
⚠ NO DESCRIPTION PROVIDED
- translate
- (optional)
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- winId
number
The window where translation takes place.
- lang
string
Language of text to be translated.
- text
string
Text to be translated.
#DialogName
ENUM
Name of the dialog to set position for.
- chromecast: The Chromecast dialog with source and destination. Centered over the active webview.
- password: The password dialog opening to save a password.
- permission: The permission dialog allowing or blocking one or more permissions.
#CookieMode
ENUM
CookieMode enumeration, corresponds to CookieControlsMode in chromium/components/content_settings/core/browser/cookie_settings.h
- off: All cookies allowed.
- BlockThirdParty: Block third party cookies.
- BlockThirdPartyIncognitoOnly: Block third party cookies in incognito mode only.
#FlowDirection
ENUM
The direction a dialog would be opened from the given rect.
- down: Dialog should position itself below the given rect.
- up: Dialog should position itself above the given rect.
#UrlValidResults
Object that describes the validitity of a given url.
Properties:
- urlValid
boolean
The url is a correctly formatted url. This might be true even if the protocol is not valid.
- isBrowserUrl
boolean
The url can be shown directly by the browser.
- schemeParsed
string
The parsed and authorative protocol scheme as parsed by Chromium.
- normalizedUrl
string
Returns the raw spec, i.e., the full text of the URL, in canonical UTF-8, if the URL is valid.
#WhatsNewResults
Object that describes how a What's new page can be used.
Properties:
- show
boolean
true if the What's new page can be shown, otherwise false.
- firstrun
boolean
true if this the first time the Whats new page is shown. Do not use if 'show' is false.
#UrlFragments
Object with url fragments, including top level domain which is eTLD aware.
Properties:
- scheme
- (optional)
string
If URL cannot be parsed at all, this will be absent
- username
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- password
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- host
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- port
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- path
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- query
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- ref
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- tld
- (optional)
string
⚠ NO DESCRIPTION PROVIDED
- urlForSecurityDisplay
- (optional)
string
URL formatted for security display, meaning formatted in unicode in a way to avoid IDN homograph attack.
- tldForSecurityDisplay
- (optional)
string
TLD for security display
- hostForSecurityDisplay
- (optional)
string
Host for security display
- pathForSecurityDisplay
- (optional)
string
Path for security display
- queryForSecurityDisplay
- (optional)
string
Query for security display
- refForSecurityDisplay
- (optional)
string
ref for security display
#FileExtension
A single extension item used for filtering
Properties:
- ext
string
Extension ending, eg. 'jpg'
#SelectFileDialogType
ENUM
The type of selectfile dialog to show.
- file: This is a file select dialog.
- save_file: This is a file select dialog, allowing to choose a nonexistent file for saving.
- folder: This is a folder select dialog.
#SelectFileOptions
Option object for selectFile.
Properties:
- windowId
integer
Id of the window to show the file selection dialog against.
- title
string
Title of the file select dialog.
- type
SelectFileDialogType
Type of file select dialog, defaults to 'file'.
- accepts
- (optional)
Extensions to filter file names on.
Array
of:- FileExtension
- defaultPath
- (optional)
string
The file's default path and name.
#SelectLocalImageParams
Option object for selectLocalImage.
Properties:
- windowId
integer
Id of the window to show the file selection dialog against.
- title
string
Title for the file selection dialog.
- profileImage
- (optional)
boolean
Store the image path as the path for a custom profile avatar.
- themeId
- (optional)
string
The id of theme to store the background image in.
- thumbnailBookmarkId
- (optional)
string
The bookmark id where to store the selected local path.
#StoreImageOptions
Option object for storeImage.
Properties:
- url
- (optional)
string
The URL to read the data from. Currently only the file URL is supported.
- data
- (optional)
binary
The image data.
- mimeType
- (optional)
string
The type of the image.
- themeId
- (optional)
string
The id of theme to store the image as theme background.
#SharedDataValue
Data key+value pair.
Properties:
- key
string
The data key.
- value
any
The data value.
#DateFormats
An object containing various system date/time formats
Properties:
- shortDateFormat
string
Short date format.
- longDateFormat
string
Long date format.
- timeFormat
string
12/24 hour time format string
- firstDayOfWeek
number
The first day of the week. 0-6 (Sunday to Saturday)
#CaptureQRDestination
ENUM
Where to store the generated QR code
- dataurl: Store as a returned data url.
- file: Store in the download location.
- clipboard: Store in the clipboard
#GetVersionResults
⚠ NO DESCRIPTION PROVIDED
Properties:
- vivaldiVersion
string
The Vivaldi version as a string.
- chromiumVersion
string
The Chromium version as a string.
#TranslateError
ENUM
The error messages translate can return.
- no_error
- network
- unknown_language
- unsupported_language
- timeout
- error
#TranslateTextResponse
⚠ NO DESCRIPTION PROVIDED
Properties:
- error
TranslateError
⚠ NO DESCRIPTION PROVIDED
- detectedSourceLanguage
string
Language code of the detected language code of the provided source text, if any.
- sourceText
The original source strings.
Array
of:- string
- translatedText
The translated text corresponding to the given sourceText.
Array
of:- string
#ReadImageData
An object that defines the data read from the image file.
Properties:
- data
Read image as raw bytes.
Array
of:- integer
- type
string
Mime type of the read image.
#VivaldiService
ENUM
Name of service
- sync
#VivaldiStatus
ENUM
The states of a remote service
- operational: Up an running.
- maintenance: Down for maintenance.
- minoroutage: Down for a minor problem.
- majoroutage: Down for a major problem.
#VivaldiServiceState
The actual state of a remote service
Properties:
- service
VivaldiService
⚠ NO DESCRIPTION PROVIDED
- status
VivaldiStatus
⚠ NO DESCRIPTION PROVIDED
#ExtensionInstallResult
An object holding result of extension installation request.
Properties:
- success
boolean
⚠ NO DESCRIPTION PROVIDED
- error
string
Installation error description, in case installation failed.
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onScroll
Fires for Mac when scroll device changes.
Parameters:
- scrollType
integer
Device that triggers scrolling. 1: Mouse, 2: Trackpad 3: Inertial
#onDialogCanceled
Called when the javascript dialog was canceled.
#onSharedDataUpdated
Fires when a shared data value has changed or been added.
Parameters:
- key
string
Name of the key for the value.
- value
any
The new value for the key.
#onSuspend
Fired when the computer is about to suspend.
#onResume
Fired when the computer has resumed from suspension.
#onPasswordIconStatusChanged
Fires for password icon status change.
Parameters:
- windowId
integer
Window id to show/hide icon for
- show
boolean
Whether to show or hide icon
#onDownloadManagerReady
Fired when the download manager has loaded all its data.
#onRazerChromaReady
Fired when the Razer Chroma API has been initialized.
#onTopSitesChanged
Fired when topsites list has changed.
#onBroadcastMessage
Test.
Parameters:
- message
BroadcastAction
The message to receive.
#onShowQRCode
Fired when Chromium wants us to show a QR code for the given url.
Parameters:
- url
string
The url to show the QR code for.
#onSessionRecoveryStart
Fired when the session recovery starts.
#onSessionRecoveryDone
Fired when the session recovery is done.
#onVivaldiSyncStatusUpdated
Fired when backend has received information of Vivaldi sync service.
Parameters:
- mode
VivaldiStatus
The state of the remote service.
Methods
Open print preview dialog.
Parameters:
- windowId
integer
WindowId of browser printing active tab.
#clearCache
Clears browser cache.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
#clearAllRecentlyClosedSessions
Clears the list of recently closed tabs and/or windows.
#clearRecentlyClosedTabs
Clears one or more recently closed tabs.
Parameters:
- ids
⚠ NO DESCRIPTION PROVIDED
Array
of:- string
#isTabInLastSession
Checks whether a given tab is part of the last loaded session
Parameters:
- tabId
integer
The tab id to check if part of the session
#isUrlValid
Validates given URL. Returns UrlValidResults with the results.
Parameters:
- url
string
The URL to validate
#canOpenUrlExternally
Check if the browser can potentially open the URL using an external application or an extension. This should only be called if it is already known that the URL is a valid one and is not handled by the browser directly to get a valid result.
Parameters:
- url
string
The URL to check
#getUrlFragments
Splits given URL. Returns UrlFragments including top level domain which is eTLD aware.
Parameters:
- url
string
The URL to process.
#urlToThumbnailText
Gets the text for a fallback speeddial thumbnail
Parameters:
- url
string
The URL to get the text from.
#getSelectedText
Returns selected text in page with given id
Parameters:
- tabId
integer
The page to examine
#selectFile
Select a single file and returns the file name.
Parameters:
- options
SelectFileOptions
⚠ NO DESCRIPTION PROVIDED
#selectLocalImage
Ask the user to select an image file and store its path as a data mapping URL in a bookmark or a preference.
Parameters:
- params
SelectLocalImageParams
⚠ NO DESCRIPTION PROVIDED
#cleanUnusedImages
Cleans unused images (thumbnails)
Parameters:
- createdBefore
integer
Run only if createdBefore <= the number of the images created sinct the last cleanup.
#storeImage
Save image from the memory blob to the image store and return related chrome:// URL.
Parameters:
- options
StoreImageOptions
⚠ NO DESCRIPTION PROVIDED
#getVersion
Gets the Vivaldi version and Chromium versions.
#getEnvVars
Gathers values of environment variables specified in the first argument, returns a list of pairs containing keys and values (or none in case the variable does not exist)
Parameters:
- keys
list of names of environment variables
Array
of:- string
#getMediaAvailableState
Windows: Returns whether this version of the OS has media codecs installed. Might return false on N versions of Windows.
#setSharedData
Sets the given data to be kept in-memory for the duration of the Vivaldi setting (until Vivaldi exits).
Parameters:
- keyValuePair
SharedDataValue
The Key-value.
#getSharedData
Gets the given data from the in-memory storage.
Parameters:
- keyValuePair
SharedDataValue
The Key-value, the value is the default value returned if the key does not exist.
#takeMutex
Uses the in-memory storage to synchronize access to a resource accross several vivaldi extension processes (until Vivaldi exits).
Parameters:
- name
string
A name uniquely identifying the mutex.
- wait
- (optional)
boolean
Whether to wait for the mutex to be available or to to throw an error if it isn't. Defaults to true.
#releaseMutex
Relinquish use of a mutex obtained in takeSharedMutex.
Parameters:
- handle
any
The handle to the mutex, returned from takeSharedMutex.
#getSystemDateFormat
Returns various date/time system formats
#getSystemCountry
Return the system settings for the country if available.
#setLanguage
Sets the Vivaldi language code.
Parameters:
- locale
string
⚠ NO DESCRIPTION PROVIDED
#getLanguage
Gets the active Vivaldi language code.
#setVivaldiAsDefaultBrowser
Set Vivaldi as the default browser.
#isVivaldiDefaultBrowser
Is Vivaldi the default browser.
#launchNetworkSettings
Launch network settings.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
#savePage
Saves web page.
Parameters:
- tabId
integer
Id to of page being saved.
#openPage
Open web page.
Parameters:
- windowId
integer
WindowId of browser opening a local file.
#broadcastMessage
Broadcast a message to all windows. Works from regular to private windows as well.
Parameters:
- message
BroadcastAction
The message to send.
#setDefaultContentSettings
Set Vivaldi default content settings.
Parameters:
- contentSetting
string
⚠ NO DESCRIPTION PROVIDED
- value
string
⚠ NO DESCRIPTION PROVIDED
#getDefaultContentSettings
Set Vivaldi default content settings.
Parameters:
- contentSetting
string
⚠ NO DESCRIPTION PROVIDED
#setBlockThirdPartyCookies
Set Vivaldi default content settings.
Parameters:
- cookieMode
CookieMode
Cookie control for third party cookies.
#getBlockThirdPartyCookies
Set Vivaldi default content settings.
#openTaskManager
Opens Vivaldi task manager dialog.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
#createQRCode
Opens the QR Code bubble window for the given page.
Parameters:
- id
integer
The id of the page.
#getStartupAction
Returns the startup action.
#setStartupAction
Returns the startup action.
Parameters:
- startup
string
⚠ NO DESCRIPTION PROVIDED
- urls
⚠ NO DESCRIPTION PROVIDED
Array
of:- string
#canShowWhatsNewPage
Checks whether showing the What's new page is allowed.
#showPasswordDialog
Shows password manage dialog.
Parameters:
- windowId
integer
The window id the dialog belongs to.
#setDialogPosition
Sets the opening position for the given Chromium-triggered dialog.
Parameters:
- dialogName
DialogName
The window to set the position for.
- windowId
integer
The window id the dialog belongs to.
- position
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- left
integer
Anchor left position in client coordinates.
- top
integer
Anchor top position in client coordinates.
- width
integer
Anchor width.
- height
integer
Anchor height.
- flowDirection
FlowDirection
The direction the dialog should be positioned based on the rect.
#isRazerChromaAvailable
Is the Razer Chroma API available.
#isRazerChromaReady
Is the Razer Chroma API initialized and ready to accept commands.
#setRazerChromaColor
Set the color(s) for the configured Razer Chroma lights.
Parameters:
- colors
⚠ NO DESCRIPTION PROVIDED
Array
of:- Color
- Array of colors to be set for the configured lights. If multiple colors are set, it will cycle quickly between them from the first to the last.
#isDownloadManagerReady
Checks whether the download manager has initialized. If not, register for the onDownloadManagerReady event to be notified when it's ready.
#setContentSettings
Set a contentsetting for a pattern .
Parameters:
- details
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- primaryPattern
string
The pattern for the primary URL. For details on the format of a pattern, see Content Setting Patterns.
- secondaryPattern
- (optional)
string
The pattern for the secondary URL. Defaults to matching all URLs. For details on the format of a pattern, see Content Setting Patterns.
- type
string
The resource identifier for the content type.
- value
string
The setting applied by this rule. See the description of the individual ContentSetting objects for the possible values.
- incognito
- (optional)
boolean
Where to set the setting (default: regular).
#isDialogOpen
Checks whether the given native dialog is open.
Parameters:
- dialogName
DialogName
Dialog name to check for visibility.
#focusDialog
Focus the named dialog so keyboard navigation within it is available.
Parameters:
- dialogName
DialogName
Dialog name to check for visibility.
#startChromecast
Shows the Chromecast dialog.
Parameters:
- windowId
integer
Window id where casting should start.
#generateQRCode
Generate a QR image based on the given data.
Parameters:
- data
string
Data to encode in the QR code. The maximum length of the data is 288 bytes.
- destination
- (optional)
CaptureQRDestination
Destination of the QR capture, defaults to 'dataurl'.
#getGAPIKey
Returns G API key.
#getVivaldiNetOAuthClientSecret
Returns Vivaldi.net OAuth client secret.
#getVivaldiNetOAuthClientId
Returns Vivaldi.net OAuth client id.
#getGOAuthClientId
Returns G OAuth API client id.
#getGOAuthClientSecret
Returns G OAuth API client secret.
#getMOAuthClientId
Returns MS OAuth API client id.
#getYOAuthClientId
Returns Yahoo OAuth client id.
#getYOAuthClientSecret
Returns Yahoo OAuth client secret.
#getFOAuthClientId
Returns Fastmail OAuth client id.
#getAOLOAuthClientId
Returns AOL OAuth client id.
#getAOLOAuthClientSecret
Returns AOL OAuth client secret.
#getOSGeolocationState
Gets the state of OS geolocation.
#openOSGeolocationSettings
Makes the OS geolocation settings visible to the user.
#getCommandLineValue
Gets the command line value for the given named argument.
Parameters:
- value
string
Name of the command line switch without initial dashes eg. translate-server-url.
#hasCommandLineSwitch
Check if the command line has switch present for the given argument.
Parameters:
- value
string
Name of the command line switch without initial dashes eg. translate-server-url.
#osCrypt
⚠ NO DESCRIPTION PROVIDED
Parameters:
- plain
string
The content to encrypt
#osDecrypt
⚠ NO DESCRIPTION PROVIDED
Parameters:
- encrypted
string
The content to decrypt
#translateText
⚠ NO DESCRIPTION PROVIDED
Parameters:
- sourceLanguageCode
string
The language code of the source text, or empty if you want the server to try to detect the language.
- destinationLanguageCode
string
The destination language code.
- sourceText
The strings to translate.
Array
of:- string
#showManageSSLCertificates
Show the OS manage certificates dialog.
Parameters:
- windowId
integer
The window to use as parent window for the dialog
#setProtocolHandling
Turn on/off protocol handling for web pages.
Parameters:
- enabled
boolean
Turn on/off protocol handling for web pages.
#browserWindowReady
Signals that JS has fully set up browser window and its event listeners.
Parameters:
- windowId
number
⚠ NO DESCRIPTION PROVIDED
#readImage
Reads an image file from the file system from the specified URL to the object.
Parameters:
- url
string
⚠ NO DESCRIPTION PROVIDED
#isRTL
Checks if current locale Right-To-Left locale.
#emulateUserInput
Notifies render there has been user driven input. To be used when normal input is not detected in render because of blocking event loop handling (eg when menus are open).
Parameters:
- windowId
number
⚠ NO DESCRIPTION PROVIDED
#isVivaldiPinnedToLaunchBar
Check is Vivaldi pinned to the launch bar. If pinning is not available, throws an Error.
#pinVivaldiToLaunchBar
Pin Vivaldi icon to the launch bar.
#downloadsDrag
Start a native drag for the downloads items.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- downloadIds
Array of IDs of the download items to initiate the drag.
Array
of:- integer
#acknowledgeCrashedSession
Must be called in the post crash browser launch. It can either restore crashed session, or just acknowledge the crash.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- restoreSession
boolean
⚠ NO DESCRIPTION PROVIDED
- reenableExtensions
boolean
⚠ NO DESCRIPTION PROVIDED
#silentlyInstallExtension
Handles silent installation of an extension, disabled after install, given it's id.
Parameters:
- id
string
⚠ NO DESCRIPTION PROVIDED
#allowVPNIncognito
A single-purpose call that grants incognito access to ProtonVPN extension.
#requestVivaldiSyncStatus
Looks up status. Status can be returned in callback, but if not, arrive later as an onVivaldiSyncStatusChange event.
#openPrivacyReportDialog
Opens privacy report dialog
#updatePrimarySelection
Writes text to the primary selection buffer. This buffer is only used on Linux and allows pasting with middle mouse button.
Parameters:
- text
string
⚠ NO DESCRIPTION PROVIDED
pipPrivate
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onVideoElementCreated
Fired when a video element has been created.
Parameters:
- tabId
integer
Tab id for the video element created event.
windowPrivate
Types
#WindowState
ENUM
The state of this browser window.
- normal: Normal window state (i.e. not minimized, maximized, or fullscreen).
- minimized: Minimized window state.
- maximized: Maximized window state.
- fullscreen: Fullscreen window state.
#CreateWindowOptions
Object passed to the |create| function.
Properties:
- bounds
- (optional)
object
⚠ NO DESCRIPTION PROVIDED
Object Properties:
- left
- (optional)
integer
⚠ NO DESCRIPTION PROVIDED
- top
- (optional)
integer
⚠ NO DESCRIPTION PROVIDED
- width
integer
⚠ NO DESCRIPTION PROVIDED
- height
integer
⚠ NO DESCRIPTION PROVIDED
- minWidth
- (optional)
integer
⚠ NO DESCRIPTION PROVIDED
- minHeight
- (optional)
integer
⚠ NO DESCRIPTION PROVIDED
- windowDecoration
- (optional)
boolean
Enable window decoration. Defaults to false.
- incognito
- (optional)
boolean
Incogito window. Default is false.
- focused
- (optional)
boolean
If true, opens a active window. Default is true.
- state
- (optional)
WindowState
The state to set the window to. Default is normal window state (i.e. not minimized, maximized, or fullscreen).
- tabUrl
- (optional)
string
The url to be added as a new tab, this will be added to the tab model. Not used for settings, popups, etc.
- vivExtData
- (optional)
string
Extra data to attach to the window.
- windowKey
- (optional)
string
Id to identify the window. If a window with a given id is created while another window with the same id already exists, the currently opened window will be focused instead of creating a new window.
#WindowType
ENUM
The type of this browser window.
- normal: This is a normal browser window.
- settings: This is a settings window.
- popup: This is a popup window.
- devtools: This is a devtools window.
#FocusedElementInfo
Information about the HTML element having focus.
Properties:
- tagName
string
Element tag name
- type
string
Element type
- editable
boolean
True if element is editable.
- role
string
Element role
#ControlButtonsPadding
ENUM
The padding type used for drawing control buttons (macOS only)
- native: ⚠ NO DESCRIPTION PROVIDED
- lightPadding: ⚠ NO DESCRIPTION PROVIDED
- mediumPadding: ⚠ NO DESCRIPTION PROVIDED
- heavyPadding: ⚠ NO DESCRIPTION PROVIDED
#ToastParameters
Parameters used to create a toast notification, typically showed as an overlay above the browser window.
Properties:
- body
string
Message to present.
- action
- (optional)
string
If an action button is needed, this is the buttone text.
- image
string
Image to show as base64 encoded.
Listeners
How to use listeners
Each listener type has the same functions, used for each listener API in the same way:
.addListener(function
callback)
Adds a function to a listener for an event
.removeListener(function
callback)
Removes a function to a listener for an event
.hasListener(function
callback)
Returns a boolean if a function is attached to a listener for an event
.hasListeners()
Returns a boolean if a listener has any attached functions
.dispatch()
Returns array of promises dispatched to the listener
#onWindowDidChangeScreens
Fired when the window has changed screens include a parameter that says whether the new screen has a notch.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- hasNotch
boolean
Screen has a notch (true) or without notch (false).
#onStateChanged
Fired when the window state changes (minimize/maximize/fullscreen).
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- state
WindowState
The new state set to the window.
#onPositionChanged
Fired when the window changes position.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
#onActivated
Fired when the window changes activation.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- activated
boolean
Changed activation state.
#onBeforeUnloadDialogOpened
Fired when a beforeunload dialog is shown for a tab.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- tabId
integer
⚠ NO DESCRIPTION PROVIDED
#onWindowClosed
Fired when a window is closed, even for guest windows.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
#onPageInfoPopupChanged
Fired when a page information popup visibility changes.
Parameters:
- windowId
integer
⚠ NO DESCRIPTION PROVIDED
- visible
boolean
⚠ NO DESCRIPTION PROVIDED
#onActiveTabStatusText
Fired when the active tab has new loadstate text. Will reset to Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Fired when the webcontents has a window object. chrome.windows.getviews find this now. Parameters: ⚠ NO DESCRIPTION PROVIDED Fire . Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Create a window with additional Vivaldi specific properties. Parameters: Url to page to show as the full window UI of the new window. ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Returns the window id of the window we are currently running inside. Sets the window state. Parameters: The window id of the window to change the state for. The state to set the window to. Notify C++ about the position of the maximize button to show extra native GUI like the split window menu in Windows 11. Parameters: The window id of the window to update the coordinates of the maximize button. ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Get information about currently focused element in Vivaldi window or any of its webviews. Parameters: ⚠ NO DESCRIPTION PROVIDED Returns true if the screen the window is on has a notch. Parameters: ⚠ NO DESCRIPTION PROVIDED Request a new control buttons position. Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Performs a haptic feedback. Defines supported nodes Defines menu type. Defines container layouts. Defines on what edge of a container additional items can be added. A node (folder or menu entry) in the menu tree. Child nodes are ordered within their parent folder. Properties: Unique identifier. The kind of node. A command or a menu identifier. It does not have to be unique. Can be empty for separators. When true, the item has been added by the user. Node title. If not present the title is determined using the action. Show shortcut string. Mandatory for radio elements. Mandatory for container elements. Mandatory for container elements. Free form parameter. Format varies with action. An ordered list of children of this node. Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fires when the content of a menu has changed. Parameters: Menu resource name. Unique identifier for menu. Describes the role of menu. If non-negative this id can be used to set selected element. ⚠ NO DESCRIPTION PROVIDED Fires when the entire menu tree is reset. Parameters: True for a context menu tree, false for a main menu tree. Retrieves content of a menu. Parameters: Menu resource name. Moves one or more items within a menu. Parameters: Menu resource name. ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Add one or more items within a menu. Parameters: Menu resource name. ⚠ NO DESCRIPTION PROVIDED Where to add elements. A negative value means at end. ⚠ NO DESCRIPTION PROVIDED Deletes one or more items within a menu. Parameters: Menu resource name. ⚠ NO DESCRIPTION PROVIDED Deletes one or more actions from all models Parameters: ⚠ NO DESCRIPTION PROVIDED Updates the properties of a node. Parameters: Menu resource name. ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Object Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Restores default content within a menu or in a submenu of that menu. Parameters: Menu resource name. ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Restores default content for all menus (either context or main menus). Parameters: ⚠ NO DESCRIPTION PROVIDED The category in which the item belong. ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED An object encapsulating one result of a omnibox query. Properties: Is allowed to be default match. The main text displayed in the address bar dropdown. The destination url The text to fill into edit. Matches open tab. The relevance score. The provider name. The transition type to use when the user opens this match. Helper text, such as a title, description or search. The inline autocompletion to display after the user's input in the omnibox, if this match becomes the default match. It may be empty. The category in which the item belong. Should the user be able to delete this match. Same as AutocompleteMatch::Type. Used by AddOrUpdateShortcut. The url of the favicon. How to load the favicon. This is used by Favicon component. Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fired when omnibox results are ready. Parameters: ⚠ NO DESCRIPTION PROVIDED Object Properties: ⚠ NO DESCRIPTION PROVIDED User-provided text to be completed. No more events for query will follow. Parameters: ⚠ NO DESCRIPTION PROVIDED Object Properties: A piece of text entered in Omnibox Prevent inline autocomplete Don't reuse previous results from slow providers while waiting for their new results. If true, the query originated from search field. Limiting the number of providers run Contains the GUID of the search engine. If no search engine was specified, string will be empty Specify the UI interaction that started autocomplete. ZeroSuggestion is only activated on specific focus The type of page the user was on when they used the omnibox. Or the type of page for which suggestions were prefetched from the server Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Properties: Parameters: ⚠ NO DESCRIPTION PROVIDED Properties: Language code. Text. Properties: Unique identifier. Text and language code of original (non-translated) data. Text and language code of translated data. Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fires when elements have been appended to the list. Parameters: Elements in the order they have been added Index where the elements are located. Fires when an element has been moved within the list. Parameters: Identifier of element that has been moved. Index to where element has been moved. Fires when elements have been appended to the list. Parameters: A list of ids that have been removed. An empty list means all. Retrieves the full history. Adds an item to the list. If item already exists that item is returned without adding a duplicate. The returned item's id it set up in the call. Parameters: Data to add. Note, the id element is ignored. Where to add element. -1 indicates end of list. Removes one or more items. Parameters: List of identifiers representing items to be removed. Removes items with matching timestamp. Parameters: In milliseconds since epoch. Remove all items with a timestamp greater or equal to this value. browser- or pageAction. Regular extension- or componentAction. Component actions will go through ToolbarActionViewController What type of menu item. Type of global error. Disabled because of permission increase, or installed by third-party. Menu item representing a single menu item. Properties: The name of the item as shown in the menu. The id for the item. Is the item enabled. Is the item visible. Is the item checked. ⚠ NO DESCRIPTION PROVIDED Sub menu items if the extension supplies a custom menu. Side Panel description (if exists). Properties: Side Panel URL. Side Panel URL. ⚠ NO DESCRIPTION PROVIDED Properties: If specified, the side panel options will only apply to the tab with this id. If omitted, these options set the default behavior (used for any tab that doesn't have specific settings). Note: if the same path is set for this tabId and the default tabId, then the panel for this tabId will be a different instance than the panel for the default tabId. The path to the side panel HTML file to use. This must be a local resource within the extension package. The path to the side panel HTML file to use. This must be a local resource within the extension package. The path to the side panel HTML file to use. This must be a local resource within the extension package. Whether the side panel should be enabled. This is optional. The default value is true. Extension action per tab id. Properties: tab id, or kDefaultTabId(-1) if the information should be used for all tabs. The unique extension identifier. Tooltip for the button. Badgetext, typically room for four chars. data-url for the current icon. Text color for the badge text, currently unused. Background color for the badge text. Whether the extension is enabled or not. The type of the extensionAction, either pageaction or browseraction. Visibility of the action button, defaults to true. Whether the action is available in incognito windows or not. The type of the extensionAction, either pageaction or browseraction. Defaults to |extensionAction|. Name of extension. Homepage of extension. Address of extension options page. false if the options page should be opened embedded, true if it opens in a new tab. Keyboard shortcut to toggle this extension. contains sidepanel URL. Whether the extension is blocked or not. Extension error. Properties: The unique extension identifier. Extension name. The type of the extensionAction, either pageaction or browseraction. Defaults to |extensionAction|. Int id to lookup an error on action. Describes action when the extension button is clicked Properties: Related extensionId relative url for the popup document if exists. openPanelOnActionClick value set by chrome.sidePanel.setPanelBehavior Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fired when an extension has been loaded. Parameters: ⚠ NO DESCRIPTION PROVIDED Fired when an extension has been unloaded. Parameters: ⚠ NO DESCRIPTION PROVIDED Fired when an extensionAction is changed. Parameters: ⚠ NO DESCRIPTION PROVIDED Fired on ExtensionAction::ClearAllValuesForTab(). Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Fired when a keyboard shortcut is added to an extension. Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Fired when a keyboard shortcut is removed from an extension. Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Fired when an extensionerror is created. Can be of various kinds of GlobalErrors Parameters: ⚠ NO DESCRIPTION PROVIDED Fired when an extensionerror is handled or removed. Can be of various kinds of GlobalErrors. Parameters: ⚠ NO DESCRIPTION PROVIDED Fired when side panel opetion changed Parameters: The unique extension identifier. ⚠ NO DESCRIPTION PROVIDED Fired when side panel action requested Parameters: The unique extension identifier. The unique action identifier. execute browserAction or pageAction for extension Parameters: id of the application window. Removes a specified extension. Parameters: The id for the extension we want to remove. id of the application window. Used to find the Browser object. Shows options for the given extension Parameters: The id for the extension we want to remove. id of the application window. Used to find the Browser object. Gets the context menu for the given extension Parameters: The id for the extension we want to get the menu for. Execute menu action for extension. Parameters: id of the application window. id of the menu item. Show the dialog for an extension install error. Parameters: The id for the error. id of the application window. Used to find the Browser object. Loop through any pending global extension errors and fire events for the ui. Object passed to the update and returned in the get function. Properties: The url of the entry. This is also the unique key. The title of the entry. Has entry been read. Last updated in micro seconds since Jan 1st 1970. Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fired when the reading list data model has changed.
Add a new entry to the reading list. Parameters: The url of the entry. This is also the unique key. Only http/https urls are supported. The title of the entry. Remove an entry from the reading list. Parameters: The url of the entry. Returns all reading list entries. Sets the read status on a url. Parameters: url to set read status on. true for read, false for unread. Ids for a set of folders. Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Object passed to the updateSpeedDialsForWindowsJumplist function. Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Copied from bookmarks.json Properties: The unique identifier for the node. IDs are unique within the current profile, and they remain valid even after the browser is restarted. The The 0-based position of this node within its parent folder. The URL navigated to when a user clicks the bookmark. Omitted for folders. The destination URL when a user clicks the bookmark. Omitted for folders. The text displayed for the node. The nickname for the node. Vivaldi extended property The description text for the node. Vivaldi extended property chrome://thumb/ Partner id for the node. Vivaldi extended property Boolean variable, stating if a folder is a speeddial folder The theme color from the website, to use as the background of the speed dials thumbnail, if no other thumbnail is available Boolean variable, stating if a folder is a bookmark bar folder true if this is the trash folder. Read only. When this node was created, in milliseconds since the epoch ( When the contents of this folder last changed, in milliseconds since the epoch. If present this url should be used to retrive a favicon. An ordered list of children of this node. Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fired when a favicon changes. Parameters: Bookmark id The favicon's url Fired when meta info changes. Parameters: Bookmark id ⚠ NO DESCRIPTION PROVIDED Object Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Update the speed dial list in Windows 7+ jumplist. Parameters: ⚠ NO DESCRIPTION PROVIDED Empty the bookmarks trash folder. Update default bookmarks Check if the bookmark has a custom thumbnail from a local file or resource. Parameters: the id of the bookmark Returns ids of top level folders. Exports bookmarks to a Chrome html bookmark file Parameters: The file selector will be modal to this window. Defines content of a container. Defines how to sort container items. Defines what element to use as sort key. Defines position of menu items added in chrome code wrt container items. What kind of item. Position and size of element in menu bar. Properties: Left position of item that opens menu, screen coordinates. Top position of item that opens menu, screen coordinates. Width of item that opens menu. Height of item that opens menu. Icons encoded as base64. One menu item. Properties: The unique id of item. Text in item. Defaults to 'normal'. Whether item is initially selected. Default to false. Whether item is enabled or not (grayed out) . Defaults to true. Whether item is visible or not. Defaults to true. true if the checkbox is checked. Ignored unless type is 'checkbox' or 'radiobutton'. The radiobutton group this item belongs to. Must be present for a radio button. If true the menu item will remain open after menu item is clicked with mouse. Shortcut to be displayed next to label. Url that can be used to determine a corresponding icon. Icons for light and dark menus. There must be two icons and the last shall be for menus with a dark background. One separator Properties: Text in item. A collection of items set up and expanded from chrome. Properties: Parent id of data to display. What kind of data to expand in this container. Offset into folder/parent data. If sorted, this flag will group any subfolders together. Where to place extra menu items Sort key for elements. Sort order for elements. One element in menu. All optional, but one and only one of 'item', 'separator' or 'container' should be set. 'children' is only considered when 'item' is set. Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Child menu items. One menu with origin rect and a list if children. Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Describes keyboard modifiers and mouse button state. Properties: true if the Ctrl key is pressed when activating the menu. true if the Shift key is pressed when activating the menu. true if the Alt key is pressed when activating the menu. true if the Command key (Mac) is pressed when activating the menu. true if the left mouse button activated the menu. true if the right mouse button activated the menu. true if the center mouse button activated the menu. Defines where a bookmark should be opened. Defines a non-navigation bookmark action. Passed with bookmark activation Properties: ⚠ NO DESCRIPTION PROVIDED If set, disposition and background is ignored. ⚠ NO DESCRIPTION PROVIDED Extends disposition with a background option. ⚠ NO DESCRIPTION PROVIDED Passed with menu activation. Properties: Command id. ⚠ NO DESCRIPTION PROVIDED Menu not closing if true, update item. Passed with menu update request. Properties: Command id. Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fires before menu opens. Parameters: Menu id of the menu that opens. Fires before menu closes. Fired when menu item is activated. Parameters: What action to execute. Fired when bookmark menu item is activated. Parameters: Window where action occurs. ⚠ NO DESCRIPTION PROVIDED Fired when bookmark command is activated. Parameters: Window where action occurs. ⚠ NO DESCRIPTION PROVIDED Fired when a menu item with a url is highlighted. Parameters: Window where hover occurs. Url in menu item. Fired if an error condtion occurs that can not be routed with a callback. Parameters: Error message for logging purposes. Shows a context menu. Parameters: ⚠ NO DESCRIPTION PROVIDED Object Properties: ⚠ NO DESCRIPTION PROVIDED Id of the menu in the 'siblings' list to open. List of menu entries. Default and folder icons. Returns the maximium id (elements) a menu can use. Object containing size and state for the inspected web contents. The devtools itself always uses the full size. Properties: Left coordinate of inspected web contents. Top coordinate of inspected web contents. Width of inspected web contents. Height of inspected web contents. false to hide the inspected contents, otherwise true. Object containing size and state for the undocked devtools window. Properties: Left coordinate of window. Top coordinate of window. Right coordinate of window. Bottom coordinate of window. Should window be maximized. Should window be always on top. Whether to open the the element panel (inspect mode), console panel, or the default. Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fired when devtools changed its docking state. Parameters: The tab id of the tab changing its devtools docking state. The new devtools docking state. Possible values are right, bottom or undocked. Fired when devtools changed its sizes. Use |getDockingStateSizes| to read the new sizes. Parameters: The tab id of the tab changing its devtools docking state. Fired when docked devtools closed. Parameters: The tab id of the tab changing its devtools docking state. Fired when devtools wants to undock and we might need to open a window for it. Parameters: The tab id of the tab we are debugging. Show the initial window. May be false in which case the user likely just re-selected inspect on an existing web page. ⚠ NO DESCRIPTION PROVIDED Fired when devtools wants to activate the given undocked devtools window. Parameters: The tab id of the tab we are debugging. Used to request the size and state of the inspected webview. Parameters: The tab id of the tab changing its devtools docking state. Explicitly close the open devtools instance for the given tabId or windowId. Parameters: The tab id of the tab to close devtools for. The window id (not app window id) of the window to close all open devtools for. Toggle developer tools. Parameters: The window id for the browserwindow we want to toggle devtools for. ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED UserProfileItem. Contains info for userprofile Properties: The profile display name. The profile name. The profile path, if it is different than parent profile. The user profile index, if it is different than parent profile. ProfileItem. Properties: The type of import profile item Import item name. The profile item index. Does profile support history. Does profile support favorites. Does profile support passwords. Does profile support a master password to decode passwords. Does profile support Speed Dial. Does profile support notes. Does profile support email. Does profile support contacts. Does profile support extensions import. Does profile support open tab import. Is a default installation detected. Is the path on disk to the detected profile. Does the profile require interactive (file/directory picker dialog) selection by the user. Does the profile require explicit access permission to the profile folder/file. Suggested default profile path for profile selection dialog. What type of dialog should be used for interactive import. Possible values are 'file' or 'folder'. The path on disk to the detected mail profile ⚠ NO DESCRIPTION PROVIDED Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fired when a import session has started. Fired when a import session has ended. Parameters: Number of data types that failed to import. Fired when a import session for a data type has started. Parameters: Name of data type. Fired when a import session for a data type has ended. Parameters: Name of data type. Fired when a import session for a data type has failed. Parameters: Name of data type. Error message that can be shown to the user. Retrieves import data profiles. Start import process. Parameters: Index of the profile we want to import. This is a null based index of results from getProfiles. Show file dialog to user. Name of profile. ⚠ NO DESCRIPTION PROVIDED Object Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Opens Thunderbird mailbox from disk and seek to seekPosition. If called with already opened file it only seeks to seekPosition. If called with a new path it closes the current file and opens the new one. Parameters: Path to mailbox. Seek to this position after opening, serialized as a string because V8's integer type is too small for large mbox files. Closes currently open thunderbird mailbox, if any Read one message from currently open Thunderbird mailbox. ⚠ NO DESCRIPTION PROVIDED Basic typesafe theme data. Properties: The id of the queried theme. This is always set. Is the theme installed or not. If the theme is installed, this is the version of the installed theme. The theme object. Object Properties: ⚠ NO DESCRIPTION PROVIDED Properties: When true, the theme archive is returned as a memory blob instead of asking the user to select the file. Window to show the file selection dialog to select the output file. Must not be given when |returnBlob| is true. The title of the file selection dialog to select the output file. Must not be given when |returnBlob| is true. ⚠ NO DESCRIPTION PROVIDED Properties: True if the theme was successfully exported. False on errors or if the user cancelled operation. The exported archive as binary blob. This is given only on success and ony when |returnBlob| is true in |ExportOptions|. ⚠ NO DESCRIPTION PROVIDED Properties: The archive to import the theme from. ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Properties: Generic error kind low-level error message in English ⚠ NO DESCRIPTION PROVIDED Properties: Error if any during the operation. The id of the imported theme or an empty string if the user cancels the import or on errors. Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fired when the theme download is starting. Parameters: ⚠ NO DESCRIPTION PROVIDED Fired on download progress. Parameters: ⚠ NO DESCRIPTION PROVIDED Fired on download progress with the current progress value. Fired on download and install completion. Parameters: ⚠ NO DESCRIPTION PROVIDED true on successful theme install. if success is false, provides an error description. Fired if the preview or permanent theme collection has changed. Parameters: true if preview has changed, otherwise false. Export the theme into a zip file Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Import and install theme archive. Parameters: ⚠ NO DESCRIPTION PROVIDED Download and install theme. Parameters: Theme ID of the theme to download and install. This parameter is primarily used for status events. URL to the theme to download and install. Get some information about the given theme id. Parameters: Theme ID of the theme to return data about. The kind of the node. A node (either a note-entry or a folder) in the notes tree. Child nodes are ordered within their parent folder. Properties: The unique identifier for the node. IDs are unique within the current profile, and they remain valid even after the browser is restarted. The The 0-based position of this node within its parent folder. Omitted for the root node. Title/subject of note. The content of the note. Omitted for separators and folders. For attachments, this contains the attachment checksum. A URL associated with the note. Omitted for separators and folders. When this node was created, in milliseconds since the epoch ( When this node was last modified, in milliseconds since the epoch ( An ordered list of children of this node. Only present for folders Which kind of node this is. Object passed to the create() function. Properties: Defaults to the root folder. ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED The content of the node. For attachments, this is either a known attachment checksum copied from another attachment or a new base64-encoded attachment content A timestamp of the node's creation. A timestamp of the node's last modification date. Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fired when a bookmark or folder is created. Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Fired when a note or folder is removed. When a folder is removed recursively, a single notification is fired for the folder, and none for its contents. Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Object Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Fired when a note or folder changes. Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Object Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Fired when a note or folder is moved. Parameters: The id of the moved note ⚠ NO DESCRIPTION PROVIDED Object Properties: The id of the parent folder The index inside the parent folder Previous parent id Previous index inside the parent folder Fired when a notes import session is begun. Expensive observers should ignore onCreated updates until onImportEnded is fired. Observers should still handle other notifications immediately. Fired when a notes import session is ended.
Retrieves the specified NoteTreeNode(s). Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Retrieves the entire Notes hierarchy. Creates a bookmark or folder under the specified parentId. Parameters: ⚠ NO DESCRIPTION PROVIDED Updates the properties of a note or folder. Specify only the properties that you want to change; unspecified properties will be left unchanged. Note: Currently, only 'title' and 'url' are supported. Parameters: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Object Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Removes a note or an empty folder. Parameters: ⚠ NO DESCRIPTION PROVIDED Parameters: A string of words matched agains note contents. Moves the specified node to the provided location. Parameters: The id to be moved Object describing the target location Object Properties: Id of target folder The index inside the target folder Empty the notes trash folder. Signal that import has been started. Signal that import has been finished. ⚠ NO DESCRIPTION PROVIDED Parameters: The command to be executed. ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED A structure describing the status of an update operation if any. Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fired when a valid update is found. Parameters: URL of the release notes of the update. The version of the update or an empty string if not known Fired if checkForUpdates did not find an update. Parameters: Enum reason why the updated did not find an update. Fired when an update will be downloaded. Parameters: The version of the update or an empty string if not known Fired when an update has been downloaded. Parameters: The version of the update or an empty string if not known Fired when an update will be installed on restart or quit. Parameters: The version that will be installed on quit or an empty string if not known Fired when an update to audio/video support (including Widevine) happened while the application was running, and restart is needed to reload. Fired just before the updater restarts the application. Fired when an application has been restarted due to an update. Fired when an update fails. Parameters: Description of the error. The reason for the error. Signal sent when update completed without installation. Currently, only sent by macOS for exit on silent error.
Check for Vivaldi browser updates. Parameters: Indicates whether we want the auto-update ui to appear. Checks whether the update notifier is set to run on startup. Sets the update notifier to run on startup and launches it. Removes the update notifier from autorun and attempts to terminate it. Installs update & restart. Should be called after an onWillInstallUpdateOnQuit event has occurred. Checks whether we automatically install updates Change automatically install updates setting Parameters: Indicates whether we want to automatically install updates. Get the date & time we last checked for an update. Returns milliseconds since epoch. Get a status of an update operation if any Return true if automatic updates are supported. Return true if restart is needed due to codec update. Runs startup checks after the autoupdate UI is prepared. ⚠ NO DESCRIPTION PROVIDED A structure describing the status of an update operation if any. Properties: ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED ⚠ NO DESCRIPTION PROVIDED Each listener type has the same functions, used for each listener API in the same way: Adds a function to a listener for an event Removes a function to a listener for an event Returns a boolean if a function is attached to a listener for an event Returns a boolean if a listener has any attached functions Returns array of promises dispatched to the listener Fired when a valid update is found. Parameters: URL of the release notes of the update. The version of the update or an empty string if not known Fired if checkForUpdates did not find an update. Parameters: Enum reason why the updated did not find an update. Fired when an update will be downloaded. Parameters: The version of the update or an empty string if not known Fired when an update has been downloaded. Parameters: The version of the update or an empty string if not known Fired when an update will be installed on restart or quit. Parameters: The version that will be installed on quit or an empty string if not known Fired when an update to audio/video support (including Widevine) happened while the application was running, and restart is needed to reload. Fired just before the updater restarts the application. Fired when an application has been restarted due to an update. Fired when an update fails. Parameters: Description of the error. The reason for the error. Signal sent when update completed without installation. Currently, only sent by macOS for exit on silent error.
Check for Vivaldi browser updates. Parameters: Indicates whether we want the auto-update ui to appear. Checks whether the update notifier is set to run on startup. Sets the update notifier to run on startup and launches it. Removes the update notifier from autorun and attempts to terminate it. Installs update & restart. Should be called after an onWillInstallUpdateOnQuit event has occurred. Checks whether we automatically install updates Change automatically install updates setting Parameters: Indicates whether we want to automatically install updates. Get the date & time we last checked for an update. Returns milliseconds since epoch. Get a status of an update operation if any Return true if automatic updates are supported. Return true if restart is needed due to codec update. Runs startup checks after the autoupdate UI is prepared.integer
string
#onWebContentsHasWindow
integer
#onToastMessage
integer
ToastParameters
Methods
#create
string
CreateWindowOptions
WindowType
#getCurrentId
#setState
integer
WindowState
#updateMaximizeButtonPosition
integer
number
number
number
number
#getFocusedElementInfo
integer
#isOnScreenWithNotch
integer
#setControlButtonsPadding
integer
ControlButtonsPadding
#performHapticFeedback
menuContent
Types
#NodeType
ENUM
#Role
ENUM
#ContainerMode
ENUM
#ContainerEdge
ENUM
#MenuTreeNode
string
NodeType
string
boolean
string
boolean
string
ContainerMode
ContainerEdge
string
Array
of:
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onChanged
string
string
Role
string
Array
of:
#onResetAll
boolean
Methods
#get
string
#move
string
Array
of:
string
integer
#create
string
string
integer
Array
of:
#remove
string
Array
of:
#removeAction
Array
of:
#update
string
string
object
string
string
boolean
ContainerMode
ContainerEdge
#reset
string
boolean
Array
of:
#resetAll
boolean
omniboxPrivate
Types
#OmniboxItemCategory
ENUM
#OmniboxProviderName
ENUM
#OmniboxFocusType
ENUM
#PageClassification
ENUM
#OmniboxItem
boolean
string
string
string
boolean
integer
OmniboxProviderName
historyPrivate.TransitionType
string
string
OmniboxItemCategory
boolean
integer
string
string
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onOmniboxResultChanged
object
Array
of:
string
boolean
Methods
#startOmnibox
object
string
boolean
boolean
boolean
string
OmniboxFocusType
PageClassification
#addOrUpdateShortcut
string
OmniboxItem
#deleteShortcut
string
dnsOverHttpsPrivate
Types
#DohEntry
string
string
string
Methods
#dataFetcher
#configTest
string
translateHistory
Types
#TextItem
string
string
#HistoryItem
string
TextItem
TextItem
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onAdded
Array
of:
number
#onMoved
string
number
#onRemoved
Array
of:
Methods
#get
#add
HistoryItem
number
#remove
Array
of:
#reset
number
extensionActionUtils
Types
#ActionType
ENUM
#ExtensionType
ENUM
#MenuType
ENUM
#GlobalErrorType
ENUM
#MenuItem
string
string
boolean
boolean
boolean
MenuType
Array
of:
#SidePanelInfo
string
string
#SidePanelOptions
integer
string
string
string
boolean
#ExtensionInfo
integer
string
string
string
string
string
string
boolean
ActionType
boolean
boolean
ExtensionType
string
string
string
boolean
string
SidePanelInfo
boolean
#ExtensionInstallError
string
string
GlobalErrorType
integer
#ExtensionActionParams
string
string
boolean
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onAdded
ExtensionInfo
#onRemoved
ExtensionInfo
#onUpdated
ExtensionInfo
#onClearAllValuesForTab
string
number
#onCommandAdded
string
string
#onCommandRemoved
string
string
#onExtensionDisabledInstallErrorAdded
ExtensionInstallError
#onExtensionDisabledInstallErrorRemoved
ExtensionInstallError
#onSidePanelOptionChanged
string
SidePanelOptions
#onSidePanelActionRequested
string
string
Methods
#getToolbarExtensions
#executeExtensionAction
string
integer
#removeExtension
string
integer
#showExtensionOptions
string
integer
#getExtensionMenu
string
#executeMenuAction
string
integer
string
#showGlobalError
integer
integer
#triggerGlobalErrors
readingListPrivate
Types
#ReadingListEntry
string
string
boolean
number
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onModelChanged
Methods
#add
string
string
#remove
string
#getAll
#setReadStatus
string
boolean
bookmarksPrivate
Types
#FolderIds
string
string
string
#SpeedDialInfo
string
string
#BookmarkTreeNode
string
string
id
of the parent folder. Omitted for the root node.integer
string
string
string
string
string
string
string
boolean
string
boolean
boolean
number
new Date(dateAdded)
).number
string
Array
of:
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onFaviconChanged
string
string
#onMetaInfoChanged
string
object
string
string
string
boolean
boolean
string
string
Methods
#updateSpeedDialsForWindowsJumplist
Array
of:
#emptyTrash
#updatePartners
#isCustomThumbnail
string
#getFolderIds
#export
integer
menubarMenu
Types
#ContainerType
ENUM
#SortOrder
ENUM
#SortField
ENUM
#Edge
ENUM
#ItemType
ENUM
#Rect
integer
integer
integer
integer
#Icons
Array
of:
#Item
integer
string
ItemType
boolean
boolean
boolean
boolean
integer
boolean
string
string
Icons
#Separator
string
#Container
string
ContainerType
integer
boolean
Edge
SortField
SortOrder
#Element
Item
Separator
Container
Array
of:
#Menu
integer
Rect
Array
of:
#EventState
boolean
boolean
boolean
boolean
boolean
boolean
boolean
#Disposition
ENUM
#BookmarkCommand
ENUM
#BookmarkAction
string
BookmarkCommand
Disposition
boolean
EventState
#Action
integer
EventState
boolean
#Update
integer
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onOpen
integer
#onClose
#onAction
Action
#onOpenBookmark
integer
BookmarkAction
#onBookmarkAction
integer
BookmarkAction
#onHover
integer
string
#onError
string
Methods
#show
object
integer
integer
Array
of:
Icons
#getMaxId
devtoolsPrivate
Types
#DevtoolResizingStrategy
integer
integer
integer
integer
boolean
#DevtoolsWindowParams
integer
integer
integer
integer
boolean
boolean
#PanelType
ENUM
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onDockingStateChanged
integer
string
#onDockingSizesChanged
integer
#onClosed
integer
#onDevtoolsUndocked
integer
boolean
DevtoolsWindowParams
#onActivateWindow
integer
Methods
#getDockingStateSizes
integer
#closeDevtools
integer
integer
#toggleDevtools
integer
PanelType
importData
Types
#import_types
ENUM
#UserProfileItem
string
string
string
integer
#ProfileItem
import_types
string
integer
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
string
boolean
boolean
string
string
string
Array
of:
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onImportStarted
#onImportEnded
integer
#onImportItemStarted
string
#onImportItemEnded
string
#onImportItemFailed
string
string
Methods
#getProfiles
#startImport
integer
boolean
string
object
boolean
boolean
boolean
boolean
boolean
boolean
boolean
string
string
#openThunderbirdMailbox
string
string
#closeThunderbirdMailbox
#readMessageFromThunderbirdMailbox
themePrivate
Types
#BackgroundPosition
ENUM
#ThemeData
string
boolean
number
#ThemeObject
object
any
True
#ExportOptions
boolean
number
string
#ExportResult
boolean
binary
#ImportOptions
binary
#ImportErrorKind
ENUM
#ImportError
ImportErrorKind
string
#ImportResult
ImportError
string
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onThemeDownloadStarted
string
#onThemeDownloadProgress
string
integer
#onThemeDownloadCompleted
string
boolean
string
#onThemesUpdated
boolean
Methods
#export
ThemeObject
ExportOptions
#import
ImportOptions
#download
string
string
#getThemeData
string
notes
Types
#NodeType
ENUM
#NoteTreeNode
string
string
id
of the parent folder. Omitted for the root node.integer
string
string
string
number
new Date(dateAdded)
).number
new Date(dateModified)
).Array
of:
NodeType
#CreateDetails
string
integer
NodeType
string
string
string
number
number
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onCreated
string
NoteTreeNode
#onRemoved
string
object
string
integer
#onChanged
string
object
string
string
string
number
#onMoved
string
object
string
integer
string
integer
#onImportBegan
#onImportEnded
Methods
#get
string
Array
of:
#getTree
#create
CreateDetails
#update
string
object
string
string
string
#remove
string
#search
string
#move
string
object
string
integer
#emptyTrash
#beginImport
#endImport
editcommand
Methods
#execute
string
integer
autoUpdate
Types
#UpdateOperationStatusEnum
ENUM
#UpdateOperationStatus
UpdateOperationStatusEnum
string
string
#UpdateNotFoundReason
ENUM
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onDidFindValidUpdate
string
string
#onUpdaterDidNotFindUpdate
UpdateNotFoundReason
#onWillDownloadUpdate
string
#onDidDownloadUpdate
string
#onWillInstallUpdateOnQuit
string
#onNeedRestartToReloadCodecs
#onUpdaterWillRelaunchApplication
#onUpdaterDidRelaunchApplication
#onDidAbortWithError
string
string
#onUpdateFinished
Methods
#checkForUpdates
boolean
#isUpdateNotifierEnabled
#enableUpdateNotifier
#disableUpdateNotifier
#installUpdateAndRestart
#getAutoInstallUpdates
#setAutoInstallUpdates
boolean
#getLastCheckTime
#getUpdateStatus
#hasAutoUpdates
#needsCodecRestart
#runStartupChecks
preferenceDefinitions
Types
#UpdateOperationStatusEnum
ENUM
#UpdateOperationStatus
UpdateOperationStatusEnum
string
string
#UpdateNotFoundReason
ENUM
Listeners
How to use listeners
.addListener(
function
callback).removeListener(
function
callback).hasListener(
function
callback).hasListeners()
.dispatch()
#onDidFindValidUpdate
string
string
#onUpdaterDidNotFindUpdate
UpdateNotFoundReason
#onWillDownloadUpdate
string
#onDidDownloadUpdate
string
#onWillInstallUpdateOnQuit
string
#onNeedRestartToReloadCodecs
#onUpdaterWillRelaunchApplication
#onUpdaterDidRelaunchApplication
#onDidAbortWithError
string
string
#onUpdateFinished
Methods
#checkForUpdates
boolean
#isUpdateNotifierEnabled
#enableUpdateNotifier
#disableUpdateNotifier
#installUpdateAndRestart
#getAutoInstallUpdates
#setAutoInstallUpdates
boolean
#getLastCheckTime
#getUpdateStatus
#hasAutoUpdates
#needsCodecRestart
#runStartupChecks