Skip to content

Commit

Permalink
feat(design): add logo
Browse files Browse the repository at this point in the history
  • Loading branch information
alexfriesen committed Jan 7, 2025
1 parent 6c44810 commit 5934a12
Show file tree
Hide file tree
Showing 7 changed files with 51 additions and 4 deletions.
2 changes: 2 additions & 0 deletions apps/timer/app/app.vue
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ useHead({

<Head>
<Title>zeity</Title>

<Link rel="icon" type="image/svg+xml" href="/favicon.svg" />
</Head>

<UApp :locale="uiLocale">
Expand Down
8 changes: 5 additions & 3 deletions apps/timer/app/components/AppHeader.vue
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,11 @@ function timeNew() {
class="bg-background/75 backdrop-blur border-b -mb-px sticky top-0 z-50 border-neutral-200 dark:border-neutral-800 min-h-12">
<div class="mx-auto px-4 sm:px-6 lg:px-8 flex items-center justify-between gap-3 h-16">
<div class="lg:flex-1 flex items-center gap-1.5 min-w-0">
<a href="/" class="flex items-end gap-2 font-bold text-xl text-neutral-900 dark:text-white min-w-0">
{{ $t('about.title') }}
</a>
<UButton to="/" icon="i-zeity-logo" variant="ghost">
<span class="font-bold text-xl text-neutral-900 dark:text-white min-w-0">
{{ $t('about.title') }}
</span>
</UButton>
</div>
<div class="flex items-center justify-end lg:flex-1 gap-1.5">
<UButton v-if="$route.path === '/'" square class="rounded-full" icon="i-lucide-plus"
Expand Down
25 changes: 25 additions & 0 deletions apps/timer/app/components/Logo.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<template>
<div class="inline-block rounded-3xl p-8 m-2 border border-[var(--ui-border)] bg-[var(--ui-bg-accented)] shadow-lg aspect-square">
<UIcon name="i-zeity-logo" :class="logoClasses" />
</div>
</template>

<script setup lang="ts">
const props = defineProps({
size: {
type: String as PropType<'sm' | 'md' | 'lg' | 'xl'>,
default: 'lg'
}
});
const sizeClasses = {
'sm': 'size-16',
'md': 'size-24',
'lg': 'size-32',
'xl': 'size-48'
};
const logoClasses = computed(() => {
return `text-[var(--ui-primary)] ${sizeClasses[props.size]}`;
});
</script>
6 changes: 5 additions & 1 deletion apps/timer/app/pages/about.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,14 @@ const config = useRuntimeConfig();
<UContainer class="my-3 space-y-6">

<div>
<div class="text-center">
<Logo size="lg" />
</div>

<p class="text-center text-2xl sm:text-3xl font-extrabold tracking-tight text-[var(--ui-primary)]">
{{ $t('about.title') }}
</p>
<p class="text-center">
<p class="text-center text-pretty">
{{ $t('about.description') }}
</p>
</div>
Expand Down
6 changes: 6 additions & 0 deletions apps/timer/nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,12 @@ export default defineNuxtConfig({
defaultLocale: 'en',
},
icon: {
customCollections: [
{
prefix: 'zeity',
dir: './public/icons'
},
],
clientBundle: {
scan: true,
},
Expand Down
4 changes: 4 additions & 0 deletions apps/timer/public/favicon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions apps/timer/public/icons/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 5934a12

Please sign in to comment.