Skip to content

Commit 2021f64

Browse files
hawkgskirjs
authored andcommitted
refactor(devtools): reduce material form field density globally (angular#60633)
Make the form field density consistent across the app. PR Close angular#60633
1 parent 654e6da commit 2021f64

File tree

4 files changed

+20
-26
lines changed

4 files changed

+20
-26
lines changed

devtools/projects/ng-devtools/src/lib/devtools-tabs/injector-tree/injector-providers/BUILD.bazel

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,6 @@ package(default_visibility = ["//visibility:public"])
66
sass_binary(
77
name = "injector_providers_component_styles",
88
src = "injector-providers.component.scss",
9-
include_paths = [
10-
"external/npm/node_modules",
11-
],
12-
deps = [
13-
"//devtools/projects/ng-devtools/src/styles:material_sass_deps",
14-
],
159
)
1610

1711
ng_module(

devtools/projects/ng-devtools/src/lib/devtools-tabs/injector-tree/injector-providers/injector-providers.component.scss

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
@use '@angular/material' as mat;
2-
31
h2 {
42
font-size: 0.875rem;
53
}
@@ -18,29 +16,13 @@ h2 {
1816
gap: 0.5rem;
1917

2018
mat-form-field {
21-
@include mat.form-field-density(-5);
22-
@include mat.form-field-overrides(
23-
(
24-
container-text-size: 0.8rem,
25-
outlined-label-text-size: 0.8rem,
26-
)
27-
);
28-
2919
&.token-search {
3020
flex: 1;
3121
}
3222

3323
&.type-filter {
3424
width: 10rem;
3525
}
36-
37-
mat-select {
38-
@include mat.select-overrides(
39-
(
40-
trigger-text-size: 0.8rem,
41-
)
42-
);
43-
}
4426
}
4527
}
4628

devtools/projects/ng-devtools/src/lib/devtools-tabs/profiler/timeline/timeline-controls.component.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<div class="controls">
22
<div class="visual-controls">
3-
<mat-form-field>
3+
<mat-form-field appearance="outline">
44
<mat-label>Filter</mat-label>
55
<input
66
matInput
@@ -9,7 +9,7 @@
99
placeholder="duration: >30 source: click"
1010
/>
1111
</mat-form-field>
12-
<mat-form-field [class.hidden]="!record()">
12+
<mat-form-field [class.hidden]="!record()" appearance="outline">
1313
<mat-select
1414
[value]="visualizationMode()"
1515
(selectionChange)="visualizationMode.set($event.value)"

devtools/projects/ng-devtools/src/styles/_global.scss

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,3 +80,21 @@ ng-devtools {
8080
.mat-mdc-menu-content {
8181
padding: 0 !important;
8282
}
83+
84+
mat-form-field {
85+
@include mat.form-field-density(-5);
86+
@include mat.form-field-overrides(
87+
(
88+
container-text-size: 0.8rem,
89+
outlined-label-text-size: 0.8rem,
90+
)
91+
);
92+
93+
mat-select {
94+
@include mat.select-overrides(
95+
(
96+
trigger-text-size: 0.8rem,
97+
)
98+
);
99+
}
100+
}

0 commit comments

Comments
 (0)