1 |
- {"version":3,"file":"useActivator.mjs","names":["VMenuSymbol","makeDelayProps","useDelay","computed","effectScope","inject","mergeProps","nextTick","onScopeDispose","ref","watch","watchEffect","bindProps","getCurrentInstance","IN_BROWSER","matchesSelector","propsFactory","refElement","unbindProps","makeActivatorProps","activator","String","Object","activatorProps","type","default","openOnClick","Boolean","undefined","openOnHover","openOnFocus","closeOnContentClick","useActivator","props","_ref","isActive","isTop","activatorEl","isHovered","isFocused","firstEnter","value","runOpenDelay","runCloseDelay","availableEvents","onClick","e","stopPropagation","currentTarget","target","onMouseenter","sourceCapabilities","firesTouchEvents","onMouseleave","onFocus","onBlur","activatorEvents","events","contentEvents","onFocusin","onFocusout","menu","closeParents","scrimEvents","val","activatorRef","vm","scope","run","_useActivator","stop","flush","immediate","_ref2","oldVal","getActivator","unbindActivatorProps","bindActivatorProps","el","arguments","length","_props","selector","proxy","$el","parentNode","hasAttribute","document","querySelector","nodeType","Node","ELEMENT_NODE"],"sources":["../../../src/components/VOverlay/useActivator.tsx"],"sourcesContent":["// Components\nimport { VMenuSymbol } from '@/components/VMenu/shared'\n\n// Composables\nimport { makeDelayProps, useDelay } from '@/composables/delay'\n\n// Utilities\nimport {\n computed,\n effectScope,\n inject,\n mergeProps,\n nextTick,\n onScopeDispose,\n ref,\n watch,\n watchEffect,\n} from 'vue'\nimport {\n bindProps,\n getCurrentInstance,\n IN_BROWSER,\n matchesSelector,\n propsFactory,\n refElement,\n unbindProps,\n} from '@/util'\n\n// Types\nimport type {\n ComponentInternalInstance,\n ComponentPublicInstance,\n EffectScope,\n PropType,\n Ref,\n} from 'vue'\nimport type { DelayProps } from '@/composables/delay'\n\ninterface ActivatorProps extends DelayProps {\n activator?: 'parent' | string | Element | ComponentPublicInstance\n activatorProps: Record<string, any>\n\n openOnClick: boolean | undefined\n openOnHover: boolean\n openOnFocus: boolean | undefined\n\n closeOnContentClick: boolean\n}\n\nexport const makeActivatorProps = propsFactory({\n activator: [String, Object] as PropType<ActivatorProps['activator']>,\n activatorProps: {\n type: Object as PropType<ActivatorProps['activatorProps']>,\n default: () => ({}),\n },\n\n openOnClick: {\n type: Boolean,\n default: undefined,\n },\n openOnHover: Boolean,\n openOnFocus: {\n type: Boolean,\n default: undefined,\n },\n\n closeOnContentClick: Boolean,\n\n ...makeDelayProps(),\n}, 'VOverlay-activator')\n\nexport function useActivator (\n props: ActivatorProps,\n { isActive, isTop }: { isActive: Ref<boolean>, isTop: Ref<boolean> }\n) {\n const activatorEl = ref<HTMLElement>()\n\n let isHovered = false\n let isFocused = false\n let firstEnter = true\n\n const openOnFocus = computed(() => props.openOnFocus || (props.openOnFocus == null && props.openOnHover))\n const openOnClick = computed(() => props.openOnClick || (props.openOnClick == null && !props.openOnHover && !openOnFocus.value))\n\n const { runOpenDelay, runCloseDelay } = useDelay(props, value => {\n if (\n value === (\n (props.openOnHover && isHovered) ||\n (openOnFocus.value && isFocused)\n ) && !(props.openOnHover && isActive.value && !isTop.value)\n ) {\n if (isActive.value !== value) {\n firstEnter = true\n }\n isActive.value = value\n }\n })\n\n const availableEvents = {\n onClick: (e: MouseEvent) => {\n e.stopPropagation()\n activatorEl.value = (e.currentTarget || e.target) as HTMLElement\n isActive.value = !isActive.value\n },\n onMouseenter: (e: MouseEvent) => {\n if (e.sourceCapabilities?.firesTouchEvents) return\n\n isHovered = true\n activatorEl.value = (e.currentTarget || e.target) as HTMLElement\n runOpenDelay()\n },\n onMouseleave: (e: MouseEvent) => {\n isHovered = false\n runCloseDelay()\n },\n onFocus: (e: FocusEvent) => {\n if (matchesSelector(e.target as HTMLElement, ':focus-visible') === false) return\n\n isFocused = true\n e.stopPropagation()\n activatorEl.value = (e.currentTarget || e.target) as HTMLElement\n\n runOpenDelay()\n },\n onBlur: (e: FocusEvent) => {\n isFocused = false\n e.stopPropagation()\n\n runCloseDelay()\n },\n }\n\n const activatorEvents = computed(() => {\n const events: Partial<typeof availableEvents> = {}\n\n if (openOnClick.value) {\n events.onClick = availableEvents.onClick\n }\n if (props.openOnHover) {\n events.onMouseenter = availableEvents.onMouseenter\n events.onMouseleave = availableEvents.onMouseleave\n }\n if (openOnFocus.value) {\n events.onFocus = availableEvents.onFocus\n events.onBlur = availableEvents.onBlur\n }\n\n return events\n })\n\n const contentEvents = computed(() => {\n const events: Record<string, EventListener> = {}\n\n if (props.openOnHover) {\n events.onMouseenter = () => {\n isHovered = true\n runOpenDelay()\n }\n events.onMouseleave = () => {\n isHovered = false\n runCloseDelay()\n }\n }\n\n if (openOnFocus.value) {\n events.onFocusin = () => {\n isFocused = true\n runOpenDelay()\n }\n events.onFocusout = () => {\n isFocused = false\n runCloseDelay()\n }\n }\n\n if (props.closeOnContentClick) {\n const menu = inject(VMenuSymbol, null)\n events.onClick = () => {\n isActive.value = false\n menu?.closeParents()\n }\n }\n\n return events\n })\n\n const scrimEvents = computed(() => {\n const events: Record<string, EventListener> = {}\n\n if (props.openOnHover) {\n events.onMouseenter = () => {\n if (firstEnter) {\n isHovered = true\n firstEnter = false\n runOpenDelay()\n }\n }\n events.onMouseleave = () => {\n isHovered = false\n runCloseDelay()\n }\n }\n\n return events\n })\n\n watch(isTop, val => {\n if (val && (\n (props.openOnHover && !isHovered && (!openOnFocus.value || !isFocused)) ||\n (openOnFocus.value && !isFocused && (!props.openOnHover || !isHovered))\n )) {\n isActive.value = false\n }\n })\n\n const activatorRef = ref()\n watchEffect(() => {\n if (!activatorRef.value) return\n\n nextTick(() => {\n activatorEl.value = refElement(activatorRef.value)\n })\n })\n\n const vm = getCurrentInstance('useActivator')\n let scope: EffectScope\n watch(() => !!props.activator, val => {\n if (val && IN_BROWSER) {\n scope = effectScope()\n scope.run(() => {\n _useActivator(props, vm, { activatorEl, activatorEvents })\n })\n } else if (scope) {\n scope.stop()\n }\n }, { flush: 'post', immediate: true })\n\n onScopeDispose(() => {\n scope?.stop()\n })\n\n return { activatorEl, activatorRef, activatorEvents, contentEvents, scrimEvents }\n}\n\nfunction _useActivator (\n props: ActivatorProps,\n vm: ComponentInternalInstance,\n { activatorEl, activatorEvents }: Pick<ReturnType<typeof useActivator>, 'activatorEl' | 'activatorEvents'>\n) {\n watch(() => props.activator, (val, oldVal) => {\n if (oldVal && val !== oldVal) {\n const activator = getActivator(oldVal)\n activator && unbindActivatorProps(activator)\n }\n if (val) {\n nextTick(() => bindActivatorProps())\n }\n }, { immediate: true })\n\n watch(() => props.activatorProps, () => {\n bindActivatorProps()\n })\n\n onScopeDispose(() => {\n unbindActivatorProps()\n })\n\n function bindActivatorProps (el = getActivator(), _props = props.activatorProps) {\n if (!el) return\n\n bindProps(el, mergeProps(activatorEvents.value, _props))\n }\n\n function unbindActivatorProps (el = getActivator(), _props = props.activatorProps) {\n if (!el) return\n\n unbindProps(el, mergeProps(activatorEvents.value, _props))\n }\n\n function getActivator (selector = props.activator): HTMLElement | undefined {\n let activator\n if (selector) {\n if (selector === 'parent') {\n let el = vm?.proxy?.$el?.parentNode\n while (el.hasAttribute('data-no-activator')) {\n el = el.parentNode\n }\n activator = el\n } else if (typeof selector === 'string') {\n // Selector\n activator = document.querySelector(selector)\n } else if ('$el' in selector) {\n // Component (ref)\n activator = selector.$el\n } else {\n // HTMLElement | Element\n activator = selector\n }\n }\n\n // The activator should only be a valid element (Ignore comments and text nodes)\n activatorEl.value = activator?.nodeType === Node.ELEMENT_NODE ? activator : null\n\n return activatorEl.value\n }\n}\n"],"mappings":"AAAA;AAAA,SACSA,WAAW,+BAEpB;AAAA,SACSC,cAAc,EAAEC,QAAQ,uCAEjC;AACA,SACEC,QAAQ,EACRC,WAAW,EACXC,MAAM,EACNC,UAAU,EACVC,QAAQ,EACRC,cAAc,EACdC,GAAG,EACHC,KAAK,EACLC,WAAW,QACN,KAAK;AAAA,SAEVC,SAAS,EACTC,kBAAkB,EAClBC,UAAU,EACVC,eAAe,EACfC,YAAY,EACZC,UAAU,EACVC,WAAW,gCAGb;AAqBA,OAAO,MAAMC,kBAAkB,GAAGH,YAAY,CAAC;EAC7CI,SAAS,EAAE,CAACC,MAAM,EA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