UNPKG

ares-ide

Version:

A browser-based code editor and UI designer for Enyo 2 projects

43 lines (40 loc) 1.41 kB
enyo.kind({ name: "PaletteComponentActionPopup", kind: "onyx.Popup", published:{ configComponent:"", targetComponent:"" }, components:[ {name:"title", content: "Select one action"}, {name:"body", kind: "FittableRows", noStretch:true, components: [ {name: "vtAction", kind: "ViewTemplateAction", showing:false }, {name: "close", kind: "onyx.Button", content: "Cancel", centered: true, style:"width:200px;height:30px;", ontap: "doPaletteComponentAction"} ]} ], events: { onPaletteComponentAction : "" }, setActionShowing: function(actionName){ for(var n in this.$){ this.$[n].setShowing(false); } this.$.title.setShowing(true); this.$.body.setShowing(true); this.$[actionName].setShowing(true); this.$.close.setShowing(true); } }); enyo.kind({ name: "ViewTemplateAction", kind: "FittableRows", noStretch:true, components: [ {name: "addtoKind", kind: "onyx.Button", content: "Add to current kind", style:"width:200px;height:30px;", ontap: "doPaletteComponentAction"}, {name: "replaceKind", kind: "onyx.Button", content: "Replace current kind", centered: true, style:"width:200px;height:30px;", ontap: "doPaletteComponentAction"}, {name: "addNewKind", kind: "onyx.Button", content: "Add new kind to current file", centered: true, style:"width:200px;height:30px;", ontap: "doPaletteComponentAction"} ], events: { onPaletteComponentAction : "" } });