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

@prosekit/extensions

Package Overview
Dependencies
Maintainers
0
Versions
117
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@prosekit/extensions - npm Package Compare versions

Comparing version 0.7.9 to 0.7.10

dist/prosekit-extensions-yjs.d.ts

131

dist/_tsup-dts-rollup.d.ts
import { Attrs } from '@prosekit/pm/model';
import { Attrs as Attrs_2 } from 'prosemirror-model';
import { Awareness } from 'y-protocols/awareness';
import { BaseCommandsExtension } from '@prosekit/core';

@@ -51,2 +52,6 @@ import { BundledLanguage } from 'shiki';

import { WrapInListGetAttrs } from 'prosemirror-flat-list';
import * as Y from 'yjs';
import { yCursorPlugin } from 'y-prosemirror';
import { ySyncPlugin } from 'y-prosemirror';
import { yUndoPlugin } from 'y-prosemirror';

@@ -955,2 +960,27 @@ export declare function applyMarkRules(rules: MarkRuleOptions[], transactions: readonly Transaction[], oldState: EditorState, newState: EditorState): Transaction | null;

/**
* @public
*/
export declare function defineYjs(options: YjsOptions): YjsExtension;
declare function defineYjsCommands(): YjsCommandsExtension;
export { defineYjsCommands }
export { defineYjsCommands as defineYjsCommands_alias_1 }
declare function defineYjsCursorPlugin(options: YjsCursorOptions): PlainExtension;
export { defineYjsCursorPlugin }
export { defineYjsCursorPlugin as defineYjsCursorPlugin_alias_1 }
declare function defineYjsKeymap(): PlainExtension;
export { defineYjsKeymap }
export { defineYjsKeymap as defineYjsKeymap_alias_1 }
declare function defineYjsSyncPlugin(options: YjsSyncOptions): PlainExtension;
export { defineYjsSyncPlugin }
export { defineYjsSyncPlugin as defineYjsSyncPlugin_alias_1 }
declare function defineYjsUndoPlugin(options: YjsUndoOptions): PlainExtension;
export { defineYjsUndoPlugin }
export { defineYjsUndoPlugin as defineYjsUndoPlugin_alias_1 }
/**
* @internal

@@ -1397,2 +1427,7 @@ */

/**
* @internal
*/
export declare const redo: Command;
/**
* Options for {@link defineSearchQuery}

@@ -1510,9 +1545,9 @@ *

image: NodeAction< {
src?: string | null;
src?: (string | null) | undefined;
}>;
list: NodeAction< {
kind?: "bullet" | "ordered" | "task" | "toggle";
order?: number | null;
checked?: boolean;
collapsed?: boolean;
kind?: ("bullet" | "ordered" | "task" | "toggle") | undefined;
order?: (number | null) | undefined;
checked?: boolean | undefined;
collapsed?: boolean | undefined;
}>;

@@ -1743,2 +1778,7 @@ table: NodeAction< {

/**
* @internal
*/
export declare const undo: Command;
export { UnwrapListOptions }

@@ -1753,2 +1793,83 @@

