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

@prosekit/core

Package Overview
Dependencies
Maintainers
1
Versions
110
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@prosekit/core - npm Package Compare versions

Comparing version 0.0.18 to 0.0.19

47

dist/_tsup-dts-rollup.d.ts

@@ -0,1 +1,2 @@

import { AllSelection } from '@prosekit/pm/state';
import { Attrs } from '@prosekit/pm/model';

@@ -17,2 +18,3 @@ import { Attrs as Attrs_2 } from 'prosemirror-model';

import { Node as Node_2 } from 'prosemirror-model';
import { NodeSelection } from '@prosekit/pm/state';
import type { NodeSpec } from '@prosekit/pm/model';

@@ -28,4 +30,6 @@ import { NodeType } from '@prosekit/pm/model';

import type { SchemaSpec } from '@prosekit/pm/model';
import { Selection as Selection_2 } from 'prosemirror-state';
import { Selection as Selection_2 } from '@prosekit/pm/state';
import { Selection as Selection_3 } from 'prosemirror-state';
import type { Simplify } from 'type-fest';
import { TextSelection } from '@prosekit/pm/state';
import { Transaction } from '@prosekit/pm/state';

@@ -563,3 +567,3 @@ import type { UnionToIntersection } from 'type-fest';

export declare function getCustomSelection(state: EditorState, from?: number | null, to?: number | null): Selection_2;
export declare function getCustomSelection(state: EditorState, from?: number | null, to?: number | null): Selection_3;

@@ -620,5 +624,17 @@ export declare function getFacetCount(): number;

/**
* @internal
*/
declare function isAllSelection(sel: Selection_2): sel is AllSelection;
export { isAllSelection }
export { isAllSelection as isAllSelection_alias_1 }
export declare const isMac: boolean;
export declare function isMark(mark: unknown): mark is Mark;
/**
* @internal
*/
declare function isMark(mark: unknown): mark is Mark;
export { isMark }
export { isMark as isMark_alias_1 }

@@ -629,5 +645,24 @@ export declare function isMarkActive(state: EditorState, type: string | MarkType, attrs?: Attrs | null): boolean;

export declare function isProseMirrorNode(node: unknown): node is ProseMirrorNode;
/**
* @internal
*/
declare function isNodeSelection(sel: Selection_2): sel is NodeSelection;
export { isNodeSelection }
export { isNodeSelection as isNodeSelection_alias_1 }
/**
* @internal
*/
declare function isProseMirrorNode(node: unknown): node is ProseMirrorNode;
export { isProseMirrorNode }
export { isProseMirrorNode as isProseMirrorNode_alias_1 }
/**
* @internal
*/
declare function isTextSelection(sel: Selection_2): sel is TextSelection;
export { isTextSelection }
export { isTextSelection as isTextSelection_alias_1 }
/**
* @public

@@ -793,4 +828,4 @@ */

declare interface SelectionJson {
from: number;
to: number;
anchor: number;
head: number;
type: string;

@@ -797,0 +832,0 @@ }

@@ -58,1 +58,6 @@ export { addMark } from './_tsup-dts-rollup';

export { htmlToNode } from './_tsup-dts-rollup';
export { isAllSelection } from './_tsup-dts-rollup';
export { isMark } from './_tsup-dts-rollup';
export { isNodeSelection } from './_tsup-dts-rollup';
export { isProseMirrorNode } from './_tsup-dts-rollup';
export { isTextSelection } from './_tsup-dts-rollup';

@@ -640,2 +640,7 @@ // src/commands/add-mark.ts

import { Mark, ProseMirrorNode } from "@prosekit/pm/model";
import {
AllSelection,
NodeSelection,
TextSelection as TextSelection2
} from "@prosekit/pm/state";
function isProseMirrorNode(node) {

@@ -647,2 +652,11 @@ return node instanceof ProseMirrorNode;

}
function isTextSelection(sel) {
return sel instanceof TextSelection2;
}
function isNodeSelection(sel) {
return sel instanceof NodeSelection;
}
function isAllSelection(sel) {
return sel instanceof AllSelection;
}

@@ -1027,6 +1041,6 @@ // src/utils/is-mark-active.ts

// src/commands/select-all.ts
import { AllSelection } from "@prosekit/pm/state";
import { AllSelection as AllSelection2 } from "@prosekit/pm/state";
function selectAll() {
return (state, dispatch) => {
dispatch == null ? void 0 : dispatch(state.tr.setSelection(new AllSelection(state.doc)));
dispatch == null ? void 0 : dispatch(state.tr.setSelection(new AllSelection2(state.doc)));
return true;

@@ -1413,2 +1427,7 @@ };

insertNode,
isAllSelection,
isMark,
isNodeSelection,
isProseMirrorNode,
isTextSelection,
pluginFacet,

@@ -1415,0 +1434,0 @@ removeMark,

2

package.json
{
"name": "@prosekit/core",
"type": "module",
"version": "0.0.18",
"version": "0.0.19",
"private": false,

@@ -6,0 +6,0 @@ "author": {

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