Skip to content

Commit

Permalink
Refactor: ItemCard indents and removed duplicate component imports
Browse files Browse the repository at this point in the history
  • Loading branch information
DanericNetwork committed Dec 20, 2023
1 parent e56c206 commit 8d8dc82
Showing 1 changed file with 47 additions and 50 deletions.
97 changes: 47 additions & 50 deletions src/resources/vue/components/ItemCard.vue
Original file line number Diff line number Diff line change
@@ -1,72 +1,69 @@
<template>
<div class="item-card">
<div class="left">
<Icon icon="book" size="90" color="white" />
<div class="info">
<p>{{ title }}</p>
<p>{{ description }}</p>
</div>
</div>
<div v-if="warning === 'true'" class="right">
<Icon icon="warning" size="35" />
</div>
<div class="item-card">
<div class="left">
<Icon icon="book" size="90" color="white" />
<div class="info">
<p>{{ title }}</p>
<p>{{ description }}</p>
</div>
</div>
<div v-if="warning === 'true'" class="right">
<Icon icon="warning" size="35" />
</div>
</div>
</template>

<script>
import Icon from "./icon.vue";
export default {
name: "ItemCard",
props: {
title: String,
description: String,
warning: Boolean,
},
components: {
Icon,
name: "ItemCard",
props: {
title: String,
description: String,
warning: Boolean,
},
components: {
Icon,
Icon
},
},
};
</script>

<style lang="scss">
.item-card {
width: 667px;
height: 116px;
background: #1D243A;
border-radius: 8px;
width: 667px;
height: 116px;
background: #1d243a;
border-radius: 8px;
display: flex;
align-items: center;
justify-content: space-between;
padding: 13px;
.left {
display: flex;
align-items: center;
justify-content: space-between;
padding: 13px;
.left {
display: flex;
align-items: center;
width: 100%;
height: 100%;
width: 100%;
height: 100%;
.info {
margin-left: 20px;
display: flex;
flex-direction: column;
.info {
margin-left: 20px;
display: flex;
flex-direction: column;
p {
color: #fff;
font-size: 32px;
font-family: "Outfit";
font-weight: 700;
}
}
}
.right {
display: flex;
align-items: flex-start;
height: 100%;
p {
color: #fff;
font-size: 32px;
font-family: "Outfit";
font-weight: 700;
}
}
}
.right {
display: flex;
align-items: flex-start;
height: 100%;
}
}
</style>

0 comments on commit 8d8dc82

Please sign in to comment.