@aicayzer/inkkit 0.1.0 → 0.1.1
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.
|
@@ -22734,7 +22734,7 @@ var SerializerState = class extends Stack {
|
|
|
22734
22734
|
#closeMark;
|
|
22735
22735
|
};
|
|
22736
22736
|
//#endregion
|
|
22737
|
-
//#region node_modules/.pnpm/prosemirror-view@1.42.
|
|
22737
|
+
//#region node_modules/.pnpm/prosemirror-view@1.42.6_patch_hash=a3414754d6cb6cd32517617a4affee5f7895ca0b3b976186951d43106adf18b3/node_modules/prosemirror-view/dist/index.js
|
|
22738
22738
|
var domIndex = function(node) {
|
|
22739
22739
|
for (var index = 0;; index++) {
|
|
22740
22740
|
node = node.previousSibling;
|
|
@@ -25155,6 +25155,7 @@ var InputState = class {
|
|
|
25155
25155
|
this.lastIOSEnter = 0;
|
|
25156
25156
|
this.lastIOSEnterFallbackTimeout = -1;
|
|
25157
25157
|
this.lastFocus = 0;
|
|
25158
|
+
this.focusTimeout = -1;
|
|
25158
25159
|
this.lastTouch = 0;
|
|
25159
25160
|
this.lastChromeDelete = 0;
|
|
25160
25161
|
this.composing = false;
|
|
@@ -25185,6 +25186,7 @@ function setSelectionOrigin(view, origin) {
|
|
|
25185
25186
|
view.input.lastSelectionTime = Date.now();
|
|
25186
25187
|
}
|
|
25187
25188
|
function destroyInput(view) {
|
|
25189
|
+
clearTimeout(view.input.focusTimeout);
|
|
25188
25190
|
if (view.input.mouseDown) view.input.mouseDown.done();
|
|
25189
25191
|
view.domObserver.stop();
|
|
25190
25192
|
for (let type in view.input.eventHandlers) view.dom.removeEventListener(type, view.input.eventHandlers[type]);
|
|
@@ -25213,6 +25215,17 @@ function dispatchEvent$1(view, event) {
|
|
|
25213
25215
|
}
|
|
25214
25216
|
editHandlers.keydown = (view, _event) => {
|
|
25215
25217
|
let event = _event;
|
|
25218
|
+
if (![
|
|
25219
|
+
16,
|
|
25220
|
+
17,
|
|
25221
|
+
18,
|
|
25222
|
+
91,
|
|
25223
|
+
92,
|
|
25224
|
+
93
|
|
25225
|
+
].includes(event.keyCode)) {
|
|
25226
|
+
clearTimeout(view.input.focusTimeout);
|
|
25227
|
+
view.input.focusTimeout = -1;
|
|
25228
|
+
}
|
|
25216
25229
|
view.input.shiftKey = event.keyCode == 16 || event.shiftKey;
|
|
25217
25230
|
if (inOrNearComposition(view)) return;
|
|
25218
25231
|
view.input.lastKeyCode = event.keyCode;
|
|
@@ -25755,12 +25768,15 @@ handlers.focus = (view) => {
|
|
|
25755
25768
|
view.dom.classList.add("ProseMirror-focused");
|
|
25756
25769
|
view.domObserver.start();
|
|
25757
25770
|
view.focused = true;
|
|
25758
|
-
setTimeout(() => {
|
|
25771
|
+
view.input.focusTimeout = setTimeout(() => {
|
|
25772
|
+
view.input.focusTimeout = -1;
|
|
25759
25773
|
if (view.docView && view.hasFocus() && !view.domObserver.currentSelection.eq(view.domSelectionRange())) selectionToDOM(view);
|
|
25760
25774
|
}, 20);
|
|
25761
25775
|
}
|
|
25762
25776
|
};
|
|
25763
25777
|
handlers.blur = (view, _event) => {
|
|
25778
|
+
clearTimeout(view.input.focusTimeout);
|
|
25779
|
+
view.input.focusTimeout = -1;
|
|
25764
25780
|
let event = _event;
|
|
25765
25781
|
if (view.focused) {
|
|
25766
25782
|
view.domObserver.stop();
|
|
@@ -55171,7 +55187,7 @@ var InkKitEditor = class InkKitEditor {
|
|
|
55171
55187
|
return true;
|
|
55172
55188
|
}
|
|
55173
55189
|
}));
|
|
55174
|
-
}).use(labelsCtx).use(instance.pasteController.plugin).use(visibleClipboard).use(instance.keymapPlugin).use(createDialect(Boolean(options.images || options.files), Boolean(options.wikiLinks), Boolean(options.files))).use(tablePlugins).use(tableBlock).use(instance.changePlugin).use(history).use(clipboard).use(cursor).use(taskListPlugin).use(quoteBackspace).use(calloutEnter).use(literalEnter).use(literalReread).use(listItemBackspace).use(listItemShiftTab).use(nestedItemEnter).use(rejoinLists).use(movedListItems).use(textInputPolicy).use(events.copy ? codeCopyPlugin((text) => events.copy?.(text)) : []).use(placeholderPlugin).use(options.rendering?.codeHighlighting === false ? [] : (await import("./highlight-
|
|
55190
|
+
}).use(labelsCtx).use(instance.pasteController.plugin).use(visibleClipboard).use(instance.keymapPlugin).use(createDialect(Boolean(options.images || options.files), Boolean(options.wikiLinks), Boolean(options.files))).use(tablePlugins).use(tableBlock).use(instance.changePlugin).use(history).use(clipboard).use(cursor).use(taskListPlugin).use(quoteBackspace).use(calloutEnter).use(literalEnter).use(literalReread).use(listItemBackspace).use(listItemShiftTab).use(nestedItemEnter).use(rejoinLists).use(movedListItems).use(textInputPolicy).use(events.copy ? codeCopyPlugin((text) => events.copy?.(text)) : []).use(placeholderPlugin).use(options.rendering?.codeHighlighting === false ? [] : (await import("./highlight-BW9W8PtS.js")).highlightPlugin).use(options.rendering?.diagramPreview === false || !diagramsAvailable() ? [] : mermaidPreview((error) => instance.report(error))).use(selectionPlugin).use($prose(() => search())).use(instance.policyPlugin).use(options.wikiLinks ? wikiLinkView(options.wikiLinks, {
|
|
55175
55191
|
capture: () => instance.adapterCapture(),
|
|
55176
55192
|
active: () => instance.ready && !instance.destroyed && !instance.literalSurface,
|
|
55177
55193
|
labels: {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as Decoration, c as PluginKey, d as __toESM, i as $prose, o as DecorationSet, s as Plugin, u as __commonJSMin } from "./core-
|
|
1
|
+
import { a as Decoration, c as PluginKey, d as __toESM, i as $prose, o as DecorationSet, s as Plugin, u as __commonJSMin } from "./core-CYp5ONPO.js";
|
|
2
2
|
//#region node_modules/.pnpm/highlight.js@11.11.2/node_modules/highlight.js/es/languages/arduino.js
|
|
3
3
|
/** @type LanguageFn */
|
|
4
4
|
function cPlusPlus(hljs) {
|
package/dist/core.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { r as InkKitError, t as InkKitEditor } from "./chunks/core-
|
|
1
|
+
import { r as InkKitError, t as InkKitEditor } from "./chunks/core-CYp5ONPO.js";
|
|
2
2
|
export { InkKitEditor, InkKitError };
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as registerMermaid, r as InkKitError, t as InkKitEditor } from "./chunks/core-
|
|
1
|
+
import { n as registerMermaid, r as InkKitError, t as InkKitEditor } from "./chunks/core-CYp5ONPO.js";
|
|
2
2
|
//#region src/index.ts
|
|
3
3
|
registerMermaid(async () => (await import("mermaid")).default);
|
|
4
4
|
//#endregion
|