@orangelogic/design-system 2.73.0 → 2.74.0
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.
|
@@ -43550,7 +43550,7 @@ let Tr = class extends Mn {
|
|
|
43550
43550
|
), this.fetchItems = this.fetchItems.bind(this), this.handleMentionKeyDown = this.handleMentionKeyDown.bind(this), this.handleMentionStart = this.handleMentionStart.bind(this), this.handleMentionUpdate = this.handleMentionUpdate.bind(this), this.handleOutsideClick = this.handleOutsideClick.bind(this), this.toggleFullscreen = this.toggleFullscreen.bind(this), this.resetMention = this.resetMention.bind(this);
|
|
43551
43551
|
}
|
|
43552
43552
|
connectedCallback() {
|
|
43553
|
-
super.connectedCallback(), document.addEventListener("click", this.handleOutsideClick);
|
|
43553
|
+
super.connectedCallback(), this.hasUpdated && this.initEditor(), document.addEventListener("click", this.handleOutsideClick);
|
|
43554
43554
|
}
|
|
43555
43555
|
disconnectedCallback() {
|
|
43556
43556
|
super.disconnectedCallback(), document.removeEventListener("click", this.handleOutsideClick), this.debouncedFetch.cancel(), this.caretAnimationId && (cancelAnimationFrame(this.caretAnimationId), this.caretAnimationId = void 0), this.editor?.destroy();
|
|
@@ -43653,7 +43653,7 @@ let Tr = class extends Mn {
|
|
|
43653
43653
|
handleMentionKeyDown(n) {
|
|
43654
43654
|
return n.event.key === "Escape" && this.commentMention.active && (n.event.stopPropagation(), this.resetMention()), n.event.key === "Tab" && (n.event.preventDefault(), this.commentMention.handleEnter()), this.commentMention?.handleKeyDown(n.event);
|
|
43655
43655
|
}
|
|
43656
|
-
|
|
43656
|
+
initEditor() {
|
|
43657
43657
|
this.editor = new T5({
|
|
43658
43658
|
content: this.content,
|
|
43659
43659
|
editable: this.editable,
|
|
@@ -43741,7 +43741,10 @@ let Tr = class extends Mn {
|
|
|
43741
43741
|
parseOptions: {
|
|
43742
43742
|
preserveWhitespace: !0
|
|
43743
43743
|
}
|
|
43744
|
-
})
|
|
43744
|
+
});
|
|
43745
|
+
}
|
|
43746
|
+
runFirstUpdated() {
|
|
43747
|
+
this.initEditor(), FY() && (this.contentEditable = "true"), TO(this.dialog, "dialog.show", null), TO(this.dialog, "dialog.overlay.show", null);
|
|
43745
43748
|
}
|
|
43746
43749
|
handleCommentMousedown(n) {
|
|
43747
43750
|
n.stopPropagation();
|
package/library/package.json
CHANGED
|
@@ -117,6 +117,7 @@ export default class CxComment extends CortexElement {
|
|
|
117
117
|
private handleMentionStart;
|
|
118
118
|
private handleMentionUpdate;
|
|
119
119
|
private handleMentionKeyDown;
|
|
120
|
+
private initEditor;
|
|
120
121
|
runFirstUpdated(): void;
|
|
121
122
|
private handleCommentMousedown;
|
|
122
123
|
handleEditableChange(): void;
|