Minor header improvements

This commit is contained in:
MD 2022-03-21 15:33:41 +00:00
parent 7628b2e0a3
commit a3ce0f2aff
2 changed files with 5 additions and 4 deletions

View File

@ -4,7 +4,7 @@ import { computed } from "vue";
const props = withDefaults( const props = withDefaults(
defineProps<{ defineProps<{
username: string; username: string;
size?: string; size?: "xs" | "sm" | "md" | "lg";
}>(), }>(),
{ {
size: "md", size: "md",
@ -21,7 +21,7 @@ const sizeClass = computed(() => {
</script> </script>
<template> <template>
<div :class="'bg-gray-100 dark:bg-gray-900 rounded-lg ' + sizeClass"> <div :class="'bg-light-300 dark:bg-dark-500 rounded-lg ' + sizeClass">
<span <span
>{{ username }}'s<br /> >{{ username }}'s<br />
avatar</span avatar</span

View File

@ -3,6 +3,7 @@ import { PropType } from "vue";
import { Project, User } from "hangar-api"; import { Project, User } from "hangar-api";
import UserAvatar from "~/components/UserAvatar.vue"; import UserAvatar from "~/components/UserAvatar.vue";
import Button from "~/components/design/Button.vue"; import Button from "~/components/design/Button.vue";
import Card from "~/components/design/Card.vue";
defineProps({ defineProps({
user: { user: {
@ -17,7 +18,7 @@ defineProps({
</script> </script>
<template> <template>
<section class="background-header rounded-lg p-4"> <Card>
<div class="flex"> <div class="flex">
<UserAvatar :username="project.namespace.owner"></UserAvatar> <UserAvatar :username="project.namespace.owner"></UserAvatar>
<div class="flex-grow mx-4"> <div class="flex-grow mx-4">
@ -32,5 +33,5 @@ defineProps({
<Button>Download latest</Button> <Button>Download latest</Button>
</div> </div>
</div> </div>
</section> </Card>
</template> </template>