Skip to content

Commit 88c6225

Browse files
Centered the "Loading..." text. Fixes microsoft#1156
1 parent 8142e9f commit 88c6225

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

preview-src/app.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,5 @@ export function Root({ children }) {
1919
setPR(ctx.pr);
2020
}, []);
2121
ctx.postMessage({ command: 'pr.debug', args: ('initialized ' + (pr ? 'with PR' : 'without PR'))});
22-
return pr ? children(pr) : 'Loading...';
22+
return pr ? children(pr) : <div className='loading-indicator'>Loading...</div>;
2323
}

preview-src/index.css

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,13 @@ a:focus, input:focus, select:focus, textarea:focus, .title-text:focus {
4545
margin-left: 5px;
4646
}
4747

48+
.loading-indicator{
49+
position: fixed;
50+
top: 50%;
51+
left: 40%;
52+
transform: translate(-50%,-50%);
53+
}
54+
4855
.comment-body li div {
4956
display: inline;
5057
}

0 commit comments

Comments
 (0)