feat: add header
This commit is contained in:
parent
0b0bda97c9
commit
ef883ffaec
0
components/templates/TheFooter.vue
Normal file
0
components/templates/TheFooter.vue
Normal file
45
components/templates/TheHeader.vue
Normal file
45
components/templates/TheHeader.vue
Normal file
@ -0,0 +1,45 @@
|
||||
<template>
|
||||
<b-navbar>
|
||||
<template #brand>
|
||||
<b-navbar-item tag="router-link" :to="{ path: '/' }">
|
||||
<img
|
||||
src="https://raw.githubusercontent.com/buefy/buefy/dev/static/img/buefy-logo.png"
|
||||
alt="Lightweight UI components for Vue.js based on Bulma"
|
||||
>
|
||||
</b-navbar-item>
|
||||
</template>
|
||||
<template #start>
|
||||
<b-navbar-item href="#">
|
||||
Home
|
||||
</b-navbar-item>
|
||||
<b-navbar-item href="#">
|
||||
Documentation
|
||||
</b-navbar-item>
|
||||
<b-navbar-dropdown label="Info">
|
||||
<b-navbar-item href="#">
|
||||
About
|
||||
</b-navbar-item>
|
||||
<b-navbar-item href="#">
|
||||
Contact
|
||||
</b-navbar-item>
|
||||
</b-navbar-dropdown>
|
||||
</template>
|
||||
|
||||
<template #end>
|
||||
<b-navbar-item tag="div">
|
||||
<div class="buttons">
|
||||
<a class="button is-primary">
|
||||
<strong>Sign up</strong>
|
||||
</a>
|
||||
<a class="button is-light">
|
||||
Log in
|
||||
</a>
|
||||
</div>
|
||||
</b-navbar-item>
|
||||
</template>
|
||||
</b-navbar>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {}
|
||||
</script>
|
@ -1,74 +1,14 @@
|
||||
<template>
|
||||
<div>
|
||||
<nav
|
||||
class="navbar header has-shadow is-primary"
|
||||
role="navigation"
|
||||
aria-label="main navigation"
|
||||
>
|
||||
<div class="navbar-brand">
|
||||
<a
|
||||
class="navbar-item"
|
||||
href="/"
|
||||
>
|
||||
<img
|
||||
src="~assets/buefy.png"
|
||||
alt="Buefy"
|
||||
height="28"
|
||||
>
|
||||
</a>
|
||||
|
||||
<div class="navbar-burger">
|
||||
<span />
|
||||
<span />
|
||||
<span />
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<section class="main-content columns">
|
||||
<aside class="column is-2 section">
|
||||
<p class="menu-label is-hidden-touch">
|
||||
General
|
||||
</p>
|
||||
<ul class="menu-list">
|
||||
<li
|
||||
v-for="(item, key) of items"
|
||||
:key="key"
|
||||
>
|
||||
<nuxt-link
|
||||
:to="item.to"
|
||||
exact-active-class="is-active"
|
||||
>
|
||||
<b-icon :icon="item.icon" /> {{ item.title }}
|
||||
</nuxt-link>
|
||||
</li>
|
||||
</ul>
|
||||
</aside>
|
||||
|
||||
<div class="container column is-10">
|
||||
<nuxt />
|
||||
</div>
|
||||
</section>
|
||||
<the-header />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import TheHeader from '@/components/templates/TheHeader.vue'
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
items: [
|
||||
{
|
||||
title: 'Home',
|
||||
icon: 'home',
|
||||
to: { name: 'index' }
|
||||
},
|
||||
{
|
||||
title: 'Inspire',
|
||||
icon: 'lightbulb',
|
||||
to: { name: 'inspire' }
|
||||
}
|
||||
]
|
||||
}
|
||||
components: {
|
||||
TheHeader
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
@ -1,53 +1,11 @@
|
||||
<template>
|
||||
<section class="section">
|
||||
<div class="columns is-mobile">
|
||||
<card
|
||||
title="Free"
|
||||
icon="github"
|
||||
>
|
||||
Open source on <a href="https://github.com/buefy/buefy">
|
||||
GitHub
|
||||
</a>
|
||||
</card>
|
||||
|
||||
<card
|
||||
title="Responsive"
|
||||
icon="cellphone-link"
|
||||
>
|
||||
<b class="has-text-grey">
|
||||
Every
|
||||
</b> component is responsive
|
||||
</card>
|
||||
|
||||
<card
|
||||
title="Modern"
|
||||
icon="alert-decagram"
|
||||
>
|
||||
Built with <a href="https://vuejs.org/">
|
||||
Vue.js
|
||||
</a> and <a href="http://bulma.io/">
|
||||
Bulma
|
||||
</a>
|
||||
</card>
|
||||
|
||||
<card
|
||||
title="Lightweight"
|
||||
icon="arrange-bring-to-front"
|
||||
>
|
||||
No other internal dependency
|
||||
</card>
|
||||
</div>
|
||||
</section>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Card from '~/components/Card'
|
||||
|
||||
export default {
|
||||
name: 'HomePage',
|
||||
|
||||
components: {
|
||||
Card
|
||||
}
|
||||
name: 'HomePage'
|
||||
}
|
||||
</script>
|
||||
|
Loading…
x
Reference in New Issue
Block a user