Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Improve the look of the spinner #6083

Merged
merged 6 commits into from
Nov 2, 2021
Merged
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
2 changes: 1 addition & 1 deletion res/css/views/elements/_InlineSpinner.scss
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,5 @@ limitations under the License.
}

.mx_InlineSpinner_icon {
display: inline-block;
display: inline-block !important; // Override regular mx_Spinner_icon
}
29 changes: 25 additions & 4 deletions res/css/views/elements/_Spinner.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/*
Copyright 2015, 2016 OpenMarket Ltd
Copyright 2021 Šimon Brandner <[email protected]>

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -37,8 +38,28 @@ limitations under the License.
}

.mx_Spinner_icon {
background-color: $primary-content;
mask: url('$(res)/img/spinner.svg');
mask-size: contain;
animation: 1.1s steps(12, end) infinite spin;
background-color: $quinary-content;
mask: url('$(res)/img/spinner/spinner-background.svg');
mask-size: 100%;

display: flex;
justify-content: center;
align-items: center;

width: 100%;
height: 100%;

&::before {
background-color: $secondary-content;
mask: url('$(res)/img/spinner/spinner-foreground.svg');
mask-size: 100%;

width: 100%;
height: 100%;

content: "";
display: flex;

animation: 1s linear spin infinite;
}
}
96 changes: 0 additions & 96 deletions res/img/spinner.svg

This file was deleted.

3 changes: 3 additions & 0 deletions res/img/spinner/spinner-background.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions res/img/spinner/spinner-foreground.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.