mirror of
https://github.com/koloml/furbooru-tagging-assistant.git
synced 2025-12-24 07:12:57 +00:00
Added event returned from booru on form submissions
This commit is contained in:
5
src/lib/components/events/booru-events.ts
Normal file
5
src/lib/components/events/booru-events.ts
Normal file
@@ -0,0 +1,5 @@
|
||||
export const eventFetchComplete = 'fetchcomplete';
|
||||
|
||||
export interface BooruEventsMap {
|
||||
[eventFetchComplete]: null; // Site sends the response, but extension will not get it due to isolation.
|
||||
}
|
||||
@@ -1,12 +1,15 @@
|
||||
import type { MaintenancePopupEventsMap } from "$lib/components/events/maintenance-popup-events";
|
||||
import { BaseComponent } from "$lib/components/base/BaseComponent";
|
||||
import type { FullscreenViewerEventsMap } from "$lib/components/events/fullscreen-viewer-events";
|
||||
import type { BooruEventsMap } from "$lib/components/events/booru-events";
|
||||
|
||||
interface EventsMapping extends MaintenancePopupEventsMap, FullscreenViewerEventsMap {
|
||||
}
|
||||
type EventsMapping =
|
||||
MaintenancePopupEventsMap
|
||||
& FullscreenViewerEventsMap
|
||||
& BooruEventsMap;
|
||||
|
||||
type EventCallback<EventDetails> = (event: CustomEvent<EventDetails>) => void;
|
||||
type UnsubscribeFunction = () => void;
|
||||
export type UnsubscribeFunction = () => void;
|
||||
type ResolvableTarget = EventTarget | BaseComponent;
|
||||
|
||||
function resolveTarget(componentOrElement: ResolvableTarget): EventTarget {
|
||||
|
||||
Reference in New Issue
Block a user