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

@prosekit/web

Package Overview
Dependencies
Maintainers
1
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.1.2 to 0.1.3

2

dist/_tsup-dts-rollup.d.ts

@@ -661,2 +661,4 @@ import { BaseElement } from '@aria-ui/core';

export declare function useFirstRendering(host: ConnectableElement): ReadonlySignal<boolean>;
export declare function useInlinePopover(host: ConnectableElement, props?: Partial<InlinePopoverProps>): SignalState<Readonly<InlinePopoverProps>>;

@@ -663,0 +665,0 @@

39

dist/prosekit-web-autocomplete.js

@@ -134,2 +134,3 @@ import {

listboxValue.value = "";
query.value = "";
}

@@ -231,5 +232,5 @@ });

createComputed,
createSignal as createSignal2,
createSignal as createSignal3,
mapSignals,
useEffect as useEffect3
useEffect as useEffect4
} from "@aria-ui/core";

@@ -243,2 +244,17 @@ import { useOverlayPositionerState } from "@aria-ui/overlay";

// src/hooks/use-first-rendering.ts
import {
createSignal as createSignal2,
useEffect as useEffect3
} from "@aria-ui/core";
function useFirstRendering(host) {
const firstRendering = createSignal2(true);
useEffect3(host, () => {
requestAnimationFrame(() => {
firstRendering.value = false;
});
});
return firstRendering;
}
// src/components/autocomplete/autocomplete-popover/helpers.ts

@@ -257,6 +273,6 @@ function defaultQueryBuilder(match) {

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.value);

@@ -278,10 +294,11 @@ queryContext.provide(host, query);

usePresence(host, presence);
useEffect3(host, () => {
const firstRendering = useFirstRendering(host);
useEffect4(host, () => {
var _a;
const queryValue = query.value;
if (presence.peek()) {
if (!firstRendering.peek()) {
(_a = state.onQueryChange.peek()) == null ? void 0 : _a(queryValue);
}
});
useEffect3(host, () => {
useEffect4(host, () => {
var _a;

@@ -293,3 +310,3 @@ const presenceValue = presence.value;

function useAutocompleteExtension(host, editor, regex, reference, query, onDismiss, onSubmit) {
useEffect3(host, () => {
useEffect4(host, () => {
const editorValue = editor.value;

@@ -347,3 +364,3 @@ const regexValue = regex.value;

function useEscapeKeydown(host, handler) {
useEffect3(host, () => {
useEffect4(host, () => {
const handleKeyDown = (event) => {

@@ -350,0 +367,0 @@ if (event.key !== "Escape") {

{
"name": "@prosekit/web",
"type": "module",
"version": "0.1.2",
"version": "0.1.3",
"private": false,

@@ -77,5 +77,5 @@ "author": {

"@prosekit/core": "^0.4.0",
"@prosekit/extensions": "^0.4.2",
"@prosekit/extensions": "^0.4.6",
"@prosekit/pm": "^0.1.2",
"@zag-js/dom-query": "^0.47.0"
"@zag-js/dom-query": "^0.48.0"
},

@@ -86,3 +86,3 @@ "devDependencies": {

"typescript": "^5.4.5",
"vitest": "^1.5.0"
"vitest": "^1.5.2"
},

@@ -89,0 +89,0 @@ "scripts": {

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