/**
* @internal
*/
export declare type YjsCommandsExtension = Extension<{
Commands: {
undo: [];
redo: [];
};
}>;
declare interface YjsCursorOptions extends YjsCursorPluginOptions {
awareness: Awareness;
}
export { YjsCursorOptions }
export { YjsCursorOptions as YjsCursorOptions_alias_1 }
/**
* Options for `y-prosemirror`'s `yCursorPlugin`.
*/
declare type YjsCursorPluginOptions = NonNullable<Parameters<typeof yCursorPlugin>[1]>;
export { YjsCursorPluginOptions }
export { YjsCursorPluginOptions as YjsCursorPluginOptions_alias_1 }
/**
* @internal
*/
export declare type YjsExtension = Union<[YjsCommandsExtension, PlainExtension]>;
export declare interface YjsOptions {
/**
* The Yjs instance handles the state of shared data.
*/
doc: Y.Doc;
/**
* The Awareness instance.
*/
awareness: Awareness;
/**
* The Yjs XmlFragment to use. If not provided,
* `doc.getXmlFragment('prosemirror')` will be used.
*/
fragment?: Y.XmlFragment;
/**
* Options for `y-prosemirror`'s `ySyncPlugin`.
*/
sync?: YjsSyncPluginOptions;
/**
* Options for the `y-prosemirror`'s `yUndoPlugin`.
*/
undo?: YjsUndoPluginOptions;
/**
* Options for `y-prosemirror`'s `yCursorPlugin`.
*/
cursor?: YjsCursorPluginOptions;
}
declare interface YjsSyncOptions extends YjsSyncPluginOptions {
fragment: Y.XmlFragment;
}
export { YjsSyncOptions }
export { YjsSyncOptions as YjsSyncOptions_alias_1 }
/**
* Options for `y-prosemirror`'s `ySyncPlugin`.
*/
declare type YjsSyncPluginOptions = NonNullable<Parameters<typeof ySyncPlugin>[1]>;
export { YjsSyncPluginOptions }
export { YjsSyncPluginOptions as YjsSyncPluginOptions_alias_1 }
declare interface YjsUndoOptions extends YjsUndoPluginOptions {
}
export { YjsUndoOptions }
export { YjsUndoOptions as YjsUndoOptions_alias_1 }
/**
* Options for the `y-prosemirror`'s `yUndoPlugin`.
*/
declare type YjsUndoPluginOptions = NonNullable<Parameters<typeof yUndoPlugin>[0]>;
export { YjsUndoPluginOptions }
export { YjsUndoPluginOptions as YjsUndoPluginOptions_alias_1 }
export { }

2

dist/prosekit-extensions-blockquote.js

