mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-16 02:11:48 +08:00
9cd204712b
Co-authored-by: holazz <2418184580@qq.com> Co-authored-by: sxzz <sxzz@sxzz.moe>
22 lines
646 B
TypeScript
22 lines
646 B
TypeScript
import type { Arrayable } from '../utils/typescript'
|
|
import type { InjectionKey, Ref } from 'vue'
|
|
import type { TooltipTriggerType } from '@element-plus/components/tooltip'
|
|
|
|
export type ElTooltipInjectionContext = {
|
|
controlled: Ref<boolean>
|
|
id: Ref<string>
|
|
open: Ref<boolean>
|
|
trigger: Ref<Arrayable<TooltipTriggerType>>
|
|
onOpen: (e?: Event) => void
|
|
onClose: (e?: Event) => void
|
|
onToggle: (e: Event) => void
|
|
onShow: () => void
|
|
onHide: () => void
|
|
onBeforeShow: () => void
|
|
onBeforeHide: () => void
|
|
updatePopper: () => void
|
|
}
|
|
|
|
export const TOOLTIP_INJECTION_KEY: InjectionKey<ElTooltipInjectionContext> =
|
|
Symbol('elTooltip')
|