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

Sidebranch: Performance Secondary Dashboard #8956

Merged
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
17 changes: 14 additions & 3 deletions ui/app/styles/components/replication-dashboard.scss
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,20 @@

.selectable-card-container {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
grid-template-rows: 1fr;
grid-gap: 2rem;

&.primary {
Monkeychip marked this conversation as resolved.
Show resolved Hide resolved
margin: 2rem 0 2rem 0;
grid-template-columns: 1fr 2fr;

@include until($mobile) {
grid-template-columns: 1fr;
}
}

&.secondary {
grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
grid-gap: 2rem;
}

.card-container {
display: grid;
Expand Down
9 changes: 0 additions & 9 deletions ui/app/styles/components/replication-summary.scss
Original file line number Diff line number Diff line change
@@ -1,13 +1,4 @@
.replication {
.selectable-card-container {
margin: 2rem 0 2rem 0;
grid-template-columns: 1fr 2fr;

@include until($mobile) {
grid-template-columns: 1fr;
}
}

.toolbar {
border-top: 0px;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
@message="This can cause a delay depending on the size of the data store. You can use Vault during this time."
data-test-isReindexing/>
{{/if}}

<div class="selectable-card-container has-top-margin-xl">
<div class="selectable-card-container {{if isSecondary 'secondary' 'primary'}} has-top-margin-xl">
{{yield (hash
card=(component componentToRender replicationDetails=replicationDetails)
)}}
Expand Down
1 change: 1 addition & 0 deletions ui/lib/core/app/helpers/format-number.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export { default, formatNumber } from 'core/helpers/format-number';
Monkeychip marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,10 @@
<p>{{cluster.replicationModeStatus.cluster_id}}</p>
<div class="replication">
<ReplicationPage @model={{cluster}} as |Page|>
<Page.dashboard @data={{cluster}} @componentToRender='replication-primary-card' as |Dashboard|>
<Page.dashboard
@data={{cluster}}
@componentToRender={{if (eq replicationAttrs.mode 'secondary') 'replication-secondary-card' 'replication-primary-card' }}
as |Dashboard|>
<Dashboard.card
@title='State'
@description='Updated every ten seconds.'
Expand Down