09 - deeper into components/cmp-adv-01-starting-setup/src/components/BadgeList.vue
@@ -1,25 +1,29 @@ <template> <section> <base-card> <h2>Available Badges</h2> <ul> <li> <base-badge type="admin" caption="ADMIN"></base-badge> </li> <li> <base-badge type="author" caption="AUTHOR"></base-badge> </li> </ul> </base-card> <base-card> <template v-slot:header> <h2>Available Badges</h2> </template> <template v-slot:default> <ul> <li> <base-badge type="admin" caption="ADMIN"></base-badge> </li> <li> <base-badge type="author" caption="AUTHOR"></base-badge> </li> </ul> </template> </base-card> </section> </template> <style scoped> section h2 { margin: 0.5rem 0; color: #3a3a3a; } ul { list-style: none; margin: 0; 09 - deeper into components/cmp-adv-01-starting-setup/src/components/BaseCard.vue
@@ -1,5 +1,8 @@ <template> <div> <header> <slot name="header"></slot> </header> <slot></slot> </div> </template> 09 - deeper into components/cmp-adv-01-starting-setup/src/components/UserInfo.vue
@@ -1,11 +1,13 @@ <template> <section> <base-card> <header> <template v-slot:header> <h3>{{ fullName }}</h3> <base-badge :type="role" :caption="role.toUpperCase()"></base-badge> </header> <p>{{ infoText }}</p> </template> <template v-slot:default> <p>{{ infoText }}</p> </template> </base-card> </section> </template> @@ -17,7 +19,6 @@ </script> <style scoped> section header { display: flex; justify-content: space-between;