@@ -29,3 +29,3 @@ import {

function defineBlockquote() {
return union([defineBlockquoteSpec(), defineBlockquoteInputRule()]);
return union(defineBlockquoteSpec(), defineBlockquoteInputRule());
}

@@ -32,0 +32,0 @@ export {

@@ -58,3 +58,3 @@ import {

function defineBold() {
return union([
return union(
defineBoldSpec(),

@@ -64,3 +64,3 @@ defineBoldCommands(),

defineBoldInputRule()
]);
);
}

@@ -67,0 +67,0 @@ export {

@@ -121,3 +121,3 @@ import {

function defineCodeBlock() {
return union([
return union(
defineCodeBlockSpec(),

@@ -128,3 +128,3 @@ defineCodeBlockInputRule(),

defineCodeBlockCommands()
]);
);
}

@@ -131,0 +131,0 @@

@@ -40,3 +40,3 @@ import {

function defineCode() {
return union([
return union(
defineCodeSpec(),

@@ -46,3 +46,3 @@ defineCodeCommands(),

defineCodeInputRule()
]);
);
}

@@ -49,0 +49,0 @@ export {

@@ -137,6 +137,6 @@ // src/commit/index.ts

function defineCommitViewer(commit) {
return union([
return union(
defineDefaultState({ defaultDoc: commit.doc }),
defineCommitDecoration(commit)
]);
);
}

@@ -143,0 +143,0 @@ var CommitRecorder = class {

@@ -97,3 +97,3 @@ import {

function defineHeading() {
return union([
return union(
defineHeadingSpec(),

@@ -103,3 +103,3 @@ defineHeadingInputRule(),

defineHeadingCommands()
]);
);
}

@@ -106,0 +106,0 @@ export {

@@ -43,3 +43,3 @@ // src/image/index.ts

function defineImage() {
return union([defineImageSpec(), defineImageCommands()]);
return union(defineImageSpec(), defineImageCommands());
}

@@ -46,0 +46,0 @@ export {

@@ -48,3 +48,3 @@ import {

function defineItalic() {
return union([
return union(
defineItalicSpec(),

@@ -54,3 +54,3 @@ defineItalicCommands(),

defineItalicInputRule()
]);
);
}

@@ -57,0 +57,0 @@ export {

@@ -101,3 +101,3 @@ import {

function defineLink() {
return union([
return union(
defineLinkSpec(),

@@ -107,3 +107,3 @@ defineLinkCommands(),

defineLinkEnterRule()
]);
);
}

@@ -110,0 +110,0 @@ export {

@@ -97,3 +97,3 @@ import {

function defineList() {
return union2([
return union2(
defineListSpec(),

@@ -104,3 +104,3 @@ defineListPlugins(),

defineListCommands()
]);
);
}

@@ -107,0 +107,0 @@ export {

@@ -50,3 +50,3 @@ // src/mention/index.ts

function defineMention() {
return union([defineMentionSpec(), defineMentionCommands()]);
return union(defineMentionSpec(), defineMentionCommands());
}

@@ -53,0 +53,0 @@ export {

@@ -47,3 +47,3 @@ import {

function defineStrike() {
return union([
return union(
defineStrikeSpec(),

@@ -53,3 +53,3 @@ defineStrikeCommands(),

defineStrikeInputRule()
]);
);
}

@@ -56,0 +56,0 @@ export {

@@ -175,3 +175,3 @@ // src/table/index.ts

function defineTable() {
return union([
return union(
defineTableSpec(),

@@ -183,3 +183,3 @@ defineTableRowSpec(),

defineTableCommands()
]);
);
}

@@ -186,0 +186,0 @@ export {

@@ -44,7 +44,7 @@ // src/text-align/index.ts

function defineTextAlign(options) {
return union([
return union(
defineTextAlignAttrs(options.types, options.default || "left"),
defineTextAlignKeymap(options.types),
defineTextAlignCommands(options.types)
]);
);
}

@@ -51,0 +51,0 @@ export {

@@ -34,7 +34,7 @@ // src/underline/index.ts

function defineUnderline() {
return union([
return union(
defineUnderlineSpec(),
defineUnderlineCommands(),
defineUnderlineKeymap()
]);
);
}

@@ -41,0 +41,0 @@ export {

{
"name": "@prosekit/extensions",
"type": "module",
"version": "0.7.9",
"version": "0.7.10",
"private": false,

@@ -183,2 +183,10 @@ "author": {

"default": "./dist/virtual-selection/style.css"
},
"./yjs": {
"types": "./dist/prosekit-extensions-yjs.d.ts",
"import": "./dist/prosekit-extensions-yjs.js",
"default": "./dist/prosekit-extensions-yjs.js"
},
"./yjs/style.css": {
"default": "./dist/yjs/style.css"
}

@@ -197,12 +205,27 @@ },

"prosemirror-tables": "^1.4.0",
"shiki": "^1.12.0",
"shiki": "^1.12.1",
"@prosekit/core": "^0.7.8",
"@prosekit/pm": "^0.1.8"
},
"peerDependencies": {
"y-prosemirror": ">= 1.2.9",
"yjs": ">= 13.6.18"
},
"peerDependenciesMeta": {
"y-prosemirror": {
"optional": true
},
"yjs": {
"optional": true
}
},
"devDependencies": {
"@vitest/browser": "^2.0.4",
"tsup": "^8.2.3",
"@vitest/browser": "^2.0.5",
"tsup": "^8.2.4",
"type-fest": "^4.23.0",
"typescript": "^5.5.3",
"vitest": "^2.0.4",
"typescript": "^5.5.4",
"vitest": "^2.0.5",
"y-prosemirror": "^1.2.9",
"y-protocols": "^1.0.6",
"yjs": "^13.6.18",
"@prosekit/dev": "0.0.0"

@@ -297,2 +320,5 @@ },

"./dist/prosekit-extensions-virtual-selection.d.ts"
],
"yjs": [
"./dist/prosekit-extensions-yjs.d.ts"
]

@@ -299,0 +325,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