MCPcopy
hub / github.com/witheve/Eve / apply

Method apply

src/ide/spans.ts:867–885  ·  view source on GitHub ↗
(from:Position, to:Position, origin = "+input")

Source from the content-addressed store, hash-verified

865 commentElem?: HTMLElement;
866
867 apply(from:Position, to:Position, origin = "+input") {
868 this.lineBackgroundClass = "COMMENT_" + this.kind;
869 this._attributes.className = this.type + " " + this.kind;
870
871 if(!this.commentElem) {
872 this.commentElem = document.createElement("div");
873 }
874
875 this.commentElem.className = "comment-widget" + " " + this.kind;
876
877 if(this.editor.inCodeBlock(to)) {
878 this.commentElem.className += " code-comment-widget";
879 }
880
881 if(this.source.delay) {
882 this["updateWidget"] = debounce(this.updateWidget, this.source.delay);
883 }
884 super.apply(from, to, origin);
885 }
886
887 clear(origin:string = "+delete") {
888 if(!this.marker) return;

Callers

nothing calls this directly

Calls 3

debounceFunction · 0.90
inCodeBlockMethod · 0.80
applyMethod · 0.45

Tested by

no test coverage detected