Skip to content

Commit

Permalink
Merge #70948
Browse files Browse the repository at this point in the history
70948: ui: update styles for stmt, txn and sessions pages r=maryliag a=maryliag

Updates styling for Statement, Statement Details,
Transactions, Transaction Details and Sessions.

Partially addresses #70783

Fixed:
- Icon alignment for clear stats
- Filter input colors (text and border)
- Color of link on Transaction page
- Tighten spaces for details titles on Statements, Transactions, Session and Jobs details pages
- Update color and font size of session duration
- Update color of SQL black boxes 
- Update color of Plan black boxes
- Update title size of tables inside Statement Details Execution Stats
- Update color of labels on Session details
- Unavailable message on Transactions Details

Release note (ui change): Update color, fonts and spaces on
Statements, Statements Details, Transaction, Transactions Details
and Session pages

Co-authored-by: Marylia Gutierrez <[email protected]>
  • Loading branch information
craig[bot] and maryliag committed Oct 1, 2021
2 parents 42730df + ad7381c commit 3bf6227
Show file tree
Hide file tree
Showing 20 changed files with 130 additions and 49 deletions.
5 changes: 5 additions & 0 deletions pkg/ui/workspaces/cluster-ui/src/button/button.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@
.crl-button__content {
display: flex;
flex: 1;
font-weight: normal;
}


Expand All @@ -158,3 +159,7 @@
order: 1;
margin-left: $spacing-base;
}

.small-margin {
margin-bottom: 10px;
}
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,10 @@ const customStyles = {
border: "none",
height: "fit-content",
}),
dropdownIndicator: (provided: any) => ({
...provided,
color: "#C0C6D9",
}),
option: (provided: any, state: any) => ({
...provided,
backgroundColor: state.isSelected ? "#DEEBFF" : provided.backgroundColor,
Expand All @@ -66,12 +70,17 @@ const customStyles = {
control: (provided: any) => ({
...provided,
width: "100%",
borderColor: "#C0C6D9",
}),
multiValue: (provided: any) => ({
...provided,
backgroundColor: "#E7ECF3",
borderRadius: "3px",
}),
placeholder: (provided: any) => ({
...provided,
color: "#475872",
}),
};

/**
Expand Down
7 changes: 6 additions & 1 deletion pkg/ui/workspaces/cluster-ui/src/queryFilter/filter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -258,10 +258,15 @@ export class Filter extends React.Component<QueryFilter, FilterState> {
control: (provided: any) => ({
...provided,
width: "100%",
borderColor: "#C0C6D9",
}),
dropdownIndicator: (provided: any) => ({
...provided,
color: "#C0C6D9",
}),
singleValue: (provided: any) => ({
...provided,
color: "hsl(0, 0%, 50%)",
color: "#475872",
}),
};
const customStylesSmall = { ...customStyles };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ export class SessionDetails extends React.Component<SessionDetailsProps> {
size="small"
icon={<ArrowLeft fontSize={"10px"} />}
iconPosition="left"
className="small-margin"
>
Sessions
</Button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,8 @@

& a {
all: initial;
font-family: $font-family--semi-bold;
font-weight: $font-weight--bold;
line-height: 1.83;
color: $colors--link;
font-family: $font-family--base;
font-size: $font-size--medium;
text-decoration: none;
cursor: pointer;
@include line-clamp(2);
Expand All @@ -45,6 +43,11 @@
}
}

.code {
font-family: $font-family--monospace;
font-size: $font-size--small;
}

.session-action--dropdown {
align-items: flex-end;
}
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ export function makeSessionsColumns(
{
name: "statement",
title: SessionTableTitle.statement,
className: cx("cl-table__col-session"),
className: cx("cl-table__col-session", "code"),
cell: session => {
if (!(session.session.active_queries?.length > 0)) {
return "N/A";
Expand Down
5 changes: 5 additions & 0 deletions pkg/ui/workspaces/cluster-ui/src/sql/sqlhighlight.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,11 @@
white-space: pre-line;
word-wrap: break-word;

span {
font-family: SFMono-Semibold;
color: $colors--neutral-2;
}

:global(.hljs-label) {
padding-left: 8px;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,11 @@
overflow: hidden;
padding: 24px 32px;

span {
font-family: RobotoMono-Regular;
color: $colors--neutral-2;
}

.plan-view-container-scroll {
max-height: 400px;
overflow-y: scroll;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -172,3 +172,7 @@ h3.base-heading {
.tooltip-info {
border-bottom: 1px dashed $colors--neutral-5;
}

.no-margin-bottom {
margin-bottom: 0px;
}
Original file line number Diff line number Diff line change
Expand Up @@ -401,10 +401,11 @@ export class StatementDetails extends React.Component<
size="small"
icon={<ArrowLeft fontSize={"10px"} />}
iconPosition="left"
className="small-margin"
>
Statements
</Button>
<h3 className={cx("base-heading", "page--header__title")}>
<h3 className={cx("base-heading", "no-margin-bottom")}>
Statement Details
</h3>
</div>
Expand Down Expand Up @@ -793,7 +794,7 @@ export class StatementDetails extends React.Component<
className={cx("fit-content-width")}
>
<SummaryCard>
<h2
<h3
className={classNames(
cx("base-heading"),
summaryCardStylesCx("summary--card__title"),
Expand All @@ -811,7 +812,7 @@ export class StatementDetails extends React.Component<
</div>
</Tooltip>
</div>
</h2>
</h3>
<NumericStatTable
title="Phase"
measure="Latency"
Expand All @@ -836,14 +837,14 @@ export class StatementDetails extends React.Component<
/>
</SummaryCard>
<SummaryCard>
<h2
<h3
className={classNames(
cx("base-heading"),
summaryCardStylesCx("summary--card__title"),
)}
>
Other Execution Statistics
</h2>
</h3>
<NumericStatTable
title="Stat"
measure="Quantity"
Expand Down Expand Up @@ -892,7 +893,7 @@ export class StatementDetails extends React.Component<
</SummaryCard>
{!isTenant && (
<SummaryCard className={cx("fit-content-width")}>
<h2
<h3
className={classNames(
cx("base-heading"),
summaryCardStylesCx("summary--card__title"),
Expand All @@ -910,7 +911,7 @@ export class StatementDetails extends React.Component<
</div>
</Tooltip>
</div>
</h2>
</h3>
<StatementsSortedTable
className={cx("statements-table")}
data={statsByNode}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,10 @@ h3.base-heading {
padding-bottom: 12px;
}

.no-margin-bottom {
margin-bottom: 0px;
}

.root {
flex-grow: 0;
width: 100%;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,16 +51,17 @@
&--label {
font-family: $font-family--base;
font-size: 14px;
font-weight: $font-weight--bold;
line-height: 1.57;
letter-spacing: 0.1px;
color: $secondary-text-color;
color: $colors--neutral-6;
margin-right: 5px;
margin-bottom: 0;
}
&--value {
font-family: $font-family--base;
font-size: 14px;
font-weight: 600;
font-weight: $font-weight--bold;
line-height: 1.71;
letter-spacing: 0.1px;
color: $popover-color;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@

.action {
color: $colors--link;
line-height: 24px;
&:hover {
color: $colors--link;
text-decoration: underline;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,8 @@
}
.summary-card {
margin-bottom: 0;
}
}

.tooltip-info {
border-bottom: 1px dashed $colors--neutral-5;
}
Loading

0 comments on commit 3bf6227

Please sign in to comment.