Looks like GiftedDialog works? A little cleanup.

This commit is contained in:
Matthew Raymer
2023-07-05 16:27:21 +08:00
parent 49c3971cf2
commit cf54096326
3 changed files with 10 additions and 69 deletions

View File

@@ -41,7 +41,7 @@
</template>
<script lang="ts">
import {Vue, Component, Prop, Emit} from "vue-facing-decorator";
import { Vue, Component, Prop, Emit } from "vue-facing-decorator";
@Component
export default class GiftedDialog extends Vue {
@@ -57,7 +57,7 @@ export default class GiftedDialog extends Vue {
this.giver = giver;
this.visible = true;
}
close() {
this.visible = false;
}
@@ -72,12 +72,12 @@ export default class GiftedDialog extends Vue {
@Emit("dialog-result")
confirm() {
result = {
const result = {
action: "confirm",
giver: this.giver,
hours: parseFloat(this.hours),
description: this.description,
};
};
this.close();
this.description = "";
this.giver = null;
@@ -88,11 +88,10 @@ export default class GiftedDialog extends Vue {
@Emit("dialog-result")
cancel() {
result = { action: "cancel" };
const result = { action: "cancel" };
this.close();
return result;
}
}
</script>