Skip to content

Commit

Permalink
clean(components): Remove template components
Browse files Browse the repository at this point in the history
  • Loading branch information
bonbisu committed Aug 8, 2022
1 parent 2123d34 commit c68339f
Show file tree
Hide file tree
Showing 10 changed files with 14 additions and 121 deletions.
3 changes: 0 additions & 3 deletions .eslintrc

This file was deleted.

2 changes: 1 addition & 1 deletion .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
github: antfu
github: bonbisu
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
MIT License

Copyright (c) 2020-2021 Anthony Fu
Copyright (c) 2022 Fernando Costa(bonbisu)
Copyright (c) 2022 Fernando Costa (bonbisu)

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,5 +55,8 @@
"vite-ssg-sitemap": "^0.3.1",
"vitest": "^0.21.0",
"vue-tsc": "^0.39.5"
},
"eslintConfig": {
"extends": "@antfu"
}
}
1 change: 1 addition & 0 deletions src/components.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ export {}

declare module '@vue/runtime-core' {
export interface GlobalComponents {
BaseButton: typeof import('./components/Atoms/BaseButton.vue')['default']
Counter: typeof import('./components/Counter.vue')['default']
Footer: typeof import('./components/Footer.vue')['default']
README: typeof import('./components/README.md')['default']
Expand Down
19 changes: 0 additions & 19 deletions src/components/Counter.vue

This file was deleted.

33 changes: 0 additions & 33 deletions src/components/Footer.vue

This file was deleted.

6 changes: 1 addition & 5 deletions src/layouts/default.vue
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
<template>
<main class="px-4 py-10 text-center text-gray-700 dark:text-gray-200">
<main class="text-gray-700 dark:text-gray-200">
<RouterView />
<Footer />
<div class="mt-5 mx-auto text-center opacity-75 dark:opacity-50 text-sm">
[Default Layout]
</div>
</main>
</template>
9 changes: 0 additions & 9 deletions src/layouts/home.vue

This file was deleted.

57 changes: 7 additions & 50 deletions src/pages/index.vue
Original file line number Diff line number Diff line change
@@ -1,62 +1,19 @@
<script setup lang="ts">
const user = useUserStore()
const name = $ref(user.savedName)
// const user = useUserStore()
// const name = $ref(user.savedName)
const router = useRouter()
const go = () => {
if (name)
router.push(`/hi/${encodeURIComponent(name)}`)
}
const { t } = useI18n()
// const router = useRouter()
// router.push(`/hi/${encodeURIComponent(name)}`)
// const { t } = useI18n()
</script>

<template>
<div>
<div text-4xl>
<div i-carbon-campsite inline-block />
</div>
<p>
<a rel="noreferrer" href="https://github.com/antfu/vitesse" target="_blank">
Vitesse
</a>
</p>
<p>
<em text-sm opacity-75>{{ t('intro.desc') }}</em>
</p>

<div py-4 />

<input
id="input"
v-model="name"
:placeholder="t('intro.whats-your-name')"
:aria-label="t('intro.whats-your-name')"
type="text"
autocomplete="false"
p="x4 y2"
w="250px"
text="center"
bg="transparent"
border="~ rounded gray-200 dark:gray-700"
outline="none active:none"
@keydown.enter="go"
>
<label class="hidden" for="input">{{ t('intro.whats-your-name') }}</label>

<div>
<button
btn m-3 text-sm
:disabled="!name"
@click="go"
>
{{ t('button.go') }}
</button>
</div>
Landing Page
</div>
</template>

<route lang="yaml">
meta:
layout: home
layout: default
</route>

0 comments on commit c68339f

Please sign in to comment.