Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@prosekit/web

Package Overview
Dependencies
Maintainers
0
Versions
79
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@prosekit/web - npm Package Compare versions

Comparing version 0.3.19 to 0.4.0

dist/chunk-ZGQ225UP.js

1105

dist/_tsup-dts-rollup.d.ts

@@ -1,14 +0,11 @@

import { BaseElement } from '@aria-ui/core';
import { AutoUpdateOptions } from '@floating-ui/dom';
import { BaseElementConstructor } from '@aria-ui/core';
import { ConnectableElement } from '@aria-ui/core';
import { Context } from '@aria-ui/core';
import { config as default_alias_1 } from '@prosekit/dev/config-vitest';
import { defaultPopoverContentProps } from '@aria-ui/popover';
import { defaultPopoverRootProps } from '@aria-ui/popover';
import { defaultPopoverTriggerProps } from '@aria-ui/popover';
import { defaultTooltipRootProps } from '@aria-ui/tooltip';
import { defaultTooltipTriggerProps } from '@aria-ui/tooltip';
import type { defineTableCommands } from '@prosekit/extensions/table';
import { Editor } from '@prosekit/core';
import type { EditorView } from '@prosekit/pm/view';
import type { EmptyObject } from '@aria-ui/core';
import { ElementContext } from '@floating-ui/dom';
import { EventDeclarations } from '@aria-ui/core';
import type { Extension } from '@prosekit/core';

@@ -18,27 +15,56 @@ import { FocusChangeHandler } from '@prosekit/core';

import { Keymap } from '@prosekit/core';
import { ListboxEvents } from '@aria-ui/listbox';
import { ListboxItemEvents } from '@aria-ui/listbox';
import { ListboxProps } from '@aria-ui/listbox';
import { MenuContentProps } from '@aria-ui/menu';
import { MenuContentEvents } from '@aria-ui/menu/elements';
import { MenuContentProps } from '@aria-ui/menu/elements';
import { MenuItemEvents } from '@aria-ui/menu';
import { MenuItemProps } from '@aria-ui/menu';
import { Options } from 'tsup';
import { OverlayPositionerProps } from '@aria-ui/overlay';
import type { Placement } from '@floating-ui/dom';
import { OverlayPositionerEvents } from '@aria-ui/overlay/elements';
import { OverlayPositionerEvents as OverlayPositionerEvents_2 } from '@aria-ui/overlay';
import { OverlayPositionerProps } from '@aria-ui/overlay/elements';
import { OverlayPositionerProps as OverlayPositionerProps_2 } from '@aria-ui/overlay';
import { Placement } from '@floating-ui/dom';
import { PlainExtension } from '@prosekit/core';
import { PopoverContentProps } from '@aria-ui/popover';
import { PopoverRootProps } from '@aria-ui/popover';
import { PopoverTriggerProps } from '@aria-ui/popover';
import { popoverContentEvents } from '@aria-ui/popover/elements';
import type { PopoverContentEvents as PopoverContentEvents_2 } from '@aria-ui/popover/elements';
import { popoverContentProps } from '@aria-ui/popover/elements';
import type { PopoverContentProps as PopoverContentProps_2 } from '@aria-ui/popover/elements';
import { popoverRootEvents } from '@aria-ui/popover/elements';
import type { PopoverRootEvents as PopoverRootEvents_2 } from '@aria-ui/popover/elements';
import { popoverRootProps } from '@aria-ui/popover/elements';
import type { PopoverRootProps as PopoverRootProps_2 } from '@aria-ui/popover/elements';
import { popoverTriggerEvents } from '@aria-ui/popover/elements';
import type { PopoverTriggerEvents as PopoverTriggerEvents_2 } from '@aria-ui/popover/elements';
import { popoverTriggerProps } from '@aria-ui/popover/elements';
import type { PopoverTriggerProps as PopoverTriggerProps_2 } from '@aria-ui/popover/elements';
import { PropDeclaration } from '@aria-ui/core';
import { PropDeclarations } from '@aria-ui/core';
import type { ProseMirrorNode } from '@prosekit/pm/model';
import { ReadonlySignal } from '@aria-ui/core';
import type { ReferenceElement } from '@floating-ui/dom';
import { RootBoundary } from '@floating-ui/dom';
import { SetupOptions } from '@aria-ui/core';
import { SignalState } from '@aria-ui/core';
import { TooltipContentProps } from '@aria-ui/tooltip';
import { TooltipRootProps } from '@aria-ui/tooltip';
import { TooltipTriggerProps } from '@aria-ui/tooltip';
import { tooltipContentEvents } from '@aria-ui/tooltip';
import { TooltipContentEvents as TooltipContentEvents_2 } from '@aria-ui/tooltip';
import { TooltipContentProps as TooltipContentProps_2 } from '@aria-ui/tooltip';
import { tooltipRootEvents } from '@aria-ui/tooltip/elements';
import type { TooltipRootEvents as TooltipRootEvents_2 } from '@aria-ui/tooltip/elements';
import { tooltipRootProps } from '@aria-ui/tooltip/elements';
import type { TooltipRootProps as TooltipRootProps_2 } from '@aria-ui/tooltip/elements';
import { tooltipTriggerEvents } from '@aria-ui/tooltip/elements';
import type { TooltipTriggerEvents as TooltipTriggerEvents_2 } from '@aria-ui/tooltip/elements';
import { tooltipTriggerProps } from '@aria-ui/tooltip/elements';
import type { TooltipTriggerProps as TooltipTriggerProps_2 } from '@aria-ui/tooltip/elements';
import { Union } from '@prosekit/core';
import { UpdateHandler } from '@prosekit/core';
import { usePopoverContent } from '@aria-ui/popover';
import { usePopoverRoot } from '@aria-ui/popover';
import { usePopoverTrigger } from '@aria-ui/popover';
import { useTooltipContent } from '@aria-ui/tooltip';
import { useTooltipRoot } from '@aria-ui/tooltip';
import { useTooltipTrigger } from '@aria-ui/tooltip';
import { useListboxEmpty } from '@aria-ui/listbox/elements';
import { usePopoverContent } from '@aria-ui/popover/elements';
import { usePopoverRoot } from '@aria-ui/popover/elements';
import { usePopoverTrigger } from '@aria-ui/popover/elements';
import { useTooltipContent } from '@aria-ui/tooltip/elements';
import { useTooltipRoot } from '@aria-ui/tooltip/elements';
import { useTooltipTrigger } from '@aria-ui/tooltip/elements';
import type { VirtualElement } from '@floating-ui/dom';

@@ -51,12 +77,26 @@

