Component({ data: { visible: false }, properties:{ dialogVisible: { type: Boolean, value: false, observer: function () { this.setData({ visible: !this.data.visible }) } }, title: { type: String, value: "" }, content: { type: Array, value: [] }, cancelText: { type: String, value: "" }, confirmText: { type: String, value: "" } }, lifetimes: { created () { }, attached () { }, detached () { } }, methods: { closeDialog () { this.setData({ visible: false }) this.triggerEvent("cancel") }, confirmDialog () { this.setData({ visible: false }) this.triggerEvent("confirm") }, catchmove () { } } })