-
Notifications
You must be signed in to change notification settings - Fork 129
Lightbox API
Murhaf Sousli edited this page Aug 9, 2020
·
6 revisions
Name | Description |
---|---|
setConfig(config: LightboxConfig) | Set lightbox config |
open(index: number) | Open lightbox |
open(index: number, id?: string) | Open lightbox for a specific gallery id |
open(index, id?: string, config?: LightboxConfig) | Open lightbox with custom config |
close() | Close lightbox |
opened | Stream that emits when lightbox is opened |
closed | Stream that emits when lightbox is closed |
Name | Default | Description |
---|---|---|
backdropClass | g-backdrop |
Lightbox backdrop class |
panelClass | g-overlay |
Lightbox panel class |
hasBackdrop | true | Lightbox hasBackdrop |
keyboardShortcuts | true | Navigation keyboard shortcuts right , left , escape
|
closeIcon | svg data | Set the close button icon, should be a svg data |
startAnimationTime | 150 | The lightbox start animation time in ms |
exitAnimationTime | 75 | The lightbox exit animation time in ms |
role | 75 | The ARIA role of the lightbox element |
ariaLabel | 75 | Aria label to assign to the lightbox element |
ariaLabelledBy | 75 | ID of the element that should be considered as the lightbox's label |
ariaDescribedBy | 75 | ID of the element that describes the lightbox |