forked from ofs/fensir
feat: layout main page
This commit is contained in:
parent
81f7051581
commit
0d027446a2
9 changed files with 79 additions and 12 deletions
39
src/components/Footer.astro
Normal file
39
src/components/Footer.astro
Normal file
|
@ -0,0 +1,39 @@
|
||||||
|
---
|
||||||
|
import CarbonArrowRight from "@/icons/CarbonArrowUpRight.vue"
|
||||||
|
const commit = "d9ea5cf7d6"
|
||||||
|
---
|
||||||
|
|
||||||
|
<footer>
|
||||||
|
<div class="commit">
|
||||||
|
build commit: <a href={`/${commit}`}> { commit } <CarbonArrowRight class="icon" /> </a>
|
||||||
|
</div>
|
||||||
|
</footer>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
footer {
|
||||||
|
display: grid;
|
||||||
|
grid-auto-flow: column;
|
||||||
|
justify-self: end;
|
||||||
|
margin-bottom: 2rem;
|
||||||
|
font-size: 14px;
|
||||||
|
color: var(--primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
footer div.commit {
|
||||||
|
display: flex;
|
||||||
|
justify-self: end;
|
||||||
|
margin-right: 3rem;
|
||||||
|
gap: 5px;
|
||||||
|
a {
|
||||||
|
display: inline-flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 5px;
|
||||||
|
text-decoration: underline;
|
||||||
|
text-underline-offset: 5px;
|
||||||
|
}
|
||||||
|
& .icon {
|
||||||
|
width: 1.1rem;
|
||||||
|
height: 1.1rem;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
<style>
|
|
@ -1,4 +1,6 @@
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
|
import CarbonArrowRight from '@/icons/CarbonArrowRight.vue'
|
||||||
|
import CarbonRecentlyView from '@/icons/CarbonRecentlyViewed.vue'
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
@ -8,17 +10,21 @@
|
||||||
<span class="search__context-item"> global </span>
|
<span class="search__context-item"> global </span>
|
||||||
</div>
|
</div>
|
||||||
<input type="search" />
|
<input type="search" />
|
||||||
|
<div class="search__buttons">
|
||||||
|
<CarbonRecentlyView class="icon" />
|
||||||
|
<CarbonArrowRight class="icon" />
|
||||||
|
</div>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style>
|
<style scoped>
|
||||||
fieldset.search {
|
fieldset.search {
|
||||||
border: 1px solid var(--accent);
|
border: 1px solid var(--accent);
|
||||||
background: var(--darken);
|
background: var(--darken);
|
||||||
min-width: 50%;
|
min-width: 50%;
|
||||||
display: grid;
|
display: grid;
|
||||||
|
grid-template-columns: 0.2fr 0.5fr 0.3fr;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
grid-template-columns: 0.22fr 0.7fr;
|
|
||||||
outline: none;
|
outline: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -33,6 +39,8 @@ fieldset.search input {
|
||||||
fieldset.search .search__context {
|
fieldset.search .search__context {
|
||||||
display: inline-grid;
|
display: inline-grid;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
grid-auto-flow: column;
|
||||||
|
justify-self: start;
|
||||||
background: var(--black);
|
background: var(--black);
|
||||||
margin: 10px;
|
margin: 10px;
|
||||||
padding: 10px 0;
|
padding: 10px 0;
|
||||||
|
@ -48,4 +56,18 @@ fieldset.search .search__context {
|
||||||
input:focus-visible, fieldset:focus-visible {
|
input:focus-visible, fieldset:focus-visible {
|
||||||
outline: 0;
|
outline: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fieldset.search .search__buttons {
|
||||||
|
display: grid;
|
||||||
|
grid-auto-flow: column;
|
||||||
|
justify-self: end;
|
||||||
|
gap: 15px;
|
||||||
|
margin-right: 15px;
|
||||||
|
& svg.icon {
|
||||||
|
width: 1.3rem;
|
||||||
|
height: 1.3rem;
|
||||||
|
justify-self: end;
|
||||||
|
color: var(--primary);
|
||||||
|
}
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -1 +0,0 @@
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 32 32"><path fill="currentColor" d="m18 6l-1.43 1.393L24.15 15H4v2h20.15l-7.58 7.573L18 26l10-10z"/></svg>
|
|
Before Width: | Height: | Size: 182 B |
3
src/icons/CarbonArrowRight.vue
Normal file
3
src/icons/CarbonArrowRight.vue
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
<template>
|
||||||
|
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32"><path fill="currentColor" d="m18 6l-1.43 1.393L24.15 15H4v2h20.15l-7.58 7.573L18 26l10-10z"/></svg>
|
||||||
|
</template>
|
3
src/icons/CarbonArrowUpRight.vue
Normal file
3
src/icons/CarbonArrowUpRight.vue
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
<template>
|
||||||
|
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32"><path fill="currentColor" d="M10 6v2h12.59L6 24.59L7.41 26L24 9.41V22h2V6z"/></svg>
|
||||||
|
</template>
|
|
@ -1 +0,0 @@
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 32 32"><path fill="currentColor" d="M20.59 22L15 16.41V7h2v8.58l5 5.01z"/><path fill="currentColor" d="M16 2A13.94 13.94 0 0 0 6 6.23V2H4v8h8V8H7.08A12 12 0 1 1 4 16H2A14 14 0 1 0 16 2"/></svg>
|
|
Before Width: | Height: | Size: 269 B |
3
src/icons/CarbonRecentlyViewed.vue
Normal file
3
src/icons/CarbonRecentlyViewed.vue
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
<template>
|
||||||
|
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32"><path fill="currentColor" d="M20.59 22L15 16.41V7h2v8.58l5 5.01z"/><path fill="currentColor" d="M16 2A13.94 13.94 0 0 0 6 6.23V2H4v8h8V8H7.08A12 12 0 1 1 4 16H2A14 14 0 1 0 16 2"/></svg>
|
||||||
|
</template>
|
|
@ -1,17 +1,19 @@
|
||||||
---
|
---
|
||||||
import Default from "@/layouts/Default.astro"
|
import Default from "@/layouts/Default.astro"
|
||||||
import Button from "@/components/Button.vue"
|
import Button from "@/components/Button.vue"
|
||||||
import Input from "@/components/Input.vue"
|
import Search from "@/components/Search.vue"
|
||||||
|
import Footer from "@/components/Footer.astro"
|
||||||
---
|
---
|
||||||
|
|
||||||
<Default>
|
<Default>
|
||||||
<header>
|
<header>
|
||||||
<span class="rate"> 0 / 1000 RQT </span>
|
<span class="rate"> 0 / 5000 RQT </span>
|
||||||
<Button class="sign" />
|
<Button class="sign" />
|
||||||
</header>
|
</header>
|
||||||
<main>
|
<main>
|
||||||
<Input />
|
<Search />
|
||||||
</main>
|
</main>
|
||||||
|
<Footer />
|
||||||
</Default>
|
</Default>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
@ -35,9 +37,7 @@ button.sign {
|
||||||
|
|
||||||
main {
|
main {
|
||||||
display: grid;
|
display: grid;
|
||||||
align-content: center;
|
place-items: center;
|
||||||
justify-items: center;
|
min-height: calc(100vh - 55px - 2.5rem);
|
||||||
align-items: center;
|
|
||||||
min-height: 100vh;
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -14,5 +14,4 @@
|
||||||
body {
|
body {
|
||||||
font-family: 'JetBrains Mono Variable', monospace;
|
font-family: 'JetBrains Mono Variable', monospace;
|
||||||
background: var(--secondary);
|
background: var(--secondary);
|
||||||
min-height: 100vh;
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue