From ac100de8d8e0fc85e34cde9aec6262259b12f96c Mon Sep 17 00:00:00 2001
From: Cristiano Magro <cristiano.magro@vola.it>
Date: Mon, 30 Dec 2024 21:53:48 +0100
Subject: [PATCH] style scoped locali

---
 07 - development setup/vue-cli-01-a-new-vue-project/src/components/NewFriend.vue |   39 +++++++++++++++++++++++++++++++++++++++
 1 files changed, 39 insertions(+), 0 deletions(-)

diff --git a/07 - development setup/vue-cli-01-a-new-vue-project/src/components/NewFriend.vue b/07 - development setup/vue-cli-01-a-new-vue-project/src/components/NewFriend.vue
new file mode 100644
index 0000000..3d9e8fb
--- /dev/null
+++ b/07 - development setup/vue-cli-01-a-new-vue-project/src/components/NewFriend.vue
@@ -0,0 +1,39 @@
+<template>
+    <form @submit.prevent="submitData">
+        <div>
+            <label>Nome:</label>
+            <input type="text" v-model="name" /><br>
+        </div>
+        <div>
+            <label>Phone:</label>
+            <input type="tel" v-model="phone" /><br>
+        </div>
+        <div>
+            <label>Email:</label>
+            <input type="email" v-model="email" /><br>
+        </div>
+        <div>
+            <button>Add new friend</button>
+        </div>
+    </form>
+</template>
+
+<script>
+export default {
+    data() {
+        return {
+            name: "",
+            phone: "",
+            email: "",
+        }
+    },
+    emits: ['add-contact'],
+    methods: {
+        submitData() {
+            this.$emit('add-contact', this.name, this.phone, this.email);
+        }
+    }
+}
+</script>
+
+<style></style>
\ No newline at end of file

--
Gitblit v1.8.0