diff --git a/src/leaf/map/fullscreen/fullscreen.ts b/src/leaf/map/fullscreen/fullscreen.ts index ed1df36..ff772af 100644 --- a/src/leaf/map/fullscreen/fullscreen.ts +++ b/src/leaf/map/fullscreen/fullscreen.ts @@ -109,21 +109,19 @@ export function fullscreenMap({ mapLifecycleEvent: FullscreenMapLifecycleEvent, ): (() => void) => fullscreenMapLifecycleListener({ - document: { - map: { - control: { - anchor: { - assign: anchorAssign, - titleStates: anchorTitleStates, - }, + map: { + control: { + anchor: { + assign: anchorAssign, + titleStates: anchorTitleStates, }, - fullscreen: { - classNames: fullscreenMapClassNames, - state: { get: getFullscreenState, toggle: toggleFullscreenState }, - }, - lifecycleEvent: mapLifecycleEvent, - map, }, + fullscreen: { + classNames: fullscreenMapClassNames, + state: { get: getFullscreenState, toggle: toggleFullscreenState }, + }, + lifecycleEvent: mapLifecycleEvent, + map, }, }) diff --git a/src/leaf/map/fullscreen/lifecycle-listener.ts b/src/leaf/map/fullscreen/lifecycle-listener.ts index ab9fb4e..131eb94 100644 --- a/src/leaf/map/fullscreen/lifecycle-listener.ts +++ b/src/leaf/map/fullscreen/lifecycle-listener.ts @@ -10,39 +10,35 @@ import { type Map, type UseSwitch } from '@stassi/leaf' export type FullscreenMapLifecycleEvent = 'ready' | 'unload' export type FullscreenMapLifecycleListenerOptions = { - document: { - map: { - control: { - anchor: { - assign: ControlAnchorAssign - titleStates: ControlAnchorTitleStates - } + map: { + control: { + anchor: { + assign: ControlAnchorAssign + titleStates: ControlAnchorTitleStates } - fullscreen: { - classNames: string - state: UseSwitch - } - lifecycleEvent: FullscreenMapLifecycleEvent - map: Map } + fullscreen: { + classNames: string + state: UseSwitch + } + lifecycleEvent: FullscreenMapLifecycleEvent + map: Map } } export type FullscreenMapLifecycleListener = () => void export function fullscreenMapLifecycleListener({ - document: { - map: { - control: { - anchor: { assign: anchorAssign, titleStates: anchorTitleStates }, - }, - fullscreen: { - classNames: fullscreenMapClassNames, - state: { get: getFullscreenState, toggle: toggleFullscreenState }, - }, - lifecycleEvent: mapLifecycleEvent, - map, + map: { + control: { + anchor: { assign: anchorAssign, titleStates: anchorTitleStates }, + }, + fullscreen: { + classNames: fullscreenMapClassNames, + state: { get: getFullscreenState, toggle: toggleFullscreenState }, }, + lifecycleEvent: mapLifecycleEvent, + map, }, }: FullscreenMapLifecycleListenerOptions): FullscreenMapLifecycleListener { return function handleFullscreenMapLifecycleEvent(): void {