-
-
Notifications
You must be signed in to change notification settings - Fork 211
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: Adrian Marin <adrian@adrianthedev.com>
- Loading branch information
1 parent
27afeba
commit 618ba9a
Showing
66 changed files
with
352 additions
and
115 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,4 +14,4 @@ | |
] | ||
} | ||
] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<template> | ||
<span :class="classes" v-text="label"/> | ||
</template> | ||
|
||
<script> | ||
export default { | ||
props: { | ||
type: String, | ||
label: String, | ||
}, | ||
computed: { | ||
classes() { | ||
const classes = ['whitespace-no-wrap', 'rounded-full', 'uppercase', 'px-2', 'text-xs', 'font-bold', 'text-white'] | ||
const backgrounds = { | ||
info: 'blue', | ||
success: 'green', | ||
danger: 'red', | ||
warning: 'yellow', | ||
} | ||
classes.push(`bg-${backgrounds[this.type]}-500`) | ||
return classes.join(' ') | ||
}, | ||
}, | ||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<template> | ||
<span>—</span> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<template> | ||
<index-field-wrapper :field="field"> | ||
<Badge v-if="badgeLabel" | ||
:type="badgeType" | ||
:label="badgeLabel" | ||
/> | ||
<empty-dash v-else /> | ||
</index-field-wrapper> | ||
</template> | ||
|
||
<script> | ||
import Badge from '@/js/components/BadgeComponent.vue' | ||
export default { | ||
props: ['field'], | ||
components: { Badge }, | ||
computed: { | ||
badgeType() { | ||
return this.field.value.type | ||
}, | ||
badgeLabel() { | ||
return this.field.value.label | ||
}, | ||
}, | ||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,21 @@ | ||
<template> | ||
<index-field-wrapper :field="field"> | ||
{{value}} | ||
<div v-if="value" v-text="value"/> | ||
<empty-dash v-else /> | ||
</index-field-wrapper> | ||
</template> | ||
|
||
<script> | ||
import moment from 'moment' | ||
export default { | ||
data: () => ({}), | ||
props: ['field'], | ||
computed: { | ||
value() { | ||
if (this.field.value) return moment(new Date(this.field.value)).format(this.field.format) | ||
return '-' | ||
return null | ||
}, | ||
}, | ||
methods: {}, | ||
mounted() {}, | ||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,12 @@ | ||
<template> | ||
<index-field-wrapper :field="field" class="w-12"> | ||
{{field.value}} | ||
<div v-if="field.value" v-text="field.value"></div> | ||
<empty-dash v-else /> | ||
</index-field-wrapper> | ||
</template> | ||
|
||
<script> | ||
export default { | ||
data: () => ({}), | ||
props: ['field'], | ||
computed: {}, | ||
methods: {}, | ||
mounted() {}, | ||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,12 @@ | ||
<template> | ||
<index-field-wrapper :field="field"> | ||
{{field.value}} | ||
<div v-if="field.value" v-text="field.value"></div> | ||
<empty-dash v-else /> | ||
</index-field-wrapper> | ||
</template> | ||
|
||
<script> | ||
export default { | ||
data: () => ({}), | ||
props: ['field'], | ||
computed: {}, | ||
methods: {}, | ||
mounted() {}, | ||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,12 @@ | ||
<template> | ||
<index-field-wrapper :field="field"> | ||
{{field.value}} | ||
<div v-if="field.value" v-text="field.value"></div> | ||
<empty-dash v-else /> | ||
</index-field-wrapper> | ||
</template> | ||
|
||
<script> | ||
export default { | ||
data: () => ({}), | ||
props: ['field'], | ||
computed: {}, | ||
methods: {}, | ||
mounted() {}, | ||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<template> | ||
<show-field-wrapper :field="field" :index="index"> | ||
<Badge v-if="badgeLabel" | ||
:type="badgeType" | ||
:label="badgeLabel" | ||
/> | ||
<empty-dash v-else /> | ||
</show-field-wrapper> | ||
</template> | ||
|
||
<script> | ||
import Badge from '@/js/components/BadgeComponent.vue' | ||
export default { | ||
props: ['field', 'index'], | ||
components: { Badge }, | ||
computed: { | ||
badgeType() { | ||
return this.field.value.type | ||
}, | ||
badgeLabel() { | ||
return this.field.value.label | ||
}, | ||
}, | ||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.