forked from JeremyHeleine/Photo-Sphere-Viewer
-
-
Notifications
You must be signed in to change notification settings - Fork 634
/
events.ts
30 lines (25 loc) · 769 Bytes
/
events.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import { TypedEvent } from '@photo-sphere-viewer/core';
import type { GalleryPlugin } from './GalleryPlugin';
/**
* @event Triggered when the gallery shown
*/
export class ShowGalleryEvent extends TypedEvent<GalleryPlugin> {
static override readonly type = 'show-gallery';
override type: 'show-gallery';
/** @internal */
constructor() {
super(ShowGalleryEvent.type);
}
}
/**
* @event Triggered when the gallery hidden
*/
export class HideGalleryEvent extends TypedEvent<GalleryPlugin> {
static override readonly type = 'hide-gallery';
override type: 'hide-gallery';
/** @internal */
constructor() {
super(ShowGalleryEvent.type);
}
}
export type GalleryPluginEvents = ShowGalleryEvent | HideGalleryEvent;