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.0.0-next-20240429132423 to 0.0.0-next-20240429132915

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 @@

40

dist/prosekit-web-autocomplete.js

@@ -231,5 +231,5 @@ import {

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

@@ -243,2 +243,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 +272,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,12 +293,11 @@ queryContext.provide(host, query);

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

@@ -295,3 +309,3 @@ const presenceValue = presence.value;

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

@@ -349,3 +363,3 @@ const regexValue = regex.value;

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

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

{
"name": "@prosekit/web",
"type": "module",
"version": "0.0.0-next-20240429132423",
"version": "0.0.0-next-20240429132915",
"private": false,

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

"@floating-ui/dom": "^1.6.3",
"@prosekit/core": "0.0.0-next-20240429132423",
"@prosekit/extensions": "0.0.0-next-20240429132423",
"@prosekit/pm": "0.0.0-next-20240429132423",
"@prosekit/core": "0.0.0-next-20240429132915",
"@prosekit/extensions": "0.0.0-next-20240429132915",
"@prosekit/pm": "0.0.0-next-20240429132915",
"@zag-js/dom-query": "^0.48.0"

@@ -81,0 +81,0 @@ },

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