mirror of
https://github.com/Equicord/Equicord.git
synced 2025-06-08 22:23:02 -04:00
parent
c91b0df607
commit
faa90eccd3
8 changed files with 182 additions and 27 deletions
|
@ -117,6 +117,7 @@ const ModalAPI = mapMangledModuleLazy("onCloseRequest:null!=", {
|
|||
openModal: filters.byCode("onCloseRequest:null!="),
|
||||
closeModal: filters.byCode("onCloseCallback&&"),
|
||||
openModalLazy: m => m?.length === 1 && filters.byCode(".apply(this,arguments)")(m),
|
||||
closeAllModals: filters.byCode(".value.key,")
|
||||
});
|
||||
|
||||
/**
|
||||
|
@ -142,3 +143,10 @@ export function openModal(render: RenderFunction, options?: ModalOptions, contex
|
|||
export function closeModal(modalKey: string, contextKey?: string): void {
|
||||
return ModalAPI.closeModal(modalKey, contextKey);
|
||||
}
|
||||
|
||||
/**
|
||||
* Close all open modals
|
||||
*/
|
||||
export function closeAllModals(): void {
|
||||
return ModalAPI.closeAllModals();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue