Skip to content

Commit

Permalink
[#13] Updated main layout
Browse files Browse the repository at this point in the history
  • Loading branch information
qtsky89 committed May 6, 2022
1 parent b47bff7 commit cbc3ef1
Showing 1 changed file with 25 additions and 29 deletions.
54 changes: 25 additions & 29 deletions tblog_quasar/src/layouts/MainLayout.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<q-layout view="lHh Lpr lFf">
<q-header elevated>
<q-layout view="hHh lpr lFr">
<q-header reveal class="bg-grey-2 text-black">
<q-toolbar>
<q-btn
flat
Expand All @@ -10,27 +10,23 @@
aria-label="Menu"
@click="toggleLeftDrawer"
/>
<q-toolbar-title>Wonhee's Tech Blog</q-toolbar-title>

<q-toolbar-title>
Quasar App
</q-toolbar-title>

<div>Quasar v{{ $q.version }}</div>
<!-- TODO: add control feature (create, update, login, logout)-->
<q-avatar class="bg-black">
<img src="https://cdn.quasar.dev/logo-v2/svg/logo-mono-white.svg" />
</q-avatar>
</q-toolbar>
</q-header>

<q-drawer
v-model="leftDrawerOpen"
side="left"
show-if-above
bordered
overlay
>
<q-list>
<q-item-label
header
>
Essential Links
</q-item-label>

<EssentialLink
v-for="link in essentialLinks"
:key="link.title"
Expand All @@ -54,63 +50,63 @@ const linksList = [
title: 'Docs',
caption: 'quasar.dev',
icon: 'school',
link: 'https://quasar.dev'
link: 'https://quasar.dev',
},
{
title: 'Github',
caption: 'github.com/quasarframework',
icon: 'code',
link: 'https://github.com/quasarframework'
link: 'https://github.com/quasarframework',
},
{
title: 'Discord Chat Channel',
caption: 'chat.quasar.dev',
icon: 'chat',
link: 'https://chat.quasar.dev'
link: 'https://chat.quasar.dev',
},
{
title: 'Forum',
caption: 'forum.quasar.dev',
icon: 'record_voice_over',
link: 'https://forum.quasar.dev'
link: 'https://forum.quasar.dev',
},
{
title: 'Twitter',
caption: '@quasarframework',
icon: 'rss_feed',
link: 'https://twitter.quasar.dev'
link: 'https://twitter.quasar.dev',
},
{
title: 'Facebook',
caption: '@QuasarFramework',
icon: 'public',
link: 'https://facebook.quasar.dev'
link: 'https://facebook.quasar.dev',
},
{
title: 'Quasar Awesome',
caption: 'Community Quasar projects',
icon: 'favorite',
link: 'https://awesome.quasar.dev'
}
link: 'https://awesome.quasar.dev',
},
];
export default defineComponent({
name: 'MainLayout',
components: {
EssentialLink
EssentialLink,
},
setup () {
const leftDrawerOpen = ref(false)
setup() {
const leftDrawerOpen = ref(false);
return {
essentialLinks: linksList,
leftDrawerOpen,
toggleLeftDrawer () {
leftDrawerOpen.value = !leftDrawerOpen.value
}
}
}
toggleLeftDrawer() {
leftDrawerOpen.value = !leftDrawerOpen.value;
},
};
},
});
</script>

0 comments on commit cbc3ef1

Please sign in to comment.