Skip to content

prefix material 2 palette colors with a comment for transforms #6995

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ limitations under the License.
padding: 2px 6px;
text-align: right;
width: 200px;
$grey-600: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 600);
$grey-600: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 600);
@include tb-dark-theme {
box-shadow: 1px 3px $grey-600;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ mat-button-toggle-group.filter-view {

&.checked {
@include tb-theme-background-prop(background-color, selected-button);
border-color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 300);
border-color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 300);
}

::ng-deep .mat-button-wrapper {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ mat-icon {

.new-card-pinned {
animation: pinned-view-fade-out 3s linear;
background: /*m2*/ mat.get-color-from-palette(mat.$red-palette, 500);
background: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$red-palette, 500);
border-radius: 5px;
color: #fff;
display: inline-block;
Expand Down
4 changes: 2 additions & 2 deletions tensorboard/webapp/metrics/views/metrics_container.scss
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ limitations under the License.

.notice {
background-color: rgba(
/*m2*/ mat.get-color-from-palette(mat.$yellow-palette, 200),
/*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$yellow-palette, 200),
0.85
);
$yellow-500: /*m2*/ mat.get-color-from-palette(mat.$yellow-palette, 500);
$yellow-500: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$yellow-palette, 500);
border-bottom: 1px solid $yellow-500;
color: map-get($tb-foreground, text);
display: block;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ $_accent: map-get(/*m2*/ mat.get-color-config($tb-theme), accent);
}

.highlighted {
background-color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 200);
background-color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 200);
}

.highlight-bottom {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ limitations under the License.

.red-dot {
$_dim: 10px;
background-color: /*m2*/ mat.get-color-from-palette(mat.$red-palette, 700);
background-color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$red-palette, 700);
border-radius: $_dim * 0.5;
height: $_dim;
position: absolute;
Expand Down Expand Up @@ -52,7 +52,7 @@ limitations under the License.
}

.category-icon {
color: /*m2*/ mat.get-color-from-palette(mat.$blue-palette, 700);
color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$blue-palette, 700);
height: 15px;
margin-right: 6px;
vertical-align: middle;
Expand Down
12 changes: 6 additions & 6 deletions tensorboard/webapp/theme/_tb_theme.template.scss
Original file line number Diff line number Diff line change
Expand Up @@ -54,12 +54,12 @@ $tb-theme: /*m2*/ mat.define-light-theme(
$tb-foreground: map_merge(
mat.$light-theme-foreground-palette,
(
text: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 900),
secondary-text: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 700),
disabled-text: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 600),
text: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 900),
secondary-text: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 700),
disabled-text: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 600),
// TB specific variable.
border: #ebebeb,
link: /*m2*/ mat.get-color-from-palette(mat.$blue-palette, 700),
link: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$blue-palette, 700),
link-visited: /*m2*/ mat.get-color-from-palette(mat.$purple-palette, 700),
)
);
Expand Down Expand Up @@ -109,8 +109,8 @@ $tb-dark-foreground: map_merge(
map-get(/*m2*/ mat.get-color-config($tb-dark-theme), foreground),
(
border: #555,
disabled-text: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 700),
link: /*m2*/ mat.get-color-from-palette(mat.$blue-palette, 400),
disabled-text: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 700),
link: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$blue-palette, 400),
link-visited: /*m2*/ mat.get-color-from-palette(mat.$purple-palette, 300),
)
);
Expand Down
2 changes: 1 addition & 1 deletion tensorboard/webapp/theme/_variable.scss
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ limitations under the License.

$tb-primary: /*m2*/ mat.define-palette($tf-orange, 700, 400, 800);
$tb-accent: /*m2*/ mat.define-palette($tf-orange);
$tb-warn: /*m2*/ mat.define-palette(mat.$red-palette);
$tb-warn: /*m2*/ mat.define-palette(/*m2$*/ mat.$red-palette);

$tb-dark-primary: /*m2*/ mat.define-palette($tf-orange, 800, 600, 900);
$tb-dark-accent: $tb-dark-primary;
16 changes: 8 additions & 8 deletions tensorboard/webapp/widgets/card_fob/card_fob_component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ limitations under the License.

.fob {
display: inline-flex;
background-color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 300);
background-color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 300);
border-radius: 25px;
padding: 2px 2px 2px 4px;
font-size: 11px;
Expand Down Expand Up @@ -50,7 +50,7 @@ limitations under the License.
&.prospective {
align-items: center;
box-sizing: border-box;
border: 1px dashed /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 500);
border: 1px dashed /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 500);
font-weight: bold;
height: 17px;
}
Expand All @@ -61,7 +61,7 @@ span {
display: inline-block;

@include tb-dark-theme {
color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 700);
color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 700);
}
}

Expand All @@ -84,17 +84,17 @@ button {
}

@include tb-dark-theme {
color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 700);
color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 700);
}
}

button:hover {
background-color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 500);
color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 200);
background-color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 500);
color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 200);
cursor: pointer;

@include tb-dark-theme {
background-color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 700);
color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 300);
background-color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 700);
color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 300);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ limitations under the License.
}

&.high-contrast .container {
border-color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 400);
border-color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 400);

&:hover {
border-color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 600);
border-color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 600);
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,13 +87,13 @@ limitations under the License.

&.selected {
background-color: /*m2*/ mat.get-color-from-palette(
mat.$gray-palette,
mat.$grey-palette,
200
);

@include tb-dark-theme {
background-color: /*m2*/ mat.get-color-from-palette(
mat.$gray-palette,
mat.$grey-palette,
400
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ $_icon_padding: 4px;
}

.highlight {
background-color: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 200);
background-color: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 200);
}

.highlight-border-right {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ text {
}
}

$border: /*m2*/ mat.get-color-from-palette(mat.$gray-palette, 500);
$border: /*m2*/ mat.get-color-from-palette(/*m2$*/ mat.$grey-palette, 500);
$_border-style: 1px solid $border;

.x-axis .major-label {
Expand Down
Loading