ContextmenuRootForSafariCompatibility.svelte view source
Blocks the next click event. Set to true when a longpress completes to prevent iOS's synthesized click from activating the first menu item.
contextmenu?
The contextmenu prop is not reactive because that's a rare corner case and
it's easier to put the contextmenu directly in the context
rather than wrapping with a store or other reactivity.
If you need to change the contextmenu prop for some reason, use a {#key contextmenu} block:
https://svelte.dev/docs#template-syntax-key
longpress_move_tolerance?
The number of pixels the pointer can be moved without canceling longpress.
numberlongpress_duration?
The number of milliseconds after a touch starts before opening the Fuz contextmenu.
numberbypass_with_tap_then_longpress?
Whether to detect tap-then-longpress to bypass the Fuz contextmenu.
This allows access to the system contextmenu by tapping once then long-pressing.
Setting to false disables the gesture.
booleanbypass_window?
The number of milliseconds between taps to detect a gesture that bypasses the Fuz contextmenu.
Used only when bypass_with_tap_then_longpress is true.
If the duration is too long, it'll detect more false positives and interrupt normal usage,
but too short and some people will have difficulty performing the gesture.
numberbypass_move_tolerance?
The number of pixels the pointer can be moved between taps to detect a tap-then-longpress.
Used only when bypass_with_tap_then_longpress is true.
numberopen_offset_x?
The number of pixels to offset from the pointer X position when opened. Useful to ensure the first menu item is immediately under the pointer.
numberopen_offset_y?
The number of pixels to offset from the pointer Y position when opened. Useful to ensure the first menu item is immediately under the pointer.
numberscoped?
If true, wraps children with a div and listens to events on it instead of the window.
booleanlink_entry?
Snippet for rendering link entries.
Set to null to disable automatic link detection.
Defaults to link_entry_default which renders ContextmenuLinkEntry.
Snippet<[ComponentProps<typeof ContextmenuLinkEntry>]> | nulltext_entry?
Snippet for rendering copy text entries.
Set to null to disable automatic copy text detection.
Defaults to text_entry_default which renders ContextmenuTextEntry.
Snippet<[ComponentProps<typeof ContextmenuTextEntry>]> | nullseparator_entry?
Snippet for rendering separator entries.
Set to null to disable automatic separator rendering.
Defaults to separator_entry_default which renders ContextmenuSeparator.
Snippet<[ComponentProps<typeof ContextmenuSeparator>]> | nullchildren
Snippet