@37signals/lexxy 0.1.18-beta → 0.1.19-beta
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/lexxy.esm.js +19 -2
- package/package.json +1 -1
package/dist/lexxy.esm.js
CHANGED
|
@@ -756,6 +756,10 @@ class ActionTextAttachmentUploadNode extends ActionTextAttachmentNode {
|
|
|
756
756
|
return new ActionTextAttachmentUploadNode({ ...node }, node.__key)
|
|
757
757
|
}
|
|
758
758
|
|
|
759
|
+
static importJSON(serializedNode) {
|
|
760
|
+
return new ActionTextAttachmentUploadNode({ ...serializedNode })
|
|
761
|
+
}
|
|
762
|
+
|
|
759
763
|
constructor({ file, uploadUrl, blobUrlTemplate, editor, progress }, key) {
|
|
760
764
|
super({ contentType: file.type }, key);
|
|
761
765
|
this.file = file;
|
|
@@ -795,6 +799,17 @@ class ActionTextAttachmentUploadNode extends ActionTextAttachmentNode {
|
|
|
795
799
|
return { element: img }
|
|
796
800
|
}
|
|
797
801
|
|
|
802
|
+
exportJSON() {
|
|
803
|
+
return {
|
|
804
|
+
type: "action_text_attachment_upload",
|
|
805
|
+
version: 1,
|
|
806
|
+
progress: this.progress,
|
|
807
|
+
uploadUrl: this.uploadUrl,
|
|
808
|
+
blobUrlTemplate: this.blobUrlTemplate,
|
|
809
|
+
...super.exportJSON()
|
|
810
|
+
}
|
|
811
|
+
}
|
|
812
|
+
|
|
798
813
|
#createDOMForImage() {
|
|
799
814
|
return createElement("img")
|
|
800
815
|
}
|
|
@@ -1661,22 +1676,24 @@ class Selection {
|
|
|
1661
1676
|
const node = this.nodeAfterCursor;
|
|
1662
1677
|
if (node instanceof DecoratorNode) {
|
|
1663
1678
|
this.#selectInLexical(node);
|
|
1679
|
+
return true
|
|
1664
1680
|
} else {
|
|
1665
1681
|
this.#contents.deleteSelectedNodes();
|
|
1666
1682
|
}
|
|
1667
1683
|
|
|
1668
|
-
return
|
|
1684
|
+
return false
|
|
1669
1685
|
}
|
|
1670
1686
|
|
|
1671
1687
|
#deletePreviousOrNext() {
|
|
1672
1688
|
const node = this.nodeBeforeCursor;
|
|
1673
1689
|
if (node instanceof DecoratorNode) {
|
|
1674
1690
|
this.#selectInLexical(node);
|
|
1691
|
+
return true
|
|
1675
1692
|
} else {
|
|
1676
1693
|
this.#contents.deleteSelectedNodes();
|
|
1677
1694
|
}
|
|
1678
1695
|
|
|
1679
|
-
return
|
|
1696
|
+
return false
|
|
1680
1697
|
}
|
|
1681
1698
|
|
|
1682
1699
|
#getValidSelectionRange() {
|