import type { InjectionKey, ComputedRef, Ref } from 'vue'; import { createContext, useContext } from '/@/hooks/core/useContext'; import {} from 'vue'; export interface PageContextProps { contentHeight: ComputedRef; pageHeight: Ref; setPageHeight: (height: number) => Promise; } const key: InjectionKey = Symbol(); export function createPageContext(context: PageContextProps) { return createContext(context, key, { native: true }); } export function usePageContext() { return useContext(key); }