Skip to content

Commit 3200a10

Browse files
committed
Merge remote-tracking branch 'origin/main' into add-start-stop-audit/kira-pilot
2 parents 5946e8b + 9070fcd commit 3200a10

File tree

11 files changed

+69
-106
lines changed

11 files changed

+69
-106
lines changed

cli/cliui/provisionerjob.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,6 @@ func ProvisionerJob(ctx context.Context, writer io.Writer, opts ProvisionerJobOp
103103
}
104104
updateStage("Running", *job.StartedAt)
105105
}
106-
updateJob()
107106

108107
if opts.Cancel != nil {
109108
// Handles ctrl+c to cancel a job.
@@ -131,6 +130,7 @@ func ProvisionerJob(ctx context.Context, writer io.Writer, opts ProvisionerJobOp
131130

132131
// The initial stage needs to print after the signal handler has been registered.
133132
printStage()
133+
updateJob()
134134

135135
logs, closer, err := opts.Logs()
136136
if err != nil {

go.mod

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -124,19 +124,19 @@ require (
124124
github.com/quasilyte/go-ruleguard/dsl v0.3.21
125125
github.com/robfig/cron/v3 v3.0.1
126126
github.com/spf13/afero v1.9.2
127-
github.com/spf13/cobra v1.5.0
127+
github.com/spf13/cobra v1.6.1
128128
github.com/spf13/pflag v1.0.5
129129
github.com/stretchr/testify v1.8.0
130130
github.com/tabbed/pqtype v0.1.1
131131
github.com/u-root/u-root v0.10.0
132132
github.com/unrolled/secure v1.13.0
133133
go.mozilla.org/pkcs7 v0.0.0-20200128120323-432b2356ecb1
134-
go.opentelemetry.io/otel v1.11.0
135-
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.11.0
136-
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.10.0
134+
go.opentelemetry.io/otel v1.11.1
135+
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.11.1
136+
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.11.1
137137
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.10.0
138-
go.opentelemetry.io/otel/sdk v1.11.0
139-
go.opentelemetry.io/otel/trace v1.11.0
138+
go.opentelemetry.io/otel/sdk v1.11.1
139+
go.opentelemetry.io/otel/trace v1.11.1
140140
go.uber.org/atomic v1.10.0
141141
go.uber.org/goleak v1.2.0
142142
golang.org/x/crypto v0.0.0-20220525230936-793ad666bf5e
@@ -165,12 +165,12 @@ require (
165165
require github.com/jmoiron/sqlx v1.3.5
166166

167167
require (
168+
github.com/adrg/xdg v0.4.0
168169
github.com/cakturk/go-netstat v0.0.0-20200220111822-e5b49efee7a5
169170
github.com/spf13/viper v1.13.0
170171
)
171172

172173
require (
173-
github.com/adrg/xdg v0.4.0 // indirect
174174
github.com/fsnotify/fsnotify v1.5.4 // indirect
175175
github.com/magiconair/properties v1.8.6 // indirect
176176
github.com/pelletier/go-toml v1.9.5 // indirect
@@ -235,7 +235,7 @@ require (
235235
github.com/hashicorp/hcl v1.0.0 // indirect
236236
github.com/hdevalence/ed25519consensus v0.0.0-20220222234857-c00d1f31bab3 // indirect
237237
github.com/imdario/mergo v0.3.12 // indirect
238-
github.com/inconshreveable/mousetrap v1.0.0 // indirect
238+
github.com/inconshreveable/mousetrap v1.0.1 // indirect
239239
github.com/insomniacslk/dhcp v0.0.0-20211209223715-7d93572ebe8e // indirect
240240
github.com/joeshaw/multierror v0.0.0-20140124173710-69b34d4ec901 // indirect
241241
github.com/josharian/native v1.0.0 // indirect
@@ -298,7 +298,7 @@ require (
298298
github.com/zclconf/go-cty v1.10.0 // indirect
299299
github.com/zeebo/errs v1.3.0 // indirect
300300
go.opencensus.io v0.23.0 // indirect
301-
go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.11.0 // indirect
301+
go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.11.1 // indirect
302302
go.opentelemetry.io/otel/metric v0.31.0 // indirect
303303
go.opentelemetry.io/proto/otlp v0.19.0 // indirect
304304
go4.org/mem v0.0.0-20210711025021-927187094b94 // indirect
@@ -309,7 +309,7 @@ require (
309309
golang.zx2c4.com/wireguard/windows v0.5.3 // indirect
310310
google.golang.org/appengine v1.6.7 // indirect
311311
google.golang.org/genproto v0.0.0-20220915135415-7fd63a7952de // indirect
312-
google.golang.org/grpc v1.49.0 // indirect
312+
google.golang.org/grpc v1.50.1 // indirect
313313
gopkg.in/square/go-jose.v2 v2.6.0
314314
gopkg.in/yaml.v2 v2.4.0 // indirect
315315
howett.net/plist v1.0.0 // indirect

go.sum

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1038,8 +1038,9 @@ github.com/imdario/mergo v0.3.12 h1:b6R2BslTbIEToALKP7LxUvijTsNI9TAe80pLWN2g/HU=
10381038
github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA=
10391039
github.com/imulab/go-scim/pkg/v2 v2.2.0 h1:PQ1jvNJKagyCwryVjwb3fvLEjztXtpxZh1LHT4BFrzI=
10401040
github.com/imulab/go-scim/pkg/v2 v2.2.0/go.mod h1:TvNTXjm2x/rJ3BBCQIKZVErA2AODyylGsLWR/spwL8A=
1041-
github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM=
10421041
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
1042+
github.com/inconshreveable/mousetrap v1.0.1 h1:U3uMjPSQEBMNp1lFxmllqCPM6P5u/Xq7Pgzkat/bFNc=
1043+
github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw=
10431044
github.com/insomniacslk/dhcp v0.0.0-20211209223715-7d93572ebe8e h1:IQpunlq7T+NiJJMO7ODYV2YWBiv/KnObR3gofX0mWOo=
10441045
github.com/insomniacslk/dhcp v0.0.0-20211209223715-7d93572ebe8e/go.mod h1:h+MxyHxRg9NH3terB1nfRIUaQEcI0XOVkdR9LNBlp8E=
10451046
github.com/intel/goresctrl v0.2.0/go.mod h1:+CZdzouYFn5EsxgqAQTEzMfwKwuc0fVdMrT9FCCAVRQ=
@@ -1669,8 +1670,8 @@ github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tL
16691670
github.com/spf13/cobra v1.0.0/go.mod h1:/6GTrnGXV9HjY+aR4k0oJ5tcvakLuG6EuKReYlHNrgE=
16701671
github.com/spf13/cobra v1.1.3/go.mod h1:pGADOWyqRD/YMrPZigI/zbliZ2wVD/23d+is3pSWzOo=
16711672
github.com/spf13/cobra v1.2.1/go.mod h1:ExllRjgxM/piMAM+3tAZvg8fsklGAf3tPfi+i8t68Nk=
1672-
github.com/spf13/cobra v1.5.0 h1:X+jTBEBqF0bHN+9cSMgmfuvv2VHJ9ezmFNf9Y/XstYU=
1673-
github.com/spf13/cobra v1.5.0/go.mod h1:dWXEIy2H428czQCjInthrTRUg7yKbok+2Qi/yBIJoUM=
1673+
github.com/spf13/cobra v1.6.1 h1:o94oiPyS4KD1mPy2fmcYYHHfCxLqYjJOhGsCHFZtEzA=
1674+
github.com/spf13/cobra v1.6.1/go.mod h1:IOw/AERYS7UzyrGinqmz6HLUo219MORXGxhbaJUqzrY=
16741675
github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
16751676
github.com/spf13/jwalterweatherman v1.1.0 h1:ue6voC5bR5F8YxI5S67j9i582FU4Qvo2bmqnqMYADFk=
16761677
github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo=
@@ -1869,18 +1870,18 @@ go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.2
18691870
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.20.0/go.mod h1:2AboqHi0CiIZU0qwhtUfCYD1GeUzvvIXWNkhDt7ZMG4=
18701871
go.opentelemetry.io/otel v0.20.0/go.mod h1:Y3ugLH2oa81t5QO+Lty+zXf8zC9L26ax4Nzoxm/dooo=
18711872
go.opentelemetry.io/otel v1.3.0/go.mod h1:PWIKzi6JCp7sM0k9yZ43VX+T345uNbAkDKwHVjb2PTs=
1872-
go.opentelemetry.io/otel v1.11.0 h1:kfToEGMDq6TrVrJ9Vht84Y8y9enykSZzDDZglV0kIEk=
1873-
go.opentelemetry.io/otel v1.11.0/go.mod h1:H2KtuEphyMvlhZ+F7tg9GRhAOe60moNx61Ex+WmiKkk=
1873+
go.opentelemetry.io/otel v1.11.1 h1:4WLLAmcfkmDk2ukNXJyq3/kiz/3UzCaYq6PskJsaou4=
1874+
go.opentelemetry.io/otel v1.11.1/go.mod h1:1nNhXBbWSD0nsL38H6btgnFN2k4i0sNLHNNMZMSbUGE=
18741875
go.opentelemetry.io/otel/exporters/otlp v0.20.0/go.mod h1:YIieizyaN77rtLJra0buKiNBOm9XQfkPEKBeuhoMwAM=
18751876
go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.3.0/go.mod h1:VpP4/RMn8bv8gNo9uK7/IMY4mtWLELsS+JIP0inH0h4=
1876-
go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.11.0 h1:0dly5et1i/6Th3WHn0M6kYiJfFNzhhxanrJ0bOfnjEo=
1877-
go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.11.0/go.mod h1:+Lq4/WkdCkjbGcBMVHHg2apTbv8oMBf29QCnyCCJjNQ=
1877+
go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.11.1 h1:X2GndnMCsUPh6CiY2a+frAbNsXaPLbB0soHRYhAZ5Ig=
1878+
go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.11.1/go.mod h1:i8vjiSzbiUC7wOQplijSXMYUpNM93DtlS5CbUT+C6oQ=
18781879
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.3.0/go.mod h1:hO1KLR7jcKaDDKDkvI9dP/FIhpmna5lkqPUQdEjFAM8=
1879-
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.11.0 h1:eyJ6njZmH16h9dOKCi7lMswAnGsSOwgTqWzfxqcuNr8=
1880-
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.11.0/go.mod h1:FnDp7XemjN3oZ3xGunnfOUTVwd2XcvLbtRAuOSU3oc8=
1880+
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.11.1 h1:MEQNafcNCB0uQIti/oHgU7CZpUMYQ7qigBwMVKycHvc=
1881+
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.11.1/go.mod h1:19O5I2U5iys38SsmT2uDJja/300woyzE1KPIQxEUBUc=
18811882
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.3.0/go.mod h1:keUU7UfnwWTWpJ+FWnyqmogPa82nuU5VUANFq49hlMY=
1882-
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.10.0 h1:KtiUEhQmj/Pa874bVYKGNVdq8NPKiacPbaRRtgXi+t4=
1883-
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.10.0/go.mod h1:OfUCyyIiDvNXHWpcWgbF+MWvqPZiNa3YDEnivcnYsV0=
1883+
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.11.1 h1:LYyG/f1W/jzAix16jbksJfMQFpOH/Ma6T639pVPMgfI=
1884+
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.11.1/go.mod h1:QrRRQiY3kzAoYPNLP0W/Ikg0gR6V3LMc+ODSxr7yyvg=
18841885
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.3.0/go.mod h1:QNX1aly8ehqqX1LEa6YniTU7VY9I6R3X/oPxhGdTceE=
18851886
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.10.0 h1:S8DedULB3gp93Rh+9Z+7NTEv+6Id/KYS7LDyipZ9iCE=
18861887
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.10.0/go.mod h1:5WV40MLWwvWlGP7Xm8g3pMcg0pKOUY609qxJn8y7LmM=
@@ -1892,15 +1893,15 @@ go.opentelemetry.io/otel/metric v0.31.0/go.mod h1:ohmwj9KTSIeBnDBm/ZwH2PSZxZzoOa
18921893
go.opentelemetry.io/otel/oteltest v0.20.0/go.mod h1:L7bgKf9ZB7qCwT9Up7i9/pn0PWIa9FqQ2IQ8LoxiGnw=
18931894
go.opentelemetry.io/otel/sdk v0.20.0/go.mod h1:g/IcepuwNsoiX5Byy2nNV0ySUF1em498m7hBWC279Yc=
18941895
go.opentelemetry.io/otel/sdk v1.3.0/go.mod h1:rIo4suHNhQwBIPg9axF8V9CA72Wz2mKF1teNrup8yzs=
1895-
go.opentelemetry.io/otel/sdk v1.11.0 h1:ZnKIL9V9Ztaq+ME43IUi/eo22mNsb6a7tGfzaOWB5fo=
1896-
go.opentelemetry.io/otel/sdk v1.11.0/go.mod h1:REusa8RsyKaq0OlyangWXaw97t2VogoO4SSEeKkSTAk=
1896+
go.opentelemetry.io/otel/sdk v1.11.1 h1:F7KmQgoHljhUuJyA+9BiU+EkJfyX5nVVF4wyzWZpKxs=
1897+
go.opentelemetry.io/otel/sdk v1.11.1/go.mod h1:/l3FE4SupHJ12TduVjUkZtlfFqDCQJlOlithYrdktys=
18971898
go.opentelemetry.io/otel/sdk/export/metric v0.20.0/go.mod h1:h7RBNMsDJ5pmI1zExLi+bJK+Dr8NQCh0qGhm1KDnNlE=
18981899
go.opentelemetry.io/otel/sdk/metric v0.20.0/go.mod h1:knxiS8Xd4E/N+ZqKmUPf3gTTZ4/0TjTXukfxjzSTpHE=
18991900
go.opentelemetry.io/otel/sdk/metric v0.31.0 h1:2sZx4R43ZMhJdteKAlKoHvRgrMp53V1aRxvEf5lCq8Q=
19001901
go.opentelemetry.io/otel/trace v0.20.0/go.mod h1:6GjCW8zgDjwGHGa6GkyeB8+/5vjT16gUEi0Nf1iBdgw=
19011902
go.opentelemetry.io/otel/trace v1.3.0/go.mod h1:c/VDhno8888bvQYmbYLqe41/Ldmr/KKunbvWM4/fEjk=
1902-
go.opentelemetry.io/otel/trace v1.11.0 h1:20U/Vj42SX+mASlXLmSGBg6jpI1jQtv682lZtTAOVFI=
1903-
go.opentelemetry.io/otel/trace v1.11.0/go.mod h1:nyYjis9jy0gytE9LXGU+/m1sHTKbRY0fX0hulNNDP1U=
1903+
go.opentelemetry.io/otel/trace v1.11.1 h1:ofxdnzsNrGBYXbP7t7zpUK281+go5rF7dvdIZXF8gdQ=
1904+
go.opentelemetry.io/otel/trace v1.11.1/go.mod h1:f/Q9G7vzk5u91PhbmKbg1Qn0rzH1LJ4vbPHFGkTPtOk=
19041905
go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI=
19051906
go.opentelemetry.io/proto/otlp v0.11.0/go.mod h1:QpEjXPrNQzrFDZgoTo49dgHR9RYRSrg3NAKnUGl9YpQ=
19061907
go.opentelemetry.io/proto/otlp v0.19.0 h1:IVN6GR+mhC4s5yfcTbmzHYODqvWAp3ZedA2SJPI1Nnw=
@@ -2680,8 +2681,8 @@ google.golang.org/grpc v1.45.0/go.mod h1:lN7owxKUQEqMfSyQikvvk5tf/6zMPsrK+ONuO11
26802681
google.golang.org/grpc v1.46.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk=
26812682
google.golang.org/grpc v1.46.2/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk=
26822683
google.golang.org/grpc v1.47.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk=
2683-
google.golang.org/grpc v1.49.0 h1:WTLtQzmQori5FUH25Pq4WT22oCsv8USpQ+F6rqtsmxw=
2684-
google.golang.org/grpc v1.49.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI=
2684+
google.golang.org/grpc v1.50.1 h1:DS/BukOZWp8s6p4Dt/tOaJaTQyPyOoCcrjroHuCeLzY=
2685+
google.golang.org/grpc v1.50.1/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI=
26852686
google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw=
26862687
google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8=
26872688
google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0=

site/src/components/PageHeader/PageHeader.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ const useStyles = makeStyles((theme) => ({
5252
display: "flex",
5353
alignItems: "center",
5454
paddingTop: theme.spacing(6),
55-
paddingBottom: theme.spacing(5),
55+
paddingBottom: theme.spacing(6),
5656

5757
[theme.breakpoints.down("sm")]: {
5858
flexDirection: "column",

site/src/components/PaginationWidget/PaginationWidget.test.tsx

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,29 +3,28 @@ import { render } from "../../testHelpers/renderHelpers"
33
import { PaginationWidget } from "./PaginationWidget"
44

55
describe("PaginatedList", () => {
6-
it("displays an accessible previous and next button regardless of the number of pages", async () => {
7-
const { container } = render(
6+
it("displays an accessible previous and next button", () => {
7+
render(
88
<PaginationWidget
99
prevLabel="Previous"
1010
nextLabel="Next"
11+
numRecords={200}
12+
numRecordsPerPage={12}
13+
activePage={1}
1114
onPrevClick={() => jest.fn()}
1215
onNextClick={() => jest.fn()}
1316
/>,
1417
)
1518

1619
expect(
17-
await screen.findByRole("button", { name: "Previous page" }),
18-
).toBeTruthy()
19-
expect(
20-
await screen.findByRole("button", { name: "Next page" }),
21-
).toBeTruthy()
22-
// Shouldn't render any pages if no records are passed in
20+
screen.getByRole("button", { name: "Previous page" }),
21+
).toBeInTheDocument()
2322
expect(
24-
await container.querySelectorAll(`button[name="Page button"]`),
25-
).toHaveLength(0)
23+
screen.getByRole("button", { name: "Next page" }),
24+
).toBeInTheDocument()
2625
})
2726

28-
it("displays the expected number of pages with one ellipsis tile", async () => {
27+
it("displays the expected number of pages with one ellipsis tile", () => {
2928
const { container } = render(
3029
<PaginationWidget
3130
prevLabel="Previous"
@@ -41,11 +40,11 @@ describe("PaginatedList", () => {
4140

4241
// 7 total spaces. 6 are page numbers, one is ellipsis
4342
expect(
44-
await container.querySelectorAll(`button[name="Page button"]`),
43+
container.querySelectorAll(`button[name="Page button"]`),
4544
).toHaveLength(6)
4645
})
4746

48-
it("displays the expected number of pages with two ellipsis tiles", async () => {
47+
it("displays the expected number of pages with two ellipsis tiles", () => {
4948
const { container } = render(
5049
<PaginationWidget
5150
prevLabel="Previous"
@@ -61,7 +60,7 @@ describe("PaginatedList", () => {
6160

6261
// 7 total spaces. 2 sets of ellipsis on either side of the active page
6362
expect(
64-
await container.querySelectorAll(`button[name="Page button"]`),
63+
container.querySelectorAll(`button[name="Page button"]`),
6564
).toHaveLength(5)
6665
})
6766
})

site/src/components/PaginationWidget/PaginationWidget.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,8 @@ export const PaginationWidget = ({
127127
const isMobile = useMediaQuery(theme.breakpoints.down("sm"))
128128
const styles = useStyles()
129129

130-
// No need to display any pagination if we know the number of pages is 1
131-
if (numPages === 1 || numRecords === 0) {
130+
// No need to display any pagination if we know the number of pages is 1 or 0
131+
if (numPages <= 1 || numRecords === 0) {
132132
return null
133133
}
134134

site/src/components/Pill/Pill.tsx

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import { makeStyles, Theme } from "@material-ui/core/styles"
22
import { FC } from "react"
3-
import { MONOSPACE_FONT_FAMILY } from "theme/constants"
43
import { PaletteIndex } from "theme/palettes"
54
import { combineClasses } from "util/combineClasses"
65

@@ -28,14 +27,12 @@ export const Pill: FC<PillProps> = (props) => {
2827

2928
const useStyles = makeStyles<Theme, PillProps>((theme) => ({
3029
wrapper: {
31-
fontFamily: MONOSPACE_FONT_FAMILY,
3230
display: "inline-flex",
3331
alignItems: "center",
3432
borderWidth: 1,
3533
borderStyle: "solid",
3634
borderRadius: 99999,
37-
fontSize: 14,
38-
fontWeight: 500,
35+
fontSize: 12,
3936
color: "#FFF",
4037
height: theme.spacing(3),
4138
paddingLeft: ({ icon }) =>

site/src/components/TemplateStats/TemplateStats.tsx

Lines changed: 11 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ import {
66
formatTemplateActiveDevelopers,
77
} from "util/templates"
88
import { Template, TemplateVersion } from "../../api/typesGenerated"
9-
import { MONOSPACE_FONT_FAMILY } from "../../theme/constants"
109

1110
const Language = {
1211
usedByLabel: "Used by",
@@ -32,7 +31,7 @@ export const TemplateStats: FC<TemplateStatsProps> = ({
3231
return (
3332
<div className={styles.stats}>
3433
<div className={styles.statItem}>
35-
<span className={styles.statsLabel}>{Language.usedByLabel}</span>
34+
<span className={styles.statsLabel}>{Language.usedByLabel}:</span>
3635

3736
<span className={styles.statsValue}>
3837
{formatTemplateActiveDevelopers(template.active_user_count)}{" "}
@@ -41,29 +40,27 @@ export const TemplateStats: FC<TemplateStatsProps> = ({
4140
: Language.developerPlural}
4241
</span>
4342
</div>
44-
<div className={styles.statsDivider} />
4543
<div className={styles.statItem}>
46-
<span className={styles.statsLabel}>{Language.buildTimeLabel}</span>
44+
<span className={styles.statsLabel}>{Language.buildTimeLabel}:</span>
4745

4846
<span className={styles.statsValue}>
4947
{formatTemplateBuildTime(template.build_time_stats.start_ms)}{" "}
5048
</span>
5149
</div>
52-
<div className={styles.statsDivider} />
5350
<div className={styles.statItem}>
54-
<span className={styles.statsLabel}>{Language.activeVersionLabel}</span>
51+
<span className={styles.statsLabel}>
52+
{Language.activeVersionLabel}:
53+
</span>
5554
<span className={styles.statsValue}>{activeVersion.name}</span>
5655
</div>
57-
<div className={styles.statsDivider} />
5856
<div className={styles.statItem}>
59-
<span className={styles.statsLabel}>{Language.lastUpdateLabel}</span>
57+
<span className={styles.statsLabel}>{Language.lastUpdateLabel}:</span>
6058
<span className={styles.statsValue} data-chromatic="ignore">
6159
{createDayString(template.updated_at)}
6260
</span>
6361
</div>
64-
<div className={styles.statsDivider} />
6562
<div className={styles.statItem}>
66-
<span className={styles.statsLabel}>{Language.createdByLabel}</span>
63+
<span className={styles.statsLabel}>{Language.createdByLabel}:</span>
6764
<span className={styles.statsValue}>{template.created_by_name}</span>
6865
</div>
6966
</div>
@@ -74,46 +71,32 @@ const useStyles = makeStyles((theme) => ({
7471
stats: {
7572
paddingLeft: theme.spacing(2),
7673
paddingRight: theme.spacing(2),
77-
backgroundColor: theme.palette.background.paper,
7874
borderRadius: theme.shape.borderRadius,
7975
display: "flex",
8076
alignItems: "center",
8177
color: theme.palette.text.secondary,
82-
fontFamily: MONOSPACE_FONT_FAMILY,
8378
border: `1px solid ${theme.palette.divider}`,
8479
[theme.breakpoints.down("sm")]: {
8580
display: "block",
8681
},
8782
},
8883

8984
statItem: {
90-
minWidth: "15%",
9185
padding: theme.spacing(2),
9286
paddingTop: theme.spacing(1.75),
87+
display: "flex",
88+
alignItems: "baseline",
89+
gap: theme.spacing(1),
9390
},
9491

9592
statsLabel: {
96-
fontSize: 12,
97-
textTransform: "uppercase",
9893
display: "block",
99-
fontWeight: 600,
10094
wordWrap: "break-word",
10195
},
10296

10397
statsValue: {
104-
fontSize: 16,
105-
marginTop: theme.spacing(0.25),
10698
display: "block",
10799
wordWrap: "break-word",
108-
},
109-
110-
statsDivider: {
111-
width: 1,
112-
height: theme.spacing(5),
113-
backgroundColor: theme.palette.divider,
114-
marginRight: theme.spacing(2),
115-
[theme.breakpoints.down("sm")]: {
116-
display: "none",
117-
},
100+
color: theme.palette.text.primary,
118101
},
119102
}))

site/src/components/Workspace/Workspace.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ export const Workspace: FC<React.PropsWithChildren<WorkspaceProps>> = ({
179179
<Stack
180180
direction="column"
181181
className={styles.firstColumnSpacer}
182-
spacing={6}
182+
spacing={4}
183183
>
184184
{buildError}
185185
{cancellationError}

0 commit comments

Comments
 (0)