@prosekit/web 0.0.0-next-20240504134708 → 0.0.0-next-20240505104851
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.
|
@@ -127,17 +127,11 @@ function useAutocompleteList(element, props) {
|
|
|
127
127
|
if (!open.value) {
|
|
128
128
|
autoFocus.value = false;
|
|
129
129
|
} else {
|
|
130
|
-
query.value;
|
|
131
130
|
let canceled = false;
|
|
132
131
|
requestAnimationFrame(() => {
|
|
133
132
|
if (canceled)
|
|
134
133
|
return;
|
|
135
134
|
autoFocus.value = true;
|
|
136
|
-
setTimeout(() => {
|
|
137
|
-
if (canceled)
|
|
138
|
-
return;
|
|
139
|
-
autoFocus.value = false;
|
|
140
|
-
}, 40);
|
|
141
135
|
});
|
|
142
136
|
return () => {
|
|
143
137
|
canceled = true;
|
|
@@ -53,7 +53,7 @@ function useEditorUpdateEvent(host, editor, handler) {
|
|
|
53
53
|
}
|
|
54
54
|
|
|
55
55
|
// src/components/inline-popover/inline-popover/virtual-selection-element.ts
|
|
56
|
-
import {
|
|
56
|
+
import { isTextSelection } from "@prosekit/core";
|
|
57
57
|
|
|
58
58
|
// src/utils/is-in-code-block.ts
|
|
59
59
|
function isInCodeBlock(selection) {
|
|
@@ -67,7 +67,7 @@ function getVirtualSelectionElement(view) {
|
|
|
67
67
|
return null;
|
|
68
68
|
}
|
|
69
69
|
const selection = view.state.selection;
|
|
70
|
-
if (!selection.empty && !isInCodeBlock(selection) &&
|
|
70
|
+
if (!selection.empty && !isInCodeBlock(selection) && isTextSelection(selection)) {
|
|
71
71
|
const decoration = getInlineDecoration(view);
|
|
72
72
|
if (decoration) {
|
|
73
73
|
return decoration;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prosekit/web",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.0.0-next-
|
|
4
|
+
"version": "0.0.0-next-20240505104851",
|
|
5
5
|
"private": false,
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "ocavue",
|
|
@@ -66,16 +66,16 @@
|
|
|
66
66
|
],
|
|
67
67
|
"dependencies": {
|
|
68
68
|
"@aria-ui/collection": "^0.0.3",
|
|
69
|
-
"@aria-ui/core": "^0.0.
|
|
70
|
-
"@aria-ui/listbox": "^0.0.
|
|
71
|
-
"@aria-ui/overlay": "^0.0.
|
|
72
|
-
"@aria-ui/popover": "^0.0.
|
|
73
|
-
"@aria-ui/presence": "^0.0.
|
|
74
|
-
"@aria-ui/tooltip": "^0.0.
|
|
69
|
+
"@aria-ui/core": "^0.0.14",
|
|
70
|
+
"@aria-ui/listbox": "^0.0.13",
|
|
71
|
+
"@aria-ui/overlay": "^0.0.14",
|
|
72
|
+
"@aria-ui/popover": "^0.0.13",
|
|
73
|
+
"@aria-ui/presence": "^0.0.9",
|
|
74
|
+
"@aria-ui/tooltip": "^0.0.15",
|
|
75
75
|
"@floating-ui/dom": "^1.6.4",
|
|
76
|
-
"@prosekit/core": "0.0.0-next-
|
|
77
|
-
"@prosekit/extensions": "0.0.0-next-
|
|
78
|
-
"@prosekit/pm": "0.0.0-next-
|
|
76
|
+
"@prosekit/core": "0.0.0-next-20240505104851",
|
|
77
|
+
"@prosekit/extensions": "0.0.0-next-20240505104851",
|
|
78
|
+
"@prosekit/pm": "0.0.0-next-20240505104851",
|
|
79
79
|
"@zag-js/dom-query": "^0.49.0"
|
|
80
80
|
},
|
|
81
81
|
"devDependencies": {
|