Skip to content

@jakguru/vueprint / @jakguru/vueprint/services/bus / BusEventCallbackSignatures

Interface: BusEventCallbackSignatures

@jakguru/vueprint/services/bus.BusEventCallbackSignatures

Describes the events and the signatures of their callbacks Should be extended by the application to include all the events it needs

Properties

api:unauthorized

api:unauthorized: (from?: string) => void

Emitted when the API returns a 401 Unauthorized status

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:131


authentication:refreshable

authentication:refreshable: (from?: string) => void

The user's authentication token is eligible for refresh

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:207


firebase:token:updated

firebase:token:updated: (token: undefined | string, from?: string) => void

The Firebase token has been updated

Type declaration

▸ (token, from?): void

Parameters
NameTypeDescription
tokenundefined | stringThe new token
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:181


identity:login

identity:login: (bearer: string, expiration: string, identity: UserIdentity, from?: string) => void

The user has been authenticated and identified

Type declaration

▸ (bearer, expiration, identity, from?): void

Parameters
NameTypeDescription
bearerstringThe bearer token
expirationstringThe expiration date of the token
identityUserIdentityThe identity of the user
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:190


identity:logout

identity:logout: (from?: string) => void

The user has been logged out

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:201


ls:change

ls:change: (from?: string) => void

Notify that the local storage has changed

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:213


ls:clear

ls:clear: (from?: string) => void

Notify that the local storage has been cleared

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:231


ls:loaded

ls:loaded: (from?: string) => void

Notify that the local storage has been loaded

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:219


ls:resetAllKeys

ls:resetAllKeys: (from?: string) => void

Notify that the local storage has been reset

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:237


ls:setDataToLocalStorage

ls:setDataToLocalStorage: (key: any, data: any, from?: string) => void

Notify that the local storage has been saved

Type declaration

▸ (key, data, from?): void

Parameters
NameTypeDescription
keyany-
dataany-
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:225


on:fcm:message

on:fcm:message: (background: boolean, payload: MessagePayload, args: any[], from?: string) => void

Type declaration

▸ (background, payload, args, from?): void

Parameters
NameType
backgroundboolean
payloadMessagePayload
argsany[]
from?string
Returns

void

Defined in

src/services/bus.ts:261


push:firebase:message

push:firebase:message: (payload: MessagePayload, from?: string) => void

Type declaration

▸ (payload, from?): void

Parameters
NameType
payloadMessagePayload
from?string
Returns

void

Defined in

src/services/bus.ts:260


push:notification

push:notification: (payload: NotificationPayload, from?: string) => void

A push notification has been received

Type declaration

▸ (payload, from?): void

Parameters
NameTypeDescription
payloadNotificationPayloadThe payload of the notification
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:174


push:permission:denied

push:permission:denied: (from?: string) => void

The push service has been granted permission

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:161


push:permission:granted

push:permission:granted: (from?: string) => void

The push service has been denied permission

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:167


push:updated

push:updated: (from?: string) => void

The push service has been updated

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:155


sw:activate

sw:activate: (event: ExtendableEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventExtendableEvent
from?string
Returns

void

Defined in

src/services/bus.ts:238


sw:backgroundfetchabort

sw:backgroundfetchabort: (event: BackgroundFetchEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventBackgroundFetchEvent
from?string
Returns

void

Defined in

src/services/bus.ts:248


sw:backgroundfetchclick

sw:backgroundfetchclick: (event: BackgroundFetchClickEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventBackgroundFetchClickEvent
from?string
Returns

void

Defined in

src/services/bus.ts:249


sw:backgroundfetchfail

sw:backgroundfetchfail: (event: BackgroundFetchFailEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventBackgroundFetchFailEvent
from?string
Returns

void

Defined in

src/services/bus.ts:250


sw:backgroundfetchsuccess

sw:backgroundfetchsuccess: (event: BackgroundFetchSuccessEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventBackgroundFetchSuccessEvent
from?string
Returns

void

Defined in

src/services/bus.ts:251


sw:canmakepayment

sw:canmakepayment: (event: CanMakePaymentEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventCanMakePaymentEvent
from?string
Returns

void

Defined in

src/services/bus.ts:252


sw:contentdelete

sw:contentdelete: (event: ContentDeleteEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventContentDeleteEvent
from?string
Returns

void

Defined in

src/services/bus.ts:253


sw:cookiechange

sw:cookiechange: (event: CookieChangeEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventCookieChangeEvent
from?string
Returns

void

Defined in

src/services/bus.ts:254


sw:fetch

sw:fetch: (event: FetchEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventFetchEvent
from?string
Returns

void

Defined in

src/services/bus.ts:240


sw:install

sw:install: (event: ExtendableEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventExtendableEvent
from?string
Returns

void

Defined in

src/services/bus.ts:239


sw:message

sw:message: (event: ExtendableMessageEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventExtendableMessageEvent
from?string
Returns

void

Defined in

src/services/bus.ts:241


sw:messageerror

sw:messageerror: (event: MessageEvent<any>, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventMessageEvent<any>
from?string
Returns

void

Defined in

src/services/bus.ts:242


sw:notificationclick

sw:notificationclick: (event: NotificationEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventNotificationEvent
from?string
Returns

void

Defined in

src/services/bus.ts:243


sw:notificationclose

sw:notificationclose: (event: NotificationEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventNotificationEvent
from?string
Returns

void

Defined in

src/services/bus.ts:244


sw:paymentrequest

sw:paymentrequest: (event: PaymentRequestEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventPaymentRequestEvent
from?string
Returns

void

Defined in

src/services/bus.ts:255


sw:periodicsync

sw:periodicsync: (event: PeriodicSyncEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventPeriodicSyncEvent
from?string
Returns

void

Defined in

src/services/bus.ts:256


sw:push

sw:push: (event: PushEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventPushEvent
from?string
Returns

void

Defined in

src/services/bus.ts:245


sw:pushsubscriptionchange

sw:pushsubscriptionchange: (event: PushSubscriptionChangeEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventPushSubscriptionChangeEvent
from?string
Returns

void

Defined in

src/services/bus.ts:246


sw:sync

sw:sync: (event: SyncEvent, from?: string) => void

Type declaration

▸ (event, from?): void

Parameters
NameType
eventSyncEvent
from?string
Returns

void

Defined in

src/services/bus.ts:247


tab:active

tab:active: (from?: string) => void

A tab has become active

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:144


tab:inactive

tab:inactive: (from?: string) => void

A tab has become inactive

Type declaration

▸ (from?): void

Parameters
NameTypeDescription
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:149


tab:uuid

tab:uuid: (uuid: string, active: boolean, from?: string) => void

A tab has been updated

Type declaration

▸ (uuid, active, from?): void

Parameters
NameTypeDescription
uuidstringThe ID of the tab which has been updated
activebooleanIf the new tab is "active" or not
from?stringThe ID of the tab that triggered the event
Returns

void

Defined in

src/services/bus.ts:139


webfonts:active

webfonts:active: (from?: string) => void

Type declaration

▸ (from?): void

Parameters
NameType
from?string
Returns

void

Defined in

src/services/bus.ts:258


webfonts:inactive

webfonts:inactive: (from?: string) => void

Type declaration

▸ (from?): void

Parameters
NameType
from?string
Returns

void

Defined in

src/services/bus.ts:259


webfonts:loading

webfonts:loading: (from?: string) => void

Type declaration

▸ (from?): void

Parameters
NameType
from?string
Returns

void

Defined in

src/services/bus.ts:257

Vueprint is a commercial work product released under the MIT License and is provided as-is with no warranty or guarantee of support.