declare const AutocompleteEmptyElement_base: {
new (): BaseElement & AutocompleteEmptyProps;
prototype: HTMLElement;
};
declare const AutocompleteEmptyElement_base: BaseElementConstructor<AutocompleteEmptyProps>;
declare interface AutocompleteEmptyProps extends EmptyObject {
/** @internal */
declare interface AutocompleteEmptyEvents {
}
export { AutocompleteEmptyEvents }
export { AutocompleteEmptyEvents as AutocompleteEmptyEvents_alias_1 }
/** @internal */
declare const autocompleteEmptyEvents: EventDeclarations<AutocompleteEmptyEvents>;
export { autocompleteEmptyEvents }
export { autocompleteEmptyEvents as autocompleteEmptyEvents_alias_1 }
/** @internal */
declare interface AutocompleteEmptyProps {
}
export { AutocompleteEmptyProps }
export { AutocompleteEmptyProps as AutocompleteEmptyProps_alias_1 }
/** @internal */
declare const autocompleteEmptyProps: PropDeclarations<AutocompleteEmptyProps>;
export { autocompleteEmptyProps }
export { autocompleteEmptyProps as autocompleteEmptyProps_alias_1 }
declare class AutocompleteItemElement extends AutocompleteItemElement_base {

@@ -67,7 +107,14 @@ }

declare const AutocompleteItemElement_base: {
new (): BaseElement & AutocompleteItemProps;
prototype: HTMLElement;
};
declare const AutocompleteItemElement_base: BaseElementConstructor<AutocompleteItemProps>;
declare interface AutocompleteItemEvents extends ListboxItemEvents {
}
export { AutocompleteItemEvents }
export { AutocompleteItemEvents as AutocompleteItemEvents_alias_1 }
/** @internal */
declare const autocompleteItemEvents: EventDeclarations<AutocompleteItemEvents>;
export { autocompleteItemEvents }
export { autocompleteItemEvents as autocompleteItemEvents_alias_1 }
declare interface AutocompleteItemProps {

@@ -82,8 +129,2 @@ /**

value: string;
/**
* The function to call when the item is selected.
*
* @default null
*/
onSelect: VoidFunction | null;
}

@@ -93,2 +134,7 @@ export { AutocompleteItemProps }

/** @internal */
declare const autocompleteItemProps: PropDeclarations<AutocompleteItemProps>;
export { autocompleteItemProps }
export { autocompleteItemProps as autocompleteItemProps_alias_1 }
declare class AutocompleteListElement extends AutocompleteListElement_base {

@@ -99,8 +145,20 @@ }

declare const AutocompleteListElement_base: {
new (): BaseElement & AutocompleteListProps;
prototype: HTMLElement;
};
declare const AutocompleteListElement_base: BaseElementConstructor<AutocompleteListProps>;
declare interface AutocompleteListEvents extends ListboxEvents {
}
export { AutocompleteListEvents }
export { AutocompleteListEvents as AutocompleteListEvents_alias_1 }
declare const autocompleteListEvents: EventDeclarations<ListboxEvents>;
export { autocompleteListEvents }
export { autocompleteListEvents as autocompleteListEvents_alias_1 }
declare interface AutocompleteListProps extends Pick<ListboxProps, 'filter'> {
/**
* The ProseKit editor instance.
*
* @default null
* @hidden
*/
editor: Editor | null;

@@ -111,2 +169,11 @@ }

declare const autocompleteListProps: {
filter: PropDeclaration<ItemFilter | null>;
editor: {
default: null;
};
};
export { autocompleteListProps }
export { autocompleteListProps as autocompleteListProps_alias_1 }
declare class AutocompletePopoverElement extends AutocompletePopoverElement_base {

@@ -117,7 +184,14 @@ }

declare const AutocompletePopoverElement_base: {
new (): BaseElement & AutocompletePopoverProps;
prototype: HTMLElement;
};
declare const AutocompletePopoverElement_base: BaseElementConstructor<AutocompletePopoverProps>;
declare interface AutocompletePopoverEvents extends OverlayPositionerEvents {
}
export { AutocompletePopoverEvents }
export { AutocompletePopoverEvents as AutocompletePopoverEvents_alias_1 }
/** @internal */
declare const autocompletePopoverEvents: EventDeclarations<AutocompletePopoverEvents>;
export { autocompletePopoverEvents }
export { autocompletePopoverEvents as autocompletePopoverEvents_alias_1 }
declare interface AutocompletePopoverProps extends OverlayPositionerProps {

@@ -128,2 +202,3 @@ /**

* @default null
* @hidden
*/

@@ -181,26 +256,53 @@ editor: Editor | null;

declare class BlockDragHandleElement extends BlockDragHandleElement_base {
}
export { BlockDragHandleElement }
export { BlockDragHandleElement as BlockDragHandleElement_alias_1 }
declare const BlockDragHandleElement_base: {
new (): BaseElement & BlockDragHandleProps;
prototype: HTMLElement;
/** @internal */
declare const autocompletePopoverProps: {
readonly editor: {
readonly default: null;
};
readonly regex: {
readonly default: null;
};
readonly onQueryChange: {
readonly default: null;
};
readonly onOpenChange: {
readonly default: null;
};
readonly placement: {
readonly default: "bottom-start";
};
readonly offset: {
readonly default: 4;
};
readonly inline: {
readonly default: true;
};
readonly hoist: {
readonly default: true;
};
readonly fitViewport: {
readonly default: true;
};
readonly boundary: {
readonly default: HTMLBodyElement | "clippingAncestors";
};
readonly overflowPadding: {
readonly default: 8;
};
readonly strategy: PropDeclaration<"fixed" | "absolute">;
readonly autoUpdate: PropDeclaration<boolean | AutoUpdateOptions>;
readonly transform: PropDeclaration<boolean>;
readonly flip: PropDeclaration<boolean | Placement[]>;
readonly shift: PropDeclaration<boolean>;
readonly overlap: PropDeclaration<boolean>;
readonly sameWidth: PropDeclaration<boolean>;
readonly sameHeight: PropDeclaration<boolean>;
readonly hide: PropDeclaration<boolean>;
readonly rootBoundary: PropDeclaration<RootBoundary>;
readonly elementContext: PropDeclaration<ElementContext>;
readonly altBoundary: PropDeclaration<boolean>;
};
export { autocompletePopoverProps }
export { autocompletePopoverProps as autocompletePopoverProps_alias_1 }
/**
* @deprecated Use `BlockHandleDraggableProps` instead.
*/
declare interface BlockDragHandleProps {
/**
* The ProseKit editor instance.
*
* @default null
*/
editor: Editor | null;
}
export { BlockDragHandleProps }
export { BlockDragHandleProps as BlockDragHandleProps_alias_1 }
declare class BlockHandleAddElement extends BlockHandleAddElement_base {

@@ -211,7 +313,15 @@ }

declare const BlockHandleAddElement_base: {
new (): BaseElement & BlockHandleAddProps;
prototype: HTMLElement;
};
declare const BlockHandleAddElement_base: BaseElementConstructor<BlockHandleAddProps>;
/** @internal */
declare interface BlockHandleAddEvents {
}
export { BlockHandleAddEvents }
export { BlockHandleAddEvents as BlockHandleAddEvents_alias_1 }
/** @internal */
declare const blockHandleAddEvents: EventDeclarations<BlockHandleAddEvents>;
export { blockHandleAddEvents }
export { blockHandleAddEvents as blockHandleAddEvents_alias_1 }
declare interface BlockHandleAddProps {

@@ -222,2 +332,3 @@ /**

* @default null
* @hidden
*/

@@ -229,2 +340,7 @@ editor: Editor | null;

/** @internal */
declare const blockHandleAddProps: PropDeclarations<BlockHandleAddProps>;
export { blockHandleAddProps }
export { blockHandleAddProps as blockHandleAddProps_alias_1 }
declare class BlockHandleDraggableElement extends BlockHandleDraggableElement_base {

@@ -235,7 +351,15 @@ }

declare const BlockHandleDraggableElement_base: {
new (): BaseElement & BlockHandleDraggableProps;
prototype: HTMLElement;
};
declare const BlockHandleDraggableElement_base: BaseElementConstructor<BlockHandleDraggableProps>;
/** @internal */
declare interface BlockHandleDraggableEvents {
}
export { BlockHandleDraggableEvents }
export { BlockHandleDraggableEvents as BlockHandleDraggableEvents_alias_1 }
/** @internal */
declare const blockHandleDraggableEvents: EventDeclarations<BlockHandleDraggableEvents>;
export { blockHandleDraggableEvents }
export { blockHandleDraggableEvents as blockHandleDraggableEvents_alias_1 }
declare interface BlockHandleDraggableProps {

@@ -246,2 +370,3 @@ /**

* @default null
* @hidden
*/

@@ -253,2 +378,7 @@ editor: Editor | null;

/** @internal */
declare const blockHandleDraggableProps: PropDeclarations<BlockHandleDraggableProps>;
export { blockHandleDraggableProps }
export { blockHandleDraggableProps as blockHandleDraggableProps_alias_1 }
declare class BlockHandlePopoverElement extends BlockHandlePopoverElement_base {

@@ -259,33 +389,16 @@ }

declare const BlockHandlePopoverElement_base: {
new (): BaseElement & BlockHandlePopoverProps;
prototype: HTMLElement;
};
declare const BlockHandlePopoverElement_base: BaseElementConstructor<BlockHandlePopoverProps>;
declare interface BlockHandlePopoverProps extends BlockPopoverProps {
/** @internal */
declare interface BlockHandlePopoverEvents {
}
export { BlockHandlePopoverProps }
export { BlockHandlePopoverProps as BlockHandlePopoverProps_alias_1 }
export { BlockHandlePopoverEvents }
export { BlockHandlePopoverEvents as BlockHandlePopoverEvents_alias_1 }
/**
* @internal
*/
export declare type BlockPopoverContext = HoverState | null;
/** @internal */
declare const blockHandlePopoverEvents: EventDeclarations<BlockHandlePopoverEvents>;
export { blockHandlePopoverEvents }
export { blockHandlePopoverEvents as blockHandlePopoverEvents_alias_1 }
/**
* @internal
*/
export declare const blockPopoverContext: Context<BlockPopoverContext>;
declare class BlockPopoverElement extends BlockPopoverElement_base {
}
export { BlockPopoverElement }
export { BlockPopoverElement as BlockPopoverElement_alias_1 }
declare const BlockPopoverElement_base: {
new (): BaseElement & BlockPopoverProps;
prototype: HTMLElement;
};
declare interface BlockPopoverProps extends Omit<OverlayPositionerProps, 'placement' | 'offset'> {
declare interface BlockHandlePopoverProps extends Omit<OverlayPositionerProps, 'placement' | 'offset'> {
/**

@@ -295,2 +408,3 @@ * The ProseKit editor instance.

* @default null
* @hidden
*/

@@ -311,5 +425,20 @@ editor: Editor | null;

}
export { BlockPopoverProps }
export { BlockPopoverProps as BlockPopoverProps_alias_1 }
export { BlockHandlePopoverProps }
export { BlockHandlePopoverProps as BlockHandlePopoverProps_alias_1 }
/** @internal */
declare const blockHandlePopoverProps: PropDeclarations<BlockHandlePopoverProps>;
export { blockHandlePopoverProps }
export { blockHandlePopoverProps as blockHandlePopoverProps_alias_1 }
/**
* @internal
*/
export declare type BlockPopoverContext = HoverState | null;
/**
* @internal
*/
export declare const blockPopoverContext: Context<BlockPopoverContext>;
export declare function calcResize(position: 'top' | 'right' | 'bottom' | 'left' | 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right', w: number, h: number, dx: number, dy: number, aspectRatio: number | null | undefined): [w: number, h: number];

@@ -321,317 +450,4 @@

declare const defaultAutocompleteEmptyProps: {};
export { defaultAutocompleteEmptyProps }
export { defaultAutocompleteEmptyProps as defaultAutocompleteEmptyProps_alias_1 }
declare const defaultAutocompleteItemProps: {
value: string;
onSelect: null;
};
export { defaultAutocompleteItemProps }
export { defaultAutocompleteItemProps as defaultAutocompleteItemProps_alias_1 }
declare const defaultAutocompleteListProps: {
filter: (options: {
query: string;
value: string;
}) => boolean;
editor: null;
};
export { defaultAutocompleteListProps }
export { defaultAutocompleteListProps as defaultAutocompleteListProps_alias_1 }
declare const defaultAutocompletePopoverProps: Readonly<{
editor: null;
regex: null;
onQueryChange: null;
onOpenChange: null;
placement: "bottom-start";
offset: 4;
inline: true;
hoist: true;
fitViewport: true;
boundary: HTMLBodyElement | "clippingAncestors";
overflowPadding: 8;
strategy: "absolute";
autoUpdate: true;
transform: false;
flip: false;
shift: false;
overlap: false;
sameWidth: false;
sameHeight: false;
hide: false;
rootBoundary: "viewport";
elementContext: "floating";
altBoundary: true;
}>;
export { defaultAutocompletePopoverProps }
export { defaultAutocompletePopoverProps as defaultAutocompletePopoverProps_alias_1 }
declare const defaultBlockDragHandleProps: Readonly<{
editor: null;
}>;
export { defaultBlockDragHandleProps }
export { defaultBlockDragHandleProps as defaultBlockDragHandleProps_alias_1 }
declare const defaultBlockHandleAddProps: Readonly<{
editor: null;
}>;
export { defaultBlockHandleAddProps }
export { defaultBlockHandleAddProps as defaultBlockHandleAddProps_alias_1 }
declare const defaultBlockHandleDraggableProps: Readonly<{
editor: null;
}>;
export { defaultBlockHandleDraggableProps }
export { defaultBlockHandleDraggableProps as defaultBlockHandleDraggableProps_alias_1 }
declare const defaultBlockHandlePopoverProps: Readonly<{
editor: null;
placement: "left-start";
offset: 4;
strategy: "absolute";
autoUpdate: true;
hoist: false;
transform: false;
flip: false;
shift: false;
overlap: false;
fitViewport: false;
sameWidth: false;
sameHeight: false;
inline: false;
hide: false;
boundary: "clippingAncestors";
rootBoundary: "viewport";
overflowPadding: 0;
elementContext: "floating";
altBoundary: true;
}>;
export { defaultBlockHandlePopoverProps }
export { defaultBlockHandlePopoverProps as defaultBlockHandlePopoverProps_alias_1 }
declare const defaultBlockPopoverProps: Readonly<{
editor: null;
placement: "left-start";
offset: 4;
strategy: "absolute";
autoUpdate: true;
hoist: false;
transform: false;
flip: false;
shift: false;
overlap: false;
fitViewport: false;
sameWidth: false;
sameHeight: false;
inline: false;
hide: false;
boundary: "clippingAncestors";
rootBoundary: "viewport";
overflowPadding: 0;
elementContext: "floating";
altBoundary: true;
}>;
export { defaultBlockPopoverProps }
export { defaultBlockPopoverProps as defaultBlockPopoverProps_alias_1 }
declare const defaultInlinePopoverProps: Readonly<{
editor: null;
defaultOpen: true;
open: false;
onOpenChange: null;
dismissOnEscape: true;
placement: "top";
offset: 12;
shift: true;
flip: true;
hide: true;
overlap: true;
inline: true;
overflowPadding: 8;
hoist: true;
boundary: never[];
strategy: "absolute";
autoUpdate: true;
transform: false;
fitViewport: false;
sameWidth: false;
sameHeight: false;
rootBoundary: "viewport";
elementContext: "floating";
altBoundary: true;
}>;
export { defaultInlinePopoverProps }
export { defaultInlinePopoverProps as defaultInlinePopoverProps_alias_1 }
export { defaultPopoverContentProps }
export { defaultPopoverContentProps as defaultPopoverContentProps_alias_1 }
export { defaultPopoverRootProps }
export { defaultPopoverRootProps as defaultPopoverRootProps_alias_1 }
export { defaultPopoverTriggerProps }
export { defaultPopoverTriggerProps as defaultPopoverTriggerProps_alias_1 }
export declare function defaultQueryBuilder(match: RegExpExecArray): string;
declare const defaultResizableHandleProps: {
position: "bottom-right";
};
export { defaultResizableHandleProps }
export { defaultResizableHandleProps as defaultResizableHandleProps_alias_1 }
declare const defaultResizableRootProps: {
width: null;
height: null;
aspectRatio: null;
onSizeChangeStart: null;
onSizeChange: null;
onSizeChangeEnd: null;
};
export { defaultResizableRootProps }
export { defaultResizableRootProps as defaultResizableRootProps_alias_1 }
declare const defaultTableHandleColumnRootProps: Readonly<{
editor: null;
placement: "top";
strategy: "absolute";
autoUpdate: true;
hoist: false;
transform: false;
offset: null;
flip: false;
shift: false;
overlap: false;
fitViewport: false;
sameWidth: false;
sameHeight: false;
inline: false;
hide: false;
boundary: "clippingAncestors";
rootBoundary: "viewport";
overflowPadding: 0;
elementContext: "floating";
altBoundary: true;
}>;
export { defaultTableHandleColumnRootProps }
export { defaultTableHandleColumnRootProps as defaultTableHandleColumnRootProps_alias_1 }
declare const defaultTableHandleColumnTriggerProps: Readonly<{
editor: null;
}>;
export { defaultTableHandleColumnTriggerProps }
export { defaultTableHandleColumnTriggerProps as defaultTableHandleColumnTriggerProps_alias_1 }
declare const defaultTableHandlePopoverContentProps: Readonly<{
placement: "right-start";
offset: {
mainAxis: number;
crossAxis: number;
};
editor: null;
onKeydownHandlerAdd: null;
hoist: true;
flip: true;
shift: true;
overflowPadding: 4;
onEscapeKeyDown: null;
onPointerDownOutside: null;
onFocusOutside: null;
onInteractOutside: null;
strategy: "absolute";
autoUpdate: true;
transform: false;
overlap: false;
fitViewport: false;
sameWidth: false;
sameHeight: false;
inline: false;
hide: false;
boundary: "clippingAncestors";
rootBoundary: "viewport";
elementContext: "floating";
altBoundary: true;
}>;
export { defaultTableHandlePopoverContentProps }
export { defaultTableHandlePopoverContentProps as defaultTableHandlePopoverContentProps_alias_1 }
declare const defaultTableHandlePopoverItemProps: Readonly<{
disabled: false;
value: "";
query: "";
filter: ItemFilter;
onSelect: null;
}>;
export { defaultTableHandlePopoverItemProps }
export { defaultTableHandlePopoverItemProps as defaultTableHandlePopoverItemProps_alias_1 }
declare const defaultTableHandleRootProps: Readonly<{
editor: null;
}>;
export { defaultTableHandleRootProps }
export { defaultTableHandleRootProps as defaultTableHandleRootProps_alias_1 }
declare const defaultTableHandleRowRootProps: Readonly<{
editor: null;
placement: "left";
strategy: "absolute";
autoUpdate: true;
hoist: false;
transform: false;
offset: null;
flip: false;
shift: false;
overlap: false;
fitViewport: false;
sameWidth: false;
sameHeight: false;
inline: false;
hide: false;
boundary: "clippingAncestors";
rootBoundary: "viewport";
overflowPadding: 0;
elementContext: "floating";
altBoundary: true;
}>;
export { defaultTableHandleRowRootProps }
export { defaultTableHandleRowRootProps as defaultTableHandleRowRootProps_alias_1 }
declare const defaultTableHandleRowTriggerProps: Readonly<{
editor: null;
}>;
export { defaultTableHandleRowTriggerProps }
export { defaultTableHandleRowTriggerProps as defaultTableHandleRowTriggerProps_alias_1 }
declare const defaultTooltipContentProps: {
shift: true;
flip: true;
offset: number;
overflowPadding: number;
hoist: true;
boundary: never[];
strategy: "absolute";
placement: "top";
autoUpdate: true;
transform: false;
overlap: false;
fitViewport: false;
sameWidth: false;
sameHeight: false;
inline: false;
hide: false;
rootBoundary: "viewport";
elementContext: "floating";
altBoundary: true;
};
export { defaultTooltipContentProps }
export { defaultTooltipContentProps as defaultTooltipContentProps_alias_1 }
export { defaultTooltipRootProps }
export { defaultTooltipRootProps as defaultTooltipRootProps_alias_1 }
export { defaultTooltipTriggerProps }
export { defaultTooltipTriggerProps as defaultTooltipTriggerProps_alias_1 }
export declare function defineCustomElement(name: string, constructor: CustomElementConstructor, options?: ElementDefinitionOptions): void;

@@ -645,2 +461,4 @@

export declare function getStateWithDefaults<Props extends Record<string, any> = Record<string, any>>(state: Partial<SignalState<Props>>, props: PropDeclarations<Props>): SignalState<Props>;
export declare function getVirtualSelectionElement(view: EditorView): ReferenceElement | undefined;

@@ -670,8 +488,16 @@

declare const InlinePopoverElement_base: {
new (): BaseElement & InlinePopoverProps;
prototype: HTMLElement;
};
declare const InlinePopoverElement_base: BaseElementConstructor<InlinePopoverProps>;
declare interface InlinePopoverProps extends Omit<OverlayPositionerProps, 'placement' | 'offset'> {
/** @internal */
declare interface InlinePopoverEvents extends OverlayPositionerEvents_2 {
}
export { InlinePopoverEvents }
export { InlinePopoverEvents as InlinePopoverEvents_alias_1 }
/** @internal */
declare const inlinePopoverEvents: EventDeclarations<InlinePopoverEvents>;
export { inlinePopoverEvents }
export { inlinePopoverEvents as inlinePopoverEvents_alias_1 }
declare interface InlinePopoverProps extends Omit<OverlayPositionerProps_2, 'placement' | 'offset'> {
/**

@@ -681,2 +507,3 @@ * The ProseKit editor instance.

* @default null
* @hidden
*/

@@ -723,27 +550,27 @@ editor: Editor | null;

*/
placement: OverlayPositionerProps['placement'];
placement: OverlayPositionerProps_2['placement'];
/**
* @default 12
*/
offset: OverlayPositionerProps['offset'];
offset: OverlayPositionerProps_2['offset'];
/**
* @default true
*/
flip: OverlayPositionerProps['flip'];
flip: OverlayPositionerProps_2['flip'];
/**
* @default true
*/
hide: OverlayPositionerProps['hide'];
hide: OverlayPositionerProps_2['hide'];
/**
* @default true
*/
overlap: OverlayPositionerProps['overlap'];
overlap: OverlayPositionerProps_2['overlap'];
/**
* @default true
*/
inline: OverlayPositionerProps['inline'];
inline: OverlayPositionerProps_2['inline'];
/**
* @default true
*/
hoist: OverlayPositionerProps['hoist'];
hoist: OverlayPositionerProps_2['hoist'];
}

@@ -753,2 +580,7 @@ export { InlinePopoverProps }

/** @internal */
declare const inlinePopoverProps: PropDeclarations<InlinePopoverProps>;
export { inlinePopoverProps }
export { inlinePopoverProps as inlinePopoverProps_alias_1 }
export declare function isFinitePositiveNumber(value: unknown): value is number;

@@ -797,10 +629,20 @@

declare const PopoverContentElement_base: {
new (): BaseElement & PopoverContentProps;
prototype: HTMLElement;
};
declare const PopoverContentElement_base: BaseElementConstructor<PopoverContentProps>;
declare interface PopoverContentEvents extends PopoverContentEvents_2 {
}
export { PopoverContentEvents }
export { PopoverContentEvents as PopoverContentEvents_alias_1 }
export { popoverContentEvents }
export { popoverContentEvents as popoverContentEvents_alias_1 }
declare interface PopoverContentProps extends PopoverContentProps_2 {
}
export { PopoverContentProps }
export { PopoverContentProps as PopoverContentProps_alias_1 }
export { popoverContentProps }
export { popoverContentProps as popoverContentProps_alias_1 }
declare class PopoverRootElement extends PopoverRootElement_base {

@@ -811,10 +653,20 @@ }

declare const PopoverRootElement_base: {
new (): BaseElement & PopoverRootProps;
prototype: HTMLElement;
};
declare const PopoverRootElement_base: BaseElementConstructor<PopoverRootProps>;
declare interface PopoverRootEvents extends PopoverRootEvents_2 {
}
export { PopoverRootEvents }
export { PopoverRootEvents as PopoverRootEvents_alias_1 }
export { popoverRootEvents }
export { popoverRootEvents as popoverRootEvents_alias_1 }
declare interface PopoverRootProps extends PopoverRootProps_2 {
}
export { PopoverRootProps }
export { PopoverRootProps as PopoverRootProps_alias_1 }
export { popoverRootProps }
export { popoverRootProps as popoverRootProps_alias_1 }
declare class PopoverTriggerElement extends PopoverTriggerElement_base {

@@ -825,10 +677,20 @@ }

declare const PopoverTriggerElement_base: {
new (): BaseElement & PopoverTriggerProps;
prototype: HTMLElement;
};
declare const PopoverTriggerElement_base: BaseElementConstructor<PopoverTriggerProps>;
declare interface PopoverTriggerEvents extends PopoverTriggerEvents_2 {
}
export { PopoverTriggerEvents }
export { PopoverTriggerEvents as PopoverTriggerEvents_alias_1 }
export { popoverTriggerEvents }
export { popoverTriggerEvents as popoverTriggerEvents_alias_1 }
declare interface PopoverTriggerProps extends PopoverTriggerProps_2 {
}
export { PopoverTriggerProps }
export { PopoverTriggerProps as PopoverTriggerProps_alias_1 }
export { popoverTriggerProps }
export { popoverTriggerProps as popoverTriggerProps_alias_1 }
export declare const queryContext: Context<string>;

@@ -841,7 +703,15 @@

declare const ResizableHandleElement_base: {
new (): BaseElement & ResizableHandleProps;
prototype: HTMLElement;
};
declare const ResizableHandleElement_base: BaseElementConstructor<ResizableHandleProps>;
/** @internal */
declare interface ResizableHandleEvents {
}
export { ResizableHandleEvents }
export { ResizableHandleEvents as ResizableHandleEvents_alias_1 }
/** @internal */
declare const resizableHandleEvents: EventDeclarations<ResizableHandleEvents>;
export { resizableHandleEvents }
export { resizableHandleEvents as resizableHandleEvents_alias_1 }
declare interface ResizableHandleProps {

@@ -858,2 +728,7 @@ /**

/** @internal */
declare const resizableHandleProps: PropDeclarations<ResizableHandleProps>;
export { resizableHandleProps }
export { resizableHandleProps as resizableHandleProps_alias_1 }
declare class ResizableRootElement extends ResizableRootElement_base {

@@ -864,27 +739,35 @@ }

declare const ResizableRootElement_base: {
new (): BaseElement & ResizableRootProps;
prototype: HTMLElement;
};
declare const ResizableRootElement_base: BaseElementConstructor<ResizableRootProps>;
declare interface ResizableRootProps {
width: number | null;
height: number | null;
aspectRatio: number | null;
onSizeChangeStart: ((size: {
declare interface ResizableRootEvents {
resizeStart: CustomEvent<{
width: number;
height: number;
}) => void) | null;
onSizeChange: ((size: {
}>;
resizeEnd: CustomEvent<{
width: number;
height: number;
}) => void) | null;
onSizeChangeEnd: ((size: {
width: number;
height: number;
}) => void) | null;
}>;
}
export { ResizableRootEvents }
export { ResizableRootEvents as ResizableRootEvents_alias_1 }
/** @internal */
declare const resizableRootEvents: EventDeclarations<ResizableRootEvents>;
export { resizableRootEvents }
export { resizableRootEvents as resizableRootEvents_alias_1 }
declare interface ResizableRootProps {
width: number | null;
height: number | null;
aspectRatio: number | null;
}
export { ResizableRootProps }
export { ResizableRootProps as ResizableRootProps_alias_1 }
/** @internal */
declare const resizableRootProps: PropDeclarations<ResizableRootProps>;
export { resizableRootProps }
export { resizableRootProps as resizableRootProps_alias_1 }
declare type TableCommandsExtension = ReturnType<typeof defineTableCommands>;

@@ -899,8 +782,16 @@

declare const TableHandleColumnRootElement_base: {
new (): BaseElement & TableHandleColumnRootProps;
prototype: HTMLElement;
};
declare const TableHandleColumnRootElement_base: BaseElementConstructor<TableHandleColumnRootProps>;
declare interface TableHandleColumnRootProps extends Omit<OverlayPositionerProps, 'placement'> {
/** @internal */
declare interface TableHandleColumnRootEvents extends OverlayPositionerEvents_2 {
}
export { TableHandleColumnRootEvents }
export { TableHandleColumnRootEvents as TableHandleColumnRootEvents_alias_1 }
/** @internal */
declare const tableHandleColumnRootEvents: EventDeclarations<TableHandleColumnRootEvents>;
export { tableHandleColumnRootEvents }
export { tableHandleColumnRootEvents as tableHandleColumnRootEvents_alias_1 }
declare interface TableHandleColumnRootProps extends Omit<OverlayPositionerProps_2, 'placement'> {
/**

@@ -910,2 +801,3 @@ * The ProseKit editor instance.

* @default null
* @hidden
*/

@@ -923,2 +815,7 @@ editor: Editor | null;

/** @internal */
declare const tableHandleColumnRootProps: PropDeclarations<TableHandleColumnRootProps>;
export { tableHandleColumnRootProps }
export { tableHandleColumnRootProps as tableHandleColumnRootProps_alias_1 }
declare class TableHandleColumnTriggerElement extends TableHandleColumnTriggerElement_base {

@@ -929,7 +826,15 @@ }

declare const TableHandleColumnTriggerElement_base: {
new (): BaseElement & TableHandleColumnTriggerProps;
prototype: HTMLElement;
};
declare const TableHandleColumnTriggerElement_base: BaseElementConstructor<TableHandleColumnTriggerProps>;
/** @internal */
declare interface TableHandleColumnTriggerEvents {
}
export { TableHandleColumnTriggerEvents }
export { TableHandleColumnTriggerEvents as TableHandleColumnTriggerEvents_alias_1 }
/** @internal */
declare const tableHandleColumnTriggerEvents: EventDeclarations<TableHandleColumnTriggerEvents>;
export { tableHandleColumnTriggerEvents }
export { tableHandleColumnTriggerEvents as tableHandleColumnTriggerEvents_alias_1 }
declare interface TableHandleColumnTriggerProps {

@@ -941,2 +846,7 @@ editor: Editor<TableCommandsExtension> | null;

/** @internal */
declare const tableHandleColumnTriggerProps: PropDeclarations<TableHandleColumnTriggerProps>;
export { tableHandleColumnTriggerProps }
export { tableHandleColumnTriggerProps as tableHandleColumnTriggerProps_alias_1 }
declare class TableHandlePopoverContentElement extends TableHandlePopoverContentElement_base {

@@ -947,7 +857,14 @@ }

declare const TableHandlePopoverContentElement_base: {
new (): BaseElement & TableHandlePopoverContentProps;
prototype: HTMLElement;
};
declare const TableHandlePopoverContentElement_base: BaseElementConstructor<TableHandlePopoverContentProps>;
declare interface TableHandlePopoverContentEvents extends MenuContentEvents {
}
export { TableHandlePopoverContentEvents }
export { TableHandlePopoverContentEvents as TableHandlePopoverContentEvents_alias_1 }
/** @internal */
declare const tableHandlePopoverContentEvents: EventDeclarations<TableHandlePopoverContentEvents>;
export { tableHandlePopoverContentEvents }
export { tableHandlePopoverContentEvents as tableHandlePopoverContentEvents_alias_1 }
declare interface TableHandlePopoverContentProps extends Omit<MenuContentProps, 'placement' | 'offset'> {

@@ -967,2 +884,7 @@ /**

/** @internal */
declare const tableHandlePopoverContentProps: PropDeclarations<TableHandlePopoverContentProps>;
export { tableHandlePopoverContentProps }
export { tableHandlePopoverContentProps as tableHandlePopoverContentProps_alias_1 }
declare class TableHandlePopoverItemElement extends TableHandlePopoverItemElement_base {

@@ -973,9 +895,15 @@ }

declare const TableHandlePopoverItemElement_base: {
new (): BaseElement & TableHandlePopoverItemProps;
prototype: HTMLElement;
};
declare const TableHandlePopoverItemElement_base: BaseElementConstructor<TableHandlePopoverItemProps>;
declare interface TableHandlePopoverItemEvents extends MenuItemEvents {
}
export { TableHandlePopoverItemEvents }
export { TableHandlePopoverItemEvents as TableHandlePopoverItemEvents_alias_1 }
/** @internal */
declare const tableHandlePopoverItemEvents: EventDeclarations<TableHandlePopoverItemEvents>;
export { tableHandlePopoverItemEvents }
export { tableHandlePopoverItemEvents as tableHandlePopoverItemEvents_alias_1 }
declare interface TableHandlePopoverItemProps extends MenuItemProps {
disabled?: boolean;
}

@@ -985,2 +913,7 @@ export { TableHandlePopoverItemProps }

/** @internal */
declare const tableHandlePopoverItemProps: PropDeclarations<TableHandlePopoverItemProps>;
export { tableHandlePopoverItemProps }
export { tableHandlePopoverItemProps as tableHandlePopoverItemProps_alias_1 }
/**

@@ -1001,7 +934,15 @@ * @internal

declare const TableHandleRootElement_base: {
new (): BaseElement & TableHandleRootProps;
prototype: HTMLElement;
};
declare const TableHandleRootElement_base: BaseElementConstructor<TableHandleRootProps>;
/** @internal */
declare interface TableHandleRootEvents {
}
export { TableHandleRootEvents }
export { TableHandleRootEvents as TableHandleRootEvents_alias_1 }
/** @internal */
declare const tableHandleRootEvents: EventDeclarations<TableHandleRootEvents>;
export { tableHandleRootEvents }
export { tableHandleRootEvents as tableHandleRootEvents_alias_1 }
declare interface TableHandleRootProps {

@@ -1012,2 +953,3 @@ /**

* @default null
* @hidden
*/

@@ -1019,2 +961,7 @@ editor: Editor | null;

/** @internal */
declare const tableHandleRootProps: PropDeclarations<TableHandleRootProps>;
export { tableHandleRootProps }
export { tableHandleRootProps as tableHandleRootProps_alias_1 }
declare class TableHandleRowRootElement extends TableHandleRowRootElement_base {

@@ -1025,8 +972,16 @@ }

declare const TableHandleRowRootElement_base: {
new (): BaseElement & TableHandleRowRootProps;
prototype: HTMLElement;
};
declare const TableHandleRowRootElement_base: BaseElementConstructor<TableHandleRowRootProps>;
declare interface TableHandleRowRootProps extends Omit<OverlayPositionerProps, 'placement'> {
/** @internal */
declare interface TableHandleRowRootEvents extends OverlayPositionerEvents_2 {
}
export { TableHandleRowRootEvents }
export { TableHandleRowRootEvents as TableHandleRowRootEvents_alias_1 }
/** @internal */
declare const tableHandleRowRootEvents: EventDeclarations<TableHandleRowRootEvents>;
export { tableHandleRowRootEvents }
export { tableHandleRowRootEvents as tableHandleRowRootEvents_alias_1 }
declare interface TableHandleRowRootProps extends Omit<OverlayPositionerProps_2, 'placement'> {
/**

@@ -1036,2 +991,3 @@ * The ProseKit editor instance.

* @default null
* @hidden
*/

@@ -1049,2 +1005,7 @@ editor: Editor | null;

/** @internal */
declare const tableHandleRowRootProps: PropDeclarations<TableHandleRowRootProps>;
export { tableHandleRowRootProps }
export { tableHandleRowRootProps as tableHandleRowRootProps_alias_1 }
declare class TableHandleRowTriggerElement extends TableHandleRowTriggerElement_base {

@@ -1055,7 +1016,15 @@ }

declare const TableHandleRowTriggerElement_base: {
new (): BaseElement & TableHandleRowTriggerProps;
prototype: HTMLElement;
};
declare const TableHandleRowTriggerElement_base: BaseElementConstructor<TableHandleRowTriggerProps>;
declare interface TableHandleRowTriggerEvents {
select: CustomEvent<void>;
}
export { TableHandleRowTriggerEvents }
export { TableHandleRowTriggerEvents as TableHandleRowTriggerEvents_alias_1 }
/** @internal */
declare const tableHandleRowTriggerEvents: EventDeclarations<TableHandleRowTriggerEvents>;
export { tableHandleRowTriggerEvents }
export { tableHandleRowTriggerEvents as tableHandleRowTriggerEvents_alias_1 }
declare interface TableHandleRowTriggerProps {

@@ -1067,2 +1036,7 @@ editor: Editor<TableCommandsExtension_2> | null;

/** @internal */
declare const tableHandleRowTriggerProps: PropDeclarations<TableHandleRowTriggerProps>;
export { tableHandleRowTriggerProps }
export { tableHandleRowTriggerProps as tableHandleRowTriggerProps_alias_1 }
/**

@@ -1078,10 +1052,53 @@ * @internal

declare const TooltipContentElement_base: {
new (): BaseElement & TooltipContentProps;
prototype: HTMLElement;
};
declare const TooltipContentElement_base: BaseElementConstructor<TooltipContentProps>;
declare interface TooltipContentEvents extends TooltipContentEvents_2 {
}
export { TooltipContentEvents }
export { TooltipContentEvents as TooltipContentEvents_alias_1 }
export { tooltipContentEvents }
export { tooltipContentEvents as tooltipContentEvents_alias_1 }
declare interface TooltipContentProps extends TooltipContentProps_2 {
}
export { TooltipContentProps }
export { TooltipContentProps as TooltipContentProps_alias_1 }
declare const tooltipContentProps: {
shift: {
default: boolean;
};
flip: {
default: boolean;
};
offset: {
default: number;
};
overflowPadding: {
default: number;
};
hoist: {
default: boolean;
};
boundary: {
default: never[];
};
inline: PropDeclaration<boolean>;
placement: PropDeclaration<Placement>;
fitViewport: PropDeclaration<boolean>;
strategy: PropDeclaration<"fixed" | "absolute">;
autoUpdate: PropDeclaration<boolean | AutoUpdateOptions>;
transform: PropDeclaration<boolean>;
overlap: PropDeclaration<boolean>;
sameWidth: PropDeclaration<boolean>;
sameHeight: PropDeclaration<boolean>;
hide: PropDeclaration<boolean>;
rootBoundary: PropDeclaration<RootBoundary>;
elementContext: PropDeclaration<ElementContext>;
altBoundary: PropDeclaration<boolean>;
};
export { tooltipContentProps }
export { tooltipContentProps as tooltipContentProps_alias_1 }
declare class TooltipRootElement extends TooltipRootElement_base {

@@ -1092,10 +1109,20 @@ }

declare const TooltipRootElement_base: {
new (): BaseElement & TooltipRootProps;
prototype: HTMLElement;
};
declare const TooltipRootElement_base: BaseElementConstructor<TooltipRootProps>;
declare interface TooltipRootEvents extends TooltipRootEvents_2 {
}
export { TooltipRootEvents }
export { TooltipRootEvents as TooltipRootEvents_alias_1 }
export { tooltipRootEvents }
export { tooltipRootEvents as tooltipRootEvents_alias_1 }
declare interface TooltipRootProps extends TooltipRootProps_2 {
}
export { TooltipRootProps }
export { TooltipRootProps as TooltipRootProps_alias_1 }
export { tooltipRootProps }
export { tooltipRootProps as tooltipRootProps_alias_1 }
declare class TooltipTriggerElement extends TooltipTriggerElement_base {

@@ -1106,34 +1133,42 @@ }

declare const TooltipTriggerElement_base: {
new (): BaseElement & TooltipTriggerProps;
prototype: HTMLElement;
};
declare const TooltipTriggerElement_base: BaseElementConstructor<TooltipTriggerProps>;
declare interface TooltipTriggerEvents extends TooltipTriggerEvents_2 {
}
export { TooltipTriggerEvents }
export { TooltipTriggerEvents as TooltipTriggerEvents_alias_1 }
export { tooltipTriggerEvents }
export { tooltipTriggerEvents as tooltipTriggerEvents_alias_1 }
declare interface TooltipTriggerProps extends TooltipTriggerProps_2 {
}
export { TooltipTriggerProps }
export { TooltipTriggerProps as TooltipTriggerProps_alias_1 }
export declare function useAutocompleteEmpty(element: ConnectableElement): void;
export { tooltipTriggerProps }
export { tooltipTriggerProps as tooltipTriggerProps_alias_1 }
export declare function useAutocompleteItem(element: ConnectableElement, state: SignalState<AutocompleteItemProps>): void;
export declare const useAutocompleteEmpty: typeof useListboxEmpty;
export declare function useAutocompleteList(element: ConnectableElement, state: SignalState<AutocompleteListProps>): void;
export declare function useAutocompleteItem(element: ConnectableElement, { state, emit }: SetupOptions<AutocompleteItemProps, AutocompleteItemEvents>): void;
export declare function useAutocompletePopover(host: ConnectableElement, state: SignalState<AutocompletePopoverProps>): void;
export declare function useAutocompleteList(element: ConnectableElement, { state, emit }: SetupOptions<AutocompleteListProps, AutocompleteListEvents>): void;
/**
* @deprecated Use `useBlockHandleDraggable` instead.
*/
export declare function useBlockDragHandle(host: ConnectableElement, state: SignalState<BlockDragHandleProps>): void;
export declare function useAutocompletePopover(host: ConnectableElement, { state }: {
state: SignalState<AutocompletePopoverProps>;
}): void;
export declare function useBlockHandleAdd(host: ConnectableElement, state: SignalState<BlockHandleAddProps>): void;
export declare function useBlockHandleAdd(host: ConnectableElement, { state }: {
state: SignalState<BlockHandleAddProps>;
}): void;
export declare function useBlockHandleDraggable(host: ConnectableElement, state: SignalState<BlockHandleDraggableProps>): void;
export declare function useBlockHandleDraggable(host: ConnectableElement, { state }: {
state: SignalState<BlockHandleDraggableProps>;
}): void;
export declare function useBlockHandlePopover(host: ConnectableElement, state: SignalState<BlockHandlePopoverProps>): void;
export declare function useBlockHandlePopover(host: ConnectableElement, { state }: {
state: SignalState<BlockHandlePopoverProps>;
}): void;
/**
* @deprecated Use `useBlockHandlePopover` instead.
*/
export declare function useBlockPopover(host: ConnectableElement, state: SignalState<BlockPopoverProps>): void;
export declare function useEditorExtension(host: ConnectableElement, editor: ReadonlySignal<Editor | null>, extension: Extension): void;

@@ -1155,3 +1190,5 @@

export declare function useInlinePopover(host: ConnectableElement, state: SignalState<InlinePopoverProps>): void;
export declare function useInlinePopover(host: ConnectableElement, { state }: {
state: SignalState<InlinePopoverProps>;
}): void;

@@ -1166,19 +1203,27 @@ export declare function useKeymap(host: ConnectableElement, editor: ReadonlySignal<Editor | null>, keymap: Keymap): void;

export declare function useResizableHandle(host: ConnectableElement, state: SignalState<ResizableHandleProps>): void;
export declare function useResizableHandle(host: ConnectableElement, { state }: {
state: SignalState<ResizableHandleProps>;
}): void;
export declare function useResizableRoot(host: ConnectableElement, state: SignalState<ResizableRootProps>): void;
export declare function useResizableRoot(host: ConnectableElement, { state, emit }: SetupOptions<ResizableRootProps, ResizableRootEvents>): void;
export declare function useTableHandleColumnRoot(host: ConnectableElement, state: SignalState<TableHandleColumnRootProps>): void;
export declare function useTableHandleColumnRoot(host: ConnectableElement, { state }: {
state: SignalState<TableHandleColumnRootProps>;
}): void;
export declare function useTableHandleColumnTrigger(host: ConnectableElement, state: SignalState<TableHandleColumnTriggerProps>): void;
export declare function useTableHandleColumnTrigger(host: ConnectableElement, { state }: {
state: SignalState<TableHandleColumnTriggerProps>;
}): void;
export declare function useTableHandlePopoverContent(host: ConnectableElement, state: SignalState<TableHandlePopoverContentProps>): void;
export declare function useTableHandlePopoverContent(host: ConnectableElement, { state, emit, }: SetupOptions<TableHandlePopoverContentProps, TableHandlePopoverContentEvents>): void;
export declare function useTableHandlePopoverItem(element: ConnectableElement, state: SignalState<TableHandlePopoverItemProps>): void;
export declare function useTableHandlePopoverItem(element: ConnectableElement, { state, emit, }: SetupOptions<TableHandlePopoverItemProps, TableHandlePopoverItemEvents>): void;
export declare function useTableHandleRoot(host: ConnectableElement, state: SignalState<TableHandleRootProps>): void;
export declare function useTableHandleRoot(host: ConnectableElement, { state }: {
state: SignalState<TableHandleRootProps>;
}): void;
export declare function useTableHandleRowRoot(host: ConnectableElement, state: SignalState<TableHandleRowRootProps>): void;
export declare function useTableHandleRowRoot(host: ConnectableElement, { state }: SetupOptions<TableHandleRowRootProps, TableHandleRowRootEvents>): void;
export declare function useTableHandleRowTrigger(host: ConnectableElement, state: SignalState<TableHandleRowTriggerProps>): void;
export declare function useTableHandleRowTrigger(host: ConnectableElement, { state, }: SetupOptions<TableHandleRowTriggerProps, TableHandleRowTriggerEvents>): void;

@@ -1185,0 +1230,0 @@ export { useTooltipContent }

export { AutocompleteEmptyElement } from './_tsup-dts-rollup';
export { defaultAutocompleteEmptyProps } from './_tsup-dts-rollup';
export { autocompleteEmptyEvents } from './_tsup-dts-rollup';
export { autocompleteEmptyProps } from './_tsup-dts-rollup';
export { AutocompleteEmptyEvents } from './_tsup-dts-rollup';
export { AutocompleteEmptyProps } from './_tsup-dts-rollup';
export { AutocompleteItemElement } from './_tsup-dts-rollup';
export { defaultAutocompleteItemProps } from './_tsup-dts-rollup';
export { autocompleteItemEvents } from './_tsup-dts-rollup';
export { autocompleteItemProps } from './_tsup-dts-rollup';
export { AutocompleteItemEvents } from './_tsup-dts-rollup';
export { AutocompleteItemProps } from './_tsup-dts-rollup';
export { AutocompleteListElement } from './_tsup-dts-rollup';
export { defaultAutocompleteListProps } from './_tsup-dts-rollup';
export { autocompleteListEvents } from './_tsup-dts-rollup';
export { autocompleteListProps } from './_tsup-dts-rollup';
export { AutocompleteListEvents } from './_tsup-dts-rollup';
export { AutocompleteListProps } from './_tsup-dts-rollup';
export { AutocompletePopoverElement } from './_tsup-dts-rollup';
export { defaultAutocompletePopoverProps } from './_tsup-dts-rollup';
export { autocompletePopoverEvents } from './_tsup-dts-rollup';
export { autocompletePopoverProps } from './_tsup-dts-rollup';
export { AutocompletePopoverEvents } from './_tsup-dts-rollup';
export { AutocompletePopoverProps } from './_tsup-dts-rollup';
import {
getStateWithDefaults
} from "./chunk-ZGQ225UP.js";
import {
useEditorExtension
} from "./chunk-MZSYOTZT.js";
import {
defineCustomElement
} from "./chunk-LCDA7GFP.js";
// src/components/autocomplete/autocomplete-empty/element.gen.ts
import { ElementBuilder } from "@aria-ui/core";
import { defineCustomElement, registerCustomElement } from "@aria-ui/core";
// src/components/autocomplete/autocomplete-empty/props.ts
var defaultAutocompleteEmptyProps = {};
// src/components/autocomplete/autocomplete-empty/setup.ts
import { useListboxEmpty } from "@aria-ui/listbox/elements";
var useAutocompleteEmpty = useListboxEmpty;
// src/components/autocomplete/autocomplete-empty/state.ts
import { useListboxEmpty } from "@aria-ui/listbox";
function useAutocompleteEmpty(element) {
useListboxEmpty(element);
}
// src/components/autocomplete/autocomplete-empty/types.ts
var autocompleteEmptyProps = {};
var autocompleteEmptyEvents = {};
// src/components/autocomplete/autocomplete-empty/element.gen.ts
var AutocompleteEmptyElement = class extends ElementBuilder(useAutocompleteEmpty, defaultAutocompleteEmptyProps) {
var AutocompleteEmptyElement = class extends defineCustomElement({
props: autocompleteEmptyProps,
events: autocompleteEmptyEvents,
setup: useAutocompleteEmpty
}) {
};
defineCustomElement("prosekit-autocomplete-empty", AutocompleteEmptyElement);
registerCustomElement("prosekit-autocomplete-empty", AutocompleteEmptyElement);
// src/components/autocomplete/autocomplete-item/element.gen.ts
import { ElementBuilder as ElementBuilder2 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement2, registerCustomElement as registerCustomElement2 } from "@aria-ui/core";
// src/components/autocomplete/autocomplete-item/props.ts
var defaultAutocompleteItemProps = {
value: "",
onSelect: null
};
// src/components/autocomplete/autocomplete-item/state.ts
// src/components/autocomplete/autocomplete-item/setup.ts
import {
useEffect
} from "@aria-ui/core";
import { useListboxItem } from "@aria-ui/listbox";
import { useListboxItem } from "@aria-ui/listbox/elements";

@@ -55,5 +52,5 @@ // src/components/autocomplete/context.ts

// src/components/autocomplete/autocomplete-item/state.ts
function useAutocompleteItem(element, state) {
useListboxItem(element, state);
// src/components/autocomplete/autocomplete-item/setup.ts
function useAutocompleteItem(element, { state, emit }) {
useListboxItem(element, { state, emit });
const open = openContext.consume(element);

@@ -68,27 +65,32 @@ useEffect(element, () => {

// src/components/autocomplete/autocomplete-item/types.ts
import { listboxItemEvents } from "@aria-ui/listbox";
var autocompleteItemProps = {
value: {
default: ""
}
};
var autocompleteItemEvents = listboxItemEvents;
// src/components/autocomplete/autocomplete-item/element.gen.ts
var AutocompleteItemElement = class extends ElementBuilder2(useAutocompleteItem, defaultAutocompleteItemProps) {
var AutocompleteItemElement = class extends defineCustomElement2({
props: autocompleteItemProps,
events: autocompleteItemEvents,
setup: useAutocompleteItem
}) {
};
defineCustomElement("prosekit-autocomplete-item", AutocompleteItemElement);
registerCustomElement2("prosekit-autocomplete-item", AutocompleteItemElement);
// src/components/autocomplete/autocomplete-list/element.gen.ts
import { ElementBuilder as ElementBuilder3 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement3, registerCustomElement as registerCustomElement3 } from "@aria-ui/core";
// src/components/autocomplete/autocomplete-list/props.ts
import { defaultListboxProps } from "@aria-ui/listbox";
var defaultFilter = defaultListboxProps.filter;
var defaultAutocompleteListProps = {
filter: defaultFilter,
editor: null
};
// src/components/autocomplete/autocomplete-list/state.ts
// src/components/autocomplete/autocomplete-list/setup.ts
import {
mapSignals,
createSignal,
useEffect as useEffect2
} from "@aria-ui/core";
import {
defaultListboxProps as defaultListboxProps2,
listboxProps,
useListbox
} from "@aria-ui/listbox";
} from "@aria-ui/listbox/elements";
import {

@@ -99,24 +101,21 @@ Priority,

} from "@prosekit/core";
import omit from "just-omit";
function useAutocompleteList(element, state) {
function useAutocompleteList(element, { state, emit }) {
const open = openContext.consume(element);
const query = queryContext.consume(element);
const onSubmit = onSubmitContext.consume(element);
const onKeydownHandlerAdd = useKeyboardHandler(element, open, state.editor);
const onValueChange = (value) => {
var _a;
if (value) {
(_a = onSubmit.peek()) == null ? void 0 : _a();
}
};
const listboxState = {
...mapSignals({
...omit(defaultListboxProps2, ["filter"]),
onKeydownHandlerAdd,
onValueChange
}),
filter: state.filter
};
useListbox(element, listboxState);
const keydownTarget = useKeyDownTarget(element, open, state.editor);
const listboxState = getStateWithDefaults(
{ filter: state.filter, eventTarget: createSignal(keydownTarget) },
listboxProps
);
useEffect2(element, () => {
element.addEventListener("valueChange", () => {
var _a;
if (onSubmit) {
(_a = onSubmit.get()) == null ? void 0 : _a();
}
});
});
useListbox(element, { state: listboxState, emit });
useEffect2(element, () => {
listboxState.query.set(query.get());

@@ -148,5 +147,4 @@ });

}
function useKeyboardHandler(element, open, editor) {
let keydownHandler = null;
let disposeKeydownHandler;
function useKeyDownTarget(element, open, editor) {
const keydownHandlers = [];
useEffect2(element, () => {

@@ -163,53 +161,52 @@ const editorValue = editor.get();

}
keydownHandler == null ? void 0 : keydownHandler(event);
keydownHandlers.forEach((handler) => handler(event));
return event.defaultPrevented;
}
);
disposeKeydownHandler == null ? void 0 : disposeKeydownHandler();
disposeKeydownHandler = editorValue.use(
withPriority(extension, Priority.highest)
);
return editorValue.use(withPriority(extension, Priority.highest));
});
return (keydownHandlerValue) => {
keydownHandler = keydownHandlerValue;
return () => {
disposeKeydownHandler == null ? void 0 : disposeKeydownHandler();
disposeKeydownHandler = void 0;
};
return {
addEventListener: (type, listener) => {
if (type === "keydown") {
keydownHandlers.push(listener);
}
},
removeEventListener: (type, listener) => {
if (type === "keydown") {
const index = keydownHandlers.indexOf(listener);
if (index !== -1) {
keydownHandlers.splice(index, 1);
}
}
}
};
}
// src/components/autocomplete/autocomplete-list/types.ts
import {
listboxEvents,
listboxProps as listboxProps2
} from "@aria-ui/listbox";
var autocompleteListProps = {
filter: listboxProps2.filter,
editor: { default: null }
};
var autocompleteListEvents = listboxEvents;
// src/components/autocomplete/autocomplete-list/element.gen.ts
var AutocompleteListElement = class extends ElementBuilder3(useAutocompleteList, defaultAutocompleteListProps) {
var AutocompleteListElement = class extends defineCustomElement3({
props: autocompleteListProps,
events: autocompleteListEvents,
setup: useAutocompleteList
}) {
};
defineCustomElement("prosekit-autocomplete-list", AutocompleteListElement);
registerCustomElement3("prosekit-autocomplete-list", AutocompleteListElement);
// src/components/autocomplete/autocomplete-popover/element.gen.ts
import { ElementBuilder as ElementBuilder4 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement4, registerCustomElement as registerCustomElement4 } from "@aria-ui/core";
// src/components/autocomplete/autocomplete-popover/props.ts
// src/components/autocomplete/autocomplete-popover/setup.ts
import {
defaultOverlayPositionerProps
} from "@aria-ui/overlay";
var body = typeof document !== "undefined" && document.querySelector("body");
var defaultBoundary = body || "clippingAncestors";
var defaultAutocompletePopoverProps = Object.freeze({
...defaultOverlayPositionerProps,
editor: null,
regex: null,
onQueryChange: null,
onOpenChange: null,
placement: "bottom-start",
offset: 4,
inline: true,
hoist: true,
fitViewport: true,
boundary: defaultBoundary,
overflowPadding: 8
});
// src/components/autocomplete/autocomplete-popover/state.ts
import {
createComputed,
createSignal as createSignal2,
createSignal as createSignal3,
useAnimationFrame,

@@ -219,3 +216,3 @@ useAttribute,

} from "@aria-ui/core";
import { useOverlayPositionerState } from "@aria-ui/overlay";
import { useOverlayPositionerState } from "@aria-ui/overlay/elements";
import { usePresence } from "@aria-ui/presence";

@@ -234,7 +231,7 @@ import {

import {
createSignal,
createSignal as createSignal2,
useEffect as useEffect3
} from "@aria-ui/core";
function useFirstRendering(host) {
const firstRendering = createSignal(true);
const firstRendering = createSignal2(true);
useEffect3(host, () => {

@@ -253,9 +250,9 @@ requestAnimationFrame(() => {

// src/components/autocomplete/autocomplete-popover/state.ts
function useAutocompletePopover(host, state) {
// src/components/autocomplete/autocomplete-popover/setup.ts
function useAutocompletePopover(host, { state }) {
const { editor, regex, ...overlayState } = state;
const reference = createSignal2(null);
const query = createSignal2("");
const onDismiss = createSignal2(null);
const onSubmit = createSignal2(null);
const reference = createSignal3(null);
const query = createSignal3("");
const onDismiss = createSignal3(null);
const onSubmit = createSignal3(null);
const presence = createComputed(() => !!reference.get());

@@ -329,4 +326,2 @@ queryContext.provide(host, query);

query.set("");
onDismiss.set(null);
onSubmit.set(null);
};

@@ -356,6 +351,33 @@ return new AutocompleteRule({

// src/components/autocomplete/autocomplete-popover/types.ts
import {
overlayPositionerEvents,
overlayPositionerProps
} from "@aria-ui/overlay/elements";
var body = typeof document !== "undefined" && document.querySelector("body");
var defaultBoundary = body || "clippingAncestors";
var autocompletePopoverProps = {
...overlayPositionerProps,
editor: { default: null },
regex: { default: null },
onQueryChange: { default: null },
onOpenChange: { default: null },
placement: { default: "bottom-start" },
offset: { default: 4 },
inline: { default: true },
hoist: { default: true },
fitViewport: { default: true },
boundary: { default: defaultBoundary },
overflowPadding: { default: 8 }
};
var autocompletePopoverEvents = overlayPositionerEvents;
// src/components/autocomplete/autocomplete-popover/element.gen.ts
var AutocompletePopoverElement = class extends ElementBuilder4(useAutocompletePopover, defaultAutocompletePopoverProps) {
var AutocompletePopoverElement = class extends defineCustomElement4({
props: autocompletePopoverProps,
events: autocompletePopoverEvents,
setup: useAutocompletePopover
}) {
};
defineCustomElement("prosekit-autocomplete-popover", AutocompletePopoverElement);
registerCustomElement4("prosekit-autocomplete-popover", AutocompletePopoverElement);
export {

@@ -366,6 +388,10 @@ AutocompleteEmptyElement,

AutocompletePopoverElement,
defaultAutocompleteEmptyProps,
defaultAutocompleteItemProps,
defaultAutocompleteListProps,
defaultAutocompletePopoverProps
autocompleteEmptyEvents,
autocompleteEmptyProps,
autocompleteItemEvents,
autocompleteItemProps,
autocompleteListEvents,
autocompleteListProps,
autocompletePopoverEvents,
autocompletePopoverProps
};

@@ -1,15 +0,15 @@

export { BlockDragHandleElement } from './_tsup-dts-rollup';
export { defaultBlockDragHandleProps } from './_tsup-dts-rollup';
export { BlockDragHandleProps } from './_tsup-dts-rollup';
export { BlockHandleAddElement } from './_tsup-dts-rollup';
export { defaultBlockHandleAddProps } from './_tsup-dts-rollup';
export { blockHandleAddEvents } from './_tsup-dts-rollup';
export { blockHandleAddProps } from './_tsup-dts-rollup';
export { BlockHandleAddEvents } from './_tsup-dts-rollup';
export { BlockHandleAddProps } from './_tsup-dts-rollup';
export { BlockHandleDraggableElement } from './_tsup-dts-rollup';
export { defaultBlockHandleDraggableProps } from './_tsup-dts-rollup';
export { blockHandleDraggableEvents } from './_tsup-dts-rollup';
export { blockHandleDraggableProps } from './_tsup-dts-rollup';
export { BlockHandleDraggableEvents } from './_tsup-dts-rollup';
export { BlockHandleDraggableProps } from './_tsup-dts-rollup';
export { BlockHandlePopoverElement } from './_tsup-dts-rollup';
export { defaultBlockHandlePopoverProps } from './_tsup-dts-rollup';
export { blockHandlePopoverEvents } from './_tsup-dts-rollup';
export { blockHandlePopoverProps } from './_tsup-dts-rollup';
export { BlockHandlePopoverEvents } from './_tsup-dts-rollup';
export { BlockHandlePopoverProps } from './_tsup-dts-rollup';
export { BlockPopoverElement } from './_tsup-dts-rollup';
export { defaultBlockPopoverProps } from './_tsup-dts-rollup';
export { BlockPopoverProps } from './_tsup-dts-rollup';
import {
useEditorExtension
} from "./chunk-MZSYOTZT.js";
import {
defineCustomElement
} from "./chunk-LCDA7GFP.js";
// src/components/block-handle/block-drag-handle/element.gen.ts
import { ElementBuilder } from "@aria-ui/core";
// src/components/block-handle/block-handle-add/element.gen.ts
import { defineCustomElement, registerCustomElement } from "@aria-ui/core";
// src/components/block-handle/block-drag-handle/props.ts
var defaultBlockDragHandleProps = Object.freeze({
editor: null
});
// src/components/block-handle/block-drag-handle/state.ts
// src/components/block-handle/block-handle-add/setup.ts
import {
createSignal,
useAttribute,
useEffect,
useEventListener
} from "@aria-ui/core";
import { Fragment, Slice } from "@prosekit/pm/model";
import { NodeSelection } from "@prosekit/pm/state";
import { insertDefaultBlock } from "@prosekit/core";

@@ -33,5 +21,48 @@ // src/components/block-handle/context.ts

// src/components/block-handle/block-drag-handle/state.ts
function useBlockDragHandle(host, state) {
// src/components/block-handle/block-handle-add/setup.ts
function useBlockHandleAdd(host, { state }) {
const context = blockPopoverContext.consume(host);
useEventListener(host, "pointerdown", (event) => {
event.preventDefault();
const editor = state.editor.get();
const hoverState = context.get();
if (!editor || !hoverState) {
return;
}
const { node, pos } = hoverState;
editor.exec(insertDefaultBlock({ pos: pos + node.nodeSize }));
editor.focus();
context.set(null);
});
}
// src/components/block-handle/block-handle-add/types.ts
var blockHandleAddProps = {
editor: { default: null }
};
var blockHandleAddEvents = {};
// src/components/block-handle/block-handle-add/element.gen.ts
var BlockHandleAddElement = class extends defineCustomElement({
props: blockHandleAddProps,
events: blockHandleAddEvents,
setup: useBlockHandleAdd
}) {
};
registerCustomElement("prosekit-block-handle-add", BlockHandleAddElement);
// src/components/block-handle/block-handle-draggable/element.gen.ts
import { defineCustomElement as defineCustomElement2, registerCustomElement as registerCustomElement2 } from "@aria-ui/core";
// src/components/block-handle/block-handle-draggable/setup.ts
import {
createSignal,
useAttribute,
useEffect,
useEventListener as useEventListener2
} from "@aria-ui/core";
import { Fragment, Slice } from "@prosekit/pm/model";
import { NodeSelection } from "@prosekit/pm/state";
function useBlockHandleDraggable(host, { state }) {
const context = blockPopoverContext.consume(host);
useEffect(host, () => {

@@ -45,3 +76,3 @@ host.draggable = true;

function usePointerDownHandler(host, context, editor) {
useEventListener(host, "pointerdown", () => {
useEventListener2(host, "pointerdown", () => {
var _a, _b;

@@ -62,3 +93,3 @@ const { pos } = (_a = context.get()) != null ? _a : {};

function useDraggingPreview(host, context, editor) {
useEventListener(host, "dragstart", (event) => {
useEventListener2(host, "dragstart", (event) => {
var _a;

@@ -87,6 +118,6 @@ const hoverState = context.get();

const dragging = createSignal(false);
useEventListener(host, "dragstart", () => {
useEventListener2(host, "dragstart", () => {
dragging.set(true);
});
useEventListener(host, "dragend", () => {
useEventListener2(host, "dragend", () => {
dragging.set(false);

@@ -97,84 +128,22 @@ });

// src/components/block-handle/block-drag-handle/element.gen.ts
var BlockDragHandleElement = class extends ElementBuilder(useBlockDragHandle, defaultBlockDragHandleProps) {
// src/components/block-handle/block-handle-draggable/types.ts
var blockHandleDraggableProps = {
editor: { default: null }
};
defineCustomElement("prosekit-block-drag-handle", BlockDragHandleElement);
var blockHandleDraggableEvents = {};
// src/components/block-handle/block-handle-add/element.gen.ts
import { ElementBuilder as ElementBuilder2 } from "@aria-ui/core";
// src/components/block-handle/block-handle-add/props.ts
var defaultBlockHandleAddProps = Object.freeze({
editor: null
});
// src/components/block-handle/block-handle-add/state.ts
import {
useEventListener as useEventListener2
} from "@aria-ui/core";
import { insertDefaultBlock } from "@prosekit/core";
function useBlockHandleAdd(host, state) {
const context = blockPopoverContext.consume(host);
useEventListener2(host, "pointerdown", (event) => {
event.preventDefault();
const editor = state.editor.get();
const hoverState = context.get();
if (!editor || !hoverState) {
return;
}
const { node, pos } = hoverState;
editor.exec(insertDefaultBlock({ pos: pos + node.nodeSize }));
editor.focus();
context.set(null);
});
}
// src/components/block-handle/block-handle-add/element.gen.ts
var BlockHandleAddElement = class extends ElementBuilder2(useBlockHandleAdd, defaultBlockHandleAddProps) {
};
defineCustomElement("prosekit-block-handle-add", BlockHandleAddElement);
// src/components/block-handle/block-handle-draggable/element.gen.ts
import { ElementBuilder as ElementBuilder3 } from "@aria-ui/core";
// src/components/block-handle/block-handle-draggable/props.ts
var defaultBlockHandleDraggableProps = Object.freeze({
editor: null
});
// src/components/block-handle/block-handle-draggable/state.ts
import "@aria-ui/core";
function useBlockHandleDraggable(host, state) {
useBlockDragHandle(host, state);
}
// src/components/block-handle/block-handle-draggable/element.gen.ts
var BlockHandleDraggableElement = class extends ElementBuilder3(useBlockHandleDraggable, defaultBlockHandleDraggableProps) {
var BlockHandleDraggableElement = class extends defineCustomElement2({
props: blockHandleDraggableProps,
events: blockHandleDraggableEvents,
setup: useBlockHandleDraggable
}) {
};
defineCustomElement("prosekit-block-handle-draggable", BlockHandleDraggableElement);
registerCustomElement2("prosekit-block-handle-draggable", BlockHandleDraggableElement);
// src/components/block-handle/block-handle-popover/element.gen.ts
import { ElementBuilder as ElementBuilder4 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement3, registerCustomElement as registerCustomElement3 } from "@aria-ui/core";
// src/components/block-handle/block-popover/props.ts
// src/components/block-handle/block-handle-popover/setup.ts
import {
defaultOverlayPositionerProps
} from "@aria-ui/overlay";
var defaultBlockPopoverProps = Object.freeze({
...defaultOverlayPositionerProps,
editor: null,
placement: "left-start",
offset: 4
});
// src/components/block-handle/block-handle-popover/props.ts
var defaultBlockHandlePopoverProps = Object.freeze({
...defaultBlockPopoverProps
});
// src/components/block-handle/block-handle-popover/state.ts
import "@aria-ui/core";
// src/components/block-handle/block-popover/state.ts
import {
createSignal as createSignal2,

@@ -184,6 +153,6 @@ useAttribute as useAttribute2,

} from "@aria-ui/core";
import { useOverlayPositionerState } from "@aria-ui/overlay";
import { useOverlayPositionerState } from "@aria-ui/overlay/elements";
import { usePresence } from "@aria-ui/presence";
// src/components/block-handle/block-popover/pointer-move.ts
// src/components/block-handle/block-handle-popover/pointer-move.ts
import { defineDOMEventHandler, union } from "@prosekit/core";

@@ -203,3 +172,3 @@

// src/components/block-handle/block-popover/pointer-move.ts
// src/components/block-handle/block-handle-popover/pointer-move.ts
function defineElementHoverHandler(handler) {

@@ -264,4 +233,4 @@ const handlePointerEvent = (view, event) => {

// src/components/block-handle/block-popover/state.ts
function useBlockPopover(host, state) {
// src/components/block-handle/block-handle-popover/setup.ts
function useBlockHandlePopover(host, { state }) {
const { editor, ...overlayState } = state;

@@ -301,28 +270,32 @@ const reference = createSignal2(null);

// src/components/block-handle/block-handle-popover/state.ts
function useBlockHandlePopover(host, state) {
useBlockPopover(host, state);
}
// src/components/block-handle/block-handle-popover/types.ts
import {
overlayPositionerProps
} from "@aria-ui/overlay/elements";
var blockHandlePopoverProps = {
...overlayPositionerProps,
editor: { default: null },
placement: { default: "left-start" },
offset: { default: 4 }
};
var blockHandlePopoverEvents = {};
// src/components/block-handle/block-handle-popover/element.gen.ts
var BlockHandlePopoverElement = class extends ElementBuilder4(useBlockHandlePopover, defaultBlockHandlePopoverProps) {
var BlockHandlePopoverElement = class extends defineCustomElement3({
props: blockHandlePopoverProps,
events: blockHandlePopoverEvents,
setup: useBlockHandlePopover
}) {
};
defineCustomElement("prosekit-block-handle-popover", BlockHandlePopoverElement);
// src/components/block-handle/block-popover/element.gen.ts
import { ElementBuilder as ElementBuilder5 } from "@aria-ui/core";
var BlockPopoverElement = class extends ElementBuilder5(useBlockPopover, defaultBlockPopoverProps) {
};
defineCustomElement("prosekit-block-popover", BlockPopoverElement);
registerCustomElement3("prosekit-block-handle-popover", BlockHandlePopoverElement);
export {
BlockDragHandleElement,
BlockHandleAddElement,
BlockHandleDraggableElement,
BlockHandlePopoverElement,
BlockPopoverElement,
defaultBlockDragHandleProps,
defaultBlockHandleAddProps,
defaultBlockHandleDraggableProps,
defaultBlockHandlePopoverProps,
defaultBlockPopoverProps
blockHandleAddEvents,
blockHandleAddProps,
blockHandleDraggableEvents,
blockHandleDraggableProps,
blockHandlePopoverEvents,
blockHandlePopoverProps
};
export { InlinePopoverElement } from './_tsup-dts-rollup';
export { defaultInlinePopoverProps } from './_tsup-dts-rollup';
export { inlinePopoverEvents } from './_tsup-dts-rollup';
export { inlinePopoverProps } from './_tsup-dts-rollup';
export { InlinePopoverEvents } from './_tsup-dts-rollup';
export { InlinePopoverProps } from './_tsup-dts-rollup';
import {
useEditorExtension
} from "./chunk-MZSYOTZT.js";
import {
defineCustomElement
} from "./chunk-LCDA7GFP.js";
// src/components/inline-popover/inline-popover/element.gen.ts
import { ElementBuilder } from "@aria-ui/core";
import { defineCustomElement, registerCustomElement } from "@aria-ui/core";
// src/components/inline-popover/inline-popover/props.ts
// src/components/inline-popover/inline-popover/setup.ts
import {
defaultOverlayPositionerProps
} from "@aria-ui/overlay";
var defaultInlinePopoverProps = Object.freeze({
...defaultOverlayPositionerProps,
editor: null,
defaultOpen: true,
open: false,
onOpenChange: null,
dismissOnEscape: true,
placement: "top",
offset: 12,
shift: true,
flip: true,
hide: true,
overlap: true,
inline: true,
overflowPadding: 8,
// Don't need boundary when hoist is true.
hoist: true,
boundary: []
});
// src/components/inline-popover/inline-popover/state.ts
import {
createComputed,

@@ -42,3 +15,3 @@ createSignal,

} from "@aria-ui/core";
import { useOverlayPositionerState } from "@aria-ui/overlay";
import { useOverlayPositionerState } from "@aria-ui/overlay/elements";
import { usePresence } from "@aria-ui/presence";

@@ -124,4 +97,4 @@

// src/components/inline-popover/inline-popover/state.ts
function useInlinePopover(host, state) {
// src/components/inline-popover/inline-popover/setup.ts
function useInlinePopover(host, { state }) {
const { editor, defaultOpen, open, onOpenChange, ...overlayState } = state;

@@ -179,9 +152,40 @@ const reference = useInlinePopoverReference(host, editor);

// src/components/inline-popover/inline-popover/types.ts
import {
overlayPositionerEvents,
overlayPositionerProps
} from "@aria-ui/overlay";
var inlinePopoverProps = Object.freeze({
...overlayPositionerProps,
editor: { default: null },
defaultOpen: { default: true },
open: { default: false },
onOpenChange: { default: null },
dismissOnEscape: { default: true },
placement: { default: "top" },
offset: { default: 12 },
shift: { default: true },
flip: { default: true },
hide: { default: true },
overlap: { default: true },
inline: { default: true },
overflowPadding: { default: 8 },
// Don't need boundary when hoist is true.
hoist: { default: true },
boundary: { default: [] }
});
var inlinePopoverEvents = overlayPositionerEvents;
// src/components/inline-popover/inline-popover/element.gen.ts
var InlinePopoverElement = class extends ElementBuilder(useInlinePopover, defaultInlinePopoverProps) {
var InlinePopoverElement = class extends defineCustomElement({
props: inlinePopoverProps,
events: inlinePopoverEvents,
setup: useInlinePopover
}) {
};
defineCustomElement("prosekit-inline-popover", InlinePopoverElement);
registerCustomElement("prosekit-inline-popover", InlinePopoverElement);
export {
InlinePopoverElement,
defaultInlinePopoverProps
inlinePopoverEvents,
inlinePopoverProps
};
export { PopoverContentElement } from './_tsup-dts-rollup';
export { defaultPopoverContentProps } from './_tsup-dts-rollup';
export { popoverContentEvents } from './_tsup-dts-rollup';
export { popoverContentProps } from './_tsup-dts-rollup';
export { PopoverContentEvents } from './_tsup-dts-rollup';
export { PopoverContentProps } from './_tsup-dts-rollup';
export { PopoverRootElement } from './_tsup-dts-rollup';
export { defaultPopoverRootProps } from './_tsup-dts-rollup';
export { popoverRootEvents } from './_tsup-dts-rollup';
export { popoverRootProps } from './_tsup-dts-rollup';
export { PopoverRootEvents } from './_tsup-dts-rollup';
export { PopoverRootProps } from './_tsup-dts-rollup';
export { PopoverTriggerElement } from './_tsup-dts-rollup';
export { defaultPopoverTriggerProps } from './_tsup-dts-rollup';
export { popoverTriggerEvents } from './_tsup-dts-rollup';
export { popoverTriggerProps } from './_tsup-dts-rollup';
export { PopoverTriggerEvents } from './_tsup-dts-rollup';
export { PopoverTriggerProps } from './_tsup-dts-rollup';

@@ -1,52 +0,60 @@

import {
defineCustomElement
} from "./chunk-LCDA7GFP.js";
// src/components/popover/popover-content/element.gen.ts
import { ElementBuilder } from "@aria-ui/core";
import { defineCustomElement, registerCustomElement } from "@aria-ui/core";
// src/components/popover/popover-content/props.ts
// src/components/popover/popover-content/setup.ts
import { usePopoverContent } from "@aria-ui/popover/elements";
// src/components/popover/popover-content/types.ts
import {
defaultPopoverContentProps
} from "@aria-ui/popover";
popoverContentEvents,
popoverContentProps
} from "@aria-ui/popover/elements";
// src/components/popover/popover-content/state.ts
import { usePopoverContent } from "@aria-ui/popover";
// src/components/popover/popover-content/element.gen.ts
var PopoverContentElement = class extends ElementBuilder(usePopoverContent, defaultPopoverContentProps) {
var PopoverContentElement = class extends defineCustomElement({
props: popoverContentProps,
events: popoverContentEvents,
setup: usePopoverContent
}) {
};
defineCustomElement("prosekit-popover-content", PopoverContentElement);
registerCustomElement("prosekit-popover-content", PopoverContentElement);
// src/components/popover/popover-root/element.gen.ts
import { ElementBuilder as ElementBuilder2 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement2, registerCustomElement as registerCustomElement2 } from "@aria-ui/core";
// src/components/popover/popover-root/props.ts
import {
defaultPopoverRootProps
} from "@aria-ui/popover";
// src/components/popover/popover-root/setup.ts
import { usePopoverRoot } from "@aria-ui/popover/elements";
// src/components/popover/popover-root/state.ts
import { usePopoverRoot } from "@aria-ui/popover";
// src/components/popover/popover-root/types.ts
import { popoverRootEvents, popoverRootProps } from "@aria-ui/popover/elements";
// src/components/popover/popover-root/element.gen.ts
var PopoverRootElement = class extends ElementBuilder2(usePopoverRoot, defaultPopoverRootProps) {
var PopoverRootElement = class extends defineCustomElement2({
props: popoverRootProps,
events: popoverRootEvents,
setup: usePopoverRoot
}) {
};
defineCustomElement("prosekit-popover-root", PopoverRootElement);
registerCustomElement2("prosekit-popover-root", PopoverRootElement);
// src/components/popover/popover-trigger/element.gen.ts
import { ElementBuilder as ElementBuilder3 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement3, registerCustomElement as registerCustomElement3 } from "@aria-ui/core";
// src/components/popover/popover-trigger/props.ts
// src/components/popover/popover-trigger/setup.ts
import { usePopoverTrigger } from "@aria-ui/popover/elements";
// src/components/popover/popover-trigger/types.ts
import {
defaultPopoverTriggerProps
} from "@aria-ui/popover";
popoverTriggerEvents,
popoverTriggerProps
} from "@aria-ui/popover/elements";
// src/components/popover/popover-trigger/state.ts
import { usePopoverTrigger } from "@aria-ui/popover";
// src/components/popover/popover-trigger/element.gen.ts
var PopoverTriggerElement = class extends ElementBuilder3(usePopoverTrigger, defaultPopoverTriggerProps) {
var PopoverTriggerElement = class extends defineCustomElement3({
props: popoverTriggerProps,
events: popoverTriggerEvents,
setup: usePopoverTrigger
}) {
};
defineCustomElement("prosekit-popover-trigger", PopoverTriggerElement);
registerCustomElement3("prosekit-popover-trigger", PopoverTriggerElement);
export {

@@ -56,5 +64,8 @@ PopoverContentElement,

PopoverTriggerElement,
defaultPopoverContentProps,
defaultPopoverRootProps,
defaultPopoverTriggerProps
popoverContentEvents,
popoverContentProps,
popoverRootEvents,
popoverRootProps,
popoverTriggerEvents,
popoverTriggerProps
};
export { ResizableHandleElement } from './_tsup-dts-rollup';
export { defaultResizableHandleProps } from './_tsup-dts-rollup';
export { resizableHandleEvents } from './_tsup-dts-rollup';
export { resizableHandleProps } from './_tsup-dts-rollup';
export { ResizableHandleEvents } from './_tsup-dts-rollup';
export { ResizableHandleProps } from './_tsup-dts-rollup';
export { ResizableRootElement } from './_tsup-dts-rollup';
export { defaultResizableRootProps } from './_tsup-dts-rollup';
export { resizableRootEvents } from './_tsup-dts-rollup';
export { resizableRootProps } from './_tsup-dts-rollup';
export { ResizableRootEvents } from './_tsup-dts-rollup';
export { ResizableRootProps } from './_tsup-dts-rollup';

@@ -1,14 +0,5 @@

import {
defineCustomElement
} from "./chunk-LCDA7GFP.js";
// src/components/resizable/resizable-handle/element.gen.ts
import { ElementBuilder } from "@aria-ui/core";
import { defineCustomElement, registerCustomElement } from "@aria-ui/core";
// src/components/resizable/resizable-handle/props.ts
var defaultResizableHandleProps = {
position: "bottom-right"
};
// src/components/resizable/resizable-handle/state.ts
// src/components/resizable/resizable-handle/setup.ts
import {

@@ -118,4 +109,4 @@ createSignal,

// src/components/resizable/resizable-handle/state.ts
function useResizableHandle(host, state) {
// src/components/resizable/resizable-handle/setup.ts
function useResizableHandle(host, { state }) {
const onResize = onResizeContext.consume(host);

@@ -186,21 +177,21 @@ const onResizeStart = onResizeStartContext.consume(host);

// src/components/resizable/resizable-handle/types.ts
var resizableHandleProps = {
position: { default: "bottom-right" }
};
var resizableHandleEvents = {};
// src/components/resizable/resizable-handle/element.gen.ts
var ResizableHandleElement = class extends ElementBuilder(useResizableHandle, defaultResizableHandleProps) {
var ResizableHandleElement = class extends defineCustomElement({
props: resizableHandleProps,
events: resizableHandleEvents,
setup: useResizableHandle
}) {
};
defineCustomElement("prosekit-resizable-handle", ResizableHandleElement);
registerCustomElement("prosekit-resizable-handle", ResizableHandleElement);
// src/components/resizable/resizable-root/element.gen.ts
import { ElementBuilder as ElementBuilder2 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement2, registerCustomElement as registerCustomElement2 } from "@aria-ui/core";
// src/components/resizable/resizable-root/props.ts
var defaultResizableRootProps = {
width: null,
height: null,
aspectRatio: null,
onSizeChangeStart: null,
onSizeChange: null,
onSizeChangeEnd: null
};
// src/components/resizable/resizable-root/state.ts
// src/components/resizable/resizable-root/setup.ts
import {

@@ -210,5 +201,5 @@ createSignal as createSignal2,

} from "@aria-ui/core";
function useResizableRoot(host, state) {
function useResizableRoot(host, { state, emit }) {
const onResizeStart = () => {
var _a, _b;
var _a;
const { width, height } = host.getBoundingClientRect();

@@ -219,8 +210,6 @@ let aspectRatio = (_a = state.aspectRatio.peek()) != null ? _a : width / height;

}
(_b = state.onSizeChangeStart.peek()) == null ? void 0 : _b({ width, height });
emit("resizeStart", { width, height });
return [width, height, aspectRatio];
};
const onResize = (width, height) => {
var _a;
(_a = state.onSizeChange.peek()) == null ? void 0 : _a({ width, height });
state.width.set(width);

@@ -230,5 +219,4 @@ state.height.set(height);

const onResizeEnd = () => {
var _a;
const { width, height } = host.getBoundingClientRect();
(_a = state.onSizeChangeEnd.peek()) == null ? void 0 : _a({ width, height });
emit("resizeEnd", { width, height });
};

@@ -260,11 +248,28 @@ onResizeStartContext.provide(host, createSignal2(onResizeStart));

// src/components/resizable/resizable-root/types.ts
var resizableRootProps = {
width: { default: null },
height: { default: null },
aspectRatio: { default: null }
};
var resizableRootEvents = {
resizeStart: {},
resizeEnd: {}
};
// src/components/resizable/resizable-root/element.gen.ts
var ResizableRootElement = class extends ElementBuilder2(useResizableRoot, defaultResizableRootProps) {
var ResizableRootElement = class extends defineCustomElement2({
props: resizableRootProps,
events: resizableRootEvents,
setup: useResizableRoot
}) {
};
defineCustomElement("prosekit-resizable-root", ResizableRootElement);
registerCustomElement2("prosekit-resizable-root", ResizableRootElement);
export {
ResizableHandleElement,
ResizableRootElement,
defaultResizableHandleProps,
defaultResizableRootProps
resizableHandleEvents,
resizableHandleProps,
resizableRootEvents,
resizableRootProps
};
export { TableHandleColumnRootElement } from './_tsup-dts-rollup';
export { defaultTableHandleColumnRootProps } from './_tsup-dts-rollup';
export { tableHandleColumnRootEvents } from './_tsup-dts-rollup';
export { tableHandleColumnRootProps } from './_tsup-dts-rollup';
export { TableHandleColumnRootEvents } from './_tsup-dts-rollup';
export { TableHandleColumnRootProps } from './_tsup-dts-rollup';
export { TableHandleColumnTriggerElement } from './_tsup-dts-rollup';
export { defaultTableHandleColumnTriggerProps } from './_tsup-dts-rollup';
export { tableHandleColumnTriggerEvents } from './_tsup-dts-rollup';
export { tableHandleColumnTriggerProps } from './_tsup-dts-rollup';
export { TableHandleColumnTriggerEvents } from './_tsup-dts-rollup';
export { TableHandleColumnTriggerProps } from './_tsup-dts-rollup';
export { TableHandlePopoverContentElement } from './_tsup-dts-rollup';
export { defaultTableHandlePopoverContentProps } from './_tsup-dts-rollup';
export { tableHandlePopoverContentEvents } from './_tsup-dts-rollup';
export { tableHandlePopoverContentProps } from './_tsup-dts-rollup';
export { TableHandlePopoverContentEvents } from './_tsup-dts-rollup';
export { TableHandlePopoverContentProps } from './_tsup-dts-rollup';
export { TableHandlePopoverItemElement } from './_tsup-dts-rollup';
export { defaultTableHandlePopoverItemProps } from './_tsup-dts-rollup';
export { tableHandlePopoverItemEvents } from './_tsup-dts-rollup';
export { tableHandlePopoverItemProps } from './_tsup-dts-rollup';
export { TableHandlePopoverItemEvents } from './_tsup-dts-rollup';
export { TableHandlePopoverItemProps } from './_tsup-dts-rollup';
export { TableHandleRootElement } from './_tsup-dts-rollup';
export { defaultTableHandleRootProps } from './_tsup-dts-rollup';
export { tableHandleRootEvents } from './_tsup-dts-rollup';
export { tableHandleRootProps } from './_tsup-dts-rollup';
export { TableHandleRootEvents } from './_tsup-dts-rollup';
export { TableHandleRootProps } from './_tsup-dts-rollup';
export { TableHandleRowRootElement } from './_tsup-dts-rollup';
export { defaultTableHandleRowRootProps } from './_tsup-dts-rollup';
export { tableHandleRowRootEvents } from './_tsup-dts-rollup';
export { tableHandleRowRootProps } from './_tsup-dts-rollup';
export { TableHandleRowRootEvents } from './_tsup-dts-rollup';
export { TableHandleRowRootProps } from './_tsup-dts-rollup';
export { TableHandleRowTriggerElement } from './_tsup-dts-rollup';
export { defaultTableHandleRowTriggerProps } from './_tsup-dts-rollup';
export { tableHandleRowTriggerEvents } from './_tsup-dts-rollup';
export { tableHandleRowTriggerProps } from './_tsup-dts-rollup';
export { TableHandleRowTriggerEvents } from './_tsup-dts-rollup';
export { TableHandleRowTriggerProps } from './_tsup-dts-rollup';
import {
getStateWithDefaults
} from "./chunk-ZGQ225UP.js";
import {
useEditorExtension
} from "./chunk-MZSYOTZT.js";
import {
defineCustomElement
} from "./chunk-LCDA7GFP.js";
// src/components/table-handle/table-handle-column-root/element.gen.ts
import { ElementBuilder } from "@aria-ui/core";
import { defineCustomElement, registerCustomElement } from "@aria-ui/core";
// src/components/table-handle/table-handle-column-root/props.ts
// src/components/table-handle/table-handle-column-root/setup.ts
import {
defaultOverlayPositionerProps
} from "@aria-ui/overlay";
var defaultTableHandleColumnRootProps = Object.freeze({
...defaultOverlayPositionerProps,
editor: null,
placement: "top"
});
// src/components/table-handle/table-handle-column-root/state.ts
import {
createComputed,
createSignal,
mapSignals,
useAttribute,
useEffect
} from "@aria-ui/core";
import { defaultMenuRootProps, useMenuRoot } from "@aria-ui/menu";
import { useOverlayPositionerState } from "@aria-ui/overlay";
import {
menuRootProps,
useMenuRoot
} from "@aria-ui/menu/elements";
import { useOverlayPositionerState } from "@aria-ui/overlay/elements";
import { usePresence } from "@aria-ui/presence";

@@ -40,4 +32,4 @@

// src/components/table-handle/table-handle-column-root/state.ts
function useTableHandleColumnRoot(host, state) {
// src/components/table-handle/table-handle-column-root/setup.ts
function useTableHandleColumnRoot(host, { state }) {
const { editor, ...overlayState } = state;

@@ -67,28 +59,43 @@ const rootContext = tableHandleRootContext.consume(host);

usePresence(host, presence);
const menuRootState = getStateWithDefaults(
{ open: contentOpen },
menuRootProps
);
useMenuRoot(host, {
...mapSignals(defaultMenuRootProps),
open: contentOpen
state: menuRootState,
emit: () => void 0
});
}
// src/components/table-handle/table-handle-column-root/types.ts
import {
overlayPositionerEvents,
overlayPositionerProps
} from "@aria-ui/overlay";
var tableHandleColumnRootProps = Object.freeze({
...overlayPositionerProps,
editor: { default: null },
placement: { default: "top" }
});
var tableHandleColumnRootEvents = overlayPositionerEvents;
// src/components/table-handle/table-handle-column-root/element.gen.ts
var TableHandleColumnRootElement = class extends ElementBuilder(useTableHandleColumnRoot, defaultTableHandleColumnRootProps) {
var TableHandleColumnRootElement = class extends defineCustomElement({
props: tableHandleColumnRootProps,
events: tableHandleColumnRootEvents,
setup: useTableHandleColumnRoot
}) {
};
defineCustomElement("prosekit-table-handle-column-root", TableHandleColumnRootElement);
registerCustomElement("prosekit-table-handle-column-root", TableHandleColumnRootElement);
// src/components/table-handle/table-handle-column-trigger/element.gen.ts
import { ElementBuilder as ElementBuilder2 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement2, registerCustomElement as registerCustomElement2 } from "@aria-ui/core";
// src/components/table-handle/table-handle-column-trigger/props.ts
var defaultTableHandleColumnTriggerProps = Object.freeze({
editor: null
});
// src/components/table-handle/table-handle-column-trigger/state.ts
// src/components/table-handle/table-handle-column-trigger/setup.ts
import {
useEventListener
} from "@aria-ui/core";
import { useMenuTrigger } from "@aria-ui/menu";
import { useMenuTrigger } from "@aria-ui/menu/elements";
import { selectTableColumn } from "@prosekit/extensions/table";
function useTableHandleColumnTrigger(host, state) {
function useTableHandleColumnTrigger(host, { state }) {
useMenuTrigger(host);

@@ -105,54 +112,50 @@ const context = tableHandleRootContext.consume(host);

// src/components/table-handle/table-handle-column-trigger/types.ts
var tableHandleColumnTriggerProps = {
editor: { default: null }
};
var tableHandleColumnTriggerEvents = {};
// src/components/table-handle/table-handle-column-trigger/element.gen.ts
var TableHandleColumnTriggerElement = class extends ElementBuilder2(useTableHandleColumnTrigger, defaultTableHandleColumnTriggerProps) {
var TableHandleColumnTriggerElement = class extends defineCustomElement2({
props: tableHandleColumnTriggerProps,
events: tableHandleColumnTriggerEvents,
setup: useTableHandleColumnTrigger
}) {
};
defineCustomElement("prosekit-table-handle-column-trigger", TableHandleColumnTriggerElement);
registerCustomElement2("prosekit-table-handle-column-trigger", TableHandleColumnTriggerElement);
// src/components/table-handle/table-handle-popover-content/element.gen.ts
import { ElementBuilder as ElementBuilder3 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement3, registerCustomElement as registerCustomElement3 } from "@aria-ui/core";
// src/components/table-handle/table-handle-popover-content/props.ts
import { defaultMenuContentProps } from "@aria-ui/menu";
var defaultTableHandlePopoverContentProps = Object.freeze({
...defaultMenuContentProps,
placement: "right-start",
offset: { mainAxis: -4, crossAxis: 4 },
editor: null
});
// src/components/table-handle/table-handle-popover-content/state.ts
// src/components/table-handle/table-handle-popover-content/setup.ts
import {
createComputed as createComputed2,
createSignal as createSignal2,
mapSignals as mapSignals2,
useEffect as useEffect2
} from "@aria-ui/core";
import {
defaultMenuContentProps as defaultMenuContentProps2,
menuContentProps,
useMenuContent
} from "@aria-ui/menu";
function useTableHandlePopoverContent(host, state) {
} from "@aria-ui/menu/elements";
function useTableHandlePopoverContent(host, {
state,
emit
}) {
const rootContext = tableHandleRootContext.consume(host);
const open = createComputed2(() => !!rootContext.get());
const onKeydownHandlerAdd = useKeyboardHandler(host, open);
const menuContentProps = {
...mapSignals2({
...defaultMenuContentProps2,
onKeydownHandlerAdd
}),
placement: state.placement,
offset: state.offset
};
useMenuContent(host, menuContentProps);
const keyDownTarget = useKeyDownTarget(host, open);
const menuContentState = getStateWithDefaults(
{
placement: state.placement,
offset: state.offset,
eventTarget: createSignal2(keyDownTarget)
},
menuContentProps
);
useMenuContent(host, { state: menuContentState, emit });
}
function useKeyboardHandler(element, open) {
const keydownHandler = createSignal2(
null
);
let disposeKeydownHandler;
function useKeyDownTarget(element, open) {
const keydownHandlers = [];
useEffect2(element, () => {
const keydownHandlerValue = keydownHandler.get();
if (!keydownHandlerValue) {
return;
}
const handleKeydown = (event) => {

@@ -162,64 +165,88 @@ if (event.isComposing || event.defaultPrevented || !open.get()) {

}
keydownHandlerValue(event);
keydownHandlers.forEach((handler) => handler(event));
};
document.addEventListener("keydown", handleKeydown);
disposeKeydownHandler = () => {
return () => {
document.removeEventListener("keydown", handleKeydown);
};
});
return (keydownHandlerValue) => {
keydownHandler.set(keydownHandlerValue);
return () => {
disposeKeydownHandler == null ? void 0 : disposeKeydownHandler();
disposeKeydownHandler = void 0;
};
return {
addEventListener: (type, listener) => {
if (type === "keydown") {
keydownHandlers.push(listener);
}
},
removeEventListener: (type, listener) => {
if (type === "keydown") {
const index = keydownHandlers.indexOf(listener);
if (index !== -1) {
keydownHandlers.splice(index, 1);
}
}
}
};
}
// src/components/table-handle/table-handle-popover-content/types.ts
import {
menuContentEvents,
menuContentProps as menuContentProps2
} from "@aria-ui/menu/elements";
var tableHandlePopoverContentProps = Object.freeze({
...menuContentProps2,
placement: { default: "right-start" },
offset: { default: { mainAxis: -4, crossAxis: 4 } },
editor: { default: null }
});
var tableHandlePopoverContentEvents = Object.freeze({
...menuContentEvents
});
// src/components/table-handle/table-handle-popover-content/element.gen.ts
var TableHandlePopoverContentElement = class extends ElementBuilder3(useTableHandlePopoverContent, defaultTableHandlePopoverContentProps) {
var TableHandlePopoverContentElement = class extends defineCustomElement3({
props: tableHandlePopoverContentProps,
events: tableHandlePopoverContentEvents,
setup: useTableHandlePopoverContent
}) {
};
defineCustomElement("prosekit-table-handle-popover-content", TableHandlePopoverContentElement);
registerCustomElement3("prosekit-table-handle-popover-content", TableHandlePopoverContentElement);
// src/components/table-handle/table-handle-popover-item/element.gen.ts
import { ElementBuilder as ElementBuilder4 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement4, registerCustomElement as registerCustomElement4 } from "@aria-ui/core";
// src/components/table-handle/table-handle-popover-item/props.ts
import { defaultMenuItemProps } from "@aria-ui/menu";
var defaultTableHandlePopoverItemProps = Object.freeze({
...defaultMenuItemProps,
disabled: false
});
// src/components/table-handle/table-handle-popover-item/setup.ts
import "@aria-ui/core";
import { useMenuItem } from "@aria-ui/menu/elements";
function useTableHandlePopoverItem(element, {
state,
emit
}) {
useMenuItem(element, { state, emit });
}
// src/components/table-handle/table-handle-popover-item/state.ts
// src/components/table-handle/table-handle-popover-item/types.ts
import {
useAttribute as useAttribute2
} from "@aria-ui/core";
import { useMenuItem } from "@aria-ui/menu";
function useTableHandlePopoverItem(element, state) {
useAttribute2(
element,
"data-disabled",
() => {
var _a;
return ((_a = state.disabled) == null ? void 0 : _a.get()) ? "true" : "false";
}
);
useMenuItem(element, state);
}
menuItemEvents,
menuItemProps
} from "@aria-ui/menu";
var tableHandlePopoverItemProps = {
...menuItemProps
};
var tableHandlePopoverItemEvents = {
...menuItemEvents
};
// src/components/table-handle/table-handle-popover-item/element.gen.ts
var TableHandlePopoverItemElement = class extends ElementBuilder4(useTableHandlePopoverItem, defaultTableHandlePopoverItemProps) {
var TableHandlePopoverItemElement = class extends defineCustomElement4({
props: tableHandlePopoverItemProps,
events: tableHandlePopoverItemEvents,
setup: useTableHandlePopoverItem
}) {
};
defineCustomElement("prosekit-table-handle-popover-item", TableHandlePopoverItemElement);
registerCustomElement4("prosekit-table-handle-popover-item", TableHandlePopoverItemElement);
// src/components/table-handle/table-handle-root/element.gen.ts
import { ElementBuilder as ElementBuilder5 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement5, registerCustomElement as registerCustomElement5 } from "@aria-ui/core";
// src/components/table-handle/table-handle-root/props.ts
var defaultTableHandleRootProps = Object.freeze({
editor: null
});
// src/components/table-handle/table-handle-root/state.ts
// src/components/table-handle/table-handle-root/setup.ts
import {

@@ -303,4 +330,4 @@ createComputed as createComputed3,

// src/components/table-handle/table-handle-root/state.ts
function useTableHandleRoot(host, state) {
// src/components/table-handle/table-handle-root/setup.ts
function useTableHandleRoot(host, { state }) {
const { editor } = state;

@@ -369,32 +396,36 @@ const context = createSignal4(null);

// src/components/table-handle/table-handle-root/types.ts
var tableHandleRootProps = {
editor: { default: null }
};
var tableHandleRootEvents = {};
// src/components/table-handle/table-handle-root/element.gen.ts
var TableHandleRootElement = class extends ElementBuilder5(useTableHandleRoot, defaultTableHandleRootProps) {
var TableHandleRootElement = class extends defineCustomElement5({
props: tableHandleRootProps,
events: tableHandleRootEvents,
setup: useTableHandleRoot
}) {
};
defineCustomElement("prosekit-table-handle-root", TableHandleRootElement);
registerCustomElement5("prosekit-table-handle-root", TableHandleRootElement);
// src/components/table-handle/table-handle-row-root/element.gen.ts
import { ElementBuilder as ElementBuilder6 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement6, registerCustomElement as registerCustomElement6 } from "@aria-ui/core";
// src/components/table-handle/table-handle-row-root/props.ts
// src/components/table-handle/table-handle-row-root/setup.ts
import {
defaultOverlayPositionerProps as defaultOverlayPositionerProps2
} from "@aria-ui/overlay";
var defaultTableHandleRowRootProps = Object.freeze({
...defaultOverlayPositionerProps2,
editor: null,
placement: "left"
});
// src/components/table-handle/table-handle-row-root/state.ts
import {
createComputed as createComputed4,
createSignal as createSignal5,
mapSignals as mapSignals3,
useAttribute as useAttribute3,
defineEmit,
useAttribute as useAttribute2,
useEffect as useEffect4
} from "@aria-ui/core";
import { defaultMenuRootProps as defaultMenuRootProps2, useMenuRoot as useMenuRoot2 } from "@aria-ui/menu";
import { useOverlayPositionerState as useOverlayPositionerState2 } from "@aria-ui/overlay";
import {
menuRootEvents,
menuRootProps as menuRootProps2,
useMenuRoot as useMenuRoot2
} from "@aria-ui/menu/elements";
import { useOverlayPositionerState as useOverlayPositionerState2 } from "@aria-ui/overlay/elements";
import { usePresence as usePresence2 } from "@aria-ui/presence";
function useTableHandleRowRoot(host, state) {
function useTableHandleRowRoot(host, { state }) {
const { editor, ...overlayState } = state;

@@ -422,30 +453,48 @@ const rootContext = tableHandleRootContext.consume(host);

const presence = createComputed4(() => !!referenceCell.get());
useAttribute3(host, "data-state", () => presence.get() ? "open" : "closed");
useAttribute2(host, "data-state", () => presence.get() ? "open" : "closed");
usePresence2(host, presence);
const menuRootState = getStateWithDefaults(
{
open: contentOpen
},
menuRootProps2
);
useMenuRoot2(host, {
...mapSignals3(defaultMenuRootProps2),
open: contentOpen
state: menuRootState,
emit: defineEmit(host, menuRootEvents)
});
}
// src/components/table-handle/table-handle-row-root/types.ts
import {
overlayPositionerProps as overlayPositionerProps2
} from "@aria-ui/overlay";
var tableHandleRowRootProps = {
...overlayPositionerProps2,
editor: { default: null },
placement: { default: "left" }
};
var tableHandleRowRootEvents = {};
// src/components/table-handle/table-handle-row-root/element.gen.ts
var TableHandleRowRootElement = class extends ElementBuilder6(useTableHandleRowRoot, defaultTableHandleRowRootProps) {
var TableHandleRowRootElement = class extends defineCustomElement6({
props: tableHandleRowRootProps,
events: tableHandleRowRootEvents,
setup: useTableHandleRowRoot
}) {
};
defineCustomElement("prosekit-table-handle-row-root", TableHandleRowRootElement);
registerCustomElement6("prosekit-table-handle-row-root", TableHandleRowRootElement);
// src/components/table-handle/table-handle-row-trigger/element.gen.ts
import { ElementBuilder as ElementBuilder7 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement7, registerCustomElement as registerCustomElement7 } from "@aria-ui/core";
// src/components/table-handle/table-handle-row-trigger/props.ts
var defaultTableHandleRowTriggerProps = Object.freeze({
editor: null
});
// src/components/table-handle/table-handle-row-trigger/state.ts
// src/components/table-handle/table-handle-row-trigger/setup.ts
import {
useEventListener as useEventListener2
} from "@aria-ui/core";
import { useMenuTrigger as useMenuTrigger2 } from "@aria-ui/menu";
import { useMenuTrigger as useMenuTrigger2 } from "@aria-ui/menu/elements";
import { selectTableRow } from "@prosekit/extensions/table";
function useTableHandleRowTrigger(host, state) {
function useTableHandleRowTrigger(host, {
state
}) {
useMenuTrigger2(host);

@@ -462,6 +511,18 @@ const context = tableHandleRootContext.consume(host);

// src/components/table-handle/table-handle-row-trigger/types.ts
var tableHandleRowTriggerProps = {
editor: { default: null }
};
var tableHandleRowTriggerEvents = {
select: {}
};
// src/components/table-handle/table-handle-row-trigger/element.gen.ts
var TableHandleRowTriggerElement = class extends ElementBuilder7(useTableHandleRowTrigger, defaultTableHandleRowTriggerProps) {
var TableHandleRowTriggerElement = class extends defineCustomElement7({
props: tableHandleRowTriggerProps,
events: tableHandleRowTriggerEvents,
setup: useTableHandleRowTrigger
}) {
};
defineCustomElement("prosekit-table-handle-row-trigger", TableHandleRowTriggerElement);
registerCustomElement7("prosekit-table-handle-row-trigger", TableHandleRowTriggerElement);
export {

@@ -475,9 +536,16 @@ TableHandleColumnRootElement,

TableHandleRowTriggerElement,
defaultTableHandleColumnRootProps,
defaultTableHandleColumnTriggerProps,
defaultTableHandlePopoverContentProps,
defaultTableHandlePopoverItemProps,
defaultTableHandleRootProps,
defaultTableHandleRowRootProps,
defaultTableHandleRowTriggerProps
tableHandleColumnRootEvents,
tableHandleColumnRootProps,
tableHandleColumnTriggerEvents,
tableHandleColumnTriggerProps,
tableHandlePopoverContentEvents,
tableHandlePopoverContentProps,
tableHandlePopoverItemEvents,
tableHandlePopoverItemProps,
tableHandleRootEvents,
tableHandleRootProps,
tableHandleRowRootEvents,
tableHandleRowRootProps,
tableHandleRowTriggerEvents,
tableHandleRowTriggerProps
};
export { TooltipContentElement } from './_tsup-dts-rollup';
export { defaultTooltipContentProps } from './_tsup-dts-rollup';
export { tooltipContentEvents } from './_tsup-dts-rollup';
export { tooltipContentProps } from './_tsup-dts-rollup';
export { TooltipContentEvents } from './_tsup-dts-rollup';
export { TooltipContentProps } from './_tsup-dts-rollup';
export { TooltipRootElement } from './_tsup-dts-rollup';
export { defaultTooltipRootProps } from './_tsup-dts-rollup';
export { tooltipRootEvents } from './_tsup-dts-rollup';
export { tooltipRootProps } from './_tsup-dts-rollup';
export { TooltipRootEvents } from './_tsup-dts-rollup';
export { TooltipRootProps } from './_tsup-dts-rollup';
export { TooltipTriggerElement } from './_tsup-dts-rollup';
export { defaultTooltipTriggerProps } from './_tsup-dts-rollup';
export { tooltipTriggerEvents } from './_tsup-dts-rollup';
export { tooltipTriggerProps } from './_tsup-dts-rollup';
export { TooltipTriggerEvents } from './_tsup-dts-rollup';
export { TooltipTriggerProps } from './_tsup-dts-rollup';

@@ -1,58 +0,70 @@

import {
defineCustomElement
} from "./chunk-LCDA7GFP.js";
// src/components/tooltip/tooltip-content/element.gen.ts
import { ElementBuilder } from "@aria-ui/core";
import { defineCustomElement, registerCustomElement } from "@aria-ui/core";
// src/components/tooltip/tooltip-content/props.ts
// src/components/tooltip/tooltip-content/setup.ts
import { useTooltipContent } from "@aria-ui/tooltip/elements";
// src/components/tooltip/tooltip-content/types.ts
import {
defaultTooltipContentProps as defaultProps
tooltipContentProps as props,
tooltipContentEvents
} from "@aria-ui/tooltip";
var defaultTooltipContentProps = {
...defaultProps,
shift: true,
flip: true,
offset: 6,
overflowPadding: 4,
var tooltipContentProps = {
...props,
shift: { default: true },
flip: { default: true },
offset: { default: 6 },
overflowPadding: { default: 4 },
// Don't need boundary when hoist is true.
hoist: true,
boundary: []
hoist: { default: true },
boundary: { default: [] }
};
// src/components/tooltip/tooltip-content/state.ts
import { useTooltipContent } from "@aria-ui/tooltip";
// src/components/tooltip/tooltip-content/element.gen.ts
var TooltipContentElement = class extends ElementBuilder(useTooltipContent, defaultTooltipContentProps) {
var TooltipContentElement = class extends defineCustomElement({
props: tooltipContentProps,
events: tooltipContentEvents,
setup: useTooltipContent
}) {
};
defineCustomElement("prosekit-tooltip-content", TooltipContentElement);
registerCustomElement("prosekit-tooltip-content", TooltipContentElement);
// src/components/tooltip/tooltip-root/element.gen.ts
import { ElementBuilder as ElementBuilder2 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement2, registerCustomElement as registerCustomElement2 } from "@aria-ui/core";
// src/components/tooltip/tooltip-root/props.ts
import { defaultTooltipRootProps } from "@aria-ui/tooltip";
// src/components/tooltip/tooltip-root/setup.ts
import { useTooltipRoot } from "@aria-ui/tooltip/elements";
// src/components/tooltip/tooltip-root/state.ts
import { useTooltipRoot } from "@aria-ui/tooltip";
// src/components/tooltip/tooltip-root/types.ts
import { tooltipRootEvents, tooltipRootProps } from "@aria-ui/tooltip/elements";
// src/components/tooltip/tooltip-root/element.gen.ts
var TooltipRootElement = class extends ElementBuilder2(useTooltipRoot, defaultTooltipRootProps) {
var TooltipRootElement = class extends defineCustomElement2({
props: tooltipRootProps,
events: tooltipRootEvents,
setup: useTooltipRoot
}) {
};
defineCustomElement("prosekit-tooltip-root", TooltipRootElement);
registerCustomElement2("prosekit-tooltip-root", TooltipRootElement);
// src/components/tooltip/tooltip-trigger/element.gen.ts
import { ElementBuilder as ElementBuilder3 } from "@aria-ui/core";
import { defineCustomElement as defineCustomElement3, registerCustomElement as registerCustomElement3 } from "@aria-ui/core";
// src/components/tooltip/tooltip-trigger/props.ts
import { defaultTooltipTriggerProps } from "@aria-ui/tooltip";
// src/components/tooltip/tooltip-trigger/setup.ts
import { useTooltipTrigger } from "@aria-ui/tooltip/elements";
// src/components/tooltip/tooltip-trigger/state.ts
import { useTooltipTrigger } from "@aria-ui/tooltip";
// src/components/tooltip/tooltip-trigger/types.ts
import {
tooltipTriggerEvents,
tooltipTriggerProps
} from "@aria-ui/tooltip/elements";
// src/components/tooltip/tooltip-trigger/element.gen.ts
var TooltipTriggerElement = class extends ElementBuilder3(useTooltipTrigger, defaultTooltipTriggerProps) {
var TooltipTriggerElement = class extends defineCustomElement3({
props: tooltipTriggerProps,
events: tooltipTriggerEvents,
setup: useTooltipTrigger
}) {
};
defineCustomElement("prosekit-tooltip-trigger", TooltipTriggerElement);
registerCustomElement3("prosekit-tooltip-trigger", TooltipTriggerElement);
export {

@@ -62,5 +74,8 @@ TooltipContentElement,

TooltipTriggerElement,
defaultTooltipContentProps,
defaultTooltipRootProps,
defaultTooltipTriggerProps
tooltipContentEvents,
tooltipContentProps,
tooltipRootEvents,
tooltipRootProps,
tooltipTriggerEvents,
tooltipTriggerProps
};
{
"name": "@prosekit/web",
"type": "module",
"version": "0.3.19",
"version": "0.4.0",
"private": false,

@@ -73,17 +73,18 @@ "author": {

"dependencies": {
"@aria-ui/collection": "^0.0.3",
"@aria-ui/core": "^0.0.18",
"@aria-ui/listbox": "^0.0.18",
"@aria-ui/menu": "^0.0.12",
"@aria-ui/overlay": "^0.0.19",
"@aria-ui/popover": "^0.0.20",
"@aria-ui/presence": "^0.0.14",
"@aria-ui/tooltip": "^0.0.22",
"@aria-ui/collection": "^0.0.4",
"@aria-ui/core": "^0.0.19",
"@aria-ui/listbox": "^0.0.19",
"@aria-ui/menu": "^0.0.13",
"@aria-ui/overlay": "^0.0.20",
"@aria-ui/popover": "^0.0.21",
"@aria-ui/presence": "^0.0.15",
"@aria-ui/tooltip": "^0.0.23",
"@floating-ui/dom": "^1.6.11",
"@zag-js/dom-query": "^0.68.1",
"just-map-values": "^3.2.0",
"just-omit": "^2.2.0",
"prosemirror-tables": "^1.5.0",
"@prosekit/core": "^0.7.11",
"@prosekit/extensions": "^0.7.18",
"@prosekit/pm": "^0.1.8"
"@prosekit/pm": "^0.1.8",
"@prosekit/extensions": "^0.7.18"
},

@@ -90,0 +91,0 @@ "devDependencies": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc