@prosekit/basic 0.9.0-beta.0 → 0.9.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{prosekit-basic.d.ts → index.d.ts} +1 -4
- package/dist/index.d.ts.map +1 -0
- package/dist/{prosekit-basic.js → index.js} +1 -3
- package/dist/index.js.map +1 -0
- package/dist/style.css +12 -0
- package/package.json +15 -25
- package/src/style.css +2 -0
- package/src/web.css +25 -0
- package/dist/prosekit-basic.d.ts.map +0 -1
- package/dist/prosekit-basic.js.map +0 -1
|
@@ -19,8 +19,6 @@ import { TableExtension } from "@prosekit/extensions/table";
|
|
|
19
19
|
import { TextExtension } from "@prosekit/extensions/text";
|
|
20
20
|
import { UnderlineExtension } from "@prosekit/extensions/underline";
|
|
21
21
|
import { VirtualSelectionExtension } from "@prosekit/extensions/virtual-selection";
|
|
22
|
-
|
|
23
|
-
//#region src/index.d.ts
|
|
24
22
|
/**
|
|
25
23
|
* @internal
|
|
26
24
|
*/
|
|
@@ -58,6 +56,5 @@ type BasicExtension = Union<[DocExtension, TextExtension, ParagraphExtension, He
|
|
|
58
56
|
* @public
|
|
59
57
|
*/
|
|
60
58
|
declare function defineBasicExtension(): BasicExtension;
|
|
61
|
-
//#endregion
|
|
62
59
|
export { BasicExtension, defineBasicExtension };
|
|
63
|
-
//# sourceMappingURL=
|
|
60
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAkCA;;KAAY,cAAA,GAAiB,KAAA,EAGzB,YAAA,EACA,aAAA,EACA,kBAAA,EACA,gBAAA,EACA,aAAA,EACA,mBAAA,EACA,cAAA,EACA,uBAAA,EACA,kBAAA,EACA,cAAA,EACA,kBAAA,EAEA,eAAA,EACA,aAAA,EACA,kBAAA,EACA,eAAA,EACA,aAAA,EACA,aAAA,EAEA,mBAAA,EACA,qBAAA,EACA,gBAAA,EACA,kBAAA,EACA,yBAAA,EACA,2BAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAoCJ;;;;iBAAgB,oBAAA,CAAA,GAAwB,cAAA"}
|
|
@@ -19,7 +19,6 @@ import { defineTable } from "@prosekit/extensions/table";
|
|
|
19
19
|
import { defineText } from "@prosekit/extensions/text";
|
|
20
20
|
import { defineUnderline } from "@prosekit/extensions/underline";
|
|
21
21
|
import { defineVirtualSelection } from "@prosekit/extensions/virtual-selection";
|
|
22
|
-
//#region src/index.ts
|
|
23
22
|
/**
|
|
24
23
|
* Define a basic extension that includes some common functionality. You can
|
|
25
24
|
* copy this function and customize it to your needs.
|
|
@@ -55,7 +54,6 @@ import { defineVirtualSelection } from "@prosekit/extensions/virtual-selection";
|
|
|
55
54
|
function defineBasicExtension() {
|
|
56
55
|
return union(defineDoc(), defineText(), defineParagraph(), defineHeading(), defineList(), defineBlockquote(), defineImage(), defineHorizontalRule(), defineHardBreak(), defineTable(), defineCodeBlock(), defineItalic(), defineBold(), defineUnderline(), defineStrike(), defineCode(), defineLink(), defineBaseKeymap(), defineBaseCommands(), defineHistory(), defineGapCursor(), defineVirtualSelection(), defineModClickPrevention());
|
|
57
56
|
}
|
|
58
|
-
//#endregion
|
|
59
57
|
export { defineBasicExtension };
|
|
60
58
|
|
|
61
|
-
//# sourceMappingURL=
|
|
59
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../src/index.ts"],"sourcesContent":["import {\n defineBaseCommands,\n defineBaseKeymap,\n defineHistory,\n union,\n type BaseCommandsExtension,\n type BaseKeymapExtension,\n type HistoryExtension,\n type Union,\n} from '@prosekit/core'\nimport { defineBlockquote, type BlockquoteExtension } from '@prosekit/extensions/blockquote'\nimport { defineBold, type BoldExtension } from '@prosekit/extensions/bold'\nimport { defineCode, type CodeExtension } from '@prosekit/extensions/code'\nimport { defineCodeBlock, type CodeBlockExtension } from '@prosekit/extensions/code-block'\nimport { defineDoc, type DocExtension } from '@prosekit/extensions/doc'\nimport { defineGapCursor, type GapCursorExtension } from '@prosekit/extensions/gap-cursor'\nimport { defineHardBreak, type HardBreakExtension } from '@prosekit/extensions/hard-break'\nimport { defineHeading, type HeadingExtension } from '@prosekit/extensions/heading'\nimport { defineHorizontalRule, type HorizontalRuleExtension } from '@prosekit/extensions/horizontal-rule'\nimport { defineImage, type ImageExtension } from '@prosekit/extensions/image'\nimport { defineItalic, type ItalicExtension } from '@prosekit/extensions/italic'\nimport { defineLink, type LinkExtension } from '@prosekit/extensions/link'\nimport { defineList, type ListExtension } from '@prosekit/extensions/list'\nimport { defineModClickPrevention, type ModClickPreventionExtension } from '@prosekit/extensions/mod-click-prevention'\nimport { defineParagraph, type ParagraphExtension } from '@prosekit/extensions/paragraph'\nimport { defineStrike, type StrikeExtension } from '@prosekit/extensions/strike'\nimport { defineTable, type TableExtension } from '@prosekit/extensions/table'\nimport { defineText, type TextExtension } from '@prosekit/extensions/text'\nimport { defineUnderline, type UnderlineExtension } from '@prosekit/extensions/underline'\nimport { defineVirtualSelection, type VirtualSelectionExtension } from '@prosekit/extensions/virtual-selection'\n\n/**\n * @internal\n */\nexport type BasicExtension = Union<\n [\n // Nodes\n DocExtension,\n TextExtension,\n ParagraphExtension,\n HeadingExtension,\n ListExtension,\n BlockquoteExtension,\n ImageExtension,\n HorizontalRuleExtension,\n HardBreakExtension,\n TableExtension,\n CodeBlockExtension,\n // Marks\n ItalicExtension,\n BoldExtension,\n UnderlineExtension,\n StrikeExtension,\n CodeExtension,\n LinkExtension,\n // Others\n BaseKeymapExtension,\n BaseCommandsExtension,\n HistoryExtension,\n GapCursorExtension,\n VirtualSelectionExtension,\n ModClickPreventionExtension,\n ]\n>\n\n/**\n * Define a basic extension that includes some common functionality. You can\n * copy this function and customize it to your needs.\n *\n * It's a combination of the following extension functions:\n *\n * - {@link defineDoc}\n * - {@link defineText}\n * - {@link defineParagraph}\n * - {@link defineHeading}\n * - {@link defineList}\n * - {@link defineBlockquote}\n * - {@link defineImage}\n * - {@link defineHorizontalRule}\n * - {@link defineHardBreak}\n * - {@link defineTable}\n * - {@link defineCodeBlock}\n * - {@link defineItalic}\n * - {@link defineBold}\n * - {@link defineUnderline}\n * - {@link defineStrike}\n * - {@link defineCode}\n * - {@link defineLink}\n * - {@link defineBaseKeymap}\n * - {@link defineBaseCommands}\n * - {@link defineHistory}\n * - {@link defineGapCursor}\n * - {@link defineVirtualSelection}\n * - {@link defineModClickPrevention}\n *\n * @public\n */\nexport function defineBasicExtension(): BasicExtension {\n return union(\n // Nodes\n defineDoc(),\n defineText(),\n defineParagraph(),\n defineHeading(),\n defineList(),\n defineBlockquote(),\n defineImage(),\n defineHorizontalRule(),\n defineHardBreak(),\n defineTable(),\n defineCodeBlock(),\n // Marks\n defineItalic(),\n defineBold(),\n defineUnderline(),\n defineStrike(),\n defineCode(),\n defineLink(),\n // Others\n defineBaseKeymap(),\n defineBaseCommands(),\n defineHistory(),\n defineGapCursor(),\n defineVirtualSelection(),\n defineModClickPrevention(),\n )\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiGA,SAAgB,uBAAuC;AACrD,QAAO,MAEL,WAAW,EACX,YAAY,EACZ,iBAAiB,EACjB,eAAe,EACf,YAAY,EACZ,kBAAkB,EAClB,aAAa,EACb,sBAAsB,EACtB,iBAAiB,EACjB,aAAa,EACb,iBAAiB,EAEjB,cAAc,EACd,YAAY,EACZ,iBAAiB,EACjB,cAAc,EACd,YAAY,EACZ,YAAY,EAEZ,kBAAkB,EAClB,oBAAoB,EACpB,eAAe,EACf,iBAAiB,EACjB,wBAAwB,EACxB,0BAA0B,CAC3B"}
|
package/dist/style.css
CHANGED
|
@@ -249,3 +249,15 @@ prosekit-table-handle-drop-indicator {
|
|
|
249
249
|
.ProseMirror-focused .ProseMirror-gapcursor {
|
|
250
250
|
display: block;
|
|
251
251
|
}
|
|
252
|
+
|
|
253
|
+
prosekit-autocomplete-root, prosekit-block-handle-root, prosekit-table-handle-root, prosekit-table-handle-column-menu-root, prosekit-table-handle-row-menu-root, prosekit-tooltip-root, prosekit-menu-root {
|
|
254
|
+
display: contents;
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
prosekit-tooltip-positioner, prosekit-autocomplete-positioner, prosekit-menu-positioner, prosekit-popover-positioner, prosekit-inline-popover-positioner, prosekit-block-handle-positioner, prosekit-table-handle-column-positioner, prosekit-table-handle-row-positioner {
|
|
258
|
+
background: none;
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
:is(prosekit-tooltip-positioner, prosekit-autocomplete-positioner, prosekit-menu-positioner, prosekit-popover-positioner, prosekit-inline-popover-positioner, prosekit-block-handle-positioner, prosekit-table-handle-column-positioner, prosekit-table-handle-row-positioner):not([data-state]) {
|
|
262
|
+
display: none;
|
|
263
|
+
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prosekit/basic",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.9.0-beta.
|
|
4
|
+
"version": "0.9.0-beta.2",
|
|
5
5
|
"private": false,
|
|
6
6
|
"description": "A quick starter for ProseKit",
|
|
7
7
|
"author": {
|
|
@@ -23,12 +23,12 @@
|
|
|
23
23
|
"ProseMirror"
|
|
24
24
|
],
|
|
25
25
|
"sideEffects": false,
|
|
26
|
-
"main": "./dist/
|
|
27
|
-
"module": "./dist/
|
|
26
|
+
"main": "./dist/index.js",
|
|
27
|
+
"module": "./dist/index.js",
|
|
28
28
|
"exports": {
|
|
29
29
|
".": {
|
|
30
|
-
"types": "./dist/
|
|
31
|
-
"default": "./dist/
|
|
30
|
+
"types": "./dist/index.d.ts",
|
|
31
|
+
"default": "./dist/index.js"
|
|
32
32
|
},
|
|
33
33
|
"./style.css": {
|
|
34
34
|
"default": "./dist/style.css"
|
|
@@ -42,43 +42,33 @@
|
|
|
42
42
|
"src"
|
|
43
43
|
],
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@prosekit/core": "^0.12.0-beta.
|
|
46
|
-
"@prosekit/
|
|
47
|
-
"@prosekit/
|
|
45
|
+
"@prosekit/core": "^0.12.0-beta.1",
|
|
46
|
+
"@prosekit/pm": "^0.1.16-beta.0",
|
|
47
|
+
"@prosekit/extensions": "^0.16.0-beta.1"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
50
|
"@types/jsdom": "^28.0.1",
|
|
51
|
-
"happy-dom": "^20.
|
|
52
|
-
"jsdom": "^29.0.
|
|
53
|
-
"sass": "^1.
|
|
54
|
-
"tsdown": "^0.21.
|
|
51
|
+
"happy-dom": "^20.9.0",
|
|
52
|
+
"jsdom": "^29.0.2",
|
|
53
|
+
"sass": "^1.99.0",
|
|
54
|
+
"tsdown": "^0.21.8",
|
|
55
55
|
"typescript": "~5.9.3",
|
|
56
|
-
"vitest": "^4.1.
|
|
56
|
+
"vitest": "^4.1.4",
|
|
57
57
|
"@prosekit/config-ts": "0.0.0",
|
|
58
58
|
"@prosekit/config-tsdown": "0.0.0",
|
|
59
59
|
"@prosekit/config-vitest": "0.0.0"
|
|
60
60
|
},
|
|
61
|
-
"publishConfig": {
|
|
62
|
-
"dev": {}
|
|
63
|
-
},
|
|
64
|
-
"dev": {
|
|
65
|
-
"entry": {
|
|
66
|
-
"prosekit-basic": "./src/index.ts",
|
|
67
|
-
"style": "./src/style.css",
|
|
68
|
-
"typography": "./src/typography.css"
|
|
69
|
-
}
|
|
70
|
-
},
|
|
71
61
|
"scripts": {
|
|
72
62
|
"dev": "sass --watch --no-source-map ./src/typography.scss ./src/typography.gen.css",
|
|
73
63
|
"gen": "sass --no-source-map ./src/typography.scss ./src/typography.gen.css",
|
|
74
64
|
"build:tsc": "tsc -b tsconfig.json",
|
|
75
65
|
"build:tsdown": "tsdown"
|
|
76
66
|
},
|
|
77
|
-
"types": "./dist/
|
|
67
|
+
"types": "./dist/index.d.ts",
|
|
78
68
|
"typesVersions": {
|
|
79
69
|
"*": {
|
|
80
70
|
".": [
|
|
81
|
-
"./dist/
|
|
71
|
+
"./dist/index.d.ts"
|
|
82
72
|
]
|
|
83
73
|
}
|
|
84
74
|
}
|
package/src/style.css
CHANGED
package/src/web.css
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
prosekit-autocomplete-root,
|
|
2
|
+
prosekit-block-handle-root,
|
|
3
|
+
prosekit-table-handle-root,
|
|
4
|
+
prosekit-table-handle-column-menu-root,
|
|
5
|
+
prosekit-table-handle-row-menu-root,
|
|
6
|
+
prosekit-tooltip-root,
|
|
7
|
+
prosekit-menu-root {
|
|
8
|
+
display: contents;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
prosekit-tooltip-positioner,
|
|
12
|
+
prosekit-autocomplete-positioner,
|
|
13
|
+
prosekit-menu-positioner,
|
|
14
|
+
prosekit-popover-positioner,
|
|
15
|
+
prosekit-inline-popover-positioner,
|
|
16
|
+
prosekit-block-handle-positioner,
|
|
17
|
+
prosekit-table-handle-column-positioner,
|
|
18
|
+
prosekit-table-handle-row-positioner {
|
|
19
|
+
background: transparent;
|
|
20
|
+
|
|
21
|
+
/* Only show when the web component is mounted */
|
|
22
|
+
&:not([data-state]) {
|
|
23
|
+
display: none;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"prosekit-basic.d.ts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAkCA;KAAY,cAAA,GAAiB,KAAA,EAGzB,YAAA,EACA,aAAA,EACA,kBAAA,EACA,gBAAA,EACA,aAAA,EACA,mBAAA,EACA,cAAA,EACA,uBAAA,EACA,kBAAA,EACA,cAAA,EACA,kBAAA,EAEA,eAAA,EACA,aAAA,EACA,kBAAA,EACA,eAAA,EACA,aAAA,EACA,aAAA,EAEA,mBAAA,EACA,qBAAA,EACA,gBAAA,EACA,kBAAA,EACA,yBAAA,EACA,2BAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAoCJ;;;iBAAgB,oBAAA,CAAA,GAAwB,cAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"prosekit-basic.js","names":[],"sources":["../src/index.ts"],"sourcesContent":["import {\n defineBaseCommands,\n defineBaseKeymap,\n defineHistory,\n union,\n type BaseCommandsExtension,\n type BaseKeymapExtension,\n type HistoryExtension,\n type Union,\n} from '@prosekit/core'\nimport { defineBlockquote, type BlockquoteExtension } from '@prosekit/extensions/blockquote'\nimport { defineBold, type BoldExtension } from '@prosekit/extensions/bold'\nimport { defineCode, type CodeExtension } from '@prosekit/extensions/code'\nimport { defineCodeBlock, type CodeBlockExtension } from '@prosekit/extensions/code-block'\nimport { defineDoc, type DocExtension } from '@prosekit/extensions/doc'\nimport { defineGapCursor, type GapCursorExtension } from '@prosekit/extensions/gap-cursor'\nimport { defineHardBreak, type HardBreakExtension } from '@prosekit/extensions/hard-break'\nimport { defineHeading, type HeadingExtension } from '@prosekit/extensions/heading'\nimport { defineHorizontalRule, type HorizontalRuleExtension } from '@prosekit/extensions/horizontal-rule'\nimport { defineImage, type ImageExtension } from '@prosekit/extensions/image'\nimport { defineItalic, type ItalicExtension } from '@prosekit/extensions/italic'\nimport { defineLink, type LinkExtension } from '@prosekit/extensions/link'\nimport { defineList, type ListExtension } from '@prosekit/extensions/list'\nimport { defineModClickPrevention, type ModClickPreventionExtension } from '@prosekit/extensions/mod-click-prevention'\nimport { defineParagraph, type ParagraphExtension } from '@prosekit/extensions/paragraph'\nimport { defineStrike, type StrikeExtension } from '@prosekit/extensions/strike'\nimport { defineTable, type TableExtension } from '@prosekit/extensions/table'\nimport { defineText, type TextExtension } from '@prosekit/extensions/text'\nimport { defineUnderline, type UnderlineExtension } from '@prosekit/extensions/underline'\nimport { defineVirtualSelection, type VirtualSelectionExtension } from '@prosekit/extensions/virtual-selection'\n\n/**\n * @internal\n */\nexport type BasicExtension = Union<\n [\n // Nodes\n DocExtension,\n TextExtension,\n ParagraphExtension,\n HeadingExtension,\n ListExtension,\n BlockquoteExtension,\n ImageExtension,\n HorizontalRuleExtension,\n HardBreakExtension,\n TableExtension,\n CodeBlockExtension,\n // Marks\n ItalicExtension,\n BoldExtension,\n UnderlineExtension,\n StrikeExtension,\n CodeExtension,\n LinkExtension,\n // Others\n BaseKeymapExtension,\n BaseCommandsExtension,\n HistoryExtension,\n GapCursorExtension,\n VirtualSelectionExtension,\n ModClickPreventionExtension,\n ]\n>\n\n/**\n * Define a basic extension that includes some common functionality. You can\n * copy this function and customize it to your needs.\n *\n * It's a combination of the following extension functions:\n *\n * - {@link defineDoc}\n * - {@link defineText}\n * - {@link defineParagraph}\n * - {@link defineHeading}\n * - {@link defineList}\n * - {@link defineBlockquote}\n * - {@link defineImage}\n * - {@link defineHorizontalRule}\n * - {@link defineHardBreak}\n * - {@link defineTable}\n * - {@link defineCodeBlock}\n * - {@link defineItalic}\n * - {@link defineBold}\n * - {@link defineUnderline}\n * - {@link defineStrike}\n * - {@link defineCode}\n * - {@link defineLink}\n * - {@link defineBaseKeymap}\n * - {@link defineBaseCommands}\n * - {@link defineHistory}\n * - {@link defineGapCursor}\n * - {@link defineVirtualSelection}\n * - {@link defineModClickPrevention}\n *\n * @public\n */\nexport function defineBasicExtension(): BasicExtension {\n return union(\n // Nodes\n defineDoc(),\n defineText(),\n defineParagraph(),\n defineHeading(),\n defineList(),\n defineBlockquote(),\n defineImage(),\n defineHorizontalRule(),\n defineHardBreak(),\n defineTable(),\n defineCodeBlock(),\n // Marks\n defineItalic(),\n defineBold(),\n defineUnderline(),\n defineStrike(),\n defineCode(),\n defineLink(),\n // Others\n defineBaseKeymap(),\n defineBaseCommands(),\n defineHistory(),\n defineGapCursor(),\n defineVirtualSelection(),\n defineModClickPrevention(),\n )\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiGA,SAAgB,uBAAuC;AACrD,QAAO,MAEL,WAAW,EACX,YAAY,EACZ,iBAAiB,EACjB,eAAe,EACf,YAAY,EACZ,kBAAkB,EAClB,aAAa,EACb,sBAAsB,EACtB,iBAAiB,EACjB,aAAa,EACb,iBAAiB,EAEjB,cAAc,EACd,YAAY,EACZ,iBAAiB,EACjB,cAAc,EACd,YAAY,EACZ,YAAY,EAEZ,kBAAkB,EAClB,oBAAoB,EACpB,eAAe,EACf,iBAAiB,EACjB,wBAAwB,EACxB,0BAA0B,CAC3B"}
|