add asset page and its components
This commit is contained in:
69
components/ClientSearch.vue
Normal file
69
components/ClientSearch.vue
Normal file
@ -0,0 +1,69 @@
|
|||||||
|
<template>
|
||||||
|
<section class="client-search">
|
||||||
|
<div class="label">Client</div>
|
||||||
|
<div class="input">
|
||||||
|
<input type="text" placeholder="..." v-model="inputValue" />
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: "ClientSearch",
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
inputValue: ""
|
||||||
|
};
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.client-search {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
padding: 0.625em 1.875em;
|
||||||
|
gap: 1.25em;
|
||||||
|
width: 30.125em;
|
||||||
|
height: 3.125em;
|
||||||
|
background: #2C2C2C;
|
||||||
|
box-shadow: 0.25em 0.25em 0.25em rgba(0, 0, 0, 0.25);
|
||||||
|
border-radius: 0.625em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.label {
|
||||||
|
width: 2.5625em;
|
||||||
|
height: 1.875em;
|
||||||
|
font-family: "Overpass";
|
||||||
|
font-style: normal;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 0.875em;
|
||||||
|
line-height: 1.875;
|
||||||
|
letter-spacing: 0.05em;
|
||||||
|
color: #FFFFFF;
|
||||||
|
}
|
||||||
|
|
||||||
|
.input {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 0.625em;
|
||||||
|
flex: 0;
|
||||||
|
height: 1.875em;
|
||||||
|
background: #212121;
|
||||||
|
box-shadow: inset 0.0625em 0.0625em 0.25em rgba(0, 0, 0, 0.25);
|
||||||
|
border-radius: 0.3125em;
|
||||||
|
min-width: 8rem;
|
||||||
|
overflow: hidden;
|
||||||
|
padding-right: 0.8rem;
|
||||||
|
padding-left: 0.8rem
|
||||||
|
}
|
||||||
|
|
||||||
|
.input input {
|
||||||
|
flex: 1;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
border: none;
|
||||||
|
background: transparent;
|
||||||
|
color: #FFFFFF;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
123
components/server/AssetTable.vue
Normal file
123
components/server/AssetTable.vue
Normal file
@ -0,0 +1,123 @@
|
|||||||
|
<template>
|
||||||
|
<div class="data">
|
||||||
|
<div class="label">Last viewed:</div>
|
||||||
|
<table class="data-table" id="client-table">
|
||||||
|
<tr class="table-row" id="table-head">
|
||||||
|
<th class="Client">Client</th>
|
||||||
|
<th class="Name">Name</th>
|
||||||
|
<th class="Type">Type</th>
|
||||||
|
<th class="State">State</th>
|
||||||
|
<th class="User">User</th>
|
||||||
|
</tr>
|
||||||
|
<tr class="table-row" id="row-1">
|
||||||
|
<td class="Client">...</td>
|
||||||
|
<td class="Name">...</td>
|
||||||
|
<td class="Type">...</td>
|
||||||
|
<td class="State">...</td>
|
||||||
|
<td class="User">...</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<script>
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: "AssetTable",
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.data {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: flex-start;
|
||||||
|
justify-content: center;
|
||||||
|
align-self: stretch;
|
||||||
|
width: 100%;
|
||||||
|
padding: 1.25rem 1.875rem;
|
||||||
|
gap: 1.25rem;
|
||||||
|
border-radius: 0.625rem;
|
||||||
|
box-shadow: 0.25rem 0.25rem 0.25rem 0rem rgba(0, 0, 0, 0.25);
|
||||||
|
background-color: #2c2c2c;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-table {
|
||||||
|
width: 100%;
|
||||||
|
padding: 0 0.625rem;
|
||||||
|
table-layout: fixed;
|
||||||
|
border-collapse: collapse;
|
||||||
|
}
|
||||||
|
|
||||||
|
.table-row {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
align-items: center;
|
||||||
|
height: 3.125rem;
|
||||||
|
padding: 0.625rem;
|
||||||
|
gap: 0.625rem;
|
||||||
|
border-top: 0.0625rem solid #000000;
|
||||||
|
}
|
||||||
|
|
||||||
|
#table-head {
|
||||||
|
border-top: none;
|
||||||
|
border-bottom: 0.0625rem solid #000000;
|
||||||
|
}
|
||||||
|
|
||||||
|
th,
|
||||||
|
td {
|
||||||
|
height: 1.875rem;
|
||||||
|
text-align: left;
|
||||||
|
padding: 0;
|
||||||
|
color: #ffffff;
|
||||||
|
letter-spacing: 5%;
|
||||||
|
font: 400 0.875rem/1.875rem Overpass, sans-serif;
|
||||||
|
}
|
||||||
|
|
||||||
|
th {
|
||||||
|
font: 700 0.875rem/1.875rem Overpass, sans-serif;
|
||||||
|
}
|
||||||
|
|
||||||
|
.Client {
|
||||||
|
width: 33.3%;
|
||||||
|
border-right: 0.0625rem solid #000000;
|
||||||
|
}
|
||||||
|
|
||||||
|
.Name {
|
||||||
|
width: 33.3%;
|
||||||
|
border-right: 0.0625rem solid #000000;
|
||||||
|
}
|
||||||
|
|
||||||
|
.Type {
|
||||||
|
width: 12.7%;
|
||||||
|
border-right: 0.0625rem solid #000000;
|
||||||
|
}
|
||||||
|
|
||||||
|
.State {
|
||||||
|
width: 12.7%;
|
||||||
|
border-right: 0.0625rem solid #000000;
|
||||||
|
}
|
||||||
|
|
||||||
|
.User {
|
||||||
|
width: 8%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.label {
|
||||||
|
width: 6.0625em;
|
||||||
|
height: 1.875em;
|
||||||
|
font-family: 'Overpass';
|
||||||
|
font-style: normal;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 1em;
|
||||||
|
line-height: 1.875em;
|
||||||
|
letter-spacing: 0.05em;
|
||||||
|
color: #FFFFFF;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@ -30,7 +30,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<span v-if="isExpanded" :class="['label', darkMode ? 'label-darkmode' : 'label-lightmode']">Checklists</span>
|
<span v-if="isExpanded" :class="['label', darkMode ? 'label-darkmode' : 'label-lightmode']">Checklists</span>
|
||||||
</router-link>
|
</router-link>
|
||||||
<router-link to="/home" class="button" :class="[darkMode ? 'button-darkmode' : 'button-lightmode']" id="assets-button">
|
<router-link to="/assets" class="button" :class="[darkMode ? 'button-darkmode' : 'button-lightmode']" id="assets-button">
|
||||||
<div class="icon" id="assets-icon">
|
<div class="icon" id="assets-icon">
|
||||||
<img :class="[darkMode ? 'img-darkmode' : 'img-lightmode']" loading="lazy"
|
<img :class="[darkMode ? 'img-darkmode' : 'img-lightmode']" loading="lazy"
|
||||||
src="../icons/navbar-icons/Assets-Icon.svg" />
|
src="../icons/navbar-icons/Assets-Icon.svg" />
|
||||||
|
|||||||
78
pages/assets.vue
Normal file
78
pages/assets.vue
Normal file
@ -0,0 +1,78 @@
|
|||||||
|
<template>
|
||||||
|
<section id="content">
|
||||||
|
<div id="content-header">
|
||||||
|
<h1 id="page-name">Assets</h1>
|
||||||
|
</div>
|
||||||
|
<div id="content-body">
|
||||||
|
<ClientSearch />
|
||||||
|
<AssetTable />
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
|
||||||
|
<script setup>
|
||||||
|
definePageMeta({
|
||||||
|
layout: 'default'
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import ClientSearch from "../components/ClientSearch.vue";
|
||||||
|
import AssetTable from "../components/server/AssetTable.vue";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: "AssetPage",
|
||||||
|
components: {
|
||||||
|
ClientSearch,
|
||||||
|
AssetTable,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
|
||||||
|
* {
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#content {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
float: left;
|
||||||
|
justify-content: stretch;
|
||||||
|
align-items: stretch;
|
||||||
|
width: 100%;
|
||||||
|
flex-grow: 1;
|
||||||
|
gap: 0.625rem;
|
||||||
|
padding: 0 1.25rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
#content-header {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
width: 100%;
|
||||||
|
height: 3.125rem;
|
||||||
|
}
|
||||||
|
#page-name {
|
||||||
|
color: #fff;
|
||||||
|
letter-spacing: 5%;
|
||||||
|
font: 400 1.5rem/125% Overpass, -apple-system, Roboto, Helvetica,
|
||||||
|
sans-serif;
|
||||||
|
}
|
||||||
|
|
||||||
|
#content-body {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
width: 100%;
|
||||||
|
gap: 1.25rem;
|
||||||
|
margin-bottom: 0.625rem;
|
||||||
|
border-radius: 0.625rem;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@ -2,6 +2,7 @@ import { createRouter, createWebHistory } from 'vue-router';
|
|||||||
import HomePage from '../pages/home.vue';
|
import HomePage from '../pages/home.vue';
|
||||||
import ClientsPage from '../pages/clients.vue';
|
import ClientsPage from '../pages/clients.vue';
|
||||||
import LoginPage from '../pages/login.vue';
|
import LoginPage from '../pages/login.vue';
|
||||||
|
import AssetPage from '../pages/assets.vue'
|
||||||
|
|
||||||
|
|
||||||
const router = createRouter({
|
const router = createRouter({
|
||||||
@ -15,6 +16,10 @@ const router = createRouter({
|
|||||||
path: '/home',
|
path: '/home',
|
||||||
component: HomePage
|
component: HomePage
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
path: '/assets',
|
||||||
|
component: AssetPage
|
||||||
|
},
|
||||||
{
|
{
|
||||||
path: '/clients',
|
path: '/clients',
|
||||||
component: ClientsPage
|
component: ClientsPage
|
||||||
|
|||||||
Reference in New Issue
Block a user