import{h}from"../aleph.core.js";var AlNodeEditor=function(){function e(){}return e.prototype.render=function(){var e=this;if(this.node){var n=this.node,t=n[0],o=n[1];return h("form",{onSubmit:function(e){return e.preventDefault()}},h("ion-item",null,h("ion-textarea",{value:o.text,rows:"5",required:!0,onIonChange:function(e){return o.text=e.detail.value}})),h("ion-button",{size:"small",onClick:function(){e.onDelete.emit(t),e.node=null}},h("ion-icon",{name:"remove"})),h("ion-button",{size:"small",type:"submit",onClick:function(){o.text&&e.onSave.emit([t,o])}},h("ion-icon",{name:"checkmark"})))}return null},Object.defineProperty(e,"is",{get:function(){return"al-node-editor"},enumerable:!0,configurable:!0}),Object.defineProperty(e,"encapsulation",{get:function(){return"shadow"},enumerable:!0,configurable:!0}),Object.defineProperty(e,"properties",{get:function(){return{node:{type:"Any",attr:"node",mutable:!0}}},enumerable:!0,configurable:!0}),Object.defineProperty(e,"events",{get:function(){return[{name:"onDelete",method:"onDelete",bubbles:!0,cancelable:!0,composed:!0},{name:"onSave",method:"onSave",bubbles:!0,cancelable:!0,composed:!0}]},enumerable:!0,configurable:!0}),Object.defineProperty(e,"style",{get:function(){return""},enumerable:!0,configurable:!0}),e}();export{AlNodeEditor};