Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Styling fixes #13369

Merged
merged 2 commits into from
Dec 8, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 31 additions & 3 deletions ui/app/styles/core/charts.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
border: $light-border;
border-radius: $radius-large;
padding: $spacing-l $spacing-l $spacing-s $spacing-l;
height: 380px;
height: 380px; // TODO amend for specific chart heights
width: 100%;

display: grid;
Expand All @@ -20,11 +20,14 @@
grid-column-start: 1;
grid-column-end: span col4-end;
grid-row-start: 1;
box-shadow: inset 0 -1px 0 $vault-gray-200;
margin-bottom: $spacing-xl;

.chart-title {
font-size: $size-5;
font-weight: $font-weight-bold;
line-height: normal;
margin-bottom: $spacing-xs;
}
.chart-description {
font-size: $size-8;
Expand All @@ -34,19 +37,44 @@
}
}

.data-description {
.data-subTitle {
grid-column-start: 1;
grid-row-start: 2;
font-size: $size-5;
font-weight: $font-weight-bold;
margin-bottom: $spacing-l;

> p {
font-size: $size-8;
font-weight: $font-weight-normal;
}
}

.data-one {
grid-column-start: 1;
grid-row-start: 3;
font-size: $size-6;
font-weight: $font-weight-bold;
margin-bottom: $spacing-l;

> p {
font-size: $size-4;
font-weight: $font-weight-normal;
margin-top: $spacing-xs;
}
}

.data-two {
grid-column-start: 1;
grid-row-start: 4;
font-size: $size-6;
font-weight: $font-weight-bold;

> p {
font-size: $size-4;
font-weight: $font-weight-normal;
margin-top: $spacing-xs;
}
}

.chart-container {
Expand All @@ -55,7 +83,7 @@
grid-row-start: 2;
grid-row-end: span 3;

padding: $spacing-m 0;
padding: 0 0 0 80px;
}

.chart {
Expand Down
10 changes: 8 additions & 2 deletions ui/app/templates/components/clients/dashboard.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -137,8 +137,14 @@
{{#if this.showGraphs}}
{{!-- ARG TODO chart playground --}}
<Clients::TotalClientUsage
@title="Title"
@description="description"
@title="Vault usage"
@description="This data can be used to understand how many total clients are using Vault each month for the time period selected above."
@subTitle="Total monthly clients"
@subDescription="Each unique client is counted once per month. This can help with capacity planning."
@dataOne="Average total clients per month"
@dataOneData="100"
@dataTwo="Average new clients per month"
@dataTwoData="4"
/>
{{!-- ARG TODO this is the search select from the old graph that can be reused --}}
{{!-- <div class="column">
Expand Down
14 changes: 10 additions & 4 deletions ui/app/templates/components/clients/total-client-usage.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,22 @@
</div>
<div class="chart-container">
<svg
{{did-insert this.registerListner}}
{{did-insert this.registerListener}}
class="chart"
></svg>
</div>

<div class="data-description">Description</div>
<div class="data-subTitle">{{@subTitle}}
<p>{{@subDescription}}</p>
</div>

<div class="data-one">Data 1</div>
<div class="data-one">{{@dataOne}}
<p>{{@dataOneData}}</p>
</div>

<div class="data-two">Data 2</div>
<div class="data-two">{{@dataTwo}}
<p>{{@dataTwoData}}</p>
</div>

<div class="legend-container">
legend
Expand Down