diff --git a/ccp/executionformfragment.html b/ccp/executionformfragment.html index cfa8512..4bc7c5a 100644 --- a/ccp/executionformfragment.html +++ b/ccp/executionformfragment.html @@ -1,24 +1,25 @@
- - + -
+
\ No newline at end of file diff --git a/ccp/js/executionformcontroller.js b/ccp/js/executionformcontroller.js index efba1cd..123fde6 100644 --- a/ccp/js/executionformcontroller.js +++ b/ccp/js/executionformcontroller.js @@ -6,8 +6,7 @@ class CCPExecutionForm extends HTMLElement{ #method; #serviceurl = "https://nubis1.int.d4science.net:8080" - //#cdnurl = "https://nubis1.int.d4science.net:8080/ccp/fragment.html" - #cdnurl = "http://d4science-cdn-public:8984/resources/ccp/executionformfragment.html" + #cdnurl = "https://nubis1.int.d4science.net:8080/ccp/fragment.html" constructor(){ super() @@ -64,10 +63,10 @@ class CCPExecutionForm extends HTMLElement{ #empty_executionform_bss = { template : "#EXECUTION_FORM_EMPTY_TEMPLATE", - target : "form[name=execution_form]", + target : "div[name=execution_form]", on_drop : ev=>{ - const id = ev.dataTransfer.getData('text/plain+ccpmethod'); - if(id){ + if(ev.dataTransfer && ev.dataTransfer.getData('text/plain+ccpmethod')){ + const id = ev.dataTransfer.getData('text/plain+ccpmethod') this.setAttribute("method", id); ev.preventDefault() ev.stopPropagation() @@ -76,7 +75,6 @@ class CCPExecutionForm extends HTMLElement{ }, on_dragover : ev=>{ ev.preventDefault() - ev.currentTarget.style.backgroundColor = "#eeffff" }, } @@ -85,8 +83,8 @@ class CCPExecutionForm extends HTMLElement{ target : "form[name=execution_form]", in : ()=>this.#data, on_drop : ev=>{ - const id = ev.dataTransfer.getData('text/plain+ccpmethod'); - if(id){ + if(ev.dataTransfer && ev.dataTransfer.getData('text/plain+ccpmethod')){ + const id = ev.dataTransfer.getData('text/plain+ccpmethod'); this.setAttribute("method", id); ev.preventDefault() ev.stopPropagation() @@ -94,8 +92,6 @@ class CCPExecutionForm extends HTMLElement{ }, on_dragover : ev=>{ ev.preventDefault() - ev.currentTarget.style.backGround = "blue" - ev.currentTarget.style.backgroundColor = "#eeffff" }, recurse : [ { diff --git a/ccp/js/inputwidgetcontroller.js b/ccp/js/inputwidgetcontroller.js index 7e460ee..21f1def 100644 --- a/ccp/js/inputwidgetcontroller.js +++ b/ccp/js/inputwidgetcontroller.js @@ -171,7 +171,7 @@ class CodeInputRenderer extends Renderer{ } connectedCallback(controller){ - const ta = controller.querySelector("textarea") + /*const ta = controller.querySelector("textarea") const opts = { lineNumbers: true, indentUnit: 4, @@ -182,7 +182,7 @@ class CodeInputRenderer extends Renderer{ this.#codemirror = CodeMirror.fromTextArea(ta, opts) this.#codemirror.setValue(this.schema.default) - this.#codemirror.refresh() + this.#codemirror.refresh()*/ } render(){ @@ -193,8 +193,7 @@ class CodeInputRenderer extends Renderer{ ${this.title} ? - + ` return this.#html diff --git a/ccp/js/methodlistcontroller.js b/ccp/js/methodlistcontroller.js index 0806a31..296dccd 100644 --- a/ccp/js/methodlistcontroller.js +++ b/ccp/js/methodlistcontroller.js @@ -7,8 +7,7 @@ class CCPMethodList extends HTMLElement{ #dragged = null; #serviceurl = "https://nubis1.int.d4science.net:8080" - //#cdnurl = "https://nubis1.int.d4science.net:8080/ccp/fragment.html" - #cdnurl = "http://d4science-cdn-public:8984/resources/ccp/methodlistfragment.html" + #cdnurl = "https://nubis1.int.d4science.net:8080/ccp/fragment.html" constructor(){ super() @@ -78,14 +77,12 @@ class CCPMethodList extends HTMLElement{ target : "li", "in" : (e,d)=>this.#filtered, on_dragstart : ev=>{ - ev.stopPropagation() ev.dataTransfer.effectAllowed = 'move' ev.dataTransfer.setData('text/html', ev.currentTarget.innerHTML) ev.dataTransfer.setData('text/plain+ccpmethod', ev.currentTarget.bss_input.data.id) }, on_dragend : ev=>{ ev.preventDefault() - ev.stopPropagation() }, recurse : [ {