Skip to content

Commit

Permalink
Text align center banner info box
Browse files Browse the repository at this point in the history
  • Loading branch information
noatpad committed Sep 15, 2023
1 parent a054e2f commit 99213c2
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 24 deletions.
16 changes: 4 additions & 12 deletions src/banner/Error.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,11 @@
</div>

<style lang="scss">
@import './mixins.scss';
.error {
position: absolute;
top: 0;
left: 0;
bottom: 0;
right: 0;
padding: 16px;
border: 4px solid var(--background-modifier-error);
margin: 16px;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
@include banner-info-box;
border-color: var(--background-modifier-error);
color: var(--text-error);
}
</style>
15 changes: 3 additions & 12 deletions src/banner/Loading.svelte
Original file line number Diff line number Diff line change
@@ -1,18 +1,9 @@
<div class="loading">Loading...</div>

<style lang="scss">
@import './mixins.scss';
.loading {
position: absolute;
top: 0;
left: 0;
bottom: 0;
right: 0;
padding: 16px;
border: 4px solid var(--background-modifier-border);
margin: 16px;
display: flex;
justify-content: center;
align-items: center;
color: var(--text-faint);
@include banner-info-box;
}
</style>
16 changes: 16 additions & 0 deletions src/banner/mixins.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
@mixin banner-info-box {
position: absolute;
top: 0;
left: 0;
bottom: 0;
right: 0;
padding: 16px;
border: 4px solid var(--background-modifier-border);
margin: 16px;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
color: var(--text-faint);
text-align: center;
}

0 comments on commit 99213c2

Please sign in to comment.